Checkbox also update settings
This commit is contained in:
parent
414aef6924
commit
b6d64d65b5
6 changed files with 45 additions and 40 deletions
|
@ -19,6 +19,10 @@ local function SplitSentences(paragraph)
|
|||
return sentences
|
||||
end
|
||||
|
||||
local function ReplaceMultipleBreakLines(text)
|
||||
return text:gsub("\r?\n+", "\n\n")
|
||||
end
|
||||
|
||||
local function ParseParagraphs(original_text, translation_text)
|
||||
if original_text == "" or original_text == nil then
|
||||
return translation_text
|
||||
|
@ -54,8 +58,8 @@ local function ParseParagraphs(original_text, translation_text)
|
|||
table.insert(translation_paragraphs, table.concat(collected, " "))
|
||||
end
|
||||
|
||||
local final_text = table.concat(translation_paragraphs, "\n")
|
||||
|
||||
return final_text
|
||||
return ReplaceMultipleBreakLines(
|
||||
table.concat(translation_paragraphs, "\n")
|
||||
)
|
||||
end
|
||||
addon.API.ParseParagraphs = ParseParagraphs
|
Loading…
Add table
Add a link
Reference in a new issue