tailwindcss 3.4.12 → 3.4.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +15 -1
- package/lib/css/preflight.css +1 -1
- package/lib/lib/content.js +17 -6
- package/package.json +1 -1
- package/src/css/preflight.css +1 -1
- package/src/lib/content.js +20 -6
package/CHANGELOG.md
CHANGED
|
@@ -9,6 +9,18 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
9
9
|
|
|
10
10
|
- Nothing yet!
|
|
11
11
|
|
|
12
|
+
## [3.4.14] - 2024-10-15
|
|
13
|
+
|
|
14
|
+
### Fixed
|
|
15
|
+
|
|
16
|
+
- Don't set `display: none` on elements that use `hidden="until-found"` ([#14625](https://github.com/tailwindlabs/tailwindcss/pull/14625))
|
|
17
|
+
|
|
18
|
+
## [3.4.13] - 2024-09-23
|
|
19
|
+
|
|
20
|
+
### Fixed
|
|
21
|
+
|
|
22
|
+
- Improve source glob verification performance ([#14481](https://github.com/tailwindlabs/tailwindcss/pull/14481))
|
|
23
|
+
|
|
12
24
|
## [3.4.12] - 2024-09-17
|
|
13
25
|
|
|
14
26
|
### Fixed
|
|
@@ -2443,7 +2455,9 @@ No release notes
|
|
|
2443
2455
|
|
|
2444
2456
|
- Everything!
|
|
2445
2457
|
|
|
2446
|
-
[unreleased]: https://github.com/tailwindlabs/tailwindcss/compare/v3.4.
|
|
2458
|
+
[unreleased]: https://github.com/tailwindlabs/tailwindcss/compare/v3.4.14...HEAD
|
|
2459
|
+
[3.4.14]: https://github.com/tailwindlabs/tailwindcss/compare/v3.4.13...v3.4.14
|
|
2460
|
+
[3.4.13]: https://github.com/tailwindlabs/tailwindcss/compare/v3.4.12...v3.4.13
|
|
2447
2461
|
[3.4.12]: https://github.com/tailwindlabs/tailwindcss/compare/v3.4.11...v3.4.12
|
|
2448
2462
|
[3.4.11]: https://github.com/tailwindlabs/tailwindcss/compare/v3.4.10...v3.4.11
|
|
2449
2463
|
[3.4.10]: https://github.com/tailwindlabs/tailwindcss/compare/v3.4.9...v3.4.10
|
package/lib/css/preflight.css
CHANGED
package/lib/lib/content.js
CHANGED
|
@@ -173,9 +173,19 @@ function createBroadPatternCheck(paths) {
|
|
|
173
173
|
if (!maybeBroadPattern) {
|
|
174
174
|
return ()=>{};
|
|
175
175
|
}
|
|
176
|
-
// All
|
|
177
|
-
|
|
178
|
-
|
|
176
|
+
// All glob matchers
|
|
177
|
+
let matchers = [];
|
|
178
|
+
// All glob matchers that explicitly contain any of the known large
|
|
179
|
+
// directories (e.g.: node_modules).
|
|
180
|
+
let explicitMatchers = [];
|
|
181
|
+
// Create matchers for all paths
|
|
182
|
+
for (let path of paths){
|
|
183
|
+
let matcher = _micromatch.default.matcher(path);
|
|
184
|
+
if (LARGE_DIRECTORIES_REGEX.test(path)) {
|
|
185
|
+
explicitMatchers.push(matcher);
|
|
186
|
+
}
|
|
187
|
+
matchers.push(matcher);
|
|
188
|
+
}
|
|
179
189
|
// Keep track of whether we already warned about the broad pattern issue or
|
|
180
190
|
// not. The `log.warn` function already does something similar where we only
|
|
181
191
|
// output the log once. However, with this we can also skip the other checks
|
|
@@ -185,11 +195,12 @@ function createBroadPatternCheck(paths) {
|
|
|
185
195
|
* @param {string} file
|
|
186
196
|
*/ return (file)=>{
|
|
187
197
|
if (warned) return; // Already warned about the broad pattern
|
|
188
|
-
if (
|
|
198
|
+
if (explicitMatchers.some((matcher)=>matcher(file))) return; // Explicitly included, so we can skip further checks
|
|
189
199
|
// When a broad pattern is used, we have to double check that the file was
|
|
190
200
|
// not explicitly included in the globs.
|
|
191
|
-
let
|
|
192
|
-
if (
|
|
201
|
+
let matchingGlobIndex = matchers.findIndex((matcher)=>matcher(file));
|
|
202
|
+
if (matchingGlobIndex === -1) return; // This should never happen
|
|
203
|
+
let matchingGlob = paths[matchingGlobIndex];
|
|
193
204
|
// Create relative paths to make the output a bit more readable.
|
|
194
205
|
let relativeMatchingGlob = _path.default.relative(process.cwd(), matchingGlob);
|
|
195
206
|
if (relativeMatchingGlob[0] !== ".") relativeMatchingGlob = `./${relativeMatchingGlob}`;
|
package/package.json
CHANGED
package/src/css/preflight.css
CHANGED
package/src/lib/content.js
CHANGED
|
@@ -210,9 +210,22 @@ export function createBroadPatternCheck(paths) {
|
|
|
210
210
|
return () => {}
|
|
211
211
|
}
|
|
212
212
|
|
|
213
|
-
// All
|
|
214
|
-
|
|
215
|
-
|
|
213
|
+
// All glob matchers
|
|
214
|
+
let matchers = []
|
|
215
|
+
|
|
216
|
+
// All glob matchers that explicitly contain any of the known large
|
|
217
|
+
// directories (e.g.: node_modules).
|
|
218
|
+
let explicitMatchers = []
|
|
219
|
+
|
|
220
|
+
// Create matchers for all paths
|
|
221
|
+
for (let path of paths) {
|
|
222
|
+
let matcher = micromatch.matcher(path)
|
|
223
|
+
if (LARGE_DIRECTORIES_REGEX.test(path)) {
|
|
224
|
+
explicitMatchers.push(matcher)
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
matchers.push(matcher)
|
|
228
|
+
}
|
|
216
229
|
|
|
217
230
|
// Keep track of whether we already warned about the broad pattern issue or
|
|
218
231
|
// not. The `log.warn` function already does something similar where we only
|
|
@@ -225,12 +238,13 @@ export function createBroadPatternCheck(paths) {
|
|
|
225
238
|
*/
|
|
226
239
|
return (file) => {
|
|
227
240
|
if (warned) return // Already warned about the broad pattern
|
|
228
|
-
if (
|
|
241
|
+
if (explicitMatchers.some((matcher) => matcher(file))) return // Explicitly included, so we can skip further checks
|
|
229
242
|
|
|
230
243
|
// When a broad pattern is used, we have to double check that the file was
|
|
231
244
|
// not explicitly included in the globs.
|
|
232
|
-
let
|
|
233
|
-
if (
|
|
245
|
+
let matchingGlobIndex = matchers.findIndex((matcher) => matcher(file))
|
|
246
|
+
if (matchingGlobIndex === -1) return // This should never happen
|
|
247
|
+
let matchingGlob = paths[matchingGlobIndex]
|
|
234
248
|
|
|
235
249
|
// Create relative paths to make the output a bit more readable.
|
|
236
250
|
let relativeMatchingGlob = path.relative(process.cwd(), matchingGlob)
|