@dloizides/ui-forms 1.34.1 → 1.36.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/CHANGELOG.md CHANGED
@@ -3,6 +3,7 @@
3
3
  ## [Unreleased]
4
4
 
5
5
  ### Added
6
+ - `ChipOption.labelWrap` (`ChipLabelWrap.None | Wrap | Truncate`, a `const enum`, default `None` = unchanged): `wrap` and `truncate` cap a chip at its container width so a long label never runs past its card at 360 px; the internal `chipLabelLayout` helper is no longer exported (D-LD-7 in LIST-DEFAULTS-1 "Operator-set default watchlists", TEXT-FIT-1).
6
7
  - `SearchSelect`: type to filter by name and detail, Recent then All, arrow keys + Enter + Esc, phone sheet / computer unfold, reduced motion = no slide (FINREG-INPUTS-1 "Searchable dropdowns, shared country field, formatted IBAN/BIC inputs").
7
8
  - `CountryField` + `COUNTRIES` (ISO 3166-1 alpha-2, 249): drawn SVG flag (`CountryFlag`, needs peer `react-native-svg >=13.0.0`), name, grey code; stores the code only.
8
9
  - `SearchSelect`: `renderDetail` slot, typing highlights the first match, web outside press closes the dropdown; `IbanInput` keeps the caret through regrouping.
package/dist/index.d.mts CHANGED
@@ -580,6 +580,13 @@ declare function useRecentValues(key: string, max?: number): RecentValues;
580
580
  /** Default cap on remembered values (most-recent-first). */
581
581
  declare const DEFAULT_MAX_RECENTS = 10;
582
582
 
583
+ /** How a long chip label fits: `None` (default) grows the chip, `Wrap` and `Truncate` cap it at its container. */
584
+ declare const enum ChipLabelWrap {
585
+ None = "none",
586
+ Wrap = "wrap",
587
+ Truncate = "truncate"
588
+ }
589
+
583
590
  /**
584
591
  * Public + internal types for ChipSelector. Split out of `ChipSelector.tsx` so the component, its
585
592
  * two chip variants and the radio keyboard hook can share them without a circular import.
@@ -599,6 +606,8 @@ interface ChipOption<T> {
599
606
  label: string;
600
607
  /** Optional decorative icon rendered before the label; hidden from assistive tech. */
601
608
  icon?: React.ReactNode;
609
+ /** Long-label behaviour for this chip; defaults to `none`. */
610
+ labelWrap?: ChipLabelWrap;
602
611
  }
