Skip to content

Commit 8a85193

Browse files
chore: update less and less-loader (#20689)
1 parent 70867d6 commit 8a85193

7 files changed

Lines changed: 31 additions & 28 deletions

File tree

.github/workflows/test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,7 @@ jobs:
262262

263263
# Install old `jest` version and deps for legacy node versions
264264
- run: |
265-
yarn upgrade jest@^27.5.0 jest-circus@^27.5.0 jest-cli@^27.5.0 jest-diff@^27.5.0 jest-environment-node@^27.5.0 jest-snapshot@^27.5.0 jest-junit@^13.0.0 @types/jest@^27.4.0 pretty-format@^27.0.2 husky@^8.0.3 lint-staged@^13.2.1 cspell@^6.31.1 open-cli@^7.2.0 coffee-loader@^1.0.0 babel-loader@^8.1.0 style-loader@^2.0.0 css-loader@^5.0.1 less-loader@^8.1.1 mini-css-extract-plugin@^1.6.1 nyc@^15.1.0 [email protected] --ignore-engines
265+
yarn upgrade jest@^27.5.0 jest-circus@^27.5.0 jest-cli@^27.5.0 jest-diff@^27.5.0 jest-environment-node@^27.5.0 jest-snapshot@^27.5.0 jest-junit@^13.0.0 @types/jest@^27.4.0 pretty-format@^27.0.2 husky@^8.0.3 lint-staged@^13.2.1 cspell@^6.31.1 open-cli@^7.2.0 coffee-loader@^1.0.0 babel-loader@^8.1.0 style-loader@^2.0.0 css-loader@^5.0.1 less-loader@^8.1.1 [email protected] mini-css-extract-plugin@^1.6.1 nyc@^15.1.0 [email protected] --ignore-engines
266266
yarn --frozen-lockfile --ignore-engines
267267
if: matrix.node-version == '10.x' || matrix.node-version == '12.x' || matrix.node-version == '14.x'
268268

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -155,8 +155,8 @@
155155
"jest-junit": "^16.0.0",
156156
"json-loader": "^0.5.7",
157157
"json5": "^2.1.3",
158-
"less": "^4.5.1",
159-
"less-loader": "^12.2.0",
158+
"less": "^4.6.4",
159+
"less-loader": "^12.3.2",
160160
"lint-staged": "^16.2.3",
161161
"lodash": "^4.17.19",
162162
"lodash-es": "^4.17.15",

test/configCases/css/import/__snapshots__/ConfigCacheTest.snap

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ p {
133133
.link {
134134
color: #428bca;
135135
}
136-
/*# sourceMappingURL=file.css.map */
136+
137137
/*!**********************************!*\\\\
138138
!*** css ./with-less-import.css ***!
139139
\\\\**********************************/
@@ -183,7 +183,7 @@ p {
183183
.conditional-names {
184184
color: #428bca;
185185
}
186-
/*# sourceMappingURL=default.css.map */
186+
187187
/*!**********************************************************************!*\\\\
188188
!*** css ./node_modules/condition-names-custom-name/custom-name.css ***!
189189
\\\\**********************************************************************/

test/configCases/css/import/__snapshots__/ConfigTest.snap

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ p {
133133
.link {
134134
color: #428bca;
135135
}
136-
/*# sourceMappingURL=file.css.map */
136+
137137
/*!**********************************!*\\\\
138138
!*** css ./with-less-import.css ***!
139139
\\\\**********************************/
@@ -183,7 +183,7 @@ p {
183183
.conditional-names {
184184
color: #428bca;
185185
}
186-
/*# sourceMappingURL=default.css.map */
186+
187187
/*!**********************************************************************!*\\\\
188188
!*** css ./node_modules/condition-names-custom-name/custom-name.css ***!
189189
\\\\**********************************************************************/
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
/** @type {import("../../../../").LoaderDefinition} */
2+
module.exports = function loader(content) {
3+
return content.replace(/\/[*/][#]?\s*sourceMappingURL=.+(\*\/)?/g, "");
4+
};

test/configCases/css/import/webpack.config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ module.exports = [
3030
},
3131
{
3232
test: /\.less$/,
33-
loader: "less-loader",
33+
use: ["./remove-source-map-url-loader", "less-loader"],
3434
type: "css/global"
3535
}
3636
]

yarn.lock

Lines changed: 19 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -3561,12 +3561,12 @@ convert-source-map@^2.0.0:
35613561
resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-2.0.0.tgz#4b560f649fc4e918dd0ab75cf4961e8bc882d82a"
35623562
integrity sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==
35633563

3564-
copy-anything@^2.0.1:
3565-
version "2.0.6"
3566-
resolved "https://registry.yarnpkg.com/copy-anything/-/copy-anything-2.0.6.tgz#092454ea9584a7b7ad5573062b2a87f5900fc480"
3567-
integrity sha512-1j20GZTsvKNkc4BY3NpMOM8tt///wY3FpIzozTOFO2ffuZcV61nojHXVKIy3WM+7ADCy5FVhdZYHYDdgTU0yJw==
3564+
copy-anything@^3.0.5:
3565+
version "3.0.5"
3566+
resolved "https://registry.yarnpkg.com/copy-anything/-/copy-anything-3.0.5.tgz#2d92dce8c498f790fa7ad16b01a1ae5a45b020a0"
3567+
integrity sha512-yCEafptTtb4bk7GLEQoM8KVJpxAfdBJYaXyzQEgQQQgYrZiDp8SJmGKlYza6CYjEDNstAdNdKA3UuoULlEbS6w==
35683568
dependencies:
3569-
is-what "^3.14.1"
3569+
is-what "^4.1.8"
35703570

35713571
core-js-compat@^3.46.0:
35723572
version "3.46.0"
@@ -5826,10 +5826,10 @@ is-weakset@^2.0.3:
58265826
call-bound "^1.0.3"
58275827
get-intrinsic "^1.2.6"
58285828

5829-
is-what@^3.14.1:
5830-
version "3.14.1"
5831-
resolved "https://registry.yarnpkg.com/is-what/-/is-what-3.14.1.tgz#e1222f46ddda85dead0fd1c9df131760e77755c1"
5832-
integrity sha512-sNxgpk9793nzSs7bA6JQJGeIuRBQhAaNGG77kzYQgMkrID+lS6SlK07K5LaptscDlSaIgH+GPFzf+d75FVxozA==
5829+
is-what@^4.1.8:
5830+
version "4.1.16"
5831+
resolved "https://registry.yarnpkg.com/is-what/-/is-what-4.1.16.tgz#1ad860a19da8b4895ad5495da3182ce2acdd7a6f"
5832+
integrity sha512-ZhMwEosbFJkA0YhFnNDgTM4ZxDRsS6HqTo7qsZM08fehyRYIYa0yHu5R6mgo1n/8MgaPBXiPimPD77baVFYg+A==
58335833

58345834
is-windows@^1.0.0, is-windows@^1.0.2:
58355835
version "1.0.2"
@@ -6569,19 +6569,18 @@ kind-of@^6.0.2:
65696569
resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-6.0.3.tgz#07c05034a6c349fa06e24fa35aa76db4580ce4dd"
65706570
integrity sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw==
65716571

6572-
less-loader@^12.2.0:
6573-
version "12.3.1"
6574-
resolved "https://registry.yarnpkg.com/less-loader/-/less-loader-12.3.1.tgz#4b80179507d522fa3082c19a09d08e50b9495ac3"
6575-
integrity sha512-JZZmG7gMzoDP3VGeEG8Sh6FW5wygB5jYL7Wp29FFihuRTsIBacqO3LbRPr2yStYD11riVf13selLm/CPFRDBRQ==
6572+
less-loader@^12.3.2:
6573+
version "12.3.2"
6574+
resolved "https://registry.yarnpkg.com/less-loader/-/less-loader-12.3.2.tgz#88dac1736b4f2e3f76db9b1617c1398ae91cd4bb"
6575+
integrity sha512-uLV5c702ff2jBvO7qewpkLRzkh/I9QW07ur2NKkv8TVTrtX2lrKjEbEU/LLXAn7cgpCIBbkfyUm4qYXCQs5/+w==
65766576

6577-
less@^4.5.1:
6578-
version "4.5.1"
6579-
resolved "https://registry.yarnpkg.com/less/-/less-4.5.1.tgz#739266532249a3de232e8b60ffb1b27ad5ec6ad8"
6580-
integrity sha512-UKgI3/KON4u6ngSsnDADsUERqhZknsVZbnuzlRZXLQCmfC/MDld42fTydUE9B+Mla1AL6SJ/Pp6SlEFi/AVGfw==
6577+
less@^4.6.4:
6578+
version "4.6.4"
6579+
resolved "https://registry.yarnpkg.com/less/-/less-4.6.4.tgz#3ff8068e6c8a59f1ece8a6b9227bda28c1ed68a2"
6580+
integrity sha512-OJmO5+HxZLLw0RLzkqaNHzcgEAQG7C0y3aMbwtCzIUFZsLMNNq/1IdAdHEycQ58CwUO3jPTHmoN+tE5I7FQxNg==
65816581
dependencies:
6582-
copy-anything "^2.0.1"
6582+
copy-anything "^3.0.5"
65836583
parse-node-version "^1.0.1"
6584-
tslib "^2.3.0"
65856584
optionalDependencies:
65866585
errno "^0.1.1"
65876586
graceful-fs "^4.1.2"
@@ -9516,7 +9515,7 @@ tsconfig-paths@^3.15.0:
95169515
minimist "^1.2.6"
95179516
strip-bom "^3.0.0"
95189517

9519-
tslib@^2.0.0, tslib@^2.0.3, tslib@^2.3.0, tslib@^2.4.0:
9518+
tslib@^2.0.0, tslib@^2.0.3, tslib@^2.4.0:
95209519
version "2.8.1"
95219520
resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.8.1.tgz#612efe4ed235d567e8aba5f2a5fab70280ade83f"
95229521
integrity sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==

0 commit comments

Comments
 (0)