@adgytec/adgytec-web-ui-components 2.1.6 → 2.1.8
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/assets/core.css +1 -1
- package/dist/chunks/ActionDialog.map +1 -1
- package/dist/chunks/AppBarAction.map +1 -1
- package/dist/chunks/AppBarAvatar +38 -30
- package/dist/chunks/AppBarAvatar.map +1 -1
- package/dist/chunks/AppBarHeadline +18 -12
- package/dist/chunks/AppBarHeadline.map +1 -1
- package/dist/chunks/BaseCalendar.map +1 -1
- package/dist/chunks/BottomSheet +23 -16
- package/dist/chunks/BottomSheet.map +1 -1
- package/dist/chunks/BottomSheetModal.map +1 -1
- package/dist/chunks/ButtonGroup +28 -20
- package/dist/chunks/ButtonGroup.map +1 -1
- package/dist/chunks/CalendarCell.map +1 -1
- package/dist/chunks/CalendarGrid +40 -22
- package/dist/chunks/CalendarGrid.map +1 -1
- package/dist/chunks/CalendarMenuItem +18 -9
- package/dist/chunks/CalendarMenuItem.map +1 -1
- package/dist/chunks/CenteredSlider.map +1 -1
- package/dist/chunks/ComboBox.map +1 -1
- package/dist/chunks/ComboBoxPopover.map +1 -1
- package/dist/chunks/ComboBoxTrigger +66 -44
- package/dist/chunks/ComboBoxTrigger.map +1 -1
- package/dist/chunks/ConnectedButtonGroup.map +1 -1
- package/dist/chunks/Dialog +21 -12
- package/dist/chunks/Dialog.map +1 -1
- package/dist/chunks/Disclosure +17 -8
- package/dist/chunks/Disclosure.map +1 -1
- package/dist/chunks/DisclosureGroup +28 -15
- package/dist/chunks/DisclosureGroup.map +1 -1
- package/dist/chunks/DisclosureHeader +53 -35
- package/dist/chunks/DisclosureHeader.map +1 -1
- package/dist/chunks/DisclosurePanel +22 -12
- package/dist/chunks/DisclosurePanel.map +1 -1
- package/dist/chunks/Divider +18 -9
- package/dist/chunks/Divider.map +1 -1
- package/dist/chunks/FieldError +18 -9
- package/dist/chunks/FieldError.map +1 -1
- package/dist/chunks/Icon +20 -15
- package/dist/chunks/Icon.map +1 -1
- package/dist/chunks/Input +72 -64
- package/dist/chunks/Input.map +1 -1
- package/dist/chunks/Input2 +82 -72
- package/dist/chunks/Input2.map +1 -1
- package/dist/chunks/Loader +17 -10
- package/dist/chunks/Loader.map +1 -1
- package/dist/chunks/MenuPopover +17 -8
- package/dist/chunks/MenuPopover.map +1 -1
- package/dist/chunks/Modal +17 -8
- package/dist/chunks/Modal.map +1 -1
- package/dist/chunks/ModalOverlay +17 -8
- package/dist/chunks/ModalOverlay.map +1 -1
- package/dist/chunks/Navigation +46 -36
- package/dist/chunks/Navigation.map +1 -1
- package/dist/chunks/NavigationScrollContainer +37 -27
- package/dist/chunks/NavigationScrollContainer.map +1 -1
- package/dist/chunks/NavigationSection +16 -7
- package/dist/chunks/NavigationSection.map +1 -1
- package/dist/chunks/NavigationSectionLabel +18 -9
- package/dist/chunks/NavigationSectionLabel.map +1 -1
- package/dist/chunks/NavigationState.map +1 -1
- package/dist/chunks/Popover +17 -8
- package/dist/chunks/Popover.map +1 -1
- package/dist/chunks/Radio +59 -52
- package/dist/chunks/Radio.map +1 -1
- package/dist/chunks/RichTooltip +17 -8
- package/dist/chunks/RichTooltip.map +1 -1
- package/dist/chunks/RichTooltipActions +16 -7
- package/dist/chunks/RichTooltipActions.map +1 -1
- package/dist/chunks/RichTooltipInfo +16 -7
- package/dist/chunks/RichTooltipInfo.map +1 -1
- package/dist/chunks/SearchField.map +1 -1
- package/dist/chunks/SelectPopover +17 -8
- package/dist/chunks/SelectPopover.map +1 -1
- package/dist/chunks/SelectTrigger +34 -24
- package/dist/chunks/SelectTrigger.map +1 -1
- package/dist/chunks/SideSheet +64 -52
- package/dist/chunks/SideSheet.map +1 -1
- package/dist/chunks/SideSheetModal.map +1 -1
- package/dist/chunks/Slider.map +1 -1
- package/dist/chunks/SliderOutput +21 -16
- package/dist/chunks/SliderOutput.map +1 -1
- package/dist/chunks/SliderStops.map +1 -1
- package/dist/chunks/Snackbar.map +1 -1
- package/dist/chunks/SplitButtonTrigger +48 -38
- package/dist/chunks/SplitButtonTrigger.map +1 -1
- package/dist/chunks/SubmenuPopover.map +1 -1
- package/dist/chunks/Switch.map +1 -1
- package/dist/chunks/Tab +41 -29
- package/dist/chunks/Tab.map +1 -1
- package/dist/chunks/TabList +16 -8
- package/dist/chunks/TabList.map +1 -1
- package/dist/chunks/TabPanel +16 -8
- package/dist/chunks/TabPanel.map +1 -1
- package/dist/chunks/TabPanels +17 -9
- package/dist/chunks/TabPanels.map +1 -1
- package/dist/chunks/Tabs +17 -8
- package/dist/chunks/Tabs.map +1 -1
- package/dist/chunks/Tag.map +1 -1
- package/dist/chunks/ThemeSelector +73 -72
- package/dist/chunks/ThemeSelector.map +1 -1
- package/dist/chunks/Toolbar +20 -12
- package/dist/chunks/Toolbar.map +1 -1
- package/dist/chunks/Tooltip.map +1 -1
- package/dist/chunks/compiler-runtime +24 -0
- package/dist/chunks/compiler-runtime.map +1 -0
- package/dist/chunks/core +75 -68
- package/dist/chunks/core.map +1 -1
- package/dist/chunks/core3.map +1 -1
- package/dist/chunks/core8.map +1 -1
- package/dist/chunks/core9.map +1 -1
- package/dist/chunks/navContext.map +1 -1
- package/dist/chunks/useGlobalListeners.map +1 -1
- package/dist/chunks/useHover +1 -1
- package/dist/chunks/useHover.map +1 -1
- package/dist/chunks/usePress +1 -1
- package/dist/chunks/usePress.map +1 -1
- package/dist/chunks/useSplash +42 -27
- package/dist/chunks/useSplash.map +1 -1
- package/dist/components/AppBar/core/index.js.map +1 -1
- package/dist/components/Button/Button/index.js +61 -48
- package/dist/components/Button/Button/index.js.map +1 -1
- package/dist/components/Button/ButtonGroups/ButtonGroupContext/index.js.map +1 -1
- package/dist/components/Button/IconButton/index.js.map +1 -1
- package/dist/components/Button/LinkButton/index.js +61 -48
- package/dist/components/Button/LinkButton/index.js.map +1 -1
- package/dist/components/Button/LinkIconButton/index.js.map +1 -1
- package/dist/components/Button/SplitButton/SplitButtonContext/index.js.map +1 -1
- package/dist/components/Button/SplitButton/SplitButtonPrimary/index.js.map +1 -1
- package/dist/components/Button/ToggleButton/index.js +69 -54
- package/dist/components/Button/ToggleButton/index.js.map +1 -1
- package/dist/components/Button/ToggleIconButton/index.js.map +1 -1
- package/dist/components/Calendar/Calendar/index.js +22 -12
- package/dist/components/Calendar/Calendar/index.js.map +1 -1
- package/dist/components/Calendar/CalendarMonthMenu/index.js +38 -33
- package/dist/components/Calendar/CalendarMonthMenu/index.js.map +1 -1
- package/dist/components/Calendar/CalendarYearMenu/index.js +31 -26
- package/dist/components/Calendar/CalendarYearMenu/index.js.map +1 -1
- package/dist/components/Calendar/RangeCalendar/index.js +25 -15
- package/dist/components/Calendar/RangeCalendar/index.js.map +1 -1
- package/dist/components/Dialog/core/index.js.map +1 -1
- package/dist/components/Disclosure/context/index.js +11 -12
- package/dist/components/Disclosure/context/index.js.map +1 -1
- package/dist/components/Image/index.js.map +1 -1
- package/dist/components/Input/CharacterCount/index.js +18 -10
- package/dist/components/Input/CharacterCount/index.js.map +1 -1
- package/dist/components/Input/DateField/index.js.map +1 -1
- package/dist/components/Input/DatePicker/DatePicker/index.js.map +1 -1
- package/dist/components/Input/DatePicker/DateRangePicker/index.js.map +1 -1
- package/dist/components/Input/Description/index.js +21 -10
- package/dist/components/Input/Description/index.js.map +1 -1
- package/dist/components/Input/Label/index.js +18 -10
- package/dist/components/Input/Label/index.js.map +1 -1
- package/dist/components/Input/Select/Select/index.js.map +1 -1
- package/dist/components/Input/Select/SelectItem/index.js.map +1 -1
- package/dist/components/Input/Select/SelectList/index.js.map +1 -1
- package/dist/components/Input/Select/SelectListSection/index.js +17 -9
- package/dist/components/Input/Select/SelectListSection/index.js.map +1 -1
- package/dist/components/Input/Select/SelectListSectionHeader/index.js +18 -10
- package/dist/components/Input/Select/SelectListSectionHeader/index.js.map +1 -1
- package/dist/components/Input/Slider/RangeSlider/index.js.map +1 -1
- package/dist/components/Input/TextArea/index.js.map +1 -1
- package/dist/components/Input/TimeField/index.js.map +1 -1
- package/dist/components/Input/hooks/index.js +16 -10
- package/dist/components/Input/hooks/index.js.map +1 -1
- package/dist/components/Menu/Menu/index.js +19 -14
- package/dist/components/Menu/Menu/index.js.map +1 -1
- package/dist/components/Menu/MenuItem/index.js +48 -38
- package/dist/components/Menu/MenuItem/index.js.map +1 -1
- package/dist/components/Menu/MenuSection/index.js +18 -10
- package/dist/components/Menu/MenuSection/index.js.map +1 -1
- package/dist/components/Menu/MenuSectionHeader/index.js +18 -10
- package/dist/components/Menu/MenuSectionHeader/index.js.map +1 -1
- package/dist/components/Menu/MenuShortcut/index.js +16 -8
- package/dist/components/Menu/MenuShortcut/index.js.map +1 -1
- package/dist/components/Menu/MenuTrailingText/index.js +16 -8
- package/dist/components/Menu/MenuTrailingText/index.js.map +1 -1
- package/dist/components/Menu/MenuTrigger/index.js +21 -11
- package/dist/components/Menu/MenuTrigger/index.js.map +1 -1
- package/dist/components/Menu/context/index.js.map +1 -1
- package/dist/components/Navigation/NavigationItem/NavigationButton/index.js +30 -21
- package/dist/components/Navigation/NavigationItem/NavigationButton/index.js.map +1 -1
- package/dist/components/Navigation/NavigationItem/NavigationItemIconRenderer/index.js +30 -8
- package/dist/components/Navigation/NavigationItem/NavigationItemIconRenderer/index.js.map +1 -1
- package/dist/components/Navigation/NavigationItem/NavigationLink/index.js +29 -20
- package/dist/components/Navigation/NavigationItem/NavigationLink/index.js.map +1 -1
- package/dist/components/Navigation/SubNavigation/SubNavigation/index.js +69 -56
- package/dist/components/Navigation/SubNavigation/SubNavigation/index.js.map +1 -1
- package/dist/components/Navigation/SubNavigation/SubNavigationTrigger/index.js +48 -29
- package/dist/components/Navigation/SubNavigation/SubNavigationTrigger/index.js.map +1 -1
- package/dist/components/Tooltip/RichTooltip/RichTooltipInfo/RichTooltipSubhead/index.js +17 -9
- package/dist/components/Tooltip/RichTooltip/RichTooltipInfo/RichTooltipSubhead/index.js.map +1 -1
- package/dist/components/Tooltip/RichTooltip/RichTooltipInfo/RichTooltipText/index.js +17 -9
- package/dist/components/Tooltip/RichTooltip/RichTooltipInfo/RichTooltipText/index.js.map +1 -1
- package/dist/components/Tooltip/TooltipTrigger/index.js.map +1 -1
- package/dist/index.js.map +1 -1
- package/dist/src/components/Navigation/NavigationItem/core/navigationItem.d.ts +1 -1
- package/package.json +4 -4
|
@@ -1,16 +1,26 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { t } from "../../../chunks/
|
|
3
|
-
import n from "
|
|
4
|
-
import
|
|
5
|
-
import {
|
|
1
|
+
import { t as e } from "../../../chunks/compiler-runtime";
|
|
2
|
+
import { r as t } from "../../../chunks/core3";
|
|
3
|
+
import { t as n } from "../../../chunks/BaseCalendar";
|
|
4
|
+
import r from "clsx";
|
|
5
|
+
import { jsx as i } from "react/jsx-runtime";
|
|
6
|
+
import { Calendar as a } from "react-aria-components";
|
|
6
7
|
//#region src/components/Calendar/Calendar/Calendar.tsx
|
|
7
|
-
var
|
|
8
|
-
|
|
9
|
-
...s,
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
8
|
+
var o = e(), s = (e) => {
|
|
9
|
+
let s = (0, o.c)(12), c, l, u;
|
|
10
|
+
s[0] === e ? (c = s[1], l = s[2], u = s[3]) : ({weekdayStyle: u, className: c, ...l} = e, s[0] = e, s[1] = c, s[2] = l, s[3] = u);
|
|
11
|
+
let d;
|
|
12
|
+
s[4] === c ? d = s[5] : (d = (e) => r(t, typeof c == "function" ? c(e) : c), s[4] = c, s[5] = d);
|
|
13
|
+
let f;
|
|
14
|
+
s[6] === u ? f = s[7] : (f = /* @__PURE__ */ i(n, { weekdayStyle: u }), s[6] = u, s[7] = f);
|
|
15
|
+
let p;
|
|
16
|
+
return s[8] !== l || s[9] !== d || s[10] !== f ? (p = /* @__PURE__ */ i(a, {
|
|
17
|
+
className: d,
|
|
18
|
+
...l,
|
|
19
|
+
"data-calendar": !0,
|
|
20
|
+
children: f
|
|
21
|
+
}), s[8] = l, s[9] = d, s[10] = f, s[11] = p) : p = s[11], p;
|
|
22
|
+
};
|
|
13
23
|
//#endregion
|
|
14
|
-
export {
|
|
24
|
+
export { s as Calendar };
|
|
15
25
|
|
|
16
26
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[],"sources":["../../../../src/components/Calendar/Calendar/Calendar.tsx"],"sourcesContent":["import clsx from \"clsx\";\nimport { Calendar as AriaCalendar } from \"react-aria-components\";\nimport { BaseCalendar } from \"../BaseCalendar\";\nimport { CalendarBaseStyles, type WeekdayStyle } from \"../core\";\n\nexport const Calendar: React.FC<\n Omit<\n React.ComponentPropsWithRef<typeof AriaCalendar>,\n \"children\" | \"visibleDuration\" | \"pageBehavior\"\n > & {\n weekdayStyle?: WeekdayStyle;\n }\n> = ({ weekdayStyle, className, ...props }) => {\n return (\n <AriaCalendar\n className={(renderProps) =>\n clsx(\n CalendarBaseStyles,\n typeof className === \"function\"\n ? className(renderProps)\n : className\n )\n }\n {...props}\n data-calendar\n >\n <BaseCalendar weekdayStyle={weekdayStyle} />\n </AriaCalendar>\n );\n};\n"],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","names":["weekdayStyle"],"sources":["../../../../src/components/Calendar/Calendar/Calendar.tsx"],"sourcesContent":["import clsx from \"clsx\";\nimport { Calendar as AriaCalendar } from \"react-aria-components\";\nimport { BaseCalendar } from \"../BaseCalendar\";\nimport { CalendarBaseStyles, type WeekdayStyle } from \"../core\";\n\nexport const Calendar: React.FC<\n Omit<\n React.ComponentPropsWithRef<typeof AriaCalendar>,\n \"children\" | \"visibleDuration\" | \"pageBehavior\"\n > & {\n weekdayStyle?: WeekdayStyle;\n }\n> = ({ weekdayStyle, className, ...props }) => {\n return (\n <AriaCalendar\n className={(renderProps) =>\n clsx(\n CalendarBaseStyles,\n typeof className === \"function\"\n ? className(renderProps)\n : className\n )\n }\n {...props}\n data-calendar\n >\n <BaseCalendar weekdayStyle={weekdayStyle} />\n </AriaCalendar>\n );\n};\n"],"mappings":";;;;;;;aAKa,KAOT,MAAA;CAAA,IAAA,KAAA,GAAA,EAAA,EAAA,CAAA,EAAA,GAAA,GAAA,GAAA;CAAA,AAAA,EAAA,OAAA,KAAsC,IAAA,EAAA,IAAA,IAAA,EAAA,IAAA,IAAA,EAAA,OAArC,mCAAA,KAAA,GAAqC,EAAA,KAAA,GAAA,EAAA,KAAA,GAAA,EAAA,KAAA,GAAA,EAAA,KAAA;CAAA,IAAA;CAAA,AAAA,EAAA,OAAA,IASzB,IAAA,EAAA,MANM,KAAA,MACP,EACI,GACA,OAAO,KAAc,aACf,EAAU,CACF,IAFd,CAGJ,GAAC,EAAA,KAAA,GAAA,EAAA,KAAA;CAAA,IAAA;CAAA,AAAA,EAAA,OAAA,IAKuC,IAAA,EAAA,MAA5C,IAAA,kBAAC,GAAD,EAA4B,gBAAY,CAAA,GAAI,EAAA,KAAA,GAAA,EAAA,KAAA;CAAA,IAAA;CACjC,OADiC,EAAA,OAAA,KAAA,EAAA,OAAA,KAAA,EAAA,QAAA,KAZhD,IAAA,kBAAC,GAAD;EACe,WAAA;EAMN,GAED;EACJ,iBAAA;YAEA;CAZS,CAAA,GAaE,EAAA,KAAA,GAAA,EAAA,KAAA,GAAA,EAAA,MAAA,GAAA,EAAA,MAAA,KAAA,IAAA,EAAA,KAbf;AAae"}
|
|
@@ -1,43 +1,48 @@
|
|
|
1
|
-
import { t as e } from "../../../chunks/
|
|
2
|
-
import { t } from "../../../chunks/
|
|
3
|
-
import { n } from "../../../chunks/
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
1
|
+
import { t as e } from "../../../chunks/compiler-runtime";
|
|
2
|
+
import { t } from "../../../chunks/Icon";
|
|
3
|
+
import { t as n } from "../../../chunks/CalendarMenuItem";
|
|
4
|
+
import { n as r } from "../../../chunks/core3";
|
|
5
|
+
import { jsx as i, jsxs as a } from "react/jsx-runtime";
|
|
6
|
+
import { ListBox as o, ListLayout as s, SelectionIndicator as c, Virtualizer as l } from "react-aria-components";
|
|
7
|
+
import { Check as u } from "lucide-react";
|
|
7
8
|
//#region src/components/Calendar/CalendarMonthMenu/CalendarMonthMenu.tsx
|
|
8
|
-
var
|
|
9
|
-
let f =
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
9
|
+
var d = e(), f = (e) => {
|
|
10
|
+
let f = (0, d.c)(9), { onSelection: p, months: m } = e, h = r(), g;
|
|
11
|
+
f[0] === h.focusedDate.month ? g = f[1] : (g = [h.focusedDate.month], f[0] = h.focusedDate.month, f[1] = g);
|
|
12
|
+
let _;
|
|
13
|
+
f[2] !== p || f[3] !== h ? (_ = (e) => {
|
|
14
|
+
let r = h.focusedDate.set({
|
|
15
|
+
month: e.id,
|
|
16
|
+
day: 1
|
|
17
|
+
}), o = r.set({ day: r.calendar.getDaysInMonth(r) });
|
|
18
|
+
return /* @__PURE__ */ a(n, {
|
|
19
|
+
onPress: () => {
|
|
20
|
+
h.setFocusedDate(h.focusedDate.set({ month: e.id })), p();
|
|
21
|
+
},
|
|
22
|
+
isDisabled: (h.maxValue && r.compare(h.maxValue) > 0 || h.minValue && o.compare(h.minValue) < 0) ?? void 0,
|
|
23
|
+
textValue: e.formatted,
|
|
24
|
+
children: [/* @__PURE__ */ i(c, { children: /* @__PURE__ */ i(t, {
|
|
25
|
+
icon: u,
|
|
26
|
+
size: 24,
|
|
27
|
+
"data-selected-icon": !0
|
|
28
|
+
}) }), e.formatted]
|
|
29
|
+
});
|
|
30
|
+
}, f[2] = p, f[3] = h, f[4] = _) : _ = f[4];
|
|
31
|
+
let v;
|
|
32
|
+
return f[5] !== m || f[6] !== g || f[7] !== _ ? (v = /* @__PURE__ */ i(l, {
|
|
33
|
+
layout: s,
|
|
34
|
+
children: /* @__PURE__ */ i(o, {
|
|
13
35
|
"aria-label": "month selection",
|
|
14
36
|
autoFocus: !0,
|
|
15
37
|
"data-menu": !0,
|
|
16
|
-
items:
|
|
38
|
+
items: m,
|
|
17
39
|
selectionMode: "single",
|
|
18
|
-
selectedKeys:
|
|
19
|
-
children:
|
|
20
|
-
let a = f.focusedDate.set({
|
|
21
|
-
month: n.id,
|
|
22
|
-
day: 1
|
|
23
|
-
}), o = a.set({ day: a.calendar.getDaysInMonth(a) });
|
|
24
|
-
return /* @__PURE__ */ i(t, {
|
|
25
|
-
onPress: () => {
|
|
26
|
-
f.setFocusedDate(f.focusedDate.set({ month: n.id })), u();
|
|
27
|
-
},
|
|
28
|
-
isDisabled: (f.maxValue && a.compare(f.maxValue) > 0 || f.minValue && o.compare(f.minValue) < 0) ?? void 0,
|
|
29
|
-
textValue: n.formatted,
|
|
30
|
-
children: [/* @__PURE__ */ r(s, { children: /* @__PURE__ */ r(e, {
|
|
31
|
-
icon: l,
|
|
32
|
-
size: 24,
|
|
33
|
-
"data-selected-icon": !0
|
|
34
|
-
}) }), n.formatted]
|
|
35
|
-
});
|
|
36
|
-
}
|
|
40
|
+
selectedKeys: g,
|
|
41
|
+
children: _
|
|
37
42
|
})
|
|
38
|
-
});
|
|
43
|
+
}), f[5] = m, f[6] = g, f[7] = _, f[8] = v) : v = f[8], v;
|
|
39
44
|
};
|
|
40
45
|
//#endregion
|
|
41
|
-
export {
|
|
46
|
+
export { f as CalendarMonthMenu };
|
|
42
47
|
|
|
43
48
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[],"sources":["../../../../src/components/Calendar/CalendarMonthMenu/CalendarMonthMenu.tsx"],"sourcesContent":["import { Check } from \"lucide-react\";\nimport {\n ListBox,\n ListLayout,\n SelectionIndicator,\n Virtualizer,\n} from \"react-aria-components\";\nimport { Icon } from \"@/components/Icon\";\nimport { CalendarMenuItem } from \"../CalendarMenuItem\";\nimport { type MonthItem, useCalendarState } from \"../core\";\n\nexport const CalendarMonthMenu: React.FC<{\n onSelection: () => void;\n months: MonthItem[];\n}> = ({ onSelection, months }) => {\n const state = useCalendarState();\n\n return (\n <Virtualizer layout={ListLayout}>\n <ListBox\n aria-label=\"month selection\"\n autoFocus\n data-menu\n items={months}\n selectionMode=\"single\"\n selectedKeys={[state.focusedDate.month]}\n >\n {(item) => {\n const nextDate = state.focusedDate.set({\n month: item.id,\n day: 1,\n });\n\n const endOfMonth = nextDate.set({\n day: nextDate.calendar.getDaysInMonth(nextDate),\n });\n\n const monthCompletelyInvalid =\n (state.maxValue &&\n nextDate.compare(state.maxValue) > 0) ||\n (state.minValue &&\n endOfMonth.compare(state.minValue) < 0);\n\n return (\n <CalendarMenuItem\n onPress={() => {\n state.setFocusedDate(\n state.focusedDate.set({ month: item.id })\n );\n onSelection();\n }}\n isDisabled={monthCompletelyInvalid ?? undefined}\n textValue={item.formatted}\n >\n <SelectionIndicator>\n <Icon\n icon={Check}\n size={24}\n data-selected-icon\n />\n </SelectionIndicator>\n {item.formatted}\n </CalendarMenuItem>\n );\n }}\n </ListBox>\n </Virtualizer>\n );\n};\n"],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","names":["Check","ListLayout","months"],"sources":["../../../../src/components/Calendar/CalendarMonthMenu/CalendarMonthMenu.tsx"],"sourcesContent":["import { Check } from \"lucide-react\";\nimport {\n ListBox,\n ListLayout,\n SelectionIndicator,\n Virtualizer,\n} from \"react-aria-components\";\nimport { Icon } from \"@/components/Icon\";\nimport { CalendarMenuItem } from \"../CalendarMenuItem\";\nimport { type MonthItem, useCalendarState } from \"../core\";\n\nexport const CalendarMonthMenu: React.FC<{\n onSelection: () => void;\n months: MonthItem[];\n}> = ({ onSelection, months }) => {\n const state = useCalendarState();\n\n return (\n <Virtualizer layout={ListLayout}>\n <ListBox\n aria-label=\"month selection\"\n autoFocus\n data-menu\n items={months}\n selectionMode=\"single\"\n selectedKeys={[state.focusedDate.month]}\n >\n {(item) => {\n const nextDate = state.focusedDate.set({\n month: item.id,\n day: 1,\n });\n\n const endOfMonth = nextDate.set({\n day: nextDate.calendar.getDaysInMonth(nextDate),\n });\n\n const monthCompletelyInvalid =\n (state.maxValue &&\n nextDate.compare(state.maxValue) > 0) ||\n (state.minValue &&\n endOfMonth.compare(state.minValue) < 0);\n\n return (\n <CalendarMenuItem\n onPress={() => {\n state.setFocusedDate(\n state.focusedDate.set({ month: item.id })\n );\n onSelection();\n }}\n isDisabled={monthCompletelyInvalid ?? undefined}\n textValue={item.formatted}\n >\n <SelectionIndicator>\n <Icon\n icon={Check}\n size={24}\n data-selected-icon\n />\n </SelectionIndicator>\n {item.formatted}\n </CalendarMenuItem>\n );\n }}\n </ListBox>\n </Virtualizer>\n );\n};\n"],"mappings":";;;;;;;;aAWa,KAGR,MAAA;CAAA,IAAA,KAAA,GAAA,EAAA,EAAA,CAAA,CAAA,GAAC,EAAA,gBAAA,cAAA,GACF,IAAc,EAAiB,GAAE;CAAA,AAAA,EAAA,OAAA,EAAA,YAAA,QAUkB,IAAA,EAAA,MAAzB,IAAA,CAAC,EAAK,YAAY,KAAM,GAAC,EAAA,KAAA,EAAA,YAAA,OAAA,EAAA,KAAA;CAAA,IAAA;CAAA,AAAA,EAAA,OAAA,KAAA,EAAA,OAAA,KAEtC,KAAA,MAAA;EACG,IAAA,IAAiB,EAAK,YAAY,IAAK;GAAA,OAC5B,EAAI;GAAG,KACT;EACT,CAAC,GAED,IAAmB,EAAQ,IAAK,EAAA,KACvB,EAAQ,SAAS,eAAgB,CAAQ,EAClD,CAAC;EAM+C,OAG5C,kBAAC,GAAD;GACa,eAAA;IAIL,AAHA,EAAK,eACD,EAAK,YAAY,IAAK,EAAA,OAAS,EAAI,GAAI,CAAC,CAC5C,GACA,EAAY;GAAC;GAEL,aAbf,EAAK,YACF,EAAQ,QAAS,EAAK,QAAS,IAAI,KACtC,EAAK,YACF,EAAU,QAAS,EAAK,QAAS,IAAI,MAUzB,KAAA;GACD,WAAA,EAAI;aARnB,CAUI,kBAAC,GAAD,EAAA,UACI,kBAAC,GAAD;IACUA,MAAA;IACA,MAAA;IACN,sBAAA;GAAkB,CAAA,EAJP,CAAA,GAOlB,EAAI,SAjBQ;;CAkBE,GAE1B,EAAA,KAAA,GAAA,EAAA,KAAA,GAAA,EAAA,KAAA,KAAA,IAAA,EAAA;CAAA,IAAA;CAEK,OAFL,EAAA,OAAA,KAAA,EAAA,OAAA,KAAA,EAAA,OAAA,KA9CT,IAAA,kBAAC,GAAD;EAAqBC,QAAA;YACjB,kBAAC,GAAD;GACe,cAAA;GACX,WAAA;GACA,aAAA;GACOC,OAAA;GACO,eAAA;GACA,cAAA;aAEb;EARG,CAAA;CADA,CAAA,GAgDE,EAAA,KAAA,GAAA,EAAA,KAAA,GAAA,EAAA,KAAA,GAAA,EAAA,KAAA,KAAA,IAAA,EAAA,IAhDd;AAgDc"}
|
|
@@ -1,36 +1,41 @@
|
|
|
1
|
-
import { t as e } from "../../../chunks/
|
|
2
|
-
import { t } from "../../../chunks/
|
|
3
|
-
import { n } from "../../../chunks/
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
1
|
+
import { t as e } from "../../../chunks/compiler-runtime";
|
|
2
|
+
import { t } from "../../../chunks/Icon";
|
|
3
|
+
import { t as n } from "../../../chunks/CalendarMenuItem";
|
|
4
|
+
import { n as r } from "../../../chunks/core3";
|
|
5
|
+
import { jsx as i, jsxs as a } from "react/jsx-runtime";
|
|
6
|
+
import { ListBox as o, ListLayout as s, SelectionIndicator as c, Virtualizer as l } from "react-aria-components";
|
|
7
|
+
import { Check as u } from "lucide-react";
|
|
7
8
|
//#region src/components/Calendar/CalendarYearMenu/CalendarYearMenu.tsx
|
|
8
|
-
var
|
|
9
|
-
let f =
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
9
|
+
var d = e(), f = (e) => {
|
|
10
|
+
let f = (0, d.c)(9), { onSelection: p, years: m } = e, h = r(), g;
|
|
11
|
+
f[0] === h.focusedDate.year ? g = f[1] : (g = [h.focusedDate.year], f[0] = h.focusedDate.year, f[1] = g);
|
|
12
|
+
let _;
|
|
13
|
+
f[2] !== p || f[3] !== h ? (_ = (e) => /* @__PURE__ */ a(n, {
|
|
14
|
+
onPress: () => {
|
|
15
|
+
h.setFocusedDate(h.focusedDate.set({ year: e.id })), p();
|
|
16
|
+
},
|
|
17
|
+
textValue: e.formatted,
|
|
18
|
+
children: [/* @__PURE__ */ i(c, { children: /* @__PURE__ */ i(t, {
|
|
19
|
+
icon: u,
|
|
20
|
+
size: 24,
|
|
21
|
+
"data-selected-icon": !0
|
|
22
|
+
}) }), e.formatted]
|
|
23
|
+
}), f[2] = p, f[3] = h, f[4] = _) : _ = f[4];
|
|
24
|
+
let v;
|
|
25
|
+
return f[5] !== g || f[6] !== _ || f[7] !== m ? (v = /* @__PURE__ */ i(l, {
|
|
26
|
+
layout: s,
|
|
27
|
+
children: /* @__PURE__ */ i(o, {
|
|
13
28
|
"aria-label": "year selection",
|
|
14
29
|
autoFocus: !0,
|
|
15
30
|
"data-menu": !0,
|
|
16
|
-
items:
|
|
31
|
+
items: m,
|
|
17
32
|
selectionMode: "single",
|
|
18
|
-
selectedKeys:
|
|
19
|
-
children:
|
|
20
|
-
onPress: () => {
|
|
21
|
-
f.setFocusedDate(f.focusedDate.set({ year: n.id })), u();
|
|
22
|
-
},
|
|
23
|
-
textValue: n.formatted,
|
|
24
|
-
children: [/* @__PURE__ */ r(s, { children: /* @__PURE__ */ r(e, {
|
|
25
|
-
icon: l,
|
|
26
|
-
size: 24,
|
|
27
|
-
"data-selected-icon": !0
|
|
28
|
-
}) }), n.formatted]
|
|
29
|
-
})
|
|
33
|
+
selectedKeys: g,
|
|
34
|
+
children: _
|
|
30
35
|
})
|
|
31
|
-
});
|
|
36
|
+
}), f[5] = g, f[6] = _, f[7] = m, f[8] = v) : v = f[8], v;
|
|
32
37
|
};
|
|
33
38
|
//#endregion
|
|
34
|
-
export {
|
|
39
|
+
export { f as CalendarYearMenu };
|
|
35
40
|
|
|
36
41
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[],"sources":["../../../../src/components/Calendar/CalendarYearMenu/CalendarYearMenu.tsx"],"sourcesContent":["import { Check } from \"lucide-react\";\nimport {\n ListBox,\n ListLayout,\n SelectionIndicator,\n Virtualizer,\n} from \"react-aria-components\";\n\nimport { Icon } from \"@/components/Icon\";\nimport { CalendarMenuItem } from \"../CalendarMenuItem\";\nimport { useCalendarState, type YearItem } from \"../core\";\n\nexport const CalendarYearMenu: React.FC<{\n onSelection: () => void;\n years: YearItem[];\n}> = ({ onSelection, years }) => {\n const state = useCalendarState();\n\n return (\n <Virtualizer layout={ListLayout}>\n <ListBox\n aria-label=\"year selection\"\n autoFocus\n data-menu\n items={years}\n selectionMode=\"single\"\n selectedKeys={[state.focusedDate.year]}\n >\n {(item) => (\n <CalendarMenuItem\n onPress={() => {\n state.setFocusedDate(\n state.focusedDate.set({ year: item.id })\n );\n onSelection();\n }}\n textValue={item.formatted}\n >\n <SelectionIndicator>\n <Icon icon={Check} size={24} data-selected-icon />\n </SelectionIndicator>\n\n {item.formatted}\n </CalendarMenuItem>\n )}\n </ListBox>\n </Virtualizer>\n );\n};\n"],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","names":["Check","ListLayout","years"],"sources":["../../../../src/components/Calendar/CalendarYearMenu/CalendarYearMenu.tsx"],"sourcesContent":["import { Check } from \"lucide-react\";\nimport {\n ListBox,\n ListLayout,\n SelectionIndicator,\n Virtualizer,\n} from \"react-aria-components\";\n\nimport { Icon } from \"@/components/Icon\";\nimport { CalendarMenuItem } from \"../CalendarMenuItem\";\nimport { useCalendarState, type YearItem } from \"../core\";\n\nexport const CalendarYearMenu: React.FC<{\n onSelection: () => void;\n years: YearItem[];\n}> = ({ onSelection, years }) => {\n const state = useCalendarState();\n\n return (\n <Virtualizer layout={ListLayout}>\n <ListBox\n aria-label=\"year selection\"\n autoFocus\n data-menu\n items={years}\n selectionMode=\"single\"\n selectedKeys={[state.focusedDate.year]}\n >\n {(item) => (\n <CalendarMenuItem\n onPress={() => {\n state.setFocusedDate(\n state.focusedDate.set({ year: item.id })\n );\n onSelection();\n }}\n textValue={item.formatted}\n >\n <SelectionIndicator>\n <Icon icon={Check} size={24} data-selected-icon />\n </SelectionIndicator>\n\n {item.formatted}\n </CalendarMenuItem>\n )}\n </ListBox>\n </Virtualizer>\n );\n};\n"],"mappings":";;;;;;;;aAYa,KAGR,MAAA;CAAA,IAAA,KAAA,GAAA,EAAA,EAAA,CAAA,CAAA,GAAC,EAAA,gBAAA,aAAA,GACF,IAAc,EAAiB,GAAE;CAAA,AAAA,EAAA,OAAA,EAAA,YAAA,OAUiB,IAAA,EAAA,MAAxB,IAAA,CAAC,EAAK,YAAY,IAAK,GAAC,EAAA,KAAA,EAAA,YAAA,MAAA,EAAA,KAAA;CAAA,IAAA;CAAA,AAAA,EAAA,OAAA,KAAA,EAAA,OAAA,KAErC,KAAA,MACG,kBAAC,GAAD;EACa,eAAA;GAIL,AAHA,EAAK,eACD,EAAK,YAAY,IAAK,EAAA,MAAQ,EAAI,GAAI,CAAC,CAC3C,GACA,EAAY;EAAC;EAEN,WAAA,EAAI;YAPnB,CASI,kBAAC,GAAD,EAAA,UACI,kBAAC,GAAD;GAAYA,MAAA;GAAa,MAAA;GAAI,sBAAA;EAAkB,CAAA,EADhC,CAAA,GAIlB,EAAI,SAbQ;KAepB,EAAA,KAAA,GAAA,EAAA,KAAA,GAAA,EAAA,KAAA,KAAA,IAAA,EAAA;CAAA,IAAA;CAEK,OAFL,EAAA,OAAA,KAAA,EAAA,OAAA,KAAA,EAAA,OAAA,KAzBT,IAAA,kBAAC,GAAD;EAAqBC,QAAA;YACjB,kBAAC,GAAD;GACe,cAAA;GACX,WAAA;GACA,aAAA;GACOC,OAAA;GACO,eAAA;GACA,cAAA;aAEb;EARG,CAAA;CADA,CAAA,GA2BE,EAAA,KAAA,GAAA,EAAA,KAAA,GAAA,EAAA,KAAA,GAAA,EAAA,KAAA,KAAA,IAAA,EAAA,IA3Bd;AA2Bc"}
|
|
@@ -1,20 +1,30 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { t } from "../../../chunks/
|
|
3
|
-
import n from "
|
|
4
|
-
import
|
|
5
|
-
import {
|
|
1
|
+
import { t as e } from "../../../chunks/compiler-runtime";
|
|
2
|
+
import { r as t } from "../../../chunks/core3";
|
|
3
|
+
import { t as n } from "../../../chunks/BaseCalendar";
|
|
4
|
+
import r from "clsx";
|
|
5
|
+
import { jsx as i } from "react/jsx-runtime";
|
|
6
|
+
import { RangeCalendar as a } from "react-aria-components";
|
|
6
7
|
//#region src/components/Calendar/RangeCalendar/RangeCalendar.tsx
|
|
7
|
-
var
|
|
8
|
-
|
|
9
|
-
...s,
|
|
10
|
-
|
|
11
|
-
"
|
|
12
|
-
|
|
13
|
-
|
|
8
|
+
var o = e(), s = (e) => {
|
|
9
|
+
let s = (0, o.c)(12), c, l, u;
|
|
10
|
+
s[0] === e ? (c = s[1], l = s[2], u = s[3]) : ({weekdayStyle: u, className: c, ...l} = e, s[0] = e, s[1] = c, s[2] = l, s[3] = u);
|
|
11
|
+
let d;
|
|
12
|
+
s[4] === c ? d = s[5] : (d = (e) => r(t, typeof c == "function" ? c(e) : c), s[4] = c, s[5] = d);
|
|
13
|
+
let f;
|
|
14
|
+
s[6] === u ? f = s[7] : (f = /* @__PURE__ */ i(n, {
|
|
15
|
+
weekdayStyle: u,
|
|
14
16
|
isRangeCalendar: !0
|
|
15
|
-
})
|
|
16
|
-
|
|
17
|
+
}), s[6] = u, s[7] = f);
|
|
18
|
+
let p;
|
|
19
|
+
return s[8] !== l || s[9] !== d || s[10] !== f ? (p = /* @__PURE__ */ i(a, {
|
|
20
|
+
className: d,
|
|
21
|
+
...l,
|
|
22
|
+
"data-calendar": !0,
|
|
23
|
+
"data-range-calendar": !0,
|
|
24
|
+
children: f
|
|
25
|
+
}), s[8] = l, s[9] = d, s[10] = f, s[11] = p) : p = s[11], p;
|
|
26
|
+
};
|
|
17
27
|
//#endregion
|
|
18
|
-
export {
|
|
28
|
+
export { s as RangeCalendar };
|
|
19
29
|
|
|
20
30
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[],"sources":["../../../../src/components/Calendar/RangeCalendar/RangeCalendar.tsx"],"sourcesContent":["import clsx from \"clsx\";\nimport { RangeCalendar as AriaRangeCalendar } from \"react-aria-components\";\nimport { BaseCalendar } from \"../BaseCalendar\";\nimport { CalendarBaseStyles, type WeekdayStyle } from \"../core\";\n\nexport const RangeCalendar: React.FC<\n Omit<\n React.ComponentPropsWithRef<typeof AriaRangeCalendar>,\n \"children\" | \"visibleDuration\" | \"pageBehavior\"\n > & {\n weekdayStyle?: WeekdayStyle;\n }\n> = ({ weekdayStyle, className, ...props }) => {\n return (\n <AriaRangeCalendar\n className={(renderProps) =>\n clsx(\n CalendarBaseStyles,\n typeof className === \"function\"\n ? className(renderProps)\n : className\n )\n }\n {...props}\n data-calendar\n data-range-calendar\n >\n <BaseCalendar weekdayStyle={weekdayStyle} isRangeCalendar />\n </AriaRangeCalendar>\n );\n};\n"],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","names":["weekdayStyle"],"sources":["../../../../src/components/Calendar/RangeCalendar/RangeCalendar.tsx"],"sourcesContent":["import clsx from \"clsx\";\nimport { RangeCalendar as AriaRangeCalendar } from \"react-aria-components\";\nimport { BaseCalendar } from \"../BaseCalendar\";\nimport { CalendarBaseStyles, type WeekdayStyle } from \"../core\";\n\nexport const RangeCalendar: React.FC<\n Omit<\n React.ComponentPropsWithRef<typeof AriaRangeCalendar>,\n \"children\" | \"visibleDuration\" | \"pageBehavior\"\n > & {\n weekdayStyle?: WeekdayStyle;\n }\n> = ({ weekdayStyle, className, ...props }) => {\n return (\n <AriaRangeCalendar\n className={(renderProps) =>\n clsx(\n CalendarBaseStyles,\n typeof className === \"function\"\n ? className(renderProps)\n : className\n )\n }\n {...props}\n data-calendar\n data-range-calendar\n >\n <BaseCalendar weekdayStyle={weekdayStyle} isRangeCalendar />\n </AriaRangeCalendar>\n );\n};\n"],"mappings":";;;;;;;aAKa,KAOT,MAAA;CAAA,IAAA,KAAA,GAAA,EAAA,EAAA,CAAA,EAAA,GAAA,GAAA,GAAA;CAAA,AAAA,EAAA,OAAA,KAAsC,IAAA,EAAA,IAAA,IAAA,EAAA,IAAA,IAAA,EAAA,OAArC,mCAAA,KAAA,GAAqC,EAAA,KAAA,GAAA,EAAA,KAAA,GAAA,EAAA,KAAA,GAAA,EAAA,KAAA;CAAA,IAAA;CAAA,AAAA,EAAA,OAAA,IASzB,IAAA,EAAA,MANM,KAAA,MACP,EACI,GACA,OAAO,KAAc,aACf,EAAU,CACF,IAFd,CAGJ,GAAC,EAAA,KAAA,GAAA,EAAA,KAAA;CAAA,IAAA;CAAA,AAAA,EAAA,OAAA,IAMuD,IAAA,EAAA,MAA5D,IAAA,kBAAC,GAAD;EAA4B;EAAc,iBAAA;CAAe,CAAA,GAAG,EAAA,KAAA,GAAA,EAAA,KAAA;CAAA,IAAA;CAC5C,OAD4C,EAAA,OAAA,KAAA,EAAA,OAAA,KAAA,EAAA,QAAA,KAbhE,IAAA,kBAAC,GAAD;EACe,WAAA;EAMN,GAED;EACJ,iBAAA;EACA,uBAAA;YAEA;CAbc,CAAA,GAcE,EAAA,KAAA,GAAA,EAAA,KAAA,GAAA,EAAA,MAAA,GAAA,EAAA,MAAA,KAAA,IAAA,EAAA,KAdpB;AAcoB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[],"sources":["../../../../src/components/Dialog/core/context.ts","../../../../src/components/Dialog/core/typography.ts"],"sourcesContent":["import { createContext, useContext } from \"react\";\n\nexport const DialogContext = createContext<boolean | null>(null);\n\nexport function useInDialog() {\n return useContext(DialogContext) === true;\n}\n","import { typography } from \"@/utils/typography\";\n\nexport const DialogIconSize = 24;\nexport const DialogHeadlineTypography = typography.headlineSmall;\nexport const DialogBodyTypography = typography.bodyMedium;\n"],"mappings":";;;AAEA,IAAa,IAAgB,EAA8B,IAAI;AAE/D,
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../../../../src/components/Dialog/core/context.ts","../../../../src/components/Dialog/core/typography.ts"],"sourcesContent":["import { createContext, useContext } from \"react\";\n\nexport const DialogContext = createContext<boolean | null>(null);\n\nexport function useInDialog() {\n return useContext(DialogContext) === true;\n}\n","import { typography } from \"@/utils/typography\";\n\nexport const DialogIconSize = 24;\nexport const DialogHeadlineTypography = typography.headlineSmall;\nexport const DialogBodyTypography = typography.bodyMedium;\n"],"mappings":";;;AAEA,IAAa,IAAgB,EAA8B,IAAI;AAE/D,SAAO,IAAA;CAAA,OACI,EAAW,CAAa,MAAM;AAAI;;;ACH7C,IAAa,IAAiB,IACjB,IAA2B,EAAW,eACtC,IAAuB,EAAW"}
|
|
@@ -1,17 +1,16 @@
|
|
|
1
|
-
import { t as e } from "../../../chunks/
|
|
2
|
-
import {
|
|
1
|
+
import { t as e } from "../../../chunks/compiler-runtime";
|
|
2
|
+
import { t } from "../../../chunks/base";
|
|
3
|
+
import { createContext as n, useContext as r } from "react";
|
|
3
4
|
//#region src/components/Disclosure/context/context.ts
|
|
4
|
-
var
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
panel: i ?? o ?? e.bodyLarge
|
|
12
|
-
};
|
|
5
|
+
var i = n({}), a = e();
|
|
6
|
+
function o(e) {
|
|
7
|
+
let n = (0, a.c)(3), { label: o, panel: s } = e, { label: c, panel: l } = r(i), u = o ?? c ?? t.titleMediumEmphasized, d = s ?? l ?? t.bodyLarge, f;
|
|
8
|
+
return n[0] !== u || n[1] !== d ? (f = {
|
|
9
|
+
label: u,
|
|
10
|
+
panel: d
|
|
11
|
+
}, n[0] = u, n[1] = d, n[2] = f) : f = n[2], f;
|
|
13
12
|
}
|
|
14
13
|
//#endregion
|
|
15
|
-
export {
|
|
14
|
+
export { i as DisclosureTypographyContext, o as useDisclosureTypographyContext };
|
|
16
15
|
|
|
17
16
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[],"sources":["../../../../src/components/Disclosure/context/context.ts","../../../../src/components/Disclosure/context/useDisclosureTypographyContext.ts"],"sourcesContent":["import { createContext } from \"react\";\nimport type { Typography } from \"@/utils\";\n\nexport type DisclosureTypographyContextValue = {\n label?: Typography;\n panel?: Typography;\n};\n\nexport const DisclosureTypographyContext =\n createContext<DisclosureTypographyContextValue>({});\n","import { useContext } from \"react\";\nimport { type Typography, typography } from \"@/utils\";\nimport { DisclosureTypographyContext } from \"./context\";\n\nexport function useDisclosureTypographyContext({\n label,\n panel,\n}: {\n label?: Typography;\n panel?: Typography;\n}) {\n const { label: groupLabel, panel: groupPanel } = useContext(\n DisclosureTypographyContext\n );\n\n const labelTypography =\n label ?? groupLabel ?? typography.titleMediumEmphasized;\n const panelTypography = panel ?? groupPanel ?? typography.bodyLarge;\n\n return { label: labelTypography, panel: panelTypography };\n}\n"],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../../../../src/components/Disclosure/context/context.ts","../../../../src/components/Disclosure/context/useDisclosureTypographyContext.ts"],"sourcesContent":["import { createContext } from \"react\";\nimport type { Typography } from \"@/utils\";\n\nexport type DisclosureTypographyContextValue = {\n label?: Typography;\n panel?: Typography;\n};\n\nexport const DisclosureTypographyContext =\n createContext<DisclosureTypographyContextValue>({});\n","import { useContext } from \"react\";\nimport { type Typography, typography } from \"@/utils\";\nimport { DisclosureTypographyContext } from \"./context\";\n\nexport function useDisclosureTypographyContext({\n label,\n panel,\n}: {\n label?: Typography;\n panel?: Typography;\n}) {\n const { label: groupLabel, panel: groupPanel } = useContext(\n DisclosureTypographyContext\n );\n\n const labelTypography =\n label ?? groupLabel ?? typography.titleMediumEmphasized;\n const panelTypography = panel ?? groupPanel ?? typography.bodyLarge;\n\n return { label: labelTypography, panel: panelTypography };\n}\n"],"mappings":";;;;AAQA,IAAa,IACT,EAAgD,CAAC,CAAC;ACLtD,SAAO,EAAA,GAAA;CAAA,IAAA,KAAA,GAAA,EAAA,EAAA,CAAA,CAAA,GAAwC,EAAA,UAAA,aAAA,GAO3C,EAAA,OAAA,GAAA,OAAA,MAAiD,EAC7C,CACJ,GAEA,IACI,KAAA,KAAuB,EAAU,uBACrC,IAAwB,KAAA,KAAuB,EAAU,WAAW;CAEX,OAFW,EAAA,OAAA,KAAA,EAAA,OAAA,KAE7D,IAAA;EAAA,OAAS;EAAe,OAAS;CAAgB,GAAC,EAAA,KAAA,GAAA,EAAA,KAAA,GAAA,EAAA,KAAA,KAAA,IAAA,EAAA,IAAlD;AAAkD"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[],"sources":["../../../src/components/Image/Image.tsx"],"sourcesContent":["import type { ImageProps, Preset } from \"./types\";\n\nconst IMAGE_SIZE_PRESETS: Record<Preset, string> = {\n default: \"(max-width: 50rem) 100vw, 50rem\", // \"sane\" default\n thumbnail: \"10rem\",\n normal: \"(max-width: 60rem) 100vw, 60rem\",\n wide: \"(max-width: 80rem) 100vw, 80rem\",\n full: \"100vw\",\n grid3Col: \"(max-width: 40rem) 100vw, (max-width: 80rem) 50vw, 30rem\",\n};\n\nexport const Image: React.FC<ImageProps> = ({\n preset = \"default\",\n thumbnail,\n small,\n medium,\n large,\n extraLarge,\n alt = \"\",\n sizes,\n ...props\n}) => {\n const defaultSrc = small;\n const finalSizes = sizes || IMAGE_SIZE_PRESETS[preset];\n\n const srcSet = [\n `${thumbnail} 150w`,\n `${small} 320w`,\n `${medium} 640w`,\n `${large} 1280w`,\n `${extraLarge} 1920w`,\n ].join(\", \");\n\n return (\n <img\n src={defaultSrc}\n srcSet={srcSet}\n sizes={finalSizes}\n alt={alt}\n {...props}\n />\n );\n};\n"],"mappings":";;AAEA,IAAM,IAA6C;CAC/C,SAAS;CACT,WAAW;CACX,QAAQ;CACR,MAAM;CACN,MAAM;CACN,UAAU;AACd,GAEa,KAA+B,EACxC,YAAS,WACT,cACA,UACA,WACA,UACA,eACA,SAAM,IACN,UACA,GAAG,QACD;CACF,IAAM,IAAa,GACb,IAAa,KAAS,EAAmB;CAU/C,OACI,kBAAC,OAAD;EACI,KAAK;EACG,QAXD;GACX,GAAG,
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../../../src/components/Image/Image.tsx"],"sourcesContent":["import type { ImageProps, Preset } from \"./types\";\n\nconst IMAGE_SIZE_PRESETS: Record<Preset, string> = {\n default: \"(max-width: 50rem) 100vw, 50rem\", // \"sane\" default\n thumbnail: \"10rem\",\n normal: \"(max-width: 60rem) 100vw, 60rem\",\n wide: \"(max-width: 80rem) 100vw, 80rem\",\n full: \"100vw\",\n grid3Col: \"(max-width: 40rem) 100vw, (max-width: 80rem) 50vw, 30rem\",\n};\n\nexport const Image: React.FC<ImageProps> = ({\n preset = \"default\",\n thumbnail,\n small,\n medium,\n large,\n extraLarge,\n alt = \"\",\n sizes,\n ...props\n}) => {\n const defaultSrc = small;\n const finalSizes = sizes || IMAGE_SIZE_PRESETS[preset];\n\n const srcSet = [\n `${thumbnail} 150w`,\n `${small} 320w`,\n `${medium} 640w`,\n `${large} 1280w`,\n `${extraLarge} 1920w`,\n ].join(\", \");\n\n return (\n <img\n src={defaultSrc}\n srcSet={srcSet}\n sizes={finalSizes}\n alt={alt}\n {...props}\n />\n );\n};\n"],"mappings":";;AAEA,IAAM,IAA6C;CAC/C,SAAS;CACT,WAAW;CACX,QAAQ;CACR,MAAM;CACN,MAAM;CACN,UAAU;AACd,GAEa,KAA+B,EACxC,YAAS,WACT,cACA,UACA,WACA,UACA,eACA,SAAM,IACN,UACA,GAAG,QACD;CACF,IAAM,IAAa,GACb,IAAa,KAAS,EAAmB;CAU/C,OACI,kBAAC,OAAD;EACI,KAAK;EACG,QAXD;GACX,GAAG,EAAS;GACZ,GAAG,EAAK;GACR,GAAG,EAAM;GACT,GAAG,EAAK;GACR,GAAG,EAAU;EAAQ,CACxB,CAAC,KAAK,IAKS;EACR,OAAO;EACF;EACL,GAAI;CAAM,CAAA;AAGtB"}
|
|
@@ -1,14 +1,22 @@
|
|
|
1
|
-
import { t as e } from "../../../chunks/
|
|
2
|
-
import { t } from "../../../chunks/
|
|
3
|
-
import n from "
|
|
4
|
-
import
|
|
1
|
+
import { t as e } from "../../../chunks/compiler-runtime";
|
|
2
|
+
import { t } from "../../../chunks/base";
|
|
3
|
+
import { t as n } from "../../../chunks/core4";
|
|
4
|
+
import r from "clsx";
|
|
5
|
+
import { jsxs as i } from "react/jsx-runtime";
|
|
5
6
|
//#region src/components/Input/CharacterCount/CharacterCount.tsx
|
|
6
|
-
var
|
|
7
|
-
|
|
8
|
-
...o,
|
|
9
|
-
|
|
10
|
-
|
|
7
|
+
var a = e(), o = (e) => {
|
|
8
|
+
let o = (0, a.c)(9), s, c, l;
|
|
9
|
+
o[0] === e ? (s = o[1], c = o[2], l = o[3]) : ({count: s, maxLength: c, ...l} = e, o[0] = e, o[1] = s, o[2] = c, o[3] = l);
|
|
10
|
+
let u;
|
|
11
|
+
o[4] === Symbol.for("react.memo_cache_sentinel") ? (u = r(n, t.labelMedium), o[4] = u) : u = o[4];
|
|
12
|
+
let d = c !== void 0 && `/${c}`, f;
|
|
13
|
+
return o[5] !== s || o[6] !== l || o[7] !== d ? (f = /* @__PURE__ */ i("span", {
|
|
14
|
+
className: u,
|
|
15
|
+
...l,
|
|
16
|
+
children: [s, d]
|
|
17
|
+
}), o[5] = s, o[6] = l, o[7] = d, o[8] = f) : f = o[8], f;
|
|
18
|
+
};
|
|
11
19
|
//#endregion
|
|
12
|
-
export {
|
|
20
|
+
export { o as CharacterCount };
|
|
13
21
|
|
|
14
22
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[],"sources":["../../../../src/components/Input/CharacterCount/CharacterCount.tsx"],"sourcesContent":["import clsx from \"clsx\";\nimport { type RefProp, typography } from \"@/utils\";\nimport { CharacterCountStyles } from \"../core\";\n\nexport const CharacterCount: React.FC<\n {\n count: number;\n maxLength?: number;\n } & RefProp<\"span\">\n> = ({ count, maxLength, ...props }) => {\n return (\n <span\n className={clsx(CharacterCountStyles, typography.labelMedium)}\n {...props}\n >\n {count}\n {maxLength !== undefined && `/${maxLength}`}\n </span>\n );\n};\n"],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","names":["count"],"sources":["../../../../src/components/Input/CharacterCount/CharacterCount.tsx"],"sourcesContent":["import clsx from \"clsx\";\nimport { type RefProp, typography } from \"@/utils\";\nimport { CharacterCountStyles } from \"../core\";\n\nexport const CharacterCount: React.FC<\n {\n count: number;\n maxLength?: number;\n } & RefProp<\"span\">\n> = ({ count, maxLength, ...props }) => {\n return (\n <span\n className={clsx(CharacterCountStyles, typography.labelMedium)}\n {...props}\n >\n {count}\n {maxLength !== undefined && `/${maxLength}`}\n </span>\n );\n};\n"],"mappings":";;;;;;aAIa,KAKT,MAAA;CAAA,IAAA,KAAA,GAAA,EAAA,EAAA,CAAA,CAAA,GAAA,GAAA,GAAA;CAAA,AAAA,EAAA,OAAA,KAA+B,IAAA,EAAA,IAAA,IAAA,EAAA,IAAA,IAAA,EAAA,OAA9B,4BAAA,KAAA,GAA8B,EAAA,KAAA,GAAA,EAAA,KAAA,GAAA,EAAA,KAAA,GAAA,EAAA,KAAA;CAAA,IAAA;CAAA,AAAA,EAAA,OAAA,OAAA,IAAA,2BAAA,KAGZ,IAAA,EAAK,GAAsB,EAAU,WAAY,GAAC,EAAA,KAAA,KAAA,IAAA,EAAA;CAI5D,IAAA,IAAA,MAAc,KAAA,KAAd,IAA+B,KAAW;CACxC,OADwC,EAAA,OAAA,KAAA,EAAA,OAAA,KAAA,EAAA,OAAA,KAL/C,IAAA,kBAAA,QAAA;EACe,WAAA;EAAkD,GACzD;YAFR,CAIK,GACA,CACE;KAAA,EAAA,KAAA,GAAA,EAAA,KAAA,GAAA,EAAA,KAAA,GAAA,EAAA,KAAA,KAAA,IAAA,EAAA,IANP;AAMO"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[],"sources":["../../../../src/components/Input/DateField/DateField.tsx"],"sourcesContent":["import clsx from \"clsx\";\nimport {\n DateField as AriaDateField,\n DateInput,\n DateSegment,\n type DateValue,\n} from \"react-aria-components\";\nimport { typography } from \"@/utils\";\nimport {\n Colors,\n DateInputStyles,\n DateSegmentStyles,\n EditorInputStyles,\n EditorStyles,\n InputGroupStyles,\n SupportingTextStyles,\n UnsetStyles,\n} from \"../core\";\nimport { Description } from \"../Description\";\nimport { FieldError } from \"../FieldError\";\nimport { Label } from \"../Label\";\nimport type { DateFieldProps } from \"./types\";\n\nexport const DateField = <T extends DateValue>({\n label,\n description,\n errorMessage,\n showDescriptionOnInvalid = false,\n className,\n ref,\n ...props\n}: DateFieldProps<T>) => {\n return (\n <AriaDateField\n className={(renderProps) =>\n clsx(\n Colors,\n InputGroupStyles,\n typeof className === \"function\"\n ? className(renderProps)\n : className\n )\n }\n {...props}\n >\n {({ isInvalid }) => {\n const showDescription =\n description &&\n (!isInvalid || (isInvalid && showDescriptionOnInvalid));\n\n return (\n <>\n {label && <Label>{label}</Label>}\n\n <DateInput\n ref={ref}\n className={clsx(\n UnsetStyles,\n EditorStyles,\n EditorInputStyles,\n typography.bodyLarge,\n DateInputStyles\n )}\n data-date-input={true}\n >\n {(segment) => (\n <DateSegment\n className={clsx(\n DateSegmentStyles,\n typography.bodyLarge\n )}\n segment={segment}\n />\n )}\n </DateInput>\n\n {showDescription && (\n <Description className={clsx(SupportingTextStyles)}>\n {description}\n </Description>\n )}\n <FieldError className={clsx(SupportingTextStyles)}>\n {errorMessage}\n </FieldError>\n </>\n );\n }}\n </AriaDateField>\n );\n};\n"],"mappings":";;;;;;;;;AAuBA,IAAa,KAAkC,EAC3C,UACA,gBACA,iBACA,8BAA2B,IAC3B,cACA,QACA,GAAG,QAGC,kBAAC,GAAD;CACI,YAAY,MACR,EACI,GACA,GACA,OAAO,KAAc,aACf,EAAU,CAAW,IACrB,CACV;CAEJ,GAAI;YAEF,EAAE,mBAAgB;EAChB,IAAM,IACF,MACC,CAAC,KAAc,KAAa;EAEjC,OACI,kBAAA,GAAA,EAAA,UAAA;GACK,KAAS,kBAAC,GAAD,EAAA,UAAQ,EAAa,CAAA;GAE/B,kBAAC,GAAD;IACS;IACL,WAAW,EACP,GACA,GACA,GACA,EAAW,WACX,CACJ;IACA,mBAAiB;eAEf,MACE,kBAAC,GAAD;KACI,WAAW,EACP,GACA,EAAW,SACf;KACS;
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../../../../src/components/Input/DateField/DateField.tsx"],"sourcesContent":["import clsx from \"clsx\";\nimport {\n DateField as AriaDateField,\n DateInput,\n DateSegment,\n type DateValue,\n} from \"react-aria-components\";\nimport { typography } from \"@/utils\";\nimport {\n Colors,\n DateInputStyles,\n DateSegmentStyles,\n EditorInputStyles,\n EditorStyles,\n InputGroupStyles,\n SupportingTextStyles,\n UnsetStyles,\n} from \"../core\";\nimport { Description } from \"../Description\";\nimport { FieldError } from \"../FieldError\";\nimport { Label } from \"../Label\";\nimport type { DateFieldProps } from \"./types\";\n\nexport const DateField = <T extends DateValue>({\n label,\n description,\n errorMessage,\n showDescriptionOnInvalid = false,\n className,\n ref,\n ...props\n}: DateFieldProps<T>) => {\n return (\n <AriaDateField\n className={(renderProps) =>\n clsx(\n Colors,\n InputGroupStyles,\n typeof className === \"function\"\n ? className(renderProps)\n : className\n )\n }\n {...props}\n >\n {({ isInvalid }) => {\n const showDescription =\n description &&\n (!isInvalid || (isInvalid && showDescriptionOnInvalid));\n\n return (\n <>\n {label && <Label>{label}</Label>}\n\n <DateInput\n ref={ref}\n className={clsx(\n UnsetStyles,\n EditorStyles,\n EditorInputStyles,\n typography.bodyLarge,\n DateInputStyles\n )}\n data-date-input={true}\n >\n {(segment) => (\n <DateSegment\n className={clsx(\n DateSegmentStyles,\n typography.bodyLarge\n )}\n segment={segment}\n />\n )}\n </DateInput>\n\n {showDescription && (\n <Description className={clsx(SupportingTextStyles)}>\n {description}\n </Description>\n )}\n <FieldError className={clsx(SupportingTextStyles)}>\n {errorMessage}\n </FieldError>\n </>\n );\n }}\n </AriaDateField>\n );\n};\n"],"mappings":";;;;;;;;;AAuBA,IAAa,KAAkC,EAC3C,UACA,gBACA,iBACA,8BAA2B,IAC3B,cACA,QACA,GAAG,QAGC,kBAAC,GAAD;CACI,YAAY,MACR,EACI,GACA,GACA,OAAO,KAAc,aACf,EAAU,CAAW,IACrB,CACV;CAEJ,GAAI;YAEF,EAAE,mBAAgB;EAChB,IAAM,IACF,MACC,CAAC,KAAc,KAAa;EAEjC,OACI,kBAAA,GAAA,EAAA,UAAA;GACK,KAAS,kBAAC,GAAD,EAAA,UAAQ,EAAa,CAAA;GAE/B,kBAAC,GAAD;IACS;IACL,WAAW,EACP,GACA,GACA,GACA,EAAW,WACX,CACJ;IACA,mBAAiB;eAEf,MACE,kBAAC,GAAD;KACI,WAAW,EACP,GACA,EAAW,SACf;KACS;IAAQ,CAAA;GAGlB,CAAA;GAEV,KACG,kBAAC,GAAD;IAAa,WAAW,EAAK,CAAoB;cAC5C;GACQ,CAAA;GAEjB,kBAAC,GAAD;IAAY,WAAW,EAAK,CAAoB;cAC3C;GACO,CAAA;EAChB,EAAA,CAAA;CAER;AACW,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[],"sources":["../../../../../src/components/Input/DatePicker/DatePicker/DatePicker.tsx"],"sourcesContent":["import clsx from \"clsx\";\nimport { CalendarDays } from \"lucide-react\";\nimport {\n DatePicker as AriaDatePicker,\n DateInput,\n DateSegment,\n type DateValue,\n Group,\n} from \"react-aria-components\";\nimport { Calendar } from \"@/components/Calendar\";\nimport { Popover } from \"@/components/Popover\";\nimport { typography } from \"@/utils\";\nimport {\n Colors,\n DateInputStyles,\n DateSegmentStyles,\n EditorInputStyles,\n EditorStyles,\n InputGroupStyles,\n SupportingTextStyles,\n UnsetStyles,\n} from \"../../core\";\nimport { Description } from \"../../Description\";\nimport { FieldError } from \"../../FieldError\";\nimport { InputButton } from \"../../Input\";\nimport { Label } from \"../../Label\";\nimport { DatePickerGroupStyles, DatePickerPopoverStyles } from \"../core\";\nimport type { DatePickerProps } from \"./types\";\n\nexport const DatePicker = <T extends DateValue>({\n label,\n description,\n errorMessage,\n showDescriptionOnInvalid = false,\n className,\n ref,\n weekdayStyle,\n ...props\n}: DatePickerProps<T>) => {\n return (\n <AriaDatePicker\n className={(renderProps) =>\n clsx(\n Colors,\n InputGroupStyles,\n typeof className === \"function\"\n ? className(renderProps)\n : className\n )\n }\n {...props}\n >\n {({ isInvalid, isDisabled, isOpen }) => {\n const showDescription =\n description &&\n (!isInvalid || (isInvalid && showDescriptionOnInvalid));\n\n return (\n <>\n {label && <Label>{label}</Label>}\n\n <Group\n className={clsx(\n EditorStyles,\n DatePickerGroupStyles\n )}\n data-trailing={true}\n data-open={isOpen || undefined}\n data-date-input={true}\n >\n <DateInput\n ref={ref}\n className={clsx(\n UnsetStyles,\n EditorInputStyles,\n typography.bodyLarge,\n DateInputStyles\n )}\n data-date-input={true}\n >\n {(segment) => (\n <DateSegment\n className={clsx(\n DateSegmentStyles,\n typography.bodyLarge\n )}\n segment={segment}\n />\n )}\n </DateInput>\n\n <InputButton\n icon={CalendarDays}\n isDisabled={isDisabled}\n data-invalid={isInvalid || undefined}\n />\n </Group>\n\n {showDescription && (\n <Description className={clsx(SupportingTextStyles)}>\n {description}\n </Description>\n )}\n <FieldError className={clsx(SupportingTextStyles)}>\n {errorMessage}\n </FieldError>\n\n <Popover className={clsx(DatePickerPopoverStyles)}>\n <Calendar weekdayStyle={weekdayStyle} />\n </Popover>\n </>\n );\n }}\n </AriaDatePicker>\n );\n};\n"],"mappings":";;;;;;;;;;;;;;AA6BA,IAAa,KAAmC,EAC5C,UACA,gBACA,iBACA,8BAA2B,IAC3B,cACA,QACA,iBACA,GAAG,QAGC,kBAAC,GAAD;CACI,YAAY,MACR,EACI,GACA,GACA,OAAO,KAAc,aACf,EAAU,CAAW,IACrB,CACV;CAEJ,GAAI;YAEF,EAAE,cAAW,eAAY,gBAAa;EACpC,IAAM,IACF,MACC,CAAC,KAAc,KAAa;EAEjC,OACI,kBAAA,GAAA,EAAA,UAAA;GACK,KAAS,kBAAC,GAAD,EAAA,UAAQ,EAAa,CAAA;GAE/B,kBAAC,GAAD;IACI,WAAW,EACP,GACA,CACJ;IACA,iBAAe;IACf,aAAW,KAAU,KAAA;IACrB,mBAAiB;cAPrB,CASI,kBAAC,GAAD;KACS;KACL,WAAW,EACP,GACA,GACA,EAAW,WACX,CACJ;KACA,mBAAiB;gBAEf,MACE,kBAAC,GAAD;MACI,WAAW,EACP,GACA,EAAW,SACf;MACS;
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../../../../../src/components/Input/DatePicker/DatePicker/DatePicker.tsx"],"sourcesContent":["import clsx from \"clsx\";\nimport { CalendarDays } from \"lucide-react\";\nimport {\n DatePicker as AriaDatePicker,\n DateInput,\n DateSegment,\n type DateValue,\n Group,\n} from \"react-aria-components\";\nimport { Calendar } from \"@/components/Calendar\";\nimport { Popover } from \"@/components/Popover\";\nimport { typography } from \"@/utils\";\nimport {\n Colors,\n DateInputStyles,\n DateSegmentStyles,\n EditorInputStyles,\n EditorStyles,\n InputGroupStyles,\n SupportingTextStyles,\n UnsetStyles,\n} from \"../../core\";\nimport { Description } from \"../../Description\";\nimport { FieldError } from \"../../FieldError\";\nimport { InputButton } from \"../../Input\";\nimport { Label } from \"../../Label\";\nimport { DatePickerGroupStyles, DatePickerPopoverStyles } from \"../core\";\nimport type { DatePickerProps } from \"./types\";\n\nexport const DatePicker = <T extends DateValue>({\n label,\n description,\n errorMessage,\n showDescriptionOnInvalid = false,\n className,\n ref,\n weekdayStyle,\n ...props\n}: DatePickerProps<T>) => {\n return (\n <AriaDatePicker\n className={(renderProps) =>\n clsx(\n Colors,\n InputGroupStyles,\n typeof className === \"function\"\n ? className(renderProps)\n : className\n )\n }\n {...props}\n >\n {({ isInvalid, isDisabled, isOpen }) => {\n const showDescription =\n description &&\n (!isInvalid || (isInvalid && showDescriptionOnInvalid));\n\n return (\n <>\n {label && <Label>{label}</Label>}\n\n <Group\n className={clsx(\n EditorStyles,\n DatePickerGroupStyles\n )}\n data-trailing={true}\n data-open={isOpen || undefined}\n data-date-input={true}\n >\n <DateInput\n ref={ref}\n className={clsx(\n UnsetStyles,\n EditorInputStyles,\n typography.bodyLarge,\n DateInputStyles\n )}\n data-date-input={true}\n >\n {(segment) => (\n <DateSegment\n className={clsx(\n DateSegmentStyles,\n typography.bodyLarge\n )}\n segment={segment}\n />\n )}\n </DateInput>\n\n <InputButton\n icon={CalendarDays}\n isDisabled={isDisabled}\n data-invalid={isInvalid || undefined}\n />\n </Group>\n\n {showDescription && (\n <Description className={clsx(SupportingTextStyles)}>\n {description}\n </Description>\n )}\n <FieldError className={clsx(SupportingTextStyles)}>\n {errorMessage}\n </FieldError>\n\n <Popover className={clsx(DatePickerPopoverStyles)}>\n <Calendar weekdayStyle={weekdayStyle} />\n </Popover>\n </>\n );\n }}\n </AriaDatePicker>\n );\n};\n"],"mappings":";;;;;;;;;;;;;;AA6BA,IAAa,KAAmC,EAC5C,UACA,gBACA,iBACA,8BAA2B,IAC3B,cACA,QACA,iBACA,GAAG,QAGC,kBAAC,GAAD;CACI,YAAY,MACR,EACI,GACA,GACA,OAAO,KAAc,aACf,EAAU,CAAW,IACrB,CACV;CAEJ,GAAI;YAEF,EAAE,cAAW,eAAY,gBAAa;EACpC,IAAM,IACF,MACC,CAAC,KAAc,KAAa;EAEjC,OACI,kBAAA,GAAA,EAAA,UAAA;GACK,KAAS,kBAAC,GAAD,EAAA,UAAQ,EAAa,CAAA;GAE/B,kBAAC,GAAD;IACI,WAAW,EACP,GACA,CACJ;IACA,iBAAe;IACf,aAAW,KAAU,KAAA;IACrB,mBAAiB;cAPrB,CASI,kBAAC,GAAD;KACS;KACL,WAAW,EACP,GACA,GACA,EAAW,WACX,CACJ;KACA,mBAAiB;gBAEf,MACE,kBAAC,GAAD;MACI,WAAW,EACP,GACA,EAAW,SACf;MACS;KAAQ,CAAA;IAGlB,CAAA,GAEX,kBAAC,GAAD;KACI,MAAM;KACM;KACZ,gBAAc,KAAa,KAAA;IAAU,CAAA,CAEtC;;GAEN,KACG,kBAAC,GAAD;IAAa,WAAW,EAAK,CAAoB;cAC5C;GACQ,CAAA;GAEjB,kBAAC,GAAD;IAAY,WAAW,EAAK,CAAoB;cAC3C;GACO,CAAA;GAEZ,kBAAC,GAAD;IAAS,WAAW,EAAK,CAAuB;cAC5C,kBAAC,GAAD,EAAwB,gBAAa,CAAA;GAChC,CAAA;EACb,EAAA,CAAA;CAER;AACY,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[],"sources":["../../../../../src/components/Input/DatePicker/DateRangePicker/DateRangePicker.tsx"],"sourcesContent":["import clsx from \"clsx\";\nimport { CalendarDays } from \"lucide-react\";\nimport {\n DateRangePicker as AriaRangeDatePicker,\n DateInput,\n DateSegment,\n type DateValue,\n Group,\n} from \"react-aria-components\";\nimport { RangeCalendar } from \"@/components/Calendar\";\nimport { Popover } from \"@/components/Popover\";\nimport { typography } from \"@/utils\";\nimport {\n Colors,\n DateInputStyles,\n DateSegmentStyles,\n EditorInputStyles,\n EditorStyles,\n InputGroupStyles,\n SupportingTextStyles,\n UnsetStyles,\n} from \"../../core\";\nimport { Description } from \"../../Description\";\nimport { FieldError } from \"../../FieldError\";\nimport { InputButton } from \"../../Input\";\nimport { Label } from \"../../Label\";\nimport {\n DatePickerGroupStyles,\n DatePickerPopoverStyles,\n DateRangePickerDateInputGroupStyles,\n} from \"../core\";\nimport type { DateRangePickerProps } from \"./types\";\n\nexport const DateRangePicker = <T extends DateValue>({\n label,\n description,\n errorMessage,\n showDescriptionOnInvalid = false,\n className,\n ref,\n weekdayStyle,\n ...props\n}: DateRangePickerProps<T>) => {\n return (\n <AriaRangeDatePicker\n className={(renderProps) =>\n clsx(\n Colors,\n InputGroupStyles,\n typeof className === \"function\"\n ? className(renderProps)\n : className\n )\n }\n {...props}\n >\n {({ isInvalid, isDisabled, isOpen }) => {\n const showDescription =\n description &&\n (!isInvalid || (isInvalid && showDescriptionOnInvalid));\n\n return (\n <>\n {label && <Label>{label}</Label>}\n\n <Group\n className={clsx(\n EditorStyles,\n DatePickerGroupStyles\n )}\n data-trailing={true}\n data-open={isOpen || undefined}\n data-date-input={true}\n >\n <div\n className={clsx(\n DateRangePickerDateInputGroupStyles\n )}\n >\n <DateInput\n slot=\"start\"\n ref={ref}\n className={clsx(\n UnsetStyles,\n EditorInputStyles,\n typography.bodyLarge,\n DateInputStyles\n )}\n data-date-input={true}\n >\n {(segment) => (\n <DateSegment\n className={clsx(\n DateSegmentStyles,\n typography.bodyLarge\n )}\n segment={segment}\n />\n )}\n </DateInput>\n\n <span aria-hidden=\"true\">–</span>\n\n <DateInput\n slot=\"end\"\n className={clsx(\n UnsetStyles,\n EditorInputStyles,\n typography.bodyLarge,\n DateInputStyles\n )}\n data-date-input={true}\n >\n {(segment) => (\n <DateSegment\n className={clsx(\n DateSegmentStyles,\n typography.bodyLarge\n )}\n segment={segment}\n />\n )}\n </DateInput>\n </div>\n\n <InputButton\n icon={CalendarDays}\n isDisabled={isDisabled}\n data-invalid={isInvalid || undefined}\n />\n </Group>\n\n {showDescription && (\n <Description className={clsx(SupportingTextStyles)}>\n {description}\n </Description>\n )}\n <FieldError className={clsx(SupportingTextStyles)}>\n {errorMessage}\n </FieldError>\n\n <Popover className={clsx(DatePickerPopoverStyles)}>\n <RangeCalendar weekdayStyle={weekdayStyle} />\n </Popover>\n </>\n );\n }}\n </AriaRangeDatePicker>\n );\n};\n"],"mappings":";;;;;;;;;;;;;;AAiCA,IAAa,KAAwC,EACjD,UACA,gBACA,iBACA,8BAA2B,IAC3B,cACA,QACA,iBACA,GAAG,QAGC,kBAAC,GAAD;CACI,YAAY,MACR,EACI,GACA,GACA,OAAO,KAAc,aACf,EAAU,CAAW,IACrB,CACV;CAEJ,GAAI;YAEF,EAAE,cAAW,eAAY,gBAAa;EACpC,IAAM,IACF,MACC,CAAC,KAAc,KAAa;EAEjC,OACI,kBAAA,GAAA,EAAA,UAAA;GACK,KAAS,kBAAC,GAAD,EAAA,UAAQ,EAAa,CAAA;GAE/B,kBAAC,GAAD;IACI,WAAW,EACP,GACA,CACJ;IACA,iBAAe;IACf,aAAW,KAAU,KAAA;IACrB,mBAAiB;cAPrB,CASI,kBAAC,OAAD;KACI,WAAW,EACP,CACJ;eAHJ;MAKI,kBAAC,GAAD;OACI,MAAK;OACA;OACL,WAAW,EACP,GACA,GACA,EAAW,WACX,CACJ;OACA,mBAAiB;kBAEf,MACE,kBAAC,GAAD;QACI,WAAW,EACP,GACA,EAAW,SACf;QACS;
|
|
1
|
+
{"version":3,"file":"index.js","names":["segment"],"sources":["../../../../../src/components/Input/DatePicker/DateRangePicker/DateRangePicker.tsx"],"sourcesContent":["import clsx from \"clsx\";\nimport { CalendarDays } from \"lucide-react\";\nimport {\n DateRangePicker as AriaRangeDatePicker,\n DateInput,\n DateSegment,\n type DateValue,\n Group,\n} from \"react-aria-components\";\nimport { RangeCalendar } from \"@/components/Calendar\";\nimport { Popover } from \"@/components/Popover\";\nimport { typography } from \"@/utils\";\nimport {\n Colors,\n DateInputStyles,\n DateSegmentStyles,\n EditorInputStyles,\n EditorStyles,\n InputGroupStyles,\n SupportingTextStyles,\n UnsetStyles,\n} from \"../../core\";\nimport { Description } from \"../../Description\";\nimport { FieldError } from \"../../FieldError\";\nimport { InputButton } from \"../../Input\";\nimport { Label } from \"../../Label\";\nimport {\n DatePickerGroupStyles,\n DatePickerPopoverStyles,\n DateRangePickerDateInputGroupStyles,\n} from \"../core\";\nimport type { DateRangePickerProps } from \"./types\";\n\nexport const DateRangePicker = <T extends DateValue>({\n label,\n description,\n errorMessage,\n showDescriptionOnInvalid = false,\n className,\n ref,\n weekdayStyle,\n ...props\n}: DateRangePickerProps<T>) => {\n return (\n <AriaRangeDatePicker\n className={(renderProps) =>\n clsx(\n Colors,\n InputGroupStyles,\n typeof className === \"function\"\n ? className(renderProps)\n : className\n )\n }\n {...props}\n >\n {({ isInvalid, isDisabled, isOpen }) => {\n const showDescription =\n description &&\n (!isInvalid || (isInvalid && showDescriptionOnInvalid));\n\n return (\n <>\n {label && <Label>{label}</Label>}\n\n <Group\n className={clsx(\n EditorStyles,\n DatePickerGroupStyles\n )}\n data-trailing={true}\n data-open={isOpen || undefined}\n data-date-input={true}\n >\n <div\n className={clsx(\n DateRangePickerDateInputGroupStyles\n )}\n >\n <DateInput\n slot=\"start\"\n ref={ref}\n className={clsx(\n UnsetStyles,\n EditorInputStyles,\n typography.bodyLarge,\n DateInputStyles\n )}\n data-date-input={true}\n >\n {(segment) => (\n <DateSegment\n className={clsx(\n DateSegmentStyles,\n typography.bodyLarge\n )}\n segment={segment}\n />\n )}\n </DateInput>\n\n <span aria-hidden=\"true\">–</span>\n\n <DateInput\n slot=\"end\"\n className={clsx(\n UnsetStyles,\n EditorInputStyles,\n typography.bodyLarge,\n DateInputStyles\n )}\n data-date-input={true}\n >\n {(segment) => (\n <DateSegment\n className={clsx(\n DateSegmentStyles,\n typography.bodyLarge\n )}\n segment={segment}\n />\n )}\n </DateInput>\n </div>\n\n <InputButton\n icon={CalendarDays}\n isDisabled={isDisabled}\n data-invalid={isInvalid || undefined}\n />\n </Group>\n\n {showDescription && (\n <Description className={clsx(SupportingTextStyles)}>\n {description}\n </Description>\n )}\n <FieldError className={clsx(SupportingTextStyles)}>\n {errorMessage}\n </FieldError>\n\n <Popover className={clsx(DatePickerPopoverStyles)}>\n <RangeCalendar weekdayStyle={weekdayStyle} />\n </Popover>\n </>\n );\n }}\n </AriaRangeDatePicker>\n );\n};\n"],"mappings":";;;;;;;;;;;;;;AAiCA,IAAa,KAAwC,EACjD,UACA,gBACA,iBACA,8BAA2B,IAC3B,cACA,QACA,iBACA,GAAG,QAGC,kBAAC,GAAD;CACI,YAAY,MACR,EACI,GACA,GACA,OAAO,KAAc,aACf,EAAU,CAAW,IACrB,CACV;CAEJ,GAAI;YAEF,EAAE,cAAW,eAAY,gBAAa;EACpC,IAAM,IACF,MACC,CAAC,KAAc,KAAa;EAEjC,OACI,kBAAA,GAAA,EAAA,UAAA;GACK,KAAS,kBAAC,GAAD,EAAA,UAAQ,EAAa,CAAA;GAE/B,kBAAC,GAAD;IACI,WAAW,EACP,GACA,CACJ;IACA,iBAAe;IACf,aAAW,KAAU,KAAA;IACrB,mBAAiB;cAPrB,CASI,kBAAC,OAAD;KACI,WAAW,EACP,CACJ;eAHJ;MAKI,kBAAC,GAAD;OACI,MAAK;OACA;OACL,WAAW,EACP,GACA,GACA,EAAW,WACX,CACJ;OACA,mBAAiB;kBAEf,MACE,kBAAC,GAAD;QACI,WAAW,EACP,GACA,EAAW,SACf;QACS;OAAQ,CAAA;MAGlB,CAAA;MAEX,kBAAC,QAAD;OAAM,eAAY;iBAAO;MAAO,CAAA;MAEhC,kBAAC,GAAD;OACI,MAAK;OACL,WAAW,EACP,GACA,GACA,EAAW,WACX,CACJ;OACA,mBAAiB;kBAEfA,MACE,kBAAC,GAAD;QACI,WAAW,EACP,GACA,EAAW,SACf;QACA,SAASA;OAAQ,CAAA;MAGlB,CAAA;KACV;QAEL,kBAAC,GAAD;KACI,MAAM;KACM;KACZ,gBAAc,KAAa,KAAA;IAAU,CAAA,CAEtC;;GAEN,KACG,kBAAC,GAAD;IAAa,WAAW,EAAK,CAAoB;cAC5C;GACQ,CAAA;GAEjB,kBAAC,GAAD;IAAY,WAAW,EAAK,CAAoB;cAC3C;GACO,CAAA;GAEZ,kBAAC,GAAD;IAAS,WAAW,EAAK,CAAuB;cAC5C,kBAAC,GAAD,EAA6B,gBAAa,CAAA;GACrC,CAAA;EACb,EAAA,CAAA;CAER;AACiB,CAAA"}
|
|
@@ -1,14 +1,25 @@
|
|
|
1
|
-
import { t as e } from "../../../chunks/
|
|
2
|
-
import t from "
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
1
|
+
import { t as e } from "../../../chunks/compiler-runtime";
|
|
2
|
+
import { t } from "../../../chunks/base";
|
|
3
|
+
import n from "clsx";
|
|
4
|
+
import { jsx as r } from "react/jsx-runtime";
|
|
5
|
+
import { Text as i } from "react-aria-components";
|
|
5
6
|
//#region src/components/Input/Description/Description.tsx
|
|
6
|
-
var
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
7
|
+
var a = e(), o = (e) => {
|
|
8
|
+
let o = (0, a.c)(8), s, c;
|
|
9
|
+
if (o[0] !== e) {
|
|
10
|
+
let { className: t, slot: n, ...r } = e;
|
|
11
|
+
s = t, c = r, o[0] = e, o[1] = s, o[2] = c;
|
|
12
|
+
} else s = o[1], c = o[2];
|
|
13
|
+
let l;
|
|
14
|
+
o[3] === s ? l = o[4] : (l = n(t.labelMedium, s), o[3] = s, o[4] = l);
|
|
15
|
+
let u;
|
|
16
|
+
return o[5] !== c || o[6] !== l ? (u = /* @__PURE__ */ r(i, {
|
|
17
|
+
slot: "description",
|
|
18
|
+
className: l,
|
|
19
|
+
...c
|
|
20
|
+
}), o[5] = c, o[6] = l, o[7] = u) : u = o[7], u;
|
|
21
|
+
};
|
|
11
22
|
//#endregion
|
|
12
|
-
export {
|
|
23
|
+
export { o as Description };
|
|
13
24
|
|
|
14
25
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[],"sources":["../../../../src/components/Input/Description/Description.tsx"],"sourcesContent":["import clsx from \"clsx\";\nimport { Text } from \"react-aria-components\";\nimport { typography } from \"@/utils/typography\";\n\nexport const Description: React.FC<\n React.ComponentPropsWithRef<typeof Text>\n> = ({ className, slot: _, ...props }) => {\n return (\n <Text\n slot=\"description\"\n className={clsx(typography.labelMedium, className)}\n {...props}\n />\n );\n};\n"],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../../../../src/components/Input/Description/Description.tsx"],"sourcesContent":["import clsx from \"clsx\";\nimport { Text } from \"react-aria-components\";\nimport { typography } from \"@/utils/typography\";\n\nexport const Description: React.FC<\n React.ComponentPropsWithRef<typeof Text>\n> = ({ className, slot: _, ...props }) => {\n return (\n <Text\n slot=\"description\"\n className={clsx(typography.labelMedium, className)}\n {...props}\n />\n );\n};\n"],"mappings":";;;;;;aAIa,KAET,MAAA;CAAA,IAAA,KAAA,GAAA,EAAA,EAAA,CAAA,CAAA,GAAA,GAAA;CAAA,IAAA,EAAA,OAAA,GAAA;EAAC,IAAA,EAAA,WAAA,GAAA,MAAA,GAAA,GAAA,MAAA;EAAgC,AAAhC,IAAA,GAAA,IAAA,GAAgC,EAAA,KAAA,GAAA,EAAA,KAAA,GAAA,EAAA,KAAA;CAAA,OAAA,AAAA,IAAA,EAAA,IAAA,IAAA,EAAA;CAAA,IAAA;CAAA,AAAA,EAAA,OAAA,IAIyB,IAAA,EAAA,MAAvC,IAAA,EAAK,EAAU,aAAc,CAAS,GAAC,EAAA,KAAA,GAAA,EAAA,KAAA;CAAA,IAAA;CAEpD,OAFoD,EAAA,OAAA,KAAA,EAAA,OAAA,KAFtD,IAAA,kBAAC,GAAD;EACS,MAAA;EACM,WAAA;EAAuC,GAC9C;CAAK,CAAA,GACX,EAAA,KAAA,GAAA,EAAA,KAAA,GAAA,EAAA,KAAA,KAAA,IAAA,EAAA,IAJF;AAIE"}
|
|
@@ -1,14 +1,22 @@
|
|
|
1
|
-
import { t as e } from "../../../chunks/
|
|
2
|
-
import t from "
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
1
|
+
import { t as e } from "../../../chunks/compiler-runtime";
|
|
2
|
+
import { t } from "../../../chunks/base";
|
|
3
|
+
import n from "clsx";
|
|
4
|
+
import { jsx as r } from "react/jsx-runtime";
|
|
5
|
+
import { Label as i } from "react-aria-components";
|
|
5
6
|
//#region src/components/Input/Label/Label.tsx
|
|
6
|
-
var
|
|
7
|
-
|
|
8
|
-
className:
|
|
9
|
-
|
|
10
|
-
|
|
7
|
+
var a = e(), o = (e) => {
|
|
8
|
+
let o = (0, a.c)(8), s, c;
|
|
9
|
+
o[0] === e ? (s = o[1], c = o[2]) : ({className: s, ...c} = e, o[0] = e, o[1] = s, o[2] = c);
|
|
10
|
+
let l;
|
|
11
|
+
o[3] === s ? l = o[4] : (l = n(t.labelLarge, s), o[3] = s, o[4] = l);
|
|
12
|
+
let u;
|
|
13
|
+
return o[5] !== c || o[6] !== l ? (u = /* @__PURE__ */ r(i, {
|
|
14
|
+
slot: "label",
|
|
15
|
+
className: l,
|
|
16
|
+
...c
|
|
17
|
+
}), o[5] = c, o[6] = l, o[7] = u) : u = o[7], u;
|
|
18
|
+
};
|
|
11
19
|
//#endregion
|
|
12
|
-
export {
|
|
20
|
+
export { o as Label };
|
|
13
21
|
|
|
14
22
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[],"sources":["../../../../src/components/Input/Label/Label.tsx"],"sourcesContent":["import clsx from \"clsx\";\nimport { Label as AriaLabel } from \"react-aria-components\";\nimport { typography } from \"@/utils/typography\";\n\nexport const Label: React.FC<React.ComponentPropsWithRef<typeof AriaLabel>> = ({\n className,\n ...props\n}) => {\n return (\n <AriaLabel\n slot=\"label\"\n className={clsx(typography.labelLarge, className)}\n {...props}\n />\n );\n};\n"],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../../../../src/components/Input/Label/Label.tsx"],"sourcesContent":["import clsx from \"clsx\";\nimport { Label as AriaLabel } from \"react-aria-components\";\nimport { typography } from \"@/utils/typography\";\n\nexport const Label: React.FC<React.ComponentPropsWithRef<typeof AriaLabel>> = ({\n className,\n ...props\n}) => {\n return (\n <AriaLabel\n slot=\"label\"\n className={clsx(typography.labelLarge, className)}\n {...props}\n />\n );\n};\n"],"mappings":";;;;;;aAIa,KAAiE,MAAA;CAAA,IAAA,KAAA,GAAA,EAAA,EAAA,CAAA,CAAA,GAAA,GAAA;CAAA,AAAA,EAAA,OAAA,KAG7E,IAAA,EAAA,IAAA,IAAA,EAAA,OAH8E,kBAAA,KAAA,GAG9E,EAAA,KAAA,GAAA,EAAA,KAAA,GAAA,EAAA,KAAA;CAAA,IAAA;CAAA,AAAA,EAAA,OAAA,IAI4D,IAAA,EAAA,MAAtC,IAAA,EAAK,EAAU,YAAa,CAAS,GAAC,EAAA,KAAA,GAAA,EAAA,KAAA;CAAA,IAAA;CAEnD,OAFmD,EAAA,OAAA,KAAA,EAAA,OAAA,KAFrD,IAAA,kBAAC,GAAD;EACS,MAAA;EACM,WAAA;EAAsC,GAC7C;CAAK,CAAA,GACX,EAAA,KAAA,GAAA,EAAA,KAAA,GAAA,EAAA,KAAA,KAAA,IAAA,EAAA,IAJF;AAIE"}
|