@fusion.dev/helix-headless 0.228.0 → 0.229.1

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 (51) hide show
  1. package/api.json +1 -1
  2. package/custom-elements.json +1 -1
  3. package/dist/announcement/root/announcement-root.d.ts +0 -23
  4. package/dist/announcement/root/announcement-root.js +0 -3
  5. package/dist/button-group/root/button-group-root.d.ts +2 -3
  6. package/dist/canvas/edge/canvas-edge.d.ts +9 -9
  7. package/dist/canvas/edge/canvas-edge.js +3 -3
  8. package/dist/canvas/node/canvas-node.d.ts +1 -1
  9. package/dist/canvas/node/canvas-node.js +1 -1
  10. package/dist/canvas/root/canvas-root.js +1 -1
  11. package/dist/code-block/root/code-block-root.d.ts +9 -9
  12. package/dist/code-block/root/code-block-root.js +4 -4
  13. package/dist/color-input/root/color-input-root.d.ts +7 -7
  14. package/dist/color-input/root/color-input-root.js +9 -9
  15. package/dist/filter-input/chip/filter-chip.js +1 -1
  16. package/dist/image/root/image-root.d.ts +3 -0
  17. package/dist/image/root/image-root.js +9 -6
  18. package/dist/list/root/list-root.d.ts +1 -1
  19. package/dist/list/root/list-root.js +2 -1
  20. package/dist/map/marker/map-marker.d.ts +1 -1
  21. package/dist/map/marker/map-marker.js +1 -1
  22. package/dist/megamenu/root/megamenu-root.d.ts +24 -24
  23. package/dist/megamenu/root/megamenu-root.js +4 -4
  24. package/dist/meter/segment/meter-segment.d.ts +0 -5
  25. package/dist/meter/segment/meter-segment.js +0 -3
  26. package/dist/navigation/root/navigation-root.d.ts +7 -7
  27. package/dist/navigation/root/navigation-root.js +2 -2
  28. package/dist/option/root/option-root.d.ts +1 -1
  29. package/dist/option/root/option-root.js +3 -3
  30. package/dist/outline/root/outline-root.d.ts +21 -21
  31. package/dist/outline/root/outline-root.js +6 -6
  32. package/dist/radio/root/radio-root.d.ts +1 -1
  33. package/dist/select/root/select-root.js +1 -1
  34. package/dist/spatial-bar-chart/root/spatial-bar-chart-root.d.ts +33 -33
  35. package/dist/spatial-bar-chart/root/spatial-bar-chart-root.js +5 -5
  36. package/dist/steps/root/steps-root.d.ts +17 -17
  37. package/dist/steps/root/steps-root.js +3 -3
  38. package/dist/switch/root/switch-root.d.ts +1 -0
  39. package/dist/switch/root/switch-root.js +4 -0
  40. package/dist/tabs/root/tabs-root.d.ts +13 -13
  41. package/dist/tabs/root/tabs-root.js +3 -3
  42. package/dist/time-input/root/time-input-root.d.ts +26 -26
  43. package/dist/time-input/root/time-input-root.js +10 -10
  44. package/dist/time-picker/root/time-picker-root.d.ts +40 -40
  45. package/dist/time-picker/root/time-picker-root.js +10 -10
  46. package/examples.json +1 -1
  47. package/lint.json +1 -1
  48. package/package.json +5 -5
  49. package/types/jsx.d.ts +207 -237
  50. package/types/vue.d.ts +159 -184
  51. package/types/words.d.ts +8 -1
