From 93527a60b8bb7bf6b66a2e16c5ccc483aa103a1e Mon Sep 17 00:00:00 2001 From: ElnuDev Date: Mon, 5 Dec 2022 14:22:16 -0800 Subject: [PATCH] Don't show kyujitai info when no kyujitai --- themes/tegakituesday.com/layouts/challenges/single.html | 2 +- themes/tegakituesday.com/static/js/toggle.js | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/themes/tegakituesday.com/layouts/challenges/single.html b/themes/tegakituesday.com/layouts/challenges/single.html index c553b82..7c41bca 100644 --- a/themes/tegakituesday.com/layouts/challenges/single.html +++ b/themes/tegakituesday.com/layouts/challenges/single.html @@ -14,7 +14,7 @@ - +

Tegaki Tuesday #{{- $current -}}

()()きの()(よう)()#{{- $current -}}・ diff --git a/themes/tegakituesday.com/static/js/toggle.js b/themes/tegakituesday.com/static/js/toggle.js index 86cb333..7387224 100644 --- a/themes/tegakituesday.com/static/js/toggle.js +++ b/themes/tegakituesday.com/static/js/toggle.js @@ -36,6 +36,8 @@ for (let i = 0; i < rubies.length; i++) { const kyujitaiButton = document.getElementById("kyujitai"); if (kyujitaiConvertable.length === 0) { kyujitaiButton.parentNode.removeChild(kyujitaiButton); + const kyujitaiInfo = document.getElementById("kyujitai-info"); + kyujitaiInfo.parentNode.removeChild(kyujitaiInfo); } else { document.getElementById("kyujitai").addEventListener("click", function() { let kyujitai = false;