lib/isodoc/function/utils.rb in isodoc-1.1.4 vs lib/isodoc/function/utils.rb in isodoc-1.2.0

- old
+ new

@@ -9,11 +9,12 @@ def ns(xpath) self.class.ns(xpath) end def insert_tab(out, n) - [1..n].each { out << '&nbsp; ' } + tab = %w(Hans Hant).include?(@script) ? "&#x3000;" : "&nbsp; " + [1..n].each { out << tab } end # add namespaces for Word fragments NOKOHEAD = <<~HERE <!DOCTYPE html SYSTEM @@ -97,11 +98,11 @@ def sentence_join(array) return '' if array.nil? || array.empty? if array.length == 1 then array[0] else - IsoDoc::Function::I18n::l10n("#{array[0..-2].join(', ')} "\ - "#{@and_lbl} #{array.last}", + @i18n.l10n("#{array[0..-2].join(', ')} "\ + "#{@i18n.and} #{array.last}", @lang, @script) end end # avoid `; avoid {{ (Liquid Templates); avoid [[ (Javascript)