603
612
  interface ChipSelectorProps<T> {
604
613
  /** Optional — with no label, no label row is rendered (no phantom gap above the chips). */
@@ -1557,4 +1566,4 @@ declare function useBlurVerdict<T>(validate: () => T): BlurVerdict<T>;
1557
1566
  /** The pre-localized message for a refusal, or null when there is no verdict, it passed, or no labels were given. */
1558
1567
  declare function rejectionMessage<R extends string, N extends R>(rejection: R | null, none: N, labels: Readonly<Record<Exclude<R, N>, string>> | undefined): string | null;
1559
1568
 
1560
- export { AddOnRequest, type AddOnRequestProps, AlignToControl, type AlignToControlProps, type AnchorRect, AnchoredMenu, type AnchoredMenuColors, type AnchoredMenuListbox, type AnchoredMenuPlacement, type AnchoredMenuProps, type BicDraft, BicInput, type BicInputProps, BicRejection, type BicRejectionLabels, type BicVerdict, type BlurVerdict, COUNTRIES, type ChipOption, ChipSelector, type ChipSelectorProps, type ChipSingleSelectRole, type ChipVariant, type ControlOption, type Country, CountryField, type CountryFieldProps, CountryFlag, type CountryFlagProps, DEFAULT_MAX_RECENTS, DEFAULT_OPTIONAL_LABEL, DEFAULT_TYPEAHEAD_MAX_SUGGESTIONS, DEFAULT_TYPEAHEAD_MIN_CHARS, DateField, type DateFieldProps, DateInput, type DateInputProps, DateRangeControl, type DateRangeControlProps, type DateRangeValue, DateTimeField, type DateTimeFieldProps, type DropdownFrame, DropdownPlacement, FLAG_HEIGHT, FLAG_WIDTH, Field, type FieldChildContext, type FieldChildren, type FieldLabelVariant, type FieldMarker, type FieldProps, type FieldSpacing, FixBar, type FixBarProps, type FlagShape, FlagShapeKind, type Focusable, type FocusableRefs, FormActions, type FormActionsProps, FormCell, type FormCellProps, FormCheckbox, type FormCheckboxProps, FormField, type FormFieldProps, FormGrid, type FormGridProps, FormSection, type FormSectionProps, FormStack, type FormStackProps, FormStatusLine, type FormStatusLineProps, FormSwitch, type FormSwitchProps, type GroupSelection, IBAN_MAX_LENGTH, IBAN_REGISTERED_COUNTRY_COUNT, INLINE_FIELD_ROW_MIN_WIDTH, type IbanDraft, IbanInput, type IbanInputProps, IbanRejection, type IbanRejectionLabels, type IbanVerdict, InlineFieldRow, type InlineFieldRowLayout, type InlineFieldRowProps, PHONE_MAX_WIDTH, RESPONSIVE_FORM_DEFAULT_BREAKPOINT, type RecentValues, ResponsiveFormLayout, type ResponsiveFormLayoutProps, SearchSelect, type SearchSelectLabels, type SearchSelectProps, type SearchSelectSections, type SearchSelectState, SelectControl, type SelectControlProps, SelectField, type SelectFieldProps, type SelectMenuAnchor, type SelectMotion, SelectSurface, type StepNeighbours, StepperNav, type StepperNavLabels, type StepperNavProps, type StepperStep, StepperTabs, type StepperTabsProps, type ThemedInput, ThemedTextInput, type ThemedTextInputProps, TypeaheadControl, type TypeaheadControlProps, type TypeaheadSearch, type TypeaheadSearchProps, UploadWithLinkField, type UploadWithLinkFieldProps, type UploadWithLinkLabels, type UseThemedInputOptions, buildSearchSelectSections, controlStyles, countryFlag, countryOptions, draftBic, draftIban, dropdownFrame, findOption, flagShapes, groupAriaChecked, groupInFours, highlightAfterQuery, ibanCounter, ibanLengthFor, inlineFieldRowLayout, isAddOnOpen, isFallbackFlag, isFixBarVisible, isOutside, isUnmatched, isWideFormLayout, moveHighlight, nextHighlight, placeDropdown, rejectionMessage, resolveGroupSelection, resolveSelectMotion, resolveStepNeighbours, suggestOptions, toCountryValue, toggleGroupSelection, useBlurVerdict, useDeferredFocus, useFocusFirstInvalid, useKeepInView, useOutsidePress, useRecentValues, useReducedMotion, useSearchSelectState, useThemedInput, validateBic, validateIban };
1569
+ export { AddOnRequest, type AddOnRequestProps, AlignToControl, type AlignToControlProps, type AnchorRect, AnchoredMenu, type AnchoredMenuColors, type AnchoredMenuListbox, type AnchoredMenuPlacement, type AnchoredMenuProps, type BicDraft, BicInput, type BicInputProps, BicRejection, type BicRejectionLabels, type BicVerdict, type BlurVerdict, COUNTRIES, ChipLabelWrap, type ChipOption, ChipSelector, type ChipSelectorProps, type ChipSingleSelectRole, type ChipVariant, type ControlOption, type Country, CountryField, type CountryFieldProps, CountryFlag, type CountryFlagProps, DEFAULT_MAX_RECENTS, DEFAULT_OPTIONAL_LABEL, DEFAULT_TYPEAHEAD_MAX_SUGGESTIONS, DEFAULT_TYPEAHEAD_MIN_CHARS, DateField, type DateFieldProps, DateInput, type DateInputProps, DateRangeControl, type DateRangeControlProps, type DateRangeValue, DateTimeField, type DateTimeFieldProps, type DropdownFrame, DropdownPlacement, FLAG_HEIGHT, FLAG_WIDTH, Field, type FieldChildContext, type FieldChildren, type FieldLabelVariant, type FieldMarker, type FieldProps, type FieldSpacing, FixBar, type FixBarProps, type FlagShape, FlagShapeKind, type Focusable, type FocusableRefs, FormActions, type FormActionsProps, FormCell, type FormCellProps, FormCheckbox, type FormCheckboxProps, FormField, type FormFieldProps, FormGrid, type FormGridProps, FormSection, type FormSectionProps, FormStack, type FormStackProps, FormStatusLine, type FormStatusLineProps, FormSwitch, type FormSwitchProps, type GroupSelection, IBAN_MAX_LENGTH, IBAN_REGISTERED_COUNTRY_COUNT, INLINE_FIELD_ROW_MIN_WIDTH, type IbanDraft, IbanInput, type IbanInputProps, IbanRejection, type IbanRejectionLabels, type IbanVerdict, InlineFieldRow, type InlineFieldRowLayout, type InlineFieldRowProps, PHONE_MAX_WIDTH, RESPONSIVE_FORM_DEFAULT_BREAKPOINT, type RecentValues, ResponsiveFormLayout, type ResponsiveFormLayoutProps, SearchSelect, type SearchSelectLabels, type SearchSelectProps, type SearchSelectSections, type SearchSelectState, SelectControl, type SelectControlProps, SelectField, type SelectFieldProps, type SelectMenuAnchor, type SelectMotion, SelectSurface, type StepNeighbours, StepperNav, type StepperNavLabels, type StepperNavProps, type StepperStep, StepperTabs, type StepperTabsProps, type ThemedInput, ThemedTextInput, type ThemedTextInputProps, TypeaheadControl, type TypeaheadControlProps, type TypeaheadSearch, type TypeaheadSearchProps, UploadWithLinkField, type UploadWithLinkFieldProps, type UploadWithLinkLabels, type UseThemedInputOptions, buildSearchSelectSections, controlStyles, countryFlag, countryOptions, draftBic, draftIban, dropdownFrame, findOption, flagShapes, groupAriaChecked, groupInFours, highlightAfterQuery, ibanCounter, ibanLengthFor, inlineFieldRowLayout, isAddOnOpen, isFallbackFlag, isFixBarVisible, isOutside, isUnmatched, isWideFormLayout, moveHighlight, nextHighlight, placeDropdown, rejectionMessage, resolveGroupSelection, resolveSelectMotion, resolveStepNeighbours, suggestOptions, toCountryValue, toggleGroupSelection, useBlurVerdict, useDeferredFocus, useFocusFirstInvalid, useKeepInView, useOutsidePress, useRecentValues, useReducedMotion, useSearchSelectState, useThemedInput, validateBic, validateIban };
package/dist/index.d.ts CHANGED
@@ -580,6 +580,13 @@ declare function useRecentValues(key: string, max?: number): RecentValues;
580
580
  /** Default cap on remembered values (most-recent-first). */
581
581
  declare const DEFAULT_MAX_RECENTS = 10;
582
582
 
583
+ /** How a long chip label fits: `None` (default) grows the chip, `Wrap` and `Truncate` cap it at its container. */
584
+ declare const enum ChipLabelWrap {
585
+ None = "none",
586
+ Wrap = "wrap",
587
+ Truncate = "truncate"
588
+ }
589
+
583
590
  /**
584
591
  * Public + internal types for ChipSelector. Split out of `ChipSelector.tsx` so the component, its
585
592
  * two chip variants and the radio keyboard hook can share them without a circular import.
@@ -599,6 +606,8 @@ interface ChipOption<T> {
599
606
  label: string;
600
607
  /** Optional decorative icon rendered before the label; hidden from assistive tech. */
601
608
  icon?: React.ReactNode;
609
+ /** Long-label behaviour for this chip; defaults to `none`. */
610
+ labelWrap?: ChipLabelWrap;
602
611
  }
