@gobolt/genesis 0.0.7
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/README.md +86 -0
- package/dist/AntdIcon-Bsnbyy6g.js +200 -0
- package/dist/CheckOutlined-DAynWe12.js +527 -0
- package/dist/CloseCircleFilled-ZIY-u-27.js +13 -0
- package/dist/Compact-CJBo3f0u.js +185 -0
- package/dist/ContextIsolator-CGkdKtc3.js +20 -0
- package/dist/ExclamationCircleFilled-BICVVQIg.js +21 -0
- package/dist/Form-Cylpi4M4.js +1815 -0
- package/dist/Overflow-CP1M4Z0s.js +369 -0
- package/dist/SearchOutlined-DuzJkIiQ.js +52 -0
- package/dist/TextArea-3MOYYuAQ.js +1680 -0
- package/dist/bundle.css +1 -0
- package/dist/button-BNV2qdrP.js +1392 -0
- package/dist/compact-item-DH13cl8A.js +61 -0
- package/dist/components/atoms/button/Button.d.ts +12 -0
- package/dist/components/atoms/button/Button.js +27 -0
- package/dist/components/atoms/button/__stories__/Button.stories.d.ts +13 -0
- package/dist/components/atoms/button/index.d.ts +2 -0
- package/dist/components/atoms/button/index.js +4 -0
- package/dist/components/atoms/button/styles.d.ts +12 -0
- package/dist/components/atoms/button/styles.js +71 -0
- package/dist/components/atoms/checkbox/Checkbox.d.ts +10 -0
- package/dist/components/atoms/checkbox/Checkbox.js +13 -0
- package/dist/components/atoms/checkbox/__stories__/Checkbox.stories.d.ts +8 -0
- package/dist/components/atoms/checkbox/__tests__/Checkbox.test.d.ts +1 -0
- package/dist/components/atoms/checkbox/__tests__/Checkbox.test.js +18 -0
- package/dist/components/atoms/checkbox/index.d.ts +2 -0
- package/dist/components/atoms/checkbox/index.js +4 -0
- package/dist/components/atoms/checkbox/styles.d.ts +11 -0
- package/dist/components/atoms/checkbox/styles.js +582 -0
- package/dist/components/atoms/index.d.ts +1 -0
- package/dist/components/atoms/index.js +3 -0
- package/dist/components/atoms/input/Input.d.ts +11 -0
- package/dist/components/atoms/input/Input.js +12 -0
- package/dist/components/atoms/input/__stories__/Input.stories.d.ts +10 -0
- package/dist/components/atoms/input/__tests__/Input.test.d.ts +1 -0
- package/dist/components/atoms/input/__tests__/Input.test.js +28 -0
- package/dist/components/atoms/input/index.d.ts +2 -0
- package/dist/components/atoms/input/index.js +4 -0
- package/dist/components/atoms/input/styles.d.ts +14 -0
- package/dist/components/atoms/input/styles.js +415 -0
- package/dist/components/atoms/select/Select.d.ts +11 -0
- package/dist/components/atoms/select/Select.js +24 -0
- package/dist/components/atoms/select/__stories__/Select.stories.d.ts +8 -0
- package/dist/components/atoms/select/__tests__/Select.test.d.ts +1 -0
- package/dist/components/atoms/select/__tests__/Select.test.js +10735 -0
- package/dist/components/atoms/select/index.d.ts +2 -0
- package/dist/components/atoms/select/index.js +4 -0
- package/dist/components/atoms/select/styles.d.ts +15 -0
- package/dist/components/atoms/select/styles.js +3868 -0
- package/dist/components/atoms/typography/Typography.d.ts +11 -0
- package/dist/components/atoms/typography/Typography.js +44 -0
- package/dist/components/atoms/typography/__stories__/Typography.stories.d.ts +12 -0
- package/dist/components/atoms/typography/__tests__/Typography.test.d.ts +1 -0
- package/dist/components/atoms/typography/__tests__/Typography.test.js +16 -0
- package/dist/components/atoms/typography/index.d.ts +2 -0
- package/dist/components/atoms/typography/index.js +4 -0
- package/dist/components/atoms/typography/styles.d.ts +11 -0
- package/dist/components/atoms/typography/styles.js +28 -0
- package/dist/components/index.d.js +1 -0
- package/dist/components/index.d.ts +14 -0
- package/dist/components/index.js +16 -0
- package/dist/components/molecules/error-boundary-fallback/ErrorBoundaryFallback.d.ts +10 -0
- package/dist/components/molecules/error-boundary-fallback/ErrorBoundaryFallback.js +35 -0
- package/dist/components/molecules/error-boundary-fallback/__stories__/ErrorBoundaryFallback.stories.d.ts +8 -0
- package/dist/components/molecules/error-boundary-fallback/index.d.ts +1 -0
- package/dist/components/molecules/error-boundary-fallback/index.js +4 -0
- package/dist/components/molecules/error-boundary-fallback/styles.d.ts +1 -0
- package/dist/components/molecules/error-boundary-fallback/styles.js +930 -0
- package/dist/components/molecules/form/Form.d.ts +15 -0
- package/dist/components/molecules/form/Form.js +7 -0
- package/dist/components/molecules/form/__stories__/Form.stories.d.ts +7 -0
- package/dist/components/molecules/form/__stories__/FormStory.d.ts +1 -0
- package/dist/components/molecules/form/__stories__/FormStory.js +90 -0
- package/dist/components/molecules/form/index.d.ts +2 -0
- package/dist/components/molecules/form/index.js +4 -0
- package/dist/constants/index.d.ts +51 -0
- package/dist/constants/index.js +54 -0
- package/dist/context-CZsFJmh6.js +2093 -0
- package/dist/declaration.d.js +1 -0
- package/dist/genesis/GenesisThemeBreakdown.d.ts +4 -0
- package/dist/genesis/GenesisThemeBreakdown.js +56 -0
- package/dist/genesis/GenesisThemeDemo.d.ts +8 -0
- package/dist/genesis/GenesisThemeDemo.js +8 -0
- package/dist/genesis/GenesisThemeDemo.stories.d.ts +7 -0
- package/dist/genesis/styles.d.ts +12 -0
- package/dist/genesis/styles.js +4038 -0
- package/dist/index-3MWkSVA1.js +96 -0
- package/dist/index-BPtFqhcp.js +19110 -0
- package/dist/index-BQO27mgE.js +402 -0
- package/dist/index-BWys7dkb.js +4462 -0
- package/dist/index-C7kFNqp2.js +276 -0
- package/dist/index-D1v_7IIx.js +1057 -0
- package/dist/index-SAAXFt-P.js +946 -0
- package/dist/index-VDH3iLaC.js +884 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +20 -0
- package/dist/isVisible-CNQjrJPN.js +366 -0
- package/dist/magic-string.es-BkUFmFT4.js +858 -0
- package/dist/presetColors-Cl8UP3Nw.js +4 -0
- package/dist/providers/GenesisProvider.d.ts +8 -0
- package/dist/providers/GenesisProvider.js +7 -0
- package/dist/providers/ThemeProvider.d.ts +9 -0
- package/dist/providers/ThemeProvider.js +18 -0
- package/dist/providers/index.d.ts +2 -0
- package/dist/providers/index.js +6 -0
- package/dist/reactNode-sKPeiqPL.js +12 -0
- package/dist/setup-CMYVZCPF.js +33883 -0
- package/dist/styled-components.browser.esm-CZ1XM4o4.js +1144 -0
- package/dist/styles/design-tokens/border-tokens/BorderTokenList.d.ts +1 -0
- package/dist/styles/design-tokens/border-tokens/BorderTokenList.js +37 -0
- package/dist/styles/design-tokens/border-tokens/BorderTokens.stories.d.ts +6 -0
- package/dist/styles/design-tokens/color-tokens/ColorTokens.stories.d.ts +7 -0
- package/dist/styles/design-tokens/sizing-tokens/SizingTokenList.d.ts +3 -0
- package/dist/styles/design-tokens/sizing-tokens/SizingTokenList.js +36 -0
- package/dist/styles/design-tokens/sizing-tokens/index.stories.d.ts +7 -0
- package/dist/styles/design-tokens/typography/TypographyTokens.stories.d.ts +7 -0
- package/dist/styles/design-tokens/variables.d.ts +704 -0
- package/dist/styles/design-tokens/variables.js +697 -0
- package/dist/styles/global-styles.d.ts +1 -0
- package/dist/styles/global-styles.js +35 -0
- package/dist/styles/theme/genesis-theme.d.ts +75 -0
- package/dist/styles/theme/genesis-theme.js +896 -0
- package/dist/styles/theme/genesis-theme.types.d.ts +162 -0
- package/dist/styles/theme/genesis-theme.types.js +4 -0
- package/dist/styles/theme/global-styles.d.ts +1 -0
- package/dist/styles/theme/global-styles.js +35 -0
- package/dist/styles/theme/index.d.ts +1 -0
- package/dist/styles/theme/index.js +9 -0
- package/dist/test/setup.d.ts +5 -0
- package/dist/test/setup.js +7 -0
- package/dist/useVariants-CEpw6Ww6.js +29 -0
- package/dist/utils/getAppointmentColor.d.ts +4 -0
- package/dist/utils/getAppointmentColor.js +91 -0
- package/dist/utils/isAllEnglishString.d.ts +1 -0
- package/dist/utils/isAllEnglishString.js +8 -0
- package/dist/utils/isAllEnglishString.test.d.ts +1 -0
- package/dist/utils/isAllEnglishString.test.js +8 -0
- package/dist/utils/parseAddress.d.ts +3 -0
- package/dist/utils/parseAddress.js +19 -0
- package/dist/vite-env.d.js +1 -0
- package/package.json +115 -0
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { FormProps as AntFormProps } from 'antd/es/typography/Title';
|
|
3
|
+
import { TYPE, STATE } from '../../../constants';
|
|
4
|
+
|
|
5
|
+
export type GenesisInputType = keyof typeof TYPE;
|
|
6
|
+
export interface FormProps extends AntFormProps {
|
|
7
|
+
children?: React.ReactNode;
|
|
8
|
+
type?: GenesisButtonType;
|
|
9
|
+
state?: keyof typeof STATE;
|
|
10
|
+
}
|
|
11
|
+
export declare const FormItem: ({ ...rest }: {
|
|
12
|
+
[x: string]: any;
|
|
13
|
+
}) => import("react/jsx-runtime").JSX.Element;
|
|
14
|
+
declare const Form: React.FC<FormProps>;
|
|
15
|
+
export default Form;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const FormStory: () => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
import { jsxs as r, Fragment as m, jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import { a as p, F as d, b as n } from "../../../../Form-Cylpi4M4.js";
|
|
3
|
+
import c from "../../../atoms/button/Button.js";
|
|
4
|
+
import u from "../../../atoms/input/Input.js";
|
|
5
|
+
import h from "../../../atoms/select/Select.js";
|
|
6
|
+
import f from "../../../atoms/checkbox/Checkbox.js";
|
|
7
|
+
import i from "../../../atoms/typography/Typography.js";
|
|
8
|
+
import "../../error-boundary-fallback/styles.js";
|
|
9
|
+
import b from "react";
|
|
10
|
+
import { S as o } from "../../../../index-3MWkSVA1.js";
|
|
11
|
+
const F = [
|
|
12
|
+
{ value: "apple", label: /* @__PURE__ */ e("span", { children: "apple" }) },
|
|
13
|
+
{ value: "pear", label: /* @__PURE__ */ e("span", { children: "pear" }) }
|
|
14
|
+
], q = () => {
|
|
15
|
+
const [a, t] = b.useState(null), [s] = p.useForm();
|
|
16
|
+
return /* @__PURE__ */ r(m, { children: [
|
|
17
|
+
/* @__PURE__ */ e(
|
|
18
|
+
d,
|
|
19
|
+
{
|
|
20
|
+
form: s,
|
|
21
|
+
autoComplete: "off",
|
|
22
|
+
initialValues: { remember: !0 },
|
|
23
|
+
onFinish: (l) => {
|
|
24
|
+
console.log("Success:", l), t(l);
|
|
25
|
+
},
|
|
26
|
+
onFinishFailed: (l) => {
|
|
27
|
+
console.log("Failed:", l);
|
|
28
|
+
},
|
|
29
|
+
children: /* @__PURE__ */ r(o, { direction: "vertical", children: [
|
|
30
|
+
/* @__PURE__ */ e(i, { variant: "heading1", children: "Hello Genesis" }),
|
|
31
|
+
/* @__PURE__ */ e(
|
|
32
|
+
n,
|
|
33
|
+
{
|
|
34
|
+
label: "What is your name?",
|
|
35
|
+
name: "username",
|
|
36
|
+
rules: [{ required: !0, message: "Please input your name!" }],
|
|
37
|
+
labelCol: { span: 24 },
|
|
38
|
+
children: /* @__PURE__ */ e(u, {})
|
|
39
|
+
}
|
|
40
|
+
),
|
|
41
|
+
/* @__PURE__ */ e(
|
|
42
|
+
n,
|
|
43
|
+
{
|
|
44
|
+
label: "What's for lunch?",
|
|
45
|
+
name: "fruit",
|
|
46
|
+
rules: [{ required: !1 }],
|
|
47
|
+
labelCol: { span: 24 },
|
|
48
|
+
children: /* @__PURE__ */ e(h, { options: F, placeholder: "Select a fruit" })
|
|
49
|
+
}
|
|
50
|
+
),
|
|
51
|
+
/* @__PURE__ */ e(
|
|
52
|
+
n,
|
|
53
|
+
{
|
|
54
|
+
name: "subscribe",
|
|
55
|
+
labelCol: { span: 24 },
|
|
56
|
+
label: "Interested in updates?",
|
|
57
|
+
children: /* @__PURE__ */ r(o, { direction: "horizontal ", children: [
|
|
58
|
+
/* @__PURE__ */ e(f, {}),
|
|
59
|
+
/* @__PURE__ */ e(i, { children: "Yes, Sign me up" })
|
|
60
|
+
] })
|
|
61
|
+
}
|
|
62
|
+
),
|
|
63
|
+
/* @__PURE__ */ e(n, { label: null, name: "subscribe", valuePropName: "checked", children: /* @__PURE__ */ r(o, { direction: "horizontal", size: 180, children: [
|
|
64
|
+
/* @__PURE__ */ e(c, { type: "secondary", onClick: () => {
|
|
65
|
+
s.resetFields(), t(null);
|
|
66
|
+
}, children: "Reset" }),
|
|
67
|
+
/* @__PURE__ */ e(c, { htmlType: "submit", children: "Submit" })
|
|
68
|
+
] }) })
|
|
69
|
+
] })
|
|
70
|
+
}
|
|
71
|
+
),
|
|
72
|
+
a && /* @__PURE__ */ r(
|
|
73
|
+
"div",
|
|
74
|
+
{
|
|
75
|
+
style: {
|
|
76
|
+
marginTop: "20px",
|
|
77
|
+
padding: "10px",
|
|
78
|
+
border: "1px solid #ccc"
|
|
79
|
+
},
|
|
80
|
+
children: [
|
|
81
|
+
/* @__PURE__ */ e(i, { variant: "heading3", children: "Form Values:" }),
|
|
82
|
+
/* @__PURE__ */ e("pre", { children: JSON.stringify(a, null, 2) })
|
|
83
|
+
]
|
|
84
|
+
}
|
|
85
|
+
)
|
|
86
|
+
] });
|
|
87
|
+
};
|
|
88
|
+
export {
|
|
89
|
+
q as FormStory
|
|
90
|
+
};
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
export declare const TYPE: {
|
|
2
|
+
primary: string;
|
|
3
|
+
secondary: string;
|
|
4
|
+
tertiary: string;
|
|
5
|
+
};
|
|
6
|
+
export declare const BREAKPOINTS: {
|
|
7
|
+
wide: string;
|
|
8
|
+
medium: string;
|
|
9
|
+
narrow: string;
|
|
10
|
+
};
|
|
11
|
+
export declare const STATE: {
|
|
12
|
+
active: string;
|
|
13
|
+
hover: string;
|
|
14
|
+
pressed: string;
|
|
15
|
+
focussed: string;
|
|
16
|
+
disabled: string;
|
|
17
|
+
};
|
|
18
|
+
export declare const TYPOGRAPHY_VARIANT: {
|
|
19
|
+
display1: string;
|
|
20
|
+
display2: string;
|
|
21
|
+
display3: string;
|
|
22
|
+
heading1: string;
|
|
23
|
+
heading2: string;
|
|
24
|
+
heading3: string;
|
|
25
|
+
subHeading1: string;
|
|
26
|
+
subHeading2: string;
|
|
27
|
+
subHeading3: string;
|
|
28
|
+
body1: string;
|
|
29
|
+
body2: string;
|
|
30
|
+
body3: string;
|
|
31
|
+
body4: string;
|
|
32
|
+
body5: string;
|
|
33
|
+
message: string;
|
|
34
|
+
overline1: string;
|
|
35
|
+
overline2: string;
|
|
36
|
+
overline3: string;
|
|
37
|
+
label1: string;
|
|
38
|
+
label2: string;
|
|
39
|
+
label3: string;
|
|
40
|
+
link1: string;
|
|
41
|
+
link2: string;
|
|
42
|
+
link3: string;
|
|
43
|
+
digits1: string;
|
|
44
|
+
digits2: string;
|
|
45
|
+
digits3: string;
|
|
46
|
+
};
|
|
47
|
+
export declare const BUTTON_VARIANT: {
|
|
48
|
+
primary: string;
|
|
49
|
+
secondary: string;
|
|
50
|
+
tertiary: string;
|
|
51
|
+
};
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
const e = {
|
|
2
|
+
primary: "primary",
|
|
3
|
+
secondary: "secondary",
|
|
4
|
+
tertiary: "tertiary"
|
|
5
|
+
}, i = {
|
|
6
|
+
wide: "wide",
|
|
7
|
+
medium: "medium",
|
|
8
|
+
narrow: "narrow"
|
|
9
|
+
}, d = {
|
|
10
|
+
active: "active",
|
|
11
|
+
hover: "hover",
|
|
12
|
+
pressed: "pressed",
|
|
13
|
+
focussed: "focus",
|
|
14
|
+
disabled: "disabled"
|
|
15
|
+
}, a = {
|
|
16
|
+
display1: "display1",
|
|
17
|
+
display2: "display2",
|
|
18
|
+
display3: "display3",
|
|
19
|
+
heading1: "heading1",
|
|
20
|
+
heading2: "heading2",
|
|
21
|
+
heading3: "heading3",
|
|
22
|
+
subHeading1: "subHeading1",
|
|
23
|
+
subHeading2: "subHeading2",
|
|
24
|
+
subHeading3: "subHeading3",
|
|
25
|
+
body1: "body1",
|
|
26
|
+
body2: "body2",
|
|
27
|
+
body3: "body3",
|
|
28
|
+
body4: "body4",
|
|
29
|
+
body5: "body5",
|
|
30
|
+
message: "message",
|
|
31
|
+
overline1: "overline1",
|
|
32
|
+
overline2: "overline2",
|
|
33
|
+
overline3: "overline3",
|
|
34
|
+
label1: "label1",
|
|
35
|
+
label2: "label2",
|
|
36
|
+
label3: "label3",
|
|
37
|
+
link1: "link1",
|
|
38
|
+
link2: "link2",
|
|
39
|
+
link3: "link3",
|
|
40
|
+
digits1: "digits1",
|
|
41
|
+
digits2: "digits2",
|
|
42
|
+
digits3: "digits3"
|
|
43
|
+
}, s = {
|
|
44
|
+
primary: "primary",
|
|
45
|
+
secondary: "secondary",
|
|
46
|
+
tertiary: "tertiary"
|
|
47
|
+
};
|
|
48
|
+
export {
|
|
49
|
+
i as BREAKPOINTS,
|
|
50
|
+
s as BUTTON_VARIANT,
|
|
51
|
+
d as STATE,
|
|
52
|
+
e as TYPE,
|
|
53
|
+
a as TYPOGRAPHY_VARIANT
|
|
54
|
+
};
|