@syscore/ui-library 2.0.0-beta-publish-workflow-beta.12 → 2.0.0-beta-publish-workflow-beta.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/client/components/ui/alert.tsx +4 -0
- package/client/components/ui/button.tsx +5 -0
- package/client/components/ui/card.tsx +43 -3
- package/client/components/ui/copy.tsx +1 -1
- package/client/components/ui/dialog.tsx +35 -8
- package/client/components/ui/layout.tsx +11 -12
- package/client/components/ui/typography.tsx +7 -0
- package/client/global.css +230 -26
- package/dist/index.cjs.js +1 -1
- package/dist/index.d.ts +3 -0
- package/dist/index.es.js +100 -43
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -511,6 +511,7 @@ import { StatusPill } from '../client/components/ui/status-pill';
|
|
|
511
511
|
import { StepItem } from '../client/components/ui/stepper';
|
|
512
512
|
import { Stepper } from '../client/components/ui/stepper';
|
|
513
513
|
import { StepperProps } from '../client/components/ui/stepper';
|
|
514
|
+
import { Swatch } from '../client/components/ui/card';
|
|
514
515
|
import { Switch } from '../client/components/ui/switch';
|
|
515
516
|
import { SwitchV01 } from '../client/components/ui/switch-v01';
|
|
516
517
|
import { SwitchV01Props } from '../client/components/ui/switch-v01';
|
|
@@ -1664,6 +1665,8 @@ export { Stepper }
|
|
|
1664
1665
|
|
|
1665
1666
|
export { StepperProps }
|
|
1666
1667
|
|
|
1668
|
+
export { Swatch }
|
|
1669
|
+
|
|
1667
1670
|
export { Switch }
|
|
1668
1671
|
|
|
1669
1672
|
export { SwitchV01 }
|
package/dist/index.es.js
CHANGED
|
@@ -710,6 +710,11 @@ const buttonVariants = cva(
|
|
|
710
710
|
"primary-dark": "button--primary-dark",
|
|
711
711
|
"secondary-light": "button--secondary-light",
|
|
712
712
|
"tertiary-light": "button--tertiary-light",
|
|
713
|
+
// Same pill shape as tertiary-light, red instead of blue — for a
|
|
714
|
+
// destructive inline action (e.g. "Remove" on an applied discount
|
|
715
|
+
// code) that isn't severe enough for a confirm dialog but shouldn't
|
|
716
|
+
// read as a neutral/affirmative action either.
|
|
717
|
+
"tertiary-danger": "button--tertiary-danger",
|
|
713
718
|
// Utility variants
|
|
714
719
|
"general-primary": "button--general-primary",
|
|
715
720
|
"general-secondary": "button--general-secondary",
|
|
@@ -1148,6 +1153,7 @@ const Text = React.forwardRef(
|
|
|
1148
1153
|
className,
|
|
1149
1154
|
variant = "body-base",
|
|
1150
1155
|
as,
|
|
1156
|
+
loose = false,
|
|
1151
1157
|
tone = "default",
|
|
1152
1158
|
strong = false,
|
|
1153
1159
|
align,
|
|
@@ -1162,6 +1168,7 @@ const Text = React.forwardRef(
|
|
|
1162
1168
|
ref,
|
|
1163
1169
|
className: cn(
|
|
1164
1170
|
typographyVariants({ variant }),
|
|
1171
|
+
loose && "typography--loose",
|
|
1165
1172
|
tone === "muted" && "typo--muted",
|
|
1166
1173
|
strong && "typo--strong",
|
|
1167
1174
|
align === "center" && "typo--center",
|
|
@@ -1218,6 +1225,10 @@ const cardVariants = cva("card", {
|
|
|
1218
1225
|
elevated: "card--elevated",
|
|
1219
1226
|
filled: "card--filled",
|
|
1220
1227
|
interactive: "card--interactive",
|
|
1228
|
+
// A dark, colored promo banner (e.g. the WELL AP credentials page's
|
|
1229
|
+
// "WELL Forum" callout) — content on it needs the inverse text tone,
|
|
1230
|
+
// same as any other dark surface in the app.
|
|
1231
|
+
gradient: "card--gradient",
|
|
1221
1232
|
/** A bordered 16px-radius panel for a side summary. */
|
|
1222
1233
|
panel: "card--panel",
|
|
1223
1234
|
/** A bordered 12px-radius box nested inside a form or another card. */
|
|
@@ -1225,7 +1236,8 @@ const cardVariants = cva("card", {
|
|
|
1225
1236
|
},
|
|
1226
1237
|
padding: {
|
|
1227
1238
|
default: "",
|
|
1228
|
-
spacious: "card--padding-spacious"
|
|
1239
|
+
spacious: "card--padding-spacious",
|
|
1240
|
+
compact: "card--padding-compact"
|
|
1229
1241
|
},
|
|
1230
1242
|
/** `relaxed` — more air between heading, description and content (dense back-office pages). */
|
|
1231
1243
|
spacing: {
|
|
@@ -1254,7 +1266,14 @@ const Card = React.forwardRef(
|
|
|
1254
1266
|
)
|
|
1255
1267
|
);
|
|
1256
1268
|
Card.displayName = "Card";
|
|
1257
|
-
const CardHeader = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
1269
|
+
const CardHeader = React.forwardRef(({ className, tinted = false, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
1270
|
+
"div",
|
|
1271
|
+
{
|
|
1272
|
+
ref,
|
|
1273
|
+
className: cn("card-header", tinted && "card-header--tinted", className),
|
|
1274
|
+
...props
|
|
1275
|
+
}
|
|
1276
|
+
));
|
|
1258
1277
|
CardHeader.displayName = "CardHeader";
|
|
1259
1278
|
const CardTitle = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
1260
1279
|
"h3",
|
|
@@ -1314,6 +1333,17 @@ const CardBadge = React.forwardRef(
|
|
|
1314
1333
|
CardBadge.displayName = "CardBadge";
|
|
1315
1334
|
const CardActions = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx("div", { ref, className: cn("card-actions", className), ...props }));
|
|
1316
1335
|
CardActions.displayName = "CardActions";
|
|
1336
|
+
const Swatch = React.forwardRef(
|
|
1337
|
+
({ className, tone = "primary", size = "md", ...props }, ref) => /* @__PURE__ */ jsx(
|
|
1338
|
+
"div",
|
|
1339
|
+
{
|
|
1340
|
+
ref,
|
|
1341
|
+
className: cn("swatch", `swatch--${tone}`, `swatch--${size}`, className),
|
|
1342
|
+
...props
|
|
1343
|
+
}
|
|
1344
|
+
)
|
|
1345
|
+
);
|
|
1346
|
+
Swatch.displayName = "Swatch";
|
|
1317
1347
|
const CardMetric = React.forwardRef(
|
|
1318
1348
|
({ className, value, label, trend, trendValue, ...props }, ref) => /* @__PURE__ */ jsxs("div", { ref, className: cn("card-metric", className), ...props, children: [
|
|
1319
1349
|
/* @__PURE__ */ jsx("span", { className: "card-metric__value", children: value }),
|
|
@@ -3629,7 +3659,11 @@ const alertVariants = cva(
|
|
|
3629
3659
|
variants: {
|
|
3630
3660
|
variant: {
|
|
3631
3661
|
default: "alert--default",
|
|
3632
|
-
destructive: "alert--destructive"
|
|
3662
|
+
destructive: "alert--destructive",
|
|
3663
|
+
// Neutral help/explainer callout — e.g. the activity-type guidance
|
|
3664
|
+
// text on the WELL AP "Report CE hours" form. Blue, not red/coral:
|
|
3665
|
+
// informational, not a warning or error.
|
|
3666
|
+
info: "alert--info"
|
|
3633
3667
|
}
|
|
3634
3668
|
},
|
|
3635
3669
|
defaultVariants: {
|
|
@@ -4749,53 +4783,68 @@ function DialogContent({
|
|
|
4749
4783
|
className: cn(
|
|
4750
4784
|
"dialog-content",
|
|
4751
4785
|
size === "fullscreen" && "dialog-content--fullscreen",
|
|
4786
|
+
size === "lg" && "dialog-content--lg",
|
|
4752
4787
|
appearance === "form" && "dialog-content--form",
|
|
4753
4788
|
className
|
|
4754
4789
|
),
|
|
4755
4790
|
...props,
|
|
4756
|
-
children: /* @__PURE__ */ jsxs(
|
|
4757
|
-
|
|
4758
|
-
|
|
4759
|
-
|
|
4760
|
-
|
|
4761
|
-
|
|
4762
|
-
|
|
4763
|
-
|
|
4791
|
+
children: /* @__PURE__ */ jsxs(
|
|
4792
|
+
"div",
|
|
4793
|
+
{
|
|
4794
|
+
className: cn(
|
|
4795
|
+
"dialog-content-wrapper",
|
|
4796
|
+
size === "lg" && "dialog-content-wrapper--lg"
|
|
4797
|
+
),
|
|
4798
|
+
children: [
|
|
4799
|
+
/* @__PURE__ */ jsx(
|
|
4800
|
+
"div",
|
|
4801
|
+
{
|
|
4802
|
+
className: cn(
|
|
4803
|
+
"dialog-content-inner",
|
|
4804
|
+
size === "fullscreen" && "dialog-content-inner--fullscreen",
|
|
4805
|
+
size === "lg" && "dialog-content-inner--lg",
|
|
4806
|
+
innerClassName
|
|
4807
|
+
),
|
|
4808
|
+
children
|
|
4809
|
+
}
|
|
4764
4810
|
),
|
|
4765
|
-
|
|
4766
|
-
|
|
4767
|
-
|
|
4768
|
-
|
|
4769
|
-
|
|
4770
|
-
|
|
4771
|
-
|
|
4772
|
-
|
|
4773
|
-
|
|
4774
|
-
|
|
4775
|
-
|
|
4776
|
-
|
|
4777
|
-
|
|
4778
|
-
|
|
4779
|
-
|
|
4780
|
-
)
|
|
4781
|
-
|
|
4782
|
-
|
|
4783
|
-
|
|
4784
|
-
|
|
4785
|
-
|
|
4786
|
-
|
|
4787
|
-
] })
|
|
4811
|
+
showCloseButton && /* @__PURE__ */ jsxs(
|
|
4812
|
+
SheetPrimitive.Close,
|
|
4813
|
+
{
|
|
4814
|
+
"data-slot": "dialog-close",
|
|
4815
|
+
className: "dialog-close",
|
|
4816
|
+
children: [
|
|
4817
|
+
/* @__PURE__ */ jsx(
|
|
4818
|
+
UtilityClose,
|
|
4819
|
+
{
|
|
4820
|
+
className: cn(
|
|
4821
|
+
"dialog-close-icon text-gray-400 hover:text-gray-600 transition-colors duration-200 ",
|
|
4822
|
+
closeClassName
|
|
4823
|
+
)
|
|
4824
|
+
}
|
|
4825
|
+
),
|
|
4826
|
+
/* @__PURE__ */ jsx("span", { className: "sr-only", children: "Close" })
|
|
4827
|
+
]
|
|
4828
|
+
}
|
|
4829
|
+
)
|
|
4830
|
+
]
|
|
4831
|
+
}
|
|
4832
|
+
)
|
|
4788
4833
|
}
|
|
4789
4834
|
)
|
|
4790
4835
|
}
|
|
4791
4836
|
) });
|
|
4792
4837
|
}
|
|
4793
|
-
function DialogHeader({
|
|
4838
|
+
function DialogHeader({
|
|
4839
|
+
className,
|
|
4840
|
+
spacious = false,
|
|
4841
|
+
...props
|
|
4842
|
+
}) {
|
|
4794
4843
|
return /* @__PURE__ */ jsx(
|
|
4795
4844
|
"div",
|
|
4796
4845
|
{
|
|
4797
4846
|
"data-slot": "dialog-header",
|
|
4798
|
-
className: cn("dialog-header", className),
|
|
4847
|
+
className: cn("dialog-header", spacious && "dialog-header--spacious", className),
|
|
4799
4848
|
...props
|
|
4800
4849
|
}
|
|
4801
4850
|
);
|
|
@@ -4812,13 +4861,15 @@ function DialogFooter({ className, ...props }) {
|
|
|
4812
4861
|
}
|
|
4813
4862
|
function DialogTitle({
|
|
4814
4863
|
className,
|
|
4864
|
+
size = "default",
|
|
4815
4865
|
...props
|
|
4816
4866
|
}) {
|
|
4867
|
+
const sizeClass2 = size === "lg" ? "heading-small" : size === "md" ? "heading-xsmall" : "heading-xxsmall";
|
|
4817
4868
|
return /* @__PURE__ */ jsx(
|
|
4818
4869
|
SheetPrimitive.Title,
|
|
4819
4870
|
{
|
|
4820
4871
|
"data-slot": "dialog-title",
|
|
4821
|
-
className: cn("dialog-title
|
|
4872
|
+
className: cn("dialog-title text-center", sizeClass2, className),
|
|
4822
4873
|
...props
|
|
4823
4874
|
}
|
|
4824
4875
|
);
|
|
@@ -5368,9 +5419,13 @@ const Grid = React.forwardRef(
|
|
|
5368
5419
|
),
|
|
5369
5420
|
style: {
|
|
5370
5421
|
gridTemplateColumns: template,
|
|
5371
|
-
|
|
5372
|
-
|
|
5373
|
-
|
|
5422
|
+
// Never emit the `gap` shorthand alongside `rowGap`/`columnGap` —
|
|
5423
|
+
// React warns on mixing a shorthand and its longhands in the same
|
|
5424
|
+
// style object across re-renders, even when one side is
|
|
5425
|
+
// `undefined`. Decomposing into the two longhands always, with
|
|
5426
|
+
// `gap` as their shared fallback, avoids the shorthand entirely.
|
|
5427
|
+
rowGap: gapCss(rowGap ?? gap),
|
|
5428
|
+
columnGap: gapCss(resolvedColumnGap ?? gap),
|
|
5374
5429
|
width: toCssSize(width),
|
|
5375
5430
|
height: toCssSize(height),
|
|
5376
5431
|
maxWidth: toCssSize(maxWidth),
|
|
@@ -5440,9 +5495,10 @@ const Columns = React.forwardRef(
|
|
|
5440
5495
|
),
|
|
5441
5496
|
style: {
|
|
5442
5497
|
gridTemplateColumns: template ?? ColumnsPresetMap[preset],
|
|
5443
|
-
|
|
5444
|
-
rowGap
|
|
5445
|
-
|
|
5498
|
+
// See Grid's identical comment — never mix the `gap` shorthand
|
|
5499
|
+
// with `rowGap`/`columnGap` longhands in the same style object.
|
|
5500
|
+
rowGap: gapCss(rowGap ?? gap),
|
|
5501
|
+
columnGap: gapCss(resolvedColumnGap ?? gap),
|
|
5446
5502
|
...style
|
|
5447
5503
|
},
|
|
5448
5504
|
...props
|
|
@@ -18806,6 +18862,7 @@ export {
|
|
|
18806
18862
|
StandardNavigation,
|
|
18807
18863
|
StatusPill,
|
|
18808
18864
|
Stepper,
|
|
18865
|
+
Swatch,
|
|
18809
18866
|
Switch,
|
|
18810
18867
|
SwitchV01,
|
|
18811
18868
|
SystemBar,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@syscore/ui-library",
|
|
3
|
-
"version": "2.0.0-beta-publish-workflow-beta.
|
|
3
|
+
"version": "2.0.0-beta-publish-workflow-beta.14",
|
|
4
4
|
"description": "A comprehensive React component library built with Radix UI, Tailwind CSS, and TypeScript",
|
|
5
5
|
"private": false,
|
|
6
6
|
"type": "module",
|