diff --git a/.changepacks/changepack_log_E5lA9E8yEv8BVqw14JnG6.json b/.changepacks/changepack_log_E5lA9E8yEv8BVqw14JnG6.json new file mode 100644 index 00000000..de5fd8f8 --- /dev/null +++ b/.changepacks/changepack_log_E5lA9E8yEv8BVqw14JnG6.json @@ -0,0 +1 @@ +{"changes":{"packages/next-plugin/package.json":"Patch"},"note":"Fix loader issue","date":"2026-01-14T11:16:47.199601600Z"} \ No newline at end of file diff --git a/.changepacks/changepack_log_Yq5qc_Svay4n89mb4Qjog.json b/.changepacks/changepack_log_Yq5qc_Svay4n89mb4Qjog.json new file mode 100644 index 00000000..ef40465e --- /dev/null +++ b/.changepacks/changepack_log_Yq5qc_Svay4n89mb4Qjog.json @@ -0,0 +1 @@ +{"changes":{"packages/bun-plugin/package.json":"Patch","packages/components/package.json":"Patch","packages/next-plugin/package.json":"Patch","packages/react/package.json":"Patch","bindings/devup-ui-wasm/package.json":"Patch","packages/plugin-utils/package.json":"Patch","packages/vite-plugin/package.json":"Patch","packages/webpack-plugin/package.json":"Patch","packages/rsbuild-plugin/package.json":"Patch"},"note":"Add importAlias option","date":"2026-01-14T11:03:40.943886300Z"} \ No newline at end of file diff --git a/.gitignore b/.gitignore index 9a0e6679..088c28e2 100644 --- a/.gitignore +++ b/.gitignore @@ -17,3 +17,4 @@ tarpaulin-report.json *storybook.log storybook-static .claude +.sisyphus diff --git a/Cargo.lock b/Cargo.lock index dc0972cf..82750ac5 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2,6 +2,12 @@ # It is not intended for manual editing. version = 4 +[[package]] +name = "adler2" +version = "2.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "320119579fcad9c21884f5c4861d16174d0e06250625266f50fe6898340abefa" + [[package]] name = "aho-corasick" version = "1.1.4" @@ -11,6 +17,15 @@ dependencies = [ "memchr", ] +[[package]] +name = "aligned-vec" +version = "0.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dc890384c8602f339876ded803c97ad529f3842aba97f6392b3dba0dd171769b" +dependencies = [ + "equator", +] + [[package]] name = "alloca" version = "0.4.0" @@ -38,6 +53,12 @@ version = "1.0.13" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5192cca8006f1fd4f7237516f40fa183bb07f8fbdfedaa0036de5ea9b0b45e78" +[[package]] +name = "arrayvec" +version = "0.7.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7c02d123df017efcdfbd739ef81735b36c5ba83ec3c59c80a9d7ecc718f92e50" + [[package]] name = "async-trait" version = "0.1.89" @@ -55,6 +76,12 @@ version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c08606f8c3cbf4ce6ec8e28fb0014a2c086708fe954eaa885384a6165172e7e8" +[[package]] +name = "base64" +version = "0.22.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6" + [[package]] name = "base64-simd" version = "0.8.0" @@ -80,6 +107,156 @@ version = "2.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "812e12b5285cc515a9c72a5c1d3b6d46a19dac5acfef5265968c166106e31dd3" +[[package]] +name = "block-buffer" +version = "0.10.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" +dependencies = [ + "generic-array", +] + +[[package]] +name = "boa_ast" +version = "0.21.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bc119a5ad34c3f459062a96907f53358989b173d104258891bb74f95d93747e8" +dependencies = [ + "bitflags", + "boa_interner", + "boa_macros", + "boa_string", + "indexmap", + "num-bigint", + "rustc-hash", +] + +[[package]] +name = "boa_engine" +version = "0.21.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e637ec52ea66d76b0ca86180c259d6c7bb6e6a6e14b2f36b85099306d8b00cc3" +dependencies = [ + "aligned-vec", + "arrayvec", + "bitflags", + "boa_ast", + "boa_gc", + "boa_interner", + "boa_macros", + "boa_parser", + "boa_string", + "bytemuck", + "cfg-if", + "cow-utils", + "dashmap", + "dynify", + "fast-float2", + "float16", + "futures-channel", + "futures-concurrency", + "futures-lite", + "hashbrown 0.16.1", + "icu_normalizer", + "indexmap", + "intrusive-collections", + "itertools 0.14.0", + "num-bigint", + "num-integer", + "num-traits", + "num_enum", + "paste", + "portable-atomic", + "rand", + "regress", + "rustc-hash", + "ryu-js", + "serde", + "serde_json", + "small_btree", + "static_assertions", + "tag_ptr", + "tap", + "thin-vec", + "thiserror", + "time", + "xsum", +] + +[[package]] +name = "boa_gc" +version = "0.21.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f1179f690cbfcbe5364cceee5f1cb577265bb6f07b0be6f210aabe270adcf9da" +dependencies = [ + "boa_macros", + "boa_string", + "hashbrown 0.16.1", + "thin-vec", +] + +[[package]] +name = "boa_interner" +version = "0.21.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9626505d33dc63d349662437297df1d3afd9d5fc4a2b3ad34e5e1ce879a78848" +dependencies = [ + "boa_gc", + "boa_macros", + "hashbrown 0.16.1", + "indexmap", + "once_cell", + "phf", + "rustc-hash", + "static_assertions", +] + +[[package]] +name = "boa_macros" +version = "0.21.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f36418a46544b152632c141b0a0b7a453cd69ca150caeef83aee9e2f4b48b7d" +dependencies = [ + "cfg-if", + "cow-utils", + "proc-macro2", + "quote", + "syn", + "synstructure", +] + +[[package]] +name = "boa_parser" +version = "0.21.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "02f99bf5b684f0de946378fcfe5f38c3a0fbd51cbf83a0f39ff773a0e218541f" +dependencies = [ + "bitflags", + "boa_ast", + "boa_interner", + "boa_macros", + "fast-float2", + "icu_properties", + "num-bigint", + "num-traits", + "regress", + "rustc-hash", +] + +[[package]] +name = "boa_string" +version = "0.21.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "45ce9d7aa5563a2e14eab111e2ae1a06a69a812f6c0c3d843196c9d03fbef440" +dependencies = [ + "fast-float2", + "itoa", + "paste", + "rustc-hash", + "ryu-js", + "static_assertions", +] + [[package]] name = "bumpalo" version = "3.19.1" @@ -89,6 +266,26 @@ dependencies = [ "allocator-api2", ] +[[package]] +name = "bytemuck" +version = "1.24.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fbdf580320f38b612e485521afda1ee26d10cc9884efaaa750d383e13e3c5f4" +dependencies = [ + "bytemuck_derive", +] + +[[package]] +name = "bytemuck_derive" +version = "1.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f9abbd1bc6865053c427f7198e6af43bfdedc55ab791faed4fbd361d789575ff" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + [[package]] name = "cast" version = "0.3.0" @@ -106,9 +303,9 @@ dependencies = [ [[package]] name = "cc" -version = "1.2.47" +version = "1.2.52" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd405d82c84ff7f35739f175f67d8b9fb7687a0e84ccdc78bd3568839827cf07" +checksum = "cd4932aefd12402b36c60956a4fe0035421f544799057659ff86f923657aada3" dependencies = [ "find-msvc-tools", "shlex", @@ -149,18 +346,18 @@ dependencies = [ [[package]] name = "clap" -version = "4.5.53" +version = "4.5.54" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c9e340e012a1bf4935f5282ed1436d1489548e8f72308207ea5df0e23d2d03f8" +checksum = "c6e6ff9dcd79cff5cd969a17a545d79e84ab086e444102a591e288a8aa3ce394" dependencies = [ "clap_builder", ] [[package]] name = "clap_builder" -version = "4.5.53" +version = "4.5.54" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d76b5d13eaa18c901fd2f7fca939fefe3a0727a953561fefdf3b2922b8569d00" +checksum = "fa42cf4d2b7a41bc8f663a7cab4031ebafa1bf3875705bfaf8466dc60ab52c00" dependencies = [ "anstyle", "clap_lex", @@ -172,6 +369,15 @@ version = "0.7.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a1d728cc89cf3aee9ff92b05e62b19ee65a02b5702cff7d5a377e32c6ae29d8d" +[[package]] +name = "cobs" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fa961b519f0b462e3a3b4a34b64d119eeaca1d59af726fe450bbba07a9fc0a1" +dependencies = [ + "thiserror", +] + [[package]] name = "compact_str" version = "0.9.0" @@ -214,11 +420,29 @@ version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "417bef24afe1460300965a25ff4a24b8b45ad011948302ec221e8a0a81eb2c79" +[[package]] +name = "cpufeatures" +version = "0.2.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "59ed5838eebb26a2bb2e58f6d5b5316989ae9d08bab10e0e6d103e656d1b0280" +dependencies = [ + "libc", +] + +[[package]] +name = "crc32fast" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9481c1c90cbf2ac953f07c8d4a58aa3945c425b7185c9154d67a65e4230da511" +dependencies = [ + "cfg-if", +] + [[package]] name = "criterion" -version = "0.8.0" +version = "0.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a0dfe5e9e71bdcf4e4954f7d14da74d1cdb92a3a07686452d1509652684b1aab" +checksum = "4d883447757bb0ee46f233e9dc22eb84d93a9508c9b868687b274fc431d886bf" dependencies = [ "alloca", "anes", @@ -241,9 +465,9 @@ dependencies = [ [[package]] name = "criterion-plot" -version = "0.8.0" +version = "0.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5de36c2bee19fba779808f92bf5d9b0fa5a40095c277aba10c458a12b35d21d6" +checksum = "ed943f81ea2faa8dcecbbfa50164acf95d555afec96a27871663b300e387b2e4" dependencies = [ "cast", "itertools 0.13.0", @@ -280,6 +504,16 @@ version = "0.2.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "460fbee9c2c2f33933d720630a6a0bac33ba7053db5344fac858d4b8952d77d5" +[[package]] +name = "crypto-common" +version = "0.1.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "78c8292055d1c1df0cce5d180393dc8cce0abec0a7102adb6c7b1eef6016d60a" +dependencies = [ + "generic-array", + "typenum", +] + [[package]] name = "css" version = "0.1.0" @@ -293,6 +527,29 @@ dependencies = [ "serial_test", ] +[[package]] +name = "dashmap" +version = "6.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5041cc499144891f3790297212f32a74fb938e5136a14943f338ef9e0ae276cf" +dependencies = [ + "cfg-if", + "crossbeam-utils", + "hashbrown 0.14.5", + "lock_api", + "once_cell", + "parking_lot_core", +] + +[[package]] +name = "deranged" +version = "0.5.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ececcb659e7ba858fb4f10388c250a7252eb0a27373f1a72b8748afdd248e587" +dependencies = [ + "powerfmt", +] + [[package]] name = "devup-ui-wasm" version = "0.1.0" @@ -301,6 +558,7 @@ dependencies = [ "console_error_panic_hook", "css", "extractor", + "getrandom", "insta", "js-sys", "once_cell", @@ -313,24 +571,97 @@ dependencies = [ "wasm-bindgen-test", ] +[[package]] +name = "digest" +version = "0.10.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" +dependencies = [ + "block-buffer", + "crypto-common", +] + +[[package]] +name = "displaydoc" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + [[package]] name = "dragonbox_ecma" version = "0.0.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d742b56656e8b14d63e7ea9806597b1849ae25412584c8adf78c0f67bd985e66" +[[package]] +name = "dynify" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "81acb15628a3e22358bf73de5e7e62360b8a777dbcb5fc9ac7dfa9ae73723747" +dependencies = [ + "dynify-macros", +] + +[[package]] +name = "dynify-macros" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1ec431cd708430d5029356535259c5d645d60edd3d39c54e5eea9782d46caa7d" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + [[package]] name = "either" version = "1.15.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "48c757948c5ede0e46177b7add2e67155f70e33c07fea8284df6576da70b3719" +[[package]] +name = "embedded-io" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ef1a6892d9eef45c8fa6b9e0086428a2cca8491aca8f787c534a3d6d0bcb3ced" + +[[package]] +name = "embedded-io" +version = "0.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "edd0f118536f44f5ccd48bcb8b111bdc3de888b58c74639dfb034a357d0f206d" + [[package]] name = "encode_unicode" version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "34aa73646ffb006b8f5147f3dc182bd4bcb190227ce861fc4a4844bf8e3cb2c0" +[[package]] +name = "equator" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4711b213838dfee0117e3be6ac926007d7f433d7bbe33595975d4190cb07e6fc" +dependencies = [ + "equator-macro", +] + +[[package]] +name = "equator-macro" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "44f23cf4b44bfce11a86ace86f8a73ffdec849c9fd00a386a53d278bd9e81fb3" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + [[package]] name = "equivalent" version = "1.0.2" @@ -351,6 +682,7 @@ dependencies = [ name = "extractor" version = "0.1.0" dependencies = [ + "boa_engine", "css", "insta", "oxc_allocator", @@ -358,15 +690,24 @@ dependencies = [ "oxc_ast_visit", "oxc_codegen", "oxc_parser", + "oxc_semantic", "oxc_span", "oxc_syntax", + "oxc_transformer", "phf", "rstest", + "serde_json", "serial_test", "strum", "strum_macros", ] +[[package]] +name = "fast-float2" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8eb564c5c7423d25c886fb561d1e4ee69f72354d16918afa32c08811f6b6a55" + [[package]] name = "fastrand" version = "2.3.0" @@ -375,25 +716,42 @@ checksum = "37909eebbb50d72f9059c3b6d82c0463f2ff062c9e95845c43a6c9c0355411be" [[package]] name = "find-msvc-tools" -version = "0.1.5" +version = "0.1.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3a3076410a55c90011c298b04d0cfa770b00fa04e1e3c97d3f6c9de105a03844" +checksum = "f449e6c6c08c865631d4890cfacf252b3d396c9bcc83adb6623cdb02a8336c41" [[package]] -name = "futures" -version = "0.3.31" +name = "fixedbitset" +version = "0.5.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "65bc07b1a8bc7c85c5f2e110c476c7389b4554ba72af57d8445ea63a576b0876" +checksum = "1d674e81391d1e1ab681a28d99df07927c6d4aa5b027d7da16ba32d1d21ecd99" + +[[package]] +name = "flate2" +version = "1.1.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b375d6465b98090a5f25b1c7703f3859783755aa9a80433b36e0379a3ec2f369" dependencies = [ - "futures-channel", - "futures-core", - "futures-executor", - "futures-io", - "futures-sink", - "futures-task", - "futures-util", + "crc32fast", + "miniz_oxide", +] + +[[package]] +name = "float16" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7bffafbd079d520191c7c2779ae9cf757601266cf4167d3f659ff09617ff8483" +dependencies = [ + "cfg-if", + "rustc_version 0.2.3", ] +[[package]] +name = "foldhash" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77ce24cb58228fbb8aa041425bb1050850ac19177686ea6e0f41a70416f56fdb" + [[package]] name = "futures-channel" version = "0.3.31" @@ -401,7 +759,19 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2dff15bf788c671c1934e366d07e30c1814a8ef514e1af724a602e8a2fbe1b10" dependencies = [ "futures-core", - "futures-sink", +] + +[[package]] +name = "futures-concurrency" +version = "7.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "69a9561702beff46b705a8ac9c0803ec4c7fc5d01330a99b1feaf86e206e92ba" +dependencies = [ + "fixedbitset", + "futures-core", + "futures-lite", + "pin-project", + "smallvec", ] [[package]] @@ -427,6 +797,19 @@ version = "0.3.31" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9e5c1b78ca4aae1ac06c48a526a655760685149f0d465d21f37abfe57ce075c6" +[[package]] +name = "futures-lite" +version = "2.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f78e10609fe0e0b3f4157ffab1876319b5b0db102a2c60dc4626306dc46b44ad" +dependencies = [ + "fastrand", + "futures-core", + "futures-io", + "parking", + "pin-project-lite", +] + [[package]] name = "futures-macro" version = "0.3.31" @@ -438,12 +821,6 @@ dependencies = [ "syn", ] -[[package]] -name = "futures-sink" -version = "0.3.31" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e575fab7d1e0dcb8d0c7bcf9a63ee213816ab51902e6d244a95819acacf1d4f7" - [[package]] name = "futures-task" version = "0.3.31" @@ -462,18 +839,24 @@ version = "0.3.31" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9fa08315bb612088cc391249efdc3bc77536f16c91f6cf495e6fbe85b20a4a81" dependencies = [ - "futures-channel", "futures-core", - "futures-io", "futures-macro", - "futures-sink", "futures-task", - "memchr", "pin-project-lite", "pin-utils", "slab", ] +[[package]] +name = "generic-array" +version = "0.14.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" +dependencies = [ + "typenum", + "version_check", +] + [[package]] name = "getrandom" version = "0.3.4" @@ -481,9 +864,11 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "899def5c37c4fd7b2664648c28120ecec138e4d395b459e5ca34f9cce2dd77fd" dependencies = [ "cfg-if", + "js-sys", "libc", "r-efi", "wasip2", + "wasm-bindgen", ] [[package]] @@ -503,6 +888,12 @@ dependencies = [ "zerocopy", ] +[[package]] +name = "hashbrown" +version = "0.14.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" + [[package]] name = "hashbrown" version = "0.16.1" @@ -510,6 +901,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "841d1cc9bed7f9236f321df977030373f4a4163ae1a7dbfe1a51a2c1a51d9100" dependencies = [ "allocator-api2", + "equivalent", + "foldhash", ] [[package]] @@ -518,21 +911,110 @@ version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" +[[package]] +name = "icu_collections" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "200072f5d0e3614556f94a9930d5dc3e0662a652823904c3a75dc3b0af7fee47" +dependencies = [ + "displaydoc", + "potential_utf", + "yoke", + "zerofrom", + "zerovec", +] + +[[package]] +name = "icu_locale_core" +version = "2.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "edba7861004dd3714265b4db54a3c390e880ab658fec5f7db895fae2046b5bb6" +dependencies = [ + "displaydoc", + "litemap", + "serde", + "tinystr", + "writeable", + "zerovec", +] + +[[package]] +name = "icu_normalizer" +version = "2.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8b24a59706036ba941c9476a55cd57b82b77f38a3c667d637ee7cabbc85eaedc" +dependencies = [ + "displaydoc", + "icu_collections", + "icu_normalizer_data", + "icu_properties", + "icu_provider", + "smallvec", + "utf16_iter", + "write16", + "zerovec", +] + +[[package]] +name = "icu_normalizer_data" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "00210d6893afc98edb752b664b8890f0ef174c8adbb8d0be9710fa66fbbf72d3" + +[[package]] +name = "icu_properties" +version = "2.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f5a97b8ac6235e69506e8dacfb2adf38461d2ce6d3e9bd9c94c4cbc3cd4400a4" +dependencies = [ + "displaydoc", + "icu_collections", + "icu_locale_core", + "icu_properties_data", + "icu_provider", + "potential_utf", + "zerotrie", + "zerovec", +] + +[[package]] +name = "icu_properties_data" +version = "2.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "298459143998310acd25ffe6810ed544932242d3f07083eee1084d83a71bd632" + +[[package]] +name = "icu_provider" +version = "2.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85962cf0ce02e1e0a629cc34e7ca3e373ce20dda4c4d7294bbd0bf1fdb59e614" +dependencies = [ + "displaydoc", + "icu_locale_core", + "serde", + "stable_deref_trait", + "writeable", + "yoke", + "zerofrom", + "zerotrie", + "zerovec", +] + [[package]] name = "indexmap" -version = "2.12.0" +version = "2.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6717a8d2a5a929a1a2eb43a12812498ed141a0bcfb7e8f7844fbdbe4303bba9f" +checksum = "7714e70437a7dc3ac8eb7e6f8df75fd8eb422675fc7678aff7364301092b1017" dependencies = [ "equivalent", - "hashbrown", + "hashbrown 0.16.1", ] [[package]] name = "insta" -version = "1.45.1" +version = "1.46.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "983e3b24350c84ab8a65151f537d67afbbf7153bb9f1110e03e9fa9b07f67a5c" +checksum = "1b66886d14d18d420ab5052cbff544fc5d34d0b2cdd35eb5976aaa10a4a472e5" dependencies = [ "console", "once_cell", @@ -540,6 +1022,15 @@ dependencies = [ "tempfile", ] +[[package]] +name = "intrusive-collections" +version = "0.9.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "189d0897e4cbe8c75efedf3502c18c887b05046e59d28404d4d8e46cbc4d1e86" +dependencies = [ + "memoffset", +] + [[package]] name = "itertools" version = "0.13.0" @@ -582,9 +1073,9 @@ checksum = "a3c2a6c0b4b5637c41719973ef40c6a1cf564f9db6958350de6193fbee9c23f5" [[package]] name = "libc" -version = "0.2.178" +version = "0.2.180" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37c93d8daa9d8a012fd8ab92f088405fb202ea0b6ab73ee2482ae66af4f42091" +checksum = "bcc35a38544a891a5f7c865aca548a982ccb3b8650a5b06d0fd33a10283c56fc" [[package]] name = "libm" @@ -598,6 +1089,12 @@ version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "df1d3c3b53da64cf5760482273a98e575c651a67eec7f77df96b5b642de8f039" +[[package]] +name = "litemap" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6373607a59f0be73a39b6fe456b8192fcc3585f602af20751600e974dd455e77" + [[package]] name = "lock_api" version = "0.4.14" @@ -609,9 +1106,9 @@ dependencies = [ [[package]] name = "log" -version = "0.4.28" +version = "0.4.29" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34080505efa8e45a4b816c349525ebe327ceaa8559756f0356cba97ef3bf7432" +checksum = "5e5032e24019045c762d3c0f28f5b6b8bbf38563a65908389bf7978758920897" [[package]] name = "memchr" @@ -619,16 +1116,44 @@ version = "2.7.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f52b00d39961fc5b2736ea853c9cc86238e165017a493d1d5c8eac6bdc4cc273" +[[package]] +name = "memoffset" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "488016bfae457b036d996092f6cb448677611ce4449e970ceaf42695203f218a" +dependencies = [ + "autocfg", +] + [[package]] name = "minicov" -version = "0.3.7" +version = "0.3.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f27fe9f1cc3c22e1687f9446c2083c4c5fc7f0bcf1c7a86bdbded14985895b4b" +checksum = "4869b6a491569605d66d3952bcdf03df789e5b536e5f0cf7758a7f08a55ae24d" dependencies = [ "cc", "walkdir", ] +[[package]] +name = "miniz_oxide" +version = "0.8.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fa76a2c86f704bdb222d66965fb3d63269ce38518b83cb0575fca855ebb6316" +dependencies = [ + "adler2", + "simd-adler32", +] + +[[package]] +name = "nom" +version = "8.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "df9761775871bdef83bee530e60050f7e54b1105350d6884eb0fb4f46c2f9405" +dependencies = [ + "memchr", +] + [[package]] name = "nonmax" version = "0.5.5" @@ -652,8 +1177,15 @@ checksum = "a5e44f723f1133c9deac646763579fdb3ac745e418f2a7af9cd0c431da1f20b9" dependencies = [ "num-integer", "num-traits", + "serde", ] +[[package]] +name = "num-conv" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "51d515d32fb182ee37cda2ccdcb92950d6a3c2893aa280e540671c2cd0f3b1d9" + [[package]] name = "num-integer" version = "0.1.46" @@ -673,6 +1205,37 @@ dependencies = [ "libm", ] +[[package]] +name = "num_enum" +version = "0.7.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b1207a7e20ad57b847bbddc6776b968420d38292bbfe2089accff5e19e82454c" +dependencies = [ + "num_enum_derive", + "rustversion", +] + +[[package]] +name = "num_enum_derive" +version = "0.7.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff32365de1b6743cb203b710788263c44a03de03802daf96092f2da4fe6ba4d7" +dependencies = [ + "proc-macro-crate", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "num_threads" +version = "0.1.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5c7398b9c8b70908f6371f47ed36737907c87c52af34c268fed0bf0ceb92ead9" +dependencies = [ + "libc", +] + [[package]] name = "once_cell" version = "1.21.3" @@ -697,11 +1260,27 @@ version = "4.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9c6901729fa79e91a0913333229e9ca5dc725089d1c363b2f4b4760709dc4a52" +[[package]] +name = "oxc-browserslist" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "23d55ecaab3af16fee2d0195f2e7d26f27cab0044d0b6d74073514c7feee6beb" +dependencies = [ + "flate2", + "nom", + "postcard", + "rustc-hash", + "serde", + "serde_json", + "thiserror", + "time", +] + [[package]] name = "oxc-miette" -version = "2.6.0" +version = "2.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f02105a875f3751a0b44b4c822b01177728dd9049ae6fb419e9b04887d730ed1" +checksum = "60a7ba54c704edefead1f44e9ef09c43e5cfae666bdc33516b066011f0e6ebf7" dependencies = [ "cfg-if", "owo-colors", @@ -714,9 +1293,9 @@ dependencies = [ [[package]] name = "oxc-miette-derive" -version = "2.6.0" +version = "2.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "003b4612827f6501183873fb0735da92157e3c7daa71c40921c7d2758fec2229" +checksum = "d4faecb54d0971f948fbc1918df69b26007e6f279a204793669542e1e8b75eb3" dependencies = [ "proc-macro2", "quote", @@ -725,22 +1304,22 @@ dependencies = [ [[package]] name = "oxc_allocator" -version = "0.106.0" +version = "0.108.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "07f4ba3148223230c546c1064c2795ece78b647ca75c9e98d42418dd4d5e4cd7" +checksum = "78958640bcae9b5b42f9eaafe4995b5460195e961439c236095547bb78952f8d" dependencies = [ "allocator-api2", "bumpalo", - "hashbrown", + "hashbrown 0.16.1", "oxc_data_structures", "rustc-hash", ] [[package]] name = "oxc_ast" -version = "0.106.0" +version = "0.108.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "33a08c611e6a481bc573c4050708f418da9ae8f09c4fac5c295c86cca6bbd1ed" +checksum = "e0d1a3c841ad6204dcdba2e584efbff30ec7a5a2c88851108dd39a2ed4be3af3" dependencies = [ "bitflags", "oxc_allocator", @@ -755,9 +1334,9 @@ dependencies = [ [[package]] name = "oxc_ast_macros" -version = "0.106.0" +version = "0.108.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3788ddf2f5da12f0eca87c849bc33016b4bf11eea2b92980bb751e0b6a83b51a" +checksum = "3fc4d7eb802fc2bfc49fdc004e875a4009c17657f53372af111eb9d98dc4a15f" dependencies = [ "phf", "proc-macro2", @@ -767,9 +1346,9 @@ dependencies = [ [[package]] name = "oxc_ast_visit" -version = "0.106.0" +version = "0.108.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c58fd9b2c7697eb1dea5d30d4ae575de810c27a414396542321e292feac0c22" +checksum = "561ace6525ddc90b36103764a959eb261ff7f92a76172a34ac2d24d579f1260d" dependencies = [ "oxc_allocator", "oxc_ast", @@ -779,9 +1358,9 @@ dependencies = [ [[package]] name = "oxc_codegen" -version = "0.106.0" +version = "0.108.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "31ce1592b043fe06b69d934902fb156ddb719716f4f79c505adbaf078700d4f2" +checksum = "0a075130a060ebc4bcf09a55fcf521243527a820937dccda4af92524d4c3def2" dependencies = [ "bitflags", "cow-utils", @@ -798,17 +1377,33 @@ dependencies = [ "rustc-hash", ] +[[package]] +name = "oxc_compat" +version = "0.108.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c4df14ee33385dff8fc347c6ddb62b8c7168c4abf6957deec8415575e0f0f2e3" +dependencies = [ + "cow-utils", + "oxc-browserslist", + "oxc_syntax", + "rustc-hash", + "serde", +] + [[package]] name = "oxc_data_structures" -version = "0.106.0" +version = "0.108.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8c6253c51f3836c35d932153398aa7582706f8e39876eae0d7163311f419afc1" +checksum = "397842ac155f7c3f707232cc8758c0e67919ac7f75ec3bc34680ae176aca8b61" +dependencies = [ + "ropey", +] [[package]] name = "oxc_diagnostics" -version = "0.106.0" +version = "0.108.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fbdefb78ab7e05e0ed1301f914905292542633fb6129da67ce82a9d3c87921c4" +checksum = "2739661b22eb7abe3966ebbe1eb236337f940eed7e9598bdb089c3353aa2c15f" dependencies = [ "cow-utils", "oxc-miette", @@ -817,9 +1412,9 @@ dependencies = [ [[package]] name = "oxc_ecmascript" -version = "0.106.0" +version = "0.108.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f845e02047887b1e4af5da1201b6d10f097f722e00cb5f7082bc847aa40f15ec" +checksum = "ef913bdaae2ed48335b500a25ecc6a9f186ca855968b5edfc6d1ebad4d0b2124" dependencies = [ "cow-utils", "num-bigint", @@ -832,9 +1427,9 @@ dependencies = [ [[package]] name = "oxc_estree" -version = "0.106.0" +version = "0.108.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd69fedb2ea8754a153e979e90fe31efed28789ead73d6d6fd69eb9025c729af" +checksum = "a61584ac8cd52d6b6c05a7a5d4b883d5666ea4612ddfe3429f28f7bcd1e93a14" [[package]] name = "oxc_index" @@ -848,9 +1443,9 @@ dependencies = [ [[package]] name = "oxc_parser" -version = "0.106.0" +version = "0.108.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ec8d0fd27fffd5742181d1ca76450e25ae51a69dffbbe2076231173b262ab31" +checksum = "06898c992b263f8e4dfcc338528445492a8d61292ad78a0ad7863a265e7beda2" dependencies = [ "bitflags", "cow-utils", @@ -871,9 +1466,9 @@ dependencies = [ [[package]] name = "oxc_regular_expression" -version = "0.106.0" +version = "0.108.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4af1f85405275d20352a69e7caaa44a28d03ba91ecc951ec79a1bf3016062d7" +checksum = "7c658b8d107d9534816312d1fd4b77311df648d07ac8af0417355a8cbb09749b" dependencies = [ "bitflags", "oxc_allocator", @@ -887,11 +1482,12 @@ dependencies = [ [[package]] name = "oxc_semantic" -version = "0.106.0" +version = "0.108.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac84d63f0e43359f38af2478a7d20cc0aecb780de46cada3f14d8ead6c89bf8c" +checksum = "7ef9534d21d00ac38ca4eab91e7b7f4fa0f1c7f0279d07865074c05357366d5c" dependencies = [ "itertools 0.14.0", + "memchr", "oxc_allocator", "oxc_ast", "oxc_ast_visit", @@ -901,9 +1497,9 @@ dependencies = [ "oxc_index", "oxc_span", "oxc_syntax", - "phf", "rustc-hash", "self_cell", + "smallvec", ] [[package]] @@ -921,9 +1517,9 @@ dependencies = [ [[package]] name = "oxc_span" -version = "0.106.0" +version = "0.108.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "32556c52175b0c616e44efa6c37f532c6a4c3a213761a10ed1b9beb3d3136a78" +checksum = "3416e347dd4837cdfbffc49bd2ef106ba592133268a962381cc82d24e8593e40" dependencies = [ "compact_str", "oxc-miette", @@ -933,23 +1529,70 @@ dependencies = [ ] [[package]] -name = "oxc_syntax" -version = "0.106.0" +name = "oxc_syntax" +version = "0.108.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c44aa646ecb431595b3255b6eee2a7f9f292422b76cf5c156a825bd042073453" +dependencies = [ + "bitflags", + "cow-utils", + "dragonbox_ecma", + "nonmax", + "oxc_allocator", + "oxc_ast_macros", + "oxc_data_structures", + "oxc_estree", + "oxc_index", + "oxc_span", + "phf", + "unicode-id-start", +] + +[[package]] +name = "oxc_transformer" +version = "0.108.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "118d7149205362a9ab9de91112f36c13e4192db5036d5cad7cc083a849146450" +dependencies = [ + "base64", + "compact_str", + "indexmap", + "itoa", + "memchr", + "oxc_allocator", + "oxc_ast", + "oxc_ast_visit", + "oxc_compat", + "oxc_data_structures", + "oxc_diagnostics", + "oxc_ecmascript", + "oxc_regular_expression", + "oxc_semantic", + "oxc_span", + "oxc_syntax", + "oxc_traverse", + "rustc-hash", + "serde", + "serde_json", + "sha1", +] + +[[package]] +name = "oxc_traverse" +version = "0.108.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c5b2154749e8d2bf8ac77bfdf9f7e9912c4cb9b63ddfcc63841838a3be48d1a" +checksum = "0b0c8dc012307ff62260d1f9f3073d4933c5f7e0a01e479f52f6ddd2a487154b" dependencies = [ - "bitflags", - "cow-utils", - "dragonbox_ecma", - "nonmax", + "itoa", "oxc_allocator", - "oxc_ast_macros", + "oxc_ast", + "oxc_ast_visit", "oxc_data_structures", - "oxc_estree", - "oxc_index", + "oxc_ecmascript", + "oxc_semantic", "oxc_span", - "phf", - "unicode-id-start", + "oxc_syntax", + "rustc-hash", ] [[package]] @@ -962,6 +1605,12 @@ dependencies = [ "winapi", ] +[[package]] +name = "parking" +version = "2.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f38d5652c16fde515bb1ecef450ab0f6a219d619a7274976324d5e377f7dceba" + [[package]] name = "parking_lot" version = "0.12.5" @@ -985,6 +1634,12 @@ dependencies = [ "windows-link", ] +[[package]] +name = "paste" +version = "1.0.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "57c0d7b74b563b49d38dae00a0c37d4d6de9b432382b2892f0574ddcae73fd0a" + [[package]] name = "percent-encoding" version = "2.3.2" @@ -1034,6 +1689,26 @@ dependencies = [ "siphasher", ] +[[package]] +name = "pin-project" +version = "1.1.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "677f1add503faace112b9f1373e43e9e054bfdd22ff1a63c1bc485eaec6a6a8a" +dependencies = [ + "pin-project-internal", +] + +[[package]] +name = "pin-project-internal" +version = "1.1.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6e918e4ff8c4549eb882f14b3a4bc8c8bc93de829416eacf579f1207a8fbf861" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + [[package]] name = "pin-project-lite" version = "0.2.16" @@ -1074,6 +1749,48 @@ dependencies = [ "plotters-backend", ] +[[package]] +name = "portable-atomic" +version = "1.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f89776e4d69bb58bc6993e99ffa1d11f228b839984854c7daeb5d37f87cbe950" + +[[package]] +name = "postcard" +version = "1.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6764c3b5dd454e283a30e6dfe78e9b31096d9e32036b5d1eaac7a6119ccb9a24" +dependencies = [ + "cobs", + "embedded-io 0.4.0", + "embedded-io 0.6.1", + "serde", +] + +[[package]] +name = "potential_utf" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b73949432f5e2a09657003c25bca5e19a0e9c84f8058ca374f49e0ebe605af77" +dependencies = [ + "zerovec", +] + +[[package]] +name = "powerfmt" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "439ee305def115ba05938db6eb1644ff94165c5ab5e9420d1c1bcedbba909391" + +[[package]] +name = "ppv-lite86" +version = "0.2.21" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85eae3c4ed2f50dcfe72643da4befc30deadb458a9b590d720cde2f2b1e97da9" +dependencies = [ + "zerocopy", +] + [[package]] name = "proc-macro-crate" version = "3.4.0" @@ -1085,18 +1802,18 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.104" +version = "1.0.105" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9695f8df41bb4f3d222c95a67532365f569318332d03d5f3f67f37b20e6ebdf0" +checksum = "535d180e0ecab6268a3e718bb9fd44db66bbbc256257165fc699dadf70d16fe7" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.42" +version = "1.0.43" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a338cc41d27e6cc6dce6cefc13a0729dfbb81c262b1f519331575dd80ef3067f" +checksum = "dc74d9a594b72ae6656596548f56f667211f8a97b3d4c3d467150794690dc40a" dependencies = [ "proc-macro2", ] @@ -1107,6 +1824,35 @@ version = "5.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "69cdb34c158ceb288df11e18b4bd39de994f6657d83847bdffdbd7f346754b0f" +[[package]] +name = "rand" +version = "0.9.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6db2770f06117d490610c7488547d543617b21bfa07796d7a12f6f1bd53850d1" +dependencies = [ + "rand_chacha", + "rand_core", +] + +[[package]] +name = "rand_chacha" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3022b5f1df60f26e1ffddd6c66e8aa15de382ae63b3a0c1bfc0e4d3e3f325cb" +dependencies = [ + "ppv-lite86", + "rand_core", +] + +[[package]] +name = "rand_core" +version = "0.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4f1b3bc831f92381018fd9c6350b917c7b21f1eed35a65a51900e0e55a3d7afa" +dependencies = [ + "getrandom", +] + [[package]] name = "rayon" version = "1.11.0" @@ -1165,12 +1911,32 @@ version = "0.8.8" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7a2d987857b319362043e95f5353c0535c1f58eec5336fdfcf626430af7def58" +[[package]] +name = "regress" +version = "0.10.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2057b2325e68a893284d1538021ab90279adac1139957ca2a74426c6f118fb48" +dependencies = [ + "hashbrown 0.16.1", + "memchr", +] + [[package]] name = "relative-path" version = "1.9.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ba39f3699c378cd8970968dcbff9c43159ea4cfbd88d43c00b22f2ef10a435d2" +[[package]] +name = "ropey" +version = "1.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93411e420bcd1a75ddd1dc3caf18c23155eda2c090631a85af21ba19e97093b5" +dependencies = [ + "smallvec", + "str_indices", +] + [[package]] name = "rstest" version = "0.26.1" @@ -1195,7 +1961,7 @@ dependencies = [ "quote", "regex", "relative-path", - "rustc_version", + "rustc_version 0.4.1", "syn", "unicode-ident", ] @@ -1206,13 +1972,22 @@ version = "2.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "357703d41365b4b27c590e3ed91eabb1b663f07c4c084095e60cbed4362dff0d" +[[package]] +name = "rustc_version" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "138e3e0acb6c9fb258b19b67cb8abd63c00679d2851805ea151465464fe9030a" +dependencies = [ + "semver 0.9.0", +] + [[package]] name = "rustc_version" version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cfcb3a22ef46e85b45de6ee7e79d063319ebb6594faafcf1c225ea92ab6e9b92" dependencies = [ - "semver", + "semver 1.0.27", ] [[package]] @@ -1240,6 +2015,12 @@ version = "1.0.22" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a50f4cf475b65d88e057964e0e9bb1f0aa9bbb2036dc65c64596b42932536984" +[[package]] +name = "ryu-js" +version = "1.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dd29631678d6fb0903b69223673e122c32e9ae559d0960a38d574695ebc0ea15" + [[package]] name = "same-file" version = "1.0.6" @@ -1272,9 +2053,18 @@ checksum = "490dcfcbfef26be6800d11870ff2df8774fa6e86d047e3e8c8a76b25655e41ca" [[package]] name = "self_cell" -version = "1.2.1" +version = "1.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b12e76d157a900eb52e81bc6e9f3069344290341720e9178cde2407113ac8d89" + +[[package]] +name = "semver" +version = "0.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "16c2f82143577edb4921b71ede051dac62ca3c16084e918bf7b40c96ae10eb33" +checksum = "1d7eb9ef2c18661902cc47e535f9bc51b78acd254da71d375c2f6720d9a40403" +dependencies = [ + "semver-parser", +] [[package]] name = "semver" @@ -1282,6 +2072,12 @@ version = "1.0.27" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d767eb0aabc880b29956c35734170f26ed551a859dbd361d140cdbeca61ab1e2" +[[package]] +name = "semver-parser" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "388a1df253eca08550bef6c72392cfe7c30914bf41df5269b68cbd6ff8f570a3" + [[package]] name = "seq-macro" version = "0.3.6" @@ -1331,9 +2127,9 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.148" +version = "1.0.149" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3084b546a1dd6289475996f182a22aba973866ea8e8b02c51d9f46b1336a22da" +checksum = "83fc039473c5595ace860d8c4fafa220ff474b3fc6bfdb4293327f1a37e94d86" dependencies = [ "itoa", "memchr", @@ -1344,11 +2140,12 @@ dependencies = [ [[package]] name = "serial_test" -version = "3.2.0" +version = "3.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b258109f244e1d6891bf1053a55d63a5cd4f8f4c30cf9a1280989f80e7a1fa9" +checksum = "0d0b343e184fc3b7bb44dff0705fffcf4b3756ba6aff420dddd8b24ca145e555" dependencies = [ - "futures", + "futures-executor", + "futures-util", "log", "once_cell", "parking_lot", @@ -1358,15 +2155,26 @@ dependencies = [ [[package]] name = "serial_test_derive" -version = "3.2.0" +version = "3.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d69265a08751de7844521fd15003ae0a888e035773ba05695c5c759a6f89eef" +checksum = "6f50427f258fb77356e4cd4aa0e87e2bd2c66dbcee41dc405282cae2bfc26c83" dependencies = [ "proc-macro2", "quote", "syn", ] +[[package]] +name = "sha1" +version = "0.10.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e3bf829a2d51ab4a5ddf1352d8470c140cadc8301b2ae1789db023f01cedd6ba" +dependencies = [ + "cfg-if", + "cpufeatures", + "digest", +] + [[package]] name = "sheet" version = "0.1.0" @@ -1388,6 +2196,12 @@ version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0fda2ff0d084019ba4d7c6f371c95d8fd75ce3524c3cb8fb653a3023f6323e64" +[[package]] +name = "simd-adler32" +version = "0.3.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e320a6c5ad31d271ad523dcf3ad13e2767ad8b1cb8f047f75a8aeaf8da139da2" + [[package]] name = "similar" version = "2.7.0" @@ -1406,11 +2220,23 @@ version = "0.4.11" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7a2ae44ef20feb57a68b23d846850f861394c2e02dc425a50098ae8c90267589" +[[package]] +name = "small_btree" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0ba60d2df92ba73864714808ca68c059734853e6ab722b40e1cf543ebb3a057a" +dependencies = [ + "arrayvec", +] + [[package]] name = "smallvec" version = "1.15.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "67b1b7a3b5fe4f1376887184045fcf45c69e92af734b7aaddc05fb777b6fbd03" +dependencies = [ + "serde", +] [[package]] name = "smawk" @@ -1418,12 +2244,24 @@ version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b7c388c1b5e93756d0c740965c41e8822f866621d41acbdf6336a6a168f8840c" +[[package]] +name = "stable_deref_trait" +version = "1.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6ce2be8dc25455e1f91df71bfa12ad37d7af1092ae736f3a6cd0e37bc7810596" + [[package]] name = "static_assertions" version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" +[[package]] +name = "str_indices" +version = "0.4.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d08889ec5408683408db66ad89e0e1f93dff55c73a4ccc71c427d5b277ee47e6" + [[package]] name = "strum" version = "0.27.2" @@ -1444,15 +2282,38 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.112" +version = "2.0.114" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21f182278bf2d2bcb3c88b1b08a37df029d71ce3d3ae26168e3c653b213b99d4" +checksum = "d4d107df263a3013ef9b1879b0df87d706ff80f65a86ea879bd9c31f9b307c2a" dependencies = [ "proc-macro2", "quote", "unicode-ident", ] +[[package]] +name = "synstructure" +version = "0.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "728a70f3dbaf5bab7f0c4b1ac8d7ae5ea60a4b5549c8a5914361c99147a709d2" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "tag_ptr" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c0e973b34477b7823833469eb0f5a3a60370fef7a453e02d751b59180d0a5a05" + +[[package]] +name = "tap" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "55937e1799185b12863d447f42597ed69d9928686b8d88a1df17376a097d8369" + [[package]] name = "tempfile" version = "3.24.0" @@ -1477,6 +2338,12 @@ dependencies = [ "unicode-width", ] +[[package]] +name = "thin-vec" +version = "0.2.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "144f754d318415ac792f9d69fc87abbbfc043ce2ef041c60f16ad828f638717d" + [[package]] name = "thiserror" version = "2.0.17" @@ -1497,6 +2364,51 @@ dependencies = [ "syn", ] +[[package]] +name = "time" +version = "0.3.44" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91e7d9e3bb61134e77bde20dd4825b97c010155709965fedf0f49bb138e52a9d" +dependencies = [ + "deranged", + "itoa", + "js-sys", + "libc", + "num-conv", + "num_threads", + "powerfmt", + "serde", + "time-core", + "time-macros", +] + +[[package]] +name = "time-core" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "40868e7c1d2f0b8d73e4a8c7f0ff63af4f6d19be117e90bd73eb1d62cf831c6b" + +[[package]] +name = "time-macros" +version = "0.2.24" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "30cfb0125f12d9c277f35663a0a33f8c30190f4e4574868a330595412d34ebf3" +dependencies = [ + "num-conv", + "time-core", +] + +[[package]] +name = "tinystr" +version = "0.8.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "42d3e9c45c09de15d06dd8acf5f4e0e399e85927b7f00711024eb7ae10fa4869" +dependencies = [ + "displaydoc", + "serde_core", + "zerovec", +] + [[package]] name = "tinytemplate" version = "1.2.1" @@ -1509,18 +2421,18 @@ dependencies = [ [[package]] name = "toml_datetime" -version = "0.7.3" +version = "0.7.5+spec-1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f2cdb639ebbc97961c51720f858597f7f24c4fc295327923af55b74c3c724533" +checksum = "92e1cfed4a3038bc5a127e35a2d360f145e1f4b971b551a2ba5fd7aedf7e1347" dependencies = [ "serde_core", ] [[package]] name = "toml_edit" -version = "0.23.7" +version = "0.23.10+spec-1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6485ef6d0d9b5d0ec17244ff7eb05310113c3f316f2d14200d4de56b3cb98f8d" +checksum = "84c8b9f757e028cee9fa244aea147aab2a9ec09d5325a9b01e0a49730c2b5269" dependencies = [ "indexmap", "toml_datetime", @@ -1530,13 +2442,19 @@ dependencies = [ [[package]] name = "toml_parser" -version = "1.0.4" +version = "1.0.6+spec-1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c0cbe268d35bdb4bb5a56a2de88d0ad0eb70af5384a99d648cd4b3d04039800e" +checksum = "a3198b4b0a8e11f09dd03e133c0280504d0801269e9afa46362ffde1cbeebf44" dependencies = [ "winnow", ] +[[package]] +name = "typenum" +version = "1.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "562d481066bde0658276a35467c4af00bdc6ee726305698a55b86e61d7ad82bb" + [[package]] name = "unicode-id-start" version = "1.4.0" @@ -1567,6 +2485,18 @@ version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b4ac048d71ede7ee76d585517add45da530660ef4390e49b098733c6e897f254" +[[package]] +name = "utf16_iter" +version = "1.0.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c8232dd3cdaed5356e0f716d285e4b40b932ac434100fe9b7e0e8e935b9e6246" + +[[package]] +name = "version_check" +version = "0.9.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a" + [[package]] name = "vsimd" version = "0.8.0" @@ -1813,9 +2743,9 @@ checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec" [[package]] name = "winnow" -version = "0.7.13" +version = "0.7.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21a0236b59786fed61e2a80582dd500fe61f18b5dca67a4a067d0bc9039339cf" +checksum = "5a5364e9d77fcdeeaa6062ced926ee3381faa2ee02d3eb83a5c27a8825540829" dependencies = [ "memchr", ] @@ -1826,20 +2756,116 @@ version = "0.46.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f17a85883d4e6d00e8a97c586de764dabcc06133f7f1d55dce5cdc070ad7fe59" +[[package]] +name = "write16" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d1890f4022759daae28ed4fe62859b1236caebfc61ede2f63ed4e695f3f6d936" + +[[package]] +name = "writeable" +version = "0.6.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9edde0db4769d2dc68579893f2306b26c6ecfbe0ef499b013d731b7b9247e0b9" + +[[package]] +name = "xsum" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0637d3a5566a82fa5214bae89087bc8c9fb94cd8e8a3c07feb691bb8d9c632db" + +[[package]] +name = "yoke" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "72d6e5c6afb84d73944e5cedb052c4680d5657337201555f9f2a16b7406d4954" +dependencies = [ + "stable_deref_trait", + "yoke-derive", + "zerofrom", +] + +[[package]] +name = "yoke-derive" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b659052874eb698efe5b9e8cf382204678a0086ebf46982b79d6ca3182927e5d" +dependencies = [ + "proc-macro2", + "quote", + "syn", + "synstructure", +] + [[package]] name = "zerocopy" -version = "0.8.30" +version = "0.8.33" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ea879c944afe8a2b25fef16bb4ba234f47c694565e97383b36f3a878219065c" +checksum = "668f5168d10b9ee831de31933dc111a459c97ec93225beb307aed970d1372dfd" dependencies = [ "zerocopy-derive", ] [[package]] name = "zerocopy-derive" -version = "0.8.30" +version = "0.8.33" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2c7962b26b0a8685668b671ee4b54d007a67d4eaf05fda79ac0ecf41e32270f1" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "zerofrom" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "50cc42e0333e05660c3587f3bf9d0478688e15d870fab3346451ce7f8c9fbea5" +dependencies = [ + "zerofrom-derive", +] + +[[package]] +name = "zerofrom-derive" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d71e5d6e06ab090c67b5e44993ec16b72dcbaabc526db883a360057678b48502" +dependencies = [ + "proc-macro2", + "quote", + "syn", + "synstructure", +] + +[[package]] +name = "zerotrie" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2a59c17a5562d507e4b54960e8569ebee33bee890c70aa3fe7b97e85a9fd7851" +dependencies = [ + "displaydoc", + "yoke", + "zerofrom", +] + +[[package]] +name = "zerovec" +version = "0.11.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c28719294829477f525be0186d13efa9a3c602f7ec202ca9e353d310fb9a002" +dependencies = [ + "serde", + "yoke", + "zerofrom", + "zerovec-derive", +] + +[[package]] +name = "zerovec-derive" +version = "0.11.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf955aa904d6040f70dc8e9384444cb1030aed272ba3cb09bbc4ab9e7c1f34f5" +checksum = "eadce39539ca5cb3985590102671f2567e659fca9666581ad3411d59207951f3" dependencies = [ "proc-macro2", "quote", @@ -1848,6 +2874,6 @@ dependencies = [ [[package]] name = "zmij" -version = "1.0.8" +version = "1.0.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "317f17ff091ac4515f17cc7a190d2769a8c9a96d227de5d64b500b01cda8f2cd" +checksum = "ac93432f5b761b22864c774aac244fa5c0fd877678a4c37ebf6cf42208f9c9ec" diff --git a/SKILL.md b/SKILL.md index c287fc14..178653f4 100644 --- a/SKILL.md +++ b/SKILL.md @@ -86,16 +86,38 @@ All `@devup-ui/react` components (`Box`, `Flex`, `Text`, etc.) throw `Error('Can ## Styling APIs +### css() Returns className String (NOT object) + ```tsx import { css, styled, globalCss, keyframes } from "@devup-ui/react"; +import clsx from "clsx"; + +// css() returns a className STRING - use with className prop +const cardStyle = css({ bg: "white", p: 4, borderRadius: "8px" }); + // CORRECT -// Reusable style object -const cardStyles = css({ bg: "white", p: 4, borderRadius: "8px" }); - +// WRONG - css() is NOT an object to spread +// // ERROR! +// Combine multiple styles with clsx +const baseStyle = css({ p: 4, borderRadius: "8px" }); +const activeStyle = css({ bg: "$primary", color: "white" }); + + +// styleOrder={1} REQUIRED when mixing className with direct props + +``` + +### styled() API + +```tsx // Styled component (familiar styled-components/Emotion API) const Card = styled("div", { bg: "white", p: 4, _hover: { shadow: "lg" } }); +``` + +### globalCss() and keyframes() +```tsx // Global styles globalCss({ body: { margin: 0 }, "*": { boxSizing: "border-box" } }); @@ -120,7 +142,8 @@ const spin = keyframes({ from: { transform: "rotate(0)" }, to: { transform: "rot } ``` -Use with `$` prefix: `` +Use colors with `$` prefix: `` +Use typography without prefix: `` Theme API: ```tsx @@ -157,11 +180,47 @@ Options: DevupUI({ include: ["@devup/hello"] }) // required to extract and merge their styles ``` +## $color Token Scope + +`$color` tokens only work in **JSX props**. Use `var(--color)` in external objects. + +```tsx +// CORRECT - $color in JSX prop + + // inline object OK + +// WRONG - $color in external object (won't be transformed) +const colors = { active: '$primary' } // '$primary' stays as string literal + // broken! + +// CORRECT - var(--color) in external object +const colors = { active: 'var(--primary)' } + // works +``` + +## Inline Variant Pattern (Preferred) + +Use inline object indexing instead of external config objects: + +```tsx +// PREFERRED - inline object indexing + + +// AVOID - external config object +const sizeStyles = { lg: { h: '48px' }, md: { h: '40px' } } + // unnecessary indirection +``` + ## Anti-Patterns (NEVER do) | Wrong | Right | Why | |-------|-------|-----| | `` | `` | style prop bypasses extraction | +| `` | `` | css() returns string, not object | | `css({ bg: variable })` | `` | css()/globalCss() only accept static values | +| `$color` in external object | `var(--color)` in external object | $color only transformed in JSX props | | No build plugin configured | Configure plugin first | Components throw at runtime without transformation | | `as any` on style props | Fix types properly | Type errors indicate real issues | diff --git a/benchmark.js b/benchmark.js index 75795bc9..cbaebe8c 100644 --- a/benchmark.js +++ b/benchmark.js @@ -75,6 +75,16 @@ function clearBuildFile() { recursive: true, force: true, }) + if (existsSync('./benchmark/next-vanilla-extract-devup-ui/.next')) + rmSync('./benchmark/next-vanilla-extract-devup-ui/.next', { + recursive: true, + force: true, + }) + if (existsSync('./benchmark/next-vanilla-extract-devup-ui/df')) + rmSync('./benchmark/next-vanilla-extract-devup-ui/df', { + recursive: true, + force: true, + }) } function checkDirSize(path) { @@ -124,5 +134,6 @@ result.push(benchmark('devup-ui')) result.push(benchmark('devup-ui-single')) result.push(benchmark('tailwind-turbo')) result.push(benchmark('devup-ui-single-turbo')) +result.push(benchmark('vanilla-extract-devup-ui')) console.info(result.join('\n')) diff --git a/benchmark/next-vanilla-extract-devup-ui/.gitignore b/benchmark/next-vanilla-extract-devup-ui/.gitignore new file mode 100644 index 00000000..5ef6a520 --- /dev/null +++ b/benchmark/next-vanilla-extract-devup-ui/.gitignore @@ -0,0 +1,41 @@ +# See https://help.github.com/articles/ignoring-files/ for more about ignoring files. + +# dependencies +/node_modules +/.pnp +.pnp.* +.yarn/* +!.yarn/patches +!.yarn/plugins +!.yarn/releases +!.yarn/versions + +# testing +/coverage + +# next.js +/.next/ +/out/ + +# production +/build + +# misc +.DS_Store +*.pem + +# debug +npm-debug.log* +yarn-debug.log* +yarn-error.log* +.pnpm-debug.log* + +# env files (can opt-in for committing if needed) +.env* + +# vercel +.vercel + +# typescript +*.tsbuildinfo +next-env.d.ts diff --git a/benchmark/next-vanilla-extract-devup-ui/README.md b/benchmark/next-vanilla-extract-devup-ui/README.md new file mode 100644 index 00000000..665152ea --- /dev/null +++ b/benchmark/next-vanilla-extract-devup-ui/README.md @@ -0,0 +1 @@ +## Nextjs App diff --git a/benchmark/next-vanilla-extract-devup-ui/next.config.mjs b/benchmark/next-vanilla-extract-devup-ui/next.config.mjs new file mode 100644 index 00000000..00a680c8 --- /dev/null +++ b/benchmark/next-vanilla-extract-devup-ui/next.config.mjs @@ -0,0 +1,3 @@ +import { DevupUI } from '@devup-ui/next-plugin' + +export default DevupUI({}) diff --git a/benchmark/next-vanilla-extract-devup-ui/package.json b/benchmark/next-vanilla-extract-devup-ui/package.json new file mode 100644 index 00000000..e23c1369 --- /dev/null +++ b/benchmark/next-vanilla-extract-devup-ui/package.json @@ -0,0 +1,26 @@ +{ + "name": "next-vanilla-extract-devup-ui-benchmark", + "version": "0.1.0", + "type": "module", + "private": true, + "scripts": { + "dev": "next dev", + "build": "next build --experimental-debug-memory-usage --webpack", + "start": "next start", + "lint": "next lint" + }, + "dependencies": { + "@vanilla-extract/css": "^1.18", + "next": "^16.1", + "react": "^19.2", + "react-dom": "^19.2", + "react-icons": "^5.5" + }, + "devDependencies": { + "@types/node": "^25", + "@types/react": "^19", + "@types/react-dom": "^19", + "typescript": "^5", + "@devup-ui/next-plugin": "workspace:^" + } +} diff --git a/benchmark/next-vanilla-extract-devup-ui/public/file.svg b/benchmark/next-vanilla-extract-devup-ui/public/file.svg new file mode 100644 index 00000000..004145cd --- /dev/null +++ b/benchmark/next-vanilla-extract-devup-ui/public/file.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/benchmark/next-vanilla-extract-devup-ui/public/globe.svg b/benchmark/next-vanilla-extract-devup-ui/public/globe.svg new file mode 100644 index 00000000..567f17b0 --- /dev/null +++ b/benchmark/next-vanilla-extract-devup-ui/public/globe.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/benchmark/next-vanilla-extract-devup-ui/public/next.svg b/benchmark/next-vanilla-extract-devup-ui/public/next.svg new file mode 100644 index 00000000..5174b28c --- /dev/null +++ b/benchmark/next-vanilla-extract-devup-ui/public/next.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/benchmark/next-vanilla-extract-devup-ui/public/vercel.svg b/benchmark/next-vanilla-extract-devup-ui/public/vercel.svg new file mode 100644 index 00000000..77053960 --- /dev/null +++ b/benchmark/next-vanilla-extract-devup-ui/public/vercel.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/benchmark/next-vanilla-extract-devup-ui/public/window.svg b/benchmark/next-vanilla-extract-devup-ui/public/window.svg new file mode 100644 index 00000000..b2b2a44f --- /dev/null +++ b/benchmark/next-vanilla-extract-devup-ui/public/window.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/benchmark/next-vanilla-extract-devup-ui/src/app/favicon.ico b/benchmark/next-vanilla-extract-devup-ui/src/app/favicon.ico new file mode 100644 index 00000000..718d6fea Binary files /dev/null and b/benchmark/next-vanilla-extract-devup-ui/src/app/favicon.ico differ diff --git a/benchmark/next-vanilla-extract-devup-ui/src/app/index.css.ts b/benchmark/next-vanilla-extract-devup-ui/src/app/index.css.ts new file mode 100644 index 00000000..cf974acd --- /dev/null +++ b/benchmark/next-vanilla-extract-devup-ui/src/app/index.css.ts @@ -0,0 +1,36 @@ +import { style } from '@vanilla-extract/css' + +export const hello = style({ + cursor: 'pointer', + fontSize: 32, + position: 'relative', + paddingTop: '28px', + paddingBottom: '28px', + selectors: { + '&:hover': { + backgroundColor: 'yellow', + cursor: 'cell', + }, + }, +}) + +export const text = style({ + color: 'var(--text)', +}) + +export const conditional = style({ + color: 'green', +}) + +export const conditional1 = style({ + color: 'blue', +}) + +export const hello3 = style({ + paddingRight: '20px', + fontSize: 32, +}) + +export const hello2 = style({ + fontSize: 12, +}) diff --git a/benchmark/next-vanilla-extract-devup-ui/src/app/layout.tsx b/benchmark/next-vanilla-extract-devup-ui/src/app/layout.tsx new file mode 100644 index 00000000..6b8b4518 --- /dev/null +++ b/benchmark/next-vanilla-extract-devup-ui/src/app/layout.tsx @@ -0,0 +1,18 @@ +import type { Metadata } from 'next' + +export const metadata: Metadata = { + title: 'Create Next App', + description: 'Generated by create next app', +} + +export default function RootLayout({ + children, +}: Readonly<{ + children: React.ReactNode +}>) { + return ( + + {children} + + ) +} diff --git a/benchmark/next-vanilla-extract-devup-ui/src/app/page.tsx b/benchmark/next-vanilla-extract-devup-ui/src/app/page.tsx new file mode 100644 index 00000000..7a3e1724 --- /dev/null +++ b/benchmark/next-vanilla-extract-devup-ui/src/app/page.tsx @@ -0,0 +1,46 @@ +'use client' + +import { useState } from 'react' + +import { + conditional, + conditional1, + hello, + hello2, + hello3, + text, +} from './index.css' + +export default function HomePage() { + const [_, setColor] = useState('yellow') + const [enabled, setEnabled] = useState(false) + + return ( +
+

+ Track & field champions: +

+
+
hello
+
hello
+
+

text

+
+ hello +
+
hello
+ +
+ ) +} diff --git a/benchmark/next-vanilla-extract-devup-ui/tsconfig.json b/benchmark/next-vanilla-extract-devup-ui/tsconfig.json new file mode 100644 index 00000000..a9788073 --- /dev/null +++ b/benchmark/next-vanilla-extract-devup-ui/tsconfig.json @@ -0,0 +1,34 @@ +{ + "compilerOptions": { + "target": "ES2017", + "lib": ["dom", "dom.iterable", "esnext"], + "allowJs": true, + "skipLibCheck": true, + "strict": true, + "noEmit": true, + "esModuleInterop": true, + "module": "esnext", + "moduleResolution": "bundler", + "resolveJsonModule": true, + "isolatedModules": true, + "jsx": "react-jsx", + "incremental": true, + "plugins": [ + { + "name": "next" + } + ], + "paths": { + "@/*": ["./src/*"] + } + }, + "include": [ + "next-env.d.ts", + "**/*.ts", + "**/*.tsx", + ".next/types/**/*.ts", + "df/*.d.ts", + ".next/dev/types/**/*.ts" + ], + "exclude": ["node_modules"] +} diff --git a/bindings/devup-ui-wasm/.cargo/config.toml b/bindings/devup-ui-wasm/.cargo/config.toml new file mode 100644 index 00000000..a3a1ba0e --- /dev/null +++ b/bindings/devup-ui-wasm/.cargo/config.toml @@ -0,0 +1,2 @@ +[target.wasm32-unknown-unknown] +rustflags = ["--cfg", "getrandom_wasm_js"] diff --git a/bindings/devup-ui-wasm/Cargo.toml b/bindings/devup-ui-wasm/Cargo.toml index f6c0382a..960b5310 100644 --- a/bindings/devup-ui-wasm/Cargo.toml +++ b/bindings/devup-ui-wasm/Cargo.toml @@ -27,12 +27,16 @@ css = { path = "../../libs/css" } console_error_panic_hook = { version = "0.1.7", optional = true } once_cell = "1.21.3" js-sys = "0.3.83" -serde_json = "1.0.148" +serde_json = "1.0.149" serde-wasm-bindgen = "0.6.5" bimap = { version = "0.6.3", features = ["serde"] } +getrandom = { version = "0.3", features = ["wasm_js"] } [dev-dependencies] wasm-bindgen-test = "0.3.56" -serial_test = "3.2.0" -insta = "1.45.1" +serial_test = "3.3.1" +insta = "1.46.0" rstest = "0.26.1" + +[package.metadata.wasm-pack.profile.release] +wasm-opt = false diff --git a/bindings/devup-ui-wasm/src/lib.rs b/bindings/devup-ui-wasm/src/lib.rs index 6cbb748e..406cae6e 100644 --- a/bindings/devup-ui-wasm/src/lib.rs +++ b/bindings/devup-ui-wasm/src/lib.rs @@ -1,10 +1,10 @@ use css::class_map::{get_class_map, set_class_map}; use css::file_map::{get_file_map, get_filename_by_file_num, set_file_map}; use extractor::extract_style::extract_style_value::ExtractStyleValue; -use extractor::{ExtractOption, extract, has_devup_ui}; +use extractor::{ExtractOption, ImportAlias, extract, has_devup_ui}; use once_cell::sync::Lazy; use sheet::StyleSheet; -use std::collections::HashSet; +use std::collections::{HashMap, HashSet}; use std::sync::Mutex; use wasm_bindgen::prelude::*; @@ -213,6 +213,7 @@ pub fn export_file_map() -> Result { } /// Internal function to extract code (testable without JsValue) +#[allow(clippy::too_many_arguments)] pub fn code_extract_internal( filename: &str, code: &str, @@ -221,6 +222,7 @@ pub fn code_extract_internal( single_css: bool, import_main_css_in_code: bool, import_main_css_in_css: bool, + import_aliases: HashMap, ) -> Result { match extract( filename, @@ -230,6 +232,7 @@ pub fn code_extract_internal( css_dir, single_css, import_main_css: import_main_css_in_code, + import_aliases, }, ) { Ok(output) => Ok(Output::new( @@ -246,6 +249,7 @@ pub fn code_extract_internal( } #[wasm_bindgen(js_name = "codeExtract")] +#[allow(clippy::too_many_arguments)] pub fn code_extract( filename: &str, code: &str, @@ -254,7 +258,25 @@ pub fn code_extract( single_css: bool, import_main_css_in_code: bool, import_main_css_in_css: bool, + import_aliases: JsValue, ) -> Result { + // Deserialize import_aliases from JsValue + // Format: { "package": "namedExport" } or { "package": null } for named exports + let aliases: HashMap> = + serde_wasm_bindgen::from_value(import_aliases).unwrap_or_default(); + + // Convert to ImportAlias enum + let import_aliases: HashMap = aliases + .into_iter() + .map(|(k, v)| { + let alias = match v { + Some(name) => ImportAlias::DefaultToNamed(name), + None => ImportAlias::NamedToNamed, + }; + (k, alias) + }) + .collect(); + code_extract_internal( filename, code, @@ -263,6 +285,7 @@ pub fn code_extract( single_css, import_main_css_in_code, import_main_css_in_css, + import_aliases, ) .map_err(|e| JsValue::from_str(&e)) } @@ -675,6 +698,7 @@ mod tests { css_dir: "@devup-ui/core".to_string(), single_css: false, import_main_css: false, + import_aliases: HashMap::new(), }, ) .unwrap(); @@ -762,6 +786,7 @@ mod tests { css_dir: "@devup-ui/core".to_string(), single_css: true, import_main_css: true, + import_aliases: HashMap::new(), }, ) .unwrap(); @@ -903,6 +928,7 @@ mod tests { false, false, false, + HashMap::new(), ); assert!(result.is_ok()); @@ -926,6 +952,7 @@ mod tests { false, false, false, + HashMap::new(), ); assert!(result.is_err()); diff --git a/bun.lock b/bun.lock index c481bc53..b3120128 100644 --- a/bun.lock +++ b/bun.lock @@ -327,6 +327,24 @@ "typescript": "^5", }, }, + "benchmark/next-vanilla-extract-devup-ui": { + "name": "next-vanilla-extract-devup-ui-benchmark", + "version": "0.1.0", + "dependencies": { + "@vanilla-extract/css": "^1.18", + "next": "^16.1", + "react": "^19.2", + "react-dom": "^19.2", + "react-icons": "^5.5", + }, + "devDependencies": { + "@devup-ui/next-plugin": "workspace:^", + "@types/node": "^25", + "@types/react": "^19", + "@types/react-dom": "^19", + "typescript": "^5", + }, + }, "bindings/devup-ui-wasm": { "name": "@devup-ui/wasm", "version": "1.0.56", @@ -2490,6 +2508,8 @@ "next-vanilla-extract-benchmark": ["next-vanilla-extract-benchmark@workspace:benchmark/next-vanilla-extract"], + "next-vanilla-extract-devup-ui-benchmark": ["next-vanilla-extract-devup-ui-benchmark@workspace:benchmark/next-vanilla-extract-devup-ui"], + "node-eval": ["node-eval@2.0.0", "", { "dependencies": { "path-is-absolute": "1.0.1" } }, "sha512-Ap+L9HznXAVeJj3TJ1op6M6bg5xtTq8L5CU/PJxtkhea/DrIxdTknGKIECKd/v/Lgql95iuMAYvIzBNd0pmcMg=="], "node-releases": ["node-releases@2.0.27", "", {}, "sha512-nmh3lCkYZ3grZvqcCH+fjmQ7X+H0OeZgP40OierEaAptX4XofMh5kwNbWh7lBduUzCcV/8kZ+NDLCwm2iorIlA=="], @@ -3066,6 +3086,8 @@ "@babel/preset-env/semver": ["semver@6.3.1", "", { "bin": { "semver": "bin/semver.js" } }, "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA=="], + "@devup-ui/bun-plugin/@types/bun": ["@types/bun@1.3.6", "", { "dependencies": { "bun-types": "1.3.6" } }, "sha512-uWCv6FO/8LcpREhenN1d1b6fcspAB+cefwD7uti8C8VffIv0Um08TKMn98FynpTiU38+y2dUO55T11NgDt8VAA=="], + "@emotion/babel-plugin/convert-source-map": ["convert-source-map@1.9.0", "", {}, "sha512-ASFBup0Mz1uyiIjANan1jzLQami9z1PoYSZCiiYW2FczPbenXc45FZdBZLzOT+r6+iciuEModtmCti+hjaAk0A=="], "@emotion/babel-plugin/source-map": ["source-map@0.5.7", "", {}, "sha512-LbrmJOMUSdEVxIKvdcJzQC+nQhe8FUZQTXQy6+I75skNgn3OoQ0DZA8YnFa7gp8tqtL3KPf1kmo0R5DoApeSGQ=="], @@ -3296,6 +3318,8 @@ "yargs/find-up": ["find-up@4.1.0", "", { "dependencies": { "locate-path": "^5.0.0", "path-exists": "^4.0.0" } }, "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw=="], + "@devup-ui/bun-plugin/@types/bun/bun-types": ["bun-types@1.3.6", "", { "dependencies": { "@types/node": "*" } }, "sha512-OlFwHcnNV99r//9v5IIOgQ9Uk37gZqrNMCcqEaExdkVq3Avwqok1bJFmvGMCkCE0FqzdY8VMOZpfpR3lwI+CsQ=="], + "@happy-dom/global-registrator/@types/node/undici-types": ["undici-types@6.21.0", "", {}, "sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ=="], "@isaacs/cliui/strip-ansi/ansi-regex": ["ansi-regex@6.2.2", "", {}, "sha512-Bq3SmSpyFHaWjPk8If9yc6svM8c56dB5BAtW4Qbw5jHTwwXXcTLoRMkpDJp6VL0XzlWaCHTXrkFURMYmD0sLqg=="], diff --git a/libs/css/Cargo.toml b/libs/css/Cargo.toml index 25ed7164..028d261f 100644 --- a/libs/css/Cargo.toml +++ b/libs/css/Cargo.toml @@ -6,10 +6,10 @@ edition = "2024" [dependencies] once_cell = "1.21.3" phf = { version = "0.13", features = ["macros"] } -serial_test = "3.2.0" serde = { version = "1.0.228", features = ["derive"] } regex = "1.12.2" bimap = { version = "0.6.3" } [dev-dependencies] rstest = "0.26.1" +serial_test = "3.3.1" diff --git a/libs/css/src/optimize_value.rs b/libs/css/src/optimize_value.rs index f8dda860..9587738e 100644 --- a/libs/css/src/optimize_value.rs +++ b/libs/css/src/optimize_value.rs @@ -8,8 +8,20 @@ use crate::{ pub fn optimize_value(value: &str) -> String { let mut ret = value.trim().to_string(); + + // Wrap CSS custom property names in var() when used as values + // e.g., "--var-0" becomes "var(--var-0)" + if ret.starts_with("--") && !ret.contains(' ') && !ret.contains(',') { + ret = format!("var({})", ret); + } + ret = INNER_TRIM_RE.replace_all(&ret, "(${1})").to_string(); - ret = RM_MINUS_ZERO_RE.replace_all(&ret, "0${1}").to_string(); + + // Skip RM_MINUS_ZERO_RE for values containing CSS custom property references + // to preserve names like --var-0 (the -0 should not be converted to 0) + if !ret.contains("--") { + ret = RM_MINUS_ZERO_RE.replace_all(&ret, "0${1}").to_string(); + } ret = NUM_TRIM_RE.replace_all(&ret, "${1} ${3}").to_string(); if ret.contains(",") { @@ -252,4 +264,15 @@ mod tests { fn test_optimize_color(#[case] input: &str, #[case] expected: &str) { assert_eq!(optimize_value(input), expected); } + + #[rstest] + #[case("--var-0", "var(--var-0)")] + #[case("--my-custom-prop", "var(--my-custom-prop)")] + #[case("--primary-color", "var(--primary-color)")] + #[case("var(--var-0)", "var(--var-0)")] // Already wrapped, don't double wrap + #[case("--a --b", "--a --b")] // Contains space, don't wrap + #[case("--a, --b", "--a,--b")] // Contains comma, don't wrap (spaces after commas are removed) + fn test_css_custom_property_wrapping(#[case] input: &str, #[case] expected: &str) { + assert_eq!(optimize_value(input), expected); + } } diff --git a/libs/css/src/style_selector.rs b/libs/css/src/style_selector.rs index 0dddd22e..56dd9365 100644 --- a/libs/css/src/style_selector.rs +++ b/libs/css/src/style_selector.rs @@ -18,6 +18,7 @@ pub enum AtRuleKind { Media, Supports, Container, + Layer, } impl Display for AtRuleKind { @@ -26,6 +27,19 @@ impl Display for AtRuleKind { AtRuleKind::Media => write!(f, "media"), AtRuleKind::Supports => write!(f, "supports"), AtRuleKind::Container => write!(f, "container"), + AtRuleKind::Layer => write!(f, "layer"), + } + } +} + +impl From<&str> for AtRuleKind { + fn from(value: &str) -> Self { + match value { + "media" => AtRuleKind::Media, + "supports" => AtRuleKind::Supports, + "container" => AtRuleKind::Container, + "layer" => AtRuleKind::Layer, + _ => unreachable!(), } } } @@ -310,6 +324,13 @@ mod tests { "@container sidebar (min-width: 400px)" )] #[case(StyleSelector::Global(":root[data-theme=dark]".to_string(), "file.rs".to_string()), ":root[data-theme=dark]")] + #[case(StyleSelector::At { + kind: AtRuleKind::Layer, + query: "reset".to_string(), + selector: None, + }, + "@layer reset" + )] fn test_style_selector_display(#[case] selector: StyleSelector, #[case] expected: &str) { let output = format!("{selector}"); assert_eq!(output, expected); @@ -449,4 +470,28 @@ mod tests { fn test_get_selector_order(#[case] selector: &str, #[case] expected: u8) { assert_eq!(get_selector_order(selector), expected); } + + #[rstest] + #[case(AtRuleKind::Media, "media")] + #[case(AtRuleKind::Supports, "supports")] + #[case(AtRuleKind::Container, "container")] + #[case(AtRuleKind::Layer, "layer")] + fn test_at_rule_kind_display(#[case] kind: AtRuleKind, #[case] expected: &str) { + assert_eq!(format!("{kind}"), expected); + } + + #[rstest] + #[case("media", AtRuleKind::Media)] + #[case("supports", AtRuleKind::Supports)] + #[case("container", AtRuleKind::Container)] + #[case("layer", AtRuleKind::Layer)] + fn test_at_rule_kind_from_str(#[case] input: &str, #[case] expected: AtRuleKind) { + assert_eq!(AtRuleKind::from(input), expected); + } + + #[test] + #[should_panic] + fn test_at_rule_kind_from_str_unknown() { + let _ = AtRuleKind::from("unknown"); + } } diff --git a/libs/extractor/Cargo.toml b/libs/extractor/Cargo.toml index 874adef2..55487d3f 100644 --- a/libs/extractor/Cargo.toml +++ b/libs/extractor/Cargo.toml @@ -4,19 +4,23 @@ version = "0.1.0" edition = "2024" [dependencies] -oxc_parser = "0.106.0" -oxc_syntax = "0.106.0" -oxc_span = "0.106.0" -oxc_allocator = "0.106.0" -oxc_ast = "0.106.0" -oxc_ast_visit = "0.106.0" -oxc_codegen = "0.106.0" +oxc_parser = "0.108.0" +oxc_syntax = "0.108.0" +oxc_span = "0.108.0" +oxc_allocator = "0.108.0" +oxc_ast = "0.108.0" +oxc_ast_visit = "0.108.0" +oxc_codegen = "0.108.0" +oxc_transformer = "0.108.0" +oxc_semantic = "0.108.0" css = { path = "../css" } phf = "0.13" strum = "0.27.2" strum_macros = "0.27.2" +serde_json = "1.0" +boa_engine = "0.21" [dev-dependencies] -insta = "1.45.1" -serial_test = "3.2.0" +insta = "1.46.0" +serial_test = "3.3.1" rstest = "0.26.1" diff --git a/libs/extractor/src/extract_style/extract_static_style.rs b/libs/extractor/src/extract_style/extract_static_style.rs index 73d2f119..abe853cb 100644 --- a/libs/extractor/src/extract_style/extract_static_style.rs +++ b/libs/extractor/src/extract_style/extract_static_style.rs @@ -24,6 +24,8 @@ pub struct ExtractStaticStyle { pub selector: Option, /// None is inf, 0 is first, 1 is second, etc pub style_order: Option, + /// CSS layer name (from vanilla-extract layer()) + pub layer: Option, } impl ExtractStaticStyle { @@ -52,9 +54,23 @@ impl ExtractStaticStyle { level, selector: selector.map(optimize_selector), style_order: None, + layer: None, } } + /// create a new ExtractStaticStyle with layer + pub fn new_with_layer( + property: &str, + value: &str, + level: u8, + selector: Option, + layer: Option, + ) -> Self { + let mut style = Self::new(property, value, level, selector); + style.layer = layer; + style + } + pub fn new_basic( property: &str, value: &str, @@ -71,9 +87,15 @@ impl ExtractStaticStyle { level, selector, style_order: Some(0), + layer: None, } } + /// Get the layer name + pub fn layer(&self) -> Option<&str> { + self.layer.as_deref() + } + pub fn property(&self) -> &str { self.property.as_str() } @@ -131,5 +153,25 @@ mod tests { assert_eq!(style.level(), 0); assert_eq!(style.selector(), None); assert_eq!(style.style_order(), None); + assert_eq!(style.layer(), None); + } + + #[test] + fn test_extract_static_style_with_layer() { + let style = + ExtractStaticStyle::new_with_layer("margin", "0", 0, None, Some("reset".to_string())); + assert_eq!(style.property(), "margin"); + assert_eq!(style.value(), "0"); + assert_eq!(style.level(), 0); + assert_eq!(style.selector(), None); + assert_eq!(style.layer(), Some("reset")); + } + + #[test] + fn test_extract_static_style_with_layer_none() { + let style = ExtractStaticStyle::new_with_layer("color", "red", 0, None, None); + assert_eq!(style.property(), "color"); + assert_eq!(style.value(), "red"); + assert_eq!(style.layer(), None); } } diff --git a/libs/extractor/src/extractor/extract_global_style_from_expression.rs b/libs/extractor/src/extractor/extract_global_style_from_expression.rs index 6c577aa7..3c8f5521 100644 --- a/libs/extractor/src/extractor/extract_global_style_from_expression.rs +++ b/libs/extractor/src/extractor/extract_global_style_from_expression.rs @@ -147,23 +147,47 @@ pub fn extract_global_style_from_expression<'a>( } } } else { - styles.extend( - extract_style_from_expression( - ast_builder, - None, - &mut o.value, - 0, - &Some(StyleSelector::Global( - if let Some(name) = name.strip_prefix("_") { - StyleSelector::from(name).to_string().replace("&", "*") - } else { - name.to_string() - }, - file.to_string(), - )), - ) - .styles, + // Handle @layer property in globalStyle + // Extract the layer name if present in the style object + let mut layer_name: Option = None; + if let Expression::ObjectExpression(style_obj) = &o.value + && let Some(ObjectPropertyKind::ObjectProperty(sp)) = style_obj.properties.iter().find(|style_prop| matches!(style_prop, ObjectPropertyKind::ObjectProperty(s) if get_string_by_property_key(&s.key) == Some("@layer".to_string()))) + { + layer_name = get_string_by_literal_expression(&sp.value); + } + + let extracted = extract_style_from_expression( + ast_builder, + None, + &mut o.value, + 0, + &Some(StyleSelector::Global( + if let Some(name) = name.strip_prefix("_") { + StyleSelector::from(name).to_string().replace("&", "*") + } else { + name.to_string() + }, + file.to_string(), + )), ); + + // Filter out @layer property from styles and set layer on remaining styles + for mut style in extracted.styles { + if let ExtractStyleProp::Static(ExtractStyleValue::Static( + ref mut st, + )) = style + { + // Skip @layer property - it's not a CSS property, set layer on other styles + if st.property() != "@layer" { + if let Some(ref layer) = layer_name { + st.layer = Some(layer.clone()); + } + styles.push(style); + } + } else { + styles.push(style); + } + } } } } diff --git a/libs/extractor/src/extractor/extract_style_from_expression.rs b/libs/extractor/src/extractor/extract_style_from_expression.rs index 888b2b93..a9275ddf 100644 --- a/libs/extractor/src/extractor/extract_style_from_expression.rs +++ b/libs/extractor/src/extractor/extract_style_from_expression.rs @@ -254,12 +254,7 @@ pub fn extract_style_from_expression<'a>( && let Some(query) = get_string_by_property_key(&o.key) { let at_selector = StyleSelector::At { - kind: match at_rule { - "media" => css::style_selector::AtRuleKind::Media, - "supports" => css::style_selector::AtRuleKind::Supports, - "container" => css::style_selector::AtRuleKind::Container, - _ => unreachable!(), - }, + kind: at_rule.into(), query: query.to_string(), selector: selector.as_ref().map(|s| s.to_string()), }; diff --git a/libs/extractor/src/import_alias_visit.rs b/libs/extractor/src/import_alias_visit.rs new file mode 100644 index 00000000..295497d6 --- /dev/null +++ b/libs/extractor/src/import_alias_visit.rs @@ -0,0 +1,392 @@ +//! Import alias transformation +//! +//! Transforms imports from aliased packages to the target package. +//! +//! Examples: +//! - `import styled from '@emotion/styled'` → `import { styled } from '@devup-ui/react'` +//! - `import styledA from '@emotion/styled'` → `import { styled as styledA } from '@devup-ui/react'` +//! - `import { style } from '@vanilla-extract/css'` → `import { style } from '@devup-ui/react'` + +use crate::ImportAlias; +use oxc_allocator::Allocator; +use oxc_ast::ast::ImportDeclarationSpecifier; +use oxc_parser::Parser; +use oxc_span::SourceType; +use std::collections::HashMap; + +/// Transform source code by rewriting aliased imports to the target package +/// +/// # Arguments +/// * `code` - The source code to transform +/// * `filename` - The filename (used for source type detection) +/// * `package` - The target package (e.g., "@devup-ui/react") +/// * `import_aliases` - Map of source package → alias configuration +/// +/// # Returns +/// The transformed source code, or the original code if no transformations were needed +pub fn transform_import_aliases( + code: &str, + filename: &str, + package: &str, + import_aliases: &HashMap, +) -> String { + // Quick check: if no aliases match, return original code + if import_aliases.is_empty() || !import_aliases.keys().any(|alias| code.contains(alias)) { + return code.to_string(); + } + + let allocator = Allocator::default(); + let source_type = SourceType::from_path(filename).unwrap_or_default(); + + // Parse the code + let parser_ret = Parser::new(&allocator, code, source_type).parse(); + let program = parser_ret.program; + + // Collect import transformations + let mut transformations: Vec<(usize, usize, String)> = Vec::new(); + + for stmt in &program.body { + if let oxc_ast::ast::Statement::ImportDeclaration(import_decl) = stmt { + let source_value = import_decl.source.value.as_str(); + + if let Some(alias) = import_aliases.get(source_value) { + let span = import_decl.span; + let new_import = generate_transformed_import(import_decl, alias, package); + transformations.push((span.start as usize, span.end as usize, new_import)); + } + } + } + + // Apply transformations in reverse order to preserve positions + if transformations.is_empty() { + return code.to_string(); + } + + let mut result = code.to_string(); + for (start, end, replacement) in transformations.into_iter().rev() { + result.replace_range(start..end, &replacement); + } + + result +} + +/// Generate the transformed import statement +fn generate_transformed_import( + import_decl: &oxc_ast::ast::ImportDeclaration, + alias: &ImportAlias, + package: &str, +) -> String { + let specifiers = match &import_decl.specifiers { + Some(specs) => specs, + None => return format!("import '{}';", package), + }; + + match alias { + ImportAlias::DefaultToNamed(named_export) => { + // Transform: `import foo from 'pkg'` → `import { named as foo } from 'target'` + let mut import_parts = Vec::new(); + + for specifier in specifiers { + match specifier { + ImportDeclarationSpecifier::ImportDefaultSpecifier(default_spec) => { + let local_name = default_spec.local.name.as_str(); + if local_name == named_export { + // Same name: `import { styled } from 'pkg'` + import_parts.push(named_export.clone()); + } else { + // Different name: `import { styled as foo } from 'pkg'` + import_parts.push(format!("{} as {}", named_export, local_name)); + } + } + ImportDeclarationSpecifier::ImportSpecifier(spec) => { + // Keep named imports + let imported = spec.imported.to_string(); + let local = spec.local.name.as_str(); + if imported == local { + import_parts.push(imported); + } else { + import_parts.push(format!("{} as {}", imported, local)); + } + } + ImportDeclarationSpecifier::ImportNamespaceSpecifier(ns_spec) => { + // Namespace imports are kept but shouldn't really happen for CSS-in-JS + return format!( + "import * as {} from '{}';", + ns_spec.local.name.as_str(), + package + ); + } + } + } + + format!( + "import {{ {} }} from '{}';", + import_parts.join(", "), + package + ) + } + ImportAlias::NamedToNamed => { + // Just change the source, keep specifiers as-is + // `import { style } from 'pkg'` → `import { style } from 'target'` + let mut import_parts = Vec::new(); + + for specifier in specifiers { + match specifier { + ImportDeclarationSpecifier::ImportDefaultSpecifier(default_spec) => { + // Default import in NamedToNamed mode - just keep it + // (shouldn't happen for @vanilla-extract/css) + import_parts + .push(format!("default as {}", default_spec.local.name.as_str())); + } + ImportDeclarationSpecifier::ImportSpecifier(spec) => { + let imported = spec.imported.to_string(); + let local = spec.local.name.as_str(); + if imported == local { + import_parts.push(imported); + } else { + import_parts.push(format!("{} as {}", imported, local)); + } + } + ImportDeclarationSpecifier::ImportNamespaceSpecifier(ns_spec) => { + return format!( + "import * as {} from '{}';", + ns_spec.local.name.as_str(), + package + ); + } + } + } + + format!( + "import {{ {} }} from '{}';", + import_parts.join(", "), + package + ) + } + } +} + +#[cfg(test)] +mod tests { + use super::*; + use insta::assert_snapshot; + + fn emotion_alias() -> HashMap { + let mut aliases = HashMap::new(); + aliases.insert( + "@emotion/styled".to_string(), + ImportAlias::DefaultToNamed("styled".to_string()), + ); + aliases + } + + fn vanilla_extract_alias() -> HashMap { + let mut aliases = HashMap::new(); + aliases.insert( + "@vanilla-extract/css".to_string(), + ImportAlias::NamedToNamed, + ); + aliases + } + + fn styled_components_alias() -> HashMap { + let mut aliases = HashMap::new(); + aliases.insert( + "styled-components".to_string(), + ImportAlias::DefaultToNamed("styled".to_string()), + ); + aliases + } + + fn combined_aliases() -> HashMap { + let mut aliases = HashMap::new(); + aliases.insert( + "@emotion/styled".to_string(), + ImportAlias::DefaultToNamed("styled".to_string()), + ); + aliases.insert( + "@vanilla-extract/css".to_string(), + ImportAlias::NamedToNamed, + ); + aliases + } + + #[test] + fn test_default_to_named_same_name() { + assert_snapshot!(transform_import_aliases( + r#"import styled from '@emotion/styled'"#, + "test.tsx", + "@devup-ui/react", + &emotion_alias() + )); + } + + #[test] + fn test_default_to_named_different_name() { + assert_snapshot!(transform_import_aliases( + r#"import styledA from '@emotion/styled'"#, + "test.tsx", + "@devup-ui/react", + &emotion_alias() + )); + } + + #[test] + fn test_named_to_named() { + assert_snapshot!(transform_import_aliases( + r#"import { style, globalStyle } from '@vanilla-extract/css'"#, + "test.tsx", + "@devup-ui/react", + &vanilla_extract_alias() + )); + } + + #[test] + fn test_no_matching_alias() { + assert_snapshot!(transform_import_aliases( + r#"import { useState } from 'react'"#, + "test.tsx", + "@devup-ui/react", + &emotion_alias() + )); + } + + #[test] + fn test_empty_aliases() { + assert_snapshot!(transform_import_aliases( + r#"import styled from '@emotion/styled'"#, + "test.tsx", + "@devup-ui/react", + &HashMap::new() + )); + } + + #[test] + fn test_styled_components() { + assert_snapshot!(transform_import_aliases( + r#"import styled from 'styled-components'"#, + "test.tsx", + "@devup-ui/react", + &styled_components_alias() + )); + } + + #[test] + fn test_css_ts_file_vanilla_extract() { + assert_snapshot!(transform_import_aliases( + r#"import { style } from '@vanilla-extract/css' +export const container = style({ background: 'red' })"#, + "styles.css.ts", + "@devup-ui/react", + &vanilla_extract_alias() + )); + } + + #[test] + fn test_multiple_imports_same_file() { + assert_snapshot!(transform_import_aliases( + r#"import styled from '@emotion/styled' +import { style } from '@vanilla-extract/css' +import { useState } from 'react'"#, + "test.tsx", + "@devup-ui/react", + &combined_aliases() + )); + } + + #[test] + fn test_preserves_code_after_import() { + assert_snapshot!(transform_import_aliases( + r#"import { style } from '@vanilla-extract/css' + +export const button = style({ + background: 'blue', + padding: '8px', +});"#, + "test.css.ts", + "@devup-ui/react", + &vanilla_extract_alias() + )); + } + + #[test] + fn test_named_import_with_alias() { + assert_snapshot!(transform_import_aliases( + r#"import { style as myStyle } from '@vanilla-extract/css'"#, + "test.tsx", + "@devup-ui/react", + &vanilla_extract_alias() + )); + } + + #[test] + fn test_side_effect_import_no_specifiers() { + assert_snapshot!(transform_import_aliases( + r#"import '@emotion/styled'"#, + "test.tsx", + "@devup-ui/react", + &emotion_alias() + )); + } + + #[test] + fn test_alias_in_comment_not_transformed() { + assert_snapshot!(transform_import_aliases( + r#"// This uses @emotion/styled but doesn't import it +const x = 1;"#, + "test.tsx", + "@devup-ui/react", + &emotion_alias() + )); + } + + #[test] + fn test_default_to_named_with_additional_named_imports() { + assert_snapshot!(transform_import_aliases( + r#"import styled, { css, keyframes } from '@emotion/styled'"#, + "test.tsx", + "@devup-ui/react", + &emotion_alias() + )); + } + + #[test] + fn test_default_to_named_with_aliased_named_import() { + assert_snapshot!(transform_import_aliases( + r#"import styled, { css as emotionCss } from '@emotion/styled'"#, + "test.tsx", + "@devup-ui/react", + &emotion_alias() + )); + } + + #[test] + fn test_default_to_named_namespace_import() { + assert_snapshot!(transform_import_aliases( + r#"import * as Emotion from '@emotion/styled'"#, + "test.tsx", + "@devup-ui/react", + &emotion_alias() + )); + } + + #[test] + fn test_named_to_named_with_default_specifier() { + assert_snapshot!(transform_import_aliases( + r#"import vanillaDefault, { style } from '@vanilla-extract/css'"#, + "test.tsx", + "@devup-ui/react", + &vanilla_extract_alias() + )); + } + + #[test] + fn test_named_to_named_namespace_import() { + assert_snapshot!(transform_import_aliases( + r#"import * as VE from '@vanilla-extract/css'"#, + "test.tsx", + "@devup-ui/react", + &vanilla_extract_alias() + )); + } +} diff --git a/libs/extractor/src/lib.rs b/libs/extractor/src/lib.rs index daec4d15..f33e12ae 100644 --- a/libs/extractor/src/lib.rs +++ b/libs/extractor/src/lib.rs @@ -5,9 +5,11 @@ pub mod extract_style; mod extractor; mod gen_class_name; mod gen_style; +mod import_alias_visit; mod prop_modify_utils; mod util_type; mod utils; +mod vanilla_extract; mod visit; use crate::extract_style::extract_style_value::ExtractStyleValue; use crate::visit::DevupVisitor; @@ -18,9 +20,19 @@ use oxc_ast_visit::VisitMut; use oxc_codegen::{Codegen, CodegenOptions}; use oxc_parser::{Parser, ParserReturn}; use oxc_span::SourceType; -use std::collections::{BTreeMap, HashSet}; +use std::collections::{BTreeMap, HashMap, HashSet}; use std::error::Error; use std::path::PathBuf; + +/// Import alias configuration for redirecting imports from other CSS-in-JS libraries +#[derive(Debug, Clone, PartialEq)] +pub enum ImportAlias { + /// Default export → named export (e.g., `import styled from '@emotion/styled'` → `import { styled } from '@devup-ui/react'`) + DefaultToNamed(String), + /// Named exports (1:1 mapping, e.g., `import { style } from '@vanilla-extract/css'` → `import { style } from '@devup-ui/react'`) + NamedToNamed, +} + #[derive(Debug)] pub enum ExtractStyleProp<'a> { Static(ExtractStyleValue), @@ -94,6 +106,20 @@ pub struct ExtractOption { pub css_dir: String, pub single_css: bool, pub import_main_css: bool, + /// Import aliases for redirecting imports from other CSS-in-JS libraries to the target package + pub import_aliases: HashMap, +} + +impl Default for ExtractOption { + fn default() -> Self { + Self { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: false, + import_main_css: false, + import_aliases: HashMap::new(), + } + } } pub fn extract( @@ -101,7 +127,20 @@ pub fn extract( code: &str, option: ExtractOption, ) -> Result> { - if !code.contains(option.package.as_str()) { + // Step 1: Transform import aliases + // e.g., `import styled from '@emotion/styled'` → `import { styled } from '@devup-ui/react'` + // e.g., `import { style } from '@vanilla-extract/css'` → `import { style } from '@devup-ui/react'` + let transformed_code = import_alias_visit::transform_import_aliases( + code, + filename, + &option.package, + &option.import_aliases, + ); + + // Step 2: Check if code contains the target package (after transformation) + let has_relevant_import = transformed_code.contains(option.package.as_str()); + + if !has_relevant_import { // skip if not using package return Ok(ExtractOutput { styles: HashSet::new(), @@ -111,6 +150,70 @@ pub fn extract( }); } + // Step 3: Handle vanilla-extract style files (.css.ts, .css.js) + let is_ve_file = vanilla_extract::is_vanilla_extract_file(filename); + let (processed_code, is_vanilla_extract) = if is_ve_file { + // Use transformed code (with imports already pointing to @devup-ui/react) + match vanilla_extract::execute_vanilla_extract(&transformed_code, &option.package, filename) + { + Ok(collected) => { + // Check if any styles are referenced in selectors + let referenced = vanilla_extract::find_selector_references(&collected); + + if referenced.is_empty() { + // No selector references, use simple code generation + let generated = + vanilla_extract::collected_styles_to_code(&collected, &option.package); + (generated, true) + } else { + // Two-pass extraction: first extract referenced styles to get their class names + let partial_code = vanilla_extract::collected_styles_to_code_partial( + &collected, + &option.package, + &referenced, + ); + + // Build class map by extracting the partial code + let class_map = if !partial_code.is_empty() { + extract_class_map_from_code(filename, &partial_code, &option, &referenced)? + } else { + std::collections::HashMap::new() + }; + + // Generate full code with class names substituted into selectors + let generated = vanilla_extract::collected_styles_to_code_with_classes( + &collected, + &option.package, + &class_map, + ); + (generated, true) + } + } + Err(_) => { + // Fall back to treating as regular file if execution fails + (transformed_code.clone(), false) + } + } + } else { + (transformed_code.clone(), false) + }; + + // For vanilla-extract files, if no styles were collected, return early + if is_vanilla_extract && processed_code.is_empty() { + return Ok(ExtractOutput { + styles: HashSet::new(), + code: code.to_string(), + map: None, + css_file: None, + }); + } + + let code_to_parse = if is_vanilla_extract { + &processed_code + } else { + &transformed_code + }; + let source_type = SourceType::from_path(filename)?; let css_file = if option.single_css { format!("{}/devup-ui.css", option.css_dir) @@ -131,7 +234,7 @@ pub fn extract( mut program, // AST panicked, // Parser encountered an error it couldn't recover from .. - } = Parser::new(&allocator, code, source_type).parse(); + } = Parser::new(&allocator, code_to_parse, source_type).parse(); if panicked { return Err("Parser panicked".into()); } @@ -162,6 +265,82 @@ pub fn extract( }) } +/// Extract class names from generated code for specific style names +/// Used for two-pass vanilla-extract processing to resolve selector references +fn extract_class_map_from_code( + filename: &str, + partial_code: &str, + option: &ExtractOption, + style_names: &HashSet, +) -> Result, Box> { + let source_type = SourceType::from_path(filename)?; + let css_file = if option.single_css { + format!("{}/devup-ui.css", option.css_dir) + } else { + format!( + "{}/devup-ui-{}.css", + option.css_dir, + get_file_num_by_filename(filename) + ) + }; + let css_files = vec![css_file]; + let allocator = Allocator::default(); + + let ParserReturn { + mut program, + panicked, + .. + } = Parser::new(&allocator, partial_code, source_type).parse(); + if panicked { + Ok(std::collections::HashMap::new()) + } else { + let mut visitor = DevupVisitor::new( + &allocator, + filename, + &option.package, + css_files, + if !option.single_css { + Some(filename.to_string()) + } else { + None + }, + ); + visitor.visit_program(&mut program); + + let result = Codegen::new().build(&program); + + // Parse the output code to extract class name assignments + // Format: const styleName = "className" or const styleName = "className1 className2" + let mut class_map = std::collections::HashMap::new(); + for line in result.code.lines() { + let line = line.trim(); + if line.starts_with("const ") || line.starts_with("export const ") { + // Parse: [export] const name = "value" + let after_const = if line.starts_with("export ") { + line.strip_prefix("export const ").unwrap_or(line) + } else { + line.strip_prefix("const ").unwrap_or(line) + }; + + if let Some((name, rest)) = after_const.split_once(" = ") { + // Extract value from "value" or "value"; + let value = rest + .trim_start_matches('"') + .trim_end_matches(';') + .trim_end_matches('"'); + + if style_names.contains(name) { + // For multi-class values like "a b", take the first class + let first_class = value.split_whitespace().next().unwrap_or(value); + class_map.insert(name.to_string(), first_class.to_string()); + } + } + } + } + Ok(class_map) + } +} + /// Check if the code has an import from the specified package pub fn has_devup_ui(filename: &str, code: &str, package: &str) -> bool { if !code.contains(package) { @@ -199,6 +378,7 @@ mod tests { use super::*; use css::class_map::reset_class_map; + use css::file_map::reset_file_map; use insta::assert_debug_snapshot; use rstest::rstest; use serial_test::serial; @@ -225,10 +405,23 @@ mod tests { } } } + + #[test] + fn test_extract_option_default() { + // Tests lines 90-91: ExtractOption::default() + let option = ExtractOption::default(); + assert_eq!(option.package, "@devup-ui/react"); + assert_eq!(option.css_dir, "@devup-ui/react"); + assert!(!option.single_css); + assert!(!option.import_main_css); + assert!(option.import_aliases.is_empty()); + } + #[test] #[serial] fn extract_just_tsx() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -237,13 +430,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() }, ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -252,7 +447,8 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() }, ) .unwrap() @@ -262,18 +458,20 @@ mod tests { #[serial] fn ignore_special_props() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", r#"import {Box} from '@devup-ui/core' {}} aria-valuenow={24} key={2} tabIndex={1} id="id" /> "#, - ExtractOption { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, import_main_css: false } + ExtractOption { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, import_main_css: false, import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -284,7 +482,8 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -295,6 +494,7 @@ mod tests { #[serial] fn convert_tag() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -305,13 +505,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -322,13 +524,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -339,13 +543,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -356,13 +562,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -373,13 +581,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -390,13 +600,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -407,13 +619,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -424,13 +638,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -441,13 +657,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -458,13 +676,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -475,13 +695,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -492,13 +714,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -509,13 +733,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -526,37 +752,41 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", r#"import {Box} from '@devup-ui/core' "#, - ExtractOption { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, import_main_css: false } + ExtractOption { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, import_main_css: false, import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", r#"import {Box} from '@devup-ui/core' "#, - ExtractOption { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, import_main_css: false } + ExtractOption { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, import_main_css: false, import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -567,13 +797,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -584,13 +816,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -601,13 +835,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); // maintain object expression assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -619,13 +855,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); // maintain object expression assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -637,7 +875,8 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -647,6 +886,7 @@ mod tests { #[serial] fn extract_style_props() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -657,12 +897,14 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -673,12 +915,14 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -689,13 +933,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -706,13 +952,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -723,13 +971,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -740,7 +990,8 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -751,6 +1002,7 @@ mod tests { #[serial] fn extract_style_props_with_namespace_import() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -763,7 +1015,8 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -774,6 +1027,7 @@ mod tests { #[serial] fn extract_style_props_with_var_css() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -787,7 +1041,8 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -798,6 +1053,7 @@ mod tests { #[serial] fn extract_style_props_with_default_import() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -810,7 +1066,8 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -821,6 +1078,7 @@ mod tests { #[serial] fn extract_style_props_with_class_name() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -831,13 +1089,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -848,13 +1108,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -865,13 +1127,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -882,12 +1146,14 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -898,13 +1164,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -921,13 +1189,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -938,13 +1208,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -959,13 +1231,15 @@ mod tests { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -994,7 +1268,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -1005,6 +1280,7 @@ import clsx from 'clsx' #[serial] fn extract_class_name_from_component() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1015,7 +1291,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -1025,6 +1302,7 @@ import clsx from 'clsx' #[serial] fn extract_responsive_style_props() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1035,7 +1313,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -1050,7 +1329,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -1061,6 +1341,7 @@ import clsx from 'clsx' #[serial] fn extract_dynamic_style_props() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1071,13 +1352,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1088,13 +1371,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1105,13 +1390,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1122,7 +1409,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -1133,6 +1421,7 @@ import clsx from 'clsx' #[serial] fn extract_dynamic_style_props_with_type() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1143,13 +1432,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1160,13 +1451,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1177,7 +1470,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -1188,6 +1482,7 @@ import clsx from 'clsx' #[serial] fn remove_semicolon() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1198,13 +1493,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1215,13 +1512,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1232,13 +1531,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1249,13 +1550,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1266,7 +1569,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -1277,6 +1581,7 @@ import clsx from 'clsx' #[serial] fn extract_dynamic_responsive_style_props() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1287,7 +1592,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -1298,6 +1604,7 @@ import clsx from 'clsx' #[serial] fn extract_compound_responsive_style_props() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1308,7 +1615,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -1319,6 +1627,7 @@ import clsx from 'clsx' #[serial] fn extract_wrong_responsive_style_props() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1329,13 +1638,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1346,7 +1657,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -1357,6 +1669,7 @@ import clsx from 'clsx' #[serial] fn extract_variable_style_props_with_style() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1367,13 +1680,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1384,7 +1699,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -1395,6 +1711,7 @@ import clsx from 'clsx' #[serial] fn extract_conditional_style_props() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1405,13 +1722,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1422,13 +1741,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1439,13 +1760,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1456,13 +1779,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1473,13 +1798,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1490,13 +1817,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1507,13 +1836,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1524,13 +1855,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1541,13 +1874,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1558,13 +1893,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1575,7 +1912,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -1586,6 +1924,7 @@ import clsx from 'clsx' #[serial] fn extract_same_value_conditional_style_props() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1596,13 +1935,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1613,13 +1954,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1630,13 +1973,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1647,13 +1992,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1664,13 +2011,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1681,7 +2030,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -1692,6 +2042,7 @@ import clsx from 'clsx' #[serial] fn extract_same_dynamic_value_conditional_style_props() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1702,13 +2053,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1719,7 +2072,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -1730,6 +2084,7 @@ import clsx from 'clsx' #[serial] fn extract_responsive_conditional_style_props() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1740,13 +2095,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1757,13 +2114,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1774,13 +2133,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1791,13 +2152,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1808,13 +2171,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1825,13 +2190,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1842,13 +2209,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1859,7 +2228,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -1870,6 +2240,7 @@ import clsx from 'clsx' #[serial] fn extract_logical_case() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1880,13 +2251,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1897,13 +2270,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1914,13 +2289,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1931,7 +2308,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -1942,6 +2320,7 @@ import clsx from 'clsx' #[serial] fn extract_dynamic_logical_case() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1952,13 +2331,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1969,13 +2350,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -1986,13 +2369,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2003,7 +2388,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -2013,6 +2399,7 @@ import clsx from 'clsx' #[serial] fn extract_responsive_conditional_style_props_with_class_name() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2023,13 +2410,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2040,7 +2429,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -2051,6 +2441,7 @@ import clsx from 'clsx' #[serial] fn extract_selector() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2063,13 +2454,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2099,13 +2492,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2120,13 +2515,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2141,13 +2538,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2162,13 +2561,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2183,13 +2584,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2204,13 +2607,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2223,13 +2628,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2249,13 +2656,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2270,13 +2679,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2291,13 +2702,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2316,13 +2729,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2337,13 +2752,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2358,13 +2775,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2386,13 +2805,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2414,7 +2835,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -2425,6 +2847,7 @@ import clsx from 'clsx' #[serial] fn optimize_func() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2435,13 +2858,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2452,13 +2877,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2469,13 +2896,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2486,13 +2915,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2503,13 +2934,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2520,13 +2953,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2537,7 +2972,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -2548,6 +2984,7 @@ import clsx from 'clsx' #[serial] fn extract_selector_with_literal() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2560,13 +2997,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2581,7 +3020,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -2591,6 +3031,7 @@ import clsx from 'clsx' #[serial] fn extract_nested_selector() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2605,13 +3046,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2628,13 +3071,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2654,13 +3099,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2679,13 +3126,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2703,13 +3152,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2733,13 +3184,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2758,13 +3211,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2785,13 +3240,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2812,13 +3269,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2839,13 +3298,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2866,7 +3327,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -2877,6 +3339,7 @@ import clsx from 'clsx' #[serial] fn extract_conditional_selector() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2889,13 +3352,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2908,13 +3373,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2925,13 +3392,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2945,7 +3414,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -2956,6 +3426,7 @@ import clsx from 'clsx' #[serial] fn extract_selector_with_responsive() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2968,13 +3439,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -2989,13 +3462,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3012,7 +3487,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -3023,6 +3499,7 @@ import clsx from 'clsx' #[serial] fn extract_static_css_class_name_props() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3035,13 +3512,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3054,13 +3533,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3074,13 +3555,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3093,13 +3576,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3115,13 +3600,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3132,13 +3619,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3149,13 +3638,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3166,13 +3657,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3188,13 +3681,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3216,13 +3711,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3233,13 +3730,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3250,13 +3749,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3268,13 +3769,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3285,13 +3788,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3302,13 +3807,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3319,7 +3826,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -3330,6 +3838,7 @@ import clsx from 'clsx' #[serial] fn extract_static_css_with_media_query() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3346,13 +3855,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3372,13 +3883,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3393,7 +3906,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -3404,6 +3918,7 @@ import clsx from 'clsx' #[serial] fn extract_static_css_with_theme() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3414,13 +3929,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3431,13 +3948,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3448,7 +3967,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -3459,6 +3979,7 @@ import clsx from 'clsx' #[serial] fn apply_typography() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3469,13 +3990,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3486,13 +4009,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3503,7 +4028,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -3513,6 +4039,7 @@ import clsx from 'clsx' #[serial] fn apply_var_typography() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3523,13 +4050,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3540,13 +4069,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3557,13 +4088,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3579,7 +4112,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -3590,6 +4124,7 @@ import clsx from 'clsx' #[serial] fn raise_error() { reset_class_map(); + reset_file_map(); assert!( extract( "test.wrong", @@ -3598,7 +4133,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() }, ) .unwrap_err() @@ -3607,6 +4143,7 @@ import clsx from 'clsx' ); reset_class_map(); + reset_file_map(); assert_eq!( extract( "test.tsx", @@ -3615,7 +4152,8 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() }, ) .unwrap_err() @@ -3628,6 +4166,7 @@ import clsx from 'clsx' #[serial] fn import_wrong_component() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3637,13 +4176,15 @@ import clsx from 'clsx' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -3654,7 +4195,8 @@ useTheme(); package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -3665,6 +4207,7 @@ useTheme(); #[serial] fn support_transpile_mjs() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.mjs", @@ -3694,13 +4237,15 @@ export { package: "@devup-ui/react".to_string(), css_dir: "@devup-ui/react".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.js", @@ -3730,13 +4275,15 @@ export { package: "@devup-ui/react".to_string(), css_dir: "@devup-ui/react".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.js", @@ -3748,13 +4295,15 @@ e(o, { className: "a", bg: "red" }) package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.js", @@ -3766,13 +4315,15 @@ e(o, { className: "a", bg: variable, style: { color: "blue" } }) package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.js", @@ -3784,7 +4335,8 @@ e(o, { className: "a", bg: variable, style: { color: "blue" }, ...props }) package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -3792,6 +4344,7 @@ e(o, { className: "a", bg: variable, style: { color: "blue" }, ...props }) // conditional as reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.js", @@ -3799,11 +4352,12 @@ e(o, { className: "a", bg: variable, style: { color: "blue" }, ...props }) import { Box as o } from "@devup-ui/core"; e(o, { as: b ? "div" : "section", className: "a", bg: variable, style: { color: "blue" }, props: { animate: { duration: 1 } } }) "#, - ExtractOption { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, import_main_css: false } + ExtractOption { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, import_main_css: false, import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.js", @@ -3811,12 +4365,13 @@ e(o, { className: "a", bg: variable, style: { color: "blue" }, ...props }) import { Box as o } from "@devup-ui/core"; e(o, { as: Variable, className: "a", bg: variable, style: { color: "blue" }, props: { animate: { duration: 1 } } }) "#, - ExtractOption { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, import_main_css: false } + ExtractOption { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, import_main_css: false, import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.js", @@ -3824,7 +4379,7 @@ e(o, { className: "a", bg: variable, style: { color: "blue" }, ...props }) import { Box as o } from "@devup-ui/core"; e(o, { as: b ? null : undefined, className: "a", bg: variable, style: { color: "blue" }, props: { animate: { duration: 1 } } }) "#, - ExtractOption { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, import_main_css: false } + ExtractOption { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, import_main_css: false, import_aliases: HashMap::new() } ) .unwrap() )); @@ -3834,38 +4389,46 @@ e(o, { className: "a", bg: variable, style: { color: "blue" }, ...props }) #[serial] fn support_transpile_cjs() { reset_class_map(); - assert_debug_snapshot!(ToBTreeSet::from(extract("test.cjs", r#""use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),r=require("@devup-ui/react");function t(){return e.jsxs("div",{children:[e.jsx(r.Box,{_hover:{bg:"blue"},bg:"$text",color:"red",children:"hello"}),e.jsx(r.Text,{typography:"header",children:"typo"}),e.jsx(r.Flex,{as:"section",mt:2,children:"section"})]})}exports.Lib=t;"#, ExtractOption { package: "@devup-ui/react".to_string(), css_dir: "@devup-ui/react".to_string(), single_css: true, import_main_css: false }).unwrap())); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from(extract("test.cjs", r#""use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),r=require("@devup-ui/react");function t(){return e.jsxs("div",{children:[e.jsx(r.Box,{_hover:{bg:"blue"},bg:"$text",color:"red",children:"hello"}),e.jsx(r.Text,{typography:"header",children:"typo"}),e.jsx(r.Flex,{as:"section",mt:2,children:"section"})]})}exports.Lib=t;"#, ExtractOption { package: "@devup-ui/react".to_string(), css_dir: "@devup-ui/react".to_string(), single_css: true, import_main_css: false, import_aliases: HashMap::new() }).unwrap())); reset_class_map(); - assert_debug_snapshot!(ToBTreeSet::from(extract("test.cjs", r#""use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const {jsx:e1, jsxs:e2}=require("react/jsx-runtime"),r=require("@devup-ui/react");function t(){return e2("div",{children:[e1(r.Box,{_hover:{bg:"blue"},bg:"$text",color:"red",children:"hello"}),e1(r.Text,{typography:"header",children:"typo"}),e1(r.Flex,{as:"section",mt:2,children:"section"})]})}exports.Lib=t;"#, ExtractOption { package: "@devup-ui/react".to_string(), css_dir: "@devup-ui/react".to_string(), single_css: true, import_main_css: false }).unwrap())); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from(extract("test.cjs", r#""use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const {jsx:e1, jsxs:e2}=require("react/jsx-runtime"),r=require("@devup-ui/react");function t(){return e2("div",{children:[e1(r.Box,{_hover:{bg:"blue"},bg:"$text",color:"red",children:"hello"}),e1(r.Text,{typography:"header",children:"typo"}),e1(r.Flex,{as:"section",mt:2,children:"section"})]})}exports.Lib=t;"#, ExtractOption { package: "@devup-ui/react".to_string(), css_dir: "@devup-ui/react".to_string(), single_css: true, import_main_css: false, import_aliases: HashMap::new() }).unwrap())); reset_class_map(); - assert_debug_snapshot!(ToBTreeSet::from(extract("test.js", r#""use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),r=require("@devup-ui/react");function t(){return e.jsxs("div",{children:[e.jsx(r.Box,{_hover:{bg:"blue"},bg:"$text",color:"red",children:"hello"}),e.jsx(r.Text,{typography:"header",children:"typo"}),e.jsx(r.Flex,{as:"section",mt:2,children:"section"})]})}exports.Lib=t;"#, ExtractOption { package: "@devup-ui/react".to_string(), css_dir: "@devup-ui/react".to_string(), single_css: true, import_main_css: false }).unwrap())); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from(extract("test.js", r#""use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),r=require("@devup-ui/react");function t(){return e.jsxs("div",{children:[e.jsx(r.Box,{_hover:{bg:"blue"},bg:"$text",color:"red",children:"hello"}),e.jsx(r.Text,{typography:"header",children:"typo"}),e.jsx(r.Flex,{as:"section",mt:2,children:"section"})]})}exports.Lib=t;"#, ExtractOption { package: "@devup-ui/react".to_string(), css_dir: "@devup-ui/react".to_string(), single_css: true, import_main_css: false, import_aliases: HashMap::new() }).unwrap())); reset_class_map(); - assert_debug_snapshot!(ToBTreeSet::from(extract("test.js", r#""use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),r=require("@devup-ui/react");function t(){return e.jsxs("div",{children:[e.jsx(r.Box,{_hover:{bg:"blue"},bg:"$text",color:"red",children:"hello"}),e.jsx(r.Text,{typography:`header`,children:"typo"}),e.jsx(r.Flex,{as:"section",mt:2,children:"section"})]})}exports.Lib=t;"#, ExtractOption { package: "@devup-ui/react".to_string(), css_dir: "@devup-ui/react".to_string(), single_css: true, import_main_css: false }).unwrap())); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from(extract("test.js", r#""use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),r=require("@devup-ui/react");function t(){return e.jsxs("div",{children:[e.jsx(r.Box,{_hover:{bg:"blue"},bg:"$text",color:"red",children:"hello"}),e.jsx(r.Text,{typography:`header`,children:"typo"}),e.jsx(r.Flex,{as:"section",mt:2,children:"section"})]})}exports.Lib=t;"#, ExtractOption { package: "@devup-ui/react".to_string(), css_dir: "@devup-ui/react".to_string(), single_css: true, import_main_css: false, import_aliases: HashMap::new() }).unwrap())); reset_class_map(); - assert_debug_snapshot!(ToBTreeSet::from(extract("test.js", r#""use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),{Box,Text,Flex}=require("@devup-ui/react");function t(){return e.jsxs("div",{children:[e.jsx(Box,{_hover:{bg:"blue"},bg:"$text",color:"red",children:"hello"}),e.jsx(Text,{typography:`header`,children:"typo"}),e.jsx(Flex,{as:"section",mt:2,children:"section"})]})}exports.Lib=t;"#, ExtractOption { package: "@devup-ui/react".to_string(), css_dir: "@devup-ui/react".to_string(), single_css: true, import_main_css: false }).unwrap())); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from(extract("test.js", r#""use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),{Box,Text,Flex}=require("@devup-ui/react");function t(){return e.jsxs("div",{children:[e.jsx(Box,{_hover:{bg:"blue"},bg:"$text",color:"red",children:"hello"}),e.jsx(Text,{typography:`header`,children:"typo"}),e.jsx(Flex,{as:"section",mt:2,children:"section"})]})}exports.Lib=t;"#, ExtractOption { package: "@devup-ui/react".to_string(), css_dir: "@devup-ui/react".to_string(), single_css: true, import_main_css: false, import_aliases: HashMap::new() }).unwrap())); reset_class_map(); - assert_debug_snapshot!(ToBTreeSet::from(extract("test.js", r#""use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),{Box,Text,Flex}=require("@devup-ui/react");function t(){return e.jsxs("div",{children:[e.jsx(Box,{["_hover"]:{bg:"blue"},bg:"$text",color:"red",children:"hello"}),e.jsx(Text,{typography:`header`,children:"typo"}),e.jsx(Flex,{as:"section",mt:2,children:"section"})]})}exports.Lib=t;"#, ExtractOption { package: "@devup-ui/react".to_string(), css_dir: "@devup-ui/react".to_string(), single_css: true, import_main_css: false }).unwrap())); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from(extract("test.js", r#""use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),{Box,Text,Flex}=require("@devup-ui/react");function t(){return e.jsxs("div",{children:[e.jsx(Box,{["_hover"]:{bg:"blue"},bg:"$text",color:"red",children:"hello"}),e.jsx(Text,{typography:`header`,children:"typo"}),e.jsx(Flex,{as:"section",mt:2,children:"section"})]})}exports.Lib=t;"#, ExtractOption { package: "@devup-ui/react".to_string(), css_dir: "@devup-ui/react".to_string(), single_css: true, import_main_css: false, import_aliases: HashMap::new() }).unwrap())); reset_class_map(); - assert_debug_snapshot!(ToBTreeSet::from(extract("test.js", r#""use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),{Box,Text,Flex}=require("@devup-ui/react");function t(){return e.jsxs("div",{children:[e.jsx(Box,{["_hover"]:{bg:"blue"},bg:"$text",[variable]:"red",children:"hello"})]})}exports.Lib=t;"#, ExtractOption { package: "@devup-ui/react".to_string(), css_dir: "@devup-ui/react".to_string(), single_css: true, import_main_css: false }).unwrap())); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from(extract("test.js", r#""use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),{Box,Text,Flex}=require("@devup-ui/react");function t(){return e.jsxs("div",{children:[e.jsx(Box,{["_hover"]:{bg:"blue"},bg:"$text",[variable]:"red",children:"hello"})]})}exports.Lib=t;"#, ExtractOption { package: "@devup-ui/react".to_string(), css_dir: "@devup-ui/react".to_string(), single_css: true, import_main_css: false, import_aliases: HashMap::new() }).unwrap())); } #[test] #[serial] fn maintain_value() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", r#"import {Flex} from '@devup-ui/core' "#, - ExtractOption { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, import_main_css: false } + ExtractOption { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, import_main_css: false, import_aliases: HashMap::new() } ) .unwrap() )); @@ -3875,6 +4438,7 @@ e(o, { className: "a", bg: variable, style: { color: "blue" }, ...props }) #[serial] fn with_prefix() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -3885,7 +4449,8 @@ e(o, { className: "a", bg: variable, style: { color: "blue" }, ...props }) package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -3896,6 +4461,7 @@ e(o, { className: "a", bg: variable, style: { color: "blue" }, ...props }) #[serial] fn optimize_aspect_ratio() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -3906,13 +4472,15 @@ e(o, { className: "a", bg: variable, style: { color: "blue" }, ...props }) package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -3923,13 +4491,15 @@ e(o, { className: "a", bg: variable, style: { color: "blue" }, ...props }) package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -3940,7 +4510,8 @@ e(o, { className: "a", bg: variable, style: { color: "blue" }, ...props }) package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -3951,6 +4522,7 @@ e(o, { className: "a", bg: variable, style: { color: "blue" }, ...props }) #[serial] fn ternary_operator_in_selector() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -3961,13 +4533,15 @@ e(o, { className: "a", bg: variable, style: { color: "blue" }, ...props }) package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -3978,13 +4552,15 @@ e(o, { className: "a", bg: variable, style: { color: "blue" }, ...props }) package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -3995,7 +4571,8 @@ e(o, { className: "a", bg: variable, style: { color: "blue" }, ...props }) package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -4006,6 +4583,7 @@ e(o, { className: "a", bg: variable, style: { color: "blue" }, ...props }) #[serial] fn test_rest_props() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4016,13 +4594,15 @@ e(o, { className: "a", bg: variable, style: { color: "blue" }, ...props }) package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4052,7 +4632,8 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -4063,6 +4644,7 @@ export default function Card({ #[serial] fn props_wrong_direct_array_select() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4073,13 +4655,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4090,13 +4674,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4107,13 +4693,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4124,13 +4712,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -4141,7 +4731,8 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -4151,6 +4742,7 @@ export default function Card({ #[serial] fn negative_props() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4161,13 +4753,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4178,13 +4772,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4195,13 +4791,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4212,13 +4810,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4229,13 +4829,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4246,13 +4848,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4263,7 +4867,8 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -4274,6 +4879,7 @@ export default function Card({ #[serial] fn props_wrong_direct_object_select() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4284,13 +4890,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4301,13 +4909,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4318,13 +4928,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4335,7 +4947,8 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -4346,6 +4959,7 @@ export default function Card({ #[serial] fn extract_conditional_style_props_with_class_name() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -4360,13 +4974,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4377,7 +4993,8 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -4388,6 +5005,7 @@ export default function Card({ #[serial] fn props_direct_array_select() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4398,13 +5016,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4415,13 +5035,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4432,13 +5054,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4449,13 +5073,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4469,13 +5095,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4486,13 +5114,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4503,7 +5133,8 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -4514,6 +5145,7 @@ export default function Card({ #[serial] fn props_multi_expression() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4544,7 +5176,8 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -4555,6 +5188,7 @@ export default function Card({ #[serial] fn props_direct_object_select() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4565,13 +5199,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4582,13 +5218,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4599,13 +5237,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4616,7 +5256,8 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -4627,6 +5268,7 @@ export default function Card({ #[serial] fn props_direct_variable_object_select() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4637,12 +5279,14 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4653,7 +5297,8 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -4664,6 +5309,7 @@ export default function Card({ #[serial] fn props_direct_object_responsive_select() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4674,13 +5320,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4691,7 +5339,8 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -4701,6 +5350,7 @@ export default function Card({ #[serial] fn props_direct_variable_object_responsive_select() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4711,7 +5361,8 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -4722,6 +5373,7 @@ export default function Card({ #[serial] fn props_direct_array_responsive_select() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4732,13 +5384,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4749,7 +5403,8 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -4759,6 +5414,7 @@ export default function Card({ #[serial] fn props_direct_variable_array_responsive_select() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4769,13 +5425,15 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4786,7 +5444,8 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -4797,6 +5456,7 @@ export default function Card({ #[serial] fn props_direct_hybrid_responsive_select() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4807,7 +5467,8 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -4818,6 +5479,7 @@ export default function Card({ #[serial] fn props_direct_wrong() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4828,7 +5490,8 @@ export default function Card({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -4838,6 +5501,7 @@ export default function Card({ #[serial] fn test_component_in_func() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4853,7 +5517,8 @@ PROCESS_DATA.map(({ id, title, content }, idx) => ( package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -4864,6 +5529,7 @@ PROCESS_DATA.map(({ id, title, content }, idx) => ( #[serial] fn backtick_prop() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4874,13 +5540,15 @@ PROCESS_DATA.map(({ id, title, content }, idx) => ( package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4891,7 +5559,8 @@ PROCESS_DATA.map(({ id, title, content }, idx) => ( package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -4902,6 +5571,7 @@ PROCESS_DATA.map(({ id, title, content }, idx) => ( #[serial] fn group_selector_props() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4912,7 +5582,8 @@ PROCESS_DATA.map(({ id, title, content }, idx) => ( package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -4923,6 +5594,7 @@ PROCESS_DATA.map(({ id, title, content }, idx) => ( #[serial] fn test_duplicate_style_props() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4933,7 +5605,8 @@ PROCESS_DATA.map(({ id, title, content }, idx) => ( package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -4944,6 +5617,7 @@ PROCESS_DATA.map(({ id, title, content }, idx) => ( #[serial] fn avoid_same_name_component() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4956,7 +5630,8 @@ import {Button} from '@devup/ui' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -4967,6 +5642,7 @@ import {Button} from '@devup/ui' #[serial] fn css_props_destructuring_assignment() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -4980,13 +5656,15 @@ import {Button} from '@devup/ui' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5000,7 +5678,8 @@ import {Button} from '@devup/ui' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -5011,6 +5690,7 @@ import {Button} from '@devup/ui' #[serial] fn theme_props() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5021,7 +5701,8 @@ import {Button} from '@devup/ui' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -5032,6 +5713,7 @@ import {Button} from '@devup/ui' #[serial] fn nested_theme_props() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5054,7 +5736,8 @@ import {Button} from '@devup/ui' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -5065,6 +5748,7 @@ import {Button} from '@devup/ui' #[serial] fn template_literal_props() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5075,13 +5759,15 @@ import {Button} from '@devup/ui' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5092,13 +5778,15 @@ import {Button} from '@devup/ui' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5109,13 +5797,15 @@ import {Button} from '@devup/ui' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5126,13 +5816,15 @@ import {Button} from '@devup/ui' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5143,13 +5835,15 @@ import {Button} from '@devup/ui' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5164,7 +5858,8 @@ import {Button} from '@devup/ui' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -5175,6 +5870,7 @@ import {Button} from '@devup/ui' #[serial] fn theme_selector() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5185,12 +5881,14 @@ import {Button} from '@devup/ui' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5201,13 +5899,15 @@ import {Button} from '@devup/ui' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5225,7 +5925,8 @@ import {Button} from '@devup/ui' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -5236,6 +5937,7 @@ import {Button} from '@devup/ui' #[serial] fn custom_selector() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5250,13 +5952,15 @@ import {Button} from '@devup/ui' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5271,13 +5975,15 @@ import {Button} from '@devup/ui' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5292,7 +5998,8 @@ import {Button} from '@devup/ui' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -5303,6 +6010,7 @@ import {Button} from '@devup/ui' #[serial] fn style_order() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5317,13 +6025,15 @@ import {Button} from '@devup/ui' package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.mjs", @@ -5354,13 +6064,15 @@ export { package: "@devup-ui/react".to_string(), css_dir: "@devup-ui/react".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5371,13 +6083,15 @@ export { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5388,13 +6102,15 @@ export { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5405,13 +6121,15 @@ export { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5429,13 +6147,15 @@ export { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5454,13 +6174,15 @@ export { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5471,7 +6193,8 @@ export { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -5482,6 +6205,7 @@ export { #[serial] fn style_order2() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5499,13 +6223,15 @@ export { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5523,13 +6249,15 @@ export { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5547,7 +6275,8 @@ export { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -5558,6 +6287,7 @@ export { #[serial] fn style_variables() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5570,13 +6300,15 @@ export { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5589,13 +6321,15 @@ export { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5609,13 +6343,15 @@ export { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5628,13 +6364,15 @@ export { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5647,13 +6385,15 @@ export { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5666,13 +6406,15 @@ export { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5685,13 +6427,15 @@ export { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5704,13 +6448,15 @@ export { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5726,13 +6472,15 @@ export { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5743,13 +6491,15 @@ export { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5760,7 +6510,8 @@ export { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -5771,6 +6522,7 @@ export { #[serial] fn wrong_style_variables() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.jsx", @@ -5781,7 +6533,8 @@ export { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -5792,6 +6545,7 @@ export { #[serial] fn style_variables_mjs() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.js", @@ -5803,7 +6557,8 @@ e(o, { styleVars: { c: "yellow" } }) package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -5814,6 +6569,7 @@ e(o, { styleVars: { c: "yellow" } }) #[serial] fn extract_global_css() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -5828,13 +6584,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -5849,13 +6607,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -5870,13 +6630,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -5891,13 +6653,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -5912,13 +6676,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -5933,13 +6699,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -5954,13 +6722,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -5971,13 +6741,15 @@ globalCss(...{}) package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -5988,7 +6760,8 @@ globalCss(...{div: {bg: "red"}}) package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -5996,6 +6769,7 @@ globalCss(...{div: {bg: "red"}}) // recursive spread reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6006,7 +6780,8 @@ globalCss(...{div: {bg: "red"}, ...{span: {bg: "blue"}}}) package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -6017,6 +6792,7 @@ globalCss(...{div: {bg: "red"}, ...{span: {bg: "blue"}}}) #[serial] fn extract_wrong_global_css() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6031,13 +6807,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6048,13 +6826,15 @@ globalCss() package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6065,7 +6845,8 @@ globalCss(1) package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -6076,6 +6857,7 @@ globalCss(1) #[serial] fn extract_global_css_with_selector() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6095,13 +6877,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6129,13 +6913,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6163,13 +6949,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6205,7 +6993,8 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -6216,6 +7005,7 @@ globalCss({ #[serial] fn extract_global_css_with_template_literal() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6230,13 +7020,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6249,13 +7041,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6268,13 +7062,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6288,13 +7084,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6310,13 +7108,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6327,13 +7127,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6344,13 +7146,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6362,13 +7166,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6379,7 +7185,8 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -6390,6 +7197,7 @@ globalCss({ #[serial] fn extract_global_css_with_imports() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6402,13 +7210,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6421,13 +7231,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6440,7 +7252,8 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -6451,6 +7264,7 @@ globalCss({ #[serial] fn extract_global_css_with_font_faces() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6474,13 +7288,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6499,13 +7315,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6523,13 +7341,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6546,13 +7366,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6571,13 +7393,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6596,13 +7420,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6636,13 +7462,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6655,13 +7483,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6674,13 +7504,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6693,7 +7525,8 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -6704,6 +7537,7 @@ globalCss({ #[serial] fn extract_global_css_with_wrong_imports() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6716,13 +7550,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6735,7 +7571,8 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -6746,6 +7583,7 @@ globalCss({ #[serial] fn extract_global_css_with_empty() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6758,13 +7596,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6778,13 +7618,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6797,13 +7639,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6817,13 +7661,15 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6834,13 +7680,15 @@ globalCss({}) package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6851,7 +7699,8 @@ globalCss() package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -6862,6 +7711,7 @@ globalCss() #[serial] fn extract_keyframs() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6875,13 +7725,15 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6896,13 +7748,15 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6917,13 +7771,15 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6938,13 +7794,15 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6959,13 +7817,15 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -6980,13 +7840,15 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7001,13 +7863,15 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7022,13 +7886,15 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7059,13 +7925,15 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7080,7 +7948,8 @@ keyframes(...{ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -7090,6 +7959,7 @@ keyframes(...{ #[serial] fn extract_wrong_keyframs() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7104,7 +7974,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -7115,6 +7986,7 @@ keyframes({ #[serial] fn extract_keyframs_literal() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7149,13 +8021,15 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7196,7 +8070,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -7207,6 +8082,7 @@ keyframes({ #[serial] fn extract_just_tsx_in_multiple_files() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7217,7 +8093,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -7232,7 +8109,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -7248,7 +8126,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -7263,7 +8142,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -7274,6 +8154,7 @@ keyframes({ #[serial] fn import_main_css() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7284,7 +8165,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: true + import_main_css: true, + import_aliases: HashMap::new() } ) .unwrap() @@ -7295,6 +8177,7 @@ keyframes({ #[serial] fn optimize_multi_css_value() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7305,7 +8188,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -7316,6 +8200,7 @@ keyframes({ #[serial] fn extract_enum_style_property() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7326,7 +8211,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -7334,6 +8220,7 @@ keyframes({ // wrong case reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7344,13 +8231,15 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7361,13 +8250,15 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7378,13 +8269,15 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7395,13 +8288,15 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7412,7 +8307,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -7423,6 +8319,7 @@ keyframes({ #[serial] fn extract_advenced_selector() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7436,13 +8333,15 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7456,7 +8355,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -7464,6 +8364,7 @@ keyframes({ // empty reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7476,13 +8377,15 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7498,13 +8401,15 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7520,13 +8425,15 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7542,13 +8449,15 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7567,13 +8476,15 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7589,7 +8500,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -7601,6 +8513,8 @@ keyframes({ fn test_styled() { // Test 1: styled.div`css` reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7614,7 +8528,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -7622,6 +8537,8 @@ keyframes({ // Test 2: styled("div")`css` reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7635,7 +8552,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -7643,6 +8561,8 @@ keyframes({ // Test 3: styled("div")({ bg: "red" }) reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7653,7 +8573,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -7661,6 +8582,8 @@ keyframes({ // Test 4: styled.div({ bg: "red" }) reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7671,7 +8594,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -7679,6 +8603,8 @@ keyframes({ // Test 5: styled(Component)({ bg: "red" }) reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7689,13 +8615,16 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7709,13 +8638,16 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7726,13 +8658,16 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7746,13 +8681,16 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7763,13 +8701,16 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7783,13 +8724,16 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7800,7 +8744,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -7812,6 +8757,8 @@ keyframes({ fn test_styled_with_variable() { // Test 1: styled.div({ bg: "$text" }) reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7822,7 +8769,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -7830,6 +8778,8 @@ keyframes({ // Test 2: styled("div")({ color: "$primary" }) reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7840,7 +8790,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -7848,6 +8799,8 @@ keyframes({ // Test 3: styled.div`css` reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7861,7 +8814,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -7869,6 +8823,8 @@ keyframes({ // Test 4: styled(Component)({ bg: "$text" }) reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7879,7 +8835,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -7887,6 +8844,8 @@ keyframes({ // Test 5: styled("div")`css` reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7900,7 +8859,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -7912,6 +8872,8 @@ keyframes({ fn test_styled_with_variable_like_emotion() { // Test 1: styled.div`css with ${variable}` reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7926,7 +8888,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -7934,6 +8897,8 @@ keyframes({ // Test 2: styled("div")`css with ${variable}` reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7949,13 +8914,16 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7968,13 +8936,16 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -7987,13 +8958,16 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -8008,13 +8982,16 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -8025,13 +9002,16 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -8042,7 +9022,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8054,6 +9035,8 @@ keyframes({ fn test_styled_with_variable_like_emotion_props() { // Test 3: styled.div`css with ${props => props.bg}` reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -8067,7 +9050,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8075,6 +9059,8 @@ keyframes({ // Test 4: styled(Component)`css with ${variable}` reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -8089,7 +9075,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8097,6 +9084,8 @@ keyframes({ // Test 5: styled.div`css with multiple ${variables}` reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -8113,7 +9102,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8121,6 +9111,8 @@ keyframes({ // Test 6: styled.div`css with ${expression}` reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -8135,7 +9127,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8146,6 +9139,8 @@ keyframes({ #[serial] fn test_wrong_styled_with_variable_like_emotion_props() { reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -8159,13 +9154,16 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -8179,13 +9177,16 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -8196,13 +9197,16 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -8213,13 +9217,16 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); reset_class_map(); + reset_file_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -8230,7 +9237,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8241,6 +9249,7 @@ keyframes({ #[serial] fn test_mask_properties_with_korean() { reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -8259,7 +9268,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8271,6 +9281,7 @@ keyframes({ fn test_dot_notation_theme_variables() { // Test that dot notation theme variables (e.g., $primary.100) are correctly extracted reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -8281,7 +9292,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8289,6 +9301,7 @@ keyframes({ // Test multiple dot notation variables reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -8299,7 +9312,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8307,6 +9321,7 @@ keyframes({ // Test deep nested dot notation reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -8317,7 +9332,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8325,6 +9341,7 @@ keyframes({ // Test dot notation in border shorthand reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -8335,7 +9352,8 @@ keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: true, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8346,6 +9364,7 @@ keyframes({ #[serial] fn test_styled_with_spread() { reset_class_map(); + reset_file_map(); // Test styled with spread element assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8358,7 +9377,8 @@ const StyledDiv = styled.div({ ...baseStyles }) package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8369,6 +9389,7 @@ const StyledDiv = styled.div({ ...baseStyles }) #[serial] fn test_css_function_no_args() { reset_class_map(); + reset_file_map(); // Test css() with no arguments assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8380,7 +9401,8 @@ const className = css() package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8391,6 +9413,7 @@ const className = css() #[serial] fn test_css_function_empty_object() { reset_class_map(); + reset_file_map(); // Test css() with empty object assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8402,7 +9425,8 @@ const className = css({}) package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8413,6 +9437,7 @@ const className = css({}) #[serial] fn test_keyframes_function() { reset_class_map(); + reset_file_map(); // Test keyframes() function assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8427,7 +9452,8 @@ const spin = keyframes({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8438,6 +9464,7 @@ const spin = keyframes({ #[serial] fn test_global_css_function() { reset_class_map(); + reset_file_map(); // Test globalCss() function assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8451,7 +9478,8 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8462,6 +9490,7 @@ globalCss({ #[serial] fn test_conditional_styles() { reset_class_map(); + reset_file_map(); // Test conditional styles with both branches having different properties assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8476,7 +9505,8 @@ const Component = () => { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8487,6 +9517,7 @@ const Component = () => { #[serial] fn test_css_variable_reassignment() { reset_class_map(); + reset_file_map(); // Test css import reassignment assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8499,7 +9530,8 @@ const className = myCss({ bg: "red" }) package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8510,6 +9542,7 @@ const className = myCss({ bg: "red" }) #[serial] fn test_global_css_with_imports() { reset_class_map(); + reset_file_map(); // Test globalCss with @import assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8523,7 +9556,8 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8534,6 +9568,7 @@ globalCss({ #[serial] fn test_global_css_with_font_faces() { reset_class_map(); + reset_file_map(); // Test globalCss with fontFaces assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8553,7 +9588,8 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8564,6 +9600,7 @@ globalCss({ #[serial] fn test_global_css_with_pseudo_selector() { reset_class_map(); + reset_file_map(); // Test globalCss with pseudo selector (prefixed with _) assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8577,7 +9614,8 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8588,6 +9626,7 @@ globalCss({ #[serial] fn test_responsive_array_styles() { reset_class_map(); + reset_file_map(); // Test responsive array with multiple breakpoints assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8599,7 +9638,8 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8610,6 +9650,7 @@ globalCss({ #[serial] fn test_member_expression_style() { reset_class_map(); + reset_file_map(); // Test dynamic member expression for styles (obj[key]) assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8623,7 +9664,8 @@ const key = "primary"; package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8634,6 +9676,7 @@ const key = "primary"; #[serial] fn test_dynamic_class_name_merge() { reset_class_map(); + reset_file_map(); // Test dynamic className merging with existing className assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8647,7 +9690,8 @@ const Component = ({ className }) => { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8658,6 +9702,7 @@ const Component = ({ className }) => { #[serial] fn test_typography_style() { reset_class_map(); + reset_file_map(); // Test typography prop assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8669,7 +9714,8 @@ const Component = ({ className }) => { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8680,6 +9726,7 @@ const Component = ({ className }) => { #[serial] fn test_css_with_template_literal() { reset_class_map(); + reset_file_map(); // Test css function with template literal containing expressions assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8692,7 +9739,8 @@ const className = css({ fontSize: `${size}px` }) package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8703,6 +9751,7 @@ const className = css({ fontSize: `${size}px` }) #[serial] fn test_conditional_with_both_branches() { reset_class_map(); + reset_file_map(); // Test conditional where both branches have styles assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8715,7 +9764,8 @@ const isActive = true; package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8726,6 +9776,7 @@ const isActive = true; #[serial] fn test_spread_props() { reset_class_map(); + reset_file_map(); // Test spread props on component assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8739,7 +9790,8 @@ const Component = (props) => { package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8750,6 +9802,7 @@ const Component = (props) => { #[serial] fn test_nested_conditional() { reset_class_map(); + reset_file_map(); // Test nested conditional expressions assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8763,7 +9816,8 @@ const b = false; package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8774,6 +9828,7 @@ const b = false; #[serial] fn test_style_prop_merge() { reset_class_map(); + reset_file_map(); // Test style prop merging with dynamic styles assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8786,7 +9841,8 @@ const color = "red"; package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8797,6 +9853,7 @@ const color = "red"; #[serial] fn test_keyframes_no_args() { reset_class_map(); + reset_file_map(); // Test keyframes with no arguments assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8808,7 +9865,8 @@ const spin = keyframes() package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8819,6 +9877,7 @@ const spin = keyframes() #[serial] fn test_global_css_no_args() { reset_class_map(); + reset_file_map(); // Test globalCss with no arguments assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8830,7 +9889,8 @@ globalCss() package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8841,6 +9901,7 @@ globalCss() #[serial] fn test_default_import_usage() { reset_class_map(); + reset_file_map(); // Test using default import assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8852,7 +9913,8 @@ globalCss() package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8863,6 +9925,7 @@ globalCss() #[serial] fn test_namespace_import_usage() { reset_class_map(); + reset_file_map(); // Test using namespace import assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8874,7 +9937,8 @@ globalCss() package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8885,6 +9949,7 @@ globalCss() #[serial] fn test_namespace_import_css() { reset_class_map(); + reset_file_map(); // Test using namespace import with css function assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8896,7 +9961,8 @@ const className = DevUI.css({ bg: "red" }) package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8907,6 +9973,7 @@ const className = DevUI.css({ bg: "red" }) #[serial] fn test_enum_style_prop() { reset_class_map(); + reset_file_map(); // Test enum-like style mapping assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8920,7 +9987,8 @@ const colors = { primary: "blue", secondary: "red" }; package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8931,6 +9999,7 @@ const colors = { primary: "blue", secondary: "red" }; #[serial] fn test_style_vars_prop() { reset_class_map(); + reset_file_map(); // Test styleVars prop assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8943,7 +10012,8 @@ const dynamicColor = "blue"; package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8954,6 +10024,7 @@ const dynamicColor = "blue"; #[serial] fn test_props_prop() { reset_class_map(); + reset_file_map(); // Test props prop forwarding assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8966,7 +10037,8 @@ const extraProps = { onClick: () => {} }; package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8977,6 +10049,7 @@ const extraProps = { onClick: () => {} }; #[serial] fn test_style_order_prop() { reset_class_map(); + reset_file_map(); // Test styleOrder prop assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -8988,7 +10061,8 @@ const extraProps = { onClick: () => {} }; package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -8999,6 +10073,7 @@ const extraProps = { onClick: () => {} }; #[serial] fn test_multiple_dynamic_values() { reset_class_map(); + reset_file_map(); // Test multiple dynamic values assert_debug_snapshot!(ToBTreeSet::from( extract( @@ -9013,7 +10088,8 @@ const margin = 5; package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -9025,6 +10101,7 @@ const margin = 5; fn test_media_query_selectors() { // Test _print media query selector reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -9035,7 +10112,8 @@ const margin = 5; package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -9043,6 +10121,7 @@ const margin = 5; // Test _screen media query selector reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -9053,7 +10132,8 @@ const margin = 5; package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -9061,6 +10141,7 @@ const margin = 5; // Test _speech media query selector reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -9071,7 +10152,8 @@ const margin = 5; package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -9079,6 +10161,7 @@ const margin = 5; // Test _all media query selector reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -9089,7 +10172,8 @@ const margin = 5; package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -9097,6 +10181,7 @@ const margin = 5; // Test multiple media query selectors combined reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -9111,7 +10196,8 @@ const margin = 5; package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -9123,6 +10209,7 @@ const margin = 5; fn test_at_rules_underscore_prefix() { // Test _container at-rule reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -9133,7 +10220,8 @@ const margin = 5; package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -9141,6 +10229,7 @@ const margin = 5; // Test _media at-rule reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -9151,7 +10240,8 @@ const margin = 5; package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -9159,6 +10249,7 @@ const margin = 5; // Test _supports at-rule reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -9169,7 +10260,8 @@ const margin = 5; package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -9177,6 +10269,7 @@ const margin = 5; // Test _container with named container reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -9187,7 +10280,8 @@ const margin = 5; package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -9199,6 +10293,7 @@ const margin = 5; fn test_at_rules_at_prefix() { // Test @container at-rule reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -9209,7 +10304,8 @@ const margin = 5; package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -9217,6 +10313,7 @@ const margin = 5; // Test @media at-rule reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -9227,7 +10324,8 @@ const margin = 5; package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -9235,6 +10333,7 @@ const margin = 5; // Test @supports at-rule reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -9245,7 +10344,8 @@ const margin = 5; package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -9257,6 +10357,7 @@ const margin = 5; fn test_global_css_at_rules() { // Test globalCss with @media nested inside selector reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -9273,7 +10374,8 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -9281,6 +10383,7 @@ globalCss({ // Test globalCss with @supports nested inside selector reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -9297,7 +10400,8 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -9305,6 +10409,7 @@ globalCss({ // Test globalCss with @container nested inside selector reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -9321,7 +10426,8 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() @@ -9329,6 +10435,7 @@ globalCss({ // Test globalCss with multiple at-rules nested inside selectors reset_class_map(); + reset_file_map(); assert_debug_snapshot!(ToBTreeSet::from( extract( "test.tsx", @@ -9352,88 +10459,2569 @@ globalCss({ package: "@devup-ui/core".to_string(), css_dir: "@devup-ui/core".to_string(), single_css: false, - import_main_css: false + import_main_css: false, + import_aliases: HashMap::new() } ) .unwrap() )); } - #[rstest] - #[case("test.tsx", "const x = 1;", "@devup-ui/react", false)] // no package string - #[case( - "test.invalid", - "import { Box } from '@devup-ui/react';", - "@devup-ui/react", - false - )] // invalid extension - #[case( - "test.tsx", - "import { Box } from '@devup-ui/react';", - "@devup-ui/react", - true - )] // named import - #[case( - "test.tsx", - "// import from @devup-ui/react\nconst x = 1;", - "@devup-ui/react", - false - )] // in comment - #[case( - "test.tsx", - "import { Box } from '@devup-ui/core';", - "@devup-ui/react", - false - )] // different package - #[case( - "test.tsx", - "import Box from '@devup-ui/react';", - "@devup-ui/react", - true - )] // default import - #[case( - "test.tsx", - "import * as DevupUI from '@devup-ui/react';", - "@devup-ui/react", - true - )] // namespace import - #[case( - "test.tsx", - "import React from 'react';\nimport { Box } from '@devup-ui/react';", - "@devup-ui/react", - true - )] // multiple imports - #[case("test.tsx", "const pkg = '@devup-ui/react';", "@devup-ui/react", false)] // string literal - #[case( - "test.js", - "import { Box } from '@devup-ui/react';", - "@devup-ui/react", - true - )] // .js - #[case( - "test.ts", - "import { Box } from '@devup-ui/react';", - "@devup-ui/react", - true - )] // .ts - #[case( - "test.jsx", - "import { Box } from '@devup-ui/react';", - "@devup-ui/react", - true - )] // .jsx - #[case( - "test.unknown", - "import { Box } from '@devup-ui/react';", - "@devup-ui/react", - false - )] // unsupported file extension - fn test_has_devup_ui( - #[case] filename: &str, - #[case] code: &str, - #[case] package: &str, - #[case] expected: bool, - ) { - assert_eq!(has_devup_ui(filename, code, package), expected); + #[test] + #[serial] + fn test_global_css_with_layer() { + // Test globalCss with @layer property + reset_class_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "test.tsx", + r#"import {globalCss} from '@devup-ui/core' +globalCss({ + "*": { + "@layer": "reset", + margin: 0, + padding: 0 + } +}) +"#, + ExtractOption { + package: "@devup-ui/core".to_string(), + css_dir: "@devup-ui/core".to_string(), + single_css: false, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + + // Test globalCss with @layer for multiple selectors + reset_class_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "test.tsx", + r#"import {globalCss} from '@devup-ui/core' +globalCss({ + "*": { + "@layer": "reset", + boxSizing: "border-box" + }, + body: { + "@layer": "base", + fontFamily: "sans-serif" + } +}) +"#, + ExtractOption { + package: "@devup-ui/core".to_string(), + css_dir: "@devup-ui/core".to_string(), + single_css: false, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + // ============================================================================ + // VANILLA-EXTRACT API TESTS + // ============================================================================ + + /// Test vanilla-extract style files (.css.ts, .css.js) + /// Using vanilla-extract API (style, globalStyle, keyframes) from @devup-ui/react package + #[test] + #[serial] + fn test_vanilla_extract_style_css_ts() { + reset_class_map(); + reset_file_map(); + // .css.ts file with style function (vanilla-extract API) + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "styles.css.ts", + r#"import { style } from '@devup-ui/react' +export const container: string = style({ background: "red", padding: 16 }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_style_css_js() { + reset_class_map(); + reset_file_map(); + // .css.js file with style function + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "styles.css.js", + r#"import { style } from '@devup-ui/react' +export const wrapper = style({ backgroundColor: "white", margin: 8 }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + + reset_class_map(); + reset_file_map(); + // .css.js file with style function for link + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "components.css.js", + r#"import { style } from '@devup-ui/react' +export const link = style({ color: "blue", textDecoration: "underline" }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + /// Test .css.ts files with @vanilla-extract/css import (compatibility mode) + #[test] + #[serial] + fn test_vanilla_extract_css_ts_with_vanilla_extract_import() { + reset_class_map(); + reset_file_map(); + // .css.ts file with import from @vanilla-extract/css (not @devup-ui/react) + // This should work the same as importing from @devup-ui/react + let mut import_aliases = HashMap::new(); + import_aliases.insert( + "@vanilla-extract/css".to_string(), + ImportAlias::NamedToNamed, + ); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "styles.css.ts", + r#"import { style } from '@vanilla-extract/css' +export const hello = style({ + cursor: 'pointer', + fontSize: 32, + paddingTop: '28px', + paddingBottom: '28px', +}) +export const text = style({ + color: 'var(--text)', +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_with_variable() { + reset_class_map(); + reset_file_map(); + // Variables should be evaluated at execution time + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "vars.css.ts", + r#"import { style } from '@devup-ui/react' +const primaryColor = "blue"; +const spacing = 16; +export const button = style({ background: primaryColor, padding: spacing }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_with_computed() { + reset_class_map(); + reset_file_map(); + // Computed values should be evaluated + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "computed.css.ts", + r#"import { style } from '@devup-ui/react' +const base = 8; +export const box = style({ padding: base * 2, margin: base / 2 }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_with_spread() { + reset_class_map(); + reset_file_map(); + // Spread operator should work + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "spread.css.ts", + r#"import { style } from '@devup-ui/react' +const baseStyle = { padding: 8, margin: 4 }; +export const extended = style({ ...baseStyle, background: "red" }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_with_pseudo_selector() { + reset_class_map(); + reset_file_map(); + // devup-ui extension: _hover pseudo selector + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "hover.css.ts", + r#"import { style } from '@devup-ui/react' +export const hoverButton = style({ background: "gray", _hover: { background: "blue" } }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_with_responsive_array() { + reset_class_map(); + reset_file_map(); + // devup-ui extension: responsive arrays + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "responsive.css.ts", + r#"import { style } from '@devup-ui/react' +export const responsiveBox = style({ padding: [8, 16, 32] }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_with_keyframes_and_global() { + reset_class_map(); + reset_file_map(); + // .css.ts file with keyframes (vanilla-extract API) + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "animations.css.ts", + r#"import { keyframes, style } from '@devup-ui/react' +export const fadeIn = keyframes({ from: { opacity: 0 }, to: { opacity: 1 } }) +export const animated = style({ animation: "fadeIn 1s ease-in" }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + + reset_class_map(); + reset_file_map(); + // .css.ts file with globalStyle (vanilla-extract API) + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "global.css.ts", + r#"import { globalStyle } from '@devup-ui/react' +globalStyle("body", { margin: 0, padding: 0 }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_create_var() { + reset_class_map(); + reset_file_map(); + // createVar - CSS variable creation + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "vars.css.ts", + r#"import { createVar, style } from '@devup-ui/react' +export const colorVar = createVar() +export const box = style({ + vars: { + [colorVar]: 'blue' + }, + color: colorVar +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + + reset_class_map(); + reset_file_map(); + // fallbackVar - CSS variable with fallback + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "fallback.css.ts", + r#"import { createVar, fallbackVar, style } from '@devup-ui/react' +export const colorVar = createVar() +export const box = style({ + color: fallbackVar(colorVar, 'red') +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_style_variants() { + reset_class_map(); + reset_file_map(); + // styleVariants - create multiple style variants + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "variants.css.ts", + r#"import { styleVariants } from '@devup-ui/react' +export const background = styleVariants({ + primary: { background: 'blue' }, + secondary: { background: 'gray' }, + danger: { background: 'red' } +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + + reset_class_map(); + reset_file_map(); + // styleVariants with base style composition + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "variants-composed.css.ts", + r#"import { style, styleVariants } from '@devup-ui/react' +const base = style({ padding: 12, borderRadius: 4 }) +export const button = styleVariants({ + primary: [base, { background: 'blue', color: 'white' }], + secondary: [base, { background: 'gray', color: 'black' }] +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_font_face() { + reset_class_map(); + reset_file_map(); + reset_file_map(); + // fontFace - define custom font + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "fonts.css.ts", + r#"import { fontFace, style } from '@devup-ui/react' +const myFont = fontFace({ + src: 'local("Comic Sans MS")' +}) +export const text = style({ + fontFamily: myFont +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + + reset_class_map(); + reset_file_map(); + // fontFace with multiple sources + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "fonts-multi.css.ts", + r#"import { fontFace, style } from '@devup-ui/react' +const roboto = fontFace({ + src: 'url("/fonts/Roboto.woff2") format("woff2")', + fontWeight: 400, + fontStyle: 'normal' +}) +export const body = style({ + fontFamily: roboto +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_theme() { + reset_class_map(); + reset_file_map(); + reset_file_map(); + // createTheme - define theme with variables + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "theme.css.ts", + r#"import { createTheme, style } from '@devup-ui/react' +export const [themeClass, vars] = createTheme({ + color: { + brand: 'blue', + text: 'black' + }, + space: { + small: '4px', + medium: '8px', + large: '16px' + } +}) +export const box = style({ + color: vars.color.text, + padding: vars.space.medium +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + + reset_class_map(); + reset_file_map(); + reset_file_map(); + // createThemeContract - type-safe theme contract + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "theme-contract.css.ts", + r#"import { createThemeContract, createTheme, style } from '@devup-ui/react' +const vars = createThemeContract({ + color: { + brand: null, + text: null + } +}) +export const lightTheme = createTheme(vars, { + color: { + brand: 'blue', + text: 'black' + } +}) +export const darkTheme = createTheme(vars, { + color: { + brand: 'lightblue', + text: 'white' + } +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_layer() { + reset_class_map(); + reset_file_map(); + reset_file_map(); + // layer - CSS cascade layers + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "layers.css.ts", + r#"import { layer, style, globalStyle } from '@devup-ui/react' +export const reset = layer('reset') +export const base = layer('base') +export const components = layer('components') +globalStyle('*', { + '@layer': reset, + margin: 0, + padding: 0 +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_container() { + reset_class_map(); + reset_file_map(); + // createContainer - container queries + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "container.css.ts", + r#"import { createContainer, style } from '@devup-ui/react' +export const sidebar = createContainer() +export const sidebarContainer = style({ + containerName: sidebar, + containerType: 'inline-size' +}) +export const responsive = style({ + '@container': { + [`${sidebar} (min-width: 400px)`]: { + flexDirection: 'row' + } + } +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_global_theme() { + reset_class_map(); + reset_file_map(); + // createGlobalTheme - global theme variables on :root + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "global-theme.css.ts", + r#"import { createGlobalTheme } from '@devup-ui/react' +export const vars = createGlobalTheme(':root', { + color: { + brand: 'blue', + text: 'black', + background: 'white' + }, + font: { + body: 'system-ui, sans-serif' + } +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_composition() { + reset_class_map(); + reset_file_map(); + // style composition - array of styles + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "composition.css.ts", + r#"import { style } from '@devup-ui/react' +const base = style({ + padding: 12, + borderRadius: 4 +}) +const interactive = style({ + cursor: 'pointer', + transition: 'all 0.2s' +}) +export const button = style([base, interactive, { + background: 'blue', + color: 'white' +}]) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_selectors() { + reset_class_map(); + reset_file_map(); + // complex selectors + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "selectors.css.ts", + r#"import { style } from '@devup-ui/react' +export const button = style({ + background: 'blue', + selectors: { + '&:hover': { + background: 'darkblue' + }, + '&:focus': { + outline: '2px solid blue' + }, + '&:active': { + transform: 'scale(0.98)' + }, + '&:disabled': { + opacity: 0.5, + cursor: 'not-allowed' + } + } +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + + reset_class_map(); + reset_file_map(); + // parent and sibling selectors + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "selectors-complex.css.ts", + r#"import { style } from '@devup-ui/react' +export const parent = style({ + background: 'white' +}) +export const child = style({ + selectors: { + [`${parent}:hover &`]: { + color: 'blue' + }, + '& + &': { + marginTop: 8 + } + } +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_media_queries() { + reset_class_map(); + reset_file_map(); + // @media queries + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "media.css.ts", + r#"import { style } from '@devup-ui/react' +export const responsive = style({ + display: 'block', + '@media': { + 'screen and (min-width: 768px)': { + display: 'flex' + }, + 'screen and (min-width: 1024px)': { + display: 'grid' + }, + '(prefers-color-scheme: dark)': { + background: 'black', + color: 'white' + } + } +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_supports() { + reset_class_map(); + reset_file_map(); + // @supports queries + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "supports.css.ts", + r#"import { style } from '@devup-ui/react' +export const grid = style({ + display: 'flex', + '@supports': { + '(display: grid)': { + display: 'grid' + } + } +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + // END VANILLA-EXTRACT API TESTS + + #[rstest] + #[case("test.tsx", "const x = 1;", "@devup-ui/react", false)] // no package string + #[case( + "test.invalid", + "import { Box } from '@devup-ui/react';", + "@devup-ui/react", + false + )] // invalid extension + #[case( + "test.tsx", + "import { Box } from '@devup-ui/react';", + "@devup-ui/react", + true + )] // named import + #[case( + "test.tsx", + "// import from @devup-ui/react\nconst x = 1;", + "@devup-ui/react", + false + )] // in comment + #[case( + "test.tsx", + "import { Box } from '@devup-ui/core';", + "@devup-ui/react", + false + )] // different package + #[case( + "test.tsx", + "import Box from '@devup-ui/react';", + "@devup-ui/react", + true + )] // default import + #[case( + "test.tsx", + "import * as DevupUI from '@devup-ui/react';", + "@devup-ui/react", + true + )] // namespace import + #[case( + "test.tsx", + "import React from 'react';\nimport { Box } from '@devup-ui/react';", + "@devup-ui/react", + true + )] // multiple imports + #[case("test.tsx", "const pkg = '@devup-ui/react';", "@devup-ui/react", false)] // string literal + #[case( + "test.js", + "import { Box } from '@devup-ui/react';", + "@devup-ui/react", + true + )] // .js + #[case( + "test.ts", + "import { Box } from '@devup-ui/react';", + "@devup-ui/react", + true + )] // .ts + #[case( + "test.jsx", + "import { Box } from '@devup-ui/react';", + "@devup-ui/react", + true + )] // .jsx + #[case( + "test.unknown", + "import { Box } from '@devup-ui/react';", + "@devup-ui/react", + false + )] // unsupported file extension + #[case( + "styles.css.ts", + "import { css } from '@devup-ui/react';", + "@devup-ui/react", + true + )] // .css.ts (devup-ui style) + #[case( + "styles.css.js", + "import { css } from '@devup-ui/react';", + "@devup-ui/react", + true + )] // .css.js (devup-ui style) + #[case( + "styles.css.ts", + "import { style } from '@devup-ui/react';", + "@devup-ui/react", + true + )] // .css.ts (vanilla-extract API from devup-ui) + #[case( + "styles.css.js", + "import { style } from '@devup-ui/react';", + "@devup-ui/react", + true + )] // .css.js (vanilla-extract API from devup-ui) + fn test_has_devup_ui( + #[case] filename: &str, + #[case] code: &str, + #[case] package: &str, + #[case] expected: bool, + ) { + assert_eq!(has_devup_ui(filename, code, package), expected); + } + + // ============================================================================ + // COVERAGE EDGE CASE TESTS + // ============================================================================ + + #[test] + #[serial] + fn test_container_at_rule_in_css() { + // Test @container at-rule (covers line 134 in extract_style_from_expression.rs) + reset_class_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "test.tsx", + r#"import { css } from "@devup-ui/core"; +
; +"#, + ExtractOption { + package: "@devup-ui/core".to_string(), + css_dir: "@devup-ui/core".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + + // Test with @container prefix + reset_class_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "test.tsx", + r#"import { css } from "@devup-ui/core"; +
; +"#, + ExtractOption { + package: "@devup-ui/core".to_string(), + css_dir: "@devup-ui/core".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_invalid_js_execution() { + // Test vanilla-extract file with invalid JS (covers line 107 fallback) + reset_class_map(); + reset_file_map(); + reset_file_map(); + // This should fall back to regular extraction when JS execution fails + let result = extract( + "invalid.css.ts", + r#"import { style } from '@devup-ui/react' +// Invalid JS that will cause execution to fail +export const broken = style((() => { throw new Error("fail"); })()) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new(), + }, + ); + // Should not panic, may return error or empty styles + assert!(result.is_ok() || result.is_err()); + } + + #[test] + #[serial] + fn test_vanilla_extract_empty_styles() { + // Test vanilla-extract file that produces empty styles (covers line 116) + reset_class_map(); + reset_file_map(); + reset_file_map(); + // File with no style() calls + let result = extract( + "empty.css.ts", + r#"import { style } from '@devup-ui/react' +// No actual style calls, just comments +const unused = 1; +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new(), + }, + ); + assert!(result.is_ok()); + } + + #[test] + #[serial] + fn test_vanilla_extract_constant_exports() { + // Test vanilla-extract file with constant exports (covers lines 576-577) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "constants.css.ts", + r#"import { style } from '@devup-ui/react' +export const SPACING = 8; +export const COLORS = { primary: 'blue', secondary: 'green' }; +export const box = style({ padding: SPACING }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_theme_with_vars() { + // Test createTheme with array destructuring [themeClass, vars] (covers lines 406-430) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "theme-vars.css.ts", + r#"import { createTheme } from '@devup-ui/react' +export const [lightTheme, vars] = createTheme({ + color: { + primary: 'blue', + secondary: 'green' + }, + space: { + small: '4px', + medium: '8px' + } +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_non_exported_theme() { + // Test non-exported createTheme (covers theme branches without export) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "internal-theme.css.ts", + r#"import { createTheme, style } from '@devup-ui/react' +const [internalTheme, themeVars] = createTheme({ + colors: { + bg: 'white', + text: 'black' + } +}) +export const themed = style({ + background: 'red' +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_style_composition_empty() { + // Test style with empty composition array + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "empty-comp.css.ts", + r#"import { style } from '@devup-ui/react' +export const empty = style([]) +export const withEmpty = style([{}]) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_style_variants_with_base() { + // Test styleVariants with base composition (covers lines 1165-1177) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "variants-base.css.ts", + r#"import { style, styleVariants } from '@devup-ui/react' +const base = style({ + padding: 8, + borderRadius: 4 +}) +export const sizes = styleVariants({ + small: [base, { fontSize: 12 }], + medium: [base, { fontSize: 16 }], + large: [base, { fontSize: 20 }] +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_layer_and_container() { + // Test layer() and createContainer() together (covers lines 1207-1216) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "layer-container.css.ts", + r#"import { layer, createContainer, style } from '@devup-ui/react' +export const resetLayer = layer('reset') +export const baseLayer = layer('base') +export const myContainer = createContainer() +export const containerStyle = style({ + containerName: myContainer, + containerType: 'inline-size' +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_all_imports() { + // Test file that uses css, globalCss, and keyframes together (covers lines 1049, 1052) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "all-imports.css.ts", + r#"import { style, globalStyle, keyframes, createTheme } from '@devup-ui/react' +export const [theme, vars] = createTheme({ + color: { primary: 'blue' } +}) +export const fadeIn = keyframes({ + from: { opacity: 0 }, + to: { opacity: 1 } +}) +globalStyle('body', { + margin: 0 +}) +export const box = style({ + animation: 'fadeIn 1s' +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_theme_without_vars_name() { + // Test createTheme two-arg form (covers lines 1108, 1111) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "theme-two-arg.css.ts", + r#"import { createThemeContract, createTheme } from '@devup-ui/react' +const contract = createThemeContract({ + color: { + brand: null, + text: null + } +}) +export const darkTheme = createTheme(contract, { + color: { + brand: 'white', + text: 'lightgray' + } +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_font_face_with_style() { + // Test fontFace used in style (covers fontFace placeholder replacement) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "font-usage.css.ts", + r#"import { fontFace, style } from '@devup-ui/react' +export const myFont = fontFace({ + src: 'local("Comic Sans MS")', + fontWeight: 400 +}) +export const text = style({ + fontFamily: myFont +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_vars_only() { + // Test createVar exports (covers lines 1191-1192) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "vars-only.css.ts", + r#"import { createVar, style, fallbackVar } from '@devup-ui/react' +export const colorVar = createVar() +export const sizeVar = createVar() +export const box = style({ + color: fallbackVar(colorVar, 'blue'), + fontSize: sizeVar +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_global_theme_empty_vars() { + // Test createGlobalTheme with empty vars (covers line 1142 branch) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "global-theme-empty.css.ts", + r#"import { createGlobalTheme, style } from '@devup-ui/react' +export const emptyVars = createGlobalTheme(':root', {}) +export const box = style({ padding: 8 }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_non_exported_styles() { + // Test non-exported styles mixed with exported (covers export flag branches) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "mixed-exports.css.ts", + r#"import { style, keyframes, createVar, createContainer, layer } from '@devup-ui/react' +const internalStyle = style({ padding: 4 }) +const internalKeyframe = keyframes({ from: { opacity: 0 }, to: { opacity: 1 } }) +const internalVar = createVar() +const internalContainer = createContainer() +const internalLayer = layer('internal') +export const publicStyle = style({ margin: 8 }) +"#, + ExtractOption { package: "@devup-ui/react".to_string(), css_dir: "@devup-ui/react".to_string(), single_css: true, import_main_css: false, import_aliases: HashMap::new() } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_selector_references() { + // Test styles referencing each other in selectors (covers find_selector_references) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "selector-refs.css.ts", + r#"import { style } from '@devup-ui/react' +export const parent = style({ background: 'white' }) +export const child = style({ + selectors: { + [`${parent}:hover &`]: { + color: 'blue' + } + } +}) +export const sibling = style({ + selectors: { + [`${parent} + &`]: { + marginTop: 8 + } + } +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_has_devup_ui_parser_panic() { + // Test has_devup_ui with invalid code that causes parser panic (covers line 202) + // Invalid syntax that will make the parser panic + let result = has_devup_ui( + "test.tsx", + "import {} '@devup-ui/react'; syntax error {{", + "@devup-ui/react", + ); + assert!(!result); + } + + #[test] + #[serial] + fn test_global_css_fontfaces_object_syntax() { + // Test globalCss fontFaces with object syntax (covers lines 103, 115 in extract_global_style_from_expression.rs) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "test.tsx", + r#"import { globalCss } from '@devup-ui/core' +globalCss({ + fontFaces: [ + { + fontFamily: "CustomFont", + src: "url('/fonts/custom.woff2')", + fontWeight: "400", + fontStyle: "normal" + } + ] +}) +"#, + ExtractOption { + package: "@devup-ui/core".to_string(), + css_dir: "@devup-ui/core".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + + // Test with multiple font properties to exercise disassemble_property + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "test.tsx", + r#"import { globalCss } from '@devup-ui/core' +globalCss({ + fontFaces: [ + { + fontFamily: "MultiFont", + src: "url('/fonts/multi.woff2')", + fontWeight: "bold", + fontDisplay: "swap" + }, + { + fontFamily: "AnotherFont", + src: "local('Arial')" + } + ] +}) +"#, + ExtractOption { + package: "@devup-ui/core".to_string(), + css_dir: "@devup-ui/core".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_conditional_expression_with_selector() { + // Test ConditionalExpression when name.is_none() and selector.is_some() (covers line 134) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "test.tsx", + r#"import { css } from "@devup-ui/core"; +
; +"#, + ExtractOption { + package: "@devup-ui/core".to_string(), + css_dir: "@devup-ui/core".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + + // Test nested conditional within selector + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "test.tsx", + r#"import { css } from "@devup-ui/core"; +
; +"#, + ExtractOption { + package: "@devup-ui/core".to_string(), + css_dir: "@devup-ui/core".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_non_vanilla_extract_file() { + // Test non-.css.ts file (covers line 154 - is_vanilla_extract = false path) + reset_class_map(); + reset_file_map(); + reset_file_map(); + let result = extract( + "regular.tsx", + r#"import { Box } from '@devup-ui/react' + +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new(), + }, + ); + assert!(result.is_ok()); + let output = result.unwrap(); + assert!(!output.code.is_empty()); + } + + #[test] + #[serial] + fn test_vanilla_extract_execution_fallback() { + // Test vanilla-extract file with execution error (covers line 116 fallback) + reset_class_map(); + reset_file_map(); + reset_file_map(); + // Syntax error in JS execution will trigger fallback + let result = extract( + "error.css.ts", + r#"import { style } from '@devup-ui/react' +const x = style({ padding: [[[}}} // invalid syntax +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new(), + }, + ); + // Should not panic - falls back to regular processing + assert!(result.is_ok() || result.is_err()); + } + + #[test] + #[serial] + fn test_import_alias_vanilla_extract_named() { + // Test @vanilla-extract/css named exports in regular .tsx files (NOT .css.ts) + // Note: .css.ts files use vanilla-extract's own processing which doesn't go through import aliases + reset_class_map(); + reset_file_map(); + let mut aliases = HashMap::new(); + aliases.insert( + "@vanilla-extract/css".to_string(), + ImportAlias::NamedToNamed, + ); + + // Use regular .tsx file (not .css.ts) for import alias to work + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "test.tsx", + r#"import { css } from '@vanilla-extract/css' +const buttonStyle = css({ bg: 'red', p: 4 }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: aliases + }, + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_keyframes_export() { + // Test exported keyframes (covers lines 1052, 1152-1153) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "keyframes-export.css.ts", + r#"import { keyframes, style } from '@devup-ui/react' +export const spin = keyframes({ + from: { transform: 'rotate(0deg)' }, + to: { transform: 'rotate(360deg)' } +}) +const internal = keyframes({ + '0%': { opacity: 0 }, + '100%': { opacity: 1 } +}) +export const spinner = style({ animation: spin }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_theme_vars_name_only() { + // Test createTheme with vars_name but no vars_object_json (covers line 1301) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "theme-vars-name.css.ts", + r#"import { createTheme } from '@devup-ui/react' +export const myTheme = createTheme({ + color: { primary: 'blue' } +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_style_variants_mixed() { + // Test styleVariants with mixed base and no-base (covers lines 1161-1184) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "variants-mixed.css.ts", + r#"import { style, styleVariants } from '@devup-ui/react' +const base = style({ borderRadius: 4, padding: 8 }) +export const buttons = styleVariants({ + primary: [base, { background: 'blue', color: 'white' }], + secondary: { background: 'gray', color: 'black' }, + danger: [base, { background: 'red' }] +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_global_theme_with_vars() { + // Test createGlobalTheme with CSS vars (covers lines 1142-1144) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "global-theme-vars.css.ts", + r#"import { createGlobalTheme, style } from '@devup-ui/react' +export const vars = createGlobalTheme(':root', { + color: { + primary: 'blue', + secondary: 'green' + }, + space: { + small: '4px', + large: '16px' + } +}) +export const box = style({ padding: 8 }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_font_face_empty_props() { + // Test fontFace with minimal properties (covers line 1132-1135 empty props branch) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "fontface-minimal.css.ts", + r#"import { fontFace, style } from '@devup-ui/react' +export const minimalFont = fontFace({}) +export const text = style({ fontFamily: minimalFont }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_imports_combination() { + // Test file with multiple import types (covers lines 1049, 1052 import generation) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "imports-combo.css.ts", + r#"import { style, globalStyle, keyframes, fontFace } from '@devup-ui/react' +export const fadeIn = keyframes({ from: { opacity: 0 }, to: { opacity: 1 } }) +export const myFont = fontFace({ src: 'local(Arial)' }) +globalStyle('body', { margin: 0, fontFamily: myFont }) +export const animated = style({ animation: fadeIn }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_theme_export_variations() { + // Test createTheme with different export patterns (covers lines 1103-1111) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "theme-exports.css.ts", + r#"import { createTheme, createThemeContract, style } from '@devup-ui/react' +const contract = createThemeContract({ + colors: { bg: null, text: null } +}) +export const lightTheme = createTheme(contract, { + colors: { bg: 'white', text: 'black' } +}) +const internalTheme = createTheme(contract, { + colors: { bg: 'gray', text: 'darkgray' } +}) +export const box = style({ padding: 8 }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_style_composition_multiple() { + // Test style with multiple style objects in composition array (covers lines 728-729) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "multi-comp.css.ts", + r#"import { style } from '@devup-ui/react' +const base = style({ padding: 8 }) +export const complex = style([base, { margin: 4 }, { color: 'blue' }]) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_selector_class_replacement() { + // Test selector references that need class name replacement (covers collected_styles_to_code_with_classes) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "selector-ref.css.ts", + r#"import { style } from '@devup-ui/react' +export const parent = style({ display: 'flex' }) +export const child = style({ + selectors: { + [`${parent}:hover &`]: { background: 'red' } + } +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_all_exports_combined() { + // Test file with styles, keyframes, globalStyles, themes, vars, containers, layers, fontFaces combined + // Covers multiple import generation paths and code generation + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "all-combined.css.ts", + r#"import { style, globalStyle, keyframes, createVar, createContainer, layer, fontFace, createGlobalTheme, styleVariants } from '@devup-ui/react' +export const myVar = createVar() +export const myContainer = createContainer() +export const myLayer = layer('components') +export const myFont = fontFace({ src: 'local(Arial)' }) +export const vars = createGlobalTheme(':root', { color: { primary: 'blue' } }) +export const fade = keyframes({ from: { opacity: 0 }, to: { opacity: 1 } }) +globalStyle('body', { margin: 0 }) +const base = style({ padding: 8 }) +export const buttons = styleVariants({ + primary: [base, { bg: 'blue' }], + secondary: { bg: 'gray' } +}) +export const box = style({ fontFamily: myFont }) +"#, + ExtractOption { package: "@devup-ui/react".to_string(), css_dir: "@devup-ui/react".to_string(), single_css: true, import_main_css: false, import_aliases: HashMap::new() } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_theme_array_destructure() { + // Test createTheme with array destructuring [themeClass, vars] (covers lines 384, 386-387) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "theme-array.css.ts", + r#"import { createTheme, style } from '@devup-ui/react' +export const [themeClass, themeVars] = createTheme({ + colors: { primary: 'blue', secondary: 'green' }, + spacing: { small: '4px', medium: '8px' } +}) +export const themed = style({ color: themeVars.colors.primary }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_font_face_placeholder() { + // Test fontFace placeholder remapping (covers lines 503-505) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "fontface-remap.css.ts", + r#"import { fontFace, style } from '@devup-ui/react' +export const customFont = fontFace({ + src: 'url("/fonts/custom.woff2")', + fontWeight: '400', + fontDisplay: 'swap' +}) +export const secondFont = fontFace({ + src: 'local("Helvetica")' +}) +export const text = style({ fontFamily: customFont }) +export const heading = style({ fontFamily: secondFont }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_global_theme_placeholder() { + // Test createGlobalTheme placeholder remapping (covers global theme paths) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "globaltheme-remap.css.ts", + r#"import { createGlobalTheme, style } from '@devup-ui/react' +export const lightVars = createGlobalTheme(':root', { + colors: { bg: 'white', text: 'black' } +}) +export const darkVars = createGlobalTheme('.dark', { + colors: { bg: 'black', text: 'white' } +}) +export const box = style({ padding: 8 }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_global_css_with_layer_in_selector() { + // Test globalCss with @layer inside selector object (covers lines 103, 115 in extract_global_style_from_expression.rs) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "test.tsx", + r#"import { globalCss } from '@devup-ui/core' +globalCss({ + ".button": { + "@layer": "components", + padding: "8px", + background: "blue" + } +}) +"#, + ExtractOption { + package: "@devup-ui/core".to_string(), + css_dir: "@devup-ui/core".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + + // Test with multiple selectors having @layer + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "test.tsx", + r#"import { globalCss } from '@devup-ui/core' +globalCss({ + ".card": { + "@layer": "layout", + display: "flex" + }, + ".text": { + "@layer": "typography", + fontSize: "16px" + } +}) +"#, + ExtractOption { + package: "@devup-ui/core".to_string(), + css_dir: "@devup-ui/core".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_css_container_at_rule_with_selector() { + // Test @container at-rule within selector context (covers line 134) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "test.tsx", + r#"import { css } from "@devup-ui/core"; +
; +"#, + ExtractOption { + package: "@devup-ui/core".to_string(), + css_dir: "@devup-ui/core".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_selector_refs_triggers_with_classes() { + // Test that triggers collected_styles_to_code_with_classes path (selector references) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "refs.css.ts", + r#"import { style, globalStyle, keyframes, createVar, fontFace, createContainer, layer } from '@devup-ui/react' +export const colorVar = createVar() +export const myContainer = createContainer() +export const myLayer = layer('ui') +export const myFont = fontFace({ src: 'local(Arial)' }) +export const fade = keyframes({ from: { opacity: 0 }, to: { opacity: 1 } }) +export const parent = style({ display: 'flex' }) +export const child = style({ + selectors: { + [`${parent}:hover &`]: { color: 'red' } + } +}) +globalStyle('body', { margin: 0 }) +"#, + ExtractOption { package: "@devup-ui/react".to_string(), css_dir: "@devup-ui/react".to_string(), single_css: true, import_main_css: false, import_aliases: HashMap::new() } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_theme_without_vars_json() { + // Test createTheme that has vars_name but might not have vars_object_json (covers line 1111) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "theme-simple.css.ts", + r#"import { createThemeContract, createTheme, style } from '@devup-ui/react' +const contract = createThemeContract({ + colors: { primary: null } +}) +export const lightTheme = createTheme(contract, { + colors: { primary: 'blue' } +}) +export const box = style({ padding: 8 }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_global_css_layer_property_extraction() { + // Test globalCss with @layer property to trigger lines 103, 115 in extract_global_style_from_expression.rs + // The @layer property should be extracted and then filtered out, with layer set on remaining styles + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "test.tsx", + r#"import { globalCss } from '@devup-ui/core' +globalCss({ + ".reset-box": { + "@layer": "reset", + margin: 0, + padding: 0, + boxSizing: "border-box" + } +}) +"#, + ExtractOption { + package: "@devup-ui/core".to_string(), + css_dir: "@devup-ui/core".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_selector_refs_with_global_theme() { + // Test that triggers append_non_style_code with global themes (covers lines 1142-1144, 1221-1222) + // Need selector references + createGlobalTheme + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "theme-refs.css.ts", + r#"import { style, createGlobalTheme } from '@devup-ui/react' +export const vars = createGlobalTheme(':root', { + colors: { primary: 'blue', secondary: 'green' } +}) +export const parent = style({ background: 'white' }) +export const child = style({ + selectors: { + [`${parent}:hover &`]: { color: 'red' } + } +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_vanilla_extract_with_at_container_selector() { + // Test @container with selector context (covers line 134 in extract_style_from_expression.rs) + reset_class_map(); + reset_file_map(); + reset_file_map(); + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "container.css.ts", + r#"import { style } from '@devup-ui/react' +export const card = style({ + containerType: 'inline-size', + '@container': { + '(min-width: 400px)': { + display: 'grid', + gridTemplateColumns: '1fr 1fr' + } + } +}) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new() + } + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_extract_class_map_from_code_parser_panic() { + // Test extract_class_map_from_code with invalid code that causes parser panic (covers line 153-154) + let mut style_names = HashSet::new(); + style_names.insert("test".to_string()); + + let result = extract_class_map_from_code( + "test.tsx", + "const {{ invalid syntax {{{{", + &ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: HashMap::new(), + }, + &style_names, + ) + .unwrap(); + + assert!(result.is_empty()); + } + + // === Import Alias Tests === + + #[test] + #[serial] + fn test_import_alias_emotion_styled() { + // Test @emotion/styled default export → styled named export + // Uses devup-ui's styled syntax: styled.button({ ... }) or styled("button")({ ... }) + reset_class_map(); + reset_file_map(); + let mut aliases = HashMap::new(); + aliases.insert( + "@emotion/styled".to_string(), + ImportAlias::DefaultToNamed("styled".to_string()), + ); + + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "test.tsx", + r#"import styled from '@emotion/styled' +const Button = styled.button({ bg: 'red', p: 4 }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: aliases + }, + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_import_alias_styled_components() { + // Test styled-components default export → styled named export + reset_class_map(); + reset_file_map(); + let mut aliases = HashMap::new(); + aliases.insert( + "styled-components".to_string(), + ImportAlias::DefaultToNamed("styled".to_string()), + ); + + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "test.tsx", + r#"import styled from 'styled-components' +const Card = styled("div")({ bg: 'blue', m: 2 }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: aliases + }, + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_import_alias_skip_when_package_not_in_code() { + // Test that extraction is skipped when neither package nor aliases are present + reset_class_map(); + reset_file_map(); + let mut aliases = HashMap::new(); + aliases.insert( + "@emotion/styled".to_string(), + ImportAlias::DefaultToNamed("styled".to_string()), + ); + + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "test.tsx", + r#"import React from 'react' +const element =
Hello
"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: aliases + }, + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_import_alias_renamed_import() { + // Test aliased import that's renamed locally: import myStyled from '@emotion/styled' + reset_class_map(); + reset_file_map(); + let mut aliases = HashMap::new(); + aliases.insert( + "@emotion/styled".to_string(), + ImportAlias::DefaultToNamed("styled".to_string()), + ); + + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "test.tsx", + r#"import myStyled from '@emotion/styled' +const Button = myStyled.button({ bg: 'green', p: 2 }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: aliases + }, + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_import_alias_custom_named_export() { + // Test @emotion/styled default export → custom named export (emotionStyled, not styled) + // This tests when user configures alias to map to a non-standard named export + reset_class_map(); + reset_file_map(); + let mut aliases = HashMap::new(); + aliases.insert( + "@emotion/styled".to_string(), + ImportAlias::DefaultToNamed("styled".to_string()), + ); + + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "test.tsx", + r#"import emotionStyled from '@emotion/styled' +const Button = emotionStyled.button({ bg: 'purple', p: 3 }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: aliases + }, + ) + .unwrap() + )); + } + + #[test] + #[serial] + fn test_import_alias_multiple_aliases() { + // Test with multiple aliases configured + reset_class_map(); + reset_file_map(); + let mut aliases = HashMap::new(); + aliases.insert( + "@emotion/styled".to_string(), + ImportAlias::DefaultToNamed("styled".to_string()), + ); + aliases.insert( + "styled-components".to_string(), + ImportAlias::DefaultToNamed("styled".to_string()), + ); + aliases.insert( + "@vanilla-extract/css".to_string(), + ImportAlias::NamedToNamed, + ); + + // Test with @emotion/styled member syntax + assert_debug_snapshot!(ToBTreeSet::from( + extract( + "test.tsx", + r#"import styled from '@emotion/styled' +const Button = styled.button({ bg: 'red' }) +"#, + ExtractOption { + package: "@devup-ui/react".to_string(), + css_dir: "@devup-ui/react".to_string(), + single_css: true, + import_main_css: false, + import_aliases: aliases + }, + ) + .unwrap() + )); } } diff --git a/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__alias_in_comment_not_transformed.snap b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__alias_in_comment_not_transformed.snap new file mode 100644 index 00000000..c2831862 --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__alias_in_comment_not_transformed.snap @@ -0,0 +1,6 @@ +--- +source: libs/extractor/src/import_alias_visit.rs +expression: "transform_import_aliases(r#\"// This uses @emotion/styled but doesn't import it\nconst x = 1;\"#,\n\"test.tsx\", \"@devup-ui/react\", &emotion_alias())" +--- +// This uses @emotion/styled but doesn't import it +const x = 1; diff --git a/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__css_ts_file_vanilla_extract.snap b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__css_ts_file_vanilla_extract.snap new file mode 100644 index 00000000..bda0523b --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__css_ts_file_vanilla_extract.snap @@ -0,0 +1,6 @@ +--- +source: libs/extractor/src/import_alias_visit.rs +expression: "transform_import_aliases(r#\"import { style } from '@vanilla-extract/css'\nexport const container = style({ background: 'red' })\"#,\n\"styles.css.ts\", \"@devup-ui/react\", &vanilla_extract_alias())" +--- +import { style } from '@devup-ui/react'; +export const container = style({ background: 'red' }) diff --git a/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__default_to_named_different_name.snap b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__default_to_named_different_name.snap new file mode 100644 index 00000000..9acbadc5 --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__default_to_named_different_name.snap @@ -0,0 +1,5 @@ +--- +source: libs/extractor/src/import_alias_visit.rs +expression: "transform_import_aliases(r#\"import styledA from '@emotion/styled'\"#,\n\"test.tsx\", \"@devup-ui/react\", &emotion_alias())" +--- +import { styled as styledA } from '@devup-ui/react'; diff --git a/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__default_to_named_namespace_import.snap b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__default_to_named_namespace_import.snap new file mode 100644 index 00000000..bafcafe1 --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__default_to_named_namespace_import.snap @@ -0,0 +1,5 @@ +--- +source: libs/extractor/src/import_alias_visit.rs +expression: "transform_import_aliases(r#\"import * as Emotion from '@emotion/styled'\"#,\n\"test.tsx\", \"@devup-ui/react\", &emotion_alias())" +--- +import * as Emotion from '@devup-ui/react'; diff --git a/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__default_to_named_same_name.snap b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__default_to_named_same_name.snap new file mode 100644 index 00000000..d70f1f03 --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__default_to_named_same_name.snap @@ -0,0 +1,5 @@ +--- +source: libs/extractor/src/import_alias_visit.rs +expression: "transform_import_aliases(r#\"import styled from '@emotion/styled'\"#,\n\"test.tsx\", \"@devup-ui/react\", &emotion_alias())" +--- +import { styled } from '@devup-ui/react'; diff --git a/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__default_to_named_with_additional_named_imports.snap b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__default_to_named_with_additional_named_imports.snap new file mode 100644 index 00000000..297ac075 --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__default_to_named_with_additional_named_imports.snap @@ -0,0 +1,5 @@ +--- +source: libs/extractor/src/import_alias_visit.rs +expression: "transform_import_aliases(r#\"import styled, { css, keyframes } from '@emotion/styled'\"#,\n\"test.tsx\", \"@devup-ui/react\", &emotion_alias())" +--- +import { styled, css, keyframes } from '@devup-ui/react'; diff --git a/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__default_to_named_with_aliased_named_import.snap b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__default_to_named_with_aliased_named_import.snap new file mode 100644 index 00000000..0af7d1a0 --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__default_to_named_with_aliased_named_import.snap @@ -0,0 +1,5 @@ +--- +source: libs/extractor/src/import_alias_visit.rs +expression: "transform_import_aliases(r#\"import styled, { css as emotionCss } from '@emotion/styled'\"#,\n\"test.tsx\", \"@devup-ui/react\", &emotion_alias())" +--- +import { styled, css as emotionCss } from '@devup-ui/react'; diff --git a/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__empty_aliases.snap b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__empty_aliases.snap new file mode 100644 index 00000000..ce0d7512 --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__empty_aliases.snap @@ -0,0 +1,5 @@ +--- +source: libs/extractor/src/import_alias_visit.rs +expression: "transform_import_aliases(r#\"import styled from '@emotion/styled'\"#,\n\"test.tsx\", \"@devup-ui/react\", &HashMap::new())" +--- +import styled from '@emotion/styled' diff --git a/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__multiple_imports_same_file.snap b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__multiple_imports_same_file.snap new file mode 100644 index 00000000..50c8089b --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__multiple_imports_same_file.snap @@ -0,0 +1,7 @@ +--- +source: libs/extractor/src/import_alias_visit.rs +expression: "transform_import_aliases(r#\"import styled from '@emotion/styled'\nimport { style } from '@vanilla-extract/css'\nimport { useState } from 'react'\"#,\n\"test.tsx\", \"@devup-ui/react\", &combined_aliases())" +--- +import { styled } from '@devup-ui/react'; +import { style } from '@devup-ui/react'; +import { useState } from 'react' diff --git a/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__named_import_with_alias.snap b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__named_import_with_alias.snap new file mode 100644 index 00000000..b63d81ab --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__named_import_with_alias.snap @@ -0,0 +1,5 @@ +--- +source: libs/extractor/src/import_alias_visit.rs +expression: "transform_import_aliases(r#\"import { style as myStyle } from '@vanilla-extract/css'\"#,\n\"test.tsx\", \"@devup-ui/react\", &vanilla_extract_alias())" +--- +import { style as myStyle } from '@devup-ui/react'; diff --git a/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__named_to_named.snap b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__named_to_named.snap new file mode 100644 index 00000000..26d93eaf --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__named_to_named.snap @@ -0,0 +1,5 @@ +--- +source: libs/extractor/src/import_alias_visit.rs +expression: "transform_import_aliases(r#\"import { style, globalStyle } from '@vanilla-extract/css'\"#,\n\"test.tsx\", \"@devup-ui/react\", &vanilla_extract_alias())" +--- +import { style, globalStyle } from '@devup-ui/react'; diff --git a/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__named_to_named_namespace_import.snap b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__named_to_named_namespace_import.snap new file mode 100644 index 00000000..52120f70 --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__named_to_named_namespace_import.snap @@ -0,0 +1,5 @@ +--- +source: libs/extractor/src/import_alias_visit.rs +expression: "transform_import_aliases(r#\"import * as VE from '@vanilla-extract/css'\"#,\n\"test.tsx\", \"@devup-ui/react\", &vanilla_extract_alias())" +--- +import * as VE from '@devup-ui/react'; diff --git a/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__named_to_named_with_default_specifier.snap b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__named_to_named_with_default_specifier.snap new file mode 100644 index 00000000..4491be92 --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__named_to_named_with_default_specifier.snap @@ -0,0 +1,5 @@ +--- +source: libs/extractor/src/import_alias_visit.rs +expression: "transform_import_aliases(r#\"import vanillaDefault, { style } from '@vanilla-extract/css'\"#,\n\"test.tsx\", \"@devup-ui/react\", &vanilla_extract_alias())" +--- +import { default as vanillaDefault, style } from '@devup-ui/react'; diff --git a/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__no_matching_alias.snap b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__no_matching_alias.snap new file mode 100644 index 00000000..3fb23269 --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__no_matching_alias.snap @@ -0,0 +1,5 @@ +--- +source: libs/extractor/src/import_alias_visit.rs +expression: "transform_import_aliases(r#\"import { useState } from 'react'\"#, \"test.tsx\",\n\"@devup-ui/react\", &emotion_alias())" +--- +import { useState } from 'react' diff --git a/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__preserves_code_after_import.snap b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__preserves_code_after_import.snap new file mode 100644 index 00000000..d61c4531 --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__preserves_code_after_import.snap @@ -0,0 +1,10 @@ +--- +source: libs/extractor/src/import_alias_visit.rs +expression: "transform_import_aliases(r#\"import { style } from '@vanilla-extract/css'\n\nexport const button = style({\n background: 'blue',\n padding: '8px',\n});\"#,\n\"test.css.ts\", \"@devup-ui/react\", &vanilla_extract_alias())" +--- +import { style } from '@devup-ui/react'; + +export const button = style({ + background: 'blue', + padding: '8px', +}); diff --git a/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__side_effect_import_no_specifiers.snap b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__side_effect_import_no_specifiers.snap new file mode 100644 index 00000000..1302f578 --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__side_effect_import_no_specifiers.snap @@ -0,0 +1,5 @@ +--- +source: libs/extractor/src/import_alias_visit.rs +expression: "transform_import_aliases(r#\"import '@emotion/styled'\"#, \"test.tsx\",\n\"@devup-ui/react\", &emotion_alias())" +--- +import '@devup-ui/react'; diff --git a/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__styled_components.snap b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__styled_components.snap new file mode 100644 index 00000000..5effdcb6 --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__import_alias_visit__tests__styled_components.snap @@ -0,0 +1,5 @@ +--- +source: libs/extractor/src/import_alias_visit.rs +expression: "transform_import_aliases(r#\"import styled from 'styled-components'\"#,\n\"test.tsx\", \"@devup-ui/react\", &styled_components_alias())" +--- +import { styled } from '@devup-ui/react'; diff --git a/libs/extractor/src/snapshots/extractor__tests__apply_var_typography-4.snap b/libs/extractor/src/snapshots/extractor__tests__apply_var_typography-4.snap index ae0e5ff9..0ec71037 100644 --- a/libs/extractor/src/snapshots/extractor__tests__apply_var_typography-4.snap +++ b/libs/extractor/src/snapshots/extractor__tests__apply_var_typography-4.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__at_rules_at_prefix-2.snap b/libs/extractor/src/snapshots/extractor__tests__at_rules_at_prefix-2.snap index 5db8c825..64b06f5e 100644 --- a/libs/extractor/src/snapshots/extractor__tests__at_rules_at_prefix-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__at_rules_at_prefix-2.snap @@ -17,6 +17,7 @@ ToBTreeSet { }, ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__at_rules_at_prefix-3.snap b/libs/extractor/src/snapshots/extractor__tests__at_rules_at_prefix-3.snap index bf57c692..76e04e7e 100644 --- a/libs/extractor/src/snapshots/extractor__tests__at_rules_at_prefix-3.snap +++ b/libs/extractor/src/snapshots/extractor__tests__at_rules_at_prefix-3.snap @@ -17,6 +17,7 @@ ToBTreeSet { }, ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__at_rules_at_prefix.snap b/libs/extractor/src/snapshots/extractor__tests__at_rules_at_prefix.snap index e370b3c7..4955f592 100644 --- a/libs/extractor/src/snapshots/extractor__tests__at_rules_at_prefix.snap +++ b/libs/extractor/src/snapshots/extractor__tests__at_rules_at_prefix.snap @@ -17,6 +17,7 @@ ToBTreeSet { }, ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__at_rules_underscore_prefix-2.snap b/libs/extractor/src/snapshots/extractor__tests__at_rules_underscore_prefix-2.snap index d441a6a8..6838840f 100644 --- a/libs/extractor/src/snapshots/extractor__tests__at_rules_underscore_prefix-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__at_rules_underscore_prefix-2.snap @@ -17,6 +17,7 @@ ToBTreeSet { }, ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__at_rules_underscore_prefix-3.snap b/libs/extractor/src/snapshots/extractor__tests__at_rules_underscore_prefix-3.snap index c635b562..c8acba68 100644 --- a/libs/extractor/src/snapshots/extractor__tests__at_rules_underscore_prefix-3.snap +++ b/libs/extractor/src/snapshots/extractor__tests__at_rules_underscore_prefix-3.snap @@ -17,6 +17,7 @@ ToBTreeSet { }, ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__at_rules_underscore_prefix-4.snap b/libs/extractor/src/snapshots/extractor__tests__at_rules_underscore_prefix-4.snap index f5008b91..46797c5f 100644 --- a/libs/extractor/src/snapshots/extractor__tests__at_rules_underscore_prefix-4.snap +++ b/libs/extractor/src/snapshots/extractor__tests__at_rules_underscore_prefix-4.snap @@ -17,6 +17,7 @@ ToBTreeSet { }, ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__at_rules_underscore_prefix.snap b/libs/extractor/src/snapshots/extractor__tests__at_rules_underscore_prefix.snap index 9d3bb36d..24ed3c83 100644 --- a/libs/extractor/src/snapshots/extractor__tests__at_rules_underscore_prefix.snap +++ b/libs/extractor/src/snapshots/extractor__tests__at_rules_underscore_prefix.snap @@ -17,6 +17,7 @@ ToBTreeSet { }, ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__avoid_same_name_component.snap b/libs/extractor/src/snapshots/extractor__tests__avoid_same_name_component.snap index 1cdbadae..d3d2d6ac 100644 --- a/libs/extractor/src/snapshots/extractor__tests__avoid_same_name_component.snap +++ b/libs/extractor/src/snapshots/extractor__tests__avoid_same_name_component.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__backtick_prop.snap b/libs/extractor/src/snapshots/extractor__tests__backtick_prop.snap index 96d1931e..771cdc4f 100644 --- a/libs/extractor/src/snapshots/extractor__tests__backtick_prop.snap +++ b/libs/extractor/src/snapshots/extractor__tests__backtick_prop.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__component_in_func.snap b/libs/extractor/src/snapshots/extractor__tests__component_in_func.snap index 305c6df2..6ddfcacd 100644 --- a/libs/extractor/src/snapshots/extractor__tests__component_in_func.snap +++ b/libs/extractor/src/snapshots/extractor__tests__component_in_func.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -22,6 +23,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -31,6 +33,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -40,6 +43,7 @@ ToBTreeSet { level: 2, selector: None, style_order: None, + layer: None, }, ), Static( @@ -49,6 +53,7 @@ ToBTreeSet { level: 4, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__conditional_expression_with_selector-2.snap b/libs/extractor/src/snapshots/extractor__tests__conditional_expression_with_selector-2.snap new file mode 100644 index 00000000..cf22a88e --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__tests__conditional_expression_with_selector-2.snap @@ -0,0 +1,37 @@ +--- +source: libs/extractor/src/lib.rs +expression: "ToBTreeSet::from(extract(\"test.tsx\",\nr#\"import { css } from \"@devup-ui/core\";\n
;\n\"#,\nExtractOption\n{\n package: \"@devup-ui/core\".to_string(), css_dir:\n \"@devup-ui/core\".to_string(), single_css: true, import_main_css: false\n}).unwrap())" +--- +ToBTreeSet { + styles: { + Static( + ExtractStaticStyle { + property: "color", + value: "blue", + level: 0, + selector: Some( + Selector( + "&:hover", + ), + ), + style_order: None, + layer: None, + }, + ), + Static( + ExtractStaticStyle { + property: "color", + value: "red", + level: 0, + selector: Some( + Selector( + "&:hover", + ), + ), + style_order: None, + layer: None, + }, + ), + }, + code: "import \"@devup-ui/core/devup-ui.css\";\n
;\n", +} diff --git a/libs/extractor/src/snapshots/extractor__tests__conditional_expression_with_selector.snap b/libs/extractor/src/snapshots/extractor__tests__conditional_expression_with_selector.snap new file mode 100644 index 00000000..6554570b --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__tests__conditional_expression_with_selector.snap @@ -0,0 +1,37 @@ +--- +source: libs/extractor/src/lib.rs +expression: "ToBTreeSet::from(extract(\"test.tsx\",\nr#\"import { css } from \"@devup-ui/core\";\n
;\n\"#,\nExtractOption\n{\n package: \"@devup-ui/core\".to_string(), css_dir:\n \"@devup-ui/core\".to_string(), single_css: true, import_main_css: false\n}).unwrap())" +--- +ToBTreeSet { + styles: { + Static( + ExtractStaticStyle { + property: "background", + value: "blue", + level: 0, + selector: Some( + Selector( + "&:hover", + ), + ), + style_order: None, + layer: None, + }, + ), + Static( + ExtractStaticStyle { + property: "background", + value: "red", + level: 0, + selector: Some( + Selector( + "&:hover", + ), + ), + style_order: None, + layer: None, + }, + ), + }, + code: "import \"@devup-ui/core/devup-ui.css\";\n
;\n", +} diff --git a/libs/extractor/src/snapshots/extractor__tests__conditional_styles.snap b/libs/extractor/src/snapshots/extractor__tests__conditional_styles.snap index 440fdab5..61943647 100644 --- a/libs/extractor/src/snapshots/extractor__tests__conditional_styles.snap +++ b/libs/extractor/src/snapshots/extractor__tests__conditional_styles.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__conditional_with_both_branches.snap b/libs/extractor/src/snapshots/extractor__tests__conditional_with_both_branches.snap index 79c66e9d..c14bcabc 100644 --- a/libs/extractor/src/snapshots/extractor__tests__conditional_with_both_branches.snap +++ b/libs/extractor/src/snapshots/extractor__tests__conditional_with_both_branches.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -29,6 +31,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -38,6 +41,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__container_at_rule_in_css-2.snap b/libs/extractor/src/snapshots/extractor__tests__container_at_rule_in_css-2.snap new file mode 100644 index 00000000..83b4b00f --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__tests__container_at_rule_in_css-2.snap @@ -0,0 +1,25 @@ +--- +source: libs/extractor/src/lib.rs +expression: "ToBTreeSet::from(extract(\"test.tsx\",\nr#\"import { css } from \"@devup-ui/core\";\n
;\n\"#,\nExtractOption\n{\n package: \"@devup-ui/core\".to_string(), css_dir:\n \"@devup-ui/core\".to_string(), single_css: true, import_main_css: false\n}).unwrap())" +--- +ToBTreeSet { + styles: { + Static( + ExtractStaticStyle { + property: "background", + value: "blue", + level: 0, + selector: Some( + At { + kind: Container, + query: "(min-width: 500px)", + selector: None, + }, + ), + style_order: None, + layer: None, + }, + ), + }, + code: "import \"@devup-ui/core/devup-ui.css\";\n
;\n", +} diff --git a/libs/extractor/src/snapshots/extractor__tests__container_at_rule_in_css.snap b/libs/extractor/src/snapshots/extractor__tests__container_at_rule_in_css.snap new file mode 100644 index 00000000..039f02dd --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__tests__container_at_rule_in_css.snap @@ -0,0 +1,25 @@ +--- +source: libs/extractor/src/lib.rs +expression: "ToBTreeSet::from(extract(\"test.tsx\",\nr#\"import { css } from \"@devup-ui/core\";\n
;\n\"#,\nExtractOption\n{\n package: \"@devup-ui/core\".to_string(), css_dir:\n \"@devup-ui/core\".to_string(), single_css: true, import_main_css: false\n}).unwrap())" +--- +ToBTreeSet { + styles: { + Static( + ExtractStaticStyle { + property: "display", + value: "flex", + level: 0, + selector: Some( + At { + kind: Container, + query: "(min-width: 400px)", + selector: None, + }, + ), + style_order: None, + layer: None, + }, + ), + }, + code: "import \"@devup-ui/core/devup-ui.css\";\n
;\n", +} diff --git a/libs/extractor/src/snapshots/extractor__tests__convert_tag-13.snap b/libs/extractor/src/snapshots/extractor__tests__convert_tag-13.snap index 8cd8d0ca..7d756d57 100644 --- a/libs/extractor/src/snapshots/extractor__tests__convert_tag-13.snap +++ b/libs/extractor/src/snapshots/extractor__tests__convert_tag-13.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__convert_tag-14.snap b/libs/extractor/src/snapshots/extractor__tests__convert_tag-14.snap index e5af20a4..9b968790 100644 --- a/libs/extractor/src/snapshots/extractor__tests__convert_tag-14.snap +++ b/libs/extractor/src/snapshots/extractor__tests__convert_tag-14.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__convert_tag-15.snap b/libs/extractor/src/snapshots/extractor__tests__convert_tag-15.snap index 4fe436bc..225d7870 100644 --- a/libs/extractor/src/snapshots/extractor__tests__convert_tag-15.snap +++ b/libs/extractor/src/snapshots/extractor__tests__convert_tag-15.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__convert_tag-16.snap b/libs/extractor/src/snapshots/extractor__tests__convert_tag-16.snap index ddea7c49..9a9efcd8 100644 --- a/libs/extractor/src/snapshots/extractor__tests__convert_tag-16.snap +++ b/libs/extractor/src/snapshots/extractor__tests__convert_tag-16.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__convert_tag-17.snap b/libs/extractor/src/snapshots/extractor__tests__convert_tag-17.snap index 00326863..f9f24e00 100644 --- a/libs/extractor/src/snapshots/extractor__tests__convert_tag-17.snap +++ b/libs/extractor/src/snapshots/extractor__tests__convert_tag-17.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__convert_tag-18.snap b/libs/extractor/src/snapshots/extractor__tests__convert_tag-18.snap index 37729f43..acf55323 100644 --- a/libs/extractor/src/snapshots/extractor__tests__convert_tag-18.snap +++ b/libs/extractor/src/snapshots/extractor__tests__convert_tag-18.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__convert_tag-19.snap b/libs/extractor/src/snapshots/extractor__tests__convert_tag-19.snap index 37729f43..acf55323 100644 --- a/libs/extractor/src/snapshots/extractor__tests__convert_tag-19.snap +++ b/libs/extractor/src/snapshots/extractor__tests__convert_tag-19.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__convert_tag-20.snap b/libs/extractor/src/snapshots/extractor__tests__convert_tag-20.snap index 3867914d..ff7b172a 100644 --- a/libs/extractor/src/snapshots/extractor__tests__convert_tag-20.snap +++ b/libs/extractor/src/snapshots/extractor__tests__convert_tag-20.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__convert_tag-21.snap b/libs/extractor/src/snapshots/extractor__tests__convert_tag-21.snap index c6cd67af..9edff711 100644 --- a/libs/extractor/src/snapshots/extractor__tests__convert_tag-21.snap +++ b/libs/extractor/src/snapshots/extractor__tests__convert_tag-21.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__convert_tag-7.snap b/libs/extractor/src/snapshots/extractor__tests__convert_tag-7.snap index 7520a855..3b0e216d 100644 --- a/libs/extractor/src/snapshots/extractor__tests__convert_tag-7.snap +++ b/libs/extractor/src/snapshots/extractor__tests__convert_tag-7.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__css_container_at_rule_with_selector.snap b/libs/extractor/src/snapshots/extractor__tests__css_container_at_rule_with_selector.snap new file mode 100644 index 00000000..aaee6069 --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__tests__css_container_at_rule_with_selector.snap @@ -0,0 +1,35 @@ +--- +source: libs/extractor/src/lib.rs +expression: "ToBTreeSet::from(extract(\"test.tsx\",\nr#\"import { css } from \"@devup-ui/core\";\n
;\n\"#,\nExtractOption\n{\n package: \"@devup-ui/core\".to_string(), css_dir:\n \"@devup-ui/core\".to_string(), single_css: true, import_main_css: false\n}).unwrap())" +--- +ToBTreeSet { + styles: { + Static( + ExtractStaticStyle { + property: "padding", + value: "32px", + level: 0, + selector: None, + style_order: None, + layer: None, + }, + ), + Static( + ExtractStaticStyle { + property: "padding", + value: "64px", + level: 0, + selector: Some( + At { + kind: Container, + query: "(min-width: 300px)", + selector: None, + }, + ), + style_order: None, + layer: None, + }, + ), + }, + code: "import \"@devup-ui/core/devup-ui.css\";\n
;\n", +} diff --git a/libs/extractor/src/snapshots/extractor__tests__css_props_destructuring_assignment-2.snap b/libs/extractor/src/snapshots/extractor__tests__css_props_destructuring_assignment-2.snap index 3c781aaa..100fee80 100644 --- a/libs/extractor/src/snapshots/extractor__tests__css_props_destructuring_assignment-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__css_props_destructuring_assignment-2.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -29,6 +31,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -38,6 +41,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -47,6 +51,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__css_props_destructuring_assignment.snap b/libs/extractor/src/snapshots/extractor__tests__css_props_destructuring_assignment.snap index f0177b1d..0da80133 100644 --- a/libs/extractor/src/snapshots/extractor__tests__css_props_destructuring_assignment.snap +++ b/libs/extractor/src/snapshots/extractor__tests__css_props_destructuring_assignment.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -29,6 +31,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__css_variable_reassignment.snap b/libs/extractor/src/snapshots/extractor__tests__css_variable_reassignment.snap index e85717ad..f90e84c5 100644 --- a/libs/extractor/src/snapshots/extractor__tests__css_variable_reassignment.snap +++ b/libs/extractor/src/snapshots/extractor__tests__css_variable_reassignment.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__custom_selector-2.snap b/libs/extractor/src/snapshots/extractor__tests__custom_selector-2.snap index 8aa0d84f..1ca0668b 100644 --- a/libs/extractor/src/snapshots/extractor__tests__custom_selector-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__custom_selector-2.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__custom_selector-3.snap b/libs/extractor/src/snapshots/extractor__tests__custom_selector-3.snap index 6ddb9588..be5f4c7b 100644 --- a/libs/extractor/src/snapshots/extractor__tests__custom_selector-3.snap +++ b/libs/extractor/src/snapshots/extractor__tests__custom_selector-3.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__custom_selector.snap b/libs/extractor/src/snapshots/extractor__tests__custom_selector.snap index cbed4818..e6c2f8ee 100644 --- a/libs/extractor/src/snapshots/extractor__tests__custom_selector.snap +++ b/libs/extractor/src/snapshots/extractor__tests__custom_selector.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__default_import_usage.snap b/libs/extractor/src/snapshots/extractor__tests__default_import_usage.snap index 6464dcb8..2627a65b 100644 --- a/libs/extractor/src/snapshots/extractor__tests__default_import_usage.snap +++ b/libs/extractor/src/snapshots/extractor__tests__default_import_usage.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__dot_notation_theme_variables-2.snap b/libs/extractor/src/snapshots/extractor__tests__dot_notation_theme_variables-2.snap index c284a7c0..d7007b3d 100644 --- a/libs/extractor/src/snapshots/extractor__tests__dot_notation_theme_variables-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__dot_notation_theme_variables-2.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__dot_notation_theme_variables-3.snap b/libs/extractor/src/snapshots/extractor__tests__dot_notation_theme_variables-3.snap index 89adcef8..983402e9 100644 --- a/libs/extractor/src/snapshots/extractor__tests__dot_notation_theme_variables-3.snap +++ b/libs/extractor/src/snapshots/extractor__tests__dot_notation_theme_variables-3.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__dot_notation_theme_variables-4.snap b/libs/extractor/src/snapshots/extractor__tests__dot_notation_theme_variables-4.snap index 7f73c5f6..7057ea9f 100644 --- a/libs/extractor/src/snapshots/extractor__tests__dot_notation_theme_variables-4.snap +++ b/libs/extractor/src/snapshots/extractor__tests__dot_notation_theme_variables-4.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__dot_notation_theme_variables.snap b/libs/extractor/src/snapshots/extractor__tests__dot_notation_theme_variables.snap index f13e9ac6..839a9df5 100644 --- a/libs/extractor/src/snapshots/extractor__tests__dot_notation_theme_variables.snap +++ b/libs/extractor/src/snapshots/extractor__tests__dot_notation_theme_variables.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__duplicate_style_props.snap b/libs/extractor/src/snapshots/extractor__tests__duplicate_style_props.snap index 4da8801d..05f28e65 100644 --- a/libs/extractor/src/snapshots/extractor__tests__duplicate_style_props.snap +++ b/libs/extractor/src/snapshots/extractor__tests__duplicate_style_props.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__dynamic_class_name_merge.snap b/libs/extractor/src/snapshots/extractor__tests__dynamic_class_name_merge.snap index aaf38676..d3e8aa2c 100644 --- a/libs/extractor/src/snapshots/extractor__tests__dynamic_class_name_merge.snap +++ b/libs/extractor/src/snapshots/extractor__tests__dynamic_class_name_merge.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector-2.snap b/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector-2.snap index f7c7d383..6548d747 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector-2.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector-4.snap b/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector-4.snap index 0b7b4c40..41b04c59 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector-4.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector-4.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector-5.snap b/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector-5.snap index 87419994..1fa1386c 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector-5.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector-5.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector-6.snap b/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector-6.snap index 75dbf5ce..de1bd84a 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector-6.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector-6.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector-7.snap b/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector-7.snap index 4fcb372e..5f08887a 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector-7.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector-7.snap @@ -18,6 +18,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -34,6 +35,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector-8.snap b/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector-8.snap index f9e69e47..bfbccd45 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector-8.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector-8.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector.snap b/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector.snap index 67ab2c4d..dd9f0ebd 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_advenced_selector.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_class_name_from_component.snap b/libs/extractor/src/snapshots/extractor__tests__extract_class_name_from_component.snap index cb925eaf..dc007e4c 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_class_name_from_component.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_class_name_from_component.snap @@ -13,6 +13,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -24,6 +25,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -33,6 +35,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -42,6 +45,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_compound_responsive_style_props.snap b/libs/extractor/src/snapshots/extractor__tests__extract_compound_responsive_style_props.snap index f8fcf0cb..4e524f26 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_compound_responsive_style_props.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_compound_responsive_style_props.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Dynamic( diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_conditional_selector-2.snap b/libs/extractor/src/snapshots/extractor__tests__extract_conditional_selector-2.snap index c34b3156..cff4cacd 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_conditional_selector-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_conditional_selector-2.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_conditional_selector-4.snap b/libs/extractor/src/snapshots/extractor__tests__extract_conditional_selector-4.snap index 72d5041a..9d3e7868 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_conditional_selector-4.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_conditional_selector-4.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -41,6 +43,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -54,6 +57,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_conditional_selector.snap b/libs/extractor/src/snapshots/extractor__tests__extract_conditional_selector.snap index 24d82285..f4d3f9f2 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_conditional_selector.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_conditional_selector.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_conditional_style_props-11.snap b/libs/extractor/src/snapshots/extractor__tests__extract_conditional_style_props-11.snap index 8fff99cf..72f488ec 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_conditional_style_props-11.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_conditional_style_props-11.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_conditional_style_props-3.snap b/libs/extractor/src/snapshots/extractor__tests__extract_conditional_style_props-3.snap index b9e29851..9cedfe23 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_conditional_style_props-3.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_conditional_style_props-3.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Dynamic( diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_conditional_style_props-5.snap b/libs/extractor/src/snapshots/extractor__tests__extract_conditional_style_props-5.snap index 67542fa5..bf517550 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_conditional_style_props-5.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_conditional_style_props-5.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_conditional_style_props-6.snap b/libs/extractor/src/snapshots/extractor__tests__extract_conditional_style_props-6.snap index 28ff1f25..3c4e2dad 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_conditional_style_props-6.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_conditional_style_props-6.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_conditional_style_props.snap b/libs/extractor/src/snapshots/extractor__tests__extract_conditional_style_props.snap index 371ba317..b96135f2 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_conditional_style_props.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_conditional_style_props.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_conditional_style_props_with_class_name-2.snap b/libs/extractor/src/snapshots/extractor__tests__extract_conditional_style_props_with_class_name-2.snap index 958f4ff0..f006fc2a 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_conditional_style_props_with_class_name-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_conditional_style_props_with_class_name-2.snap @@ -13,6 +13,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -22,6 +23,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -31,6 +33,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_dynamic_style_props_with_type-3.snap b/libs/extractor/src/snapshots/extractor__tests__extract_dynamic_style_props_with_type-3.snap index e2d5be42..369d6b4d 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_dynamic_style_props_with_type-3.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_dynamic_style_props_with_type-3.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_enum_style_property-3.snap b/libs/extractor/src/snapshots/extractor__tests__extract_enum_style_property-3.snap index 0163aca1..fb9351c1 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_enum_style_property-3.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_enum_style_property-3.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -29,6 +31,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -38,6 +41,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_enum_style_property-4.snap b/libs/extractor/src/snapshots/extractor__tests__extract_enum_style_property-4.snap index 115f3d38..b79144fe 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_enum_style_property-4.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_enum_style_property-4.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -29,6 +31,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -38,6 +41,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -47,6 +51,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_enum_style_property-5.snap b/libs/extractor/src/snapshots/extractor__tests__extract_enum_style_property-5.snap index d7790f99..f9e54cf5 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_enum_style_property-5.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_enum_style_property-5.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -29,6 +31,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -38,6 +41,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_enum_style_property-6.snap b/libs/extractor/src/snapshots/extractor__tests__extract_enum_style_property-6.snap index 8d8014e6..b03da3d7 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_enum_style_property-6.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_enum_style_property-6.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 1, selector: None, style_order: None, + layer: None, }, ), Static( @@ -29,6 +31,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -38,6 +41,7 @@ ToBTreeSet { level: 1, selector: None, style_order: None, + layer: None, }, ), Static( @@ -47,6 +51,7 @@ ToBTreeSet { level: 3, selector: None, style_order: None, + layer: None, }, ), Static( @@ -56,6 +61,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -65,6 +71,7 @@ ToBTreeSet { level: 1, selector: None, style_order: None, + layer: None, }, ), Static( @@ -74,6 +81,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -83,6 +91,7 @@ ToBTreeSet { level: 1, selector: None, style_order: None, + layer: None, }, ), Static( @@ -92,6 +101,7 @@ ToBTreeSet { level: 2, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_enum_style_property.snap b/libs/extractor/src/snapshots/extractor__tests__extract_enum_style_property.snap index d87d3470..d867c200 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_enum_style_property.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_enum_style_property.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_global_css-10.snap b/libs/extractor/src/snapshots/extractor__tests__extract_global_css-10.snap index ebd5498c..8e8e1c4a 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_global_css-10.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_global_css-10.snap @@ -18,6 +18,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -34,6 +35,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_global_css-2.snap b/libs/extractor/src/snapshots/extractor__tests__extract_global_css-2.snap index 23d8f2fa..e5416ab4 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_global_css-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_global_css-2.snap @@ -18,6 +18,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_global_css-3.snap b/libs/extractor/src/snapshots/extractor__tests__extract_global_css-3.snap index 8e389a2d..25b8ca34 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_global_css-3.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_global_css-3.snap @@ -18,6 +18,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_global_css-4.snap b/libs/extractor/src/snapshots/extractor__tests__extract_global_css-4.snap index 6ce50048..8280beb4 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_global_css-4.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_global_css-4.snap @@ -18,6 +18,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_global_css-5.snap b/libs/extractor/src/snapshots/extractor__tests__extract_global_css-5.snap index e0db4ccf..df6f4adb 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_global_css-5.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_global_css-5.snap @@ -18,6 +18,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_global_css-6.snap b/libs/extractor/src/snapshots/extractor__tests__extract_global_css-6.snap index 725f4412..6aa19651 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_global_css-6.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_global_css-6.snap @@ -18,6 +18,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_global_css-7.snap b/libs/extractor/src/snapshots/extractor__tests__extract_global_css-7.snap index 6709991b..41b49af8 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_global_css-7.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_global_css-7.snap @@ -18,6 +18,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_global_css-9.snap b/libs/extractor/src/snapshots/extractor__tests__extract_global_css-9.snap index 1736960f..706947d7 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_global_css-9.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_global_css-9.snap @@ -18,6 +18,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_global_css.snap b/libs/extractor/src/snapshots/extractor__tests__extract_global_css.snap index 59b494f9..5cfb9881 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_global_css.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_global_css.snap @@ -18,6 +18,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_global_css_with_selector-2.snap b/libs/extractor/src/snapshots/extractor__tests__extract_global_css_with_selector-2.snap index c7baa8be..d144d445 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_global_css_with_selector-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_global_css_with_selector-2.snap @@ -18,6 +18,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -34,6 +35,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -50,6 +52,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -66,6 +69,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -82,6 +86,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -98,6 +103,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -114,6 +120,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -130,6 +137,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_global_css_with_selector-3.snap b/libs/extractor/src/snapshots/extractor__tests__extract_global_css_with_selector-3.snap index c7baa8be..d144d445 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_global_css_with_selector-3.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_global_css_with_selector-3.snap @@ -18,6 +18,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -34,6 +35,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -50,6 +52,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -66,6 +69,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -82,6 +86,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -98,6 +103,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -114,6 +120,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -130,6 +137,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_global_css_with_selector-4.snap b/libs/extractor/src/snapshots/extractor__tests__extract_global_css_with_selector-4.snap index f5474711..3a8cdf0f 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_global_css_with_selector-4.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_global_css_with_selector-4.snap @@ -18,6 +18,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -34,6 +35,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -50,6 +52,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -66,6 +69,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -82,6 +86,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -98,6 +103,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -114,6 +120,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -130,6 +137,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -146,6 +154,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -162,6 +171,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -178,6 +188,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -194,6 +205,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_global_css_with_selector.snap b/libs/extractor/src/snapshots/extractor__tests__extract_global_css_with_selector.snap index 56b25aee..ef647ac3 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_global_css_with_selector.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_global_css_with_selector.snap @@ -18,6 +18,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -34,6 +35,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -50,6 +52,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -66,6 +69,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_global_css_with_template_literal.snap b/libs/extractor/src/snapshots/extractor__tests__extract_global_css_with_template_literal.snap index 6f24c0eb..2914629a 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_global_css_with_template_literal.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_global_css_with_template_literal.snap @@ -18,6 +18,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_just_tsx_in_multiple_files-2.snap b/libs/extractor/src/snapshots/extractor__tests__extract_just_tsx_in_multiple_files-2.snap index e316a3f8..9a5a36f3 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_just_tsx_in_multiple_files-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_just_tsx_in_multiple_files-2.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_just_tsx_in_multiple_files-3.snap b/libs/extractor/src/snapshots/extractor__tests__extract_just_tsx_in_multiple_files-3.snap index bc3c3ce7..0ae4ab4e 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_just_tsx_in_multiple_files-3.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_just_tsx_in_multiple_files-3.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_just_tsx_in_multiple_files-4.snap b/libs/extractor/src/snapshots/extractor__tests__extract_just_tsx_in_multiple_files-4.snap index 95377a9c..92fd3e0b 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_just_tsx_in_multiple_files-4.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_just_tsx_in_multiple_files-4.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_just_tsx_in_multiple_files.snap b/libs/extractor/src/snapshots/extractor__tests__extract_just_tsx_in_multiple_files.snap index 34220c2d..2f6abfc9 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_just_tsx_in_multiple_files.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_just_tsx_in_multiple_files.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-10.snap b/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-10.snap index f0e001d8..b33ab78d 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-10.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-10.snap @@ -14,6 +14,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ExtractStaticStyle { property: "opacity", @@ -21,6 +22,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "100%": [ @@ -30,6 +32,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "50%": [ @@ -39,6 +42,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-2.snap b/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-2.snap index 4a47d23a..e8eb2daa 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-2.snap @@ -14,6 +14,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "100%": [ @@ -23,6 +24,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "50%": [ @@ -32,6 +34,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-3.snap b/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-3.snap index b6aa7943..72a334d6 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-3.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-3.snap @@ -14,6 +14,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "100%": [ @@ -23,6 +24,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "50%": [ @@ -32,6 +34,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-4.snap b/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-4.snap index 29260a59..d95079a7 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-4.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-4.snap @@ -14,6 +14,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "100%": [ @@ -23,6 +24,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "50%": [ @@ -32,6 +34,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-5.snap b/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-5.snap index 02ef511e..8d60a224 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-5.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-5.snap @@ -14,6 +14,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "100%": [ @@ -23,6 +24,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "50%": [ @@ -32,6 +34,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-6.snap b/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-6.snap index 5a4853f3..5e898208 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-6.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-6.snap @@ -14,6 +14,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "100%": [ @@ -23,6 +24,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "50%": [ @@ -32,6 +34,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-7.snap b/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-7.snap index cafaf847..32d9bdd1 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-7.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-7.snap @@ -14,6 +14,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "100%": [ @@ -23,6 +24,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "50%": [ @@ -32,6 +34,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-8.snap b/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-8.snap index 276a0983..653f251b 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-8.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-8.snap @@ -14,6 +14,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "100%": [ @@ -23,6 +24,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "50%": [ @@ -32,6 +34,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-9.snap b/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-9.snap index 214bf046..c838cd6e 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-9.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_keyframs-9.snap @@ -14,6 +14,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "100%": [ @@ -23,6 +24,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "50%": [ @@ -32,6 +34,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], }, @@ -47,6 +50,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "100%": [ @@ -56,6 +60,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "50%": [ @@ -65,6 +70,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], }, @@ -80,6 +86,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "100%": [ @@ -89,6 +96,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "50%": [ @@ -98,6 +106,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_keyframs.snap b/libs/extractor/src/snapshots/extractor__tests__extract_keyframs.snap index 2084f266..7c50ae17 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_keyframs.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_keyframs.snap @@ -14,6 +14,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "to": [ @@ -23,6 +24,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_keyframs_literal-2.snap b/libs/extractor/src/snapshots/extractor__tests__extract_keyframs_literal-2.snap index 0a7f6684..2c8d9f24 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_keyframs_literal-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_keyframs_literal-2.snap @@ -14,6 +14,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ExtractStaticStyle { property: "color", @@ -21,6 +22,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "100%": [ @@ -30,6 +32,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ExtractStaticStyle { property: "color", @@ -37,6 +40,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_keyframs_literal.snap b/libs/extractor/src/snapshots/extractor__tests__extract_keyframs_literal.snap index 5d739fa7..a2a2d621 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_keyframs_literal.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_keyframs_literal.snap @@ -14,6 +14,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "to": [ @@ -23,6 +24,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_logical_case-2.snap b/libs/extractor/src/snapshots/extractor__tests__extract_logical_case-2.snap index 9a2a2006..4a599dc1 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_logical_case-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_logical_case-2.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_logical_case-3.snap b/libs/extractor/src/snapshots/extractor__tests__extract_logical_case-3.snap index 1e2ed115..a5abd435 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_logical_case-3.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_logical_case-3.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Dynamic( diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_logical_case-4.snap b/libs/extractor/src/snapshots/extractor__tests__extract_logical_case-4.snap index f374e006..95cdf98b 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_logical_case-4.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_logical_case-4.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_logical_case.snap b/libs/extractor/src/snapshots/extractor__tests__extract_logical_case.snap index fce00360..94afa099 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_logical_case.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_logical_case.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-10.snap b/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-10.snap index 7c4889a1..bd104643 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-10.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-10.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-11.snap b/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-11.snap index b1780baf..f7f49ffb 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-11.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-11.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-2.snap b/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-2.snap index 5d2604ef..a20ec2d4 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-2.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-3.snap b/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-3.snap index 49754ace..8136c041 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-3.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-3.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -41,6 +43,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-4.snap b/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-4.snap index fa91e018..fcdc5830 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-4.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-4.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-5.snap b/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-5.snap index bff3c03a..fca96046 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-5.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-5.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-6.snap b/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-6.snap index bb0e71ea..138a6bdf 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-6.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-6.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-7.snap b/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-7.snap index d1b31650..185888bd 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-7.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-7.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-8.snap b/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-8.snap index 555f570e..e146baaa 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-8.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-8.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-9.snap b/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-9.snap index a60e8df3..fec667f1 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-9.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector-9.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector.snap b/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector.snap index 4beda642..1cadb3a6 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_nested_selector.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-2.snap b/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-2.snap index c047f7a1..70fc747f 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-2.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 1, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 1, selector: None, style_order: None, + layer: None, }, ), Static( @@ -29,6 +31,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-3.snap b/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-3.snap index efee8272..b2175a51 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-3.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-3.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 3, selector: None, style_order: None, + layer: None, }, ), Dynamic( diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-4.snap b/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-4.snap index 5aadc27d..a78b6264 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-4.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-4.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 3, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 3, selector: None, style_order: None, + layer: None, }, ), Dynamic( diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-5.snap b/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-5.snap index 9ff2972a..042b3502 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-5.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-5.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 3, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 3, selector: None, style_order: None, + layer: None, }, ), Dynamic( diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-6.snap b/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-6.snap index 035786b3..b3c17038 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-6.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-6.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 1, selector: None, style_order: None, + layer: None, }, ), Static( @@ -29,6 +31,7 @@ ToBTreeSet { level: 3, selector: None, style_order: None, + layer: None, }, ), Static( @@ -38,6 +41,7 @@ ToBTreeSet { level: 2, selector: None, style_order: None, + layer: None, }, ), Static( @@ -47,6 +51,7 @@ ToBTreeSet { level: 3, selector: None, style_order: None, + layer: None, }, ), Dynamic( diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-7.snap b/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-7.snap index 106fdf04..8cafaa99 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-7.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-7.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 1, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-8.snap b/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-8.snap index e57263ab..a241846d 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-8.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props-8.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 1, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 2, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props.snap b/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props.snap index 03406fb9..079cd1c6 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 1, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 1, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props_with_class_name-2.snap b/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props_with_class_name-2.snap index f6967f43..079b55f0 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props_with_class_name-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props_with_class_name-2.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 1, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props_with_class_name.snap b/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props_with_class_name.snap index 0adb6bdf..c9197f7d 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props_with_class_name.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_responsive_conditional_style_props_with_class_name.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 1, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 1, selector: None, style_order: None, + layer: None, }, ), Static( @@ -29,6 +31,7 @@ ToBTreeSet { level: 1, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_responsive_style_props-2.snap b/libs/extractor/src/snapshots/extractor__tests__extract_responsive_style_props-2.snap index 17ce9ef5..6b76b1e6 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_responsive_style_props-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_responsive_style_props-2.snap @@ -13,6 +13,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -22,6 +23,7 @@ ToBTreeSet { level: 2, selector: None, style_order: None, + layer: None, }, ), Static( @@ -31,6 +33,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_responsive_style_props.snap b/libs/extractor/src/snapshots/extractor__tests__extract_responsive_style_props.snap index f0c610af..495f7e57 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_responsive_style_props.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_responsive_style_props.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 2, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -29,6 +31,7 @@ ToBTreeSet { level: 1, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_same_value_conditional_style_props-2.snap b/libs/extractor/src/snapshots/extractor__tests__extract_same_value_conditional_style_props-2.snap index 4f808466..5fbaf22c 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_same_value_conditional_style_props-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_same_value_conditional_style_props-2.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_same_value_conditional_style_props-3.snap b/libs/extractor/src/snapshots/extractor__tests__extract_same_value_conditional_style_props-3.snap index 156d663f..b790de3a 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_same_value_conditional_style_props-3.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_same_value_conditional_style_props-3.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_same_value_conditional_style_props-4.snap b/libs/extractor/src/snapshots/extractor__tests__extract_same_value_conditional_style_props-4.snap index 0385bb4c..681d43ce 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_same_value_conditional_style_props-4.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_same_value_conditional_style_props-4.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_same_value_conditional_style_props-5.snap b/libs/extractor/src/snapshots/extractor__tests__extract_same_value_conditional_style_props-5.snap index 5c2ece76..85fd49fb 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_same_value_conditional_style_props-5.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_same_value_conditional_style_props-5.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_same_value_conditional_style_props-6.snap b/libs/extractor/src/snapshots/extractor__tests__extract_same_value_conditional_style_props-6.snap index 9c8dba14..7c6784b9 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_same_value_conditional_style_props-6.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_same_value_conditional_style_props-6.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_same_value_conditional_style_props.snap b/libs/extractor/src/snapshots/extractor__tests__extract_same_value_conditional_style_props.snap index 4875c22c..860d92b0 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_same_value_conditional_style_props.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_same_value_conditional_style_props.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_selector-10.snap b/libs/extractor/src/snapshots/extractor__tests__extract_selector-10.snap index 9d73a6cc..62e4318a 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_selector-10.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_selector-10.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_selector-11.snap b/libs/extractor/src/snapshots/extractor__tests__extract_selector-11.snap index 79249216..3121b0c0 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_selector-11.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_selector-11.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_selector-12.snap b/libs/extractor/src/snapshots/extractor__tests__extract_selector-12.snap index 2cb4a6c7..0b28812f 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_selector-12.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_selector-12.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_selector-13.snap b/libs/extractor/src/snapshots/extractor__tests__extract_selector-13.snap index 67f1a251..8bb04b34 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_selector-13.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_selector-13.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_selector-14.snap b/libs/extractor/src/snapshots/extractor__tests__extract_selector-14.snap index 0cf0195f..2f76a954 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_selector-14.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_selector-14.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_selector-15.snap b/libs/extractor/src/snapshots/extractor__tests__extract_selector-15.snap index 08cbd693..5e62a982 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_selector-15.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_selector-15.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_selector-16.snap b/libs/extractor/src/snapshots/extractor__tests__extract_selector-16.snap index a0ac858a..e74c8add 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_selector-16.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_selector-16.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -41,6 +43,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -54,6 +57,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_selector-2.snap b/libs/extractor/src/snapshots/extractor__tests__extract_selector-2.snap index 767d75e1..91ed4fbf 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_selector-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_selector-2.snap @@ -13,6 +13,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -26,6 +27,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -39,6 +41,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -52,6 +55,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -63,6 +67,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -74,6 +79,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -87,6 +93,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_selector-3.snap b/libs/extractor/src/snapshots/extractor__tests__extract_selector-3.snap index 3ea380c1..f6a72f6a 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_selector-3.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_selector-3.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_selector-4.snap b/libs/extractor/src/snapshots/extractor__tests__extract_selector-4.snap index f54f5ca5..5bdb655f 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_selector-4.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_selector-4.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_selector-5.snap b/libs/extractor/src/snapshots/extractor__tests__extract_selector-5.snap index caf4e049..7a1b9683 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_selector-5.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_selector-5.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_selector-6.snap b/libs/extractor/src/snapshots/extractor__tests__extract_selector-6.snap index 2a1fea5d..2b6887ae 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_selector-6.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_selector-6.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -41,6 +43,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -54,6 +57,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_selector-7.snap b/libs/extractor/src/snapshots/extractor__tests__extract_selector-7.snap index a15840aa..255b76d8 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_selector-7.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_selector-7.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -41,6 +43,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -54,6 +57,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_selector-8.snap b/libs/extractor/src/snapshots/extractor__tests__extract_selector-8.snap index fb8a1974..b84465ed 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_selector-8.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_selector-8.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_selector-9.snap b/libs/extractor/src/snapshots/extractor__tests__extract_selector-9.snap index 4ad742bb..80905f7a 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_selector-9.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_selector-9.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -41,6 +43,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -54,6 +57,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -67,6 +71,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -80,6 +85,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_selector.snap b/libs/extractor/src/snapshots/extractor__tests__extract_selector.snap index 134b2160..1dec81e3 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_selector.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_selector.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_selector_with_literal-2.snap b/libs/extractor/src/snapshots/extractor__tests__extract_selector_with_literal-2.snap index 7b92cd58..be8db47a 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_selector_with_literal-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_selector_with_literal-2.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_selector_with_literal.snap b/libs/extractor/src/snapshots/extractor__tests__extract_selector_with_literal.snap index 31d7ca06..bf7be2c0 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_selector_with_literal.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_selector_with_literal.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_selector_with_responsive-2.snap b/libs/extractor/src/snapshots/extractor__tests__extract_selector_with_responsive-2.snap index bda50fcc..0bc2ebfd 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_selector_with_responsive-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_selector_with_responsive-2.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -41,6 +43,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -54,6 +57,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_selector_with_responsive-3.snap b/libs/extractor/src/snapshots/extractor__tests__extract_selector_with_responsive-3.snap index 2714b305..1d72bba3 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_selector_with_responsive-3.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_selector_with_responsive-3.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -41,6 +43,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -54,6 +57,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_selector_with_responsive.snap b/libs/extractor/src/snapshots/extractor__tests__extract_selector_with_responsive.snap index 73e85e47..3883550c 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_selector_with_responsive.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_selector_with_responsive.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -41,6 +43,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -54,6 +57,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-10.snap b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-10.snap index 45f51835..b0e26b2b 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-10.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-10.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -41,6 +43,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -54,6 +57,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -67,6 +71,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -80,6 +85,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-14.snap b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-14.snap index f7d1d6b4..29d5c174 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-14.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-14.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-16.snap b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-16.snap index d43a2844..fccec3d8 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-16.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-16.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-2.snap b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-2.snap index f05759ba..80418b82 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-2.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-3.snap b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-3.snap index 108d85ba..0abaf053 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-3.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-3.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-4.snap b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-4.snap index 9f216d68..57a96746 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-4.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-4.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-5.snap b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-5.snap index 04ca1f39..44cf482c 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-5.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-5.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-6.snap b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-6.snap index 6ccc9b6a..dc562d70 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-6.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-6.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-9.snap b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-9.snap index 2fc0e451..4b8bcf7b 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-9.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props-9.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props.snap b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props.snap index a2d44a5a..b2f07e10 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_class_name_props.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_with_media_query-2.snap b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_with_media_query-2.snap index 86da1b52..fbecc316 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_with_media_query-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_with_media_query-2.snap @@ -19,6 +19,7 @@ ToBTreeSet { }, ), style_order: None, + layer: None, }, ), Static( @@ -36,6 +37,7 @@ ToBTreeSet { }, ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_with_media_query-3.snap b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_with_media_query-3.snap index ead2764b..36e10741 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_with_media_query-3.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_with_media_query-3.snap @@ -17,6 +17,7 @@ ToBTreeSet { }, ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_with_media_query.snap b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_with_media_query.snap index 9a47ff54..2077d8c2 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_with_media_query.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_with_media_query.snap @@ -17,6 +17,7 @@ ToBTreeSet { }, ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_with_theme-2.snap b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_with_theme-2.snap index 4eb9a1ba..6d74926e 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_with_theme-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_with_theme-2.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_with_theme-3.snap b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_with_theme-3.snap index 22d5428e..cdc744ed 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_with_theme-3.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_with_theme-3.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_with_theme.snap b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_with_theme.snap index 651d3a8f..c48814ad 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_static_css_with_theme.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_static_css_with_theme.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_style_props-2.snap b/libs/extractor/src/snapshots/extractor__tests__extract_style_props-2.snap index 4b427ebc..ed8c3a89 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_style_props-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_style_props-2.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_style_props-3.snap b/libs/extractor/src/snapshots/extractor__tests__extract_style_props-3.snap index 41cc3780..305819ae 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_style_props-3.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_style_props-3.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_style_props-4.snap b/libs/extractor/src/snapshots/extractor__tests__extract_style_props-4.snap index 5fa03b86..a3398beb 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_style_props-4.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_style_props-4.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_style_props-5.snap b/libs/extractor/src/snapshots/extractor__tests__extract_style_props-5.snap index 5f4ecc07..da5a8374 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_style_props-5.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_style_props-5.snap @@ -13,6 +13,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -22,6 +23,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -31,6 +33,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_style_props-6.snap b/libs/extractor/src/snapshots/extractor__tests__extract_style_props-6.snap index e72f84d5..f1919eb8 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_style_props-6.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_style_props-6.snap @@ -13,6 +13,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -22,6 +23,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_style_props.snap b/libs/extractor/src/snapshots/extractor__tests__extract_style_props.snap index 2309807c..61c2a7e9 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_style_props.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_style_props.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-2.snap b/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-2.snap index f8852f79..897bf5bb 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-2.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-3.snap b/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-3.snap index a02a4b7e..e9334b61 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-3.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-3.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-4.snap b/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-4.snap index 7f7f222d..e65ea4f5 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-4.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-4.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-5.snap b/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-5.snap index 15629abc..3575d539 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-5.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-5.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-6.snap b/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-6.snap index 1d5af36d..93a01d85 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-6.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-6.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-7.snap b/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-7.snap index 4fabccb8..a4cdbe2e 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-7.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-7.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-8.snap b/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-8.snap index b32298c2..754c6f48 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-8.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-8.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -28,6 +29,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), Static( @@ -37,6 +39,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-9.snap b/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-9.snap index 83b81baa..eea9d4bd 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-9.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name-9.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Typography( diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name.snap b/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name.snap index b01411ad..28eefb54 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_class_name.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -20,6 +21,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_default_import.snap b/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_default_import.snap index cdf1cb1e..7bfcc213 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_default_import.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_default_import.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -22,6 +23,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -31,6 +33,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_namespace_import.snap b/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_namespace_import.snap index d5a07731..4fa9b7fb 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_namespace_import.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_namespace_import.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), Static( @@ -22,6 +23,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -31,6 +33,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_var_css.snap b/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_var_css.snap index 9e4261cd..2085cbbd 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_var_css.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_style_props_with_var_css.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_wrong_global_css.snap b/libs/extractor/src/snapshots/extractor__tests__extract_wrong_global_css.snap index ae6f23bf..3610d104 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_wrong_global_css.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_wrong_global_css.snap @@ -18,6 +18,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_wrong_keyframs.snap b/libs/extractor/src/snapshots/extractor__tests__extract_wrong_keyframs.snap index b911c2f4..53644f20 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_wrong_keyframs.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_wrong_keyframs.snap @@ -14,6 +14,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "to": [ @@ -23,6 +24,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], "true": [ @@ -32,6 +34,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ], }, diff --git a/libs/extractor/src/snapshots/extractor__tests__extract_wrong_responsive_style_props-2.snap b/libs/extractor/src/snapshots/extractor__tests__extract_wrong_responsive_style_props-2.snap index d42c6379..84fd26ea 100644 --- a/libs/extractor/src/snapshots/extractor__tests__extract_wrong_responsive_style_props-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__extract_wrong_responsive_style_props-2.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__global_css_at_rules-2.snap b/libs/extractor/src/snapshots/extractor__tests__global_css_at_rules-2.snap index 7a8285fc..5d0a57e4 100644 --- a/libs/extractor/src/snapshots/extractor__tests__global_css_at_rules-2.snap +++ b/libs/extractor/src/snapshots/extractor__tests__global_css_at_rules-2.snap @@ -21,6 +21,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__global_css_at_rules-3.snap b/libs/extractor/src/snapshots/extractor__tests__global_css_at_rules-3.snap index e3df1c7c..b8b66f73 100644 --- a/libs/extractor/src/snapshots/extractor__tests__global_css_at_rules-3.snap +++ b/libs/extractor/src/snapshots/extractor__tests__global_css_at_rules-3.snap @@ -21,6 +21,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__global_css_at_rules-4.snap b/libs/extractor/src/snapshots/extractor__tests__global_css_at_rules-4.snap index f1927a5d..111d8b3a 100644 --- a/libs/extractor/src/snapshots/extractor__tests__global_css_at_rules-4.snap +++ b/libs/extractor/src/snapshots/extractor__tests__global_css_at_rules-4.snap @@ -21,6 +21,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -37,6 +38,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -56,6 +58,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -75,6 +78,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__global_css_at_rules.snap b/libs/extractor/src/snapshots/extractor__tests__global_css_at_rules.snap index 9a5dfc1c..6344e3ca 100644 --- a/libs/extractor/src/snapshots/extractor__tests__global_css_at_rules.snap +++ b/libs/extractor/src/snapshots/extractor__tests__global_css_at_rules.snap @@ -21,6 +21,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__global_css_fontfaces_object_syntax-2.snap b/libs/extractor/src/snapshots/extractor__tests__global_css_fontfaces_object_syntax-2.snap new file mode 100644 index 00000000..ed8403d3 --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__tests__global_css_fontfaces_object_syntax-2.snap @@ -0,0 +1,29 @@ +--- +source: libs/extractor/src/lib.rs +expression: "ToBTreeSet::from(extract(\"test.tsx\",\nr#\"import { globalCss } from '@devup-ui/core'\nglobalCss({\n fontFaces: [\n {\n fontFamily: \"MultiFont\",\n src: \"url('/fonts/multi.woff2')\",\n fontWeight: \"bold\",\n fontDisplay: \"swap\"\n },\n {\n fontFamily: \"AnotherFont\",\n src: \"local('Arial')\"\n }\n ]\n})\n\"#,\nExtractOption\n{\n package: \"@devup-ui/core\".to_string(), css_dir:\n \"@devup-ui/core\".to_string(), single_css: true, import_main_css: false\n}).unwrap())" +--- +ToBTreeSet { + styles: { + FontFace( + ExtractFontFace { + file: "test.tsx", + properties: { + "font-display": "swap", + "font-family": "MultiFont", + "font-weight": "bold", + "src": "url('/fonts/multi.woff2')", + }, + }, + ), + FontFace( + ExtractFontFace { + file: "test.tsx", + properties: { + "font-family": "AnotherFont", + "src": "local('Arial')", + }, + }, + ), + }, + code: "import \"@devup-ui/core/devup-ui.css\";\n;\n", +} diff --git a/libs/extractor/src/snapshots/extractor__tests__global_css_fontfaces_object_syntax.snap b/libs/extractor/src/snapshots/extractor__tests__global_css_fontfaces_object_syntax.snap new file mode 100644 index 00000000..bfb9c42d --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__tests__global_css_fontfaces_object_syntax.snap @@ -0,0 +1,20 @@ +--- +source: libs/extractor/src/lib.rs +expression: "ToBTreeSet::from(extract(\"test.tsx\",\nr#\"import { globalCss } from '@devup-ui/core'\nglobalCss({\n fontFaces: [\n {\n fontFamily: \"CustomFont\",\n src: \"url('/fonts/custom.woff2')\",\n fontWeight: \"400\",\n fontStyle: \"normal\"\n }\n ]\n})\n\"#,\nExtractOption\n{\n package: \"@devup-ui/core\".to_string(), css_dir:\n \"@devup-ui/core\".to_string(), single_css: true, import_main_css: false\n}).unwrap())" +--- +ToBTreeSet { + styles: { + FontFace( + ExtractFontFace { + file: "test.tsx", + properties: { + "font-family": "CustomFont", + "font-style": "normal", + "font-weight": "400", + "src": "url('/fonts/custom.woff2')", + }, + }, + ), + }, + code: "import \"@devup-ui/core/devup-ui.css\";\n;\n", +} diff --git a/libs/extractor/src/snapshots/extractor__tests__global_css_function.snap b/libs/extractor/src/snapshots/extractor__tests__global_css_function.snap index 4753ef46..75314812 100644 --- a/libs/extractor/src/snapshots/extractor__tests__global_css_function.snap +++ b/libs/extractor/src/snapshots/extractor__tests__global_css_function.snap @@ -18,6 +18,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), Static( @@ -34,6 +35,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__global_css_layer_property_extraction.snap b/libs/extractor/src/snapshots/extractor__tests__global_css_layer_property_extraction.snap new file mode 100644 index 00000000..968cb53e --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__tests__global_css_layer_property_extraction.snap @@ -0,0 +1,66 @@ +--- +source: libs/extractor/src/lib.rs +expression: "ToBTreeSet::from(extract(\"test.tsx\",\nr#\"import { globalCss } from '@devup-ui/core'\nglobalCss({\n \".reset-box\": {\n \"@layer\": \"reset\",\n margin: 0,\n padding: 0,\n boxSizing: \"border-box\"\n }\n})\n\"#,\nExtractOption\n{\n package: \"@devup-ui/core\".to_string(), css_dir:\n \"@devup-ui/core\".to_string(), single_css: true, import_main_css: false\n}).unwrap())" +--- +ToBTreeSet { + styles: { + Static( + ExtractStaticStyle { + property: "box-sizing", + value: "border-box", + level: 0, + selector: Some( + Global( + ".reset-box", + "test.tsx", + ), + ), + style_order: Some( + 0, + ), + layer: Some( + "reset", + ), + }, + ), + Static( + ExtractStaticStyle { + property: "margin", + value: "0", + level: 0, + selector: Some( + Global( + ".reset-box", + "test.tsx", + ), + ), + style_order: Some( + 0, + ), + layer: Some( + "reset", + ), + }, + ), + Static( + ExtractStaticStyle { + property: "padding", + value: "0", + level: 0, + selector: Some( + Global( + ".reset-box", + "test.tsx", + ), + ), + style_order: Some( + 0, + ), + layer: Some( + "reset", + ), + }, + ), + }, + code: "import \"@devup-ui/core/devup-ui.css\";\n;\n", +} diff --git a/libs/extractor/src/snapshots/extractor__tests__global_css_with_layer-2.snap b/libs/extractor/src/snapshots/extractor__tests__global_css_with_layer-2.snap new file mode 100644 index 00000000..ff8f0255 --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__tests__global_css_with_layer-2.snap @@ -0,0 +1,47 @@ +--- +source: libs/extractor/src/lib.rs +expression: "ToBTreeSet::from(extract(\"test.tsx\",\nr#\"import {globalCss} from '@devup-ui/core'\nglobalCss({\n \"*\": {\n \"@layer\": \"reset\",\n boxSizing: \"border-box\"\n },\n body: {\n \"@layer\": \"base\",\n fontFamily: \"sans-serif\"\n }\n})\n\"#,\nExtractOption\n{\n package: \"@devup-ui/core\".to_string(), css_dir:\n \"@devup-ui/core\".to_string(), single_css: false, import_main_css: false\n}).unwrap())" +--- +ToBTreeSet { + styles: { + Static( + ExtractStaticStyle { + property: "box-sizing", + value: "border-box", + level: 0, + selector: Some( + Global( + "*", + "test.tsx", + ), + ), + style_order: Some( + 0, + ), + layer: Some( + "reset", + ), + }, + ), + Static( + ExtractStaticStyle { + property: "font-family", + value: "sans-serif", + level: 0, + selector: Some( + Global( + "body", + "test.tsx", + ), + ), + style_order: Some( + 0, + ), + layer: Some( + "base", + ), + }, + ), + }, + code: "import \"@devup-ui/core/devup-ui-0.css\";\n;\n", +} diff --git a/libs/extractor/src/snapshots/extractor__tests__global_css_with_layer.snap b/libs/extractor/src/snapshots/extractor__tests__global_css_with_layer.snap new file mode 100644 index 00000000..250a4095 --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__tests__global_css_with_layer.snap @@ -0,0 +1,47 @@ +--- +source: libs/extractor/src/lib.rs +expression: "ToBTreeSet::from(extract(\"test.tsx\",\nr#\"import {globalCss} from '@devup-ui/core'\nglobalCss({\n \"*\": {\n \"@layer\": \"reset\",\n margin: 0,\n padding: 0\n }\n})\n\"#,\nExtractOption\n{\n package: \"@devup-ui/core\".to_string(), css_dir:\n \"@devup-ui/core\".to_string(), single_css: false, import_main_css: false\n}).unwrap())" +--- +ToBTreeSet { + styles: { + Static( + ExtractStaticStyle { + property: "margin", + value: "0", + level: 0, + selector: Some( + Global( + "*", + "test.tsx", + ), + ), + style_order: Some( + 0, + ), + layer: Some( + "reset", + ), + }, + ), + Static( + ExtractStaticStyle { + property: "padding", + value: "0", + level: 0, + selector: Some( + Global( + "*", + "test.tsx", + ), + ), + style_order: Some( + 0, + ), + layer: Some( + "reset", + ), + }, + ), + }, + code: "import \"@devup-ui/core/devup-ui-0.css\";\n;\n", +} diff --git a/libs/extractor/src/snapshots/extractor__tests__global_css_with_layer_in_selector-2.snap b/libs/extractor/src/snapshots/extractor__tests__global_css_with_layer_in_selector-2.snap new file mode 100644 index 00000000..aa2aa7cd --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__tests__global_css_with_layer_in_selector-2.snap @@ -0,0 +1,47 @@ +--- +source: libs/extractor/src/lib.rs +expression: "ToBTreeSet::from(extract(\"test.tsx\",\nr#\"import { globalCss } from '@devup-ui/core'\nglobalCss({\n \".card\": {\n \"@layer\": \"layout\",\n display: \"flex\"\n },\n \".text\": {\n \"@layer\": \"typography\",\n fontSize: \"16px\"\n }\n})\n\"#,\nExtractOption\n{\n package: \"@devup-ui/core\".to_string(), css_dir:\n \"@devup-ui/core\".to_string(), single_css: true, import_main_css: false\n}).unwrap())" +--- +ToBTreeSet { + styles: { + Static( + ExtractStaticStyle { + property: "display", + value: "flex", + level: 0, + selector: Some( + Global( + ".card", + "test.tsx", + ), + ), + style_order: Some( + 0, + ), + layer: Some( + "layout", + ), + }, + ), + Static( + ExtractStaticStyle { + property: "font-size", + value: "16px", + level: 0, + selector: Some( + Global( + ".text", + "test.tsx", + ), + ), + style_order: Some( + 0, + ), + layer: Some( + "typography", + ), + }, + ), + }, + code: "import \"@devup-ui/core/devup-ui.css\";\n;\n", +} diff --git a/libs/extractor/src/snapshots/extractor__tests__global_css_with_layer_in_selector.snap b/libs/extractor/src/snapshots/extractor__tests__global_css_with_layer_in_selector.snap new file mode 100644 index 00000000..dd98a9a1 --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__tests__global_css_with_layer_in_selector.snap @@ -0,0 +1,47 @@ +--- +source: libs/extractor/src/lib.rs +expression: "ToBTreeSet::from(extract(\"test.tsx\",\nr#\"import { globalCss } from '@devup-ui/core'\nglobalCss({\n \".button\": {\n \"@layer\": \"components\",\n padding: \"8px\",\n background: \"blue\"\n }\n})\n\"#,\nExtractOption\n{\n package: \"@devup-ui/core\".to_string(), css_dir:\n \"@devup-ui/core\".to_string(), single_css: true, import_main_css: false\n}).unwrap())" +--- +ToBTreeSet { + styles: { + Static( + ExtractStaticStyle { + property: "background", + value: "blue", + level: 0, + selector: Some( + Global( + ".button", + "test.tsx", + ), + ), + style_order: Some( + 0, + ), + layer: Some( + "components", + ), + }, + ), + Static( + ExtractStaticStyle { + property: "padding", + value: "8px", + level: 0, + selector: Some( + Global( + ".button", + "test.tsx", + ), + ), + style_order: Some( + 0, + ), + layer: Some( + "components", + ), + }, + ), + }, + code: "import \"@devup-ui/core/devup-ui.css\";\n;\n", +} diff --git a/libs/extractor/src/snapshots/extractor__tests__global_css_with_pseudo_selector.snap b/libs/extractor/src/snapshots/extractor__tests__global_css_with_pseudo_selector.snap index b3efee99..fc538fa8 100644 --- a/libs/extractor/src/snapshots/extractor__tests__global_css_with_pseudo_selector.snap +++ b/libs/extractor/src/snapshots/extractor__tests__global_css_with_pseudo_selector.snap @@ -18,6 +18,7 @@ ToBTreeSet { style_order: Some( 0, ), + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__group_selector_props.snap b/libs/extractor/src/snapshots/extractor__tests__group_selector_props.snap index b8004ff1..19213712 100644 --- a/libs/extractor/src/snapshots/extractor__tests__group_selector_props.snap +++ b/libs/extractor/src/snapshots/extractor__tests__group_selector_props.snap @@ -15,6 +15,7 @@ ToBTreeSet { ), ), style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__ignore_special_props.snap b/libs/extractor/src/snapshots/extractor__tests__ignore_special_props.snap index ad243f22..bed553eb 100644 --- a/libs/extractor/src/snapshots/extractor__tests__ignore_special_props.snap +++ b/libs/extractor/src/snapshots/extractor__tests__ignore_special_props.snap @@ -11,6 +11,7 @@ ToBTreeSet { level: 0, selector: None, style_order: None, + layer: None, }, ), }, diff --git a/libs/extractor/src/snapshots/extractor__tests__import_alias_custom_named_export.snap b/libs/extractor/src/snapshots/extractor__tests__import_alias_custom_named_export.snap new file mode 100644 index 00000000..da0a4d6d --- /dev/null +++ b/libs/extractor/src/snapshots/extractor__tests__import_alias_custom_named_export.snap @@ -0,0 +1,29 @@ +--- +source: libs/extractor/src/lib.rs +expression: "ToBTreeSet::from(extract(\"test.tsx\",\nr#\"import emotionStyled from '@emotion/styled'\nconst Button = emotionStyled.button({ bg: 'purple', p: 3 })\n\"#,\nExtractOption\n{\n package: \"@devup-ui/react\".to_string(), css_dir:\n \"@devup-ui/react\".to_string(), single_css: true, import_main_css: false,\n import_aliases: aliases,\n},).unwrap())" +--- +ToBTreeSet { + styles: { + Static( + ExtractStaticStyle { + property: "background", + value: "purple", + level: 0, + selector: None, + style_order: None, + layer: None, + }, + ), + Static( + ExtractStaticStyle { + property: "padding", + value: "12px", + level: 0, + selector: None, + style_order: None, + layer: None, + }, + ), + }, + code: "import \"@devup-ui/react/devup-ui.css\";\nconst Button = ({ style, className, ...rest }) =>