@classic-homes/theme-react 0.8.0 → 0.8.2

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.d.mts CHANGED
@@ -352,7 +352,7 @@ declare namespace SimpleDialog {
352
352
  * - Optional actions slot for CTA buttons
353
353
  * - Consistent typography using design tokens: `default` and `centered`
354
354
  * set the theme heading scale for the rendered level explicitly (h1 =
355
- * Spectral 500 italic via `text-h1`, h2-h6 = Figtree 600 via `text-h2`..
355
+ * Spectral 400 upright via `text-h1`, h2-h6 = Figtree 600 via `text-h2`..
356
356
  * `text-h6`). They do not lean on the bare-element styles: Tailwind
357
357
  * preflight outranks the theme's `@layer` heading rules in consumer apps,
358
358
  * which left the title at body size. `hero` and `form` are display styles
package/dist/index.d.ts CHANGED
@@ -352,7 +352,7 @@ declare namespace SimpleDialog {
352
352
  * - Optional actions slot for CTA buttons
353
353
  * - Consistent typography using design tokens: `default` and `centered`
354
354
  * set the theme heading scale for the rendered level explicitly (h1 =
355
- * Spectral 500 italic via `text-h1`, h2-h6 = Figtree 600 via `text-h2`..
355
+ * Spectral 400 upright via `text-h1`, h2-h6 = Figtree 600 via `text-h2`..
356
356
  * `text-h6`). They do not lean on the bare-element styles: Tailwind
357
357
  * preflight outranks the theme's `@layer` heading rules in consumer apps,
358
358
  * which left the title at body size. `hero` and `form` are display styles
package/dist/index.js CHANGED
@@ -354,10 +354,10 @@ var checkbox = recipe({
354
354
  defaultVariants: { invalid: false }
355
355
  });
356
356
  var switchRoot = recipe({
357
- base: "peer relative inline-flex h-7 w-12 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=unchecked]:bg-input"
357
+ base: "peer relative inline-flex h-7 w-12 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=unchecked]:border-input data-[state=unchecked]:bg-background"
358
358
  });
359
359
  var switchThumb = recipe({
360
- base: "pointer-events-none block h-5 w-5 rounded-full bg-background shadow-lg ring-0 transition-transform data-[state=checked]:translate-x-[22px] data-[state=unchecked]:translate-x-0.5"
360
+ base: "pointer-events-none block h-5 w-5 rounded-full ring-0 transition-transform data-[state=checked]:bg-background data-[state=checked]:shadow-lg data-[state=unchecked]:bg-foreground data-[state=checked]:translate-x-[22px] data-[state=unchecked]:translate-x-0.5"
361
361
  });
362
362
  var tabsList = recipe({
363
363
  base: "inline-flex items-center rounded-md bg-muted p-1 text-muted-foreground"
@@ -365,9 +365,11 @@ var tabsList = recipe({
365
365
  var tabsTrigger = recipe({
366
366
  base: `inline-flex items-center justify-center whitespace-nowrap rounded-sm px-3 py-1.5 text-sm font-medium ${focusRing}`,
367
367
  variants: {
368
+ // Selected is a Heritage Teal fill, not a White pill: White on the Paper
369
+ // track is ~1.1:1, so the current tab was hard to pick out (v2.5).
368
370
  active: {
369
- true: "bg-background text-foreground shadow-sm",
370
- false: "hover:bg-background-hover hover:text-foreground"
371
+ true: "bg-primary text-primary-foreground shadow-sm",
372
+ false: "hover:bg-muted-hover hover:text-foreground"
371
373
  },
372
374
  disabled: { true: "opacity-50 pointer-events-none cursor-not-allowed", false: "" }
373
375
  },
@@ -568,7 +570,7 @@ var segmentedControl = recipe({
568
570
  defaultVariants: { size: "md" }
569
571
  });
570
572
  var segmentedControlItem = recipe({
571
- base: "inline-flex shrink-0 items-center justify-center gap-1.5 whitespace-nowrap rounded-md px-3 text-sm font-medium ring-offset-background hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=checked]:bg-background data-[state=checked]:text-foreground data-[state=checked]:shadow-sm",
573
+ base: "inline-flex shrink-0 items-center justify-center gap-1.5 whitespace-nowrap rounded-md px-3 text-sm font-medium ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=unchecked]:hover:bg-muted-hover data-[state=unchecked]:hover:text-foreground data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground data-[state=checked]:shadow-sm",
572
574
  variants: { size: { md: "h-8", sm: "h-7 px-2.5" } },
573
575
  defaultVariants: { size: "md" }
574
576
  });
@@ -1635,7 +1637,7 @@ var pageHeaderSubtitleVariants = (0, import_class_variance_authority7.cva)("text
1635
1637
  variants: {
1636
1638
  variant: {
1637
1639
  default: "text-lg",
1638
- hero: "text-lg font-serif italic",
1640
+ hero: "text-lg font-serif",
1639
1641
  centered: "text-xl max-w-2xl mx-auto",
1640
1642
  form: "mt-3 text-base md:text-lg text-gray-600"
1641
1643
  }
@@ -1645,7 +1647,7 @@ var pageHeaderSubtitleVariants = (0, import_class_variance_authority7.cva)("text
1645
1647
  }
1646
1648
  });
1647
1649
  var levelTypeClass = {
1648
- h1: "font-serif italic text-h1",
1650
+ h1: "font-serif text-h1",
1649
1651
  h2: "font-sans not-italic text-h2",
1650
1652
  h3: "font-sans not-italic text-h3",
1651
1653
  h4: "font-sans not-italic text-h4",
@@ -6876,7 +6878,9 @@ function Tabs({
6876
6878
  {
6877
6879
  className: cn(
6878
6880
  "size-2 shrink-0 rounded-full",
6879
- extra.dot === "destructive" ? "bg-destructive" : "bg-success"
6881
+ // The selected tab is a teal fill: a teal dot turns White on it, and a
6882
+ // red one gets a White ring (red on teal is too close)
6883
+ extra.dot === "destructive" ? cn("bg-destructive", active && "ring-2 ring-primary-foreground") : active ? "bg-primary-foreground" : "bg-success"
6880
6884
  ),
6881
6885
  "aria-hidden": "true",
6882
6886
  "data-tab-indicator": ""
package/dist/index.mjs CHANGED
@@ -197,10 +197,10 @@ var checkbox = recipe({
197
197
  defaultVariants: { invalid: false }
198
198
  });
199
199
  var switchRoot = recipe({
200
- base: "peer relative inline-flex h-7 w-12 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=unchecked]:bg-input"
200
+ base: "peer relative inline-flex h-7 w-12 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=unchecked]:border-input data-[state=unchecked]:bg-background"
201
201
  });
202
202
  var switchThumb = recipe({
203
- base: "pointer-events-none block h-5 w-5 rounded-full bg-background shadow-lg ring-0 transition-transform data-[state=checked]:translate-x-[22px] data-[state=unchecked]:translate-x-0.5"
203
+ base: "pointer-events-none block h-5 w-5 rounded-full ring-0 transition-transform data-[state=checked]:bg-background data-[state=checked]:shadow-lg data-[state=unchecked]:bg-foreground data-[state=checked]:translate-x-[22px] data-[state=unchecked]:translate-x-0.5"
204
204
  });
205
205
  var tabsList = recipe({
206
206
  base: "inline-flex items-center rounded-md bg-muted p-1 text-muted-foreground"
@@ -208,9 +208,11 @@ var tabsList = recipe({
208
208
  var tabsTrigger = recipe({
209
209
  base: `inline-flex items-center justify-center whitespace-nowrap rounded-sm px-3 py-1.5 text-sm font-medium ${focusRing}`,
210
210
  variants: {
211
+ // Selected is a Heritage Teal fill, not a White pill: White on the Paper
212
+ // track is ~1.1:1, so the current tab was hard to pick out (v2.5).
211
213
  active: {
212
- true: "bg-background text-foreground shadow-sm",
213
- false: "hover:bg-background-hover hover:text-foreground"
214
+ true: "bg-primary text-primary-foreground shadow-sm",
215
+ false: "hover:bg-muted-hover hover:text-foreground"
214
216
  },
215
217
  disabled: { true: "opacity-50 pointer-events-none cursor-not-allowed", false: "" }
216
218
  },
@@ -411,7 +413,7 @@ var segmentedControl = recipe({
411
413
  defaultVariants: { size: "md" }
412
414
  });
413
415
  var segmentedControlItem = recipe({
414
- base: "inline-flex shrink-0 items-center justify-center gap-1.5 whitespace-nowrap rounded-md px-3 text-sm font-medium ring-offset-background hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=checked]:bg-background data-[state=checked]:text-foreground data-[state=checked]:shadow-sm",
416
+ base: "inline-flex shrink-0 items-center justify-center gap-1.5 whitespace-nowrap rounded-md px-3 text-sm font-medium ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=unchecked]:hover:bg-muted-hover data-[state=unchecked]:hover:text-foreground data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground data-[state=checked]:shadow-sm",
415
417
  variants: { size: { md: "h-8", sm: "h-7 px-2.5" } },
416
418
  defaultVariants: { size: "md" }
417
419
  });
@@ -1478,7 +1480,7 @@ var pageHeaderSubtitleVariants = cva7("text-muted-foreground", {
1478
1480
  variants: {
1479
1481
  variant: {
1480
1482
  default: "text-lg",
1481
- hero: "text-lg font-serif italic",
1483
+ hero: "text-lg font-serif",
1482
1484
  centered: "text-xl max-w-2xl mx-auto",
1483
1485
  form: "mt-3 text-base md:text-lg text-gray-600"
1484
1486
  }
@@ -1488,7 +1490,7 @@ var pageHeaderSubtitleVariants = cva7("text-muted-foreground", {
1488
1490
  }
1489
1491
  });
1490
1492
  var levelTypeClass = {
1491
- h1: "font-serif italic text-h1",
1493
+ h1: "font-serif text-h1",
1492
1494
  h2: "font-sans not-italic text-h2",
1493
1495
  h3: "font-sans not-italic text-h3",
1494
1496
  h4: "font-sans not-italic text-h4",
@@ -6751,7 +6753,9 @@ function Tabs({
6751
6753
  {
6752
6754
  className: cn(
6753
6755
  "size-2 shrink-0 rounded-full",
6754
- extra.dot === "destructive" ? "bg-destructive" : "bg-success"
6756
+ // The selected tab is a teal fill: a teal dot turns White on it, and a
6757
+ // red one gets a White ring (red on teal is too close)
6758
+ extra.dot === "destructive" ? cn("bg-destructive", active && "ring-2 ring-primary-foreground") : active ? "bg-primary-foreground" : "bg-success"
6755
6759
  ),
6756
6760
  "aria-hidden": "true",
6757
6761
  "data-tab-indicator": ""
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@classic-homes/theme-react",
3
- "version": "0.8.0",
3
+ "version": "0.8.2",
4
4
  "description": "React components for the Classic theme system",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",