X-Git-Url: https://git.auder.net/pieces/Checkered/cn.svg?a=blobdiff_plain;f=client%2Fsrc%2Fcomponents%2FSettings.vue;h=d2194dae9d4fac32f75bc44d359ecb0c47f998ec;hb=af34341d92d47d14f396e7f4adb81f2a7e9d9a61;hp=df60e04cf9d61b8dbff8060be71acb8dc48c31aa;hpb=9a3049f3a48fa4b3627ef26ccdf213a8e550d478;p=vchess.git
diff --git a/client/src/components/Settings.vue b/client/src/components/Settings.vue
index df60e04c..d2194dae 100644
--- a/client/src/components/Settings.vue
+++ b/client/src/components/Settings.vue
@@ -1,18 +1,44 @@
div
input#modalSettings.modal(type="checkbox")
- div(role="dialog" data-checkbox="modalSettings")
- .card(@change="updateSettings($event)")
+ div#settingsDiv(
+ role="dialog"
+ data-checkbox="modalSettings"
+ )
+ .card
label.modal-close(for="modalSettings")
- h3.section {{ st.tr["Settings"] }}
- form
+ -
+ var langName = {
+ "en": "English",
+ "es": "Español",
+ "fr": "Français",
+ };
+ fieldset(@change="setLanguage($event)")
+ label(for="langSelect")
+ | {{ st.tr["Language"] }}
+ select#langSelect
+ each language,langCode in langName
+ option(value=langCode)
+ =language
+ #flagContainer
+ img(
+ v-if="!!st.lang"
+ :src="flagImage"
+ )
+ div(@change="updateSettings($event)")
fieldset
- label(for="setHints") {{ st.tr["Show possible moves?"] }}
- input#setHints(type="checkbox" v-model="st.settings.hints")
+ label(for="setHints") {{ st.tr["Show possible moves"] }}
+ input#setHints(
+ type="checkbox"
+ v-model="st.settings.hints"
+ )
fieldset
label(for="setHighlight")
- | {{ st.tr["Highlight last move and checks?"] }}
- input#setHighlight(type="checkbox" v-model="st.settings.highlight")
+ | {{ st.tr["Highlight last move"] }}
+ input#setHighlight(
+ type="checkbox"
+ v-model="st.settings.highlight"
+ )
fieldset
label(for="setBcolor") {{ st.tr["Board colors"] }}
select#setBcolor(v-model="st.settings.bcolor")
@@ -20,39 +46,78 @@ div
option(value="chesscom") {{ st.tr["green"] }}
option(value="chesstempo") {{ st.tr["blue"] }}
fieldset
- label(for="setSound") {{ st.tr["Play sounds?"] }}
- select#setSound(v-model="st.settings.sound")
- option(value="0") {{ st.tr["None"] }}
- option(value="1") {{ st.tr["New game"] }}
- option(value="2") {{ st.tr["All"] }}
+ label(for="setSound")
+ | {{ st.tr["Sound alert at game start"] }}
+ input#setSound(
+ type="checkbox"
+ v-model="st.settings.sound"
+ )
+ fieldset
+ label(for="setGotonext")
+ | {{ st.tr["Show next game after a move"] }}
+ input#setGotonext(
+ type="checkbox"
+ v-model="st.settings.gotonext"
+ )
+ fieldset
+ label(for="setRandomness") {{ st.tr["Randomness"] }}
+ select#setRandomness(v-model="st.settings.randomness")
+ option(value="0") {{ st.tr["Deterministic"] }}
+ option(value="1") {{ st.tr["Symmetric random"] }}
+ option(value="2") {{ st.tr["Asymmetric random"] }}