@nswds/app 1.97.14 → 1.98.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.js CHANGED
@@ -42,6 +42,8 @@ import * as LabelPrimitive from '@radix-ui/react-label';
42
42
  import * as RadioGroupPrimitive from '@radix-ui/react-radio-group';
43
43
  import * as TabsPrimitives from '@radix-ui/react-tabs';
44
44
  import * as CollapsiblePrimitive from '@radix-ui/react-collapsible';
45
+ import * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';
46
+ import * as TogglePrimitive from '@radix-ui/react-toggle';
45
47
  import { Command as Command$1 } from 'cmdk';
46
48
  import * as DialogPrimitive from '@radix-ui/react-dialog';
47
49
  import * as ContextMenuPrimitive from '@radix-ui/react-context-menu';
@@ -49,8 +51,6 @@ import { useReactTable, getFacetedUniqueValues, getFacetedRowModel, getSortedRow
49
51
  import * as SeparatorPrimitive from '@radix-ui/react-separator';
50
52
  import { Drawer as Drawer$1 } from 'vaul';
51
53
  import { FormProvider, Controller, useFormContext, useFormState } from 'react-hook-form';
52
- import * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';
53
- import * as TogglePrimitive from '@radix-ui/react-toggle';
54
54
  import Image2 from 'next/image';
55
55
  import * as HoverCardPrimitive from '@radix-ui/react-hover-card';
56
56
  import { OTPInput, OTPInputContext } from 'input-otp';
@@ -14918,6 +14918,734 @@ function ColorCard({ name, token, hex: hex2, rgb: rgb2, hsl, oklch: oklch2, form
14918
14918
  ] })
14919
14919
  ] }) });
14920
14920
  }
