@bergetai/ui 0.13.0 → 0.13.1
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 +8 -17
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +2 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.js +8 -17
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -79,9 +79,10 @@ declare function CardFooter({ className, ...props }: React$1.ComponentProps<"div
|
|
|
79
79
|
|
|
80
80
|
declare const cardVariants: (props?: ({
|
|
81
81
|
variant?: "outlined" | "filled" | null | undefined;
|
|
82
|
-
padding?: "sm" | "md" | "lg" | "none" | null | undefined;
|
|
83
82
|
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
84
83
|
interface CardProps extends React$1.HTMLAttributes<HTMLDivElement>, VariantProps<typeof cardVariants> {
|
|
84
|
+
/** Spacing scale of the card. `sm` uses a compact 16px spacing, `default` 24px. */
|
|
85
|
+
size?: 'default' | 'sm';
|
|
85
86
|
}
|
|
86
87
|
declare const Card: React$1.ForwardRefExoticComponent<CardProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
87
88
|
|
package/dist/index.d.ts
CHANGED
|
@@ -79,9 +79,10 @@ declare function CardFooter({ className, ...props }: React$1.ComponentProps<"div
|
|
|
79
79
|
|
|
80
80
|
declare const cardVariants: (props?: ({
|
|
81
81
|
variant?: "outlined" | "filled" | null | undefined;
|
|
82
|
-
padding?: "sm" | "md" | "lg" | "none" | null | undefined;
|
|
83
82
|
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
84
83
|
interface CardProps extends React$1.HTMLAttributes<HTMLDivElement>, VariantProps<typeof cardVariants> {
|
|
84
|
+
/** Spacing scale of the card. `sm` uses a compact 16px spacing, `default` 24px. */
|
|
85
|
+
size?: 'default' | 'sm';
|
|
85
86
|
}
|
|
86
87
|
declare const Card: React$1.ForwardRefExoticComponent<CardProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
87
88
|
|
package/dist/index.js
CHANGED
|
@@ -597,31 +597,25 @@ function CardFooter({ className, ...props }) {
|
|
|
597
597
|
|
|
598
598
|
// src/components/card/Card.tsx
|
|
599
599
|
import { jsx as jsx7 } from "react/jsx-runtime";
|
|
600
|
-
var cardVariants = cva3("
|
|
600
|
+
var cardVariants = cva3("ring-0", {
|
|
601
601
|
variants: {
|
|
602
602
|
variant: {
|
|
603
603
|
outlined: "bg-transparent border border-berget-border-subtle",
|
|
604
604
|
filled: "bg-berget-card-filled-bg border border-berget-border-subtle"
|
|
605
|
-
},
|
|
606
|
-
padding: {
|
|
607
|
-
none: "p-0",
|
|
608
|
-
sm: "p-3 sm:p-4",
|
|
609
|
-
md: "p-4 sm:p-6",
|
|
610
|
-
lg: "p-6 sm:p-8"
|
|
611
605
|
}
|
|
612
606
|
},
|
|
613
607
|
defaultVariants: {
|
|
614
|
-
variant: "outlined"
|
|
615
|
-
padding: "md"
|
|
608
|
+
variant: "outlined"
|
|
616
609
|
}
|
|
617
610
|
});
|
|
618
611
|
var Card2 = React5.forwardRef(
|
|
619
|
-
({ className, variant,
|
|
612
|
+
({ className, variant, size, children, ...props }, ref) => {
|
|
620
613
|
return /* @__PURE__ */ jsx7(
|
|
621
614
|
Card,
|
|
622
615
|
{
|
|
623
616
|
ref,
|
|
624
|
-
|
|
617
|
+
size,
|
|
618
|
+
className: cn(cardVariants({ variant }), className),
|
|
625
619
|
...props,
|
|
626
620
|
children
|
|
627
621
|
}
|
|
@@ -936,7 +930,6 @@ var ModelCard = React9.forwardRef(
|
|
|
936
930
|
Card2,
|
|
937
931
|
{
|
|
938
932
|
variant: "filled",
|
|
939
|
-
padding: "none",
|
|
940
933
|
className: "relative flex h-full flex-col bg-berget-card-filled-bg p-5 transition-all hover:bg-[color-mix(in_oklab,var(--berget-brand-granite-100)_5%,var(--berget-card-filled-bg))] sm:p-6",
|
|
941
934
|
children: [
|
|
942
935
|
lifecycle && /* @__PURE__ */ jsx11("div", { className: "absolute top-0 right-0 z-10 overflow-hidden rounded-bl-berget-sm", children: /* @__PURE__ */ jsx11(
|
|
@@ -1629,7 +1622,7 @@ function Input({ className, type, ...props }) {
|
|
|
1629
1622
|
type,
|
|
1630
1623
|
"data-slot": "input",
|
|
1631
1624
|
className: cn6(
|
|
1632
|
-
"h-8 w-full min-w-0 rounded-lg border border-input bg-
|
|
1625
|
+
"h-8 w-full min-w-0 rounded-lg border border-input bg-input/30 px-2.5 py-1 text-base transition-colors outline-none file:inline-flex file:h-6 file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:pointer-events-none disabled:cursor-not-allowed disabled:bg-input/50 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 md:text-sm dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40",
|
|
1633
1626
|
className
|
|
1634
1627
|
),
|
|
1635
1628
|
...props
|
|
@@ -3105,7 +3098,6 @@ var Checkbox2 = React18.forwardRef(
|
|
|
3105
3098
|
ref,
|
|
3106
3099
|
id: checkboxId,
|
|
3107
3100
|
disabled,
|
|
3108
|
-
nativeButton: true,
|
|
3109
3101
|
"aria-invalid": !!error,
|
|
3110
3102
|
"aria-describedby": error ? errorId : void 0,
|
|
3111
3103
|
"aria-label": ariaLabel || label || void 0,
|
|
@@ -3210,7 +3202,6 @@ var Switch = React19.forwardRef(
|
|
|
3210
3202
|
ref,
|
|
3211
3203
|
id: switchId,
|
|
3212
3204
|
disabled,
|
|
3213
|
-
nativeButton: true,
|
|
3214
3205
|
"aria-invalid": !!error,
|
|
3215
3206
|
"aria-describedby": error ? errorId : void 0,
|
|
3216
3207
|
"aria-label": ariaLabel || label || void 0,
|
|
@@ -3281,7 +3272,7 @@ function SelectTrigger({
|
|
|
3281
3272
|
"data-slot": "select-trigger",
|
|
3282
3273
|
"data-size": size,
|
|
3283
3274
|
className: cn15(
|
|
3284
|
-
"flex w-fit cursor-pointer items-center justify-between gap-1.5 rounded-lg border border-input bg-
|
|
3275
|
+
"flex w-fit cursor-pointer items-center justify-between gap-1.5 rounded-lg border border-input bg-input/30 py-2 pr-2 pl-2.5 text-sm whitespace-nowrap transition-colors outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 data-placeholder:text-muted-foreground data-[size=default]:h-8 data-[size=sm]:h-7 data-[size=sm]:rounded-[min(var(--radius-md),10px)] *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-1.5 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
3285
3276
|
className
|
|
3286
3277
|
),
|
|
3287
3278
|
...props,
|
|
@@ -3529,7 +3520,7 @@ function Textarea({ className, ...props }) {
|
|
|
3529
3520
|
{
|
|
3530
3521
|
"data-slot": "textarea",
|
|
3531
3522
|
className: cn18(
|
|
3532
|
-
"flex field-sizing-content min-h-16 w-full rounded-lg border border-input bg-
|
|
3523
|
+
"flex field-sizing-content min-h-16 w-full rounded-lg border border-input bg-input/30 px-2.5 py-2 text-base transition-colors outline-none placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:bg-input/50 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 md:text-sm dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40",
|
|
3533
3524
|
className
|
|
3534
3525
|
),
|
|
3535
3526
|
...props
|