Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/text.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'src/extensions/UserColor.js')
-rw-r--r--src/extensions/UserColor.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/extensions/UserColor.js b/src/extensions/UserColor.js
index 2dd786b18..d359b3443 100644
--- a/src/extensions/UserColor.js
+++ b/src/extensions/UserColor.js
@@ -73,10 +73,11 @@ export default class UserColor extends Extension {
.filter(span => typeof tState.commits[span.commit]?.author?.color !== 'undefined')
.map(span => {
const commit = tState.commits[span.commit]
+ const clientID = commit.author.clientID
return Decoration.inline(span.from, span.to, {
class: 'author-annotation',
- style: 'background-color: ' + commit.author.color + 'ee;',
- title: commit.author.name,
+ style: 'background-color: ' + this.spec.color(clientID) + 'ee;',
+ title: this.spec.name(clientID),
})
}).filter(dec => dec !== null)
return { tracked, deco: DecorationSet.create(state.doc, decos) }