diff --git a/.github/workflows/app-release.yml b/.github/workflows/app-release.yml index dfff2656..15c3e0e8 100644 --- a/.github/workflows/app-release.yml +++ b/.github/workflows/app-release.yml @@ -42,6 +42,9 @@ jobs: with: components: rustfmt, clippy + - name: Install Tauri CLI + run: cargo install tauri-cli --git https://github.com/modrinth/tauri.git --rev 5e2942876c2266594ed1db516c1d9975c873c36a + - name: Setup rust cache uses: actions/cache@v4 with: @@ -60,9 +63,13 @@ jobs: !target/release/bundle/*/*.deb !target/release/bundle/*/*.rpm - !target/release/bundle/*/*.msi - !target/release/bundle/*/*.msi.zip - !target/release/bundle/*/*.msi.zip.sig + !target/release/bundle/msi/*.msi + !target/release/bundle/msi/*.msi.zip + !target/release/bundle/msi/*.msi.zip.sig + + !target/release/bundle/nsis/*.exe + !target/release/bundle/nsis/*.nsis.zip + !target/release/bundle/nsis/*.nsis.zip.sig key: ${{ runner.os }}-rust-target-${{ hashFiles('**/Cargo.lock') }} restore-keys: | ${{ runner.os }}-rust-target- @@ -108,6 +115,7 @@ jobs: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} TAURI_SIGNING_PRIVATE_KEY: ${{ secrets.TAURI_PRIVATE_KEY }} TAURI_SIGNING_PRIVATE_KEY_PASSWORD: ${{ secrets.TAURI_KEY_PASSWORD }} + V1_COMPATIBLE_BIN_NAME: true - name: build app run: pnpm --filter=@modrinth/app run tauri build --config "tauri-release.conf.json" @@ -117,6 +125,7 @@ jobs: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} TAURI_SIGNING_PRIVATE_KEY: ${{ secrets.TAURI_PRIVATE_KEY }} TAURI_SIGNING_PRIVATE_KEY_PASSWORD: ${{ secrets.TAURI_KEY_PASSWORD }} + V1_COMPATIBLE_BIN_NAME: true - name: upload ${{ matrix.platform }} uses: actions/upload-artifact@v4 @@ -136,7 +145,10 @@ jobs: target/release/bundle/*/*.deb target/release/bundle/*/*.rpm - target/release/bundle/*/*.msi - target/release/bundle/*/*.msi.zip - target/release/bundle/*/*.msi.zip.sig - + target/release/bundle/msi/*.msi + target/release/bundle/msi/*.msi.zip + target/release/bundle/msi/*.msi.zip.sig + + target/release/bundle/nsis/*.exe + target/release/bundle/nsis/*.nsis.zip + target/release/bundle/nsis/*.nsis.zip.sig diff --git a/Cargo.lock b/Cargo.lock index dc5259d0..c2a18bc6 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -4,9 +4,9 @@ version = 3 [[package]] name = "addr2line" -version = "0.22.0" +version = "0.24.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e4503c46a5c0c7844e948c9a4d6acd9f50cccb4de1c48eb9e291ea17470c678" +checksum = "f5fb1d8e4442bd405fdfd1dacb42792696b0cf9cb15882e5d097b742a676d375" dependencies = [ "gimli", ] @@ -93,9 +93,9 @@ dependencies = [ [[package]] name = "anyhow" -version = "1.0.86" +version = "1.0.88" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b3d1d046238990b9cf5bcde22a3fb3584ee5cf65fb2765f454ed428c7a0063da" +checksum = "4e1496f8fb1fbf272686b8d37f523dab3e4a7443300055e74cdaa449f3114356" [[package]] name = "arbitrary" @@ -174,9 +174,9 @@ dependencies = [ [[package]] name = "async-executor" -version = "1.13.0" +version = "1.13.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d7ebdfa2ebdab6b1760375fa7d6f382b9f486eac35fc994625a00e89280bdbb7" +checksum = "30ca9a001c1e8ba5149f91a74362376cc6bc5b919d92d988668657bd570bdcec" dependencies = [ "async-task", "concurrent-queue", @@ -283,9 +283,9 @@ checksum = "8b75356056920673b02621b35afd0f7dda9306d03c79a30f5c56c44cf256e3de" [[package]] name = "async-trait" -version = "0.1.81" +version = "0.1.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e0c28dcc82d7c8ead5cb13beb15405b57b8546e93215673ff8ca0349a028107" +checksum = "a27b8a3a6e1a44fa4c8baf1f653e4172e81486d4941f2237e20dc2d0cf4ddff1" dependencies = [ "proc-macro2", "quote", @@ -371,17 +371,17 @@ checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "backtrace" -version = "0.3.73" +version = "0.3.74" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cc23269a4f8976d0a4d2e7109211a419fe30e8d88d677cd60b6bc79c5732e0a" +checksum = "8d82cb332cdfaed17ae235a638438ac4d4839913cc2af585c3c6746e8f8bee1a" dependencies = [ "addr2line", - "cc", "cfg-if", "libc", - "miniz_oxide 0.7.4", + "miniz_oxide 0.8.0", "object", "rustc-demangle", + "windows-targets 0.52.6", ] [[package]] @@ -500,9 +500,9 @@ checksum = "79296716171880943b8470b5f8d03aa55eb2e645a4874bdbb28adb49162e012c" [[package]] name = "bytemuck" -version = "1.17.1" +version = "1.18.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "773d90827bc3feecfb67fab12e24de0749aad83c74b9504ecde46237b5cd24e2" +checksum = "94bbb0ad554ad961ddc5da507a12a29b14e4ae5bda06b19f575a3e6079d2e2ae" [[package]] name = "byteorder" @@ -609,9 +609,9 @@ dependencies = [ [[package]] name = "cc" -version = "1.1.15" +version = "1.1.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57b6a275aa2903740dc87da01c62040406b8812552e97129a63ea8850a17c6e6" +checksum = "b62ac837cdb5cb22e10a256099b4fc502b1dfe560cb282963a974d7abd80e476" dependencies = [ "jobserver", "libc", @@ -888,9 +888,9 @@ dependencies = [ [[package]] name = "cpufeatures" -version = "0.2.13" +version = "0.2.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "51e852e6dc9a5bed1fae92dd2375037bf2b768725bf3be87811edee3249d09ad" +checksum = "608697df725056feaccfa42cffdaeeec3fccc4ffc38358ecd19b243e716a78e0" dependencies = [ "libc", ] @@ -1077,9 +1077,9 @@ dependencies = [ [[package]] name = "dashmap" -version = "6.0.1" +version = "6.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "804c8821570c3f8b70230c2ba75ffa5c0f9a4189b9a432b6656c536712acae28" +checksum = "5041cc499144891f3790297212f32a74fb938e5136a14943f338ef9e0ae276cf" dependencies = [ "cfg-if", "crossbeam-utils", @@ -1910,9 +1910,9 @@ dependencies = [ [[package]] name = "gimli" -version = "0.29.0" +version = "0.31.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "40ecd4077b5ae9fd2e9e169b102c6c330d0605168eb0e8bf79952b256dbefffd" +checksum = "32085ea23f3234fc7846555e85283ba4de91e21016dc0455a16286d87a292d64" [[package]] name = "gio" @@ -2256,9 +2256,9 @@ dependencies = [ [[package]] name = "hyper-rustls" -version = "0.27.2" +version = "0.27.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ee4be2c948921a1a5320b629c4193916ed787a7f7f293fd3f7f5a6c9de74155" +checksum = "08afdbb5c31130e3034af566421053ab03787c640246a446327f550d11bcb333" dependencies = [ "futures-util", "http", @@ -2290,9 +2290,9 @@ dependencies = [ [[package]] name = "hyper-util" -version = "0.1.7" +version = "0.1.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cde7055719c54e36e95e8719f95883f22072a48ede39db7fc17a4e1d5281e9b9" +checksum = "da62f120a8a37763efb0cf8fdf264b884c7b8b9ac8660b900c8661030c00e6ba" dependencies = [ "bytes", "futures-channel", @@ -2394,9 +2394,9 @@ dependencies = [ [[package]] name = "infer" -version = "0.15.0" +version = "0.16.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cb33622da908807a06f9513c19b3c1ad50fab3e4137d82a78107d502075aa199" +checksum = "bc150e5ce2330295b8616ce0e3f53250e53af31759a9dbedad1621ba29151847" dependencies = [ "cfb", ] @@ -2441,9 +2441,9 @@ dependencies = [ [[package]] name = "ipnet" -version = "2.9.0" +version = "2.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f518f335dce6725a761382244631d86cf0ccb2863413590b31338feb467f9c3" +checksum = "187674a687eed5fe42285b40c6291f9a01517d415fad1c3cbc6a9f778af7fcd4" [[package]] name = "is-docker" @@ -2688,7 +2688,7 @@ checksum = "c0ff37bd590ca25063e35af745c343cb7a0271906fb7b37e4813e8f79f00268d" dependencies = [ "bitflags 2.6.0", "libc", - "redox_syscall 0.5.3", + "redox_syscall", ] [[package]] @@ -3221,7 +3221,6 @@ checksum = "0ee638a5da3799329310ad4cfa62fbf045d5f56e3ef5ba4149e7452dcf89d5a8" dependencies = [ "bitflags 2.6.0", "block2", - "dispatch", "libc", "objc2", ] @@ -3342,9 +3341,9 @@ checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" [[package]] name = "openssl-src" -version = "300.3.1+3.3.1" +version = "300.3.2+3.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7259953d42a81bf137fbbd73bd30a8e1914d6dce43c2b90ed575783a22608b91" +checksum = "a211a18d945ef7e648cc6e0058f4c548ee46aab922ea203e0d30e966ea23647b" dependencies = [ "cc", ] @@ -3454,9 +3453,9 @@ dependencies = [ [[package]] name = "parking" -version = "2.2.0" +version = "2.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb813b8af86854136c6922af0598d719255ecb2179515e6e7730d468f05c9cae" +checksum = "f38d5652c16fde515bb1ecef450ab0f6a219d619a7274976324d5e377f7dceba" [[package]] name = "parking_lot" @@ -3476,7 +3475,7 @@ checksum = "1e401f977ab385c9e4e3ab30627d6f26d00e2c73eef317493c4ec6d468726cf8" dependencies = [ "cfg-if", "libc", - "redox_syscall 0.5.3", + "redox_syscall", "smallvec", "windows-targets 0.52.6", ] @@ -3890,9 +3889,9 @@ dependencies = [ [[package]] name = "quinn" -version = "0.11.3" +version = "0.11.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b22d8e7369034b9a7132bc2008cac12f2013c8132b45e0554e6e20e2617f2156" +checksum = "8c7c5fdde3cdae7203427dc4f0a68fe0ed09833edc525a03456b153b79828684" dependencies = [ "bytes", "pin-project-lite", @@ -3908,9 +3907,9 @@ dependencies = [ [[package]] name = "quinn-proto" -version = "0.11.6" +version = "0.11.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba92fb39ec7ad06ca2582c0ca834dfeadcaf06ddfc8e635c80aa7e1c05315fdd" +checksum = "fadfaed2cd7f389d0161bb73eeb07b7b78f8691047a6f3e73caaeae55310a4a6" dependencies = [ "bytes", "rand 0.8.5", @@ -3925,15 +3924,15 @@ dependencies = [ [[package]] name = "quinn-udp" -version = "0.5.4" +version = "0.5.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8bffec3605b73c6f1754535084a85229fa8a30f86014e6c81aeec4abb68b0285" +checksum = "4fe68c2e9e1a1234e218683dbdf9f9dfcb094113c5ac2b938dfcb9bab4c4140b" dependencies = [ "libc", "once_cell", "socket2", "tracing", - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] @@ -4058,15 +4057,6 @@ dependencies = [ "crossbeam-utils", ] -[[package]] -name = "redox_syscall" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4722d768eff46b75989dd134e5c353f0d6296e5aaa3132e776cbdb56be7731aa" -dependencies = [ - "bitflags 1.3.2", -] - [[package]] name = "redox_syscall" version = "0.5.3" @@ -4291,9 +4281,9 @@ dependencies = [ [[package]] name = "rustix" -version = "0.38.35" +version = "0.38.37" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a85d50532239da68e9addb745ba38ff4612a242c1c7ceea689c4bc7c2f43c36f" +checksum = "8acb788b847c24f28525660c4d7758620a7210875711f79e7f663cc152726811" dependencies = [ "bitflags 2.6.0", "errno", @@ -4304,9 +4294,9 @@ dependencies = [ [[package]] name = "rustls" -version = "0.23.12" +version = "0.23.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c58f8c84392efc0a126acce10fa59ff7b3d2ac06ab451a33f2741989b806b044" +checksum = "f2dabaac7466917e566adb06783a81ca48944c6898a1b08b9374106dd671f4c8" dependencies = [ "once_cell", "ring", @@ -4334,9 +4324,9 @@ checksum = "fc0a2ce646f8655401bb81e7927b812614bd5d91dbc968696be50603510fcaf0" [[package]] name = "rustls-webpki" -version = "0.102.7" +version = "0.102.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "84678086bd54edf2b415183ed7a94d0efb049f1b646a33e22a36f3794be6ae56" +checksum = "64ca1bc8749bd4cf37b5ce386cc146580777b4e8572c7b97baf22c83f444bee9" dependencies = [ "ring", "rustls-pki-types", @@ -4366,11 +4356,11 @@ dependencies = [ [[package]] name = "schannel" -version = "0.1.23" +version = "0.1.24" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fbc91545643bcf3a0bbb6569265615222618bdf33ce4ffbbd13c4bbd4c093534" +checksum = "e9aaafd5a2b6e3d657ff009d82fbd630b6bd54dd4eb06f21693925cdf80f9b8b" dependencies = [ - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] @@ -4479,9 +4469,9 @@ dependencies = [ [[package]] name = "serde" -version = "1.0.209" +version = "1.0.210" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99fce0ffe7310761ca6bf9faf5115afbc19688edd00171d81b1bb1b116c63e09" +checksum = "c8e3592472072e6e22e0a54d5904d9febf8508f65fb8552499a1abc7d1078c3a" dependencies = [ "serde_derive", ] @@ -4499,9 +4489,9 @@ dependencies = [ [[package]] name = "serde_derive" -version = "1.0.209" +version = "1.0.210" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a5831b979fd7b5439637af1752d535ff49f4860c0f341d1baeb6faf0f4242170" +checksum = "243902eda00fad750862fc144cea25caca5e20d615af0a81bee94ca738f1df1f" dependencies = [ "proc-macro2", "quote", @@ -4532,9 +4522,9 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.127" +version = "1.0.128" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8043c06d9f82bd7271361ed64f415fe5e12a77fdb52e573e7f06a516dea329ad" +checksum = "6ff5456707a1de34e7e37f2a6fd3d3f808c318259cbd01ab6377795054b483d8" dependencies = [ "itoa 1.0.11", "memchr", @@ -4750,25 +4740,24 @@ dependencies = [ [[package]] name = "softbuffer" -version = "0.4.5" +version = "0.4.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d623bff5d06f60d738990980d782c8c866997d9194cfe79ecad00aa2f76826dd" +checksum = "18051cdd562e792cad055119e0cdb2cfc137e44e3987532e0f9659a77931bb08" dependencies = [ "bytemuck", "cfg_aliases", - "core-graphics 0.23.2", + "core-graphics 0.24.0", "foreign-types 0.5.0", "js-sys", "log", "objc2", - "objc2-app-kit", "objc2-foundation", "objc2-quartz-core", "raw-window-handle 0.6.2", - "redox_syscall 0.5.3", + "redox_syscall", "wasm-bindgen", "web-sys", - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] @@ -4818,9 +4807,9 @@ dependencies = [ [[package]] name = "sqlformat" -version = "0.2.4" +version = "0.2.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f895e3734318cc55f1fe66258926c9b910c124d47520339efecbb6c59cec7c1f" +checksum = "7bba3a93db0cc4f7bdece8bb09e77e2e785c20bfebf79eb8340ed80708048790" dependencies = [ "nom", "unicode_categories", @@ -4828,9 +4817,9 @@ dependencies = [ [[package]] name = "sqlx" -version = "0.8.1" +version = "0.8.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fcfa89bea9500db4a0d038513d7a060566bfc51d46d1c014847049a45cce85e8" +checksum = "93334716a037193fac19df402f8571269c84a00852f6a7066b5d2616dcd64d3e" dependencies = [ "sqlx-core", "sqlx-macros", @@ -4841,9 +4830,9 @@ dependencies = [ [[package]] name = "sqlx-core" -version = "0.8.1" +version = "0.8.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d06e2f2bd861719b1f3f0c7dbe1d80c30bf59e76cf019f07d9014ed7eefb8e08" +checksum = "d4d8060b456358185f7d50c55d9b5066ad956956fddec42ee2e8567134a8936e" dependencies = [ "atoi", "byteorder", @@ -4880,9 +4869,9 @@ dependencies = [ [[package]] name = "sqlx-macros" -version = "0.8.1" +version = "0.8.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f998a9defdbd48ed005a89362bd40dd2117502f15294f61c8d47034107dbbdc" +checksum = "cac0692bcc9de3b073e8d747391827297e075c7710ff6276d9f7a1f3d58c6657" dependencies = [ "proc-macro2", "quote", @@ -4893,9 +4882,9 @@ dependencies = [ [[package]] name = "sqlx-macros-core" -version = "0.8.1" +version = "0.8.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d100558134176a2629d46cec0c8891ba0be8910f7896abfdb75ef4ab6f4e7ce" +checksum = "1804e8a7c7865599c9c79be146dc8a9fd8cc86935fa641d3ea58e5f0688abaa5" dependencies = [ "dotenvy", "either", @@ -4919,9 +4908,9 @@ dependencies = [ [[package]] name = "sqlx-mysql" -version = "0.8.1" +version = "0.8.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "936cac0ab331b14cb3921c62156d913e4c15b74fb6ec0f3146bd4ef6e4fb3c12" +checksum = "64bb4714269afa44aef2755150a0fc19d756fb580a67db8885608cf02f47d06a" dependencies = [ "atoi", "base64 0.22.1", @@ -4961,9 +4950,9 @@ dependencies = [ [[package]] name = "sqlx-postgres" -version = "0.8.1" +version = "0.8.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9734dbce698c67ecf67c442f768a5e90a49b2a4d61a9f1d59f73874bd4cf0710" +checksum = "6fa91a732d854c5d7726349bb4bb879bb9478993ceb764247660aee25f67c2f8" dependencies = [ "atoi", "base64 0.22.1", @@ -4999,9 +4988,9 @@ dependencies = [ [[package]] name = "sqlx-sqlite" -version = "0.8.1" +version = "0.8.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a75b419c3c1b1697833dd927bdc4c6545a620bc1bbafabd44e1efbe9afcd337e" +checksum = "d5b2cf34a45953bfd3daaf3db0f7a7878ab9b7a6b91b422d24a7a9e4c857b680" dependencies = [ "atoi", "flume", @@ -5202,9 +5191,9 @@ dependencies = [ [[package]] name = "tao" -version = "0.29.1" +version = "0.30.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3a97abbc7d6cfd0720da3e06fcb1cf2ac87cbfdb5bbbce103a1279a211c4d81" +checksum = "2a93f2c6b8fdaeb7f417bda89b5bc767999745c3052969664ae1fa65892deb7e" dependencies = [ "bitflags 2.6.0", "cocoa 0.26.0", @@ -5269,9 +5258,8 @@ checksum = "61c41af27dd6d1e27b1b16b489db798443478cef1f06a660c96db617ba5de3b1" [[package]] name = "tauri" -version = "2.0.0-rc.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8345ccc676ef16e26b61fc0f5340b4e770678b1e1f53f08c69ebdac5e56b422" +version = "2.0.0-rc.10" +source = "git+https://github.com/modrinth/tauri?rev=5e29428#5e2942876c2266594ed1db516c1d9975c873c36a" dependencies = [ "anyhow", "bytes", @@ -5305,7 +5293,7 @@ dependencies = [ "tauri-macros", "tauri-runtime", "tauri-runtime-wry", - "tauri-utils", + "tauri-utils 2.0.0-rc.9", "thiserror", "tokio", "tray-icon", @@ -5319,9 +5307,8 @@ dependencies = [ [[package]] name = "tauri-build" -version = "2.0.0-rc.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d5ad5fcfaf02cf79aa6727f6c5df38567d8dce172b00b62690c6bc46c08b7ce" +version = "2.0.0-rc.9" +source = "git+https://github.com/modrinth/tauri?rev=5e29428#5e2942876c2266594ed1db516c1d9975c873c36a" dependencies = [ "anyhow", "cargo_toml", @@ -5335,7 +5322,7 @@ dependencies = [ "serde", "serde_json", "tauri-codegen", - "tauri-utils", + "tauri-utils 2.0.0-rc.9", "tauri-winres", "toml 0.8.19", "walkdir", @@ -5343,9 +5330,8 @@ dependencies = [ [[package]] name = "tauri-codegen" -version = "2.0.0-rc.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "809ef6316726fc72593d296cf6f4e7461326e310c313d6a6c42b6e7f1e2671cf" +version = "2.0.0-rc.9" +source = "git+https://github.com/modrinth/tauri?rev=5e29428#5e2942876c2266594ed1db516c1d9975c873c36a" dependencies = [ "base64 0.22.1", "brotli", @@ -5360,7 +5346,7 @@ dependencies = [ "serde_json", "sha2", "syn 2.0.77", - "tauri-utils", + "tauri-utils 2.0.0-rc.9", "thiserror", "time", "url", @@ -5370,23 +5356,22 @@ dependencies = [ [[package]] name = "tauri-macros" -version = "2.0.0-rc.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1359e8861d210d25731f8b1bfbb4d111dd06406cf73c59659366ef450364d811" +version = "2.0.0-rc.8" +source = "git+https://github.com/modrinth/tauri?rev=5e29428#5e2942876c2266594ed1db516c1d9975c873c36a" dependencies = [ "heck 0.5.0", "proc-macro2", "quote", "syn 2.0.77", "tauri-codegen", - "tauri-utils", + "tauri-utils 2.0.0-rc.9", ] [[package]] name = "tauri-plugin" -version = "2.0.0-rc.7" +version = "2.0.0-rc.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7dded420c86183f592d0fe925ef9447f41e26fa79f0bdfef8d3f17bfbcdbfb7" +checksum = "ad2b0b4fe684059a1b700c1a0d7d51698c05b2257ca64eca2a730d7be2e47c6a" dependencies = [ "anyhow", "glob", @@ -5394,16 +5379,16 @@ dependencies = [ "schemars", "serde", "serde_json", - "tauri-utils", + "tauri-utils 2.0.0-rc.10", "toml 0.8.19", "walkdir", ] [[package]] name = "tauri-plugin-deep-link" -version = "2.0.0-rc.2" +version = "2.0.0-rc.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a6b5660955c91ab25365613295788ce840c4e07b810e65436720b1a194cc72c2" +checksum = "2e8f87f55b7ea1ad415c8e3f5542637126bb7faf890be871569d522bc4c6dbc8" dependencies = [ "dunce", "log", @@ -5412,7 +5397,7 @@ dependencies = [ "serde_json", "tauri", "tauri-plugin", - "tauri-utils", + "tauri-utils 2.0.0-rc.10", "thiserror", "url", "windows-registry", @@ -5421,11 +5406,10 @@ dependencies = [ [[package]] name = "tauri-plugin-dialog" -version = "2.0.0-rc.3" +version = "2.0.0-rc.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa8bd381f75c47687f41fb603f67fdd99a1af377da22d03d8fb959d2481845c1" +checksum = "0e0c5b6a7ea7db72623e9a6f7e5a8044dae4bb9cb3d154557cb082d10288bc9b" dependencies = [ - "dunce", "log", "raw-window-handle 0.6.2", "rfd", @@ -5440,11 +5424,12 @@ dependencies = [ [[package]] name = "tauri-plugin-fs" -version = "2.0.0-rc.1" +version = "2.0.0-rc.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "694a746b0e0c1d318198fabf4957800c42fb4b705e866e0eed7ec21476ef88db" +checksum = "8a4fa21faf29a0b18f1ab509c2f75f9b793ec2ebdbc9a81b75f9c8f1399f20ae" dependencies = [ "anyhow", + "dunce", "glob", "schemars", "serde", @@ -5498,14 +5483,15 @@ dependencies = [ [[package]] name = "tauri-plugin-single-instance" -version = "2.0.0-rc.1" +version = "2.0.0-rc.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d73c92c98d44d4daba0118d905f45243dfcd6eaac82216c3382a02d17cb74cf2" +checksum = "2b1f3924d67b5370bce5871d4ba5701d0e2d66f45b0c528a410514a306e7c811" dependencies = [ "log", "serde", "serde_json", "tauri", + "tauri-plugin-deep-link", "thiserror", "windows-sys 0.59.0", "zbus", @@ -5513,9 +5499,9 @@ dependencies = [ [[package]] name = "tauri-plugin-updater" -version = "2.0.0-rc.2" +version = "2.0.0-rc.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f7048854b4271f3bc58ee850f0582f8d9bb0190118afa8397f36fc260daaa68b" +checksum = "391ebb8ae8cd6aec44b5d96d3005659d88cde69c57326f639bbc660116a30d63" dependencies = [ "base64 0.22.1", "dirs", @@ -5542,9 +5528,9 @@ dependencies = [ [[package]] name = "tauri-plugin-window-state" -version = "2.0.0-rc.2" +version = "2.0.0-rc.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba56bcec4b7a1601cf3136c9a3a98f77036b7e1a67564788c5ccd051035d028a" +checksum = "303569dd7858361d4c623845448b136b4c95d53b5d2bde6630bea9d7f0022d45" dependencies = [ "bitflags 2.6.0", "log", @@ -5557,9 +5543,8 @@ dependencies = [ [[package]] name = "tauri-runtime" -version = "2.0.0-rc.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75c72b844f387bfc3341c355f3e16b8cbf4161848fa4e348670effb222cd3ba5" +version = "2.0.0-rc.9" +source = "git+https://github.com/modrinth/tauri?rev=5e29428#5e2942876c2266594ed1db516c1d9975c873c36a" dependencies = [ "dpi", "gtk", @@ -5568,7 +5553,7 @@ dependencies = [ "raw-window-handle 0.6.2", "serde", "serde_json", - "tauri-utils", + "tauri-utils 2.0.0-rc.9", "thiserror", "url", "windows 0.58.0", @@ -5576,9 +5561,8 @@ dependencies = [ [[package]] name = "tauri-runtime-wry" -version = "2.0.0-rc.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "73accf936a7cd01d1382de7850726fdf6c1f6ab3b01ccb7a0950cb852e332596" +version = "2.0.0-rc.9" +source = "git+https://github.com/modrinth/tauri?rev=5e29428#5e2942876c2266594ed1db516c1d9975c873c36a" dependencies = [ "cocoa 0.26.0", "gtk", @@ -5590,7 +5574,7 @@ dependencies = [ "softbuffer", "tao", "tauri-runtime", - "tauri-utils", + "tauri-utils 2.0.0-rc.9", "url", "webkit2gtk", "webview2-com", @@ -5600,9 +5584,8 @@ dependencies = [ [[package]] name = "tauri-utils" -version = "2.0.0-rc.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d53d9fe87e985b273696ae22ce2b9f099a8f1b44bc8fb127467bda5fcb3e4371" +version = "2.0.0-rc.9" +source = "git+https://github.com/modrinth/tauri?rev=5e29428#5e2942876c2266594ed1db516c1d9975c873c36a" dependencies = [ "brotli", "cargo_metadata", @@ -5633,6 +5616,39 @@ dependencies = [ "walkdir", ] +[[package]] +name = "tauri-utils" +version = "2.0.0-rc.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba92ad9cdf7658fefa29a7218dda0acead9400c021bbf9c3f88e98f5e3b9bbab" +dependencies = [ + "cargo_metadata", + "ctor", + "dunce", + "glob", + "html5ever", + "infer", + "json-patch", + "kuchikiki", + "log", + "memchr", + "phf 0.11.2", + "proc-macro2", + "quote", + "regex", + "schemars", + "semver", + "serde", + "serde-untagged", + "serde_json", + "serde_with", + "swift-rs", + "thiserror", + "toml 0.8.19", + "url", + "urlpattern", +] + [[package]] name = "tauri-winres" version = "0.1.1" @@ -5669,7 +5685,7 @@ dependencies = [ [[package]] name = "theseus" -version = "0.8.5" +version = "0.8.7" dependencies = [ "async-recursion", "async-tungstenite", @@ -5720,7 +5736,7 @@ dependencies = [ [[package]] name = "theseus_gui" -version = "0.8.5" +version = "0.8.7" dependencies = [ "chrono", "cocoa 0.25.0", @@ -5765,7 +5781,6 @@ dependencies = [ "futures", "serde", "serde_json", - "tauri", "theseus", "thiserror", "tokio", @@ -5921,9 +5936,9 @@ dependencies = [ [[package]] name = "tokio-stream" -version = "0.1.15" +version = "0.1.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "267ac89e0bec6e691e5813911606935d77c476ff49024f98abcea3e7b15e37af" +checksum = "4f4e6ce100d0eb49a2734f8c0812bcd324cf357d21810932c5df6b96ef2b86f1" dependencies = [ "futures-core", "pin-project-lite", @@ -5932,9 +5947,9 @@ dependencies = [ [[package]] name = "tokio-util" -version = "0.7.11" +version = "0.7.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9cf6b47b3771c49ac75ad09a6162f53ad4b8088b76ac60e8ec1455b31a189fe1" +checksum = "61e7c3654c13bcd040d4a03abee2c75b1d14a37b423cf5a813ceae1cc903ec6a" dependencies = [ "bytes", "futures-core", @@ -6116,9 +6131,9 @@ dependencies = [ [[package]] name = "tray-icon" -version = "0.16.0" +version = "0.17.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "131a65b2cef2081bc14dbcd414c906edbfa3bb5323dd7e748cc298614681196b" +checksum = "044d7738b3d50f288ddef035b793228740ad4d927f5466b0af55dc15e7e03cfe" dependencies = [ "core-graphics 0.24.0", "crossbeam-channel", @@ -6239,9 +6254,9 @@ checksum = "08f95100a766bf4f8f28f90d77e0a5461bbdb219042e7679bebe79004fed8d75" [[package]] name = "unicode-ident" -version = "1.0.12" +version = "1.0.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +checksum = "e91b56cd4cadaeb79bbf1a5645f6b4f8dc5bde8834ad5894a8db35fda9efa1fe" [[package]] name = "unicode-normalization" @@ -6302,11 +6317,10 @@ checksum = "daf8dba3b7eb870caf1ddeed7bc9d2a049f3cfdfae7cb521b087cc33ae4c49da" [[package]] name = "urlpattern" -version = "0.2.0" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f9bd5ff03aea02fa45b13a7980151fe45009af1980ba69f651ec367121a31609" +checksum = "70acd30e3aa1450bc2eece896ce2ad0d178e9c079493819301573dae3c37ba6d" dependencies = [ - "derive_more", "regex", "serde", "unic-ucd-ident", @@ -6655,11 +6669,11 @@ dependencies = [ [[package]] name = "whoami" -version = "1.5.1" +version = "1.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a44ab49fad634e88f55bf8f9bb3abd2f27d7204172a112c7c9987e01c1c94ea9" +checksum = "372d5b87f58ec45c384ba03563b03544dc5fadc3983e434b286913f5b4a9bb6d" dependencies = [ - "redox_syscall 0.4.1", + "redox_syscall", "wasite", "web-sys", ] @@ -6709,12 +6723,13 @@ dependencies = [ [[package]] name = "window-vibrancy" -version = "0.5.1" +version = "0.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8cdd6999298d969289d8078dae02ce798ad23452075985cccba8b6326711ecf" +checksum = "3ea403deff7b51fff19e261330f71608ff2cdef5721d72b64180bb95be7c4150" dependencies = [ - "cocoa 0.26.0", - "objc", + "objc2", + "objc2-app-kit", + "objc2-foundation", "raw-window-handle 0.6.2", "windows-sys 0.59.0", "windows-version", @@ -7076,8 +7091,8 @@ dependencies = [ [[package]] name = "wry" -version = "0.42.0" -source = "git+https://github.com/modrinth/wry?rev=23b0ee4#23b0ee4ea1c1956db7edefac8e4fd710f548c85d" +version = "0.43.1" +source = "git+https://github.com/modrinth/wry?rev=5840108#5840108b00930f038deaca8708804f091679a128" dependencies = [ "base64 0.22.1", "block", diff --git a/Cargo.toml b/Cargo.toml index a4c663d6..904e7b2c 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -18,4 +18,5 @@ strip = true # Remove debug symbols opt-level = 3 [patch.crates-io] -wry = { git = "https://github.com/modrinth/wry", rev = "23b0ee4" } +wry = { git = "https://github.com/modrinth/wry", rev = "5840108" } +tauri = { git = "https://github.com/modrinth/tauri", rev = "5e29428" } \ No newline at end of file diff --git a/apps/app-frontend/.eslintrc.cjs b/apps/app-frontend/.eslintrc.cjs deleted file mode 100644 index 1f85730c..00000000 --- a/apps/app-frontend/.eslintrc.cjs +++ /dev/null @@ -1,4 +0,0 @@ -module.exports = { - root: true, - extends: ['custom/vue'], -} diff --git a/apps/app-frontend/eslint.config.mjs b/apps/app-frontend/eslint.config.mjs new file mode 100644 index 00000000..05f55942 --- /dev/null +++ b/apps/app-frontend/eslint.config.mjs @@ -0,0 +1,22 @@ +import { createConfigForNuxt } from '@nuxt/eslint-config/flat' +import { fixupPluginRules } from '@eslint/compat' +import turboPlugin from 'eslint-plugin-turbo' + +export default createConfigForNuxt().append([ + { + name: 'turbo', + plugins: { + turbo: fixupPluginRules(turboPlugin), + }, + rules: { + 'turbo/no-undeclared-env-vars': 'error', + }, + }, + { + name: 'modrinth', + rules: { + 'vue/html-self-closing': 'off', + 'vue/multi-word-component-names': 'off', + }, + }, +]) diff --git a/apps/app-frontend/package.json b/apps/app-frontend/package.json index 79648c4f..61e19ad5 100644 --- a/apps/app-frontend/package.json +++ b/apps/app-frontend/package.json @@ -1,12 +1,13 @@ { "name": "@modrinth/app-frontend", "private": true, - "version": "0.8.504", - "development_build": false, + "version": "0.8.701", + "development_build": true, "type": "module", "scripts": { "dev": "vite", - "build": "vite build", + "build": "vue-tsc --noEmit && vite build", + "tsc:check": "vue-tsc --noEmit", "lint": "eslint . && prettier --check .", "fix": "eslint . --fix && prettier --write ." }, @@ -14,37 +15,41 @@ "@modrinth/assets": "workspace:*", "@modrinth/ui": "workspace:*", "@modrinth/utils": "workspace:*", + "@sentry/vue": "^8.27.0", "@tauri-apps/api": "^2.0.0-rc.3", "@tauri-apps/plugin-dialog": "^2.0.0-rc.0", "@tauri-apps/plugin-os": "^2.0.0-rc.0", - "@tauri-apps/plugin-window-state": "^2.0.0-rc.0", "@tauri-apps/plugin-shell": "^2.0.0-rc.0", "@tauri-apps/plugin-updater": "^2.0.0-rc.0", + "@tauri-apps/plugin-window-state": "^2.0.0-rc.0", "@vintl/vintl": "^4.4.1", "dayjs": "^1.11.10", "floating-vue": "^5.2.2", "ofetch": "^1.3.4", "pinia": "^2.1.7", + "posthog-js": "^1.158.2", "vite-svg-loader": "^5.1.0", "vue": "^3.4.21", "vue-multiselect": "3.0.0", "vue-router": "4.3.0", - "vue-virtual-scroller": "v2.0.0-beta.8", - "posthog-js": "^1.158.2", - "@sentry/vue": "^8.27.0" + "vue-virtual-scroller": "v2.0.0-beta.8" }, "devDependencies": { - "@tauri-apps/cli": "^2.0.0-rc", + "@eslint/compat": "^1.1.1", + "@nuxt/eslint-config": "^0.5.6", "@vitejs/plugin-vue": "^5.0.4", "autoprefixer": "^10.4.19", - "eslint": "^8.57.0", + "eslint": "^9.9.1", "eslint-config-custom": "workspace:*", + "eslint-plugin-turbo": "^2.1.1", "postcss": "^8.4.39", "prettier": "^3.2.5", "sass": "^1.74.1", "tailwindcss": "^3.4.4", "tsconfig": "workspace:*", - "vite": "^5.2.8" + "typescript": "^5.5.4", + "vite": "^5.2.8", + "vue-tsc": "^2.1.6" }, "packageManager": "pnpm@9.4.0" } diff --git a/apps/app-frontend/src/components/ui/AccountsCard.vue b/apps/app-frontend/src/components/ui/AccountsCard.vue index 1eaa97af..d117d4c6 100644 --- a/apps/app-frontend/src/components/ui/AccountsCard.vue +++ b/apps/app-frontend/src/components/ui/AccountsCard.vue @@ -195,9 +195,9 @@ const logout = async (id) => { trackEvent('AccountLogOut') } -let showCard = ref(false) -let card = ref(null) -let button = ref(null) +const showCard = ref(false) +const card = ref(null) +const button = ref(null) const handleClickOutside = (event) => { const elements = document.elementsFromPoint(event.clientX, event.clientY) if ( diff --git a/apps/app-frontend/src/components/ui/AddContentButton.vue b/apps/app-frontend/src/components/ui/AddContentButton.vue index 2b54711e..0673a919 100644 --- a/apps/app-frontend/src/components/ui/AddContentButton.vue +++ b/apps/app-frontend/src/components/ui/AddContentButton.vue @@ -20,7 +20,7 @@ const handleAddContentFromFile = async () => { if (!newProject) return for (const project of newProject) { - await add_project_from_path(props.instance.path, project.path).catch(handleError) + await add_project_from_path(props.instance.path, project.path ?? project).catch(handleError) } } diff --git a/apps/app-frontend/src/components/ui/InstanceCreationModal.vue b/apps/app-frontend/src/components/ui/InstanceCreationModal.vue index e439c203..6e3a51d1 100644 --- a/apps/app-frontend/src/components/ui/InstanceCreationModal.vue +++ b/apps/app-frontend/src/components/ui/InstanceCreationModal.vue @@ -379,7 +379,7 @@ const upload_icon = async () => { ], }) - icon.value = res ? res : null + icon.value = res.path ?? res if (!icon.value) return display_icon.value = convertFileSrc(icon.value) @@ -417,7 +417,7 @@ const openFile = async () => { const newProject = await open({ multiple: false }) if (!newProject) return hide() - await install_from_file(newProject.path).catch(handleError) + await install_from_file(newProject.path ?? newProject).catch(handleError) trackEvent('InstanceCreate', { source: 'CreationModalFileOpen', @@ -462,7 +462,7 @@ const promises = profileOptions.value.map(async (option) => { option.name, instances.map((name) => ({ name, selected: false })), ) - } catch (error) { + } catch { // Allow failure silently } }) diff --git a/apps/app-frontend/src/components/ui/JavaSelector.vue b/apps/app-frontend/src/components/ui/JavaSelector.vue index f321f814..7c113eb7 100644 --- a/apps/app-frontend/src/components/ui/JavaSelector.vue +++ b/apps/app-frontend/src/components/ui/JavaSelector.vue @@ -124,20 +124,19 @@ async function testJava() { } async function handleJavaFileInput() { - let filePath = await open() + const filePath = await open() if (filePath) { - let result = await get_jre(filePath.path) + let result = await get_jre(filePath.path ?? filePath) if (!result) { result = { - path: filePath.path, + path: filePath.path ?? filePath, version: props.version.toString(), architecture: 'x86', } } trackEvent('JavaManualSelect', { - path: filePath.path, version: props.version, }) @@ -150,7 +149,7 @@ async function autoDetect() { if (!props.compact) { detectJavaModal.value.show(props.version, props.modelValue) } else { - let versions = await find_filtered_jres(props.version).catch(handleError) + const versions = await find_filtered_jres(props.version).catch(handleError) if (versions.length > 0) { emit('update:modelValue', versions[0]) } diff --git a/apps/app-frontend/src/components/ui/SplashScreen.vue b/apps/app-frontend/src/components/ui/SplashScreen.vue index bb3ac1aa..39389937 100644 --- a/apps/app-frontend/src/components/ui/SplashScreen.vue +++ b/apps/app-frontend/src/components/ui/SplashScreen.vue @@ -88,8 +88,6 @@ import { loading_listener } from '@/helpers/events.js' import { getCurrentWindow } from '@tauri-apps/api/window' import { XIcon } from '@modrinth/assets' import { MaximizeIcon, MinimizeIcon } from '@/assets/icons/index.js' -import { TauriEvent } from '@tauri-apps/api/event' -import { saveWindowState, StateFlags } from '@tauri-apps/plugin-window-state' import { getOS } from '@/helpers/utils.js' import { useLoading } from '@/store/loading.js' diff --git a/apps/app-frontend/src/components/ui/install_flow/IncompatibilityWarningModal.vue b/apps/app-frontend/src/components/ui/install_flow/IncompatibilityWarningModal.vue index 81bdf107..f75f7946 100644 --- a/apps/app-frontend/src/components/ui/install_flow/IncompatibilityWarningModal.vue +++ b/apps/app-frontend/src/components/ui/install_flow/IncompatibilityWarningModal.vue @@ -66,7 +66,7 @@ const selectedVersion = ref(null) const incompatibleModal = ref(null) const installing = ref(false) -let onInstall = ref(() => {}) +const onInstall = ref(() => {}) defineExpose({ show: (instanceVal, projectVal, projectVersions, callback) => { diff --git a/apps/app-frontend/src/components/ui/install_flow/InstallConfirmModal.vue b/apps/app-frontend/src/components/ui/install_flow/InstallConfirmModal.vue index 014cf63b..9bb7ec0d 100644 --- a/apps/app-frontend/src/components/ui/install_flow/InstallConfirmModal.vue +++ b/apps/app-frontend/src/components/ui/install_flow/InstallConfirmModal.vue @@ -12,7 +12,7 @@ const project = ref() const confirmModal = ref(null) const installing = ref(false) -let onInstall = ref(() => {}) +const onInstall = ref(() => {}) defineExpose({ show: (projectVal, versionIdVal, callback) => { diff --git a/apps/app-frontend/src/components/ui/install_flow/ModInstallModal.vue b/apps/app-frontend/src/components/ui/install_flow/ModInstallModal.vue index e4e342dc..58e0f4ce 100644 --- a/apps/app-frontend/src/components/ui/install_flow/ModInstallModal.vue +++ b/apps/app-frontend/src/components/ui/install_flow/ModInstallModal.vue @@ -48,7 +48,7 @@ const shownProfiles = computed(() => return profile.name.toLowerCase().includes(searchFilter.value.toLowerCase()) }) .filter((profile) => { - let loaders = versions.value.flatMap((v) => v.loaders) + const loaders = versions.value.flatMap((v) => v.loaders) return ( versions.value.flatMap((v) => v.game_versions).includes(profile.game_version) && @@ -59,7 +59,7 @@ const shownProfiles = computed(() => }), ) -let onInstall = ref(() => {}) +const onInstall = ref(() => {}) defineExpose({ show: async (projectVal, versionsVal, callback) => { @@ -77,7 +77,7 @@ defineExpose({ onInstall.value = callback const profilesVal = await list().catch(handleError) - for (let profile of profilesVal) { + for (const profile of profilesVal) { profile.installing = false profile.installedMod = await check_installed(profile.path, project.value.id).catch( handleError, @@ -150,7 +150,7 @@ const upload_icon = async () => { }, ], }) - icon.value = res ? res.path : null + icon.value = res.path ?? res if (!icon.value) return display_icon.value = convertFileSrc(icon.value) diff --git a/apps/app-frontend/src/helpers/utils.js b/apps/app-frontend/src/helpers/utils.js index d4650acb..fbd7ddb1 100644 --- a/apps/app-frontend/src/helpers/utils.js +++ b/apps/app-frontend/src/helpers/utils.js @@ -61,7 +61,7 @@ export function debounce(fn, wait) { if (timer) { clearTimeout(timer) // clear any pre-existing timer } - // eslint-disable-next-line @typescript-eslint/no-this-alias + const context = this // get the current context timer = setTimeout(() => { fn.apply(context, args) // call the function if time expires diff --git a/apps/app-frontend/src/pages/Browse.vue b/apps/app-frontend/src/pages/Browse.vue index 237d7dbd..0bee9aa8 100644 --- a/apps/app-frontend/src/pages/Browse.vue +++ b/apps/app-frontend/src/pages/Browse.vue @@ -380,20 +380,20 @@ const sortedCategories = computed(() => { // identifier[0], then if it ties, identifier[1], etc async function sortByNameOrNumber(sortable, identifiers) { sortable.sort((a, b) => { - for (let identifier of identifiers) { - let aNum = parseFloat(a[identifier]) - let bNum = parseFloat(b[identifier]) + for (const identifier of identifiers) { + const aNum = parseFloat(a[identifier]) + const bNum = parseFloat(b[identifier]) if (isNaN(aNum) && isNaN(bNum)) { // Both are strings, sort alphabetically - let stringComp = a[identifier].localeCompare(b[identifier]) + const stringComp = a[identifier].localeCompare(b[identifier]) if (stringComp != 0) return stringComp } else if (!isNaN(aNum) && !isNaN(bNum)) { // Both are numbers, sort numerically - let numComp = aNum - bNum + const numComp = aNum - bNum if (numComp != 0) return numComp } else { // One is a number and one is a string, numbers go first - let numStringComp = isNaN(aNum) ? 1 : -1 + const numStringComp = isNaN(aNum) ? 1 : -1 if (numStringComp != 0) return numStringComp } } diff --git a/apps/app-frontend/src/pages/Index.vue b/apps/app-frontend/src/pages/Index.vue index 3a01cc01..02e2fe11 100644 --- a/apps/app-frontend/src/pages/Index.vue +++ b/apps/app-frontend/src/pages/Index.vue @@ -42,7 +42,7 @@ const getInstances = async () => { return dateB - dateA }) - let filters = [] + const filters = [] for (const instance of recentInstances.value) { if (instance.linked_data && instance.linked_data.project_id) { filters.push(`NOT"project_id"="${instance.linked_data.project_id}"`) diff --git a/apps/app-frontend/src/pages/Settings.vue b/apps/app-frontend/src/pages/Settings.vue index afee22be..10bca1a5 100644 --- a/apps/app-frontend/src/pages/Settings.vue +++ b/apps/app-frontend/src/pages/Settings.vue @@ -353,12 +353,16 @@ await getBranches() Java settings -