Skip to content

Commit d6093b4

Browse files
committed
chore(deps): upgrade
1 parent 86c4e0c commit d6093b4

File tree

18 files changed

+1566
-657
lines changed

18 files changed

+1566
-657
lines changed

package.json

+8-8
Original file line numberDiff line numberDiff line change
@@ -25,29 +25,29 @@
2525
"@tailwindcss-mangle/shared": "workspace:*",
2626
"@tsconfig/recommended": "^1.0.3",
2727
"@types/lodash-es": "^4.17.12",
28-
"@types/node": "^20.10.5",
29-
"@vitest/coverage-v8": "^1.1.0",
30-
"bumpp": "^9.2.1",
28+
"@types/node": "^20.11.5",
29+
"@vitest/coverage-v8": "^1.2.0",
30+
"bumpp": "^9.3.0",
3131
"cross-env": "^7.0.3",
3232
"dedent": "^1.5.1",
33-
"defu": "^6.1.3",
33+
"defu": "^6.1.4",
3434
"del": "^7.1.0",
3535
"eslint": "^8.56.0",
3636
"eslint-config-icebreaker": "^1.2.3",
3737
"eslint-config-prettier": "^9.1.0",
38-
"eslint-plugin-prettier": "^5.1.0",
38+
"eslint-plugin-prettier": "^5.1.3",
3939
"lodash-es": "^4.17.21",
4040
"only-allow": "^1.2.1",
41-
"prettier": "^3.1.1",
42-
"rollup": "^4.9.1",
41+
"prettier": "^3.2.3",
42+
"rollup": "^4.9.5",
4343
"tailwindcss-patch": "workspace:*",
4444
"ts-node": "^10.9.2",
4545
"tslib": "^2.6.2",
4646
"tsup": "^8.0.1",
4747
"typescript": "^5.3.3",
4848
"unbuild": "^2.0.0",
4949
"unplugin-tailwindcss-mangle": "workspace:*",
50-
"vitest": "^1.1.0"
50+
"vitest": "^1.2.0"
5151
},
5252
"engines": {
5353
"node": ">=16.6.0"

packages/config/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@
4646
},
4747
"dependencies": {
4848
"@tailwindcss-mangle/shared": "workspace:^",
49-
"c12": "^1.5.1",
49+
"c12": "^1.6.1",
5050
"dedent": "^1.5.1"
5151
},
5252
"homepage": "https://github.com/sonofmagic/tailwindcss-mangle",

packages/core/package.json

+6-6
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
},
4545
"dependencies": {
4646
"@ast-core/escape": "^1.0.1",
47-
"@babel/core": "^7.23.6",
47+
"@babel/core": "^7.23.7",
4848
"@babel/helper-plugin-utils": "^7.22.5",
4949
"@babel/preset-typescript": "^7.23.3",
5050
"@babel/types": "^7.23.6",
@@ -54,15 +54,15 @@
5454
"magic-string": "^0.30.5",
5555
"micromatch": "^4.0.5",
5656
"parse5": "^7.1.2",
57-
"postcss": "^8.4.32",
58-
"postcss-selector-parser": "^6.0.13"
57+
"postcss": "^8.4.33",
58+
"postcss-selector-parser": "^6.0.15"
5959
},
6060
"devDependencies": {
61-
"@parse5/tools": "^0.3.0",
61+
"@parse5/tools": "^0.4.0",
6262
"@types/babel__core": "^7.20.5",
6363
"@types/micromatch": "^4.0.6",
64-
"@vue/compiler-core": "^3.3.13",
65-
"@vue/compiler-sfc": "^3.3.13"
64+
"@vue/compiler-core": "^3.4.14",
65+
"@vue/compiler-sfc": "^3.4.14"
6666
},
6767
"homepage": "https://github.com/sonofmagic/tailwindcss-mangle",
6868
"repository": {

packages/tailwindcss-patch/package.json

+4-4
Original file line numberDiff line numberDiff line change
@@ -41,22 +41,22 @@
4141
},
4242
"devDependencies": {
4343
"@types/babel__generator": "^7.6.8",
44-
"@types/babel__traverse": "^7.20.4",
44+
"@types/babel__traverse": "^7.20.5",
4545
"@types/resolve": "^1.20.6",
4646
"@types/semver": "^7.5.6",
4747
"pkg-types": "^1.0.3",
48-
"tailwindcss": "^3.4.0"
48+
"tailwindcss": "^3.4.1"
4949
},
5050
"dependencies": {
5151
"@babel/generator": "^7.23.6",
5252
"@babel/parser": "^7.23.6",
53-
"@babel/traverse": "^7.23.6",
53+
"@babel/traverse": "^7.23.7",
5454
"@babel/types": "^7.23.6",
5555
"@tailwindcss-mangle/config": "workspace:^",
5656
"cac": "^6.7.14",
5757
"jiti": "^1.21.0",
5858
"lilconfig": "^3.0.0",
59-
"postcss": "^8.4.32",
59+
"postcss": "^8.4.33",
6060
"resolve": "^1.22.8",
6161
"semver": "^7.5.4"
6262
},

