a43ba6016bbf4fea6b417146a41b47617fc1ff6c
[vchess.git] / views / variant.pug
1 extends layout
2
3 block css
4 link(rel="stylesheet" href="/stylesheets/variant.css")
5
6 block content
7 .container#variantPage
8 .row
9 .col-sm-12.col-md-10.col-md-offset-1.col-lg-8.col-lg-offset-2
10 label.drawer-toggle(for="drawer-control")
11 input#drawer-control.drawer(type="checkbox")
12 #menuBar
13 label.drawer-close(for="drawer-control")
14 a.icon-link(href="/")
15 i.material-icons home
16 a(href="#room" @click="setDisplay('room')")
17 =translations["Hall"]
18 a(href="#gameList" @click="setDisplay('gameList')")
19 =translations["My games"]
20 a(href="#rules" @click="setDisplay('rules')")
21 =translations["Rules"]
22 a(href="#problems" @click="setDisplay('problems')")
23 =translations["Problems"]
24 #settings.clickable(
25 onClick="document.getElementById('modalSettings').checked=true")
26 i.material-icons settings
27 .row
28 my-room(v-show="display=='room'")
29 my-games-list(v-show="display=='gameList'")
30 my-rules(v-show="display=='rules'")
31 my-problems(v-show="display=='problems'")
32 // my-game: for room and games-list components
33 my-game(v-show="display=='game'" :gameId="gameid")
34
35 block javascripts
36 script(src="/javascripts/utils/misc.js")
37 script(src="/javascripts/utils/array.js")
38 script(src="/javascripts/utils/printDiagram.js")
39 script(src="/javascripts/utils/datetime.js")
40 script(src="/javascripts/socket_url.js")
41 script(src="/javascripts/base_rules.js")
42 script(src="/javascripts/variants/" + variant + ".js")
43 script.
44 const V = VariantRules; //because this variable is often used
45 const variant = "#{variant}";
46 script(src="/javascripts/components/rules.js")
47 script(src="/javascripts/components/game.js")
48 script(src="/javascripts/components/problemSummary.js")
49 script(src="/javascripts/components/problems.js")
50 script(src="/javascripts/variant.js")