@cjlapao/ui-kit 0.2.27 → 0.2.28
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 +13 -8
- package/dist/index.cjs.map +1 -1
- package/dist/index.css +2857 -1901
- package/dist/index.js +13 -8
- package/dist/index.js.map +1 -1
- package/dist/markdown.cjs +1 -1
- package/dist/markdown.cjs.map +1 -1
- package/dist/markdown.js +1 -1
- package/dist/markdown.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -17578,7 +17578,7 @@ var ScrollArea = ({
|
|
|
17578
17578
|
...horizontal ? null : { overflowX: "hidden" }
|
|
17579
17579
|
},
|
|
17580
17580
|
className: classNames35(
|
|
17581
|
-
"h-full w-full max-h-[inherit] overflow-auto rounded-[inherit] outline-none",
|
|
17581
|
+
"relative z-0 h-full w-full max-h-[inherit] overflow-auto rounded-[inherit] outline-none",
|
|
17582
17582
|
// `max-height: inherit` is what makes a `max-h-*` frame work: a
|
|
17583
17583
|
// percentage height would resolve against an auto-height parent
|
|
17584
17584
|
// and the viewport would simply grow past the frame's cap, get
|
|
@@ -57585,10 +57585,10 @@ function TableComponent({
|
|
|
57585
57585
|
const highlightRowClass = isHighlighted ? getHighlightRowClass(controlColor) : "";
|
|
57586
57586
|
const isStripedRow = striped && originalIndex % 2 === 1;
|
|
57587
57587
|
const baseRowBgClass = isStripedRow ? getStripedRowClass(tone) : "bg-white dark:bg-neutral-900";
|
|
57588
|
-
const rowHoverClass = !isSelected && !isHighlighted && hoverable ? rowHoverClassName?.(row, originalIndex) ?? (isStripedRow ? getStripedRowHoverClass(tone) : getLightRowHoverClass(tone)) : void 0;
|
|
57588
|
+
const rowHoverClass = (!isSelected && !isHighlighted && hoverable ? rowHoverClassName?.(row, originalIndex) ?? (isStripedRow ? getStripedRowHoverClass(tone) : getLightRowHoverClass(tone)) : void 0)?.replace(/group-hover:/g, "group-hover/table-row:");
|
|
57589
57589
|
const rowClasses = classNames96(
|
|
57590
57590
|
cellPadding,
|
|
57591
|
-
"group",
|
|
57591
|
+
"group group/table-row",
|
|
57592
57592
|
isSelected ? selectedClass : isHighlighted ? highlightRowClass : isStripedRow && getStripedRowClass(tone),
|
|
57593
57593
|
isHighlighted && hoverable && "hover:brightness-95",
|
|
57594
57594
|
"transition-colors duration-150 ease-out",
|
|
@@ -57600,6 +57600,11 @@ function TableComponent({
|
|
|
57600
57600
|
{
|
|
57601
57601
|
role: "row",
|
|
57602
57602
|
className: rowClasses,
|
|
57603
|
+
style: {
|
|
57604
|
+
// Sticky cells must blend hover over the same stripe as normal cells.
|
|
57605
|
+
"--ui-table-row-stripe-light": isStripedRow && !isSelected && !isHighlighted ? `color-mix(in oklab, var(--color-${NEUTRAL_TONES.includes(tone) ? "neutral" : tone}-50) 55%, transparent)` : "transparent",
|
|
57606
|
+
"--ui-table-row-stripe-dark": isStripedRow && !isSelected && !isHighlighted ? NEUTRAL_TONES.includes(tone) ? "color-mix(in oklab, var(--color-neutral-800) 15%, transparent)" : `color-mix(in oklab, var(--color-${tone}-500) 8%, transparent)` : "transparent"
|
|
57607
|
+
},
|
|
57603
57608
|
onClick: onRowClick ? () => onRowClick(row, originalIndex) : void 0,
|
|
57604
57609
|
children: [
|
|
57605
57610
|
showGroupExpandCol && /* @__PURE__ */ jsx287(
|
|
@@ -57607,10 +57612,10 @@ function TableComponent({
|
|
|
57607
57612
|
{
|
|
57608
57613
|
role: "cell",
|
|
57609
57614
|
className: classNames96(
|
|
57610
|
-
"w-10 sticky left-0 z-20 transition-colors duration-150 ease-out",
|
|
57615
|
+
"w-10 sticky left-0 z-20 ui-table-sticky-cell transition-colors duration-150 ease-out",
|
|
57611
57616
|
// Only apply an opaque background when there is a left-sticky data column;
|
|
57612
57617
|
// otherwise the spacer can remain transparent.
|
|
57613
|
-
hasLeftStickyColumn && (isSelected ? getSelectedRowClass(controlColor) : isHighlighted ? getHighlightRowClass(controlColor) : baseRowBgClass),
|
|
57618
|
+
hasLeftStickyColumn && (isSelected ? getSelectedRowClass(controlColor) : isHighlighted ? getHighlightRowClass(controlColor) : isStripedRow ? "bg-transparent" : baseRowBgClass),
|
|
57614
57619
|
rowHoverClass
|
|
57615
57620
|
),
|
|
57616
57621
|
"aria-hidden": "true",
|
|
@@ -57642,14 +57647,14 @@ function TableComponent({
|
|
|
57642
57647
|
isStickyLeft && (showGroupExpandCol ? "left-10" : "left-0"),
|
|
57643
57648
|
// right position is set via inline style when offset > 0
|
|
57644
57649
|
isStickyRight && !rightOffset && "right-0",
|
|
57645
|
-
(isStickyLeft || isStickyRight) && "z-10",
|
|
57646
|
-
(isStickyLeft || isStickyRight) && (isSelected ? getSelectedRowClass(controlColor) : isHighlighted ? getHighlightRowClass(controlColor) : isStripedRow ?
|
|
57650
|
+
(isStickyLeft || isStickyRight) && "z-10 ui-table-sticky-cell",
|
|
57651
|
+
(isStickyLeft || isStickyRight) && (isSelected ? getSelectedRowClass(controlColor) : isHighlighted ? getHighlightRowClass(controlColor) : isStripedRow ? "bg-transparent" : column.stickyBackgroundFn?.(row, originalIndex) ?? column.stickyBackground ?? "bg-white dark:bg-neutral-900"),
|
|
57647
57652
|
// Same hover fill for every cell (sticky included) — the
|
|
57648
57653
|
// `group-hover:` variant beats the cell's base background, so
|
|
57649
57654
|
// the whole row shifts uniformly without scrolled content
|
|
57650
57655
|
// bleeding through a sticky column.
|
|
57651
57656
|
rowHoverClass,
|
|
57652
|
-
(isStickyLeft || isStickyRight) && isHighlighted && hoverable && "group-hover:brightness-95",
|
|
57657
|
+
(isStickyLeft || isStickyRight) && isHighlighted && hoverable && "group-hover/table-row:brightness-95",
|
|
57653
57658
|
getCellAlignment(column.align),
|
|
57654
57659
|
// Horizontal padding. Every cell keeps a symmetric gap so
|
|
57655
57660
|
// adjacent columns never sit flush (bordered or not) and the
|