603
612
  interface ChipSelectorProps<T> {
604
613
  /** Optional — with no label, no label row is rendered (no phantom gap above the chips). */
@@ -1557,4 +1566,4 @@ declare function useBlurVerdict<T>(validate: () => T): BlurVerdict<T>;
1557
1566
  /** The pre-localized message for a refusal, or null when there is no verdict, it passed, or no labels were given. */
1558
1567
  declare function rejectionMessage<R extends string, N extends R>(rejection: R | null, none: N, labels: Readonly<Record<Exclude<R, N>, string>> | undefined): string | null;
1559
1568
 
1560
- export { AddOnRequest, type AddOnRequestProps, AlignToControl, type AlignToControlProps, type AnchorRect, AnchoredMenu, type AnchoredMenuColors, type AnchoredMenuListbox, type AnchoredMenuPlacement, type AnchoredMenuProps, type BicDraft, BicInput, type BicInputProps, BicRejection, type BicRejectionLabels, type BicVerdict, type BlurVerdict, COUNTRIES, type ChipOption, ChipSelector, type ChipSelectorProps, type ChipSingleSelectRole, type ChipVariant, type ControlOption, type Country, CountryField, type CountryFieldProps, CountryFlag, type CountryFlagProps, DEFAULT_MAX_RECENTS, DEFAULT_OPTIONAL_LABEL, DEFAULT_TYPEAHEAD_MAX_SUGGESTIONS, DEFAULT_TYPEAHEAD_MIN_CHARS, DateField, type DateFieldProps, DateInput, type DateInputProps, DateRangeControl, type DateRangeControlProps, type DateRangeValue, DateTimeField, type DateTimeFieldProps, type DropdownFrame, DropdownPlacement, FLAG_HEIGHT, FLAG_WIDTH, Field, type FieldChildContext, type FieldChildren, type FieldLabelVariant, type FieldMarker, type FieldProps, type FieldSpacing, FixBar, type FixBarProps, type FlagShape, FlagShapeKind, type Focusable, type FocusableRefs, FormActions, type FormActionsProps, FormCell, type FormCellProps, FormCheckbox, type FormCheckboxProps, FormField, type FormFieldProps, FormGrid, type FormGridProps, FormSection, type FormSectionProps, FormStack, type FormStackProps, FormStatusLine, type FormStatusLineProps, FormSwitch, type FormSwitchProps, type GroupSelection, IBAN_MAX_LENGTH, IBAN_REGISTERED_COUNTRY_COUNT, INLINE_FIELD_ROW_MIN_WIDTH, type IbanDraft, IbanInput, type IbanInputProps, IbanRejection, type IbanRejectionLabels, type IbanVerdict, InlineFieldRow, type InlineFieldRowLayout, type InlineFieldRowProps, PHONE_MAX_WIDTH, RESPONSIVE_FORM_DEFAULT_BREAKPOINT, type RecentValues, ResponsiveFormLayout, type ResponsiveFormLayoutProps, SearchSelect, type SearchSelectLabels, type SearchSelectProps, type SearchSelectSections, type SearchSelectState, SelectControl, type SelectControlProps, SelectField, type SelectFieldProps, type SelectMenuAnchor, type SelectMotion, SelectSurface, type StepNeighbours, StepperNav, type StepperNavLabels, type StepperNavProps, type StepperStep, StepperTabs, type StepperTabsProps, type ThemedInput, ThemedTextInput, type ThemedTextInputProps, TypeaheadControl, type TypeaheadControlProps, type TypeaheadSearch, type TypeaheadSearchProps, UploadWithLinkField, type UploadWithLinkFieldProps, type UploadWithLinkLabels, type UseThemedInputOptions, buildSearchSelectSections, controlStyles, countryFlag, countryOptions, draftBic, draftIban, dropdownFrame, findOption, flagShapes, groupAriaChecked, groupInFours, highlightAfterQuery, ibanCounter, ibanLengthFor, inlineFieldRowLayout, isAddOnOpen, isFallbackFlag, isFixBarVisible, isOutside, isUnmatched, isWideFormLayout, moveHighlight, nextHighlight, placeDropdown, rejectionMessage, resolveGroupSelection, resolveSelectMotion, resolveStepNeighbours, suggestOptions, toCountryValue, toggleGroupSelection, useBlurVerdict, useDeferredFocus, useFocusFirstInvalid, useKeepInView, useOutsidePress, useRecentValues, useReducedMotion, useSearchSelectState, useThemedInput, validateBic, validateIban };
1569
+ export { AddOnRequest, type AddOnRequestProps, AlignToControl, type AlignToControlProps, type AnchorRect, AnchoredMenu, type AnchoredMenuColors, type AnchoredMenuListbox, type AnchoredMenuPlacement, type AnchoredMenuProps, type BicDraft, BicInput, type BicInputProps, BicRejection, type BicRejectionLabels, type BicVerdict, type BlurVerdict, COUNTRIES, ChipLabelWrap, type ChipOption, ChipSelector, type ChipSelectorProps, type ChipSingleSelectRole, type ChipVariant, type ControlOption, type Country, CountryField, type CountryFieldProps, CountryFlag, type CountryFlagProps, DEFAULT_MAX_RECENTS, DEFAULT_OPTIONAL_LABEL, DEFAULT_TYPEAHEAD_MAX_SUGGESTIONS, DEFAULT_TYPEAHEAD_MIN_CHARS, DateField, type DateFieldProps, DateInput, type DateInputProps, DateRangeControl, type DateRangeControlProps, type DateRangeValue, DateTimeField, type DateTimeFieldProps, type DropdownFrame, DropdownPlacement, FLAG_HEIGHT, FLAG_WIDTH, Field, type FieldChildContext, type FieldChildren, type FieldLabelVariant, type FieldMarker, type FieldProps, type FieldSpacing, FixBar, type FixBarProps, type FlagShape, FlagShapeKind, type Focusable, type FocusableRefs, FormActions, type FormActionsProps, FormCell, type FormCellProps, FormCheckbox, type FormCheckboxProps, FormField, type FormFieldProps, FormGrid, type FormGridProps, FormSection, type FormSectionProps, FormStack, type FormStackProps, FormStatusLine, type FormStatusLineProps, FormSwitch, type FormSwitchProps, type GroupSelection, IBAN_MAX_LENGTH, IBAN_REGISTERED_COUNTRY_COUNT, INLINE_FIELD_ROW_MIN_WIDTH, type IbanDraft, IbanInput, type IbanInputProps, IbanRejection, type IbanRejectionLabels, type IbanVerdict, InlineFieldRow, type InlineFieldRowLayout, type InlineFieldRowProps, PHONE_MAX_WIDTH, RESPONSIVE_FORM_DEFAULT_BREAKPOINT, type RecentValues, ResponsiveFormLayout, type ResponsiveFormLayoutProps, SearchSelect, type SearchSelectLabels, type SearchSelectProps, type SearchSelectSections, type SearchSelectState, SelectControl, type SelectControlProps, SelectField, type SelectFieldProps, type SelectMenuAnchor, type SelectMotion, SelectSurface, type StepNeighbours, StepperNav, type StepperNavLabels, type StepperNavProps, type StepperStep, StepperTabs, type StepperTabsProps, type ThemedInput, ThemedTextInput, type ThemedTextInputProps, TypeaheadControl, type TypeaheadControlProps, type TypeaheadSearch, type TypeaheadSearchProps, UploadWithLinkField, type UploadWithLinkFieldProps, type UploadWithLinkLabels, type UseThemedInputOptions, buildSearchSelectSections, controlStyles, countryFlag, countryOptions, draftBic, draftIban, dropdownFrame, findOption, flagShapes, groupAriaChecked, groupInFours, highlightAfterQuery, ibanCounter, ibanLengthFor, inlineFieldRowLayout, isAddOnOpen, isFallbackFlag, isFixBarVisible, isOutside, isUnmatched, isWideFormLayout, moveHighlight, nextHighlight, placeDropdown, rejectionMessage, resolveGroupSelection, resolveSelectMotion, resolveStepNeighbours, suggestOptions, toCountryValue, toggleGroupSelection, useBlurVerdict, useDeferredFocus, useFocusFirstInvalid, useKeepInView, useOutsidePress, useRecentValues, useReducedMotion, useSearchSelectState, useThemedInput, validateBic, validateIban };
package/dist/index.js CHANGED
@@ -1202,6 +1202,26 @@ var TRANSPARENT_COLOR = "transparent";
1202
1202
  var CHIP_HIT_SLOP = { top: 10, bottom: 10, left: 4, right: 4 };
1203
1203
  var CHIP_GUTTER = 8;
1204
1204
  var DEFAULT_CHIP_TESTID_PREFIX = "chip-selector-chip";
1205
+
1206
+ // src/ChipSelector/ChipLabelWrap.ts
1207
+ var ChipLabelWrap = /* @__PURE__ */ ((ChipLabelWrap2) => {
1208
+ ChipLabelWrap2["None"] = "none";
1209
+ ChipLabelWrap2["Wrap"] = "wrap";
1210
+ ChipLabelWrap2["Truncate"] = "truncate";
1211
+ return ChipLabelWrap2;
1212
+ })(ChipLabelWrap || {});
1213
+
1214
+ // src/ChipSelector/utils/chipLabelLayout.ts
1215
+ var CAPPED_BOX = { maxWidth: "100%", flexShrink: 1 };
1216
+ var SHRINKING_TEXT = { flexShrink: 1 };
1217
+ var SINGLE_LINE = 1;
1218
+ function chipLabelLayout(labelWrap) {
1219
+ if (labelWrap === "wrap" /* Wrap */)
1220
+ return { boxStyle: CAPPED_BOX, textStyle: SHRINKING_TEXT, numberOfLines: void 0 };
1221
+ if (labelWrap === "truncate" /* Truncate */)
1222
+ return { boxStyle: CAPPED_BOX, textStyle: SHRINKING_TEXT, numberOfLines: SINGLE_LINE };
1223
+ return { boxStyle: void 0, textStyle: void 0, numberOfLines: void 0 };
1224
+ }
1205
1225
  var SOLID_RADIUS = 20;
1206
1226
  var OUTLINE_RADIUS = 999;
1207
1227
  var OUTLINE_PAD_H = 12;
@@ -1233,8 +1253,8 @@ var chipStyles = reactNative.StyleSheet.create({
1233
1253
  chipText: {},
1234
1254
  chipTextOutline: { fontSize: OUTLINE_FONT_SIZE }
1235
1255
  });
1236
- function ChipContent({ icon, label, textStyle }) {
1237
- const text = /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: textStyle, children: label });
1256
+ function ChipContent({ icon, label, textStyle, numberOfLines }) {
1257
+ const text = /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { numberOfLines, style: textStyle, children: label });
1238
1258
  if (icon === void 0 || icon === null)
