mask template tag title popup when preview is disabled (#1995)

This commit is contained in:
Alfonso Ruzafa 2020-03-13 00:00:11 +01:00 committed by GitHub
parent 7aae21154a
commit 39c73e17c5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -268,7 +268,8 @@ async function _updateElementText(render, mark, text, renderContext, isVariableU
} else {
innerHTML = tagDefinition.displayName || tagData.name;
}
title = await render(text);
const preview = await render(text);
title = tagDefinition.disablePreview(tagData.args) ? preview.replace(/./g, '*') : preview;
} else {
innerHTML = cleanedStr;
title = 'Unrecognized tag';