packages/tailwindcss-patch/test/__snapshots__/index.test.ts.snap

+163
Original file line numberDiff line numberDiff line change
@@ -2527,3 +2527,166 @@ function processTailwindFeatures(setupContext) {
25272527
}",
25282528
}
25292529
`;
2530+
2531+
exports[`versions-patch > patch tailwindcss3.4.1 1`] = `
2532+
{
2533+
"plugin": ""use strict";
2534+
2535+
Object.defineProperty(exports, "__esModule", {
2536+
value: true
2537+
});
2538+
const _setupTrackingContext = /*#__PURE__*/_interop_require_default(require("./lib/setupTrackingContext"));
2539+
const _processTailwindFeatures = /*#__PURE__*/_interop_require_default(require("./processTailwindFeatures"));
2540+
const _sharedState = require("./lib/sharedState");
2541+
const _findAtConfigPath = require("./lib/findAtConfigPath");
2542+
function _interop_require_default(obj) {
2543+
return obj && obj.__esModule ? obj : {
2544+
default: obj
2545+
};
2546+
}
2547+
const contextRef = {
2548+
value: []
2549+
};
2550+
module.exports = function tailwindcss(configOrPath) {
2551+
return {
2552+
postcssPlugin: "tailwindcss",
2553+
plugins: [_sharedState.env.DEBUG && function (root) {
2554+
console.log("\\n");
2555+
console.time("JIT TOTAL");
2556+
return root;
2557+
}, async function (root, result) {
2558+
contextRef.value.length = 0;
2559+
var _findAtConfigPath1;
2560+
// Use the path for the \`@config\` directive if it exists, otherwise use the
2561+
// path for the file being processed
2562+
configOrPath = (_findAtConfigPath1 = (0, _findAtConfigPath.findAtConfigPath)(root, result)) !== null && _findAtConfigPath1 !== void 0 ? _findAtConfigPath1 : configOrPath;
2563+
let context = (0, _setupTrackingContext.default)(configOrPath);
2564+
if (root.type === "document") {
2565+
let roots = root.nodes.filter(node => node.type === "root");
2566+
for (const root of roots) {
2567+
if (root.type === "root") {
2568+
contextRef.value.push(await (0, _processTailwindFeatures.default)(context)(root, result));
2569+
}
2570+
}
2571+
return;
2572+
}
2573+
contextRef.value.push(await (0, _processTailwindFeatures.default)(context)(root, result));
2574+
}, false && function lightningCssPlugin(_root, result) {
2575+
let postcss = require("postcss");
2576+
let lightningcss = require("lightningcss");
2577+
let browserslist = require("browserslist");
2578+
try {
2579+
let transformed = lightningcss.transform({
2580+
filename: result.opts.from,
2581+
code: Buffer.from(result.root.toString()),
2582+
minify: false,
2583+
sourceMap: !!result.map,
2584+
inputSourceMap: result.map ? result.map.toString() : undefined,
2585+
targets: typeof process !== "undefined" && process.env.JEST_WORKER_ID ? {
2586+
chrome: 106 << 16
2587+
} : lightningcss.browserslistToTargets(browserslist(require("../package.json").browserslist)),
2588+
drafts: {
2589+
nesting: true,
2590+
customMedia: true
2591+
}
2592+
});
2593+
var _result_map;
2594+
result.map = Object.assign((_result_map = result.map) !== null && _result_map !== void 0 ? _result_map : {}, {
2595+
toJSON() {
2596+
return transformed.map.toJSON();
2597+
},
2598+
toString() {
2599+
return transformed.map.toString();
2600+
}
2601+
});
2602+
result.root = postcss.parse(transformed.code.toString("utf8"));
2603+
} catch (err) {
2604+
if (typeof process !== "undefined" && process.env.JEST_WORKER_ID) {
2605+
let lines = err.source.split("\\n");
2606+
err = new Error(["Error formatting using Lightning CSS:", "", ...["\`\`\`css", ...lines.slice(Math.max(err.loc.line - 3, 0), err.loc.line), " ".repeat(err.loc.column - 1) + "^-- " + err.toString(), ...lines.slice(err.loc.line, err.loc.line + 2), "\`\`\`"]].join("\\n"));
2607+
}
2608+
if (Error.captureStackTrace) {
2609+
Error.captureStackTrace(err, lightningCssPlugin);
2610+
}
2611+
throw err;
2612+
}
2613+
}, _sharedState.env.DEBUG && function (root) {
2614+
console.timeEnd("JIT TOTAL");
2615+
console.log("\\n");
2616+
return root;
2617+
}].filter(Boolean)
2618+
};
2619+
};
2620+
module.exports.postcss = true;
2621+
module.exports.contextRef = contextRef;",
2622+
"processTailwindFeatures": ""use strict";
2623+
2624+
Object.defineProperty(exports, "__esModule", {
2625+
value: true
2626+
});
2627+
Object.defineProperty(exports, "default", {
2628+
enumerable: true,
2629+
get: function () {
2630+
return processTailwindFeatures;
2631+
}
2632+
});
2633+
const _normalizeTailwindDirectives = /*#__PURE__*/_interop_require_default(require("./lib/normalizeTailwindDirectives"));
2634+
const _expandTailwindAtRules = /*#__PURE__*/_interop_require_default(require("./lib/expandTailwindAtRules"));
2635+
const _expandApplyAtRules = /*#__PURE__*/_interop_require_default(require("./lib/expandApplyAtRules"));
2636+
const _evaluateTailwindFunctions = /*#__PURE__*/_interop_require_default(require("./lib/evaluateTailwindFunctions"));
2637+
const _substituteScreenAtRules = /*#__PURE__*/_interop_require_default(require("./lib/substituteScreenAtRules"));
2638+
const _resolveDefaultsAtRules = /*#__PURE__*/_interop_require_default(require("./lib/resolveDefaultsAtRules"));
2639+
const _collapseAdjacentRules = /*#__PURE__*/_interop_require_default(require("./lib/collapseAdjacentRules"));
2640+
const _collapseDuplicateDeclarations = /*#__PURE__*/_interop_require_default(require("./lib/collapseDuplicateDeclarations"));
2641+
const _partitionApplyAtRules = /*#__PURE__*/_interop_require_default(require("./lib/partitionApplyAtRules"));
2642+
const _detectNesting = /*#__PURE__*/_interop_require_default(require("./lib/detectNesting"));
2643+
const _setupContextUtils = require("./lib/setupContextUtils");
2644+
const _featureFlags = require("./featureFlags");
2645+
function _interop_require_default(obj) {
2646+
return obj && obj.__esModule ? obj : {
2647+
default: obj
2648+
};
2649+
}
2650+
function processTailwindFeatures(setupContext) {
2651+
return async function (root, result) {
2652+
let {
2653+
tailwindDirectives,
2654+
applyDirectives
2655+
} = (0, _normalizeTailwindDirectives.default)(root);
2656+
(0, _detectNesting.default)()(root, result);
2657+
// Partition apply rules that are found in the css
2658+
// itself.
2659+
(0, _partitionApplyAtRules.default)()(root, result);
2660+
let context = setupContext({
2661+
tailwindDirectives,
2662+
applyDirectives,
2663+
registerDependency(dependency) {
2664+
result.messages.push({
2665+
plugin: "tailwindcss",
2666+
parent: result.opts.from,
2667+
...dependency
2668+
});
2669+
},
2670+
createContext(tailwindConfig, changedContent) {
2671+
return (0, _setupContextUtils.createContext)(tailwindConfig, changedContent, root);
2672+
}
2673+
})(root, result);
2674+
if (context.tailwindConfig.separator === "-") {
2675+
throw new Error("The '-' character cannot be used as a custom separator in JIT mode due to parsing ambiguity. Please use another character like '_' instead.");
2676+
}
2677+
(0, _featureFlags.issueFlagNotices)(context.tailwindConfig);
2678+
await (0, _expandTailwindAtRules.default)(context)(root, result);
2679+
// Partition apply rules that are generated by
2680+
// addComponents, addUtilities and so on.
2681+
(0, _partitionApplyAtRules.default)()(root, result);
2682+
(0, _expandApplyAtRules.default)(context)(root, result);
2683+
(0, _evaluateTailwindFunctions.default)(context)(root, result);
2684+
(0, _substituteScreenAtRules.default)(context)(root, result);
2685+
(0, _resolveDefaultsAtRules.default)(context)(root, result);
2686+
(0, _collapseAdjacentRules.default)(context)(root, result);
2687+
(0, _collapseDuplicateDeclarations.default)(context)(root, result);
2688+
return context;
2689+
};
2690+
}",
2691+
}
2692+
`;

packages/tailwindcss-patch/test/__snapshots__/postcss.test.ts.snap

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
exports[`postcss > getCss 0.common 1`] = `
44
"/*
5-
! tailwindcss v3.4.0 | MIT License | https://tailwindcss.com
5+
! tailwindcss v3.4.1 | MIT License | https://tailwindcss.com
66
*//*
77
1. Prevent padding and border from affecting element width. (https://github.com/mozdevs/cssremedy/issues/4)
88
2. Allow adding a border to an element by just adding a border-width. (https://github.com/tailwindcss/tailwindcss/pull/116)
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
"use strict";
2+
module.exports = require("./plugin");
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,98 @@
1+
"use strict";
2+
Object.defineProperty(exports, "__esModule", {
3+
value: true
4+
});
5+
const _setupTrackingContext = /*#__PURE__*/ _interop_require_default(require("./lib/setupTrackingContext"));
6+
const _processTailwindFeatures = /*#__PURE__*/ _interop_require_default(require("./processTailwindFeatures"));
7+
const _sharedState = require("./lib/sharedState");
8+
const _findAtConfigPath = require("./lib/findAtConfigPath");
9+
function _interop_require_default(obj) {
10+
return obj && obj.__esModule ? obj : {
11+
default: obj
12+
};
13+
}
14+
module.exports = function tailwindcss(configOrPath) {
15+
return {
16+
postcssPlugin: "tailwindcss",
17+
plugins: [
18+
_sharedState.env.DEBUG && function(root) {
19+
console.log("\n");
20+
console.time("JIT TOTAL");
21+
return root;
22+
},
23+
async function(root, result) {
24+
var _findAtConfigPath1;
25+
// Use the path for the `@config` directive if it exists, otherwise use the
26+
// path for the file being processed
27+
configOrPath = (_findAtConfigPath1 = (0, _findAtConfigPath.findAtConfigPath)(root, result)) !== null && _findAtConfigPath1 !== void 0 ? _findAtConfigPath1 : configOrPath;
28+
let context = (0, _setupTrackingContext.default)(configOrPath);
29+
if (root.type === "document") {
30+
let roots = root.nodes.filter((node)=>node.type === "root");
31+
for (const root of roots){
32+
if (root.type === "root") {
33+
await (0, _processTailwindFeatures.default)(context)(root, result);
34+
}
35+
}
36+
return;
37+
}
38+
await (0, _processTailwindFeatures.default)(context)(root, result);
39+
},
40+
false && function lightningCssPlugin(_root, result) {
41+
let postcss = require("postcss");
42+
let lightningcss = require("lightningcss");
43+
let browserslist = require("browserslist");
44+
try {
45+
let transformed = lightningcss.transform({
46+
filename: result.opts.from,
47+
code: Buffer.from(result.root.toString()),
48+
minify: false,
49+
sourceMap: !!result.map,
50+
inputSourceMap: result.map ? result.map.toString() : undefined,
51+
targets: typeof process !== "undefined" && process.env.JEST_WORKER_ID ? {
52+
chrome: 106 << 16
53+
} : lightningcss.browserslistToTargets(browserslist(require("../package.json").browserslist)),
54+
drafts: {
55+
nesting: true,
56+
customMedia: true
57+
}
58+
});
59+
var _result_map;
60+
result.map = Object.assign((_result_map = result.map) !== null && _result_map !== void 0 ? _result_map : {}, {
61+
toJSON () {
62+
return transformed.map.toJSON();
63+
},
64+
toString () {
65+
return transformed.map.toString();
66+
}
67+
});
68+
result.root = postcss.parse(transformed.code.toString("utf8"));
69+
} catch (err) {
70+
if (typeof process !== "undefined" && process.env.JEST_WORKER_ID) {
71+
let lines = err.source.split("\n");
72+
err = new Error([
73+
"Error formatting using Lightning CSS:",
74+
"",
75+
...[
76+
"```css",
77+
...lines.slice(Math.max(err.loc.line - 3, 0), err.loc.line),
78+
" ".repeat(err.loc.column - 1) + "^-- " + err.toString(),
79+
...lines.slice(err.loc.line, err.loc.line + 2),
80+
"```"
81+
]
82+
].join("\n"));
83+
}
84+
if (Error.captureStackTrace) {
85+
Error.captureStackTrace(err, lightningCssPlugin);
86+
}
87+
throw err;
88+
}
89+
},
90+
_sharedState.env.DEBUG && function(root) {
91+
console.timeEnd("JIT TOTAL");
92+
console.log("\n");
93+
return root;
94+
}
95+
].filter(Boolean)
96+
};
97+
};
98+
module.exports.postcss = true;

0 commit comments

Comments
 (0)