@recursica/mui-adapter 0.1.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/.storybook/commonArgTypes.ts +148 -0
- package/CHANGELOG.md +13 -0
- package/LICENSE +21 -0
- package/README.md +70 -0
- package/dist/index.d.ts +2 -0
- package/dist/mui-adapter.cjs +2 -0
- package/dist/mui-adapter.cjs.map +1 -0
- package/dist/mui-adapter.css +1 -0
- package/dist/mui-adapter.js +164 -0
- package/dist/mui-adapter.js.map +1 -0
- package/dist/src/components/Accordion/Accordion.d.ts +3 -0
- package/dist/src/components/Accordion/index.d.ts +1 -0
- package/dist/src/components/AssistiveElement/AssistiveElement.d.ts +3 -0
- package/dist/src/components/AssistiveElement/index.d.ts +1 -0
- package/dist/src/components/Avatar/Avatar.d.ts +3 -0
- package/dist/src/components/Avatar/index.d.ts +1 -0
- package/dist/src/components/Badge/Badge.d.ts +3 -0
- package/dist/src/components/Badge/index.d.ts +1 -0
- package/dist/src/components/Box/Box.d.ts +9 -0
- package/dist/src/components/Box/index.d.ts +1 -0
- package/dist/src/components/Breadcrumb/Breadcrumb.d.ts +3 -0
- package/dist/src/components/Breadcrumb/index.d.ts +1 -0
- package/dist/src/components/Button/Button.d.ts +3 -0
- package/dist/src/components/Button/index.d.ts +1 -0
- package/dist/src/components/Card/Card.d.ts +3 -0
- package/dist/src/components/Card/index.d.ts +1 -0
- package/dist/src/components/Checkbox/Checkbox.d.ts +3 -0
- package/dist/src/components/Checkbox/index.d.ts +1 -0
- package/dist/src/components/Chip/Chip.d.ts +3 -0
- package/dist/src/components/Chip/index.d.ts +1 -0
- package/dist/src/components/Container/Container.d.ts +3 -0
- package/dist/src/components/Container/index.d.ts +1 -0
- package/dist/src/components/DatePicker/DatePicker.d.ts +3 -0
- package/dist/src/components/DatePicker/index.d.ts +1 -0
- package/dist/src/components/Dropdown/Dropdown.d.ts +3 -0
- package/dist/src/components/Dropdown/index.d.ts +1 -0
- package/dist/src/components/FileInput/FileInput.d.ts +3 -0
- package/dist/src/components/FileInput/index.d.ts +1 -0
- package/dist/src/components/FileUpload/FileUpload.d.ts +3 -0
- package/dist/src/components/FileUpload/index.d.ts +1 -0
- package/dist/src/components/Flex/Flex.d.ts +3 -0
- package/dist/src/components/Flex/index.d.ts +1 -0
- package/dist/src/components/FormControlLayout/FormControlLayout.d.ts +3 -0
- package/dist/src/components/FormControlLayout/index.d.ts +1 -0
- package/dist/src/components/FormControlWrapper/FormControlWrapper.d.ts +3 -0
- package/dist/src/components/FormControlWrapper/index.d.ts +1 -0
- package/dist/src/components/Group/Group.d.ts +3 -0
- package/dist/src/components/Group/index.d.ts +1 -0
- package/dist/src/components/HoverCard/HoverCard.d.ts +3 -0
- package/dist/src/components/HoverCard/index.d.ts +1 -0
- package/dist/src/components/Label/Label.d.ts +3 -0
- package/dist/src/components/Label/index.d.ts +1 -0
- package/dist/src/components/Link/Link.d.ts +3 -0
- package/dist/src/components/Link/index.d.ts +1 -0
- package/dist/src/components/Loader/Loader.d.ts +3 -0
- package/dist/src/components/Loader/index.d.ts +1 -0
- package/dist/src/components/Menu/Menu.d.ts +3 -0
- package/dist/src/components/Menu/index.d.ts +1 -0
- package/dist/src/components/Modal/Modal.d.ts +3 -0
- package/dist/src/components/Modal/index.d.ts +1 -0
- package/dist/src/components/NumberInput/NumberInput.d.ts +3 -0
- package/dist/src/components/NumberInput/index.d.ts +1 -0
- package/dist/src/components/Pagination/Pagination.d.ts +3 -0
- package/dist/src/components/Pagination/index.d.ts +1 -0
- package/dist/src/components/Panel/Panel.d.ts +3 -0
- package/dist/src/components/Panel/index.d.ts +1 -0
- package/dist/src/components/Radio/Radio.d.ts +3 -0
- package/dist/src/components/Radio/index.d.ts +1 -0
- package/dist/src/components/ReadOnlyField/ReadOnlyField.d.ts +3 -0
- package/dist/src/components/ReadOnlyField/index.d.ts +1 -0
- package/dist/src/components/SegmentedControl/SegmentedControl.d.ts +3 -0
- package/dist/src/components/SegmentedControl/index.d.ts +1 -0
- package/dist/src/components/Slider/Slider.d.ts +3 -0
- package/dist/src/components/Slider/index.d.ts +1 -0
- package/dist/src/components/Stack/Stack.d.ts +3 -0
- package/dist/src/components/Stack/index.d.ts +1 -0
- package/dist/src/components/Stepper/Stepper.d.ts +3 -0
- package/dist/src/components/Stepper/index.d.ts +1 -0
- package/dist/src/components/Switch/Switch.d.ts +3 -0
- package/dist/src/components/Switch/index.d.ts +1 -0
- package/dist/src/components/Table/Table.d.ts +3 -0
- package/dist/src/components/Table/index.d.ts +1 -0
- package/dist/src/components/Tabs/Tabs.d.ts +3 -0
- package/dist/src/components/Tabs/index.d.ts +1 -0
- package/dist/src/components/Text/Text.d.ts +3 -0
- package/dist/src/components/Text/index.d.ts +1 -0
- package/dist/src/components/TextArea/TextArea.d.ts +3 -0
- package/dist/src/components/TextArea/index.d.ts +1 -0
- package/dist/src/components/TextField/TextField.d.ts +3 -0
- package/dist/src/components/TextField/index.d.ts +1 -0
- package/dist/src/components/TimePicker/TimePicker.d.ts +3 -0
- package/dist/src/components/TimePicker/index.d.ts +1 -0
- package/dist/src/components/Timeline/Timeline.d.ts +3 -0
- package/dist/src/components/Timeline/index.d.ts +1 -0
- package/dist/src/components/Title/Title.d.ts +3 -0
- package/dist/src/components/Title/index.d.ts +1 -0
- package/dist/src/components/Toast/Toast.d.ts +3 -0
- package/dist/src/components/Toast/index.d.ts +1 -0
- package/dist/src/components/Tooltip/Tooltip.d.ts +3 -0
- package/dist/src/components/Tooltip/index.d.ts +1 -0
- package/dist/src/components/TransferList/TransferList.d.ts +3 -0
- package/dist/src/components/TransferList/index.d.ts +1 -0
- package/dist/src/components/index.d.ts +46 -0
- package/dist/src/index.d.ts +2 -0
- package/dist/src/types/index.d.ts +6 -0
- package/dist/src/utils/ColorSchemeWrapper.d.ts +3 -0
- package/dist/src/utils/RequireAccessibleLabel.d.ts +18 -0
- package/dist/src/utils/copyToClipboard.d.ts +8 -0
- package/dist/src/utils/filterStylingProps.d.ts +36 -0
- package/dist/src/utils/index.d.ts +1 -0
- package/dist/vite.config.d.ts +2 -0
- package/dist/vite.svg +1 -0
- package/dist/vitest.workspace.d.ts +2 -0
- package/package.json +98 -0
- package/src/OverStyling.stories.tsx +235 -0
- package/src/Version.stories.tsx +56 -0
- package/src/components/Accordion/Accordion.stories.tsx +16 -0
- package/src/components/Accordion/Accordion.tsx +7 -0
- package/src/components/Accordion/index.ts +1 -0
- package/src/components/AssistiveElement/AssistiveElement.stories.tsx +16 -0
- package/src/components/AssistiveElement/AssistiveElement.tsx +7 -0
- package/src/components/AssistiveElement/index.ts +1 -0
- package/src/components/Avatar/Avatar.stories.tsx +16 -0
- package/src/components/Avatar/Avatar.tsx +7 -0
- package/src/components/Avatar/index.ts +1 -0
- package/src/components/Badge/Badge.stories.tsx +16 -0
- package/src/components/Badge/Badge.tsx +7 -0
- package/src/components/Badge/index.ts +1 -0
- package/src/components/Box/Box.stories.tsx +59 -0
- package/src/components/Box/Box.tsx +27 -0
- package/src/components/Box/index.ts +1 -0
- package/src/components/Breadcrumb/Breadcrumb.stories.tsx +16 -0
- package/src/components/Breadcrumb/Breadcrumb.tsx +7 -0
- package/src/components/Breadcrumb/index.ts +1 -0
- package/src/components/Button/Button.stories.tsx +16 -0
- package/src/components/Button/Button.tsx +7 -0
- package/src/components/Button/index.ts +1 -0
- package/src/components/Card/Card.stories.tsx +16 -0
- package/src/components/Card/Card.tsx +7 -0
- package/src/components/Card/index.ts +1 -0
- package/src/components/Checkbox/Checkbox.stories.tsx +16 -0
- package/src/components/Checkbox/Checkbox.tsx +7 -0
- package/src/components/Checkbox/index.ts +1 -0
- package/src/components/Chip/Chip.stories.tsx +16 -0
- package/src/components/Chip/Chip.tsx +7 -0
- package/src/components/Chip/index.ts +1 -0
- package/src/components/Container/Container.stories.tsx +16 -0
- package/src/components/Container/Container.tsx +7 -0
- package/src/components/Container/index.ts +1 -0
- package/src/components/DatePicker/DatePicker.stories.tsx +16 -0
- package/src/components/DatePicker/DatePicker.tsx +7 -0
- package/src/components/DatePicker/index.ts +1 -0
- package/src/components/Dropdown/Dropdown.stories.tsx +16 -0
- package/src/components/Dropdown/Dropdown.tsx +7 -0
- package/src/components/Dropdown/index.ts +1 -0
- package/src/components/FileInput/FileInput.stories.tsx +16 -0
- package/src/components/FileInput/FileInput.tsx +7 -0
- package/src/components/FileInput/index.ts +1 -0
- package/src/components/FileUpload/FileUpload.stories.tsx +16 -0
- package/src/components/FileUpload/FileUpload.tsx +7 -0
- package/src/components/FileUpload/index.ts +1 -0
- package/src/components/Flex/Flex.stories.tsx +16 -0
- package/src/components/Flex/Flex.tsx +7 -0
- package/src/components/Flex/index.ts +1 -0
- package/src/components/FormControlLayout/FormControlLayout.stories.tsx +16 -0
- package/src/components/FormControlLayout/FormControlLayout.tsx +7 -0
- package/src/components/FormControlLayout/index.ts +1 -0
- package/src/components/FormControlWrapper/FormControlWrapper.stories.tsx +16 -0
- package/src/components/FormControlWrapper/FormControlWrapper.tsx +9 -0
- package/src/components/FormControlWrapper/index.ts +1 -0
- package/src/components/Group/Group.stories.tsx +16 -0
- package/src/components/Group/Group.tsx +7 -0
- package/src/components/Group/index.ts +1 -0
- package/src/components/HoverCard/HoverCard.stories.tsx +16 -0
- package/src/components/HoverCard/HoverCard.tsx +7 -0
- package/src/components/HoverCard/index.ts +1 -0
- package/src/components/Label/Label.stories.tsx +16 -0
- package/src/components/Label/Label.tsx +7 -0
- package/src/components/Label/index.ts +1 -0
- package/src/components/Link/Link.stories.tsx +16 -0
- package/src/components/Link/Link.tsx +7 -0
- package/src/components/Link/index.ts +1 -0
- package/src/components/Loader/Loader.stories.tsx +16 -0
- package/src/components/Loader/Loader.tsx +7 -0
- package/src/components/Loader/index.ts +1 -0
- package/src/components/Menu/Menu.stories.tsx +16 -0
- package/src/components/Menu/Menu.tsx +7 -0
- package/src/components/Menu/index.ts +1 -0
- package/src/components/Modal/Modal.stories.tsx +16 -0
- package/src/components/Modal/Modal.tsx +7 -0
- package/src/components/Modal/index.ts +1 -0
- package/src/components/NumberInput/NumberInput.stories.tsx +16 -0
- package/src/components/NumberInput/NumberInput.tsx +7 -0
- package/src/components/NumberInput/index.ts +1 -0
- package/src/components/Pagination/Pagination.stories.tsx +16 -0
- package/src/components/Pagination/Pagination.tsx +7 -0
- package/src/components/Pagination/index.ts +1 -0
- package/src/components/Panel/Panel.stories.tsx +16 -0
- package/src/components/Panel/Panel.tsx +7 -0
- package/src/components/Panel/index.ts +1 -0
- package/src/components/Radio/Radio.stories.tsx +16 -0
- package/src/components/Radio/Radio.tsx +7 -0
- package/src/components/Radio/index.ts +1 -0
- package/src/components/ReadOnlyField/ReadOnlyField.stories.tsx +16 -0
- package/src/components/ReadOnlyField/ReadOnlyField.tsx +7 -0
- package/src/components/ReadOnlyField/index.ts +1 -0
- package/src/components/SegmentedControl/SegmentedControl.stories.tsx +16 -0
- package/src/components/SegmentedControl/SegmentedControl.tsx +7 -0
- package/src/components/SegmentedControl/index.ts +1 -0
- package/src/components/Slider/Slider.stories.tsx +16 -0
- package/src/components/Slider/Slider.tsx +7 -0
- package/src/components/Slider/index.ts +1 -0
- package/src/components/Stack/Stack.stories.tsx +16 -0
- package/src/components/Stack/Stack.tsx +7 -0
- package/src/components/Stack/index.ts +1 -0
- package/src/components/Stepper/Stepper.stories.tsx +16 -0
- package/src/components/Stepper/Stepper.tsx +7 -0
- package/src/components/Stepper/index.ts +1 -0
- package/src/components/Switch/Switch.stories.tsx +16 -0
- package/src/components/Switch/Switch.tsx +7 -0
- package/src/components/Switch/index.ts +1 -0
- package/src/components/Table/Table.stories.tsx +16 -0
- package/src/components/Table/Table.tsx +7 -0
- package/src/components/Table/index.ts +1 -0
- package/src/components/Tabs/Tabs.stories.tsx +16 -0
- package/src/components/Tabs/Tabs.tsx +7 -0
- package/src/components/Tabs/index.ts +1 -0
- package/src/components/Text/Text.stories.tsx +16 -0
- package/src/components/Text/Text.tsx +7 -0
- package/src/components/Text/index.ts +1 -0
- package/src/components/TextArea/TextArea.stories.tsx +16 -0
- package/src/components/TextArea/TextArea.tsx +7 -0
- package/src/components/TextArea/index.ts +1 -0
- package/src/components/TextField/TextField.stories.tsx +16 -0
- package/src/components/TextField/TextField.tsx +7 -0
- package/src/components/TextField/index.ts +1 -0
- package/src/components/TimePicker/TimePicker.stories.tsx +16 -0
- package/src/components/TimePicker/TimePicker.tsx +7 -0
- package/src/components/TimePicker/index.ts +1 -0
- package/src/components/Timeline/Timeline.stories.tsx +16 -0
- package/src/components/Timeline/Timeline.tsx +7 -0
- package/src/components/Timeline/index.ts +1 -0
- package/src/components/Title/Title.stories.tsx +16 -0
- package/src/components/Title/Title.tsx +7 -0
- package/src/components/Title/index.ts +1 -0
- package/src/components/Toast/Toast.stories.tsx +16 -0
- package/src/components/Toast/Toast.tsx +7 -0
- package/src/components/Toast/index.ts +1 -0
- package/src/components/Tooltip/Tooltip.stories.tsx +16 -0
- package/src/components/Tooltip/Tooltip.tsx +7 -0
- package/src/components/Tooltip/index.ts +1 -0
- package/src/components/TransferList/TransferList.stories.tsx +16 -0
- package/src/components/TransferList/TransferList.tsx +7 -0
- package/src/components/TransferList/index.ts +1 -0
- package/src/components/index.ts +46 -0
- package/src/env.d.ts +7 -0
- package/src/index.ts +3 -0
- package/src/types/index.ts +9 -0
- package/src/types/mantine.d.ts +7 -0
- package/src/types/scss-modules.d.ts +9 -0
- package/src/utils/ColorSchemeWrapper.tsx +27 -0
- package/src/utils/RequireAccessibleLabel.ts +12 -0
- package/src/utils/copyToClipboard.ts +36 -0
- package/src/utils/filterStylingProps.ts +139 -0
- package/src/utils/index.ts +1 -0
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from "@storybook/react";
|
|
2
|
+
import { Stack } from "./Stack";
|
|
3
|
+
import { ComingSoon } from "@recursica/storybook-template";
|
|
4
|
+
|
|
5
|
+
const meta: Meta<typeof Stack> = {
|
|
6
|
+
title: "UI-Kit/🚧 Stack",
|
|
7
|
+
component: Stack,
|
|
8
|
+
tags: ["autodocs"],
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
export default meta;
|
|
12
|
+
type Story = StoryObj<typeof Stack>;
|
|
13
|
+
|
|
14
|
+
export const Default: Story = {
|
|
15
|
+
render: () => <ComingSoon componentName="Stack" />,
|
|
16
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./Stack";
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from "@storybook/react";
|
|
2
|
+
import { Stepper } from "./Stepper";
|
|
3
|
+
import { ComingSoon } from "@recursica/storybook-template";
|
|
4
|
+
|
|
5
|
+
const meta: Meta<typeof Stepper> = {
|
|
6
|
+
title: "UI-Kit/🚧 Stepper",
|
|
7
|
+
component: Stepper,
|
|
8
|
+
tags: ["autodocs"],
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
export default meta;
|
|
12
|
+
type Story = StoryObj<typeof Stepper>;
|
|
13
|
+
|
|
14
|
+
export const Default: Story = {
|
|
15
|
+
render: () => <ComingSoon componentName="Stepper" />,
|
|
16
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./Stepper";
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from "@storybook/react";
|
|
2
|
+
import { Switch } from "./Switch";
|
|
3
|
+
import { ComingSoon } from "@recursica/storybook-template";
|
|
4
|
+
|
|
5
|
+
const meta: Meta<typeof Switch> = {
|
|
6
|
+
title: "UI-Kit/🚧 Switch",
|
|
7
|
+
component: Switch,
|
|
8
|
+
tags: ["autodocs"],
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
export default meta;
|
|
12
|
+
type Story = StoryObj<typeof Switch>;
|
|
13
|
+
|
|
14
|
+
export const Default: Story = {
|
|
15
|
+
render: () => <ComingSoon componentName="Switch" />,
|
|
16
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./Switch";
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from "@storybook/react";
|
|
2
|
+
import { Table } from "./Table";
|
|
3
|
+
import { ComingSoon } from "@recursica/storybook-template";
|
|
4
|
+
|
|
5
|
+
const meta: Meta<typeof Table> = {
|
|
6
|
+
title: "UI-Kit/🚧 Table",
|
|
7
|
+
component: Table,
|
|
8
|
+
tags: ["autodocs"],
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
export default meta;
|
|
12
|
+
type Story = StoryObj<typeof Table>;
|
|
13
|
+
|
|
14
|
+
export const Default: Story = {
|
|
15
|
+
render: () => <ComingSoon componentName="Table" />,
|
|
16
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./Table";
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from "@storybook/react";
|
|
2
|
+
import { Tabs } from "./Tabs";
|
|
3
|
+
import { ComingSoon } from "@recursica/storybook-template";
|
|
4
|
+
|
|
5
|
+
const meta: Meta<typeof Tabs> = {
|
|
6
|
+
title: "UI-Kit/🚧 Tabs",
|
|
7
|
+
component: Tabs,
|
|
8
|
+
tags: ["autodocs"],
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
export default meta;
|
|
12
|
+
type Story = StoryObj<typeof Tabs>;
|
|
13
|
+
|
|
14
|
+
export const Default: Story = {
|
|
15
|
+
render: () => <ComingSoon componentName="Tabs" />,
|
|
16
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./Tabs";
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from "@storybook/react";
|
|
2
|
+
import { Text } from "./Text";
|
|
3
|
+
import { ComingSoon } from "@recursica/storybook-template";
|
|
4
|
+
|
|
5
|
+
const meta: Meta<typeof Text> = {
|
|
6
|
+
title: "UI-Kit/🚧 Text",
|
|
7
|
+
component: Text,
|
|
8
|
+
tags: ["autodocs"],
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
export default meta;
|
|
12
|
+
type Story = StoryObj<typeof Text>;
|
|
13
|
+
|
|
14
|
+
export const Default: Story = {
|
|
15
|
+
render: () => <ComingSoon componentName="Text" />,
|
|
16
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./Text";
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from "@storybook/react";
|
|
2
|
+
import { TextArea } from "./TextArea";
|
|
3
|
+
import { ComingSoon } from "@recursica/storybook-template";
|
|
4
|
+
|
|
5
|
+
const meta: Meta<typeof TextArea> = {
|
|
6
|
+
title: "UI-Kit/🚧 TextArea",
|
|
7
|
+
component: TextArea,
|
|
8
|
+
tags: ["autodocs"],
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
export default meta;
|
|
12
|
+
type Story = StoryObj<typeof TextArea>;
|
|
13
|
+
|
|
14
|
+
export const Default: Story = {
|
|
15
|
+
render: () => <ComingSoon componentName="TextArea" />,
|
|
16
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./TextArea";
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from "@storybook/react";
|
|
2
|
+
import { TextField } from "./TextField";
|
|
3
|
+
import { ComingSoon } from "@recursica/storybook-template";
|
|
4
|
+
|
|
5
|
+
const meta: Meta<typeof TextField> = {
|
|
6
|
+
title: "UI-Kit/🚧 TextField",
|
|
7
|
+
component: TextField,
|
|
8
|
+
tags: ["autodocs"],
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
export default meta;
|
|
12
|
+
type Story = StoryObj<typeof TextField>;
|
|
13
|
+
|
|
14
|
+
export const Default: Story = {
|
|
15
|
+
render: () => <ComingSoon componentName="TextField" />,
|
|
16
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./TextField";
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from "@storybook/react";
|
|
2
|
+
import { TimePicker } from "./TimePicker";
|
|
3
|
+
import { ComingSoon } from "@recursica/storybook-template";
|
|
4
|
+
|
|
5
|
+
const meta: Meta<typeof TimePicker> = {
|
|
6
|
+
title: "UI-Kit/🚧 TimePicker",
|
|
7
|
+
component: TimePicker,
|
|
8
|
+
tags: ["autodocs"],
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
export default meta;
|
|
12
|
+
type Story = StoryObj<typeof TimePicker>;
|
|
13
|
+
|
|
14
|
+
export const Default: Story = {
|
|
15
|
+
render: () => <ComingSoon componentName="TimePicker" />,
|
|
16
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./TimePicker";
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from "@storybook/react";
|
|
2
|
+
import { Timeline } from "./Timeline";
|
|
3
|
+
import { ComingSoon } from "@recursica/storybook-template";
|
|
4
|
+
|
|
5
|
+
const meta: Meta<typeof Timeline> = {
|
|
6
|
+
title: "UI-Kit/🚧 Timeline",
|
|
7
|
+
component: Timeline,
|
|
8
|
+
tags: ["autodocs"],
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
export default meta;
|
|
12
|
+
type Story = StoryObj<typeof Timeline>;
|
|
13
|
+
|
|
14
|
+
export const Default: Story = {
|
|
15
|
+
render: () => <ComingSoon componentName="Timeline" />,
|
|
16
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./Timeline";
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from "@storybook/react";
|
|
2
|
+
import { Title } from "./Title";
|
|
3
|
+
import { ComingSoon } from "@recursica/storybook-template";
|
|
4
|
+
|
|
5
|
+
const meta: Meta<typeof Title> = {
|
|
6
|
+
title: "UI-Kit/🚧 Title",
|
|
7
|
+
component: Title,
|
|
8
|
+
tags: ["autodocs"],
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
export default meta;
|
|
12
|
+
type Story = StoryObj<typeof Title>;
|
|
13
|
+
|
|
14
|
+
export const Default: Story = {
|
|
15
|
+
render: () => <ComingSoon componentName="Title" />,
|
|
16
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./Title";
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from "@storybook/react";
|
|
2
|
+
import { Toast } from "./Toast";
|
|
3
|
+
import { ComingSoon } from "@recursica/storybook-template";
|
|
4
|
+
|
|
5
|
+
const meta: Meta<typeof Toast> = {
|
|
6
|
+
title: "UI-Kit/🚧 Toast",
|
|
7
|
+
component: Toast,
|
|
8
|
+
tags: ["autodocs"],
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
export default meta;
|
|
12
|
+
type Story = StoryObj<typeof Toast>;
|
|
13
|
+
|
|
14
|
+
export const Default: Story = {
|
|
15
|
+
render: () => <ComingSoon componentName="Toast" />,
|
|
16
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./Toast";
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from "@storybook/react";
|
|
2
|
+
import { Tooltip } from "./Tooltip";
|
|
3
|
+
import { ComingSoon } from "@recursica/storybook-template";
|
|
4
|
+
|
|
5
|
+
const meta: Meta<typeof Tooltip> = {
|
|
6
|
+
title: "UI-Kit/🚧 Tooltip",
|
|
7
|
+
component: Tooltip,
|
|
8
|
+
tags: ["autodocs"],
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
export default meta;
|
|
12
|
+
type Story = StoryObj<typeof Tooltip>;
|
|
13
|
+
|
|
14
|
+
export const Default: Story = {
|
|
15
|
+
render: () => <ComingSoon componentName="Tooltip" />,
|
|
16
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./Tooltip";
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from "@storybook/react";
|
|
2
|
+
import { TransferList } from "./TransferList";
|
|
3
|
+
import { ComingSoon } from "@recursica/storybook-template";
|
|
4
|
+
|
|
5
|
+
const meta: Meta<typeof TransferList> = {
|
|
6
|
+
title: "UI-Kit/🚧 TransferList",
|
|
7
|
+
component: TransferList,
|
|
8
|
+
tags: ["autodocs"],
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
export default meta;
|
|
12
|
+
type Story = StoryObj<typeof TransferList>;
|
|
13
|
+
|
|
14
|
+
export const Default: Story = {
|
|
15
|
+
render: () => <ComingSoon componentName="TransferList" />,
|
|
16
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./TransferList";
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
export * from "./Accordion";
|
|
2
|
+
export * from "./AssistiveElement";
|
|
3
|
+
export * from "./Avatar";
|
|
4
|
+
export * from "./Badge";
|
|
5
|
+
export * from "./Box";
|
|
6
|
+
export * from "./Breadcrumb";
|
|
7
|
+
export * from "./Button";
|
|
8
|
+
export * from "./Card";
|
|
9
|
+
export * from "./Checkbox";
|
|
10
|
+
export * from "./Chip";
|
|
11
|
+
export * from "./Container";
|
|
12
|
+
export * from "./DatePicker";
|
|
13
|
+
export * from "./Dropdown";
|
|
14
|
+
export * from "./FileInput";
|
|
15
|
+
export * from "./FileUpload";
|
|
16
|
+
export * from "./Flex";
|
|
17
|
+
export * from "./FormControlLayout";
|
|
18
|
+
export * from "./FormControlWrapper";
|
|
19
|
+
export * from "./Group";
|
|
20
|
+
export * from "./HoverCard";
|
|
21
|
+
export * from "./Label";
|
|
22
|
+
export * from "./Link";
|
|
23
|
+
export * from "./Loader";
|
|
24
|
+
export * from "./Menu";
|
|
25
|
+
export * from "./Modal";
|
|
26
|
+
export * from "./NumberInput";
|
|
27
|
+
export * from "./Pagination";
|
|
28
|
+
export * from "./Panel";
|
|
29
|
+
export * from "./Radio";
|
|
30
|
+
export * from "./ReadOnlyField";
|
|
31
|
+
export * from "./SegmentedControl";
|
|
32
|
+
export * from "./Slider";
|
|
33
|
+
export * from "./Stack";
|
|
34
|
+
export * from "./Stepper";
|
|
35
|
+
export * from "./Switch";
|
|
36
|
+
export * from "./Table";
|
|
37
|
+
export * from "./Tabs";
|
|
38
|
+
export * from "./Text";
|
|
39
|
+
export * from "./TextArea";
|
|
40
|
+
export * from "./TextField";
|
|
41
|
+
export * from "./TimePicker";
|
|
42
|
+
export * from "./Timeline";
|
|
43
|
+
export * from "./Title";
|
|
44
|
+
export * from "./Toast";
|
|
45
|
+
export * from "./Tooltip";
|
|
46
|
+
export * from "./TransferList";
|
package/src/env.d.ts
ADDED
package/src/index.ts
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { ComboboxItem as RecursicaComboboxItem } from "./index";
|
|
2
|
+
import "@mantine/core";
|
|
3
|
+
|
|
4
|
+
declare module "@mantine/core" {
|
|
5
|
+
// eslint-disable-next-line @typescript-eslint/no-empty-object-type
|
|
6
|
+
export interface ComboboxItem extends RecursicaComboboxItem {}
|
|
7
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { useMantineColorScheme } from "@mantine/core";
|
|
2
|
+
import { useEffect } from "react";
|
|
3
|
+
import { addons } from "storybook/internal/preview-api";
|
|
4
|
+
import { DARK_MODE_EVENT_NAME } from "storybook-dark-mode";
|
|
5
|
+
|
|
6
|
+
const channel = addons.getChannel();
|
|
7
|
+
|
|
8
|
+
export function ColorSchemeWrapper({
|
|
9
|
+
children,
|
|
10
|
+
}: {
|
|
11
|
+
children: React.ReactNode;
|
|
12
|
+
}) {
|
|
13
|
+
const { setColorScheme } = useMantineColorScheme();
|
|
14
|
+
|
|
15
|
+
useEffect(() => {
|
|
16
|
+
const handleColorScheme = (value: boolean) => {
|
|
17
|
+
const theme = value ? "dark" : "light";
|
|
18
|
+
setColorScheme(theme);
|
|
19
|
+
document.documentElement.setAttribute("data-recursica-theme", theme);
|
|
20
|
+
};
|
|
21
|
+
|
|
22
|
+
channel.on(DARK_MODE_EVENT_NAME, handleColorScheme);
|
|
23
|
+
return () => channel.off(DARK_MODE_EVENT_NAME, handleColorScheme);
|
|
24
|
+
}, [setColorScheme]);
|
|
25
|
+
|
|
26
|
+
return <>{children}</>;
|
|
27
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { ReactNode } from "react";
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Enforces accessibility by strictly requiring at least one form of labeling:
|
|
5
|
+
* either a visual \`label\`, an \`aria-label\`, or an \`aria-labelledby\`.
|
|
6
|
+
*/
|
|
7
|
+
export type RequireAccessibleLabel<T> = T &
|
|
8
|
+
(
|
|
9
|
+
| { label: ReactNode; "aria-label"?: string; "aria-labelledby"?: string }
|
|
10
|
+
| { label?: ReactNode; "aria-label": string; "aria-labelledby"?: string }
|
|
11
|
+
| { label?: ReactNode; "aria-label"?: string; "aria-labelledby": string }
|
|
12
|
+
);
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Helper function for copy text to clipboard
|
|
5
|
+
* @param {string} textToCopy The text string for copying to the clipboard
|
|
6
|
+
* @param {element|node} componentRef The ref of the component that we want to trigger the copy
|
|
7
|
+
*/
|
|
8
|
+
const copyToClipboard = (
|
|
9
|
+
textToCopy: string,
|
|
10
|
+
componentRef: React.RefObject<HTMLElement | null>,
|
|
11
|
+
): Promise<void> => {
|
|
12
|
+
const currentFocus = document.activeElement as HTMLInputElement;
|
|
13
|
+
return new Promise((resolve, reject) => {
|
|
14
|
+
if (componentRef && componentRef.current) {
|
|
15
|
+
const textArea = document.createElement("textarea");
|
|
16
|
+
textArea.readOnly = true;
|
|
17
|
+
textArea.defaultValue = textToCopy;
|
|
18
|
+
componentRef.current.appendChild(textArea);
|
|
19
|
+
textArea.select();
|
|
20
|
+
const wasCopied = document.execCommand("copy");
|
|
21
|
+
componentRef.current.removeChild(textArea);
|
|
22
|
+
if (currentFocus) {
|
|
23
|
+
currentFocus.focus();
|
|
24
|
+
}
|
|
25
|
+
if (wasCopied) {
|
|
26
|
+
resolve();
|
|
27
|
+
} else {
|
|
28
|
+
reject(new Error("Failed to copy"));
|
|
29
|
+
}
|
|
30
|
+
} else {
|
|
31
|
+
reject(new Error("Copy area reference is not defined"));
|
|
32
|
+
}
|
|
33
|
+
});
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
export { copyToClipboard };
|