@kanso-labs/react-native-kanso-ui 0.9.0 → 0.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -3
- package/dist/autocomplete/index.js +15 -1
- package/dist/autocomplete/index.js.map +1 -1
- package/dist/button/group.d.ts +5 -0
- package/dist/button/group.js +115 -0
- package/dist/button/group.js.map +1 -0
- package/dist/button/index.d.ts +4 -1
- package/dist/button/index.js +44 -22
- package/dist/button/index.js.map +1 -1
- package/dist/button/slots.js +2 -1
- package/dist/button/slots.js.map +1 -1
- package/dist/calendar/index.js +351 -182
- package/dist/calendar/index.js.map +1 -1
- package/dist/calendar/styles.js +33 -2
- package/dist/calendar/styles.js.map +1 -1
- package/dist/carousel/arrangement.d.ts +5 -0
- package/dist/carousel/arrangement.js +123 -0
- package/dist/carousel/arrangement.js.map +1 -0
- package/dist/chequer/index.js +95 -0
- package/dist/chequer/index.js.map +1 -0
- package/dist/collection/index.d.ts +157 -0
- package/dist/collection/index.js +1331 -0
- package/dist/collection/index.js.map +1 -0
- package/dist/color-thumb/index.js +56 -0
- package/dist/color-thumb/index.js.map +1 -0
- package/dist/components/button/index.d.ts +4 -2
- package/dist/components/button/index.js +227 -188
- package/dist/components/button/index.js.map +1 -1
- package/dist/components/button-group/index.d.ts +87 -0
- package/dist/components/button-group/index.js +275 -0
- package/dist/components/button-group/index.js.map +1 -0
- package/dist/components/calendar/index.d.ts +11 -3
- package/dist/components/calendar/index.js +60 -45
- package/dist/components/calendar/index.js.map +1 -1
- package/dist/components/carousel/index.d.ts +72 -0
- package/dist/components/carousel/index.js +496 -0
- package/dist/components/carousel/index.js.map +1 -0
- package/dist/components/checkbox-group/index.d.ts +3 -4
- package/dist/components/checkbox-group/index.js +1 -1
- package/dist/components/checkbox-group/index.js.map +1 -1
- package/dist/components/color-area/index.d.ts +85 -0
- package/dist/components/color-area/index.js +630 -0
- package/dist/components/color-area/index.js.map +1 -0
- package/dist/components/color-field/index.d.ts +144 -0
- package/dist/components/color-field/index.js +516 -0
- package/dist/components/color-field/index.js.map +1 -0
- package/dist/components/color-picker/index.d.ts +74 -0
- package/dist/components/color-picker/index.js +317 -0
- package/dist/components/color-picker/index.js.map +1 -0
- package/dist/components/color-slider/index.d.ts +82 -0
- package/dist/components/color-slider/index.js +456 -0
- package/dist/components/color-slider/index.js.map +1 -0
- package/dist/components/color-swatch/index.d.ts +46 -0
- package/dist/components/color-swatch/index.js +127 -0
- package/dist/components/color-swatch/index.js.map +1 -0
- package/dist/components/color-swatch-picker/index.d.ts +81 -0
- package/dist/components/color-swatch-picker/index.js +287 -0
- package/dist/components/color-swatch-picker/index.js.map +1 -0
- package/dist/components/color-wheel/index.d.ts +71 -0
- package/dist/components/color-wheel/index.js +407 -0
- package/dist/components/color-wheel/index.js.map +1 -0
- package/dist/components/combo-box/index.d.ts +193 -0
- package/dist/components/combo-box/index.js +616 -0
- package/dist/components/combo-box/index.js.map +1 -0
- package/dist/components/date-field/index.d.ts +120 -0
- package/dist/components/date-field/index.js +111 -0
- package/dist/components/date-field/index.js.map +1 -0
- package/dist/components/date-picker/index.d.ts +130 -0
- package/dist/components/date-picker/index.js +310 -0
- package/dist/components/date-picker/index.js.map +1 -0
- package/dist/components/date-range-picker/index.d.ts +139 -0
- package/dist/components/date-range-picker/index.js +421 -0
- package/dist/components/date-range-picker/index.js.map +1 -0
- package/dist/components/disclosure/index.d.ts +94 -0
- package/dist/components/disclosure/index.js +365 -0
- package/dist/components/disclosure/index.js.map +1 -0
- package/dist/components/disclosure-group/index.d.ts +61 -0
- package/dist/components/disclosure-group/index.js +100 -0
- package/dist/components/disclosure-group/index.js.map +1 -0
- package/dist/components/drop-zone/index.d.ts +113 -0
- package/dist/components/drop-zone/index.js +304 -0
- package/dist/components/drop-zone/index.js.map +1 -0
- package/dist/components/fab/index.d.ts +1 -1
- package/dist/components/fab/index.js +91 -76
- package/dist/components/fab/index.js.map +1 -1
- package/dist/components/form/index.d.ts +3 -2
- package/dist/components/form/index.js.map +1 -1
- package/dist/components/icon-button/index.d.ts +4 -2
- package/dist/components/icon-button/index.js +204 -171
- package/dist/components/icon-button/index.js.map +1 -1
- package/dist/components/list/index.d.ts +15 -158
- package/dist/components/list/index.js +21 -1047
- package/dist/components/list/index.js.map +1 -1
- package/dist/components/list-box/index.d.ts +73 -0
- package/dist/components/list-box/index.js +82 -0
- package/dist/components/list-box/index.js.map +1 -0
- package/dist/components/loading-indicator/index.d.ts +32 -0
- package/dist/components/loading-indicator/index.js +174 -0
- package/dist/components/loading-indicator/index.js.map +1 -0
- package/dist/components/navigation-tree/index.d.ts +117 -0
- package/dist/components/navigation-tree/index.js +135 -0
- package/dist/components/navigation-tree/index.js.map +1 -0
- package/dist/components/number-field/index.js +132 -143
- package/dist/components/number-field/index.js.map +1 -1
- package/dist/components/range-calendar/index.d.ts +69 -0
- package/dist/components/range-calendar/index.js +144 -0
- package/dist/components/range-calendar/index.js.map +1 -0
- package/dist/components/search-view/index.d.ts +78 -0
- package/dist/components/search-view/index.js +570 -0
- package/dist/components/search-view/index.js.map +1 -0
- package/dist/components/select/index.d.ts +152 -0
- package/dist/components/select/index.js +419 -0
- package/dist/components/select/index.js.map +1 -0
- package/dist/components/slider/index.d.ts +111 -0
- package/dist/components/slider/index.js +673 -0
- package/dist/components/slider/index.js.map +1 -0
- package/dist/components/split-button/index.d.ts +77 -0
- package/dist/components/split-button/index.js +354 -0
- package/dist/components/split-button/index.js.map +1 -0
- package/dist/components/tabs/index.d.ts +196 -0
- package/dist/components/tabs/index.js +1137 -0
- package/dist/components/tabs/index.js.map +1 -0
- package/dist/components/time-field/index.d.ts +43 -0
- package/dist/components/time-field/index.js +107 -0
- package/dist/components/time-field/index.js.map +1 -0
- package/dist/components/time-picker/index.d.ts +65 -0
- package/dist/components/time-picker/index.js +1168 -0
- package/dist/components/time-picker/index.js.map +1 -0
- package/dist/components/tooltip/index.d.ts +101 -0
- package/dist/components/tooltip/index.js +223 -0
- package/dist/components/tooltip/index.js.map +1 -0
- package/dist/components/tree/index.d.ts +112 -0
- package/dist/components/tree/index.js +157 -0
- package/dist/components/tree/index.js.map +1 -0
- package/dist/disclosure/chevron.js +75 -0
- package/dist/disclosure/chevron.js.map +1 -0
- package/dist/disclosure/index.js +7 -0
- package/dist/disclosure/index.js.map +1 -0
- package/dist/drop/index.d.ts +54 -0
- package/dist/drop/index.js +161 -0
- package/dist/drop/index.js.map +1 -0
- package/dist/field/chevron.js +74 -0
- package/dist/field/chevron.js.map +1 -0
- package/dist/field/index.d.ts +2 -1
- package/dist/field/index.js +310 -154
- package/dist/field/index.js.map +1 -1
- package/dist/field/styles.js +9 -0
- package/dist/field/styles.js.map +1 -1
- package/dist/files/index.d.ts +18 -0
- package/dist/files/index.js +107 -0
- package/dist/files/index.js.map +1 -0
- package/dist/form/index.d.ts +5 -2
- package/dist/form/index.js +64 -85
- package/dist/form/index.js.map +1 -1
- package/dist/glyphs/index.js +92 -1
- package/dist/glyphs/index.js.map +1 -1
- package/dist/i18n/index.js +20 -1
- package/dist/i18n/index.js.map +1 -1
- package/dist/i18n/messages.js +1394 -34
- package/dist/i18n/messages.js.map +1 -1
- package/dist/index.d.ts +35 -3
- package/dist/index.js +34 -3
- package/dist/indicator/paths.js +23 -1
- package/dist/indicator/paths.js.map +1 -1
- package/dist/modal/index.js +92 -77
- package/dist/modal/index.js.map +1 -1
- package/dist/number/keyboard.js +16 -0
- package/dist/number/keyboard.js.map +1 -0
- package/dist/overlay/anchored.js +68 -38
- package/dist/overlay/anchored.js.map +1 -1
- package/dist/overlay/keyboard.js +57 -0
- package/dist/overlay/keyboard.js.map +1 -0
- package/dist/overlay/panel.js +173 -19
- package/dist/overlay/panel.js.map +1 -1
- package/dist/overlay/placement.js +13 -1
- package/dist/overlay/placement.js.map +1 -1
- package/dist/picker/index.js +322 -0
- package/dist/picker/index.js.map +1 -0
- package/dist/press/index.d.ts +2 -0
- package/dist/press/index.js +102 -100
- package/dist/press/index.js.map +1 -1
- package/dist/row/index.js +77 -69
- package/dist/row/index.js.map +1 -1
- package/dist/row/styles.js +13 -2
- package/dist/row/styles.js.map +1 -1
- package/dist/segments/field.js +277 -0
- package/dist/segments/field.js.map +1 -0
- package/dist/segments/index.js +574 -0
- package/dist/segments/index.js.map +1 -0
- package/dist/segments/styles.js +24 -0
- package/dist/segments/styles.js.map +1 -0
- package/dist/slider/index.js +145 -0
- package/dist/slider/index.js.map +1 -0
- package/dist/swatch/index.js +56 -0
- package/dist/swatch/index.js.map +1 -0
- package/package.json +11 -2
|
@@ -0,0 +1,421 @@
|
|
|
1
|
+
import { messagesFor } from "../../i18n/index.js";
|
|
2
|
+
import { useLocaleOf } from "../../i18n/provider.js";
|
|
3
|
+
import { PickerPopup, PickerTrigger } from "../../picker/index.js";
|
|
4
|
+
import { SegmentedField } from "../../segments/field.js";
|
|
5
|
+
import { RangeCalendar } from "../range-calendar/index.js";
|
|
6
|
+
import { c } from "react/compiler-runtime";
|
|
7
|
+
import { useRef, useState } from "react";
|
|
8
|
+
import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
|
|
9
|
+
import { createCalendar } from "@internationalized/date";
|
|
10
|
+
import { useDateFieldState } from "react-stately/useDateFieldState";
|
|
11
|
+
import { useDateRangePickerState } from "react-stately/useDateRangePickerState";
|
|
12
|
+
//#region src/components/date-range-picker/index.tsx
|
|
13
|
+
function chosenOf(state) {
|
|
14
|
+
const { dateRange } = state;
|
|
15
|
+
return dateRange?.start == null || dateRange.end == null ? null : {
|
|
16
|
+
end: dateRange.end,
|
|
17
|
+
start: dateRange.start
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* A date range typed into a field, or picked from a calendar behind a
|
|
22
|
+
* button. The value is a `{ start, end }` pair of `@internationalized/date`
|
|
23
|
+
* values, as on web: pass `value` with `onChange` to control it, or
|
|
24
|
+
* `defaultValue` to let it keep its own. `onChange` is called once both
|
|
25
|
+
* dates are filled.
|
|
26
|
+
*
|
|
27
|
+
* ```tsx
|
|
28
|
+
* import { CalendarDate } from '@internationalized/date'
|
|
29
|
+
*
|
|
30
|
+
* <DateRangePicker
|
|
31
|
+
* defaultValue={{
|
|
32
|
+
* end: new CalendarDate(2026, 9, 20),
|
|
33
|
+
* start: new CalendarDate(2026, 9, 15),
|
|
34
|
+
* }}
|
|
35
|
+
* label="Label"
|
|
36
|
+
* />
|
|
37
|
+
* ```
|
|
38
|
+
*
|
|
39
|
+
* The segments are DateField's and the calendar is RangeCalendar, so
|
|
40
|
+
* `granularity`, `minValue`, `maxValue` and `isDateUnavailable` behave as
|
|
41
|
+
* they do there. From the medium window size up the calendar is docked to
|
|
42
|
+
* the field; below it, it opens centred over a scrim, the same swap
|
|
43
|
+
* DatePicker makes.
|
|
44
|
+
*
|
|
45
|
+
* `style`, `ref` and `testID` land on the picker as a whole.
|
|
46
|
+
*/
|
|
47
|
+
function DateRangePicker(t0) {
|
|
48
|
+
const $ = c(129);
|
|
49
|
+
let allowsNonContiguousRanges;
|
|
50
|
+
let defaultOpen;
|
|
51
|
+
let defaultValue;
|
|
52
|
+
let endName;
|
|
53
|
+
let firstDayOfWeek;
|
|
54
|
+
let granularity;
|
|
55
|
+
let hideTimeZone;
|
|
56
|
+
let hourCycle;
|
|
57
|
+
let isDateUnavailable;
|
|
58
|
+
let isOpen;
|
|
59
|
+
let label;
|
|
60
|
+
let locale;
|
|
61
|
+
let maxValue;
|
|
62
|
+
let minValue;
|
|
63
|
+
let onChange;
|
|
64
|
+
let onOpenChange;
|
|
65
|
+
let placeholderValue;
|
|
66
|
+
let props;
|
|
67
|
+
let shouldCloseOnSelect;
|
|
68
|
+
let shouldForceLeadingZeros;
|
|
69
|
+
let startName;
|
|
70
|
+
let t1;
|
|
71
|
+
let t2;
|
|
72
|
+
let t3;
|
|
73
|
+
let t4;
|
|
74
|
+
let t5;
|
|
75
|
+
let triggerLabel;
|
|
76
|
+
let validate;
|
|
77
|
+
let value;
|
|
78
|
+
let visibleDuration;
|
|
79
|
+
if ($[0] !== t0) {
|
|
80
|
+
({allowsNonContiguousRanges, defaultOpen, defaultValue, endName, firstDayOfWeek, granularity, hideTimeZone, hourCycle, isDateUnavailable, isDisabled: t1, isOpen, isReadOnly: t2, isRequired: t3, label, locale, maxValue, minValue, onChange, onOpenChange, placeholderValue, separator: t4, shouldCloseOnSelect, shouldForceLeadingZeros, showMonthYearMenus: t5, startName, triggerLabel, validate, value, visibleDuration, ...props} = t0);
|
|
81
|
+
$[0] = t0;
|
|
82
|
+
$[1] = allowsNonContiguousRanges;
|
|
83
|
+
$[2] = defaultOpen;
|
|
84
|
+
$[3] = defaultValue;
|
|
85
|
+
$[4] = endName;
|
|
86
|
+
$[5] = firstDayOfWeek;
|
|
87
|
+
$[6] = granularity;
|
|
88
|
+
$[7] = hideTimeZone;
|
|
89
|
+
$[8] = hourCycle;
|
|
90
|
+
$[9] = isDateUnavailable;
|
|
91
|
+
$[10] = isOpen;
|
|
92
|
+
$[11] = label;
|
|
93
|
+
$[12] = locale;
|
|
94
|
+
$[13] = maxValue;
|
|
95
|
+
$[14] = minValue;
|
|
96
|
+
$[15] = onChange;
|
|
97
|
+
$[16] = onOpenChange;
|
|
98
|
+
$[17] = placeholderValue;
|
|
99
|
+
$[18] = props;
|
|
100
|
+
$[19] = shouldCloseOnSelect;
|
|
101
|
+
$[20] = shouldForceLeadingZeros;
|
|
102
|
+
$[21] = startName;
|
|
103
|
+
$[22] = t1;
|
|
104
|
+
$[23] = t2;
|
|
105
|
+
$[24] = t3;
|
|
106
|
+
$[25] = t4;
|
|
107
|
+
$[26] = t5;
|
|
108
|
+
$[27] = triggerLabel;
|
|
109
|
+
$[28] = validate;
|
|
110
|
+
$[29] = value;
|
|
111
|
+
$[30] = visibleDuration;
|
|
112
|
+
} else {
|
|
113
|
+
allowsNonContiguousRanges = $[1];
|
|
114
|
+
defaultOpen = $[2];
|
|
115
|
+
defaultValue = $[3];
|
|
116
|
+
endName = $[4];
|
|
117
|
+
firstDayOfWeek = $[5];
|
|
118
|
+
granularity = $[6];
|
|
119
|
+
hideTimeZone = $[7];
|
|
120
|
+
hourCycle = $[8];
|
|
121
|
+
isDateUnavailable = $[9];
|
|
122
|
+
isOpen = $[10];
|
|
123
|
+
label = $[11];
|
|
124
|
+
locale = $[12];
|
|
125
|
+
maxValue = $[13];
|
|
126
|
+
minValue = $[14];
|
|
127
|
+
onChange = $[15];
|
|
128
|
+
onOpenChange = $[16];
|
|
129
|
+
placeholderValue = $[17];
|
|
130
|
+
props = $[18];
|
|
131
|
+
shouldCloseOnSelect = $[19];
|
|
132
|
+
shouldForceLeadingZeros = $[20];
|
|
133
|
+
startName = $[21];
|
|
134
|
+
t1 = $[22];
|
|
135
|
+
t2 = $[23];
|
|
136
|
+
t3 = $[24];
|
|
137
|
+
t4 = $[25];
|
|
138
|
+
t5 = $[26];
|
|
139
|
+
triggerLabel = $[27];
|
|
140
|
+
validate = $[28];
|
|
141
|
+
value = $[29];
|
|
142
|
+
visibleDuration = $[30];
|
|
143
|
+
}
|
|
144
|
+
const isDisabled = t1 === void 0 ? false : t1;
|
|
145
|
+
const isReadOnly = t2 === void 0 ? false : t2;
|
|
146
|
+
const isRequired = t3 === void 0 ? false : t3;
|
|
147
|
+
const separator = t4 === void 0 ? "–" : t4;
|
|
148
|
+
const showMonthYearMenus = t5 === void 0 ? false : t5;
|
|
149
|
+
const writtenIn = useLocaleOf(locale);
|
|
150
|
+
const words = messagesFor(writtenIn).segments;
|
|
151
|
+
const box = useRef(null);
|
|
152
|
+
const [trigger, setTrigger] = useState(null);
|
|
153
|
+
let t6;
|
|
154
|
+
if ($[31] !== allowsNonContiguousRanges || $[32] !== defaultOpen || $[33] !== defaultValue || $[34] !== granularity || $[35] !== hideTimeZone || $[36] !== hourCycle || $[37] !== isDateUnavailable || $[38] !== isDisabled || $[39] !== isOpen || $[40] !== isReadOnly || $[41] !== isRequired || $[42] !== maxValue || $[43] !== minValue || $[44] !== onChange || $[45] !== onOpenChange || $[46] !== placeholderValue || $[47] !== shouldCloseOnSelect || $[48] !== shouldForceLeadingZeros || $[49] !== validate || $[50] !== value) {
|
|
155
|
+
t6 = {
|
|
156
|
+
allowsNonContiguousRanges,
|
|
157
|
+
defaultOpen,
|
|
158
|
+
defaultValue,
|
|
159
|
+
granularity,
|
|
160
|
+
hideTimeZone,
|
|
161
|
+
hourCycle,
|
|
162
|
+
isDateUnavailable,
|
|
163
|
+
isDisabled,
|
|
164
|
+
isOpen,
|
|
165
|
+
isReadOnly,
|
|
166
|
+
isRequired,
|
|
167
|
+
maxValue,
|
|
168
|
+
minValue,
|
|
169
|
+
onChange,
|
|
170
|
+
onOpenChange,
|
|
171
|
+
placeholderValue,
|
|
172
|
+
shouldCloseOnSelect,
|
|
173
|
+
shouldForceLeadingZeros,
|
|
174
|
+
validate,
|
|
175
|
+
value
|
|
176
|
+
};
|
|
177
|
+
$[31] = allowsNonContiguousRanges;
|
|
178
|
+
$[32] = defaultOpen;
|
|
179
|
+
$[33] = defaultValue;
|
|
180
|
+
$[34] = granularity;
|
|
181
|
+
$[35] = hideTimeZone;
|
|
182
|
+
$[36] = hourCycle;
|
|
183
|
+
$[37] = isDateUnavailable;
|
|
184
|
+
$[38] = isDisabled;
|
|
185
|
+
$[39] = isOpen;
|
|
186
|
+
$[40] = isReadOnly;
|
|
187
|
+
$[41] = isRequired;
|
|
188
|
+
$[42] = maxValue;
|
|
189
|
+
$[43] = minValue;
|
|
190
|
+
$[44] = onChange;
|
|
191
|
+
$[45] = onOpenChange;
|
|
192
|
+
$[46] = placeholderValue;
|
|
193
|
+
$[47] = shouldCloseOnSelect;
|
|
194
|
+
$[48] = shouldForceLeadingZeros;
|
|
195
|
+
$[49] = validate;
|
|
196
|
+
$[50] = value;
|
|
197
|
+
$[51] = t6;
|
|
198
|
+
} else t6 = $[51];
|
|
199
|
+
const state = useDateRangePickerState(t6);
|
|
200
|
+
const { close, open, setDateRange } = state;
|
|
201
|
+
let t7;
|
|
202
|
+
if ($[52] !== granularity || $[53] !== hideTimeZone || $[54] !== hourCycle || $[55] !== isDisabled || $[56] !== isReadOnly || $[57] !== isRequired || $[58] !== placeholderValue || $[59] !== shouldForceLeadingZeros || $[60] !== writtenIn) {
|
|
203
|
+
t7 = {
|
|
204
|
+
granularity,
|
|
205
|
+
hideTimeZone,
|
|
206
|
+
hourCycle,
|
|
207
|
+
isDisabled,
|
|
208
|
+
isReadOnly,
|
|
209
|
+
isRequired,
|
|
210
|
+
locale: writtenIn,
|
|
211
|
+
placeholderValue,
|
|
212
|
+
shouldForceLeadingZeros
|
|
213
|
+
};
|
|
214
|
+
$[52] = granularity;
|
|
215
|
+
$[53] = hideTimeZone;
|
|
216
|
+
$[54] = hourCycle;
|
|
217
|
+
$[55] = isDisabled;
|
|
218
|
+
$[56] = isReadOnly;
|
|
219
|
+
$[57] = isRequired;
|
|
220
|
+
$[58] = placeholderValue;
|
|
221
|
+
$[59] = shouldForceLeadingZeros;
|
|
222
|
+
$[60] = writtenIn;
|
|
223
|
+
$[61] = t7;
|
|
224
|
+
} else t7 = $[61];
|
|
225
|
+
const ends = t7;
|
|
226
|
+
let t8;
|
|
227
|
+
if ($[62] !== state) {
|
|
228
|
+
t8 = (date) => {
|
|
229
|
+
state.setDateTime("start", date);
|
|
230
|
+
};
|
|
231
|
+
$[62] = state;
|
|
232
|
+
$[63] = t8;
|
|
233
|
+
} else t8 = $[63];
|
|
234
|
+
let t9;
|
|
235
|
+
if ($[64] !== ends || $[65] !== state.value.start || $[66] !== t8) {
|
|
236
|
+
t9 = {
|
|
237
|
+
...ends,
|
|
238
|
+
createCalendar,
|
|
239
|
+
onChange: t8,
|
|
240
|
+
value: state.value.start
|
|
241
|
+
};
|
|
242
|
+
$[64] = ends;
|
|
243
|
+
$[65] = state.value.start;
|
|
244
|
+
$[66] = t8;
|
|
245
|
+
$[67] = t9;
|
|
246
|
+
} else t9 = $[67];
|
|
247
|
+
const start = useDateFieldState(t9);
|
|
248
|
+
let t10;
|
|
249
|
+
if ($[68] !== state) {
|
|
250
|
+
t10 = (date_0) => {
|
|
251
|
+
state.setDateTime("end", date_0);
|
|
252
|
+
};
|
|
253
|
+
$[68] = state;
|
|
254
|
+
$[69] = t10;
|
|
255
|
+
} else t10 = $[69];
|
|
256
|
+
let t11;
|
|
257
|
+
if ($[70] !== ends || $[71] !== state.value.end || $[72] !== t10) {
|
|
258
|
+
t11 = {
|
|
259
|
+
...ends,
|
|
260
|
+
createCalendar,
|
|
261
|
+
onChange: t10,
|
|
262
|
+
value: state.value.end
|
|
263
|
+
};
|
|
264
|
+
$[70] = ends;
|
|
265
|
+
$[71] = state.value.end;
|
|
266
|
+
$[72] = t10;
|
|
267
|
+
$[73] = t11;
|
|
268
|
+
} else t11 = $[73];
|
|
269
|
+
const end = useDateFieldState(t11);
|
|
270
|
+
const range = state.formatValue(writtenIn, { month: "long" });
|
|
271
|
+
const name = `${triggerLabel ?? words.calendar} ${label}`;
|
|
272
|
+
const T0 = SegmentedField;
|
|
273
|
+
let t12;
|
|
274
|
+
if ($[74] !== state.value.end) {
|
|
275
|
+
t12 = state.value.end?.toString() ?? "";
|
|
276
|
+
$[74] = state.value.end;
|
|
277
|
+
$[75] = t12;
|
|
278
|
+
} else t12 = $[75];
|
|
279
|
+
const t13 = state.realtimeValidation.validationErrors;
|
|
280
|
+
const t14 = range === null ? "" : words.selectedRange.replace("{startDate}", range.start).replace("{endDate}", range.end);
|
|
281
|
+
const t15 = state.value.start === null || state.value.end === null;
|
|
282
|
+
let t16;
|
|
283
|
+
if ($[76] !== state.value.start) {
|
|
284
|
+
t16 = state.value.start?.toString() ?? "";
|
|
285
|
+
$[76] = state.value.start;
|
|
286
|
+
$[77] = t16;
|
|
287
|
+
} else t16 = $[77];
|
|
288
|
+
const t17 = isDisabled || isReadOnly;
|
|
289
|
+
let t18;
|
|
290
|
+
if ($[78] !== name || $[79] !== open || $[80] !== setTrigger || $[81] !== state.isOpen || $[82] !== t17) {
|
|
291
|
+
t18 = triggerOf({
|
|
292
|
+
isDisabled: t17,
|
|
293
|
+
isOpen: state.isOpen,
|
|
294
|
+
label: name,
|
|
295
|
+
onPress: open,
|
|
296
|
+
ref: setTrigger
|
|
297
|
+
});
|
|
298
|
+
$[78] = name;
|
|
299
|
+
$[79] = open;
|
|
300
|
+
$[80] = setTrigger;
|
|
301
|
+
$[81] = state.isOpen;
|
|
302
|
+
$[82] = t17;
|
|
303
|
+
$[83] = t18;
|
|
304
|
+
} else t18 = $[83];
|
|
305
|
+
let t19;
|
|
306
|
+
if ($[84] !== T0 || $[85] !== end || $[86] !== endName || $[87] !== isDisabled || $[88] !== isReadOnly || $[89] !== isRequired || $[90] !== label || $[91] !== props || $[92] !== separator || $[93] !== start || $[94] !== startName || $[95] !== state.realtimeValidation.validationErrors || $[96] !== t12 || $[97] !== t14 || $[98] !== t15 || $[99] !== t16 || $[100] !== t18 || $[101] !== writtenIn) {
|
|
307
|
+
t19 = /* @__PURE__ */ jsx(T0, {
|
|
308
|
+
...props,
|
|
309
|
+
box,
|
|
310
|
+
end,
|
|
311
|
+
endName,
|
|
312
|
+
endSubmitted: t12,
|
|
313
|
+
errors: t13,
|
|
314
|
+
holding: t14,
|
|
315
|
+
isDisabled,
|
|
316
|
+
isEmpty: t15,
|
|
317
|
+
isReadOnly,
|
|
318
|
+
isRequired,
|
|
319
|
+
label,
|
|
320
|
+
locale: writtenIn,
|
|
321
|
+
name: startName,
|
|
322
|
+
separator,
|
|
323
|
+
state: start,
|
|
324
|
+
submitted: t16,
|
|
325
|
+
trailingIcon: t18
|
|
326
|
+
});
|
|
327
|
+
$[84] = T0;
|
|
328
|
+
$[85] = end;
|
|
329
|
+
$[86] = endName;
|
|
330
|
+
$[87] = isDisabled;
|
|
331
|
+
$[88] = isReadOnly;
|
|
332
|
+
$[89] = isRequired;
|
|
333
|
+
$[90] = label;
|
|
334
|
+
$[91] = props;
|
|
335
|
+
$[92] = separator;
|
|
336
|
+
$[93] = start;
|
|
337
|
+
$[94] = startName;
|
|
338
|
+
$[95] = state.realtimeValidation.validationErrors;
|
|
339
|
+
$[96] = t12;
|
|
340
|
+
$[97] = t14;
|
|
341
|
+
$[98] = t15;
|
|
342
|
+
$[99] = t16;
|
|
343
|
+
$[100] = t18;
|
|
344
|
+
$[101] = writtenIn;
|
|
345
|
+
$[102] = t19;
|
|
346
|
+
} else t19 = $[102];
|
|
347
|
+
const t20 = state.isOpen;
|
|
348
|
+
const t21 = state.dateRange === null ? placeholderValue : void 0;
|
|
349
|
+
let t22;
|
|
350
|
+
if ($[103] !== state) {
|
|
351
|
+
t22 = chosenOf(state);
|
|
352
|
+
$[103] = state;
|
|
353
|
+
$[104] = t22;
|
|
354
|
+
} else t22 = $[104];
|
|
355
|
+
let t23;
|
|
356
|
+
if ($[105] !== allowsNonContiguousRanges || $[106] !== firstDayOfWeek || $[107] !== isDateUnavailable || $[108] !== isDisabled || $[109] !== isReadOnly || $[110] !== label || $[111] !== maxValue || $[112] !== minValue || $[113] !== setDateRange || $[114] !== showMonthYearMenus || $[115] !== t21 || $[116] !== t22 || $[117] !== visibleDuration || $[118] !== writtenIn) {
|
|
357
|
+
t23 = /* @__PURE__ */ jsx(RangeCalendar, {
|
|
358
|
+
allowsNonContiguousRanges,
|
|
359
|
+
"aria-label": label,
|
|
360
|
+
defaultFocusedValue: t21,
|
|
361
|
+
firstDayOfWeek,
|
|
362
|
+
isDateUnavailable,
|
|
363
|
+
isDisabled,
|
|
364
|
+
isReadOnly,
|
|
365
|
+
locale: writtenIn,
|
|
366
|
+
maxValue,
|
|
367
|
+
minValue,
|
|
368
|
+
onChange: setDateRange,
|
|
369
|
+
showMonthYearMenus,
|
|
370
|
+
value: t22,
|
|
371
|
+
visibleDuration
|
|
372
|
+
});
|
|
373
|
+
$[105] = allowsNonContiguousRanges;
|
|
374
|
+
$[106] = firstDayOfWeek;
|
|
375
|
+
$[107] = isDateUnavailable;
|
|
376
|
+
$[108] = isDisabled;
|
|
377
|
+
$[109] = isReadOnly;
|
|
378
|
+
$[110] = label;
|
|
379
|
+
$[111] = maxValue;
|
|
380
|
+
$[112] = minValue;
|
|
381
|
+
$[113] = setDateRange;
|
|
382
|
+
$[114] = showMonthYearMenus;
|
|
383
|
+
$[115] = t21;
|
|
384
|
+
$[116] = t22;
|
|
385
|
+
$[117] = visibleDuration;
|
|
386
|
+
$[118] = writtenIn;
|
|
387
|
+
$[119] = t23;
|
|
388
|
+
} else t23 = $[119];
|
|
389
|
+
let t24;
|
|
390
|
+
if ($[120] !== close || $[121] !== name || $[122] !== state.isOpen || $[123] !== t23 || $[124] !== trigger) {
|
|
391
|
+
t24 = /* @__PURE__ */ jsx(PickerPopup, {
|
|
392
|
+
anchor: box,
|
|
393
|
+
close,
|
|
394
|
+
isOpen: t20,
|
|
395
|
+
label: name,
|
|
396
|
+
trigger,
|
|
397
|
+
children: t23
|
|
398
|
+
});
|
|
399
|
+
$[120] = close;
|
|
400
|
+
$[121] = name;
|
|
401
|
+
$[122] = state.isOpen;
|
|
402
|
+
$[123] = t23;
|
|
403
|
+
$[124] = trigger;
|
|
404
|
+
$[125] = t24;
|
|
405
|
+
} else t24 = $[125];
|
|
406
|
+
let t25;
|
|
407
|
+
if ($[126] !== t19 || $[127] !== t24) {
|
|
408
|
+
t25 = /* @__PURE__ */ jsxs(Fragment$1, { children: [t19, t24] });
|
|
409
|
+
$[126] = t19;
|
|
410
|
+
$[127] = t24;
|
|
411
|
+
$[128] = t25;
|
|
412
|
+
} else t25 = $[128];
|
|
413
|
+
return t25;
|
|
414
|
+
}
|
|
415
|
+
function triggerOf(props) {
|
|
416
|
+
return /* @__PURE__ */ jsx(PickerTrigger, { ...props });
|
|
417
|
+
}
|
|
418
|
+
//#endregion
|
|
419
|
+
export { DateRangePicker };
|
|
420
|
+
|
|
421
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","names":["DateDuration","ComponentRef","ReactNode","Ref","HostInstance","StyleProp","View","ViewStyle","DateFieldStateOptions","DateRange","DateRangePickerState","DateValue","DateRangePickerStateOptions","StatelyDateRangePickerProps","createCalendar","useRef","useState","useDateFieldState","useDateRangePickerState","FieldVariant","messagesFor","useLocaleOf","PickerPopup","PickerTrigger","SegmentedField","RangeCalendar","DateRangePickerProps","Pick","T","description","error","floatingLabel","isDisabled","isReadOnly","isRequired","label","leadingIcon","locale","onBlur","onFocus","ref","separator","showMonthYearMenus","style","testID","triggerLabel","variant","visibleDuration","EndOptions","chosenOf","state","dateRange","start","end","DateRangePicker","t0","$","_c","allowsNonContiguousRanges","defaultOpen","defaultValue","endName","firstDayOfWeek","granularity","hideTimeZone","hourCycle","isDateUnavailable","isOpen","maxValue","minValue","onChange","onOpenChange","placeholderValue","props","shouldCloseOnSelect","shouldForceLeadingZeros","startName","t1","t2","t3","t4","t5","validate","value","undefined","writtenIn","words","segments","box","trigger","setTrigger","t6","close","open","setDateRange","t7","ends","t8","date","setDateTime","t9","t10","date_0","t11","range","formatValue","month","name","calendar","T0","t12","toString","t13","realtimeValidation","validationErrors","t14","selectedRange","replace","t15","t16","t17","t18","triggerOf","onPress","t19","t20","t21","t22","t23","t24","t25","Parameters","_c"],"sources":["../../../src/components/date-range-picker/index.tsx"],"sourcesContent":["import type { DateDuration } from '@internationalized/date'\nimport type { ComponentRef, ReactNode, Ref } from 'react'\nimport type { HostInstance, StyleProp, View, ViewStyle } from 'react-native'\nimport type { DateFieldStateOptions } from 'react-stately/useDateFieldState'\nimport type {\n DateRange,\n DateRangePickerState,\n DateValue,\n DateRangePickerStateOptions as StatelyDateRangePickerProps,\n} from 'react-stately/useDateRangePickerState'\n\nimport { createCalendar } from '@internationalized/date'\nimport { useRef, useState } from 'react'\nimport { useDateFieldState } from 'react-stately/useDateFieldState'\nimport { useDateRangePickerState } from 'react-stately/useDateRangePickerState'\n\nimport type { FieldVariant } from '../../field'\n\nimport { messagesFor } from '../../i18n'\nimport { useLocaleOf } from '../../i18n/provider'\nimport { PickerPopup, PickerTrigger } from '../../picker'\nimport { SegmentedField } from '../../segments/field'\nimport { RangeCalendar } from '../range-calendar'\n\n// kanso-ui's DateRangePicker: DatePicker picking two dates rather than one.\n// Every part it draws is already here, the segments from src/segments, the\n// button and the surface from src/picker and the calendar RangeCalendar, so\n// the two pickers cannot come apart. What a range adds is a second date's\n// segments and the dash between the two.\n//\n// The date pickers page draws a range only as the modal picker, and carries\n// no docked range picker and no token of its own for one. So the docked\n// shape here follows the docked single picker, as web's does and as\n// RangeCalendar does for the band it draws: docked under the field from the\n// medium window size up, and modal in a compact window.\n//\n// The state is React Stately's `useDateRangePickerState`, which web's React\n// Aria picker is built on, with a date field's state for each end that reads\n// and writes its half of the range, as React Aria wires its two fields.\n//\n// Three things are this component's own, as on web.\n//\n// **The dash is decoration, not content.** It reads as a range to someone\n// looking, and every segment is already named for its date, \"Start Date\" or\n// \"End Date\" before the label in React Aria's words, so a screen reader\n// hearing the dash as well would be told a third time. It is hidden from\n// one, in the segments' muted role.\n//\n// **Both dates and the button are one field.** The box draws once around\n// all three, focus runs on from the start's last segment to the end's\n// first, and focus moving between the two is not focus leaving the field.\n// Each date's first segment reads the whole range after its name, \"Selected\n// Range\" in React Aria's words, once both dates are filled.\n//\n// **The range is picked in the calendar with two presses**, one on each\n// end, and picking it closes the calendar, unless `shouldCloseOnSelect`\n// says otherwise. A screen reader goes to the range's start as the calendar\n// opens, or to the date it opens on, and back to the button once it has\n// gone.\n\ntype DateRangePickerProps<T extends DateValue = DateValue> = Pick<\n StatelyDateRangePickerProps<T>,\n | 'allowsNonContiguousRanges'\n | 'defaultOpen'\n | 'defaultValue'\n | 'endName'\n | 'firstDayOfWeek'\n | 'granularity'\n | 'hideTimeZone'\n | 'hourCycle'\n | 'isDateUnavailable'\n | 'isOpen'\n | 'maxValue'\n | 'minValue'\n | 'onChange'\n | 'onOpenChange'\n | 'placeholderValue'\n | 'shouldCloseOnSelect'\n | 'shouldForceLeadingZeros'\n | 'startName'\n | 'validate'\n | 'value'\n> & {\n /**\n * A hint shown under the field. Replaced by `error` when there is one, so\n * the two never stack.\n */\n readonly description?: string\n /**\n * The problem with the current range, in words. Its presence is what puts\n * the field in its error state: the message, the error colours, and the\n * invalid state a screen reader reads all follow from it. The line under\n * the field arrives with the message, so the field grows when this does,\n * unless it is inside a `Form`, which keeps the line drawn. It wins over\n * what `validate`, the bounds and the form say.\n */\n readonly error?: string\n /**\n * Whether the label floats into the box's top, as the text fields page\n * draws a field holding a value. The segments always show, their\n * placeholders while empty, so it floats from the start. `false` keeps it\n * small at the top.\n * @default true\n */\n readonly floatingLabel?: boolean\n /**\n * Draws the picker disabled: neither date takes input and the calendar\n * does not open.\n * @default false\n */\n readonly isDisabled?: boolean\n /**\n * Shows the range and takes focus, but takes no input, and the calendar\n * does not open.\n * @default false\n */\n readonly isReadOnly?: boolean\n /**\n * Marks the label with an asterisk, as the text fields page marks a field\n * that must be filled. Inside a `Form` that validates natively, both dates\n * must be.\n * @default false\n */\n readonly isRequired?: boolean\n /**\n * What the field is for, and the name a screen reader reads for it, after\n * each segment's own and its date's. It names the calendar too, and the\n * button opening it after that button's own name.\n */\n readonly label: string\n /**\n * An icon at the start of the box, before the label and the segments: the\n * page's 24dp leading icon, in the muted role. The slot hands it that\n * colour and size through `useIconStyle()`.\n */\n readonly leadingIcon?: ReactNode\n /**\n * The BCP 47 locale the dates are written and typed in, and the calendar\n * drawn in: the order of the segments, their placeholders, the month and\n * weekday names, the digits and the calendar system. Defaults to the\n * `I18nProvider`'s, or the device's outside one.\n */\n readonly locale?: string\n /** Called as focus leaves the field, once it has filled what it can. */\n readonly onBlur?: () => void\n /** Called as focus arrives in the field, at whichever segment. */\n readonly onFocus?: () => void\n readonly ref?: Ref<ComponentRef<typeof View>>\n /**\n * What is drawn between the two dates. Decoration: a screen reader hears\n * which date each segment is part of instead.\n * @default '–'\n */\n readonly separator?: string\n /**\n * Whether the calendar's header draws the month and the year as menu\n * buttons, each opening a list of them in the grid's place, as the docked\n * date picker's header does: see `RangeCalendar`.\n * @default false\n */\n readonly showMonthYearMenus?: boolean\n /** Positions and sizes the picker as a whole. */\n readonly style?: StyleProp<ViewStyle>\n readonly testID?: string\n /**\n * What the button that opens the calendar is called, for a screen reader,\n * before the field's label. Left out, it is \"Calendar\" in the locale's\n * words, React Aria's.\n */\n readonly triggerLabel?: string\n /**\n * The filled box, or the outlined one, as the text fields page draws them.\n * @default 'filled'\n */\n readonly variant?: FieldVariant\n /**\n * How much of the calendar shows at once: `{ months: 2 }` draws two\n * months, side by side from the expanded window size up and one under the\n * other below it, which is what a range is usually picked from: see\n * `RangeCalendar`.\n * @default { months: 1 }\n */\n readonly visibleDuration?: DateDuration\n}\n\n// What each end's field shares with the other, as React Aria hands both of\n// its fields the same props.\ntype EndOptions = Pick<\n DateFieldStateOptions,\n | 'granularity'\n | 'hideTimeZone'\n | 'hourCycle'\n | 'isDisabled'\n | 'isReadOnly'\n | 'isRequired'\n | 'locale'\n | 'placeholderValue'\n | 'shouldForceLeadingZeros'\n>\n\n// The range the calendar holds: the one the picker has chosen, which React\n// Stately keeps whole or not at all, though its type leaves either end open.\nfunction chosenOf(state: DateRangePickerState): DateRange | null {\n const { dateRange } = state\n\n return dateRange?.start == null || dateRange.end == null\n ? null\n : { end: dateRange.end, start: dateRange.start }\n}\n\n/**\n * A date range typed into a field, or picked from a calendar behind a\n * button. The value is a `{ start, end }` pair of `@internationalized/date`\n * values, as on web: pass `value` with `onChange` to control it, or\n * `defaultValue` to let it keep its own. `onChange` is called once both\n * dates are filled.\n *\n * ```tsx\n * import { CalendarDate } from '@internationalized/date'\n *\n * <DateRangePicker\n * defaultValue={{\n * end: new CalendarDate(2026, 9, 20),\n * start: new CalendarDate(2026, 9, 15),\n * }}\n * label=\"Label\"\n * />\n * ```\n *\n * The segments are DateField's and the calendar is RangeCalendar, so\n * `granularity`, `minValue`, `maxValue` and `isDateUnavailable` behave as\n * they do there. From the medium window size up the calendar is docked to\n * the field; below it, it opens centred over a scrim, the same swap\n * DatePicker makes.\n *\n * `style`, `ref` and `testID` land on the picker as a whole.\n */\nfunction DateRangePicker<T extends DateValue = DateValue>({\n allowsNonContiguousRanges,\n defaultOpen,\n defaultValue,\n endName,\n firstDayOfWeek,\n granularity,\n hideTimeZone,\n hourCycle,\n isDateUnavailable,\n isDisabled = false,\n isOpen,\n isReadOnly = false,\n isRequired = false,\n label,\n locale,\n maxValue,\n minValue,\n onChange,\n onOpenChange,\n placeholderValue,\n separator = '–',\n shouldCloseOnSelect,\n shouldForceLeadingZeros,\n showMonthYearMenus = false,\n startName,\n triggerLabel,\n validate,\n value,\n visibleDuration,\n ...props\n}: DateRangePickerProps<T>) {\n const writtenIn = useLocaleOf(locale)\n const words = messagesFor(writtenIn).segments\n const box = useRef<HostInstance>(null)\n const [trigger, setTrigger] = useState<HostInstance | null>(null)\n const state = useDateRangePickerState<T>({\n allowsNonContiguousRanges,\n defaultOpen,\n defaultValue,\n granularity,\n hideTimeZone,\n hourCycle,\n isDateUnavailable,\n isDisabled,\n isOpen,\n isReadOnly,\n isRequired,\n maxValue,\n minValue,\n onChange,\n onOpenChange,\n placeholderValue,\n shouldCloseOnSelect,\n shouldForceLeadingZeros,\n validate,\n value,\n })\n // oxlint-disable-next-line typescript/unbound-method -- React Stately's setters are callbacks, and read no `this`\n const { close, open, setDateRange } = state\n const ends: EndOptions = {\n granularity,\n hideTimeZone,\n hourCycle,\n isDisabled,\n isReadOnly,\n isRequired,\n locale: writtenIn,\n placeholderValue,\n shouldForceLeadingZeros,\n }\n const start = useDateFieldState({\n ...ends,\n createCalendar,\n onChange: (date) => {\n state.setDateTime('start', date)\n },\n value: state.value.start,\n })\n const end = useDateFieldState({\n ...ends,\n createCalendar,\n onChange: (date) => {\n state.setDateTime('end', date)\n },\n value: state.value.end,\n })\n const range = state.formatValue(writtenIn, { month: 'long' })\n const name = `${triggerLabel ?? words.calendar} ${label}`\n\n return (\n <>\n <SegmentedField\n {...props}\n box={box}\n end={end}\n endName={endName}\n endSubmitted={state.value.end?.toString() ?? ''}\n errors={state.realtimeValidation.validationErrors}\n holding={\n range === null\n ? ''\n : words.selectedRange\n .replace('{startDate}', range.start)\n .replace('{endDate}', range.end)\n }\n isDisabled={isDisabled}\n isEmpty={state.value.start === null || state.value.end === null}\n isReadOnly={isReadOnly}\n isRequired={isRequired}\n label={label}\n locale={writtenIn}\n name={startName}\n separator={separator}\n state={start}\n submitted={state.value.start?.toString() ?? ''}\n trailingIcon={triggerOf({\n isDisabled: isDisabled || isReadOnly,\n isOpen: state.isOpen,\n label: name,\n onPress: open,\n ref: setTrigger,\n })}\n />\n <PickerPopup\n anchor={box}\n close={close}\n isOpen={state.isOpen}\n label={name}\n trigger={trigger}\n >\n <RangeCalendar\n allowsNonContiguousRanges={allowsNonContiguousRanges}\n aria-label={label}\n defaultFocusedValue={\n state.dateRange === null ? placeholderValue : undefined\n }\n firstDayOfWeek={firstDayOfWeek}\n isDateUnavailable={isDateUnavailable}\n isDisabled={isDisabled}\n isReadOnly={isReadOnly}\n locale={writtenIn}\n maxValue={maxValue}\n minValue={minValue}\n onChange={setDateRange}\n showMonthYearMenus={showMonthYearMenus}\n value={chosenOf(state)}\n visibleDuration={visibleDuration}\n />\n </PickerPopup>\n </>\n )\n}\n\n// The button for the box's trailing slot. A call rather than JSX written at\n// the prop, which is what react-perf's jsx-no-jsx-as-prop is after.\nfunction triggerOf(props: Parameters<typeof PickerTrigger>[0]) {\n return <PickerTrigger {...props} />\n}\n\nexport type { DateRangePickerProps }\n\nexport { DateRangePicker }\n"],"mappings":";;;;;;;;;;;;AA0MA,SAASiD,SAASC,OAA+C;CAC/D,MAAM,EAAEC,cAAcD;CAEtB,OAAOC,WAAWC,SAAS,QAAQD,UAAUE,OAAO,OAChD,OACA;EAAEA,KAAKF,UAAUE;EAAKD,OAAOD,UAAUC;CAAM;AACnD;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA6BA,SAAAE,gBAAAC,IAAA;CAAA,MAAAC,IAAAC,EAAA,GAAA;CAAA,IAAAC;CAAA,IAAAC;CA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AAAV,EAAA,OAAAxB;EAAAwB,EAAA,OAAAvB;EAAAuB,EAAA,OAAArB;EAAAqB,EAAA,OAAAY;EAAAZ,EAAA,OAAAa;EAAAb,EAAA,OAAAsC;EAAAtC,EAAA,OAAAd;EAAAc,EAAA,OAAAsE;EAAAtE,EAAA,OAAAuE;EAAAvE,EAAA,OAAAT;EAAAS,EAAA,OAAA6B;EAAA7B,EAAA,OAAAwE;CAAA,OAAAA,MAAAxE,EAAA;CAAA,IAAAyE;CAAA,IAAAzE,EAAA,SAAAoC,SAAApC,EAAA,SAAAmD,QAAAnD,EAAA,SAAAN,MAAAiB,UAAAX,EAAA,SAAAwE,OAAAxE,EAAA,SAAAiC,SAAA;EAxBJwC,MAAA,oBAAC,aAAD;GACUzC,QAAAA;GACDI;GACC,QAAAiC;GACDlB,OAAAA;GACElB;GAETuC,UAAAA;EAPU,CAAA;EAyBExE,EAAA,OAAAoC;EAAApC,EAAA,OAAAmD;EAAAnD,EAAA,OAAAN,MAAAiB;EAAAX,EAAA,OAAAwE;EAAAxE,EAAA,OAAAiC;EAAAjC,EAAA,OAAAyE;CAAA,OAAAA,MAAAzE,EAAA;CAAA,IAAA0E;CAAA,IAAA1E,EAAA,SAAAoE,OAAApE,EAAA,SAAAyE,KAAA;EA1DhBC,MAAA,qBAAA,YAAA,EAAA,UAAA,CACEN,KAgCAK,GAyBc,EAAA,CAAA;EACbzE,EAAA,OAAAoE;EAAApE,EAAA,OAAAyE;EAAAzE,EAAA,OAAA0E;CAAA,OAAAA,MAAA1E,EAAA;CAAA,OA3DH0E;AA2DG;AAMP,SAASR,UAAUjD,OAA4C;CAC7D,OAAO,oBAAC,eAAD,EAAe,GAAIA,MAAM,CAAA;AAClC"}
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
import { StyleProp, View, ViewStyle } from "react-native";
|
|
2
|
+
import { ComponentRef, ReactNode, Ref } from "react";
|
|
3
|
+
import { Key } from "react-stately";
|
|
4
|
+
//#region src/components/disclosure/index.d.ts
|
|
5
|
+
type DisclosureHeaderProps = {
|
|
6
|
+
/** The header's headline, what the section is about. */
|
|
7
|
+
readonly children?: ReactNode;
|
|
8
|
+
/** Content before the headline: an avatar, an icon. */
|
|
9
|
+
readonly leading?: ReactNode;
|
|
10
|
+
readonly ref?: Ref<ComponentRef<typeof View>>;
|
|
11
|
+
readonly style?: StyleProp<ViewStyle>;
|
|
12
|
+
/** A second line under the headline, in the muted role. */
|
|
13
|
+
readonly supporting?: ReactNode;
|
|
14
|
+
readonly testID?: string;
|
|
15
|
+
};
|
|
16
|
+
type DisclosurePanelProps = {
|
|
17
|
+
/** What the section shows while it is open. */
|
|
18
|
+
readonly children?: ReactNode;
|
|
19
|
+
readonly ref?: Ref<ComponentRef<typeof View>>;
|
|
20
|
+
/**
|
|
21
|
+
* `region` names the panel as a landmark, for a section a reader should be
|
|
22
|
+
* able to jump to, where `group` only gathers what is in it.
|
|
23
|
+
* @default 'group'
|
|
24
|
+
*/
|
|
25
|
+
readonly role?: 'group' | 'region';
|
|
26
|
+
readonly style?: StyleProp<ViewStyle>;
|
|
27
|
+
readonly testID?: string;
|
|
28
|
+
};
|
|
29
|
+
type DisclosureProps = {
|
|
30
|
+
/** A `Disclosure.Header` and a `Disclosure.Panel`. */
|
|
31
|
+
readonly children?: ReactNode;
|
|
32
|
+
/** Whether the section starts open, when it keeps its own state. */
|
|
33
|
+
readonly defaultExpanded?: boolean;
|
|
34
|
+
/**
|
|
35
|
+
* The section's key in a `DisclosureGroup`, which the group reports as
|
|
36
|
+
* expanded. Outside a group it does nothing.
|
|
37
|
+
*/
|
|
38
|
+
readonly id?: Key;
|
|
39
|
+
/**
|
|
40
|
+
* Keeps the section from opening or closing, and draws its header
|
|
41
|
+
* disabled.
|
|
42
|
+
* @default false
|
|
43
|
+
*/
|
|
44
|
+
readonly isDisabled?: boolean;
|
|
45
|
+
/** Whether the section is open, when the call site holds the state. */
|
|
46
|
+
readonly isExpanded?: boolean;
|
|
47
|
+
/** Called with the new state as the section opens or closes. */
|
|
48
|
+
readonly onExpandedChange?: (isExpanded: boolean) => void;
|
|
49
|
+
readonly ref?: Ref<ComponentRef<typeof View>>;
|
|
50
|
+
readonly style?: StyleProp<ViewStyle>;
|
|
51
|
+
readonly testID?: string;
|
|
52
|
+
};
|
|
53
|
+
/**
|
|
54
|
+
* A section that opens to show what is under it. Pass `isExpanded` with
|
|
55
|
+
* `onExpandedChange` to hold whether it is open, or `defaultExpanded` to let
|
|
56
|
+
* it keep its own.
|
|
57
|
+
*
|
|
58
|
+
* ```tsx
|
|
59
|
+
* <Disclosure>
|
|
60
|
+
* <Disclosure.Header>Headline</Disclosure.Header>
|
|
61
|
+
* <Disclosure.Panel>
|
|
62
|
+
* <Text>Supporting line</Text>
|
|
63
|
+
* </Disclosure.Panel>
|
|
64
|
+
* </Disclosure>
|
|
65
|
+
* ```
|
|
66
|
+
*
|
|
67
|
+
* The header is the row every list here draws, so a section above a list of
|
|
68
|
+
* rows lines up with them. The panel opens to whatever height its content
|
|
69
|
+
* reports, and opens and closes at once under reduced motion.
|
|
70
|
+
*
|
|
71
|
+
* Inside a `DisclosureGroup`, give it an `id`, the key the group reports.
|
|
72
|
+
*
|
|
73
|
+
* `style`, `ref` and `testID` land on the section's own view, as they do on
|
|
74
|
+
* each part's.
|
|
75
|
+
*/
|
|
76
|
+
declare function Disclosure({ children, defaultExpanded, id, isDisabled, isExpanded, onExpandedChange, ref, style, testID }: DisclosureProps): import("react").JSX.Element;
|
|
77
|
+
declare namespace Disclosure {
|
|
78
|
+
var Header: typeof DisclosureHeader;
|
|
79
|
+
var Panel: typeof DisclosurePanel;
|
|
80
|
+
}
|
|
81
|
+
/**
|
|
82
|
+
* The row that opens and closes the section: a button announced as expanded
|
|
83
|
+
* or collapsed, drawing the shared row's slots with a chevron in the
|
|
84
|
+
* trailing one.
|
|
85
|
+
*/
|
|
86
|
+
declare function DisclosureHeader({ children, leading, ref, style, supporting, testID }: DisclosureHeaderProps): import("react").JSX.Element;
|
|
87
|
+
/**
|
|
88
|
+
* What the section shows while it is open. Its content sits 16dp in, lined
|
|
89
|
+
* up with the headline above it, and it is named by the header.
|
|
90
|
+
*/
|
|
91
|
+
declare function DisclosurePanel({ children, ref, role, style, testID }: DisclosurePanelProps): import("react").JSX.Element;
|
|
92
|
+
//#endregion
|
|
93
|
+
export { Disclosure, DisclosureHeader, type DisclosureHeaderProps, DisclosurePanel, type DisclosurePanelProps, type DisclosureProps };
|
|
94
|
+
//# sourceMappingURL=index.d.ts.map
|