@underverse-ui/underverse 1.0.30 → 1.0.32
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/api-reference.json +1 -1
- package/dist/index.cjs +38 -54
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +38 -54
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -5643,7 +5643,7 @@ var ScrollArea = forwardRef7(
|
|
|
5643
5643
|
className
|
|
5644
5644
|
),
|
|
5645
5645
|
...props,
|
|
5646
|
-
children: /* @__PURE__ */ jsx28("div", { className: cn("h-full w-full overflow-y-auto scroll-area-viewport", contentClassName), children })
|
|
5646
|
+
children: /* @__PURE__ */ jsx28("div", { className: cn("h-full w-full overflow-y-auto scroll-area-viewport custom-scrollbar", contentClassName), "data-os-scrollbar": true, children })
|
|
5647
5647
|
}
|
|
5648
5648
|
);
|
|
5649
5649
|
}
|
|
@@ -6913,7 +6913,6 @@ function WheelColumn({
|
|
|
6913
6913
|
ref: scrollRef,
|
|
6914
6914
|
className: cn(
|
|
6915
6915
|
"h-full overflow-y-auto overscroll-contain snap-y snap-mandatory",
|
|
6916
|
-
"scrollbar-none",
|
|
6917
6916
|
"select-none cursor-grab active:cursor-grabbing",
|
|
6918
6917
|
"focus:outline-none focus-visible:ring-2 focus-visible:ring-primary/50 focus-visible:ring-offset-2 focus-visible:ring-offset-background rounded-xl"
|
|
6919
6918
|
),
|
|
@@ -8337,7 +8336,6 @@ function WheelColumn2({
|
|
|
8337
8336
|
ref: scrollRef,
|
|
8338
8337
|
className: cn(
|
|
8339
8338
|
"h-full overflow-y-auto overscroll-contain snap-y snap-mandatory",
|
|
8340
|
-
"scrollbar-none",
|
|
8341
8339
|
"select-none cursor-grab active:cursor-grabbing",
|
|
8342
8340
|
"focus:outline-none focus-visible:ring-2 focus-visible:ring-primary/50 focus-visible:ring-offset-2 focus-visible:ring-offset-background rounded-xl"
|
|
8343
8341
|
),
|
|
@@ -10098,7 +10096,7 @@ function CalendarTimelineHeader(props) {
|
|
|
10098
10096
|
]
|
|
10099
10097
|
}
|
|
10100
10098
|
) : null,
|
|
10101
|
-
/* @__PURE__ */ jsx35("div", { ref: headerRef, className: "flex-1 min-w-0 overflow-x-auto overflow-y-hidden
|
|
10099
|
+
/* @__PURE__ */ jsx35("div", { ref: headerRef, className: "flex-1 min-w-0 overflow-x-auto overflow-y-hidden", children: slotHeaderNodes })
|
|
10102
10100
|
] })
|
|
10103
10101
|
] });
|
|
10104
10102
|
}
|
|
@@ -11689,7 +11687,7 @@ function CalendarTimeline({
|
|
|
11689
11687
|
"div",
|
|
11690
11688
|
{
|
|
11691
11689
|
ref: leftRef,
|
|
11692
|
-
className: "shrink-0 overflow-y-auto overflow-x-hidden
|
|
11690
|
+
className: "shrink-0 overflow-y-auto overflow-x-hidden",
|
|
11693
11691
|
style: { width: effectiveResourceColumnWidth, minWidth: effectiveResourceColumnWidth },
|
|
11694
11692
|
children: [
|
|
11695
11693
|
/* @__PURE__ */ jsx39("div", { style: { height: topSpacer } }),
|
|
@@ -11719,7 +11717,8 @@ function CalendarTimeline({
|
|
|
11719
11717
|
"div",
|
|
11720
11718
|
{
|
|
11721
11719
|
ref: bodyRef,
|
|
11722
|
-
className: "relative flex-1 overflow-auto
|
|
11720
|
+
className: "relative flex-1 overflow-auto custom-scrollbar",
|
|
11721
|
+
"data-os-scrollbar": true,
|
|
11723
11722
|
onPointerMove,
|
|
11724
11723
|
onPointerUp,
|
|
11725
11724
|
onPointerLeave: () => setHoverCell(null),
|
|
@@ -13932,12 +13931,13 @@ function CategoryTreeSelect(props) {
|
|
|
13932
13931
|
"div",
|
|
13933
13932
|
{
|
|
13934
13933
|
className: cn(
|
|
13935
|
-
"absolute z-20 mt-2 w-full max-h-80 overflow-auto",
|
|
13934
|
+
"absolute z-20 mt-2 w-full max-h-80 overflow-auto custom-scrollbar",
|
|
13936
13935
|
"rounded-2xl md:rounded-3xl border border-border/40 bg-popover/95 text-popover-foreground",
|
|
13937
13936
|
"shadow-2xl backdrop-blur-xl",
|
|
13938
13937
|
"p-2",
|
|
13939
13938
|
"animate-in fade-in-0 zoom-in-95 slide-in-from-top-2 duration-300"
|
|
13940
13939
|
),
|
|
13940
|
+
"data-os-scrollbar": true,
|
|
13941
13941
|
children: [
|
|
13942
13942
|
renderSearch(),
|
|
13943
13943
|
renderTreeContent()
|
|
@@ -18849,16 +18849,14 @@ var LoadingBar = ({
|
|
|
18849
18849
|
// ../../components/ui/OverlayScrollbarProvider.tsx
|
|
18850
18850
|
import { useEffect as useEffect28 } from "react";
|
|
18851
18851
|
import { OverlayScrollbars } from "overlayscrollbars";
|
|
18852
|
-
var
|
|
18853
|
-
var
|
|
18854
|
-
"
|
|
18855
|
-
"
|
|
18856
|
-
"
|
|
18857
|
-
"
|
|
18858
|
-
".overflow-x-scroll",
|
|
18859
|
-
".overflow-y-scroll"
|
|
18852
|
+
var EXPLICIT_SELECTOR = [".thin-scrollbar", ".scrollbar-thin", ".custom-scrollbar", "[data-os-scrollbar]"].join(", ");
|
|
18853
|
+
var PORTAL_EXCLUDE_SELECTOR = [
|
|
18854
|
+
"[data-radix-portal]",
|
|
18855
|
+
"[role='dialog']",
|
|
18856
|
+
"[aria-modal='true']",
|
|
18857
|
+
"[data-sonner-toaster]"
|
|
18860
18858
|
].join(", ");
|
|
18861
|
-
var
|
|
18859
|
+
var OPTIONS = {
|
|
18862
18860
|
scrollbars: {
|
|
18863
18861
|
theme: "os-theme-underverse",
|
|
18864
18862
|
visibility: "auto",
|
|
@@ -18868,42 +18866,27 @@ var SCROLLBAR_OPTIONS = {
|
|
|
18868
18866
|
clickScroll: false
|
|
18869
18867
|
}
|
|
18870
18868
|
};
|
|
18869
|
+
function shouldSkip(element) {
|
|
18870
|
+
if (element === document.body || element === document.documentElement) return true;
|
|
18871
|
+
if (element.hasAttribute("data-os-ignore")) return true;
|
|
18872
|
+
if (element.hasAttribute("data-overlayscrollbars")) return true;
|
|
18873
|
+
if (element.closest(PORTAL_EXCLUDE_SELECTOR)) return true;
|
|
18874
|
+
return false;
|
|
18875
|
+
}
|
|
18871
18876
|
function OverlayScrollbarProvider() {
|
|
18872
18877
|
useEffect28(() => {
|
|
18873
|
-
const bodyInstance = OverlayScrollbars(document.body, SCROLLBAR_OPTIONS);
|
|
18874
18878
|
const instances = /* @__PURE__ */ new Map();
|
|
18875
|
-
|
|
18876
|
-
|
|
18877
|
-
if (element.classList.contains("scrollbar-none")) return true;
|
|
18878
|
-
if (element.hasAttribute("data-overlayscrollbars")) return true;
|
|
18879
|
-
return false;
|
|
18880
|
-
};
|
|
18881
|
-
const initElement = (element) => {
|
|
18879
|
+
let rafId = 0;
|
|
18880
|
+
const init = (element) => {
|
|
18882
18881
|
if (shouldSkip(element)) return;
|
|
18883
18882
|
if (instances.has(element)) return;
|
|
18884
|
-
instances.set(element, OverlayScrollbars(element,
|
|
18885
|
-
};
|
|
18886
|
-
const collectCandidates = (root, selector) => {
|
|
18887
|
-
const candidates = [];
|
|
18888
|
-
if (root instanceof HTMLElement && root.matches(selector)) {
|
|
18889
|
-
candidates.push(root);
|
|
18890
|
-
}
|
|
18891
|
-
if ("querySelectorAll" in root) {
|
|
18892
|
-
root.querySelectorAll(selector).forEach((element) => {
|
|
18893
|
-
candidates.push(element);
|
|
18894
|
-
});
|
|
18895
|
-
}
|
|
18896
|
-
return candidates.filter((element, index) => candidates.indexOf(element) === index);
|
|
18883
|
+
instances.set(element, OverlayScrollbars(element, OPTIONS));
|
|
18897
18884
|
};
|
|
18898
18885
|
const scan = (root) => {
|
|
18899
|
-
|
|
18900
|
-
|
|
18901
|
-
|
|
18902
|
-
|
|
18903
|
-
(element) => !explicitCandidates.some((explicit) => explicit === element || explicit.contains(element) || element.contains(explicit))
|
|
18904
|
-
);
|
|
18905
|
-
const leafGeneric = filteredGeneric.filter((element) => !filteredGeneric.some((other) => other !== element && element.contains(other)));
|
|
18906
|
-
leafGeneric.forEach(initElement);
|
|
18886
|
+
if (root instanceof HTMLElement && root.matches(EXPLICIT_SELECTOR)) {
|
|
18887
|
+
init(root);
|
|
18888
|
+
}
|
|
18889
|
+
root.querySelectorAll(EXPLICIT_SELECTOR).forEach(init);
|
|
18907
18890
|
};
|
|
18908
18891
|
const cleanup = () => {
|
|
18909
18892
|
instances.forEach((instance, element) => {
|
|
@@ -18914,14 +18897,13 @@ function OverlayScrollbarProvider() {
|
|
|
18914
18897
|
});
|
|
18915
18898
|
};
|
|
18916
18899
|
scan(document.body);
|
|
18917
|
-
let rafId = 0;
|
|
18918
18900
|
const observer = new MutationObserver((mutations) => {
|
|
18919
18901
|
if (rafId) return;
|
|
18920
|
-
rafId =
|
|
18902
|
+
rafId = requestAnimationFrame(() => {
|
|
18921
18903
|
rafId = 0;
|
|
18922
18904
|
const scanRoots = /* @__PURE__ */ new Set();
|
|
18923
18905
|
mutations.forEach((mutation) => {
|
|
18924
|
-
if (mutation.target instanceof
|
|
18906
|
+
if (mutation.target instanceof HTMLElement || mutation.target instanceof Document || mutation.target instanceof DocumentFragment) {
|
|
18925
18907
|
scanRoots.add(mutation.target);
|
|
18926
18908
|
}
|
|
18927
18909
|
mutation.addedNodes.forEach((node) => {
|
|
@@ -18934,16 +18916,17 @@ function OverlayScrollbarProvider() {
|
|
|
18934
18916
|
cleanup();
|
|
18935
18917
|
});
|
|
18936
18918
|
});
|
|
18937
|
-
observer.observe(document.body, { childList: true, subtree: true });
|
|
18919
|
+
observer.observe(document.body, { childList: true, subtree: true, attributes: true, attributeFilter: ["class"] });
|
|
18938
18920
|
return () => {
|
|
18939
|
-
if (rafId)
|
|
18921
|
+
if (rafId) cancelAnimationFrame(rafId);
|
|
18940
18922
|
observer.disconnect();
|
|
18941
18923
|
instances.forEach((instance) => instance.destroy());
|
|
18942
|
-
|
|
18924
|
+
instances.clear();
|
|
18943
18925
|
};
|
|
18944
18926
|
}, []);
|
|
18945
18927
|
return null;
|
|
18946
18928
|
}
|
|
18929
|
+
var OverlayScrollbarProvider_default = OverlayScrollbarProvider;
|
|
18947
18930
|
|
|
18948
18931
|
// ../../components/ui/Table.tsx
|
|
18949
18932
|
import React55 from "react";
|
|
@@ -18956,12 +18939,13 @@ var Table = React55.forwardRef(({ className, containerClassName, disableContaine
|
|
|
18956
18939
|
"div",
|
|
18957
18940
|
{
|
|
18958
18941
|
className: cn(
|
|
18959
|
-
"relative w-full overflow-auto",
|
|
18942
|
+
"relative w-full overflow-auto custom-scrollbar",
|
|
18960
18943
|
"rounded-2xl md:rounded-3xl border border-border",
|
|
18961
18944
|
"bg-card text-card-foreground shadow-sm",
|
|
18962
18945
|
"backdrop-blur-sm transition-all duration-300",
|
|
18963
18946
|
containerClassName
|
|
18964
18947
|
),
|
|
18948
|
+
"data-os-scrollbar": true,
|
|
18965
18949
|
children: /* @__PURE__ */ jsx65("table", { ref, className: cn("w-full caption-bottom text-sm", className), ...props })
|
|
18966
18950
|
}
|
|
18967
18951
|
);
|
|
@@ -19893,7 +19877,7 @@ function DataTable({
|
|
|
19893
19877
|
children: /* @__PURE__ */ jsx68(
|
|
19894
19878
|
"div",
|
|
19895
19879
|
{
|
|
19896
|
-
className: "
|
|
19880
|
+
className: "custom-scrollbar w-full",
|
|
19897
19881
|
"data-os-scrollbar": true,
|
|
19898
19882
|
style: stickyHeader ? {
|
|
19899
19883
|
maxHeight: typeof maxHeight === "number" ? `${maxHeight}px` : maxHeight,
|
|
@@ -24911,7 +24895,7 @@ export {
|
|
|
24911
24895
|
NotificationModal_default as NotificationModal,
|
|
24912
24896
|
NumberInput,
|
|
24913
24897
|
OverlayControls,
|
|
24914
|
-
OverlayScrollbarProvider,
|
|
24898
|
+
OverlayScrollbarProvider_default as OverlayScrollbarProvider,
|
|
24915
24899
|
PageLoading,
|
|
24916
24900
|
Pagination,
|
|
24917
24901
|
PasswordInput,
|