14921
+ var recommendedBackgroundTones = [100, 200, 400, 500, 600, 700, 800];
14922
+ var AAA_NORMAL_TEXT_RATIO = 7;
14923
+ function extractTone(token) {
14924
+ const match = token.match(/-(\d+)$/);
14925
+ return match ? Number.parseInt(match[1], 10) : 0;
14926
+ }
14927
+ function formatFamilyLabel(name, key) {
14928
+ if (key === "grey") return "Grey";
14929
+ return name.replace(/^NSW Aboriginal\s+/i, "").replace(/^NSW\s+/i, "").trim();
14930
+ }
14931
+ function toPairingColor(color2) {
14932
+ return {
14933
+ ...color2,
14934
+ tone: extractTone(color2.token)
14935
+ };
14936
+ }
14937
+ function getPreferredForegroundTone(backgroundTone) {
14938
+ if (backgroundTone <= 200) return 800;
14939
+ if (backgroundTone <= 500) return 700;
14940
+ if (backgroundTone <= 650) return 250;
14941
+ return 200;
14942
+ }
14943
+ function getPairRating(contrastRatio) {
14944
+ if (contrastRatio >= 7) return "AAA";
14945
+ if (contrastRatio >= 4.5) return "AA";
14946
+ return "AA Large";
14947
+ }
14948
+ function isPreferredDirection(backgroundTone, foregroundTone, preferredForegroundTone) {
14949
+ if (preferredForegroundTone < backgroundTone) {
14950
+ return foregroundTone < backgroundTone;
14951
+ }
14952
+ return foregroundTone > backgroundTone;
14953
+ }
14954
+ function buildPair(background, foreground) {
14955
+ const contrastRatio = culori.wcagContrast(background.hex, foreground.hex);
14956
+ return {
14957
+ id: `${background.token}:${foreground.token}`,
14958
+ background,
14959
+ foreground,
14960
+ contrastRatio,
14961
+ passes: {
14962
+ aaLarge: contrastRatio >= 3,
14963
+ aaText: contrastRatio >= 4.5,
14964
+ aaaLarge: contrastRatio >= 4.5,
14965
+ aaaText: contrastRatio >= 7
14966
+ },
14967
+ rating: getPairRating(contrastRatio)
14968
+ };
14969
+ }
14970
+ function pickForeground(colorsToPair, background, minimumRatio) {
14971
+ const preferredForegroundTone = getPreferredForegroundTone(background.tone);
14972
+ const passingCandidates = colorsToPair.filter((color2) => color2.token !== background.token).map((color2) => buildPair(background, color2)).filter((pair) => pair.contrastRatio >= minimumRatio);
14973
+ if (passingCandidates.length === 0) return null;
14974
+ const preferredCandidates = passingCandidates.filter(
14975
+ (pair) => isPreferredDirection(background.tone, pair.foreground.tone, preferredForegroundTone)
14976
+ );
14977
+ const candidates = preferredCandidates.length > 0 ? preferredCandidates : passingCandidates;
14978
+ return candidates.sort((left, right) => {
14979
+ const leftTargetDelta = Math.abs(left.foreground.tone - preferredForegroundTone);
14980
+ const rightTargetDelta = Math.abs(right.foreground.tone - preferredForegroundTone);
14981
+ if (leftTargetDelta !== rightTargetDelta) {
14982
+ return leftTargetDelta - rightTargetDelta;
14983
+ }
14984
+ const leftToneGap = Math.abs(left.foreground.tone - background.tone);
14985
+ const rightToneGap = Math.abs(right.foreground.tone - background.tone);
14986
+ if (leftToneGap !== rightToneGap) {
14987
+ return rightToneGap - leftToneGap;
14988
+ }
14989
+ return right.contrastRatio - left.contrastRatio;
14990
+ })[0];
14991
+ }
14992
+ function buildRecommendedPairs(colorsToPair, minimumRatio) {
14993
+ const backgrounds = recommendedBackgroundTones.map((tone) => colorsToPair.find((color2) => color2.tone === tone)).filter((color2) => Boolean(color2));
14994
+ const recommendedPairs = [];
14995
+ for (const background of backgrounds) {
14996
+ const pair = pickForeground(colorsToPair, background, minimumRatio);
14997
+ if (!pair || recommendedPairs.some((item) => item.id === pair.id)) {
14998
+ continue;
14999
+ }
15000
+ recommendedPairs.push(pair);
15001
+ }
15002
+ return recommendedPairs;
15003
+ }
15004
+ function buildRecommendedCollections(minimumRatio) {
15005
+ return {
15006
+ brand: Object.entries(colors.brand).map(([key, palette]) => {
15007
+ const scale2 = palette.colors.map(toPairingColor);
15008
+ return {
15009
+ key,
15010
+ label: formatFamilyLabel(palette.name, key),
15011
+ paletteName: palette.name,
15012
+ colors: scale2,
15013
+ recommendedPairs: buildRecommendedPairs(scale2, minimumRatio)
15014
+ };
15015
+ }),
15016
+ aboriginal: Object.entries(colors.aboriginal).map(([key, palette]) => {
15017
+ const scale2 = palette.colors.map(toPairingColor);
15018
+ return {
15019
+ key,
15020
+ label: formatFamilyLabel(palette.name, key),
15021
+ paletteName: palette.name,
15022
+ colors: scale2,
15023
+ recommendedPairs: buildRecommendedPairs(scale2, minimumRatio)
15024
+ };
15025
+ })
15026
+ };
15027
+ }
15028
+ var recommendedAaaPairingCollections = buildRecommendedCollections(AAA_NORMAL_TEXT_RATIO);
15029
+ function getPairingColorValue(color2, format) {
15030
+ return getColorValue(color2, format);
15031
+ }
15032
+ var styles3 = {
15033
+ base: [
15034
+ // Base
15035
+ "inline-flex items-center justify-center gap-2 rounded-sm text-sm font-medium bg-transparent transition-all whitespace-nowrap cursor-pointer border-(--toggle-border) [--toggle-border:var(--color-grey-200)] text-grey-800",
15036
+ // States
15037
+ "data-[state=on]:bg-grey-100 data-[state=on]:text-grey-850",
15038
+ // Hover
15039
+ "hover:bg-grey-100 hover:text-grey-850",
15040
+ // Focus
15041
+ "focus:outline focus:outline-2 focus:outline-offset-0 focus:outline-(--toggle-border)",
15042
+ // Dark mode
15043
+ "dark:text-white",
15044
+ // Dark mode states
15045
+ "dark:data-[state=on]:bg-white/10 dark:data-[state=on]:text-white",
15046
+ // Dark mode hover
15047
+ "dark:hover:bg-white/10 dark:hover:text-white",
15048
+ // Disabled
15049
+ "disabled:pointer-events-none disabled:opacity-50",
15050
+ // Icon
15051
+ '[&_svg]:pointer-events-none [&_svg:not([class*="size-"])]:size-4 [&_svg]:shrink-0',
15052
+ // Aria invalid
15053
+ "aria-invalid:ring-destructive/20 aria-invalid:border-destructive",
15054
+ // Aria invalid dark mode
15055
+ "dark:aria-invalid:ring-destructive/40"
15056
+ ],
15057
+ outline: [
15058
+ // Base
15059
+ "text-grey-800 border [--toggle-border:var(--color-grey-300)]",
15060
+ // States
15061
+ "hover:[--toggle-border:var(--color-grey-400)]",
15062
+ // Dark mode
15063
+ "dark:[--toggle-border:white]/40",
15064
+ // Dark mode states
15065
+ "dark:hover:[--toggle-border:white]/50",
15066
+ // Data on
15067
+ "data-[state=on]:bg-primary-800/10"
15068
+ ]
15069
+ };
15070
+ var toggleVariants = cva(styles3.base, {
15071
+ variants: {
15072
+ variant: {
15073
+ ghost: "",
15074
+ outline: clsx12(styles3.outline)
15075
+ },
15076
+ size: {
15077
+ default: "h-9 px-2 min-w-9",
15078
+ sm: "h-8 px-1.5 min-w-8",
15079
+ lg: "h-10 px-2.5 min-w-10"
15080
+ }
15081
+ },
15082
+ defaultVariants: {
15083
+ variant: "ghost",
15084
+ size: "default"
15085
+ }
15086
+ });
15087
+ function Toggle({
15088
+ className,
15089
+ variant,
15090
+ size,
15091
+ ...props
15092
+ }) {
15093
+ return /* @__PURE__ */ jsx(
15094
+ TogglePrimitive.Root,
15095
+ {
15096
+ "data-slot": "toggle",
15097
+ className: cn(toggleVariants({ variant, size, className })),
15098
+ ...props
15099
+ }
15100
+ );
15101
+ }
15102
+ var ToggleGroupContext = React5.createContext({
15103
+ size: "default",
15104
+ variant: "ghost"
15105
+ });
15106
+ function ToggleGroup({
15107
+ className,
15108
+ variant,
15109
+ size,
15110
+ children,
15111
+ ...props
15112
+ }) {
15113
+ return /* @__PURE__ */ jsx(
15114
+ ToggleGroupPrimitive.Root,
15115
+ {
15116
+ "data-slot": "toggle-group",
15117
+ "data-variant": variant,
15118
+ "data-size": size,
15119
+ className: cn(
15120
+ "group/toggle-group flex w-fit items-center rounded-md data-[variant=outline]:shadow-xs",
15121
+ className
15122
+ ),
15123
+ ...props,
15124
+ children: /* @__PURE__ */ jsx(ToggleGroupContext.Provider, { value: { variant, size }, children })
15125
+ }
15126
+ );
15127
+ }
15128
+ function ToggleGroupItem({
15129
+ className,
15130
+ children,
15131
+ variant,
15132
+ size,
15133
+ ...props
15134
+ }) {
15135
+ const context = React5.useContext(ToggleGroupContext);
15136
+ return /* @__PURE__ */ jsx(
15137
+ ToggleGroupPrimitive.Item,
15138
+ {
15139
+ "data-slot": "toggle-group-item",
15140
+ "data-variant": context.variant || variant,
15141
+ "data-size": context.size || size,
15142
+ className: cn(
15143
+ toggleVariants({
15144
+ variant: context.variant || variant,
15145
+ size: context.size || size
15146
+ }),
15147
+ "min-w-0 shrink-0 rounded-none shadow-none first:rounded-l-sm last:rounded-r-sm focus:z-10 focus-visible:z-10 data-[variant=outline]:border-l-0 data-[variant=outline]:first:border-l",
15148
+ className
15149
+ ),
15150
+ ...props,
15151
+ children
15152
+ }
15153
+ );
15154
+ }
15155
+ function FormatToggle({ format, setFormat }) {
15156
+ return /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2", children: [
15157
+ /* @__PURE__ */ jsx("span", { className: "text-sm font-medium", children: "Format:" }),
15158
+ /* @__PURE__ */ jsxs(
15159
+ ToggleGroup,
15160
+ {
15161
+ type: "single",
15162
+ value: format,
15163
+ onValueChange: (value) => value && setFormat(value),
15164
+ children: [
15165
+ /* @__PURE__ */ jsx(ToggleGroupItem, { value: "hex", "aria-label": "HEX format", children: "HEX" }),
15166
+ /* @__PURE__ */ jsx(ToggleGroupItem, { value: "rgb", "aria-label": "RGB format", children: "RGB" }),
15167
+ /* @__PURE__ */ jsx(ToggleGroupItem, { value: "hsl", "aria-label": "HSL format", children: "HSL" }),
15168
+ /* @__PURE__ */ jsx(ToggleGroupItem, { value: "oklch", "aria-label": "OKLCH format", children: "OKLCH" })
15169
+ ]
15170
+ }
15171
+ )
15172
+ ] });
15173
+ }
15174
+ function getPreferredFamilyKey(families) {
15175
+ return families.find((family) => family.key === "green")?.key ?? families[0]?.key ?? "";
15176
+ }
15177
+ function getDefaultPair(family) {
15178
+ if (!family || family.recommendedPairs.length === 0) return null;
15179
+ return family.recommendedPairs.reduce((bestPair, pair) => {
15180
+ const bestDelta = Math.abs(bestPair.background.tone - 600);
15181
+ const currentDelta = Math.abs(pair.background.tone - 600);
15182
+ return currentDelta < bestDelta ? pair : bestPair;
15183
+ }, family.recommendedPairs[0]);
15184
+ }
15185
+ function getFamilySwatchColor(family) {
15186
+ return family.colors.find((color2) => color2.tone === 500)?.hex ?? family.colors.find((color2) => color2.tone === 400)?.hex ?? family.colors[Math.min(3, family.colors.length - 1)]?.hex ?? "transparent";
15187
+ }
15188
+ function ColorPairingToolLoading() {
15189
+ return /* @__PURE__ */ jsxs("div", { className: "animate-pulse space-y-6", children: [
15190
+ /* @__PURE__ */ jsx("div", { className: "h-40 rounded-md border border-grey-200 bg-grey-50 dark:border-grey-700 dark:bg-grey-900" }),
15191
+ /* @__PURE__ */ jsxs("div", { className: "grid gap-6 xl:grid-cols-[minmax(0,1.3fr)_minmax(20rem,0.9fr)]", children: [
15192
+ /* @__PURE__ */ jsx("div", { className: "h-96 rounded-md border border-grey-200 bg-grey-50 dark:border-grey-700 dark:bg-grey-900" }),
15193
+ /* @__PURE__ */ jsx("div", { className: "h-96 rounded-md border border-grey-200 bg-grey-50 dark:border-grey-700 dark:bg-grey-900" })
15194
+ ] })
15195
+ ] });
15196
+ }
15197
+ function getInitialPairingState(searchParams) {
15198
+ const paletteParam = searchParams.get("palette");
15199
+ const familyParam = searchParams.get("family");
15200
+ const pairParam = searchParams.get("pair");
15201
+ const themeCategory = paletteParam === "brand" || paletteParam === "aboriginal" ? paletteParam : "brand";
15202
+ const families = recommendedAaaPairingCollections[themeCategory];
15203
+ const familyKey = families.some((family) => family.key === familyParam) ? familyParam : getPreferredFamilyKey(families);
15204
+ const activeFamily = families.find((family) => family.key === familyKey) ?? families[0];
15205
+ const defaultPair = getDefaultPair(activeFamily);
15206
+ const selectedPairId = activeFamily?.recommendedPairs.some((pair) => pair.id === pairParam) ? pairParam : defaultPair?.id ?? "";
15207
+ return { familyKey, selectedPairId, themeCategory };
15208
+ }
15209
+ function PairPreview({ family, pair }) {
15210
+ return /* @__PURE__ */ jsx(Card, { className: "gap-0 overflow-hidden py-0", children: /* @__PURE__ */ jsx(
15211
+ "div",
15212
+ {
15213
+ className: "p-6 sm:min-h-[26rem] sm:p-8",
15214
+ style: {
15215
+ backgroundColor: pair.background.hex,
15216
+ color: pair.foreground.hex
15217
+ },
15218
+ children: /* @__PURE__ */ jsxs("div", { className: "flex min-h-[22rem] flex-col justify-between gap-8", children: [
15219
+ /* @__PURE__ */ jsxs("div", { className: "flex flex-wrap items-center gap-2", children: [
15220
+ /* @__PURE__ */ jsxs(
15221
+ "span",
15222
+ {
15223
+ className: "inline-flex items-center gap-2 rounded-full border px-3 py-1 text-[0.72rem] font-semibold tracking-[0.16em] uppercase",
15224
+ style: {
15225
+ borderColor: pair.foreground.hex,
15226
+ backgroundColor: pair.foreground.hex,
15227
+ color: pair.background.hex
15228
+ },
15229
+ children: [
15230
+ /* @__PURE__ */ jsx(Icons.palette, { "data-slot": "icon", className: "size-4" }),
15231
+ family.label
15232
+ ]
15233
+ }
15234
+ ),
15235
+ /* @__PURE__ */ jsxs(
15236
+ "span",
15237
+ {
15238
+ className: "inline-flex rounded-full border px-3 py-1 text-[0.72rem] font-semibold tracking-[0.16em] uppercase",
15239
+ style: {
15240
+ borderColor: pair.foreground.hex
15241
+ },
15242
+ children: [
15243
+ pair.rating,
15244
+ " ",
15245
+ pair.contrastRatio.toFixed(2),
15246
+ ":1"
15247
+ ]
15248
+ }
15249
+ )
15250
+ ] }),
15251
+ /* @__PURE__ */ jsxs("div", { className: "max-w-xl space-y-4 pb-12 sm:pb-16", children: [
15252
+ /* @__PURE__ */ jsx("p", { className: "text-sm font-semibold tracking-[0.22em] uppercase", children: "Tone on tone" }),
15253
+ /* @__PURE__ */ jsxs("div", { className: "space-y-4", children: [
15254
+ /* @__PURE__ */ jsx("h3", { className: "max-w-lg text-4xl leading-none font-bold text-current sm:text-5xl", children: "Pair colour with confidence." }),
15255
+ /* @__PURE__ */ jsx("p", { className: "max-w-md text-sm/6 sm:text-base/7", children: "Use only AAA-approved tone-on-tone combinations for headings, body copy, and calls to action on colour." })
15256
+ ] })
15257
+ ] }),
15258
+ /* @__PURE__ */ jsxs("div", { className: "flex flex-wrap items-center gap-3", children: [
15259
+ /* @__PURE__ */ jsxs(
15260
+ "span",
15261
+ {
15262
+ className: "inline-flex items-center gap-2 rounded-full px-4 py-2 text-sm font-semibold",
15263
+ style: {
15264
+ backgroundColor: pair.foreground.hex,
15265
+ color: pair.background.hex
15266
+ },
15267
+ children: [
15268
+ "Pass",
15269
+ /* @__PURE__ */ jsx(Icons.check, { "data-slot": "icon", className: "size-4" })
15270
+ ]
15271
+ }
15272
+ ),
15273
+ /* @__PURE__ */ jsxs(
15274
+ "span",
15275
+ {
15276
+ className: "inline-flex rounded-full border px-4 py-2 text-sm",
15277
+ style: {
15278
+ borderColor: pair.foreground.hex
15279
+ },
15280
+ children: [
15281
+ pair.background.token,
15282
+ " / ",
15283
+ pair.foreground.token
15284
+ ]
15285
+ }
15286
+ )
15287
+ ] })
15288
+ ] })
15289
+ }
15290
+ ) });
15291
+ }
15292
+ function PairDetailCard({
15293
+ color: color2,
15294
+ format,
15295
+ role
15296
+ }) {
15297
+ const [, copyToClipboardRaw] = useCopyToClipboard();
15298
+ const [copiedField, setCopiedField] = useState(null);
15299
+ const valueLabel = format.toUpperCase();
15300
+ const formattedValue = getPairingColorValue(color2, format);
15301
+ const copyField = (field) => {
15302
+ const fieldValue = field === "token" ? color2.token : field === "tone" ? String(color2.tone) : formattedValue;
15303
+ copyToClipboardRaw(fieldValue);
15304
+ setCopiedField(field);
15305
+ const toastLabel = field === "token" ? "Token" : field === "tone" ? "Tone" : `${valueLabel} value`;
15306
+ toast(`${toastLabel} copied to clipboard`, {
15307
+ duration: 2e3
15308
+ });
15309
+ setTimeout(() => setCopiedField(null), 2e3);
15310
+ };
15311
+ const renderCopyButton = (field, srLabel, className) => /* @__PURE__ */ jsxs(
15312
+ Button2,
15313
+ {
15314
+ variant: "ghost",
15315
+ size: "icon",
15316
+ className: cn("shrink-0", className),
15317
+ onClick: () => copyField(field),
15318
+ children: [
15319
+ copiedField === field ? /* @__PURE__ */ jsx(Icons.check, { "data-slot": "icon", className: "size-5" }) : /* @__PURE__ */ jsx(Icons.content_copy, { "data-slot": "icon", className: "size-5" }),
15320
+ /* @__PURE__ */ jsx("span", { className: "sr-only", children: srLabel })
15321
+ ]
15322
+ }
15323
+ );
15324
+ return /* @__PURE__ */ jsxs(Card, { className: "gap-4", children: [
15325
+ /* @__PURE__ */ jsx(CardHeader, { className: "gap-3 border-b", children: /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-4", children: [
15326
+ /* @__PURE__ */ jsx(
15327
+ "div",
15328
+ {
15329
+ className: "size-14 rounded-2xl border border-grey-200 shadow-sm dark:border-grey-700",
15330
+ style: { backgroundColor: color2.hex }
15331
+ }
15332
+ ),
15333
+ /* @__PURE__ */ jsxs("div", { className: "space-y-1", children: [
15334
+ /* @__PURE__ */ jsx(CardTitle, { children: role }),
15335
+ /* @__PURE__ */ jsx(CardDescription, { children: color2.name ?? color2.token })
15336
+ ] })
15337
+ ] }) }),
15338
+ /* @__PURE__ */ jsxs(CardContent, { className: "grid gap-4", children: [
15339
+ /* @__PURE__ */ jsxs("div", { className: "space-y-2", children: [
15340
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center justify-between gap-3", children: [
15341
+ /* @__PURE__ */ jsx("p", { className: "text-xs font-semibold tracking-[0.16em] text-muted-foreground uppercase", children: "Token" }),
15342
+ renderCopyButton("token", `Copy ${role.toLowerCase()} token`)
15343
+ ] }),
15344
+ /* @__PURE__ */ jsx("p", { className: "font-mono text-base break-all", children: color2.token })
15345
+ ] }),
15346
+ /* @__PURE__ */ jsxs("div", { className: "space-y-2", children: [
15347
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center justify-between gap-3", children: [
15348
+ /* @__PURE__ */ jsx("p", { className: "text-xs font-semibold tracking-[0.16em] text-muted-foreground uppercase", children: "Tone" }),
15349
+ renderCopyButton("tone", `Copy ${role.toLowerCase()} tone`)
15350
+ ] }),
15351
+ /* @__PURE__ */ jsx("p", { className: "font-medium", children: color2.tone })
15352
+ ] }),
15353
+ /* @__PURE__ */ jsxs("div", { className: "space-y-2", children: [
15354
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center justify-between gap-3", children: [
15355
+ /* @__PURE__ */ jsx("p", { className: "text-xs font-semibold tracking-[0.16em] text-muted-foreground uppercase", children: valueLabel }),
15356
+ renderCopyButton("value", `Copy ${role.toLowerCase()} ${valueLabel} value`)
15357
+ ] }),
15358
+ /* @__PURE__ */ jsx("p", { className: "font-mono text-sm break-all", children: formattedValue })
15359
+ ] })
15360
+ ] })
15361
+ ] });
15362
+ }
15363
+ function ComplianceRow({
15364
+ label,
15365
+ passes,
15366
+ threshold
15367
+ }) {
15368
+ return /* @__PURE__ */ jsxs("div", { className: "flex items-center justify-between gap-4 rounded-xl border border-grey-200 px-4 py-3 dark:border-grey-700", children: [
15369
+ /* @__PURE__ */ jsxs("div", { className: "space-y-1", children: [
15370
+ /* @__PURE__ */ jsx("p", { className: "font-medium", children: label }),
15371
+ /* @__PURE__ */ jsx("p", { className: "text-sm text-muted-foreground", children: threshold })
15372
+ ] }),
15373
+ /* @__PURE__ */ jsxs(
15374
+ "span",
15375
+ {
15376
+ className: cn(
15377
+ "inline-flex items-center gap-1 rounded-full px-2.5 py-1 text-xs font-semibold",
15378
+ passes ? "bg-success-50 text-success-800 dark:bg-success-950/30 dark:text-success-200" : "bg-danger-50 text-danger-800 dark:bg-danger-950/30 dark:text-danger-200"
15379
+ ),
15380
+ children: [
15381
+ passes ? /* @__PURE__ */ jsx(Icons.check, { "data-slot": "icon", className: "size-4" }) : /* @__PURE__ */ jsx(Icons.close, { "data-slot": "icon", className: "size-4" }),
15382
+ passes ? "Pass" : "Fail"
15383
+ ]
15384
+ }
15385
+ )
15386
+ ] });
15387
+ }
15388
+ function PairComplianceCard({ pair }) {
15389
+ return /* @__PURE__ */ jsxs(Card, { children: [
15390
+ /* @__PURE__ */ jsxs(CardHeader, { className: "gap-2 border-b", children: [
15391
+ /* @__PURE__ */ jsx(CardTitle, { className: "text-base", children: "AAA compliance" }),
15392
+ /* @__PURE__ */ jsx(CardDescription, { children: "Only pairs that pass AAA normal-text contrast are suggested here. Evaluation uses the raw contrast ratio, not the rounded display value." })
15393
+ ] }),
15394
+ /* @__PURE__ */ jsxs(CardContent, { className: "space-y-3", children: [
15395
+ /* @__PURE__ */ jsxs("div", { className: "rounded-xl border border-grey-200 bg-grey-50 px-4 py-3 dark:border-grey-700 dark:bg-grey-900/60", children: [
15396
+ /* @__PURE__ */ jsx("p", { className: "text-xs font-semibold tracking-[0.16em] text-muted-foreground uppercase", children: "Contrast ratio" }),
15397
+ /* @__PURE__ */ jsxs("p", { className: "mt-1 text-2xl font-semibold", children: [
15398
+ pair.contrastRatio.toFixed(2),
15399
+ ":1"
15400
+ ] })
15401
+ ] }),
15402
+ /* @__PURE__ */ jsx(
15403
+ ComplianceRow,
15404
+ {
15405
+ label: "AAA normal text",
15406
+ passes: pair.passes.aaaText,
15407
+ threshold: "7.0:1 or higher"
15408
+ }
15409
+ ),
15410
+ /* @__PURE__ */ jsx(
15411
+ ComplianceRow,
15412
+ {
15413
+ label: "AAA large text",
15414
+ passes: pair.passes.aaaLarge,
15415
+ threshold: "4.5:1 or higher"
15416
+ }
15417
+ )
15418
+ ] })
15419
+ ] });
15420
+ }
15421
+ function ColorPairingToolContent() {
15422
+ const searchParams = useSearchParams();
15423
+ const {
15424
+ familyKey: initialFamilyKey,
15425
+ selectedPairId: initialSelectedPairId,
15426
+ themeCategory: initialThemeCategory
15427
+ } = getInitialPairingState(searchParams);
15428
+ const [themeCategory, setThemeCategory] = useState(initialThemeCategory);
15429
+ const [format, setFormat] = useState("hex");
15430
+ const [activeFamilyKey, setActiveFamilyKey] = useState(initialFamilyKey);
15431
+ const [selectedPairId, setSelectedPairId] = useState(initialSelectedPairId);
15432
+ const families = recommendedAaaPairingCollections[themeCategory];
15433
+ const resolvedActiveFamilyKey = families.some((family) => family.key === activeFamilyKey) ? activeFamilyKey : getPreferredFamilyKey(families);
15434
+ const activeFamily = families.find((family) => family.key === resolvedActiveFamilyKey) ?? families[0];
15435
+ const selectedPair = activeFamily?.recommendedPairs.find((pair) => pair.id === selectedPairId) ?? getDefaultPair(activeFamily);
15436
+ const updateUrlParams = (nextThemeCategory, nextFamilyKey, nextSelectedPairId) => {
15437
+ const params = new URLSearchParams(window.location.search);
15438
+ params.set("palette", nextThemeCategory);
15439
+ params.set("family", nextFamilyKey);
15440
+ if (nextSelectedPairId) {
15441
+ params.set("pair", nextSelectedPairId);
15442
+ } else {
15443
+ params.delete("pair");
15444
+ }
15445
+ window.history.replaceState(
15446
+ null,
15447
+ "",
15448
+ `${window.location.pathname}?${params.toString()}${window.location.hash}`
15449
+ );
15450
+ };
15451
+ const handleThemeCategoryChange = (nextThemeCategory) => {
15452
+ const nextFamilies = recommendedAaaPairingCollections[nextThemeCategory];
15453
+ const nextFamilyKey = nextFamilies.some((family) => family.key === activeFamilyKey) ? activeFamilyKey : getPreferredFamilyKey(nextFamilies);
15454
+ const nextActiveFamily = nextFamilies.find((family) => family.key === nextFamilyKey) ?? nextFamilies[0];
15455
+ const nextSelectedPair = nextActiveFamily?.recommendedPairs.find((pair) => pair.id === selectedPairId) ?? getDefaultPair(nextActiveFamily);
15456
+ setThemeCategory(nextThemeCategory);
15457
+ setActiveFamilyKey(nextFamilyKey);
15458
+ setSelectedPairId(nextSelectedPair?.id ?? "");
15459
+ updateUrlParams(nextThemeCategory, nextFamilyKey, nextSelectedPair?.id ?? "");
15460
+ };
15461
+ const handleFamilyChange = (nextFamilyKey) => {
15462
+ const nextActiveFamily = families.find((family) => family.key === nextFamilyKey);
15463
+ const nextSelectedPair = nextActiveFamily?.recommendedPairs.find((pair) => pair.id === selectedPairId) ?? getDefaultPair(nextActiveFamily);
15464
+ setActiveFamilyKey(nextFamilyKey);
15465
+ setSelectedPairId(nextSelectedPair?.id ?? "");
15466
+ updateUrlParams(themeCategory, nextFamilyKey, nextSelectedPair?.id ?? "");
15467
+ };
15468
+ const handlePairChange = (nextSelectedPairId) => {
15469
+ setSelectedPairId(nextSelectedPairId);
15470
+ updateUrlParams(themeCategory, resolvedActiveFamilyKey, nextSelectedPairId);
15471
+ };
15472
+ if (!activeFamily || !selectedPair) {
15473
+ return /* @__PURE__ */ jsx(Card, { children: /* @__PURE__ */ jsxs(CardHeader, { children: [
15474
+ /* @__PURE__ */ jsx(CardTitle, { children: "No recommended AAA pairs available" }),
15475
+ /* @__PURE__ */ jsx(CardDescription, { children: "No recommended pairs are available for the current palette." })
15476
+ ] }) });
15477
+ }
15478
+ return /* @__PURE__ */ jsxs("div", { className: "space-y-6", children: [
15479
+ /* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-4 sm:flex-row sm:items-center sm:justify-between", children: [
15480
+ /* @__PURE__ */ jsxs("div", { className: "flex flex-wrap items-center gap-3", children: [
15481
+ /* @__PURE__ */ jsx("span", { className: "text-sm font-medium", children: "Palette:" }),
15482
+ /* @__PURE__ */ jsx(
15483
+ SegmentedControl,
15484
+ {
15485
+ value: themeCategory,
15486
+ onValueChange: (value) => handleThemeCategoryChange(value),
15487
+ children: /* @__PURE__ */ jsxs(SegmentedControlList, { className: "w-full sm:w-fit", children: [
15488
+ /* @__PURE__ */ jsx(SegmentedControlTrigger, { value: "brand", children: "Brand palette" }),
15489
+ /* @__PURE__ */ jsx(SegmentedControlTrigger, { value: "aboriginal", children: "Aboriginal palette" })
15490
+ ] })
15491
+ }
15492
+ )
15493
+ ] }),
15494
+ /* @__PURE__ */ jsx(FormatToggle, { format, setFormat })
15495
+ ] }),
15496
+ /* @__PURE__ */ jsx("div", { className: "space-y-3", children: /* @__PURE__ */ jsx("div", { className: "grid grid-cols-2 gap-2 lg:grid-cols-4 xl:grid-cols-5", children: families.map((family) => {
15497
+ const isActive = family.key === resolvedActiveFamilyKey;
15498
+ return /* @__PURE__ */ jsxs(
15499
+ "button",
15500
+ {
15501
+ type: "button",
15502
+ onClick: () => handleFamilyChange(family.key),
15503
+ className: cn(
15504
+ "group relative flex w-full items-center gap-3 rounded-sm border px-3 py-2 text-left transition-colors",
15505
+ "border-grey-200 bg-background hover:bg-primary-800/10 hover:text-foreground dark:hover:bg-white/10",
15506
+ isActive && "border-grey-800 dark:border-grey-400"
15507
+ ),
15508
+ children: [
15509
+ /* @__PURE__ */ jsx(
15510
+ "span",
15511
+ {
15512
+ className: "size-4 shrink-0 rounded-full",
15513
+ style: { backgroundColor: getFamilySwatchColor(family) }
15514
+ }
15515
+ ),
15516
+ /* @__PURE__ */ jsx("span", { className: "truncate font-medium", children: family.label })
15517
+ ]
15518
+ },
15519
+ family.key
15520
+ );
15521
+ }) }) }),
15522
+ /* @__PURE__ */ jsxs("div", { className: "space-y-6", children: [
15523
+ /* @__PURE__ */ jsxs("div", { className: "grid items-start gap-6 xl:grid-cols-[minmax(0,1.5fr)_minmax(17rem,0.68fr)]", children: [
15524
+ /* @__PURE__ */ jsxs("div", { className: "space-y-6", children: [
15525
+ /* @__PURE__ */ jsx(PairPreview, { family: activeFamily, pair: selectedPair }),
15526
+ /* @__PURE__ */ jsxs(Card, { children: [
15527
+ /* @__PURE__ */ jsxs(CardHeader, { className: "gap-2 border-b", children: [
15528
+ /* @__PURE__ */ jsx(CardTitle, { className: "text-base", children: "Background tone strip" }),
15529
+ /* @__PURE__ */ jsx(CardDescription, { children: "Filled chips have a recommended AAA foreground pair. Select one to update the preview." })
15530
+ ] }),
15531
+ /* @__PURE__ */ jsxs(CardContent, { className: "space-y-4", children: [
15532
+ /* @__PURE__ */ jsx("div", { className: "grid grid-cols-5 gap-2 sm:grid-cols-7 lg:grid-cols-10 xl:grid-cols-[repeat(19,minmax(0,1fr))]", children: activeFamily.colors.map((color2) => {
15533
+ const pair = activeFamily.recommendedPairs.find(
15534
+ (item) => item.background.token === color2.token
15535
+ );
15536
+ const isSelected = selectedPair.background.token === color2.token;
15537
+ return /* @__PURE__ */ jsxs(
15538
+ "button",
15539
+ {
15540
+ type: "button",
15541
+ disabled: !pair,
15542
+ onClick: () => pair && handlePairChange(pair.id),
15543
+ className: cn(
15544
+ "group relative h-12 rounded-xl border transition-transform",
15545
+ pair ? "cursor-pointer border-grey-200 hover:scale-[1.03] dark:border-grey-700" : "cursor-not-allowed border-grey-100 dark:border-grey-800",
15546
+ isSelected && "ring-2 ring-primary-500 ring-offset-2 ring-offset-background"
15547
+ ),
15548
+ style: { backgroundColor: color2.hex },
15549
+ children: [
15550
+ pair && /* @__PURE__ */ jsx(
15551
+ "span",
15552
+ {
15553
+ className: "absolute top-1/2 left-1/2 size-3 -translate-x-1/2 -translate-y-1/2 rounded-full border border-white/30 shadow-sm",
15554
+ style: { backgroundColor: pair.foreground.hex }
15555
+ }
15556
+ ),
15557
+ /* @__PURE__ */ jsxs("span", { className: "sr-only", children: [
15558
+ color2.token,
15559
+ pair ? ` paired with ${pair.foreground.token}` : " has no recommended pair in this tool"
15560
+ ] })
15561
+ ]
15562
+ },
15563
+ color2.token
15564
+ );
15565
+ }) }),
15566
+ /* @__PURE__ */ jsxs("div", { className: "flex flex-wrap items-center gap-4 text-sm text-muted-foreground", children: [
15567
+ /* @__PURE__ */ jsxs("span", { children: [
15568
+ "Selected background:",
15569
+ " ",
15570
+ /* @__PURE__ */ jsx("strong", { className: "text-foreground", children: selectedPair.background.token })
15571
+ ] }),
15572
+ /* @__PURE__ */ jsxs("span", { children: [
15573
+ "Recommended foreground:",
15574
+ " ",
15575
+ /* @__PURE__ */ jsx("strong", { className: "text-foreground", children: selectedPair.foreground.token })
15576
+ ] })
15577
+ ] })
15578
+ ] })
15579
+ ] }),
15580
+ /* @__PURE__ */ jsxs("div", { className: "grid gap-4 lg:grid-cols-2", children: [
15581
+ /* @__PURE__ */ jsx(PairDetailCard, { color: selectedPair.background, format, role: "Background" }),
15582
+ /* @__PURE__ */ jsx(PairDetailCard, { color: selectedPair.foreground, format, role: "Foreground" })
15583
+ ] })
15584
+ ] }),
15585
+ /* @__PURE__ */ jsx("div", { className: "space-y-6", children: /* @__PURE__ */ jsxs(Card, { className: "h-fit", children: [
15586
+ /* @__PURE__ */ jsxs(CardHeader, { className: "gap-2 border-b", children: [
15587
+ /* @__PURE__ */ jsx(CardTitle, { className: "text-base", children: "Recommended pairs" }),
15588
+ /* @__PURE__ */ jsx(CardDescription, { children: "Recommended same-family combinations that meet AAA normal-text contrast." })
15589
+ ] }),
15590
+ /* @__PURE__ */ jsx(CardContent, { className: "grid gap-3", children: activeFamily.recommendedPairs.map((pair) => {
15591
+ const isActive = selectedPair.id === pair.id;
15592
+ return /* @__PURE__ */ jsxs(
15593
+ "button",
15594
+ {
15595
+ type: "button",
15596
+ onClick: () => handlePairChange(pair.id),
15597
+ className: cn(
15598
+ "rounded-2xl border p-4 text-left transition-colors",
15599
+ isActive ? "border-primary-500 bg-primary-50/70 dark:bg-primary-950/30" : "border-grey-200 hover:border-grey-400 hover:bg-grey-50 dark:border-grey-700 dark:hover:border-grey-500 dark:hover:bg-grey-900/70"
15600
+ ),
15601
+ children: [
15602
+ /* @__PURE__ */ jsxs("div", { className: "flex items-start justify-between gap-4", children: [
15603
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3", children: [
15604
+ /* @__PURE__ */ jsx(
15605
+ "div",
15606
+ {
15607
+ className: "size-11 rounded-2xl border border-grey-200 shadow-sm dark:border-grey-700",
15608
+ style: { backgroundColor: pair.background.hex }
15609
+ }
15610
+ ),
15611
+ /* @__PURE__ */ jsx(
15612
+ "div",
15613
+ {
15614
+ className: "size-11 rounded-2xl border border-grey-200 shadow-sm dark:border-grey-700",
15615
+ style: { backgroundColor: pair.foreground.hex }
15616
+ }
15617
+ )
15618
+ ] }),
15619
+ /* @__PURE__ */ jsxs("span", { className: "inline-flex items-center gap-1 rounded-full border border-grey-200 px-2.5 py-1 text-xs font-semibold text-muted-foreground dark:border-grey-700", children: [
15620
+ /* @__PURE__ */ jsx(Icons.contrast, { "data-slot": "icon", className: "size-4" }),
15621
+ pair.rating
15622
+ ] })
15623
+ ] }),
15624
+ /* @__PURE__ */ jsxs("div", { className: "mt-4 space-y-1", children: [
15625
+ /* @__PURE__ */ jsxs("p", { className: "font-medium text-foreground", children: [
15626
+ pair.background.token,
15627
+ " / ",
15628
+ pair.foreground.token
15629
+ ] }),
15630
+ /* @__PURE__ */ jsxs("p", { className: "text-sm text-muted-foreground", children: [
15631
+ pair.contrastRatio.toFixed(2),
15632
+ ":1 contrast ratio"
15633
+ ] })
15634
+ ] })
15635
+ ]
15636
+ },
15637
+ pair.id
15638
+ );
15639
+ }) })
15640
+ ] }) })
15641
+ ] }),
15642
+ /* @__PURE__ */ jsx(PairComplianceCard, { pair: selectedPair })
15643
+ ] })
15644
+ ] });
15645
+ }
15646
+ function ColorPairingTool() {
15647
+ return /* @__PURE__ */ jsx(Suspense, { fallback: /* @__PURE__ */ jsx(ColorPairingToolLoading, {}), children: /* @__PURE__ */ jsx(ColorPairingToolContent, {}) });
15648
+ }
14921
15649
  function ColorSwatches({ theme: theme2, format, viewMode }) {
14922
15650
  return /* @__PURE__ */ jsx(
14923
15651
  "div",
@@ -17397,152 +18125,10 @@ function FormMessage({ className, ...props }) {
17397
18125
  }
17398
18126
  );
17399
18127
  }
