@eteg/react-dropdowns
TypeScript icon, indicating that this package has built-in type declarations

1.0.0 • Public • Published

@garden/components npm version

This package includes several varieties of notifications and wells within the Garden Design System.

Installation

npm install @garden/components

# Peer Dependencies - Also Required
npm install react react-dom styled-components @zendeskgarden/react-theming @zendeskgarden/react-dropdowns

Usage

import { ThemeProvider } from '@zendeskgarden/react-theming';
import { SelectSearchable } from '@garden/components'

const selectSearchableOptions = [
  "Asparagus",
  "Brussel sprouts",
  "Cauliflower",
  "Garlic",
  "Jerusalem artichoke",
  "Kale",
  "Lettuce",
  "Onion",
  "Mushroom",
  "Potato",
  "Radish",
  "Spinach",
  "Tomato",
  "Yam",
  "Zucchini",
]

/**
 * Place a `ThemeProvider` at the root of your React application
 */
<ThemeProvider>
  <SelectSearchable
          label="Choose a vegetable"
          options={selectSearchableOptions}
          onSelect={(item) => console.log(`${item} selected.`)}
        />
</ThemeProvider>;

SelectSearchable

Prop name Type default description required
options string[] An array containing just the names of all options yes
label string A name that describes the dropdown menu yes
onSelect (item: string) => void Select the item clicked no

Package Sidebar

Install

npm i @eteg/react-dropdowns

Homepage

eteg.com.br

Weekly Downloads

0

Version

1.0.0

License

Apache-2.0

Unpacked Size

7.69 kB

Total Files

6

Last publish

Collaborators

  • vitorpeixoto
  • augustobritodev
  • eteg-owner