@mlw-packages/react-components 1.9.8 → 1.9.9
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.css +8 -28
- package/dist/index.d.mts +43 -30
- package/dist/index.d.ts +43 -30
- package/dist/index.js +109 -288
- package/dist/index.mjs +111 -285
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import './index.css';
|
|
2
2
|
import * as React33 from 'react';
|
|
3
|
-
import React33__default, {
|
|
3
|
+
import React33__default, { forwardRef, useState, useEffect, createContext, useMemo, useRef, useCallback, useContext, useId, useLayoutEffect } from 'react';
|
|
4
4
|
import { Slot } from '@radix-ui/react-slot';
|
|
5
5
|
import { cva } from 'class-variance-authority';
|
|
6
6
|
import { clsx } from 'clsx';
|
|
7
7
|
import { twMerge } from 'tailwind-merge';
|
|
8
|
-
import { XIcon, CircleNotchIcon, MagnifyingGlassIcon, CaretUpIcon, CaretDownIcon, CheckIcon, CaretRightIcon, CircleIcon, CloudArrowUpIcon, MinusIcon, CaretUpDownIcon, PencilSimpleIcon, ArrowsLeftRightIcon, FloppyDiskIcon, PlusIcon, TrashIcon, SidebarSimpleIcon, FilePdfIcon, FileDocIcon, FileXlsIcon, FilePptIcon, FileCsvIcon, FileTextIcon, FileImageIcon, FileVideoIcon, FileAudioIcon, FileZipIcon, FileIcon, DotsSixVerticalIcon, InfoIcon, WarningIcon, XCircleIcon, CheckCircleIcon, SunIcon, MoonIcon, CaretLeftIcon, DownloadSimpleIcon, UploadSimpleIcon, CopyIcon, ArrowClockwiseIcon, ArrowLeftIcon, GearIcon, BellIcon, DotsThreeIcon, FunnelIcon, HeartIcon, StarIcon, EyeIcon, EyeSlashIcon, LockIcon, LockOpenIcon, ArrowRightIcon as ArrowRightIcon$1,
|
|
8
|
+
import { XIcon, CircleNotchIcon, MagnifyingGlassIcon, CaretUpIcon, CaretDownIcon, CheckIcon, CaretRightIcon, CircleIcon, CloudArrowUpIcon, MinusIcon, CaretUpDownIcon, PencilSimpleIcon, ArrowsLeftRightIcon, FloppyDiskIcon, PlusIcon, TrashIcon, SidebarSimpleIcon, FilePdfIcon, FileDocIcon, FileXlsIcon, FilePptIcon, FileCsvIcon, FileTextIcon, FileImageIcon, FileVideoIcon, FileAudioIcon, FileZipIcon, FileIcon, DotsSixVerticalIcon, InfoIcon, WarningIcon, XCircleIcon, CheckCircleIcon, SunIcon, MoonIcon, CaretLeftIcon, DownloadSimpleIcon, UploadSimpleIcon, CopyIcon, ArrowClockwiseIcon, ArrowLeftIcon, GearIcon, BellIcon, DotsThreeIcon, FunnelIcon, HeartIcon, StarIcon, EyeIcon, EyeSlashIcon, LockIcon, LockOpenIcon, FolderIcon, ArrowRightIcon as ArrowRightIcon$1, ArrowsOutIcon, DownloadIcon, CalendarBlankIcon, CalendarIcon, CaretLeft, CaretRight, ArrowDownIcon, ClockUserIcon, EyeSlash, Eye, ArrowRight, ArrowUpRightIcon, ArrowDownRightIcon, FunnelSimpleIcon, FileArchiveIcon, TerminalIcon, CodeIcon, CalendarDotIcon as CalendarDotIcon$1, DesktopIcon } from '@phosphor-icons/react';
|
|
9
9
|
import * as AlertDialogPrimitive from '@radix-ui/react-alert-dialog';
|
|
10
10
|
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
11
11
|
import * as DialogPrimitive from '@radix-ui/react-dialog';
|
|
@@ -28,7 +28,6 @@ import * as HoverCardPrimitive from '@radix-ui/react-hover-card';
|
|
|
28
28
|
import { OTPInput, OTPInputContext } from 'input-otp';
|
|
29
29
|
import * as SliderPrimitive from '@radix-ui/react-slider';
|
|
30
30
|
import * as SwitchPrimitives from '@radix-ui/react-switch';
|
|
31
|
-
import useEmblaCarousel from 'embla-carousel-react';
|
|
32
31
|
import * as ScrollAreaPrimitive from '@radix-ui/react-scroll-area';
|
|
33
32
|
import * as SeparatorPrimitive from '@radix-ui/react-separator';
|
|
34
33
|
import * as TabsPrimitive from '@radix-ui/react-tabs';
|
|
@@ -1850,7 +1849,8 @@ var InputBase = React33.forwardRef(
|
|
|
1850
1849
|
className: cn(
|
|
1851
1850
|
"flex items-center rounded-md transition h-9 bg-background overflow-hidden",
|
|
1852
1851
|
type !== "file" && "border border-input",
|
|
1853
|
-
error ? "border-destructive focus:ring-1 focus:ring-destructive" : "border-input"
|
|
1852
|
+
error ? "border-destructive focus:ring-1 focus:ring-destructive" : "border-input",
|
|
1853
|
+
className
|
|
1854
1854
|
),
|
|
1855
1855
|
children: [
|
|
1856
1856
|
leftIcon && /* @__PURE__ */ jsx("div", { className: "flex items-center justify-center px-2", children: leftIcon }),
|
|
@@ -1878,6 +1878,65 @@ var InputBase = React33.forwardRef(
|
|
|
1878
1878
|
}
|
|
1879
1879
|
);
|
|
1880
1880
|
InputBase.displayName = "Input";
|
|
1881
|
+
var DebouncedInput = forwardRef(
|
|
1882
|
+
({
|
|
1883
|
+
value: initialValue,
|
|
1884
|
+
onChange,
|
|
1885
|
+
debounce: debounce2 = 500,
|
|
1886
|
+
label,
|
|
1887
|
+
labelClassname,
|
|
1888
|
+
leftIcon,
|
|
1889
|
+
rightIcon,
|
|
1890
|
+
showLoadingIndicator = false,
|
|
1891
|
+
className,
|
|
1892
|
+
error,
|
|
1893
|
+
...props
|
|
1894
|
+
}, ref) => {
|
|
1895
|
+
const [value, setValue] = useState(initialValue);
|
|
1896
|
+
const [isDebouncing, setIsDebouncing] = useState(false);
|
|
1897
|
+
useEffect(() => {
|
|
1898
|
+
setValue(initialValue);
|
|
1899
|
+
}, [initialValue]);
|
|
1900
|
+
useEffect(() => {
|
|
1901
|
+
if (value === initialValue) {
|
|
1902
|
+
setIsDebouncing(false);
|
|
1903
|
+
return;
|
|
1904
|
+
}
|
|
1905
|
+
setIsDebouncing(true);
|
|
1906
|
+
const timeout = setTimeout(() => {
|
|
1907
|
+
onChange(value);
|
|
1908
|
+
setIsDebouncing(false);
|
|
1909
|
+
}, debounce2);
|
|
1910
|
+
return () => {
|
|
1911
|
+
clearTimeout(timeout);
|
|
1912
|
+
setIsDebouncing(false);
|
|
1913
|
+
};
|
|
1914
|
+
}, [debounce2, initialValue, onChange, value]);
|
|
1915
|
+
const renderRightIcon = () => {
|
|
1916
|
+
if (showLoadingIndicator && isDebouncing) {
|
|
1917
|
+
return /* @__PURE__ */ jsx(CircleNotchIcon, { className: "h-4 w-4 animate-spin text-muted-foreground" });
|
|
1918
|
+
}
|
|
1919
|
+
return rightIcon;
|
|
1920
|
+
};
|
|
1921
|
+
return /* @__PURE__ */ jsx(
|
|
1922
|
+
InputBase,
|
|
1923
|
+
{
|
|
1924
|
+
...props,
|
|
1925
|
+
ref,
|
|
1926
|
+
label,
|
|
1927
|
+
labelClassname,
|
|
1928
|
+
leftIcon,
|
|
1929
|
+
rightIcon: renderRightIcon(),
|
|
1930
|
+
className: cn("transition-all duration-200", className),
|
|
1931
|
+
value,
|
|
1932
|
+
onChange: (e) => setValue(e.target.value),
|
|
1933
|
+
error
|
|
1934
|
+
}
|
|
1935
|
+
);
|
|
1936
|
+
}
|
|
1937
|
+
);
|
|
1938
|
+
DebouncedInput.displayName = "DebouncedInput";
|
|
1939
|
+
var DebouncedInput_default = DebouncedInput;
|
|
1881
1940
|
var CommandBase = React33.forwardRef(({ className, testid: dataTestId = "command-base", ...props }, ref) => /* @__PURE__ */ jsx(
|
|
1882
1941
|
Command,
|
|
1883
1942
|
{
|
|
@@ -1934,29 +1993,47 @@ var CommandInputBase = React33.forwardRef(({ className, testid: dataTestId = "co
|
|
|
1934
1993
|
}
|
|
1935
1994
|
));
|
|
1936
1995
|
CommandInputBase.displayName = Command.Input.displayName;
|
|
1937
|
-
var CommandDebouncedInputBase = React33.forwardRef(
|
|
1938
|
-
|
|
1939
|
-
|
|
1940
|
-
|
|
1941
|
-
|
|
1942
|
-
|
|
1943
|
-
|
|
1944
|
-
|
|
1945
|
-
|
|
1946
|
-
|
|
1947
|
-
|
|
1948
|
-
|
|
1949
|
-
|
|
1950
|
-
|
|
1951
|
-
|
|
1952
|
-
|
|
1953
|
-
|
|
1954
|
-
|
|
1955
|
-
|
|
1956
|
-
|
|
1957
|
-
|
|
1958
|
-
|
|
1959
|
-
|
|
1996
|
+
var CommandDebouncedInputBase = React33.forwardRef(
|
|
1997
|
+
({
|
|
1998
|
+
className,
|
|
1999
|
+
testid: dataTestId = "command-input",
|
|
2000
|
+
onValueChange,
|
|
2001
|
+
value: propValue,
|
|
2002
|
+
onChange: propOnChange,
|
|
2003
|
+
search,
|
|
2004
|
+
onSearch,
|
|
2005
|
+
...props
|
|
2006
|
+
}, ref) => /* @__PURE__ */ jsxs(
|
|
2007
|
+
"div",
|
|
2008
|
+
{
|
|
2009
|
+
className: "flex items-center px-3 border-border border-b",
|
|
2010
|
+
"cmdk-input-wrapper": "",
|
|
2011
|
+
children: [
|
|
2012
|
+
/* @__PURE__ */ jsx(MagnifyingGlassIcon, { className: "mr-2 h-4 w-4 shrink-0 text-primary" }),
|
|
2013
|
+
/* @__PURE__ */ jsx(
|
|
2014
|
+
DebouncedInput_default,
|
|
2015
|
+
{
|
|
2016
|
+
ref,
|
|
2017
|
+
className: cn(
|
|
2018
|
+
"flex h-10 border-transparent w-full rounded-md bg-transparent text-sm outline-none text-primary placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50",
|
|
2019
|
+
className
|
|
2020
|
+
),
|
|
2021
|
+
"data-testid": dataTestId,
|
|
2022
|
+
"cmdk-input": "",
|
|
2023
|
+
value: search ?? propValue ?? "",
|
|
2024
|
+
...props,
|
|
2025
|
+
onChange: (value) => {
|
|
2026
|
+
onValueChange?.(value);
|
|
2027
|
+
propOnChange?.(value);
|
|
2028
|
+
onSearch?.(value);
|
|
2029
|
+
}
|
|
2030
|
+
}
|
|
2031
|
+
)
|
|
2032
|
+
]
|
|
2033
|
+
}
|
|
2034
|
+
)
|
|
2035
|
+
);
|
|
2036
|
+
CommandDebouncedInputBase.displayName = "CommandDebouncedInputBase";
|
|
1960
2037
|
var CommandListBase = React33.forwardRef(
|
|
1961
2038
|
({ className, testid: dataTestId = "command-list", onEndReached, ...props }, ref) => {
|
|
1962
2039
|
const listRef = React33.useRef(null);
|
|
@@ -3636,7 +3713,7 @@ var FileUploader = React33.forwardRef(
|
|
|
3636
3713
|
showPreview = true,
|
|
3637
3714
|
dropzoneText = "Arraste arquivos aqui ou clique para selecionar",
|
|
3638
3715
|
dropzoneSubtext,
|
|
3639
|
-
animate = true,
|
|
3716
|
+
animate: animate2 = true,
|
|
3640
3717
|
...props
|
|
3641
3718
|
}, ref) => {
|
|
3642
3719
|
const [isDragging, setIsDragging] = React33.useState(false);
|
|
@@ -3844,7 +3921,7 @@ var FileUploader = React33.forwardRef(
|
|
|
3844
3921
|
motion.p,
|
|
3845
3922
|
{
|
|
3846
3923
|
className: "mb-2 text-base font-semibold text-foreground",
|
|
3847
|
-
initial:
|
|
3924
|
+
initial: animate2 ? { opacity: 0, y: -10 } : false,
|
|
3848
3925
|
animate: { opacity: 1, y: 0 },
|
|
3849
3926
|
transition: { delay: 0.1 },
|
|
3850
3927
|
children: dropzoneText
|
|
@@ -3854,7 +3931,7 @@ var FileUploader = React33.forwardRef(
|
|
|
3854
3931
|
motion.p,
|
|
3855
3932
|
{
|
|
3856
3933
|
className: "text-sm text-muted-foreground",
|
|
3857
|
-
initial:
|
|
3934
|
+
initial: animate2 ? { opacity: 0, y: -10 } : false,
|
|
3858
3935
|
animate: { opacity: 1, y: 0 },
|
|
3859
3936
|
transition: { delay: 0.2 },
|
|
3860
3937
|
children: defaultSubtext
|
|
@@ -3898,7 +3975,7 @@ var FileUploader = React33.forwardRef(
|
|
|
3898
3975
|
motion.div,
|
|
3899
3976
|
{
|
|
3900
3977
|
className: "mt-6 w-full",
|
|
3901
|
-
initial:
|
|
3978
|
+
initial: animate2 ? { opacity: 0, y: 10 } : false,
|
|
3902
3979
|
animate: { opacity: 1, y: 0 },
|
|
3903
3980
|
transition: { delay: 0.3 },
|
|
3904
3981
|
children: /* @__PURE__ */ jsxs("div", { children: [
|
|
@@ -3913,7 +3990,7 @@ var FileUploader = React33.forwardRef(
|
|
|
3913
3990
|
motion.div,
|
|
3914
3991
|
{
|
|
3915
3992
|
layout: true,
|
|
3916
|
-
initial:
|
|
3993
|
+
initial: animate2 ? { opacity: 0, x: -20 } : false,
|
|
3917
3994
|
animate: { opacity: 1, x: 0 },
|
|
3918
3995
|
exit: {
|
|
3919
3996
|
opacity: 0,
|
|
@@ -3921,7 +3998,7 @@ var FileUploader = React33.forwardRef(
|
|
|
3921
3998
|
transition: { duration: 0.2 }
|
|
3922
3999
|
},
|
|
3923
4000
|
transition: {
|
|
3924
|
-
delay:
|
|
4001
|
+
delay: animate2 ? index * 0.05 : 0,
|
|
3925
4002
|
layout: { duration: 0.2 }
|
|
3926
4003
|
},
|
|
3927
4004
|
className: cn(
|
|
@@ -5159,201 +5236,6 @@ var TextAreaBase = React33.forwardRef(
|
|
|
5159
5236
|
}
|
|
5160
5237
|
);
|
|
5161
5238
|
TextAreaBase.displayName = "TextAreaBase";
|
|
5162
|
-
var CarouselContext = React33.createContext(null);
|
|
5163
|
-
function useCarousel() {
|
|
5164
|
-
const context = React33.useContext(CarouselContext);
|
|
5165
|
-
if (!context) {
|
|
5166
|
-
throw new Error("useCarousel must be used within a <CarouselBase />");
|
|
5167
|
-
}
|
|
5168
|
-
return context;
|
|
5169
|
-
}
|
|
5170
|
-
function CarouselBase({
|
|
5171
|
-
orientation = "horizontal",
|
|
5172
|
-
opts,
|
|
5173
|
-
setApi,
|
|
5174
|
-
plugins,
|
|
5175
|
-
className,
|
|
5176
|
-
children,
|
|
5177
|
-
...props
|
|
5178
|
-
}) {
|
|
5179
|
-
const [carouselRef, api] = useEmblaCarousel(
|
|
5180
|
-
{
|
|
5181
|
-
...opts,
|
|
5182
|
-
axis: orientation === "horizontal" ? "x" : "y"
|
|
5183
|
-
},
|
|
5184
|
-
plugins
|
|
5185
|
-
);
|
|
5186
|
-
const [canScrollPrev, setCanScrollPrev] = React33.useState(false);
|
|
5187
|
-
const [canScrollNext, setCanScrollNext] = React33.useState(false);
|
|
5188
|
-
const onSelect = React33.useCallback((api2) => {
|
|
5189
|
-
if (!api2) return;
|
|
5190
|
-
setCanScrollPrev(api2.canScrollPrev());
|
|
5191
|
-
setCanScrollNext(api2.canScrollNext());
|
|
5192
|
-
}, []);
|
|
5193
|
-
const scrollPrev = React33.useCallback(() => {
|
|
5194
|
-
api?.scrollPrev();
|
|
5195
|
-
}, [api]);
|
|
5196
|
-
const scrollNext = React33.useCallback(() => {
|
|
5197
|
-
api?.scrollNext();
|
|
5198
|
-
}, [api]);
|
|
5199
|
-
const handleKeyDown = React33.useCallback(
|
|
5200
|
-
(event) => {
|
|
5201
|
-
if (event.key === "ArrowLeft") {
|
|
5202
|
-
event.preventDefault();
|
|
5203
|
-
scrollPrev();
|
|
5204
|
-
} else if (event.key === "ArrowRight") {
|
|
5205
|
-
event.preventDefault();
|
|
5206
|
-
scrollNext();
|
|
5207
|
-
}
|
|
5208
|
-
},
|
|
5209
|
-
[scrollPrev, scrollNext]
|
|
5210
|
-
);
|
|
5211
|
-
React33.useEffect(() => {
|
|
5212
|
-
if (!api || !setApi) return;
|
|
5213
|
-
setApi(api);
|
|
5214
|
-
}, [api, setApi]);
|
|
5215
|
-
React33.useEffect(() => {
|
|
5216
|
-
if (!api) return;
|
|
5217
|
-
onSelect(api);
|
|
5218
|
-
api.on("reInit", onSelect);
|
|
5219
|
-
api.on("select", onSelect);
|
|
5220
|
-
return () => {
|
|
5221
|
-
api?.off("select", onSelect);
|
|
5222
|
-
};
|
|
5223
|
-
}, [api, onSelect]);
|
|
5224
|
-
return /* @__PURE__ */ jsx(
|
|
5225
|
-
CarouselContext.Provider,
|
|
5226
|
-
{
|
|
5227
|
-
value: {
|
|
5228
|
-
carouselRef,
|
|
5229
|
-
api,
|
|
5230
|
-
opts,
|
|
5231
|
-
orientation: orientation || (opts?.axis === "y" ? "vertical" : "horizontal"),
|
|
5232
|
-
scrollPrev,
|
|
5233
|
-
scrollNext,
|
|
5234
|
-
canScrollPrev,
|
|
5235
|
-
canScrollNext
|
|
5236
|
-
},
|
|
5237
|
-
children: /* @__PURE__ */ jsx(
|
|
5238
|
-
"div",
|
|
5239
|
-
{
|
|
5240
|
-
onKeyDownCapture: handleKeyDown,
|
|
5241
|
-
className: cn("relative", className),
|
|
5242
|
-
role: "region",
|
|
5243
|
-
"aria-roledescription": "carousel",
|
|
5244
|
-
"data-slot": "carousel",
|
|
5245
|
-
...props,
|
|
5246
|
-
children
|
|
5247
|
-
}
|
|
5248
|
-
)
|
|
5249
|
-
}
|
|
5250
|
-
);
|
|
5251
|
-
}
|
|
5252
|
-
function CarouselContentBase({
|
|
5253
|
-
className,
|
|
5254
|
-
...props
|
|
5255
|
-
}) {
|
|
5256
|
-
const { carouselRef, orientation } = useCarousel();
|
|
5257
|
-
return /* @__PURE__ */ jsx(
|
|
5258
|
-
"div",
|
|
5259
|
-
{
|
|
5260
|
-
ref: carouselRef,
|
|
5261
|
-
className: "overflow-hidden",
|
|
5262
|
-
"data-slot": "carousel-content",
|
|
5263
|
-
children: /* @__PURE__ */ jsx(
|
|
5264
|
-
"div",
|
|
5265
|
-
{
|
|
5266
|
-
className: cn(
|
|
5267
|
-
"flex",
|
|
5268
|
-
orientation === "horizontal" ? "-ml-4" : "-mt-4 flex-col",
|
|
5269
|
-
className
|
|
5270
|
-
),
|
|
5271
|
-
...props
|
|
5272
|
-
}
|
|
5273
|
-
)
|
|
5274
|
-
}
|
|
5275
|
-
);
|
|
5276
|
-
}
|
|
5277
|
-
function CarouselItemBase({
|
|
5278
|
-
className,
|
|
5279
|
-
...props
|
|
5280
|
-
}) {
|
|
5281
|
-
const { orientation } = useCarousel();
|
|
5282
|
-
return /* @__PURE__ */ jsx(
|
|
5283
|
-
"div",
|
|
5284
|
-
{
|
|
5285
|
-
role: "group",
|
|
5286
|
-
"aria-roledescription": "slide",
|
|
5287
|
-
"data-slot": "carousel-item",
|
|
5288
|
-
className: cn(
|
|
5289
|
-
"min-w-0 shrink-0 grow-0 basis-full",
|
|
5290
|
-
orientation === "horizontal" ? "pl-4" : "pt-4",
|
|
5291
|
-
className
|
|
5292
|
-
),
|
|
5293
|
-
...props
|
|
5294
|
-
}
|
|
5295
|
-
);
|
|
5296
|
-
}
|
|
5297
|
-
function CarouselPreviousBase({
|
|
5298
|
-
className,
|
|
5299
|
-
variant = "outline",
|
|
5300
|
-
size = "icon",
|
|
5301
|
-
...props
|
|
5302
|
-
}) {
|
|
5303
|
-
const { orientation, scrollPrev, canScrollPrev } = useCarousel();
|
|
5304
|
-
const btnRef = React33.useRef(null);
|
|
5305
|
-
return /* @__PURE__ */ jsxs(
|
|
5306
|
-
ButtonBase,
|
|
5307
|
-
{
|
|
5308
|
-
"data-slot": "carousel-previous",
|
|
5309
|
-
variant,
|
|
5310
|
-
size,
|
|
5311
|
-
ref: btnRef,
|
|
5312
|
-
className: cn(
|
|
5313
|
-
"absolute size-8 rounded-l-3xl px-6",
|
|
5314
|
-
orientation === "horizontal" ? "top-2 right-1" : "bottom-64 left-1/3 rotate-90",
|
|
5315
|
-
className
|
|
5316
|
-
),
|
|
5317
|
-
disabled: !canScrollPrev,
|
|
5318
|
-
onClick: scrollPrev,
|
|
5319
|
-
...props,
|
|
5320
|
-
children: [
|
|
5321
|
-
/* @__PURE__ */ jsx(ArrowLeftIcon, {}),
|
|
5322
|
-
/* @__PURE__ */ jsx("span", { className: "sr-only", children: "Previous slide" })
|
|
5323
|
-
]
|
|
5324
|
-
}
|
|
5325
|
-
);
|
|
5326
|
-
}
|
|
5327
|
-
function CarouselNextBase({
|
|
5328
|
-
className,
|
|
5329
|
-
variant = "outline",
|
|
5330
|
-
size = "icon",
|
|
5331
|
-
...props
|
|
5332
|
-
}) {
|
|
5333
|
-
const { orientation, scrollNext, canScrollNext } = useCarousel();
|
|
5334
|
-
const btnRef = React33.useRef(null);
|
|
5335
|
-
return /* @__PURE__ */ jsxs(
|
|
5336
|
-
ButtonBase,
|
|
5337
|
-
{
|
|
5338
|
-
"data-slot": "carousel-next",
|
|
5339
|
-
variant,
|
|
5340
|
-
size,
|
|
5341
|
-
ref: btnRef,
|
|
5342
|
-
className: cn(
|
|
5343
|
-
"absolute size-8 rounded-r-3xl px-6",
|
|
5344
|
-
orientation === "horizontal" ? "top-2" : "left-14 -translate-x-1/2 rotate-90",
|
|
5345
|
-
className
|
|
5346
|
-
),
|
|
5347
|
-
disabled: !canScrollNext,
|
|
5348
|
-
onClick: scrollNext,
|
|
5349
|
-
...props,
|
|
5350
|
-
children: [
|
|
5351
|
-
/* @__PURE__ */ jsx(ArrowRightIcon$1, {}),
|
|
5352
|
-
/* @__PURE__ */ jsx("span", { className: "sr-only", children: "Next slide" })
|
|
5353
|
-
]
|
|
5354
|
-
}
|
|
5355
|
-
);
|
|
5356
|
-
}
|
|
5357
5239
|
var ScrollAreaBase = React33.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxs(
|
|
5358
5240
|
ScrollAreaPrimitive.Root,
|
|
5359
5241
|
{
|
|
@@ -7323,62 +7205,6 @@ function StatusIndicator({
|
|
|
7323
7205
|
/* @__PURE__ */ jsx("div", { className: "min-w-0", children })
|
|
7324
7206
|
] });
|
|
7325
7207
|
}
|
|
7326
|
-
var DebouncedInput = forwardRef(
|
|
7327
|
-
({
|
|
7328
|
-
value: initialValue,
|
|
7329
|
-
onChange,
|
|
7330
|
-
debounce: debounce2 = 500,
|
|
7331
|
-
label,
|
|
7332
|
-
labelClassname,
|
|
7333
|
-
leftIcon,
|
|
7334
|
-
rightIcon,
|
|
7335
|
-
showLoadingIndicator = false,
|
|
7336
|
-
className,
|
|
7337
|
-
error,
|
|
7338
|
-
...props
|
|
7339
|
-
}, ref) => {
|
|
7340
|
-
const [value, setValue] = useState(initialValue);
|
|
7341
|
-
const [isDebouncing, setIsDebouncing] = useState(false);
|
|
7342
|
-
useEffect(() => {
|
|
7343
|
-
setValue(initialValue);
|
|
7344
|
-
}, [initialValue]);
|
|
7345
|
-
useEffect(() => {
|
|
7346
|
-
if (value !== initialValue) {
|
|
7347
|
-
setIsDebouncing(true);
|
|
7348
|
-
}
|
|
7349
|
-
const timeout = setTimeout(() => {
|
|
7350
|
-
onChange(value);
|
|
7351
|
-
setIsDebouncing(false);
|
|
7352
|
-
}, debounce2);
|
|
7353
|
-
return () => {
|
|
7354
|
-
clearTimeout(timeout);
|
|
7355
|
-
setIsDebouncing(false);
|
|
7356
|
-
};
|
|
7357
|
-
}, [debounce2, initialValue, onChange, value]);
|
|
7358
|
-
const renderRightIcon = () => {
|
|
7359
|
-
if (showLoadingIndicator && isDebouncing) {
|
|
7360
|
-
return /* @__PURE__ */ jsx(CircleNotchIcon, { className: "h-4 w-4 animate-spin text-muted-foreground" });
|
|
7361
|
-
}
|
|
7362
|
-
return rightIcon;
|
|
7363
|
-
};
|
|
7364
|
-
return /* @__PURE__ */ jsx(
|
|
7365
|
-
InputBase,
|
|
7366
|
-
{
|
|
7367
|
-
...props,
|
|
7368
|
-
ref,
|
|
7369
|
-
label,
|
|
7370
|
-
labelClassname,
|
|
7371
|
-
leftIcon,
|
|
7372
|
-
rightIcon: renderRightIcon(),
|
|
7373
|
-
className: cn("transition-all duration-200", className),
|
|
7374
|
-
value,
|
|
7375
|
-
onChange: (e) => setValue(e.target.value),
|
|
7376
|
-
error
|
|
7377
|
-
}
|
|
7378
|
-
);
|
|
7379
|
-
}
|
|
7380
|
-
);
|
|
7381
|
-
DebouncedInput.displayName = "DebouncedInput";
|
|
7382
7208
|
function useCheckboxTree(initialTree) {
|
|
7383
7209
|
const initialCheckedNodes = useMemo(() => {
|
|
7384
7210
|
const checkedSet = /* @__PURE__ */ new Set();
|
|
@@ -18780,4 +18606,4 @@ function Leaderboard({
|
|
|
18780
18606
|
);
|
|
18781
18607
|
}
|
|
18782
18608
|
|
|
18783
|
-
export { AddButton, Agenda, AgendaDaysToShow, AgendaDaysToShowAgenda, AgendaView, AlertDialogActionBase, AlertDialogBase, AlertDialogCancelBase, AlertDialogContentBase, AlertDialogDescriptionBase, AlertDialogFooterBase, AlertDialogHeaderBase, AlertDialogOverlayBase, AlertDialogPortalBase, AlertDialogTitleBase, AlertDialogTriggerBase, AvatarBase, AvatarCombobox, AvatarFallbackBase, AvatarImageBase, BackButton, Badge, BreadcrumbBase, BreadcrumbEllipsisBase, BreadcrumbItemBase, BreadcrumbLinkBase, BreadcrumbListBase, BreadcrumbPageBase, BreadcrumbSeparatorBase, Brush_default as Brush, ButtonBase, ButtonGroupBase, CENTER_INDEX, CalendarBase, CalendarDndProvider, CalendarDndProviderAgenda, CardBase, CardContentBase, CardDescriptionBase, CardFooterBase, CardHeaderBase, CardTitleBase,
|
|
18609
|
+
export { AddButton, Agenda, AgendaDaysToShow, AgendaDaysToShowAgenda, AgendaView, AlertDialogActionBase, AlertDialogBase, AlertDialogCancelBase, AlertDialogContentBase, AlertDialogDescriptionBase, AlertDialogFooterBase, AlertDialogHeaderBase, AlertDialogOverlayBase, AlertDialogPortalBase, AlertDialogTitleBase, AlertDialogTriggerBase, AvatarBase, AvatarCombobox, AvatarFallbackBase, AvatarImageBase, BackButton, Badge, BreadcrumbBase, BreadcrumbEllipsisBase, BreadcrumbItemBase, BreadcrumbLinkBase, BreadcrumbListBase, BreadcrumbPageBase, BreadcrumbSeparatorBase, Brush_default as Brush, ButtonBase, ButtonGroupBase, CENTER_INDEX, CalendarBase, CalendarDndProvider, CalendarDndProviderAgenda, CardBase, CardContentBase, CardDescriptionBase, CardFooterBase, CardHeaderBase, CardTitleBase, ChangeButton, Chart_default as Chart, ChartControls, ChartHeader, ChartTotalLegend_default as ChartTotalLegend, CheckButton, CheckboxBase, CheckboxTree, CloseAllButton_default as CloseAllButton, CloseButton, CodeBlock, CollapsibleBase, CollapsibleContentBase, CollapsibleTriggerBase, Combobox, CommandBase, CommandDebouncedInputBase, CommandDialogBase, CommandEmptyBase, CommandGroupBase, CommandInputBase, CommandItemBase, CommandListBase, CommandSeparatorBase, CommandShortcutBase, ContextMenuBase, ContextMenuCheckboxItemBase, ContextMenuContentBase, ContextMenuGroupBase, ContextMenuItemBase, ContextMenuLabelBase, ContextMenuPortalBase, ContextMenuRadioGroupBase, ContextMenuRadioItemBase, ContextMenuSeparatorBase, ContextMenuShortcutBase, ContextMenuSubBase, ContextMenuSubContentBase, ContextMenuSubTriggerBase, ContextMenuTriggerBase, CopyButton, DateTimePicker, DayView, DayViewAgenda, DebouncedInput, DefaultEndHour, DefaultEndHourAgenda, DefaultStartHour, DefaultStartHourAgenda, DestructiveDialog, DialogBase, DialogCloseBase, DialogContentBase, DialogDescriptionBase, DialogFooterBase, DialogHeaderBase, DialogOverlayBase, DialogPortalBase, DialogTitleBase, DialogTriggerBase, DownloadButton, DraggableEvent2 as DraggableEvent, DraggableTooltip_default as DraggableTooltip, DrawerBase, DrawerCloseBase, DrawerContentBase, DrawerDescriptionBase, DrawerFooterBase, DrawerHeaderBase, DrawerOverlayBase, DrawerPortalBase, DrawerTitleBase, DrawerTriggerBase, DropDownMenuBase, DropDownMenuCheckboxItemBase, DropDownMenuContentBase, DropDownMenuGroupBase, DropDownMenuItemBase, DropDownMenuLabelBase, DropDownMenuPortalBase, DropDownMenuRadioGroupBase, DropDownMenuRadioItemBase, DropDownMenuSeparatorBase, DropDownMenuShortcutBase, DropDownMenuSubBase, DropDownMenuSubContentBase, DropDownMenuSubTriggerBase, DropDownMenuTriggerBase, DroppableCell, DroppableCellAgenda, EditButton, EndHour, EndHourAgenda, ErrorMessage_default as ErrorMessage, EventAgenda, EventCalendar, EventDialog, EventGap, EventGapAgenda, EventHeight, EventHeightAgenda, EventItem, EventItemAgenda, EventsPopup, FavoriteButton, FileUploader, FilterButton, HideButton, Highlights_default as Highlights, HorizontalChart_default as HorizontalChart, HorizontalLegend_default as HorizontalLegend, HoverCardBase, HoverCardContentBase, HoverCardTriggerBase, ITEM_HEIGHT, InputBase, InputOTPBase, InputOTPGroupBase, InputOTPSeparatorBase, InputOTPSlotBase, LabelBase_default as LabelBase, Leaderboard, LikeButton, LoadingBase, LockButton, ModalBase, ModalCloseBase, ModalContentBase, ModalDescriptionBase, ModalFooterBase, ModalHeaderBase, ModalOverlayBase, ModalPortalBase, ModalTitleBase, ModalTriggerBase, ModeToggleBase, MonthView, MonthViewAgenda, MoreButton, MultiCombobox, MultiSelect, MultiSelectBase, MultiSelectContentBase, MultiSelectGroupBase, MultiSelectItemBase, MultiSelectSeparatorBase, MultiSelectTriggerBase, MultiSelectValueBase, NavigationMenuBase, NavigationMenuContentBase, NavigationMenuIndicatorBase, NavigationMenuItemBase, NavigationMenuLinkBase, NavigationMenuListBase, NavigationMenuTriggerBase, NavigationMenuViewportBase, NoData_default as NoData, NotificationButton, NumericInput, PeriodsDropdown_default as PeriodsDropdown, PopoverAnchorBase, PopoverBase, PopoverContentBase, PopoverTriggerBase, ProgressBase, ProgressCirclesBase, ProgressPanelsBase, ProgressSegmentsBase, RangePicker, RefreshButton, SaveButton, ScrollAreaBase, ScrollBarBase, SearchButton, Select, SelectBase, SelectContentBase, SelectEmpty, SelectGroupBase, SelectItemBase, SelectLabelBase, SelectScrollDownButtonBase, SelectScrollUpButtonBase, SelectSeparatorBase, SelectTriggerBase, SelectValueBase, SeparatorBase, SettingsButton, SheetBase, SheetCloseBase, SheetContentBase, SheetDescriptionBase, SheetFooterBase, SheetHeaderBase, SheetOverlayBase, SheetPortalBase, SheetTitleBase, SheetTriggerBase, ShowOnly_default as ShowOnly, SidebarBase, SidebarContentBase, SidebarFooterBase, SidebarGroupActionBase, SidebarGroupBase, SidebarGroupContentBase, SidebarGroupLabelBase, SidebarHeaderBase, SidebarInputBase, SidebarInsetBase, SidebarMenuActionBase, SidebarMenuBadgeBase, SidebarMenuBase, SidebarMenuButtonBase, SidebarMenuItemBase, SidebarMenuSkeletonBase, SidebarMenuSubBase, SidebarMenuSubButtonBase, SidebarMenuSubItemBase, SidebarProviderBase, SidebarRailBase, SidebarSeparatorBase, SidebarTriggerBase, SkeletonBase, SlideBase, StartHour, StartHourAgenda, StatusIndicator, SwitchBase, SystemTooltip_default as SystemTooltip, TableBase, TableBodyBase, TableCaptionBase, TableCellBase, TableFooterBase, TableHeadBase, TableHeaderBase, TableRowBase, TabsBase, TabsContentBase, TabsListBase, TabsTriggerBase, TextAreaBase, ThemeProviderBase, TimePicker, TimePickerInput, TimeSeries_default as TimeSeries, Toaster, TooltipBase, TooltipContentBase, TooltipProviderBase, TooltipSimple_default as TooltipSimple, TooltipTriggerBase, TooltipWithTotal_default as TooltipWithTotal, UndatedEvents, UniversalTooltipRenderer, UnlockButton, UploadButton, UseSideBarBase, VISIBLE_ITEMS, ViewButton, VisibilityButton, WeekCellsHeight, WeekCellsHeightAgenda, WeekView, WeekViewAgenda, adaptDataForTooltip, addHoursToDate, addHoursToDateAgenda, addMinutesToDateAgenda, badgeVariants, buttonVariantsBase, compactTick, computeChartWidth, computeNiceMax, computeYAxisTickWidth, convert12HourTo24Hour, createValueFormatter, createYTickFormatter, detectDataFields, detectXAxis, display12HourValue, formatFieldName, formatLinePercentage, generateAdditionalColors, generateColorMap, getAgendaEventsForDay, getAgendaEventsForDayAgenda, getAllEventsForDay, getAllEventsForDayAgenda, getArrowByType, getBorderRadiusClasses, getBorderRadiusClassesAgenda, getDateByType, getEventColorClasses, getEventColorClassesAgenda, getEventEndDate, getEventStartDate, getEventsForDay, getEventsForDayAgenda, getItems, getMaxDataValue, getMinDataValue, getSpanningEventsForDay, getSpanningEventsForDayAgenda, getValid12Hour, getValidArrow12Hour, getValidArrowHour, getValidArrowMinuteOrSecond, getValidArrowNumber, getValidHour, getValidMinuteOrSecond, getValidNumber, isMultiDayEvent, isMultiDayEventAgenda, isValid12Hour, isValidHour, isValidMinuteOrSecond, niceCeil, normalizeAttendDate, processNeo4jData, renderInsideBarLabel, pillLabelRenderer_default as renderPillLabel, resolveChartMargins, resolveContainerPaddingLeft, set12Hours, setDateByType, setHours, setMinutes, setSeconds, sortEvents, sortEventsAgenda, toast, useBiaxial, useCalendarDnd, useCalendarDndAgenda, useChartClick, useChartDimensions, useChartHighlights, useChartLayout, useChartMinMax, useChartTooltips, useCurrentTimeIndicator, useCurrentTimeIndicatorAgenda, useDrag, useEventVisibility, useEventVisibilityAgenda, useIsMobile, useOpenTooltipForPeriod, useProcessedData, useSeriesOpacity, useTheme, useTimeSeriesRange, visualForItem };
|