17400
- var styles3 = {
17401
- base: [
17402
- // Base
17403
- "inline-flex items-center justify-center gap-2 rounded-sm text-sm font-medium bg-transparent transition-all whitespace-nowrap cursor-pointer border-(--toggle-border) [--toggle-border:var(--color-grey-200)] text-grey-800",
17404
- // States
17405
- "data-[state=on]:bg-grey-100 data-[state=on]:text-grey-850",
17406
- // Hover
17407
- "hover:bg-grey-100 hover:text-grey-850",
17408
- // Focus
17409
- "focus:outline focus:outline-2 focus:outline-offset-0 focus:outline-(--toggle-border)",
17410
- // Dark mode
17411
- "dark:text-white",
17412
- // Dark mode states
17413
- "dark:data-[state=on]:bg-white/10 dark:data-[state=on]:text-white",
17414
- // Dark mode hover
17415
- "dark:hover:bg-white/10 dark:hover:text-white",
17416
- // Disabled
17417
- "disabled:pointer-events-none disabled:opacity-50",
17418
- // Icon
17419
- '[&_svg]:pointer-events-none [&_svg:not([class*="size-"])]:size-4 [&_svg]:shrink-0',
17420
- // Aria invalid
17421
- "aria-invalid:ring-destructive/20 aria-invalid:border-destructive",
17422
- // Aria invalid dark mode
17423
- "dark:aria-invalid:ring-destructive/40"
17424
- ],
17425
- outline: [
17426
- // Base
17427
- "text-grey-800 border [--toggle-border:var(--color-grey-300)]",
17428
- // States
17429
- "hover:[--toggle-border:var(--color-grey-400)]",
17430
- // Dark mode
17431
- "dark:[--toggle-border:white]/40",
17432
- // Dark mode states
17433
- "dark:hover:[--toggle-border:white]/50",
17434
- // Data on
17435
- "data-[state=on]:bg-primary-800/10"
17436
- ]
17437
- };
17438
- var toggleVariants = cva(styles3.base, {
17439
- variants: {
17440
- variant: {
17441
- ghost: "",
17442
- outline: clsx12(styles3.outline)
17443
- },
17444
- size: {
17445
- default: "h-9 px-2 min-w-9",
17446
- sm: "h-8 px-1.5 min-w-8",
17447
- lg: "h-10 px-2.5 min-w-10"
17448
- }
17449
- },
17450
- defaultVariants: {
17451
- variant: "ghost",
17452
- size: "default"
17453
- }
17454
- });
17455
- function Toggle({
17456
- className,
17457
- variant,
17458
- size,
17459
- ...props
17460
- }) {
17461
- return /* @__PURE__ */ jsx(
17462
- TogglePrimitive.Root,
17463
- {
17464
- "data-slot": "toggle",
17465
- className: cn(toggleVariants({ variant, size, className })),
17466
- ...props
17467
- }
17468
- );
17469
- }
17470
- var ToggleGroupContext = React5.createContext({
17471
- size: "default",
17472
- variant: "ghost"
17473
- });
17474
- function ToggleGroup({
17475
- className,
17476
- variant,
17477
- size,
17478
- children,
17479
- ...props
17480
- }) {
17481
- return /* @__PURE__ */ jsx(
17482
- ToggleGroupPrimitive.Root,
17483
- {
17484
- "data-slot": "toggle-group",
17485
- "data-variant": variant,
17486
- "data-size": size,
17487
- className: cn(
17488
- "group/toggle-group flex w-fit items-center rounded-md data-[variant=outline]:shadow-xs",
17489
- className
17490
- ),
17491
- ...props,
17492
- children: /* @__PURE__ */ jsx(ToggleGroupContext.Provider, { value: { variant, size }, children })
17493
- }
17494
- );
17495
- }
17496
- function ToggleGroupItem({
17497
- className,
17498
- children,
17499
- variant,
17500
- size,
17501
- ...props
17502
- }) {
17503
- const context = React5.useContext(ToggleGroupContext);
17504
- return /* @__PURE__ */ jsx(
17505
- ToggleGroupPrimitive.Item,
17506
- {
17507
- "data-slot": "toggle-group-item",
17508
- "data-variant": context.variant || variant,
17509
- "data-size": context.size || size,
17510
- className: cn(
17511
- toggleVariants({
17512
- variant: context.variant || variant,
17513
- size: context.size || size
17514
- }),
17515
- "min-w-0 shrink-0 rounded-none shadow-none first:rounded-l-sm last:rounded-r-sm focus:z-10 focus-visible:z-10 data-[variant=outline]:border-l-0 data-[variant=outline]:first:border-l",
17516
- className
17517
- ),
17518
- ...props,
17519
- children
17520
- }
17521
- );
17522
- }
17523
- function FormatToggle({ format, setFormat }) {
17524
- return /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2", children: [
17525
- /* @__PURE__ */ jsx("span", { className: "text-sm font-medium", children: "Format:" }),
17526
- /* @__PURE__ */ jsxs(
17527
- ToggleGroup,
17528
- {
17529
- type: "single",
17530
- value: format,
17531
- onValueChange: (value) => value && setFormat(value),
17532
- children: [
17533
- /* @__PURE__ */ jsx(ToggleGroupItem, { value: "hex", "aria-label": "HEX format", children: "HEX" }),
17534
- /* @__PURE__ */ jsx(ToggleGroupItem, { value: "rgb", "aria-label": "RGB format", children: "RGB" }),
17535
- /* @__PURE__ */ jsx(ToggleGroupItem, { value: "hsl", "aria-label": "HSL format", children: "HSL" }),
17536
- /* @__PURE__ */ jsx(ToggleGroupItem, { value: "oklch", "aria-label": "OKLCH format", children: "OKLCH" })
17537
- ]
17538
- }
17539
- )
17540
- ] });
17541
- }
17542
18128
 
