diff --git a/apps/shinkai-desktop/src-tauri/Cargo.lock b/apps/shinkai-desktop/src-tauri/Cargo.lock index 5acea2596..6ed2573f0 100644 --- a/apps/shinkai-desktop/src-tauri/Cargo.lock +++ b/apps/shinkai-desktop/src-tauri/Cargo.lock @@ -299,7 +299,7 @@ checksum = "3b43422f69d8ff38f95f1b2bb76517c91589a924d1559a0e935d7c8ce0274c11" dependencies = [ "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -334,7 +334,7 @@ checksum = "a27b8a3a6e1a44fa4c8baf1f653e4172e81486d4941f2237e20dc2d0cf4ddff1" dependencies = [ "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -446,7 +446,7 @@ dependencies = [ "regex", "rustc-hash 1.1.0", "shlex", - "syn 2.0.55", + "syn 2.0.90", "which", ] @@ -562,15 +562,15 @@ dependencies = [ "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", "syn_derive", ] [[package]] name = "brotli" -version = "6.0.0" +version = "7.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74f7971dbd9326d58187408ab83117d8ac1bb9c17b085fdacd1cf2f598719b6b" +checksum = "cc97b8f16f944bba54f0433f07e30be199b6dc2bd25937444bbad560bcea29bd" dependencies = [ "alloc-no-stdlib", "alloc-stdlib", @@ -664,7 +664,7 @@ dependencies = [ "glib", "libc", "once_cell", - "thiserror", + "thiserror 1.0.61", ] [[package]] @@ -707,7 +707,7 @@ dependencies = [ "semver", "serde", "serde_json", - "thiserror", + "thiserror 1.0.61", ] [[package]] @@ -906,6 +906,26 @@ version = "0.9.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c2459377285ad874054d797f3ccebf984978aa39129f6eafde5cdc8315b612f8" +[[package]] +name = "const-random" +version = "0.1.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "87e00182fe74b066627d63b85fd550ac2998d4b0bd86bfed477a0ae4c7c71359" +dependencies = [ + "const-random-macro", +] + +[[package]] +name = "const-random-macro" +version = "0.1.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f9d839f2a20b0aee515dc581a6172f2321f96cab76c1a38a4c584a194955390e" +dependencies = [ + "getrandom 0.2.12", + "once_cell", + "tiny-keccak", +] + [[package]] name = "constant_time_eq" version = "0.3.0" @@ -918,6 +938,16 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6245d59a3e82a7fc217c5828a6692dbc6dfb63a0c8c90495621f7b9d79704a0e" +[[package]] +name = "cookie" +version = "0.18.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4ddef33a339a91ea89fb53151bd0a4689cfce27055c291dfa69945475d22c747" +dependencies = [ + "time", + "version_check", +] + [[package]] name = "core-foundation" version = "0.9.4" @@ -1088,6 +1118,12 @@ version = "0.8.19" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "248e3bacc7dc6baa3b21e405ee045c3047101a49145e7e9eca583ab4c2ca5345" +[[package]] +name = "crunchy" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a81dae078cea95a014a339291cec439d2f232ebe854a9d672b796c6afafa9b7" + [[package]] name = "crypto-common" version = "0.1.6" @@ -1122,7 +1158,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "13b588ba4ac1a99f7f2964d24b3d896ddc6bf847ee3855dbd4366f058cfcd331" dependencies = [ "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -1132,7 +1168,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ad291aa74992b9b7a7e88c38acbbf6ad7e107f1d90ee8775b7bc1fc3394f485c" dependencies = [ "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -1160,7 +1196,7 @@ checksum = "f46882e17999c6cc590af592290432be3bce0428cb0d5f8b6715e4dc7b383eb3" dependencies = [ "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -1195,7 +1231,7 @@ dependencies = [ "proc-macro2", "quote", "strsim", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -1206,7 +1242,7 @@ checksum = "a668eda54683121533a393014d8692171709ff57a7d61f187b6e782719f8933f" dependencies = [ "darling_core", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -1254,7 +1290,7 @@ checksum = "67e77553c4162a157adbf834ebae5b415acbecbeafc7a74b0e886657506a7611" dependencies = [ "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -1315,7 +1351,7 @@ checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0" dependencies = [ "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -1347,7 +1383,16 @@ checksum = "f2b99bf03862d7f545ebc28ddd33a665b50865f4dfd84031a393823879bd4c54" dependencies = [ "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", +] + +[[package]] +name = "dlv-list" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "442039f5147480ba31067cb00ada1adae6892028e40e45fc5de7b7df6dcc1b5f" +dependencies = [ + "const-random", ] [[package]] @@ -1485,7 +1530,7 @@ checksum = "de0d48a183585823424a4ce1aa132d174a6a81bd540895822eb4c8373a8e49e8" dependencies = [ "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -1562,9 +1607,9 @@ dependencies = [ [[package]] name = "fern" -version = "0.6.2" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d9f0c14694cbd524c8720dd69b0e3179344f04ebb5f90f2e4a440c6ea3b2f1ee" +checksum = "69ff9c9d5fb3e6da8ac2f77ab76fe7e8087d512ce095200f8f29ac5b656cf6dc" dependencies = [ "log", ] @@ -1607,15 +1652,6 @@ dependencies = [ "miniz_oxide", ] -[[package]] -name = "fluent-uri" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c704e9dbe1ddd863da1e6ff3567795087b1eb201ce80d8fa81162e1516500d" -dependencies = [ - "bitflags 1.3.2", -] - [[package]] name = "fnv" version = "1.0.7" @@ -1649,7 +1685,7 @@ checksum = "1a5c6c585bc94aaf2c7b51dd4c2ba22680844aba4c687be581871a6f518c5742" dependencies = [ "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -1742,7 +1778,7 @@ checksum = "87750cf4b7a4c0625b1529e4c543c2182106e4dedc60a2a6455e00d212c489ac" dependencies = [ "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -1946,7 +1982,7 @@ dependencies = [ "once_cell", "pin-project-lite", "smallvec", - "thiserror", + "thiserror 1.0.61", ] [[package]] @@ -1993,7 +2029,7 @@ dependencies = [ "memchr", "once_cell", "smallvec", - "thiserror", + "thiserror 1.0.61", ] [[package]] @@ -2007,7 +2043,7 @@ dependencies = [ "proc-macro-error", "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -2038,7 +2074,7 @@ dependencies = [ "objc2-app-kit", "once_cell", "serde", - "thiserror", + "thiserror 1.0.61", "windows-sys 0.59.0", "x11-dl", ] @@ -2102,7 +2138,7 @@ checksum = "6f56f6318968d03c18e1bcf4857ff88c61157e9da8e47c5f29055d60e1228884" dependencies = [ "log", "presser", - "thiserror", + "thiserror 1.0.61", "winapi", "windows 0.52.0", ] @@ -2176,7 +2212,7 @@ dependencies = [ "proc-macro-error", "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -2227,7 +2263,7 @@ dependencies = [ "com", "libc", "libloading 0.8.3", - "thiserror", + "thiserror 1.0.61", "widestring", "winapi", ] @@ -2640,7 +2676,7 @@ dependencies = [ "combine", "jni-sys", "log", - "thiserror", + "thiserror 1.0.61", "walkdir", "windows-sys 0.45.0", ] @@ -2671,23 +2707,22 @@ dependencies = [ [[package]] name = "json-patch" -version = "2.0.0" +version = "3.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b1fb8864823fad91877e6caea0baca82e49e8db50f8e5c9f9a453e27d3330fc" +checksum = "863726d7afb6bc2590eeff7135d923545e5e964f004c2ccf8716c25e70a86f08" dependencies = [ "jsonptr", "serde", "serde_json", - "thiserror", + "thiserror 1.0.61", ] [[package]] name = "jsonptr" -version = "0.4.7" +version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c6e529149475ca0b2820835d3dce8fcc41c6b943ca608d32f35b449255e4627" +checksum = "5dea2b27dd239b2556ed7a25ba842fe47fd602e7fc7433c2a8d6106d4d9edd70" dependencies = [ - "fluent-uri", "serde", "serde_json", ] @@ -2995,7 +3030,7 @@ dependencies = [ "once_cell", "png", "serde", - "thiserror", + "thiserror 1.0.61", "windows-sys 0.59.0", ] @@ -3016,7 +3051,7 @@ dependencies = [ "rustc-hash 1.1.0", "spirv", "termcolor", - "thiserror", + "thiserror 1.0.61", "unicode-xid", ] @@ -3049,7 +3084,7 @@ dependencies = [ "log", "ndk-sys 0.5.0+25.2.9519653", "num_enum", - "thiserror", + "thiserror 1.0.61", ] [[package]] @@ -3064,7 +3099,7 @@ dependencies = [ "ndk-sys 0.6.0+11769913", "num_enum", "raw-window-handle", - "thiserror", + "thiserror 1.0.61", ] [[package]] @@ -3149,7 +3184,7 @@ checksum = "ed3955f1a9c7c0c15e092f9c887db08b1fc683305fdf6eb6684f22555355e202" dependencies = [ "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -3189,7 +3224,7 @@ dependencies = [ "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -3501,7 +3536,7 @@ checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" dependencies = [ "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -3528,6 +3563,16 @@ version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "04744f49eae99ab78e0d5c0b603ab218f515ea8cfe5a456d7629ad883a3b6e7d" +[[package]] +name = "ordered-multimap" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "49203cdcae0030493bad186b28da2fa25645fa276a51b6fec8010d281e02ef79" +dependencies = [ + "dlv-list", + "hashbrown 0.14.3", +] + [[package]] name = "ordered-stream" version = "0.2.0" @@ -3750,7 +3795,7 @@ dependencies = [ "phf_shared 0.11.2", "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -3797,7 +3842,7 @@ checksum = "2f38a4412a78282e09a2cf38d195ea5420d15ba0602cb375210efbc877243965" dependencies = [ "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -3918,7 +3963,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8d3928fb5db768cb86f891ff014f0144589297e3c6a1aba6ed7cecfdace270c7" dependencies = [ "proc-macro2", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -3981,9 +4026,9 @@ checksum = "dc375e1527247fe1a97d8b7156678dfe7c1af2fc075c9a4db3690ecd2a148068" [[package]] name = "proc-macro2" -version = "1.0.79" +version = "1.0.92" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e835ff2298f5721608eb1a980ecaee1aef2c132bf95ecc026a11b7bf3c01c02e" +checksum = "37d3544b3f2748c54e147655edb5025752e2303145b5aefb3c3ea2c78b973bb0" dependencies = [ "unicode-ident", ] @@ -4045,7 +4090,7 @@ dependencies = [ "rustc-hash 2.0.0", "rustls", "socket2", - "thiserror", + "thiserror 1.0.61", "tokio", "tracing", ] @@ -4062,7 +4107,7 @@ dependencies = [ "rustc-hash 2.0.0", "rustls", "slab", - "thiserror", + "thiserror 1.0.61", "tinyvec", "tracing", ] @@ -4234,7 +4279,7 @@ checksum = "a18479200779601e498ada4e8c1e1f50e3ee19deb0259c25825a98b5603b2cb4" dependencies = [ "getrandom 0.2.12", "libredox 0.0.1", - "thiserror", + "thiserror 1.0.61", ] [[package]] @@ -4364,7 +4409,7 @@ dependencies = [ "wasm-streams", "web-sys", "webpki-roots", - "windows-registry", + "windows-registry 0.2.0", ] [[package]] @@ -4434,6 +4479,17 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "rust-ini" +version = "0.21.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4e310ef0e1b6eeb79169a1171daf9abcb87a2e17c03bee2c4bb100b55c75409f" +dependencies = [ + "cfg-if", + "ordered-multimap", + "trim-in-place", +] + [[package]] name = "rust_decimal" version = "1.36.0" @@ -4588,7 +4644,7 @@ dependencies = [ "proc-macro2", "quote", "serde_derive_internals", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -4663,9 +4719,9 @@ dependencies = [ [[package]] name = "serde" -version = "1.0.197" +version = "1.0.216" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3fb1c873e1b9b056a4dc4c0c198b24c3ffa059243875552b2bd0933b1aee4ce2" +checksum = "0b9781016e935a97e8beecf0c933758c97a5520d32930e460142b4cd80c6338e" dependencies = [ "serde_derive", ] @@ -4683,13 +4739,13 @@ dependencies = [ [[package]] name = "serde_derive" -version = "1.0.197" +version = "1.0.216" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7eb0b34b42edc17f6b7cac84a52a1c5f0e1bb2227e997ca9011ea3dd34e8610b" +checksum = "46f859dbbf73865c6627ed570e78961cd3ac92407a2d117204c49232485da55e" dependencies = [ "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -4700,16 +4756,17 @@ checksum = "18d26a20a969b9e3fdf2fc2d9f21eda6c40e2de84c9408bb5d3b05d499aae711" dependencies = [ "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] name = "serde_json" -version = "1.0.115" +version = "1.0.133" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "12dc5c46daa8e9fdf4f5e71b6cf9a53f2487da0e86e55808e2d35539666497dd" +checksum = "c7fceb2473b9166b2294ef05efcb65a3db80803f0b03ef86a5fc88a2b85ee377" dependencies = [ "itoa 1.0.11", + "memchr", "ryu", "serde", ] @@ -4722,7 +4779,7 @@ checksum = "0b2e6b945e9d3df726b65d6ee24060aff8e3533d431f677a9695db04eff9dfdb" dependencies = [ "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -4773,7 +4830,7 @@ dependencies = [ "darling", "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -4864,6 +4921,7 @@ dependencies = [ "sysinfo", "tauri", "tauri-build", + "tauri-plugin-deep-link", "tauri-plugin-dialog", "tauri-plugin-fs", "tauri-plugin-global-shortcut", @@ -5105,9 +5163,9 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.55" +version = "2.0.90" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "002a1b3dbf967edfafc32655d0f377ab0bb7b994aa1d32c8cc7e9b8bf3ebb8f0" +checksum = "919d3b74a5dd0ccd15aeb8f93e7006bd9e14c295087c9896a110f490752bcf31" dependencies = [ "proc-macro2", "quote", @@ -5123,7 +5181,7 @@ dependencies = [ "proc-macro-error", "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -5201,9 +5259,9 @@ dependencies = [ [[package]] name = "tao" -version = "0.30.3" +version = "0.30.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a0dbbebe82d02044dfa481adca1550d6dd7bd16e086bc34fa0fbecceb5a63751" +checksum = "6682a07cf5bab0b8a2bd20d0a542917ab928b5edb75ebd4eda6b05cbaab872da" dependencies = [ "bitflags 2.5.0", "cocoa", @@ -5274,9 +5332,9 @@ checksum = "e1fc403891a21bcfb7c37834ba66a547a8f402146eba7265b5a6d88059c9ff2f" [[package]] name = "tauri" -version = "2.0.5" +version = "2.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ce2818e803ce3097987296623ed8c0d9f65ed93b4137ff9a83e168bdbf62932" +checksum = "e545de0a2dfe296fa67db208266cd397c5a55ae782da77973ef4c4fac90e9f2c" dependencies = [ "anyhow", "bytes", @@ -5312,7 +5370,7 @@ dependencies = [ "tauri-runtime", "tauri-runtime-wry", "tauri-utils", - "thiserror", + "thiserror 2.0.6", "tokio", "tray-icon", "url", @@ -5325,9 +5383,9 @@ dependencies = [ [[package]] name = "tauri-build" -version = "2.0.1" +version = "2.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "935f9b3c49b22b3e2e485a57f46d61cd1ae07b1cbb2ba87387a387caf2d8c4e7" +checksum = "7bd2a4bcfaf5fb9f4be72520eefcb61ae565038f8ccba2a497d8c28f463b8c01" dependencies = [ "anyhow", "cargo_toml", @@ -5347,9 +5405,9 @@ dependencies = [ [[package]] name = "tauri-codegen" -version = "2.0.1" +version = "2.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95d7443dd4f0b597704b6a14b964ee2ed16e99928d8e6292ae9825f09fbcd30e" +checksum = "bf79faeecf301d3e969b1fae977039edb77a4c1f25cc0a961be298b54bff97cf" dependencies = [ "base64 0.22.1", "brotli", @@ -5363,9 +5421,9 @@ dependencies = [ "serde", "serde_json", "sha2", - "syn 2.0.55", + "syn 2.0.90", "tauri-utils", - "thiserror", + "thiserror 2.0.6", "time", "url", "uuid", @@ -5374,14 +5432,14 @@ dependencies = [ [[package]] name = "tauri-macros" -version = "2.0.1" +version = "2.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d2c0963ccfc3f5194415f2cce7acc975942a8797fbabfb0aa1ed6f59326ae7f" +checksum = "c52027c8c5afb83166dacddc092ee8fff50772f9646d461d8c33ee887e447a03" dependencies = [ "heck 0.5.0", "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", "tauri-codegen", "tauri-utils", ] @@ -5403,11 +5461,31 @@ dependencies = [ "walkdir", ] +[[package]] +name = "tauri-plugin-deep-link" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "35d51ffd286073414d26353bcfc9e83e3cd63f96fa7f7a912f92f2118e5de5a6" +dependencies = [ + "dunce", + "rust-ini", + "serde", + "serde_json", + "tauri", + "tauri-plugin", + "tauri-utils", + "thiserror 2.0.6", + "tracing", + "url", + "windows-registry 0.3.0", + "windows-result 0.2.0", +] + [[package]] name = "tauri-plugin-dialog" -version = "2.0.1" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ddb2fe88b602461c118722c574e2775ab26a4e68886680583874b2f6520608b7" +checksum = "8b59fd750551b1066744ab956a1cd6b1ea3e1b3763b0b9153ac27a044d596426" dependencies = [ "log", "raw-window-handle", @@ -5417,15 +5495,15 @@ dependencies = [ "tauri", "tauri-plugin", "tauri-plugin-fs", - "thiserror", + "thiserror 2.0.6", "url", ] [[package]] name = "tauri-plugin-fs" -version = "2.0.1" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ab300488ebec3487ca5f56289692e7e45feb07eea8d5e1dba497f7dc9dd9c407" +checksum = "a1a1edf18000f02903a7c2e5997fb89aca455ecbc0acc15c6535afbb883be223" dependencies = [ "anyhow", "dunce", @@ -5437,16 +5515,18 @@ dependencies = [ "serde_repr", "tauri", "tauri-plugin", - "thiserror", + "tauri-utils", + "thiserror 2.0.6", + "toml 0.8.12", "url", "uuid", ] [[package]] name = "tauri-plugin-global-shortcut" -version = "2.0.1" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c15fb7f5e4c80a73ce97217dcff27e423f496178cbcb87e13b4efe99eebb550" +checksum = "00f646a09511e8d283267dcdaa08c2ef27c4116bf271d9114849d9ca215606c3" dependencies = [ "global-hotkey", "log", @@ -5454,14 +5534,14 @@ dependencies = [ "serde_json", "tauri", "tauri-plugin", - "thiserror", + "thiserror 2.0.6", ] [[package]] name = "tauri-plugin-log" -version = "2.0.1" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a49f2c05d15e6375ab7f7e528b3049150ba4dfafdf61f85e5178d0aef18e3f5" +checksum = "eddd784c138c08a43954bc3e735402e6b2b2ee8d8c254a7391f4e77c01273dd5" dependencies = [ "android_logger", "byte-unit", @@ -5475,15 +5555,15 @@ dependencies = [ "swift-rs", "tauri", "tauri-plugin", - "thiserror", + "thiserror 2.0.6", "time", ] [[package]] name = "tauri-plugin-os" -version = "2.0.1" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fbc5f23a86f37687c7f4fecfdc706b279087bc44f7a46702f7307ff1551ee03a" +checksum = "dda2d571a9baf0664c1f2088db227e3072f9028602fafa885deade7547c3b738" dependencies = [ "gethostname", "log", @@ -5494,14 +5574,14 @@ dependencies = [ "sys-locale", "tauri", "tauri-plugin", - "thiserror", + "thiserror 2.0.6", ] [[package]] name = "tauri-plugin-process" -version = "2.0.1" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae06a00087c148962a52814a2d7265b1a0505bced5ffb74f8c284a5f96a4d03d" +checksum = "40cc553ab29581c8c43dfa5fb0c9d5aee8ba962ad3b42908eea26c79610441b7" dependencies = [ "tauri", "tauri-plugin", @@ -5509,9 +5589,9 @@ dependencies = [ [[package]] name = "tauri-plugin-shell" -version = "2.0.1" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "371fb9aca2823990a2d0db7970573be5fdf07881fcaa2b835b29631feb84aec1" +checksum = "bb2c50a63e60fb8925956cc5b7569f4b750ac197a4d39f13b8dd46ea8e2bad79" dependencies = [ "encoding_rs", "log", @@ -5524,30 +5604,31 @@ dependencies = [ "shared_child", "tauri", "tauri-plugin", - "thiserror", + "thiserror 2.0.6", "tokio", ] [[package]] name = "tauri-plugin-single-instance" -version = "2.0.1" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a25ac834491d089699a2bc9266a662faf373c9f779f05a2235bc6e4d9e61769a" +checksum = "0f36019ee9832dc99e4450bb55a21cfad8633b19c2c18bd17c7741939b070ede" dependencies = [ - "log", "serde", "serde_json", "tauri", - "thiserror", + "tauri-plugin-deep-link", + "thiserror 2.0.6", + "tracing", "windows-sys 0.59.0", "zbus", ] [[package]] name = "tauri-plugin-updater" -version = "2.0.2" +version = "2.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1dd3d2fe0f02bf52eebb5a9d23b987fffac6684646ab6fd683d706dafb18da87" +checksum = "b7351014c140906bcfff59d96e04b1170c8f602557f40eb37f7de356d4e7067b" dependencies = [ "base64 0.22.1", "dirs", @@ -5565,7 +5646,7 @@ dependencies = [ "tauri", "tauri-plugin", "tempfile", - "thiserror", + "thiserror 2.0.6", "time", "tokio", "url", @@ -5575,9 +5656,9 @@ dependencies = [ [[package]] name = "tauri-runtime" -version = "2.1.0" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c8f437293d6f5e5dce829250f4dbdce4e0b52905e297a6689cc2963eb53ac728" +checksum = "cce18d43f80d4aba3aa8a0c953bbe835f3d0f2370aca75e8dbb14bd4bab27958" dependencies = [ "dpi", "gtk", @@ -5587,16 +5668,16 @@ dependencies = [ "serde", "serde_json", "tauri-utils", - "thiserror", + "thiserror 2.0.6", "url", "windows 0.58.0", ] [[package]] name = "tauri-runtime-wry" -version = "2.1.1" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1431602bcc71f2f840ad623915c9842ecc32999b867c4a787d975a17a9625cc6" +checksum = "9f442a38863e10129ffe2cec7bd09c2dcf8a098a3a27801a476a304d5bb991d2" dependencies = [ "gtk", "http 1.1.0", @@ -5620,9 +5701,9 @@ dependencies = [ [[package]] name = "tauri-utils" -version = "2.0.1" +version = "2.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c38b0230d6880cf6dd07b6d7dd7789a0869f98ac12146e0d18d1c1049215a045" +checksum = "9271a88f99b4adea0dc71d0baca4505475a0bbd139fb135f62958721aaa8fe54" dependencies = [ "brotli", "cargo_metadata", @@ -5630,6 +5711,7 @@ dependencies = [ "dunce", "glob", "html5ever", + "http 1.1.0", "infer", "json-patch", "kuchikiki", @@ -5646,7 +5728,7 @@ dependencies = [ "serde_json", "serde_with", "swift-rs", - "thiserror", + "thiserror 2.0.6", "toml 0.8.12", "url", "urlpattern", @@ -5708,7 +5790,16 @@ version = "1.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c546c80d6be4bc6a00c0f01730c08df82eaa7a7a61f11d656526506112cc1709" dependencies = [ - "thiserror-impl", + "thiserror-impl 1.0.61", +] + +[[package]] +name = "thiserror" +version = "2.0.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8fec2a1820ebd077e2b90c4df007bebf344cd394098a13c563957d0afc83ea47" +dependencies = [ + "thiserror-impl 2.0.6", ] [[package]] @@ -5719,7 +5810,18 @@ checksum = "46c3384250002a6d5af4d114f2845d37b57521033f30d5c3f46c4d70e1197533" dependencies = [ "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", +] + +[[package]] +name = "thiserror-impl" +version = "2.0.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d65750cab40f4ff1929fb1ba509e9914eb756131cef4210da8d5d700d26f6312" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.90", ] [[package]] @@ -5755,6 +5857,15 @@ dependencies = [ "time-core", ] +[[package]] +name = "tiny-keccak" +version = "2.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2c9d3793400a45f954c52e73d068316d76b6f4e36977e3fcebb13a2721e80237" +dependencies = [ + "crunchy", +] + [[package]] name = "tinyvec" version = "1.6.0" @@ -5797,7 +5908,7 @@ checksum = "5b8a1e28f2deaa14e508979454cb3a223b10b938b45af148bc0986de36f1923b" dependencies = [ "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -5962,7 +6073,7 @@ checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -5991,10 +6102,16 @@ dependencies = [ "once_cell", "png", "serde", - "thiserror", + "thiserror 1.0.61", "windows-sys 0.59.0", ] +[[package]] +name = "trim-in-place" +version = "0.1.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "343e926fc669bc8cde4fa3129ab681c63671bae288b1f1081ceee6d9d37904fc" + [[package]] name = "try-lock" version = "0.2.5" @@ -6252,7 +6369,7 @@ dependencies = [ "once_cell", "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", "wasm-bindgen-shared", ] @@ -6286,7 +6403,7 @@ checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", "wasm-bindgen-backend", "wasm-bindgen-shared", ] @@ -6464,7 +6581,7 @@ checksum = "1d228f15bba3b9d56dde8bddbee66fa24545bd17b48d5128ccf4a8742b18e431" dependencies = [ "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -6473,7 +6590,7 @@ version = "0.33.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a3a3e2eeb58f82361c93f9777014668eb3d07e7d174ee4c819575a9208011886" dependencies = [ - "thiserror", + "thiserror 1.0.61", "windows 0.58.0", "windows-core 0.58.0", ] @@ -6525,7 +6642,7 @@ dependencies = [ "raw-window-handle", "rustc-hash 1.1.0", "smallvec", - "thiserror", + "thiserror 1.0.61", "web-sys", "wgpu-hal", "wgpu-types", @@ -6569,7 +6686,7 @@ dependencies = [ "renderdoc-sys", "rustc-hash 1.1.0", "smallvec", - "thiserror", + "thiserror 1.0.61", "wasm-bindgen", "web-sys", "wgpu-types", @@ -6727,7 +6844,7 @@ dependencies = [ "windows-implement", "windows-interface", "windows-result 0.2.0", - "windows-strings", + "windows-strings 0.1.0", "windows-targets 0.52.6", ] @@ -6739,7 +6856,7 @@ checksum = "2bbd5b46c938e506ecbce286b6628a02171d56153ba733b6c741fc627ec9579b" dependencies = [ "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -6750,7 +6867,7 @@ checksum = "053c4c462dc91d3b1504c6fe5a726dd15e216ba718e84a0e46a88fbe5ded3515" dependencies = [ "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -6760,7 +6877,18 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e400001bb720a623c1c69032f8e3e4cf09984deec740f007dd2b03ec864804b0" dependencies = [ "windows-result 0.2.0", - "windows-strings", + "windows-strings 0.1.0", + "windows-targets 0.52.6", +] + +[[package]] +name = "windows-registry" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bafa604f2104cf5ae2cc2db1dee84b7e6a5d11b05f737b60def0ffdc398cbc0a" +dependencies = [ + "windows-result 0.2.0", + "windows-strings 0.2.0", "windows-targets 0.52.6", ] @@ -6792,6 +6920,15 @@ dependencies = [ "windows-targets 0.52.6", ] +[[package]] +name = "windows-strings" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "978d65aedf914c664c510d9de43c8fd85ca745eaff1ed53edf409b479e441663" +dependencies = [ + "windows-targets 0.52.6", +] + [[package]] name = "windows-sys" version = "0.45.0" @@ -7055,12 +7192,13 @@ dependencies = [ [[package]] name = "wry" -version = "0.46.3" +version = "0.47.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd5cdf57c66813d97601181349c63b96994b3074fc3d7a31a8cce96e968e3bbd" +checksum = "61ce51277d65170f6379d8cda935c80e3c2d1f0ff712a123c8bddb11b31a4b73" dependencies = [ "base64 0.22.1", "block2", + "cookie", "crossbeam-channel", "dpi", "dunce", @@ -7084,7 +7222,8 @@ dependencies = [ "sha2", "soup3", "tao-macros", - "thiserror", + "thiserror 1.0.61", + "url", "webkit2gtk", "webkit2gtk-sys", "webview2-com", @@ -7233,7 +7372,7 @@ checksum = "15e934569e47891f7d9411f1a451d947a60e000ab3bd24fbb970f000387d1b3b" dependencies = [ "proc-macro2", "quote", - "syn 2.0.55", + "syn 2.0.90", ] [[package]] @@ -7253,7 +7392,7 @@ dependencies = [ "crossbeam-utils", "displaydoc", "indexmap 2.2.6", - "thiserror", + "thiserror 1.0.61", ] [[package]] diff --git a/apps/shinkai-desktop/src-tauri/Cargo.toml b/apps/shinkai-desktop/src-tauri/Cargo.toml index 4f1197a7a..c386aee76 100644 --- a/apps/shinkai-desktop/src-tauri/Cargo.toml +++ b/apps/shinkai-desktop/src-tauri/Cargo.toml @@ -10,10 +10,10 @@ edition = "2021" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [build-dependencies] -tauri-build = { version = "2.0.1", features = [] } +tauri-build = { version = "2.0.3", features = [] } [dependencies] -tauri = { version = "2.0.2", features = [ "macos-private-api", "tray-icon", "image-png"] } +tauri = { version = "2.1.1", features = [ "macos-private-api", "tray-icon", "image-png"] } serde = { version = "1.0", features = ["derive"] } serde_json = "1.0" whisper-rs = "0.8.0" @@ -40,15 +40,16 @@ log = "0.4" anyhow = "1.0.89" uuid = "1.10.0" -tauri-plugin-global-shortcut = "2.0.1" -tauri-plugin-shell = "2.0.1" -tauri-plugin-single-instance = "2.0.1" -tauri-plugin-updater = "2.0.2" -tauri-plugin-dialog = "2.0.1" -tauri-plugin-fs="2.0.1" -tauri-plugin-os = "2.0.1" -tauri-plugin-process = "2.0.1" -tauri-plugin-log = "2.0.1" +tauri-plugin-global-shortcut = "2.2" +tauri-plugin-shell = "2.2" +tauri-plugin-single-instance = { version = "2.2", features = ["deep-link"] } +tauri-plugin-updater = "2.3" +tauri-plugin-dialog = "2.2" +tauri-plugin-fs ="2.2" +tauri-plugin-os = "2.2" +tauri-plugin-process = "2.2" +tauri-plugin-log = "2.2" +tauri-plugin-deep-link = "2.2" [features] # this feature is used for production builds or when `devPath` points to the filesystem diff --git a/apps/shinkai-desktop/src-tauri/src/deep_links.rs b/apps/shinkai-desktop/src-tauri/src/deep_links.rs new file mode 100644 index 000000000..2f555f900 --- /dev/null +++ b/apps/shinkai-desktop/src-tauri/src/deep_links.rs @@ -0,0 +1,56 @@ +use tauri::Emitter; +use tauri_plugin_deep_link::DeepLinkExt; + +use crate::windows::{recreate_window, Window}; + +#[derive(Debug, Clone, serde::Serialize)] +pub struct OAuthDeepLinkPayload { + pub state: String, + pub code: String, +} + +pub fn setup_deep_links(app: &tauri::AppHandle) -> tauri::Result<()> { + #[cfg(any(windows, target_os = "linux"))] + { + use tauri_plugin_deep_link::DeepLinkExt; + app.deep_link() + .register_all() + .map_err(|e| tauri::Error::Anyhow(e.into()))?; + } + let app_handle = app.clone(); + app.deep_link().on_open_url(move |event| { + let urls: Vec<_> = event.urls().into_iter().collect(); + log::debug!("deep link URLs: {:?}", urls); + for url in urls { + log::debug!("handling deep link: {:?}", url); + if let Some(host) = url.host() { + if host.to_string() == "oauth" { + log::debug!("oauth deep link: {:?}", url); + let query_pairs = url.query_pairs().collect::>(); + let state = query_pairs + .iter() + .find(|(key, _)| key == "state") + .map(|(_, value)| value.to_string()) + .unwrap_or_default(); + let code = query_pairs + .iter() + .find(|(key, _)| key == "code") + .map(|(_, value)| value.to_string()) + .unwrap_or_default(); + let payload = OAuthDeepLinkPayload { state, code }; + log::debug!( + "emitting oauth-deep-link event to {}", + Window::Coordinator.as_str() + ); + let _ = recreate_window(app_handle.clone(), Window::Main, true); + let _ = app_handle.emit_to( + Window::Coordinator.as_str(), + "oauth-deep-link", + payload, + ); + } + } + } + }); + Ok(()) +} diff --git a/apps/shinkai-desktop/src-tauri/src/global_shortcuts/toggle_spotlight.rs b/apps/shinkai-desktop/src-tauri/src/global_shortcuts/toggle_spotlight.rs index 505839c78..0b08dcac9 100644 --- a/apps/shinkai-desktop/src-tauri/src/global_shortcuts/toggle_spotlight.rs +++ b/apps/shinkai-desktop/src-tauri/src/global_shortcuts/toggle_spotlight.rs @@ -11,5 +11,5 @@ pub fn toggle_spotlight(app: &tauri::AppHandle, _: Shortcut, _: ShortcutEvent) { return; } } - recreate_window(app.clone(), Window::Spotlight, true) + recreate_window(app.clone(), Window::Spotlight, true); } diff --git a/apps/shinkai-desktop/src-tauri/src/main.rs b/apps/shinkai-desktop/src-tauri/src/main.rs index 66fe006b3..454a16f9b 100644 --- a/apps/shinkai-desktop/src-tauri/src/main.rs +++ b/apps/shinkai-desktop/src-tauri/src/main.rs @@ -23,7 +23,7 @@ use tauri::{Manager, RunEvent}; use tokio::sync::Mutex; use tray::create_tray; use windows::{recreate_window, Window}; - +use deep_links::setup_deep_links; mod audio; mod commands; mod galxe; @@ -33,6 +33,7 @@ mod hardware; mod local_shinkai_node; mod tray; mod windows; +mod deep_links; #[derive(Clone, serde::Serialize)] struct Payload { @@ -42,16 +43,16 @@ struct Payload { fn main() { tauri::Builder::default() + .plugin(tauri_plugin_single_instance::init(|app, argv, cwd| { + app.emit("single-instance", Payload { args: argv, cwd }) + .unwrap(); + })) .plugin(tauri_plugin_log::Builder::new().build()) .plugin(tauri_plugin_os::init()) .plugin(tauri_plugin_updater::Builder::new().build()) .plugin(tauri_plugin_shell::init()) .plugin(tauri_plugin_fs::init()) .plugin(tauri_plugin_process::init()) - .plugin(tauri_plugin_single_instance::init(|app, argv, cwd| { - app.emit("single-instance", Payload { args: argv, cwd }) - .unwrap(); - })) .plugin(tauri_plugin_dialog::init()) .plugin( tauri_plugin_global_shortcut::Builder::new() @@ -71,6 +72,7 @@ fn main() { ) .build(), ) + .plugin(tauri_plugin_deep_link::init()) .invoke_handler(tauri::generate_handler![ hide_spotlight_window_app, show_spotlight_window_app, @@ -104,6 +106,7 @@ fn main() { } create_tray(app.handle())?; + setup_deep_links(app.handle())?; /* This is the initialization pipeline @@ -118,9 +121,9 @@ fn main() { shinkai_node_manager_guard.kill().await; drop(shinkai_node_manager_guard); - recreate_window(app_handle.clone(), Window::Coordinator, false); - recreate_window(app_handle.clone(), Window::Spotlight, false); - recreate_window(app_handle.clone(), Window::Main, true); + let _ = recreate_window(app_handle.clone(), Window::Coordinator, false); + let _ = recreate_window(app_handle.clone(), Window::Spotlight, false); + let _ = recreate_window(app_handle.clone(), Window::Main, true); } }); @@ -141,6 +144,8 @@ fn main() { } }); + + Ok(()) }) .build(tauri::generate_context!()) diff --git a/apps/shinkai-desktop/src-tauri/src/windows/mod.rs b/apps/shinkai-desktop/src-tauri/src/windows/mod.rs index e1d9fa3d8..ca9812725 100644 --- a/apps/shinkai-desktop/src-tauri/src/windows/mod.rs +++ b/apps/shinkai-desktop/src-tauri/src/windows/mod.rs @@ -1,4 +1,4 @@ -use tauri::{AppHandle, Manager, WebviewWindowBuilder}; +use tauri::{AppHandle, Manager, WebviewWindow, WebviewWindowBuilder}; #[derive(Debug, Clone, Copy)] pub enum Window { @@ -19,7 +19,7 @@ impl Window { } } -pub fn recreate_window(app_handle: AppHandle, window_name: Window, focus: bool) { +pub fn recreate_window(app_handle: AppHandle, window_name: Window, focus: bool) -> tauri::Result { let label = window_name.as_str(); if let Some(window) = app_handle.get_webview_window(label) { log::info!("window {} found, bringing to front", label); @@ -32,6 +32,7 @@ pub fn recreate_window(app_handle: AppHandle, window_name: Window, focus: bool) // window.center().unwrap(); let _ = window.set_focus(); } + return Ok(window); } else { log::info!("window {} not found, recreating...", label); let window_config = app_handle @@ -44,13 +45,18 @@ pub fn recreate_window(app_handle: AppHandle, window_name: Window, focus: bool) .clone(); match WebviewWindowBuilder::from_config(&app_handle, &window_config) { Ok(builder) => match builder.build() { - Ok(_) => { + Ok(window) => { log::info!("window {} created", label); + return Ok(window) } - Err(e) => log::error!("failed to recreate window: {}", e), + Err(e) => { + log::error!("failed to recreate window: {}", e); + Err(e) + }, }, Err(e) => { log::error!("failed to recreate window from config: {}", e); + Err(e) } } } diff --git a/apps/shinkai-desktop/src-tauri/tauri.conf.json b/apps/shinkai-desktop/src-tauri/tauri.conf.json index 25edb7bd9..c3c57768f 100644 --- a/apps/shinkai-desktop/src-tauri/tauri.conf.json +++ b/apps/shinkai-desktop/src-tauri/tauri.conf.json @@ -38,6 +38,11 @@ "windows": { "installMode": "basicUi" } + }, + "deep-link": { + "desktop": { + "schemes": ["shinkai"] + } } }, "app": { diff --git a/apps/shinkai-desktop/src/App.tsx b/apps/shinkai-desktop/src/App.tsx index a1b46b3d5..13df264f2 100644 --- a/apps/shinkai-desktop/src/App.tsx +++ b/apps/shinkai-desktop/src/App.tsx @@ -7,6 +7,7 @@ import { ErrorBoundary } from 'react-error-boundary'; import { BrowserRouter as Router } from 'react-router-dom'; import FullPageErrorFallback from './components/error-boundary'; +import { OAuthConnect } from './components/oauth/oauth-connect'; import { AnalyticsProvider } from './lib/posthog-provider'; import AppRoutes from './routes'; import { useSyncStorageSecondary } from './store/sync-utils'; @@ -21,6 +22,7 @@ function App() { + diff --git a/apps/shinkai-desktop/src/components/chat/components/message.tsx b/apps/shinkai-desktop/src/components/chat/components/message.tsx index 35faf6213..7adf1d42c 100644 --- a/apps/shinkai-desktop/src/components/chat/components/message.tsx +++ b/apps/shinkai-desktop/src/components/chat/components/message.tsx @@ -37,12 +37,21 @@ import { formatText } from '@shinkai_network/shinkai-ui/helpers'; import { cn } from '@shinkai_network/shinkai-ui/utils'; import { format } from 'date-fns'; import { AnimatePresence, motion } from 'framer-motion'; -import { Edit3, InfoIcon, Loader2, RotateCcw, XCircle } from 'lucide-react'; +import { + Edit3, + InfoIcon, + Loader2, + RotateCcw, + Unplug, + XCircle, +} from 'lucide-react'; import React, { Fragment, memo, useEffect, useMemo, useState } from 'react'; import { useForm } from 'react-hook-form'; import { Link } from 'react-router-dom'; import { z } from 'zod'; +import { useOAuth } from '../../../store/oauth'; +import { oauthUrlMatcherFromErrorMessage } from '../../../utils/oauth'; import { useChatStore } from '../context/chat-context'; export const extractErrorPropertyOrContent = ( @@ -196,6 +205,12 @@ export const MessageBase = ({ return null; }, [message.content]); + const oauthUrl = useMemo(() => { + return oauthUrlMatcherFromErrorMessage(message.content); + }, [message.content]); + + const { setOauthModalVisible } = useOAuth(); + return ( )} {pythonCode && } + + {oauthUrl && ( +
+

+

+ + {t('oauth.connectionRequired')} +
+

+

+ {t('oauth.connectionRequiredDescription', { + provider: new URL(oauthUrl).hostname, + })} +

+ +
+ )} + {message.role === 'user' && !!message.attachments.length && ( = { + 'github.com': { + name: 'GitHub', + image: + 'https://github.githubassets.com/images/modules/logos_page/GitHub-Mark.png', + }, + // Here we can customize more known providers +}; + +export const OAuthConnect = () => { + const CLOSE_TIMEOUT_SECONDS = 10; + const { t } = useTranslation(); + const { oauthModalVisible, url, setOauthModalVisible } = useOAuth(); + const [connectDone, setConnectDone] = React.useState(false); + const [oauthData, setoauthData] = React.useState< + | { + domain: string; + state: string; + providerData: ProviderData; + } + | undefined + >(undefined); + + useOAuthSuccess((payload) => { + console.log('oauth success', payload); + if (payload.state === oauthData?.state) { + setConnectDone(true); + setTimeout(() => { + setOauthModalVisible({ visible: false }); + }, CLOSE_TIMEOUT_SECONDS * 1000); + } + }); + + React.useEffect(() => { + if (url) { + const urlParams = new URLSearchParams(new URL(url).search); + const state = urlParams.get('state'); + console.log('Extracted state:', state); + if (state) { + console.log('Setting OAuth data with state and code.'); + const domain = new URL(url).hostname; + setoauthData({ + domain: new URL(url).hostname, + state, + providerData: providers[domain] ?? { + image: '', + name: domain, + }, + }); + } else { + console.warn('State is missing in the URL parameters.'); + } + } + }, [url]); + + const [countdown, setCountdown] = React.useState(CLOSE_TIMEOUT_SECONDS); + React.useEffect(() => { + if (connectDone) { + const interval = setInterval(() => { + setCountdown((prev) => { + if (prev <= 1) { + clearInterval(interval); + return 0; + } + return prev - 1; + }); + }, 1000); + return () => clearInterval(interval); + } + }, [connectDone]); + + React.useEffect(() => { + if (!oauthModalVisible) { + setConnectDone(false); + setOauthModalVisible({ visible: false }); + setoauthData(undefined); + setCountdown(CLOSE_TIMEOUT_SECONDS); + } + }, [oauthModalVisible, setOauthModalVisible]); + + return ( + + + +
+ {oauthData?.providerData?.image && ( + {`${oauthData?.providerData?.name} + )} + + {t('oauth.title', { provider: oauthData?.providerData?.name })} + +
+ + {connectDone ? ( +
+
+ + {t('oauth.success')} +
+ + {t('oauth.successDescription', { countdown })} + +
+ ) : ( + + )} +
+
+
+ {!connectDone && ( +
+
+ +
{' '} + + {t('oauth.processing')} + +
+ )} +
+
+
+ +
+
+
+
+ ); +}; diff --git a/apps/shinkai-desktop/src/hooks/oauth.ts b/apps/shinkai-desktop/src/hooks/oauth.ts new file mode 100644 index 000000000..2648c8f8d --- /dev/null +++ b/apps/shinkai-desktop/src/hooks/oauth.ts @@ -0,0 +1,48 @@ +import { useSetOAuthToken } from '@shinkai_network/shinkai-node-state/v2/mutations/setOAuthToken/index'; +import { emit, listen } from '@tauri-apps/api/event'; +import { useEffect } from 'react'; + +import { useAuth } from '../store/auth'; + +export const useOAuthDeepLinkSet = () => { + const { mutateAsync: setOAuthToken } = useSetOAuthToken({ + onSuccess: (data) => { + console.log('oauth-success', data); + emit('oauth-success', { state: data.state, code: data.code }); + }, + }); + const auth = useAuth((s) => s.auth); + + useEffect(() => { + const unlisten = listen('oauth-deep-link', (event) => { + if (!auth) return; + + const payload = event.payload as { state: string; code: string }; + setOAuthToken({ + state: payload.state, + code: payload.code, + nodeAddress: auth.node_address ?? '', + token: auth.api_v2_key ?? '', + }); + }); + + return () => { + unlisten.then((fn) => fn()); + }; + }, [setOAuthToken, auth]); +}; + +export const useOAuthSuccess = ( + callback: (payload: { state: string; code: string }) => void, +) => { + useEffect(() => { + const unlisten = listen('oauth-success', (event) => { + const payload = event.payload as { state: string; code: string }; + callback(payload); + }); + + return () => { + unlisten.then((fn) => fn()); + }; + }, [callback]); +}; diff --git a/apps/shinkai-desktop/src/store/oauth.ts b/apps/shinkai-desktop/src/store/oauth.ts new file mode 100644 index 000000000..78ecfdecf --- /dev/null +++ b/apps/shinkai-desktop/src/store/oauth.ts @@ -0,0 +1,41 @@ +import { create } from 'zustand'; +import { devtools } from 'zustand/middleware'; + +type OAuthStore = { + oauthModalVisible: boolean; + url?: string; + setOauthModalVisible: ( + options: + | { + visible: true; + url: string; + } + | { visible: false }, + ) => void; +}; + +export const useOAuth = create()( + devtools( + (set) => ({ + oauthModalVisible: false, + provider: 'github', + url: undefined, + setOauthModalVisible: (options) => { + if (options.visible) { + set({ + oauthModalVisible: true, + url: options.url, + }); + } else { + set({ + oauthModalVisible: false, + url: undefined, + }); + } + }, + }), + { + name: 'oauth', + }, + ), +); diff --git a/apps/shinkai-desktop/src/utils/oauth.ts b/apps/shinkai-desktop/src/utils/oauth.ts new file mode 100644 index 000000000..3b67ab13c --- /dev/null +++ b/apps/shinkai-desktop/src/utils/oauth.ts @@ -0,0 +1,6 @@ +export const oauthUrlMatcherFromErrorMessage = (errorMessage: string) => { + const match = errorMessage?.match( + /Execution error: OAuth not setup: (https:\/\/.*)/, + ); + return match ? match[1] : undefined; +}; diff --git a/apps/shinkai-desktop/src/windows/coordinator/main.tsx b/apps/shinkai-desktop/src/windows/coordinator/main.tsx index fe2886a7e..100193bdd 100644 --- a/apps/shinkai-desktop/src/windows/coordinator/main.tsx +++ b/apps/shinkai-desktop/src/windows/coordinator/main.tsx @@ -1,7 +1,10 @@ +import { QueryClientProvider } from '@tanstack/react-query'; import { info } from '@tauri-apps/plugin-log'; import React, { useEffect } from 'react'; import ReactDOM from 'react-dom/client'; +import { useOAuthDeepLinkSet } from '../../hooks/oauth'; +import { shinkaiNodeQueryClient } from '../../lib/shinkai-node-manager/shinkai-node-manager-client'; import { useSyncStorageMain, useSyncStorageSecondary, @@ -15,11 +18,15 @@ const App = () => { useSyncStorageMain(); useSyncStorageSecondary(); useSyncStorageSideEffects(); + useOAuthDeepLinkSet(); + return null; }; ReactDOM.createRoot(document.querySelector('#root') as HTMLElement).render( - + + + , ); diff --git a/libs/shinkai-i18n/locales/en-US.json b/libs/shinkai-i18n/locales/en-US.json index 94aed6223..274fcd521 100644 --- a/libs/shinkai-i18n/locales/en-US.json +++ b/libs/shinkai-i18n/locales/en-US.json @@ -566,5 +566,19 @@ "stdout": "Standard Output", "output": "Output", "executeCode": "Execute Code" + }, + "oauth": { + "title": "Connect to {{provider}}", + "description": "Connect to {{provider}} to use this tool", + "signIn": "Sign in with {{provider}}", + "success": "Connection successful!", + "successDescription": "This window will close automatically in {{countdown}} seconds...", + "navigateToProvider": "Navigate and follow the authentication steps to continue.", + "processing": "Processing...", + "goToProvider": "Go to {{provider}}", + "close": "Close", + "connectionRequired": "Connection Required", + "connectionRequiredDescription": "To use this tool, please connect your {{provider}} account.", + "connectNow": "Connect Now" } } \ No newline at end of file diff --git a/libs/shinkai-i18n/locales/es-ES.json b/libs/shinkai-i18n/locales/es-ES.json index 84e353971..1654c7ece 100644 --- a/libs/shinkai-i18n/locales/es-ES.json +++ b/libs/shinkai-i18n/locales/es-ES.json @@ -1,4 +1,6 @@ { + "": { + }, "aiFilesSearch": { "description": "Busca para encontrar contenido en todos los archivos de tus archivos AI fácilmente", "filesSelected": "Seleccionados {{count}} archivos", @@ -277,8 +279,21 @@ "label": "Mensaje Recibido" } }, + "oauth": { + "close": "Cerrar", + "connectNow": "Conectar Ahora", + "connectionRequired": "Conexión Requerida", + "connectionRequiredDescription": "Para usar esta herramienta, por favor conecta tu cuenta de {{provider}}.", + "description": "Conéctate a {{provider}} para usar esta herramienta", + "goToProvider": "Ir a {{provider}}", + "navigateToProvider": "Navega y sigue los pasos de autenticación para continuar.", + "processing": "Procesando...", + "signIn": "Iniciar sesión con {{provider}}", + "success": "¡Conexión exitosa!", + "successDescription": "Esta ventana se cerrará automáticamente en {{countdown}} segundos...", + "title": "Conectar a {{provider}}" + }, "ollama": { - "version": "Versión de Ollama", "errors": { "failedToFetch": "Error al obtener modelos locales de Ollama. Por favor, asegúrate de que Ollama esté funcionando correctamente." }, diff --git a/libs/shinkai-i18n/locales/id-ID.json b/libs/shinkai-i18n/locales/id-ID.json index 4c573fdfd..6226d49fd 100644 --- a/libs/shinkai-i18n/locales/id-ID.json +++ b/libs/shinkai-i18n/locales/id-ID.json @@ -277,8 +277,21 @@ "label": "Pesan Diterima" } }, + "oauth": { + "close": "Tutup", + "connectNow": "Sambungkan Sekarang", + "connectionRequired": "Koneksi Diperlukan", + "connectionRequiredDescription": "Untuk menggunakan alat ini, silakan sambungkan akun {{provider}} Anda.", + "description": "Sambungkan ke {{provider}} untuk menggunakan alat ini", + "goToProvider": "Pergi ke {{provider}}", + "navigateToProvider": "Navigasikan dan ikuti langkah-langkah otentikasi untuk melanjutkan.", + "processing": "Memproses...", + "signIn": "Masuk dengan {{provider}}", + "success": "Sambungan berhasil!", + "successDescription": "Jendela ini akan ditutup secara otomatis dalam {{countdown}} detik...", + "title": "Sambungkan ke {{provider}}" + }, "ollama": { - "version": "Versi Ollama", "errors": { "failedToFetch": "Gagal mengambil model Ollama lokal. Pastikan Ollama berjalan dengan benar." }, @@ -568,4 +581,4 @@ "folderUnshared": "Folder berhasil tidak dibagikan" } } -} +} \ No newline at end of file diff --git a/libs/shinkai-i18n/locales/ja-JP.json b/libs/shinkai-i18n/locales/ja-JP.json index 07c8f8244..537c7a8c7 100644 --- a/libs/shinkai-i18n/locales/ja-JP.json +++ b/libs/shinkai-i18n/locales/ja-JP.json @@ -277,8 +277,21 @@ "label": "メッセージを受信しました" } }, + "oauth": { + "close": "閉じる", + "connectNow": "今すぐ接続", + "connectionRequired": "接続が必要です", + "connectionRequiredDescription": "このツールを使用するには、{{provider}}アカウントに接続してください。", + "description": "このツールを使用するために{{provider}}に接続します", + "goToProvider": "{{provider}}に移動", + "navigateToProvider": "認証手順に従って進んでください。", + "processing": "処理中...", + "signIn": "{{provider}}でサインイン", + "success": "接続に成功しました!", + "successDescription": "{{countdown}}秒後にこのウィンドウは自動的に閉じます...", + "title": "{{provider}}に接続" + }, "ollama": { - "version": "Ollamaバージョン", "errors": { "failedToFetch": "ローカルのOllamaモデルの取得に失敗しました。Ollamaが正常に動作していることを確認してください。" }, @@ -568,4 +581,4 @@ "folderUnshared": "フォルダが正常に共有解除されました" } } -} +} \ No newline at end of file diff --git a/libs/shinkai-i18n/locales/tr-TR.json b/libs/shinkai-i18n/locales/tr-TR.json index 0d84e4a4f..4c5ee03ae 100644 --- a/libs/shinkai-i18n/locales/tr-TR.json +++ b/libs/shinkai-i18n/locales/tr-TR.json @@ -277,6 +277,20 @@ "label": "Mesaj Alındı" } }, + "oauth": { + "close": "Kapat", + "connectNow": "Şimdi Bağlan", + "connectionRequired": "Bağlantı Gerekli", + "connectionRequiredDescription": "Bu aracı kullanmak için lütfen {{provider}} hesabınıza bağlanın.", + "description": "{{provider}} ile bu aracı kullanmak için bağlanın", + "goToProvider": "{{provider}}'ye Git", + "navigateToProvider": "Devam etmek için kimlik doğrulama adımlarını izlemek üzere gidin.", + "processing": "İşleniyor...", + "signIn": "{{provider}} ile Giriş Yap", + "success": "Bağlantı başarılı!", + "successDescription": "{{countdown}} saniye içinde bu pencere otomatik olarak kapanacaktır...", + "title": "{{provider}} ile Bağlan" + }, "ollama": { "errors": { "failedToFetch": "Yerel Ollama modelleri alınamadı. Lütfen Ollama'nın doğru çalıştığından emin olun." @@ -567,4 +581,4 @@ "folderUnshared": "Klasörün paylaşımı başarıyla kaldırıldı" } } -} +} \ No newline at end of file diff --git a/libs/shinkai-i18n/locales/zh-CN.json b/libs/shinkai-i18n/locales/zh-CN.json index 8c08cc943..0d6d26874 100644 --- a/libs/shinkai-i18n/locales/zh-CN.json +++ b/libs/shinkai-i18n/locales/zh-CN.json @@ -277,8 +277,21 @@ "label": "已收到消息" } }, + "oauth": { + "close": "关闭", + "connectNow": "立即连接", + "connectionRequired": "需要连接", + "connectionRequiredDescription": "要使用此工具,请连接您的 {{provider}} 账户。", + "description": "连接到 {{provider}} 以使用此工具", + "goToProvider": "前往 {{provider}}", + "navigateToProvider": "请导航并按照认证步骤继续。", + "processing": "处理中...", + "signIn": "使用 {{provider}} 登录", + "success": "连接成功!", + "successDescription": "此窗口将在 {{countdown}} 秒后自动关闭...", + "title": "连接到 {{provider}}" + }, "ollama": { - "version": "Ollama 版本", "errors": { "failedToFetch": "无法获取本地Ollama模型。请确保Ollama正常运行。" }, @@ -568,4 +581,4 @@ "folderUnshared": "文件夹取消分享成功" } } -} +} \ No newline at end of file diff --git a/libs/shinkai-i18n/src/lib/default/index.ts b/libs/shinkai-i18n/src/lib/default/index.ts index 161d4b35b..3a6ede5aa 100644 --- a/libs/shinkai-i18n/src/lib/default/index.ts +++ b/libs/shinkai-i18n/src/lib/default/index.ts @@ -619,4 +619,18 @@ export default { output: 'Output', executeCode: 'Execute Code', }, + oauth: { + title: 'Connect to {{provider}}', + description: 'Connect to {{provider}} to use this tool', + signIn: 'Sign in with {{provider}}', + success: 'Connection successful!', + successDescription: 'This window will close automatically in {{countdown}} seconds...', + navigateToProvider: 'Navigate and follow the authentication steps to continue.', + processing: 'Processing...', + goToProvider: 'Go to {{provider}}', + close: 'Close', + connectionRequired: 'Connection Required', + connectionRequiredDescription: 'To use this tool, please connect your {{provider}} account.', + connectNow: 'Connect Now', + }, }; diff --git a/libs/shinkai-message-ts/src/api/tools/index.ts b/libs/shinkai-message-ts/src/api/tools/index.ts index e2a8841ff..120bf7768 100644 --- a/libs/shinkai-message-ts/src/api/tools/index.ts +++ b/libs/shinkai-message-ts/src/api/tools/index.ts @@ -32,6 +32,8 @@ import { SaveToolCodeRequest, SaveToolCodeResponse, SearchPromptsResponse, + SetOAuthTokenRequest, + SetOAuthTokenResponse, UndoToolImplementationRequest, UndoToolImplementationResponse, UpdatePromptRequest, @@ -284,6 +286,7 @@ export const saveToolCode = async ( ); return response.data as SaveToolCodeResponse; }; + export const getPlaygroundTools = async ( nodeAddress: string, bearerToken: string, @@ -408,6 +411,22 @@ export const getShinkaiFileProtocol = async ( }, ); return response.data as GetShinkaiFileProtocolResponse; +} + +export const setOAuthToken = async ( + nodeAddress: string, + bearerToken: string, + payload: SetOAuthTokenRequest, +): Promise => { + const response = await httpClient.post( + urlJoin(nodeAddress, '/v2/set_oauth_token'), + payload, + { + headers: { Authorization: `Bearer ${bearerToken}` }, + responseType: 'json', + }, + ); + return response.data as SetOAuthTokenResponse; }; export const getAllToolAssets = async ( diff --git a/libs/shinkai-message-ts/src/api/tools/types.ts b/libs/shinkai-message-ts/src/api/tools/types.ts index be332505c..49d0e8e5c 100644 --- a/libs/shinkai-message-ts/src/api/tools/types.ts +++ b/libs/shinkai-message-ts/src/api/tools/types.ts @@ -334,3 +334,12 @@ export type AddToolRequestResponse = { export type RemoveToolRequestRequest = { filename: string; }; +export type SetOAuthTokenRequest = { + code: string; + state: string; +}; + +export type SetOAuthTokenResponse = { + message: string; + status: string; +}; diff --git a/libs/shinkai-node-state/src/v2/mutations/setOAuthToken/index.ts b/libs/shinkai-node-state/src/v2/mutations/setOAuthToken/index.ts new file mode 100644 index 000000000..97ea74c7a --- /dev/null +++ b/libs/shinkai-node-state/src/v2/mutations/setOAuthToken/index.ts @@ -0,0 +1,36 @@ +import { setOAuthToken } from '@shinkai_network/shinkai-message-ts/api/tools/index'; +import { useMutation, UseMutationOptions } from '@tanstack/react-query'; + +import { APIError } from '../../types'; + +export type SetOAuthTokenInput = { + nodeAddress: string; + token: string; + state: string; + code: string; +}; + +export type SetOAuthTokenOutput = { + state: string; + code: string; +}; + +type Options = UseMutationOptions< + SetOAuthTokenOutput, + APIError, + SetOAuthTokenInput +>; + +export const useSetOAuthToken = (options?: Options) => { + return useMutation({ + mutationFn: async (variables) => { + const { nodeAddress, token, state, code } = variables; + await setOAuthToken(nodeAddress, token, { + code, + state, + }); + return { code, state }; + }, + ...options, + }); +}; diff --git a/package-lock.json b/package-lock.json index 4912f3767..2872f648c 100644 --- a/package-lock.json +++ b/package-lock.json @@ -50,14 +50,14 @@ "@tanstack/react-query-devtools": "^5.40.0", "@tanstack/react-table": "^8.20.1", "@tanstack/react-virtual": "^3.8.4", - "@tauri-apps/api": "^2.0.2", - "@tauri-apps/plugin-dialog": "^2.0.0", - "@tauri-apps/plugin-fs": "^2.0.0", - "@tauri-apps/plugin-log": "^2.0.0", - "@tauri-apps/plugin-notification": "^2.0.0", - "@tauri-apps/plugin-os": "^2.0.0", - "@tauri-apps/plugin-process": "^2.0.0", - "@tauri-apps/plugin-updater": "^2.0.0", + "@tauri-apps/api": "^2.1.1", + "@tauri-apps/plugin-dialog": "^2.2.0", + "@tauri-apps/plugin-fs": "^2.2.0", + "@tauri-apps/plugin-log": "^2.2.0", + "@tauri-apps/plugin-notification": "^2.2.0", + "@tauri-apps/plugin-os": "^2.2.0", + "@tauri-apps/plugin-process": "^2.2.0", + "@tauri-apps/plugin-updater": "^2.3.0", "@types/babel__standalone": "^7.1.7", "@uidotdev/usehooks": "^2.4.1", "@uiw/react-json-view": "^2.0.0-alpha.30", @@ -151,7 +151,7 @@ "@swc/core": "~1.5.7", "@swc/helpers": "~0.5.11", "@tailwindcss/typography": "^0.5.13", - "@tauri-apps/cli": "^2.0.3", + "@tauri-apps/cli": "^2.1.0", "@testing-library/jest-dom": "^6.4.5", "@testing-library/react": "15.0.7", "@testing-library/user-event": "^14.5.2", @@ -9203,9 +9203,9 @@ } }, "node_modules/@tauri-apps/api": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/@tauri-apps/api/-/api-2.0.2.tgz", - "integrity": "sha512-3wSwmG+1kr6WrgAFKK5ijkNFPp8TT3FLj3YHUb5EwMO+3FxX4uWlfSWkeeBy+Kc1RsKzugtYLuuya+98Flj+3w==", + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/@tauri-apps/api/-/api-2.1.1.tgz", + "integrity": "sha512-fzUfFFKo4lknXGJq8qrCidkUcKcH2UHhfaaCNt4GzgzGaW2iS26uFOg4tS3H4P8D6ZEeUxtiD5z0nwFF0UN30A==", "license": "Apache-2.0 OR MIT", "funding": { "type": "opencollective", @@ -9213,9 +9213,9 @@ } }, "node_modules/@tauri-apps/cli": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/@tauri-apps/cli/-/cli-2.0.3.tgz", - "integrity": "sha512-JwEyhc5BAVpn4E8kxzY/h7+bVOiXQdudR1r3ODMfyyumZBfgIWqpD/WuTcPq6Yjchju1BSS+80jAE/oYwI/RKg==", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/@tauri-apps/cli/-/cli-2.1.0.tgz", + "integrity": "sha512-K2VhcKqBhAeS5pNOVdnR/xQRU6jwpgmkSL2ejHXcl0m+kaTggT0WRDQnFtPq6NljA7aE03cvwsbCAoFG7vtkJw==", "dev": true, "license": "Apache-2.0 OR MIT", "bin": { @@ -9229,22 +9229,22 @@ "url": "https://opencollective.com/tauri" }, "optionalDependencies": { - "@tauri-apps/cli-darwin-arm64": "2.0.3", - "@tauri-apps/cli-darwin-x64": "2.0.3", - "@tauri-apps/cli-linux-arm-gnueabihf": "2.0.3", - "@tauri-apps/cli-linux-arm64-gnu": "2.0.3", - "@tauri-apps/cli-linux-arm64-musl": "2.0.3", - "@tauri-apps/cli-linux-x64-gnu": "2.0.3", - "@tauri-apps/cli-linux-x64-musl": "2.0.3", - "@tauri-apps/cli-win32-arm64-msvc": "2.0.3", - "@tauri-apps/cli-win32-ia32-msvc": "2.0.3", - "@tauri-apps/cli-win32-x64-msvc": "2.0.3" + "@tauri-apps/cli-darwin-arm64": "2.1.0", + "@tauri-apps/cli-darwin-x64": "2.1.0", + "@tauri-apps/cli-linux-arm-gnueabihf": "2.1.0", + "@tauri-apps/cli-linux-arm64-gnu": "2.1.0", + "@tauri-apps/cli-linux-arm64-musl": "2.1.0", + "@tauri-apps/cli-linux-x64-gnu": "2.1.0", + "@tauri-apps/cli-linux-x64-musl": "2.1.0", + "@tauri-apps/cli-win32-arm64-msvc": "2.1.0", + "@tauri-apps/cli-win32-ia32-msvc": "2.1.0", + "@tauri-apps/cli-win32-x64-msvc": "2.1.0" } }, "node_modules/@tauri-apps/cli-darwin-arm64": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/@tauri-apps/cli-darwin-arm64/-/cli-darwin-arm64-2.0.3.tgz", - "integrity": "sha512-jIsbxGWS+As1ZN7umo90nkql/ZAbrDK0GBT6UsgHSz5zSwwArICsZFFwE1pLZip5yoiV5mn3TGG2c1+v+0puzQ==", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/@tauri-apps/cli-darwin-arm64/-/cli-darwin-arm64-2.1.0.tgz", + "integrity": "sha512-ESc6J6CE8hl1yKH2vJ+ALF+thq4Be+DM1mvmTyUCQObvezNCNhzfS6abIUd3ou4x5RGH51ouiANeT3wekU6dCw==", "cpu": [ "arm64" ], @@ -9259,9 +9259,9 @@ } }, "node_modules/@tauri-apps/cli-darwin-x64": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/@tauri-apps/cli-darwin-x64/-/cli-darwin-x64-2.0.3.tgz", - "integrity": "sha512-ROITHtLTA1muyrwgyuwyasmaLCGtT4as/Kd1kerXaSDtFcYrnxiM984ZD0+FDUEDl5BgXtYa/sKKkKQFjgmM0A==", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/@tauri-apps/cli-darwin-x64/-/cli-darwin-x64-2.1.0.tgz", + "integrity": "sha512-TasHS442DFs8cSH2eUQzuDBXUST4ECjCd0yyP+zZzvAruiB0Bg+c8A+I/EnqCvBQ2G2yvWLYG8q/LI7c87A5UA==", "cpu": [ "x64" ], @@ -9276,9 +9276,9 @@ } }, "node_modules/@tauri-apps/cli-linux-arm-gnueabihf": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/@tauri-apps/cli-linux-arm-gnueabihf/-/cli-linux-arm-gnueabihf-2.0.3.tgz", - "integrity": "sha512-bQ3EZwCFfrLg/ZQ2I8sLuifSxESz4TP56SleTkKsPtTIZgNnKpM88PRDz4neiRroHVOq8NK0X276qi9LjGcXPw==", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/@tauri-apps/cli-linux-arm-gnueabihf/-/cli-linux-arm-gnueabihf-2.1.0.tgz", + "integrity": "sha512-aP7ZBGNL4ny07Cbb6kKpUOSrmhcIK2KhjviTzYlh+pPhAptxnC78xQGD3zKQkTi2WliJLPmBYbOHWWQa57lQ9w==", "cpu": [ "arm" ], @@ -9293,9 +9293,9 @@ } }, "node_modules/@tauri-apps/cli-linux-arm64-gnu": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/@tauri-apps/cli-linux-arm64-gnu/-/cli-linux-arm64-gnu-2.0.3.tgz", - "integrity": "sha512-aLfAA8P9OTErVUk3sATxtXqpAtlfDPMPp4fGjDysEELG/MyekGhmh2k/kG/i32OdPeCfO+Nr37wJksARJKubGw==", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/@tauri-apps/cli-linux-arm64-gnu/-/cli-linux-arm64-gnu-2.1.0.tgz", + "integrity": "sha512-ZTdgD5gLeMCzndMT2f358EkoYkZ5T+Qy6zPzU+l5vv5M7dHVN9ZmblNAYYXmoOuw7y+BY4X/rZvHV9pcGrcanQ==", "cpu": [ "arm64" ], @@ -9310,9 +9310,9 @@ } }, "node_modules/@tauri-apps/cli-linux-arm64-musl": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/@tauri-apps/cli-linux-arm64-musl/-/cli-linux-arm64-musl-2.0.3.tgz", - "integrity": "sha512-I4MVD7nf6lLLRmNQPpe5beEIFM6q7Zkmh77ROA5BNu/+vHNL5kiTMD+bmd10ZL2r753A6pO7AvqkIxcBuIl0tg==", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/@tauri-apps/cli-linux-arm64-musl/-/cli-linux-arm64-musl-2.1.0.tgz", + "integrity": "sha512-NzwqjUCilhnhJzusz3d/0i0F1GFrwCQbkwR6yAHUxItESbsGYkZRJk0yMEWkg3PzFnyK4cWTlQJMEU52TjhEzA==", "cpu": [ "arm64" ], @@ -9327,9 +9327,9 @@ } }, "node_modules/@tauri-apps/cli-linux-x64-gnu": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/@tauri-apps/cli-linux-x64-gnu/-/cli-linux-x64-gnu-2.0.3.tgz", - "integrity": "sha512-C6Jkx2zZGKkoi+sg5FK9GoH/0EvAaOgrZfF5azV5EALGba46g7VpWcZgp9zFUd7K2IzTi+0OOY8TQ2OVfKZgew==", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/@tauri-apps/cli-linux-x64-gnu/-/cli-linux-x64-gnu-2.1.0.tgz", + "integrity": "sha512-TyiIpMEtZxNOQmuFyfJwaaYbg3movSthpBJLIdPlKxSAB2BW0VWLY3/ZfIxm/G2YGHyREkjJvimzYE0i37PnMA==", "cpu": [ "x64" ], @@ -9344,9 +9344,9 @@ } }, "node_modules/@tauri-apps/cli-linux-x64-musl": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/@tauri-apps/cli-linux-x64-musl/-/cli-linux-x64-musl-2.0.3.tgz", - "integrity": "sha512-qi4ghmTfSAl+EEUDwmwI9AJUiOLNSmU1RgiGgcPRE+7A/W+Am9UnxYySAiRbB/gJgTl9sj/pqH5Y9duP1/sqHg==", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/@tauri-apps/cli-linux-x64-musl/-/cli-linux-x64-musl-2.1.0.tgz", + "integrity": "sha512-/dQd0TlaxBdJACrR72DhynWftzHDaX32eBtS5WBrNJ+nnNb+znM3gON6nJ9tSE9jgDa6n1v2BkI/oIDtypfUXw==", "cpu": [ "x64" ], @@ -9361,9 +9361,9 @@ } }, "node_modules/@tauri-apps/cli-win32-arm64-msvc": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/@tauri-apps/cli-win32-arm64-msvc/-/cli-win32-arm64-msvc-2.0.3.tgz", - "integrity": "sha512-UXxHkYmFesC97qVmZre4vY7oDxRDtC2OeKNv0bH+iSnuUp/ROxzJYGyaelnv9Ybvgl4YVqDCnxgB28qMM938TA==", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/@tauri-apps/cli-win32-arm64-msvc/-/cli-win32-arm64-msvc-2.1.0.tgz", + "integrity": "sha512-NdQJO7SmdYqOcE+JPU7bwg7+odfZMWO6g8xF9SXYCMdUzvM2Gv/AQfikNXz5yS7ralRhNFuW32i5dcHlxh4pDg==", "cpu": [ "arm64" ], @@ -9378,9 +9378,9 @@ } }, "node_modules/@tauri-apps/cli-win32-ia32-msvc": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/@tauri-apps/cli-win32-ia32-msvc/-/cli-win32-ia32-msvc-2.0.3.tgz", - "integrity": "sha512-D+xoaa35RGlkXDpnL5uDTpj29untuC5Wp6bN9snfgFDagD0wnFfC8+2ZQGu16bD0IteWqDI0OSoIXhNvy+F+wg==", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/@tauri-apps/cli-win32-ia32-msvc/-/cli-win32-ia32-msvc-2.1.0.tgz", + "integrity": "sha512-f5h8gKT/cB8s1ticFRUpNmHqkmaLutT62oFDB7N//2YTXnxst7EpMIn1w+QimxTvTk2gcx6EcW6bEk/y2hZGzg==", "cpu": [ "ia32" ], @@ -9395,9 +9395,9 @@ } }, "node_modules/@tauri-apps/cli-win32-x64-msvc": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/@tauri-apps/cli-win32-x64-msvc/-/cli-win32-x64-msvc-2.0.3.tgz", - "integrity": "sha512-eWV9XWb4dSYHXl13OtYWLjX1JHphUEkHkkGwJrhr8qFBm7RbxXxQvrsUEprSi51ug/dwJenjJgM4zR8By4htfw==", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/@tauri-apps/cli-win32-x64-msvc/-/cli-win32-x64-msvc-2.1.0.tgz", + "integrity": "sha512-P/+LrdSSb5Xbho1LRP4haBjFHdyPdjWvGgeopL96OVtrFpYnfC+RctB45z2V2XxqFk3HweDDxk266btjttfjGw==", "cpu": [ "x64" ], @@ -9412,63 +9412,63 @@ } }, "node_modules/@tauri-apps/plugin-dialog": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@tauri-apps/plugin-dialog/-/plugin-dialog-2.0.0.tgz", - "integrity": "sha512-ApNkejXP2jpPBSifznPPcHTXxu9/YaRW+eJ+8+nYwqp0lLUtebFHG4QhxitM43wwReHE81WAV1DQ/b+2VBftOA==", + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/@tauri-apps/plugin-dialog/-/plugin-dialog-2.2.0.tgz", + "integrity": "sha512-6bLkYK68zyK31418AK5fNccCdVuRnNpbxquCl8IqgFByOgWFivbiIlvb79wpSXi0O+8k8RCSsIpOquebusRVSg==", "license": "MIT OR Apache-2.0", "dependencies": { "@tauri-apps/api": "^2.0.0" } }, "node_modules/@tauri-apps/plugin-fs": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@tauri-apps/plugin-fs/-/plugin-fs-2.0.0.tgz", - "integrity": "sha512-BNEeQQ5aH8J5SwYuWgRszVyItsmquRuzK2QRkVj8Z0sCsLnSvJFYI3JHRzzr3ltZGq1nMPtblrlZzuKqVzRawA==", + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/@tauri-apps/plugin-fs/-/plugin-fs-2.2.0.tgz", + "integrity": "sha512-+08mApuONKI8/sCNEZ6AR8vf5vI9DXD4YfrQ9NQmhRxYKMLVhRW164vdW5BSLmMpuevftpQ2FVoL9EFkfG9Z+g==", "license": "MIT OR Apache-2.0", "dependencies": { "@tauri-apps/api": "^2.0.0" } }, "node_modules/@tauri-apps/plugin-log": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@tauri-apps/plugin-log/-/plugin-log-2.0.0.tgz", - "integrity": "sha512-C+NII9vzswqnOQE8k7oRtnaw0z5TZsMmnirRhXkCKDEhQQH9841Us/PC1WHtGiAaJ8za1A1JB2xXndEq/47X/w==", + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/@tauri-apps/plugin-log/-/plugin-log-2.2.0.tgz", + "integrity": "sha512-g6CsQAR1lsm5ABSZZxpM/iCn86GrMDTTlhj7GPkZkYBRSm3+WczfOAl7SV7HDn77tOKCzhZffwI5uHfRoHutrw==", "license": "MIT OR Apache-2.0", "dependencies": { "@tauri-apps/api": "^2.0.0" } }, "node_modules/@tauri-apps/plugin-notification": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@tauri-apps/plugin-notification/-/plugin-notification-2.0.0.tgz", - "integrity": "sha512-6qEDYJS7mgXZWLXA0EFL+DVCJh8sJlzSoyw6B50pxhLPVFjc5Vr5DVzl5W3mUHaYhod5wsC984eQnlCCGqxYDA==", + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/@tauri-apps/plugin-notification/-/plugin-notification-2.2.0.tgz", + "integrity": "sha512-uhE3a2gFlqwiWhY/JbhXOF13K4iILEYxUk0D2Y+q69HP6tnfPqKCuNTHxDM0H+oFAakXESNmJVnYw0Vi4IrMMQ==", "license": "MIT OR Apache-2.0", "dependencies": { "@tauri-apps/api": "^2.0.0" } }, "node_modules/@tauri-apps/plugin-os": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@tauri-apps/plugin-os/-/plugin-os-2.0.0.tgz", - "integrity": "sha512-M7hG/nNyQYTJxVG/UhTKhp9mpXriwWzrs9mqDreB8mIgqA3ek5nHLdwRZJWhkKjZrnDT4v9CpA9BhYeplTlAiA==", + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/@tauri-apps/plugin-os/-/plugin-os-2.2.0.tgz", + "integrity": "sha512-HszbCdbisMlu5QhCNAN8YIWyz2v33abAWha6+uvV2CKX8P5VSct/y+kEe22JeyqrxCnWlQ3DRx7s49Byg7/0EA==", "license": "MIT OR Apache-2.0", "dependencies": { "@tauri-apps/api": "^2.0.0" } }, "node_modules/@tauri-apps/plugin-process": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@tauri-apps/plugin-process/-/plugin-process-2.0.0.tgz", - "integrity": "sha512-OYzi0GnkrF4NAnsHZU7U3tjSoP0PbeAlO7T1Z+vJoBUH9sFQ1NSLqWYWQyf8hcb3gVWe7P1JggjiskO+LST1ug==", + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/@tauri-apps/plugin-process/-/plugin-process-2.2.0.tgz", + "integrity": "sha512-uypN2Crmyop9z+KRJr3zl71OyVFgTuvHFjsJ0UxxQ/J5212jVa5w4nPEYjIewcn8bUEXacRebwE6F7owgrbhSw==", "license": "MIT OR Apache-2.0", "dependencies": { "@tauri-apps/api": "^2.0.0" } }, "node_modules/@tauri-apps/plugin-updater": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@tauri-apps/plugin-updater/-/plugin-updater-2.0.0.tgz", - "integrity": "sha512-N0cl71g7RPr7zK2Fe5aoIwzw14NcdLcz7XMGFWZVjprsqgDRWoxbnUkknyCQMZthjhGkppCd/wN2MIsUz+eAhQ==", + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/@tauri-apps/plugin-updater/-/plugin-updater-2.3.0.tgz", + "integrity": "sha512-qdzyZEUN69FZQ/nRx51fBub10tT6wffJl3DLVo9q922Gvw8Wk++rZhoD9eethPlZYbog/7RGgT8JkrfLh5BKAg==", "license": "MIT OR Apache-2.0", "dependencies": { "@tauri-apps/api": "^2.0.0" diff --git a/package.json b/package.json index 0e6687bd9..3c1853209 100644 --- a/package.json +++ b/package.json @@ -49,14 +49,14 @@ "@tanstack/react-query-devtools": "^5.40.0", "@tanstack/react-table": "^8.20.1", "@tanstack/react-virtual": "^3.8.4", - "@tauri-apps/api": "^2.0.2", - "@tauri-apps/plugin-dialog": "^2.0.0", - "@tauri-apps/plugin-fs": "^2.0.0", - "@tauri-apps/plugin-log": "^2.0.0", - "@tauri-apps/plugin-notification": "^2.0.0", - "@tauri-apps/plugin-os": "^2.0.0", - "@tauri-apps/plugin-process": "^2.0.0", - "@tauri-apps/plugin-updater": "^2.0.0", + "@tauri-apps/api": "^2.1.1", + "@tauri-apps/plugin-dialog": "^2.2.0", + "@tauri-apps/plugin-fs": "^2.2.0", + "@tauri-apps/plugin-log": "^2.2.0", + "@tauri-apps/plugin-notification": "^2.2.0", + "@tauri-apps/plugin-os": "^2.2.0", + "@tauri-apps/plugin-process": "^2.2.0", + "@tauri-apps/plugin-updater": "^2.3.0", "@types/babel__standalone": "^7.1.7", "@uidotdev/usehooks": "^2.4.1", "@uiw/react-json-view": "^2.0.0-alpha.30", @@ -150,7 +150,7 @@ "@swc/core": "~1.5.7", "@swc/helpers": "~0.5.11", "@tailwindcss/typography": "^0.5.13", - "@tauri-apps/cli": "^2.0.3", + "@tauri-apps/cli": "^2.1.0", "@testing-library/jest-dom": "^6.4.5", "@testing-library/react": "15.0.7", "@testing-library/user-event": "^14.5.2",