DocSpace-client/packages/components/drop-down
2023-04-07 18:32:36 +05:30
..
drop-down.stories.js Web: Components: added indent to drop down story and removed irrelevant section with group button 2023-03-29 20:03:19 +05:00
drop-down.test.js Web: Moved all clients app to packages directory 2022-07-22 22:01:25 +03:00
index.js Web: Components: DropDownContainer - descriptions changed 2023-04-07 18:32:36 +05:30
README.md Web: Moved all clients app to packages directory 2022-07-22 22:01:25 +03:00
styled-drop-down.js Web:Components:Display list at bottom if mobile view. 2023-01-16 17:04:48 +03:00

DropDown

Is a dropdown with any number of action

Usage

import DropDown from "@docspace/components/drop-down";
<DropDown opened={false}></DropDown>

By default, it is used with DropDownItem elements in role of children.

If you want to display something custom, you can put it in children, but take into account that all stylization is assigned to the implemented component.

When using component, it should be noted that parent must have CSS property position: relative. Otherwise, DropDown will appear outside parent's border.

Properties

Props Type Required Values Default Description
className string - - - Accepts class
clickOutsideAction func - - - Required for determining a click outside DropDown with the withBackdrop parameter
directionX oneOf - left, right left Sets the opening direction relative to the parent
directionY oneOf - top, bottom bottom Sets the opening direction relative to the parent
id string - - - Accepts id
manualWidth string - - - Required if you need to specify the exact width of the component, for example 100%
manualX string - - - Required if you need to specify the exact distance from the parent component
manualY string - - - Required if you need to specify the exact distance from the parent component
maxHeight number - - - Required if the scrollbar is displayed
open bool - - false Tells when the dropdown should be opened
style obj, array - - - Accepts css style
withBackdrop bool - - true Used to display backdrop
showDisabledItems bool - - false Display disabled items or not
withBlur bool - - false Enable blur for backdrop