@@ -9,7 +9,7 @@ declare const HelixHeadlessTimePicker_base: (new (...args: any[]) => import("@fu
9
9
  * @description
10
10
  * Shows the times at each `step` as a `Listbox`, which provides the keyboard
11
11
  * behavior, typeahead, scrolling into view, and announcements for a set of
12
- * options. `variant="wheels"` shows a column each for the hour, the minute, and
12
+ * options. `picker="wheels"` shows a column each for the hour, the minute, and
13
13
  * the meridiem, and one for the second with `seconds`. Left and Right move
14
14
  * between the wheels, and Tab does too.
15
15
  *
@@ -257,7 +257,7 @@ export declare class HelixHeadlessTimePicker extends HelixHeadlessTimePicker_bas
257
257
  * separate "from" and "to" control, is two answers to what a product asks as
258
258
  * one, and it makes the between part impossible to show.
259
259
  *
260
- * **Neither works on wheels and the variant falls back.** A range on
260
+ * **Neither works on wheels and the picker falls back.** A range on
261
261
  * wheels is two sets of wheels, which is two controls; a multiple is a set,
262
262
  * and a wheel has exactly one value by construction. Rather than draw
263
263
  * something that cannot say what it holds, `wheels` renders as a list
@@ -269,16 +269,39 @@ export declare class HelixHeadlessTimePicker extends HelixHeadlessTimePicker_bas
269
269
  * `show-now`.
270
270
  */
271
271
  nowLabel: string;
272
+ /**
273
+ * Shows the times as one `list`, or as `wheels` with a column for each part
274
+ * of the time.
275
+ *
276
+ * `list` is the default and offers whole times, which is what a product with
277
+ * opening hours or slots actually has. `wheels` splits them into an hour, a
278
+ * minute and, where the locale uses one, a meridiem: three short columns
279
+ * instead of ninety-six rows, and the only way to reach `23:45` without
280
+ * scrolling most of a day.
281
+ *
282
+ * The trade is that a wheel cannot say which *combinations* are on offer. A
283
+ * list of half hours from nine to five is seventeen rows and every one of them
284
+ * is a time the product has; the same thing as columns is an hour column and a
285
+ * minute column, and nothing in either says the two are only valid together.
286
+ * The bounds are still enforced, so a reader can be refused after the fact,
287
+ * which is worse than not being offered it.
288
+ *
289
+ * So: `list` where the set is the point, `wheels` where any time is allowed
290
+ * and the range is a whole day.
291
+ *
292
+ * **Optional rather than defaulted, which is not a style preference.** A
293
+ * reflecting property with a default writes its attribute onto every host the
294
+ * moment the element upgrades, including the ones a consumer rendered and did
295
+ * not touch, and React reads that as a hydration mismatch. The absent
296
+ * attribute *is* the list, which the stylesheet reads as the base rule, so
297
+ * only the departure has to be named.
298
+ */
299
+ picker?: 'list' | 'wheels';
272
300
  /**
273
301
  * The validation message for a time after `max`. `{max}` is replaced with
274
302
  * `max`, written in `locale`.
275
303
  */
276
304
  rangeOverflowMessage: string;
277
- /**
278
- * The validation message for a time before `min`. `{min}` is replaced with
279
- * `min`, written in `locale`.
280
- */
281
- rangeUnderflowMessage: string;
282
305
  /**
283
306
  * Every time on offer, as seconds since midnight.
284
307
  *
@@ -428,6 +451,13 @@ export declare class HelixHeadlessTimePicker extends HelixHeadlessTimePicker_bas
428
451
  * rather than wrong, which is why it can be left in.
429
452
  */
430
453
  reveal(): void;
454
+ /**
455
+ * The validation message for a time before `min`. `{min}` is replaced with
456
+ * `min`, written in `locale`.
457
+ */
458
+ rangeUnderflowMessage: string;
459
+ /** Refuses every change while read-only. See `readOnly`. */
460
+ requestValue(next: string): boolean;
431
461
  /**
432
462
  * Blocks changes to the time. The value is still submitted with the form.
433
463
  *
@@ -442,8 +472,6 @@ export declare class HelixHeadlessTimePicker extends HelixHeadlessTimePicker_bas
442
472
  * else set needs.
443
473
  */
444
474
  readOnly: boolean;
445
- /** Refuses every change while read-only. See `readOnly`. */
446
- requestValue(next: string): boolean;
447
475
  /**
448
476
  * Stops the form from submitting while no time is chosen.
449
477
  */
@@ -506,10 +534,6 @@ export declare class HelixHeadlessTimePicker extends HelixHeadlessTimePicker_bas
506
534
  * The validation message for a time that `disable-times` bars.
507
535
  */
508
536
  unavailableMessage: string;
509
- /**
510
- * The validation message for a required time picker with no time chosen.
511
- */
512
- valueMissingMessage: string;
513
537
  /**
514
538
  * What is wrong with a time the picker can read, as a validity flag and a
515
539
  * message, or nothing.
@@ -520,33 +544,9 @@ export declare class HelixHeadlessTimePicker extends HelixHeadlessTimePicker_bas
520
544
  */
521
545
  private fault;
522
546
  /**
523
- * Shows the times as one `list`, or as `wheels` with a column for each part
524
- * of the time.
525
- *
526
- * `list` is the default and offers whole times, which is what a product with
527
- * opening hours or slots actually has. `wheels` splits them into an hour, a
528
- * minute and, where the locale uses one, a meridiem: three short columns
529
- * instead of ninety-six rows, and the only way to reach `23:45` without
530
- * scrolling most of a day.
531
- *
532
- * The trade is that a wheel cannot say which *combinations* are on offer. A
533
- * list of half hours from nine to five is seventeen rows and every one of them
534
- * is a time the product has; the same thing as columns is an hour column and a
535
- * minute column, and nothing in either says the two are only valid together.
536
- * The bounds are still enforced, so a reader can be refused after the fact,
537
- * which is worse than not being offered it.
538
- *
539
- * So: `list` where the set is the point, `wheels` where any time is allowed
540
- * and the range is a whole day.
541
- *
542
- * **Optional rather than defaulted, which is not a style preference.** A
543
- * reflecting property with a default writes its attribute onto every host the
544
- * moment the element upgrades, including the ones a consumer rendered and did
545
- * not touch, and React reads that as a hydration mismatch. The absent
546
- * attribute *is* the list, which the stylesheet reads as the base rule, so
547
- * only the departure has to be named.
547
+ * The validation message for a required time picker with no time chosen.
548
548
  */
549
- variant?: 'list' | 'wheels';
549
+ valueMissingMessage: string;
550
550
  /**
551
551
  * Reports "required and empty", or clears it.
552
552
  *
@@ -679,7 +679,7 @@ export declare class HelixHeadlessTimePicker extends HelixHeadlessTimePicker_bas
679
679
  private readonly handleColumnsKeydown;
680
680
  private renderSpinner;
681
681
  /**
682
- * The flat list of times, for the variant that is not wheels, behind a seam the styled tier can move.
682
+ * The flat list of times, for the picker that is not wheels, behind a seam the styled tier can move.
683
683
  *
684
684
  * A method rather than a fragment inline, so a tier above can render its own,
685
685
  * wrap this one, pass it a property the base does not know about, or leave it
@@ -21,7 +21,6 @@ let HelixHeadlessTimePicker = class HelixHeadlessTimePicker extends MixinPickerF
21
21
  this.min = '00:00';
22
22
  this.nowLabel = 'Now';
23
23
  this.rangeOverflowMessage = 'Choose a time at or before {max}.';
24
- this.rangeUnderflowMessage = 'Choose a time at or after {min}.';
25
24
  this.handleListInput = (event) => {
26
25
  event.stopPropagation();
27
26
  };
@@ -75,6 +74,7 @@ let HelixHeadlessTimePicker = class HelixHeadlessTimePicker extends MixinPickerF
75
74
  }
76
75
  this.requestValue(this.valueFor(nearest));
77
76
  };
77
+ this.rangeUnderflowMessage = 'Choose a time at or after {min}.';
78
78
  this.readOnly = false;
79
79
  this.required = false;
80
80
  this.seconds = false;
@@ -235,7 +235,7 @@ let HelixHeadlessTimePicker = class HelixHeadlessTimePicker extends MixinPickerF
235
235
  if (this.mode !== undefined) {
236
236
  return;
237
237
  }
238
- if (this.variant !== 'wheels') {
238
+ if (this.picker !== 'wheels') {
239
239
  this.highlightNearest();
240
240
  this.partNamed('list')?.reveal?.();
241
241
  return;
@@ -385,7 +385,7 @@ let HelixHeadlessTimePicker = class HelixHeadlessTimePicker extends MixinPickerF
385
385
  updated(changed) {
386
386
  super.updated(changed);
387
387
  this.reportRequired();
388
- if (this.variant === 'wheels') {
388
+ if (this.picker === 'wheels') {
389
389
  this.reveal();
390
390
  void this.revealWhenSettled();
391
391
  }
@@ -499,7 +499,7 @@ let HelixHeadlessTimePicker = class HelixHeadlessTimePicker extends MixinPickerF
499
499
  </${this.tag('listbox')}>`;
500
500
  }
501
501
  render() {
502
- if (this.variant === 'wheels' && this.mode === undefined) {
502
+ if (this.picker === 'wheels' && this.mode === undefined) {
503
503
  return html `${this.renderSlottedLabel()}${this.renderSpinner()}${this.renderNow()}${this.renderHint()}${this.renderPickerFeedback()}`;
504
504
  }
505
505
  return html `${this.renderSlottedLabel()}${this.renderList()}${this.renderNow()}${this.renderHint()}${this.renderPickerFeedback()}`;
@@ -573,17 +573,20 @@ __decorate([
573
573
  words,
574
574
  property({ attribute: 'now-label' })
575
575
  ], HelixHeadlessTimePicker.prototype, "nowLabel", void 0);
576
+ __decorate([
577
+ property({ reflect: true })
578
+ ], HelixHeadlessTimePicker.prototype, "picker", void 0);
576
579
  __decorate([
577
580
  words,
578
581
  property({ attribute: 'range-overflow-message' })
579
582
  ], HelixHeadlessTimePicker.prototype, "rangeOverflowMessage", void 0);
583
+ __decorate([
584
+ state()
585
+ ], HelixHeadlessTimePicker.prototype, "previewed", void 0);
580
586
  __decorate([
581
587
  words,
582
588
  property({ attribute: 'range-underflow-message' })
583
589
  ], HelixHeadlessTimePicker.prototype, "rangeUnderflowMessage", void 0);
584
- __decorate([
585
- state()
586
- ], HelixHeadlessTimePicker.prototype, "previewed", void 0);
587
590
  __decorate([
588
591
  property({ attribute: 'readonly', reflect: true, type: Boolean })
589
592
  ], HelixHeadlessTimePicker.prototype, "readOnly", void 0);
@@ -617,9 +620,6 @@ __decorate([
617
620
  words,
618
621
  property({ attribute: 'value-missing-message' })
619
622
  ], HelixHeadlessTimePicker.prototype, "valueMissingMessage", void 0);
620
- __decorate([
621
- property({ reflect: true })
622
- ], HelixHeadlessTimePicker.prototype, "variant", void 0);
623
623
  __decorate([
624
624
  state()
625
625
  ], HelixHeadlessTimePicker.prototype, "hintSlotted", void 0);