17543
18129
  // package.json
17544
18130
  var package_default = {
17545
- version: "1.96.0"};
18131
+ version: "1.97.13"};
17546
18132
  var SluggerContext = React5__default.createContext(null);
17547
18133
  function flattenText(nodes) {
17548
18134
  if (nodes == null || typeof nodes === "boolean") return "";
@@ -33691,6 +34277,6 @@ var languages = [
33691
34277
  "html"
33692
34278
  ];
33693
34279
 
33694
- export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, Action2 as Action, Actions, Alert, AlertDescription, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, AlertTitle, AreaChart, Artifact, ArtifactAction, ArtifactActions, ArtifactContent, ArtifactDescription, ArtifactHeader, ArtifactTitle, AspectRatio, AuthLayout, AvailableChartColors, Avatar, AvatarFallback, AvatarImage, Badge, BadgeButton, BarChart, BarList, BaseColorSwatches, Branch, BranchMessages, BranchNext, BranchPage, BranchPrevious, BranchSelector, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator, Breadcrumbs, Button2 as Button, Calendar, CalendarDayButton, Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, Carousel, CarouselContent, CarouselItem, CarouselNext, CarouselPrevious, CategoryBar, ChainOfThought, ChainOfThoughtContent, ChainOfThoughtHeader, ChainOfThoughtImage, ChainOfThoughtSearchResult, ChainOfThoughtSearchResults, ChainOfThoughtStep, ChartContainer, ChartLegend3 as ChartLegend, ChartLegendContent, ChartStyle, ChartTooltip3 as ChartTooltip, ChartTooltipContent, Checkbox, CheckboxSmall, Code, CodeBlock, CodeBlockCopyButton, CodeDemo, CodeHighlight, Collapsible, CollapsibleContent2 as CollapsibleContent, CollapsibleTrigger2 as CollapsibleTrigger, ColorCard, ColorSwatches, ColourScale, ComboChart, Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandSeparator, CommandShortcut, Context, ContextCacheUsage, ContextContent, ContextContentBody, ContextContentFooter, ContextContentHeader, ContextInputUsage, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuPortal, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, ContextOutputUsage, ContextReasoningUsage, ContextTrigger, Conversation, ConversationContent, ConversationEmptyState, ConversationScrollButton, DataTable, DataTableColumnHeader, DataTableFacetedFilter, DataTablePagination, DataTableToolbar, DataTableViewOptions, Description4 as Description, DescriptionDetails, DescriptionList, DescriptionTerm, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, DonutChart, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, DynamicFavicon, ErrorMessage, ExpandableSearch, ExpandableSearchField, Field2 as Field, FieldGroup, FieldLabel, Fieldset2 as Fieldset, Footer, FooterAcknowledgement, FooterLegalLinks, FooterSmallPrint, FooterSocialLink, Form, FormControl, FormDescription, FormField, FormItem, FormLabel, FormMessage, FormatToggle, GenerateInterpolatedColors, Header2 as Header, Heading, HeroBannerSupportingImage, HoverCard, HoverCardContent, HoverCardTrigger, Icons, Image4 as Image, InlineCitation, InlineCitationCard, InlineCitationCardBody, InlineCitationCardTrigger, InlineCitationCarousel, InlineCitationCarouselContent, InlineCitationCarouselHeader, InlineCitationCarouselIndex, InlineCitationCarouselItem, InlineCitationSource, InlineCitationText, Input, InputOTP, InputOTPGroup, InputOTPSeparator, InputOTPSlot, Label5 as Label, Legend6 as Legend, LineChart, Link, _List as List, Listbox2 as Listbox, ListboxDescription, ListboxLabel, ListboxOption2 as ListboxOption, Loader, Loading, Logo, MainNavigation, Masthead, MegaMenu, Menubar, MenubarCheckboxItem, MenubarContent, MenubarGroup, MenubarItem, MenubarLabel, MenubarMenu, MenubarPortal, MenubarRadioGroup, MenubarRadioItem, MenubarSeparator, MenubarShortcut, MenubarSub, MenubarSubContent, MenubarSubTrigger, MenubarTrigger, Message, MessageContent, MobileHeader, MobileSearch, MultiLevelPushMenu, NSWCard, NSWCardArrow, NSWCardDescription, NSWCardIcon, NSWCardImg, NSWCardTitle, Navbar, NavbarDivider, NavbarItem, NavbarLabel, NavbarSection, NavbarSpacer, Navigation, NavigationMenu, NavigationMenuContent, NavigationMenuIndicator, NavigationMenuItem, NavigationMenuLink, NavigationMenuList, NavigationMenuTrigger, NavigationMenuViewport, NotFound, OpenIn, OpenInChatGPT, OpenInClaude, OpenInContent, OpenInScira, OpenInT3, OpenInTrigger, OpenInv0, PageHeading, Pagination, PaginationGap, PaginationList, PaginationNext, PaginationPage, PaginationPrevious, Popover, PopoverAnchor, PopoverContent, PopoverTrigger, PreWithCopy, PrevNextLinks, PrevNextLinksPageLink, Progress, ProgressBar, ProgressCircle, PromptInput, PromptInputActionAddAttachments, PromptInputActionMenu, PromptInputActionMenuContent, PromptInputActionMenuItem, PromptInputActionMenuTrigger, PromptInputAttachment, PromptInputAttachments, PromptInputBody, PromptInputButton, PromptInputSubmit, PromptInputTextarea, PromptInputToolbar, PromptInputTools, Prose, RadioGroup2 as RadioGroup, RadioGroupItem, Reasoning, ReasoningContent, ReasoningTrigger, ResizableHandle, ResizablePanel, ResizablePanelGroup, Response, ScrollArea, ScrollBar, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Separator4 as Separator, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetTitle, SheetTrigger, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarLink, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarNavigation, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, SiteSearch, Skeleton, Slider, Social, Source, Sources, SourcesContent, SourcesTrigger, SparkAreaChart, SparkBarChart, SparkLineChart, Spinner, StepIndicator, StepNavigation, Strong, SubmitButton, Suggestion, Suggestions, Switch2 as Switch, SwitchField, SwitchGroup, TabNavigation, TabNavigationLink, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableOfContents, TableRow, Tabs2 as Tabs, TabsContent, TabsList, TabsTrigger, Task, TaskContent, TaskItem, TaskItemFile, TaskTrigger, Text, TextLink, Textarea, ThemeColorPalette, ThemeProvider, ThemeSelector, ThemeSwitcher, Toaster, TocContext, TocProvider, Toggle, ToggleGroup, ToggleGroupItem, Tool, ToolContent, ToolHeader, ToolInput, ToolOutput, Tooltip5 as Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, TopLevel, TouchTarget, Tracker, Tooltip3 as TremorTooltip, ViewToggle, WebPreview, WebPreviewBody, WebPreviewNavigation, WebPreviewUrl, Wrapper, aboriginal, addStartStopToColorArray, allPalettes, badgeVariants, brand, buttonVariants, camelCase, chartColors, cn, colorDataArray, colorThemes, colors, constructCategoryColors, createColorArray, createColorData, createFormStore, darkenColor, diverging, domToSimple, focusInput, focusRing, generateColorThemes, generateDataVisColors, getColorClassName, getColorValue, getHeadings, getNodeText, getSurroundingColors, getYAxisDomain, hasErrorInput, hasOnlyOneValueForKey, humaniseVariant, interpolateColors, isLightColor, kebabCase, languages, lightenColor, navigationMenuTriggerStyle, oklchConverter, progressBarVariants, renderColorOutput, renderColorOutputToDTFM, semantic, sequential, shades, themeIndices, themeTokens, toggleVariants, truncate, useActiveSectionObserver, useDisableToc, useFormField, useIsMobile, useOnWindowResize, usePageHeadings, usePromptInputAttachments, useSelectorHeight, useSidebar, useStickyOffset, useToc };
34280
+ export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, Action2 as Action, Actions, Alert, AlertDescription, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, AlertTitle, AreaChart, Artifact, ArtifactAction, ArtifactActions, ArtifactContent, ArtifactDescription, ArtifactHeader, ArtifactTitle, AspectRatio, AuthLayout, AvailableChartColors, Avatar, AvatarFallback, AvatarImage, Badge, BadgeButton, BarChart, BarList, BaseColorSwatches, Branch, BranchMessages, BranchNext, BranchPage, BranchPrevious, BranchSelector, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator, Breadcrumbs, Button2 as Button, Calendar, CalendarDayButton, Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, Carousel, CarouselContent, CarouselItem, CarouselNext, CarouselPrevious, CategoryBar, ChainOfThought, ChainOfThoughtContent, ChainOfThoughtHeader, ChainOfThoughtImage, ChainOfThoughtSearchResult, ChainOfThoughtSearchResults, ChainOfThoughtStep, ChartContainer, ChartLegend3 as ChartLegend, ChartLegendContent, ChartStyle, ChartTooltip3 as ChartTooltip, ChartTooltipContent, Checkbox, CheckboxSmall, Code, CodeBlock, CodeBlockCopyButton, CodeDemo, CodeHighlight, Collapsible, CollapsibleContent2 as CollapsibleContent, CollapsibleTrigger2 as CollapsibleTrigger, ColorCard, ColorPairingTool, ColorSwatches, ColourScale, ComboChart, Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandSeparator, CommandShortcut, Context, ContextCacheUsage, ContextContent, ContextContentBody, ContextContentFooter, ContextContentHeader, ContextInputUsage, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuPortal, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, ContextOutputUsage, ContextReasoningUsage, ContextTrigger, Conversation, ConversationContent, ConversationEmptyState, ConversationScrollButton, DataTable, DataTableColumnHeader, DataTableFacetedFilter, DataTablePagination, DataTableToolbar, DataTableViewOptions, Description4 as Description, DescriptionDetails, DescriptionList, DescriptionTerm, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, DonutChart, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, DynamicFavicon, ErrorMessage, ExpandableSearch, ExpandableSearchField, Field2 as Field, FieldGroup, FieldLabel, Fieldset2 as Fieldset, Footer, FooterAcknowledgement, FooterLegalLinks, FooterSmallPrint, FooterSocialLink, Form, FormControl, FormDescription, FormField, FormItem, FormLabel, FormMessage, FormatToggle, GenerateInterpolatedColors, Header2 as Header, Heading, HeroBannerSupportingImage, HoverCard, HoverCardContent, HoverCardTrigger, Icons, Image4 as Image, InlineCitation, InlineCitationCard, InlineCitationCardBody, InlineCitationCardTrigger, InlineCitationCarousel, InlineCitationCarouselContent, InlineCitationCarouselHeader, InlineCitationCarouselIndex, InlineCitationCarouselItem, InlineCitationSource, InlineCitationText, Input, InputOTP, InputOTPGroup, InputOTPSeparator, InputOTPSlot, Label5 as Label, Legend6 as Legend, LineChart, Link, _List as List, Listbox2 as Listbox, ListboxDescription, ListboxLabel, ListboxOption2 as ListboxOption, Loader, Loading, Logo, MainNavigation, Masthead, MegaMenu, Menubar, MenubarCheckboxItem, MenubarContent, MenubarGroup, MenubarItem, MenubarLabel, MenubarMenu, MenubarPortal, MenubarRadioGroup, MenubarRadioItem, MenubarSeparator, MenubarShortcut, MenubarSub, MenubarSubContent, MenubarSubTrigger, MenubarTrigger, Message, MessageContent, MobileHeader, MobileSearch, MultiLevelPushMenu, NSWCard, NSWCardArrow, NSWCardDescription, NSWCardIcon, NSWCardImg, NSWCardTitle, Navbar, NavbarDivider, NavbarItem, NavbarLabel, NavbarSection, NavbarSpacer, Navigation, NavigationMenu, NavigationMenuContent, NavigationMenuIndicator, NavigationMenuItem, NavigationMenuLink, NavigationMenuList, NavigationMenuTrigger, NavigationMenuViewport, NotFound, OpenIn, OpenInChatGPT, OpenInClaude, OpenInContent, OpenInScira, OpenInT3, OpenInTrigger, OpenInv0, PageHeading, Pagination, PaginationGap, PaginationList, PaginationNext, PaginationPage, PaginationPrevious, Popover, PopoverAnchor, PopoverContent, PopoverTrigger, PreWithCopy, PrevNextLinks, PrevNextLinksPageLink, Progress, ProgressBar, ProgressCircle, PromptInput, PromptInputActionAddAttachments, PromptInputActionMenu, PromptInputActionMenuContent, PromptInputActionMenuItem, PromptInputActionMenuTrigger, PromptInputAttachment, PromptInputAttachments, PromptInputBody, PromptInputButton, PromptInputSubmit, PromptInputTextarea, PromptInputToolbar, PromptInputTools, Prose, RadioGroup2 as RadioGroup, RadioGroupItem, Reasoning, ReasoningContent, ReasoningTrigger, ResizableHandle, ResizablePanel, ResizablePanelGroup, Response, ScrollArea, ScrollBar, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Separator4 as Separator, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetTitle, SheetTrigger, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarLink, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarNavigation, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, SiteSearch, Skeleton, Slider, Social, Source, Sources, SourcesContent, SourcesTrigger, SparkAreaChart, SparkBarChart, SparkLineChart, Spinner, StepIndicator, StepNavigation, Strong, SubmitButton, Suggestion, Suggestions, Switch2 as Switch, SwitchField, SwitchGroup, TabNavigation, TabNavigationLink, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableOfContents, TableRow, Tabs2 as Tabs, TabsContent, TabsList, TabsTrigger, Task, TaskContent, TaskItem, TaskItemFile, TaskTrigger, Text, TextLink, Textarea, ThemeColorPalette, ThemeProvider, ThemeSelector, ThemeSwitcher, Toaster, TocContext, TocProvider, Toggle, ToggleGroup, ToggleGroupItem, Tool, ToolContent, ToolHeader, ToolInput, ToolOutput, Tooltip5 as Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, TopLevel, TouchTarget, Tracker, Tooltip3 as TremorTooltip, ViewToggle, WebPreview, WebPreviewBody, WebPreviewNavigation, WebPreviewUrl, Wrapper, aboriginal, addStartStopToColorArray, allPalettes, badgeVariants, brand, buttonVariants, camelCase, chartColors, cn, colorDataArray, colorThemes, colors, constructCategoryColors, createColorArray, createColorData, createFormStore, darkenColor, diverging, domToSimple, focusInput, focusRing, generateColorThemes, generateDataVisColors, getColorClassName, getColorValue, getHeadings, getNodeText, getSurroundingColors, getYAxisDomain, hasErrorInput, hasOnlyOneValueForKey, humaniseVariant, interpolateColors, isLightColor, kebabCase, languages, lightenColor, navigationMenuTriggerStyle, oklchConverter, progressBarVariants, renderColorOutput, renderColorOutputToDTFM, semantic, sequential, shades, themeIndices, themeTokens, toggleVariants, truncate, useActiveSectionObserver, useDisableToc, useFormField, useIsMobile, useOnWindowResize, usePageHeadings, usePromptInputAttachments, useSelectorHeight, useSidebar, useStickyOffset, useToc };
33695
34281
  //# sourceMappingURL=index.js.map
33696
34282
  //# sourceMappingURL=index.js.map