@contractspec/lib.ui-kit-web 1.61.0 → 2.0.0
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/browser/ui/alert-dialog.js +9 -4
- package/dist/browser/ui/atoms/Pagination/Pagination.js +9 -4
- package/dist/browser/ui/atoms/Pagination/index.js +9 -4
- package/dist/browser/ui/atoms/SearchInput/SearchInput.js +9 -4
- package/dist/browser/ui/atoms/SearchInput/index.js +9 -4
- package/dist/browser/ui/button.js +9 -4
- package/dist/browser/ui/calendar.js +12 -7
- package/dist/browser/ui/carousel.js +20 -15
- package/dist/browser/ui/confirm-dialog.js +9 -4
- package/dist/browser/ui/context-menu.js +178 -85
- package/dist/browser/ui/cta.js +13 -9
- package/dist/browser/ui/date-picker.js +17 -12
- package/dist/browser/ui/date-range-picker.js +14 -9
- package/dist/browser/ui/datetime-picker.js +21 -16
- package/dist/browser/ui/empty-state.js +32 -10
- package/dist/browser/ui/input-group.js +9 -4
- package/dist/browser/ui/input-otp.js +37 -18
- package/dist/browser/ui/link.js +6 -4
- package/dist/browser/ui/loading-button.js +41 -14
- package/dist/browser/ui/marketing/Hero.js +9 -4
- package/dist/browser/ui/marketing/PricingTable.js +9 -4
- package/dist/browser/ui/marketing/index.js +9 -4
- package/dist/browser/ui/molecules/Autocomplete/index.js +15 -10
- package/dist/browser/ui/molecules/SearchAndFilter/SearchAndFilter.js +9 -4
- package/dist/browser/ui/molecules/SearchAndFilter/index.js +9 -4
- package/dist/browser/ui/organisms/ErrorBoundary/ErrorBoundary.js +12 -7
- package/dist/browser/ui/organisms/ErrorBoundary/index.js +12 -7
- package/dist/browser/ui/organisms/ListPage/ListPage.js +41 -14
- package/dist/browser/ui/organisms/ListPage/index.js +41 -14
- package/dist/browser/ui/page-header.js +32 -10
- package/dist/browser/ui/pagination.js +98 -79
- package/dist/browser/ui/resizable.js +6 -9
- package/dist/browser/ui/section.js +12 -4
- package/dist/browser/ui/sidebar.js +22 -17
- package/dist/browser/ui/stack.js +32 -10
- package/dist/browser/ui/stat-card-group.js +32 -10
- package/dist/browser/ui/stepper.js +32 -10
- package/dist/browser/ui/time-picker.js +13 -8
- package/dist/browser/ui/toast.js +57 -29
- package/dist/browser/ui/toaster.js +60 -32
- package/dist/browser/ui/usecases/UseCaseCard.js +41 -14
- package/dist/browser/ui/usecases/UserStoryCard.js +32 -10
- package/dist/browser/ui/usecases/index.js +41 -14
- package/dist/browser/ui/visually-hidden.js +8 -4
- package/dist/index.d.ts +0 -1
- package/dist/ui/accordion.d.ts +0 -1
- package/dist/ui/alert-dialog.d.ts +0 -1
- package/dist/ui/alert-dialog.js +9 -4
- package/dist/ui/alert.d.ts +0 -1
- package/dist/ui/aspect-ratio.d.ts +0 -1
- package/dist/ui/atoms/FilterSelect/FilterSelect.d.ts +0 -1
- package/dist/ui/atoms/FilterSelect/index.d.ts +0 -1
- package/dist/ui/atoms/FilterSelect/types.d.ts +0 -1
- package/dist/ui/atoms/LoadingSpinner/LoadingSpinner.d.ts +0 -1
- package/dist/ui/atoms/LoadingSpinner/index.d.ts +0 -1
- package/dist/ui/atoms/Pagination/Pagination.d.ts +0 -1
- package/dist/ui/atoms/Pagination/Pagination.js +9 -4
- package/dist/ui/atoms/Pagination/index.d.ts +0 -1
- package/dist/ui/atoms/Pagination/index.js +9 -4
- package/dist/ui/atoms/Pagination/types.d.ts +0 -1
- package/dist/ui/atoms/SearchInput/SearchInput.d.ts +0 -1
- package/dist/ui/atoms/SearchInput/SearchInput.js +9 -4
- package/dist/ui/atoms/SearchInput/index.d.ts +0 -1
- package/dist/ui/atoms/SearchInput/index.js +9 -4
- package/dist/ui/atoms/SearchInput/types.d.ts +0 -1
- package/dist/ui/avatar.d.ts +0 -1
- package/dist/ui/badge.d.ts +0 -1
- package/dist/ui/breadcrumb.d.ts +0 -1
- package/dist/ui/button.d.ts +2 -7
- package/dist/ui/button.js +9 -4
- package/dist/ui/calendar.d.ts +0 -1
- package/dist/ui/calendar.js +12 -7
- package/dist/ui/card.d.ts +0 -1
- package/dist/ui/carousel.d.ts +0 -1
- package/dist/ui/carousel.js +20 -15
- package/dist/ui/checkbox.d.ts +0 -1
- package/dist/ui/collapsible.d.ts +0 -1
- package/dist/ui/command.d.ts +0 -1
- package/dist/ui/confirm-dialog.d.ts +0 -1
- package/dist/ui/confirm-dialog.js +9 -4
- package/dist/ui/context-menu.d.ts +26 -23
- package/dist/ui/context-menu.js +178 -85
- package/dist/ui/cta.d.ts +2 -9
- package/dist/ui/cta.js +13 -9
- package/dist/ui/date-picker.d.ts +0 -1
- package/dist/ui/date-picker.js +17 -12
- package/dist/ui/date-range-picker.d.ts +0 -1
- package/dist/ui/date-range-picker.js +14 -9
- package/dist/ui/datetime-picker.d.ts +0 -1
- package/dist/ui/datetime-picker.js +21 -16
- package/dist/ui/dialog.d.ts +0 -1
- package/dist/ui/drawer.d.ts +0 -1
- package/dist/ui/dropdown-menu.d.ts +0 -1
- package/dist/ui/empty-state.d.ts +0 -1
- package/dist/ui/empty-state.js +32 -10
- package/dist/ui/empty.d.ts +0 -1
- package/dist/ui/field.d.ts +0 -1
- package/dist/ui/focus-on-route-change.d.ts +0 -1
- package/dist/ui/form.d.ts +0 -1
- package/dist/ui/hover-card.d.ts +0 -1
- package/dist/ui/input-group.d.ts +0 -1
- package/dist/ui/input-group.js +9 -4
- package/dist/ui/input-otp.d.ts +13 -32
- package/dist/ui/input-otp.js +37 -18
- package/dist/ui/input.d.ts +0 -1
- package/dist/ui/label.d.ts +0 -1
- package/dist/ui/link.d.ts +4 -3
- package/dist/ui/link.js +6 -4
- package/dist/ui/live-region.d.ts +0 -1
- package/dist/ui/loading-button.d.ts +0 -1
- package/dist/ui/loading-button.js +41 -14
- package/dist/ui/map/MapBase.d.ts +0 -1
- package/dist/ui/map/MapGeoJsonOverlay.d.ts +0 -1
- package/dist/ui/map/MapHeatmapH3.d.ts +0 -1
- package/dist/ui/map/MapMarkers.d.ts +0 -1
- package/dist/ui/map/index.d.ts +0 -1
- package/dist/ui/marketing/FeatureGrid.d.ts +0 -1
- package/dist/ui/marketing/Hero.d.ts +0 -1
- package/dist/ui/marketing/Hero.js +9 -4
- package/dist/ui/marketing/PricingTable.d.ts +0 -1
- package/dist/ui/marketing/PricingTable.js +9 -4
- package/dist/ui/marketing/index.d.ts +0 -1
- package/dist/ui/marketing/index.js +9 -4
- package/dist/ui/menubar.d.ts +0 -1
- package/dist/ui/molecules/Autocomplete/index.d.ts +0 -1
- package/dist/ui/molecules/Autocomplete/index.js +15 -10
- package/dist/ui/molecules/SearchAndFilter/SearchAndFilter.d.ts +0 -1
- package/dist/ui/molecules/SearchAndFilter/SearchAndFilter.js +9 -4
- package/dist/ui/molecules/SearchAndFilter/index.d.ts +0 -1
- package/dist/ui/molecules/SearchAndFilter/index.js +9 -4
- package/dist/ui/molecules/SearchAndFilter/types.d.ts +0 -1
- package/dist/ui/molecules/SkeletonList.d.ts +0 -1
- package/dist/ui/nav-layout.d.ts +0 -1
- package/dist/ui/navigation-menu.d.ts +0 -1
- package/dist/ui/organisms/ErrorBoundary/ErrorBoundary.d.ts +0 -1
- package/dist/ui/organisms/ErrorBoundary/ErrorBoundary.js +12 -7
- package/dist/ui/organisms/ErrorBoundary/index.d.ts +0 -1
- package/dist/ui/organisms/ErrorBoundary/index.js +12 -7
- package/dist/ui/organisms/ListPage/ListPage.d.ts +0 -1
- package/dist/ui/organisms/ListPage/ListPage.js +41 -14
- package/dist/ui/organisms/ListPage/index.d.ts +0 -1
- package/dist/ui/organisms/ListPage/index.js +41 -14
- package/dist/ui/organisms/ListPage/types.d.ts +0 -1
- package/dist/ui/page-header.d.ts +0 -1
- package/dist/ui/page-header.js +32 -10
- package/dist/ui/pagination.d.ts +11 -23
- package/dist/ui/pagination.js +98 -79
- package/dist/ui/popover.d.ts +0 -1
- package/dist/ui/progress.d.ts +0 -1
- package/dist/ui/radio-group.d.ts +0 -1
- package/dist/ui/resizable.d.ts +5 -21
- package/dist/ui/resizable.js +6 -9
- package/dist/ui/route-announcer.d.ts +0 -1
- package/dist/ui/scroll-area.d.ts +0 -1
- package/dist/ui/section.d.ts +2 -10
- package/dist/ui/section.js +12 -4
- package/dist/ui/select.d.ts +0 -1
- package/dist/ui/separator.d.ts +0 -1
- package/dist/ui/sheet.d.ts +0 -1
- package/dist/ui/sidebar.d.ts +0 -1
- package/dist/ui/sidebar.js +22 -17
- package/dist/ui/skeleton.d.ts +0 -1
- package/dist/ui/skip-link.d.ts +0 -1
- package/dist/ui/slider.d.ts +0 -1
- package/dist/ui/sonner.d.ts +0 -1
- package/dist/ui/stack.d.ts +15 -24
- package/dist/ui/stack.js +32 -10
- package/dist/ui/stat-card-group.d.ts +0 -1
- package/dist/ui/stat-card-group.js +32 -10
- package/dist/ui/stepper.d.ts +0 -1
- package/dist/ui/stepper.js +32 -10
- package/dist/ui/switch.d.ts +0 -1
- package/dist/ui/table.d.ts +0 -1
- package/dist/ui/tabs.d.ts +0 -1
- package/dist/ui/text.d.ts +0 -1
- package/dist/ui/textarea.d.ts +0 -1
- package/dist/ui/time-picker.d.ts +0 -1
- package/dist/ui/time-picker.js +13 -8
- package/dist/ui/toast.d.ts +20 -8
- package/dist/ui/toast.js +57 -29
- package/dist/ui/toaster.d.ts +0 -1
- package/dist/ui/toaster.js +60 -32
- package/dist/ui/toggle-group.d.ts +0 -1
- package/dist/ui/toggle.d.ts +0 -1
- package/dist/ui/tooltip.d.ts +0 -1
- package/dist/ui/typography.d.ts +0 -1
- package/dist/ui/use-media-query.d.ts +0 -1
- package/dist/ui/use-mobile.d.ts +0 -1
- package/dist/ui/use-reduced-motion.d.ts +0 -1
- package/dist/ui/use-toast.d.ts +0 -1
- package/dist/ui/useListState.d.ts +0 -1
- package/dist/ui/usecases/UseCaseCard.d.ts +0 -1
- package/dist/ui/usecases/UseCaseCard.js +41 -14
- package/dist/ui/usecases/UserStoryCard.d.ts +0 -1
- package/dist/ui/usecases/UserStoryCard.js +32 -10
- package/dist/ui/usecases/index.d.ts +0 -1
- package/dist/ui/usecases/index.js +41 -14
- package/dist/ui/utils.d.ts +0 -1
- package/dist/ui/visually-hidden.d.ts +4 -3
- package/dist/ui/visually-hidden.js +8 -4
- package/package.json +13 -12
- package/dist/index.d.ts.map +0 -1
- package/dist/ui/accordion.d.ts.map +0 -1
- package/dist/ui/alert-dialog.d.ts.map +0 -1
- package/dist/ui/alert.d.ts.map +0 -1
- package/dist/ui/aspect-ratio.d.ts.map +0 -1
- package/dist/ui/atoms/FilterSelect/FilterSelect.d.ts.map +0 -1
- package/dist/ui/atoms/FilterSelect/index.d.ts.map +0 -1
- package/dist/ui/atoms/FilterSelect/types.d.ts.map +0 -1
- package/dist/ui/atoms/LoadingSpinner/LoadingSpinner.d.ts.map +0 -1
- package/dist/ui/atoms/LoadingSpinner/index.d.ts.map +0 -1
- package/dist/ui/atoms/Pagination/Pagination.d.ts.map +0 -1
- package/dist/ui/atoms/Pagination/index.d.ts.map +0 -1
- package/dist/ui/atoms/Pagination/types.d.ts.map +0 -1
- package/dist/ui/atoms/SearchInput/SearchInput.d.ts.map +0 -1
- package/dist/ui/atoms/SearchInput/index.d.ts.map +0 -1
- package/dist/ui/atoms/SearchInput/types.d.ts.map +0 -1
- package/dist/ui/avatar.d.ts.map +0 -1
- package/dist/ui/badge.d.ts.map +0 -1
- package/dist/ui/breadcrumb.d.ts.map +0 -1
- package/dist/ui/button.d.ts.map +0 -1
- package/dist/ui/calendar.d.ts.map +0 -1
- package/dist/ui/card.d.ts.map +0 -1
- package/dist/ui/carousel.d.ts.map +0 -1
- package/dist/ui/checkbox.d.ts.map +0 -1
- package/dist/ui/collapsible.d.ts.map +0 -1
- package/dist/ui/command.d.ts.map +0 -1
- package/dist/ui/confirm-dialog.d.ts.map +0 -1
- package/dist/ui/context-menu.d.ts.map +0 -1
- package/dist/ui/cta.d.ts.map +0 -1
- package/dist/ui/date-picker.d.ts.map +0 -1
- package/dist/ui/date-range-picker.d.ts.map +0 -1
- package/dist/ui/datetime-picker.d.ts.map +0 -1
- package/dist/ui/dialog.d.ts.map +0 -1
- package/dist/ui/drawer.d.ts.map +0 -1
- package/dist/ui/dropdown-menu.d.ts.map +0 -1
- package/dist/ui/empty-state.d.ts.map +0 -1
- package/dist/ui/empty.d.ts.map +0 -1
- package/dist/ui/field.d.ts.map +0 -1
- package/dist/ui/focus-on-route-change.d.ts.map +0 -1
- package/dist/ui/form.d.ts.map +0 -1
- package/dist/ui/hover-card.d.ts.map +0 -1
- package/dist/ui/input-group.d.ts.map +0 -1
- package/dist/ui/input-otp.d.ts.map +0 -1
- package/dist/ui/input.d.ts.map +0 -1
- package/dist/ui/label.d.ts.map +0 -1
- package/dist/ui/link.d.ts.map +0 -1
- package/dist/ui/live-region.d.ts.map +0 -1
- package/dist/ui/loading-button.d.ts.map +0 -1
- package/dist/ui/map/MapBase.d.ts.map +0 -1
- package/dist/ui/map/MapGeoJsonOverlay.d.ts.map +0 -1
- package/dist/ui/map/MapHeatmapH3.d.ts.map +0 -1
- package/dist/ui/map/MapMarkers.d.ts.map +0 -1
- package/dist/ui/map/index.d.ts.map +0 -1
- package/dist/ui/marketing/FeatureGrid.d.ts.map +0 -1
- package/dist/ui/marketing/Hero.d.ts.map +0 -1
- package/dist/ui/marketing/PricingTable.d.ts.map +0 -1
- package/dist/ui/marketing/index.d.ts.map +0 -1
- package/dist/ui/menubar.d.ts.map +0 -1
- package/dist/ui/molecules/Autocomplete/index.d.ts.map +0 -1
- package/dist/ui/molecules/SearchAndFilter/SearchAndFilter.d.ts.map +0 -1
- package/dist/ui/molecules/SearchAndFilter/index.d.ts.map +0 -1
- package/dist/ui/molecules/SearchAndFilter/types.d.ts.map +0 -1
- package/dist/ui/molecules/SkeletonList.d.ts.map +0 -1
- package/dist/ui/nav-layout.d.ts.map +0 -1
- package/dist/ui/navigation-menu.d.ts.map +0 -1
- package/dist/ui/organisms/ErrorBoundary/ErrorBoundary.d.ts.map +0 -1
- package/dist/ui/organisms/ErrorBoundary/index.d.ts.map +0 -1
- package/dist/ui/organisms/ListPage/ListPage.d.ts.map +0 -1
- package/dist/ui/organisms/ListPage/index.d.ts.map +0 -1
- package/dist/ui/organisms/ListPage/types.d.ts.map +0 -1
- package/dist/ui/page-header.d.ts.map +0 -1
- package/dist/ui/pagination.d.ts.map +0 -1
- package/dist/ui/popover.d.ts.map +0 -1
- package/dist/ui/progress.d.ts.map +0 -1
- package/dist/ui/radio-group.d.ts.map +0 -1
- package/dist/ui/resizable.d.ts.map +0 -1
- package/dist/ui/route-announcer.d.ts.map +0 -1
- package/dist/ui/scroll-area.d.ts.map +0 -1
- package/dist/ui/section.d.ts.map +0 -1
- package/dist/ui/select.d.ts.map +0 -1
- package/dist/ui/separator.d.ts.map +0 -1
- package/dist/ui/sheet.d.ts.map +0 -1
- package/dist/ui/sidebar.d.ts.map +0 -1
- package/dist/ui/skeleton.d.ts.map +0 -1
- package/dist/ui/skip-link.d.ts.map +0 -1
- package/dist/ui/slider.d.ts.map +0 -1
- package/dist/ui/sonner.d.ts.map +0 -1
- package/dist/ui/stack.d.ts.map +0 -1
- package/dist/ui/stat-card-group.d.ts.map +0 -1
- package/dist/ui/stepper.d.ts.map +0 -1
- package/dist/ui/switch.d.ts.map +0 -1
- package/dist/ui/table.d.ts.map +0 -1
- package/dist/ui/tabs.d.ts.map +0 -1
- package/dist/ui/text.d.ts.map +0 -1
- package/dist/ui/textarea.d.ts.map +0 -1
- package/dist/ui/time-picker.d.ts.map +0 -1
- package/dist/ui/toast.d.ts.map +0 -1
- package/dist/ui/toaster.d.ts.map +0 -1
- package/dist/ui/toggle-group.d.ts.map +0 -1
- package/dist/ui/toggle.d.ts.map +0 -1
- package/dist/ui/tooltip.d.ts.map +0 -1
- package/dist/ui/typography.d.ts.map +0 -1
- package/dist/ui/use-media-query.d.ts.map +0 -1
- package/dist/ui/use-mobile.d.ts.map +0 -1
- package/dist/ui/use-reduced-motion.d.ts.map +0 -1
- package/dist/ui/use-toast.d.ts.map +0 -1
- package/dist/ui/useListState.d.ts.map +0 -1
- package/dist/ui/usecases/UseCaseCard.d.ts.map +0 -1
- package/dist/ui/usecases/UserStoryCard.d.ts.map +0 -1
- package/dist/ui/usecases/index.d.ts.map +0 -1
- package/dist/ui/utils.d.ts.map +0 -1
- package/dist/ui/visually-hidden.d.ts.map +0 -1
package/dist/ui/context-menu.js
CHANGED
|
@@ -1,108 +1,201 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
var __require = import.meta.require;
|
|
3
3
|
|
|
4
|
+
// ui/utils.ts
|
|
5
|
+
import { clsx } from "clsx";
|
|
6
|
+
import { twMerge } from "tailwind-merge";
|
|
7
|
+
function cn(...inputs) {
|
|
8
|
+
return twMerge(clsx(inputs));
|
|
9
|
+
}
|
|
10
|
+
|
|
4
11
|
// ui/context-menu.tsx
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import { Check, ChevronRight, Circle } from "lucide-react";
|
|
8
|
-
import { cn } from "@contractspec/lib.ui-kit-core/utils";
|
|
12
|
+
import { ContextMenu as ContextMenuPrimitive } from "radix-ui";
|
|
13
|
+
import { CheckIcon, ChevronRightIcon } from "lucide-react";
|
|
9
14
|
import { jsxDEV } from "react/jsx-dev-runtime";
|
|
10
15
|
"use client";
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
16
|
+
function ContextMenu({
|
|
17
|
+
...props
|
|
18
|
+
}) {
|
|
19
|
+
return /* @__PURE__ */ jsxDEV(ContextMenuPrimitive.Root, {
|
|
20
|
+
"data-slot": "context-menu",
|
|
21
|
+
...props
|
|
22
|
+
}, undefined, false, undefined, this);
|
|
23
|
+
}
|
|
24
|
+
function ContextMenuTrigger({
|
|
25
|
+
className,
|
|
26
|
+
...props
|
|
27
|
+
}) {
|
|
28
|
+
return /* @__PURE__ */ jsxDEV(ContextMenuPrimitive.Trigger, {
|
|
29
|
+
"data-slot": "context-menu-trigger",
|
|
30
|
+
className: cn("select-none", className),
|
|
31
|
+
...props
|
|
32
|
+
}, undefined, false, undefined, this);
|
|
33
|
+
}
|
|
34
|
+
function ContextMenuGroup({
|
|
35
|
+
...props
|
|
36
|
+
}) {
|
|
37
|
+
return /* @__PURE__ */ jsxDEV(ContextMenuPrimitive.Group, {
|
|
38
|
+
"data-slot": "context-menu-group",
|
|
39
|
+
...props
|
|
40
|
+
}, undefined, false, undefined, this);
|
|
41
|
+
}
|
|
42
|
+
function ContextMenuPortal({
|
|
43
|
+
...props
|
|
44
|
+
}) {
|
|
45
|
+
return /* @__PURE__ */ jsxDEV(ContextMenuPrimitive.Portal, {
|
|
46
|
+
"data-slot": "context-menu-portal",
|
|
47
|
+
...props
|
|
48
|
+
}, undefined, false, undefined, this);
|
|
49
|
+
}
|
|
50
|
+
function ContextMenuSub({
|
|
51
|
+
...props
|
|
52
|
+
}) {
|
|
53
|
+
return /* @__PURE__ */ jsxDEV(ContextMenuPrimitive.Sub, {
|
|
54
|
+
"data-slot": "context-menu-sub",
|
|
55
|
+
...props
|
|
56
|
+
}, undefined, false, undefined, this);
|
|
57
|
+
}
|
|
58
|
+
function ContextMenuRadioGroup({
|
|
59
|
+
...props
|
|
60
|
+
}) {
|
|
61
|
+
return /* @__PURE__ */ jsxDEV(ContextMenuPrimitive.RadioGroup, {
|
|
62
|
+
"data-slot": "context-menu-radio-group",
|
|
63
|
+
...props
|
|
64
|
+
}, undefined, false, undefined, this);
|
|
65
|
+
}
|
|
66
|
+
function ContextMenuContent({
|
|
67
|
+
className,
|
|
68
|
+
...props
|
|
69
|
+
}) {
|
|
70
|
+
return /* @__PURE__ */ jsxDEV(ContextMenuPrimitive.Portal, {
|
|
71
|
+
children: /* @__PURE__ */ jsxDEV(ContextMenuPrimitive.Content, {
|
|
72
|
+
"data-slot": "context-menu-content",
|
|
73
|
+
className: cn("data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 data-closed:zoom-out-95 data-open:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 ring-foreground/10 bg-popover text-popover-foreground z-50 max-h-(--radix-context-menu-content-available-height) min-w-36 origin-(--radix-context-menu-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-lg p-1 shadow-md ring-1 duration-100", className),
|
|
74
|
+
...props
|
|
25
75
|
}, undefined, false, undefined, this)
|
|
26
|
-
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
76
|
+
}, undefined, false, undefined, this);
|
|
77
|
+
}
|
|
78
|
+
function ContextMenuItem({
|
|
79
|
+
className,
|
|
80
|
+
inset,
|
|
81
|
+
variant = "default",
|
|
32
82
|
...props
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
className: cn("bg-
|
|
83
|
+
}) {
|
|
84
|
+
return /* @__PURE__ */ jsxDEV(ContextMenuPrimitive.Item, {
|
|
85
|
+
"data-slot": "context-menu-item",
|
|
86
|
+
"data-inset": inset,
|
|
87
|
+
"data-variant": variant,
|
|
88
|
+
className: cn("focus:bg-accent focus:text-accent-foreground data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 dark:data-[variant=destructive]:focus:bg-destructive/20 data-[variant=destructive]:focus:text-destructive data-[variant=destructive]:*:[svg]:text-destructive focus:*:[svg]:text-accent-foreground group/context-menu-item relative flex cursor-default items-center gap-1.5 rounded-md px-1.5 py-1 text-sm outline-hidden select-none data-disabled:pointer-events-none data-disabled:opacity-50 data-inset:pl-7 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className),
|
|
39
89
|
...props
|
|
40
|
-
}, undefined, false, undefined, this)
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
90
|
+
}, undefined, false, undefined, this);
|
|
91
|
+
}
|
|
92
|
+
function ContextMenuSubTrigger({
|
|
93
|
+
className,
|
|
94
|
+
inset,
|
|
95
|
+
children,
|
|
46
96
|
...props
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
97
|
+
}) {
|
|
98
|
+
return /* @__PURE__ */ jsxDEV(ContextMenuPrimitive.SubTrigger, {
|
|
99
|
+
"data-slot": "context-menu-sub-trigger",
|
|
100
|
+
"data-inset": inset,
|
|
101
|
+
className: cn("focus:bg-accent focus:text-accent-foreground data-open:bg-accent data-open:text-accent-foreground flex cursor-default items-center gap-1.5 rounded-md px-1.5 py-1 text-sm outline-hidden select-none data-inset:pl-7 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className),
|
|
102
|
+
...props,
|
|
103
|
+
children: [
|
|
104
|
+
children,
|
|
105
|
+
/* @__PURE__ */ jsxDEV(ChevronRightIcon, {
|
|
106
|
+
className: "cn-rtl-flip ml-auto"
|
|
107
|
+
}, undefined, false, undefined, this)
|
|
108
|
+
]
|
|
109
|
+
}, undefined, true, undefined, this);
|
|
110
|
+
}
|
|
111
|
+
function ContextMenuSubContent({
|
|
112
|
+
className,
|
|
113
|
+
...props
|
|
114
|
+
}) {
|
|
115
|
+
return /* @__PURE__ */ jsxDEV(ContextMenuPrimitive.SubContent, {
|
|
116
|
+
"data-slot": "context-menu-sub-content",
|
|
117
|
+
className: cn("data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 data-closed:zoom-out-95 data-open:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 bg-popover text-popover-foreground z-50 min-w-32 origin-(--radix-context-menu-content-transform-origin) overflow-hidden rounded-lg border p-1 shadow-lg duration-100", className),
|
|
118
|
+
...props
|
|
119
|
+
}, undefined, false, undefined, this);
|
|
120
|
+
}
|
|
121
|
+
function ContextMenuCheckboxItem({
|
|
122
|
+
className,
|
|
123
|
+
children,
|
|
52
124
|
checked,
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
125
|
+
inset,
|
|
126
|
+
...props
|
|
127
|
+
}) {
|
|
128
|
+
return /* @__PURE__ */ jsxDEV(ContextMenuPrimitive.CheckboxItem, {
|
|
129
|
+
"data-slot": "context-menu-checkbox-item",
|
|
130
|
+
"data-inset": inset,
|
|
131
|
+
className: cn("focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-1.5 rounded-md py-1 pr-8 pl-1.5 text-sm outline-hidden select-none data-disabled:pointer-events-none data-disabled:opacity-50 data-inset:pl-7 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className),
|
|
132
|
+
checked,
|
|
133
|
+
...props,
|
|
134
|
+
children: [
|
|
135
|
+
/* @__PURE__ */ jsxDEV("span", {
|
|
136
|
+
className: "pointer-events-none absolute right-2",
|
|
137
|
+
children: /* @__PURE__ */ jsxDEV(ContextMenuPrimitive.ItemIndicator, {
|
|
138
|
+
children: /* @__PURE__ */ jsxDEV(CheckIcon, {}, undefined, false, undefined, this)
|
|
60
139
|
}, undefined, false, undefined, this)
|
|
61
|
-
}, undefined, false, undefined, this)
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
...props
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
140
|
+
}, undefined, false, undefined, this),
|
|
141
|
+
children
|
|
142
|
+
]
|
|
143
|
+
}, undefined, true, undefined, this);
|
|
144
|
+
}
|
|
145
|
+
function ContextMenuRadioItem({
|
|
146
|
+
className,
|
|
147
|
+
children,
|
|
148
|
+
inset,
|
|
149
|
+
...props
|
|
150
|
+
}) {
|
|
151
|
+
return /* @__PURE__ */ jsxDEV(ContextMenuPrimitive.RadioItem, {
|
|
152
|
+
"data-slot": "context-menu-radio-item",
|
|
153
|
+
"data-inset": inset,
|
|
154
|
+
className: cn("focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-1.5 rounded-md py-1 pr-8 pl-1.5 text-sm outline-hidden select-none data-disabled:pointer-events-none data-disabled:opacity-50 data-inset:pl-7 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className),
|
|
155
|
+
...props,
|
|
156
|
+
children: [
|
|
157
|
+
/* @__PURE__ */ jsxDEV("span", {
|
|
158
|
+
className: "pointer-events-none absolute right-2",
|
|
159
|
+
children: /* @__PURE__ */ jsxDEV(ContextMenuPrimitive.ItemIndicator, {
|
|
160
|
+
children: /* @__PURE__ */ jsxDEV(CheckIcon, {}, undefined, false, undefined, this)
|
|
77
161
|
}, undefined, false, undefined, this)
|
|
78
|
-
}, undefined, false, undefined, this)
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
className: cn("text-foreground px-2 py-1.5 text-base font-semibold", inset && "pl-8", className),
|
|
162
|
+
}, undefined, false, undefined, this),
|
|
163
|
+
children
|
|
164
|
+
]
|
|
165
|
+
}, undefined, true, undefined, this);
|
|
166
|
+
}
|
|
167
|
+
function ContextMenuLabel({
|
|
168
|
+
className,
|
|
169
|
+
inset,
|
|
87
170
|
...props
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
171
|
+
}) {
|
|
172
|
+
return /* @__PURE__ */ jsxDEV(ContextMenuPrimitive.Label, {
|
|
173
|
+
"data-slot": "context-menu-label",
|
|
174
|
+
"data-inset": inset,
|
|
175
|
+
className: cn("text-muted-foreground px-1.5 py-1 text-xs font-medium data-inset:pl-7", className),
|
|
176
|
+
...props
|
|
177
|
+
}, undefined, false, undefined, this);
|
|
178
|
+
}
|
|
179
|
+
function ContextMenuSeparator({
|
|
180
|
+
className,
|
|
93
181
|
...props
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
|
|
182
|
+
}) {
|
|
183
|
+
return /* @__PURE__ */ jsxDEV(ContextMenuPrimitive.Separator, {
|
|
184
|
+
"data-slot": "context-menu-separator",
|
|
185
|
+
className: cn("bg-border -mx-1 my-1 h-px", className),
|
|
186
|
+
...props
|
|
187
|
+
}, undefined, false, undefined, this);
|
|
188
|
+
}
|
|
189
|
+
function ContextMenuShortcut({
|
|
97
190
|
className,
|
|
98
191
|
...props
|
|
99
|
-
})
|
|
192
|
+
}) {
|
|
100
193
|
return /* @__PURE__ */ jsxDEV("span", {
|
|
101
|
-
|
|
194
|
+
"data-slot": "context-menu-shortcut",
|
|
195
|
+
className: cn("text-muted-foreground group-focus/context-menu-item:text-accent-foreground ml-auto text-xs tracking-widest", className),
|
|
102
196
|
...props
|
|
103
197
|
}, undefined, false, undefined, this);
|
|
104
|
-
}
|
|
105
|
-
ContextMenuShortcut.displayName = "ContextMenuShortcut";
|
|
198
|
+
}
|
|
106
199
|
export {
|
|
107
200
|
ContextMenuTrigger,
|
|
108
201
|
ContextMenuSubTrigger,
|
package/dist/ui/cta.d.ts
CHANGED
|
@@ -7,13 +7,6 @@ export type CtaProps = Omit<ButtonProps, 'onClick'> & {
|
|
|
7
7
|
href?: string;
|
|
8
8
|
onClick?: React.MouseEventHandler<HTMLButtonElement | HTMLAnchorElement>;
|
|
9
9
|
children?: React.ReactNode;
|
|
10
|
+
ref?: React.Ref<HTMLButtonElement | HTMLAnchorElement>;
|
|
10
11
|
};
|
|
11
|
-
export declare
|
|
12
|
-
capture?: (cta: string) => void;
|
|
13
|
-
ctaName?: string;
|
|
14
|
-
as?: "button" | "a";
|
|
15
|
-
href?: string;
|
|
16
|
-
onClick?: React.MouseEventHandler<HTMLButtonElement | HTMLAnchorElement>;
|
|
17
|
-
children?: React.ReactNode;
|
|
18
|
-
} & React.RefAttributes<HTMLButtonElement | HTMLAnchorElement>>;
|
|
19
|
-
//# sourceMappingURL=cta.d.ts.map
|
|
12
|
+
export declare function Cta({ capture, ctaName, className, as, href, onClick, size, children, ref, ...props }: CtaProps): import("react/jsx-runtime").JSX.Element;
|
package/dist/ui/cta.js
CHANGED
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
var __require = import.meta.require;
|
|
3
3
|
|
|
4
4
|
// ui/button.tsx
|
|
5
|
-
import * as React from "react";
|
|
6
5
|
import { Slot } from "@radix-ui/react-slot";
|
|
7
6
|
import { cva } from "class-variance-authority";
|
|
8
7
|
import { cn } from "@contractspec/lib.ui-kit-core/utils";
|
|
@@ -29,7 +28,14 @@ var buttonVariants = cva("inline-flex items-center justify-center gap-2 whitespa
|
|
|
29
28
|
size: "default"
|
|
30
29
|
}
|
|
31
30
|
});
|
|
32
|
-
|
|
31
|
+
function Button({
|
|
32
|
+
className,
|
|
33
|
+
variant,
|
|
34
|
+
size,
|
|
35
|
+
asChild = false,
|
|
36
|
+
ref,
|
|
37
|
+
...props
|
|
38
|
+
}) {
|
|
33
39
|
if (asChild) {
|
|
34
40
|
return /* @__PURE__ */ jsxDEV(Slot, {
|
|
35
41
|
"data-slot": "button",
|
|
@@ -43,13 +49,11 @@ var Button = React.forwardRef(({ className, variant, size, asChild = false, ...p
|
|
|
43
49
|
className: cn(buttonVariants({ variant, size, className })),
|
|
44
50
|
...props
|
|
45
51
|
}, undefined, false, undefined, this);
|
|
46
|
-
}
|
|
47
|
-
Button.displayName = "Button";
|
|
52
|
+
}
|
|
48
53
|
// ui/cta.tsx
|
|
49
|
-
import * as React2 from "react";
|
|
50
54
|
import { cn as cn2 } from "@contractspec/lib.ui-kit-core/utils";
|
|
51
55
|
import { jsxDEV as jsxDEV2 } from "react/jsx-dev-runtime";
|
|
52
|
-
|
|
56
|
+
function Cta({
|
|
53
57
|
capture,
|
|
54
58
|
ctaName,
|
|
55
59
|
className,
|
|
@@ -58,8 +62,9 @@ var Cta = React2.forwardRef(({
|
|
|
58
62
|
onClick,
|
|
59
63
|
size = "lg",
|
|
60
64
|
children,
|
|
65
|
+
ref,
|
|
61
66
|
...props
|
|
62
|
-
}
|
|
67
|
+
}) {
|
|
63
68
|
const handleClick = (e) => {
|
|
64
69
|
if (ctaName && capture) {
|
|
65
70
|
try {
|
|
@@ -90,8 +95,7 @@ var Cta = React2.forwardRef(({
|
|
|
90
95
|
...props,
|
|
91
96
|
children
|
|
92
97
|
}, undefined, false, undefined, this);
|
|
93
|
-
}
|
|
94
|
-
Cta.displayName = "Cta";
|
|
98
|
+
}
|
|
95
99
|
export {
|
|
96
100
|
Cta
|
|
97
101
|
};
|
package/dist/ui/date-picker.d.ts
CHANGED
|
@@ -9,4 +9,3 @@ export interface DatePickerProps {
|
|
|
9
9
|
language?: string;
|
|
10
10
|
}
|
|
11
11
|
export declare function DatePicker({ value, onChange, disabled, minDate, maxDate, placeholder, className, language, }: DatePickerProps): import("react/jsx-runtime").JSX.Element;
|
|
12
|
-
//# sourceMappingURL=date-picker.d.ts.map
|
package/dist/ui/date-picker.js
CHANGED
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
var __require = import.meta.require;
|
|
3
3
|
|
|
4
4
|
// ui/button.tsx
|
|
5
|
-
import * as React from "react";
|
|
6
5
|
import { Slot } from "@radix-ui/react-slot";
|
|
7
6
|
import { cva } from "class-variance-authority";
|
|
8
7
|
import { cn } from "@contractspec/lib.ui-kit-core/utils";
|
|
@@ -29,7 +28,14 @@ var buttonVariants = cva("inline-flex items-center justify-center gap-2 whitespa
|
|
|
29
28
|
size: "default"
|
|
30
29
|
}
|
|
31
30
|
});
|
|
32
|
-
|
|
31
|
+
function Button({
|
|
32
|
+
className,
|
|
33
|
+
variant,
|
|
34
|
+
size,
|
|
35
|
+
asChild = false,
|
|
36
|
+
ref,
|
|
37
|
+
...props
|
|
38
|
+
}) {
|
|
33
39
|
if (asChild) {
|
|
34
40
|
return /* @__PURE__ */ jsxDEV(Slot, {
|
|
35
41
|
"data-slot": "button",
|
|
@@ -43,8 +49,7 @@ var Button = React.forwardRef(({ className, variant, size, asChild = false, ...p
|
|
|
43
49
|
className: cn(buttonVariants({ variant, size, className })),
|
|
44
50
|
...props
|
|
45
51
|
}, undefined, false, undefined, this);
|
|
46
|
-
}
|
|
47
|
-
Button.displayName = "Button";
|
|
52
|
+
}
|
|
48
53
|
// ui/input.tsx
|
|
49
54
|
import { cn as cn2 } from "@contractspec/lib.ui-kit-core/utils";
|
|
50
55
|
import { jsxDEV as jsxDEV2 } from "react/jsx-dev-runtime";
|
|
@@ -57,7 +62,7 @@ function Input({ className, type, ...props }) {
|
|
|
57
62
|
}, undefined, false, undefined, this);
|
|
58
63
|
}
|
|
59
64
|
// ui/calendar.tsx
|
|
60
|
-
import * as
|
|
65
|
+
import * as React from "react";
|
|
61
66
|
import {
|
|
62
67
|
ChevronDownIcon,
|
|
63
68
|
ChevronLeftIcon,
|
|
@@ -163,8 +168,8 @@ function CalendarDayButton({
|
|
|
163
168
|
...props
|
|
164
169
|
}) {
|
|
165
170
|
const defaultClassNames = getDefaultClassNames();
|
|
166
|
-
const ref =
|
|
167
|
-
|
|
171
|
+
const ref = React.useRef(null);
|
|
172
|
+
React.useEffect(() => {
|
|
168
173
|
if (modifiers.focused)
|
|
169
174
|
ref.current?.focus();
|
|
170
175
|
}, [modifiers.focused]);
|
|
@@ -227,7 +232,7 @@ function PopoverAnchor({
|
|
|
227
232
|
}, undefined, false, undefined, this);
|
|
228
233
|
}
|
|
229
234
|
// ui/date-picker.tsx
|
|
230
|
-
import * as
|
|
235
|
+
import * as React2 from "react";
|
|
231
236
|
import { CalendarIcon } from "lucide-react";
|
|
232
237
|
import { cn as cn5 } from "@contractspec/lib.ui-kit-core/utils";
|
|
233
238
|
import { jsxDEV as jsxDEV5 } from "react/jsx-dev-runtime";
|
|
@@ -242,10 +247,10 @@ function DatePicker({
|
|
|
242
247
|
className,
|
|
243
248
|
language
|
|
244
249
|
}) {
|
|
245
|
-
const [open, setOpen] =
|
|
246
|
-
const [month, setMonth] =
|
|
247
|
-
const [textValue, setTextValue] =
|
|
248
|
-
|
|
250
|
+
const [open, setOpen] = React2.useState(false);
|
|
251
|
+
const [month, setMonth] = React2.useState(value ?? new Date);
|
|
252
|
+
const [textValue, setTextValue] = React2.useState(formatDate(value));
|
|
253
|
+
React2.useEffect(() => {
|
|
249
254
|
setTextValue(formatDate(value));
|
|
250
255
|
if (value)
|
|
251
256
|
setMonth(value);
|
|
@@ -11,4 +11,3 @@ export interface DateRangePickerProps {
|
|
|
11
11
|
className?: string;
|
|
12
12
|
}
|
|
13
13
|
export declare function DateRangePicker({ value, onChange, disabled, minDate, maxDate, className, }: DateRangePickerProps): import("react/jsx-runtime").JSX.Element;
|
|
14
|
-
//# sourceMappingURL=date-range-picker.d.ts.map
|
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
var __require = import.meta.require;
|
|
3
3
|
|
|
4
4
|
// ui/button.tsx
|
|
5
|
-
import * as React from "react";
|
|
6
5
|
import { Slot } from "@radix-ui/react-slot";
|
|
7
6
|
import { cva } from "class-variance-authority";
|
|
8
7
|
import { cn } from "@contractspec/lib.ui-kit-core/utils";
|
|
@@ -29,7 +28,14 @@ var buttonVariants = cva("inline-flex items-center justify-center gap-2 whitespa
|
|
|
29
28
|
size: "default"
|
|
30
29
|
}
|
|
31
30
|
});
|
|
32
|
-
|
|
31
|
+
function Button({
|
|
32
|
+
className,
|
|
33
|
+
variant,
|
|
34
|
+
size,
|
|
35
|
+
asChild = false,
|
|
36
|
+
ref,
|
|
37
|
+
...props
|
|
38
|
+
}) {
|
|
33
39
|
if (asChild) {
|
|
34
40
|
return /* @__PURE__ */ jsxDEV(Slot, {
|
|
35
41
|
"data-slot": "button",
|
|
@@ -43,10 +49,9 @@ var Button = React.forwardRef(({ className, variant, size, asChild = false, ...p
|
|
|
43
49
|
className: cn(buttonVariants({ variant, size, className })),
|
|
44
50
|
...props
|
|
45
51
|
}, undefined, false, undefined, this);
|
|
46
|
-
}
|
|
47
|
-
Button.displayName = "Button";
|
|
52
|
+
}
|
|
48
53
|
// ui/calendar.tsx
|
|
49
|
-
import * as
|
|
54
|
+
import * as React from "react";
|
|
50
55
|
import {
|
|
51
56
|
ChevronDownIcon,
|
|
52
57
|
ChevronLeftIcon,
|
|
@@ -152,8 +157,8 @@ function CalendarDayButton({
|
|
|
152
157
|
...props
|
|
153
158
|
}) {
|
|
154
159
|
const defaultClassNames = getDefaultClassNames();
|
|
155
|
-
const ref =
|
|
156
|
-
|
|
160
|
+
const ref = React.useRef(null);
|
|
161
|
+
React.useEffect(() => {
|
|
157
162
|
if (modifiers.focused)
|
|
158
163
|
ref.current?.focus();
|
|
159
164
|
}, [modifiers.focused]);
|
|
@@ -216,7 +221,7 @@ function PopoverAnchor({
|
|
|
216
221
|
}, undefined, false, undefined, this);
|
|
217
222
|
}
|
|
218
223
|
// ui/date-range-picker.tsx
|
|
219
|
-
import * as
|
|
224
|
+
import * as React2 from "react";
|
|
220
225
|
import { cn as cn4 } from "@contractspec/lib.ui-kit-core/utils";
|
|
221
226
|
import { jsxDEV as jsxDEV4 } from "react/jsx-dev-runtime";
|
|
222
227
|
"use client";
|
|
@@ -228,7 +233,7 @@ function DateRangePicker({
|
|
|
228
233
|
maxDate,
|
|
229
234
|
className
|
|
230
235
|
}) {
|
|
231
|
-
const [open, setOpen] =
|
|
236
|
+
const [open, setOpen] = React2.useState(false);
|
|
232
237
|
return /* @__PURE__ */ jsxDEV4(Popover, {
|
|
233
238
|
open,
|
|
234
239
|
onOpenChange: setOpen,
|
|
@@ -10,4 +10,3 @@ export interface DateTimePickerProps {
|
|
|
10
10
|
className?: string;
|
|
11
11
|
}
|
|
12
12
|
export declare function DateTimePicker({ value, onChange, disabled, minDate, maxDate, datePlaceholder, timePlaceholder, is24Hour, className, }: DateTimePickerProps): import("react/jsx-runtime").JSX.Element;
|
|
13
|
-
//# sourceMappingURL=datetime-picker.d.ts.map
|
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
var __require = import.meta.require;
|
|
3
3
|
|
|
4
4
|
// ui/button.tsx
|
|
5
|
-
import * as React from "react";
|
|
6
5
|
import { Slot } from "@radix-ui/react-slot";
|
|
7
6
|
import { cva } from "class-variance-authority";
|
|
8
7
|
import { cn } from "@contractspec/lib.ui-kit-core/utils";
|
|
@@ -29,7 +28,14 @@ var buttonVariants = cva("inline-flex items-center justify-center gap-2 whitespa
|
|
|
29
28
|
size: "default"
|
|
30
29
|
}
|
|
31
30
|
});
|
|
32
|
-
|
|
31
|
+
function Button({
|
|
32
|
+
className,
|
|
33
|
+
variant,
|
|
34
|
+
size,
|
|
35
|
+
asChild = false,
|
|
36
|
+
ref,
|
|
37
|
+
...props
|
|
38
|
+
}) {
|
|
33
39
|
if (asChild) {
|
|
34
40
|
return /* @__PURE__ */ jsxDEV(Slot, {
|
|
35
41
|
"data-slot": "button",
|
|
@@ -43,8 +49,7 @@ var Button = React.forwardRef(({ className, variant, size, asChild = false, ...p
|
|
|
43
49
|
className: cn(buttonVariants({ variant, size, className })),
|
|
44
50
|
...props
|
|
45
51
|
}, undefined, false, undefined, this);
|
|
46
|
-
}
|
|
47
|
-
Button.displayName = "Button";
|
|
52
|
+
}
|
|
48
53
|
// ui/input.tsx
|
|
49
54
|
import { cn as cn2 } from "@contractspec/lib.ui-kit-core/utils";
|
|
50
55
|
import { jsxDEV as jsxDEV2 } from "react/jsx-dev-runtime";
|
|
@@ -57,7 +62,7 @@ function Input({ className, type, ...props }) {
|
|
|
57
62
|
}, undefined, false, undefined, this);
|
|
58
63
|
}
|
|
59
64
|
// ui/calendar.tsx
|
|
60
|
-
import * as
|
|
65
|
+
import * as React from "react";
|
|
61
66
|
import {
|
|
62
67
|
ChevronDownIcon,
|
|
63
68
|
ChevronLeftIcon,
|
|
@@ -163,8 +168,8 @@ function CalendarDayButton({
|
|
|
163
168
|
...props
|
|
164
169
|
}) {
|
|
165
170
|
const defaultClassNames = getDefaultClassNames();
|
|
166
|
-
const ref =
|
|
167
|
-
|
|
171
|
+
const ref = React.useRef(null);
|
|
172
|
+
React.useEffect(() => {
|
|
168
173
|
if (modifiers.focused)
|
|
169
174
|
ref.current?.focus();
|
|
170
175
|
}, [modifiers.focused]);
|
|
@@ -227,7 +232,7 @@ function PopoverAnchor({
|
|
|
227
232
|
}, undefined, false, undefined, this);
|
|
228
233
|
}
|
|
229
234
|
// ui/date-picker.tsx
|
|
230
|
-
import * as
|
|
235
|
+
import * as React2 from "react";
|
|
231
236
|
import { CalendarIcon } from "lucide-react";
|
|
232
237
|
import { cn as cn5 } from "@contractspec/lib.ui-kit-core/utils";
|
|
233
238
|
import { jsxDEV as jsxDEV5 } from "react/jsx-dev-runtime";
|
|
@@ -242,10 +247,10 @@ function DatePicker({
|
|
|
242
247
|
className,
|
|
243
248
|
language
|
|
244
249
|
}) {
|
|
245
|
-
const [open, setOpen] =
|
|
246
|
-
const [month, setMonth] =
|
|
247
|
-
const [textValue, setTextValue] =
|
|
248
|
-
|
|
250
|
+
const [open, setOpen] = React2.useState(false);
|
|
251
|
+
const [month, setMonth] = React2.useState(value ?? new Date);
|
|
252
|
+
const [textValue, setTextValue] = React2.useState(formatDate(value));
|
|
253
|
+
React2.useEffect(() => {
|
|
249
254
|
setTextValue(formatDate(value));
|
|
250
255
|
if (value)
|
|
251
256
|
setMonth(value);
|
|
@@ -342,7 +347,7 @@ function DatePicker({
|
|
|
342
347
|
}
|
|
343
348
|
|
|
344
349
|
// ui/time-picker.tsx
|
|
345
|
-
import * as
|
|
350
|
+
import * as React3 from "react";
|
|
346
351
|
import { cn as cn6 } from "@contractspec/lib.ui-kit-core/utils";
|
|
347
352
|
import { jsxDEV as jsxDEV6 } from "react/jsx-dev-runtime";
|
|
348
353
|
"use client";
|
|
@@ -363,9 +368,9 @@ function TimePicker({
|
|
|
363
368
|
is24Hour = true,
|
|
364
369
|
className
|
|
365
370
|
}) {
|
|
366
|
-
const [open, setOpen] =
|
|
367
|
-
const [hours, setHours] =
|
|
368
|
-
const [minutes, setMinutes] =
|
|
371
|
+
const [open, setOpen] = React3.useState(false);
|
|
372
|
+
const [hours, setHours] = React3.useState(() => value ? String(value.getHours()).padStart(2, "0") : "");
|
|
373
|
+
const [minutes, setMinutes] = React3.useState(() => value ? String(value.getMinutes()).padStart(2, "0") : "");
|
|
369
374
|
const commit = (h, m) => {
|
|
370
375
|
const base = value ?? new Date;
|
|
371
376
|
const next = new Date(base);
|
package/dist/ui/dialog.d.ts
CHANGED
|
@@ -13,4 +13,3 @@ declare function DialogFooter({ className, ...props }: React.ComponentPropsWitho
|
|
|
13
13
|
declare function DialogTitle({ className, ...props }: React.ComponentProps<typeof DialogPrimitive.Title>): import("react/jsx-runtime").JSX.Element;
|
|
14
14
|
declare function DialogDescription({ className, ...props }: React.ComponentProps<typeof DialogPrimitive.Description>): import("react/jsx-runtime").JSX.Element;
|
|
15
15
|
export { Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, };
|
|
16
|
-
//# sourceMappingURL=dialog.d.ts.map
|
package/dist/ui/drawer.d.ts
CHANGED
|
@@ -11,4 +11,3 @@ declare function DrawerFooter({ className, ...props }: React.ComponentPropsWitho
|
|
|
11
11
|
declare function DrawerTitle({ className, ...props }: React.ComponentProps<typeof DrawerPrimitive.Title>): import("react/jsx-runtime").JSX.Element;
|
|
12
12
|
declare function DrawerDescription({ className, ...props }: React.ComponentProps<typeof DrawerPrimitive.Description>): import("react/jsx-runtime").JSX.Element;
|
|
13
13
|
export { Drawer, DrawerPortal, DrawerOverlay, DrawerTrigger, DrawerClose, DrawerContent, DrawerHeader, DrawerFooter, DrawerTitle, DrawerDescription, };
|
|
14
|
-
//# sourceMappingURL=drawer.d.ts.map
|
|
@@ -23,4 +23,3 @@ declare function DropdownMenuSubTrigger({ className, inset, children, ...props }
|
|
|
23
23
|
}): import("react/jsx-runtime").JSX.Element;
|
|
24
24
|
declare function DropdownMenuSubContent({ className, ...props }: React.ComponentProps<typeof DropdownMenuPrimitive.SubContent>): import("react/jsx-runtime").JSX.Element;
|
|
25
25
|
export { DropdownMenu, DropdownMenuPortal, DropdownMenuTrigger, DropdownMenuContent, DropdownMenuGroup, DropdownMenuLabel, DropdownMenuItem, DropdownMenuCheckboxItem, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubTrigger, DropdownMenuSubContent, };
|
|
26
|
-
//# sourceMappingURL=dropdown-menu.d.ts.map
|
package/dist/ui/empty-state.d.ts
CHANGED
|
@@ -13,4 +13,3 @@ export interface EmptyStateProps extends VariantProps<typeof containerVariants>
|
|
|
13
13
|
}
|
|
14
14
|
export declare function EmptyState({ icon, title, description, primaryAction, secondaryAction, className, density, }: EmptyStateProps): import("react/jsx-runtime").JSX.Element;
|
|
15
15
|
export {};
|
|
16
|
-
//# sourceMappingURL=empty-state.d.ts.map
|