@lumx/react 4.17.0 → 4.18.0-next.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/index.d.ts CHANGED
@@ -2529,6 +2529,7 @@ interface DropdownProps extends GenericProps$1 {
2529
2529
  /**
2530
2530
  * Dropdown component.
2531
2531
  *
2532
+ * @deprecated Use `MenuButton` for action-based dropdowns, `SelectButton` for selection-based dropdowns, or `Popover` for lower-level control.
2532
2533
  * @param props Component props.
2533
2534
  * @param ref Component ref.
2534
2535
  * @return React element.
@@ -4336,11 +4337,8 @@ interface SelectButtonProps$1<O> extends BaseSelectProps<O> {
4336
4337
  * The wrapper layer chooses the shape; the core just renders names.
4337
4338
  */
4338
4339
  value?: O | O[];
4339
- /**
4340
- * When `true`, sets `aria-multiselectable="true"` on the listbox so
4341
- * the dropdown stays open after each selection (combobox setup detects this attribute).
4342
- */
4343
- isMultiselectable?: boolean;
4340
+ /** Single or multiple selection */
4341
+ selectionType?: 'single' | 'multiple';
4344
4342
  /** Button label (used for ARIA and when no selection). */
4345
4343
  label: string;
4346
4344
  /** Controls how the label/value is displayed in the button. */
@@ -4388,7 +4386,7 @@ declare const DefaultButton: Comp<ButtonProps, HTMLButtonElement>;
4388
4386
  /** Keys managed internally — never forwarded to the trigger element. */
4389
4387
  type OmittedKeys = 'value' | 'children' | 'role' | 'aria-controls' | 'aria-haspopup' | 'aria-expanded' | 'aria-activedescendant' | 'ref';
4390
4388
  /** Select-specific props common to both single and multi modes. */
4391
- type SelectButtonSelectProps<O> = Omit<ReactToJSX<SelectButtonProps$1<O>>, 'renderOption' | 'buttonProps' | 'value' | 'isMultiselectable'> & {
4389
+ interface SelectButtonSelectProps<O> extends ReactToJSX<SelectButtonProps$1<O>, 'renderOption' | 'buttonProps' | 'value' | 'handleSelect' | 'listProps' | 'infiniteScrollOptions'> {
4392
4390
  /** Called to load more options (infinite scroll). */
4393
4391
  onLoadMore?: () => void;
4394
4392
  /** Called when the dropdown opens or closes. */
@@ -4398,7 +4396,7 @@ type SelectButtonSelectProps<O> = Omit<ReactToJSX<SelectButtonProps$1<O>>, 'rend
4398
4396
  * Props `value`, `isSelected`, `description` and `key` are merged in automatically.
4399
4397
  */
4400
4398
  renderOption?: (option: O, index: number) => React__default.ReactNode;
4401
- };
4399
+ }
4402
4400
  /**
4403
4401
  * Forwarded trigger props for a given element `E`, minus the keys that the
4404
4402
  * component manages internally.
@@ -4546,6 +4544,11 @@ interface MultipleSelectTextFieldProps<O = any> extends BaseSelectTextFieldProps
4546
4544
  }
4547
4545
  /**
4548
4546
  * SelectTextField props — supports both single and multiple selection.
4547
+ * Discriminated on `selectionType`:
4548
+ * - `'single'` → `value?: O`, `onChange?: (newValue?: O) => void`.
4549
+ * - `'multiple'` → `value?: O[]`, `onChange?: (newValue?: O[]) => void`, `renderChip`, `getChipProps`.
4550
+ *
4551
+ * @typeParam O - Option object type, inferred from `options` / `getOptionId`.
4549
4552
  */
4550
4553
  type SelectTextFieldProps<O = any> = SingleSelectTextFieldProps<O> | MultipleSelectTextFieldProps<O>;
4551
4554
 
@@ -5435,7 +5438,16 @@ interface TimePickerFieldWrapperProps {
5435
5438
  */
5436
5439
  maxTime?: Date;
5437
5440
  /**
5438
- * Translations label for clear and show suggestions buttons.
5441
+ * Controls how the time value interacts with `[minTime, maxTime]` bounds.
5442
+ * Typed input is always snapped to bounds on blur.
5443
+ * - `'enforce'`: additionally, the controlled `value` prop is proactively
5444
+ * clamped to bounds on mount and whenever bounds change, calling
5445
+ * `onChange` when adjusted.
5446
+ * - `'on-blur'` (default): only blur snapping applies.
5447
+ */
5448
+ boundsMode?: 'on-blur' | 'enforce';
5449
+ /**
5450
+ * Translation labels for clear and show suggestions buttons.
5439
5451
  */
5440
5452
  translations: TimePickerFieldTranslations;
5441
5453
  }