@scripso-homepad/ui 0.4.35 → 0.4.36
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/web/index.cjs +59 -1
- package/dist/web/index.cjs.map +1 -1
- package/dist/web/index.d.cts +17 -1
- package/dist/web/index.d.ts +17 -1
- package/dist/web/index.js +59 -3
- package/dist/web/index.js.map +1 -1
- package/package.json +1 -1
- package/src/web/icons/SidebarCollapseIcon.tsx +32 -0
- package/src/web/icons/SidebarExpandIcon.tsx +32 -0
- package/src/web/index.ts +2 -0
- package/src/web/layout/Sidebar.tsx +5 -3
package/dist/web/index.cjs
CHANGED
|
@@ -29500,6 +29500,62 @@ function AppHeader({
|
|
|
29500
29500
|
}
|
|
29501
29501
|
);
|
|
29502
29502
|
}
|
|
29503
|
+
function SidebarCollapseIcon({
|
|
29504
|
+
className,
|
|
29505
|
+
size = 20,
|
|
29506
|
+
strokeWidth = 2
|
|
29507
|
+
}) {
|
|
29508
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
29509
|
+
"svg",
|
|
29510
|
+
{
|
|
29511
|
+
width: size,
|
|
29512
|
+
height: size,
|
|
29513
|
+
viewBox: "0 0 20 20",
|
|
29514
|
+
fill: "none",
|
|
29515
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
29516
|
+
"aria-hidden": true,
|
|
29517
|
+
className,
|
|
29518
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
29519
|
+
"path",
|
|
29520
|
+
{
|
|
29521
|
+
d: "M12.5 2.5V17.5M8.33333 12.5L5.83333 10L8.33333 7.5M4.16667 2.5H15.8333C16.7538 2.5 17.5 3.24619 17.5 4.16667V15.8333C17.5 16.7538 16.7538 17.5 15.8333 17.5H4.16667C3.24619 17.5 2.5 16.7538 2.5 15.8333V4.16667C2.5 3.24619 3.24619 2.5 4.16667 2.5Z",
|
|
29522
|
+
stroke: "currentColor",
|
|
29523
|
+
strokeWidth,
|
|
29524
|
+
strokeLinecap: "round",
|
|
29525
|
+
strokeLinejoin: "round"
|
|
29526
|
+
}
|
|
29527
|
+
)
|
|
29528
|
+
}
|
|
29529
|
+
);
|
|
29530
|
+
}
|
|
29531
|
+
function SidebarExpandIcon({
|
|
29532
|
+
className,
|
|
29533
|
+
size = 20,
|
|
29534
|
+
strokeWidth = 2
|
|
29535
|
+
}) {
|
|
29536
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
29537
|
+
"svg",
|
|
29538
|
+
{
|
|
29539
|
+
width: size,
|
|
29540
|
+
height: size,
|
|
29541
|
+
viewBox: "0 0 20 20",
|
|
29542
|
+
fill: "none",
|
|
29543
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
29544
|
+
"aria-hidden": true,
|
|
29545
|
+
className,
|
|
29546
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
29547
|
+
"path",
|
|
29548
|
+
{
|
|
29549
|
+
d: "M12.5 2.5V17.5M6.66667 7.5L9.16667 10L6.66667 12.5M4.16667 2.5H15.8333C16.7538 2.5 17.5 3.24619 17.5 4.16667V15.8333C17.5 16.7538 16.7538 17.5 15.8333 17.5H4.16667C3.24619 17.5 2.5 16.7538 2.5 15.8333V4.16667C2.5 3.24619 3.24619 2.5 4.16667 2.5Z",
|
|
29550
|
+
stroke: "currentColor",
|
|
29551
|
+
strokeWidth,
|
|
29552
|
+
strokeLinecap: "round",
|
|
29553
|
+
strokeLinejoin: "round"
|
|
29554
|
+
}
|
|
29555
|
+
)
|
|
29556
|
+
}
|
|
29557
|
+
);
|
|
29558
|
+
}
|
|
29503
29559
|
function useMediaQuery(query) {
|
|
29504
29560
|
const [matches, setMatches] = react.useState(() => {
|
|
29505
29561
|
if (typeof window === "undefined") {
|
|
@@ -29848,7 +29904,7 @@ function Sidebar({
|
|
|
29848
29904
|
onClick: handleHeaderAction,
|
|
29849
29905
|
className: "shrink-0 cursor-pointer text-white transition-[opacity,transform] duration-200 hover:opacity-80 active:scale-95",
|
|
29850
29906
|
"aria-label": isDesktop ? isExpanded ? labels.collapse : labels.expand : labels.closeMenu,
|
|
29851
|
-
children: isDesktop ? isExpanded ? collapseIcon ?? /* @__PURE__ */ jsxRuntime.jsx(
|
|
29907
|
+
children: isDesktop ? isExpanded ? collapseIcon ?? /* @__PURE__ */ jsxRuntime.jsx(SidebarCollapseIcon, {}) : expandIcon ?? /* @__PURE__ */ jsxRuntime.jsx(SidebarExpandIcon, {}) : closeIcon ?? /* @__PURE__ */ jsxRuntime.jsx(lucideReact.X, { size: 20, strokeWidth: 1.75 })
|
|
29852
29908
|
}
|
|
29853
29909
|
)
|
|
29854
29910
|
]
|
|
@@ -31899,6 +31955,8 @@ exports.HistoryTimeline = HistoryTimeline;
|
|
|
31899
31955
|
exports.Modal = Modal;
|
|
31900
31956
|
exports.Pagination = Pagination;
|
|
31901
31957
|
exports.Sidebar = Sidebar;
|
|
31958
|
+
exports.SidebarCollapseIcon = SidebarCollapseIcon;
|
|
31959
|
+
exports.SidebarExpandIcon = SidebarExpandIcon;
|
|
31902
31960
|
exports.SidebarMobileHeader = SidebarMobileHeader;
|
|
31903
31961
|
exports.SidebarNavItem = SidebarNavItem;
|
|
31904
31962
|
exports.SidebarUserCard = SidebarUserCard;
|