fix: react-query working in production builds + fix Linux compilation issue

This commit is contained in:
Oscar Beaumont 2022-04-09 02:19:27 +08:00
parent 118a35835a
commit af9d435086
No known key found for this signature in database
GPG key ID: FEAA9F222BDFD945
15 changed files with 866 additions and 795 deletions

372
Cargo.lock generated
View file

@ -188,9 +188,9 @@ dependencies = [
[[package]]
name = "async-global-executor"
version = "2.0.3"
version = "2.0.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c026b7e44f1316b567ee750fea85103f87fcb80792b860e979f221259796ca0a"
checksum = "c290043c9a95b05d45e952fb6383c67bcb61471f60cfa21e890dba6654234f43"
dependencies = [
"async-channel",
"async-executor",
@ -251,6 +251,23 @@ dependencies = [
"url",
]
[[package]]
name = "async-process"
version = "1.3.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "83137067e3a2a6a06d67168e49e68a0957d215410473a740cea95a2425c0b7c6"
dependencies = [
"async-io",
"blocking",
"cfg-if 1.0.0",
"event-listener",
"futures-lite",
"libc",
"once_cell",
"signal-hook",
"winapi 0.3.9",
]
[[package]]
name = "async-recursion"
version = "0.3.2"
@ -272,6 +289,7 @@ dependencies = [
"async-global-executor",
"async-io",
"async-lock",
"async-process",
"crossbeam-utils 0.8.8",
"futures-channel",
"futures-core",
@ -291,16 +309,17 @@ dependencies = [
[[package]]
name = "async-std-resolver"
version = "0.20.4"
version = "0.21.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "dbf3e776afdf3a2477ef4854b85ba0dff3bd85792f685fb3c68948b4d304e4f0"
checksum = "0f2f8a4a203be3325981310ab243a28e6e4ea55b6519bffce05d41ab60e09ad8"
dependencies = [
"async-std",
"async-trait",
"futures-io",
"futures-util",
"pin-utils",
"trust-dns-resolver",
"socket2 0.4.4",
"trust-dns-resolver 0.21.2",
]
[[package]]
@ -616,9 +635,9 @@ dependencies = [
[[package]]
name = "brotli"
version = "3.3.3"
version = "3.3.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "f838e47a451d5a8fa552371f80024dd6ace9b7acdf25c4c3d0f9bc6816fb1c39"
checksum = "a1a0b1dbcc8ae29329621f8d4f0d835787c1c38bb1401979b49d13b0b305ff68"
dependencies = [
"alloc-no-stdlib",
"alloc-stdlib",
@ -683,9 +702,9 @@ checksum = "e3b5ca7a04898ad4bcd41c90c5285445ff5b791899bb1b0abdd2a2aa791211d7"
[[package]]
name = "bytemuck"
version = "1.9.0"
version = "1.9.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ee1e0e2125faccb856bf10b0a9dfa89c4c718d05ef85580dfefbdf1c422ef801"
checksum = "cdead85bdec19c194affaeeb670c0e41fe23de31459efd1c174d049269cf02cc"
[[package]]
name = "byteorder"
@ -1424,12 +1443,12 @@ dependencies = [
[[package]]
name = "darling"
version = "0.13.1"
version = "0.13.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d0d720b8683f8dd83c65155f0530560cba68cd2bf395f6513a483caee57ff7f4"
checksum = "a01d95850c592940db9b8194bc39f4bc0e89dee5c4265e4b1807c34a9aba453c"
dependencies = [
"darling_core 0.13.1",
"darling_macro 0.13.1",
"darling_core 0.13.4",
"darling_macro 0.13.4",
]
[[package]]
@ -1448,9 +1467,9 @@ dependencies = [
[[package]]
name = "darling_core"
version = "0.13.1"
version = "0.13.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7a340f241d2ceed1deb47ae36c4144b2707ec7dd0b649f894cb39bb595986324"
checksum = "859d65a907b6852c9361e3185c862aae7fafd2887876799fa55f5f99dc40d610"
dependencies = [
"fnv",
"ident_case",
@ -1473,11 +1492,11 @@ dependencies = [
[[package]]
name = "darling_macro"
version = "0.13.1"
version = "0.13.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "72c41b3b7352feb3211a0d743dc5700a4e3b60f51bd2b368892d1e0f9a95f44b"
checksum = "9c972679f83bdf9c42bd905396b6c3588a843a17f0f16dfcfa3e2c5d57441835"
dependencies = [
"darling_core 0.13.1",
"darling_core 0.13.4",
"quote",
"syn",
]
@ -1491,7 +1510,7 @@ checksum = "3ee2393c4a91429dffb4bedf19f4d6abf27d8a732c8ce4980305d782e5426d57"
[[package]]
name = "datamodel"
version = "0.1.0"
source = "git+https://github.com/prisma/prisma-engines#135475a4847d2683a93878eabc5fddddc928cd16"
source = "git+https://github.com/prisma/prisma-engines#8940c973956ded416ab61d3940480aff8f7fc869"
dependencies = [
"bigdecimal 0.2.2",
"chrono",
@ -1514,7 +1533,7 @@ dependencies = [
[[package]]
name = "datamodel-connector"
version = "0.1.0"
source = "git+https://github.com/prisma/prisma-engines#135475a4847d2683a93878eabc5fddddc928cd16"
source = "git+https://github.com/prisma/prisma-engines#8940c973956ded416ab61d3940480aff8f7fc869"
dependencies = [
"diagnostics",
"enumflags2",
@ -1584,7 +1603,7 @@ dependencies = [
[[package]]
name = "diagnostics"
version = "0.1.0"
source = "git+https://github.com/prisma/prisma-engines#135475a4847d2683a93878eabc5fddddc928cd16"
source = "git+https://github.com/prisma/prisma-engines#8940c973956ded416ab61d3940480aff8f7fc869"
dependencies = [
"colored",
"pest",
@ -1659,7 +1678,7 @@ dependencies = [
[[package]]
name = "dml"
version = "0.1.0"
source = "git+https://github.com/prisma/prisma-engines#135475a4847d2683a93878eabc5fddddc928cd16"
source = "git+https://github.com/prisma/prisma-engines#8940c973956ded416ab61d3940480aff8f7fc869"
dependencies = [
"chrono",
"cuid",
@ -1675,7 +1694,7 @@ dependencies = [
[[package]]
name = "dmmf"
version = "0.1.0"
source = "git+https://github.com/prisma/prisma-engines#135475a4847d2683a93878eabc5fddddc928cd16"
source = "git+https://github.com/prisma/prisma-engines#8940c973956ded416ab61d3940480aff8f7fc869"
dependencies = [
"bigdecimal 0.2.2",
"datamodel",
@ -1843,6 +1862,18 @@ dependencies = [
"syn",
]
[[package]]
name = "enum-as-inner"
version = "0.4.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "21cdad81446a7f7dc43f6a77409efeb9733d2fa65553efef6018ef257c959b73"
dependencies = [
"heck 0.4.0",
"proc-macro2",
"quote",
"syn",
]
[[package]]
name = "enumflags2"
version = "0.7.4"
@ -1989,7 +2020,7 @@ checksum = "975ccf83d8d9d0d84682850a38c8169027be83368805971cc4f238c2b245bc98"
dependencies = [
"cfg-if 1.0.0",
"libc",
"redox_syscall 0.2.12",
"redox_syscall 0.2.13",
"winapi 0.3.9",
]
@ -2983,7 +3014,7 @@ dependencies = [
"color_quant",
"exr",
"gif",
"jpeg-decoder 0.2.3",
"jpeg-decoder 0.2.4",
"num-iter",
"num-rational",
"num-traits",
@ -3127,9 +3158,21 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "f7e2f18aece9709094573a9f24f483c4f65caa4298e2f7ae1b71cc65d853fad7"
dependencies = [
"socket2 0.3.19",
"widestring",
"widestring 0.4.3",
"winapi 0.3.9",
"winreg",
"winreg 0.6.2",
]
[[package]]
name = "ipconfig"
version = "0.3.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "723519edce41262b05d4143ceb95050e4c614f483e78e9fd9e39a8275a84ad98"
dependencies = [
"socket2 0.4.4",
"widestring 0.5.1",
"winapi 0.3.9",
"winreg 0.7.0",
]
[[package]]
@ -3225,9 +3268,9 @@ checksum = "229d53d58899083193af11e15917b5640cd40b29ff475a1fe4ef725deb02d0f2"
[[package]]
name = "jpeg-decoder"
version = "0.2.3"
version = "0.2.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "a55ad40a2d27923f63b6fbde5934926176c69ac5e23da6ac05ebfaca984e163f"
checksum = "744c24117572563a98a7e9168a5ac1ee4a1ca7f702211258797bbe0ed0346c3c"
dependencies = [
"rayon",
]
@ -3402,9 +3445,9 @@ dependencies = [
[[package]]
name = "libc"
version = "0.2.121"
version = "0.2.122"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "efaa7b300f3b5fe8eb6bf21ce3895e1751d9665086af2d64b42f19701015ff4f"
checksum = "ec647867e2bf0772e28c8bcde4f0d19a9216916e890543b5a03ed8ef27b8f259"
[[package]]
name = "libgit2-sys"
@ -3496,9 +3539,9 @@ dependencies = [
[[package]]
name = "libp2p-core"
version = "0.32.0"
version = "0.32.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "9164ec41455856e8187addc870bb4fe1ea2ee28e1a9244831d449a2429b32c1a"
checksum = "db5b02602099fb75cb2d16f9ea860a320d6eb82ce41e95ab680912c454805cd5"
dependencies = [
"asn1_der",
"bs58",
@ -3542,16 +3585,16 @@ dependencies = [
[[package]]
name = "libp2p-dns"
version = "0.32.0"
version = "0.32.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7838647d33978b77f943687412f4a39e74234c8342cbfdad14282b465b272cb4"
checksum = "066e33e854e10b5c93fc650458bf2179c7e0d143db260b0963e44a94859817f1"
dependencies = [
"async-std-resolver",
"futures",
"libp2p-core",
"log",
"smallvec",
"trust-dns-resolver",
"trust-dns-resolver 0.21.2",
]
[[package]]
@ -3924,7 +3967,7 @@ dependencies = [
"rw-stream-sink",
"soketto",
"url",
"webpki-roots 0.22.2",
"webpki-roots 0.22.3",
]
[[package]]
@ -4051,10 +4094,11 @@ dependencies = [
[[package]]
name = "lock_api"
version = "0.4.6"
version = "0.4.7"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "88943dd7ef4a2e5a4bfa2753aaab3013e34ce2533d1996fb18ef591e315e2b3b"
checksum = "327fa5b6a6940e4699ec49a9beae1ea4845c6bab9314e4f84ac68742139d8c53"
dependencies = [
"autocfg",
"scopeguard",
]
@ -4085,9 +4129,9 @@ dependencies = [
[[package]]
name = "lru"
version = "0.7.3"
version = "0.7.5"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "fcb87f3080f6d1d69e8c564c0fcfde1d7aa8cc451ce40cae89479111f03bc0eb"
checksum = "32613e41de4c47ab04970c348ca7ae7382cf116625755af070b008a15516a889"
dependencies = [
"hashbrown 0.11.2",
]
@ -4383,8 +4427,8 @@ dependencies = [
"tokio",
"tokio-rustls",
"tokio-util 0.6.9",
"trust-dns-proto",
"trust-dns-resolver",
"trust-dns-proto 0.20.4",
"trust-dns-resolver 0.20.4",
"typed-builder",
"uuid",
"version_check",
@ -4395,7 +4439,7 @@ dependencies = [
[[package]]
name = "mongodb-client"
version = "0.1.0"
source = "git+https://github.com/prisma/prisma-engines#135475a4847d2683a93878eabc5fddddc928cd16"
source = "git+https://github.com/prisma/prisma-engines#8940c973956ded416ab61d3940480aff8f7fc869"
dependencies = [
"mongodb",
"once_cell",
@ -4406,7 +4450,7 @@ dependencies = [
[[package]]
name = "mongodb-datamodel-connector"
version = "0.1.0"
source = "git+https://github.com/prisma/prisma-engines#135475a4847d2683a93878eabc5fddddc928cd16"
source = "git+https://github.com/prisma/prisma-engines#8940c973956ded416ab61d3940480aff8f7fc869"
dependencies = [
"datamodel-connector",
"enumflags2",
@ -4418,7 +4462,7 @@ dependencies = [
[[package]]
name = "mongodb-query-connector"
version = "0.1.0"
source = "git+https://github.com/prisma/prisma-engines#135475a4847d2683a93878eabc5fddddc928cd16"
source = "git+https://github.com/prisma/prisma-engines#8940c973956ded416ab61d3940480aff8f7fc869"
dependencies = [
"anyhow",
"async-trait",
@ -4467,9 +4511,9 @@ dependencies = [
[[package]]
name = "multihash"
version = "0.16.1"
version = "0.16.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7392bffd88bc0c4f8297e36a777ab9f80b7127409c4a1acb8fee99c9f27addcd"
checksum = "e3db354f401db558759dfc1e568d010a5d4146f4d3f637be1275ec4a3cf09689"
dependencies = [
"core2",
"digest 0.10.3",
@ -4617,7 +4661,7 @@ dependencies = [
[[package]]
name = "native-types"
version = "0.1.0"
source = "git+https://github.com/prisma/prisma-engines#135475a4847d2683a93878eabc5fddddc928cd16"
source = "git+https://github.com/prisma/prisma-engines#8940c973956ded416ab61d3940480aff8f7fc869"
dependencies = [
"serde",
"serde_json",
@ -5201,7 +5245,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7d17b78036a60663b797adeaee46f5c9dfebb86948d1255007a1d6be0271ff99"
dependencies = [
"instant",
"lock_api 0.4.6",
"lock_api 0.4.7",
"parking_lot_core 0.8.5",
]
@ -5211,8 +5255,8 @@ version = "0.12.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "87f5ec2493a61ac0506c0f4199f99070cbe83857b0337006a30f3e6719b8ef58"
dependencies = [
"lock_api 0.4.6",
"parking_lot_core 0.9.1",
"lock_api 0.4.7",
"parking_lot_core 0.9.2",
]
[[package]]
@ -5238,28 +5282,28 @@ dependencies = [
"cfg-if 1.0.0",
"instant",
"libc",
"redox_syscall 0.2.12",
"redox_syscall 0.2.13",
"smallvec",
"winapi 0.3.9",
]
[[package]]
name = "parking_lot_core"
version = "0.9.1"
version = "0.9.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "28141e0cc4143da2443301914478dc976a61ffdb3f043058310c70df2fed8954"
checksum = "995f667a6c822200b0433ac218e05582f0e2efa1b922a3fd2fbaadc5f87bab37"
dependencies = [
"cfg-if 1.0.0",
"libc",
"redox_syscall 0.2.12",
"redox_syscall 0.2.13",
"smallvec",
"windows-sys 0.32.0",
"windows-sys",
]
[[package]]
name = "parser-database"
version = "0.1.0"
source = "git+https://github.com/prisma/prisma-engines#135475a4847d2683a93878eabc5fddddc928cd16"
source = "git+https://github.com/prisma/prisma-engines#8940c973956ded416ab61d3940480aff8f7fc869"
dependencies = [
"diagnostics",
"enumflags2",
@ -5566,9 +5610,9 @@ dependencies = [
[[package]]
name = "pkg-config"
version = "0.3.24"
version = "0.3.25"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "58893f751c9b0412871a09abd62ecd2a00298c6c83befa223ef98c52aef40cbe"
checksum = "1df8c4ec4b0627e53bdf214615ad287367e482558cf84b109250b37464dc03ae"
[[package]]
name = "png"
@ -5712,7 +5756,7 @@ dependencies = [
[[package]]
name = "prisma-inflector"
version = "0.1.0"
source = "git+https://github.com/prisma/prisma-engines#135475a4847d2683a93878eabc5fddddc928cd16"
source = "git+https://github.com/prisma/prisma-engines#8940c973956ded416ab61d3940480aff8f7fc869"
dependencies = [
"once_cell",
"regex",
@ -5722,7 +5766,7 @@ dependencies = [
[[package]]
name = "prisma-models"
version = "0.0.0"
source = "git+https://github.com/prisma/prisma-engines#135475a4847d2683a93878eabc5fddddc928cd16"
source = "git+https://github.com/prisma/prisma-engines#8940c973956ded416ab61d3940480aff8f7fc869"
dependencies = [
"bigdecimal 0.2.2",
"chrono",
@ -5743,7 +5787,7 @@ dependencies = [
[[package]]
name = "prisma-value"
version = "0.1.0"
source = "git+https://github.com/prisma/prisma-engines#135475a4847d2683a93878eabc5fddddc928cd16"
source = "git+https://github.com/prisma/prisma-engines#8940c973956ded416ab61d3940480aff8f7fc869"
dependencies = [
"base64 0.12.3",
"bigdecimal 0.2.2",
@ -5808,9 +5852,9 @@ checksum = "dbf0c48bc1d91375ae5c3cd81e3722dff1abcf81a30960240640d223f59fe0e5"
[[package]]
name = "proc-macro2"
version = "1.0.36"
version = "1.0.37"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c7342d5883fbccae1cc37a2353b09c87c9b0f3afd73f5fb9bba687a1f733b029"
checksum = "ec757218438d5fda206afc041538b2f6d889286160d649a86a24d37e1235afd1"
dependencies = [
"unicode-xid",
]
@ -5903,7 +5947,7 @@ dependencies = [
[[package]]
name = "quaint"
version = "0.2.0-alpha.13"
source = "git+https://github.com/prisma/quaint#479e08a41b13902028906bc05f778688c06a3f18"
source = "git+https://github.com/prisma/quaint#a0722f26311669377ca9069843e8866a1706c42a"
dependencies = [
"async-trait",
"base64 0.12.3",
@ -5942,7 +5986,7 @@ dependencies = [
[[package]]
name = "query-connector"
version = "0.1.0"
source = "git+https://github.com/prisma/prisma-engines#135475a4847d2683a93878eabc5fddddc928cd16"
source = "git+https://github.com/prisma/prisma-engines#8940c973956ded416ab61d3940480aff8f7fc869"
dependencies = [
"anyhow",
"async-trait",
@ -5962,7 +6006,7 @@ dependencies = [
[[package]]
name = "query-core"
version = "0.1.0"
source = "git+https://github.com/prisma/prisma-engines#135475a4847d2683a93878eabc5fddddc928cd16"
source = "git+https://github.com/prisma/prisma-engines#8940c973956ded416ab61d3940480aff8f7fc869"
dependencies = [
"async-trait",
"base64 0.12.3",
@ -6167,21 +6211,21 @@ checksum = "41cc0f7e4d5d4544e8861606a285bb08d3e70712ccc7d2b84d7c0ccfaf4b05ce"
[[package]]
name = "redox_syscall"
version = "0.2.12"
version = "0.2.13"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "8ae183fc1b06c149f0c1793e1eb447c8b04bfe46d48e9e48bfb8d2d7ed64ecf0"
checksum = "62f25bc4c7e55e0b0b7a1d43fb893f4fa1361d0abe38b9ce4f323c2adfe6ef42"
dependencies = [
"bitflags 1.3.2",
]
[[package]]
name = "redox_users"
version = "0.4.2"
version = "0.4.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7776223e2696f1aa4c6b0170e83212f47296a00424305117d013dfe86fb0fe55"
checksum = "b033d837a7cf162d7993aded9304e30a83213c648b6e389db233191f891e5c2b"
dependencies = [
"getrandom 0.2.6",
"redox_syscall 0.2.12",
"redox_syscall 0.2.13",
"thiserror",
]
@ -6223,7 +6267,7 @@ dependencies = [
[[package]]
name = "request-handlers"
version = "0.1.0"
source = "git+https://github.com/prisma/prisma-engines#135475a4847d2683a93878eabc5fddddc928cd16"
source = "git+https://github.com/prisma/prisma-engines#8940c973956ded416ab61d3940480aff8f7fc869"
dependencies = [
"bigdecimal 0.2.2",
"connection-string",
@ -6508,7 +6552,7 @@ dependencies = [
[[package]]
name = "schema-ast"
version = "0.1.0"
source = "git+https://github.com/prisma/prisma-engines#135475a4847d2683a93878eabc5fddddc928cd16"
source = "git+https://github.com/prisma/prisma-engines#8940c973956ded416ab61d3940480aff8f7fc869"
dependencies = [
"diagnostics",
"pest",
@ -6747,9 +6791,9 @@ dependencies = [
[[package]]
name = "serde_with"
version = "1.12.0"
version = "1.12.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ec1e6ec4d8950e5b1e894eac0d360742f3b1407a6078a604a731c4b3f49cefbc"
checksum = "946fa04a8ac43ff78a1f4b811990afb9ddbdf5890b46d6dda0ba1998230138b7"
dependencies = [
"rustversion",
"serde",
@ -6758,11 +6802,11 @@ dependencies = [
[[package]]
name = "serde_with_macros"
version = "1.5.1"
version = "1.5.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "12e47be9471c72889ebafb5e14d5ff930d89ae7a67bbdb5f8abb564f845a927e"
checksum = "e182d6ec6f05393cc0e5ed1bf81ad6db3a8feedf8ee515ecdd369809bcce8082"
dependencies = [
"darling 0.13.1",
"darling 0.13.4",
"proc-macro2",
"quote",
"syn",
@ -6928,6 +6972,25 @@ version = "1.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "43b2853a4d09f215c24cc5489c992ce46052d359b5109343cbafbf26bc62f8a3"
[[package]]
name = "signal-hook"
version = "0.3.13"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "647c97df271007dcea485bb74ffdb57f2e683f1306c854f468a0c244badabf2d"
dependencies = [
"libc",
"signal-hook-registry",
]
[[package]]
name = "signal-hook-registry"
version = "1.4.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "e51e73328dc4ac0c7ccbda3a494dfa03df1de2f46018127f60c693f2648455b0"
dependencies = [
"libc",
]
[[package]]
name = "signature"
version = "1.5.0"
@ -6951,9 +7014,9 @@ dependencies = [
[[package]]
name = "slab"
version = "0.4.5"
version = "0.4.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "9def91fd1e018fe007022791f865d0ccc9b3a0d5001e01aabb8b40e46000afb5"
checksum = "eb703cfe953bccee95685111adeedb76fabe4e97549a58d16f03ea7b9367bb32"
[[package]]
name = "smallvec"
@ -7091,13 +7154,13 @@ version = "0.9.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "511254be0c5bcf062b019a6c89c01a664aa359ded62f78aa72c6fc137c0590e5"
dependencies = [
"lock_api 0.4.6",
"lock_api 0.4.7",
]
[[package]]
name = "sql-datamodel-connector"
version = "0.1.0"
source = "git+https://github.com/prisma/prisma-engines#135475a4847d2683a93878eabc5fddddc928cd16"
source = "git+https://github.com/prisma/prisma-engines#8940c973956ded416ab61d3940480aff8f7fc869"
dependencies = [
"datamodel-connector",
"enumflags2",
@ -7110,7 +7173,7 @@ dependencies = [
[[package]]
name = "sql-query-connector"
version = "0.1.0"
source = "git+https://github.com/prisma/prisma-engines#135475a4847d2683a93878eabc5fddddc928cd16"
source = "git+https://github.com/prisma/prisma-engines#8940c973956ded416ab61d3940480aff8f7fc869"
dependencies = [
"anyhow",
"async-trait",
@ -7308,9 +7371,9 @@ dependencies = [
[[package]]
name = "syn"
version = "1.0.90"
version = "1.0.91"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "704df27628939572cd88d33f171cd6f896f4eaca85252c6e0a72d8d8287ee86f"
checksum = "b683b2b825c8eef438b77c36a06dc262294da3d5a5813fac20da149241dcd44d"
dependencies = [
"proc-macro2",
"quote",
@ -7331,9 +7394,9 @@ dependencies = [
[[package]]
name = "sysinfo"
version = "0.23.6"
version = "0.23.8"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "5f3c0db8e08e06cfd352a043bd0143498fb7d42783a6e941da83b55464eb27d2"
checksum = "ad04c584871b8dceb769a20b94e26a357a870c999b7246dcd4cb233d927547e3"
dependencies = [
"cfg-if 1.0.0",
"core-foundation-sys",
@ -7655,7 +7718,7 @@ dependencies = [
"cfg-if 1.0.0",
"fastrand",
"libc",
"redox_syscall 0.2.12",
"redox_syscall 0.2.13",
"remove_dir_all",
"winapi 0.3.9",
]
@ -7760,9 +7823,9 @@ dependencies = [
[[package]]
name = "tiberius"
version = "0.7.1"
version = "0.7.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "00035fdbcee3e791e756d1831a1b9a89e414c320d3eccdae65aba4f388216c30"
checksum = "833311bc8e26e96c73ad1b5c1f488c588808c747a318905ec67e43d422ea2c08"
dependencies = [
"async-native-tls",
"async-trait",
@ -7984,9 +8047,9 @@ dependencies = [
[[package]]
name = "tracing-core"
version = "0.1.23"
version = "0.1.24"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "aa31669fa42c09c34d94d8165dd2012e8ff3c66aca50f3bb226b68f216f2706c"
checksum = "90442985ee2f57c9e1b548ee72ae842f4a9a20e3f417cc38dbc5dc684d9bb4ee"
dependencies = [
"lazy_static",
"valuable",
@ -8028,9 +8091,9 @@ dependencies = [
[[package]]
name = "tracing-subscriber"
version = "0.3.9"
version = "0.3.10"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "9e0ab7bdc962035a87fba73f3acca9b8a8d0034c2e6f60b84aeaaddddc155dce"
checksum = "b9df98b037d039d03400d9dd06b0f8ce05486b5f25e9a2d7d36196e142ebbc52"
dependencies = [
"ansi_term",
"lazy_static",
@ -8062,7 +8125,7 @@ dependencies = [
"async-trait",
"cfg-if 1.0.0",
"data-encoding",
"enum-as-inner",
"enum-as-inner 0.3.4",
"futures-channel",
"futures-io",
"futures-util",
@ -8078,6 +8141,30 @@ dependencies = [
"url",
]
[[package]]
name = "trust-dns-proto"
version = "0.21.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "9c31f240f59877c3d4bb3b3ea0ec5a6a0cff07323580ff8c7a605cd7d08b255d"
dependencies = [
"async-trait",
"cfg-if 1.0.0",
"data-encoding",
"enum-as-inner 0.4.0",
"futures-channel",
"futures-io",
"futures-util",
"idna",
"ipnet",
"lazy_static",
"log",
"rand 0.8.5",
"smallvec",
"thiserror",
"tinyvec",
"url",
]
[[package]]
name = "trust-dns-resolver"
version = "0.20.4"
@ -8086,7 +8173,7 @@ checksum = "ecae383baad9995efaa34ce8e57d12c3f305e545887472a492b838f4b5cfb77a"
dependencies = [
"cfg-if 1.0.0",
"futures-util",
"ipconfig",
"ipconfig 0.2.2",
"lazy_static",
"log",
"lru-cache",
@ -8095,7 +8182,26 @@ dependencies = [
"smallvec",
"thiserror",
"tokio",
"trust-dns-proto",
"trust-dns-proto 0.20.4",
]
[[package]]
name = "trust-dns-resolver"
version = "0.21.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "e4ba72c2ea84515690c9fcef4c6c660bb9df3036ed1051686de84605b74fd558"
dependencies = [
"cfg-if 1.0.0",
"futures-util",
"ipconfig 0.3.0",
"lazy_static",
"log",
"lru-cache",
"parking_lot 0.12.0",
"resolv-conf",
"smallvec",
"thiserror",
"trust-dns-proto 0.21.2",
]
[[package]]
@ -8279,7 +8385,7 @@ dependencies = [
[[package]]
name = "user-facing-error-macros"
version = "0.1.0"
source = "git+https://github.com/prisma/prisma-engines#135475a4847d2683a93878eabc5fddddc928cd16"
source = "git+https://github.com/prisma/prisma-engines#8940c973956ded416ab61d3940480aff8f7fc869"
dependencies = [
"proc-macro2",
"quote",
@ -8289,7 +8395,7 @@ dependencies = [
[[package]]
name = "user-facing-errors"
version = "0.1.0"
source = "git+https://github.com/prisma/prisma-engines#135475a4847d2683a93878eabc5fddddc928cd16"
source = "git+https://github.com/prisma/prisma-engines#8940c973956ded416ab61d3940480aff8f7fc869"
dependencies = [
"backtrace",
"indoc",
@ -8587,9 +8693,9 @@ dependencies = [
[[package]]
name = "webpki-roots"
version = "0.22.2"
version = "0.22.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "552ceb903e957524388c4d3475725ff2c8b7960922063af6ce53c9a43da07449"
checksum = "44d8de8415c823c8abd270ad483c6feeac771fad964890779f9a8cb24fbbc1bf"
dependencies = [
"webpki 0.22.0",
]
@ -8663,6 +8769,12 @@ version = "0.4.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c168940144dd21fd8046987c16a46a33d5fc84eec29ef9dcddc2ac9e31526b7c"
[[package]]
name = "widestring"
version = "0.5.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "17882f045410753661207383517a6f62ec3dbeb6a4ed2acce01f0728238d1983"
[[package]]
name = "wildmatch"
version = "2.1.0"
@ -8734,7 +8846,7 @@ dependencies = [
"cocoa",
"objc",
"raw-window-handle",
"windows-sys 0.34.0",
"windows-sys",
]
[[package]]
@ -8798,19 +8910,6 @@ dependencies = [
"windows_reader",
]
[[package]]
name = "windows-sys"
version = "0.32.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "3df6e476185f92a12c072be4a189a0210dcdcf512a1891d6dff9edb874deadc6"
dependencies = [
"windows_aarch64_msvc 0.32.0",
"windows_i686_gnu 0.32.0",
"windows_i686_msvc 0.32.0",
"windows_x86_64_gnu 0.32.0",
"windows_x86_64_msvc 0.32.0",
]
[[package]]
name = "windows-sys"
version = "0.34.0"
@ -8836,12 +8935,6 @@ version = "0.30.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "29277a4435d642f775f63c7d1faeb927adba532886ce0287bd985bffb16b6bca"
[[package]]
name = "windows_aarch64_msvc"
version = "0.32.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d8e92753b1c443191654ec532f14c199742964a061be25d77d7a96f09db20bf5"
[[package]]
name = "windows_aarch64_msvc"
version = "0.33.0"
@ -8882,12 +8975,6 @@ version = "0.30.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "1145e1989da93956c68d1864f32fb97c8f561a8f89a5125f6a2b7ea75524e4b8"
[[package]]
name = "windows_i686_gnu"
version = "0.32.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "6a711c68811799e017b6038e0922cb27a5e2f43a2ddb609fe0b6f3eeda9de615"
[[package]]
name = "windows_i686_gnu"
version = "0.33.0"
@ -8918,12 +9005,6 @@ version = "0.30.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d4a09e3a0d4753b73019db171c1339cd4362c8c44baf1bcea336235e955954a6"
[[package]]
name = "windows_i686_msvc"
version = "0.32.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "146c11bb1a02615db74680b32a68e2d61f553cc24c4eb5b4ca10311740e44172"
[[package]]
name = "windows_i686_msvc"
version = "0.33.0"
@ -8978,12 +9059,6 @@ version = "0.30.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "8ca64fcb0220d58db4c119e050e7af03c69e6f4f415ef69ec1773d9aab422d5a"
[[package]]
name = "windows_x86_64_gnu"
version = "0.32.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c912b12f7454c6620635bbff3450962753834be2a594819bd5e945af18ec64bc"
[[package]]
name = "windows_x86_64_gnu"
version = "0.33.0"
@ -9014,12 +9089,6 @@ version = "0.30.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "08cabc9f0066848fef4bc6a1c1668e6efce38b661d2aeec75d18d8617eebb5f1"
[[package]]
name = "windows_x86_64_msvc"
version = "0.32.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "504a2476202769977a040c6364301a3f65d0cc9e3fb08600b2bda150a0488316"
[[package]]
name = "windows_x86_64_msvc"
version = "0.33.0"
@ -9041,6 +9110,15 @@ dependencies = [
"winapi 0.3.9",
]
[[package]]
name = "winreg"
version = "0.7.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "0120db82e8a1e0b9fb3345a539c478767c0048d842860994d96113d5b667bd69"
dependencies = [
"winapi 0.3.9",
]
[[package]]
name = "winres"
version = "0.1.12"

View file

@ -5,18 +5,18 @@
"license": "MIT",
"private": true,
"devDependencies": {
"@tauri-apps/cli": "^1.0.0-beta.6",
"@tauri-apps/cli": "^1.0.0-rc.8",
"@types/babel-core": "^6.25.7",
"@types/byte-size": "^8.1.0",
"@types/react": "^17.0.18",
"@types/react-dom": "^17.0.9",
"@types/react-router-dom": "^5.3.1",
"@types/react": "^18.0.0",
"@types/react-dom": "^18.0.0",
"@types/react-router-dom": "^5.3.3",
"@types/react-virtualized-auto-sizer": "^1.0.1",
"@types/react-window": "^1.8.5",
"@types/tailwindcss": "^2.2.1",
"concurrently": "^6.2.1",
"prettier": "^2.3.2",
"typescript": "^4.3.5"
"@types/tailwindcss": "^3.0.10",
"concurrently": "^7.1.0",
"prettier": "^2.6.2",
"typescript": "^4.6.3"
},
"scripts": {
"vite": "vite",
@ -28,46 +28,46 @@
"react-virtualized": "patch:react-virtualized@9.22.3#./path/to/react-virtualized-9.22.3.patch"
},
"dependencies": {
"@apollo/client": "^3.4.7",
"@headlessui/react": "^1.4.0",
"@heroicons/react": "^1.0.4",
"@radix-ui/react-dialog": "^0.1.5",
"@apollo/client": "^3.5.10",
"@headlessui/react": "^1.5.0",
"@heroicons/react": "^1.0.6",
"@radix-ui/react-dialog": "^0.1.7",
"@radix-ui/react-slider": "^0.1.4",
"@sd/core": "*",
"@sd/client": "*",
"@sd/ui": "*",
"@tauri-apps/api": "^1.0.0-beta.5",
"@sd/client": "workspace:*",
"@sd/core": "workspace:*",
"@sd/ui": "workspace:*",
"@tauri-apps/api": "^1.0.0-rc.3",
"@types/pretty-bytes": "^5.2.0",
"@types/react-table": "^7.7.6",
"@types/react-virtualized": "^9.21.14",
"@types/react-table": "^7.7.10",
"@types/react-virtualized": "^9.21.21",
"@vitejs/plugin-react-refresh": "^1.3.6",
"autoprefixer": "^9",
"autoprefixer": "^10.4.4",
"byte-size": "^8.1.0",
"clsx": "^1.1.1",
"immer": "^9.0.12",
"jotai": "^1.6.0",
"moment": "^2.29.1",
"phosphor-react": "^1.3.1",
"pretty-bytes": "^5.6.0",
"react": "^17.0.2",
"react-dom": "^17.0.2",
"react-dropzone": "^11.3.4",
"react-error-boundary": "^3.1.3",
"jotai": "^1.6.2",
"moment": "^2.29.2",
"phosphor-react": "^1.4.1",
"pretty-bytes": "^6.0.0",
"react": "^18.0.0",
"react-dom": "^18.0.0",
"react-dropzone": "^12.0.4",
"react-error-boundary": "^3.1.4",
"react-hotkeys-hook": "^3.4.4",
"react-json-view": "^1.21.3",
"react-portal": "^4.2.1",
"react-query": "^3.34.16",
"react-router": "6.2.1",
"react-router-dom": "6.2.1",
"react-portal": "^4.2.2",
"react-query": "^3.34.19",
"react-router": "6.3.0",
"react-router-dom": "6.3.0",
"react-spline": "^1.2.1",
"react-transition-group": "^4.4.2",
"react-virtuoso": "^2.2.6",
"rooks": "^5.7.1",
"tailwindcss": "^3.0.7",
"vite": "^2.4.4",
"react-virtuoso": "^2.9.0",
"rooks": "^5.11.0",
"tailwindcss": "^3.0.23",
"vite": "^2.9.1",
"vite-plugin-filter-replace": "^0.1.9",
"vite-plugin-react-svg": "^0.2.0",
"vite-tsconfig-paths": "^3.3.13",
"zustand": "^3.7.1"
"vite-tsconfig-paths": "^3.4.1",
"zustand": "^3.7.2"
}
}

View file

@ -5,8 +5,6 @@ use tauri::api::path;
use tauri::Manager;
mod menu;
use window_shadows::set_shadow;
#[tauri::command(async)]
async fn client_query_transport(
core: tauri::State<'_, CoreController>,
@ -55,11 +53,14 @@ async fn main() {
.setup(|app| {
let app = app.handle();
app.windows().iter().for_each(|(_, window)| {
set_shadow(&window, true).unwrap_or(());
#[cfg(not(target_os = "linux"))]
{
app.windows().iter().for_each(|(_, window)| {
window_shadows::set_shadow(&window, true).unwrap_or(());
window.start_dragging().unwrap_or(());
});
window.start_dragging().unwrap_or(());
});
}
// core event transport
tokio::spawn(async move {

View file

@ -24,6 +24,7 @@ import LocationSettings from './screens/settings/LocationSettings';
import { RedirectPage } from './screens/Redirect';
import { QueryClient, QueryClientProvider } from 'react-query';
import { platform } from '@tauri-apps/api/os';
import { ClientProvider } from '@sd/client';
const queryClient = new QueryClient();
@ -83,6 +84,10 @@ function Router() {
let location = useLocation();
let state = location.state as { backgroundLocation?: Location };
useEffect(() => {
console.log({ url: location.pathname });
}, [state]);
return (
<>
<Routes location={state?.backgroundLocation || location}>
@ -91,7 +96,7 @@ function Router() {
<Route path="overview" element={<OverviewScreen />} />
<Route path="spaces" element={<SpacesScreen />} />
<Route path="settings/*" element={<SettingsRoutes />} />
<Route path="explorer" element={<ExplorerScreen />} />
<Route path="explorer/*" element={<ExplorerScreen />} />
<Route path="*" element={<NotFound />} />
</Route>
</Routes>
@ -124,7 +129,6 @@ function ErrorFallback({ error, resetErrorBoundary }: FallbackProps) {
function NotFound() {
const navigate = useNavigate();
return (
<div
data-tauri-drag-region
@ -142,6 +146,10 @@ function NotFound() {
);
}
// useHotkeys('command+q', () => {
// process.exit();
// });
function AppContainer() {
useCoreEvents();
return (
@ -152,10 +160,18 @@ function AppContainer() {
}
export default function App() {
// @ts-ignore: TODO: This is a hack and a better solution should probably be found. This exists so that the queryClient can be accessed within the subpackage '@sd/client'. Refer to <ClientProvider /> for where this is used.
if (window.ReactQueryClient === undefined) {
// @ts-ignore
window.ReactQueryClient = queryClient;
}
return (
<ErrorBoundary FallbackComponent={ErrorFallback} onReset={() => {}}>
<QueryClientProvider client={queryClient}>
<AppContainer />
<QueryClientProvider client={queryClient} contextSharing={false}>
<ClientProvider>
<AppContainer />
</ClientProvider>
</QueryClientProvider>
</ErrorBoundary>
);

View file

@ -86,14 +86,14 @@ export interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElemen
justifyLeft?: boolean;
}
export const Button: React.FC<ButtonProps> = ({ loading, ...props }) => {
export const Button: React.FC<ButtonProps> = ({ loading, justifyLeft, ...props }) => {
return (
<button
{...props}
className={clsx(
'border rounded-md items-center transition-colors duration-100 cursor-default',
{ 'opacity-5': loading, '!p-1': props.noPadding },
{ 'justify-center': !props.justifyLeft },
{ 'justify-center': !justifyLeft },
sizes[props.size || 'default'],
variants[props.variant || 'default'],
{ 'active:translate-y-[1px]': props.pressEffect },

View file

@ -1,5 +1,5 @@
import React from 'react';
import ReactDOM from 'react-dom';
import { createRoot } from 'react-dom/client';
import App from './App';
import './style.css';
@ -18,9 +18,9 @@ class Transport extends BaseTransport {
}
setTransport(new Transport());
ReactDOM.render(
const root = createRoot(document.getElementById('root')!);
root.render(
<React.StrictMode>
<App />
</React.StrictMode>,
document.getElementById('root')
</React.StrictMode>
);

View file

@ -28,6 +28,7 @@ pub mod util;
// pub mod native;
// a wrapper around external input with a returning sender channel for core to respond
#[derive(Debug)]
pub struct ReturnableMessage<D, R = Result<CoreResponse, CoreError>> {
data: D,
return_sender: oneshot::Sender<R>,

View file

@ -21,8 +21,8 @@
"server": "pnpm --filter @sd/server -- "
},
"devDependencies": {
"prettier": "^2.5.1",
"turbo": "latest"
"prettier": "^2.6.2",
"turbo": "^1.2.1"
},
"turbo": {
"pipeline": {

View file

@ -0,0 +1,11 @@
import React from 'react';
import { QueryClientProvider } from 'react-query';
// The ClientProvider injects the React-query context into the "context store" of the current package. This is needed due to the fact the repository is a monorepo.
// This is a pretty hacky solution and a better solution should probably be found to replace it.
export function ClientProvider({ children }: any) {
return (
// @ts-ignore: This exists to add the QueryClientProvider to the current subpackage '@sd/client'. The ReactQueryClient is fetched from the window object (which is set in the parent application).
<QueryClientProvider client={window.ReactQueryClient}>{children}</QueryClientProvider>
);
}

View file

@ -1,2 +1,3 @@
export * from './bridge';
export * from './files';
export * from './ClientProvider';

View file

@ -18,18 +18,22 @@
"devDependencies": {
"scripts": "*",
"tsconfig": "*",
"typescript": "^4.5.3"
"typescript": "^4.6.3",
"react": "^18.0.0",
"react-query": "^3.34.19"
},
"jest": {
"preset": "scripts/jest/node"
},
"dependencies": {
"@sd/config": "*",
"@sd/core": "*",
"@sd/config": "workspace:*",
"@sd/core": "workspace:*",
"eventemitter3": "^4.0.7",
"immer": "^9.0.12",
"react": "^17.0.2",
"react-query": "^3.34.16",
"zustand": "^3.7.1"
"zustand": "^3.7.2"
},
"peerDependencies": {
"react": "^18.0.0",
"react-query": "^3.34.19"
}
}

View file

@ -1,11 +1,12 @@
{
"compilerOptions": {
"lib": ["esnext"],
"module": "esnext",
"outDir": "./dist",
"rootDir": "./lib"
"lib": ["esnext"],
"module": "esnext",
"outDir": "./dist",
"rootDir": "./lib",
"jsx": "react"
},
"extends": "../config/tsconfig/base.json",
"include": ["**/*.ts"],
"include": ["**/*.ts", "**/*.tsx"],
"exclude": ["node_modules", "dist"]
}
}

View file

@ -7,10 +7,10 @@
"eslint-preset.js"
],
"devDependencies": {
"typescript": "^4.5.3"
"typescript": "^4.6.3"
},
"dependencies": {
"eslint-config-next": "^12.0.3",
"eslint-config-prettier": "^8.3.0"
"eslint-config-next": "^12.1.4",
"eslint-config-prettier": "^8.5.0"
}
}

View file

@ -8,14 +8,14 @@
"build": "tsc"
},
"dependencies": {
"@headlessui/react": "^1.4.0",
"@headlessui/react": "^1.5.0",
"clsx": "^1.1.1",
"react": "^17.0.2"
"react": "^18.0.0"
},
"devDependencies": {
"@sd/config": "*",
"typescript": "^4.5.3",
"@types/react": "^17.0.37",
"@types/react-dom": "^17.0.11"
"@sd/config": "workspace:*",
"@types/react": "^18.0.0",
"@types/react-dom": "^18.0.0",
"typescript": "^4.6.3"
}
}

File diff suppressed because it is too large Load diff