tailwind-styled-v4 5.0.37 → 5.0.38

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.
Files changed (119) hide show
  1. package/dist/analyzer.js +213 -161
  2. package/dist/analyzer.js.map +1 -1
  3. package/dist/analyzer.mjs +118 -82
  4. package/dist/analyzer.mjs.map +1 -1
  5. package/dist/animate.js +131 -87
  6. package/dist/animate.js.map +1 -1
  7. package/dist/animate.mjs +28 -14
  8. package/dist/animate.mjs.map +1 -1
  9. package/dist/atomic.js +105 -68
  10. package/dist/atomic.js.map +1 -1
  11. package/dist/atomic.mjs +40 -13
  12. package/dist/atomic.mjs.map +1 -1
  13. package/dist/cli.js +577 -426
  14. package/dist/cli.js.map +1 -1
  15. package/dist/cli.mjs +466 -304
  16. package/dist/cli.mjs.map +1 -1
  17. package/dist/compiler.js +826 -508
  18. package/dist/compiler.js.map +1 -1
  19. package/dist/compiler.mjs +287 -29
  20. package/dist/compiler.mjs.map +1 -1
  21. package/dist/dashboard.js +71 -41
  22. package/dist/dashboard.js.map +1 -1
  23. package/dist/dashboard.mjs +12 -6
  24. package/dist/dashboard.mjs.map +1 -1
  25. package/dist/devtools.js +333 -289
  26. package/dist/devtools.js.map +1 -1
  27. package/dist/devtools.mjs +26 -11
  28. package/dist/devtools.mjs.map +1 -1
  29. package/dist/engine.js +679 -502
  30. package/dist/engine.js.map +1 -1
  31. package/dist/engine.mjs +467 -307
  32. package/dist/engine.mjs.map +1 -1
  33. package/dist/index.d.mts +145 -319
  34. package/dist/index.d.ts +145 -319
  35. package/dist/index.js +1329 -7441
  36. package/dist/index.js.map +1 -1
  37. package/dist/index.mjs +1266 -7385
  38. package/dist/index.mjs.map +1 -1
  39. package/dist/next.js +318 -243
  40. package/dist/next.js.map +1 -1
  41. package/dist/next.mjs +256 -181
  42. package/dist/next.mjs.map +1 -1
  43. package/dist/plugin-api.js +93 -49
  44. package/dist/plugin-api.js.map +1 -1
  45. package/dist/plugin-api.mjs +26 -6
  46. package/dist/plugin-api.mjs.map +1 -1
  47. package/dist/plugin-registry.js +67 -40
  48. package/dist/plugin-registry.js.map +1 -1
  49. package/dist/plugin-registry.mjs +14 -10
  50. package/dist/plugin-registry.mjs.map +1 -1
  51. package/dist/plugin.js +101 -53
  52. package/dist/plugin.js.map +1 -1
  53. package/dist/plugin.mjs +30 -6
  54. package/dist/plugin.mjs.map +1 -1
  55. package/dist/preset.js +47 -15
  56. package/dist/preset.js.map +1 -1
  57. package/dist/preset.mjs +13 -5
  58. package/dist/preset.mjs.map +1 -1
  59. package/dist/rspack.js +82 -50
  60. package/dist/rspack.js.map +1 -1
  61. package/dist/rspack.mjs +20 -12
  62. package/dist/rspack.mjs.map +1 -1
  63. package/dist/runtime-css.js +62 -24
  64. package/dist/runtime-css.js.map +1 -1
  65. package/dist/runtime-css.mjs +15 -7
  66. package/dist/runtime-css.mjs.map +1 -1
  67. package/dist/runtime.js +97 -44
  68. package/dist/runtime.js.map +1 -1
  69. package/dist/runtime.mjs +31 -8
  70. package/dist/runtime.mjs.map +1 -1
  71. package/dist/scanner.js +163 -120
  72. package/dist/scanner.js.map +1 -1
  73. package/dist/scanner.mjs +67 -39
  74. package/dist/scanner.mjs.map +1 -1
  75. package/dist/shared.js +441 -295
  76. package/dist/shared.js.map +1 -1
  77. package/dist/shared.mjs +253 -122
  78. package/dist/shared.mjs.map +1 -1
  79. package/dist/storybook-addon.js +39 -10
  80. package/dist/storybook-addon.js.map +1 -1
  81. package/dist/storybook-addon.mjs +8 -3
  82. package/dist/storybook-addon.mjs.map +1 -1
  83. package/dist/svelte.js +88 -64
  84. package/dist/svelte.js.map +1 -1
  85. package/dist/svelte.mjs +28 -13
  86. package/dist/svelte.mjs.map +1 -1
  87. package/dist/syntax.js +68 -37
  88. package/dist/syntax.js.map +1 -1
  89. package/dist/syntax.mjs +8 -7
  90. package/dist/syntax.mjs.map +1 -1
  91. package/dist/testing.js +55 -18
  92. package/dist/testing.js.map +1 -1
  93. package/dist/testing.mjs +16 -3
  94. package/dist/testing.mjs.map +1 -1
  95. package/dist/theme.js +131 -74
  96. package/dist/theme.js.map +1 -1
  97. package/dist/theme.mjs +42 -13
  98. package/dist/theme.mjs.map +1 -1
  99. package/dist/turbopackLoader.js +150 -116
  100. package/dist/turbopackLoader.js.map +1 -1
  101. package/dist/turbopackLoader.mjs +124 -81
  102. package/dist/turbopackLoader.mjs.map +1 -1
  103. package/dist/tw.js +560 -421
  104. package/dist/tw.js.map +1 -1
  105. package/dist/tw.mjs +460 -302
  106. package/dist/tw.mjs.map +1 -1
  107. package/dist/vite.js +561 -446
  108. package/dist/vite.js.map +1 -1
  109. package/dist/vite.mjs +433 -321
  110. package/dist/vite.mjs.map +1 -1
  111. package/dist/vue.js +95 -70
  112. package/dist/vue.js.map +1 -1
  113. package/dist/vue.mjs +30 -14
  114. package/dist/vue.mjs.map +1 -1
  115. package/dist/webpackLoader.js +110 -78
  116. package/dist/webpackLoader.js.map +1 -1
  117. package/dist/webpackLoader.mjs +45 -17
  118. package/dist/webpackLoader.mjs.map +1 -1
  119. package/package.json +3 -1
