frontile 0.18.0-alpha.14 → 0.18.0-alpha.15

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.
Files changed (61) hide show
  1. package/declarations/components/buttons/chip.d.ts +35 -4
  2. package/declarations/components/collections/listbox/item.d.ts +6 -0
  3. package/declarations/components/collections/listbox/listbox.d.ts +9 -6
  4. package/declarations/components/forms/autocomplete.d.ts +13 -2
  5. package/declarations/components/forms/form.d.ts +1 -1
  6. package/declarations/components/forms/input.d.ts +11 -1
  7. package/declarations/components/forms/native-select.d.ts +22 -6
  8. package/declarations/components/forms/select/end-content.d.ts +31 -0
  9. package/declarations/components/forms/select/native-mirror.d.ts +44 -0
  10. package/declarations/components/forms/select/select.d.ts +425 -0
  11. package/declarations/components/forms/select/selected-items.d.ts +80 -0
  12. package/declarations/components/forms/select/trigger.d.ts +76 -0
  13. package/declarations/components/forms/select/types.d.ts +411 -0
  14. package/declarations/components/forms/select.d.ts +2 -498
  15. package/declarations/components/forms/textarea.d.ts +6 -0
  16. package/declarations/components/overlays/popover.d.ts +33 -0
  17. package/declarations/components/status/progress-bar.d.ts +5 -0
  18. package/declarations/components/utilities/divider.d.ts +14 -0
  19. package/declarations/components/utilities/spinner.d.ts +8 -0
  20. package/declarations/utils/listManager.d.ts +30 -5
  21. package/dist/components/buttons/chip.js +1 -1
  22. package/dist/components/buttons/chip.js.map +1 -1
  23. package/dist/components/collections/listbox/item.js +1 -1
  24. package/dist/components/collections/listbox/item.js.map +1 -1
  25. package/dist/components/collections/listbox/listbox.js +1 -1
  26. package/dist/components/collections/listbox/listbox.js.map +1 -1
  27. package/dist/components/forms/field.js +1 -1
  28. package/dist/components/forms/index.js +1 -1
  29. package/dist/components/forms/native-select.js +2 -2
  30. package/dist/components/forms/native-select.js.map +1 -1
  31. package/dist/components/forms/select/end-content.js +24 -0
  32. package/dist/components/forms/select/end-content.js.map +1 -0
  33. package/dist/components/forms/select/native-mirror.js +29 -0
  34. package/dist/components/forms/select/native-mirror.js.map +1 -0
  35. package/dist/components/forms/select/select.js +599 -0
  36. package/dist/components/forms/select/select.js.map +1 -0
  37. package/dist/components/forms/select/selected-items.js +63 -0
  38. package/dist/components/forms/select/selected-items.js.map +1 -0
  39. package/dist/components/forms/select/trigger.js +30 -0
  40. package/dist/components/forms/select/trigger.js.map +1 -0
  41. package/dist/components/forms/select/types.js +2 -0
  42. package/dist/components/forms/select/types.js.map +1 -0
  43. package/dist/components/forms/select.js +1 -391
  44. package/dist/components/forms/select.js.map +1 -1
  45. package/dist/components/overlays/popover.js +53 -2
  46. package/dist/components/overlays/popover.js.map +1 -1
  47. package/dist/components/status/progress-bar.js +8 -1
  48. package/dist/components/status/progress-bar.js.map +1 -1
  49. package/dist/components/utilities/avatar.js +1 -1
  50. package/dist/components/utilities/avatar.js.map +1 -1
  51. package/dist/components/utilities/divider.js +8 -2
  52. package/dist/components/utilities/divider.js.map +1 -1
  53. package/dist/components/utilities/spinner.js +1 -1
  54. package/dist/components/utilities/spinner.js.map +1 -1
  55. package/dist/forms.js +1 -1
  56. package/dist/index.js +1 -1
  57. package/dist/utils/listManager.js +63 -4
  58. package/dist/utils/listManager.js.map +1 -1
  59. package/dist/utils/nested-data.js +10 -1
  60. package/dist/utils/nested-data.js.map +1 -1
  61. package/package.json +4 -4
