Quantum-Game / quantum-game-2

LEGACY open-source version of Quantum Game 2 (Sept 2019 - Oct 2020)
https://quantumgame.io
MIT License
65 stars 16 forks source link

responsive views #91

Closed SektorDV closed 4 years ago

stared commented 4 years ago

I get a TypeScript error:

ERROR in /Users/pmigdal/my_repos/QG/quantum-game-2/src/components/Board/index.vue
137:37 Property 'boardScaler' does not exist on type '{ 'gridWrapper': HTMLElement; }'.
    135 |
    136 |   assessTileSize(): void {
  > 137 |     const currentWidth = this.$refs.boardScaler.getBoundingClientRect().width;
        |                                     ^
    138 |     const currentHeight = this.$refs.gridWrapper.getBoundingClientRect().height;
    139 |     this.$data.scalerStyle = {
    140 |       transform: `scale(${currentWidth / 870})`
ERROR in /Users/pmigdal/my_repos/QG/quantum-game-2/src/store/userStore.ts
stared commented 4 years ago

Overall, it is very nice, thank you @SektorDV ! There are some problems that need to be addressed, though (look at my comments).

I created, and merged, a different PR #92 where I addressed the most important things (I data()).