From b7a5d24b671cb62d066cfb04d6f9d9bfa4714e90 Mon Sep 17 00:00:00 2001 From: cyfraeviolae Date: Mon, 28 Feb 2022 22:20:52 -0500 Subject: one more poem --- static/script.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'static/script.js') diff --git a/static/script.js b/static/script.js index 325b8e5..4648567 100644 --- a/static/script.js +++ b/static/script.js @@ -194,7 +194,8 @@ function winGame(challenge) { winEl.style = 'display: block;' document.getElementById('btns').style = 'display: none;' document.getElementById('meter').innerText = challenge.meter - document.getElementById('ctx').innerHTML = challenge.ctx.replaceAll(/^(.*)/gm, ' $1') + `\n\t${challenge.title}\n\t\t${challenge.collection}, ${challenge.author}` + var collection = challenge.collection ? `${challenge.collection}, ` : "" + document.getElementById('ctx').innerHTML = challenge.ctx.replaceAll(/^(.*)/gm, ' $1') + `\n\t${challenge.title}\n\t\t${collection}${challenge.author}` var firstguess = Object.values(guesses[0]).join(' ') document.getElementById('share').value = `I solved Prosodyle #${getChallengeIdx()+1} at cyfraeviolae.org/prosodyle. My first guess was: "${firstguess}."` } -- cgit v1.2.3