@@ -8,19 +8,29 @@ interface ChipSignature {
8
8
  */
9
9
  appearance?: 'default' | 'outlined' | 'faded';
10
10
  /**
11
- * The intent of the chip
11
+ * The intent of the chip, which drives its color
12
+ *
13
+ * @defaultValue 'default'
12
14
  */
13
15
  intent?: 'default' | 'primary' | 'secondary' | 'tertiary' | 'success' | 'warning' | 'danger';
14
16
  /**
15
17
  * The size of the chip
18
+ *
19
+ * @defaultValue 'md'
16
20
  */
17
21
  size?: 'sm' | 'md' | 'lg';
18
22
  /**
19
- * The radius the chip
23
+ * The border radius of the chip
24
+ *
25
+ * @defaultValue 'full'
20
26
  */
21
27
  radius?: 'none' | 'sm' | 'lg' | 'full';
22
28
  /**
23
- * Option to add dot to the chip
29
+ * Adds a dot before the content, colored by `@intent`. On the `default`
30
+ * appearance the dot takes the chip's text color, since the chip's
31
+ * background is already the intent color.
32
+ *
33
+ * @defaultValue false
24
34
  */
25
35
  withDot?: boolean;
26
36
  /**
@@ -29,7 +39,28 @@ interface ChipSignature {
29
39
  */
30
40
  onClose?: () => void;
31
41
  /**
32
- * Disables the clip and disables the close button if any.
42
+ * The accessible name of the close button. Every close button would
43
+ * otherwise be announced as just "Close", which does not say *what* is
44
+ * being removed — worth setting when several chips sit together.
45
+ *
46
+ * @defaultValue 'Close'
47
+ */
48
+ closeButtonTitle?: string;
49
+ /**
50
+ * `tabindex` for the close button.
51
+ *
52
+ * Set to `-1` when chips sit inside another control (a multi-select field,
53
+ * say) and the close button should stay a pointer affordance: every chip
54
+ * would otherwise cost a Tab stop before the control itself is reached.
55
+ * Whoever does this owes keyboard users another way to remove a chip.
56
+ *
57
+ * @defaultValue undefined (the close button is a normal tab stop)
58
+ */
59
+ closeButtonTabIndex?: number | string;
60
+ /**
61
+ * Dims the chip and disables its close button, if any.
62
+ *
63
+ * @defaultValue false
33
64
  */
34
65
  isDisabled?: boolean;
35
66
  /**
@@ -5,6 +5,12 @@ export interface ListboxItemSignature {
5
5
  manager: ListManager;
6
6
  key: string;
7
7
  textValue?: string;
8
+ /**
9
+ * The entry of `@items` this option renders, remembered on the registered
10
+ * list item so a selection can hand it back. Bound for you on the Item
11
+ * yielded from the `:item` block; block-form options have no such entry.
12
+ */
13
+ item?: unknown;
8
14
  description?: string;
9
15
  shortcut?: string;
10
16
  onClick?: () => void;
@@ -3,6 +3,7 @@ import { ListManager, type SelectionMode, type ListItem } from '../../../utils/l
3
3
  import { ListboxItem, type ListboxItemSignature } from './item';
4
4
  import type { WithBoundArgs } from '@glint/template';
5
5
  type ItemCompBounded = WithBoundArgs<typeof ListboxItem, 'manager'>;
6
+ type ItemCompBoundedWithItem = WithBoundArgs<typeof ListboxItem, 'manager' | 'item'>;
6
7
  interface ListboxSignature<T> {
7
8
  Args: {
8
9
  /**
@@ -42,12 +43,14 @@ interface ListboxSignature<T> {
42
43
  };
43
44
  Element: HTMLUListElement;
44
45
  Blocks: {
45
- item: [{
46
- item: T;
47
- key: string;
48
- label: string;
49
- Item: ItemCompBounded;
50
- }];
46
+ item: [
47
+ {
48
+ item: T;
49
+ key: string;
50
+ label: string;
51
+ Item: ItemCompBoundedWithItem;
52
+ }
53
+ ];
51
54
  default: [{
52
55
  Item: ItemCompBounded;
53
56
  }];
@@ -247,7 +247,7 @@ declare class Autocomplete<T = unknown> extends Component<AutocompleteSignature<
247
247
  selectedLabel?: string;
248
248
  containerRef: {
249
249
  current: HTMLDivElement | undefined;
250
- "__#8@#onChange"?: ((el: HTMLDivElement | undefined) => void) | undefined;
250
+ "__#9@#onChange"?: ((el: HTMLDivElement | undefined) => void) | undefined;
251
251
  setup: import("ember-modifier").FunctionBasedModifier<{
252
252
  Args: {
253
253
  Positional: unknown[];
@@ -258,7 +258,7 @@ declare class Autocomplete<T = unknown> extends Component<AutocompleteSignature<
258
258
  };
259
259
  triggerRef: {
260
260
  current: HTMLInputElement | undefined;
261
- "__#8@#onChange"?: ((el: HTMLInputElement | undefined) => void) | undefined;
261
+ "__#9@#onChange"?: ((el: HTMLInputElement | undefined) => void) | undefined;
262
262
  setup: import("ember-modifier").FunctionBasedModifier<{
263
263
  Args: {
264
264
  Positional: unknown[];
@@ -301,6 +301,7 @@ declare class Autocomplete<T = unknown> extends Component<AutocompleteSignature<
301
301
  endContentPointerEvents?: "none" | "auto" | undefined;
302
302
  hasStartContent?: boolean | undefined;
303
303
  hasEndContent?: boolean | undefined;
304
+ hasChips?: boolean | undefined;
304
305
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
305
306
  innerContainer: (slotProps?: ({
306
307
  size?: "sm" | "md" | "lg" | undefined;
@@ -308,6 +309,7 @@ declare class Autocomplete<T = unknown> extends Component<AutocompleteSignature<
308
309
  endContentPointerEvents?: "none" | "auto" | undefined;
309
310
  hasStartContent?: boolean | undefined;
310
311
  hasEndContent?: boolean | undefined;
312
+ hasChips?: boolean | undefined;
311
313
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
312
314
  startContent: (slotProps?: ({
313
315
  size?: "sm" | "md" | "lg" | undefined;
@@ -315,6 +317,7 @@ declare class Autocomplete<T = unknown> extends Component<AutocompleteSignature<
315
317
  endContentPointerEvents?: "none" | "auto" | undefined;
316
318
  hasStartContent?: boolean | undefined;
317
319
  hasEndContent?: boolean | undefined;
320
+ hasChips?: boolean | undefined;
318
321
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
319
322
  endContent: (slotProps?: ({
320
323
  size?: "sm" | "md" | "lg" | undefined;
@@ -322,6 +325,7 @@ declare class Autocomplete<T = unknown> extends Component<AutocompleteSignature<
322
325
  endContentPointerEvents?: "none" | "auto" | undefined;
323
326
  hasStartContent?: boolean | undefined;
324
327
  hasEndContent?: boolean | undefined;
328
+ hasChips?: boolean | undefined;
325
329
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
326
330
  input: (slotProps?: ({
327
331
  size?: "sm" | "md" | "lg" | undefined;
@@ -329,6 +333,7 @@ declare class Autocomplete<T = unknown> extends Component<AutocompleteSignature<
329
333
  endContentPointerEvents?: "none" | "auto" | undefined;
330
334
  hasStartContent?: boolean | undefined;
331
335
  hasEndContent?: boolean | undefined;
336
+ hasChips?: boolean | undefined;
332
337
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
333
338
  } & {
334
339
  base: (slotProps?: ({
@@ -337,6 +342,7 @@ declare class Autocomplete<T = unknown> extends Component<AutocompleteSignature<
337
342
  endContentPointerEvents?: "none" | "auto" | undefined;
338
343
  hasStartContent?: boolean | undefined;
339
344
  hasEndContent?: boolean | undefined;
345
+ hasChips?: boolean | undefined;
340
346
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
341
347
  listbox: (slotProps?: ({
342
348
  size?: "sm" | "md" | "lg" | undefined;
@@ -344,6 +350,7 @@ declare class Autocomplete<T = unknown> extends Component<AutocompleteSignature<
344
350
  endContentPointerEvents?: "none" | "auto" | undefined;
345
351
  hasStartContent?: boolean | undefined;
346
352
  hasEndContent?: boolean | undefined;
353
+ hasChips?: boolean | undefined;
347
354
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
348
355
  icon: (slotProps?: ({
349
356
  size?: "sm" | "md" | "lg" | undefined;
@@ -351,6 +358,7 @@ declare class Autocomplete<T = unknown> extends Component<AutocompleteSignature<
351
358
  endContentPointerEvents?: "none" | "auto" | undefined;
352
359
  hasStartContent?: boolean | undefined;
353
360
  hasEndContent?: boolean | undefined;
361
+ hasChips?: boolean | undefined;
354
362
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
355
363
  clearButton: (slotProps?: ({
356
364
  size?: "sm" | "md" | "lg" | undefined;
@@ -358,6 +366,7 @@ declare class Autocomplete<T = unknown> extends Component<AutocompleteSignature<
358
366
  endContentPointerEvents?: "none" | "auto" | undefined;
359
367
  hasStartContent?: boolean | undefined;
360
368
  hasEndContent?: boolean | undefined;
369
+ hasChips?: boolean | undefined;
361
370
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
362
371
  input: (slotProps?: ({
363
372
  size?: "sm" | "md" | "lg" | undefined;
@@ -365,6 +374,7 @@ declare class Autocomplete<T = unknown> extends Component<AutocompleteSignature<
365
374
  endContentPointerEvents?: "none" | "auto" | undefined;
366
375
  hasStartContent?: boolean | undefined;
367
376
  hasEndContent?: boolean | undefined;
377
+ hasChips?: boolean | undefined;
368
378
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
369
379
  emptyContent: (slotProps?: ({
370
380
  size?: "sm" | "md" | "lg" | undefined;
@@ -372,6 +382,7 @@ declare class Autocomplete<T = unknown> extends Component<AutocompleteSignature<
372
382
  endContentPointerEvents?: "none" | "auto" | undefined;
373
383
  hasStartContent?: boolean | undefined;
374
384
  hasEndContent?: boolean | undefined;
385
+ hasChips?: boolean | undefined;
375
386
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
376
387
  } & {};
377
388
  get isClearable(): boolean | undefined;
@@ -159,7 +159,7 @@ declare class Form<T = FormDataCompiled> extends Component<FormSignature<T>> {
159
159
  /** Reference to the form element. */
160
160
  element: {
161
161
  current: HTMLFormElement | undefined;
162
- "__#8@#onChange"?: ((el: HTMLFormElement | undefined) => void) | undefined;
162
+ "__#9@#onChange"?: ((el: HTMLFormElement | undefined) => void) | undefined;
163
163
  setup: import("ember-modifier").FunctionBasedModifier<{
164
164
  Args: {
165
165
  Positional: unknown[];
@@ -78,7 +78,7 @@ declare class Input extends Component<InputSignature> {
78
78
  elementValue: string;
79
79
  inputRef: {
80
80
  current: HTMLInputElement | undefined;
81
- "__#8@#onChange"?: ((el: HTMLInputElement | undefined) => void) | undefined;
81
+ "__#9@#onChange"?: ((el: HTMLInputElement | undefined) => void) | undefined;
82
82
  setup: import("ember-modifier").FunctionBasedModifier<{
83
83
  Args: {
84
84
  Positional: unknown[];
@@ -107,6 +107,7 @@ declare class Input extends Component<InputSignature> {
107
107
  endContentPointerEvents?: "none" | "auto" | undefined;
108
108
  hasStartContent?: boolean | undefined;
109
109
  hasEndContent?: boolean | undefined;
110
+ hasChips?: boolean | undefined;
110
111
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
111
112
  innerContainer: (slotProps?: ({
112
113
  size?: "sm" | "md" | "lg" | undefined;
@@ -114,6 +115,7 @@ declare class Input extends Component<InputSignature> {
114
115
  endContentPointerEvents?: "none" | "auto" | undefined;
115
116
  hasStartContent?: boolean | undefined;
116
117
  hasEndContent?: boolean | undefined;
118
+ hasChips?: boolean | undefined;
117
119
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
118
120
  startContent: (slotProps?: ({
119
121
  size?: "sm" | "md" | "lg" | undefined;
@@ -121,6 +123,7 @@ declare class Input extends Component<InputSignature> {
121
123
  endContentPointerEvents?: "none" | "auto" | undefined;
122
124
  hasStartContent?: boolean | undefined;
123
125
  hasEndContent?: boolean | undefined;
126
+ hasChips?: boolean | undefined;
124
127
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
125
128
  endContent: (slotProps?: ({
126
129
  size?: "sm" | "md" | "lg" | undefined;
@@ -128,6 +131,7 @@ declare class Input extends Component<InputSignature> {
128
131
  endContentPointerEvents?: "none" | "auto" | undefined;
129
132
  hasStartContent?: boolean | undefined;
130
133
  hasEndContent?: boolean | undefined;
134
+ hasChips?: boolean | undefined;
131
135
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
132
136
  input: (slotProps?: ({
133
137
  size?: "sm" | "md" | "lg" | undefined;
@@ -135,6 +139,7 @@ declare class Input extends Component<InputSignature> {
135
139
  endContentPointerEvents?: "none" | "auto" | undefined;
136
140
  hasStartContent?: boolean | undefined;
137
141
  hasEndContent?: boolean | undefined;
142
+ hasChips?: boolean | undefined;
138
143
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
139
144
  } & {
140
145
  base: (slotProps?: ({
@@ -143,6 +148,7 @@ declare class Input extends Component<InputSignature> {
143
148
  endContentPointerEvents?: "none" | "auto" | undefined;
144
149
  hasStartContent?: boolean | undefined;
145
150
  hasEndContent?: boolean | undefined;
151
+ hasChips?: boolean | undefined;
146
152
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
147
153
  innerContainer: (slotProps?: ({
148
154
  size?: "sm" | "md" | "lg" | undefined;
@@ -150,6 +156,7 @@ declare class Input extends Component<InputSignature> {
150
156
  endContentPointerEvents?: "none" | "auto" | undefined;
151
157
  hasStartContent?: boolean | undefined;
152
158
  hasEndContent?: boolean | undefined;
159
+ hasChips?: boolean | undefined;
153
160
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
154
161
  startContent: (slotProps?: ({
155
162
  size?: "sm" | "md" | "lg" | undefined;
@@ -157,6 +164,7 @@ declare class Input extends Component<InputSignature> {
157
164
  endContentPointerEvents?: "none" | "auto" | undefined;
158
165
  hasStartContent?: boolean | undefined;
159
166
  hasEndContent?: boolean | undefined;
167
+ hasChips?: boolean | undefined;
160
168
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
161
169
  endContent: (slotProps?: ({
162
170
  size?: "sm" | "md" | "lg" | undefined;
@@ -164,6 +172,7 @@ declare class Input extends Component<InputSignature> {
164
172
  endContentPointerEvents?: "none" | "auto" | undefined;
165
173
  hasStartContent?: boolean | undefined;
166
174
  hasEndContent?: boolean | undefined;
175
+ hasChips?: boolean | undefined;
167
176
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
168
177
  input: (slotProps?: ({
169
178
  size?: "sm" | "md" | "lg" | undefined;
@@ -171,6 +180,7 @@ declare class Input extends Component<InputSignature> {
171
180
  endContentPointerEvents?: "none" | "auto" | undefined;
172
181
  hasStartContent?: boolean | undefined;
173
182
  hasEndContent?: boolean | undefined;
183
+ hasChips?: boolean | undefined;
174
184
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
175
185
  } & {};
176
186
  }
@@ -5,6 +5,7 @@ import { type FormControlSharedArgs } from './form-control';
5
5
  import { ListManager, type ListItem } from '../../utils/listManager';
6
6
  import type { WithBoundArgs } from '@glint/template';
7
7
  type ItemCompBounded = WithBoundArgs<typeof NativeSelectItem, 'manager'>;
8
+ type ItemCompBoundedWithItem = WithBoundArgs<typeof NativeSelectItem, 'manager' | 'item'>;
8
9
  interface BaseArgs<T> extends FormControlSharedArgs {
9
10
  /**
10
11
  * Keys of the options that cannot be selected. Disabled options are still
@@ -125,12 +126,14 @@ interface NativeSelectSignature<T> {
125
126
  Args: Args<T>;
126
127
  Element: HTMLSelectElement;
127
128
  Blocks: {
128
- item: [{
129
- item: T;
130
- key: string;
131
- label: string;
132
- Item: ItemCompBounded;
133
- }];
129
+ item: [
130
+ {
131
+ item: T;
132
+ key: string;
133
+ label: string;
134
+ Item: ItemCompBoundedWithItem;
135
+ }
136
+ ];
134
137
  default: [{
135
138
  Item: ItemCompBounded;
136
139
  }];
@@ -151,6 +154,7 @@ declare class NativeSelect<T = unknown> extends Component<NativeSelectSignature<
151
154
  endContentPointerEvents?: "none" | "auto" | undefined;
152
155
  hasStartContent?: boolean | undefined;
153
156
  hasEndContent?: boolean | undefined;
157
+ hasChips?: boolean | undefined;
154
158
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
155
159
  innerContainer: (slotProps?: ({
156
160
  size?: "sm" | "md" | "lg" | undefined;
@@ -158,6 +162,7 @@ declare class NativeSelect<T = unknown> extends Component<NativeSelectSignature<
158
162
  endContentPointerEvents?: "none" | "auto" | undefined;
159
163
  hasStartContent?: boolean | undefined;
160
164
  hasEndContent?: boolean | undefined;
165
+ hasChips?: boolean | undefined;
161
166
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
162
167
  startContent: (slotProps?: ({
163
168
  size?: "sm" | "md" | "lg" | undefined;
@@ -165,6 +170,7 @@ declare class NativeSelect<T = unknown> extends Component<NativeSelectSignature<
165
170
  endContentPointerEvents?: "none" | "auto" | undefined;
166
171
  hasStartContent?: boolean | undefined;
167
172
  hasEndContent?: boolean | undefined;
173
+ hasChips?: boolean | undefined;
168
174
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
169
175
  endContent: (slotProps?: ({
170
176
  size?: "sm" | "md" | "lg" | undefined;
@@ -172,6 +178,7 @@ declare class NativeSelect<T = unknown> extends Component<NativeSelectSignature<
172
178
  endContentPointerEvents?: "none" | "auto" | undefined;
173
179
  hasStartContent?: boolean | undefined;
174
180
  hasEndContent?: boolean | undefined;
181
+ hasChips?: boolean | undefined;
175
182
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
176
183
  input: (slotProps?: ({
177
184
  size?: "sm" | "md" | "lg" | undefined;
@@ -179,6 +186,7 @@ declare class NativeSelect<T = unknown> extends Component<NativeSelectSignature<
179
186
  endContentPointerEvents?: "none" | "auto" | undefined;
180
187
  hasStartContent?: boolean | undefined;
181
188
  hasEndContent?: boolean | undefined;
189
+ hasChips?: boolean | undefined;
182
190
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
183
191
  } & {
184
192
  input: (slotProps?: ({
@@ -187,6 +195,7 @@ declare class NativeSelect<T = unknown> extends Component<NativeSelectSignature<
187
195
  endContentPointerEvents?: "none" | "auto" | undefined;
188
196
  hasStartContent?: boolean | undefined;
189
197
  hasEndContent?: boolean | undefined;
198
+ hasChips?: boolean | undefined;
190
199
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
191
200
  icon: (slotProps?: ({
192
201
  size?: "sm" | "md" | "lg" | undefined;
@@ -194,6 +203,7 @@ declare class NativeSelect<T = unknown> extends Component<NativeSelectSignature<
194
203
  endContentPointerEvents?: "none" | "auto" | undefined;
195
204
  hasStartContent?: boolean | undefined;
196
205
  hasEndContent?: boolean | undefined;
206
+ hasChips?: boolean | undefined;
197
207
  } & import("tailwind-variants").ClassProp<import("tailwind-variants").ClassValue>) | undefined) => string;
198
208
  } & {};
199
209
  get isMultiple(): boolean;
@@ -216,6 +226,12 @@ export interface SelectItemSignature {
216
226
  * option's rendered text content.
217
227
  */
218
228
  textValue?: string;
229
+ /**
230
+ * The entry of `@items` this option renders, remembered on the registered
231
+ * list item so a selection can hand it back. Bound for you on the Item
232
+ * yielded from the `:item` block; block-form options have no such entry.
233
+ */
234
+ item?: unknown;
219
235
  };
220
236
  Element: HTMLOptionElement;
221
237
  Blocks: {
@@ -0,0 +1,31 @@
1
+ import type { TOC } from '@ember/component/template-only';
2
+ import type { SelectSlots, SelectVariants, SlotsToClasses } from '@frontile/theme';
3
+ import type { SelectClasses } from './types';
4
+ interface SelectEndContentSignature {
5
+ Args: {
6
+ classes: SelectClasses;
7
+ userClasses?: SlotsToClasses<SelectSlots>;
8
+ /**
9
+ * Defaults to `none` so clicks fall through to the trigger; content that
10
+ * needs its own events opts back in per element.
11
+ */
12
+ endContentPointerEvents?: 'none' | 'auto';
13
+ inputSize?: SelectVariants['size'];
14
+ isLoading?: boolean;
15
+ /** Whether the clear button takes the chevron's place. */
16
+ isClearable?: boolean;
17
+ onClear: () => void;
18
+ };
19
+ Blocks: {
20
+ /** Consumer content, rendered before the spinner/clear/chevron cluster. */
21
+ default: [];
22
+ };
23
+ Element: HTMLDivElement;
24
+ }
25
+ /**
26
+ * The cluster at the end of the field: any consumer content, then exactly one
27
+ * of the loading spinner, the clear button, or the chevron.
28
+ */
29
+ declare const SelectEndContent: TOC<SelectEndContentSignature>;
30
+ export { SelectEndContent, type SelectEndContentSignature };
31
+ export default SelectEndContent;
@@ -0,0 +1,44 @@
1
+ import Component from '@glimmer/component';
2
+ import { type ListItem, type NativeSelectSignature } from '../native-select';
3
+ interface SelectNativeMirrorSignature<T> {
4
+ Args: {
5
+ /**
6
+ * The **unfiltered** collection. The mirror carries the form value, which
7
+ * must not shrink to whatever the listbox filter currently shows, so it is
8
+ * deliberately never handed `filteredItems`.
9
+ */
10
+ items?: T[];
11
+ allowEmpty?: boolean;
12
+ disabledKeys?: string[];
13
+ selectionMode?: 'single' | 'multiple';
14
+ /** Read in multiple selection mode. */
15
+ selectedKeys: string[];
16
+ /** Read in single selection mode. */
17
+ selectedKey: string | null;
18
+ /** Selection handler for multiple selection mode. */
19
+ onSelectionChange: (keys: string[]) => void;
20
+ /** Selection handler for single selection mode. */
21
+ onSingleSelectionChange: (key: string | null) => void;
22
+ onItemsChange: (nodes: ListItem[], action: 'add' | 'remove') => void;
23
+ placeholder?: string;
24
+ id?: string;
25
+ name?: string;
26
+ isDisabled?: boolean;
27
+ };
28
+ Blocks: {
29
+ default: NativeSelectSignature<T>['Blocks']['default'];
30
+ };
31
+ }
32
+ /**
33
+ * The visually hidden native `<select>` that makes a Select submit with a form.
34
+ *
35
+ * Single and multiple selection mode differ only in three arguments, so those
36
+ * three are curried onto the component and everything else -- the element, its
37
+ * attributes and both blocks -- is written **once**. Two copies of this used to
38
+ * sit side by side in `select.gts`, and a fix to the submitted value landed in
39
+ * one of them and not the other.
40
+ */
41
+ declare class SelectNativeMirror<T = unknown> extends Component<SelectNativeMirrorSignature<T>> {
42
+ }
43
+ export { SelectNativeMirror, type SelectNativeMirrorSignature };
44
+ export default SelectNativeMirror;