Add help modal on index. Adjustments in Checkered rules
[vchess.git] / views / index.pug
1 extends layout
2
3 block css
4 link(rel="stylesheet", href="/stylesheets/index.css")
5
6 block content
7 .container#indexPage
8 .row
9 .col-sm-12
10 h1.text-center Welcome to v[ariant] chess club !
11 h2.help.text-center(onClick="document.getElementById('modal-control').checked=true") Help ?
12 input#modal-control.modal(type="checkbox")
13 div(role="dialog")
14 .card
15 label.modal-close(for="modal-control")
16 h3.blue.section Modes
17 p.section.
18 Each variant page offers two modes: against a human or computer opponent.
19 The latter is not designed to play well: it is here to help learning the rules.
20 When you beat the bot easily consider playing human opponents!
21 h3.blue.section Initial position
22 p.section.
23 Whenever possible, all games start with a random assymetric position.
24 This might be unapplicable for some variants: Moscow Chess at least (coming soon),
25 Racing Kings probably too.
26 h3.blue.section Comments
27 p.section.
28 Games are untimed, and played anonymously. This website lacks a user/challenge/chat/... system,
29 both for technical reasons (difficult to maintain all that alone) and also a bit for
30 focusing on the essential: the moves! :)
31 .row
32 my-variant-summary(
33 v-for="(v,idx) in sortedCounts",
34 v-show="v.name.startsWith(curPrefix)",
35 v-bind:vobj="v",
36 v-bind:key="v.name")
37
38 block javascripts
39 script.
40 const variantArray = !{JSON.stringify(variantArray)};
41 //JSON.parse("!{variantArray}".replace(/\"/g,'"'));
42 script(src="/javascripts/utils/socket_url.js")
43 script(src="/javascripts/components/variantSummary.js")
44 script(src="/javascripts/index.js")