template code tweaks
This commit is contained in:
parent
3e23c56396
commit
e4839dee94
|
@ -188,10 +188,7 @@ asyncJs: Boolean = false)(body: Html)(implicit ctx: Context)
|
|||
@if(ctx.requiresFingerprint) { @fingerprintTag }
|
||||
@jsAt(s"compiled/lichess.site${isProd??".min"}.js", async = asyncJs)
|
||||
@moreJs
|
||||
@embedJs {lichess.quantity=@i18nJsQuantityFunction;@timeagoLocaleScript;}
|
||||
@if(ctx.pageData.inquiry.isDefined) { @jsTag("inquiry.js") }
|
||||
@embedJs {
|
||||
lichess.quantity=@i18nJsQuantityFunction;
|
||||
@timeagoLocaleScript;
|
||||
}
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
@ -65,10 +65,10 @@
|
|||
window.customWS = true;
|
||||
lichess_lobby = {
|
||||
data: @safeJson(data),
|
||||
playban: @playban.fold(Html("null")){ pb =>
|
||||
playban: @htmlOrNull(playban) { pb =>
|
||||
@safeJson(Json.obj("minutes" -> pb.mins, "remainingSeconds" -> (pb.remainingSeconds + 3)))
|
||||
},
|
||||
currentGame: @currentGame.fold(Html("null")) { cg =>
|
||||
currentGame: @htmlOrNull(currentGame) { cg =>
|
||||
@safeJson(cg.json)
|
||||
},
|
||||
i18n: @jsI18n()
|
||||
|
|
Loading…
Reference in a new issue