From cd5f4ad91ad8f3ced3096a2ad248e178a3bd999b Mon Sep 17 00:00:00 2001 From: Jose Conde Date: Mon, 22 Jul 2024 21:04:51 +0200 Subject: [PATCH] 0.1.12 --- .gitignore | 2 +- .hmrc | 8 +- CHANGELOG.md | 16 + package-lock.json | 4 +- package.json | 6 +- public/CHANGELOG.html | 18 + src-tauri/Cargo.lock | 511 +++++++++++++++++- src-tauri/Cargo.toml | 2 +- src-tauri/tauri.conf.json | 28 +- src/App.vue | 4 +- src/common/helpers.ts | 31 ++ src/components/MatchConfiguration.vue | 89 ++- src/components/ScoreboardComponent.vue | 24 + src/components/ScoreboardTableComponent.vue | 77 +++ .../layouts/AuthenticatedLayout.vue | 21 +- src/game/Board.ts | 1 + src/game/Game.ts | 29 +- src/game/GameSummayView.ts | 39 +- src/game/utilities/fonts.ts | 20 +- src/i18n/en.json | 17 +- src/i18n/es.json | 17 +- src/main.ts | 2 + src/router/index.ts | 15 +- src/services/AuthenticationService.ts | 67 ++- src/services/LocalStorageService.ts | 30 + src/services/NetworkService.ts | 31 +- src/services/PersistenceService.ts | 58 ++ src/services/StorageInterface.ts | 8 + src/services/TauriFileStorageService.ts | 94 ++++ src/stores/auth.ts | 43 +- src/views/GameView.vue | 6 +- src/views/HomeView.vue | 57 +- src/views/LandingView.vue | 38 +- src/views/MatchView.vue | 73 ++- tsconfig.app.json | 2 +- tsconfig.json | 1 + env.d.ts => types/env.d.ts | 0 type.d.ts => types/type.d.ts | 4 + 38 files changed, 1311 insertions(+), 182 deletions(-) create mode 100644 src/components/ScoreboardComponent.vue create mode 100644 src/components/ScoreboardTableComponent.vue create mode 100644 src/services/LocalStorageService.ts create mode 100644 src/services/PersistenceService.ts create mode 100644 src/services/StorageInterface.ts create mode 100644 src/services/TauriFileStorageService.ts rename env.d.ts => types/env.d.ts (100%) rename type.d.ts => types/type.d.ts (59%) diff --git a/.gitignore b/.gitignore index 79ff1c4..114c9f1 100644 --- a/.gitignore +++ b/.gitignore @@ -29,4 +29,4 @@ coverage *.tsbuildinfo .history -.env \ No newline at end of file +.env* \ No newline at end of file diff --git a/.hmrc b/.hmrc index 35ed611..3ca1daa 100644 --- a/.hmrc +++ b/.hmrc @@ -2,7 +2,7 @@ "path": "G:\\Other\\Development\\Projects\\[ideas]\\domino-client", "name": "domino-client", "initialVersion": "0.1.4", - "version": "0.1.8", + "version": "0.1.12", "docker": { "useRegistry": true, "registry": "192.168.1.115:5000", @@ -84,7 +84,7 @@ }, "_backup": { "name": "domino-client", - "version": "0.1.7", + "version": "0.1.11", "private": true, "type": "commonjs", "scripts": { @@ -97,8 +97,8 @@ "lint": "eslint . --ext .vue,.js,.jsx,.cjs,.mjs,.ts,.tsx,.cts,.mts --fix --ignore-path .gitignore", "format": "prettier --write src/", "docker-build": "docker build -t 192.168.1.115:5000/arhuako/domino-client:latest .", - "docker-tag": "docker tag 192.168.1.115:5000/arhuako/domino-client:latest 192.168.1.115:5000/arhuako/domino-client:0.1.7", - "docker-push": "docker push 192.168.1.115:5000/arhuako/domino-client:latest && docker push 192.168.1.115:5000/arhuako/domino-client:0.1.7", + "docker-tag": "docker tag 192.168.1.115:5000/arhuako/domino-client:latest 192.168.1.115:5000/arhuako/domino-client:0.1.11", + "docker-push": "docker push 192.168.1.115:5000/arhuako/domino-client:latest && docker push 192.168.1.115:5000/arhuako/domino-client:0.1.11", "publish": "npm run docker-build && npm run docker-tag && npm run docker-push", "serve": "npm run build-only && http-server ./dist -c-1 -s ", "tauri": "tauri" diff --git a/CHANGELOG.md b/CHANGELOG.md index 31e13c3..6246923 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,22 @@ All notable changes to this project will be documented in this file. ## Unreleased +## 0.1.12 - 2024-07-22 +### Added +- I18n translations +- Win conditions + +### Fixed +- Multiplayer join button not accessible + +## 0.1.10 - 2024-07-20 +### Added +- Updater +- Refresh authentication when expires +- Match summary page phase 1 + +## 0.1.9 - 2024-07-19 + ## 0.1.8 - 2024-07-18 ## 0.1.7 - 2024-07-17 diff --git a/package-lock.json b/package-lock.json index 6bf2184..b2324d0 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "domino-client", - "version": "0.1.7", + "version": "0.1.8", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "domino-client", - "version": "0.1.7", + "version": "0.1.8", "dependencies": { "@pixi/sound": "^6.0.0", "@tauri-apps/api": "^1.6.0", diff --git a/package.json b/package.json index bdb633d..335d568 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "domino-client", - "version": "0.1.8", + "version": "0.1.12", "private": true, "type": "commonjs", "scripts": { @@ -13,8 +13,8 @@ "lint": "eslint . --ext .vue,.js,.jsx,.cjs,.mjs,.ts,.tsx,.cts,.mts --fix --ignore-path .gitignore", "format": "prettier --write src/", "docker-build": "docker build -t 192.168.1.115:5000/arhuako/domino-client:latest .", - "docker-tag": "docker tag 192.168.1.115:5000/arhuako/domino-client:latest 192.168.1.115:5000/arhuako/domino-client:0.1.8", - "docker-push": "docker push 192.168.1.115:5000/arhuako/domino-client:latest && docker push 192.168.1.115:5000/arhuako/domino-client:0.1.8", + "docker-tag": "docker tag 192.168.1.115:5000/arhuako/domino-client:latest 192.168.1.115:5000/arhuako/domino-client:0.1.12", + "docker-push": "docker push 192.168.1.115:5000/arhuako/domino-client:latest && docker push 192.168.1.115:5000/arhuako/domino-client:0.1.12", "publish": "npm run docker-build && npm run docker-tag && npm run docker-push", "serve": "npm run build-only && http-server ./dist -c-1 -s ", "tauri": "tauri" diff --git a/public/CHANGELOG.html b/public/CHANGELOG.html index 1839e37..6dbe356 100644 --- a/public/CHANGELOG.html +++ b/public/CHANGELOG.html @@ -1,5 +1,23 @@

Changelog

All notable changes to this project will be documented in this file.

+

0.1.12 - 2024-07-22

+

Added

+ +

Fixed

+ +

0.1.10 - 2024-07-20

+

Added

+ +

0.1.9 - 2024-07-19

0.1.8 - 2024-07-18

0.1.7 - 2024-07-17

0.1.6 - 2024-07-17

diff --git a/src-tauri/Cargo.lock b/src-tauri/Cargo.lock index 90ba3bc..fe0a208 100644 --- a/src-tauri/Cargo.lock +++ b/src-tauri/Cargo.lock @@ -216,6 +216,9 @@ name = "bytes" version = "1.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a12916984aab3fa6e39d655a33e09c0071eb36d6ab3aea5c2d78551f1df6d952" +dependencies = [ + "serde", +] [[package]] name = "cairo-rs" @@ -630,7 +633,7 @@ dependencies = [ "rustc_version", "toml 0.8.15", "vswhom", - "winreg", + "winreg 0.52.0", ] [[package]] @@ -794,6 +797,12 @@ dependencies = [ "syn 2.0.71", ] +[[package]] +name = "futures-sink" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9fb8e00e87438d937621c1c6269e53f536c14d3fbd6a042bb24879e57d474fb5" + [[package]] name = "futures-task" version = "0.3.30" @@ -807,8 +816,11 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3d6401deb83407ab3da39eba7e33987a73c3df0c82b4bb5813ee871c19c41d48" dependencies = [ "futures-core", + "futures-io", "futures-macro", + "futures-sink", "futures-task", + "memchr", "pin-project-lite", "pin-utils", "slab", @@ -1120,6 +1132,25 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "h2" +version = "0.3.26" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "81fe527a889e1532da5c525686d96d4c2e74cdd345badf8dfef9f6b39dd5f5e8" +dependencies = [ + "bytes", + "fnv", + "futures-core", + "futures-sink", + "futures-util", + "http", + "indexmap 2.2.6", + "slab", + "tokio", + "tokio-util", + "tracing", +] + [[package]] name = "hashbrown" version = "0.12.3" @@ -1190,12 +1221,72 @@ dependencies = [ "itoa 1.0.11", ] +[[package]] +name = "http-body" +version = "0.4.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7ceab25649e9960c0311ea418d17bee82c0dcec1bd053b5f9a66e265a693bed2" +dependencies = [ + "bytes", + "http", + "pin-project-lite", +] + [[package]] name = "http-range" version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "21dec9db110f5f872ed9699c3ecf50cf16f423502706ba5c72462e28d3157573" +[[package]] +name = "httparse" +version = "1.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fcc0b4a115bf80b728eb8ea024ad5bd707b615bfed49e0665b6e0f86fd082d9" + +[[package]] +name = "httpdate" +version = "1.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "df3b46402a9d5adb4c86a0cf463f42e19994e3ee891101b1841f30a545cb49a9" + +[[package]] +name = "hyper" +version = "0.14.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a152ddd61dfaec7273fe8419ab357f33aee0d914c5f4efbf0d96fa749eea5ec9" +dependencies = [ + "bytes", + "futures-channel", + "futures-core", + "futures-util", + "h2", + "http", + "http-body", + "httparse", + "httpdate", + "itoa 1.0.11", + "pin-project-lite", + "socket2", + "tokio", + "tower-service", + "tracing", + "want", +] + +[[package]] +name = "hyper-tls" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d6183ddfa99b85da61a140bea0efc93fdf56ceaa041b37d553518030827f9905" +dependencies = [ + "bytes", + "hyper", + "native-tls", + "tokio", + "tokio-native-tls", +] + [[package]] name = "iana-time-zone" version = "0.1.60" @@ -1313,6 +1404,12 @@ dependencies = [ "cfg-if", ] +[[package]] +name = "ipnet" +version = "2.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f518f335dce6725a761382244631d86cf0ccb2863413590b31338feb467f9c3" + [[package]] name = "itoa" version = "0.4.8" @@ -1519,6 +1616,18 @@ dependencies = [ "autocfg", ] +[[package]] +name = "mime" +version = "0.3.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" + +[[package]] +name = "minisign-verify" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "933dca44d65cdd53b355d0b73d380a2ff5da71f87f036053188bf1eab6a19881" + [[package]] name = "miniz_oxide" version = "0.7.4" @@ -1529,6 +1638,34 @@ dependencies = [ "simd-adler32", ] +[[package]] +name = "mio" +version = "0.8.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a4a650543ca06a924e8b371db273b2756685faae30f8487da1b56505a8f78b0c" +dependencies = [ + "libc", + "wasi 0.11.0+wasi-snapshot-preview1", + "windows-sys 0.48.0", +] + +[[package]] +name = "native-tls" +version = "0.2.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a8614eb2c83d59d1c8cc974dd3f920198647674a0a035e1af1fa58707e317466" +dependencies = [ + "libc", + "log", + "openssl", + "openssl-probe", + "openssl-sys", + "schannel", + "security-framework", + "security-framework-sys", + "tempfile", +] + [[package]] name = "ndk" version = "0.6.0" @@ -1635,6 +1772,17 @@ dependencies = [ "objc_exception", ] +[[package]] +name = "objc-foundation" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1add1b659e36c9607c7aab864a76c7a4c2760cd0cd2e120f3fb8b952c7e22bf9" +dependencies = [ + "block", + "objc", + "objc_id", +] + [[package]] name = "objc_exception" version = "0.1.2" @@ -1668,6 +1816,50 @@ version = "1.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" +[[package]] +name = "openssl" +version = "0.10.64" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "95a0481286a310808298130d22dd1fef0fa571e05a8f44ec801801e84b216b1f" +dependencies = [ + "bitflags 2.6.0", + "cfg-if", + "foreign-types", + "libc", + "once_cell", + "openssl-macros", + "openssl-sys", +] + +[[package]] +name = "openssl-macros" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.71", +] + +[[package]] +name = "openssl-probe" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" + +[[package]] +name = "openssl-sys" +version = "0.9.102" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c597637d56fbc83893a35eb0dd04b2b8e7a50c91e64e9493e398b5df4fb45fa2" +dependencies = [ + "cc", + "libc", + "pkg-config", + "vcpkg", +] + [[package]] name = "overload" version = "0.1.1" @@ -2151,6 +2343,72 @@ version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7a66a03ae7c801facd77a29370b4faec201768915ac14a721ba36f20bc9c209b" +[[package]] +name = "reqwest" +version = "0.11.27" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dd67538700a17451e7cba03ac727fb961abb7607553461627b97de0b89cf4a62" +dependencies = [ + "base64 0.21.7", + "bytes", + "encoding_rs", + "futures-core", + "futures-util", + "h2", + "http", + "http-body", + "hyper", + "hyper-tls", + "ipnet", + "js-sys", + "log", + "mime", + "native-tls", + "once_cell", + "percent-encoding", + "pin-project-lite", + "rustls-pemfile", + "serde", + "serde_json", + "serde_urlencoded", + "sync_wrapper", + "system-configuration", + "tokio", + "tokio-native-tls", + "tokio-util", + "tower-service", + "url", + "wasm-bindgen", + "wasm-bindgen-futures", + "wasm-streams", + "web-sys", + "winreg 0.50.0", +] + +[[package]] +name = "rfd" +version = "0.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0149778bd99b6959285b0933288206090c50e2327f47a9c463bfdbf45c8823ea" +dependencies = [ + "block", + "dispatch", + "glib-sys", + "gobject-sys", + "gtk-sys", + "js-sys", + "lazy_static", + "log", + "objc", + "objc-foundation", + "objc_id", + "raw-window-handle", + "wasm-bindgen", + "wasm-bindgen-futures", + "web-sys", + "windows 0.37.0", +] + [[package]] name = "rustc-demangle" version = "0.1.24" @@ -2179,6 +2437,15 @@ dependencies = [ "windows-sys 0.52.0", ] +[[package]] +name = "rustls-pemfile" +version = "1.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1c74cae0a4cf6ccbbf5f359f08efdf8ee7e1dc532573bf0db71968cb56b1448c" +dependencies = [ + "base64 0.21.7", +] + [[package]] name = "rustversion" version = "1.0.17" @@ -2200,6 +2467,15 @@ dependencies = [ "winapi-util", ] +[[package]] +name = "schannel" +version = "0.1.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fbc91545643bcf3a0bbb6569265615222618bdf33ce4ffbbd13c4bbd4c093534" +dependencies = [ + "windows-sys 0.52.0", +] + [[package]] name = "scoped-tls" version = "1.0.1" @@ -2212,6 +2488,29 @@ version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" +[[package]] +name = "security-framework" +version = "2.11.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "897b2245f0b511c87893af39b033e5ca9cce68824c4d7e7630b5a1d339658d02" +dependencies = [ + "bitflags 2.6.0", + "core-foundation", + "core-foundation-sys", + "libc", + "security-framework-sys", +] + +[[package]] +name = "security-framework-sys" +version = "2.11.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "75da29fe9b9b08fe9d6b22b5b4bcbc75d8db3aa31e639aa56bb62e9d46bfceaf" +dependencies = [ + "core-foundation-sys", + "libc", +] + [[package]] name = "selectors" version = "0.22.0" @@ -2293,6 +2592,18 @@ dependencies = [ "serde", ] +[[package]] +name = "serde_urlencoded" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd" +dependencies = [ + "form_urlencoded", + "itoa 1.0.11", + "ryu", + "serde", +] + [[package]] name = "serde_with" version = "3.9.0" @@ -2402,6 +2713,16 @@ version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" +[[package]] +name = "socket2" +version = "0.5.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce305eb0b4296696835b71df73eb912e0f1ffd2556a501fcede6e0c50349191c" +dependencies = [ + "libc", + "windows-sys 0.52.0", +] + [[package]] name = "soup2" version = "0.2.1" @@ -2499,6 +2820,33 @@ dependencies = [ "unicode-ident", ] +[[package]] +name = "sync_wrapper" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2047c6ded9c721764247e62cd3b03c09ffc529b2ba5b10ec482ae507a4a70160" + +[[package]] +name = "system-configuration" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba3a3adc5c275d719af8cb4272ea1c4a6d668a777f37e115f6d11ddbc1c8e0e7" +dependencies = [ + "bitflags 1.3.2", + "core-foundation", + "system-configuration-sys", +] + +[[package]] +name = "system-configuration-sys" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a75fb188eb626b924683e3b95e3a48e63551fcfb51949de2f06a9d91dbee93c9" +dependencies = [ + "core-foundation-sys", + "libc", +] + [[package]] name = "system-deps" version = "5.0.0" @@ -2607,6 +2955,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "336bc661a3f3250853fa83c6e5245449ed1c26dce5dcb28bdee7efedf6278806" dependencies = [ "anyhow", + "base64 0.21.7", + "bytes", "cocoa", "dirs-next", "dunce", @@ -2621,11 +2971,15 @@ dependencies = [ "heck 0.5.0", "http", "ignore", + "indexmap 1.9.3", + "minisign-verify", "objc", "once_cell", "percent-encoding", "rand 0.8.5", "raw-window-handle", + "reqwest", + "rfd", "semver", "serde", "serde_json", @@ -2639,12 +2993,14 @@ dependencies = [ "tauri-utils", "tempfile", "thiserror", + "time", "tokio", "url", "uuid", "webkit2gtk", "webview2-com", "windows 0.39.0", + "zip", ] [[package]] @@ -2899,8 +3255,35 @@ checksum = "eb2caba9f80616f438e09748d5acda951967e1ea58508ef53d9c6402485a46df" dependencies = [ "backtrace", "bytes", + "libc", + "mio", "num_cpus", "pin-project-lite", + "socket2", + "windows-sys 0.48.0", +] + +[[package]] +name = "tokio-native-tls" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2" +dependencies = [ + "native-tls", + "tokio", +] + +[[package]] +name = "tokio-util" +version = "0.7.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9cf6b47b3771c49ac75ad09a6162f53ad4b8088b76ac60e8ec1455b31a189fe1" +dependencies = [ + "bytes", + "futures-core", + "futures-sink", + "pin-project-lite", + "tokio", ] [[package]] @@ -2971,6 +3354,12 @@ dependencies = [ "winnow 0.6.13", ] +[[package]] +name = "tower-service" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" + [[package]] name = "tracing" version = "0.1.40" @@ -3032,6 +3421,12 @@ dependencies = [ "tracing-log", ] +[[package]] +name = "try-lock" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b" + [[package]] name = "typenum" version = "1.17.0" @@ -3098,6 +3493,12 @@ version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "830b7e5d4d90034032940e4ace0d9a9a057e7a45cd94e6c007832e39edb82f6d" +[[package]] +name = "vcpkg" +version = "0.2.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" + [[package]] name = "version-compare" version = "0.0.11" @@ -3146,6 +3547,15 @@ dependencies = [ "winapi-util", ] +[[package]] +name = "want" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e" +dependencies = [ + "try-lock", +] + [[package]] name = "wasi" version = "0.9.0+wasi-snapshot-preview1" @@ -3183,6 +3593,18 @@ dependencies = [ "wasm-bindgen-shared", ] +[[package]] +name = "wasm-bindgen-futures" +version = "0.4.42" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "76bc14366121efc8dbb487ab05bcc9d346b3b5ec0eaa76e46594cabbe51762c0" +dependencies = [ + "cfg-if", + "js-sys", + "wasm-bindgen", + "web-sys", +] + [[package]] name = "wasm-bindgen-macro" version = "0.2.92" @@ -3212,6 +3634,29 @@ version = "0.2.92" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96" +[[package]] +name = "wasm-streams" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b65dc4c90b63b118468cf747d8bf3566c1913ef60be765b5730ead9e0a3ba129" +dependencies = [ + "futures-util", + "js-sys", + "wasm-bindgen", + "wasm-bindgen-futures", + "web-sys", +] + +[[package]] +name = "web-sys" +version = "0.3.69" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77afa9a11836342370f4817622a2f0f418b134426d91a82dfb48f532d2ec13ef" +dependencies = [ + "js-sys", + "wasm-bindgen", +] + [[package]] name = "webkit2gtk" version = "0.18.2" @@ -3328,6 +3773,19 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" +[[package]] +name = "windows" +version = "0.37.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "57b543186b344cc61c85b5aab0d2e3adf4e0f99bc076eff9aa5927bcc0b8a647" +dependencies = [ + "windows_aarch64_msvc 0.37.0", + "windows_i686_gnu 0.37.0", + "windows_i686_msvc 0.37.0", + "windows_x86_64_gnu 0.37.0", + "windows_x86_64_msvc 0.37.0", +] + [[package]] name = "windows" version = "0.39.0" @@ -3462,6 +3920,12 @@ version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "32a4622180e7a0ec044bb555404c800bc9fd9ec262ec147edd5989ccd0c02cd3" +[[package]] +name = "windows_aarch64_msvc" +version = "0.37.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2623277cb2d1c216ba3b578c0f3cf9cdebeddb6e66b1b218bb33596ea7769c3a" + [[package]] name = "windows_aarch64_msvc" version = "0.39.0" @@ -3480,6 +3944,12 @@ version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "09ec2a7bb152e2252b53fa7803150007879548bc709c039df7627cabbd05d469" +[[package]] +name = "windows_i686_gnu" +version = "0.37.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3925fd0b0b804730d44d4b6278c50f9699703ec49bcd628020f46f4ba07d9e1" + [[package]] name = "windows_i686_gnu" version = "0.39.0" @@ -3504,6 +3974,12 @@ version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0eee52d38c090b3caa76c563b86c3a4bd71ef1a819287c19d586d7334ae8ed66" +[[package]] +name = "windows_i686_msvc" +version = "0.37.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce907ac74fe331b524c1298683efbf598bb031bc84d5e274db2083696d07c57c" + [[package]] name = "windows_i686_msvc" version = "0.39.0" @@ -3522,6 +3998,12 @@ version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "240948bc05c5e7c6dabba28bf89d89ffce3e303022809e73deaefe4f6ec56c66" +[[package]] +name = "windows_x86_64_gnu" +version = "0.37.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2babfba0828f2e6b32457d5341427dcbb577ceef556273229959ac23a10af33d" + [[package]] name = "windows_x86_64_gnu" version = "0.39.0" @@ -3552,6 +4034,12 @@ version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "24d5b23dc417412679681396f2b49f3de8c1473deb516bd34410872eff51ed0d" +[[package]] +name = "windows_x86_64_msvc" +version = "0.37.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f4dd6dc7df2d84cf7b33822ed5b86318fb1781948e9663bacd047fc9dd52259d" + [[package]] name = "windows_x86_64_msvc" version = "0.39.0" @@ -3588,6 +4076,16 @@ dependencies = [ "memchr", ] +[[package]] +name = "winreg" +version = "0.50.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "524e57b2c537c0f9b1e69f1965311ec12182b4122e45035b1508cd24d2adadb1" +dependencies = [ + "cfg-if", + "windows-sys 0.48.0", +] + [[package]] name = "winreg" version = "0.52.0" @@ -3667,3 +4165,14 @@ dependencies = [ "linux-raw-sys", "rustix", ] + +[[package]] +name = "zip" +version = "0.6.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "760394e246e4c28189f19d488c058bf16f564016aefac5d32bb1f3b51d5e9261" +dependencies = [ + "byteorder", + "crc32fast", + "crossbeam-utils", +] diff --git a/src-tauri/Cargo.toml b/src-tauri/Cargo.toml index 36a4acb..e3c735f 100644 --- a/src-tauri/Cargo.toml +++ b/src-tauri/Cargo.toml @@ -17,7 +17,7 @@ tauri-build = { version = "1.5.3", features = [] } [dependencies] serde_json = "1.0" serde = { version = "1.0", features = ["derive"] } -tauri = { version = "1.7.0", features = [] } +tauri = { version = "1.7.0", features = [ "fs-all", "path-all", "updater"] } [features] # this feature is used for production builds or when `devPath` points to the filesystem and the built-in dev server is disabled. diff --git a/src-tauri/tauri.conf.json b/src-tauri/tauri.conf.json index 100a09e..4825243 100644 --- a/src-tauri/tauri.conf.json +++ b/src-tauri/tauri.conf.json @@ -8,11 +8,26 @@ }, "package": { "productName": "domino-client", - "version": "0.1.8" + "version": "0.1.11" }, "tauri": { "allowlist": { - "all": false + "path": { + "all": true + }, + "fs": { + "copyFile": true, + "createDir": true, + "exists": true, + "readDir": true, + "readFile": true, + "removeDir": true, + "removeFile": true, + "renameFile": true, + "scope": ["$APPDATA/*", "$APP/*"], + "writeFile": true, + "all": true + } }, "bundle": { "active": true, @@ -51,14 +66,19 @@ "csp": null }, "updater": { - "active": false + "active": true, + "dialog": true, + "endpoints": [ + "https://domserv.xintanalabs.net/api/updater/{{target}}/{{arch}}/{{current_version}}" + ], + "pubkey": "dW50cnVzdGVkIGNvbW1lbnQ6IG1pbmlzaWduIHB1YmxpYyBrZXk6IDQwRTBDNUU1QzIyNEYzQUQKUldTdDh5VEM1Y1hnUVA2M01pcEZMbVltVUpuMlhpN09Rc3BnN1A3NC9BOGs5OE92MndRZzVXSm4K" }, "windows": [ { "fullscreen": false, "height": 720, "resizable": true, - "title": "Domino", + "title": "Domino v0.1.11", "width": 1280, "minHeight": 720, "minWidth": 1280, diff --git a/src/App.vue b/src/App.vue index 2222138..fc6cd26 100644 --- a/src/App.vue +++ b/src/App.vue @@ -57,8 +57,6 @@ onUnmounted(() => { }) - + diff --git a/src/common/helpers.ts b/src/common/helpers.ts index e61be82..a3b91d9 100644 --- a/src/common/helpers.ts +++ b/src/common/helpers.ts @@ -111,3 +111,34 @@ export function copyToclipboard(value: string) { const { toClipboard } = useClipboard() toClipboard(value) } + +export function transposeMatrix(matrix: any[][]): any[][] { + // Get the number of rows and columns + const numRows = matrix.length + const numCols = matrix[0].length + + // Create a new matrix with transposed dimensions + const transposed = Array.from({ length: numCols }, () => Array(numRows).fill(null)) + + // Transpose the matrix + for (let row = 0; row < numRows; row++) { + for (let col = 0; col < numCols; col++) { + transposed[col][row] = matrix[row][col] + } + } + + return transposed +} + +export function createStringMatrix( + rows: number, + cols: number, + initialValue: string = '', +): string[][] { + // Create an array of arrays (matrix) + const matrix: string[][] = Array.from({ length: rows }, () => + Array.from({ length: cols }, () => initialValue), + ) + + return matrix +} diff --git a/src/components/MatchConfiguration.vue b/src/components/MatchConfiguration.vue index 9a807cb..caf1ad5 100644 --- a/src/components/MatchConfiguration.vue +++ b/src/components/MatchConfiguration.vue @@ -1,8 +1,8 @@ diff --git a/src/components/ScoreboardComponent.vue b/src/components/ScoreboardComponent.vue new file mode 100644 index 0000000..2514d7a --- /dev/null +++ b/src/components/ScoreboardComponent.vue @@ -0,0 +1,24 @@ + + + + + diff --git a/src/components/ScoreboardTableComponent.vue b/src/components/ScoreboardTableComponent.vue new file mode 100644 index 0000000..d1a82c3 --- /dev/null +++ b/src/components/ScoreboardTableComponent.vue @@ -0,0 +1,77 @@ + + + + diff --git a/src/components/layouts/AuthenticatedLayout.vue b/src/components/layouts/AuthenticatedLayout.vue index 04af63e..f2dfefc 100644 --- a/src/components/layouts/AuthenticatedLayout.vue +++ b/src/components/layouts/AuthenticatedLayout.vue @@ -1,24 +1,33 @@