@underverse-ui/underverse 0.2.112 → 0.2.114
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 +225 -152
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +3 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.js +225 -152
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -1384,6 +1384,9 @@ interface SliderProps extends Omit<React$1.InputHTMLAttributes<HTMLInputElement>
|
|
|
1384
1384
|
disabled?: boolean;
|
|
1385
1385
|
orientation?: "horizontal" | "vertical";
|
|
1386
1386
|
noFocus?: boolean;
|
|
1387
|
+
showTooltip?: boolean;
|
|
1388
|
+
tooltipClassName?: string;
|
|
1389
|
+
useGradient?: boolean;
|
|
1387
1390
|
}
|
|
1388
1391
|
declare const Slider: React$1.ForwardRefExoticComponent<SliderProps & React$1.RefAttributes<HTMLInputElement>>;
|
|
1389
1392
|
|
package/dist/index.d.ts
CHANGED
|
@@ -1384,6 +1384,9 @@ interface SliderProps extends Omit<React$1.InputHTMLAttributes<HTMLInputElement>
|
|
|
1384
1384
|
disabled?: boolean;
|
|
1385
1385
|
orientation?: "horizontal" | "vertical";
|
|
1386
1386
|
noFocus?: boolean;
|
|
1387
|
+
showTooltip?: boolean;
|
|
1388
|
+
tooltipClassName?: string;
|
|
1389
|
+
useGradient?: boolean;
|
|
1387
1390
|
}
|
|
1388
1391
|
declare const Slider: React$1.ForwardRefExoticComponent<SliderProps & React$1.RefAttributes<HTMLInputElement>>;
|
|
1389
1392
|
|
package/dist/index.js
CHANGED
|
@@ -178,11 +178,11 @@ var variantStyles = {
|
|
|
178
178
|
gradient: "bg-linear-to-r from-primary to-secondary text-primary-foreground border-transparent hover:from-primary/90 hover:to-secondary/90"
|
|
179
179
|
};
|
|
180
180
|
var sizeStyles = {
|
|
181
|
-
xs: "px-1.5 py-0.5 text-xs font-medium min-h-
|
|
182
|
-
sm: "px-2 py-0.5 text-xs font-medium min-h-
|
|
183
|
-
md: "px-2.5 py-1 text-xs font-medium min-h-
|
|
184
|
-
lg: "px-3 py-1.5 text-sm font-medium min-h-
|
|
185
|
-
xl: "px-4 py-2 text-sm font-semibold min-h-
|
|
181
|
+
xs: "px-1.5 py-0.5 text-xs font-medium min-h-4.5",
|
|
182
|
+
sm: "px-2 py-0.5 text-xs font-medium min-h-5",
|
|
183
|
+
md: "px-2.5 py-1 text-xs font-medium min-h-6",
|
|
184
|
+
lg: "px-3 py-1.5 text-sm font-medium min-h-7",
|
|
185
|
+
xl: "px-4 py-2 text-sm font-semibold min-h-8"
|
|
186
186
|
};
|
|
187
187
|
var dotSizeStyles = {
|
|
188
188
|
xs: "w-1.5 h-1.5",
|
|
@@ -1774,9 +1774,9 @@ var Textarea2 = forwardRef5(
|
|
|
1774
1774
|
({ label, error, description, className, required, variant = "default", size = "md", ...rest }, ref) => {
|
|
1775
1775
|
const [isFocused, setIsFocused] = useState6(false);
|
|
1776
1776
|
const sizeClasses2 = {
|
|
1777
|
-
sm: "px-3 py-2 text-sm min-h-
|
|
1778
|
-
md: "px-4 py-3 text-sm min-h-
|
|
1779
|
-
lg: "px-5 py-4 text-base min-h-
|
|
1777
|
+
sm: "px-3 py-2 text-sm min-h-20",
|
|
1778
|
+
md: "px-4 py-3 text-sm min-h-25",
|
|
1779
|
+
lg: "px-5 py-4 text-base min-h-30"
|
|
1780
1780
|
};
|
|
1781
1781
|
const variantClasses2 = {
|
|
1782
1782
|
default: cn(
|
|
@@ -3844,28 +3844,28 @@ import { X as X6 } from "lucide-react";
|
|
|
3844
3844
|
import { jsx as jsx19, jsxs as jsxs16 } from "react/jsx-runtime";
|
|
3845
3845
|
var sizeStyles4 = {
|
|
3846
3846
|
sm: {
|
|
3847
|
-
right: "w-
|
|
3848
|
-
left: "w-
|
|
3849
|
-
top: "h-
|
|
3850
|
-
bottom: "h-
|
|
3847
|
+
right: "w-75",
|
|
3848
|
+
left: "w-75",
|
|
3849
|
+
top: "h-50",
|
|
3850
|
+
bottom: "h-50"
|
|
3851
3851
|
},
|
|
3852
3852
|
md: {
|
|
3853
|
-
right: "w-
|
|
3854
|
-
left: "w-
|
|
3855
|
-
top: "h-
|
|
3856
|
-
bottom: "h-
|
|
3853
|
+
right: "w-100",
|
|
3854
|
+
left: "w-100",
|
|
3855
|
+
top: "h-75",
|
|
3856
|
+
bottom: "h-75"
|
|
3857
3857
|
},
|
|
3858
3858
|
lg: {
|
|
3859
|
-
right: "w-
|
|
3860
|
-
left: "w-
|
|
3861
|
-
top: "h-
|
|
3862
|
-
bottom: "h-
|
|
3859
|
+
right: "w-125",
|
|
3860
|
+
left: "w-125",
|
|
3861
|
+
top: "h-100",
|
|
3862
|
+
bottom: "h-100"
|
|
3863
3863
|
},
|
|
3864
3864
|
xl: {
|
|
3865
|
-
right: "w-
|
|
3866
|
-
left: "w-
|
|
3867
|
-
top: "h-
|
|
3868
|
-
bottom: "h-
|
|
3865
|
+
right: "w-150",
|
|
3866
|
+
left: "w-150",
|
|
3867
|
+
top: "h-125",
|
|
3868
|
+
bottom: "h-125"
|
|
3869
3869
|
},
|
|
3870
3870
|
full: {
|
|
3871
3871
|
right: "w-full",
|
|
@@ -6956,7 +6956,7 @@ function WheelColumn({
|
|
|
6956
6956
|
const ui = React25.useMemo(() => {
|
|
6957
6957
|
if (size === "sm") {
|
|
6958
6958
|
return {
|
|
6959
|
-
columnWidth: "min-w-
|
|
6959
|
+
columnWidth: "min-w-16 max-w-21",
|
|
6960
6960
|
label: "text-[9px] mb-2",
|
|
6961
6961
|
selectedText: "text-base",
|
|
6962
6962
|
unselectedText: "text-sm",
|
|
@@ -6965,7 +6965,7 @@ function WheelColumn({
|
|
|
6965
6965
|
}
|
|
6966
6966
|
if (size === "lg") {
|
|
6967
6967
|
return {
|
|
6968
|
-
columnWidth: "min-w-
|
|
6968
|
+
columnWidth: "min-w-20 max-w-27.5",
|
|
6969
6969
|
label: "text-[11px] mb-3",
|
|
6970
6970
|
selectedText: "text-xl",
|
|
6971
6971
|
unselectedText: "text-lg",
|
|
@@ -6973,7 +6973,7 @@ function WheelColumn({
|
|
|
6973
6973
|
};
|
|
6974
6974
|
}
|
|
6975
6975
|
return {
|
|
6976
|
-
columnWidth: "min-w-
|
|
6976
|
+
columnWidth: "min-w-17.5 max-w-22.5",
|
|
6977
6977
|
label: "text-[10px] mb-3",
|
|
6978
6978
|
selectedText: "text-lg",
|
|
6979
6979
|
unselectedText: "text-base",
|
|
@@ -7850,7 +7850,7 @@ function TimePicker({
|
|
|
7850
7850
|
{
|
|
7851
7851
|
className: cn(
|
|
7852
7852
|
"flex-1",
|
|
7853
|
-
size === "sm" ? "min-w-
|
|
7853
|
+
size === "sm" ? "min-w-16 max-w-21" : size === "lg" ? "min-w-20 max-w-27.5" : "min-w-17.5 max-w-22.5"
|
|
7854
7854
|
),
|
|
7855
7855
|
children: [
|
|
7856
7856
|
/* @__PURE__ */ jsx31("div", { className: cn(panelSz.periodLabel, "font-bold uppercase tracking-wider text-muted-foreground/70 text-center"), children: "Period" }),
|
|
@@ -11467,17 +11467,20 @@ var SIZE_STYLES = {
|
|
|
11467
11467
|
sm: {
|
|
11468
11468
|
track: "h-1",
|
|
11469
11469
|
thumb: "w-3 h-3",
|
|
11470
|
-
container: "py-1"
|
|
11470
|
+
container: "py-1",
|
|
11471
|
+
tooltip: "text-xs px-2 py-1"
|
|
11471
11472
|
},
|
|
11472
11473
|
md: {
|
|
11473
11474
|
track: "h-2",
|
|
11474
11475
|
thumb: "w-4 h-4",
|
|
11475
|
-
container: "py-2"
|
|
11476
|
+
container: "py-2",
|
|
11477
|
+
tooltip: "text-sm px-2.5 py-1.5"
|
|
11476
11478
|
},
|
|
11477
11479
|
lg: {
|
|
11478
11480
|
track: "h-3",
|
|
11479
11481
|
thumb: "w-5 h-5",
|
|
11480
|
-
container: "py-3"
|
|
11482
|
+
container: "py-3",
|
|
11483
|
+
tooltip: "text-sm px-3 py-2"
|
|
11481
11484
|
}
|
|
11482
11485
|
};
|
|
11483
11486
|
var clamp5 = (n, min, max) => Math.min(max, Math.max(min, n));
|
|
@@ -11510,6 +11513,9 @@ var Slider = React35.forwardRef(
|
|
|
11510
11513
|
disabled = false,
|
|
11511
11514
|
orientation = "horizontal",
|
|
11512
11515
|
noFocus = true,
|
|
11516
|
+
showTooltip = true,
|
|
11517
|
+
tooltipClassName,
|
|
11518
|
+
useGradient = true,
|
|
11513
11519
|
...props
|
|
11514
11520
|
}, ref) => {
|
|
11515
11521
|
const isRange = mode === "range";
|
|
@@ -11522,6 +11528,8 @@ var Slider = React35.forwardRef(
|
|
|
11522
11528
|
});
|
|
11523
11529
|
const [activeThumb, setActiveThumb] = React35.useState(null);
|
|
11524
11530
|
const dragRef = React35.useRef(null);
|
|
11531
|
+
const [isHovering, setIsHovering] = React35.useState(false);
|
|
11532
|
+
const [isDragging, setIsDragging] = React35.useState(false);
|
|
11525
11533
|
const isControlled = value !== void 0;
|
|
11526
11534
|
const currentValue = isControlled ? value : internalValue;
|
|
11527
11535
|
const isRangeControlled = rangeValue !== void 0;
|
|
@@ -11600,6 +11608,7 @@ var Slider = React35.forwardRef(
|
|
|
11600
11608
|
const distToMax = Math.abs(nextValue - curMax);
|
|
11601
11609
|
const thumb = distToMin <= distToMax ? "min" : "max";
|
|
11602
11610
|
setActiveThumb(thumb);
|
|
11611
|
+
setIsDragging(true);
|
|
11603
11612
|
dragRef.current = { pointerId: e.pointerId, thumb };
|
|
11604
11613
|
try {
|
|
11605
11614
|
e.currentTarget.setPointerCapture(e.pointerId);
|
|
@@ -11624,6 +11633,7 @@ var Slider = React35.forwardRef(
|
|
|
11624
11633
|
if (!drag) return;
|
|
11625
11634
|
if (e.pointerId !== drag.pointerId) return;
|
|
11626
11635
|
dragRef.current = null;
|
|
11636
|
+
setIsDragging(false);
|
|
11627
11637
|
onMouseUp?.();
|
|
11628
11638
|
onTouchEnd?.();
|
|
11629
11639
|
try {
|
|
@@ -11633,135 +11643,198 @@ var Slider = React35.forwardRef(
|
|
|
11633
11643
|
};
|
|
11634
11644
|
if (orientation === "vertical") {
|
|
11635
11645
|
}
|
|
11646
|
+
const Tooltip2 = ({ value: value2, position }) => {
|
|
11647
|
+
const shouldShow = showTooltip && !disabled && (isHovering || isDragging);
|
|
11648
|
+
const displayVal = formatValue ? formatValue(value2) : value2.toString();
|
|
11649
|
+
return /* @__PURE__ */ jsxs36(
|
|
11650
|
+
"div",
|
|
11651
|
+
{
|
|
11652
|
+
className: cn(
|
|
11653
|
+
"absolute pointer-events-none transition-all duration-200 ease-out",
|
|
11654
|
+
"bg-popover text-popover-foreground rounded-lg shadow-lg border border-border",
|
|
11655
|
+
"whitespace-nowrap font-medium -translate-x-1/2 z-50",
|
|
11656
|
+
sizeStyles8.tooltip,
|
|
11657
|
+
shouldShow ? "opacity-100 -translate-y-10 scale-100" : "opacity-0 -translate-y-8 scale-95",
|
|
11658
|
+
tooltipClassName
|
|
11659
|
+
),
|
|
11660
|
+
style: {
|
|
11661
|
+
left: `${position}%`,
|
|
11662
|
+
bottom: "100%"
|
|
11663
|
+
},
|
|
11664
|
+
children: [
|
|
11665
|
+
displayVal,
|
|
11666
|
+
/* @__PURE__ */ jsx41("div", { className: "absolute left-1/2 -translate-x-1/2 top-full w-0 h-0 border-4 border-transparent border-t-border" }),
|
|
11667
|
+
/* @__PURE__ */ jsx41("div", { className: "absolute left-1/2 -translate-x-1/2 top-full w-0 h-0 border-[3px] border-transparent border-t-popover -mt-px" })
|
|
11668
|
+
]
|
|
11669
|
+
}
|
|
11670
|
+
);
|
|
11671
|
+
};
|
|
11636
11672
|
return /* @__PURE__ */ jsxs36("div", { className: cn("w-full space-y-2", containerClassName), children: [
|
|
11637
11673
|
(label || showValue) && /* @__PURE__ */ jsxs36("div", { className: "flex items-center justify-between", children: [
|
|
11638
11674
|
label && /* @__PURE__ */ jsx41("label", { className: cn("text-sm font-medium text-foreground", labelClassName), children: label }),
|
|
11639
11675
|
showValue && /* @__PURE__ */ jsx41("span", { className: cn("text-xs font-mono text-muted-foreground min-w-8 text-right", valueClassName), children: displayValue })
|
|
11640
11676
|
] }),
|
|
11641
|
-
/* @__PURE__ */ jsxs36(
|
|
11642
|
-
|
|
11643
|
-
|
|
11644
|
-
|
|
11645
|
-
|
|
11646
|
-
|
|
11647
|
-
|
|
11648
|
-
|
|
11649
|
-
|
|
11650
|
-
const baseInputClassName = cn(
|
|
11651
|
-
// Base styles
|
|
11652
|
-
"absolute w-full h-full appearance-none bg-transparent cursor-pointer",
|
|
11653
|
-
!noFocus && "focus:outline-none focus:ring-2 focus:ring-primary focus:ring-offset-2 focus:ring-offset-background rounded-full",
|
|
11654
|
-
noFocus && "outline-none ring-0 focus:outline-none focus:ring-0 focus-visible:outline-none",
|
|
11655
|
-
// Webkit styles for thumb
|
|
11656
|
-
"[&::-webkit-slider-thumb]:appearance-none",
|
|
11657
|
-
"[&::-webkit-slider-thumb]:bg-primary",
|
|
11658
|
-
"[&::-webkit-slider-thumb]:border-2 [&::-webkit-slider-thumb]:border-background",
|
|
11659
|
-
"[&::-webkit-slider-thumb]:rounded-full",
|
|
11660
|
-
"[&::-webkit-slider-thumb]:shadow-md",
|
|
11661
|
-
"[&::-webkit-slider-thumb]:cursor-pointer",
|
|
11662
|
-
"[&::-webkit-slider-thumb]:transition-all [&::-webkit-slider-thumb]:duration-150",
|
|
11663
|
-
size === "sm" && "[&::-webkit-slider-thumb]:w-3 [&::-webkit-slider-thumb]:h-3",
|
|
11664
|
-
size === "md" && "[&::-webkit-slider-thumb]:w-4 [&::-webkit-slider-thumb]:h-4",
|
|
11665
|
-
size === "lg" && "[&::-webkit-slider-thumb]:w-5 [&::-webkit-slider-thumb]:h-5",
|
|
11666
|
-
// Firefox styles for thumb
|
|
11667
|
-
"[&::-moz-range-thumb]:bg-primary",
|
|
11668
|
-
"[&::-moz-range-thumb]:border-2 [&::-moz-range-thumb]:border-background",
|
|
11669
|
-
"[&::-moz-range-thumb]:rounded-full",
|
|
11670
|
-
"[&::-moz-range-thumb]:shadow-md",
|
|
11671
|
-
"[&::-moz-range-thumb]:cursor-pointer",
|
|
11672
|
-
"[&::-moz-range-thumb]:transition-all [&::-moz-range-thumb]:duration-150",
|
|
11673
|
-
size === "sm" && "[&::-moz-range-thumb]:w-3 [&::-moz-range-thumb]:h-3",
|
|
11674
|
-
size === "md" && "[&::-moz-range-thumb]:w-4 [&::-moz-range-thumb]:h-4",
|
|
11675
|
-
size === "lg" && "[&::-moz-range-thumb]:w-5 [&::-moz-range-thumb]:h-5",
|
|
11676
|
-
// Remove default track in Firefox
|
|
11677
|
-
"[&::-moz-range-track]:bg-transparent",
|
|
11678
|
-
"[&::-moz-range-track]:border-transparent",
|
|
11679
|
-
// Hover effects
|
|
11680
|
-
"hover:[&::-webkit-slider-thumb]:scale-110 hover:[&::-webkit-slider-thumb]:shadow-lg",
|
|
11681
|
-
"hover:[&::-moz-range-thumb]:scale-110 hover:[&::-moz-range-thumb]:shadow-lg",
|
|
11682
|
-
// Disabled styles
|
|
11683
|
-
disabled && [
|
|
11684
|
-
"cursor-not-allowed opacity-50",
|
|
11685
|
-
"[&::-webkit-slider-thumb]:cursor-not-allowed [&::-webkit-slider-thumb]:opacity-50",
|
|
11686
|
-
"[&::-moz-range-thumb]:cursor-not-allowed [&::-moz-range-thumb]:opacity-50"
|
|
11687
|
-
],
|
|
11688
|
-
className,
|
|
11689
|
-
thumbClassName
|
|
11690
|
-
);
|
|
11691
|
-
if (!isRange) {
|
|
11692
|
-
return /* @__PURE__ */ jsx41(
|
|
11693
|
-
"input",
|
|
11694
|
-
{
|
|
11695
|
-
ref,
|
|
11696
|
-
type: "range",
|
|
11697
|
-
min,
|
|
11698
|
-
max,
|
|
11699
|
-
step,
|
|
11700
|
-
value: currentValue,
|
|
11701
|
-
onChange: handleSingleChange,
|
|
11702
|
-
onMouseUp,
|
|
11703
|
-
onTouchEnd,
|
|
11704
|
-
disabled,
|
|
11705
|
-
className: baseInputClassName,
|
|
11706
|
-
...props
|
|
11707
|
-
}
|
|
11708
|
-
);
|
|
11709
|
-
}
|
|
11710
|
-
const minZ = activeThumb === "min" ? "z-20" : "z-10";
|
|
11711
|
-
const maxZ = activeThumb === "max" ? "z-20" : "z-10";
|
|
11712
|
-
return /* @__PURE__ */ jsxs36(Fragment14, { children: [
|
|
11713
|
-
/* @__PURE__ */ jsx41(
|
|
11677
|
+
/* @__PURE__ */ jsxs36(
|
|
11678
|
+
"div",
|
|
11679
|
+
{
|
|
11680
|
+
ref: trackRef,
|
|
11681
|
+
className: cn("relative flex items-center", sizeStyles8.container),
|
|
11682
|
+
onMouseEnter: () => setIsHovering(true),
|
|
11683
|
+
onMouseLeave: () => setIsHovering(false),
|
|
11684
|
+
children: [
|
|
11685
|
+
/* @__PURE__ */ jsx41("div", { className: cn("w-full rounded-full bg-secondary relative overflow-hidden shadow-inner", sizeStyles8.track, trackClassName), children: isRange ? /* @__PURE__ */ jsx41(
|
|
11714
11686
|
"div",
|
|
11715
11687
|
{
|
|
11716
|
-
className: cn(
|
|
11717
|
-
|
|
11718
|
-
|
|
11719
|
-
|
|
11720
|
-
|
|
11688
|
+
className: cn(
|
|
11689
|
+
"absolute top-0 h-full rounded-full transition-all duration-150",
|
|
11690
|
+
useGradient ? "bg-linear-to-r from-primary via-primary to-primary/80 shadow-[0_0_8px_rgba(var(--primary-rgb,147,51,234),0.3)]" : "bg-primary"
|
|
11691
|
+
),
|
|
11692
|
+
style: { left: `${rangeStartPct}%`, width: `${Math.max(0, rangeEndPct - rangeStartPct)}%` }
|
|
11721
11693
|
}
|
|
11722
|
-
)
|
|
11723
|
-
|
|
11724
|
-
"input",
|
|
11694
|
+
) : /* @__PURE__ */ jsx41(
|
|
11695
|
+
"div",
|
|
11725
11696
|
{
|
|
11726
|
-
|
|
11727
|
-
|
|
11728
|
-
|
|
11729
|
-
|
|
11730
|
-
|
|
11731
|
-
value: normalizedRange[0],
|
|
11732
|
-
onChange: handleRangeChange("min"),
|
|
11733
|
-
onMouseUp,
|
|
11734
|
-
onTouchEnd,
|
|
11735
|
-
disabled,
|
|
11736
|
-
"aria-label": "Minimum value",
|
|
11737
|
-
onPointerDown: () => setActiveThumb("min"),
|
|
11738
|
-
onFocus: () => setActiveThumb("min"),
|
|
11739
|
-
className: cn(baseInputClassName, minZ, "pointer-events-none"),
|
|
11740
|
-
...props
|
|
11697
|
+
className: cn(
|
|
11698
|
+
"absolute left-0 top-0 h-full rounded-full transition-all duration-150",
|
|
11699
|
+
useGradient ? "bg-linear-to-r from-primary via-primary to-primary/80 shadow-[0_0_8px_rgba(var(--primary-rgb,147,51,234),0.3)]" : "bg-primary"
|
|
11700
|
+
),
|
|
11701
|
+
style: { width: `${percentage}%` }
|
|
11741
11702
|
}
|
|
11742
|
-
),
|
|
11743
|
-
/* @__PURE__ */ jsx41(
|
|
11744
|
-
|
|
11745
|
-
{
|
|
11746
|
-
|
|
11747
|
-
|
|
11748
|
-
|
|
11749
|
-
|
|
11750
|
-
|
|
11751
|
-
|
|
11752
|
-
|
|
11753
|
-
|
|
11754
|
-
|
|
11755
|
-
"
|
|
11756
|
-
|
|
11757
|
-
|
|
11758
|
-
|
|
11759
|
-
|
|
11703
|
+
) }),
|
|
11704
|
+
!isRange && /* @__PURE__ */ jsx41(Tooltip2, { value: currentValue, position: percentage }),
|
|
11705
|
+
isRange && /* @__PURE__ */ jsxs36(Fragment14, { children: [
|
|
11706
|
+
/* @__PURE__ */ jsx41(Tooltip2, { value: normalizedRange[0], position: rangeStartPct }),
|
|
11707
|
+
/* @__PURE__ */ jsx41(Tooltip2, { value: normalizedRange[1], position: rangeEndPct })
|
|
11708
|
+
] }),
|
|
11709
|
+
(() => {
|
|
11710
|
+
const baseInputClassName = cn(
|
|
11711
|
+
// Base styles
|
|
11712
|
+
"absolute w-full h-full appearance-none bg-transparent cursor-pointer",
|
|
11713
|
+
!noFocus && "focus:outline-none focus:ring-2 focus:ring-primary focus:ring-offset-2 focus:ring-offset-background rounded-full",
|
|
11714
|
+
noFocus && "outline-none ring-0 focus:outline-none focus:ring-0 focus-visible:outline-none",
|
|
11715
|
+
// Webkit styles for thumb
|
|
11716
|
+
"[&::-webkit-slider-thumb]:appearance-none",
|
|
11717
|
+
"[&::-webkit-slider-thumb]:bg-linear-to-br [&::-webkit-slider-thumb]:from-primary [&::-webkit-slider-thumb]:to-primary/80",
|
|
11718
|
+
"[&::-webkit-slider-thumb]:border-2 [&::-webkit-slider-thumb]:border-background",
|
|
11719
|
+
"[&::-webkit-slider-thumb]:rounded-full",
|
|
11720
|
+
"[&::-webkit-slider-thumb]:shadow-[0_2px_8px_rgba(0,0,0,0.15),0_0_0_1px_rgba(0,0,0,0.05)]",
|
|
11721
|
+
"[&::-webkit-slider-thumb]:cursor-pointer",
|
|
11722
|
+
"[&::-webkit-slider-thumb]:transition-all [&::-webkit-slider-thumb]:duration-200 [&::-webkit-slider-thumb]:ease-out",
|
|
11723
|
+
size === "sm" && "[&::-webkit-slider-thumb]:w-3 [&::-webkit-slider-thumb]:h-3",
|
|
11724
|
+
size === "md" && "[&::-webkit-slider-thumb]:w-4 [&::-webkit-slider-thumb]:h-4",
|
|
11725
|
+
size === "lg" && "[&::-webkit-slider-thumb]:w-5 [&::-webkit-slider-thumb]:h-5",
|
|
11726
|
+
// Firefox styles for thumb
|
|
11727
|
+
"[&::-moz-range-thumb]:bg-linear-to-br [&::-moz-range-thumb]:from-primary [&::-moz-range-thumb]:to-primary/80",
|
|
11728
|
+
"[&::-moz-range-thumb]:border-2 [&::-moz-range-thumb]:border-background",
|
|
11729
|
+
"[&::-moz-range-thumb]:rounded-full",
|
|
11730
|
+
"[&::-moz-range-thumb]:shadow-[0_2px_8px_rgba(0,0,0,0.15),0_0_0_1px_rgba(0,0,0,0.05)]",
|
|
11731
|
+
"[&::-moz-range-thumb]:cursor-pointer",
|
|
11732
|
+
"[&::-moz-range-thumb]:transition-all [&::-moz-range-thumb]:duration-200 [&::-moz-range-thumb]:ease-out",
|
|
11733
|
+
size === "sm" && "[&::-moz-range-thumb]:w-3 [&::-moz-range-thumb]:h-3",
|
|
11734
|
+
size === "md" && "[&::-moz-range-thumb]:w-4 [&::-moz-range-thumb]:h-4",
|
|
11735
|
+
size === "lg" && "[&::-moz-range-thumb]:w-5 [&::-moz-range-thumb]:h-5",
|
|
11736
|
+
// Remove default track in Firefox
|
|
11737
|
+
"[&::-moz-range-track]:bg-transparent",
|
|
11738
|
+
"[&::-moz-range-track]:border-transparent",
|
|
11739
|
+
// Hover effects - Enhanced premium look
|
|
11740
|
+
"hover:[&::-webkit-slider-thumb]:scale-110 hover:[&::-webkit-slider-thumb]:shadow-[0_4px_16px_rgba(0,0,0,0.2),0_0_12px_rgba(var(--primary-rgb,147,51,234),0.4)]",
|
|
11741
|
+
"hover:[&::-moz-range-thumb]:scale-110 hover:[&::-moz-range-thumb]:shadow-[0_4px_16px_rgba(0,0,0,0.2),0_0_12px_rgba(var(--primary-rgb,147,51,234),0.4)]",
|
|
11742
|
+
// Active/dragging effects
|
|
11743
|
+
"active:[&::-webkit-slider-thumb]:scale-105 active:[&::-webkit-slider-thumb]:shadow-[0_2px_12px_rgba(0,0,0,0.25),0_0_16px_rgba(var(--primary-rgb,147,51,234),0.5)]",
|
|
11744
|
+
"active:[&::-moz-range-thumb]:scale-105 active:[&::-moz-range-thumb]:shadow-[0_2px_12px_rgba(0,0,0,0.25),0_0_16px_rgba(var(--primary-rgb,147,51,234),0.5)]",
|
|
11745
|
+
// Disabled styles
|
|
11746
|
+
disabled && [
|
|
11747
|
+
"cursor-not-allowed opacity-50",
|
|
11748
|
+
"[&::-webkit-slider-thumb]:cursor-not-allowed [&::-webkit-slider-thumb]:opacity-50 [&::-webkit-slider-thumb]:shadow-none",
|
|
11749
|
+
"[&::-moz-range-thumb]:cursor-not-allowed [&::-moz-range-thumb]:opacity-50 [&::-moz-range-thumb]:shadow-none"
|
|
11750
|
+
],
|
|
11751
|
+
className,
|
|
11752
|
+
thumbClassName
|
|
11753
|
+
);
|
|
11754
|
+
if (!isRange) {
|
|
11755
|
+
return /* @__PURE__ */ jsx41(
|
|
11756
|
+
"input",
|
|
11757
|
+
{
|
|
11758
|
+
ref,
|
|
11759
|
+
type: "range",
|
|
11760
|
+
min,
|
|
11761
|
+
max,
|
|
11762
|
+
step,
|
|
11763
|
+
value: currentValue,
|
|
11764
|
+
onChange: handleSingleChange,
|
|
11765
|
+
onMouseDown: () => setIsDragging(true),
|
|
11766
|
+
onMouseUp: () => {
|
|
11767
|
+
setIsDragging(false);
|
|
11768
|
+
onMouseUp?.();
|
|
11769
|
+
},
|
|
11770
|
+
onTouchStart: () => setIsDragging(true),
|
|
11771
|
+
onTouchEnd: () => {
|
|
11772
|
+
setIsDragging(false);
|
|
11773
|
+
onTouchEnd?.();
|
|
11774
|
+
},
|
|
11775
|
+
disabled,
|
|
11776
|
+
className: baseInputClassName,
|
|
11777
|
+
...props
|
|
11778
|
+
}
|
|
11779
|
+
);
|
|
11760
11780
|
}
|
|
11761
|
-
|
|
11762
|
-
|
|
11763
|
-
|
|
11764
|
-
|
|
11781
|
+
const minZ = activeThumb === "min" ? "z-20" : "z-10";
|
|
11782
|
+
const maxZ = activeThumb === "max" ? "z-20" : "z-10";
|
|
11783
|
+
return /* @__PURE__ */ jsxs36(Fragment14, { children: [
|
|
11784
|
+
/* @__PURE__ */ jsx41(
|
|
11785
|
+
"div",
|
|
11786
|
+
{
|
|
11787
|
+
className: cn("absolute inset-0 z-30", disabled ? "cursor-not-allowed" : "cursor-pointer"),
|
|
11788
|
+
onPointerDown: startRangeDrag,
|
|
11789
|
+
onPointerMove: moveRangeDrag,
|
|
11790
|
+
onPointerUp: endRangeDrag,
|
|
11791
|
+
onPointerCancel: endRangeDrag
|
|
11792
|
+
}
|
|
11793
|
+
),
|
|
11794
|
+
/* @__PURE__ */ jsx41(
|
|
11795
|
+
"input",
|
|
11796
|
+
{
|
|
11797
|
+
ref,
|
|
11798
|
+
type: "range",
|
|
11799
|
+
min,
|
|
11800
|
+
max,
|
|
11801
|
+
step,
|
|
11802
|
+
value: normalizedRange[0],
|
|
11803
|
+
onChange: handleRangeChange("min"),
|
|
11804
|
+
onMouseUp,
|
|
11805
|
+
onTouchEnd,
|
|
11806
|
+
disabled,
|
|
11807
|
+
"aria-label": "Minimum value",
|
|
11808
|
+
onPointerDown: () => setActiveThumb("min"),
|
|
11809
|
+
onFocus: () => setActiveThumb("min"),
|
|
11810
|
+
className: cn(baseInputClassName, minZ, "pointer-events-none"),
|
|
11811
|
+
...props
|
|
11812
|
+
}
|
|
11813
|
+
),
|
|
11814
|
+
/* @__PURE__ */ jsx41(
|
|
11815
|
+
"input",
|
|
11816
|
+
{
|
|
11817
|
+
type: "range",
|
|
11818
|
+
min,
|
|
11819
|
+
max,
|
|
11820
|
+
step,
|
|
11821
|
+
value: normalizedRange[1],
|
|
11822
|
+
onChange: handleRangeChange("max"),
|
|
11823
|
+
onMouseUp,
|
|
11824
|
+
onTouchEnd,
|
|
11825
|
+
disabled,
|
|
11826
|
+
"aria-label": "Maximum value",
|
|
11827
|
+
onPointerDown: () => setActiveThumb("max"),
|
|
11828
|
+
onFocus: () => setActiveThumb("max"),
|
|
11829
|
+
className: cn(baseInputClassName, maxZ, "pointer-events-none"),
|
|
11830
|
+
...props
|
|
11831
|
+
}
|
|
11832
|
+
)
|
|
11833
|
+
] });
|
|
11834
|
+
})()
|
|
11835
|
+
]
|
|
11836
|
+
}
|
|
11837
|
+
)
|
|
11765
11838
|
] });
|
|
11766
11839
|
}
|
|
11767
11840
|
);
|
|
@@ -13979,7 +14052,7 @@ var TimelineItem = React42.forwardRef(
|
|
|
13979
14052
|
const horizontalItem = /* @__PURE__ */ jsxs44(
|
|
13980
14053
|
"div",
|
|
13981
14054
|
{
|
|
13982
|
-
className: cn("flex flex-col items-center gap-2 min-w-
|
|
14055
|
+
className: cn("flex flex-col items-center gap-2 min-w-50", ctx.animate && "animate-in fade-in-50 zoom-in-95 duration-500"),
|
|
13983
14056
|
style: { animationDelay: ctx.animate ? `${(idx ?? 0) * 100}ms` : void 0 },
|
|
13984
14057
|
children: [
|
|
13985
14058
|
/* @__PURE__ */ jsx49(
|
|
@@ -19223,12 +19296,12 @@ function buildUEditorExtensions({
|
|
|
19223
19296
|
TableRow2,
|
|
19224
19297
|
TableCell2.configure({
|
|
19225
19298
|
HTMLAttributes: {
|
|
19226
|
-
class: "border border-border p-2 min-w-
|
|
19299
|
+
class: "border border-border p-2 min-w-25"
|
|
19227
19300
|
}
|
|
19228
19301
|
}),
|
|
19229
19302
|
TableHeader2.configure({
|
|
19230
19303
|
HTMLAttributes: {
|
|
19231
|
-
class: "border border-border p-2 bg-muted font-semibold min-w-
|
|
19304
|
+
class: "border border-border p-2 bg-muted font-semibold min-w-25"
|
|
19232
19305
|
}
|
|
19233
19306
|
}),
|
|
19234
19307
|
CharacterCount.configure({
|