@giddaa-housing/ui 0.1.0 → 1.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/README.md +18 -6
- package/css/base.css +37 -0
- package/css/components.css +135 -0
- package/css/generated/shared.css +1 -0
- package/css/giddaa.css +402 -0
- package/css/preset.css +77 -0
- package/css/styles.css +2 -0
- package/css/theme.css +255 -0
- package/dist/accordion.js +5 -35
- package/dist/accordion.js.map +1 -1
- package/dist/activity-timeline.d.ts +33 -0
- package/dist/activity-timeline.js +212 -0
- package/dist/activity-timeline.js.map +1 -0
- package/dist/alert.js +5 -35
- package/dist/alert.js.map +1 -1
- package/dist/auth-layout.d.ts +23 -0
- package/dist/auth-layout.js +304 -0
- package/dist/auth-layout.js.map +1 -0
- package/dist/avatar.js +10 -142
- package/dist/avatar.js.map +1 -1
- package/dist/badge.d.ts +3 -2
- package/dist/badge.js +6 -114
- package/dist/badge.js.map +1 -1
- package/dist/bar-chart.d.ts +101 -77
- package/dist/bar-chart.js +142 -220
- package/dist/bar-chart.js.map +1 -1
- package/dist/breadcrumb.js +5 -35
- package/dist/breadcrumb.js.map +1 -1
- package/dist/bullet-chart.js +15 -48
- package/dist/bullet-chart.js.map +1 -1
- package/dist/button-group.js +14 -90
- package/dist/button-group.js.map +1 -1
- package/dist/button.d.ts +5 -5
- package/dist/button.js +7 -140
- package/dist/button.js.map +1 -1
- package/dist/calendar.js +12 -287
- package/dist/calendar.js.map +1 -1
- package/dist/card.js +5 -35
- package/dist/card.js.map +1 -1
- package/dist/carousel.js +12 -386
- package/dist/carousel.js.map +1 -1
- package/dist/chart.js +16 -480
- package/dist/chart.js.map +1 -1
- package/dist/checkbox.d.ts +1 -1
- package/dist/checkbox.js +13 -48
- package/dist/checkbox.js.map +1 -1
- package/dist/chunk-322YCNVL.js +278 -0
- package/dist/chunk-322YCNVL.js.map +1 -0
- package/dist/chunk-3ACQVT7A.js +25 -0
- package/dist/chunk-3ACQVT7A.js.map +1 -0
- package/dist/chunk-3T65TLJX.js +334 -0
- package/dist/chunk-3T65TLJX.js.map +1 -0
- package/dist/chunk-6ZSGQHH2.js +192 -0
- package/dist/chunk-6ZSGQHH2.js.map +1 -0
- package/dist/chunk-7TBMLFGW.js +41 -0
- package/dist/chunk-7TBMLFGW.js.map +1 -0
- package/dist/chunk-B4H6RNDH.js +135 -0
- package/dist/chunk-B4H6RNDH.js.map +1 -0
- package/dist/chunk-BUXCGZ6X.js +219 -0
- package/dist/chunk-BUXCGZ6X.js.map +1 -0
- package/dist/chunk-CHII2QHH.js +58 -0
- package/dist/chunk-CHII2QHH.js.map +1 -0
- package/dist/chunk-DMNOXRRW.js +147 -0
- package/dist/chunk-DMNOXRRW.js.map +1 -0
- package/dist/chunk-EFSOSSIC.js +130 -0
- package/dist/chunk-EFSOSSIC.js.map +1 -0
- package/dist/chunk-FZDSVMKY.js +363 -0
- package/dist/chunk-FZDSVMKY.js.map +1 -0
- package/dist/chunk-GJOFIJS3.js +246 -0
- package/dist/chunk-GJOFIJS3.js.map +1 -0
- package/dist/chunk-HL3ZSYES.js +23 -0
- package/dist/chunk-HL3ZSYES.js.map +1 -0
- package/dist/chunk-JVLUBAPB.js +129 -0
- package/dist/chunk-JVLUBAPB.js.map +1 -0
- package/dist/chunk-KDPYSOYZ.js +64 -0
- package/dist/chunk-KDPYSOYZ.js.map +1 -0
- package/dist/chunk-KSMDANKI.js +43 -0
- package/dist/chunk-KSMDANKI.js.map +1 -0
- package/dist/chunk-MEKCCOP5.js +46 -0
- package/dist/chunk-MEKCCOP5.js.map +1 -0
- package/dist/chunk-NOFXVRWL.js +451 -0
- package/dist/chunk-NOFXVRWL.js.map +1 -0
- package/dist/chunk-PC5MHNVA.js +171 -0
- package/dist/chunk-PC5MHNVA.js.map +1 -0
- package/dist/chunk-QKAQZ2GU.js +122 -0
- package/dist/chunk-QKAQZ2GU.js.map +1 -0
- package/dist/chunk-QZHSHSVV.js +26 -0
- package/dist/chunk-QZHSHSVV.js.map +1 -0
- package/dist/chunk-RBMK26XD.js +19 -0
- package/dist/chunk-RBMK26XD.js.map +1 -0
- package/dist/chunk-SFNJGF6M.js +262 -0
- package/dist/chunk-SFNJGF6M.js.map +1 -0
- package/dist/chunk-UJJNLGTM.js +112 -0
- package/dist/chunk-UJJNLGTM.js.map +1 -0
- package/dist/chunk-VGR4ZWJ3.js +418 -0
- package/dist/chunk-VGR4ZWJ3.js.map +1 -0
- package/dist/chunk-XG47P6D4.js +99 -0
- package/dist/chunk-XG47P6D4.js.map +1 -0
- package/dist/chunk-XZZAHNVM.js +21 -0
- package/dist/chunk-XZZAHNVM.js.map +1 -0
- package/dist/chunk-Y4TTYVNE.js +36 -0
- package/dist/chunk-Y4TTYVNE.js.map +1 -0
- package/dist/chunk-YDWIHW6Q.js +69 -0
- package/dist/chunk-YDWIHW6Q.js.map +1 -0
- package/dist/collapsible.js +6 -35
- package/dist/collapsible.js.map +1 -1
- package/dist/combobox.js +26 -694
- package/dist/combobox.js.map +1 -1
- package/dist/cta.d.ts +66 -0
- package/dist/cta.js +358 -0
- package/dist/cta.js.map +1 -0
- package/dist/currency-selector.d.ts +42 -0
- package/dist/currency-selector.js +192 -0
- package/dist/currency-selector.js.map +1 -0
- package/dist/date-picker.d.ts +18 -10
- package/dist/date-picker.js +105 -430
- package/dist/date-picker.js.map +1 -1
- package/dist/details-card.d.ts +19 -0
- package/dist/details-card.js +267 -0
- package/dist/details-card.js.map +1 -0
- package/dist/dialog.js +36 -146
- package/dist/dialog.js.map +1 -1
- package/dist/dropdown-menu.d.ts +1 -1
- package/dist/dropdown-menu.js +20 -358
- package/dist/dropdown-menu.js.map +1 -1
- package/dist/dropzone.js +13 -40
- package/dist/dropzone.js.map +1 -1
- package/dist/editorial-card.d.ts +29 -0
- package/dist/editorial-card.js +311 -0
- package/dist/editorial-card.js.map +1 -0
- package/dist/empty-state.js +5 -35
- package/dist/empty-state.js.map +1 -1
- package/dist/field.js +30 -135
- package/dist/field.js.map +1 -1
- package/dist/footer.d.ts +47 -0
- package/dist/footer.js +430 -0
- package/dist/footer.js.map +1 -0
- package/dist/funnel-chart.js +42 -415
- package/dist/funnel-chart.js.map +1 -1
- package/dist/gallery-indicator.d.ts +18 -0
- package/dist/gallery-indicator.js +12 -0
- package/dist/gallery-indicator.js.map +1 -0
- package/dist/heatmap-chart.d.ts +98 -0
- package/dist/heatmap-chart.js +248 -0
- package/dist/heatmap-chart.js.map +1 -0
- package/dist/infotip.d.ts +11 -0
- package/dist/infotip.js +66 -0
- package/dist/infotip.js.map +1 -0
- package/dist/input-group.d.ts +2 -1
- package/dist/input-group.js +15 -371
- package/dist/input-group.js.map +1 -1
- package/dist/input-size-context.js +5 -19
- package/dist/input-size-context.js.map +1 -1
- package/dist/input.js +6 -78
- package/dist/input.js.map +1 -1
- package/dist/item.js +5 -35
- package/dist/item.js.map +1 -1
- package/dist/kpi-card.js +12 -52
- package/dist/kpi-card.js.map +1 -1
- package/dist/label.js +5 -64
- package/dist/label.js.map +1 -1
- package/dist/line-chart.js +9 -166
- package/dist/line-chart.js.map +1 -1
- package/dist/logo.js +4 -141
- package/dist/logo.js.map +1 -1
- package/dist/map-indicator.d.ts +13 -0
- package/dist/map-indicator.js +109 -0
- package/dist/map-indicator.js.map +1 -0
- package/dist/match.d.ts +16 -0
- package/dist/match.js +113 -0
- package/dist/match.js.map +1 -0
- package/dist/media-gallery-hero.d.ts +60 -0
- package/dist/media-gallery-hero.js +362 -0
- package/dist/media-gallery-hero.js.map +1 -0
- package/dist/media-player.d.ts +60 -0
- package/dist/media-player.js +1394 -0
- package/dist/media-player.js.map +1 -0
- package/dist/number-input.js +30 -325
- package/dist/number-input.js.map +1 -1
- package/dist/page-header.js +4 -32
- package/dist/page-header.js.map +1 -1
- package/dist/pagination.d.ts +1 -0
- package/dist/pagination.js +27 -161
- package/dist/pagination.js.map +1 -1
- package/dist/password-input.d.ts +1 -0
- package/dist/password-input.js +21 -319
- package/dist/password-input.js.map +1 -1
- package/dist/phone-input.d.ts +2 -1
- package/dist/phone-input.js +148 -359
- package/dist/phone-input.js.map +1 -1
- package/dist/photo-gallery.d.ts +1 -1
- package/dist/photo-gallery.js +97 -393
- package/dist/photo-gallery.js.map +1 -1
- package/dist/pie-chart.js +17 -52
- package/dist/pie-chart.js.map +1 -1
- package/dist/popover.js +13 -158
- package/dist/popover.js.map +1 -1
- package/dist/price-tag.d.ts +35 -0
- package/dist/price-tag.js +178 -0
- package/dist/price-tag.js.map +1 -0
- package/dist/progress.d.ts +5 -2
- package/dist/progress.js +14 -303
- package/dist/progress.js.map +1 -1
- package/dist/property-listing-card.d.ts +32 -0
- package/dist/property-listing-card.js +235 -0
- package/dist/property-listing-card.js.map +1 -0
- package/dist/radar-chart.d.ts +110 -0
- package/dist/radar-chart.js +147 -0
- package/dist/radar-chart.js.map +1 -0
- package/dist/radio-group.js +15 -50
- package/dist/radio-group.js.map +1 -1
- package/dist/review-block.d.ts +20 -0
- package/dist/review-block.js +10 -0
- package/dist/review-block.js.map +1 -0
- package/dist/rich-text-editor.js +172 -433
- package/dist/rich-text-editor.js.map +1 -1
- package/dist/scatter-chart.d.ts +142 -0
- package/dist/scatter-chart.js +252 -0
- package/dist/scatter-chart.js.map +1 -0
- package/dist/search-input.d.ts +1 -0
- package/dist/search-input.js +22 -320
- package/dist/search-input.js.map +1 -1
- package/dist/select.js +15 -292
- package/dist/select.js.map +1 -1
- package/dist/separator.js +5 -68
- package/dist/separator.js.map +1 -1
- package/dist/sheet.js +14 -271
- package/dist/sheet.js.map +1 -1
- package/dist/sidebar.d.ts +1 -1
- package/dist/sidebar.js +89 -494
- package/dist/sidebar.js.map +1 -1
- package/dist/size-context.js +5 -17
- package/dist/size-context.js.map +1 -1
- package/dist/skeleton.js +4 -44
- package/dist/skeleton.js.map +1 -1
- package/dist/slider.d.ts +28 -0
- package/dist/slider.js +152 -0
- package/dist/slider.js.map +1 -0
- package/dist/sparkline.js +33 -341
- package/dist/sparkline.js.map +1 -1
- package/dist/stepper.js +5 -35
- package/dist/stepper.js.map +1 -1
- package/dist/styles.css +9593 -2
- package/dist/switch.js +13 -48
- package/dist/switch.js.map +1 -1
- package/dist/tab-list.js +35 -306
- package/dist/tab-list.js.map +1 -1
- package/dist/table.js +5 -32
- package/dist/table.js.map +1 -1
- package/dist/tabs.js +10 -150
- package/dist/tabs.js.map +1 -1
- package/dist/tag.d.ts +7 -6
- package/dist/tag.js +101 -97
- package/dist/tag.js.map +1 -1
- package/dist/testimonial-block.d.ts +34 -0
- package/dist/testimonial-block.js +377 -0
- package/dist/testimonial-block.js.map +1 -0
- package/dist/textarea.js +6 -73
- package/dist/textarea.js.map +1 -1
- package/dist/time-picker.js +119 -279
- package/dist/time-picker.js.map +1 -1
- package/dist/toast.js +27 -132
- package/dist/toast.js.map +1 -1
- package/dist/tooltip.d.ts +5 -5
- package/dist/tooltip.js +7 -90
- package/dist/tooltip.js.map +1 -1
- package/dist/tree-map.js +41 -414
- package/dist/tree-map.js.map +1 -1
- package/dist/waterfall-chart.d.ts +129 -0
- package/dist/waterfall-chart.js +577 -0
- package/dist/waterfall-chart.js.map +1 -0
- package/package.json +98 -28
- package/dist/base.css +0 -32
- package/dist/files/red-hat-display-latin-300-italic.woff +0 -0
- package/dist/files/red-hat-display-latin-300-italic.woff2 +0 -0
- package/dist/files/red-hat-display-latin-300-normal.woff +0 -0
- package/dist/files/red-hat-display-latin-300-normal.woff2 +0 -0
- package/dist/files/red-hat-display-latin-400-italic.woff +0 -0
- package/dist/files/red-hat-display-latin-400-italic.woff2 +0 -0
- package/dist/files/red-hat-display-latin-400-normal.woff +0 -0
- package/dist/files/red-hat-display-latin-400-normal.woff2 +0 -0
- package/dist/files/red-hat-display-latin-500-italic.woff +0 -0
- package/dist/files/red-hat-display-latin-500-italic.woff2 +0 -0
- package/dist/files/red-hat-display-latin-500-normal.woff +0 -0
- package/dist/files/red-hat-display-latin-500-normal.woff2 +0 -0
- package/dist/files/red-hat-display-latin-600-italic.woff +0 -0
- package/dist/files/red-hat-display-latin-600-italic.woff2 +0 -0
- package/dist/files/red-hat-display-latin-600-normal.woff +0 -0
- package/dist/files/red-hat-display-latin-600-normal.woff2 +0 -0
- package/dist/files/red-hat-display-latin-700-italic.woff +0 -0
- package/dist/files/red-hat-display-latin-700-italic.woff2 +0 -0
- package/dist/files/red-hat-display-latin-700-normal.woff +0 -0
- package/dist/files/red-hat-display-latin-700-normal.woff2 +0 -0
- package/dist/files/red-hat-display-latin-800-italic.woff +0 -0
- package/dist/files/red-hat-display-latin-800-italic.woff2 +0 -0
- package/dist/files/red-hat-display-latin-800-normal.woff +0 -0
- package/dist/files/red-hat-display-latin-800-normal.woff2 +0 -0
- package/dist/files/red-hat-display-latin-900-italic.woff +0 -0
- package/dist/files/red-hat-display-latin-900-italic.woff2 +0 -0
- package/dist/files/red-hat-display-latin-900-normal.woff +0 -0
- package/dist/files/red-hat-display-latin-900-normal.woff2 +0 -0
- package/dist/files/red-hat-display-latin-ext-300-italic.woff +0 -0
- package/dist/files/red-hat-display-latin-ext-300-italic.woff2 +0 -0
- package/dist/files/red-hat-display-latin-ext-300-normal.woff +0 -0
- package/dist/files/red-hat-display-latin-ext-300-normal.woff2 +0 -0
- package/dist/files/red-hat-display-latin-ext-400-italic.woff +0 -0
- package/dist/files/red-hat-display-latin-ext-400-italic.woff2 +0 -0
- package/dist/files/red-hat-display-latin-ext-400-normal.woff +0 -0
- package/dist/files/red-hat-display-latin-ext-400-normal.woff2 +0 -0
- package/dist/files/red-hat-display-latin-ext-500-italic.woff +0 -0
- package/dist/files/red-hat-display-latin-ext-500-italic.woff2 +0 -0
- package/dist/files/red-hat-display-latin-ext-500-normal.woff +0 -0
- package/dist/files/red-hat-display-latin-ext-500-normal.woff2 +0 -0
- package/dist/files/red-hat-display-latin-ext-600-italic.woff +0 -0
- package/dist/files/red-hat-display-latin-ext-600-italic.woff2 +0 -0
- package/dist/files/red-hat-display-latin-ext-600-normal.woff +0 -0
- package/dist/files/red-hat-display-latin-ext-600-normal.woff2 +0 -0
- package/dist/files/red-hat-display-latin-ext-700-italic.woff +0 -0
- package/dist/files/red-hat-display-latin-ext-700-italic.woff2 +0 -0
- package/dist/files/red-hat-display-latin-ext-700-normal.woff +0 -0
- package/dist/files/red-hat-display-latin-ext-700-normal.woff2 +0 -0
- package/dist/files/red-hat-display-latin-ext-800-italic.woff +0 -0
- package/dist/files/red-hat-display-latin-ext-800-italic.woff2 +0 -0
- package/dist/files/red-hat-display-latin-ext-800-normal.woff +0 -0
- package/dist/files/red-hat-display-latin-ext-800-normal.woff2 +0 -0
- package/dist/files/red-hat-display-latin-ext-900-italic.woff +0 -0
- package/dist/files/red-hat-display-latin-ext-900-italic.woff2 +0 -0
- package/dist/files/red-hat-display-latin-ext-900-normal.woff +0 -0
- package/dist/files/red-hat-display-latin-ext-900-normal.woff2 +0 -0
- package/dist/index.d.ts +0 -87
- package/dist/index.js +0 -10448
- package/dist/index.js.map +0 -1
- package/dist/red-hat-display.css +0 -2
- package/dist/theme/giddaa.css +0 -2
|
@@ -0,0 +1,418 @@
|
|
|
1
|
+
import {
|
|
2
|
+
InputGroup,
|
|
3
|
+
InputGroupAddon,
|
|
4
|
+
InputGroupButton,
|
|
5
|
+
InputGroupInput
|
|
6
|
+
} from "./chunk-6ZSGQHH2.js";
|
|
7
|
+
import {
|
|
8
|
+
Button
|
|
9
|
+
} from "./chunk-B4H6RNDH.js";
|
|
10
|
+
import {
|
|
11
|
+
SizeProvider,
|
|
12
|
+
useComponentSize
|
|
13
|
+
} from "./chunk-HL3ZSYES.js";
|
|
14
|
+
import {
|
|
15
|
+
cn
|
|
16
|
+
} from "./chunk-Y4TTYVNE.js";
|
|
17
|
+
|
|
18
|
+
// src/combobox.tsx
|
|
19
|
+
import { Combobox as ComboboxPrimitive } from "@base-ui/react";
|
|
20
|
+
import { cva } from "class-variance-authority";
|
|
21
|
+
import { CheckIcon, ChevronDownIcon, XIcon } from "lucide-react";
|
|
22
|
+
import * as React from "react";
|
|
23
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
24
|
+
var ComboboxSelectionContext = React.createContext({ multiple: false });
|
|
25
|
+
function Combobox({
|
|
26
|
+
multiple,
|
|
27
|
+
children,
|
|
28
|
+
size,
|
|
29
|
+
...props
|
|
30
|
+
}) {
|
|
31
|
+
return /* @__PURE__ */ jsx(SizeProvider, { size, children: /* @__PURE__ */ jsx(
|
|
32
|
+
ComboboxSelectionContext.Provider,
|
|
33
|
+
{
|
|
34
|
+
value: { multiple: multiple === true },
|
|
35
|
+
children: /* @__PURE__ */ jsx(ComboboxPrimitive.Root, { multiple, ...props, children })
|
|
36
|
+
}
|
|
37
|
+
) });
|
|
38
|
+
}
|
|
39
|
+
var comboboxTriggerVariants = cva(
|
|
40
|
+
"group/combobox-trigger flex w-fit min-w-0 items-center justify-between rounded-full border border-line bg-canvas text-left font-normal whitespace-nowrap text-fg-primary shadow-none outline-none transition-[background-color,border-color,border-radius,box-shadow,color] select-none hover:border-line-strong focus-visible:border-line-focus focus-visible:inset-ring-1 focus-visible:inset-ring-line-focus data-focused:border-line-focus data-focused:inset-ring-1 data-focused:inset-ring-line-focus data-popup-open:rounded-2xl data-popup-open:border-line-focus data-popup-open:inset-ring-1 data-popup-open:inset-ring-line-focus disabled:pointer-events-none disabled:cursor-not-allowed disabled:border-line-subtle disabled:bg-surface disabled:text-fg-caption-placeholder data-disabled:pointer-events-none data-disabled:cursor-not-allowed data-disabled:border-line-subtle data-disabled:bg-surface data-disabled:text-fg-caption-placeholder data-placeholder:text-fg-caption-placeholder aria-invalid:border-line-danger aria-invalid:text-fg-danger aria-invalid:shadow-none data-[invalid=true]:border-line-danger data-[invalid=true]:text-fg-danger *:data-[slot=combobox-value]:line-clamp-1 *:data-[slot=combobox-value]:flex *:data-[slot=combobox-value]:min-w-0 *:data-[slot=combobox-value]:items-center *:data-[slot=combobox-value]:gap-2 [&_svg]:pointer-events-none [&_svg]:shrink-0",
|
|
41
|
+
{
|
|
42
|
+
variants: {
|
|
43
|
+
size: {
|
|
44
|
+
sm: "h-8 gap-2 px-3 text-gdt-xs [&_svg:not([class*='size-'])]:size-3.5",
|
|
45
|
+
md: "h-10 gap-2 px-3.5 text-gdt-sm [&_svg:not([class*='size-'])]:size-4",
|
|
46
|
+
lg: "h-12 gap-2.5 px-4 pr-5 text-gdt-md [&_svg:not([class*='size-'])]:size-4.5"
|
|
47
|
+
}
|
|
48
|
+
},
|
|
49
|
+
defaultVariants: {
|
|
50
|
+
size: "md"
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
);
|
|
54
|
+
var comboboxInputVariants = cva(
|
|
55
|
+
"w-auto has-data-popup-open:rounded-2xl has-data-popup-open:border-line-focus has-data-popup-open:inset-ring-1 has-data-popup-open:inset-ring-line-focus",
|
|
56
|
+
{
|
|
57
|
+
variants: {
|
|
58
|
+
size: {
|
|
59
|
+
sm: "",
|
|
60
|
+
md: "",
|
|
61
|
+
lg: ""
|
|
62
|
+
}
|
|
63
|
+
},
|
|
64
|
+
defaultVariants: {
|
|
65
|
+
size: "md"
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
);
|
|
69
|
+
var comboboxContentVariants = cva(
|
|
70
|
+
"relative isolate z-50 max-h-(--available-height) w-(--anchor-width) max-w-(--available-width) min-w-[calc(var(--anchor-width))] origin-(--transform-origin) overflow-hidden border border-line-subtle bg-canvas text-fg-primary shadow-(--elevation-e1-shadow) duration-100 data-[chips=true]:min-w-(--anchor-width) data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-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 *:data-[slot=input-group]:mb-1 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",
|
|
71
|
+
{
|
|
72
|
+
variants: {
|
|
73
|
+
size: {
|
|
74
|
+
sm: "rounded-lg p-1",
|
|
75
|
+
md: "rounded-xl p-1.5",
|
|
76
|
+
lg: "rounded-[18px] p-2"
|
|
77
|
+
}
|
|
78
|
+
},
|
|
79
|
+
defaultVariants: {
|
|
80
|
+
size: "md"
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
);
|
|
84
|
+
var comboboxItemVariants = cva(
|
|
85
|
+
"group/combobox-item relative flex w-full cursor-pointer items-center font-normal text-fg-primary outline-none select-none data-highlighted:bg-surface data-disabled:pointer-events-none data-disabled:text-fg-caption-placeholder [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
86
|
+
{
|
|
87
|
+
variants: {
|
|
88
|
+
size: {
|
|
89
|
+
sm: "gap-1.5 rounded-md px-3 py-1.5 text-gdt-xs",
|
|
90
|
+
md: "gap-2 rounded-md px-4 py-2 text-gdt-sm",
|
|
91
|
+
lg: "gap-2.5 rounded-md px-4 py-2.5 text-gdt-md"
|
|
92
|
+
}
|
|
93
|
+
},
|
|
94
|
+
defaultVariants: {
|
|
95
|
+
size: "md"
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
);
|
|
99
|
+
var comboboxChipsVariants = cva(
|
|
100
|
+
"flex flex-wrap items-center gap-1 rounded-full border border-line bg-canvas bg-clip-padding text-fg-primary transition-[background-color,border-color,box-shadow,color] focus-within:border-line-focus focus-within:inset-ring-1 focus-within:inset-ring-line-focus has-aria-invalid:border-line-danger has-aria-invalid:text-fg-danger has-aria-invalid:shadow-none has-data-[slot=combobox-chip]:px-1 has-data-popup-open:rounded-2xl has-data-popup-open:border-line-focus has-data-popup-open:inset-ring-1 has-data-popup-open:inset-ring-line-focus",
|
|
101
|
+
{
|
|
102
|
+
variants: {
|
|
103
|
+
size: {
|
|
104
|
+
sm: "min-h-8 px-2.5 py-1 text-gdt-xs",
|
|
105
|
+
md: "min-h-10 px-3 py-1.5 text-gdt-sm",
|
|
106
|
+
lg: "min-h-12 px-4 py-2 text-gdt-md"
|
|
107
|
+
}
|
|
108
|
+
},
|
|
109
|
+
defaultVariants: {
|
|
110
|
+
size: "md"
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
);
|
|
114
|
+
var comboboxChipVariants = cva(
|
|
115
|
+
"flex w-fit items-center justify-center gap-1 rounded-sm bg-surface font-medium whitespace-nowrap text-fg-primary has-disabled:pointer-events-none has-disabled:cursor-not-allowed has-disabled:opacity-50 has-data-[slot=combobox-chip-remove]:pr-0",
|
|
116
|
+
{
|
|
117
|
+
variants: {
|
|
118
|
+
size: {
|
|
119
|
+
sm: "h-5 px-1.5 text-gdt-xs",
|
|
120
|
+
md: "h-[calc(--spacing(5.25))] px-1.5 text-gdt-xs",
|
|
121
|
+
lg: "h-6 px-2 text-gdt-sm"
|
|
122
|
+
}
|
|
123
|
+
},
|
|
124
|
+
defaultVariants: {
|
|
125
|
+
size: "md"
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
);
|
|
129
|
+
function ComboboxValue({ ...props }) {
|
|
130
|
+
return /* @__PURE__ */ jsx(ComboboxPrimitive.Value, { "data-slot": "combobox-value", ...props });
|
|
131
|
+
}
|
|
132
|
+
function ComboboxTrigger({
|
|
133
|
+
className,
|
|
134
|
+
children,
|
|
135
|
+
...props
|
|
136
|
+
}) {
|
|
137
|
+
const resolvedSize = useComponentSize();
|
|
138
|
+
return /* @__PURE__ */ jsxs(
|
|
139
|
+
ComboboxPrimitive.Trigger,
|
|
140
|
+
{
|
|
141
|
+
"data-slot": "combobox-trigger",
|
|
142
|
+
"data-size": resolvedSize,
|
|
143
|
+
className: cn(comboboxTriggerVariants({ size: resolvedSize }), className),
|
|
144
|
+
...props,
|
|
145
|
+
children: [
|
|
146
|
+
children,
|
|
147
|
+
/* @__PURE__ */ jsx(
|
|
148
|
+
ComboboxPrimitive.Icon,
|
|
149
|
+
{
|
|
150
|
+
render: /* @__PURE__ */ jsx(ChevronDownIcon, { className: "text-line-strong transition-transform group-data-disabled/combobox-trigger:text-fg-caption-placeholder group-data-popup-open/combobox-trigger:rotate-180" })
|
|
151
|
+
}
|
|
152
|
+
)
|
|
153
|
+
]
|
|
154
|
+
}
|
|
155
|
+
);
|
|
156
|
+
}
|
|
157
|
+
function ComboboxClear({ className, ...props }) {
|
|
158
|
+
return /* @__PURE__ */ jsx(
|
|
159
|
+
ComboboxPrimitive.Clear,
|
|
160
|
+
{
|
|
161
|
+
"data-slot": "combobox-clear",
|
|
162
|
+
className: cn(className),
|
|
163
|
+
...props,
|
|
164
|
+
render: /* @__PURE__ */ jsx(InputGroupButton, { variant: "ghost", size: "icon-xs", children: /* @__PURE__ */ jsx(XIcon, { className: "pointer-events-none" }) })
|
|
165
|
+
}
|
|
166
|
+
);
|
|
167
|
+
}
|
|
168
|
+
function ComboboxInput({
|
|
169
|
+
className,
|
|
170
|
+
children,
|
|
171
|
+
disabled = false,
|
|
172
|
+
showTrigger = true,
|
|
173
|
+
showClear = false,
|
|
174
|
+
...props
|
|
175
|
+
}) {
|
|
176
|
+
const resolvedSize = useComponentSize();
|
|
177
|
+
return /* @__PURE__ */ jsxs(
|
|
178
|
+
InputGroup,
|
|
179
|
+
{
|
|
180
|
+
className: cn(comboboxInputVariants({ size: resolvedSize }), className),
|
|
181
|
+
children: [
|
|
182
|
+
/* @__PURE__ */ jsx(
|
|
183
|
+
ComboboxPrimitive.Input,
|
|
184
|
+
{
|
|
185
|
+
render: /* @__PURE__ */ jsx(InputGroupInput, { disabled }),
|
|
186
|
+
...props
|
|
187
|
+
}
|
|
188
|
+
),
|
|
189
|
+
/* @__PURE__ */ jsxs(InputGroupAddon, { align: "inline-end", children: [
|
|
190
|
+
showTrigger && /* @__PURE__ */ jsx(
|
|
191
|
+
InputGroupButton,
|
|
192
|
+
{
|
|
193
|
+
size: "icon-xs",
|
|
194
|
+
variant: "ghost",
|
|
195
|
+
render: /* @__PURE__ */ jsx(ComboboxTrigger, {}),
|
|
196
|
+
"data-slot": "input-group-button",
|
|
197
|
+
className: "h-6 border-0 bg-transparent p-0 shadow-none inset-ring-0 group-has-data-[slot=combobox-clear]/input-group:hidden hover:border-transparent focus-visible:border-transparent focus-visible:inset-ring-0 data-popup-open:border-transparent data-popup-open:bg-transparent data-popup-open:inset-ring-0 data-pressed:bg-transparent",
|
|
198
|
+
disabled
|
|
199
|
+
}
|
|
200
|
+
),
|
|
201
|
+
showClear && /* @__PURE__ */ jsx(ComboboxClear, { disabled })
|
|
202
|
+
] }),
|
|
203
|
+
children
|
|
204
|
+
]
|
|
205
|
+
}
|
|
206
|
+
);
|
|
207
|
+
}
|
|
208
|
+
function ComboboxContent({
|
|
209
|
+
className,
|
|
210
|
+
side = "bottom",
|
|
211
|
+
sideOffset = 6,
|
|
212
|
+
align = "start",
|
|
213
|
+
alignOffset = 0,
|
|
214
|
+
anchor,
|
|
215
|
+
...props
|
|
216
|
+
}) {
|
|
217
|
+
const resolvedSize = useComponentSize();
|
|
218
|
+
return /* @__PURE__ */ jsx(ComboboxPrimitive.Portal, { children: /* @__PURE__ */ jsx(
|
|
219
|
+
ComboboxPrimitive.Positioner,
|
|
220
|
+
{
|
|
221
|
+
side,
|
|
222
|
+
sideOffset,
|
|
223
|
+
align,
|
|
224
|
+
alignOffset,
|
|
225
|
+
anchor,
|
|
226
|
+
className: "isolate z-50",
|
|
227
|
+
children: /* @__PURE__ */ jsx(
|
|
228
|
+
ComboboxPrimitive.Popup,
|
|
229
|
+
{
|
|
230
|
+
"data-slot": "combobox-content",
|
|
231
|
+
"data-chips": !!anchor,
|
|
232
|
+
className: cn(
|
|
233
|
+
"group/combobox-content",
|
|
234
|
+
comboboxContentVariants({ size: resolvedSize }),
|
|
235
|
+
className
|
|
236
|
+
),
|
|
237
|
+
...props
|
|
238
|
+
}
|
|
239
|
+
)
|
|
240
|
+
}
|
|
241
|
+
) });
|
|
242
|
+
}
|
|
243
|
+
function ComboboxList({ className, ...props }) {
|
|
244
|
+
return /* @__PURE__ */ jsx(
|
|
245
|
+
ComboboxPrimitive.List,
|
|
246
|
+
{
|
|
247
|
+
"data-slot": "combobox-list",
|
|
248
|
+
className: cn(
|
|
249
|
+
"no-scrollbar max-h-(--available-height) space-y-0.5 scroll-py-1 overflow-y-auto overscroll-contain data-empty:p-0",
|
|
250
|
+
className
|
|
251
|
+
),
|
|
252
|
+
...props
|
|
253
|
+
}
|
|
254
|
+
);
|
|
255
|
+
}
|
|
256
|
+
function ComboboxItem({
|
|
257
|
+
className,
|
|
258
|
+
children,
|
|
259
|
+
...props
|
|
260
|
+
}) {
|
|
261
|
+
const { multiple } = React.useContext(ComboboxSelectionContext);
|
|
262
|
+
const resolvedSize = useComponentSize();
|
|
263
|
+
return /* @__PURE__ */ jsxs(
|
|
264
|
+
ComboboxPrimitive.Item,
|
|
265
|
+
{
|
|
266
|
+
"data-slot": "combobox-item",
|
|
267
|
+
className: cn(
|
|
268
|
+
comboboxItemVariants({ size: resolvedSize }),
|
|
269
|
+
!multiple && "data-selected:bg-surface-brand-subtle data-selected:font-medium data-selected:text-fg-brand",
|
|
270
|
+
className
|
|
271
|
+
),
|
|
272
|
+
...props,
|
|
273
|
+
children: [
|
|
274
|
+
multiple ? /* @__PURE__ */ jsx(
|
|
275
|
+
ComboboxPrimitive.ItemIndicator,
|
|
276
|
+
{
|
|
277
|
+
keepMounted: true,
|
|
278
|
+
className: "flex size-5 shrink-0 items-center justify-center rounded-sm border border-line bg-canvas text-transparent transition-[background-color,border-color,color] group-data-selected/combobox-item:border-action-primary group-data-selected/combobox-item:bg-action-primary group-data-selected/combobox-item:text-fg-on-brand group-data-disabled/combobox-item:border-line-subtle group-data-disabled/combobox-item:bg-surface group-data-disabled/combobox-item:text-fg-caption-placeholder [&>svg]:size-3",
|
|
279
|
+
children: /* @__PURE__ */ jsx(CheckIcon, {})
|
|
280
|
+
}
|
|
281
|
+
) : null,
|
|
282
|
+
/* @__PURE__ */ jsx("span", { className: "flex min-w-0 flex-1 shrink-0 gap-2 whitespace-nowrap", children })
|
|
283
|
+
]
|
|
284
|
+
}
|
|
285
|
+
);
|
|
286
|
+
}
|
|
287
|
+
function ComboboxGroup({ className, ...props }) {
|
|
288
|
+
return /* @__PURE__ */ jsx(
|
|
289
|
+
ComboboxPrimitive.Group,
|
|
290
|
+
{
|
|
291
|
+
"data-slot": "combobox-group",
|
|
292
|
+
className: cn("scroll-my-1 space-y-0.5", className),
|
|
293
|
+
...props
|
|
294
|
+
}
|
|
295
|
+
);
|
|
296
|
+
}
|
|
297
|
+
function ComboboxLabel({
|
|
298
|
+
className,
|
|
299
|
+
...props
|
|
300
|
+
}) {
|
|
301
|
+
return /* @__PURE__ */ jsx(
|
|
302
|
+
ComboboxPrimitive.GroupLabel,
|
|
303
|
+
{
|
|
304
|
+
"data-slot": "combobox-label",
|
|
305
|
+
className: cn("px-3 py-1 text-gdt-xs text-fg-secondary", className),
|
|
306
|
+
...props
|
|
307
|
+
}
|
|
308
|
+
);
|
|
309
|
+
}
|
|
310
|
+
function ComboboxCollection({ ...props }) {
|
|
311
|
+
return /* @__PURE__ */ jsx(ComboboxPrimitive.Collection, { "data-slot": "combobox-collection", ...props });
|
|
312
|
+
}
|
|
313
|
+
function ComboboxEmpty({ className, ...props }) {
|
|
314
|
+
return /* @__PURE__ */ jsx(
|
|
315
|
+
ComboboxPrimitive.Empty,
|
|
316
|
+
{
|
|
317
|
+
"data-slot": "combobox-empty",
|
|
318
|
+
className: cn(
|
|
319
|
+
"hidden w-full justify-center py-2 text-center text-gdt-sm text-fg-secondary group-data-empty/combobox-content:flex",
|
|
320
|
+
className
|
|
321
|
+
),
|
|
322
|
+
...props
|
|
323
|
+
}
|
|
324
|
+
);
|
|
325
|
+
}
|
|
326
|
+
function ComboboxSeparator({
|
|
327
|
+
className,
|
|
328
|
+
...props
|
|
329
|
+
}) {
|
|
330
|
+
return /* @__PURE__ */ jsx(
|
|
331
|
+
ComboboxPrimitive.Separator,
|
|
332
|
+
{
|
|
333
|
+
"data-slot": "combobox-separator",
|
|
334
|
+
className: cn("pointer-events-none my-1 h-px bg-line-subtle", className),
|
|
335
|
+
...props
|
|
336
|
+
}
|
|
337
|
+
);
|
|
338
|
+
}
|
|
339
|
+
function ComboboxChips({
|
|
340
|
+
className,
|
|
341
|
+
...props
|
|
342
|
+
}) {
|
|
343
|
+
const resolvedSize = useComponentSize();
|
|
344
|
+
return /* @__PURE__ */ jsx(
|
|
345
|
+
ComboboxPrimitive.Chips,
|
|
346
|
+
{
|
|
347
|
+
"data-slot": "combobox-chips",
|
|
348
|
+
className: cn(comboboxChipsVariants({ size: resolvedSize }), className),
|
|
349
|
+
...props
|
|
350
|
+
}
|
|
351
|
+
);
|
|
352
|
+
}
|
|
353
|
+
function ComboboxChip({
|
|
354
|
+
className,
|
|
355
|
+
children,
|
|
356
|
+
showRemove = true,
|
|
357
|
+
...props
|
|
358
|
+
}) {
|
|
359
|
+
const resolvedSize = useComponentSize();
|
|
360
|
+
return /* @__PURE__ */ jsxs(
|
|
361
|
+
ComboboxPrimitive.Chip,
|
|
362
|
+
{
|
|
363
|
+
"data-slot": "combobox-chip",
|
|
364
|
+
className: cn(comboboxChipVariants({ size: resolvedSize }), className),
|
|
365
|
+
...props,
|
|
366
|
+
children: [
|
|
367
|
+
children,
|
|
368
|
+
showRemove && /* @__PURE__ */ jsx(
|
|
369
|
+
ComboboxPrimitive.ChipRemove,
|
|
370
|
+
{
|
|
371
|
+
className: "-ml-1 opacity-50 hover:opacity-100",
|
|
372
|
+
"data-slot": "combobox-chip-remove",
|
|
373
|
+
render: /* @__PURE__ */ jsx(Button, { variant: "ghost", size: "icon-xs", children: /* @__PURE__ */ jsx(XIcon, { className: "pointer-events-none" }) })
|
|
374
|
+
}
|
|
375
|
+
)
|
|
376
|
+
]
|
|
377
|
+
}
|
|
378
|
+
);
|
|
379
|
+
}
|
|
380
|
+
function ComboboxChipsInput({
|
|
381
|
+
className,
|
|
382
|
+
...props
|
|
383
|
+
}) {
|
|
384
|
+
return /* @__PURE__ */ jsx(
|
|
385
|
+
ComboboxPrimitive.Input,
|
|
386
|
+
{
|
|
387
|
+
"data-slot": "combobox-chip-input",
|
|
388
|
+
className: cn(
|
|
389
|
+
"min-w-16 flex-1 bg-transparent text-fg-primary outline-none placeholder:text-fg-caption-placeholder",
|
|
390
|
+
className
|
|
391
|
+
),
|
|
392
|
+
...props
|
|
393
|
+
}
|
|
394
|
+
);
|
|
395
|
+
}
|
|
396
|
+
function useComboboxAnchor() {
|
|
397
|
+
return React.useRef(null);
|
|
398
|
+
}
|
|
399
|
+
|
|
400
|
+
export {
|
|
401
|
+
Combobox,
|
|
402
|
+
ComboboxValue,
|
|
403
|
+
ComboboxTrigger,
|
|
404
|
+
ComboboxInput,
|
|
405
|
+
ComboboxContent,
|
|
406
|
+
ComboboxList,
|
|
407
|
+
ComboboxItem,
|
|
408
|
+
ComboboxGroup,
|
|
409
|
+
ComboboxLabel,
|
|
410
|
+
ComboboxCollection,
|
|
411
|
+
ComboboxEmpty,
|
|
412
|
+
ComboboxSeparator,
|
|
413
|
+
ComboboxChips,
|
|
414
|
+
ComboboxChip,
|
|
415
|
+
ComboboxChipsInput,
|
|
416
|
+
useComboboxAnchor
|
|
417
|
+
};
|
|
418
|
+
//# sourceMappingURL=chunk-VGR4ZWJ3.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/combobox.tsx"],"sourcesContent":["\"use client\";\n\nimport { Combobox as ComboboxPrimitive } from \"@base-ui/react\";\nimport { cva } from \"class-variance-authority\";\nimport { CheckIcon, ChevronDownIcon, XIcon } from \"lucide-react\";\nimport * as React from \"react\";\nimport { Button } from \"./button\";\nimport {\n\tInputGroup,\n\tInputGroupAddon,\n\tInputGroupButton,\n\tInputGroupInput,\n} from \"./input-group\";\nimport { cn } from \"./lib/cn\";\nimport {\n\ttype ComponentSize,\n\tSizeProvider,\n\tuseComponentSize,\n} from \"./size-context\";\n\nconst ComboboxSelectionContext = React.createContext({ multiple: false });\n\ntype ComboboxSize = ComponentSize;\n\nfunction Combobox<Value, Multiple extends boolean | undefined = false>({\n\tmultiple,\n\tchildren,\n\tsize,\n\t...props\n}: ComboboxPrimitive.Root.Props<Value, Multiple> & {\n\tsize?: ComboboxSize;\n}) {\n\treturn (\n\t\t<SizeProvider size={size}>\n\t\t\t<ComboboxSelectionContext.Provider\n\t\t\t\tvalue={{ multiple: multiple === true }}\n\t\t\t>\n\t\t\t\t<ComboboxPrimitive.Root multiple={multiple} {...props}>\n\t\t\t\t\t{children}\n\t\t\t\t</ComboboxPrimitive.Root>\n\t\t\t</ComboboxSelectionContext.Provider>\n\t\t</SizeProvider>\n\t);\n}\n\nconst comboboxTriggerVariants = cva(\n\t\"group/combobox-trigger flex w-fit min-w-0 items-center justify-between rounded-full border border-line bg-canvas text-left font-normal whitespace-nowrap text-fg-primary shadow-none outline-none transition-[background-color,border-color,border-radius,box-shadow,color] select-none hover:border-line-strong focus-visible:border-line-focus focus-visible:inset-ring-1 focus-visible:inset-ring-line-focus data-focused:border-line-focus data-focused:inset-ring-1 data-focused:inset-ring-line-focus data-popup-open:rounded-2xl data-popup-open:border-line-focus data-popup-open:inset-ring-1 data-popup-open:inset-ring-line-focus disabled:pointer-events-none disabled:cursor-not-allowed disabled:border-line-subtle disabled:bg-surface disabled:text-fg-caption-placeholder data-disabled:pointer-events-none data-disabled:cursor-not-allowed data-disabled:border-line-subtle data-disabled:bg-surface data-disabled:text-fg-caption-placeholder data-placeholder:text-fg-caption-placeholder aria-invalid:border-line-danger aria-invalid:text-fg-danger aria-invalid:shadow-none data-[invalid=true]:border-line-danger data-[invalid=true]:text-fg-danger *:data-[slot=combobox-value]:line-clamp-1 *:data-[slot=combobox-value]:flex *:data-[slot=combobox-value]:min-w-0 *:data-[slot=combobox-value]:items-center *:data-[slot=combobox-value]:gap-2 [&_svg]:pointer-events-none [&_svg]:shrink-0\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"h-8 gap-2 px-3 text-gdt-xs [&_svg:not([class*='size-'])]:size-3.5\",\n\t\t\t\tmd: \"h-10 gap-2 px-3.5 text-gdt-sm [&_svg:not([class*='size-'])]:size-4\",\n\t\t\t\tlg: \"h-12 gap-2.5 px-4 pr-5 text-gdt-md [&_svg:not([class*='size-'])]:size-4.5\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\nconst comboboxInputVariants = cva(\n\t\"w-auto has-data-popup-open:rounded-2xl has-data-popup-open:border-line-focus has-data-popup-open:inset-ring-1 has-data-popup-open:inset-ring-line-focus\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"\",\n\t\t\t\tmd: \"\",\n\t\t\t\tlg: \"\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\nconst comboboxContentVariants = cva(\n\t\"relative isolate z-50 max-h-(--available-height) w-(--anchor-width) max-w-(--available-width) min-w-[calc(var(--anchor-width))] origin-(--transform-origin) overflow-hidden border border-line-subtle bg-canvas text-fg-primary shadow-(--elevation-e1-shadow) duration-100 data-[chips=true]:min-w-(--anchor-width) data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-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 *:data-[slot=input-group]:mb-1 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"rounded-lg p-1\",\n\t\t\t\tmd: \"rounded-xl p-1.5\",\n\t\t\t\tlg: \"rounded-[18px] p-2\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\nconst comboboxItemVariants = cva(\n\t\"group/combobox-item relative flex w-full cursor-pointer items-center font-normal text-fg-primary outline-none select-none data-highlighted:bg-surface data-disabled:pointer-events-none data-disabled:text-fg-caption-placeholder [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"gap-1.5 rounded-md px-3 py-1.5 text-gdt-xs\",\n\t\t\t\tmd: \"gap-2 rounded-md px-4 py-2 text-gdt-sm\",\n\t\t\t\tlg: \"gap-2.5 rounded-md px-4 py-2.5 text-gdt-md\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\nconst comboboxChipsVariants = cva(\n\t\"flex flex-wrap items-center gap-1 rounded-full border border-line bg-canvas bg-clip-padding text-fg-primary transition-[background-color,border-color,box-shadow,color] focus-within:border-line-focus focus-within:inset-ring-1 focus-within:inset-ring-line-focus has-aria-invalid:border-line-danger has-aria-invalid:text-fg-danger has-aria-invalid:shadow-none has-data-[slot=combobox-chip]:px-1 has-data-popup-open:rounded-2xl has-data-popup-open:border-line-focus has-data-popup-open:inset-ring-1 has-data-popup-open:inset-ring-line-focus\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"min-h-8 px-2.5 py-1 text-gdt-xs\",\n\t\t\t\tmd: \"min-h-10 px-3 py-1.5 text-gdt-sm\",\n\t\t\t\tlg: \"min-h-12 px-4 py-2 text-gdt-md\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\nconst comboboxChipVariants = cva(\n\t\"flex w-fit items-center justify-center gap-1 rounded-sm bg-surface font-medium whitespace-nowrap text-fg-primary has-disabled:pointer-events-none has-disabled:cursor-not-allowed has-disabled:opacity-50 has-data-[slot=combobox-chip-remove]:pr-0\",\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\tsm: \"h-5 px-1.5 text-gdt-xs\",\n\t\t\t\tmd: \"h-[calc(--spacing(5.25))] px-1.5 text-gdt-xs\",\n\t\t\t\tlg: \"h-6 px-2 text-gdt-sm\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t},\n\t},\n);\n\nfunction ComboboxValue({ ...props }: ComboboxPrimitive.Value.Props) {\n\treturn <ComboboxPrimitive.Value data-slot=\"combobox-value\" {...props} />;\n}\n\nfunction ComboboxTrigger({\n\tclassName,\n\tchildren,\n\t...props\n}: ComboboxPrimitive.Trigger.Props) {\n\tconst resolvedSize = useComponentSize();\n\n\treturn (\n\t\t<ComboboxPrimitive.Trigger\n\t\t\tdata-slot=\"combobox-trigger\"\n\t\t\tdata-size={resolvedSize}\n\t\t\tclassName={cn(comboboxTriggerVariants({ size: resolvedSize }), className)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{children}\n\t\t\t<ComboboxPrimitive.Icon\n\t\t\t\trender={\n\t\t\t\t\t<ChevronDownIcon className=\"text-line-strong transition-transform group-data-disabled/combobox-trigger:text-fg-caption-placeholder group-data-popup-open/combobox-trigger:rotate-180\" />\n\t\t\t\t}\n\t\t\t/>\n\t\t</ComboboxPrimitive.Trigger>\n\t);\n}\n\nfunction ComboboxClear({ className, ...props }: ComboboxPrimitive.Clear.Props) {\n\treturn (\n\t\t<ComboboxPrimitive.Clear\n\t\t\tdata-slot=\"combobox-clear\"\n\t\t\tclassName={cn(className)}\n\t\t\t{...props}\n\t\t\trender={\n\t\t\t\t<InputGroupButton variant=\"ghost\" size=\"icon-xs\">\n\t\t\t\t\t<XIcon className=\"pointer-events-none\" />\n\t\t\t\t</InputGroupButton>\n\t\t\t}\n\t\t/>\n\t);\n}\n\nfunction ComboboxInput({\n\tclassName,\n\tchildren,\n\tdisabled = false,\n\tshowTrigger = true,\n\tshowClear = false,\n\t...props\n}: ComboboxPrimitive.Input.Props & {\n\tshowTrigger?: boolean;\n\tshowClear?: boolean;\n}) {\n\tconst resolvedSize = useComponentSize();\n\n\treturn (\n\t\t<InputGroup\n\t\t\tclassName={cn(comboboxInputVariants({ size: resolvedSize }), className)}\n\t\t>\n\t\t\t<ComboboxPrimitive.Input\n\t\t\t\trender={<InputGroupInput disabled={disabled} />}\n\t\t\t\t{...props}\n\t\t\t/>\n\t\t\t<InputGroupAddon align=\"inline-end\">\n\t\t\t\t{showTrigger && (\n\t\t\t\t\t<InputGroupButton\n\t\t\t\t\t\tsize=\"icon-xs\"\n\t\t\t\t\t\tvariant=\"ghost\"\n\t\t\t\t\t\trender={<ComboboxTrigger />}\n\t\t\t\t\t\tdata-slot=\"input-group-button\"\n\t\t\t\t\t\tclassName=\"h-6 border-0 bg-transparent p-0 shadow-none inset-ring-0 group-has-data-[slot=combobox-clear]/input-group:hidden hover:border-transparent focus-visible:border-transparent focus-visible:inset-ring-0 data-popup-open:border-transparent data-popup-open:bg-transparent data-popup-open:inset-ring-0 data-pressed:bg-transparent\"\n\t\t\t\t\t\tdisabled={disabled}\n\t\t\t\t\t/>\n\t\t\t\t)}\n\t\t\t\t{showClear && <ComboboxClear disabled={disabled} />}\n\t\t\t</InputGroupAddon>\n\t\t\t{children}\n\t\t</InputGroup>\n\t);\n}\n\nfunction ComboboxContent({\n\tclassName,\n\tside = \"bottom\",\n\tsideOffset = 6,\n\talign = \"start\",\n\talignOffset = 0,\n\tanchor,\n\t...props\n}: ComboboxPrimitive.Popup.Props &\n\tPick<\n\t\tComboboxPrimitive.Positioner.Props,\n\t\t\"side\" | \"align\" | \"sideOffset\" | \"alignOffset\" | \"anchor\"\n\t>) {\n\tconst resolvedSize = useComponentSize();\n\n\treturn (\n\t\t<ComboboxPrimitive.Portal>\n\t\t\t<ComboboxPrimitive.Positioner\n\t\t\t\tside={side}\n\t\t\t\tsideOffset={sideOffset}\n\t\t\t\talign={align}\n\t\t\t\talignOffset={alignOffset}\n\t\t\t\tanchor={anchor}\n\t\t\t\tclassName=\"isolate z-50\"\n\t\t\t>\n\t\t\t\t<ComboboxPrimitive.Popup\n\t\t\t\t\tdata-slot=\"combobox-content\"\n\t\t\t\t\tdata-chips={!!anchor}\n\t\t\t\t\tclassName={cn(\n\t\t\t\t\t\t\"group/combobox-content\",\n\t\t\t\t\t\tcomboboxContentVariants({ size: resolvedSize }),\n\t\t\t\t\t\tclassName,\n\t\t\t\t\t)}\n\t\t\t\t\t{...props}\n\t\t\t\t/>\n\t\t\t</ComboboxPrimitive.Positioner>\n\t\t</ComboboxPrimitive.Portal>\n\t);\n}\n\nfunction ComboboxList({ className, ...props }: ComboboxPrimitive.List.Props) {\n\treturn (\n\t\t<ComboboxPrimitive.List\n\t\t\tdata-slot=\"combobox-list\"\n\t\t\tclassName={cn(\n\t\t\t\t\"no-scrollbar max-h-(--available-height) space-y-0.5 scroll-py-1 overflow-y-auto overscroll-contain data-empty:p-0\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction ComboboxItem({\n\tclassName,\n\tchildren,\n\t...props\n}: ComboboxPrimitive.Item.Props) {\n\tconst { multiple } = React.useContext(ComboboxSelectionContext);\n\tconst resolvedSize = useComponentSize();\n\n\treturn (\n\t\t<ComboboxPrimitive.Item\n\t\t\tdata-slot=\"combobox-item\"\n\t\t\tclassName={cn(\n\t\t\t\tcomboboxItemVariants({ size: resolvedSize }),\n\t\t\t\t!multiple &&\n\t\t\t\t\t\"data-selected:bg-surface-brand-subtle data-selected:font-medium data-selected:text-fg-brand\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{multiple ? (\n\t\t\t\t<ComboboxPrimitive.ItemIndicator\n\t\t\t\t\tkeepMounted\n\t\t\t\t\tclassName=\"flex size-5 shrink-0 items-center justify-center rounded-sm border border-line bg-canvas text-transparent transition-[background-color,border-color,color] group-data-selected/combobox-item:border-action-primary group-data-selected/combobox-item:bg-action-primary group-data-selected/combobox-item:text-fg-on-brand group-data-disabled/combobox-item:border-line-subtle group-data-disabled/combobox-item:bg-surface group-data-disabled/combobox-item:text-fg-caption-placeholder [&>svg]:size-3\"\n\t\t\t\t>\n\t\t\t\t\t<CheckIcon />\n\t\t\t\t</ComboboxPrimitive.ItemIndicator>\n\t\t\t) : null}\n\t\t\t<span className=\"flex min-w-0 flex-1 shrink-0 gap-2 whitespace-nowrap\">\n\t\t\t\t{children}\n\t\t\t</span>\n\t\t</ComboboxPrimitive.Item>\n\t);\n}\n\nfunction ComboboxGroup({ className, ...props }: ComboboxPrimitive.Group.Props) {\n\treturn (\n\t\t<ComboboxPrimitive.Group\n\t\t\tdata-slot=\"combobox-group\"\n\t\t\tclassName={cn(\"scroll-my-1 space-y-0.5\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction ComboboxLabel({\n\tclassName,\n\t...props\n}: ComboboxPrimitive.GroupLabel.Props) {\n\treturn (\n\t\t<ComboboxPrimitive.GroupLabel\n\t\t\tdata-slot=\"combobox-label\"\n\t\t\tclassName={cn(\"px-3 py-1 text-gdt-xs text-fg-secondary\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction ComboboxCollection({ ...props }: ComboboxPrimitive.Collection.Props) {\n\treturn (\n\t\t<ComboboxPrimitive.Collection data-slot=\"combobox-collection\" {...props} />\n\t);\n}\n\nfunction ComboboxEmpty({ className, ...props }: ComboboxPrimitive.Empty.Props) {\n\treturn (\n\t\t<ComboboxPrimitive.Empty\n\t\t\tdata-slot=\"combobox-empty\"\n\t\t\tclassName={cn(\n\t\t\t\t\"hidden w-full justify-center py-2 text-center text-gdt-sm text-fg-secondary group-data-empty/combobox-content:flex\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction ComboboxSeparator({\n\tclassName,\n\t...props\n}: ComboboxPrimitive.Separator.Props) {\n\treturn (\n\t\t<ComboboxPrimitive.Separator\n\t\t\tdata-slot=\"combobox-separator\"\n\t\t\tclassName={cn(\"pointer-events-none my-1 h-px bg-line-subtle\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction ComboboxChips({\n\tclassName,\n\t...props\n}: React.ComponentPropsWithRef<typeof ComboboxPrimitive.Chips> &\n\tComboboxPrimitive.Chips.Props) {\n\tconst resolvedSize = useComponentSize();\n\n\treturn (\n\t\t<ComboboxPrimitive.Chips\n\t\t\tdata-slot=\"combobox-chips\"\n\t\t\tclassName={cn(comboboxChipsVariants({ size: resolvedSize }), className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction ComboboxChip({\n\tclassName,\n\tchildren,\n\tshowRemove = true,\n\t...props\n}: ComboboxPrimitive.Chip.Props & {\n\tshowRemove?: boolean;\n}) {\n\tconst resolvedSize = useComponentSize();\n\n\treturn (\n\t\t<ComboboxPrimitive.Chip\n\t\t\tdata-slot=\"combobox-chip\"\n\t\t\tclassName={cn(comboboxChipVariants({ size: resolvedSize }), className)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{children}\n\t\t\t{showRemove && (\n\t\t\t\t<ComboboxPrimitive.ChipRemove\n\t\t\t\t\tclassName=\"-ml-1 opacity-50 hover:opacity-100\"\n\t\t\t\t\tdata-slot=\"combobox-chip-remove\"\n\t\t\t\t\trender={\n\t\t\t\t\t\t<Button variant=\"ghost\" size=\"icon-xs\">\n\t\t\t\t\t\t\t<XIcon className=\"pointer-events-none\" />\n\t\t\t\t\t\t</Button>\n\t\t\t\t\t}\n\t\t\t\t/>\n\t\t\t)}\n\t\t</ComboboxPrimitive.Chip>\n\t);\n}\n\nfunction ComboboxChipsInput({\n\tclassName,\n\t...props\n}: ComboboxPrimitive.Input.Props) {\n\treturn (\n\t\t<ComboboxPrimitive.Input\n\t\t\tdata-slot=\"combobox-chip-input\"\n\t\t\tclassName={cn(\n\t\t\t\t\"min-w-16 flex-1 bg-transparent text-fg-primary outline-none placeholder:text-fg-caption-placeholder\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction useComboboxAnchor() {\n\treturn React.useRef<HTMLDivElement | null>(null);\n}\n\nexport {\n\tCombobox,\n\tComboboxInput,\n\tComboboxContent,\n\tComboboxList,\n\tComboboxItem,\n\tComboboxGroup,\n\tComboboxLabel,\n\tComboboxCollection,\n\tComboboxEmpty,\n\tComboboxSeparator,\n\tComboboxChips,\n\tComboboxChip,\n\tComboboxChipsInput,\n\tComboboxTrigger,\n\ttype ComboboxSize,\n\tComboboxValue,\n\tuseComboboxAnchor,\n};\n"],"mappings":";;;;;;;;;;;;;;;;;;AAEA,SAAS,YAAY,yBAAyB;AAC9C,SAAS,WAAW;AACpB,SAAS,WAAW,iBAAiB,aAAa;AAClD,YAAY,WAAW;AAgCnB,cAoHF,YApHE;AAjBJ,IAAM,2BAAiC,oBAAc,EAAE,UAAU,MAAM,CAAC;AAIxE,SAAS,SAA8D;AAAA,EACtE;AAAA,EACA;AAAA,EACA;AAAA,EACA,GAAG;AACJ,GAEG;AACF,SACC,oBAAC,gBAAa,MACb;AAAA,IAAC,yBAAyB;AAAA,IAAzB;AAAA,MACA,OAAO,EAAE,UAAU,aAAa,KAAK;AAAA,MAErC,8BAAC,kBAAkB,MAAlB,EAAuB,UAAqB,GAAG,OAC9C,UACF;AAAA;AAAA,EACD,GACD;AAEF;AAEA,IAAM,0BAA0B;AAAA,EAC/B;AAAA,EACA;AAAA,IACC,UAAU;AAAA,MACT,MAAM;AAAA,QACL,IAAI;AAAA,QACJ,IAAI;AAAA,QACJ,IAAI;AAAA,MACL;AAAA,IACD;AAAA,IACA,iBAAiB;AAAA,MAChB,MAAM;AAAA,IACP;AAAA,EACD;AACD;AAEA,IAAM,wBAAwB;AAAA,EAC7B;AAAA,EACA;AAAA,IACC,UAAU;AAAA,MACT,MAAM;AAAA,QACL,IAAI;AAAA,QACJ,IAAI;AAAA,QACJ,IAAI;AAAA,MACL;AAAA,IACD;AAAA,IACA,iBAAiB;AAAA,MAChB,MAAM;AAAA,IACP;AAAA,EACD;AACD;AAEA,IAAM,0BAA0B;AAAA,EAC/B;AAAA,EACA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B;AAAA,MACA,aAAU;AAAA,MACV,WAAW,GAAG,qBAAqB,EAAE,MAAM,aAAa,CAAC,GAAG,SAAS;AAAA,MACpE,GAAG;AAAA,MAEH;AAAA;AAAA,QACA,cACA;AAAA,UAAC,kBAAkB;AAAA,UAAlB;AAAA,YACA,WAAU;AAAA,YACV,aAAU;AAAA,YACV,QACC,oBAAC,UAAO,SAAQ,SAAQ,MAAK,WAC5B,8BAAC,SAAM,WAAU,uBAAsB,GACxC;AAAA;AAAA,QAEF;AAAA;AAAA;AAAA,EAEF;AAEF;AAEA,SAAS,mBAAmB;AAAA,EAC3B;AAAA,EACA,GAAG;AACJ,GAAkC;AACjC,SACC;AAAA,IAAC,kBAAkB;AAAA,IAAlB;AAAA,MACA,aAAU;AAAA,MACV,WAAW;AAAA,QACV;AAAA,QACA;AAAA,MACD;AAAA,MACC,GAAG;AAAA;AAAA,EACL;AAEF;AAEA,SAAS,oBAAoB;AAC5B,SAAa,aAA8B,IAAI;AAChD;","names":[]}
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
import {
|
|
2
|
+
useComponentSize
|
|
3
|
+
} from "./chunk-HL3ZSYES.js";
|
|
4
|
+
import {
|
|
5
|
+
cn
|
|
6
|
+
} from "./chunk-Y4TTYVNE.js";
|
|
7
|
+
|
|
8
|
+
// src/badge.tsx
|
|
9
|
+
import { mergeProps } from "@base-ui/react/merge-props";
|
|
10
|
+
import { useRender } from "@base-ui/react/use-render";
|
|
11
|
+
import { cva } from "class-variance-authority";
|
|
12
|
+
var badgeVariants = cva(
|
|
13
|
+
"group/badge inline-flex w-fit shrink-0 items-center justify-center overflow-hidden border font-bold leading-none whitespace-nowrap transition-[background-color,border-color,color,box-shadow] outline-none focus-visible:border-line-focus focus-visible:shadow-[0px_0px_0px_2px_var(--color-line-focus)] aria-invalid:border-line-danger aria-invalid:text-fg-danger [&>svg]:pointer-events-none [&>svg]:shrink-0 [&>svg]:text-current",
|
|
14
|
+
{
|
|
15
|
+
variants: {
|
|
16
|
+
variant: {
|
|
17
|
+
default: "border-line bg-surface-raised text-fg-secondary",
|
|
18
|
+
accent: "border-transparent bg-surface-accent text-fg-on-accent",
|
|
19
|
+
info: "border-status-info/40 bg-surface-info-subtle text-status-info",
|
|
20
|
+
success: "border-status-success/40 bg-surface-brand-subtle text-status-success",
|
|
21
|
+
warning: "border-status-warning/40 bg-surface-accent-subtle text-status-warning",
|
|
22
|
+
danger: "border-line-danger bg-surface-danger-subtle text-status-danger",
|
|
23
|
+
secondary: "border-status-info/40 bg-surface-info-subtle text-status-info",
|
|
24
|
+
destructive: "border-line-danger bg-surface-danger-subtle text-status-danger",
|
|
25
|
+
outline: "border-line bg-transparent text-fg-secondary"
|
|
26
|
+
},
|
|
27
|
+
size: {
|
|
28
|
+
sm: "min-h-7 min-w-7 gap-1 px-2.5 py-1 text-gdt-xs [&>svg]:size-3",
|
|
29
|
+
md: "min-h-9 min-w-9 gap-1.5 px-3 py-1.5 text-gdt-sm [&>svg]:size-3.5",
|
|
30
|
+
lg: "min-h-10.5 min-w-10.5 gap-2 px-4 py-2 text-gdt-md [&>svg]:size-4"
|
|
31
|
+
},
|
|
32
|
+
shape: {
|
|
33
|
+
round: "rounded-4xl",
|
|
34
|
+
box: "rounded-lg"
|
|
35
|
+
},
|
|
36
|
+
border: {
|
|
37
|
+
true: "",
|
|
38
|
+
false: "border-transparent"
|
|
39
|
+
},
|
|
40
|
+
iconOnly: {
|
|
41
|
+
true: "py-0 px-0",
|
|
42
|
+
false: ""
|
|
43
|
+
}
|
|
44
|
+
},
|
|
45
|
+
defaultVariants: {
|
|
46
|
+
variant: "default",
|
|
47
|
+
size: "md",
|
|
48
|
+
shape: "round",
|
|
49
|
+
border: true
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
);
|
|
53
|
+
function Badge({
|
|
54
|
+
className,
|
|
55
|
+
variant = "default",
|
|
56
|
+
size,
|
|
57
|
+
shape = "round",
|
|
58
|
+
border = true,
|
|
59
|
+
iconOnly = false,
|
|
60
|
+
render,
|
|
61
|
+
children,
|
|
62
|
+
...props
|
|
63
|
+
}) {
|
|
64
|
+
const resolvedSize = useComponentSize(size);
|
|
65
|
+
return useRender({
|
|
66
|
+
defaultTagName: "span",
|
|
67
|
+
props: mergeProps(
|
|
68
|
+
{
|
|
69
|
+
className: cn(
|
|
70
|
+
badgeVariants({
|
|
71
|
+
variant,
|
|
72
|
+
size: resolvedSize,
|
|
73
|
+
shape,
|
|
74
|
+
border,
|
|
75
|
+
iconOnly
|
|
76
|
+
}),
|
|
77
|
+
className
|
|
78
|
+
),
|
|
79
|
+
children
|
|
80
|
+
},
|
|
81
|
+
props
|
|
82
|
+
),
|
|
83
|
+
render,
|
|
84
|
+
state: {
|
|
85
|
+
slot: "badge",
|
|
86
|
+
variant,
|
|
87
|
+
size: resolvedSize,
|
|
88
|
+
shape,
|
|
89
|
+
border,
|
|
90
|
+
iconOnly
|
|
91
|
+
}
|
|
92
|
+
});
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
export {
|
|
96
|
+
badgeVariants,
|
|
97
|
+
Badge
|
|
98
|
+
};
|
|
99
|
+
//# sourceMappingURL=chunk-XG47P6D4.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/badge.tsx"],"sourcesContent":["import { mergeProps } from \"@base-ui/react/merge-props\";\nimport { useRender } from \"@base-ui/react/use-render\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\n\nimport { cn } from \"./lib/cn\";\nimport { useComponentSize } from \"./size-context\";\n\nconst badgeVariants = cva(\n\t\"group/badge inline-flex w-fit shrink-0 items-center justify-center overflow-hidden border font-bold leading-none whitespace-nowrap transition-[background-color,border-color,color,box-shadow] outline-none focus-visible:border-line-focus focus-visible:shadow-[0px_0px_0px_2px_var(--color-line-focus)] aria-invalid:border-line-danger aria-invalid:text-fg-danger [&>svg]:pointer-events-none [&>svg]:shrink-0 [&>svg]:text-current\",\n\t{\n\t\tvariants: {\n\t\t\tvariant: {\n\t\t\t\tdefault: \"border-line bg-surface-raised text-fg-secondary\",\n\t\t\t\taccent: \"border-transparent bg-surface-accent text-fg-on-accent\",\n\t\t\t\tinfo: \"border-status-info/40 bg-surface-info-subtle text-status-info\",\n\t\t\t\tsuccess:\n\t\t\t\t\t\"border-status-success/40 bg-surface-brand-subtle text-status-success\",\n\t\t\t\twarning:\n\t\t\t\t\t\"border-status-warning/40 bg-surface-accent-subtle text-status-warning\",\n\t\t\t\tdanger:\n\t\t\t\t\t\"border-line-danger bg-surface-danger-subtle text-status-danger\",\n\t\t\t\tsecondary:\n\t\t\t\t\t\"border-status-info/40 bg-surface-info-subtle text-status-info\",\n\t\t\t\tdestructive:\n\t\t\t\t\t\"border-line-danger bg-surface-danger-subtle text-status-danger\",\n\t\t\t\toutline: \"border-line bg-transparent text-fg-secondary\",\n\t\t\t},\n\t\t\tsize: {\n\t\t\t\tsm: \"min-h-7 min-w-7 gap-1 px-2.5 py-1 text-gdt-xs [&>svg]:size-3\",\n\t\t\t\tmd: \"min-h-9 min-w-9 gap-1.5 px-3 py-1.5 text-gdt-sm [&>svg]:size-3.5\",\n\t\t\t\tlg: \"min-h-10.5 min-w-10.5 gap-2 px-4 py-2 text-gdt-md [&>svg]:size-4\",\n\t\t\t},\n\t\t\tshape: {\n\t\t\t\tround: \"rounded-4xl\",\n\t\t\t\tbox: \"rounded-lg\",\n\t\t\t},\n\t\t\tborder: {\n\t\t\t\ttrue: \"\",\n\t\t\t\tfalse: \"border-transparent\",\n\t\t\t},\n\t\t\ticonOnly: {\n\t\t\t\ttrue: \"py-0 px-0\",\n\t\t\t\tfalse: \"\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tvariant: \"default\",\n\t\t\tsize: \"md\",\n\t\t\tshape: \"round\",\n\t\t\tborder: true,\n\t\t},\n\t},\n);\n\nfunction Badge({\n\tclassName,\n\tvariant = \"default\",\n\tsize,\n\tshape = \"round\",\n\tborder = true,\n\ticonOnly = false,\n\trender,\n\tchildren,\n\t...props\n}: useRender.ComponentProps<\"span\"> & VariantProps<typeof badgeVariants>) {\n\tconst resolvedSize = useComponentSize(size);\n\n\treturn useRender({\n\t\tdefaultTagName: \"span\",\n\t\tprops: mergeProps<\"span\">(\n\t\t\t{\n\t\t\t\tclassName: cn(\n\t\t\t\t\tbadgeVariants({\n\t\t\t\t\t\tvariant,\n\t\t\t\t\t\tsize: resolvedSize,\n\t\t\t\t\t\tshape,\n\t\t\t\t\t\tborder,\n\t\t\t\t\t\ticonOnly,\n\t\t\t\t\t}),\n\t\t\t\t\tclassName,\n\t\t\t\t),\n\t\t\t\tchildren,\n\t\t\t},\n\t\t\tprops,\n\t\t),\n\t\trender,\n\t\tstate: {\n\t\t\tslot: \"badge\",\n\t\t\tvariant,\n\t\t\tsize: resolvedSize,\n\t\t\tshape,\n\t\t\tborder,\n\t\t\ticonOnly,\n\t\t},\n\t});\n}\n\nexport { Badge, badgeVariants };\n"],"mappings":";;;;;;;;AAAA,SAAS,kBAAkB;AAC3B,SAAS,iBAAiB;AAC1B,SAAS,WAA8B;AAKvC,IAAM,gBAAgB;AAAA,EACrB;AAAA,EACA;AAAA,IACC,UAAU;AAAA,MACT,SAAS;AAAA,QACR,SAAS;AAAA,QACT,QAAQ;AAAA,QACR,MAAM;AAAA,QACN,SACC;AAAA,QACD,SACC;AAAA,QACD,QACC;AAAA,QACD,WACC;AAAA,QACD,aACC;AAAA,QACD,SAAS;AAAA,MACV;AAAA,MACA,MAAM;AAAA,QACL,IAAI;AAAA,QACJ,IAAI;AAAA,QACJ,IAAI;AAAA,MACL;AAAA,MACA,OAAO;AAAA,QACN,OAAO;AAAA,QACP,KAAK;AAAA,MACN;AAAA,MACA,QAAQ;AAAA,QACP,MAAM;AAAA,QACN,OAAO;AAAA,MACR;AAAA,MACA,UAAU;AAAA,QACT,MAAM;AAAA,QACN,OAAO;AAAA,MACR;AAAA,IACD;AAAA,IACA,iBAAiB;AAAA,MAChB,SAAS;AAAA,MACT,MAAM;AAAA,MACN,OAAO;AAAA,MACP,QAAQ;AAAA,IACT;AAAA,EACD;AACD;AAEA,SAAS,MAAM;AAAA,EACd;AAAA,EACA,UAAU;AAAA,EACV;AAAA,EACA,QAAQ;AAAA,EACR,SAAS;AAAA,EACT,WAAW;AAAA,EACX;AAAA,EACA;AAAA,EACA,GAAG;AACJ,GAA0E;AACzE,QAAM,eAAe,iBAAiB,IAAI;AAE1C,SAAO,UAAU;AAAA,IAChB,gBAAgB;AAAA,IAChB,OAAO;AAAA,MACN;AAAA,QACC,WAAW;AAAA,UACV,cAAc;AAAA,YACb;AAAA,YACA,MAAM;AAAA,YACN;AAAA,YACA;AAAA,YACA;AAAA,UACD,CAAC;AAAA,UACD;AAAA,QACD;AAAA,QACA;AAAA,MACD;AAAA,MACA;AAAA,IACD;AAAA,IACA;AAAA,IACA,OAAO;AAAA,MACN,MAAM;AAAA,MACN;AAAA,MACA,MAAM;AAAA,MACN;AAAA,MACA;AAAA,MACA;AAAA,IACD;AAAA,EACD,CAAC;AACF;","names":[]}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import {
|
|
2
|
+
cn
|
|
3
|
+
} from "./chunk-Y4TTYVNE.js";
|
|
4
|
+
|
|
5
|
+
// src/skeleton.tsx
|
|
6
|
+
import { jsx } from "react/jsx-runtime";
|
|
7
|
+
function Skeleton({ className, ...props }) {
|
|
8
|
+
return /* @__PURE__ */ jsx(
|
|
9
|
+
"div",
|
|
10
|
+
{
|
|
11
|
+
"data-slot": "skeleton",
|
|
12
|
+
className: cn("animate-pulse rounded-md bg-line", className),
|
|
13
|
+
...props
|
|
14
|
+
}
|
|
15
|
+
);
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export {
|
|
19
|
+
Skeleton
|
|
20
|
+
};
|
|
21
|
+
//# sourceMappingURL=chunk-XZZAHNVM.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/skeleton.tsx"],"sourcesContent":["import { cn } from \"./lib/cn\";\n\nfunction Skeleton({ className, ...props }: React.ComponentProps<\"div\">) {\n\treturn (\n\t\t<div\n\t\t\tdata-slot=\"skeleton\"\n\t\t\tclassName={cn(\"animate-pulse rounded-md bg-line\", className)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport { Skeleton };\n"],"mappings":";;;;;AAIE;AAFF,SAAS,SAAS,EAAE,WAAW,GAAG,MAAM,GAAgC;AACvE,SACC;AAAA,IAAC;AAAA;AAAA,MACA,aAAU;AAAA,MACV,WAAW,GAAG,oCAAoC,SAAS;AAAA,MAC1D,GAAG;AAAA;AAAA,EACL;AAEF;","names":[]}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
// src/lib/cn.ts
|
|
2
|
+
import { clsx } from "clsx";
|
|
3
|
+
import { extendTailwindMerge } from "tailwind-merge";
|
|
4
|
+
var twMerge = extendTailwindMerge({
|
|
5
|
+
extend: {
|
|
6
|
+
classGroups: {
|
|
7
|
+
"font-size": [
|
|
8
|
+
{
|
|
9
|
+
text: [
|
|
10
|
+
"gdt-display",
|
|
11
|
+
"gdt-h1",
|
|
12
|
+
"gdt-h2",
|
|
13
|
+
"gdt-h3",
|
|
14
|
+
"gdt-h4",
|
|
15
|
+
"gdt-h5",
|
|
16
|
+
"gdt-xl",
|
|
17
|
+
"gdt-lg",
|
|
18
|
+
"gdt-md",
|
|
19
|
+
"gdt-sm",
|
|
20
|
+
"gdt-xs",
|
|
21
|
+
"gdt-subtext",
|
|
22
|
+
"gdt-capitalized"
|
|
23
|
+
]
|
|
24
|
+
}
|
|
25
|
+
]
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
});
|
|
29
|
+
function cn(...inputs) {
|
|
30
|
+
return twMerge(clsx(inputs));
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
export {
|
|
34
|
+
cn
|
|
35
|
+
};
|
|
36
|
+
//# sourceMappingURL=chunk-Y4TTYVNE.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/lib/cn.ts"],"sourcesContent":["import { type ClassValue, clsx } from \"clsx\";\nimport { extendTailwindMerge } from \"tailwind-merge\";\n\nconst twMerge = extendTailwindMerge({\n\textend: {\n\t\tclassGroups: {\n\t\t\t\"font-size\": [\n\t\t\t\t{\n\t\t\t\t\ttext: [\n\t\t\t\t\t\t\"gdt-display\",\n\t\t\t\t\t\t\"gdt-h1\",\n\t\t\t\t\t\t\"gdt-h2\",\n\t\t\t\t\t\t\"gdt-h3\",\n\t\t\t\t\t\t\"gdt-h4\",\n\t\t\t\t\t\t\"gdt-h5\",\n\t\t\t\t\t\t\"gdt-xl\",\n\t\t\t\t\t\t\"gdt-lg\",\n\t\t\t\t\t\t\"gdt-md\",\n\t\t\t\t\t\t\"gdt-sm\",\n\t\t\t\t\t\t\"gdt-xs\",\n\t\t\t\t\t\t\"gdt-subtext\",\n\t\t\t\t\t\t\"gdt-capitalized\",\n\t\t\t\t\t],\n\t\t\t\t},\n\t\t\t],\n\t\t},\n\t},\n});\n\nexport function cn(...inputs: ClassValue[]) {\n\treturn twMerge(clsx(inputs));\n}\n"],"mappings":";AAAA,SAA0B,YAAY;AACtC,SAAS,2BAA2B;AAEpC,IAAM,UAAU,oBAAoB;AAAA,EACnC,QAAQ;AAAA,IACP,aAAa;AAAA,MACZ,aAAa;AAAA,QACZ;AAAA,UACC,MAAM;AAAA,YACL;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,UACD;AAAA,QACD;AAAA,MACD;AAAA,IACD;AAAA,EACD;AACD,CAAC;AAEM,SAAS,MAAM,QAAsB;AAC3C,SAAO,QAAQ,KAAK,MAAM,CAAC;AAC5B;","names":[]}
|