@mrshmllw/smores-react 2.1.13 → 2.1.16
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/dist/Accordion/Accordion.d.ts +1 -2
- package/dist/Accordion/Accordion.js +1 -1
- package/dist/Accordion/Accordion.stories.d.ts +9 -8
- package/dist/Accordion/Accordion.stories.js +1 -1
- package/dist/Accordion/Accordion.stories.js.map +1 -1
- package/dist/ActionDropdown/ActionDropdown.stories.d.ts +13 -6
- package/dist/ActionDropdown/ActionDropdown.stories.js +1 -1
- package/dist/ActionDropdown/ActionDropdown.stories.js.map +1 -1
- package/dist/ActionDropdown/Container.d.ts +2 -1
- package/dist/ActionDropdown/Container.js +3 -1
- package/dist/ActionDropdown/Container.js.map +1 -1
- package/dist/Box/Box.d.ts +2 -4
- package/dist/Box/Box.js.map +1 -1
- package/dist/Box/Box.stories.d.ts +5 -6
- package/dist/Box/Box.stories.js +1 -1
- package/dist/Box/Box.stories.js.map +1 -1
- package/dist/Button/Button.d.ts +1 -1
- package/dist/Button/Button.stories.d.ts +15 -22
- package/dist/Button/Button.stories.js +14 -53
- package/dist/Button/Button.stories.js.map +1 -1
- package/dist/Button/Collection.d.ts +2 -0
- package/dist/Button/Collection.js +51 -0
- package/dist/Button/Collection.js.map +1 -0
- package/dist/Card/Card.d.ts +2 -3
- package/dist/Card/Card.js.map +1 -1
- package/dist/Card/Card.stories.d.ts +11 -10
- package/dist/Card/Card.stories.js +2 -2
- package/dist/Card/Card.stories.js.map +1 -1
- package/dist/CheckBox/CheckBox.d.ts +2 -3
- package/dist/CheckBox/CheckBox.js.map +1 -1
- package/dist/CheckBox/CheckBox.stories.d.ts +9 -8
- package/dist/CheckBox/CheckBox.stories.js +2 -2
- package/dist/CheckBox/CheckBox.stories.js.map +1 -1
- package/dist/CheckBox/Container.d.ts +2 -1
- package/dist/CheckBox/Container.js.map +1 -1
- package/dist/CheckBoxGroup/CheckBoxGroup.stories.d.ts +13 -6
- package/dist/CheckBoxGroup/CheckBoxGroup.stories.js +1 -1
- package/dist/CheckBoxGroup/CheckBoxGroup.stories.js.map +1 -1
- package/dist/Chip/Chip.d.ts +1 -1
- package/dist/Chip/Chip.stories.d.ts +15 -14
- package/dist/Chip/Chip.stories.js +1 -1
- package/dist/Chip/Chip.stories.js.map +1 -1
- package/dist/ConfirmationRadioButtons/Confirmation.d.ts +1 -2
- package/dist/ConfirmationRadioButtons/Confirmation.stories.d.ts +16 -15
- package/dist/ConfirmationRadioButtons/Confirmation.stories.js +7 -6
- package/dist/ConfirmationRadioButtons/Confirmation.stories.js.map +1 -1
- package/dist/Datepicker/Datepicker.d.ts +1 -2
- package/dist/Datepicker/Datepicker.stories.d.ts +12 -11
- package/dist/Datepicker/Datepicker.stories.js +1 -1
- package/dist/Datepicker/Datepicker.stories.js.map +1 -1
- package/dist/Divider/Divider.d.ts +1 -2
- package/dist/Divider/Divier.stories.d.ts +7 -6
- package/dist/Divider/Divier.stories.js +1 -1
- package/dist/Divider/Divier.stories.js.map +1 -1
- package/dist/Dropdown/Container.d.ts +2 -1
- package/dist/Dropdown/Container.js +3 -3
- package/dist/Dropdown/Container.js.map +1 -1
- package/dist/Dropdown/Dropdown.d.ts +2 -2
- package/dist/Dropdown/Dropdown.js.map +1 -1
- package/dist/Dropdown/Dropdown.stories.d.ts +27 -26
- package/dist/Dropdown/Dropdown.stories.js +2 -2
- package/dist/Dropdown/Dropdown.stories.js.map +1 -1
- package/dist/Emoji/Emoji.d.ts +1 -2
- package/dist/Emoji/Emoji.stories.d.ts +7 -6
- package/dist/Emoji/Emoji.stories.js +1 -1
- package/dist/Emoji/Emoji.stories.js.map +1 -1
- package/dist/Icon/Container.d.ts +2 -1
- package/dist/Icon/Container.js +3 -0
- package/dist/Icon/Container.js.map +1 -1
- package/dist/Icon/Icon.d.ts +2 -3
- package/dist/Icon/Icon.js +2 -0
- package/dist/Icon/Icon.js.map +1 -1
- package/dist/Icon/Icon.stories.d.ts +8 -7
- package/dist/Icon/Icon.stories.js +2 -2
- package/dist/Icon/Icon.stories.js.map +1 -1
- package/dist/IconWrapper/IconWrapper.d.ts +2 -3
- package/dist/IconWrapper/IconWrapper.js.map +1 -1
- package/dist/IconWrapper/IconWrapper.stories.d.ts +12 -11
- package/dist/IconWrapper/IconWrapper.stories.js +1 -1
- package/dist/IconWrapper/IconWrapper.stories.js.map +1 -1
- package/dist/IconWrapper/__tests__/IconWrapper.js +2 -2
- package/dist/IconWrapper/__tests__/IconWrapper.js.map +1 -1
- package/dist/LabelledText/LabelledText.d.ts +2 -3
- package/dist/LabelledText/LabelledText.js.map +1 -1
- package/dist/LabelledText/LabelledText.stories.d.ts +7 -6
- package/dist/LabelledText/LabelledText.stories.js +1 -1
- package/dist/LabelledText/LabelledText.stories.js.map +1 -1
- package/dist/Loader/Loader.d.ts +2 -3
- package/dist/Loader/Loader.js.map +1 -1
- package/dist/Loader/Loader.stories.d.ts +8 -7
- package/dist/Loader/Loader.stories.js +2 -2
- package/dist/Loader/Loader.stories.js.map +1 -1
- package/dist/Message/Message.stories.d.ts +12 -11
- package/dist/Message/Message.stories.js +1 -1
- package/dist/Message/Message.stories.js.map +1 -1
- package/dist/Modal/Modal.d.ts +1 -2
- package/dist/Modal/Modal.js +8 -9
- package/dist/Modal/Modal.js.map +1 -1
- package/dist/Modal/Modal.stories.d.ts +14 -4
- package/dist/Modal/Modal.stories.js +32 -5
- package/dist/Modal/Modal.stories.js.map +1 -1
- package/dist/NumberInput/Container.d.ts +2 -1
- package/dist/NumberInput/Container.js +3 -1
- package/dist/NumberInput/Container.js.map +1 -1
- package/dist/NumberInput/NumberInput.d.ts +1 -2
- package/dist/NumberInput/NumberInput.stories.d.ts +20 -19
- package/dist/NumberInput/NumberInput.stories.js +11 -10
- package/dist/NumberInput/NumberInput.stories.js.map +1 -1
- package/dist/Pagination/Pagination.d.ts +1 -2
- package/dist/Pagination/Pagination.stories.d.ts +13 -12
- package/dist/Pagination/Pagination.stories.js +1 -1
- package/dist/Pagination/Pagination.stories.js.map +1 -1
- package/dist/RadioButton/Container.d.ts +2 -1
- package/dist/RadioButton/Container.js.map +1 -1
- package/dist/RadioButton/RadioButton.d.ts +1 -2
- package/dist/RadioButton/RadioButton.stories.d.ts +14 -13
- package/dist/RadioButton/RadioButton.stories.js +5 -4
- package/dist/RadioButton/RadioButton.stories.js.map +1 -1
- package/dist/Row/Row.d.ts +2 -2
- package/dist/Row/Row.js.map +1 -1
- package/dist/Row/Row.stories.d.ts +19 -18
- package/dist/Row/Row.stories.js +2 -2
- package/dist/Row/Row.stories.js.map +1 -1
- package/dist/SearchInput/SearchInput.stories.d.ts +9 -8
- package/dist/SearchInput/SearchInput.stories.js +1 -1
- package/dist/SearchInput/SearchInput.stories.js.map +1 -1
- package/dist/Tag/Tag.d.ts +1 -2
- package/dist/Tag/Tag.stories.d.ts +7 -6
- package/dist/Tag/Tag.stories.js +1 -1
- package/dist/Tag/Tag.stories.js.map +1 -1
- package/dist/Text/Text.d.ts +1 -1
- package/dist/Text/Text.stories.d.ts +9 -8
- package/dist/Text/Text.stories.js +1 -1
- package/dist/Text/Text.stories.js.map +1 -1
- package/dist/TextInput/Container.d.ts +2 -1
- package/dist/TextInput/Container.js.map +1 -1
- package/dist/TextInput/TextInput.d.ts +2 -2
- package/dist/TextInput/TextInput.js.map +1 -1
- package/dist/TextInput/TextInput.stories.d.ts +21 -20
- package/dist/TextInput/TextInput.stories.js +30 -29
- package/dist/TextInput/TextInput.stories.js.map +1 -1
- package/dist/Textarea/Container.d.ts +2 -1
- package/dist/Textarea/Container.js.map +1 -1
- package/dist/Textarea/Textarea.d.ts +3 -3
- package/dist/Textarea/Textarea.js.map +1 -1
- package/dist/Textarea/Textarea.stories.d.ts +10 -9
- package/dist/Textarea/Textarea.stories.js +6 -5
- package/dist/Textarea/Textarea.stories.js.map +1 -1
- package/dist/Toggle/Container.d.ts +2 -1
- package/dist/Toggle/Container.js +1 -1
- package/dist/Toggle/Container.js.map +1 -1
- package/dist/Toggle/Toggle.stories.d.ts +10 -6
- package/dist/Toggle/Toggle.stories.js +1 -1
- package/dist/Toggle/Toggle.stories.js.map +1 -1
- package/dist/colors.stories.d.ts +6 -6
- package/dist/colors.stories.js +5 -5
- package/dist/colors.stories.js.map +1 -1
- package/dist/utils/noop.d.ts +1 -0
- package/dist/utils/noop.js +3 -0
- package/dist/utils/noop.js.map +1 -0
- package/package.json +3 -3
- package/dist/ActionDropdown/__tests__/__snapshots__/ActionDropdown.js.snap +0 -167
- package/dist/Box/__tests__/__snapshots__/Box.js.snap +0 -20
- package/dist/Button/__tests__/__snapshots__/Button.js.snap +0 -46
- package/dist/Card/__tests__/__snapshots__/Card.js.snap +0 -24
- package/dist/CheckBox/__tests__/__snapshots__/CheckBox.js.snap +0 -20
- package/dist/Dropdown/__tests__/__snapshots__/Dropdown.js.snap +0 -167
- package/dist/Emoji/__tests__/__snapshots__/Emoji.js.snap +0 -20
- package/dist/Icon/__tests__/__snapshots__/Icon.js.snap +0 -47
- package/dist/IconWrapper/__tests__/__snapshots__/IconWrapper.js.snap +0 -121
- package/dist/LabelledText/__tests__/__snapshots__/LabelledText.js.snap +0 -57
- package/dist/Loader/__tests__/__snapshots__/Loader.js.snap +0 -53
- package/dist/Message/__tests__/__snapshots__/Message.js.snap +0 -279
- package/dist/Modal/__tests__/__snapshots__/Modal.js.snap +0 -208
- package/dist/NumberInput/__tests__/__snapshots__/NumberInput.js.snap +0 -1398
- package/dist/Pagination/__tests__/__snapshots__/Pagination.js.snap +0 -273
- package/dist/RadioButton/__tests__/__snapshots__/RadioButton.js.snap +0 -146
- package/dist/Row/__tests__/__snapshots__/Row.js.snap +0 -96
- package/dist/SearchInput/__tests__/__snapshots__/SearchInput.js.snap +0 -146
- package/dist/Tag/__tests__/__snapshots__/Tag.js.snap +0 -54
- package/dist/Text/__tests__/__snapshots__/Text.js.snap +0 -34
- package/dist/TextInput/__tests__/__snapshots__/TextInput.js.snap +0 -74
- package/dist/Textarea/__tests__/__snapshots__/Textarea.js.snap +0 -271
- package/dist/Toggle/__tests__/__snapshots__/Toggle.js.snap +0 -70
@@ -17,7 +17,7 @@ export const Accordion = ({ title, children, borderTop = false, subTitle, fullBo
|
|
17
17
|
const Wrapper = styled(Box)(({ borderTop, fullBorder }) => css `
|
18
18
|
border-bottom: 1px solid ${theme.colors.outline};
|
19
19
|
padding: 16px 0;
|
20
|
-
border-top: ${borderTop && `1px solid ${theme.colors.
|
20
|
+
border-top: ${borderTop && `1px solid ${theme.colors.outline}`};
|
21
21
|
|
22
22
|
${fullBorder &&
|
23
23
|
css `
|
@@ -1,9 +1,10 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
1
|
+
import React from 'react';
|
2
|
+
import { AccordionProps } from './Accordion';
|
3
|
+
declare const _default: {
|
4
|
+
title: string;
|
5
|
+
component: React.FC<AccordionProps>;
|
6
|
+
};
|
5
7
|
export default _default;
|
6
|
-
export const Default: any;
|
7
|
-
export const SubTitle: any;
|
8
|
-
export const FullBorder: any;
|
9
|
-
import { Accordion } from "./Accordion";
|
8
|
+
export declare const Default: any;
|
9
|
+
export declare const SubTitle: any;
|
10
|
+
export declare const FullBorder: any;
|
@@ -4,7 +4,7 @@ export default {
|
|
4
4
|
title: 'Accordion',
|
5
5
|
component: Accordion,
|
6
6
|
};
|
7
|
-
const Template = (
|
7
|
+
const Template = (props) => (React.createElement(Accordion, Object.assign({}, props, { title: "How it works" }), "Lots of brilliant information about this beautiful component"));
|
8
8
|
export const Default = Template.bind({});
|
9
9
|
export const SubTitle = Template.bind({});
|
10
10
|
SubTitle.args = {
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"Accordion.stories.js","sourceRoot":"","sources":["../../src/Accordion/Accordion.stories.
|
1
|
+
{"version":3,"file":"Accordion.stories.js","sourceRoot":"","sources":["../../src/Accordion/Accordion.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,EAAE,SAAS,EAAkB,MAAM,aAAa,CAAA;AAEvD,eAAe;IACb,KAAK,EAAE,WAAW;IAClB,SAAS,EAAE,SAAS;CACrB,CAAA;AAED,MAAM,QAAQ,GAAG,CAAC,KAAqB,EAAE,EAAE,CAAC,CAC1C,oBAAC,SAAS,oBAAK,KAAK,IAAE,KAAK,EAAC,cAAc,oEAE9B,CACb,CAAA;AAED,MAAM,CAAC,MAAM,OAAO,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;AAExC,MAAM,CAAC,MAAM,QAAQ,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;AAEzC,QAAQ,CAAC,IAAI,GAAG;IACd,QAAQ,EAAE,UAAU;CACrB,CAAA;AAED,MAAM,CAAC,MAAM,UAAU,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;AAE3C,UAAU,CAAC,IAAI,GAAG;IAChB,UAAU,EAAE,IAAI;CACjB,CAAA"}
|
@@ -1,7 +1,14 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
1
|
+
import React from 'react';
|
2
|
+
declare const _default: {
|
3
|
+
title: string;
|
4
|
+
component: React.FC<{
|
5
|
+
id: string;
|
6
|
+
className?: string | undefined;
|
7
|
+
label?: string | undefined;
|
8
|
+
value: import("./List").ActionListItem;
|
9
|
+
list: import("./List").ActionListItem[];
|
10
|
+
onSelect: (action: import("./List").ActionListItem) => void;
|
11
|
+
}>;
|
12
|
+
};
|
5
13
|
export default _default;
|
6
|
-
export const Default: any;
|
7
|
-
import { ActionDropdown } from "./ActionDropdown";
|
14
|
+
export declare const Default: any;
|
@@ -5,7 +5,7 @@ export default {
|
|
5
5
|
title: 'Action Dropdown',
|
6
6
|
component: ActionDropdown,
|
7
7
|
};
|
8
|
-
const Template = (
|
8
|
+
const Template = () => React.createElement(ActionDropdownContainer, null);
|
9
9
|
export const Default = Template.bind({});
|
10
10
|
Default.args = {
|
11
11
|
textColor: 'secondary',
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"ActionDropdown.stories.js","sourceRoot":"","sources":["../../src/ActionDropdown/ActionDropdown.stories.
|
1
|
+
{"version":3,"file":"ActionDropdown.stories.js","sourceRoot":"","sources":["../../src/ActionDropdown/ActionDropdown.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAA;AACjD,OAAO,EAAE,SAAS,IAAI,uBAAuB,EAAE,MAAM,aAAa,CAAA;AAElE,eAAe;IACb,KAAK,EAAE,iBAAiB;IACxB,SAAS,EAAE,cAAc;CAC1B,CAAA;AAED,MAAM,QAAQ,GAAG,GAAG,EAAE,CAAC,oBAAC,uBAAuB,OAAG,CAAA;AAElD,MAAM,CAAC,MAAM,OAAO,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;AAExC,OAAO,CAAC,IAAI,GAAG;IACb,SAAS,EAAE,WAAW;CACvB,CAAA"}
|
@@ -1 +1,2 @@
|
|
1
|
-
|
1
|
+
/// <reference types="react" />
|
2
|
+
export declare const Container: () => JSX.Element;
|
@@ -37,7 +37,9 @@ const actions = [
|
|
37
37
|
export const Container = () => {
|
38
38
|
const [selectedAction, setSelectedAction] = useState(actions[0]);
|
39
39
|
return (React.createElement(Box, { flex: true, alignItems: "center" },
|
40
|
-
React.createElement(ActionDropdown, { id: "statusActions", list: actions, value: selectedAction,
|
40
|
+
React.createElement(ActionDropdown, { id: "statusActions", list: actions, value: selectedAction,
|
41
|
+
// @ts-expect-error onSelect type is too broad and should be with generic type
|
42
|
+
onSelect: setSelectedAction }),
|
41
43
|
React.createElement(Box, { mr: "16px" }),
|
42
44
|
React.createElement(Box, null,
|
43
45
|
React.createElement(Text, { tag: "p", typo: "base-small" }, selectedAction.label))));
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"Container.js","sourceRoot":"","sources":["../../src/ActionDropdown/Container.
|
1
|
+
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E,EAAC,MAAM,GAAG;QAEjB,oBAAC,GAAG;YACF,oBAAC,IAAI,IAAC,GAAG,EAAC,GAAG,EAAC,IAAI,EAAC,YAAY,IAC5B,cAAc,CAAC,KAAK,CAChB,CACH,CACF,CACP,CAAA;AACH,CAAC,CAAA"}
|
package/dist/Box/Box.d.ts
CHANGED
@@ -1,7 +1,5 @@
|
|
1
1
|
import { FlexProps } from '../utils/flex';
|
2
2
|
import { MeasureProps } from '../utils/measure';
|
3
3
|
import { SpaceProps } from '../utils/space';
|
4
|
-
|
5
|
-
|
6
|
-
export declare const Box: import("styled-components").StyledComponent<"div", any, IBox, never>;
|
7
|
-
export {};
|
4
|
+
export declare type BoxProps = SpaceProps & FlexProps & MeasureProps;
|
5
|
+
export declare const Box: import("styled-components").StyledComponent<"div", any, SpaceProps & FlexProps & MeasureProps, never>;
|
package/dist/Box/Box.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"Box.js","sourceRoot":"","sources":["../../src/Box/Box.tsx"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,mBAAmB,CAAA;AAEtC,OAAO,EAAE,IAAI,EAAa,MAAM,eAAe,CAAA;AAC/C,OAAO,EAAE,OAAO,EAAgB,MAAM,kBAAkB,CAAA;AACxD,OAAO,EAAE,KAAK,EAAc,MAAM,gBAAgB,CAAA;AAIlD,MAAM,CAAC,MAAM,GAAG,GAAG,MAAM,CAAC,GAAG,
|
1
|
+
{"version":3,"file":"Box.js","sourceRoot":"","sources":["../../src/Box/Box.tsx"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,mBAAmB,CAAA;AAEtC,OAAO,EAAE,IAAI,EAAa,MAAM,eAAe,CAAA;AAC/C,OAAO,EAAE,OAAO,EAAgB,MAAM,kBAAkB,CAAA;AACxD,OAAO,EAAE,KAAK,EAAc,MAAM,gBAAgB,CAAA;AAIlD,MAAM,CAAC,MAAM,GAAG,GAAG,MAAM,CAAC,GAAG,CAAU;IACnC,KAAK;IACL,IAAI;IACJ,OAAO;CACV,CAAA"}
|
@@ -1,7 +1,6 @@
|
|
1
|
-
declare
|
2
|
-
|
3
|
-
|
4
|
-
}
|
1
|
+
declare const _default: {
|
2
|
+
title: string;
|
3
|
+
component: import("styled-components").StyledComponent<"div", any, import("../utils/space").SpaceProps & import("../utils/flex").FlexProps & import("../utils/measure").MeasureProps, never>;
|
4
|
+
};
|
5
5
|
export default _default;
|
6
|
-
export const Default: any;
|
7
|
-
import { Box } from "./Box";
|
6
|
+
export declare const Default: any;
|
package/dist/Box/Box.stories.js
CHANGED
@@ -4,7 +4,7 @@ export default {
|
|
4
4
|
title: 'Box',
|
5
5
|
component: Box,
|
6
6
|
};
|
7
|
-
const Template = (
|
7
|
+
const Template = (props) => React.createElement(Box, Object.assign({}, props), "Some lovely content.");
|
8
8
|
export const Default = Template.bind({});
|
9
9
|
Default.args = {
|
10
10
|
flex: true,
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"Box.stories.js","sourceRoot":"","sources":["../../src/Box/Box.stories.
|
1
|
+
{"version":3,"file":"Box.stories.js","sourceRoot":"","sources":["../../src/Box/Box.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,EAAE,GAAG,EAAY,MAAM,OAAO,CAAA;AAErC,eAAe;IACb,KAAK,EAAE,KAAK;IACZ,SAAS,EAAE,GAAG;CACf,CAAA;AAED,MAAM,QAAQ,GAAG,CAAC,KAAe,EAAE,EAAE,CAAC,oBAAC,GAAG,oBAAK,KAAK,0BAA4B,CAAA;AAEhF,MAAM,CAAC,MAAM,OAAO,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;AAExC,OAAO,CAAC,IAAI,GAAG;IACb,IAAI,EAAE,IAAI;IACV,SAAS,EAAE,KAAK;IAChB,cAAc,EAAE,YAAY;IAC5B,UAAU,EAAE,aAAa;IACzB,CAAC,EAAE,MAAM;IACT,CAAC,EAAE,MAAM;CACV,CAAA;AAED,OAAO,CAAC,QAAQ,GAAG;IACjB,KAAK,EAAE,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,IAAI,EAAE,EAAE;IACnC,EAAE,EAAE,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,IAAI,EAAE,EAAE;IAChC,WAAW,EAAE,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,IAAI,EAAE,EAAE;CAC1C,CAAA"}
|
package/dist/Button/Button.d.ts
CHANGED
@@ -18,6 +18,6 @@ declare type Props = {
|
|
18
18
|
form?: string;
|
19
19
|
type?: 'button' | 'submit' | 'reset';
|
20
20
|
};
|
21
|
-
declare type ButtonProps = Props & ButtonHTMLAttributes<HTMLButtonElement>;
|
21
|
+
export declare type ButtonProps = Props & ButtonHTMLAttributes<HTMLButtonElement>;
|
22
22
|
export declare const Button: FC<ButtonProps>;
|
23
23
|
export {};
|
@@ -1,23 +1,16 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
}
|
1
|
+
import React from 'react';
|
2
|
+
import { ButtonProps } from './Button';
|
3
|
+
declare const _default: {
|
4
|
+
title: string;
|
5
|
+
component: React.FC<ButtonProps>;
|
6
|
+
argTypes: {
|
7
|
+
handleClick: {
|
8
|
+
action: string;
|
9
|
+
};
|
10
|
+
};
|
11
|
+
};
|
10
12
|
export default _default;
|
11
|
-
export const
|
12
|
-
export const
|
13
|
-
export const
|
14
|
-
export const
|
15
|
-
export const PrimaryForcedWidth: any;
|
16
|
-
export const Secondary: any;
|
17
|
-
export const SecondaryDisabled: any;
|
18
|
-
export const SecondaryLoading: any;
|
19
|
-
export const Tertiary: any;
|
20
|
-
export const TertiaryDisabled: any;
|
21
|
-
export const TertiaryLoading: any;
|
22
|
-
export const Icon: any;
|
23
|
-
import { Button } from "./Button";
|
13
|
+
export declare const Playground: any;
|
14
|
+
export declare const Interactive: any;
|
15
|
+
export declare const Collection: any;
|
16
|
+
export declare const ForcedWidth: any;
|
@@ -1,67 +1,28 @@
|
|
1
1
|
import React from 'react';
|
2
2
|
import { Button } from './Button';
|
3
3
|
import { InteractivePlayground } from './InteractivePlayground';
|
4
|
+
import { CollectionPage } from './Collection';
|
4
5
|
export default {
|
5
6
|
title: 'Button',
|
6
7
|
component: Button,
|
7
8
|
argTypes: { handleClick: { action: 'clicked' } },
|
8
9
|
};
|
9
|
-
const Template = (
|
10
|
-
const InteractivePlaygroundTemplate = (
|
11
|
-
export const
|
12
|
-
|
13
|
-
Primary.args = {
|
14
|
-
primary: true,
|
15
|
-
'data-testid': 'test',
|
16
|
-
'aria-label': 'primary-button',
|
17
|
-
};
|
18
|
-
export const PrimaryDisabled = Template.bind({});
|
19
|
-
PrimaryDisabled.args = {
|
10
|
+
const Template = (props) => React.createElement(Button, Object.assign({}, props), "Get started");
|
11
|
+
const InteractivePlaygroundTemplate = (props) => (React.createElement(InteractivePlayground, Object.assign({}, props)));
|
12
|
+
export const Playground = Template.bind({});
|
13
|
+
Playground.args = {
|
20
14
|
primary: true,
|
21
|
-
|
22
|
-
|
15
|
+
secondary: false,
|
16
|
+
tertiary: false,
|
17
|
+
disabled: false,
|
18
|
+
loading: false,
|
19
|
+
icon: '',
|
23
20
|
};
|
24
|
-
export const
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
};
|
29
|
-
export const PrimaryForcedWidth = Template.bind({});
|
30
|
-
PrimaryForcedWidth.args = {
|
21
|
+
export const Interactive = InteractivePlaygroundTemplate.bind({});
|
22
|
+
export const Collection = CollectionPage.bind({});
|
23
|
+
export const ForcedWidth = Template.bind({});
|
24
|
+
ForcedWidth.args = {
|
31
25
|
primary: true,
|
32
26
|
forcedWidth: '300px',
|
33
27
|
};
|
34
|
-
export const Secondary = Template.bind({});
|
35
|
-
Secondary.args = {
|
36
|
-
secondary: true,
|
37
|
-
};
|
38
|
-
export const SecondaryDisabled = Template.bind({});
|
39
|
-
SecondaryDisabled.args = {
|
40
|
-
secondary: true,
|
41
|
-
disabled: true,
|
42
|
-
};
|
43
|
-
export const SecondaryLoading = Template.bind({});
|
44
|
-
SecondaryLoading.args = {
|
45
|
-
secondary: true,
|
46
|
-
loading: true,
|
47
|
-
};
|
48
|
-
export const Tertiary = Template.bind({});
|
49
|
-
Tertiary.args = {
|
50
|
-
tertiary: true,
|
51
|
-
};
|
52
|
-
export const TertiaryDisabled = Template.bind({});
|
53
|
-
TertiaryDisabled.args = {
|
54
|
-
tertiary: true,
|
55
|
-
disabled: true,
|
56
|
-
};
|
57
|
-
export const TertiaryLoading = Template.bind({});
|
58
|
-
TertiaryLoading.args = {
|
59
|
-
tertiary: true,
|
60
|
-
loading: true,
|
61
|
-
};
|
62
|
-
export const Icon = Template.bind({});
|
63
|
-
Icon.args = {
|
64
|
-
primary: true,
|
65
|
-
icon: 'info',
|
66
|
-
};
|
67
28
|
//# sourceMappingURL=Button.stories.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"Button.stories.js","sourceRoot":"","sources":["../../src/Button/Button.stories.
|
1
|
+
{"version":3,"file":"Button.stories.js","sourceRoot":"","sources":["../../src/Button/Button.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,OAAO,EAAE,MAAM,EAAe,MAAM,UAAU,CAAA;AAC9C,OAAO,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAA;AAC/D,OAAO,EAAE,cAAc,EAAE,MAAM,cAAc,CAAA;AAE7C,eAAe;IACb,KAAK,EAAE,QAAQ;IACf,SAAS,EAAE,MAAM;IACjB,QAAQ,EAAE,EAAE,WAAW,EAAE,EAAE,MAAM,EAAE,SAAS,EAAE,EAAE;CACjD,CAAA;AAED,MAAM,QAAQ,GAAG,CAAC,KAAkB,EAAE,EAAE,CAAC,oBAAC,MAAM,oBAAK,KAAK,iBAAsB,CAAA;AAEhF,MAAM,6BAA6B,GAAG,CAAC,KAAkB,EAAE,EAAE,CAAC,CAC5D,oBAAC,qBAAqB,oBAAK,KAAK,EAAI,CACrC,CAAA;AAED,MAAM,CAAC,MAAM,UAAU,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;AAE3C,UAAU,CAAC,IAAI,GAAG;IAChB,OAAO,EAAE,IAAI;IACb,SAAS,EAAE,KAAK;IAChB,QAAQ,EAAE,KAAK;IACf,QAAQ,EAAE,KAAK;IACf,OAAO,EAAE,KAAK;IACd,IAAI,EAAE,EAAE;CACT,CAAA;AAED,MAAM,CAAC,MAAM,WAAW,GAAG,6BAA6B,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;AACjE,MAAM,CAAC,MAAM,UAAU,GAAG,cAAc,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;AAEjD,MAAM,CAAC,MAAM,WAAW,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;AAE5C,WAAW,CAAC,IAAI,GAAG;IACjB,OAAO,EAAE,IAAI;IACb,WAAW,EAAE,OAAO;CACrB,CAAA"}
|
@@ -0,0 +1,51 @@
|
|
1
|
+
import React from 'react';
|
2
|
+
import styled from 'styled-components';
|
3
|
+
import { Text } from '../Text';
|
4
|
+
import { Box } from '../Box';
|
5
|
+
import { Button } from './Button';
|
6
|
+
const buttonList = [
|
7
|
+
{ primary: true, children: 'Save' },
|
8
|
+
{ secondary: true, children: 'Edit' },
|
9
|
+
{ tertiary: true, children: 'Cancel' },
|
10
|
+
];
|
11
|
+
export const CollectionPage = () => {
|
12
|
+
return (React.createElement(Wrapper, null,
|
13
|
+
React.createElement(Section, { label: "Default" },
|
14
|
+
React.createElement(Row, { label: "Default" }, buttonList.map((props, index) => (React.createElement(Button, Object.assign({ key: index }, props))))),
|
15
|
+
React.createElement(Row, { label: "Loading" }, buttonList.map((props, index) => (React.createElement(Button, Object.assign({ key: index }, props, { loading: true }))))),
|
16
|
+
React.createElement(Row, { label: "Disabled" }, buttonList.map((props, index) => (React.createElement(Button, Object.assign({ key: index }, props, { disabled: true })))))),
|
17
|
+
React.createElement(Section, { label: "With icon" },
|
18
|
+
React.createElement(Row, { label: "Default" }, buttonList.map((props, index) => (React.createElement(Button, Object.assign({ key: index }, props, { icon: "info" }))))),
|
19
|
+
React.createElement(Row, { label: "Loading" }, buttonList.map((props, index) => (React.createElement(Button, Object.assign({ key: index }, props, { loading: true, icon: "info" }))))),
|
20
|
+
React.createElement(Row, { label: "Disabled" }, buttonList.map((props, index) => (React.createElement(Button, Object.assign({ key: index }, props, { disabled: true, icon: "info" }))))))));
|
21
|
+
};
|
22
|
+
const Wrapper = styled(Box) `
|
23
|
+
display: flex;
|
24
|
+
flex-direction: column;
|
25
|
+
align-items: flex-start;
|
26
|
+
gap: 40px;
|
27
|
+
`;
|
28
|
+
const Section = ({ label, children, }) => {
|
29
|
+
return (React.createElement(Box, null,
|
30
|
+
React.createElement(Box, { mb: "16px" },
|
31
|
+
React.createElement(Text, { tag: "span", typo: "header-small" }, label)),
|
32
|
+
React.createElement(Column, null, children)));
|
33
|
+
};
|
34
|
+
const Column = styled(Box) `
|
35
|
+
display: flex;
|
36
|
+
flex-direction: column;
|
37
|
+
gap: 16px;
|
38
|
+
`;
|
39
|
+
const Row = ({ label, children, }) => {
|
40
|
+
return (React.createElement(RowWrapper, null,
|
41
|
+
React.createElement(Box, { width: "80px" },
|
42
|
+
React.createElement(Text, { tag: "span", typo: "label-large" }, label)),
|
43
|
+
children));
|
44
|
+
};
|
45
|
+
const RowWrapper = styled(Box) `
|
46
|
+
display: flex;
|
47
|
+
flex-direction: row;
|
48
|
+
align-items: center;
|
49
|
+
gap: 16px;
|
50
|
+
`;
|
51
|
+
//# sourceMappingURL=Collection.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"Collection.js","sourceRoot":"","sources":["../../src/Button/Collection.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAwB,MAAM,OAAO,CAAA;AAC5C,OAAO,MAAM,MAAM,mBAAmB,CAAA;AAEtC,OAAO,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,GAAG,EAAC,MAAM,EAAC,IAAI,EAAC,aAAa,IAChC,KAAK,CACD,CACH;QACL,QAAQ,CACE,CACd,CAAA;AACH,CAAC,CAAA;AAED,MAAM,UAAU,GAAG,MAAM,CAAC,GAAG,CAAC,CAAA;;;;;CAK7B,CAAA"}
|
package/dist/Card/Card.d.ts
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
import { FC, ReactNode } from 'react';
|
2
|
-
declare type
|
2
|
+
export declare type CardProps = {
|
3
3
|
children: ReactNode;
|
4
4
|
className?: string;
|
5
5
|
/** margin */
|
@@ -13,5 +13,4 @@ declare type Props = {
|
|
13
13
|
/** Wide padding */
|
14
14
|
wide?: boolean;
|
15
15
|
};
|
16
|
-
export declare const Card: FC<
|
17
|
-
export {};
|
16
|
+
export declare const Card: FC<CardProps>;
|
package/dist/Card/Card.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"Card.js","sourceRoot":"","sources":["../../src/Card/Card.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAwB,MAAM,OAAO,CAAA;AAC5C,OAAO,MAAM,MAAM,mBAAmB,CAAA;AACtC,OAAO,EAAE,KAAK,EAAE,MAAM,UAAU,CAAA;AAyBhC,MAAM,CAAC,MAAM,IAAI,
|
1
|
+
{"version":3,"file":"Card.js","sourceRoot":"","sources":["../../src/Card/Card.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAwB,MAAM,OAAO,CAAA;AAC5C,OAAO,MAAM,MAAM,mBAAmB,CAAA;AACtC,OAAO,EAAE,KAAK,EAAE,MAAM,UAAU,CAAA;AAyBhC,MAAM,CAAC,MAAM,IAAI,GAAkB,CAAC,EAClC,QAAQ,EACR,SAAS,GAAG,EAAE,EACd,QAAQ,GAAG,EAAE,EACb,OAAO,GAAG,EAAE,EACZ,OAAO,GAAG,EAAE,EACZ,MAAM,GAAG,KAAK,EACd,IAAI,GAAG,KAAK,GACb,EAAE,EAAE,CAAC,CACJ,oBAAC,SAAS,IACR,SAAS,EAAE,SAAS,EACpB,QAAQ,EAAE,QAAQ,EAClB,OAAO,EAAE,OAAO,EAChB,OAAO,EAAE,OAAO,EAChB,MAAM,EAAE,MAAM,EACd,IAAI,EAAE,IAAI,IAET,QAAQ,CACC,CACb,CAAA;AAED,MAAM,SAAS,GAAG,MAAM,CAAC,GAAG,CAAO;gBACnB,KAAK,CAAC,MAAM,CAAC,KAAK;sBACZ,KAAK,CAAC,MAAM,CAAC,OAAO;;;;;eAK3B,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,QAAQ;gBAChB,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,OAAO;kBACd,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,OAAO;mBACf,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,OAAO;iBAClB,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,OAAO;;aAEpB,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC;;;eAGnD,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC;;CAEnE,CAAA"}
|
@@ -1,11 +1,12 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
1
|
+
import React from 'react';
|
2
|
+
import { CardProps } from './Card';
|
3
|
+
declare const _default: {
|
4
|
+
title: string;
|
5
|
+
component: React.FC<CardProps>;
|
6
|
+
};
|
5
7
|
export default _default;
|
6
|
-
export const Default: any;
|
7
|
-
export const MaxWidth: any;
|
8
|
-
export const NarrowPadding: any;
|
9
|
-
export const WidePadding: any;
|
10
|
-
export const Margins: any;
|
11
|
-
import { Card } from "../Card";
|
8
|
+
export declare const Default: any;
|
9
|
+
export declare const MaxWidth: any;
|
10
|
+
export declare const NarrowPadding: any;
|
11
|
+
export declare const WidePadding: any;
|
12
|
+
export declare const Margins: any;
|
@@ -1,11 +1,11 @@
|
|
1
1
|
import React from 'react';
|
2
|
-
import { Card } from '
|
2
|
+
import { Card } from './Card';
|
3
3
|
import { Text } from '../Text';
|
4
4
|
export default {
|
5
5
|
title: 'Card',
|
6
6
|
component: Card,
|
7
7
|
};
|
8
|
-
const Template = (
|
8
|
+
const Template = (props) => (React.createElement(Card, Object.assign({}, props),
|
9
9
|
React.createElement(Text, { tag: "h1" }, "Card with default padding")));
|
10
10
|
export const Default = Template.bind({});
|
11
11
|
export const MaxWidth = Template.bind({});
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"Card.stories.js","sourceRoot":"","sources":["../../src/Card/Card.stories.
|
1
|
+
{"version":3,"file":"Card.stories.js","sourceRoot":"","sources":["../../src/Card/Card.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,EAAE,IAAI,EAAa,MAAM,QAAQ,CAAA;AACxC,OAAO,EAAE,IAAI,EAAE,MAAM,SAAS,CAAA;AAE9B,eAAe;IACb,KAAK,EAAE,MAAM;IACb,SAAS,EAAE,IAAI;CAChB,CAAA;AAED,MAAM,QAAQ,GAAG,CAAC,KAAgB,EAAE,EAAE,CAAC,CACrC,oBAAC,IAAI,oBAAK,KAAK;IACb,oBAAC,IAAI,IAAC,GAAG,EAAC,IAAI,gCAAiC,CAC1C,CACR,CAAA;AAED,MAAM,CAAC,MAAM,OAAO,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;AAExC,MAAM,CAAC,MAAM,QAAQ,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;AAEzC,QAAQ,CAAC,IAAI,GAAG;IACd,QAAQ,EAAE,OAAO;CAClB,CAAA;AAED,MAAM,CAAC,MAAM,aAAa,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;AAE9C,aAAa,CAAC,IAAI,GAAG;IACnB,MAAM,EAAE,IAAI;CACb,CAAA;AAED,MAAM,CAAC,MAAM,WAAW,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;AAE5C,WAAW,CAAC,IAAI,GAAG;IACjB,IAAI,EAAE,IAAI;CACX,CAAA;AAED,MAAM,CAAC,MAAM,OAAO,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;AAExC,OAAO,CAAC,IAAI,GAAG;IACb,OAAO,EAAE,MAAM;IACf,OAAO,EAAE,MAAM;CAChB,CAAA"}
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { FC, ReactNode } from 'react';
|
2
|
-
declare type
|
2
|
+
export declare type CheckBoxProps = {
|
3
3
|
id: string;
|
4
4
|
checked: boolean;
|
5
5
|
children: ReactNode;
|
@@ -7,5 +7,4 @@ declare type Props = {
|
|
7
7
|
error?: boolean;
|
8
8
|
errorMsg?: string;
|
9
9
|
};
|
10
|
-
export declare const CheckBox: FC<
|
11
|
-
export {};
|
10
|
+
export declare const CheckBox: FC<CheckBoxProps>;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"CheckBox.js","sourceRoot":"","sources":["../../src/CheckBox/CheckBox.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAwB,MAAM,OAAO,CAAA;AAC5C,OAAO,MAAM,MAAM,mBAAmB,CAAA;AAEtC,OAAO,EAAE,IAAI,EAAE,MAAM,SAAS,CAAA;AAC9B,OAAO,EAAE,KAAK,EAAE,MAAM,UAAU,CAAA;AAWhC,MAAM,CAAC,MAAM,QAAQ,
|
1
|
+
{"version":3,"file":"CheckBox.js","sourceRoot":"","sources":["../../src/CheckBox/CheckBox.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAwB,MAAM,OAAO,CAAA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;;;;CAO/C,CAAA;AAED,MAAM,QAAQ,GAAG,MAAM,CAAC,IAAI,CAAA;;;WAGjB,KAAK,CAAC,MAAM,CAAC,KAAK;CAC5B,CAAA"}
|
@@ -1,9 +1,10 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
1
|
+
import React from 'react';
|
2
|
+
import { CheckBoxProps } from './CheckBox';
|
3
|
+
declare const _default: {
|
4
|
+
title: string;
|
5
|
+
component: React.FC<CheckBoxProps>;
|
6
|
+
};
|
5
7
|
export default _default;
|
6
|
-
export const Default: any;
|
7
|
-
export const WithError: any;
|
8
|
-
export const WithErrorLabel: any;
|
9
|
-
import { CheckBox } from "./CheckBox";
|
8
|
+
export declare const Default: any;
|
9
|
+
export declare const WithError: any;
|
10
|
+
export declare const WithErrorLabel: any;
|
@@ -5,9 +5,9 @@ export default {
|
|
5
5
|
title: 'Checkbox',
|
6
6
|
component: CheckBox,
|
7
7
|
};
|
8
|
-
const ContainerTemplate = (
|
8
|
+
const ContainerTemplate = () => React.createElement(CheckBoxContainer, null);
|
9
9
|
export const Default = ContainerTemplate.bind({});
|
10
|
-
const Template = (
|
10
|
+
const Template = (props) => React.createElement(CheckBox, Object.assign({}, props));
|
11
11
|
export const WithError = Template.bind({});
|
12
12
|
WithError.args = {
|
13
13
|
children: 'I disagree',
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"CheckBox.stories.js","sourceRoot":"","sources":["../../src/CheckBox/CheckBox.stories.
|
1
|
+
{"version":3,"file":"CheckBox.stories.js","sourceRoot":"","sources":["../../src/CheckBox/CheckBox.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,EAAE,QAAQ,EAAiB,MAAM,YAAY,CAAA;AACpD,OAAO,EAAE,SAAS,IAAI,iBAAiB,EAAE,MAAM,aAAa,CAAA;AAE5D,eAAe;IACb,KAAK,EAAE,UAAU;IACjB,SAAS,EAAE,QAAQ;CACpB,CAAA;AAED,MAAM,iBAAiB,GAAG,GAAG,EAAE,CAAC,oBAAC,iBAAiB,OAAG,CAAA;AAErD,MAAM,CAAC,MAAM,OAAO,GAAG,iBAAiB,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;AAEjD,MAAM,QAAQ,GAAG,CAAC,KAAoB,EAAE,EAAE,CAAC,oBAAC,QAAQ,oBAAK,KAAK,EAAI,CAAA;AAElE,MAAM,CAAC,MAAM,SAAS,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;AAE1C,SAAS,CAAC,IAAI,GAAG;IACf,QAAQ,EAAE,YAAY;IACtB,KAAK,EAAE,IAAI;CACZ,CAAA;AAED,MAAM,CAAC,MAAM,cAAc,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;AAE/C,cAAc,CAAC,IAAI,GAAG;IACpB,QAAQ,EAAE,YAAY;IACtB,KAAK,EAAE,IAAI;IACX,QAAQ,EAAE,0BAA0B;CACrC,CAAA"}
|
@@ -1 +1,2 @@
|
|
1
|
-
|
1
|
+
/// <reference types="react" />
|
2
|
+
export declare const Container: () => JSX.Element;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"Container.js","sourceRoot":"","sources":["../../src/CheckBox/Container.
|
1
|
+
{"version":3,"file":"Container.js","sourceRoot":"","sources":["../../src/CheckBox/Container.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AACvC,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAA;AAErC,MAAM,CAAC,MAAM,SAAS,GAAG,GAAG,EAAE;IAC5B,MAAM,CAAC,OAAO,EAAE,UAAU,CAAC,GAAG,QAAQ,CAAC,KAAK,CAAC,CAAA;IAE7C,OAAO,CACL,oBAAC,QAAQ,IACP,EAAE,EAAC,WAAW,EACd,OAAO,EAAE,OAAO,EAChB,MAAM,EAAE,GAAG,EAAE,CAAC,UAAU,CAAC,CAAC,OAAO,CAAC,cAGzB,CACZ,CAAA;AACH,CAAC,CAAA"}
|
@@ -1,7 +1,14 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
1
|
+
import React from 'react';
|
2
|
+
declare const _default: {
|
3
|
+
title: string;
|
4
|
+
component: React.FC<{
|
5
|
+
list: {
|
6
|
+
id: number;
|
7
|
+
label: string;
|
8
|
+
checked: boolean;
|
9
|
+
}[];
|
10
|
+
onToggle: (id: number) => void;
|
11
|
+
}>;
|
12
|
+
};
|
5
13
|
export default _default;
|
6
|
-
export const Default: any;
|
7
|
-
import { CheckBoxGroup } from "./CheckBoxGroup";
|
14
|
+
export declare const Default: any;
|
@@ -35,6 +35,6 @@ export default {
|
|
35
35
|
title: 'Checkbox Group',
|
36
36
|
component: CheckBoxGroup,
|
37
37
|
};
|
38
|
-
const Template = (
|
38
|
+
const Template = () => React.createElement(Group, null);
|
39
39
|
export const Default = Template.bind({});
|
40
40
|
//# sourceMappingURL=CheckBoxGroup.stories.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"CheckBoxGroup.stories.js","sourceRoot":"","sources":["../../src/CheckBoxGroup/CheckBoxGroup.stories.
|
1
|
+
{"version":3,"file":"CheckBoxGroup.stories.js","sourceRoot":"","sources":["../../src/CheckBoxGroup/CheckBoxGroup.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AACvC,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAA;AAE/C,MAAM,OAAO,GAAG;IACd;QACE,EAAE,EAAE,CAAC;QACL,KAAK,EAAE,QAAQ;QACf,OAAO,EAAE,KAAK;KACf;IACD;QACE,EAAE,EAAE,CAAC;QACL,KAAK,EAAE,SAAS;QAChB,OAAO,EAAE,KAAK;KACf;IACD;QACE,EAAE,EAAE,CAAC;QACL,KAAK,EAAE,QAAQ;QACf,OAAO,EAAE,KAAK;KACf;IACD;QACE,EAAE,EAAE,CAAC;QACL,KAAK,EAAE,SAAS;QAChB,OAAO,EAAE,KAAK;KACf;CACF,CAAA;AAED,MAAM,KAAK,GAAG,GAAG,EAAE;IACjB,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,GAAG,QAAQ,CAAC,OAAO,CAAC,CAAA;IAEzC,MAAM,WAAW,GAAG,CAAC,EAAU,EAAE,EAAE;QACjC,MAAM,OAAO,GAAG,CAAC,GAAG,IAAI,CAAC,CAAA;QACzB,OAAO,CAAC,EAAE,CAAC,CAAC,OAAO,GAAG,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,OAAO,CAAA;QAEvC,OAAO,CAAC,OAAO,CAAC,CAAA;IAClB,CAAC,CAAA;IAED,OAAO,oBAAC,aAAa,IAAC,IAAI,EAAE,IAAI,EAAE,QAAQ,EAAE,WAAW,GAAI,CAAA;AAC7D,CAAC,CAAA;AAED,eAAe;IACb,KAAK,EAAE,gBAAgB;IACvB,SAAS,EAAE,aAAa;CACzB,CAAA;AAED,MAAM,QAAQ,GAAG,GAAG,EAAE,CAAC,oBAAC,KAAK,OAAG,CAAA;AAEhC,MAAM,CAAC,MAAM,OAAO,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA"}
|
package/dist/Chip/Chip.d.ts
CHANGED
@@ -8,6 +8,6 @@ declare type Props = {
|
|
8
8
|
disabled?: boolean;
|
9
9
|
loading?: boolean;
|
10
10
|
};
|
11
|
-
declare type ChipProps = Props & ButtonHTMLAttributes<HTMLButtonElement>;
|
11
|
+
export declare type ChipProps = Props & ButtonHTMLAttributes<HTMLButtonElement>;
|
12
12
|
export declare const Chip: FC<ChipProps>;
|
13
13
|
export {};
|
@@ -1,15 +1,16 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
}
|
1
|
+
import React from 'react';
|
2
|
+
import { ChipProps } from './Chip';
|
3
|
+
declare const _default: {
|
4
|
+
title: string;
|
5
|
+
component: React.FC<ChipProps>;
|
6
|
+
argTypes: {
|
7
|
+
handleClick: {
|
8
|
+
action: string;
|
9
|
+
};
|
10
|
+
};
|
11
|
+
};
|
10
12
|
export default _default;
|
11
|
-
export const Primary: any;
|
12
|
-
export const Secondary: any;
|
13
|
-
export const Loading: any;
|
14
|
-
export const SecondaryDisabled: any;
|
15
|
-
import { Chip } from "./Chip";
|
13
|
+
export declare const Primary: any;
|
14
|
+
export declare const Secondary: any;
|
15
|
+
export declare const Loading: any;
|
16
|
+
export declare const SecondaryDisabled: any;
|