1239
1259
  return text;
1240
1260
  return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: chipStyles.chipContent, children: [
@@ -1249,6 +1269,7 @@ function OutlineChip(props) {
1249
1269
  const borderColor = active ? colors.primary : colors.border;
1250
1270
  const backgroundColor = selected ? colors.tint : colors.muted;
1251
1271
  const textColor = active ? colors.primary : colors.textMuted;
1272
+ const layout = chipLabelLayout(option.labelWrap);
1252
1273
  return /* @__PURE__ */ jsxRuntime.jsx(
1253
1274
  reactNative.Pressable,
1254
1275
  {
@@ -1261,17 +1282,19 @@ function OutlineChip(props) {
1261
1282
  "aria-pressed": props.ariaPressed,
1262
1283
  disabled,
1263
1284
  hitSlop: CHIP_HIT_SLOP,
1285
+ style: layout.boxStyle,
1264
1286
  tabIndex: props.tabIndex,
1265
1287
  testID,
1266
1288
  onHoverIn: () => setHovered(true),
1267
1289
  onHoverOut: () => setHovered(false),
1268
1290
  onPress,
1269
- children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [chipStyles.chipOutline, { borderColor, backgroundColor }], children: /* @__PURE__ */ jsxRuntime.jsx(
1291
+ children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [chipStyles.chipOutline, { borderColor, backgroundColor }, layout.boxStyle], children: /* @__PURE__ */ jsxRuntime.jsx(
1270
1292
  ChipContent,
1271
1293
  {
1272
1294
  icon: option.icon,
1273
1295
  label: option.label,
1274
- textStyle: [chipStyles.chipText, chipStyles.chipTextOutline, { color: textColor }]
1296
+ numberOfLines: layout.numberOfLines,
1297
+ textStyle: [chipStyles.chipText, chipStyles.chipTextOutline, { color: textColor }, layout.textStyle]
1275
1298
  }
1276
1299
  ) })
1277
1300
  }
@@ -1281,6 +1304,7 @@ function SolidChip(props) {
1281
1304
  const { option, selected, disabled, colors, testID, accessibilityHint, onPress } = props;
1282
1305
  const backgroundColor = selected ? colors.primary : TRANSPARENT_COLOR;
1283
1306
  const textColor = selected ? colors.onPrimary : colors.textStrong;
1307
+ const layout = chipLabelLayout(option.labelWrap);
1284
1308
  const rovingTabStop = { tabIndex: props.tabIndex };
1285
1309
  return /* @__PURE__ */ jsxRuntime.jsx(
1286
1310
  reactNative.TouchableOpacity,
@@ -1294,10 +1318,19 @@ function SolidChip(props) {
1294
1318
  "aria-pressed": props.ariaPressed,
1295
1319
  disabled,
1296
1320
  hitSlop: CHIP_HIT_SLOP,
1321
+ style: layout.boxStyle,
1297
1322
  testID,
1298
1323
  onPress,
1299
1324
  ...rovingTabStop,
1300
- children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [chipStyles.chip, { borderColor: colors.border, backgroundColor }], children: /* @__PURE__ */ jsxRuntime.jsx(ChipContent, { icon: option.icon, label: option.label, textStyle: [chipStyles.chipText, { color: textColor }] }) })
1325
+ children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [chipStyles.chip, { borderColor: colors.border, backgroundColor }, layout.boxStyle], children: /* @__PURE__ */ jsxRuntime.jsx(
1326
+ ChipContent,
1327
+ {
1328
+ icon: option.icon,
1329
+ label: option.label,
1330
+ numberOfLines: layout.numberOfLines,
1331
+ textStyle: [chipStyles.chipText, { color: textColor }, layout.textStyle]
1332
+ }
1333
+ ) })
1301
1334
  }
1302
1335
  );
1303
1336
  }
@@ -4060,6 +4093,7 @@ exports.AnchoredMenu = AnchoredMenu;
4060
4093
  exports.BicInput = BicInput;
4061
4094
  exports.BicRejection = BicRejection;
4062
4095
  exports.COUNTRIES = COUNTRIES;
4096
+ exports.ChipLabelWrap = ChipLabelWrap;
4063
4097
  exports.ChipSelector = ChipSelector;
4064
4098
  exports.CountryField = CountryField;
4065
4099
  exports.CountryFlag = CountryFlag;