Compare commits
2 Commits
9cd0537717
...
6215550ff5
Author | SHA1 | Date | |
---|---|---|---|
6215550ff5 | |||
7f0f1dfdd7 |
@ -2,6 +2,8 @@
|
||||
|
||||
Explore 1D and 2D cellular automata, with a few bells and whistles.
|
||||
|
||||
![rules73](./example.png)
|
||||
|
||||
## Project setup
|
||||
|
||||
```
|
||||
|
BIN
example.png
Normal file
BIN
example.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 103 KiB |
@ -10,9 +10,6 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { mapWritableState } from "pinia";
|
||||
import { globalStore } from "../stores/index.js";
|
||||
|
||||
export default {
|
||||
name: "MenuRow",
|
||||
props: {
|
||||
@ -21,9 +18,10 @@
|
||||
default: "",
|
||||
},
|
||||
},
|
||||
computed: {
|
||||
// TODO: should be passed as a props/slot, not in a store
|
||||
...mapWritableState(globalStore, ["activeMenu"]),
|
||||
data() {
|
||||
return {
|
||||
activeMenu: "",
|
||||
};
|
||||
},
|
||||
methods: {
|
||||
updateActiveMenu(event) {
|
||||
|
@ -27,7 +27,6 @@ export const globalStore = defineStore("globalStore", {
|
||||
boardHeight: 0,
|
||||
refreshRate: 300,
|
||||
initial1dState: "onecell",
|
||||
activeMenu: "",
|
||||
drawingDirection: "y",
|
||||
lastBoard: {},
|
||||
draw1d: false,
|
||||
|
Loading…
Reference in New Issue
Block a user