@@ -1,11 +1,3 @@
1
- import { createRequire } from 'module';
2
- import * as fs from 'fs';
3
- import * as path from 'path';
4
- import path__default from 'path';
5
- import 'crypto';
6
- import { fileURLToPath } from 'url';
7
- import { z } from 'zod';
8
-
9
1
  /* tailwind-styled-v4 v5.0.4 | MIT | https://github.com/dictionar32/tailwind-styled-v4 */
10
2
  var __getOwnPropNames = Object.getOwnPropertyNames;
11
3
  var __require = /* @__PURE__ */ ((x) => typeof require !== "undefined" ? require : typeof Proxy !== "undefined" ? new Proxy(x, {
@@ -17,6 +9,11 @@ var __require = /* @__PURE__ */ ((x) => typeof require !== "undefined" ? require
17
9
  var __esm = (fn, res) => function __init() {
18
10
  return fn && (res = (0, fn[__getOwnPropNames(fn)[0]])(fn = 0)), res;
19
11
  };
12
+
13
+ // packages/domain/shared/src/native-resolution.ts
14
+ import { createRequire } from "module";
15
+ import * as fs from "fs";
16
+ import * as path from "path";
20
17
  function platformKey() {
21
18
  if (isBrowser) return "browser";
22
19
  return `${process.platform}-${process.arch}`;
@@ -101,6 +98,7 @@ function resolveNativeBinary(runtimeDir) {
101
98
  var isBrowser, _require, PLATFORM_MAP;
102
99
  var init_native_resolution = __esm({
103
100
  "packages/domain/shared/src/native-resolution.ts"() {
101
+ "use strict";
104
102
  isBrowser = typeof window !== "undefined" || typeof document !== "undefined";
105
103
  _require = typeof __require !== "undefined" ? __require : createRequire(import.meta.url);
106
104
  PLATFORM_MAP = {
@@ -113,17 +111,27 @@ var init_native_resolution = __esm({
113
111
  };
114
112
  }
115
113
  });
114
+
115
+ // packages/domain/shared/src/index.ts
116
+ import { createHash } from "crypto";
117
+ import fs2 from "fs";
118
+ import path2 from "path";
119
+ import { fileURLToPath } from "url";
120
+ import { createRequire as createRequire2 } from "module";
116
121
  function resolveRuntimeDir(dir, importMetaUrl) {
122
+ if (dir) return path2.resolve(dir);
117
123
  try {
118
- return path__default.dirname(fileURLToPath(importMetaUrl));
124
+ return path2.dirname(fileURLToPath(importMetaUrl));
119
125
  } catch {
120
126
  return process.cwd();
121
127
  }
122
128
  }
129
+ var _require2;
123
130
  var init_src = __esm({
124
131
  "packages/domain/shared/src/index.ts"() {
132
+ "use strict";
125
133
  init_native_resolution();
126
- createRequire(import.meta.url);
134
+ _require2 = createRequire2(import.meta.url);
127
135
  }
128
136
  });
129
137
 
@@ -131,6 +139,7 @@ var init_src = __esm({
131
139
  var _loadNative, log, NATIVE_UNAVAILABLE_MESSAGE, nativeBridge, bridgeLoadAttempted, bridgeLoadError, isValidNativeBridge, getNativeBridge;
132
140
  var init_nativeBridge = __esm({
133
141
  "packages/domain/compiler/src/nativeBridge.ts"() {
142
+ "use strict";
134
143
  init_src();
135
144
  _loadNative = (path6) => __require(path6);
136
145
  log = (...args) => {
@@ -229,38 +238,49 @@ Tried paths: ${result.tried.join("\n")}`);
229
238
  // packages/domain/compiler/src/compiler/index.ts
230
239
  var init_compiler = __esm({
231
240
  "packages/domain/compiler/src/compiler/index.ts"() {
241
+ "use strict";
232
242
  }
233
243
  });
234
244
 
235
245
  // packages/domain/compiler/src/parser/index.ts
236
246
  var init_parser = __esm({
237
247
  "packages/domain/compiler/src/parser/index.ts"() {
248
+ "use strict";
238
249
  }
239
250
  });
240
251
 
241
252
  // packages/domain/compiler/src/analyzer/index.ts
242
253
  var init_analyzer = __esm({
243
254
  "packages/domain/compiler/src/analyzer/index.ts"() {
255
+ "use strict";
244
256
  }
245
257
  });
246
258
 
247
259
  // packages/domain/compiler/src/cache/index.ts
248
260
  var init_cache = __esm({
249
261
  "packages/domain/compiler/src/cache/index.ts"() {
262
+ "use strict";
250
263
  }
251
264
  });
252
265
 
253
266
  // packages/domain/compiler/src/redis/index.ts
254
267
  var init_redis = __esm({
255
268
  "packages/domain/compiler/src/redis/index.ts"() {
269
+ "use strict";
256
270
  }
257
271
  });
258
272
 
259
273
  // packages/domain/compiler/src/watch/index.ts
260
274
  var init_watch = __esm({
261
275
  "packages/domain/compiler/src/watch/index.ts"() {
276
+ "use strict";
262
277
  }
263
278
  });
279
+
280
+ // packages/domain/compiler/src/index.ts
281
+ import fs3 from "fs";
282
+ import path3 from "path";
283
+ import { createRequire as createRequire3 } from "module";
264
284
  function _layoutClassesToCss(classes) {
265
285
  const native = getNativeBridge();
266
286
  if (!native?.layoutClassesToCss) {
@@ -295,9 +315,10 @@ function extractContainerCssFromSource(source) {
295
315
  }
296
316
  return rules.join("\n");
297
317
  }
298
- var transformSource, _CONTAINER_BREAKPOINTS, runLoaderTransform, shouldSkipFile, registerFileClasses, extractTwStateConfigs, generateStaticStateCss, extractAndGenerateStateCss;
318
+ var _require3, transformSource, _CONTAINER_BREAKPOINTS, runLoaderTransform, shouldSkipFile, registerFileClasses, extractTwStateConfigs, generateStaticStateCss, extractAndGenerateStateCss;
299
319
  var init_src2 = __esm({
300
320
  "packages/domain/compiler/src/index.ts"() {
321
+ "use strict";
301
322
  init_nativeBridge();
302
323
  init_compiler();
303
324
  init_parser();
@@ -305,7 +326,7 @@ var init_src2 = __esm({
305
326
  init_cache();
306
327
  init_redis();
307
328
  init_watch();
308
- createRequire(import.meta.url);
329
+ _require3 = createRequire3(import.meta.url);
309
330
  transformSource = (source, opts) => {
310
331
  const native = getNativeBridge();
311
332
  if (!native?.transformSource) {
@@ -403,6 +424,7 @@ var init_src2 = __esm({
403
424
  // packages/domain/compiler/src/internal.ts
404
425
  var init_internal = __esm({
405
426
  "packages/domain/compiler/src/internal.ts"() {
427
+ "use strict";
406
428
  init_src2();
407
429
  init_compiler();
408
430
  init_parser();
@@ -415,6 +437,12 @@ var init_internal = __esm({
415
437
 
416
438
  // packages/presentation/next/src/webpackLoader.ts
417
439
  init_internal();
440
+ import path5 from "path";
441
+ import { z } from "zod";
442
+
443
+ // packages/presentation/next/src/staticCssWebpackPlugin.ts
444
+ import fs4 from "fs";
445
+ import path4 from "path";
418
446
  var _fileStaticCssMap = /* @__PURE__ */ new Map();
419
447
  function setFileStaticCss(filepath, css) {
420
448
  if (css && css.trim()) {
@@ -436,7 +464,7 @@ var WebpackLoaderOptionsSchema = z.object({
436
464
  preserveImports: z.boolean().optional(),
437
465
  safelistPath: z.string().optional()
438
466
  });
439
- var isNextBuildArtifact = (filepath) => filepath.includes(`${path__default.sep}.next${path__default.sep}`);
467
+ var isNextBuildArtifact = (filepath) => filepath.includes(`${path5.sep}.next${path5.sep}`);
440
468
  function webpackLoader(source) {
441
469
  const callback = this.async?.();
442
470
  if (!callback) {
@@ -477,7 +505,7 @@ function webpackLoader(source) {
477
505
  const rsc = output.rsc;
478
506
  const engine = output.engine ?? "js";
479
507
  const env = rsc?.isServer ? "server" : "client";
480
- const name = path__default.basename(filepath);
508
+ const name = path5.basename(filepath);
481
509
  process.stdout.write(
482
510
  `[tailwind-styled/webpack] ${name} -> ${output.classes.length} classes (${env}) [${engine}]
483
511
  `
@@ -496,7 +524,7 @@ function webpackLoader(source) {
496
524
  callback(null, source);
497
525
  }
498
526
  }
499
-
500
- export { webpackLoader as default };
501
- //# sourceMappingURL=webpackLoader.mjs.map
527
+ export {
528
+ webpackLoader as default
529
+ };
502
530
  //# sourceMappingURL=webpackLoader.mjs.map