@worldresources/wri-design-systems 2.161.0 → 2.162.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/dist/index.d.ts CHANGED
@@ -567,7 +567,7 @@ type ItemCountProps = {
567
567
 
568
568
  declare const ItemCount: ({ pageSize, currentPage, totalItems, onPageSizeChange, showItemCountText, }: ItemCountProps) => _emotion_react_jsx_runtime.JSX.Element;
569
569
 
570
- type ListItemVariant = 'data' | 'navigation';
570
+ type ListItemVariant = 'data' | 'navigation' | 'select';
571
571
  interface ListItemProps {
572
572
  id?: string;
573
573
  label: string;
@@ -811,6 +811,27 @@ type TabBarProps = {
811
811
 
812
812
  declare const TabBar: ({ variant, defaultValue, tabs, onTabClick, activationMode, }: TabBarProps) => _emotion_react_jsx_runtime.JSX.Element;
813
813
 
814
+ type SearchProps = Omit<InputProps, 'variant' | 'colorPalette' | 'defaultChecked'> & {
815
+ placeholder?: string;
816
+ disabled?: boolean;
817
+ size?: 'small' | 'default';
818
+ options: ListItemProps[];
819
+ resultsMaxHeight?: string;
820
+ isLoading?: boolean;
821
+ displayResults?: 'none' | 'text' | 'list' | 'custom';
822
+ onSelect?: (selectedOption: ListItemProps) => void;
823
+ onQueryChange?: (query: string) => void;
824
+ onClear?: () => void;
825
+ renderResults?: (params: {
826
+ items: any[];
827
+ highlightedIndex: number;
828
+ query: string;
829
+ onSelect: (id: string) => void;
830
+ }) => React.ReactNode;
831
+ };
832
+
833
+ declare const Search: ({ placeholder, disabled, size, options, resultsMaxHeight, isLoading, displayResults, onSelect, onQueryChange, onClear, renderResults, }: SearchProps) => _emotion_react_jsx_runtime.JSX.Element;
834
+
814
835
  type AvatarProps = {
815
836
  name: string;
816
837
  ariaLabel?: string;
@@ -884,4 +905,4 @@ type ToastProps = {
884
905
 
885
906
  declare const showToast: (props: ToastProps) => void;
886
907
 
887
- export { AnalysisWidget, Avatar, Badge, BaseMap, Breadcrumb, Button, Checkbox, CheckboxList, CheckboxOptionCard, CloseButton, ClusterPoint, ExtendableCard, Footer, IconButton, InlineMessage, InputWithUnits, ItemCount, LayerGroup, LayerGroupContainer, LayerItem, LayerParameters, LegendItem, List, MapControlsToolbar, MapMarker, MapMarkers, MapPopUp, Menu, MobileTabBar, Modal, MultiActionButton, Navbar, NavigationRail, OptionCard, Pagination, Panel, Password, ProgressBar, QualitativeAttribute, Radio, RadioGroup, RadioList, SSOButtons, ScaleBar, Select, Sheet, SimpleMapPin, Slider, SliderInput, StepProgressIndicator, Switch, TabBar, Table, TableCell, TableRow, Tag, TextInput, Textarea, Toast, Toolbar, Tooltip, designSystemStyles, designSystemStylesForTailwind, getThemedColor, showToast };
908
+ export { AnalysisWidget, Avatar, Badge, BaseMap, Breadcrumb, Button, Checkbox, CheckboxList, CheckboxOptionCard, CloseButton, ClusterPoint, ExtendableCard, Footer, IconButton, InlineMessage, InputWithUnits, ItemCount, LayerGroup, LayerGroupContainer, LayerItem, LayerParameters, LegendItem, List, MapControlsToolbar, MapMarker, MapMarkers, MapPopUp, Menu, MobileTabBar, Modal, MultiActionButton, Navbar, NavigationRail, OptionCard, Pagination, Panel, Password, ProgressBar, QualitativeAttribute, Radio, RadioGroup, RadioList, SSOButtons, ScaleBar, Search, Select, Sheet, SimpleMapPin, Slider, SliderInput, StepProgressIndicator, Switch, TabBar, Table, TableCell, TableRow, Tag, TextInput, Textarea, Toast, Toolbar, Tooltip, designSystemStyles, designSystemStylesForTailwind, getThemedColor, showToast };