Add support for custom text type generation (#1683)

This commit is contained in:
toasted-nutbread 2021-05-16 15:52:39 -04:00 committed by GitHub
parent 66d048832f
commit 39cabc4db6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -293,6 +293,8 @@ class DisplayGenerator {
return this._createTermDefinitionEntryText(entry);
} else if (typeof entry === 'object' && entry !== null) {
switch (entry.type) {
case 'text':
return this._createTermDefinitionEntryText(entry.text);
case 'image':
return this._createTermDefinitionEntryImage(entry, dictionary);
}