mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2025-01-31 12:09:17 +08:00
Merge pull request #6412 from G-Chubinidze/gc_SCI_9429
Code sample in RTF on archived results is not highlighted with colors [SCI-9429]
This commit is contained in:
commit
e5a7e2d4ba
1 changed files with 10 additions and 0 deletions
|
@ -106,6 +106,10 @@
|
|||
if (this.isNew) {
|
||||
this.enableEditMode();
|
||||
}
|
||||
|
||||
this.$nextTick(() => {
|
||||
this.highlightText();
|
||||
})
|
||||
},
|
||||
computed: {
|
||||
actionMenu() {
|
||||
|
@ -167,6 +171,12 @@
|
|||
this.element.attributes.orderable.name = data.attributes.name
|
||||
this.element.attributes.orderable.updated_at = data.attributes.updated_at
|
||||
this.$emit('update', this.element, true)
|
||||
},
|
||||
highlightText() {
|
||||
var textElement = $('.results-list')[0]
|
||||
if (textElement) {
|
||||
Prism.highlightAllUnder(textElement)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue