Skip to content

Commit f7a5668

Browse files
committed
Merge branch 'release/3.1.2'
2 parents c006f60 + 01b5fe6 commit f7a5668

File tree

10 files changed

+1625
-945
lines changed

10 files changed

+1625
-945
lines changed

.github/workflows/build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ jobs:
3030

3131
- uses: actions/setup-node@v3
3232
with:
33-
node-version: 18
33+
node-version: 20
3434
cache: npm
3535

3636
- run: npm install

.github/workflows/deploy.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ jobs:
2424

2525
- uses: actions/setup-node@v3
2626
with:
27-
node-version: 18
27+
node-version: 20
2828
cache: npm
2929

3030
- run: npm install

index.html

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,18 @@
1010
<link rel="icon" type="image/svg+xml" href="/img/icons/favicon.svg">
1111
<link rel="apple-touch-icon" href="/img/icons/apple-touch-icon-180x180.png" sizes="180x180">
1212
<link rel="mask-icon" href="/img/icons/maskable-icon-512x512.png" color="#fff">
13+
<!-- Matomo Tracking: Cookie-less and GDPR-conformant -->
14+
<script>
15+
var _paq = window._paq = window._paq || [];
16+
(function() {
17+
var u="//matomo.brdgm.me/";
18+
_paq.push(['setTrackerUrl', u+'matomo.php']);
19+
_paq.push(['setSiteId', '2']);
20+
var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0];
21+
g.async=true; g.src=u+'matomo.js'; s.parentNode.insertBefore(g,s);
22+
})();
23+
</script>
24+
<!-- End Matomo Code -->
1325
</head>
1426
<body>
1527
<noscript>

package-lock.json

Lines changed: 1568 additions & 905 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 23 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@brdgm/ark-nova-solo-helper",
3-
"version": "3.1.1",
3+
"version": "3.1.2",
44
"private": true,
55
"description": "Ark Nova Solo Helper",
66
"appDeployName": "ark-nova",
@@ -12,43 +12,46 @@
1212
"test:unit": "vitest",
1313
"test:coverage": "vitest run --coverage",
1414
"lint": "eslint . --ext .vue,.js,.jsx,.cjs,.mjs,.ts,.tsx,.cts,.mts --fix --ignore-path .gitignore",
15+
"lint:watch": "nodemon --exec \"npm run lint\" --ext .vue,.js,.jsx,.cjs,.mjs,.ts,.tsx,.cts,.mts",
1516
"generate-pwa-assets": "pwa-assets-generator"
1617
},
1718
"dependencies": {
1819
"@popperjs/core": "~2.11.8",
1920
"bootstrap": "~5.3.2",
20-
"brdgm-commons": "github:brdgm/brdgm-commons#1.3.1",
21-
"core-js": "~3.34.0",
21+
"brdgm-commons": "github:brdgm/brdgm-commons#1.6.1",
22+
"core-js": "~3.36.0",
2223
"lodash": "~4.17.21",
23-
"vue": "~3.3.11",
24-
"vue-i18n": "~9.8.0",
24+
"vue": "~3.4.19",
25+
"vue-i18n": "~9.9.1",
2526
"vue-router": "~4.2.5",
2627
"vuex": "~4.1.0"
2728
},
2829
"devDependencies": {
29-
"@intlify/unplugin-vue-i18n": "^1.5.0",
30+
"@intlify/unplugin-vue-i18n": "^2.0.0",
3031
"@types/bootstrap": "^5.2.10",
3132
"@types/chai": "^4.3.11",
3233
"@types/jsdom": "^21.1.6",
34+
"@types/lodash": "^4.14.202",
3335
"@types/mocha": "^10.0.6",
34-
"@typescript-eslint/eslint-plugin": "^6.14.0",
35-
"@typescript-eslint/parser": "^6.14.0",
36-
"@vite-pwa/assets-generator": "^0.1.0",
37-
"@vitejs/plugin-legacy": "^5.2.0",
38-
"@vitejs/plugin-vue": "^4.5.2",
39-
"@vitest/coverage-istanbul": "^1.0.4",
36+
"@typescript-eslint/eslint-plugin": "^7.0.1",
37+
"@typescript-eslint/parser": "^7.0.1",
38+
"@vite-pwa/assets-generator": "^0.2.4",
39+
"@vitejs/plugin-legacy": "^5.3.0",
40+
"@vitejs/plugin-vue": "^5.0.4",
41+
"@vitest/coverage-istanbul": "^1.3.0",
4042
"@vue/eslint-config-typescript": "^12.0.0",
4143
"babel-plugin-istanbul": "^6.1.1",
42-
"chai": "^4.3.10",
43-
"eslint": "^8.55.0",
44-
"eslint-plugin-vue": "^9.19.2",
45-
"jsdom": "^23.0.1",
46-
"sass": "^1.69.5",
44+
"chai": "^5.1.0",
45+
"eslint": "^8.56.0",
46+
"eslint-plugin-vue": "^9.21.1",
47+
"jsdom": "^24.0.0",
48+
"nodemon": "^3.0.3",
49+
"sass": "^1.71.0",
4750
"source-map-support": "^0.5.21",
4851
"ts-node": "^10.9.2",
4952
"typescript": "~5.3.3",
50-
"vite": "^5.0.8",
51-
"vite-plugin-pwa": "^0.17.4",
52-
"vitest": "^1.0.4"
53+
"vite": "^5.1.3",
54+
"vite-plugin-pwa": "^0.19.0",
55+
"vitest": "^1.3.0"
5356
}
5457
}

src/router/index.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
import { RouteRecordRaw } from 'vue-router'
2+
import createRouterMatomoTracking from 'brdgm-commons/src/util/router/createRouterMatomoTracking'
3+
import { name, version, appDeployName } from '@/../package.json'
24
import AppHome from '@/views/AppHome.vue'
35
import NotFound from '@/views/NotFound.vue'
46
import SetupGame from '@/views/SetupGame.vue'
57
import RoundPlayer from '@/views/RoundPlayer.vue'
68
import RoundBot from '@/views/RoundBot.vue'
79
import SetupARNO from '@/views/SetupARNO.vue'
810
import Scoring from '@/views/Scoring.vue'
9-
import createRouter from 'brdgm-commons/src/util/router/createRouter'
10-
import { name } from '@/../package.json'
1111

1212
const LOCALSTORAGE_KEY = `${name}.route`
1313

@@ -49,4 +49,4 @@ const routes: Array<RouteRecordRaw> = [
4949
}
5050
]
5151

52-
export default createRouter(routes, LOCALSTORAGE_KEY, 'AppHome')
52+
export default createRouterMatomoTracking(routes, LOCALSTORAGE_KEY, appDeployName, version, 'AppHome')

src/services/CardSlots.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { CardSlotsPersistence } from '@/store'
2-
import * as _ from 'lodash'
2+
import { shuffle, cloneDeep } from 'lodash'
33
import Card from './Card'
44
import Cards from './Cards'
55
import CardName from './enum/CardName'
@@ -91,7 +91,7 @@ export default class CardSlots {
9191
public toPersistence() : CardSlotsPersistence {
9292
return {
9393
slots: this._slots.map(card => card.name),
94-
upgradedCards: _.cloneDeep(this._upgradedCards)
94+
upgradedCards: cloneDeep(this._upgradedCards)
9595
}
9696
}
9797

@@ -101,7 +101,7 @@ export default class CardSlots {
101101
public static new() : CardSlots {
102102
const cards = [
103103
Cards.get(CardName.ANIMALS),
104-
..._.shuffle(Cards.getAll().filter(card => card.name != CardName.ANIMALS))
104+
...shuffle(Cards.getAll().filter(card => card.name != CardName.ANIMALS))
105105
]
106106
return new CardSlots(cards, [])
107107
}
@@ -112,7 +112,7 @@ export default class CardSlots {
112112
public static fromPersistence(persistence : CardSlotsPersistence) : CardSlots {
113113
return new CardSlots(
114114
persistence.slots.map(Cards.get),
115-
_.cloneDeep(persistence.upgradedCards)
115+
cloneDeep(persistence.upgradedCards)
116116
)
117117
}
118118

src/services/enum/Expansion.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* Expansion
33
*/
44
enum Expansion {
5-
ARNO_CONSERVATION_PROJECT_MODULE = "arno-conservation-project-module",
6-
MARINE_WORLDS = "marine-worlds"
5+
ARNO_CONSERVATION_PROJECT_MODULE = 'arno-conservation-project-module',
6+
MARINE_WORLDS = 'marine-worlds'
77
}
88
export default Expansion

tsconfig.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
"types": [
1616
"mocha",
1717
"chai",
18+
"vite/client",
1819
"vite-plugin-pwa/client",
1920
"@intlify/unplugin-vue-i18n/messages"
2021
],

vite.config.ts

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -15,16 +15,17 @@ export default defineConfig({
1515
registerType: 'prompt',
1616
manifestFilename: 'manifest.json',
1717
filename: 'service-worker.js',
18+
// cache all asset imports
19+
workbox: {
20+
globPatterns: ["**/*"]
21+
},
22+
// include all static assets
1823
includeAssets: [
19-
'favicon.ico',
20-
'img/icons/favicon.ico',
21-
'img/icons/favicon.svg',
22-
'img/icons/apple-touch-icon-60x60.png',
23-
'img/icons/apple-touch-icon-76x76.png',
24-
'img/icons/apple-touch-icon-120x120.png',
25-
'img/icons/apple-touch-icon-152x152.png',
26-
'img/icons/apple-touch-icon-180x180.png',
27-
'img/icons/maskable-icon-512x512.png'
24+
"**/*.ico",
25+
"**/*.svg",
26+
"**/*.png",
27+
"**/*.jpg",
28+
"**/*.webp"
2829
],
2930
manifest: {
3031
name: description,

0 commit comments

Comments
 (0)