@lolmath/ui 9.1.2 → 9.3.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/index.mjs CHANGED
@@ -1,4 +1,4 @@
1
- import { Autocomplete, Autocomplete as Autocomplete$1, AutocompleteContext, AutocompleteStateContext, Breadcrumb as Breadcrumb$1, Breadcrumbs as Breadcrumbs$1, Button as Button$1, Cell, CheckboxButton as CheckboxButton$1, CheckboxField as CheckboxField$1, Collection, Column, ColumnResizer, Dialog, Dialog as Dialog$1, DialogTrigger, Disclosure as Disclosure$1, DisclosureGroup as DisclosureGroup$1, DisclosurePanel as DisclosurePanel$1, FieldError, GridLayout, Group, Header, Heading as Heading$1, Input, Label as Label$1, Link, ListBox, ListBoxItem, ListBoxItem as ListBoxItem$1, ListLayout, ListLayout as ListLayout$1, Menu as Menu$1, MenuItem as MenuItem$1, MenuSection as MenuSection$1, MenuTrigger as MenuTrigger$1, Modal as Modal$1, ModalOverlay, NumberField as NumberField$1, OverlayArrow, Popover as Popover$1, Popover as UnstyledPopover, ProgressBar as ProgressBar$1, RadioButton as RadioButton$1, RadioField as RadioField$1, RadioGroup as RadioGroup$1, ResizableTableContainer, RouterProvider, Row, SearchField as SearchField$1, Select, Select as Select$1, SelectValue, SelectValue as SelectValue$1, SelectionIndicator, Separator, Size, Slider as Slider$1, SliderFill, SliderOutput as SliderOutput$1, SliderThumb, SliderTrack, SubmenuTrigger as SubmenuTrigger$1, SwitchButton as SwitchButton$1, SwitchField as SwitchField$1, Tab as Tab$1, TabList as TabList$1, TabPanel as TabPanel$1, Table as Table$1, TableBody as TableBody$1, TableFooter as TableFooter$1, TableHeader, TableLayout, Tabs as Tabs$1, Tag as Tag$1, TagGroup as TagGroup$1, TagList as TagList$1, Text as Text$1, TextArea as TextArea$1, TextField as TextField$1, ToggleButton as ToggleButton$1, ToggleButtonGroup as ToggleButtonGroup$1, Toolbar as Toolbar$1, Tree as Tree$1, TreeItem as TreeItem$1, TreeItemContent as TreeItemContent$1, TreeLoadMoreItem as TreeLoadMoreItem$1, Virtualizer, Virtualizer as Virtualizer$1, WaterfallLayout, composeRenderProps, useFilter, useFilter as useFilter$1 } from "react-aria-components";
1
+ import { Autocomplete, Autocomplete as Autocomplete$1, AutocompleteContext, AutocompleteStateContext, Breadcrumb as Breadcrumb$1, Breadcrumbs as Breadcrumbs$1, Button as Button$1, Calendar as Calendar$1, CalendarCell as CalendarCell$1, CalendarGrid as CalendarGrid$1, CalendarGridBody, CalendarGridHeader as CalendarGridHeader$1, CalendarHeaderCell as CalendarHeaderCell$1, CalendarHeading, CalendarMonthPicker, CalendarYearPicker, Cell, CheckboxButton as CheckboxButton$1, CheckboxField as CheckboxField$1, Collection, Column, ColumnResizer, DateField as DateField$1, DateInput as DateInput$1, DatePicker as DatePicker$1, DateRangePicker as DateRangePicker$1, DateSegment as DateSegment$1, Dialog, Dialog as Dialog$1, DialogTrigger, Disclosure as Disclosure$1, DisclosureGroup as DisclosureGroup$1, DisclosurePanel as DisclosurePanel$1, FieldError, GridLayout, Group as Group$1, Header, Heading as Heading$1, Input, Label as Label$1, Link, ListBox, ListBoxItem, ListBoxItem as ListBoxItem$1, ListLayout, ListLayout as ListLayout$1, Menu as Menu$1, MenuItem as MenuItem$1, MenuSection as MenuSection$1, MenuTrigger as MenuTrigger$1, Modal as Modal$1, ModalOverlay, NumberField as NumberField$1, OverlayArrow, Popover as Popover$1, Popover as UnstyledPopover, ProgressBar as ProgressBar$1, RadioButton as RadioButton$1, RadioField as RadioField$1, RadioGroup as RadioGroup$1, RangeCalendar as RangeCalendar$1, ResizableTableContainer, RouterProvider, Row, SearchField as SearchField$1, Select, Select as Select$1, SelectValue, SelectValue as SelectValue$1, SelectionIndicator, Separator, Size, Slider as Slider$1, SliderFill, SliderOutput as SliderOutput$1, SliderThumb, SliderTrack, SubmenuTrigger as SubmenuTrigger$1, SwitchButton as SwitchButton$1, SwitchField as SwitchField$1, Tab as Tab$1, TabList as TabList$1, TabPanel as TabPanel$1, Table as Table$1, TableBody as TableBody$1, TableFooter as TableFooter$1, TableHeader, TableLayout, Tabs as Tabs$1, Tag as Tag$1, TagGroup as TagGroup$1, TagList as TagList$1, Text as Text$1, TextArea as TextArea$1, TextField as TextField$1, TimeField as TimeField$1, ToggleButton as ToggleButton$1, ToggleButtonGroup as ToggleButtonGroup$1, Toolbar as Toolbar$1, Tree as Tree$1, TreeItem as TreeItem$1, TreeItemContent as TreeItemContent$1, TreeLoadMoreItem as TreeLoadMoreItem$1, Virtualizer, Virtualizer as Virtualizer$1, WaterfallLayout, composeRenderProps, useFilter, useFilter as useFilter$1 } from "react-aria-components";
2
2
  import { cva, cx } from "cva";
