Add a comment about avatar.js
This commit is contained in:
parent
c13daedcb0
commit
f6f29adacc
1 changed files with 3 additions and 0 deletions
|
@ -54,6 +54,9 @@ function renderImage(imagePart) {
|
|||
}
|
||||
|
||||
function renderPill(pillPart) {
|
||||
// The classes and structure are borrowed from avatar.js;
|
||||
// We don't call renderStaticAvatar because that would require
|
||||
// an intermediate object that has getAvatarUrl etc.
|
||||
const classes = `avatar size-12 usercolor${pillPart.avatarColorNumber}`;
|
||||
const avatar = tag.div({class: classes}, text(pillPart.avatarInitials));
|
||||
const children = renderParts(pillPart.children);
|
||||
|
|
Reference in a new issue