@nadicodeai/ui 12.1.22 → 12.1.23
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/components/badge.js
CHANGED
|
@@ -2,7 +2,7 @@ import { mergeProps } from "@base-ui/react/merge-props";
|
|
|
2
2
|
import { useRender } from "@base-ui/react/use-render";
|
|
3
3
|
import { cva } from "class-variance-authority";
|
|
4
4
|
import { cn } from "../lib/utils.js";
|
|
5
|
-
const badgeVariants = cva("group/badge inline-flex h-5 w-fit shrink-0 items-center justify-center gap-1 overflow-hidden rounded-md border border-transparent px-2 py-
|
|
5
|
+
const badgeVariants = cva("group/badge inline-flex min-h-5 w-fit max-w-full shrink-0 items-center justify-center gap-1 overflow-hidden rounded-md border border-transparent px-2 py-px text-xs font-medium transition-[background-color,border-color,color,opacity] duration-[var(--nc-duration-confirm)] ease-[var(--nc-ease-out-strong)] has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 aria-invalid:border-destructive [&>svg]:pointer-events-none [&>svg]:size-3!", {
|
|
6
6
|
variants: {
|
|
7
7
|
variant: {
|
|
8
8
|
default: "bg-primary text-primary-foreground [a]:hover:bg-primary-hover",
|
|
@@ -27,12 +27,14 @@ export declare function ObjectOverview({ primary, supporting, }: {
|
|
|
27
27
|
primary: ReactNode;
|
|
28
28
|
supporting: ReactNode;
|
|
29
29
|
}): import("react").JSX.Element;
|
|
30
|
-
export declare function ObjectSection({ title, description, action, icon, children, }: {
|
|
30
|
+
export declare function ObjectSection({ title, description, action, icon, children, headingLevel, }: {
|
|
31
31
|
title: string;
|
|
32
32
|
description?: ReactNode;
|
|
33
33
|
action?: ReactNode;
|
|
34
34
|
icon?: ReactNode;
|
|
35
35
|
children: ReactNode;
|
|
36
|
+
/** A card titles a section of its page; nest it deeper only under another heading. */
|
|
37
|
+
headingLevel?: 2 | 3 | 4;
|
|
36
38
|
}): import("react").JSX.Element;
|
|
37
39
|
export declare function ObjectFacts({ facts, density, }: {
|
|
38
40
|
facts: readonly ObjectFact[];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"object-workspace.d.ts","sourceRoot":"","sources":["../../src/components/object-workspace.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAMvC,MAAM,MAAM,UAAU,GAAG;IACvB,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,SAAS,CAAC;IACjB,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB;;;OAGG;IACH,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB,CAAC;AAEF,MAAM,MAAM,0BAA0B,GAAG;IACvC,KAAK,EAAE,SAAS,UAAU,EAAE,CAAC;IAC7B,KAAK,EAAE,MAAM,CAAC;CACf,CAAC;AAEF,wBAAgB,cAAc,CAAC,EAC7B,MAAM,EACN,KAAK,EACL,WAAW,EACX,QAAQ,EACR,MAAM,EACN,UAAU,EACV,MAAiB,EACjB,OAAO,GACR,EAAE;IACD,MAAM,EAAE,SAAS,CAAC;IAClB,KAAK,EAAE,SAAS,CAAC;IACjB,WAAW,CAAC,EAAE,SAAS,CAAC;IACxB,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,MAAM,CAAC,EAAE,SAAS,CAAC;IACnB,UAAU,CAAC,EAAE,SAAS,CAAC;IACvB,MAAM,CAAC,EAAE,QAAQ,GAAG,SAAS,CAAC;IAC9B,OAAO,CAAC,EAAE,0BAA0B,CAAC;CACtC,+
|
|
1
|
+
{"version":3,"file":"object-workspace.d.ts","sourceRoot":"","sources":["../../src/components/object-workspace.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAMvC,MAAM,MAAM,UAAU,GAAG;IACvB,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,SAAS,CAAC;IACjB,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB;;;OAGG;IACH,KAAK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AAS,CAAC;CACjC,+BAkCA"}
|
|
@@ -5,13 +5,13 @@ import { ObjectIdentitySupport } from "../internal/object-identity-support.js";
|
|
|
5
5
|
export function ObjectIdentity({ visual, title, description, metadata, action, editAction, layout = "inline", support, }) {
|
|
6
6
|
return (_jsxs(Card, { className: layout === "inline" && support
|
|
7
7
|
? "min-w-0 lg:grid lg:grid-cols-[minmax(0,1fr)_minmax(0,1.25fr)] lg:items-center"
|
|
8
|
-
: "min-w-0", render: _jsx("header", { "data-slot": "object-identity" }), size: "sm", children: [_jsxs(CardHeader, { children: [_jsxs("div", { className: "flex min-w-0 items-center gap-4", children: [_jsx("div", { className: "shrink-0", children: visual }), _jsxs("div", { className: "grid min-w-0 gap-1.5", children: [_jsx(CardTitle, {
|
|
8
|
+
: "min-w-0", render: _jsx("header", { "data-slot": "object-identity" }), size: "sm", children: [_jsxs(CardHeader, { children: [_jsxs("div", { className: "flex min-w-0 items-center gap-4", children: [_jsx("div", { className: "shrink-0", children: visual }), _jsxs("div", { className: "grid min-w-0 gap-1.5", children: [_jsx(CardTitle, { className: "break-words", children: title }), description ? _jsx(CardDescription, { children: description }) : null, metadata ? (_jsx("div", { className: "flex flex-wrap items-center gap-x-4 gap-y-1 text-xs text-muted-foreground", children: metadata })) : null] })] }), editAction ? _jsx(CardAction, { children: editAction }) : null] }), support || action ? (_jsxs(CardContent, { className: "flex min-w-0 flex-wrap items-start gap-4", children: [support ? (_jsx(ObjectIdentitySupport, { label: support.label, children: _jsx(ObjectFacts, { density: "compact", facts: support.facts }) })) : null, action ? _jsx("div", { className: "min-w-0 flex-1 basis-full", children: action }) : null] })) : null] }));
|
|
9
9
|
}
|
|
10
10
|
export function ObjectOverview({ primary, supporting, }) {
|
|
11
11
|
return (_jsxs("div", { "data-slot": "object-overview", className: "grid min-w-0 items-start gap-6 xl:grid-cols-[minmax(0,1.6fr)_minmax(0,1fr)]", children: [_jsx("div", { className: "grid min-w-0 gap-6", children: primary }), _jsx("div", { className: "grid min-w-0 gap-6", children: supporting })] }));
|
|
12
12
|
}
|
|
13
|
-
export function ObjectSection({ title, description, action, icon, children, }) {
|
|
14
|
-
return (_jsxs(Card, { "data-slot": "object-section", children: [_jsxs(CardHeader, { children: [
|
|
13
|
+
export function ObjectSection({ title, description, action, icon, children, headingLevel = 2, }) {
|
|
14
|
+
return (_jsxs(Card, { "data-slot": "object-section", children: [_jsxs(CardHeader, { children: [_jsxs(CardTitle, { role: "heading", "aria-level": headingLevel, className: "flex items-center gap-2", children: [icon ? (_jsx("span", { "aria-hidden": "true", className: "text-muted-foreground [&_svg]:size-4", children: icon })) : null, title] }), description ? _jsx(CardDescription, { children: description }) : null, action ? _jsx(CardAction, { children: action }) : null] }), _jsx(CardContent, { children: children })] }));
|
|
15
15
|
}
|
|
16
16
|
export function ObjectFacts({ facts, density = "default", }) {
|
|
17
17
|
return (_jsx("dl", { "data-density": density, "data-slot": "object-facts", className: density === "compact"
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nadicodeai/ui",
|
|
3
|
-
"version": "12.1.
|
|
3
|
+
"version": "12.1.23",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
@@ -71,7 +71,7 @@
|
|
|
71
71
|
"@assistant-ui/react": "0.15.21",
|
|
72
72
|
"@assistant-ui/react-markdown": "0.14.16",
|
|
73
73
|
"@base-ui/react": "^1.8.0",
|
|
74
|
-
"@nadicodeai/design-system": "12.1.
|
|
74
|
+
"@nadicodeai/design-system": "12.1.23",
|
|
75
75
|
"class-variance-authority": "^0.7.1",
|
|
76
76
|
"clsx": "^2.1.1",
|
|
77
77
|
"cmdk": "^1.1.1",
|