3
3
  import { Fragment, jsx, jsxs } from "react/jsx-runtime";
4
4
  import React, { createElement, useMemo } from "react";
@@ -112,10 +112,514 @@ function ButtonLink({ children, className, preset = "secondary", shape = "normal
112
112
  });
113
113
  }
114
114
  //#endregion
115
+ //#region src/components/typography/text.module.css
116
+ var text_module_default = {
117
+ "text": "_text_1tvjr_2",
118
+ "label": "_label_1tvjr_6",
119
+ "stat": "_stat_1tvjr_13",
120
+ "largeNumber": "_largeNumber_1tvjr_20",
121
+ "sm": "_sm_1tvjr_27",
122
+ "base": "_base_1tvjr_34",
123
+ "md": "_md_1tvjr_41",
124
+ "lg": "_lg_1tvjr_48",
125
+ "grey100": "_grey100_1tvjr_55",
126
+ "grey150": "_grey150_1tvjr_59",
127
+ "gold100": "_gold100_1tvjr_63"
128
+ };
129
+ //#endregion
130
+ //#region src/components/typography/text.tsx
131
+ const text = cva({
132
+ base: text_module_default.text,
133
+ variants: {
134
+ color: {
135
+ grey100: text_module_default.grey100,
136
+ grey150: text_module_default.grey150,
137
+ gold100: text_module_default.gold100
138
+ },
139
+ preset: {
140
+ sm: text_module_default.sm,
141
+ base: text_module_default.base,
142
+ md: text_module_default.md,
143
+ lg: text_module_default.lg,
144
+ label: text_module_default.label,
145
+ largeNumber: text_module_default.largeNumber,
146
+ stat: text_module_default.stat
147
+ }
148
+ }
149
+ });
150
+ function Text({ preset = "base", color = "grey100", className, ...rest }) {
151
+ return /* @__PURE__ */ jsx(Text$1, {
152
+ className: text({
153
+ preset,
154
+ color,
155
+ className
156
+ }),
157
+ ...rest
158
+ });
159
+ }
160
+ function Label({ preset = "sm", color = "grey100", className, ...rest }) {
161
+ return /* @__PURE__ */ jsx(Label$1, {
162
+ className: text({
163
+ preset,
164
+ color,
165
+ className
166
+ }),
167
+ ...rest
168
+ });
169
+ }
170
+ //#endregion
171
+ //#region src/components/select/select.module.css
172
+ var select_module_default = {
173
+ "button": "_button_2pv2a_2",
174
+ "small": "_small_2pv2a_47",
175
+ "medium": "_medium_2pv2a_51",
176
+ "large": "_large_2pv2a_55",
177
+ "singleSelect": "_singleSelect_2pv2a_60",
178
+ "multiSelect": "_multiSelect_2pv2a_67",
179
+ "listBox": "_listBox_2pv2a_73",
180
+ "item": "_item_2pv2a_80",
181
+ "focus": "_focus_2pv2a_97",
182
+ "selected": "_selected_2pv2a_106",
183
+ "popover": "_popover_2pv2a_113",
184
+ "emptyList": "_emptyList_2pv2a_119"
185
+ };
186
+ //#endregion
187
+ //#region src/components/select/select.tsx
188
+ const select = cva({
189
+ base: select_module_default.button,
190
+ variants: {
191
+ size: {
192
+ small: select_module_default.small,
193
+ medium: select_module_default.medium,
194
+ large: select_module_default.large
195
+ },
196
+ selectionMode: {
197
+ single: select_module_default.singleSelect,
198
+ multiple: select_module_default.multiSelect
199
+ }
200
+ }
201
+ });
202
+ function SelectButton({ className, size = "medium", ...props }) {
203
+ return /* @__PURE__ */ jsx(Button$1, {
204
+ ...props,
205
+ className: composeRenderProps(className, (className, buttonValues) => select({
206
+ ...buttonValues,
207
+ size,
208
+ className,
209
+ selectionMode: "single"
210
+ }))
211
+ });
212
+ }
213
+ function SelectPopover({ className, ...props }) {
214
+ return /* @__PURE__ */ jsx(Popover$1, {
215
+ ...props,
216
+ className: composeRenderProps(className, (className) => cx(className, select_module_default.popover))
217
+ });
218
+ }
219
+ function SelectListBox({ className, emptyList = "No results found", ...props }) {
220
+ return /* @__PURE__ */ jsx(ListBox, {
221
+ ...props,
222
+ renderEmptyState: () => /* @__PURE__ */ jsx("div", {
223
+ className: text({
224
+ color: "grey150",
225
+ preset: "base",
226
+ className: select_module_default.emptyList
227
+ }),
228
+ children: emptyList
229
+ }),
230
+ className: composeRenderProps(className, (className) => cx(className, select_module_default.listBox))
231
+ });
232
+ }
233
+ const item = cva({
234
+ base: select_module_default.item,
235
+ variants: {
236
+ isSelected: { true: select_module_default.selected },
237
+ isFocused: { true: select_module_default.focus }
238
+ }
239
+ });
240
+ function SelectListBoxItem({ className, ...props }) {
241
+ return /* @__PURE__ */ jsx(ListBoxItem$1, {
242
+ ...props,
243
+ className: composeRenderProps(className, (className, values) => item({
244
+ ...values,
245
+ className
246
+ }))
247
+ });
248
+ }
249
+ function SelectVirtualizer(props) {
250
+ return /* @__PURE__ */ jsx(Virtualizer$1, {
251
+ layout: ListLayout$1,
252
+ layoutOptions: {
253
+ padding: 0,
254
+ gap: 0,
255
+ rowHeight: 31,
256
+ headingHeight: 35
257
+ },
258
+ ...props
259
+ });
260
+ }
261
+ //#endregion
262
+ //#region src/components/calendar/calendar.module.css
263
+ var calendar_module_default = {
264
+ "calendar": "_calendar_dpi4c_2",
265
+ "rangeCalendar": "_rangeCalendar_dpi4c_3",
266
+ "months": "_months_dpi4c_28",
267
+ "month": "_month_dpi4c_16",
268
+ "nav": "_nav_dpi4c_39",
269
+ "pickerGroup": "_pickerGroup_dpi4c_46",
270
+ "chevronFlipped": "_chevronFlipped_dpi4c_54",
271
+ "heading": "_heading_dpi4c_58",
272
+ "grid": "_grid_dpi4c_70",
273
+ "gridHeader": "_gridHeader_dpi4c_97",
274
+ "headerCell": "_headerCell_dpi4c_101",
275
+ "cell": "_cell_dpi4c_82"
276
+ };
277
+ //#endregion
278
+ //#region src/components/calendar/calendar.tsx
279
+ function CalendarChevron({ flip }) {
280
+ return /* @__PURE__ */ jsx("svg", {
281
+ width: "10",
282
+ height: "10",
283
+ viewBox: "0 0 10 10",
284
+ fill: "none",
285
+ "aria-hidden": "true",
286
+ className: flip ? calendar_module_default.chevronFlipped : void 0,
287
+ children: /* @__PURE__ */ jsx("path", {
288
+ d: "M7 1L3 5L7 9",
289
+ stroke: "currentColor",
290
+ strokeWidth: "1.5",
291
+ strokeLinecap: "round",
292
+ strokeLinejoin: "round"
293
+ })
294
+ });
295
+ }
296
+ function CalendarNavButton({ slot }) {
297
+ return /* @__PURE__ */ jsx(Button, {
298
+ preset: "text",
299
+ shape: "round",
300
+ size: "small",
301
+ slot,
302
+ "aria-label": slot === "previous" ? "Previous" : "Next",
303
+ children: /* @__PURE__ */ jsx(CalendarChevron, { flip: slot === "next" })
304
+ });
305
+ }
306
+ /**
307
+ * Lets the user jump straight to a month, via a hextech-styled `Select`
308
+ * fed by the calendar's own `CalendarMonthPicker`/`CalendarYearPicker`
309
+ * render props (`aria-label`, `value`, `onChange`, `items`).
310
+ */
311
+ function CalendarMonthYearNav() {
312
+ return /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx(CalendarMonthPicker, { children: ({ "aria-label": ariaLabel, value, onChange, items }) => /* @__PURE__ */ jsxs(Select, {
313
+ "aria-label": ariaLabel,
314
+ selectedKey: value,
315
+ onSelectionChange: onChange,
316
+ children: [/* @__PURE__ */ jsx(SelectButton, {
317
+ size: "small",
318
+ style: { minWidth: "6.5rem" },
319
+ children: /* @__PURE__ */ jsx(SelectValue, {})
320
+ }), /* @__PURE__ */ jsx(SelectPopover, { children: /* @__PURE__ */ jsx(SelectListBox, {
321
+ items,
322
+ children: (item) => /* @__PURE__ */ jsx(SelectListBoxItem, {
323
+ id: item.id,
324
+ children: item.formatted
325
+ })
326
+ }) })]
327
+ }) }), /* @__PURE__ */ jsx(CalendarYearPicker, { children: ({ "aria-label": ariaLabel, value, onChange, items }) => /* @__PURE__ */ jsxs(Select, {
328
+ "aria-label": ariaLabel,
329
+ selectedKey: value,
330
+ onSelectionChange: onChange,
331
+ children: [/* @__PURE__ */ jsx(SelectButton, {
332
+ size: "small",
333
+ style: { minWidth: "5rem" },
334
+ children: /* @__PURE__ */ jsx(SelectValue, {})
335
+ }), /* @__PURE__ */ jsx(SelectPopover, { children: /* @__PURE__ */ jsx(SelectListBox, {
336
+ items,
337
+ children: (item) => /* @__PURE__ */ jsx(SelectListBoxItem, {
338
+ id: item.id,
339
+ children: item.formatted
340
+ })
341
+ }) })]
342
+ }) })] });
343
+ }
344
+ function CalendarHeaderCell({ className, ...props }) {
345
+ return /* @__PURE__ */ jsx(CalendarHeaderCell$1, {
346
+ ...props,
347
+ className: cx(calendar_module_default.headerCell, className)
348
+ });
349
+ }
350
+ function CalendarGridHeader({ className, ...props }) {
351
+ return /* @__PURE__ */ jsx(CalendarGridHeader$1, {
352
+ ...props,
353
+ className: cx(calendar_module_default.gridHeader, className)
354
+ });
355
+ }
356
+ function CalendarCell({ className, ...props }) {
357
+ return /* @__PURE__ */ jsx(CalendarCell$1, {
358
+ ...props,
359
+ className: composeRenderProps(className, (className) => cx(calendar_module_default.cell, className))
360
+ });
361
+ }
362
+ function CalendarGrid({ className, weekdayStyle = "narrow", ...props }) {
363
+ return /* @__PURE__ */ jsxs(CalendarGrid$1, {
364
+ ...props,
365
+ weekdayStyle,
366
+ className: cx(calendar_module_default.grid, className),
367
+ children: [/* @__PURE__ */ jsx(CalendarGridHeader, { children: (day) => /* @__PURE__ */ jsx(CalendarHeaderCell, { children: day }) }), /* @__PURE__ */ jsx(CalendarGridBody, { children: (date) => /* @__PURE__ */ jsx(CalendarCell, { date }) })]
368
+ });
369
+ }
370
+ function Calendar({ header = "heading", className, ...props }) {
371
+ const months = props.visibleDuration?.months ?? 1;
372
+ return /* @__PURE__ */ jsxs(Calendar$1, {
373
+ ...props,
374
+ className: composeRenderProps(className, (className) => cx(calendar_module_default.calendar, className)),
375
+ children: [header === "picker" && /* @__PURE__ */ jsxs("div", {
376
+ className: calendar_module_default.nav,
377
+ children: [
378
+ /* @__PURE__ */ jsx(CalendarNavButton, { slot: "previous" }),
379
+ /* @__PURE__ */ jsx("div", {
380
+ className: calendar_module_default.pickerGroup,
381
+ children: /* @__PURE__ */ jsx(CalendarMonthYearNav, {})
382
+ }),
383
+ /* @__PURE__ */ jsx(CalendarNavButton, { slot: "next" })
384
+ ]
385
+ }), /* @__PURE__ */ jsx("div", {
386
+ className: calendar_module_default.months,
387
+ children: Array.from({ length: months }, (_, i) => /* @__PURE__ */ jsxs("div", {
388
+ className: calendar_module_default.month,
389
+ children: [header === "heading" && /* @__PURE__ */ jsxs("div", {
390
+ className: calendar_module_default.nav,
391
+ children: [
392
+ i === 0 && /* @__PURE__ */ jsx(CalendarNavButton, { slot: "previous" }),
393
+ /* @__PURE__ */ jsx(CalendarHeading, {
394
+ offset: { months: i },
395
+ className: calendar_module_default.heading
396
+ }),
397
+ i === months - 1 && /* @__PURE__ */ jsx(CalendarNavButton, { slot: "next" })
398
+ ]
399
+ }), /* @__PURE__ */ jsx(CalendarGrid, { offset: { months: i } })]
400
+ }, i))
401
+ })]
402
+ });
403
+ }
404
+ function RangeCalendar({ header = "heading", className, ...props }) {
405
+ const months = props.visibleDuration?.months ?? 1;
406
+ return /* @__PURE__ */ jsxs(RangeCalendar$1, {
407
+ ...props,
408
+ className: composeRenderProps(className, (className) => cx(calendar_module_default.rangeCalendar, className)),
409
+ children: [header === "picker" && /* @__PURE__ */ jsxs("div", {
410
+ className: calendar_module_default.nav,
411
+ children: [
412
+ /* @__PURE__ */ jsx(CalendarNavButton, { slot: "previous" }),
413
+ /* @__PURE__ */ jsx("div", {
414
+ className: calendar_module_default.pickerGroup,
415
+ children: /* @__PURE__ */ jsx(CalendarMonthYearNav, {})
416
+ }),
417
+ /* @__PURE__ */ jsx(CalendarNavButton, { slot: "next" })
418
+ ]
419
+ }), /* @__PURE__ */ jsx("div", {
420
+ className: calendar_module_default.months,
421
+ children: Array.from({ length: months }, (_, i) => /* @__PURE__ */ jsxs("div", {
422
+ className: calendar_module_default.month,
423
+ children: [header === "heading" && /* @__PURE__ */ jsxs("div", {
424
+ className: calendar_module_default.nav,
425
+ children: [
426
+ i === 0 && /* @__PURE__ */ jsx(CalendarNavButton, { slot: "previous" }),
427
+ /* @__PURE__ */ jsx(CalendarHeading, {
428
+ offset: { months: i },
429
+ className: calendar_module_default.heading
430
+ }),
431
+ i === months - 1 && /* @__PURE__ */ jsx(CalendarNavButton, { slot: "next" })
432
+ ]
433
+ }), /* @__PURE__ */ jsx(CalendarGrid, { offset: { months: i } })]
434
+ }, i))
435
+ })]
436
+ });
437
+ }
438
+ //#endregion
439
+ //#region src/components/calendar/date-field.module.css
440
+ var date_field_module_default = {
441
+ "dateInput": "_dateInput_qxz9d_2",
442
+ "small": "_small_qxz9d_29",
443
+ "medium": "_medium_qxz9d_33",
444
+ "large": "_large_qxz9d_37",
445
+ "segment": "_segment_qxz9d_42"
446
+ };
447
+ //#endregion
448
+ //#region src/components/calendar/date-field.tsx
449
+ const dateInput = cva({
450
+ base: date_field_module_default.dateInput,
451
+ variants: { size: {
452
+ small: date_field_module_default.small,
453
+ medium: date_field_module_default.medium,
454
+ large: date_field_module_default.large
455
+ } }
456
+ });
457
+ function DateSegment({ className, ...props }) {
458
+ return /* @__PURE__ */ jsx(DateSegment$1, {
459
+ ...props,
460
+ className: composeRenderProps(className, (className) => cx(date_field_module_default.segment, className))
461
+ });
462
+ }
463
+ function DateInput({ className, size = "medium", children, ...props }) {
464
+ return /* @__PURE__ */ jsx(DateInput$1, {
465
+ ...props,
466
+ className: composeRenderProps(className, (className, values) => dateInput({
467
+ className,
468
+ size,
469
+ ...values
470
+ })),
471
+ children: children ?? ((segment) => /* @__PURE__ */ jsx(DateSegment, { segment }))
472
+ });
473
+ }
474
+ function DateField({ inputProps = {}, children, size = "medium", ...props }) {
475
+ return /* @__PURE__ */ jsx(DateField$1, {
476
+ ...props,
477
+ children: (values) => /* @__PURE__ */ jsxs(Fragment, { children: [typeof children === "function" ? children(values) : children, /* @__PURE__ */ jsx(DateInput, {
478
+ ...inputProps,
479
+ size
480
+ })] })
481
+ });
482
+ }
483
+ //#endregion
484
+ //#region src/components/calendar/date-picker.module.css
485
+ var date_picker_module_default = {
486
+ "group": "_group_1dgbw_2",
487
+ "small": "_small_1dgbw_19",
488
+ "medium": "_medium_1dgbw_23",
489
+ "large": "_large_1dgbw_27",
490
+ "input": "_input_1dgbw_32",
491
+ "separator": "_separator_1dgbw_47",
492
+ "button": "_button_1dgbw_74",
493
+ "popover": "_popover_1dgbw_110"
494
+ };
495
+ //#endregion
496
+ //#region src/components/calendar/date-picker.tsx
497
+ /** A small calendar glyph for the trigger button. */
498
+ function CalendarIcon() {
499
+ return /* @__PURE__ */ jsx("svg", {
500
+ width: "16",
501
+ height: "17",
502
+ viewBox: "0 0 32 34",
503
+ fill: "none",
504
+ "aria-hidden": "true",
505
+ children: /* @__PURE__ */ jsx("path", {
506
+ fillRule: "evenodd",
507
+ clipRule: "evenodd",
508
+ d: "M8.23077 30L2 24.8077V7.61692C2 6.51235 2.89543 5.61692 4 5.61692H4.61692L4.61692 5C4.61692 3.89543 5.51235 3 6.61692 3H7.80923C8.9138 3 9.80923 3.89543 9.80923 5V5.61692H21.0964L21.1212 4.9279C21.16 3.85209 22.0434 3 23.1199 3H24.3831C25.4876 3 26.3831 3.89543 26.3831 5V5.61692H27C28.1046 5.61692 29 6.51236 29 7.61692V9.48H2V11.64H29V30H8.23077ZM17.369 17.8088L15.5001 13.827L13.6311 17.8088L9.45215 18.4472L12.4762 21.5467L11.7623 25.923L15.5001 23.8568L19.238 25.923L18.5242 21.5467L21.5481 18.4472L17.369 17.8088Z",
509
+ fill: "currentColor"
510
+ })
511
+ });
512
+ }
513
+ const dateGroup = cva({
514
+ base: date_picker_module_default.group,
515
+ variants: { size: {
516
+ small: date_picker_module_default.small,
517
+ medium: date_picker_module_default.medium,
518
+ large: date_picker_module_default.large
519
+ } }
520
+ });
521
+ /**
522
+ * The borderless `DateInput` used inside a `DatePicker`/`DateRangePicker`'s
523
+ * `Group`, which draws the border itself. `DateField`/`TimeField` use the
524
+ * standalone, self-bordered `DateInput` from "./date-field" instead.
525
+ */
526
+ function PickerDateInput({ className, children, ...props }) {
527
+ return /* @__PURE__ */ jsx(DateInput$1, {
528
+ ...props,
529
+ className: composeRenderProps(className, (className) => cx(date_picker_module_default.input, className)),
530
+ children: children ?? ((segment) => /* @__PURE__ */ jsx(DateSegment, { segment }))
531
+ });
532
+ }
533
+ function DatePickerButton({ className, children, ...props }) {
534
+ return /* @__PURE__ */ jsx(Button$1, {
535
+ ...props,
536
+ className: cx(date_picker_module_default.button, className),
537
+ children: children ?? /* @__PURE__ */ jsx(CalendarIcon, {})
538
+ });
539
+ }
540
+ function DatePickerPopover({ className, ...props }) {
541
+ return /* @__PURE__ */ jsx(Popover$1, {
542
+ ...props,
543
+ className: composeRenderProps(className, (className) => cx(date_picker_module_default.popover, className))
544
+ });
545
+ }
546
+ function DatePicker({ children, groupProps = {}, inputProps = {}, buttonProps = {}, popoverProps = {}, calendarProps = {}, size = "medium", ...props }) {
547
+ return /* @__PURE__ */ jsx(DatePicker$1, {
548
+ ...props,
549
+ children: (values) => /* @__PURE__ */ jsxs(Fragment, { children: [
550
+ typeof children === "function" ? children(values) : children,
551
+ /* @__PURE__ */ jsxs(Group$1, {
552
+ ...groupProps,
553
+ className: composeRenderProps(groupProps.className, (className, v) => dateGroup({
554
+ className,
555
+ size,
556
+ ...v
557
+ })),
558
+ children: [/* @__PURE__ */ jsx(PickerDateInput, { ...inputProps }), /* @__PURE__ */ jsx(DatePickerButton, { ...buttonProps })]
559
+ }),
560
+ /* @__PURE__ */ jsx(DatePickerPopover, {
561
+ ...popoverProps,
562
+ children: /* @__PURE__ */ jsx(Calendar, { ...calendarProps })
563
+ })
564
+ ] })
565
+ });
566
+ }
567
+ //#endregion
568
+ //#region src/components/calendar/date-range-picker.tsx
569
+ function DateRangePicker({ children, groupProps = {}, startInputProps = {}, endInputProps = {}, buttonProps = {}, popoverProps = {}, calendarProps = {}, size = "medium", shouldCloseOnSelect = false, ...props }) {
570
+ return /* @__PURE__ */ jsx(DateRangePicker$1, {
571
+ ...props,
572
+ shouldCloseOnSelect,
573
+ children: (values) => /* @__PURE__ */ jsxs(Fragment, { children: [
574
+ typeof children === "function" ? children(values) : children,
575
+ /* @__PURE__ */ jsxs(Group$1, {
576
+ ...groupProps,
577
+ className: composeRenderProps(groupProps.className, (className, v) => dateGroup({
578
+ className,
579
+ size,
580
+ ...v
581
+ })),
582
+ children: [
583
+ /* @__PURE__ */ jsx(PickerDateInput, {
584
+ ...startInputProps,
585
+ slot: "start"
586
+ }),
587
+ /* @__PURE__ */ jsx("span", {
588
+ className: date_picker_module_default.separator,
589
+ "aria-hidden": "true",
590
+ "data-disabled": values.isDisabled || void 0,
591
+ children: "–"
592
+ }),
593
+ /* @__PURE__ */ jsx(PickerDateInput, {
594
+ ...endInputProps,
595
+ slot: "end"
596
+ }),
597
+ /* @__PURE__ */ jsx(DatePickerButton, { ...buttonProps })
598
+ ]
599
+ }),
600
+ /* @__PURE__ */ jsx(DatePickerPopover, {
601
+ ...popoverProps,
602
+ children: /* @__PURE__ */ jsx(RangeCalendar, { ...calendarProps })
603
+ })
604
+ ] })
605
+ });
606
+ }
607
+ //#endregion
608
+ //#region src/components/calendar/time-field.tsx
609
+ function TimeField({ inputProps = {}, children, size = "medium", ...props }) {
610
+ return /* @__PURE__ */ jsx(TimeField$1, {
611
+ ...props,
612
+ children: (values) => /* @__PURE__ */ jsxs(Fragment, { children: [typeof children === "function" ? children(values) : children, /* @__PURE__ */ jsx(DateInput, {
613
+ ...inputProps,
614
+ size
615
+ })] })
616
+ });
617
+ }
618
+ //#endregion
115
619
  //#region src/components/checkbox/checkbox.module.css
