portraits fix

This commit is contained in:
Alexander Yakovlev 2021-10-28 19:26:52 +07:00
parent fc125db6a8
commit 5544d99fff
Signed by: oreolek
GPG key ID: 8D24103F5EE2A6C0

View file

@ -76,7 +76,11 @@ continueToNextChoice = function(s) {
if (s.currentChoices.length > 0) {
const characters = listCharacters(jQuery("#content").text());
if (characters.trim().length > 0) {
jQuery("#content").prepend('<div class="portraits">'+characters.trim()+'</div>')
if (jQuery("#content .portraits").length === 0) {
jQuery("#content").prepend('<div class="portraits">'+characters.trim()+'</div>')
} else {
jQuery(".portraits").html(characters.trim())
}
}
jQuery("#options").html("").hide();
ref = s.currentChoices;