@geomak/ui 6.2.2 → 6.2.3
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 +14 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +14 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -2958,6 +2958,7 @@ function TableBody({
|
|
|
2958
2958
|
getRowKey
|
|
2959
2959
|
}) {
|
|
2960
2960
|
const [expanded, setExpanded] = useState(() => /* @__PURE__ */ new Set());
|
|
2961
|
+
const reduced = useReducedMotion();
|
|
2961
2962
|
const toggleRow = (rowKey) => {
|
|
2962
2963
|
setExpanded((prev) => {
|
|
2963
2964
|
const next = new Set(prev);
|
|
@@ -2999,7 +3000,19 @@ function TableBody({
|
|
|
2999
3000
|
]
|
|
3000
3001
|
}
|
|
3001
3002
|
),
|
|
3002
|
-
hasExpand &&
|
|
3003
|
+
hasExpand && /* @__PURE__ */ jsx("tr", { className: "bg-surface", children: /* @__PURE__ */ jsx("td", { colSpan: expandColCount, className: "p-0", children: /* @__PURE__ */ jsx(AnimatePresence, { initial: false, children: isExpanded && /* @__PURE__ */ jsx(
|
|
3004
|
+
motion.div,
|
|
3005
|
+
{
|
|
3006
|
+
initial: { height: 0, opacity: 0 },
|
|
3007
|
+
animate: { height: "auto", opacity: 1 },
|
|
3008
|
+
exit: { height: 0, opacity: 0 },
|
|
3009
|
+
transition: reduced ? { duration: 0 } : { height: { duration: 0.28, ease: [0.16, 1, 0.3, 1] }, opacity: { duration: 0.2 } },
|
|
3010
|
+
style: { overflow: "hidden" },
|
|
3011
|
+
className: "border-b border-border",
|
|
3012
|
+
children: /* @__PURE__ */ jsx("div", { className: "p-3", children: expandRow.expandComponent?.(row) })
|
|
3013
|
+
},
|
|
3014
|
+
"expand"
|
|
3015
|
+
) }) }) })
|
|
3003
3016
|
] }, rowKey);
|
|
3004
3017
|
}) });
|
|
3005
3018
|
}
|