@bamboocss/generator 1.40.1 → 1.41.0

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/dist/index.cjs CHANGED
@@ -2424,7 +2424,17 @@ function generatePropTypes(ctx) {
2424
2424
  * writes on purpose.
2425
2425
  */
2426
2426
  type Modifier = "/" | "!" | " !"
2427
- type WithModifier<T> = [T] extends [string] ? \`\${T}\${Modifier}\${string}\` & { __modifier?: true } : never
2427
+ /**
2428
+ * \`Extract\`, not a \`[T] extends [string]\` test, which was the same thing until a utility
2429
+ * carried keywords beside its tokens: \`KnownKeywords\` keeps \`Number\` deliberately, and that
2430
+ * one non-string member turned every modifier form off for the whole property. It rejected
2431
+ * \`roundedBottom: 'lg!'\` while \`rounded: 'lg!'\` passed, purely because the two utilities are
2432
+ * declared differently — both emit \`var(--radii-lg) !important\`.
2433
+ *
2434
+ * Filtering costs nothing the test did not: the same string members distribute either way,
2435
+ * and \`Extract\` of no strings is \`never\`, exactly what the false branch returned.
2436
+ */
2437
+ type WithModifier<T> = \`\${Extract<T, string>}\${Modifier}\${string}\` & { __modifier?: true }
2428
2438
 
2429
2439
  /**
2430
2440
  * A list of candidate values, most-preferred first, emitted as repeated declarations so the
package/dist/index.mjs CHANGED
@@ -2398,7 +2398,17 @@ function generatePropTypes(ctx) {
2398
2398
  * writes on purpose.
2399
2399
  */
2400
2400
  type Modifier = "/" | "!" | " !"
2401
- type WithModifier<T> = [T] extends [string] ? \`\${T}\${Modifier}\${string}\` & { __modifier?: true } : never
2401
+ /**
2402
+ * \`Extract\`, not a \`[T] extends [string]\` test, which was the same thing until a utility
2403
+ * carried keywords beside its tokens: \`KnownKeywords\` keeps \`Number\` deliberately, and that
2404
+ * one non-string member turned every modifier form off for the whole property. It rejected
2405
+ * \`roundedBottom: 'lg!'\` while \`rounded: 'lg!'\` passed, purely because the two utilities are
2406
+ * declared differently — both emit \`var(--radii-lg) !important\`.
2407
+ *
2408
+ * Filtering costs nothing the test did not: the same string members distribute either way,
2409
+ * and \`Extract\` of no strings is \`never\`, exactly what the false branch returned.
2410
+ */
2411
+ type WithModifier<T> = \`\${Extract<T, string>}\${Modifier}\${string}\` & { __modifier?: true }
2402
2412
 
2403
2413
  /**
2404
2414
  * A list of candidate values, most-preferred first, emitted as repeated declarations so the
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bamboocss/generator",
3
- "version": "1.40.1",
3
+ "version": "1.41.0",
4
4
  "description": "The css generator for css bamboo",
5
5
  "homepage": "https://bamboocss.com",
6
6
  "license": "MIT",
@@ -38,12 +38,12 @@
38
38
  "pluralize": "8.0.0",
39
39
  "postcss": "8.5.26",
40
40
  "ts-pattern": "5.9.0",
41
- "@bamboocss/core": "1.40.1",
42
- "@bamboocss/is-valid-prop": "^1.40.1",
43
- "@bamboocss/logger": "1.40.1",
44
- "@bamboocss/shared": "1.40.1",
45
- "@bamboocss/token-dictionary": "1.40.1",
46
- "@bamboocss/types": "1.40.1"
41
+ "@bamboocss/core": "1.41.0",
42
+ "@bamboocss/logger": "1.41.0",
43
+ "@bamboocss/token-dictionary": "1.41.0",
44
+ "@bamboocss/is-valid-prop": "^1.41.0",
45
+ "@bamboocss/types": "1.41.0",
46
+ "@bamboocss/shared": "1.41.0"
47
47
  },
48
48
  "devDependencies": {
49
49
  "@types/pluralize": "0.0.33"