@planningcenter/tapestry 3.3.0 → 3.3.1-qa-887.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/date-picker/DatePicker.d.ts.map +1 -1
- package/dist/components/date-picker/DatePicker.js +136 -8
- package/dist/components/date-picker/DatePicker.js.map +1 -1
- package/dist/components/page-header/index.js +3 -3
- package/dist/components/sidenav/index.js +5 -5
- package/dist/ext/@internationalized/date/dist/string.js +19 -1
- package/dist/ext/@internationalized/date/dist/string.js.map +1 -1
- package/dist/reactRender.css +474 -474
- package/dist/reactRender.css.map +1 -1
- package/dist/reactRenderLegacy.css +474 -474
- package/dist/reactRenderLegacy.css.map +1 -1
- package/dist/tapestry-wc/dist/components/p-B00sJe3H.js +41 -0
- package/dist/tapestry-wc/dist/components/p-B00sJe3H.js.map +1 -0
- package/dist/tapestry-wc/dist/components/p-Bn0hHWDB.js +22 -0
- package/dist/tapestry-wc/dist/components/p-Bn0hHWDB.js.map +1 -0
- package/dist/tapestry-wc/dist/components/p-Dq8WF4tc.js +886 -0
- package/dist/tapestry-wc/dist/components/p-Dq8WF4tc.js.map +1 -0
- package/dist/tapestry-wc/dist/components/p-T7x-WXUY.js +51 -0
- package/dist/tapestry-wc/dist/components/p-T7x-WXUY.js.map +1 -0
- package/dist/tapestry-wc/dist/components/p-nyMzpSUR.js +1736 -0
- package/dist/tapestry-wc/dist/components/p-nyMzpSUR.js.map +1 -0
- package/dist/tapestry-wc/dist/components/tds-page-header-nav.js +10 -0
- package/dist/tapestry-wc/dist/components/tds-page-header-nav.js.map +1 -0
- package/dist/tapestry-wc/dist/components/tds-page-header.js +63 -0
- package/dist/tapestry-wc/dist/components/tds-page-header.js.map +1 -0
- package/dist/tapestry-wc/dist/components/tds-sidenav-item.js +96 -0
- package/dist/tapestry-wc/dist/components/tds-sidenav-item.js.map +1 -0
- package/dist/tapestry-wc/dist/components/tds-sidenav-responsive-header.js +10 -0
- package/dist/tapestry-wc/dist/components/tds-sidenav-responsive-header.js.map +1 -0
- package/dist/tapestry-wc/dist/components/tds-sidenav-section.js +52 -0
- package/dist/tapestry-wc/dist/components/tds-sidenav-section.js.map +1 -0
- package/dist/tapestry-wc/dist/components/tds-sidenav.js +74 -0
- package/dist/tapestry-wc/dist/components/tds-sidenav.js.map +1 -0
- package/dist/unstable.js +0 -1
- package/dist/unstable.js.map +1 -1
- package/package.json +5 -5
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DatePicker.d.ts","sourceRoot":"","sources":["../../../src/components/date-picker/DatePicker.tsx"],"names":[],"mappings":"AAAA,OAAO,mBAAmB,CAAA;AAC1B,OAAO,8BAA8B,CAAA;AACrC,OAAO,aAAa,CAAA;AAEpB,OAAO,EAEL,KAAK,SAAS,EAIf,MAAM,yBAAyB,CAAA;AAEhC,OAAO,KAAK,EAAE,+BAA+B,EAAE,MAAM,2BAA2B,CAAA;AAEhF,OAAO,
|
|
1
|
+
{"version":3,"file":"DatePicker.d.ts","sourceRoot":"","sources":["../../../src/components/date-picker/DatePicker.tsx"],"names":[],"mappings":"AAAA,OAAO,mBAAmB,CAAA;AAC1B,OAAO,8BAA8B,CAAA;AACrC,OAAO,aAAa,CAAA;AAEpB,OAAO,EAEL,KAAK,SAAS,EAIf,MAAM,yBAAyB,CAAA;AAEhC,OAAO,KAAK,EAAE,+BAA+B,EAAE,MAAM,2BAA2B,CAAA;AAEhF,OAAO,KAAwD,MAAM,OAAO,CAAA;AAC5E,OAAO,EAWL,KAAK,eAAe,IAAI,mBAAmB,EAS5C,MAAM,uBAAuB,CAAA;AAE9B,MAAM,MAAM,cAAc,GAAG,IAAI,GAAG,IAAI,CAAA;AAExC,MAAM,MAAM,mBAAmB,GAAG,SAAS,GAAG,MAAM,CAAA;AAepD,MAAM,WAAW,eAAe;IAC9B,gGAAgG;IAChG,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,8CAA8C;IAC9C,QAAQ,CAAC,EAAE,OAAO,C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Ac,EACd,SAAS,EACT,OAAO,EACP,iBAAiB,EACjB,KAAK,EACL,GAAG,EACH,GAAG,EACH,QAAQ,EACR,QAAQ,EACR,QAAQ,EACR,IAAW,EACX,KAAK,EACL,GAAG,SAAS,EACb,EAAE,sBAAsB,qBAwFxB;yBAzGe,UAAU"}
|
|
@@ -1,11 +1,139 @@
|
|
|
1
|
+
import { CalendarDate as $35ea8db9cb2ccb90$export$99faa760c7908e4f } from './../../ext/@internationalized/date/dist/CalendarDate.js';
|
|
1
2
|
import { today as $14e0f24ef4ac5c92$export$d0bdf45af03a6ea3, getLocalTimeZone as $14e0f24ef4ac5c92$export$aa8b41735afcabd2 } from './../../ext/@internationalized/date/dist/queries.js';
|
|
2
|
-
import '
|
|
3
|
-
import '
|
|
4
|
-
import '
|
|
5
|
-
import '
|
|
6
|
-
import 'react-aria-components';
|
|
3
|
+
import { parseDate as $fae977aafc393c5c$export$6b862160d295c8e } from './../../ext/@internationalized/date/dist/string.js';
|
|
4
|
+
import Icon from '../../utilities/Icon.js';
|
|
5
|
+
import classNames from 'classnames';
|
|
6
|
+
import React__default, { useState, useContext, useMemo } from 'react';
|
|
7
|
+
import { DatePicker as DatePicker$1, Label, Group, DateInput, DateSegment, Button, Popover, Dialog, Calendar, Text, CalendarStateContext, ListBox, ListBoxItem, CalendarGrid, CalendarGridHeader, CalendarHeaderCell, CalendarGridBody, CalendarCell } from 'react-aria-components';
|
|
7
8
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
9
|
+
function toCalendarDate(input) {
|
|
10
|
+
if (input === null)
|
|
11
|
+
return null;
|
|
12
|
+
if (input === undefined)
|
|
13
|
+
return undefined;
|
|
14
|
+
if (typeof input === "object" && "calendar" in input) {
|
|
15
|
+
return input;
|
|
16
|
+
}
|
|
17
|
+
return $fae977aafc393c5c$export$6b862160d295c8e(input);
|
|
18
|
+
}
|
|
19
|
+
function DatePickerOverlay({ children, variant, }) {
|
|
20
|
+
return (React__default.createElement("div", { "aria-label": `Select ${variant}`, "aria-modal": "true", className: `tds-date-picker-overlay tds-date-picker-overlay--${variant}`, role: "dialog" }, children));
|
|
21
|
+
}
|
|
22
|
+
function DatePickerCalendarBody({ activeOverlay, setActiveOverlay, }) {
|
|
23
|
+
// Read and drive Calendar's focused date through its state context. This
|
|
24
|
+
// lets react-aria-components own the "open to selected month" behavior:
|
|
25
|
+
// when the popover opens, Calendar mounts and auto-focuses the DatePicker's
|
|
26
|
+
// current value (whether typed into the input segments or set via `value`).
|
|
27
|
+
const state = useContext(CalendarStateContext);
|
|
28
|
+
const focusedDate = state.focusedDate;
|
|
29
|
+
const today = $14e0f24ef4ac5c92$export$d0bdf45af03a6ea3($14e0f24ef4ac5c92$export$aa8b41735afcabd2());
|
|
30
|
+
const MONTHS = Array.from({ length: 12 }, (_, i) => i);
|
|
31
|
+
const YEARS = Array.from({ length: 131 }, (_, i) => today.year - 100 + i);
|
|
32
|
+
const shortMonthFormatter = useMemo(() => new Intl.DateTimeFormat(undefined, { month: "short" }), []);
|
|
33
|
+
const longMonthFormatter = useMemo(() => new Intl.DateTimeFormat(undefined, { month: "long" }), []);
|
|
34
|
+
function handleOverlaySelectionChange(keys, onSelect) {
|
|
35
|
+
if (keys === "all")
|
|
36
|
+
return;
|
|
37
|
+
const [first] = Array.from(keys);
|
|
38
|
+
if (first !== undefined)
|
|
39
|
+
onSelect(Number(first));
|
|
40
|
+
}
|
|
41
|
+
function handleMonthSelect(monthIndex) {
|
|
42
|
+
state.setFocusedDate(new $35ea8db9cb2ccb90$export$99faa760c7908e4f(focusedDate.year, monthIndex + 1, 1));
|
|
43
|
+
setActiveOverlay(null);
|
|
44
|
+
}
|
|
45
|
+
function handleYearSelect(year) {
|
|
46
|
+
state.setFocusedDate(new $35ea8db9cb2ccb90$export$99faa760c7908e4f(year, focusedDate.month, 1));
|
|
47
|
+
setActiveOverlay(null);
|
|
48
|
+
}
|
|
49
|
+
return (React__default.createElement(React__default.Fragment, null,
|
|
50
|
+
React__default.createElement("header", { className: "tds-date-picker-calendar-header" },
|
|
51
|
+
React__default.createElement("div", { className: "tds-date-picker-calendar-heading" },
|
|
52
|
+
React__default.createElement(Button, { "aria-expanded": activeOverlay === "month", "aria-haspopup": "dialog", className: "tds-date-picker-calendar-overlay-trigger", onPress: () => setActiveOverlay(activeOverlay === "month" ? null : "month"), slot: null }, longMonthFormatter.format(new Date(2000, focusedDate.month - 1, 1))),
|
|
53
|
+
React__default.createElement(Button, { "aria-expanded": activeOverlay === "year", "aria-haspopup": "dialog", className: "tds-date-picker-calendar-overlay-trigger", onPress: () => setActiveOverlay(activeOverlay === "year" ? null : "year"), slot: null }, focusedDate.year)),
|
|
54
|
+
activeOverlay ? (React__default.createElement(Button, { "aria-label": `Close ${activeOverlay} picker`, className: "tds-date-picker-calendar-nav", onPress: () => setActiveOverlay(null), slot: null },
|
|
55
|
+
React__default.createElement(Icon, { "aria-hidden": true, symbol: "general#x" }))) : (React__default.createElement(React__default.Fragment, null,
|
|
56
|
+
React__default.createElement(Button, { "aria-label": "Go to today", className: "tds-date-picker-calendar-nav tds-date-picker-calendar-nav--lg", style: {
|
|
57
|
+
visibility: focusedDate.month === today.month &&
|
|
58
|
+
focusedDate.year === today.year
|
|
59
|
+
? "hidden"
|
|
60
|
+
: undefined,
|
|
61
|
+
}, onPress: () => {
|
|
62
|
+
state.setFocusedDate(today);
|
|
63
|
+
state.setFocused(true);
|
|
64
|
+
}, slot: null },
|
|
65
|
+
React__default.createElement("svg", { "aria-hidden": true, xmlns: "http://www.w3.org/2000/svg", fill: "currentColor", viewBox: "0 0 16 16", className: "symbol" },
|
|
66
|
+
React__default.createElement("path", { d: "M13.444 14.222H2.556V5.667h10.888zm0-12.444h-.777V.222h-1.556v1.556H4.889V.222H3.333v1.556h-.777a1.55 1.55 0 0 0-1.548 1.555L1 14.222a1.555 1.555 0 0 0 1.556 1.556h10.888A1.56 1.56 0 0 0 15 14.222V3.333a1.56 1.56 0 0 0-1.556-1.555" }),
|
|
67
|
+
React__default.createElement("circle", { cx: "8", cy: "9.75", r: "2.25" }))),
|
|
68
|
+
React__default.createElement(Button, { "aria-label": "Previous month", className: "tds-date-picker-calendar-nav", slot: "previous" },
|
|
69
|
+
React__default.createElement(Icon, { "aria-hidden": true, symbol: "general#left-chevron" })),
|
|
70
|
+
React__default.createElement(Button, { "aria-label": "Next month", className: "tds-date-picker-calendar-nav", slot: "next" },
|
|
71
|
+
React__default.createElement(Icon, { "aria-hidden": true, symbol: "general#right-chevron" }))))),
|
|
72
|
+
React__default.createElement("div", { className: "tds-date-picker-calendar-body" },
|
|
73
|
+
activeOverlay === "month" && (React__default.createElement(DatePickerOverlay, { variant: "month" },
|
|
74
|
+
React__default.createElement(ListBox, { "aria-label": "Months",
|
|
75
|
+
// eslint-disable-next-line jsx-a11y/no-autofocus -- focusing the active item on dialog open is required per ARIA authoring practices
|
|
76
|
+
autoFocus: true, className: "tds-date-picker-overlay-list", disallowEmptySelection: true, escapeKeyBehavior: "none", layout: "grid", onSelectionChange: (keys) => handleOverlaySelectionChange(keys, handleMonthSelect), selectedKeys: [String(focusedDate.month - 1)], selectionMode: "single" }, MONTHS.map((i) => {
|
|
77
|
+
const date = new Date(2000, i, 1);
|
|
78
|
+
const shortMonth = shortMonthFormatter.format(date);
|
|
79
|
+
const longMonth = longMonthFormatter.format(date);
|
|
80
|
+
return (React__default.createElement(ListBoxItem, { className: "tds-date-picker-overlay-cell", id: String(i), key: i, "aria-label": longMonth, textValue: longMonth }, shortMonth));
|
|
81
|
+
})))),
|
|
82
|
+
activeOverlay === "year" && (React__default.createElement(DatePickerOverlay, { variant: "year" },
|
|
83
|
+
React__default.createElement(ListBox, { "aria-label": "Years",
|
|
84
|
+
// eslint-disable-next-line jsx-a11y/no-autofocus -- focusing the active item on dialog open is required per ARIA authoring practices
|
|
85
|
+
autoFocus: true, className: "tds-date-picker-overlay-list", disallowEmptySelection: true, escapeKeyBehavior: "none", layout: "grid", onSelectionChange: (keys) => handleOverlaySelectionChange(keys, handleYearSelect), selectedKeys: [String(focusedDate.year)], selectionMode: "single" }, YEARS.map((year) => (React__default.createElement(ListBoxItem, { className: "tds-date-picker-overlay-cell", id: String(year), key: year, textValue: String(year) }, year)))))),
|
|
86
|
+
React__default.createElement(CalendarGrid, { className: "tds-date-picker-calendar-grid" },
|
|
87
|
+
React__default.createElement(CalendarGridHeader, { className: "tds-date-picker-calendar-grid-header" }, (day) => (React__default.createElement(CalendarHeaderCell, { className: "tds-date-picker-calendar-header-cell" }, day))),
|
|
88
|
+
React__default.createElement(CalendarGridBody, { className: "tds-date-picker-calendar-grid-body" }, (date) => (React__default.createElement(CalendarCell, { className: "tds-date-picker-calendar-cell-button", date: date })))))));
|
|
89
|
+
}
|
|
90
|
+
/**
|
|
91
|
+
* A date picker allows a user to select a particular date.
|
|
92
|
+
* The input supports keyboard entry of individual day, month, and year segments;
|
|
93
|
+
* the calendar offers month and year quick-pick overlays plus a "go to today" shortcut.
|
|
94
|
+
*
|
|
95
|
+
* The date picker automatically displays the value and calendar from the user's locale,
|
|
96
|
+
* and does not require a specific date format.
|
|
97
|
+
*
|
|
98
|
+
* Values are exchanged as `DateValue` from `@internationalized/date`, but
|
|
99
|
+
* `value`, `min`, and `max` also accept ISO date strings (`"YYYY-MM-DD"`) for
|
|
100
|
+
* convenience. Restrict the selectable range with `min`/`max`, or mark
|
|
101
|
+
* individual dates as unavailable via `isDateUnavailable`.
|
|
102
|
+
*
|
|
103
|
+
* @component
|
|
104
|
+
* @see {@link https://planningcenter.github.io/tapestry/?path=/docs/components-datepicker--docs | Storybook Documentation}
|
|
105
|
+
*/
|
|
106
|
+
function DatePicker({ className, description, disabled, firstDayOfWeek, hideLabel, invalid, isDateUnavailable, label, max, min, onChange, readOnly, required, size = "md", value, ...restProps }) {
|
|
107
|
+
const convertedValue = toCalendarDate(value);
|
|
108
|
+
const convertedMin = toCalendarDate(min) ?? undefined;
|
|
109
|
+
const convertedMax = toCalendarDate(max) ?? undefined;
|
|
110
|
+
const combinedClassName = classNames("tds-field tds-date-picker", {
|
|
111
|
+
"tds-date-picker--lg": size === "lg",
|
|
112
|
+
"tds-field--lg": size === "lg",
|
|
113
|
+
}, className);
|
|
114
|
+
const [activeOverlay, setActiveOverlay] = useState(null);
|
|
115
|
+
return (React__default.createElement(DatePicker$1, { ...restProps, "aria-label": hideLabel ? label : undefined, className: combinedClassName, isDateUnavailable: isDateUnavailable, isDisabled: disabled, isInvalid: invalid, isReadOnly: readOnly, isRequired: required, maxValue: convertedMax, minValue: convertedMin, onChange: onChange ?? undefined, onOpenChange: (isOpen) => {
|
|
116
|
+
if (!isOpen)
|
|
117
|
+
setActiveOverlay(null);
|
|
118
|
+
}, value: convertedValue },
|
|
119
|
+
!hideLabel && React__default.createElement(Label, { className: "tds-field-label" }, label),
|
|
120
|
+
React__default.createElement(Group, { className: "tds-field-control tds-date-picker-field" },
|
|
121
|
+
React__default.createElement(DateInput, { className: "tds-date-picker-input" }, (segment) => (React__default.createElement(DateSegment, { className: segment.type === "literal"
|
|
122
|
+
? "tds-field-date-segment-separator"
|
|
123
|
+
: "tds-field-date-segment", segment: segment }))),
|
|
124
|
+
React__default.createElement(Button, { className: "tds-btn tds-btn--infield tds-date-picker-button" },
|
|
125
|
+
React__default.createElement(Icon, { "aria-hidden": true, symbol: "general#calendar" }))),
|
|
126
|
+
React__default.createElement(Popover, { className: classNames("tds-date-picker-popover", {
|
|
127
|
+
"tds-date-picker-popover--lg": size === "lg",
|
|
128
|
+
}), offset: 2 },
|
|
129
|
+
React__default.createElement(Dialog, null,
|
|
130
|
+
React__default.createElement(Calendar, { className: "tds-date-picker-calendar", firstDayOfWeek: firstDayOfWeek },
|
|
131
|
+
React__default.createElement(DatePickerCalendarBody, { activeOverlay: activeOverlay, setActiveOverlay: setActiveOverlay })))),
|
|
132
|
+
description && (React__default.createElement(Text, { elementType: "p", className: "tds-field-description", slot: "description" },
|
|
133
|
+
React__default.createElement(Icon, { "aria-hidden": true, className: "tds-field-description-invalid-icon", symbol: "general#exclamation-triangle" }),
|
|
134
|
+
description))));
|
|
135
|
+
}
|
|
136
|
+
DatePicker.displayName = "DatePicker";
|
|
137
|
+
|
|
138
|
+
export { DatePicker };
|
|
11
139
|
//# sourceMappingURL=DatePicker.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DatePicker.js","sources":["../../../src/components/date-picker/DatePicker.tsx"],"sourcesContent":["import \"../button/btn.css\"\nimport \"../input-text-base/index.css\"\nimport \"./index.css\"\n\nimport {\n CalendarDate,\n type DateValue,\n getLocalTimeZone,\n parseDate,\n today as todayCalendar,\n} from \"@internationalized/date\"\nimport Icon from \"@utilities/Icon\"\nimport type { CombineAriaPropsWithCustomProps } from \"@utilities/reactAriaProps\"\nimport classNames from \"classnames\"\nimport React, { type ReactNode, useContext, useState } from \"react\"\nimport {\n Button,\n Calendar,\n CalendarCell,\n CalendarGrid,\n CalendarGridBody,\n CalendarGridHeader,\n CalendarHeaderCell,\n CalendarStateContext,\n DateInput,\n DatePicker as AriaDatePicker,\n type DatePickerProps as AriaDatePickerProps,\n DateSegment,\n Dialog,\n Group,\n Label,\n ListBox,\n ListBoxItem,\n Popover,\n Text,\n} from \"react-aria-components\"\n\nconst _today = todayCalendar(getLocalTimeZone())\nconst MONTHS = Array.from({ length: 12 }, (_, i) => i)\nconst YEARS = Array.from({ length: 131 }, (_, i) => _today.year - 100 + i)\nconst shortMonthFormatter = new Intl.DateTimeFormat(undefined, {\n month: \"short\",\n})\nconst longMonthFormatter = new Intl.DateTimeFormat(undefined, { month: \"long\" })\n\nexport type DatePickerSize = \"md\" | \"lg\"\n\nexport type DatePickerDateValue = DateValue | string\n\nfunction toCalendarDate(\n input: DatePickerDateValue | null | undefined\n): DateValue | null | undefined {\n if (input === null) return null\n if (input === undefined) return undefined\n\n if (typeof input === \"object\" && \"calendar\" in input) {\n return input\n }\n\n return parseDate(input)\n}\n\nexport interface DatePickerProps {\n /** Helper text displayed below the component. Styled as error text when `invalid` is `true`. */\n description?: string\n /** Disables the input and calendar button. */\n disabled?: boolean\n /** Sets the first day of the week in the calendar. Defaults to locale-appropriate value. */\n firstDayOfWeek?: \"fri\" | \"mon\" | \"sat\" | \"sun\" | \"thu\" | \"tue\" | \"wed\"\n /** If `true`, the `label` text is rendered as an `aria-label` instead of a visible label element. */\n hideLabel?: boolean\n /** Whether the input is in an invalid state. */\n invalid?: boolean\n /** Callback that returns `true` for dates that should be visible but not selectable. */\n isDateUnavailable?: (date: DateValue) => boolean\n /** Accessible label for the field. */\n label: string\n /** Maximum selectable date. Accepts a DateValue or ISO date string. */\n max?: DatePickerDateValue\n /** Minimum selectable date. Accepts a DateValue or ISO date string. */\n min?: DatePickerDateValue\n /** Called when the selected date changes. */\n onChange?: (value: DateValue | null) => void\n /** If `true`, allows the value to be read but not changed. */\n readOnly?: boolean\n /** If `true`, appends an asterisk at the end of the label text. */\n required?: boolean\n /** The size of the date picker. */\n size?: DatePickerSize\n /** The controlled value. Accepts a DateValue or ISO date string. */\n value?: DatePickerDateValue | null\n}\n\ntype AriaDatePickerPropsToOmit =\n | \"children\"\n | \"defaultOpen\"\n | \"defaultValue\"\n | \"granularity\"\n | \"hideTimeZone\"\n | \"hourCycle\"\n | \"pageBehavior\"\n | \"placeholderValue\"\n | \"shouldCloseOnSelect\"\n | \"shouldForceLeadingZeros\"\n | \"slot\"\n\ntype AriaDatePickerPropsToInclude = \"isOpen\" | \"name\" | \"onOpenChange\"\n\nexport type DatePickerElementProps = CombineAriaPropsWithCustomProps<\n AriaDatePickerProps<DateValue>,\n DatePickerProps,\n AriaDatePickerPropsToOmit,\n AriaDatePickerPropsToInclude\n>\n\nfunction DatePickerOverlay({\n children,\n variant,\n}: {\n children: ReactNode\n variant: \"month\" | \"year\"\n}) {\n return (\n <div\n aria-label={`Select ${variant}`}\n aria-modal=\"true\"\n className={`tds-date-picker-overlay tds-date-picker-overlay--${variant}`}\n role=\"dialog\"\n >\n {children}\n </div>\n )\n}\n\nfunction DatePickerCalendarBody({\n activeOverlay,\n setActiveOverlay,\n}: {\n activeOverlay: \"month\" | \"year\" | null\n setActiveOverlay: (overlay: \"month\" | \"year\" | null) => void\n}) {\n // Read and drive Calendar's focused date through its state context. This\n // lets react-aria-components own the \"open to selected month\" behavior:\n // when the popover opens, Calendar mounts and auto-focuses the DatePicker's\n // current value (whether typed into the input segments or set via `value`).\n const state = useContext(CalendarStateContext)!\n const focusedDate = state.focusedDate\n const today = todayCalendar(getLocalTimeZone())\n\n function handleOverlaySelectionChange(\n keys: \"all\" | Set<number | string>,\n onSelect: (key: number) => void\n ) {\n if (keys === \"all\") return\n const [first] = Array.from(keys)\n if (first !== undefined) onSelect(Number(first))\n }\n\n function handleMonthSelect(monthIndex: number) {\n state.setFocusedDate(new CalendarDate(focusedDate.year, monthIndex + 1, 1))\n setActiveOverlay(null)\n }\n\n function handleYearSelect(year: number) {\n state.setFocusedDate(new CalendarDate(year, focusedDate.month, 1))\n setActiveOverlay(null)\n }\n\n return (\n <>\n <header className=\"tds-date-picker-calendar-header\">\n <div className=\"tds-date-picker-calendar-heading\">\n <Button\n aria-expanded={activeOverlay === \"month\"}\n aria-haspopup=\"dialog\"\n className=\"tds-date-picker-calendar-overlay-trigger\"\n onPress={() =>\n setActiveOverlay(activeOverlay === \"month\" ? null : \"month\")\n }\n slot={null}\n >\n {longMonthFormatter.format(\n new Date(2000, focusedDate.month - 1, 1)\n )}\n </Button>\n <Button\n aria-expanded={activeOverlay === \"year\"}\n aria-haspopup=\"dialog\"\n className=\"tds-date-picker-calendar-overlay-trigger\"\n onPress={() =>\n setActiveOverlay(activeOverlay === \"year\" ? null : \"year\")\n }\n slot={null}\n >\n {focusedDate.year}\n </Button>\n </div>\n {activeOverlay ? (\n <Button\n aria-label={`Close ${activeOverlay} picker`}\n className=\"tds-date-picker-calendar-nav\"\n onPress={() => setActiveOverlay(null)}\n slot={null}\n >\n <Icon aria-hidden symbol=\"general#x\" />\n </Button>\n ) : (\n <>\n <Button\n aria-label=\"Go to today\"\n className=\"tds-date-picker-calendar-nav tds-date-picker-calendar-nav--lg\"\n style={{\n visibility:\n focusedDate.month === today.month &&\n focusedDate.year === today.year\n ? \"hidden\"\n : undefined,\n }}\n onPress={() => {\n state.setFocusedDate(today)\n state.setFocused(true)\n }}\n slot={null}\n >\n {/* TODO: Add to icon library and use Icon once icon is decided on */}\n <svg\n aria-hidden\n xmlns=\"http://www.w3.org/2000/svg\"\n fill=\"currentColor\"\n viewBox=\"0 0 16 16\"\n className=\"symbol\"\n >\n <path d=\"M13.444 14.222H2.556V5.667h10.888zm0-12.444h-.777V.222h-1.556v1.556H4.889V.222H3.333v1.556h-.777a1.55 1.55 0 0 0-1.548 1.555L1 14.222a1.555 1.555 0 0 0 1.556 1.556h10.888A1.56 1.56 0 0 0 15 14.222V3.333a1.56 1.56 0 0 0-1.556-1.555\" />\n <circle cx=\"8\" cy=\"9.75\" r=\"2.25\" />\n </svg>\n </Button>\n <Button\n aria-label=\"Previous month\"\n className=\"tds-date-picker-calendar-nav\"\n slot=\"previous\"\n >\n <Icon aria-hidden symbol=\"general#left-chevron\" />\n </Button>\n <Button\n aria-label=\"Next month\"\n className=\"tds-date-picker-calendar-nav\"\n slot=\"next\"\n >\n <Icon aria-hidden symbol=\"general#right-chevron\" />\n </Button>\n </>\n )}\n </header>\n <div className=\"tds-date-picker-calendar-body\">\n {activeOverlay === \"month\" && (\n <DatePickerOverlay variant=\"month\">\n <ListBox\n aria-label=\"Months\"\n // eslint-disable-next-line jsx-a11y/no-autofocus -- focusing the active item on dialog open is required per ARIA authoring practices\n autoFocus\n className=\"tds-date-picker-overlay-list\"\n disallowEmptySelection\n escapeKeyBehavior=\"none\"\n layout=\"grid\"\n onSelectionChange={(keys) =>\n handleOverlaySelectionChange(keys, handleMonthSelect)\n }\n selectedKeys={[String(focusedDate.month - 1)]}\n selectionMode=\"single\"\n >\n {MONTHS.map((i) => {\n const date = new Date(2000, i, 1)\n const shortMonth = shortMonthFormatter.format(date)\n const longMonth = longMonthFormatter.format(date)\n\n return (\n <ListBoxItem\n className=\"tds-date-picker-overlay-cell\"\n id={String(i)}\n key={i}\n aria-label={longMonth}\n textValue={longMonth}\n >\n {shortMonth}\n </ListBoxItem>\n )\n })}\n </ListBox>\n </DatePickerOverlay>\n )}\n {activeOverlay === \"year\" && (\n <DatePickerOverlay variant=\"year\">\n <ListBox\n aria-label=\"Years\"\n // eslint-disable-next-line jsx-a11y/no-autofocus -- focusing the active item on dialog open is required per ARIA authoring practices\n autoFocus\n className=\"tds-date-picker-overlay-list\"\n disallowEmptySelection\n escapeKeyBehavior=\"none\"\n layout=\"grid\"\n onSelectionChange={(keys) =>\n handleOverlaySelectionChange(keys, handleYearSelect)\n }\n selectedKeys={[String(focusedDate.year)]}\n selectionMode=\"single\"\n >\n {YEARS.map((year) => (\n <ListBoxItem\n className=\"tds-date-picker-overlay-cell\"\n id={String(year)}\n key={year}\n textValue={String(year)}\n >\n {year}\n </ListBoxItem>\n ))}\n </ListBox>\n </DatePickerOverlay>\n )}\n <CalendarGrid className=\"tds-date-picker-calendar-grid\">\n <CalendarGridHeader className=\"tds-date-picker-calendar-grid-header\">\n {(day) => (\n <CalendarHeaderCell className=\"tds-date-picker-calendar-header-cell\">\n {day}\n </CalendarHeaderCell>\n )}\n </CalendarGridHeader>\n <CalendarGridBody className=\"tds-date-picker-calendar-grid-body\">\n {(date) => (\n <CalendarCell\n className=\"tds-date-picker-calendar-cell-button\"\n date={date}\n />\n )}\n </CalendarGridBody>\n </CalendarGrid>\n </div>\n </>\n )\n}\n\n/**\n * A date picker allows a user to select a particular date.\n * The input supports keyboard entry of individual day, month, and year segments;\n * the calendar offers month and year quick-pick overlays plus a \"go to today\" shortcut.\n *\n * The date picker automatically displays the value and calendar from the user's locale,\n * and does not require a specific date format.\n *\n * Values are exchanged as `DateValue` from `@internationalized/date`, but\n * `value`, `min`, and `max` also accept ISO date strings (`\"YYYY-MM-DD\"`) for\n * convenience. Restrict the selectable range with `min`/`max`, or mark\n * individual dates as unavailable via `isDateUnavailable`.\n *\n * @component\n * @see {@link https://planningcenter.github.io/tapestry/?path=/docs/components-datepicker--docs | Storybook Documentation}\n */\nexport function DatePicker({\n className,\n description,\n disabled,\n firstDayOfWeek,\n hideLabel,\n invalid,\n isDateUnavailable,\n label,\n max,\n min,\n onChange,\n readOnly,\n required,\n size = \"md\",\n value,\n ...restProps\n}: DatePickerElementProps) {\n const convertedValue = toCalendarDate(value)\n const convertedMin = toCalendarDate(min) ?? undefined\n const convertedMax = toCalendarDate(max) ?? undefined\n\n const combinedClassName = classNames(\n \"tds-field tds-date-picker\",\n {\n \"tds-date-picker--lg\": size === \"lg\",\n \"tds-field--lg\": size === \"lg\",\n },\n className\n )\n\n const [activeOverlay, setActiveOverlay] = useState<\"month\" | \"year\" | null>(\n null\n )\n\n return (\n <AriaDatePicker\n {...restProps}\n aria-label={hideLabel ? label : undefined}\n className={combinedClassName}\n isDateUnavailable={isDateUnavailable}\n isDisabled={disabled}\n isInvalid={invalid}\n isReadOnly={readOnly}\n isRequired={required}\n maxValue={convertedMax}\n minValue={convertedMin}\n onChange={onChange ?? undefined}\n onOpenChange={(isOpen) => {\n if (!isOpen) setActiveOverlay(null)\n }}\n value={convertedValue}\n >\n {!hideLabel && <Label className=\"tds-field-label\">{label}</Label>}\n <Group className=\"tds-field-control tds-date-picker-field\">\n <DateInput className=\"tds-date-picker-input\">\n {(segment) => (\n <DateSegment\n className={\n segment.type === \"literal\"\n ? \"tds-field-date-segment-separator\"\n : \"tds-field-date-segment\"\n }\n segment={segment}\n />\n )}\n </DateInput>\n <Button className=\"tds-btn tds-btn--infield tds-date-picker-button\">\n <Icon aria-hidden symbol=\"general#calendar\" />\n </Button>\n </Group>\n <Popover\n className={classNames(\"tds-date-picker-popover\", {\n \"tds-date-picker-popover--lg\": size === \"lg\",\n })}\n offset={2}\n >\n <Dialog>\n <Calendar\n className=\"tds-date-picker-calendar\"\n firstDayOfWeek={firstDayOfWeek}\n >\n <DatePickerCalendarBody\n activeOverlay={activeOverlay}\n setActiveOverlay={setActiveOverlay}\n />\n </Calendar>\n </Dialog>\n </Popover>\n {description && (\n <Text\n elementType=\"p\"\n className=\"tds-field-description\"\n slot=\"description\"\n >\n <Icon\n aria-hidden\n className=\"tds-field-description-invalid-icon\"\n symbol=\"general#exclamation-triangle\"\n />\n {description}\n </Text>\n )}\n </AriaDatePicker>\n )\n}\n\nDatePicker.displayName = \"DatePicker\"\n"],"names":["todayCalendar","getLocalTimeZone"],"mappings":";;;;;;;AAqCA,MAAM,MAAM,GAAGA,yCAAa,CAACC,yCAAgB,EAAE,CAAC;AACjC,KAAK,CAAC,IAAI,CAAC,EAAE,MAAM,EAAE,EAAE,EAAE,EAAE,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC;AACvC,KAAK,CAAC,IAAI,CAAC,EAAE,MAAM,EAAE,GAAG,EAAE,EAAE,CAAC,CAAC,EAAE,CAAC,KAAK,MAAM,CAAC,IAAI,GAAG,GAAG,GAAG,CAAC"}
|
|
1
|
+
{"version":3,"file":"DatePicker.js","sources":["../../../src/components/date-picker/DatePicker.tsx"],"sourcesContent":["import \"../button/btn.css\"\nimport \"../input-text-base/index.css\"\nimport \"./index.css\"\n\nimport {\n CalendarDate,\n type DateValue,\n getLocalTimeZone,\n parseDate,\n today as todayCalendar,\n} from \"@internationalized/date\"\nimport Icon from \"@utilities/Icon\"\nimport type { CombineAriaPropsWithCustomProps } from \"@utilities/reactAriaProps\"\nimport classNames from \"classnames\"\nimport React, { type ReactNode, useContext, useMemo, useState } from \"react\"\nimport {\n Button,\n Calendar,\n CalendarCell,\n CalendarGrid,\n CalendarGridBody,\n CalendarGridHeader,\n CalendarHeaderCell,\n CalendarStateContext,\n DateInput,\n DatePicker as AriaDatePicker,\n type DatePickerProps as AriaDatePickerProps,\n DateSegment,\n Dialog,\n Group,\n Label,\n ListBox,\n ListBoxItem,\n Popover,\n Text,\n} from \"react-aria-components\"\n\nexport type DatePickerSize = \"md\" | \"lg\"\n\nexport type DatePickerDateValue = DateValue | string\n\nfunction toCalendarDate(\n input: DatePickerDateValue | null | undefined\n): DateValue | null | undefined {\n if (input === null) return null\n if (input === undefined) return undefined\n\n if (typeof input === \"object\" && \"calendar\" in input) {\n return input\n }\n\n return parseDate(input)\n}\n\nexport interface DatePickerProps {\n /** Helper text displayed below the component. Styled as error text when `invalid` is `true`. */\n description?: string\n /** Disables the input and calendar button. */\n disabled?: boolean\n /** Sets the first day of the week in the calendar. Defaults to locale-appropriate value. */\n firstDayOfWeek?: \"fri\" | \"mon\" | \"sat\" | \"sun\" | \"thu\" | \"tue\" | \"wed\"\n /** If `true`, the `label` text is rendered as an `aria-label` instead of a visible label element. */\n hideLabel?: boolean\n /** Whether the input is in an invalid state. */\n invalid?: boolean\n /** Callback that returns `true` for dates that should be visible but not selectable. */\n isDateUnavailable?: (date: DateValue) => boolean\n /** Accessible label for the field. */\n label: string\n /** Maximum selectable date. Accepts a DateValue or ISO date string. */\n max?: DatePickerDateValue\n /** Minimum selectable date. Accepts a DateValue or ISO date string. */\n min?: DatePickerDateValue\n /** Called when the selected date changes. */\n onChange?: (value: DateValue | null) => void\n /** If `true`, allows the value to be read but not changed. */\n readOnly?: boolean\n /** If `true`, appends an asterisk at the end of the label text. */\n required?: boolean\n /** The size of the date picker. */\n size?: DatePickerSize\n /** The controlled value. Accepts a DateValue or ISO date string. */\n value?: DatePickerDateValue | null\n}\n\ntype AriaDatePickerPropsToOmit =\n | \"children\"\n | \"defaultOpen\"\n | \"defaultValue\"\n | \"granularity\"\n | \"hideTimeZone\"\n | \"hourCycle\"\n | \"pageBehavior\"\n | \"placeholderValue\"\n | \"shouldCloseOnSelect\"\n | \"shouldForceLeadingZeros\"\n | \"slot\"\n\ntype AriaDatePickerPropsToInclude = \"isOpen\" | \"name\" | \"onOpenChange\"\n\nexport type DatePickerElementProps = CombineAriaPropsWithCustomProps<\n AriaDatePickerProps<DateValue>,\n DatePickerProps,\n AriaDatePickerPropsToOmit,\n AriaDatePickerPropsToInclude\n>\n\nfunction DatePickerOverlay({\n children,\n variant,\n}: {\n children: ReactNode\n variant: \"month\" | \"year\"\n}) {\n return (\n <div\n aria-label={`Select ${variant}`}\n aria-modal=\"true\"\n className={`tds-date-picker-overlay tds-date-picker-overlay--${variant}`}\n role=\"dialog\"\n >\n {children}\n </div>\n )\n}\n\nfunction DatePickerCalendarBody({\n activeOverlay,\n setActiveOverlay,\n}: {\n activeOverlay: \"month\" | \"year\" | null\n setActiveOverlay: (overlay: \"month\" | \"year\" | null) => void\n}) {\n // Read and drive Calendar's focused date through its state context. This\n // lets react-aria-components own the \"open to selected month\" behavior:\n // when the popover opens, Calendar mounts and auto-focuses the DatePicker's\n // current value (whether typed into the input segments or set via `value`).\n const state = useContext(CalendarStateContext)!\n const focusedDate = state.focusedDate\n const today = todayCalendar(getLocalTimeZone())\n const MONTHS = Array.from({ length: 12 }, (_, i) => i)\n const YEARS = Array.from({ length: 131 }, (_, i) => today.year - 100 + i)\n const shortMonthFormatter = useMemo(\n () => new Intl.DateTimeFormat(undefined, { month: \"short\" }),\n []\n )\n const longMonthFormatter = useMemo(\n () => new Intl.DateTimeFormat(undefined, { month: \"long\" }),\n []\n )\n\n function handleOverlaySelectionChange(\n keys: \"all\" | Set<number | string>,\n onSelect: (key: number) => void\n ) {\n if (keys === \"all\") return\n const [first] = Array.from(keys)\n if (first !== undefined) onSelect(Number(first))\n }\n\n function handleMonthSelect(monthIndex: number) {\n state.setFocusedDate(new CalendarDate(focusedDate.year, monthIndex + 1, 1))\n setActiveOverlay(null)\n }\n\n function handleYearSelect(year: number) {\n state.setFocusedDate(new CalendarDate(year, focusedDate.month, 1))\n setActiveOverlay(null)\n }\n\n return (\n <>\n <header className=\"tds-date-picker-calendar-header\">\n <div className=\"tds-date-picker-calendar-heading\">\n <Button\n aria-expanded={activeOverlay === \"month\"}\n aria-haspopup=\"dialog\"\n className=\"tds-date-picker-calendar-overlay-trigger\"\n onPress={() =>\n setActiveOverlay(activeOverlay === \"month\" ? null : \"month\")\n }\n slot={null}\n >\n {longMonthFormatter.format(\n new Date(2000, focusedDate.month - 1, 1)\n )}\n </Button>\n <Button\n aria-expanded={activeOverlay === \"year\"}\n aria-haspopup=\"dialog\"\n className=\"tds-date-picker-calendar-overlay-trigger\"\n onPress={() =>\n setActiveOverlay(activeOverlay === \"year\" ? null : \"year\")\n }\n slot={null}\n >\n {focusedDate.year}\n </Button>\n </div>\n {activeOverlay ? (\n <Button\n aria-label={`Close ${activeOverlay} picker`}\n className=\"tds-date-picker-calendar-nav\"\n onPress={() => setActiveOverlay(null)}\n slot={null}\n >\n <Icon aria-hidden symbol=\"general#x\" />\n </Button>\n ) : (\n <>\n <Button\n aria-label=\"Go to today\"\n className=\"tds-date-picker-calendar-nav tds-date-picker-calendar-nav--lg\"\n style={{\n visibility:\n focusedDate.month === today.month &&\n focusedDate.year === today.year\n ? \"hidden\"\n : undefined,\n }}\n onPress={() => {\n state.setFocusedDate(today)\n state.setFocused(true)\n }}\n slot={null}\n >\n {/* TODO: Add to icon library and use Icon once icon is decided on */}\n <svg\n aria-hidden\n xmlns=\"http://www.w3.org/2000/svg\"\n fill=\"currentColor\"\n viewBox=\"0 0 16 16\"\n className=\"symbol\"\n >\n <path d=\"M13.444 14.222H2.556V5.667h10.888zm0-12.444h-.777V.222h-1.556v1.556H4.889V.222H3.333v1.556h-.777a1.55 1.55 0 0 0-1.548 1.555L1 14.222a1.555 1.555 0 0 0 1.556 1.556h10.888A1.56 1.56 0 0 0 15 14.222V3.333a1.56 1.56 0 0 0-1.556-1.555\" />\n <circle cx=\"8\" cy=\"9.75\" r=\"2.25\" />\n </svg>\n </Button>\n <Button\n aria-label=\"Previous month\"\n className=\"tds-date-picker-calendar-nav\"\n slot=\"previous\"\n >\n <Icon aria-hidden symbol=\"general#left-chevron\" />\n </Button>\n <Button\n aria-label=\"Next month\"\n className=\"tds-date-picker-calendar-nav\"\n slot=\"next\"\n >\n <Icon aria-hidden symbol=\"general#right-chevron\" />\n </Button>\n </>\n )}\n </header>\n <div className=\"tds-date-picker-calendar-body\">\n {activeOverlay === \"month\" && (\n <DatePickerOverlay variant=\"month\">\n <ListBox\n aria-label=\"Months\"\n // eslint-disable-next-line jsx-a11y/no-autofocus -- focusing the active item on dialog open is required per ARIA authoring practices\n autoFocus\n className=\"tds-date-picker-overlay-list\"\n disallowEmptySelection\n escapeKeyBehavior=\"none\"\n layout=\"grid\"\n onSelectionChange={(keys) =>\n handleOverlaySelectionChange(keys, handleMonthSelect)\n }\n selectedKeys={[String(focusedDate.month - 1)]}\n selectionMode=\"single\"\n >\n {MONTHS.map((i) => {\n const date = new Date(2000, i, 1)\n const shortMonth = shortMonthFormatter.format(date)\n const longMonth = longMonthFormatter.format(date)\n\n return (\n <ListBoxItem\n className=\"tds-date-picker-overlay-cell\"\n id={String(i)}\n key={i}\n aria-label={longMonth}\n textValue={longMonth}\n >\n {shortMonth}\n </ListBoxItem>\n )\n })}\n </ListBox>\n </DatePickerOverlay>\n )}\n {activeOverlay === \"year\" && (\n <DatePickerOverlay variant=\"year\">\n <ListBox\n aria-label=\"Years\"\n // eslint-disable-next-line jsx-a11y/no-autofocus -- focusing the active item on dialog open is required per ARIA authoring practices\n autoFocus\n className=\"tds-date-picker-overlay-list\"\n disallowEmptySelection\n escapeKeyBehavior=\"none\"\n layout=\"grid\"\n onSelectionChange={(keys) =>\n handleOverlaySelectionChange(keys, handleYearSelect)\n }\n selectedKeys={[String(focusedDate.year)]}\n selectionMode=\"single\"\n >\n {YEARS.map((year) => (\n <ListBoxItem\n className=\"tds-date-picker-overlay-cell\"\n id={String(year)}\n key={year}\n textValue={String(year)}\n >\n {year}\n </ListBoxItem>\n ))}\n </ListBox>\n </DatePickerOverlay>\n )}\n <CalendarGrid className=\"tds-date-picker-calendar-grid\">\n <CalendarGridHeader className=\"tds-date-picker-calendar-grid-header\">\n {(day) => (\n <CalendarHeaderCell className=\"tds-date-picker-calendar-header-cell\">\n {day}\n </CalendarHeaderCell>\n )}\n </CalendarGridHeader>\n <CalendarGridBody className=\"tds-date-picker-calendar-grid-body\">\n {(date) => (\n <CalendarCell\n className=\"tds-date-picker-calendar-cell-button\"\n date={date}\n />\n )}\n </CalendarGridBody>\n </CalendarGrid>\n </div>\n </>\n )\n}\n\n/**\n * A date picker allows a user to select a particular date.\n * The input supports keyboard entry of individual day, month, and year segments;\n * the calendar offers month and year quick-pick overlays plus a \"go to today\" shortcut.\n *\n * The date picker automatically displays the value and calendar from the user's locale,\n * and does not require a specific date format.\n *\n * Values are exchanged as `DateValue` from `@internationalized/date`, but\n * `value`, `min`, and `max` also accept ISO date strings (`\"YYYY-MM-DD\"`) for\n * convenience. Restrict the selectable range with `min`/`max`, or mark\n * individual dates as unavailable via `isDateUnavailable`.\n *\n * @component\n * @see {@link https://planningcenter.github.io/tapestry/?path=/docs/components-datepicker--docs | Storybook Documentation}\n */\nexport function DatePicker({\n className,\n description,\n disabled,\n firstDayOfWeek,\n hideLabel,\n invalid,\n isDateUnavailable,\n label,\n max,\n min,\n onChange,\n readOnly,\n required,\n size = \"md\",\n value,\n ...restProps\n}: DatePickerElementProps) {\n const convertedValue = toCalendarDate(value)\n const convertedMin = toCalendarDate(min) ?? undefined\n const convertedMax = toCalendarDate(max) ?? undefined\n\n const combinedClassName = classNames(\n \"tds-field tds-date-picker\",\n {\n \"tds-date-picker--lg\": size === \"lg\",\n \"tds-field--lg\": size === \"lg\",\n },\n className\n )\n\n const [activeOverlay, setActiveOverlay] = useState<\"month\" | \"year\" | null>(\n null\n )\n\n return (\n <AriaDatePicker\n {...restProps}\n aria-label={hideLabel ? label : undefined}\n className={combinedClassName}\n isDateUnavailable={isDateUnavailable}\n isDisabled={disabled}\n isInvalid={invalid}\n isReadOnly={readOnly}\n isRequired={required}\n maxValue={convertedMax}\n minValue={convertedMin}\n onChange={onChange ?? undefined}\n onOpenChange={(isOpen) => {\n if (!isOpen) setActiveOverlay(null)\n }}\n value={convertedValue}\n >\n {!hideLabel && <Label className=\"tds-field-label\">{label}</Label>}\n <Group className=\"tds-field-control tds-date-picker-field\">\n <DateInput className=\"tds-date-picker-input\">\n {(segment) => (\n <DateSegment\n className={\n segment.type === \"literal\"\n ? \"tds-field-date-segment-separator\"\n : \"tds-field-date-segment\"\n }\n segment={segment}\n />\n )}\n </DateInput>\n <Button className=\"tds-btn tds-btn--infield tds-date-picker-button\">\n <Icon aria-hidden symbol=\"general#calendar\" />\n </Button>\n </Group>\n <Popover\n className={classNames(\"tds-date-picker-popover\", {\n \"tds-date-picker-popover--lg\": size === \"lg\",\n })}\n offset={2}\n >\n <Dialog>\n <Calendar\n className=\"tds-date-picker-calendar\"\n firstDayOfWeek={firstDayOfWeek}\n >\n <DatePickerCalendarBody\n activeOverlay={activeOverlay}\n setActiveOverlay={setActiveOverlay}\n />\n </Calendar>\n </Dialog>\n </Popover>\n {description && (\n <Text\n elementType=\"p\"\n className=\"tds-field-description\"\n slot=\"description\"\n >\n <Icon\n aria-hidden\n className=\"tds-field-description-invalid-icon\"\n symbol=\"general#exclamation-triangle\"\n />\n {description}\n </Text>\n )}\n </AriaDatePicker>\n )\n}\n\nDatePicker.displayName = \"DatePicker\"\n"],"names":["parseDate","React","todayCalendar","getLocalTimeZone","CalendarDate","AriaDatePicker"],"mappings":";;;;;;;;AAyCA,SAAS,cAAc,CACrB,KAA6C,EAAA;IAE7C,IAAI,KAAK,KAAK,IAAI;AAAE,QAAA,OAAO,IAAI;IAC/B,IAAI,KAAK,KAAK,SAAS;AAAE,QAAA,OAAO,SAAS;IAEzC,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,UAAU,IAAI,KAAK,EAAE;AACpD,QAAA,OAAO,KAAK;IACd;AAEA,IAAA,OAAOA,wCAAS,CAAC,KAAK,CAAC;AACzB;AAuDA,SAAS,iBAAiB,CAAC,EACzB,QAAQ,EACR,OAAO,GAIR,EAAA;IACC,QACEC,oDACc,CAAA,OAAA,EAAU,OAAO,EAAE,EAAA,YAAA,EACpB,MAAM,EACjB,SAAS,EAAE,oDAA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A,CAAC,IAAI,IACH,WAAW,EAAC,GAAG,EACf,SAAS,EAAC,uBAAuB,EACjC,IAAI,EAAC,aAAa,EAAA;YAElBA,cAAA,CAAA,aAAA,CAAC,IAAI,yBAEH,SAAS,EAAC,oCAAoC,EAC9C,MAAM,EAAC,8BAA8B,EAAA,CACrC;AACD,YAAA,WAAW,CACP,CACR,CACc;AAErB;AAEA,UAAU,CAAC,WAAW,GAAG,YAAY;;;;"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import '../../
|
|
2
|
-
import { defineCustomElement } from '../../
|
|
3
|
-
import { defineCustomElement as defineCustomElement$1 } from '../../
|
|
1
|
+
import '../../tapestry-wc/dist/components/p-nyMzpSUR.js';
|
|
2
|
+
import { defineCustomElement } from '../../tapestry-wc/dist/components/tds-page-header.js';
|
|
3
|
+
import { defineCustomElement as defineCustomElement$1 } from '../../tapestry-wc/dist/components/tds-page-header-nav.js';
|
|
4
4
|
|
|
5
5
|
defineCustomElement();
|
|
6
6
|
defineCustomElement$1();
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import '../../
|
|
2
|
-
import { defineCustomElement } from '../../
|
|
3
|
-
import { defineCustomElement as defineCustomElement$1 } from '../../
|
|
4
|
-
import { defineCustomElement as defineCustomElement$3 } from '../../
|
|
5
|
-
import { defineCustomElement as defineCustomElement$2 } from '../../
|
|
1
|
+
import '../../tapestry-wc/dist/components/p-nyMzpSUR.js';
|
|
2
|
+
import { defineCustomElement } from '../../tapestry-wc/dist/components/tds-sidenav.js';
|
|
3
|
+
import { defineCustomElement as defineCustomElement$1 } from '../../tapestry-wc/dist/components/tds-sidenav-item.js';
|
|
4
|
+
import { defineCustomElement as defineCustomElement$3 } from '../../tapestry-wc/dist/components/tds-sidenav-responsive-header.js';
|
|
5
|
+
import { defineCustomElement as defineCustomElement$2 } from '../../tapestry-wc/dist/components/tds-sidenav-section.js';
|
|
6
6
|
|
|
7
7
|
defineCustomElement();
|
|
8
8
|
defineCustomElement$1();
|
|
@@ -1,6 +1,24 @@
|
|
|
1
|
+
import { CalendarDate as $35ea8db9cb2ccb90$export$99faa760c7908e4f } from './CalendarDate.js';
|
|
1
2
|
import { toCalendar as $11d87f3f76e88657$export$b4a036af3fc0b032 } from './conversion.js';
|
|
2
3
|
import { GregorianCalendar as $3b62074eb05584b2$export$80ee6245ec4f29ec } from './GregorianCalendar.js';
|
|
3
4
|
|
|
5
|
+
const $fae977aafc393c5c$var$DATE_RE = /^([+-]\d{6}|\d{4})-(\d{2})-(\d{2})$/;
|
|
6
|
+
const $fae977aafc393c5c$var$ABSOLUTE_RE = /^([+-]\d{6}|\d{4})-(\d{2})-(\d{2})(?:T(\d{2}))?(?::(\d{2}))?(?::(\d{2}))?(\.\d+)?(?:(?:([+-]\d{2})(?::?(\d{2}))?)|Z)$/;
|
|
7
|
+
function $fae977aafc393c5c$export$6b862160d295c8e(value) {
|
|
8
|
+
let m = value.match($fae977aafc393c5c$var$DATE_RE);
|
|
9
|
+
if (!m) {
|
|
10
|
+
if ($fae977aafc393c5c$var$ABSOLUTE_RE.test(value)) throw new Error(`Invalid ISO 8601 date string: ${value}. Use parseAbsolute() instead.`);
|
|
11
|
+
throw new Error('Invalid ISO 8601 date string: ' + value);
|
|
12
|
+
}
|
|
13
|
+
let date = new ($35ea8db9cb2ccb90$export$99faa760c7908e4f)($fae977aafc393c5c$var$parseNumber(m[1], 0, 9999), $fae977aafc393c5c$var$parseNumber(m[2], 1, 12), 1);
|
|
14
|
+
date.day = $fae977aafc393c5c$var$parseNumber(m[3], 1, date.calendar.getDaysInMonth(date));
|
|
15
|
+
return date;
|
|
16
|
+
}
|
|
17
|
+
function $fae977aafc393c5c$var$parseNumber(value, min, max) {
|
|
18
|
+
let val = Number(value);
|
|
19
|
+
if (val < min || val > max) throw new RangeError(`Value out of range: ${min} <= ${val} <= ${max}`);
|
|
20
|
+
return val;
|
|
21
|
+
}
|
|
4
22
|
function $fae977aafc393c5c$export$f59dee82248f5ad4(time) {
|
|
5
23
|
return `${String(time.hour).padStart(2, '0')}:${String(time.minute).padStart(2, '0')}:${String(time.second).padStart(2, '0')}${time.millisecond ? String(time.millisecond / 1000).slice(1) : ''}`;
|
|
6
24
|
}
|
|
@@ -29,5 +47,5 @@ function $fae977aafc393c5c$export$bf79f1ebf4b18792(date) {
|
|
|
29
47
|
return `${$fae977aafc393c5c$export$4223de14708adc63(date)}${$fae977aafc393c5c$var$offsetToString(date.offset)}[${date.timeZone}]`;
|
|
30
48
|
}
|
|
31
49
|
|
|
32
|
-
export { $fae977aafc393c5c$export$4223de14708adc63 as dateTimeToString, $fae977aafc393c5c$export$60dfd74aa96791bd as dateToString, $fae977aafc393c5c$export$f59dee82248f5ad4 as timeToString, $fae977aafc393c5c$export$bf79f1ebf4b18792 as zonedDateTimeToString };
|
|
50
|
+
export { $fae977aafc393c5c$export$4223de14708adc63 as dateTimeToString, $fae977aafc393c5c$export$60dfd74aa96791bd as dateToString, $fae977aafc393c5c$export$6b862160d295c8e as parseDate, $fae977aafc393c5c$export$f59dee82248f5ad4 as timeToString, $fae977aafc393c5c$export$bf79f1ebf4b18792 as zonedDateTimeToString };
|
|
33
51
|
//# sourceMappingURL=string.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"string.js","sources":["../../../../../../../node_modules/@internationalized/date/dist/string.mjs"],"sourcesContent":["import {CalendarDate as $35ea8db9cb2ccb90$export$99faa760c7908e4f, CalendarDateTime as $35ea8db9cb2ccb90$export$ca871e8dbb80966f, Time as $35ea8db9cb2ccb90$export$680ea196effce5f, ZonedDateTime as $35ea8db9cb2ccb90$export$d3b7288e7994edea} from \"./CalendarDate.mjs\";\nimport {epochFromDate as $11d87f3f76e88657$export$bd4fb2bc8bb06fb, fromAbsolute as $11d87f3f76e88657$export$1b96692a1ba042ac, possibleAbsolutes as $11d87f3f76e88657$export$136f38efe7caf549, toAbsolute as $11d87f3f76e88657$export$5107c82f94518f5c, toCalendar as $11d87f3f76e88657$export$b4a036af3fc0b032, toCalendarDateTime as $11d87f3f76e88657$export$b21e0b124e224484, toTimeZone as $11d87f3f76e88657$export$538b00033cc11c75} from \"./conversion.mjs\";\nimport {getLocalTimeZone as $14e0f24ef4ac5c92$export$aa8b41735afcabd2} from \"./queries.mjs\";\nimport {GregorianCalendar as $3b62074eb05584b2$export$80ee6245ec4f29ec} from \"./GregorianCalendar.mjs\";\n\n/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */ \n\n\n\nconst $fae977aafc393c5c$var$TIME_RE = /^(\\d{2})(?::(\\d{2}))?(?::(\\d{2}))?(\\.\\d+)?$/;\nconst $fae977aafc393c5c$var$DATE_RE = /^([+-]\\d{6}|\\d{4})-(\\d{2})-(\\d{2})$/;\nconst $fae977aafc393c5c$var$DATE_TIME_RE = /^([+-]\\d{6}|\\d{4})-(\\d{2})-(\\d{2})(?:T(\\d{2}))?(?::(\\d{2}))?(?::(\\d{2}))?(\\.\\d+)?$/;\nconst $fae977aafc393c5c$var$ZONED_DATE_TIME_RE = /^([+-]\\d{6}|\\d{4})-(\\d{2})-(\\d{2})(?:T(\\d{2}))?(?::(\\d{2}))?(?::(\\d{2}))?(\\.\\d+)?(?:([+-]\\d{2})(?::?(\\d{2}))?(?::?(\\d{2}))?)?\\[(.*?)\\]$/;\nconst $fae977aafc393c5c$var$ABSOLUTE_RE = /^([+-]\\d{6}|\\d{4})-(\\d{2})-(\\d{2})(?:T(\\d{2}))?(?::(\\d{2}))?(?::(\\d{2}))?(\\.\\d+)?(?:(?:([+-]\\d{2})(?::?(\\d{2}))?)|Z)$/;\nconst $fae977aafc393c5c$var$DATE_TIME_DURATION_RE = /^((?<negative>-)|\\+)?P((?<years>\\d*)Y)?((?<months>\\d*)M)?((?<weeks>\\d*)W)?((?<days>\\d*)D)?((?<time>T)((?<hours>\\d*[.,]?\\d{1,9})H)?((?<minutes>\\d*[.,]?\\d{1,9})M)?((?<seconds>\\d*[.,]?\\d{1,9})S)?)?$/;\nconst $fae977aafc393c5c$var$requiredDurationTimeGroups = [\n 'hours',\n 'minutes',\n 'seconds'\n];\nconst $fae977aafc393c5c$var$requiredDurationGroups = [\n 'years',\n 'months',\n 'weeks',\n 'days',\n ...$fae977aafc393c5c$var$requiredDurationTimeGroups\n];\nfunction $fae977aafc393c5c$export$c9698ec7f05a07e1(value) {\n let m = value.match($fae977aafc393c5c$var$TIME_RE);\n if (!m) throw new Error('Invalid ISO 8601 time string: ' + value);\n return new (0, $35ea8db9cb2ccb90$export$680ea196effce5f)($fae977aafc393c5c$var$parseNumber(m[1], 0, 23), m[2] ? $fae977aafc393c5c$var$parseNumber(m[2], 0, 59) : 0, m[3] ? $fae977aafc393c5c$var$parseNumber(m[3], 0, 59) : 0, m[4] ? $fae977aafc393c5c$var$parseNumber(m[4], 0, Infinity) * 1000 : 0);\n}\nfunction $fae977aafc393c5c$export$6b862160d295c8e(value) {\n let m = value.match($fae977aafc393c5c$var$DATE_RE);\n if (!m) {\n if ($fae977aafc393c5c$var$ABSOLUTE_RE.test(value)) throw new Error(`Invalid ISO 8601 date string: ${value}. Use parseAbsolute() instead.`);\n throw new Error('Invalid ISO 8601 date string: ' + value);\n }\n let date = new (0, $35ea8db9cb2ccb90$export$99faa760c7908e4f)($fae977aafc393c5c$var$parseNumber(m[1], 0, 9999), $fae977aafc393c5c$var$parseNumber(m[2], 1, 12), 1);\n date.day = $fae977aafc393c5c$var$parseNumber(m[3], 1, date.calendar.getDaysInMonth(date));\n return date;\n}\nfunction $fae977aafc393c5c$export$588937bcd60ade55(value) {\n let m = value.match($fae977aafc393c5c$var$DATE_TIME_RE);\n if (!m) {\n if ($fae977aafc393c5c$var$ABSOLUTE_RE.test(value)) throw new Error(`Invalid ISO 8601 date time string: ${value}. Use parseAbsolute() instead.`);\n throw new Error('Invalid ISO 8601 date time string: ' + value);\n }\n let year = $fae977aafc393c5c$var$parseNumber(m[1], -9999, 9999);\n let era = year < 1 ? 'BC' : 'AD';\n let date = new (0, $35ea8db9cb2ccb90$export$ca871e8dbb80966f)(era, year < 1 ? -year + 1 : year, $fae977aafc393c5c$var$parseNumber(m[2], 1, 12), 1, m[4] ? $fae977aafc393c5c$var$parseNumber(m[4], 0, 23) : 0, m[5] ? $fae977aafc393c5c$var$parseNumber(m[5], 0, 59) : 0, m[6] ? $fae977aafc393c5c$var$parseNumber(m[6], 0, 59) : 0, m[7] ? $fae977aafc393c5c$var$parseNumber(m[7], 0, Infinity) * 1000 : 0);\n date.day = $fae977aafc393c5c$var$parseNumber(m[3], 0, date.calendar.getDaysInMonth(date));\n return date;\n}\nfunction $fae977aafc393c5c$export$fd7893f06e92a6a4(value, disambiguation) {\n let m = value.match($fae977aafc393c5c$var$ZONED_DATE_TIME_RE);\n if (!m) throw new Error('Invalid ISO 8601 date time string: ' + value);\n let year = $fae977aafc393c5c$var$parseNumber(m[1], -9999, 9999);\n let era = year < 1 ? 'BC' : 'AD';\n let date = new (0, $35ea8db9cb2ccb90$export$d3b7288e7994edea)(era, year < 1 ? -year + 1 : year, $fae977aafc393c5c$var$parseNumber(m[2], 1, 12), 1, m[11], 0, m[4] ? $fae977aafc393c5c$var$parseNumber(m[4], 0, 23) : 0, m[5] ? $fae977aafc393c5c$var$parseNumber(m[5], 0, 59) : 0, m[6] ? $fae977aafc393c5c$var$parseNumber(m[6], 0, 59) : 0, m[7] ? $fae977aafc393c5c$var$parseNumber(m[7], 0, Infinity) * 1000 : 0);\n date.day = $fae977aafc393c5c$var$parseNumber(m[3], 0, date.calendar.getDaysInMonth(date));\n let plainDateTime = (0, $11d87f3f76e88657$export$b21e0b124e224484)(date);\n let ms;\n if (m[8]) {\n let hourOffset = $fae977aafc393c5c$var$parseNumber(m[8], -23, 23);\n var _m_, _m_1;\n date.offset = Math.sign(hourOffset) * (Math.abs(hourOffset) * 3600000 + $fae977aafc393c5c$var$parseNumber((_m_ = m[9]) !== null && _m_ !== void 0 ? _m_ : '0', 0, 59) * 60000 + $fae977aafc393c5c$var$parseNumber((_m_1 = m[10]) !== null && _m_1 !== void 0 ? _m_1 : '0', 0, 59) * 1000);\n ms = (0, $11d87f3f76e88657$export$bd4fb2bc8bb06fb)(date) - date.offset;\n // Validate offset against parsed date.\n let absolutes = (0, $11d87f3f76e88657$export$136f38efe7caf549)(plainDateTime, date.timeZone);\n if (!absolutes.includes(ms)) throw new Error(`Offset ${$fae977aafc393c5c$var$offsetToString(date.offset)} is invalid for ${$fae977aafc393c5c$export$4223de14708adc63(date)} in ${date.timeZone}`);\n } else // Convert to absolute and back to fix invalid times due to DST.\n ms = (0, $11d87f3f76e88657$export$5107c82f94518f5c)((0, $11d87f3f76e88657$export$b21e0b124e224484)(plainDateTime), date.timeZone, disambiguation);\n return (0, $11d87f3f76e88657$export$1b96692a1ba042ac)(ms, date.timeZone);\n}\nfunction $fae977aafc393c5c$export$5adfdab05168c219(value, timeZone) {\n let m = value.match($fae977aafc393c5c$var$ABSOLUTE_RE);\n if (!m) throw new Error('Invalid ISO 8601 date time string: ' + value);\n let year = $fae977aafc393c5c$var$parseNumber(m[1], -9999, 9999);\n let era = year < 1 ? 'BC' : 'AD';\n let date = new (0, $35ea8db9cb2ccb90$export$d3b7288e7994edea)(era, year < 1 ? -year + 1 : year, $fae977aafc393c5c$var$parseNumber(m[2], 1, 12), 1, timeZone, 0, m[4] ? $fae977aafc393c5c$var$parseNumber(m[4], 0, 23) : 0, m[5] ? $fae977aafc393c5c$var$parseNumber(m[5], 0, 59) : 0, m[6] ? $fae977aafc393c5c$var$parseNumber(m[6], 0, 59) : 0, m[7] ? $fae977aafc393c5c$var$parseNumber(m[7], 0, Infinity) * 1000 : 0);\n date.day = $fae977aafc393c5c$var$parseNumber(m[3], 0, date.calendar.getDaysInMonth(date));\n var _m_;\n if (m[8]) date.offset = $fae977aafc393c5c$var$parseNumber(m[8], -23, 23) * 3600000 + $fae977aafc393c5c$var$parseNumber((_m_ = m[9]) !== null && _m_ !== void 0 ? _m_ : '0', 0, 59) * 60000;\n return (0, $11d87f3f76e88657$export$538b00033cc11c75)(date, timeZone);\n}\nfunction $fae977aafc393c5c$export$8e384432362ed0f0(value) {\n return $fae977aafc393c5c$export$5adfdab05168c219(value, (0, $14e0f24ef4ac5c92$export$aa8b41735afcabd2)());\n}\nfunction $fae977aafc393c5c$var$parseNumber(value, min, max) {\n let val = Number(value);\n if (val < min || val > max) throw new RangeError(`Value out of range: ${min} <= ${val} <= ${max}`);\n return val;\n}\nfunction $fae977aafc393c5c$export$f59dee82248f5ad4(time) {\n return `${String(time.hour).padStart(2, '0')}:${String(time.minute).padStart(2, '0')}:${String(time.second).padStart(2, '0')}${time.millisecond ? String(time.millisecond / 1000).slice(1) : ''}`;\n}\nfunction $fae977aafc393c5c$export$60dfd74aa96791bd(date) {\n let gregorianDate = (0, $11d87f3f76e88657$export$b4a036af3fc0b032)(date, new (0, $3b62074eb05584b2$export$80ee6245ec4f29ec)());\n let year;\n if (gregorianDate.era === 'BC') year = gregorianDate.year === 1 ? '0000' : '-' + String(Math.abs(1 - gregorianDate.year)).padStart(6, '00');\n else year = String(gregorianDate.year).padStart(4, '0');\n return `${year}-${String(gregorianDate.month).padStart(2, '0')}-${String(gregorianDate.day).padStart(2, '0')}`;\n}\nfunction $fae977aafc393c5c$export$4223de14708adc63(date) {\n // @ts-ignore\n return `${$fae977aafc393c5c$export$60dfd74aa96791bd(date)}T${$fae977aafc393c5c$export$f59dee82248f5ad4(date)}`;\n}\nfunction $fae977aafc393c5c$var$offsetToString(offset) {\n let sign = Math.sign(offset) < 0 ? '-' : '+';\n offset = Math.abs(offset);\n let offsetHours = Math.floor(offset / 3600000);\n let offsetMinutes = Math.floor(offset % 3600000 / 60000);\n let offsetSeconds = Math.floor(offset % 3600000 % 60000 / 1000);\n let stringOffset = `${sign}${String(offsetHours).padStart(2, '0')}:${String(offsetMinutes).padStart(2, '0')}`;\n if (offsetSeconds !== 0) stringOffset += `:${String(offsetSeconds).padStart(2, '0')}`;\n return stringOffset;\n}\nfunction $fae977aafc393c5c$export$bf79f1ebf4b18792(date) {\n return `${$fae977aafc393c5c$export$4223de14708adc63(date)}${$fae977aafc393c5c$var$offsetToString(date.offset)}[${date.timeZone}]`;\n}\nfunction $fae977aafc393c5c$export$ecae829bb3747ea6(value) {\n var _match_groups, _match_groups1, _match_groups2, _match_groups3, _match_groups4, _match_groups5, _match_groups6, _match_groups7, _match_groups8;\n const match = value.match($fae977aafc393c5c$var$DATE_TIME_DURATION_RE);\n if (!match) throw new Error(`Invalid ISO 8601 Duration string: ${value}`);\n const parseDurationGroup = (group, isNegative)=>{\n if (!group) return 0;\n try {\n const sign = isNegative ? -1 : 1;\n return sign * Number(group.replace(',', '.'));\n } catch {\n throw new Error(`Invalid ISO 8601 Duration string: ${value}`);\n }\n };\n const isNegative = !!((_match_groups = match.groups) === null || _match_groups === void 0 ? void 0 : _match_groups.negative);\n const hasRequiredGroups = $fae977aafc393c5c$var$requiredDurationGroups.some((group)=>{\n var _match_groups;\n return (_match_groups = match.groups) === null || _match_groups === void 0 ? void 0 : _match_groups[group];\n });\n if (!hasRequiredGroups) throw new Error(`Invalid ISO 8601 Duration string: ${value}`);\n const durationStringIncludesTime = (_match_groups1 = match.groups) === null || _match_groups1 === void 0 ? void 0 : _match_groups1.time;\n if (durationStringIncludesTime) {\n const hasRequiredDurationTimeGroups = $fae977aafc393c5c$var$requiredDurationTimeGroups.some((group)=>{\n var _match_groups;\n return (_match_groups = match.groups) === null || _match_groups === void 0 ? void 0 : _match_groups[group];\n });\n if (!hasRequiredDurationTimeGroups) throw new Error(`Invalid ISO 8601 Duration string: ${value}`);\n }\n const duration = {\n years: parseDurationGroup((_match_groups2 = match.groups) === null || _match_groups2 === void 0 ? void 0 : _match_groups2.years, isNegative),\n months: parseDurationGroup((_match_groups3 = match.groups) === null || _match_groups3 === void 0 ? void 0 : _match_groups3.months, isNegative),\n weeks: parseDurationGroup((_match_groups4 = match.groups) === null || _match_groups4 === void 0 ? void 0 : _match_groups4.weeks, isNegative),\n days: parseDurationGroup((_match_groups5 = match.groups) === null || _match_groups5 === void 0 ? void 0 : _match_groups5.days, isNegative),\n hours: parseDurationGroup((_match_groups6 = match.groups) === null || _match_groups6 === void 0 ? void 0 : _match_groups6.hours, isNegative),\n minutes: parseDurationGroup((_match_groups7 = match.groups) === null || _match_groups7 === void 0 ? void 0 : _match_groups7.minutes, isNegative),\n seconds: parseDurationGroup((_match_groups8 = match.groups) === null || _match_groups8 === void 0 ? void 0 : _match_groups8.seconds, isNegative)\n };\n if (duration.hours !== undefined && duration.hours % 1 !== 0 && (duration.minutes || duration.seconds)) throw new Error(`Invalid ISO 8601 Duration string: ${value} - only the smallest unit can be fractional`);\n if (duration.minutes !== undefined && duration.minutes % 1 !== 0 && duration.seconds) throw new Error(`Invalid ISO 8601 Duration string: ${value} - only the smallest unit can be fractional`);\n return duration;\n}\n\n\nexport {$fae977aafc393c5c$export$c9698ec7f05a07e1 as parseTime, $fae977aafc393c5c$export$6b862160d295c8e as parseDate, $fae977aafc393c5c$export$588937bcd60ade55 as parseDateTime, $fae977aafc393c5c$export$fd7893f06e92a6a4 as parseZonedDateTime, $fae977aafc393c5c$export$4223de14708adc63 as dateTimeToString, $fae977aafc393c5c$export$5adfdab05168c219 as parseAbsolute, $fae977aafc393c5c$export$8e384432362ed0f0 as parseAbsoluteToLocal, $fae977aafc393c5c$export$f59dee82248f5ad4 as timeToString, $fae977aafc393c5c$export$60dfd74aa96791bd as dateToString, $fae977aafc393c5c$export$bf79f1ebf4b18792 as zonedDateTimeToString, $fae977aafc393c5c$export$ecae829bb3747ea6 as parseDuration};\n//# sourceMappingURL=string.module.js.map\n"],"names":[],"mappings":";;;AA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AAC,CAAC,CAAC;AACrI;;;;","x_google_ignoreList":[0]}
|
|
1
|
+
{"version":3,"file":"string.js","sources":["../../../../../../../node_modules/@internationalized/date/dist/string.mjs"],"sourcesContent":["import {CalendarDate as $35ea8db9cb2ccb90$export$99faa760c7908e4f, CalendarDateTime as $35ea8db9cb2ccb90$export$ca871e8dbb80966f, Time as $35ea8db9cb2ccb90$export$680ea196effce5f, ZonedDateTime as $35ea8db9cb2ccb90$export$d3b7288e7994edea} from \"./CalendarDate.mjs\";\nimport {epochFromDate as $11d87f3f76e88657$export$bd4fb2bc8bb06fb, fromAbsolute as $11d87f3f76e88657$export$1b96692a1ba042ac, possibleAbsolutes as $11d87f3f76e88657$export$136f38efe7caf549, toAbsolute as $11d87f3f76e88657$export$5107c82f94518f5c, toCalendar as $11d87f3f76e88657$export$b4a036af3fc0b032, toCalendarDateTime as $11d87f3f76e88657$export$b21e0b124e224484, toTimeZone as $11d87f3f76e88657$export$538b00033cc11c75} from \"./conversion.mjs\";\nimport {getLocalTimeZone as $14e0f24ef4ac5c92$export$aa8b41735afcabd2} from \"./queries.mjs\";\nimport {GregorianCalendar as $3b62074eb05584b2$export$80ee6245ec4f29ec} from \"./GregorianCalendar.mjs\";\n\n/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */ \n\n\n\nconst $fae977aafc393c5c$var$TIME_RE = /^(\\d{2})(?::(\\d{2}))?(?::(\\d{2}))?(\\.\\d+)?$/;\nconst $fae977aafc393c5c$var$DATE_RE = /^([+-]\\d{6}|\\d{4})-(\\d{2})-(\\d{2})$/;\nconst $fae977aafc393c5c$var$DATE_TIME_RE = /^([+-]\\d{6}|\\d{4})-(\\d{2})-(\\d{2})(?:T(\\d{2}))?(?::(\\d{2}))?(?::(\\d{2}))?(\\.\\d+)?$/;\nconst $fae977aafc393c5c$var$ZONED_DATE_TIME_RE = /^([+-]\\d{6}|\\d{4})-(\\d{2})-(\\d{2})(?:T(\\d{2}))?(?::(\\d{2}))?(?::(\\d{2}))?(\\.\\d+)?(?:([+-]\\d{2})(?::?(\\d{2}))?(?::?(\\d{2}))?)?\\[(.*?)\\]$/;\nconst $fae977aafc393c5c$var$ABSOLUTE_RE = /^([+-]\\d{6}|\\d{4})-(\\d{2})-(\\d{2})(?:T(\\d{2}))?(?::(\\d{2}))?(?::(\\d{2}))?(\\.\\d+)?(?:(?:([+-]\\d{2})(?::?(\\d{2}))?)|Z)$/;\nconst $fae977aafc393c5c$var$DATE_TIME_DURATION_RE = /^((?<negative>-)|\\+)?P((?<years>\\d*)Y)?((?<months>\\d*)M)?((?<weeks>\\d*)W)?((?<days>\\d*)D)?((?<time>T)((?<hours>\\d*[.,]?\\d{1,9})H)?((?<minutes>\\d*[.,]?\\d{1,9})M)?((?<seconds>\\d*[.,]?\\d{1,9})S)?)?$/;\nconst $fae977aafc393c5c$var$requiredDurationTimeGroups = [\n 'hours',\n 'minutes',\n 'seconds'\n];\nconst $fae977aafc393c5c$var$requiredDurationGroups = [\n 'years',\n 'months',\n 'weeks',\n 'days',\n ...$fae977aafc393c5c$var$requiredDurationTimeGroups\n];\nfunction $fae977aafc393c5c$export$c9698ec7f05a07e1(value) {\n let m = value.match($fae977aafc393c5c$var$TIME_RE);\n if (!m) throw new Error('Invalid ISO 8601 time string: ' + value);\n return new (0, $35ea8db9cb2ccb90$export$680ea196effce5f)($fae977aafc393c5c$var$parseNumber(m[1], 0, 23), m[2] ? $fae977aafc393c5c$var$parseNumber(m[2], 0, 59) : 0, m[3] ? $fae977aafc393c5c$var$parseNumber(m[3], 0, 59) : 0, m[4] ? $fae977aafc393c5c$var$parseNumber(m[4], 0, Infinity) * 1000 : 0);\n}\nfunction $fae977aafc393c5c$export$6b862160d295c8e(value) {\n let m = value.match($fae977aafc393c5c$var$DATE_RE);\n if (!m) {\n if ($fae977aafc393c5c$var$ABSOLUTE_RE.test(value)) throw new Error(`Invalid ISO 8601 date string: ${value}. Use parseAbsolute() instead.`);\n throw new Error('Invalid ISO 8601 date string: ' + value);\n }\n let date = new (0, $35ea8db9cb2ccb90$export$99faa760c7908e4f)($fae977aafc393c5c$var$parseNumber(m[1], 0, 9999), $fae977aafc393c5c$var$parseNumber(m[2], 1, 12), 1);\n date.day = $fae977aafc393c5c$var$parseNumber(m[3], 1, date.calendar.getDaysInMonth(date));\n return date;\n}\nfunction $fae977aafc393c5c$export$588937bcd60ade55(value) {\n let m = value.match($fae977aafc393c5c$var$DATE_TIME_RE);\n if (!m) {\n if ($fae977aafc393c5c$var$ABSOLUTE_RE.test(value)) throw new Error(`Invalid ISO 8601 date time string: ${value}. Use parseAbsolute() instead.`);\n throw new Error('Invalid ISO 8601 date time string: ' + value);\n }\n let year = $fae977aafc393c5c$var$parseNumber(m[1], -9999, 9999);\n let era = year < 1 ? 'BC' : 'AD';\n let date = new (0, $35ea8db9cb2ccb90$export$ca871e8dbb80966f)(era, year < 1 ? -year + 1 : year, $fae977aafc393c5c$var$parseNumber(m[2], 1, 12), 1, m[4] ? $fae977aafc393c5c$var$parseNumber(m[4], 0, 23) : 0, m[5] ? $fae977aafc393c5c$var$parseNumber(m[5], 0, 59) : 0, m[6] ? $fae977aafc393c5c$var$parseNumber(m[6], 0, 59) : 0, m[7] ? $fae977aafc393c5c$var$parseNumber(m[7], 0, Infinity) * 1000 : 0);\n date.day = $fae977aafc393c5c$var$parseNumber(m[3], 0, date.calendar.getDaysInMonth(date));\n return date;\n}\nfunction $fae977aafc393c5c$export$fd7893f06e92a6a4(value, disambiguation) {\n let m = value.match($fae977aafc393c5c$var$ZONED_DATE_TIME_RE);\n if (!m) throw new Error('Invalid ISO 8601 date time string: ' + value);\n let year = $fae977aafc393c5c$var$parseNumber(m[1], -9999, 9999);\n let era = year < 1 ? 'BC' : 'AD';\n let date = new (0, $35ea8db9cb2ccb90$export$d3b7288e7994edea)(era, year < 1 ? -year + 1 : year, $fae977aafc393c5c$var$parseNumber(m[2], 1, 12), 1, m[11], 0, m[4] ? $fae977aafc393c5c$var$parseNumber(m[4], 0, 23) : 0, m[5] ? $fae977aafc393c5c$var$parseNumber(m[5], 0, 59) : 0, m[6] ? $fae977aafc393c5c$var$parseNumber(m[6], 0, 59) : 0, m[7] ? $fae977aafc393c5c$var$parseNumber(m[7], 0, Infinity) * 1000 : 0);\n date.day = $fae977aafc393c5c$var$parseNumber(m[3], 0, date.calendar.getDaysInMonth(date));\n let plainDateTime = (0, $11d87f3f76e88657$export$b21e0b124e224484)(date);\n let ms;\n if (m[8]) {\n let hourOffset = $fae977aafc393c5c$var$parseNumber(m[8], -23, 23);\n var _m_, _m_1;\n date.offset = Math.sign(hourOffset) * (Math.abs(hourOffset) * 3600000 + $fae977aafc393c5c$var$parseNumber((_m_ = m[9]) !== null && _m_ !== void 0 ? _m_ : '0', 0, 59) * 60000 + $fae977aafc393c5c$var$parseNumber((_m_1 = m[10]) !== null && _m_1 !== void 0 ? _m_1 : '0', 0, 59) * 1000);\n ms = (0, $11d87f3f76e88657$export$bd4fb2bc8bb06fb)(date) - date.offset;\n // Validate offset against parsed date.\n let absolutes = (0, $11d87f3f76e88657$export$136f38efe7caf549)(plainDateTime, date.timeZone);\n if (!absolutes.includes(ms)) throw new Error(`Offset ${$fae977aafc393c5c$var$offsetToString(date.offset)} is invalid for ${$fae977aafc393c5c$export$4223de14708adc63(date)} in ${date.timeZone}`);\n } else // Convert to absolute and back to fix invalid times due to DST.\n ms = (0, $11d87f3f76e88657$export$5107c82f94518f5c)((0, $11d87f3f76e88657$export$b21e0b124e224484)(plainDateTime), date.timeZone, disambiguation);\n return (0, $11d87f3f76e88657$export$1b96692a1ba042ac)(ms, date.timeZone);\n}\nfunction $fae977aafc393c5c$export$5adfdab05168c219(value, timeZone) {\n let m = value.match($fae977aafc393c5c$var$ABSOLUTE_RE);\n if (!m) throw new Error('Invalid ISO 8601 date time string: ' + value);\n let year = $fae977aafc393c5c$var$parseNumber(m[1], -9999, 9999);\n let era = year < 1 ? 'BC' : 'AD';\n let date = new (0, $35ea8db9cb2ccb90$export$d3b7288e7994edea)(era, year < 1 ? -year + 1 : year, $fae977aafc393c5c$var$parseNumber(m[2], 1, 12), 1, timeZone, 0, m[4] ? $fae977aafc393c5c$var$parseNumber(m[4], 0, 23) : 0, m[5] ? $fae977aafc393c5c$var$parseNumber(m[5], 0, 59) : 0, m[6] ? $fae977aafc393c5c$var$parseNumber(m[6], 0, 59) : 0, m[7] ? $fae977aafc393c5c$var$parseNumber(m[7], 0, Infinity) * 1000 : 0);\n date.day = $fae977aafc393c5c$var$parseNumber(m[3], 0, date.calendar.getDaysInMonth(date));\n var _m_;\n if (m[8]) date.offset = $fae977aafc393c5c$var$parseNumber(m[8], -23, 23) * 3600000 + $fae977aafc393c5c$var$parseNumber((_m_ = m[9]) !== null && _m_ !== void 0 ? _m_ : '0', 0, 59) * 60000;\n return (0, $11d87f3f76e88657$export$538b00033cc11c75)(date, timeZone);\n}\nfunction $fae977aafc393c5c$export$8e384432362ed0f0(value) {\n return $fae977aafc393c5c$export$5adfdab05168c219(value, (0, $14e0f24ef4ac5c92$export$aa8b41735afcabd2)());\n}\nfunction $fae977aafc393c5c$var$parseNumber(value, min, max) {\n let val = Number(value);\n if (val < min || val > max) throw new RangeError(`Value out of range: ${min} <= ${val} <= ${max}`);\n return val;\n}\nfunction $fae977aafc393c5c$export$f59dee82248f5ad4(time) {\n return `${String(time.hour).padStart(2, '0')}:${String(time.minute).padStart(2, '0')}:${String(time.second).padStart(2, '0')}${time.millisecond ? String(time.millisecond / 1000).slice(1) : ''}`;\n}\nfunction $fae977aafc393c5c$export$60dfd74aa96791bd(date) {\n let gregorianDate = (0, $11d87f3f76e88657$export$b4a036af3fc0b032)(date, new (0, $3b62074eb05584b2$export$80ee6245ec4f29ec)());\n let year;\n if (gregorianDate.era === 'BC') year = gregorianDate.year === 1 ? '0000' : '-' + String(Math.abs(1 - gregorianDate.year)).padStart(6, '00');\n else year = String(gregorianDate.year).padStart(4, '0');\n return `${year}-${String(gregorianDate.month).padStart(2, '0')}-${String(gregorianDate.day).padStart(2, '0')}`;\n}\nfunction $fae977aafc393c5c$export$4223de14708adc63(date) {\n // @ts-ignore\n return `${$fae977aafc393c5c$export$60dfd74aa96791bd(date)}T${$fae977aafc393c5c$export$f59dee82248f5ad4(date)}`;\n}\nfunction $fae977aafc393c5c$var$offsetToString(offset) {\n let sign = Math.sign(offset) < 0 ? '-' : '+';\n offset = Math.abs(offset);\n let offsetHours = Math.floor(offset / 3600000);\n let offsetMinutes = Math.floor(offset % 3600000 / 60000);\n let offsetSeconds = Math.floor(offset % 3600000 % 60000 / 1000);\n let stringOffset = `${sign}${String(offsetHours).padStart(2, '0')}:${String(offsetMinutes).padStart(2, '0')}`;\n if (offsetSeconds !== 0) stringOffset += `:${String(offsetSeconds).padStart(2, '0')}`;\n return stringOffset;\n}\nfunction $fae977aafc393c5c$export$bf79f1ebf4b18792(date) {\n return `${$fae977aafc393c5c$export$4223de14708adc63(date)}${$fae977aafc393c5c$var$offsetToString(date.offset)}[${date.timeZone}]`;\n}\nfunction $fae977aafc393c5c$export$ecae829bb3747ea6(value) {\n var _match_groups, _match_groups1, _match_groups2, _match_groups3, _match_groups4, _match_groups5, _match_groups6, _match_groups7, _match_groups8;\n const match = value.match($fae977aafc393c5c$var$DATE_TIME_DURATION_RE);\n if (!match) throw new Error(`Invalid ISO 8601 Duration string: ${value}`);\n const parseDurationGroup = (group, isNegative)=>{\n if (!group) return 0;\n try {\n const sign = isNegative ? -1 : 1;\n return sign * Number(group.replace(',', '.'));\n } catch {\n throw new Error(`Invalid ISO 8601 Duration string: ${value}`);\n }\n };\n const isNegative = !!((_match_groups = match.groups) === null || _match_groups === void 0 ? void 0 : _match_groups.negative);\n const hasRequiredGroups = $fae977aafc393c5c$var$requiredDurationGroups.some((group)=>{\n var _match_groups;\n return (_match_groups = match.groups) === null || _match_groups === void 0 ? void 0 : _match_groups[group];\n });\n if (!hasRequiredGroups) throw new Error(`Invalid ISO 8601 Duration string: ${value}`);\n const durationStringIncludesTime = (_match_groups1 = match.groups) === null || _match_groups1 === void 0 ? void 0 : _match_groups1.time;\n if (durationStringIncludesTime) {\n const hasRequiredDurationTimeGroups = $fae977aafc393c5c$var$requiredDurationTimeGroups.some((group)=>{\n var _match_groups;\n return (_match_groups = match.groups) === null || _match_groups === void 0 ? void 0 : _match_groups[group];\n });\n if (!hasRequiredDurationTimeGroups) throw new Error(`Invalid ISO 8601 Duration string: ${value}`);\n }\n const duration = {\n years: parseDurationGroup((_match_groups2 = match.groups) === null || _match_groups2 === void 0 ? void 0 : _match_groups2.years, isNegative),\n months: parseDurationGroup((_match_groups3 = match.groups) === null || _match_groups3 === void 0 ? void 0 : _match_groups3.months, isNegative),\n weeks: parseDurationGroup((_match_groups4 = match.groups) === null || _match_groups4 === void 0 ? void 0 : _match_groups4.weeks, isNegative),\n days: parseDurationGroup((_match_groups5 = match.groups) === null || _match_groups5 === void 0 ? void 0 : _match_groups5.days, isNegative),\n hours: parseDurationGroup((_match_groups6 = match.groups) === null || _match_groups6 === void 0 ? void 0 : _match_groups6.hours, isNegative),\n minutes: parseDurationGroup((_match_groups7 = match.groups) === null || _match_groups7 === void 0 ? void 0 : _match_groups7.minutes, isNegative),\n seconds: parseDurationGroup((_match_groups8 = match.groups) === null || _match_groups8 === void 0 ? void 0 : _match_groups8.seconds, isNegative)\n };\n if (duration.hours !== undefined && duration.hours % 1 !== 0 && (duration.minutes || duration.seconds)) throw new Error(`Invalid ISO 8601 Duration string: ${value} - only the smallest unit can be fractional`);\n if (duration.minutes !== undefined && duration.minutes % 1 !== 0 && duration.seconds) throw new Error(`Invalid ISO 8601 Duration string: ${value} - only the smallest unit can be fractional`);\n return duration;\n}\n\n\nexport {$fae977aafc393c5c$export$c9698ec7f05a07e1 as parseTime, $fae977aafc393c5c$export$6b862160d295c8e as parseDate, $fae977aafc393c5c$export$588937bcd60ade55 as parseDateTime, $fae977aafc393c5c$export$fd7893f06e92a6a4 as parseZonedDateTime, $fae977aafc393c5c$export$4223de14708adc63 as dateTimeToString, $fae977aafc393c5c$export$5adfdab05168c219 as parseAbsolute, $fae977aafc393c5c$export$8e384432362ed0f0 as parseAbsoluteToLocal, $fae977aafc393c5c$export$f59dee82248f5ad4 as timeToString, $fae977aafc393c5c$export$60dfd74aa96791bd as dateToString, $fae977aafc393c5c$export$bf79f1ebf4b18792 as zonedDateTimeToString, $fae977aafc393c5c$export$ecae829bb3747ea6 as parseDuration};\n//# sourceMappingURL=string.module.js.map\n"],"names":[],"mappings":";;;;AAoBA,MAAM,6BAA6B,GAAG,qCAAqC;AAG3E,MAAM,iCAAiC,GAAG,uHAAuH;AAmBjK,SAAS,wCAAwC,CAAC,KAAK,EAAE;AACzD,IAAI,IAAI,CAAC,GAAG,KAAK,CAAC,KAAK,CAAC,6BAA6B,CAAC;AACtD,IAAI,IAAI,CAAC,CAAC,EAAE;AACZ,QAAQ,IAAI,iCAAiC,CAAC,IAAI,CAAC,KAAK,CAAC,EAAE,MAAM,IAAI,KAAK,CAAC,CAAC,8BAA8B,EAAE,KAAK,CAAC,8BAA8B,CAAC,CAAC;AAClJ,QAAQ,MAAM,IAAI,KAAK,CAAC,gCAAgC,GAAG,KAAK,CAAC;AACjE,IAAI;AACJ,IAAI,IAAI,IAAI,GAAG,KAAQ,yCAAyC,EAAE,iCAAiC,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,IAAI,CAAC,EAAE,iCAAiC,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,EAAE,CAAC,CAAC;AACtK,IAAI,IAAI,CAAC,GAAG,GAAG,iCAAiC,CAAC,CAAC,CAAC,CAA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