116
620
  var checkbox_module_default = {
117
- "checkbox": "_checkbox_1rldq_2",
118
- "icon": "_icon_1rldq_22"
621
+ "checkbox": "_checkbox_6xifu_2",
622
+ "icon": "_icon_6xifu_22"
119
623
  };
120
624
  //#endregion
121
625
  //#region src/components/checkbox/checkbox-checked.png
@@ -249,6 +753,59 @@ function Divider({ preset = "center", hrProps: { className: hrClassName, ...hrPr
249
753
  });
250
754
  }
251
755
  //#endregion
756
+ //#region src/components/group.module.css
757
+ var group_module_default = {
758
+ "group": "_group_74tda_2",
759
+ "small": "_small_74tda_30",
760
+ "medium": "_medium_74tda_34",
761
+ "large": "_large_74tda_38",
762
+ "input": "_input_74tda_43",
763
+ "separator": "_separator_74tda_69"
764
+ };
765
+ //#endregion
766
+ //#region src/components/group.tsx
767
+ const group = cva({
768
+ base: group_module_default.group,
769
+ variants: { size: {
770
+ small: group_module_default.small,
771
+ medium: group_module_default.medium,
772
+ large: group_module_default.large
773
+ } }
774
+ });
775
+ /**
776
+ * Visually merges several focusable controls (inputs, buttons, static
777
+ * segments) into what reads as a single bordered field, e.g. a summoner name
778
+ * plus its `#`-prefixed tag. `Group` draws the border itself, so children
779
+ * meant to sit inside it should stay borderless — see `GroupInput` and
780
+ * `GroupSeparator`.
781
+ */
782
+ function Group({ size = "medium", className, ...props }) {
783
+ return /* @__PURE__ */ jsx(Group$1, {
784
+ ...props,
785
+ className: composeRenderProps(className, (className, values) => group({
786
+ className,
787
+ size,
788
+ ...values
789
+ }))
790
+ });
791
+ }
792
+ /** A borderless text input for use as a segment inside a `Group`. */
793
+ function GroupInput({ className, ...props }) {
794
+ return /* @__PURE__ */ jsx(Input, {
795
+ type: "text",
796
+ ...props,
797
+ className: composeRenderProps(className, (className) => cx(group_module_default.input, className))
798
+ });
799
+ }
800
+ /** A static, non-interactive segment for use inside a `Group`, e.g. a `#` between a name and its tag. */
801
+ function GroupSeparator({ className, ...props }) {
802
+ return /* @__PURE__ */ jsx("span", {
803
+ "aria-hidden": true,
804
+ ...props,
805
+ className: cx(group_module_default.separator, className)
806
+ });
807
+ }
808
+ //#endregion
252
809
  //#region src/components/typography/heading.module.css
