dkforest

A forum and chat platform (onion)
git clone https://git.dasho.dev/n0tr1v/dkforest.git
Log | Files | Refs | LICENSE

commit 14933f615c89b029befb8804be2b400628d3b8d3
parent 02211fe2643f2a60f0bbc5f0b44500f72927d856
Author: n0tr1v <n0tr1v@protonmail.com>
Date:   Fri, 15 Dec 2023 16:46:37 -0500

cleanup

Diffstat:
Mpkg/web/handlers/poker/poker.go | 4++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/pkg/web/handlers/poker/poker.go b/pkg/web/handlers/poker/poker.go @@ -1702,10 +1702,10 @@ func drawCountDownStyle(evt PokerWaitTurnEvent) string { html := "<style>" html += `#countdown1, #countdown2, #countdown3, #countdown4, #countdown5, #countdown6 { display: none; }` html += `#seat1, #seat2, #seat3, #seat4, #seat5, #seat6 { background-color: rgba(45, 45, 45, 0.4); }` - tmp := int((MaxUserCountdown*time.Second - time.Since(evt.CreatedAt)).Seconds()) + remainingSecs := int((MaxUserCountdown*time.Second - time.Since(evt.CreatedAt)).Seconds()) if evt.Idx >= 0 && evt.Idx <= 5 { html += `#seat` + itoa(evt.Idx+1) + ` { background-color: rgba(200, 45, 45, 0.7); }` - html += `#countdown` + itoa(evt.Idx+1) + ` { --duration: ` + itoa(tmp) + `; display: block; animation: time calc(var(--duration) * 1s) steps(1000, start) forwards; }` + html += `#countdown` + itoa(evt.Idx+1) + ` { --duration: ` + itoa(remainingSecs) + `; display: block; animation: time calc(var(--duration) * 1s) steps(1000, start) forwards; }` } html += "</style>" return html