DocSpace-client/packages/components/access-right-select
2023-08-23 09:35:35 +03:00
..
access-right-select.mdx Web: Components: fixed storybook blocks import 2023-05-31 20:00:04 +05:00
access-right-select.stories.js web component selector add rtl without scrollbar 2023-06-20 09:49:39 +03:00
data.js Web: Components: AccessRightSelect: delete icons for story 2023-05-30 16:57:50 +05:00
index.js Web:Components:Fixed AccessRightSelect list not closing on the invitation panel on mobile and tablets when clicking outside the area. 2023-08-23 09:35:35 +03:00
README.md Web:Components: editing path for assets for storybook 2023-01-16 15:04:26 +05:00
styled-accessright.js front add rtl access-right-select 2023-06-05 17:16:49 +03:00

AccessRightSelect

Usage

import AccessRightSelect from "@docspace/components/AccessRightSelect";
<AccessRightSelect
  options={options}
  onSelect={(option) => console.log("selected", option)}
  selectedOption={{
    key: "key1",
    title: "Room administrator",
    description: `Administration of rooms, archiving of rooms, inviting and managing users in rooms.`,
    icon: AccessCommentReactSvgUrl,
    quota: "free",
    color: "#20D21F",
  }}
/>

Options is an array of objects that contains the following fields:

  • key
  • title
  • description
  • icon
  • quota
  • color
Example:
  {
    key: "key1",
    title: "Room administrator",
    description: `Administration of rooms, archiving of rooms, inviting and managing users in rooms.`,
    icon: AccessCommentReactSvgUrl,
    quota: "free",
    color: "#20D21F",
  }

Properties

Props Type Required Values Default Description
options obj, array - - List of options
onSelect obj, array - - - Will be triggered whenever an AccessRightSelect is selected option
selectedOption obj - - - The option that is selected by default