253
810
  var heading_module_default = {
254
811
  "heading": "_heading_4cie6_2",
@@ -439,7 +996,7 @@ const numberFieldInput = cva({
439
996
  function NumberField({ inputProps = {}, groupProps = {}, children, preset = "normal", size = "medium", ...props }) {
440
997
  return /* @__PURE__ */ jsx(NumberField$1, {
441
998
  ...props,
442
- children: (values) => /* @__PURE__ */ jsxs(Fragment, { children: [typeof children === "function" ? children(values) : children, /* @__PURE__ */ jsxs(Group, {
999
+ children: (values) => /* @__PURE__ */ jsxs(Fragment, { children: [typeof children === "function" ? children(values) : children, /* @__PURE__ */ jsxs(Group$1, {
443
1000
  ...groupProps,
444
1001
  className: composeRenderProps(groupProps.className, (className, values) => numberFieldGroup({
445
1002
  className,
@@ -472,14 +1029,15 @@ function NumberField({ inputProps = {}, groupProps = {}, children, preset = "nor
472
1029
  //#endregion
473
1030
  //#region src/components/popover.module.css
474
1031
  var popover_module_default = {
475
- "popover": "_popover_uemk0_2",
476
- "top": "_top_uemk0_12",
477
- "bottom": "_bottom_uemk0_16",
478
- "left": "_left_uemk0_20",
479
- "right": "_right_uemk0_24",
480
- "arrow": "_arrow_uemk0_29",
481
- "outer": "_outer_uemk0_38",
482
- "inner": "_inner_uemk0_42"
1032
+ "popover": "_popover_18zyh_2",
1033
+ "top": "_top_18zyh_12",
1034
+ "bottom": "_bottom_18zyh_16",
1035
+ "left": "_left_18zyh_20",
1036
+ "right": "_right_18zyh_24",
1037
+ "body": "_body_18zyh_29",
1038
+ "arrow": "_arrow_18zyh_33",
1039
+ "outer": "_outer_18zyh_42",
1040
+ "inner": "_inner_18zyh_46"
483
1041
  };
484
1042
  //#endregion
485
1043
  //#region src/components/popover.tsx
@@ -530,6 +1088,12 @@ function Popover({ children, className, ...props }) {
530
1088
  }) }) }), /* @__PURE__ */ jsx(Dialog$1, { children: typeof children === "function" ? children(values) : children })] })
531
1089
  });
532
1090
  }
1091
+ function PopoverBody({ className, ...props }) {
1092
+ return /* @__PURE__ */ jsx("div", {
1093
+ ...props,
1094
+ className: cx(popover_module_default.body, className)
1095
+ });
1096
+ }
533
1097
  //#endregion
534
1098
  //#region src/components/progress-bar.module.css
535
1099
  var progress_bar_module_default = {
@@ -636,14 +1200,14 @@ function SearchField({ inputProps = {}, borderProps = {}, children, className, s
636
1200
  //#endregion
637
1201
  //#region src/components/tag-group/tag-group.module.css
638
1202
  var tag_group_module_default = {
639
- "tag": "_tag_baprz_3",
640
- "gold": "_gold_baprz_24",
641
- "hextech": "_hextech_baprz_31",
642
- "grey": "_grey_baprz_38",
643
- "text": "_text_baprz_45",
644
- "remove": "_remove_baprz_49",
645
- "tagGroup": "_tagGroup_baprz_76",
646
- "tagList": "_tagList_baprz_82"
1203
+ "tag": "_tag_1db70_3",
1204
+ "gold": "_gold_1db70_24",
1205
+ "hextech": "_hextech_1db70_31",
1206
+ "grey": "_grey_1db70_38",
1207
+ "text": "_text_1db70_45",
1208
+ "remove": "_remove_1db70_49",
1209
+ "tagGroup": "_tagGroup_1db70_76",
1210
+ "tagList": "_tagList_1db70_82"
647
1211
  };
648
1212
  //#endregion
649
1213
  //#region src/components/tag-group/tag-group.tsx
@@ -695,158 +1259,11 @@ function TagList({ children, className, selectLabel, variant = "hextech", ...pro
695
1259
  //#endregion
696
1260
  //#region src/components/select/multiple-select.module.css
697
1261
  var multiple_select_module_default = {
698
- "popover": "_popover_1bri3_2",
699
- "select": "_select_1bri3_8",
700
- "triggerContainer": "_triggerContainer_1bri3_14"
701
- };
702
- //#endregion
703
- //#region src/components/typography/text.module.css
704
- var text_module_default = {
705
- "text": "_text_1tvjr_2",
706
- "label": "_label_1tvjr_6",
707
- "stat": "_stat_1tvjr_13",
708
- "largeNumber": "_largeNumber_1tvjr_20",
709
- "sm": "_sm_1tvjr_27",
710
- "base": "_base_1tvjr_34",
711
- "md": "_md_1tvjr_41",
712
- "lg": "_lg_1tvjr_48",
713
- "grey100": "_grey100_1tvjr_55",
714
- "grey150": "_grey150_1tvjr_59",
715
- "gold100": "_gold100_1tvjr_63"
716
- };
717
- //#endregion
718
- //#region src/components/typography/text.tsx
719
- const text = cva({
720
- base: text_module_default.text,
721
- variants: {
722
- color: {
723
- grey100: text_module_default.grey100,
724
- grey150: text_module_default.grey150,
725
- gold100: text_module_default.gold100
726
- },
727
- preset: {
728
- sm: text_module_default.sm,
729
- base: text_module_default.base,
730
- md: text_module_default.md,
731
- lg: text_module_default.lg,
732
- label: text_module_default.label,
733
- largeNumber: text_module_default.largeNumber,
734
- stat: text_module_default.stat
735
- }
736
- }
737
- });
738
- function Text({ preset = "base", color = "grey100", className, ...rest }) {
739
- return /* @__PURE__ */ jsx(Text$1, {
740
- className: text({
741
- preset,
742
- color,
743
- className
744
- }),
745
- ...rest
746
- });
747
- }
748
- function Label({ preset = "sm", color = "grey100", className, ...rest }) {
749
- return /* @__PURE__ */ jsx(Label$1, {
750
- className: text({
751
- preset,
752
- color,
753
- className
754
- }),
755
- ...rest
756
- });
757
- }
758
- //#endregion
759
- //#region src/components/select/select.module.css
760
- var select_module_default = {
761
- "button": "_button_y5tgp_2",
762
- "small": "_small_y5tgp_47",
763
- "medium": "_medium_y5tgp_51",
764
- "large": "_large_y5tgp_55",
765
- "singleSelect": "_singleSelect_y5tgp_60",
766
- "multiSelect": "_multiSelect_y5tgp_67",
767
- "listBox": "_listBox_y5tgp_73",
768
- "item": "_item_y5tgp_80",
769
- "focus": "_focus_y5tgp_97",
770
- "selected": "_selected_y5tgp_106",
771
- "popover": "_popover_y5tgp_113",
772
- "emptyList": "_emptyList_y5tgp_119"
1262
+ "popover": "_popover_1gisa_2",
1263
+ "triggerContainer": "_triggerContainer_1gisa_8",
1264
+ "select": "_select_1gisa_12"
773
1265
  };
774
1266
  //#endregion
775
- //#region src/components/select/select.tsx
776
- const select = cva({
777
- base: select_module_default.button,
778
- variants: {
779
- size: {
780
- small: select_module_default.small,
781
- medium: select_module_default.medium,
782
- large: select_module_default.large
783
- },
784
- selectionMode: {
785
- single: select_module_default.singleSelect,
786
- multiple: select_module_default.multiSelect
787
- }
788
- }
789
- });
790
- function SelectButton({ className, size = "medium", ...props }) {
791
- return /* @__PURE__ */ jsx(Button$1, {
792
- ...props,
793
- className: composeRenderProps(className, (className, buttonValues) => select({
794
- ...buttonValues,
795
- size,
796
- className,
797
- selectionMode: "single"
798
- }))
799
- });
800
- }
801
- function SelectPopover({ className, ...props }) {
802
- return /* @__PURE__ */ jsx(Popover$1, {
803
- ...props,
804
- className: composeRenderProps(className, (className) => cx(className, select_module_default.popover))
805
- });
806
- }
807
- function SelectListBox({ className, emptyList = "No results found", ...props }) {
808
- return /* @__PURE__ */ jsx(ListBox, {
809
- ...props,
810
- renderEmptyState: () => /* @__PURE__ */ jsx("div", {
811
- className: text({
812
- color: "grey150",
813
- preset: "base",
814
- className: select_module_default.emptyList
815
- }),
816
- children: emptyList
817
- }),
818
- className: composeRenderProps(className, (className) => cx(className, select_module_default.listBox))
819
- });
820
- }
821
- const item = cva({
822
- base: select_module_default.item,
823
- variants: {
824
- isSelected: { true: select_module_default.selected },
825
- isFocused: { true: select_module_default.focus }
826
- }
827
- });
828
- function SelectListBoxItem({ className, ...props }) {
829
- return /* @__PURE__ */ jsx(ListBoxItem$1, {
830
- ...props,
831
- className: composeRenderProps(className, (className, values) => item({
832
- ...values,
833
- className
834
- }))
835
- });
836
- }
837
- function SelectVirtualizer(props) {
838
- return /* @__PURE__ */ jsx(Virtualizer$1, {
839
- layout: ListLayout$1,
840
- layoutOptions: {
841
- padding: 0,
842
- gap: 0,
843
- rowHeight: 31,
844
- headingHeight: 35
845
- },
846
- ...props
847
- });
848
- }
849
- //#endregion
850
1267
  //#region src/components/select/multiple-select.tsx
851
1268
  function MultipleSelect({ items, className, size = "medium", emptyList, emptyTags = "No items selected", tagGroupLabel = "Selected items", selectId, selectLabel, ...selectProps }) {
852
1269
  const triggerContainerRef = React.useRef(null);
@@ -1416,6 +1833,6 @@ function TreeLoadMoreItem({ children, className, ...props }) {
1416
1833
  });
1417
1834
  }
1418
1835
  //#endregion
1419
- export { Autocomplete, AutocompleteContext, AutocompleteStateContext, Breadcrumb, Breadcrumbs, Button, ButtonLink, Checkbox, CheckboxButton, CheckboxField, Collection, Dialog, DialogButtons, DialogHeading, DialogTrigger, Disclosure, DisclosureButton, DisclosureGroup, DisclosurePanel, Divider, FieldError, GridLayout, Heading, Label, ListBoxItem, ListLayout, Menu, MenuHeader, MenuItem, MenuPopover, MenuSection, MenuSeparator, MenuTrigger, MenuVirtualizer, Modal, MultipleSelect, NumberField, Popover, ProgressBar, Radio, RadioButton, RadioField, RadioGroup, ResizableTableContainer, RouterProvider, SearchField, Select, SelectButton, SelectListBox, SelectListBoxItem, SelectPopover, SelectValue, SelectVirtualizer, Size, Slider, SliderOutput, Sonner, Spinner, SubmenuTrigger, Switch, SwitchButton, SwitchField, Tab, TabList, TabPanel, Table, TableBody, TableCell, TableColumn, TableColumnResizer, TableFooter, TableHeader, TableLayout, TableRow, Tabs, Tag, TagGroup, TagList, Text, TextArea, TextField, ToggleButton, ToggleButtonGroup, Toolbar, ToolbarSeparator, Tree, TreeItem, TreeItemContent, TreeLoadMoreItem, UnstyledPopover, Virtualizer, WaterfallLayout, button, heading, select, sonner, table, tableCell, tableColumn, tableRow, tagGroup, tagList, text, textField, tree, treeItem, useFilter };
1836
+ export { Autocomplete, AutocompleteContext, AutocompleteStateContext, Breadcrumb, Breadcrumbs, Button, ButtonLink, Calendar, CalendarCell, CalendarGrid, CalendarGridHeader, CalendarHeaderCell, CalendarIcon, Checkbox, CheckboxButton, CheckboxField, Collection, DateField, DateInput, DatePicker, DatePickerButton, DatePickerPopover, DateRangePicker, DateSegment, Dialog, DialogButtons, DialogHeading, DialogTrigger, Disclosure, DisclosureButton, DisclosureGroup, DisclosurePanel, Divider, FieldError, GridLayout, Group, GroupInput, GroupSeparator, Heading, Label, ListBoxItem, ListLayout, Menu, MenuHeader, MenuItem, MenuPopover, MenuSection, MenuSeparator, MenuTrigger, MenuVirtualizer, Modal, MultipleSelect, NumberField, PickerDateInput, Popover, PopoverBody, ProgressBar, Radio, RadioButton, RadioField, RadioGroup, RangeCalendar, ResizableTableContainer, RouterProvider, SearchField, Select, SelectButton, SelectListBox, SelectListBoxItem, SelectPopover, SelectValue, SelectVirtualizer, Size, Slider, SliderOutput, Sonner, Spinner, SubmenuTrigger, Switch, SwitchButton, SwitchField, Tab, TabList, TabPanel, Table, TableBody, TableCell, TableColumn, TableColumnResizer, TableFooter, TableHeader, TableLayout, TableRow, Tabs, Tag, TagGroup, TagList, Text, TextArea, TextField, TimeField, ToggleButton, ToggleButtonGroup, Toolbar, ToolbarSeparator, Tree, TreeItem, TreeItemContent, TreeLoadMoreItem, UnstyledPopover, Virtualizer, WaterfallLayout, button, dateGroup, dateInput, group, heading, select, sonner, table, tableCell, tableColumn, tableRow, tagGroup, tagList, text, textField, tree, treeItem, useFilter };
1420
1837
 
1421
1838
  //# sourceMappingURL=index.mjs.map