Skip to content
Snippets Groups Projects
Commit 832f3b3f authored by Henrik Askjer's avatar Henrik Askjer
Browse files

keep italics

parent 41cdcacd
No related branches found
No related tags found
No related merge requests found
......@@ -138,9 +138,11 @@ export default {
let linkIndex = 0
old_parts.forEach((item) => {
if (item == '$') {
if (definition.elements[0].items[linkIndex].id) {
let subitem = definition.elements[0].items[linkIndex]
if (subitem.id) {
new_string += entities[this.dictionary][definition.elements[0].items[linkIndex].id].expansion
}
else if (subitem.text) new_string += subitem.text
else {
new_string += definition.elements[0].items[linkIndex].lemmas[0].lemma
......@@ -158,7 +160,7 @@ export default {
})
console.log("STRING", new_string)
console.log("LAST", new_string.substring(new_string.length, new_string.length - 1))
if (new_string.substring(new_string.length, new_string.length - 1) == ":") {
new_string = new_string.slice(0, -1)+"[...]"
}
......@@ -170,7 +172,7 @@ export default {
}
})
return definitionTexts.join(" [...] ")
return definitionTexts.join(" | ")
},
expand: function() {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment