From d730186e9f49b9481b89b35121d7095e05781565 Mon Sep 17 00:00:00 2001 From: OJ Kwon <1210596+kwonoj@users.noreply.github.com> Date: Tue, 29 Nov 2022 23:09:44 -0800 Subject: [PATCH 1/2] build(cargo): Update `browerslist-rs` (#6547) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Donny/강동윤 --- Cargo.lock | 114 ++++++++++++++- crates/preset_env_base/Cargo.toml | 32 ++--- .../issues-1xxx/1402/case1/output/index.ts | 2 +- .../issues-1xxx/1448/case1/output/index.ts | 4 +- .../issues-1xxx/1568/case1/output/index.ts | 4 +- .../issues-1xxx/1714/case1/output/index.js | 8 +- .../issues-1xxx/1721/case1/output/index.js | 135 ++---------------- .../issues-1xxx/1722/case1/output/index.js | 19 +-- .../issues-2xxx/2154/case1/output/index.js | 2 +- .../fixture/shopify/003-env/output/index.js | 13 +- .../fixture/shopify/004-jest/output/index.js | 13 +- .../shopify/005-no-module/output/index.js | 3 +- .../clip-path/output.defaults-not-ie-11.css | 1 - .../output.defaults-not-ie-11.css | 6 - .../output.defaults-not-ie-11.css | 7 - .../nested/output.defaults-not-ie-11.css | 15 -- .../placeholder/output.defaults-not-ie-11.css | 13 +- .../position/output.defaults-not-ie-11.css | 1 - .../output.defaults-not-ie-11.css | 2 - .../resolution/output.defaults-not-ie-11.css | 3 - .../output.defaults-not-ie-11.css | 8 -- .../width-size/output.defaults-not-ie-11.css | 22 --- .../width/output.defaults-not-ie-11.css | 6 - 23 files changed, 154 insertions(+), 279 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 878a540fe566..4f4b99fb95c8 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -49,6 +49,15 @@ dependencies = [ "memchr", ] +[[package]] +name = "android_system_properties" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "819e7219dbd41043ac279b19830f2efc897156490d7fd6ea916720117ee66311" +dependencies = [ + "libc", +] + [[package]] name = "ansi_term" version = "0.12.1" @@ -216,9 +225,9 @@ dependencies = [ [[package]] name = "browserslist-rs" -version = "0.11.0" +version = "0.12.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7c689fb4e42bd511c1927856b078d8a582690f5be196199d1c9005b9d4feae8c" +checksum = "421478dde88feb4281328dea29dbf6d2b57bc19a8968214fc3694c8c574bc47f" dependencies = [ "ahash", "anyhow", @@ -318,12 +327,12 @@ checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" [[package]] name = "chrono" -version = "0.4.19" +version = "0.4.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "670ad68c9088c2a963aaa298cb369688cf3f9465ce5e2d4ca10e6e0098a1ce73" +checksum = "16b0a3d9ed01224b22057780a37bb8c5dbfe1be8ba48678e7bf57ec4b385411f" dependencies = [ + "iana-time-zone", "js-sys", - "libc", "num-integer", "num-traits", "time 0.1.43", @@ -372,6 +381,16 @@ dependencies = [ "syn", ] +[[package]] +name = "codespan-reporting" +version = "0.11.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3538270d33cc669650c4b093848450d380def10c331d38c768e34cac80576e6e" +dependencies = [ + "termcolor", + "unicode-width", +] + [[package]] name = "console" version = "0.15.1" @@ -697,6 +716,50 @@ version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b365fabc795046672053e29c954733ec3b05e4be654ab130fe8f1f94d7051f35" +[[package]] +name = "cxx" +version = "1.0.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d4a41a86530d0fe7f5d9ea779916b7cadd2d4f9add748b99c2c029cbbdfaf453" +dependencies = [ + "cc", + "cxxbridge-flags", + "cxxbridge-macro", + "link-cplusplus", +] + +[[package]] +name = "cxx-build" +version = "1.0.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "06416d667ff3e3ad2df1cd8cd8afae5da26cf9cec4d0825040f88b5ca659a2f0" +dependencies = [ + "cc", + "codespan-reporting", + "once_cell", + "proc-macro2", + "quote", + "scratch", + "syn", +] + +[[package]] +name = "cxxbridge-flags" +version = "1.0.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "820a9a2af1669deeef27cb271f476ffd196a2c4b6731336011e0ba63e2c7cf71" + +[[package]] +name = "cxxbridge-macro" +version = "1.0.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a08a6e2fcc370a089ad3b4aaf54db3b1b4cee38ddabce5896b33eb693275f470" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + [[package]] name = "darling" version = "0.13.1" @@ -1267,6 +1330,30 @@ dependencies = [ "tokio-native-tls", ] +[[package]] +name = "iana-time-zone" +version = "0.1.53" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "64c122667b287044802d6ce17ee2ddf13207ed924c712de9a66a5814d5b64765" +dependencies = [ + "android_system_properties", + "core-foundation-sys", + "iana-time-zone-haiku", + "js-sys", + "wasm-bindgen", + "winapi", +] + +[[package]] +name = "iana-time-zone-haiku" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0703ae284fc167426161c2e3f1da3ea71d94b21bedbcc9494e92b28e334e3dca" +dependencies = [ + "cxx", + "cxx-build", +] + [[package]] name = "ident_case" version = "1.0.1" @@ -1482,6 +1569,15 @@ dependencies = [ "winapi", ] +[[package]] +name = "link-cplusplus" +version = "1.0.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9272ab7b96c9046fbc5bc56c06c117cb639fe2d509df0c421cad82d2915cf369" +dependencies = [ + "cc", +] + [[package]] name = "lock_api" version = "0.4.6" @@ -2594,6 +2690,12 @@ version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d29ab0c6d3fc0ee92fe66e2d99f700eab17a8d57d1c1d3b748380fb20baa78cd" +[[package]] +name = "scratch" +version = "1.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9c8132065adcfd6e02db789d9285a0deb2f3fcb04002865ab67d5fb103533898" + [[package]] name = "seahash" version = "4.1.0" @@ -4924,8 +5026,6 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "eaf9f5aceeec8be17c128b2e93e031fb8a4d469bb9c4ae2d7dc1888b26887268" dependencies = [ "cfg-if 1.0.0", - "serde", - "serde_json", "wasm-bindgen-macro", ] diff --git a/crates/preset_env_base/Cargo.toml b/crates/preset_env_base/Cargo.toml index 5c1c0424239e..a9b79ed0d626 100644 --- a/crates/preset_env_base/Cargo.toml +++ b/crates/preset_env_base/Cargo.toml @@ -1,23 +1,23 @@ [package] -authors = ["강동윤 "] -description = "Common logic for targetting vairous browsers" +authors = ["강동윤 "] +description = "Common logic for targetting vairous browsers" documentation = "https://rustdoc.swc.rs/preset_env_base/" -edition = "2021" -license = "Apache-2.0" -name = "preset_env_base" -version = "0.3.2" +edition = "2021" +license = "Apache-2.0" +name = "preset_env_base" +version = "0.3.2" [lib] bench = false [dependencies] -ahash = "0.7.4" -anyhow = "1" -browserslist-rs = "=0.11.0" -dashmap = "5.1.0" -from_variant = { version = "0.1.3", path = "../from_variant" } -once_cell = "1.12.0" -semver = { version = "1.0.4", features = ["serde"] } -serde = { version = "1", features = ["derive"] } -st-map = "0.1.2" -tracing = { version = "0.1.32" } +ahash = "0.7.4" +anyhow = "1" +browserslist-rs = "0.12.2" +dashmap = "5.1.0" +from_variant = { version = "0.1.3", path = "../from_variant" } +once_cell = "1.12.0" +semver = { version = "1.0.4", features = ["serde"] } +serde = { version = "1", features = ["derive"] } +st-map = "0.1.2" +tracing = { version = "0.1.32" } diff --git a/crates/swc/tests/fixture/issues-1xxx/1402/case1/output/index.ts b/crates/swc/tests/fixture/issues-1xxx/1402/case1/output/index.ts index dda230d06d28..11f3f0383c46 100644 --- a/crates/swc/tests/fixture/issues-1xxx/1402/case1/output/index.ts +++ b/crates/swc/tests/fixture/issues-1xxx/1402/case1/output/index.ts @@ -1,6 +1,6 @@ var e = 1; try { throw 2; -} catch (e1) { +} catch { console.log(e); } diff --git a/crates/swc/tests/fixture/issues-1xxx/1448/case1/output/index.ts b/crates/swc/tests/fixture/issues-1xxx/1448/case1/output/index.ts index 9694556cf46b..c83f9e21883a 100644 --- a/crates/swc/tests/fixture/issues-1xxx/1448/case1/output/index.ts +++ b/crates/swc/tests/fixture/issues-1xxx/1448/case1/output/index.ts @@ -1,4 +1,4 @@ import { createRequire as _createRequire } from "module"; -var __require = _createRequire(import.meta.url); -var F = __require("yaml"); +const __require = _createRequire(import.meta.url); +const F = __require("yaml"); console.log(F); diff --git a/crates/swc/tests/fixture/issues-1xxx/1568/case1/output/index.ts b/crates/swc/tests/fixture/issues-1xxx/1568/case1/output/index.ts index a138f7f9c593..01d3e8e0edad 100644 --- a/crates/swc/tests/fixture/issues-1xxx/1568/case1/output/index.ts +++ b/crates/swc/tests/fixture/issues-1xxx/1568/case1/output/index.ts @@ -4,9 +4,7 @@ Object.defineProperty(exports, "__esModule", { }); Object.defineProperty(exports, "default", { enumerable: true, - get: function() { - return get; - } + get: ()=>get }); function get(key) { console.log(key); diff --git a/crates/swc/tests/fixture/issues-1xxx/1714/case1/output/index.js b/crates/swc/tests/fixture/issues-1xxx/1714/case1/output/index.js index a81d8749ac19..48f220be6542 100644 --- a/crates/swc/tests/fixture/issues-1xxx/1714/case1/output/index.js +++ b/crates/swc/tests/fixture/issues-1xxx/1714/case1/output/index.js @@ -4,10 +4,8 @@ Object.defineProperty(exports, "__esModule", { }); Object.defineProperty(exports, "render", { enumerable: true, - get: function() { - return _customRender.customRender; - } + get: ()=>_customRender.customRender }); -var _exportStar = require("@swc/helpers/lib/_export_star.js").default; -var _customRender = require("./customRender"); +const _exportStar = require("@swc/helpers/lib/_export_star.js").default; +const _customRender = require("./customRender"); _exportStar(require("@testing-library/react"), exports); diff --git a/crates/swc/tests/fixture/issues-1xxx/1721/case1/output/index.js b/crates/swc/tests/fixture/issues-1xxx/1721/case1/output/index.js index 4818a3b65699..d34a8d3f0bbd 100644 --- a/crates/swc/tests/fixture/issues-1xxx/1721/case1/output/index.js +++ b/crates/swc/tests/fixture/issues-1xxx/1721/case1/output/index.js @@ -1,129 +1,10 @@ -import _async_iterator from "@swc/helpers/src/_async_iterator.mjs"; -import _async_to_generator from "@swc/helpers/src/_async_to_generator.mjs"; -import _wrap_async_generator from "@swc/helpers/src/_wrap_async_generator.mjs"; -import _ts_generator from "@swc/helpers/src/_ts_generator.mjs"; -function lol() { - return _lol.apply(this, arguments); -} -function _lol() { - _lol = _wrap_async_generator(function() { - return _ts_generator(this, function(_state) { - switch(_state.label){ - case 0: - return [ - 4, - 1 - ]; - case 1: - _state.sent(); - return [ - 4, - 2 - ]; - case 2: - _state.sent(); - return [ - 2 - ]; - } - }); - }); - return _lol.apply(this, arguments); -} -function main() { - return _main.apply(this, arguments); -} -function _main() { - _main = _async_to_generator(function() { - var _iteratorAbruptCompletion, _didIteratorError, _iteratorError, _iterator, _step, _value, x, err; - return _ts_generator(this, function(_state) { - switch(_state.label){ - case 0: - _iteratorAbruptCompletion = false, _didIteratorError = false; - _state.label = 1; - case 1: - _state.trys.push([ - 1, - 6, - 7, - 12 - ]); - _iterator = _async_iterator(lol()); - _state.label = 2; - case 2: - return [ - 4, - _iterator.next() - ]; - case 3: - if (!(_iteratorAbruptCompletion = !(_step = _state.sent()).done)) return [ - 3, - 5 - ]; - _value = _step.value; - x = _value; - console.log(x); - _state.label = 4; - case 4: - _iteratorAbruptCompletion = false; - return [ - 3, - 2 - ]; - case 5: - return [ - 3, - 12 - ]; - case 6: - err = _state.sent(); - _didIteratorError = true; - _iteratorError = err; - return [ - 3, - 12 - ]; - case 7: - _state.trys.push([ - 7, - , - 10, - 11 - ]); - if (!(_iteratorAbruptCompletion && _iterator.return != null)) return [ - 3, - 9 - ]; - return [ - 4, - _iterator.return() - ]; - case 8: - _state.sent(); - _state.label = 9; - case 9: - return [ - 3, - 11 - ]; - case 10: - if (_didIteratorError) { - throw _iteratorError; - } - return [ - 7 - ]; - case 11: - return [ - 7 - ]; - case 12: - return [ - 2 - ]; - } - }); - }); - return _main.apply(this, arguments); +async function* lol() { + yield 1; + yield 2; +} +async function main() { + for await (const x of lol()){ + console.log(x); + } } main(); diff --git a/crates/swc/tests/fixture/issues-1xxx/1722/case1/output/index.js b/crates/swc/tests/fixture/issues-1xxx/1722/case1/output/index.js index f97ff32dfe95..db896fdbfabb 100644 --- a/crates/swc/tests/fixture/issues-1xxx/1722/case1/output/index.js +++ b/crates/swc/tests/fixture/issues-1xxx/1722/case1/output/index.js @@ -1,16 +1,3 @@ -import _async_to_generator from "@swc/helpers/src/_async_to_generator.mjs"; -import _ts_generator from "@swc/helpers/src/_ts_generator.mjs"; -(function() { - var _main = _async_to_generator(function() { - return _ts_generator(this, function(_state) { - console.log(1); - return [ - 2 - ]; - }); - }); - function main() { - return _main.apply(this, arguments); - } - return main; -})()(); +(async function main() { + console.log(1); +})(); diff --git a/crates/swc/tests/fixture/issues-2xxx/2154/case1/output/index.js b/crates/swc/tests/fixture/issues-2xxx/2154/case1/output/index.js index 642ef4f89948..644e5fc459ea 100644 --- a/crates/swc/tests/fixture/issues-2xxx/2154/case1/output/index.js +++ b/crates/swc/tests/fixture/issues-2xxx/2154/case1/output/index.js @@ -1,4 +1,4 @@ -var c = /*#__PURE__*/ React.createElement("img", { +const c = /*#__PURE__*/ React.createElement("img", { alt: "caf\xe9" }).props.alt; console.log(c); diff --git a/crates/swc/tests/fixture/shopify/003-env/output/index.js b/crates/swc/tests/fixture/shopify/003-env/output/index.js index a7974d80c5b6..2eafd6f5b2a1 100644 --- a/crates/swc/tests/fixture/shopify/003-env/output/index.js +++ b/crates/swc/tests/fixture/shopify/003-env/output/index.js @@ -4,15 +4,12 @@ Object.defineProperty(exports, "__esModule", { }); Object.defineProperty(exports, "App", { enumerable: true, - get: function() { - return App; - } + get: ()=>App }); -var _interopRequireDefault = require("@swc/helpers/lib/_interop_require_default.js").default; -var _slicedToArray = require("@swc/helpers/lib/_sliced_to_array.js").default; -var _react = /*#__PURE__*/ _interopRequireDefault(require("react")); -var _reactI18N = require("@shopify/react-i18n"); +const _interopRequireDefault = require("@swc/helpers/lib/_interop_require_default.js").default; +const _react = /*#__PURE__*/ _interopRequireDefault(require("react")); +const _reactI18N = require("@shopify/react-i18n"); function App() { - var _useI18n = _slicedToArray((0, _reactI18N.useI18n)(), 1), i18n = _useI18n[0]; + const [i18n] = (0, _reactI18N.useI18n)(); return /*#__PURE__*/ _react.default.createElement("h1", null, i18n.translate("foo")); } diff --git a/crates/swc/tests/fixture/shopify/004-jest/output/index.js b/crates/swc/tests/fixture/shopify/004-jest/output/index.js index a7974d80c5b6..2eafd6f5b2a1 100644 --- a/crates/swc/tests/fixture/shopify/004-jest/output/index.js +++ b/crates/swc/tests/fixture/shopify/004-jest/output/index.js @@ -4,15 +4,12 @@ Object.defineProperty(exports, "__esModule", { }); Object.defineProperty(exports, "App", { enumerable: true, - get: function() { - return App; - } + get: ()=>App }); -var _interopRequireDefault = require("@swc/helpers/lib/_interop_require_default.js").default; -var _slicedToArray = require("@swc/helpers/lib/_sliced_to_array.js").default; -var _react = /*#__PURE__*/ _interopRequireDefault(require("react")); -var _reactI18N = require("@shopify/react-i18n"); +const _interopRequireDefault = require("@swc/helpers/lib/_interop_require_default.js").default; +const _react = /*#__PURE__*/ _interopRequireDefault(require("react")); +const _reactI18N = require("@shopify/react-i18n"); function App() { - var _useI18n = _slicedToArray((0, _reactI18N.useI18n)(), 1), i18n = _useI18n[0]; + const [i18n] = (0, _reactI18N.useI18n)(); return /*#__PURE__*/ _react.default.createElement("h1", null, i18n.translate("foo")); } diff --git a/crates/swc/tests/fixture/shopify/005-no-module/output/index.js b/crates/swc/tests/fixture/shopify/005-no-module/output/index.js index 2bc9aab67943..fbe16db1b695 100644 --- a/crates/swc/tests/fixture/shopify/005-no-module/output/index.js +++ b/crates/swc/tests/fixture/shopify/005-no-module/output/index.js @@ -1,7 +1,6 @@ -import _sliced_to_array from "@swc/helpers/src/_sliced_to_array.mjs"; import React from "react"; import { useI18n } from "@shopify/react-i18n"; export function App() { - var _useI18n = _sliced_to_array(useI18n(), 1), i18n = _useI18n[0]; + const [i18n] = useI18n(); return /*#__PURE__*/ React.createElement("h1", null, i18n.translate("foo")); } diff --git a/crates/swc_css_prefixer/tests/fixture/clip-path/output.defaults-not-ie-11.css b/crates/swc_css_prefixer/tests/fixture/clip-path/output.defaults-not-ie-11.css index a296cb81bde1..57c6d6804bb4 100644 --- a/crates/swc_css_prefixer/tests/fixture/clip-path/output.defaults-not-ie-11.css +++ b/crates/swc_css_prefixer/tests/fixture/clip-path/output.defaults-not-ie-11.css @@ -1,4 +1,3 @@ .class { - -webkit-clip-path: none; clip-path: none; } diff --git a/crates/swc_css_prefixer/tests/fixture/file-selector-button/output.defaults-not-ie-11.css b/crates/swc_css_prefixer/tests/fixture/file-selector-button/output.defaults-not-ie-11.css index 848f622dad38..9e77af342362 100644 --- a/crates/swc_css_prefixer/tests/fixture/file-selector-button/output.defaults-not-ie-11.css +++ b/crates/swc_css_prefixer/tests/fixture/file-selector-button/output.defaults-not-ie-11.css @@ -1,12 +1,6 @@ -input[type=file]::-webkit-file-upload-button { - border: 2px solid #6c5ce7; -} input[type=file]::file-selector-button { border: 2px solid #6c5ce7; } -input[type=file]::-webkit-file-upload-button:hover { - border: 2px solid #00cec9; -} input[type=file]::file-selector-button:hover { border: 2px solid #00cec9; } diff --git a/crates/swc_css_prefixer/tests/fixture/grouping-rule/output.defaults-not-ie-11.css b/crates/swc_css_prefixer/tests/fixture/grouping-rule/output.defaults-not-ie-11.css index 1165861d111e..cc3f98c5d2b1 100644 --- a/crates/swc_css_prefixer/tests/fixture/grouping-rule/output.defaults-not-ie-11.css +++ b/crates/swc_css_prefixer/tests/fixture/grouping-rule/output.defaults-not-ie-11.css @@ -5,13 +5,6 @@ .b, .c::selection, .d:read-only, -.e::-webkit-input-placeholder { - color: yellow; -} -.a, -.b, -.c::selection, -.d:read-only, .e::placeholder { color: yellow; } diff --git a/crates/swc_css_prefixer/tests/fixture/nested/output.defaults-not-ie-11.css b/crates/swc_css_prefixer/tests/fixture/nested/output.defaults-not-ie-11.css index cf990b3d5233..da283e037db1 100644 --- a/crates/swc_css_prefixer/tests/fixture/nested/output.defaults-not-ie-11.css +++ b/crates/swc_css_prefixer/tests/fixture/nested/output.defaults-not-ie-11.css @@ -20,18 +20,11 @@ } } .test { - &.class::-webkit-input-placeholder { - color: red; - } &.class::placeholder { color: red; } } .test { - &.class::-webkit-input-placeholder { - -webkit-appearance: auto; - appearance: auto; - } &.class::placeholder { -webkit-appearance: auto; appearance: auto; @@ -67,10 +60,6 @@ .test { -webkit-appearance: auto; appearance: auto; - &.class::-webkit-input-placeholder { - -webkit-appearance: auto; - appearance: auto; - } &.class::placeholder { -webkit-appearance: auto; appearance: auto; @@ -82,10 +71,6 @@ } @media (orientation: landscape) { .test { - &.class::-webkit-input-placeholder { - -webkit-appearance: auto; - appearance: auto; - } &.class::placeholder { -webkit-appearance: auto; appearance: auto; diff --git a/crates/swc_css_prefixer/tests/fixture/placeholder/output.defaults-not-ie-11.css b/crates/swc_css_prefixer/tests/fixture/placeholder/output.defaults-not-ie-11.css index e640ae5340c2..0cccfd48e11a 100644 --- a/crates/swc_css_prefixer/tests/fixture/placeholder/output.defaults-not-ie-11.css +++ b/crates/swc_css_prefixer/tests/fixture/placeholder/output.defaults-not-ie-11.css @@ -1,10 +1,7 @@ -input::-webkit-input-placeholder { - color: red; -} input::placeholder { color: red; } -input::-webkit-input-placeholder, +input::placeholder, #fs-toggle:-webkit-full-screen { color: red; } @@ -12,18 +9,10 @@ input::placeholder, #fs-toggle:fullscreen { color: red; } -input::-webkit-input-placeholder { - -webkit-backdrop-filter: blur(2px); - backdrop-filter: blur(2px); -} input::placeholder { -webkit-backdrop-filter: blur(2px); backdrop-filter: blur(2px); } -input.appearance::-webkit-input-placeholder { - -webkit-appearance: none; - appearance: none; -} input.appearance::placeholder { -webkit-appearance: none; appearance: none; diff --git a/crates/swc_css_prefixer/tests/fixture/position/output.defaults-not-ie-11.css b/crates/swc_css_prefixer/tests/fixture/position/output.defaults-not-ie-11.css index fe353faaf334..a360e8a1a6fb 100644 --- a/crates/swc_css_prefixer/tests/fixture/position/output.defaults-not-ie-11.css +++ b/crates/swc_css_prefixer/tests/fixture/position/output.defaults-not-ie-11.css @@ -2,6 +2,5 @@ position: relative; } .class { - position: -webkit-sticky; position: sticky; } diff --git a/crates/swc_css_prefixer/tests/fixture/print-color-adjust/output.defaults-not-ie-11.css b/crates/swc_css_prefixer/tests/fixture/print-color-adjust/output.defaults-not-ie-11.css index d7187b08f286..6e2a8af19d11 100644 --- a/crates/swc_css_prefixer/tests/fixture/print-color-adjust/output.defaults-not-ie-11.css +++ b/crates/swc_css_prefixer/tests/fixture/print-color-adjust/output.defaults-not-ie-11.css @@ -1,10 +1,8 @@ .a { - color-adjust: economy; -webkit-print-color-adjust: economy; print-color-adjust: economy; } .b { - color-adjust: exact; -webkit-print-color-adjust: exact; print-color-adjust: exact; } diff --git a/crates/swc_css_prefixer/tests/fixture/resolution/output.defaults-not-ie-11.css b/crates/swc_css_prefixer/tests/fixture/resolution/output.defaults-not-ie-11.css index 7f07df96640b..8079d99a10d9 100644 --- a/crates/swc_css_prefixer/tests/fixture/resolution/output.defaults-not-ie-11.css +++ b/crates/swc_css_prefixer/tests/fixture/resolution/output.defaults-not-ie-11.css @@ -42,9 +42,6 @@ color: red; } } -::-webkit-input-placeholder { - color: gray; -} ::placeholder { color: gray; } diff --git a/crates/swc_css_prefixer/tests/fixture/text-emphasis/output.defaults-not-ie-11.css b/crates/swc_css_prefixer/tests/fixture/text-emphasis/output.defaults-not-ie-11.css index b8ebe6e2b441..7a1cd9378bbd 100644 --- a/crates/swc_css_prefixer/tests/fixture/text-emphasis/output.defaults-not-ie-11.css +++ b/crates/swc_css_prefixer/tests/fixture/text-emphasis/output.defaults-not-ie-11.css @@ -1,5 +1,4 @@ .class { - -webkit-text-emphasis: none; text-emphasis: none; } .class { @@ -7,30 +6,23 @@ -webkit-text-emphasis: filled red; } .class { - -webkit-text-emphasis-position: left; text-emphasis-position: left; } .class { - -webkit-text-emphasis-style: circle; text-emphasis-style: circle; } .class { - -webkit-text-emphasis-color: red; text-emphasis-color: red; } a { - -webkit-text-emphasis-position: over left; text-emphasis-position: over left; } em { - -webkit-text-emphasis-position: under right; text-emphasis-position: under right; } .reverse { - -webkit-text-emphasis-position: left over; text-emphasis-position: left over; } .wrong { - -webkit-text-emphasis-position: over; text-emphasis-position: over; } diff --git a/crates/swc_css_prefixer/tests/fixture/width-size/output.defaults-not-ie-11.css b/crates/swc_css_prefixer/tests/fixture/width-size/output.defaults-not-ie-11.css index 2547c03155fe..dd763f6c813b 100644 --- a/crates/swc_css_prefixer/tests/fixture/width-size/output.defaults-not-ie-11.css +++ b/crates/swc_css_prefixer/tests/fixture/width-size/output.defaults-not-ie-11.css @@ -1,9 +1,6 @@ div { - width: -moz-fit-content; width: fit-content; - width: -webkit-max-content; width: max-content; - width: -webkit-min-content; width: min-content; width: -webkit-fill-available; width: -moz-available; @@ -11,27 +8,16 @@ div { width: -webkit-fill-available; width: -moz-available; width: stretch; - min-width: -moz-fit-content; min-width: fit-content; - max-width: -moz-fit-content; max-width: fit-content; - height: -moz-fit-content; height: fit-content; - min-height: -moz-fit-content; min-height: fit-content; - max-height: -moz-fit-content; max-height: fit-content; - inline-size: -moz-fit-content; inline-size: fit-content; - min-inline-size: -moz-fit-content; min-inline-size: fit-content; - max-inline-size: -moz-fit-content; max-inline-size: fit-content; - block-size: -moz-fit-content; block-size: fit-content; - min-block-size: -moz-fit-content; min-block-size: fit-content; - max-block-size: -moz-fit-content; max-block-size: fit-content; } .outdated { @@ -45,13 +31,10 @@ a { width: stretch; } b { - height: -webkit-max-content; height: max-content; } p { - block-size: -webkit-min-content; block-size: min-content; - min-inline-size: -moz-fit-content; min-inline-size: fit-content; } .outdated { @@ -68,21 +51,16 @@ p { width: calc(100% - var(--jqx-circular-progress-bar-fill-size)); } .grid { - grid: -webkit-min-content -webkit-max-content/ fit-content(500px); grid: min-content max-content/ fit-content(500px); } .grid-template { - grid-template: -webkit-min-content/ fit-content(10px) -webkit-max-content; grid-template: min-content/ fit-content(10px) max-content; - grid-template: -webkit-max-content 1fr -webkit-max-content -webkit-max-content/ -webkit-max-content 1fr; grid-template: max-content 1fr max-content max-content/ max-content 1fr; } .grid-template-columns { - grid-template-columns: minmax(100px, -webkit-min-content); grid-template-columns: minmax(100px, min-content); } .grid-auto-columns { - grid-auto-columns: -webkit-min-content -webkit-max-content; grid-auto-columns: min-content max-content; } .ignore { diff --git a/crates/swc_css_prefixer/tests/fixture/width/output.defaults-not-ie-11.css b/crates/swc_css_prefixer/tests/fixture/width/output.defaults-not-ie-11.css index 9bd59df492eb..091e773a0b54 100644 --- a/crates/swc_css_prefixer/tests/fixture/width/output.defaults-not-ie-11.css +++ b/crates/swc_css_prefixer/tests/fixture/width/output.defaults-not-ie-11.css @@ -29,18 +29,15 @@ width: --max-content; } .class { - width: -moz-fit-content; width: fit-content; } .class { width: stackWidth; } .class { - min-width: -webkit-max-content; min-width: max-content; } .class { - max-width: -webkit-min-content; max-width: min-content; } .class { @@ -49,7 +46,6 @@ height: fill-available; } .class { - max-height: -moz-fit-content; max-height: fit-content; } .class { @@ -63,11 +59,9 @@ width: stretch !important; } .class { - min-block-size: -webkit-max-content; min-block-size: max-content; } .class { - min-inline-size: -webkit-max-content; min-inline-size: max-content; } .class { From 25fa08017ad772185f832b2175ab33565999a406 Mon Sep 17 00:00:00 2001 From: SWC Bot Date: Wed, 30 Nov 2022 07:13:15 +0000 Subject: [PATCH 2/2] chore: Publish crates --- CHANGELOG.md | 6 ++++++ Cargo.lock | 20 ++++++++++---------- crates/binding_macros/Cargo.toml | 4 ++-- crates/preset_env_base/Cargo.toml | 2 +- crates/swc/Cargo.toml | 4 ++-- crates/swc_core/Cargo.toml | 12 ++++++------ crates/swc_css/Cargo.toml | 4 ++-- crates/swc_css_prefixer/Cargo.toml | 4 ++-- crates/swc_ecma_preset_env/Cargo.toml | 4 ++-- crates/swc_ecmascript/Cargo.toml | 4 ++-- crates/swc_estree_compat/Cargo.toml | 4 ++-- crates/swc_node_bundler/Cargo.toml | 4 ++-- 12 files changed, 39 insertions(+), 33 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index b835dfd0a847..f68d92f20cf5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -67,6 +67,12 @@ - **(ts/compat)** Migrate inline tests to fixture testing (#6475) ([cc4646a](https://github.com/swc-project/swc/commit/cc4646a4cc455c08680f7dedb344337f90f0c668))- **general**: Use correct extensions for fixture tests (#6539) ([7ee86d1](https://github.com/swc-project/swc/commit/7ee86d1d2579d861501a525cbc6ddd3669d4c25c)) +### Build + + + +- **(cargo)** Update `browerslist-rs` (#6547) ([d730186](https://github.com/swc-project/swc/commit/d730186e9f49b9481b89b35121d7095e05781565)) + ## [1.3.20] - 2022-11-26 ### Bug Fixes diff --git a/Cargo.lock b/Cargo.lock index 4f4b99fb95c8..74696edd1a78 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -177,7 +177,7 @@ dependencies = [ [[package]] name = "binding_macros" -version = "0.20.122" +version = "0.20.123" dependencies = [ "anyhow", "console_error_panic_hook", @@ -2234,7 +2234,7 @@ checksum = "925383efa346730478fb4838dbe9137d2a47675ad789c546d150a6e1dd4ab31c" [[package]] name = "preset_env_base" -version = "0.3.2" +version = "0.3.3" dependencies = [ "ahash", "anyhow", @@ -3081,7 +3081,7 @@ dependencies = [ [[package]] name = "swc" -version = "0.232.119" +version = "0.232.120" dependencies = [ "ahash", "ansi_term", @@ -3267,7 +3267,7 @@ dependencies = [ [[package]] name = "swc_core" -version = "0.43.40" +version = "0.43.41" dependencies = [ "anyhow", "binding_macros", @@ -3318,7 +3318,7 @@ dependencies = [ [[package]] name = "swc_css" -version = "0.140.6" +version = "0.140.7" dependencies = [ "swc_css_ast", "swc_css_codegen", @@ -3462,7 +3462,7 @@ dependencies = [ [[package]] name = "swc_css_prefixer" -version = "0.138.6" +version = "0.138.7" dependencies = [ "once_cell", "preset_env_base", @@ -3694,7 +3694,7 @@ dependencies = [ [[package]] name = "swc_ecma_preset_env" -version = "0.174.65" +version = "0.174.66" dependencies = [ "ahash", "anyhow", @@ -4051,7 +4051,7 @@ dependencies = [ [[package]] name = "swc_ecmascript" -version = "0.205.106" +version = "0.205.107" dependencies = [ "swc_ecma_ast", "swc_ecma_codegen", @@ -4099,7 +4099,7 @@ dependencies = [ [[package]] name = "swc_estree_compat" -version = "0.154.119" +version = "0.154.120" dependencies = [ "ahash", "anyhow", @@ -4285,7 +4285,7 @@ dependencies = [ [[package]] name = "swc_node_bundler" -version = "0.18.119" +version = "0.18.120" dependencies = [ "anyhow", "dashmap", diff --git a/crates/binding_macros/Cargo.toml b/crates/binding_macros/Cargo.toml index a5200b92e56a..07516027d43e 100644 --- a/crates/binding_macros/Cargo.toml +++ b/crates/binding_macros/Cargo.toml @@ -5,7 +5,7 @@ edition = "2021" license = "Apache-2.0" name = "binding_macros" repository = "https://github.com/swc-project/swc.git" -version = "0.20.122" +version = "0.20.123" [lib] bench = false @@ -33,7 +33,7 @@ binding_wasm = [ [dependencies] # Common deps for the SWC imports -swc = { optional = true, version = "0.232.119", path = "../swc" } +swc = { optional = true, version = "0.232.120", path = "../swc" } swc_common = { optional = true, version = "0.29.16", path = "../swc_common" } swc_ecma_ast = { optional = true, version = "0.94.21", path = "../swc_ecma_ast" } swc_ecma_transforms = { optional = true, version = "0.198.64", path = "../swc_ecma_transforms" } diff --git a/crates/preset_env_base/Cargo.toml b/crates/preset_env_base/Cargo.toml index a9b79ed0d626..4ecec48baf79 100644 --- a/crates/preset_env_base/Cargo.toml +++ b/crates/preset_env_base/Cargo.toml @@ -5,7 +5,7 @@ documentation = "https://rustdoc.swc.rs/preset_env_base/" edition = "2021" license = "Apache-2.0" name = "preset_env_base" -version = "0.3.2" +version = "0.3.3" [lib] bench = false diff --git a/crates/swc/Cargo.toml b/crates/swc/Cargo.toml index 89fe2935481a..8689b7a19939 100644 --- a/crates/swc/Cargo.toml +++ b/crates/swc/Cargo.toml @@ -9,7 +9,7 @@ include = ["Cargo.toml", "src/**/*.rs"] license = "Apache-2.0" name = "swc" repository = "https://github.com/swc-project/swc.git" -version = "0.232.119" +version = "0.232.120" [lib] bench = false @@ -77,7 +77,7 @@ swc_ecma_loader = { version = "0.41.17", path = "../swc_ecma_loader", features = ] } swc_ecma_minifier = { version = "0.159.104", path = "../swc_ecma_minifier" } swc_ecma_parser = { version = "0.122.32", path = "../swc_ecma_parser" } -swc_ecma_preset_env = { version = "0.174.65", path = "../swc_ecma_preset_env" } +swc_ecma_preset_env = { version = "0.174.66", path = "../swc_ecma_preset_env" } swc_ecma_transforms = { version = "0.198.64", path = "../swc_ecma_transforms", features = [ "compat", "module", diff --git a/crates/swc_core/Cargo.toml b/crates/swc_core/Cargo.toml index f2508f16d65a..4aee6ad92d4f 100644 --- a/crates/swc_core/Cargo.toml +++ b/crates/swc_core/Cargo.toml @@ -6,7 +6,7 @@ edition = "2021" license = "Apache-2.0" name = "swc_core" repository = "https://github.com/swc-project/swc.git" -version = "0.43.40" +version = "0.43.41" [package.metadata.docs.rs] features = [ "common_perf", @@ -318,8 +318,8 @@ wasmer = { optional = true, version = "2.3.0", default-features = false } wasmer-wasi = { optional = true, version = "2.3.0", default-features = false } # swc_* dependencies -binding_macros = { optional = true, version = "0.20.122", path = "../binding_macros" } -swc = { optional = true, version = "0.232.119", path = "../swc" } +binding_macros = { optional = true, version = "0.20.123", path = "../binding_macros" } +swc = { optional = true, version = "0.232.120", path = "../swc" } swc_atoms = { optional = true, version = "0.4.25", path = "../swc_atoms" } swc_bundler = { optional = true, version = "0.192.104", path = "../swc_bundler" } swc_cached = { optional = true, version = "0.3.15", path = "../swc_cached" } @@ -329,7 +329,7 @@ swc_css_codegen = { optional = true, version = "0.137.6", path swc_css_minifier = { optional = true, version = "0.102.6", path = "../swc_css_minifier" } swc_css_modules = { optional = true, version = "0.13.6", path = "../swc_css_modules" } swc_css_parser = { optional = true, version = "0.136.6", path = "../swc_css_parser" } -swc_css_prefixer = { optional = true, version = "0.138.6", path = "../swc_css_prefixer" } +swc_css_prefixer = { optional = true, version = "0.138.7", path = "../swc_css_prefixer" } swc_css_utils = { optional = true, version = "0.124.3", path = "../swc_css_utils/" } swc_css_visit = { optional = true, version = "0.126.3", path = "../swc_css_visit" } swc_ecma_ast = { optional = true, version = "0.94.21", path = "../swc_ecma_ast" } @@ -337,7 +337,7 @@ swc_ecma_codegen = { optional = true, version = "0.127.39", path swc_ecma_loader = { optional = true, version = "0.41.17", path = "../swc_ecma_loader" } swc_ecma_minifier = { optional = true, version = "0.159.104", path = "../swc_ecma_minifier" } swc_ecma_parser = { optional = true, version = "0.122.32", path = "../swc_ecma_parser" } -swc_ecma_preset_env = { optional = true, version = "0.174.65", path = "../swc_ecma_preset_env" } +swc_ecma_preset_env = { optional = true, version = "0.174.66", path = "../swc_ecma_preset_env" } swc_ecma_quote_macros = { optional = true, version = "0.33.33", path = "../swc_ecma_quote_macros" } swc_ecma_transforms_base = { optional = true, version = "0.111.59", path = "../swc_ecma_transforms_base" } swc_ecma_transforms_module = { optional = true, version = "0.153.56", path = "../swc_ecma_transforms_module" } @@ -349,7 +349,7 @@ swc_ecma_transforms_typescript = { optional = true, version = "0.159.59", path swc_ecma_utils = { optional = true, version = "0.105.40", path = "../swc_ecma_utils" } swc_ecma_visit = { optional = true, version = "0.80.21", path = "../swc_ecma_visit" } swc_node_base = { optional = true, version = "0.5.8", path = "../swc_node_base" } -swc_node_bundler = { optional = true, version = "0.18.119", path = "../swc_node_bundler" } +swc_node_bundler = { optional = true, version = "0.18.120", path = "../swc_node_bundler" } swc_nodejs_common = { optional = true, version = "0.0.4", path = "../swc_nodejs_common" } swc_plugin = { optional = true, version = "0.90.0", path = "../swc_plugin" } swc_plugin_macro = { optional = true, version = "0.9.9", path = "../swc_plugin_macro" } diff --git a/crates/swc_css/Cargo.toml b/crates/swc_css/Cargo.toml index e7c0556f2ed4..8a1a986a8c61 100644 --- a/crates/swc_css/Cargo.toml +++ b/crates/swc_css/Cargo.toml @@ -6,7 +6,7 @@ edition = "2021" license = "Apache-2.0" name = "swc_css" repository = "https://github.com/swc-project/swc.git" -version = "0.140.6" +version = "0.140.7" [package.metadata.docs.rs] all-features = true @@ -28,6 +28,6 @@ swc_css_compat = {version = "0.12.6", path = "../swc_css_compat", optional = tru swc_css_minifier = {version = "0.102.6", path = "../swc_css_minifier", optional = true} swc_css_modules = {version = "0.13.6", path = "../swc_css_modules", optional = true} swc_css_parser = {version = "0.136.6", path = "../swc_css_parser"} -swc_css_prefixer = {version = "0.138.6", path = "../swc_css_prefixer", optional = true} +swc_css_prefixer = {version = "0.138.7", path = "../swc_css_prefixer", optional = true} swc_css_utils = {version = "0.124.3", path = "../swc_css_utils/"} swc_css_visit = {version = "0.126.3", path = "../swc_css_visit"} diff --git a/crates/swc_css_prefixer/Cargo.toml b/crates/swc_css_prefixer/Cargo.toml index dfde60b9dbd6..4663c537397b 100644 --- a/crates/swc_css_prefixer/Cargo.toml +++ b/crates/swc_css_prefixer/Cargo.toml @@ -7,14 +7,14 @@ include = ["Cargo.toml", "src/**/*.rs", "src/**/*.json", "data/**/*.json"] license = "Apache-2.0" name = "swc_css_prefixer" repository = "https://github.com/swc-project/swc.git" -version = "0.138.6" +version = "0.138.7" [lib] bench = false [dependencies] once_cell = "1.10.0" -preset_env_base = {version = "0.3.2", path = "../preset_env_base"} +preset_env_base = {version = "0.3.3", path = "../preset_env_base"} serde = {version = "1.0.118", features = ["derive"]} serde_json = "1.0.61" swc_atoms = {version = "0.4.25", path = "../swc_atoms"} diff --git a/crates/swc_ecma_preset_env/Cargo.toml b/crates/swc_ecma_preset_env/Cargo.toml index 7d30afe90469..c42a6627940d 100644 --- a/crates/swc_ecma_preset_env/Cargo.toml +++ b/crates/swc_ecma_preset_env/Cargo.toml @@ -6,7 +6,7 @@ edition = "2021" include = ["Cargo.toml", "src/**/*.rs", "src/**/*.json", "data/**/*.json"] license = "Apache-2.0" name = "swc_ecma_preset_env" -version = "0.174.65" +version = "0.174.66" [lib] bench = false @@ -17,7 +17,7 @@ anyhow = "1" dashmap = "5.1.0" indexmap = "1.6.1" once_cell = "1.10.0" -preset_env_base = { version = "0.3.2", path = "../preset_env_base" } +preset_env_base = { version = "0.3.3", path = "../preset_env_base" } semver = { version = "1.0.4", features = ["serde"] } serde = { version = "1", features = ["derive"] } serde_json = "1" diff --git a/crates/swc_ecmascript/Cargo.toml b/crates/swc_ecmascript/Cargo.toml index b9052ce0c65d..a33f022b7d20 100644 --- a/crates/swc_ecmascript/Cargo.toml +++ b/crates/swc_ecmascript/Cargo.toml @@ -6,7 +6,7 @@ edition = "2021" license = "Apache-2.0" name = "swc_ecmascript" repository = "https://github.com/swc-project/swc.git" -version = "0.205.106" +version = "0.205.107" [package.metadata.docs.rs] all-features = true @@ -44,7 +44,7 @@ swc_ecma_codegen = { version = "0.127.39", path = "../swc_ecma_codegen", opti swc_ecma_dep_graph = { version = "0.94.32", path = "../swc_ecma_dep_graph", optional = true } swc_ecma_minifier = { version = "0.159.104", path = "../swc_ecma_minifier", optional = true } swc_ecma_parser = { version = "0.122.32", path = "../swc_ecma_parser", optional = true, default-features = false } -swc_ecma_preset_env = { version = "0.174.65", path = "../swc_ecma_preset_env", optional = true } +swc_ecma_preset_env = { version = "0.174.66", path = "../swc_ecma_preset_env", optional = true } swc_ecma_quote = { version = "0.38.35", path = "../swc_ecma_quote", optional = true } swc_ecma_transforms = { version = "0.198.64", path = "../swc_ecma_transforms", optional = true } swc_ecma_utils = { version = "0.105.40", path = "../swc_ecma_utils", optional = true } diff --git a/crates/swc_estree_compat/Cargo.toml b/crates/swc_estree_compat/Cargo.toml index c03c4bff6487..3f8573e83d83 100644 --- a/crates/swc_estree_compat/Cargo.toml +++ b/crates/swc_estree_compat/Cargo.toml @@ -7,7 +7,7 @@ include = ["Cargo.toml", "src/**/*.rs"] license = "Apache-2.0" name = "swc_estree_compat" repository = "https://github.com/swc-project/swc.git" -version = "0.154.119" +version = "0.154.120" [package.metadata.docs.rs] all-features = true @@ -38,7 +38,7 @@ swc_node_comments = { version = "0.16.16", path = "../swc_node_comments/" } [dev-dependencies] criterion = "0.3" pretty_assertions = "1.1" -swc = { version = "0.232.119", path = "../swc" } +swc = { version = "0.232.120", path = "../swc" } swc_ecma_ast = { version = "0.94.21", path = "../swc_ecma_ast" } swc_ecma_parser = { version = "0.122.32", path = "../swc_ecma_parser" } swc_ecma_transforms = { version = "0.198.64", path = "../swc_ecma_transforms/" } diff --git a/crates/swc_node_bundler/Cargo.toml b/crates/swc_node_bundler/Cargo.toml index a5c47b09e2a0..4a9d088159e4 100644 --- a/crates/swc_node_bundler/Cargo.toml +++ b/crates/swc_node_bundler/Cargo.toml @@ -7,7 +7,7 @@ edition = "2021" license = "Apache-2.0" name = "swc_node_bundler" repository = "https://github.com/swc-project/swc.git" -version = "0.18.119" +version = "0.18.120" [lib] bench = false @@ -26,7 +26,7 @@ regex = "1" serde = { version = "1", features = ["derive"] } serde_json = "1" string_enum = { version = "0.3.2", path = "../string_enum" } -swc = { version = "0.232.119", path = "../swc" } +swc = { version = "0.232.120", path = "../swc" } swc_atoms = { version = "0.4.25", path = "../swc_atoms" } swc_bundler = { version = "0.192.104", path = "../swc_bundler", features = [ "concurrent",