@carbon/ibm-products
Version:
Carbon for IBM Products
72 lines (71 loc) • 1.82 kB
TypeScript
import React from 'react';
import { Entry } from '../AddSelect/types';
export interface SingleAddSelectProps {
/**
* optional class name
*/
className?: string;
/**
* text description that appears under the title
*/
description?: string;
/**
* label for global search input
*/
globalSearchLabel?: string;
/**
* placeholder for global search input
*/
globalSearchPlaceholder?: string;
/**
* object that contains the item data. for more information reference the
* "Structuring items" section in the docs tab
*/
items?: {
entries: Entry[];
};
/**
* label that display above the list of items
*/
itemsLabel?: string;
/**
* text to display when no results are found from the global search
*/
noResultsDescription?: string;
/**
* title to display when no results are found from the global search
*/
noResultsTitle?: string;
/**
* function to call when the close button clicked
*/
onClose?: () => void;
/**
* text for close button
*/
onCloseButtonText?: string;
/**
* function to call when the submit button is clicked. returns a selection
*/
onSubmit?: () => void;
/**
* text for the submit button
*/
onSubmitButtonText?: string;
/**
* specifies if the component is open or not
*/
open?: boolean;
/**
* text that displays when displaying filtered items
*/
searchResultsLabel?: string;
/**
* header text
*/
title?: string;
}
/**
* Used to add or select one or more items from larger lists or hierarchies.
*/
export declare let SingleAddSelect: React.ForwardRefExoticComponent<SingleAddSelectProps & React.RefAttributes<HTMLDivElement>>;