@yuva-devlab/ui 2.2.1 → 3.0.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/README.md +2 -3
- package/dist/components/table/table.css +29 -7
- package/dist/components.css +29 -7
- package/dist/index.cjs +27 -4
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +19 -5
- package/dist/index.d.ts +19 -5
- package/dist/index.js +27 -4
- package/dist/index.js.map +1 -1
- package/dist/styles/components.css +29 -7
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
|
|
22
22
|
## Features
|
|
23
23
|
|
|
24
|
-
- 🎨 **Multi-Brand Theme Architecture** - Seamless brand isolation across OrchestrAI,
|
|
24
|
+
- 🎨 **Multi-Brand Theme Architecture** - Seamless brand isolation across OrchestrAI, FinAI, Logs, Portal, and KnowledgeAI.
|
|
25
25
|
- 📐 **Dynamic Theme-Driven Sizing** - Automatic adaptation across brand densities (compact telemetry logs, precision finance tables, athletic kinetic scaling).
|
|
26
26
|
- ⚡ **Pure Platform CSS** - Scoped W3C Cascade Layers (`@layer dl-components, dl-layout, dl-utilities`) and semantic design tokens.
|
|
27
27
|
- 🔤 **Typography Primitives** - First-class `<Heading>` and `<Text>` primitives with semantic decoupling.
|
|
@@ -74,7 +74,7 @@ In your application's root stylesheet (e.g. `globals.css` or `app.css`), establi
|
|
|
74
74
|
@import "@yuva-devlab/ui/styles.css";
|
|
75
75
|
```
|
|
76
76
|
|
|
77
|
-
> **Tip:** You can import any theme preset from `@yuva-devlab/tokens/themes/*` (`finai`, `
|
|
77
|
+
> **Tip:** You can import any theme preset from `@yuva-devlab/tokens/themes/*` (`finai`, `logs`, `orchestrai`, `portal`).
|
|
78
78
|
|
|
79
79
|
### 2. Render Components & Typography Primitives
|
|
80
80
|
|
|
@@ -172,7 +172,6 @@ DevLab UI supports multi-brand switching at runtime using `data-brand` and `data
|
|
|
172
172
|
| Brand Key | Theme Name | Primary Aesthetic | Token Import |
|
|
173
173
|
| :----------- | :---------------- | :------------------------ | :------------------------------------------ |
|
|
174
174
|
| `finai` | **FinAI** | High-Finance Emerald | `@yuva-devlab/tokens/themes/finai.css` |
|
|
175
|
-
| `vitalai` | **VitalAI** | Athletic Volt Kinetic | `@yuva-devlab/tokens/themes/vitalai.css` |
|
|
176
175
|
| `logs` | **DevLab Logs** | High-Density Matrix Amber | `@yuva-devlab/tokens/themes/logs.css` |
|
|
177
176
|
| `orchestrai` | **OrchestrAI** | Midnight Neon Violet | `@yuva-devlab/tokens/themes/orchestrai.css` |
|
|
178
177
|
| `portal` | **DevLab Portal** | Enterprise Modern Indigo | `@yuva-devlab/tokens/themes/portal.css` |
|
|
@@ -1,32 +1,52 @@
|
|
|
1
1
|
.dl-table-wrapper {
|
|
2
2
|
position: relative;
|
|
3
3
|
width: 100%;
|
|
4
|
-
overflow: auto;
|
|
4
|
+
overflow-x: auto;
|
|
5
|
+
-webkit-overflow-scrolling: touch;
|
|
5
6
|
}
|
|
6
7
|
|
|
7
8
|
.dl-table {
|
|
8
9
|
width: 100%;
|
|
9
10
|
caption-side: bottom;
|
|
10
|
-
font-size: 0.875rem;
|
|
11
|
+
font-size: var(--text-body, 0.875rem);
|
|
11
12
|
border-collapse: collapse;
|
|
12
13
|
}
|
|
14
|
+
|
|
13
15
|
.dl-table__head tr {
|
|
14
16
|
border-bottom: 1px solid var(--border);
|
|
15
17
|
}
|
|
18
|
+
|
|
16
19
|
.dl-table__body tr:last-child {
|
|
17
20
|
border-bottom: none;
|
|
18
21
|
}
|
|
19
|
-
|
|
20
|
-
background-color: color-mix(in oklch, var(--muted) 50%, transparent);
|
|
21
|
-
}
|
|
22
|
+
|
|
22
23
|
.dl-table__foot {
|
|
23
24
|
border-top: 1px solid var(--border);
|
|
24
25
|
font-weight: 500;
|
|
25
26
|
}
|
|
27
|
+
|
|
26
28
|
.dl-table__row {
|
|
27
29
|
border-bottom: 1px solid var(--border);
|
|
28
|
-
transition:
|
|
30
|
+
transition:
|
|
31
|
+
background-color 0.15s ease,
|
|
32
|
+
color 0.15s ease;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
/* Base subtle row hover */
|
|
36
|
+
.dl-table__body tr:hover {
|
|
37
|
+
background-color: color-mix(in oklch, var(--muted) 40%, transparent);
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
/* Theme-Aware Enhanced Row Hover Highlighting */
|
|
41
|
+
.dl-table--hoverable .dl-table__body tr:hover,
|
|
42
|
+
.dl-table--hoverable .dl-table__row:hover,
|
|
43
|
+
.dl-table__row--hoverable:hover {
|
|
44
|
+
background-color: var(
|
|
45
|
+
--table-row-hover,
|
|
46
|
+
color-mix(in oklch, var(--primary) 8%, transparent)
|
|
47
|
+
);
|
|
29
48
|
}
|
|
49
|
+
|
|
30
50
|
.dl-table__head-cell {
|
|
31
51
|
height: var(--control-height-md, 2.5rem);
|
|
32
52
|
padding: var(--table-row-padding-y, 0.5rem)
|
|
@@ -36,13 +56,15 @@
|
|
|
36
56
|
color: var(--muted-foreground);
|
|
37
57
|
white-space: nowrap;
|
|
38
58
|
}
|
|
59
|
+
|
|
39
60
|
.dl-table__cell {
|
|
40
61
|
padding: var(--table-row-padding-y, 0.75rem)
|
|
41
62
|
var(--table-row-padding-x, 0.75rem);
|
|
42
63
|
vertical-align: middle;
|
|
43
64
|
}
|
|
65
|
+
|
|
44
66
|
.dl-table__caption {
|
|
45
67
|
margin-top: 1rem;
|
|
46
|
-
font-size: 0.875rem;
|
|
68
|
+
font-size: var(--text-body-sm, 0.875rem);
|
|
47
69
|
color: var(--muted-foreground);
|
|
48
70
|
}
|
package/dist/components.css
CHANGED
|
@@ -5895,32 +5895,52 @@
|
|
|
5895
5895
|
.dl-table-wrapper {
|
|
5896
5896
|
position: relative;
|
|
5897
5897
|
width: 100%;
|
|
5898
|
-
overflow: auto;
|
|
5898
|
+
overflow-x: auto;
|
|
5899
|
+
-webkit-overflow-scrolling: touch;
|
|
5899
5900
|
}
|
|
5900
5901
|
|
|
5901
5902
|
.dl-table {
|
|
5902
5903
|
width: 100%;
|
|
5903
5904
|
caption-side: bottom;
|
|
5904
|
-
font-size: 0.875rem;
|
|
5905
|
+
font-size: var(--text-body, 0.875rem);
|
|
5905
5906
|
border-collapse: collapse;
|
|
5906
5907
|
}
|
|
5908
|
+
|
|
5907
5909
|
.dl-table__head tr {
|
|
5908
5910
|
border-bottom: 1px solid var(--border);
|
|
5909
5911
|
}
|
|
5912
|
+
|
|
5910
5913
|
.dl-table__body tr:last-child {
|
|
5911
5914
|
border-bottom: none;
|
|
5912
5915
|
}
|
|
5913
|
-
|
|
5914
|
-
background-color: color-mix(in oklch, var(--muted) 50%, transparent);
|
|
5915
|
-
}
|
|
5916
|
+
|
|
5916
5917
|
.dl-table__foot {
|
|
5917
5918
|
border-top: 1px solid var(--border);
|
|
5918
5919
|
font-weight: 500;
|
|
5919
5920
|
}
|
|
5921
|
+
|
|
5920
5922
|
.dl-table__row {
|
|
5921
5923
|
border-bottom: 1px solid var(--border);
|
|
5922
|
-
transition:
|
|
5924
|
+
transition:
|
|
5925
|
+
background-color 0.15s ease,
|
|
5926
|
+
color 0.15s ease;
|
|
5927
|
+
}
|
|
5928
|
+
|
|
5929
|
+
/* Base subtle row hover */
|
|
5930
|
+
.dl-table__body tr:hover {
|
|
5931
|
+
background-color: color-mix(in oklch, var(--muted) 40%, transparent);
|
|
5923
5932
|
}
|
|
5933
|
+
|
|
5934
|
+
/* Theme-Aware Enhanced Row Hover Highlighting */
|
|
5935
|
+
.dl-table--hoverable .dl-table__body tr:hover,
|
|
5936
|
+
.dl-table--hoverable .dl-table__row:hover,
|
|
5937
|
+
.dl-table__row--hoverable:hover {
|
|
5938
|
+
background-color: var(
|
|
5939
|
+
--table-row-hover,
|
|
5940
|
+
color-mix(in oklch, var(--primary) 8%, transparent)
|
|
5941
|
+
);
|
|
5942
|
+
}
|
|
5943
|
+
|
|
5924
5944
|
.dl-table__head-cell {
|
|
5925
5945
|
height: var(--control-height-md, 2.5rem);
|
|
5926
5946
|
padding: var(--table-row-padding-y, 0.5rem)
|
|
@@ -5930,14 +5950,16 @@
|
|
|
5930
5950
|
color: var(--muted-foreground);
|
|
5931
5951
|
white-space: nowrap;
|
|
5932
5952
|
}
|
|
5953
|
+
|
|
5933
5954
|
.dl-table__cell {
|
|
5934
5955
|
padding: var(--table-row-padding-y, 0.75rem)
|
|
5935
5956
|
var(--table-row-padding-x, 0.75rem);
|
|
5936
5957
|
vertical-align: middle;
|
|
5937
5958
|
}
|
|
5959
|
+
|
|
5938
5960
|
.dl-table__caption {
|
|
5939
5961
|
margin-top: 1rem;
|
|
5940
|
-
font-size: 0.875rem;
|
|
5962
|
+
font-size: var(--text-body-sm, 0.875rem);
|
|
5941
5963
|
color: var(--muted-foreground);
|
|
5942
5964
|
}
|
|
5943
5965
|
|
package/dist/index.cjs
CHANGED
|
@@ -2037,7 +2037,18 @@ var import_lucide_react14 = require("lucide-react");
|
|
|
2037
2037
|
var React26 = __toESM(require("react"), 1);
|
|
2038
2038
|
var import_jsx_runtime26 = require("react/jsx-runtime");
|
|
2039
2039
|
var Table = React26.forwardRef(
|
|
2040
|
-
({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { className: "dl-table-wrapper", children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
2040
|
+
({ className, hoverable = false, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { className: "dl-table-wrapper", children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
2041
|
+
"table",
|
|
2042
|
+
{
|
|
2043
|
+
ref,
|
|
2044
|
+
className: cn(
|
|
2045
|
+
"dl-table",
|
|
2046
|
+
hoverable && "dl-table--hoverable",
|
|
2047
|
+
className
|
|
2048
|
+
),
|
|
2049
|
+
...props
|
|
2050
|
+
}
|
|
2051
|
+
) })
|
|
2041
2052
|
);
|
|
2042
2053
|
Table.displayName = "Table";
|
|
2043
2054
|
var TableHeader = React26.forwardRef(
|
|
@@ -2053,7 +2064,18 @@ var TableFooter = React26.forwardRef(
|
|
|
2053
2064
|
);
|
|
2054
2065
|
TableFooter.displayName = "TableFooter";
|
|
2055
2066
|
var TableRow = React26.forwardRef(
|
|
2056
|
-
({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
2067
|
+
({ className, hoverable, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
2068
|
+
"tr",
|
|
2069
|
+
{
|
|
2070
|
+
ref,
|
|
2071
|
+
className: cn(
|
|
2072
|
+
"dl-table__row",
|
|
2073
|
+
hoverable && "dl-table__row--hoverable",
|
|
2074
|
+
className
|
|
2075
|
+
),
|
|
2076
|
+
...props
|
|
2077
|
+
}
|
|
2078
|
+
)
|
|
2057
2079
|
);
|
|
2058
2080
|
TableRow.displayName = "TableRow";
|
|
2059
2081
|
var TableHead = React26.forwardRef(
|
|
@@ -2269,6 +2291,7 @@ function DataTable({
|
|
|
2269
2291
|
loading = false,
|
|
2270
2292
|
emptyState,
|
|
2271
2293
|
onRowClick,
|
|
2294
|
+
hoverable = false,
|
|
2272
2295
|
className
|
|
2273
2296
|
}) {
|
|
2274
2297
|
const [internalPage, setInternalPage] = React29.useState(1);
|
|
@@ -2334,7 +2357,7 @@ function DataTable({
|
|
|
2334
2357
|
return typeof val === "string" || typeof val === "number" ? val : index;
|
|
2335
2358
|
};
|
|
2336
2359
|
return /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)("div", { className: cn("dl-data-table-container", className), children: [
|
|
2337
|
-
/* @__PURE__ */ (0, import_jsx_runtime31.jsx)("div", { className: "dl-data-table-wrapper", children: /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)(Table, { children: [
|
|
2360
|
+
/* @__PURE__ */ (0, import_jsx_runtime31.jsx)("div", { className: "dl-data-table-wrapper", children: /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)(Table, { hoverable: hoverable || Boolean(onRowClick), children: [
|
|
2338
2361
|
/* @__PURE__ */ (0, import_jsx_runtime31.jsx)(TableHeader, { children: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(TableRow, { children: columns.map((col) => {
|
|
2339
2362
|
const isSorted = sortKey === col.key;
|
|
2340
2363
|
return /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
|
|
@@ -7023,7 +7046,7 @@ var LegalFooter = React95.forwardRef(
|
|
|
7023
7046
|
className: cn("dl-legal-footer dl-legal-footer--sidebar", className),
|
|
7024
7047
|
...props,
|
|
7025
7048
|
children: [
|
|
7026
|
-
/* @__PURE__ */ (0, import_jsx_runtime101.jsx)("span", { children: appName ? `${appName} ${version ?? ""}`.trim() : version ?? "
|
|
7049
|
+
/* @__PURE__ */ (0, import_jsx_runtime101.jsx)("span", { children: appName ? `${appName} ${version ?? ""}`.trim() : version ?? "" }),
|
|
7027
7050
|
/* @__PURE__ */ (0, import_jsx_runtime101.jsxs)("span", { children: [
|
|
7028
7051
|
"\xA9 ",
|
|
7029
7052
|
currentYear,
|