toggle star/dot on collector's info

This commit is contained in:
Kyle
2021-04-03 11:05:39 -07:00
parent 1ddf2dd3b1
commit 19f435b246
2 changed files with 20 additions and 2 deletions

View File

@@ -1089,6 +1089,18 @@ function artistEdited(value) {
document.querySelector('#info-artist').value = value;
bottomInfoEdited();
}
function toggleStarDot() {
for (var key of Object.keys(card.bottomInfo)) {
var text = card.bottomInfo[key].text
if (text.includes('*')) {
card.bottomInfo[key].text = text.replace('*', ' \u2022 ');
} else {
card.bottomInfo[key].text = text.replace(' \u2022 ', '*');
}
// console.log(textObject[1].text)
}
bottomInfoEdited();
}
//DRAWING THE CARD (putting it all together)
function drawCard() {
cardContext.globalCompositeOperation = 'source-over';