linting and formating

This commit is contained in:
Gator
2022-12-02 17:11:34 +01:00
parent 0556992c3b
commit d7c2d45180
9 changed files with 66 additions and 62 deletions

View File

@ -25,7 +25,7 @@
</div>
<div class="form-field">
<label
>Rules presets
>Rules presets
<br />
<select
name="ruleset-elementary"
@ -51,7 +51,7 @@
class="form-field"
>
<label
>{{ name }}
>{{ name }}
<input
:value="rule"
type="checkbox"
@ -76,8 +76,8 @@
</template>
<script>
import { mapActions, mapWritableState } from 'pinia'
import { presetRules, initialStates } from "./preset.js"
import { mapActions, mapWritableState } from "pinia";
import { presetRules, initialStates } from "./preset.js";
import { globalStore } from "../stores/index.js";
import MenuRow from "./MenuRow.vue";
export default {
@ -92,20 +92,18 @@
};
},
computed: {
...mapWritableState(
globalStore, {
initialState: "initial1dState",
rules: "rules1d"
}
),
...mapWritableState(globalStore, {
initialState: "initial1dState",
rules: "rules1d",
}),
rules1dFileName() {
// TODO: broken
return (
Object.keys(this.rules)
.map((index) => {
return this.rules[index];
})
.join("_") + ".json"
.map((index) => {
return this.rules[index];
})
.join("_") + ".json"
);
},
},
@ -130,20 +128,20 @@
const newRuleset = this.presetRules.find((ruleset) => {
return ruleset.name === name;
});
this.rules.rules = newRuleset.rules
this.rules.rules = newRuleset.rules;
},
updateInitialState(event) {
const elem = event.target;
this.initial1dState = elem.value
this.initial1dState = elem.value;
},
},
};
</script>
<style>
.menu-row a {
color: white;
font-weight: bold;
text-decoration: none;
font-size: small;
color: white;
font-weight: bold;
text-decoration: none;
font-size: small;
}
</style>