@dxc-technology/halstack-react 6.1.0 → 6.2.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.
Files changed (41) hide show
  1. package/accordion/Accordion.js +122 -103
  2. package/accordion/Accordion.stories.tsx +1 -2
  3. package/accordion/Accordion.test.js +9 -10
  4. package/accordion/types.d.ts +3 -3
  5. package/accordion-group/AccordionGroup.js +1 -21
  6. package/accordion-group/AccordionGroup.stories.tsx +27 -1
  7. package/accordion-group/AccordionGroup.test.js +20 -45
  8. package/accordion-group/types.d.ts +8 -2
  9. package/alert/Alert.js +1 -1
  10. package/box/Box.js +1 -1
  11. package/checkbox/Checkbox.js +88 -95
  12. package/checkbox/Checkbox.test.js +93 -16
  13. package/checkbox/types.d.ts +2 -2
  14. package/common/variables.js +8 -4
  15. package/dropdown/Dropdown.js +1 -1
  16. package/footer/Footer.stories.tsx +8 -1
  17. package/header/Header.stories.tsx +4 -4
  18. package/layout/ApplicationLayout.stories.tsx +1 -0
  19. package/package.json +8 -8
  20. package/select/Listbox.js +0 -1
  21. package/slider/Slider.js +112 -91
  22. package/slider/Slider.stories.tsx +7 -1
  23. package/slider/Slider.test.js +87 -24
  24. package/slider/types.d.ts +2 -2
  25. package/switch/Switch.js +1 -1
  26. package/tabs/Tab.d.ts +4 -0
  27. package/tabs/Tab.js +135 -0
  28. package/tabs/Tabs.js +360 -104
  29. package/tabs/Tabs.stories.tsx +74 -0
  30. package/tabs/Tabs.test.js +217 -6
  31. package/tabs/types.d.ts +14 -4
  32. package/tag/Tag.js +1 -1
  33. package/text-input/Icons.d.ts +8 -0
  34. package/text-input/Icons.js +60 -0
  35. package/text-input/Suggestion.js +7 -5
  36. package/text-input/Suggestions.d.ts +4 -0
  37. package/text-input/Suggestions.js +134 -0
  38. package/text-input/TextInput.js +103 -201
  39. package/text-input/TextInput.stories.tsx +189 -181
  40. package/text-input/TextInput.test.js +163 -162
  41. package/text-input/types.d.ts +16 -2
@@ -159,17 +159,31 @@ declare type Props = {
159
159
  */
160
160
  tabIndex?: number;
161
161
  };
162
+ /**
163
+ * List of suggestions of an Text Input component.
164
+ */
165
+ export declare type SuggestionsProps = {
166
+ id: string;
167
+ value: string;
168
+ suggestions: string[];
169
+ visualFocusIndex: number;
170
+ highlightedSuggestions: boolean;
171
+ searchHasErrors: boolean;
172
+ isSearching: boolean;
173
+ suggestionOnClick: (suggestion: string) => void;
174
+ getTextInputWidth: () => number;
175
+ };
162
176
  /**
163
177
  * Reference to the component.
164
178
  */
165
179
  export declare type RefType = HTMLDivElement;
166
180
  /**
167
- * Single suggestion of the Autosuggest Text Input component.
181
+ * Single suggestion of an Text Input component.
168
182
  */
169
183
  export declare type SuggestionProps = {
170
184
  id: string;
171
185
  value: string;
172
- onClick: () => void;
186
+ onClick: (suggestion: string) => void;
173
187
  suggestion: string;
174
188
  isLast: boolean;
175
189
  visuallyFocused: boolean;