@sikka/hawa 0.0.15 → 0.0.18
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/.github/workflows/hawa-publish-push.yml +1 -0
- package/es/index.es.js +1 -1
- package/lib/index.js +1 -1
- package/package.json +1 -1
- package/src/blocks/Account/UserProfileForm.js +79 -43
- package/src/blocks/Account/UserSettingsForm.js +7 -2
- package/src/blocks/AuthForms/SignInForm.js +5 -1
- package/src/blocks/AuthForms/SignUpForm.js +6 -2
- package/src/blocks/Payment/ChargeWalletForm.js +29 -20
- package/src/elements/HawaAlert.js +1 -24
- package/src/elements/HawaTable.js +39 -0
- package/src/elements/HawaTypography.js +0 -19
- package/src/elements/OfflineBanner.js +20 -0
- package/src/elements/index.js +2 -0
- package/src/layout/HawaDialog.js +45 -0
- package/src/layout/index.js +1 -0
- package/storybook-static/{0.f47eb24a4893a96ec307.manager.bundle.js → 0.42b12e88e2d7c13fc83c.manager.bundle.js} +1 -1
- package/storybook-static/{4.0fcda1281dc1961dbe94.manager.bundle.js → 4.6efb4495a449edfbd0b0.manager.bundle.js} +2 -2
- package/storybook-static/{4.0fcda1281dc1961dbe94.manager.bundle.js.LICENSE.txt → 4.6efb4495a449edfbd0b0.manager.bundle.js.LICENSE.txt} +0 -0
- package/storybook-static/{5.63ab4f94d50a3acf080d.manager.bundle.js → 5.fdf5c7287259585b43a3.manager.bundle.js} +1 -1
- package/storybook-static/{6.704d1e8d.iframe.bundle.js → 6.19c48a8c.iframe.bundle.js} +1 -1
- package/storybook-static/{6.a6d45262f7e98f3f18d3.manager.bundle.js → 6.8f7b9049856bdace5643.manager.bundle.js} +2 -2
- package/storybook-static/{6.a6d45262f7e98f3f18d3.manager.bundle.js.LICENSE.txt → 6.8f7b9049856bdace5643.manager.bundle.js.LICENSE.txt} +0 -0
- package/storybook-static/{7.097710753af9a1c41b80.manager.bundle.js → 7.dfc01154563c92ef9ccf.manager.bundle.js} +1 -1
- package/storybook-static/{8.76c3cbf398692028e834.manager.bundle.js → 8.c1928a9f13347c159613.manager.bundle.js} +1 -1
- package/storybook-static/iframe.html +1 -1
- package/storybook-static/index.html +1 -1
- package/storybook-static/main.c1b22dad.iframe.bundle.js +1 -0
- package/storybook-static/main.d9e1c87c8c22202eed3c.manager.bundle.js +1 -0
- package/storybook-static/{runtime~main.c8dac23bc753439736f0.manager.bundle.js → runtime~main.1373976137528887a7ad.manager.bundle.js} +1 -1
- package/storybook-static/{runtime~main.f1ebae9b.iframe.bundle.js → runtime~main.2c77505f.iframe.bundle.js} +1 -1
- package/storybook-static/vendors~main.41b22d5a0c6132a028f1.manager.bundle.js +2 -0
- package/storybook-static/{vendors~main.a697e07137d366f95f76.manager.bundle.js.LICENSE.txt → vendors~main.41b22d5a0c6132a028f1.manager.bundle.js.LICENSE.txt} +0 -0
- package/storybook-static/vendors~main.78f2cf4f.iframe.bundle.js +76 -0
- package/storybook-static/{vendors~main.b4186832.iframe.bundle.js.LICENSE.txt → vendors~main.78f2cf4f.iframe.bundle.js.LICENSE.txt} +0 -0
- package/storybook-static/vendors~main.78f2cf4f.iframe.bundle.js.map +1 -0
- package/src/stories/BlocksStories/Account/UserProfile.stories.js +0 -21
- package/src/stories/BlocksStories/Account/UserSettings.stories.js +0 -55
- package/src/stories/BlocksStories/Auth/NewPassword.stories.js +0 -61
- package/src/stories/BlocksStories/Auth/ResetPassword.stories.js +0 -58
- package/src/stories/BlocksStories/Auth/SignIn.stories.js +0 -89
- package/src/stories/BlocksStories/Auth/SignUp.stories.js +0 -91
- package/src/stories/BlocksStories/Payment/ChargeWallet.stories.js +0 -30
- package/src/stories/BlocksStories/Payment/PayWithCreditCard.stories.js +0 -37
- package/src/stories/BlocksStories/Payment/PayWithWallet.stories.js +0 -17
- package/src/stories/BlocksStories/Payment/PaymentSelection.stories.js +0 -60
- package/src/stories/BlocksStories/Pricing/BillingPlans.stories.js +0 -63
- package/src/stories/BlocksStories/Pricing/LandingPlans.stories.js +0 -63
- package/src/stories/ElementsStories/AdaptiveButton.stories.js +0 -51
- package/src/stories/ElementsStories/Alert.stories.js +0 -41
- package/src/stories/ElementsStories/InputLabel.stories.js +0 -13
- package/src/stories/ElementsStories/ItemCard.stories.js +0 -18
- package/src/stories/ElementsStories/LogoButtons.stories.js +0 -73
- package/src/stories/ElementsStories/PricingCard.stories.js +0 -91
- package/src/stories/ElementsStories/RadioSelector.stories.js +0 -36
- package/src/stories/ElementsStories/SettingsRow.stories.js +0 -63
- package/src/stories/ElementsStories/TextField.stories.js +0 -49
- package/src/stories/Introduction.stories.mdx +0 -229
- package/src/stories/LayoutStories/AppBar.stories.js +0 -29
- package/src/stories/LayoutStories/AppLayout.stories.js +0 -52
- package/src/stories/LayoutStories/Box.stories.js +0 -36
- package/storybook-static/main.66955578.iframe.bundle.js +0 -1
- package/storybook-static/main.ac6e4b72b033097dad76.manager.bundle.js +0 -1
- package/storybook-static/vendors~main.a697e07137d366f95f76.manager.bundle.js +0 -2
- package/storybook-static/vendors~main.b4186832.iframe.bundle.js +0 -76
- package/storybook-static/vendors~main.b4186832.iframe.bundle.js.map +0 -1
|
@@ -1,51 +0,0 @@
|
|
|
1
|
-
import { Class } from "@mui/icons-material";
|
|
2
|
-
import React from "react";
|
|
3
|
-
import { AdaptiveButton } from "../../elements";
|
|
4
|
-
|
|
5
|
-
export default {
|
|
6
|
-
title: "Elements/Buttons/AdaptiveButton",
|
|
7
|
-
component: AdaptiveButton,
|
|
8
|
-
argTypes: {
|
|
9
|
-
buttonText: {
|
|
10
|
-
control: "text",
|
|
11
|
-
description: "The button text",
|
|
12
|
-
table: {
|
|
13
|
-
defaultValue: { summary: "Click" }
|
|
14
|
-
}
|
|
15
|
-
},
|
|
16
|
-
showText: {
|
|
17
|
-
control: "boolean",
|
|
18
|
-
// default: true,
|
|
19
|
-
description: "Boolean to show or hide the text",
|
|
20
|
-
table: {
|
|
21
|
-
defaultValue: { summary: true },
|
|
22
|
-
type: {
|
|
23
|
-
summary: "Use Case",
|
|
24
|
-
detail:
|
|
25
|
-
"Set this property to true in large screen and false on mobile"
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
},
|
|
30
|
-
args: {
|
|
31
|
-
buttonText: "Click"
|
|
32
|
-
}
|
|
33
|
-
};
|
|
34
|
-
|
|
35
|
-
const Template = (args) => {
|
|
36
|
-
return <AdaptiveButton {...args} />;
|
|
37
|
-
};
|
|
38
|
-
|
|
39
|
-
export const FullButton = Template.bind({});
|
|
40
|
-
FullButton.args = {
|
|
41
|
-
showText: true,
|
|
42
|
-
// buttonText: "Full Button",
|
|
43
|
-
icon: <Class />
|
|
44
|
-
};
|
|
45
|
-
|
|
46
|
-
export const IconOnly = Template.bind({});
|
|
47
|
-
IconOnly.args = {
|
|
48
|
-
showText: false,
|
|
49
|
-
icon: <Class />,
|
|
50
|
-
buttonText: "test"
|
|
51
|
-
};
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
|
|
3
|
-
import { HawaAlert } from "../../elements";
|
|
4
|
-
|
|
5
|
-
const Template = (args) => {
|
|
6
|
-
return (
|
|
7
|
-
<>
|
|
8
|
-
<HawaAlert
|
|
9
|
-
title="What?"
|
|
10
|
-
text="This is a success alert"
|
|
11
|
-
severity="success"
|
|
12
|
-
/>
|
|
13
|
-
<HawaAlert text="This is an info alert" severity="info" />
|
|
14
|
-
<HawaAlert text="This is a warning alert" severity="warning" />
|
|
15
|
-
<HawaAlert text="This is an error alert" severity="error" />
|
|
16
|
-
</>
|
|
17
|
-
);
|
|
18
|
-
};
|
|
19
|
-
//types:
|
|
20
|
-
//error (red)
|
|
21
|
-
//warning (red)
|
|
22
|
-
//notice (blue)
|
|
23
|
-
|
|
24
|
-
export default {
|
|
25
|
-
title: "UI/Alert",
|
|
26
|
-
component: HawaAlert,
|
|
27
|
-
argTypes: {
|
|
28
|
-
theme: {
|
|
29
|
-
options: ["primary", "secondary", "default"],
|
|
30
|
-
control: { type: "select" }
|
|
31
|
-
}
|
|
32
|
-
},
|
|
33
|
-
args: {
|
|
34
|
-
theme: "primary"
|
|
35
|
-
}
|
|
36
|
-
};
|
|
37
|
-
|
|
38
|
-
export const Default = Template.bind({});
|
|
39
|
-
Default.args = {
|
|
40
|
-
theme: "primary"
|
|
41
|
-
};
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { storiesOf } from "@storybook/react";
|
|
2
|
-
import { HawaInputLabel } from "../../elements";
|
|
3
|
-
|
|
4
|
-
export default {
|
|
5
|
-
title: "Components/InputLabel",
|
|
6
|
-
component: [HawaInputLabel],
|
|
7
|
-
argTypes: {
|
|
8
|
-
resize: {
|
|
9
|
-
options: ["vertical", "horizontal", "both"],
|
|
10
|
-
control: { type: "radio" }
|
|
11
|
-
}
|
|
12
|
-
}
|
|
13
|
-
};
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { Container } from "@mui/material";
|
|
2
|
-
import React from "react";
|
|
3
|
-
import { HawaCard } from "../../elements";
|
|
4
|
-
|
|
5
|
-
export default {
|
|
6
|
-
title: "Elements/Cards/Items",
|
|
7
|
-
component: [HawaCard],
|
|
8
|
-
argTypes: {
|
|
9
|
-
buttonLabel: {
|
|
10
|
-
control: "text",
|
|
11
|
-
description: "The text next to the logo"
|
|
12
|
-
}
|
|
13
|
-
}
|
|
14
|
-
};
|
|
15
|
-
|
|
16
|
-
export const Items = (args) => {
|
|
17
|
-
return <HawaCard />;
|
|
18
|
-
};
|
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
import { Container } from "@mui/material";
|
|
2
|
-
import React from "react";
|
|
3
|
-
import { ActionButton, HawaLogoButton } from "../../elements";
|
|
4
|
-
|
|
5
|
-
export default {
|
|
6
|
-
title: "Elements/Buttons/LogoButtons",
|
|
7
|
-
component: HawaLogoButton,
|
|
8
|
-
argTypes: {
|
|
9
|
-
buttonLabel: {
|
|
10
|
-
control: "text",
|
|
11
|
-
description: "The text next to the logo"
|
|
12
|
-
},
|
|
13
|
-
logo: {
|
|
14
|
-
control: "select",
|
|
15
|
-
options: [
|
|
16
|
-
"google",
|
|
17
|
-
"twitter",
|
|
18
|
-
"github",
|
|
19
|
-
"paypal",
|
|
20
|
-
"applepay",
|
|
21
|
-
"googlepay",
|
|
22
|
-
"stcpay",
|
|
23
|
-
"mada",
|
|
24
|
-
"visa/master"
|
|
25
|
-
],
|
|
26
|
-
description: "a brand name that will display the logo accordingly",
|
|
27
|
-
table: {
|
|
28
|
-
type: {
|
|
29
|
-
summary: "Examples",
|
|
30
|
-
detail: "google, twitter, github, paypal, applepay, googlepay"
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
};
|
|
36
|
-
|
|
37
|
-
const Template = (args) => {
|
|
38
|
-
return (
|
|
39
|
-
<Container maxWidth="xs" variant="plain">
|
|
40
|
-
<HawaLogoButton logo={args.logo} buttonText={args.buttonLabel} />
|
|
41
|
-
</Container>
|
|
42
|
-
);
|
|
43
|
-
};
|
|
44
|
-
|
|
45
|
-
export const Google = Template.bind({});
|
|
46
|
-
Google.args = { buttonLabel: "Sign in via Google", logo: "google" };
|
|
47
|
-
|
|
48
|
-
export const Twitter = Template.bind({});
|
|
49
|
-
Twitter.args = { buttonLabel: "Sign in via Twitter", logo: "twitter" };
|
|
50
|
-
|
|
51
|
-
export const Github = Template.bind({});
|
|
52
|
-
Github.args = { buttonLabel: "Sign in via Github", logo: "github" };
|
|
53
|
-
|
|
54
|
-
export const WalletPay = Template.bind({});
|
|
55
|
-
WalletPay.args = { buttonLabel: "Pay with Wallet", logo: "wallet" };
|
|
56
|
-
|
|
57
|
-
export const GooglePay = Template.bind({});
|
|
58
|
-
GooglePay.args = { buttonLabel: "Google Pay", logo: "googlepay" };
|
|
59
|
-
|
|
60
|
-
export const ApplePay = Template.bind({});
|
|
61
|
-
ApplePay.args = { buttonLabel: "Apple Pay", logo: "applepay" };
|
|
62
|
-
|
|
63
|
-
export const STCPay = Template.bind({});
|
|
64
|
-
STCPay.args = { buttonLabel: "STC Pay", logo: "stcpay" };
|
|
65
|
-
|
|
66
|
-
export const VisaMasterPay = Template.bind({});
|
|
67
|
-
VisaMasterPay.args = { buttonLabel: "Visa / Mastercard", logo: "visa/master" };
|
|
68
|
-
|
|
69
|
-
export const PayPal = Template.bind({});
|
|
70
|
-
PayPal.args = { buttonLabel: "PayPal", logo: "paypal" };
|
|
71
|
-
|
|
72
|
-
export const Mada = Template.bind({});
|
|
73
|
-
Mada.args = { buttonLabel: "Mada", logo: "mada" };
|
|
@@ -1,91 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { HawaPricingCard } from "../../elements";
|
|
3
|
-
|
|
4
|
-
export default {
|
|
5
|
-
title: "Elements/Cards/Pricing",
|
|
6
|
-
component: [HawaPricingCard],
|
|
7
|
-
argTypes: {
|
|
8
|
-
title: {
|
|
9
|
-
control: "text",
|
|
10
|
-
description: "The title of the pricing package"
|
|
11
|
-
},
|
|
12
|
-
subtitle: {
|
|
13
|
-
control: "text",
|
|
14
|
-
description: "The subtitle of the pricing package"
|
|
15
|
-
},
|
|
16
|
-
price: {
|
|
17
|
-
control: "number",
|
|
18
|
-
description: "The price of the pricing package"
|
|
19
|
-
},
|
|
20
|
-
currency: {
|
|
21
|
-
control: "text",
|
|
22
|
-
description: "The currency of the price",
|
|
23
|
-
table: {
|
|
24
|
-
type: {
|
|
25
|
-
summary: "Examples",
|
|
26
|
-
detail: "$, SAR, ريال, دولار"
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
},
|
|
30
|
-
cycleText: {
|
|
31
|
-
control: "text",
|
|
32
|
-
description: "The cycle period of the payment",
|
|
33
|
-
table: {
|
|
34
|
-
type: {
|
|
35
|
-
summary: "Examples",
|
|
36
|
-
detail: "Monthly, Annually, Quarterly, Every 3 Months, Every 6 Months"
|
|
37
|
-
}
|
|
38
|
-
}
|
|
39
|
-
},
|
|
40
|
-
features: {
|
|
41
|
-
control: "array",
|
|
42
|
-
description: "An Array of strings for the package features"
|
|
43
|
-
},
|
|
44
|
-
lang: {
|
|
45
|
-
control: "text",
|
|
46
|
-
description: "The language of the card to change the direction",
|
|
47
|
-
table: {
|
|
48
|
-
type: {
|
|
49
|
-
summary: "Options",
|
|
50
|
-
detail: "ar, en"
|
|
51
|
-
}
|
|
52
|
-
}
|
|
53
|
-
},
|
|
54
|
-
buttonText: {
|
|
55
|
-
control: "text",
|
|
56
|
-
description: "The text of the button"
|
|
57
|
-
}
|
|
58
|
-
},
|
|
59
|
-
args: {
|
|
60
|
-
title: "Pro",
|
|
61
|
-
subtitle: "For small businesses",
|
|
62
|
-
price: 300,
|
|
63
|
-
currency: "$",
|
|
64
|
-
cycleText: "Monthly",
|
|
65
|
-
buttonText: "Select Plan"
|
|
66
|
-
}
|
|
67
|
-
};
|
|
68
|
-
|
|
69
|
-
export const LTR = (args) => {
|
|
70
|
-
return (
|
|
71
|
-
<HawaPricingCard
|
|
72
|
-
{...args}
|
|
73
|
-
features={["Unlimited Menus", "Unlimited Items", "Custom Handle"]}
|
|
74
|
-
/>
|
|
75
|
-
);
|
|
76
|
-
};
|
|
77
|
-
|
|
78
|
-
export const RTL = (args) => {
|
|
79
|
-
return (
|
|
80
|
-
<HawaPricingCard
|
|
81
|
-
lang="ar"
|
|
82
|
-
title="الإحترافي"
|
|
83
|
-
subtitle="للمنشئات الصغيرة"
|
|
84
|
-
price="300"
|
|
85
|
-
currency="ريال"
|
|
86
|
-
cycleText="كل 6 أشهر"
|
|
87
|
-
buttonText="إختر الباقة"
|
|
88
|
-
features={["قوائم لا محدودة", "عناصر لا محدودة", "أسم مخصص"]}
|
|
89
|
-
/>
|
|
90
|
-
);
|
|
91
|
-
};
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { HawaRadio } from "../../elements";
|
|
3
|
-
|
|
4
|
-
export default {
|
|
5
|
-
title: "Elements/Selections/Panel Tabs",
|
|
6
|
-
component: [HawaRadio],
|
|
7
|
-
argTypes: {
|
|
8
|
-
options: {
|
|
9
|
-
control: "array",
|
|
10
|
-
description: "An array of objects containing the option label and value",
|
|
11
|
-
table: {
|
|
12
|
-
type: {
|
|
13
|
-
summary: "Object Example",
|
|
14
|
-
detail: "{label: 'Option 1', value: 'option1'}"
|
|
15
|
-
}
|
|
16
|
-
}
|
|
17
|
-
}
|
|
18
|
-
},
|
|
19
|
-
args: {
|
|
20
|
-
options: 3
|
|
21
|
-
}
|
|
22
|
-
};
|
|
23
|
-
|
|
24
|
-
export const PanelTabs = (args) => {
|
|
25
|
-
let allOptions = Array.from({ length: args.options }, (v, i) => {
|
|
26
|
-
return { label: `Option ${i}`, value: `option${i}` };
|
|
27
|
-
});
|
|
28
|
-
return (
|
|
29
|
-
<HawaRadio
|
|
30
|
-
{...args}
|
|
31
|
-
handleChange={(e) => console.log("changing to ", e)}
|
|
32
|
-
defaultValue="option1"
|
|
33
|
-
options={allOptions}
|
|
34
|
-
/>
|
|
35
|
-
);
|
|
36
|
-
};
|
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { HawaSettingsRow } from "../../elements";
|
|
3
|
-
|
|
4
|
-
export default {
|
|
5
|
-
title: "Elements/Settings/Row",
|
|
6
|
-
component: [HawaSettingsRow],
|
|
7
|
-
parameters: {
|
|
8
|
-
backgrounds: {
|
|
9
|
-
default: 'twitter',
|
|
10
|
-
values: [
|
|
11
|
-
{
|
|
12
|
-
name: 'light',
|
|
13
|
-
value: '#00aced',
|
|
14
|
-
},
|
|
15
|
-
{
|
|
16
|
-
name: 'dark',
|
|
17
|
-
value: '#3b5998',
|
|
18
|
-
},
|
|
19
|
-
],
|
|
20
|
-
},
|
|
21
|
-
// backgrounds: [{ name: "dark background", value: "#000", default: true }]
|
|
22
|
-
},
|
|
23
|
-
argTypes: {
|
|
24
|
-
settingsType: {
|
|
25
|
-
options: ["checkbox", "text", "radio"],
|
|
26
|
-
control: { type: "select" }
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
};
|
|
30
|
-
|
|
31
|
-
export const CheckboxSettings = (args) => <HawaSettingsRow {...args} />;
|
|
32
|
-
CheckboxSettings.args = {
|
|
33
|
-
settingsType: "checkbox",
|
|
34
|
-
settingsLabel: "Text Settings"
|
|
35
|
-
};
|
|
36
|
-
export const TextSettings = (args) => (
|
|
37
|
-
<HawaSettingsRow placeholder="Text here" {...args} />
|
|
38
|
-
);
|
|
39
|
-
|
|
40
|
-
TextSettings.args = {
|
|
41
|
-
settingsType: "text",
|
|
42
|
-
settingsLabel: "Text Settings"
|
|
43
|
-
};
|
|
44
|
-
export const RadioSettings = (args) => {
|
|
45
|
-
let allOptions = Array.from({ length: args.options }, (v, i) => {
|
|
46
|
-
return { label: `Option ${i}`, value: `option${i}` };
|
|
47
|
-
});
|
|
48
|
-
return (
|
|
49
|
-
<HawaSettingsRow
|
|
50
|
-
settingsType={args.settingsType}
|
|
51
|
-
settingsLabel={args.settingsLabel}
|
|
52
|
-
handleChange={(e) => console.log("changing to ", e)}
|
|
53
|
-
defaultValue="option1"
|
|
54
|
-
options={allOptions}
|
|
55
|
-
/>
|
|
56
|
-
);
|
|
57
|
-
};
|
|
58
|
-
|
|
59
|
-
RadioSettings.args = {
|
|
60
|
-
options: 3,
|
|
61
|
-
settingsType: "radio",
|
|
62
|
-
settingsLabel: "Radio Settings"
|
|
63
|
-
};
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { HawaTextField } from "../../elements";
|
|
3
|
-
|
|
4
|
-
const Template = (args) => {
|
|
5
|
-
return <HawaTextField {...args} />;
|
|
6
|
-
};
|
|
7
|
-
|
|
8
|
-
export default {
|
|
9
|
-
title: "UI/TextField",
|
|
10
|
-
component: HawaTextField,
|
|
11
|
-
argsTypes: {
|
|
12
|
-
type: {
|
|
13
|
-
name: "type",
|
|
14
|
-
type: { name: "string", required: true },
|
|
15
|
-
options: ["text", "number", "date"],
|
|
16
|
-
control: { type: "radio" },
|
|
17
|
-
defaultValue: "text",
|
|
18
|
-
description: "Styled Text Field",
|
|
19
|
-
table: {
|
|
20
|
-
type: { summary: "string" },
|
|
21
|
-
defaultValue: { summary: "Hello" }
|
|
22
|
-
}
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
// args: {
|
|
26
|
-
// bdRadius: 15,
|
|
27
|
-
// defaultValue: "Test",
|
|
28
|
-
// type: "date"
|
|
29
|
-
// }
|
|
30
|
-
};
|
|
31
|
-
|
|
32
|
-
export const Light = Template.bind({});
|
|
33
|
-
export const Dark = Template.bind({});
|
|
34
|
-
|
|
35
|
-
Light.args = {
|
|
36
|
-
placeholder: "Exemple ...",
|
|
37
|
-
defaultValue: "This isko default value",
|
|
38
|
-
inputLabel: "Text Field",
|
|
39
|
-
bgColor: "lightgray",
|
|
40
|
-
padding: 10
|
|
41
|
-
// type: "number"
|
|
42
|
-
};
|
|
43
|
-
Dark.args = {
|
|
44
|
-
placeholder: "Exemple ...",
|
|
45
|
-
defaultValue: "This is default value",
|
|
46
|
-
inputLabel: "Text Field",
|
|
47
|
-
bgColor: "lightgray",
|
|
48
|
-
padding: 10
|
|
49
|
-
};
|
|
@@ -1,229 +0,0 @@
|
|
|
1
|
-
import { Meta } from "@storybook/addon-docs"
|
|
2
|
-
// import Code from './assets/code-brackets.svg';
|
|
3
|
-
// import Colors from './assets/colors.svg';
|
|
4
|
-
// import Comments from './assets/comments.svg';
|
|
5
|
-
// import Direction from './assets/direction.svg';
|
|
6
|
-
// import Flow from './assets/flow.svg';
|
|
7
|
-
// import Plugin from './assets/plugin.svg';
|
|
8
|
-
// import Repo from './assets/repo.svg';
|
|
9
|
-
// import StackAlt from './assets/stackalt.svg';
|
|
10
|
-
|
|
11
|
-
<Meta title="Introduction" />
|
|
12
|
-
|
|
13
|
-
<style>{`
|
|
14
|
-
.subheading {
|
|
15
|
-
--mediumdark: '#999999';
|
|
16
|
-
font-weight: 900;
|
|
17
|
-
font-size: 13px;
|
|
18
|
-
color: #999;
|
|
19
|
-
letter-spacing: 6px;
|
|
20
|
-
line-height: 24px;
|
|
21
|
-
text-transform: uppercase;
|
|
22
|
-
margin-bottom: 12px;
|
|
23
|
-
margin-top: 40px;
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
.link-list {
|
|
27
|
-
display: grid;
|
|
28
|
-
grid-template-columns: 1fr;
|
|
29
|
-
grid-template-rows: 1fr 1fr;
|
|
30
|
-
row-gap: 10px;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
@media (min-width: 620px) {
|
|
34
|
-
.link-list {
|
|
35
|
-
row-gap: 20px;
|
|
36
|
-
column-gap: 20px;
|
|
37
|
-
grid-template-columns: 1fr 1fr;
|
|
38
|
-
}
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
@media all and (-ms-high-contrast:none) {
|
|
42
|
-
.link-list {
|
|
43
|
-
display: -ms-grid;
|
|
44
|
-
-ms-grid-columns: 1fr 1fr;
|
|
45
|
-
-ms-grid-rows: 1fr 1fr;
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
.link-item {
|
|
50
|
-
display: block;
|
|
51
|
-
padding: 20px 30px 20px 15px;
|
|
52
|
-
border: 1px solid #00000010;
|
|
53
|
-
border-radius: 5px;
|
|
54
|
-
transition: background 150ms ease-out, border 150ms ease-out, transform 150ms ease-out;
|
|
55
|
-
color: #333333;
|
|
56
|
-
display: flex;
|
|
57
|
-
flex-direction:column;
|
|
58
|
-
align-items: flex-start;
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
.link-item:hover {
|
|
62
|
-
border-color: #1EA7FD50;
|
|
63
|
-
transform: translate3d(0, -3px, 0);
|
|
64
|
-
box-shadow: rgba(0, 0, 0, 0.08) 0 3px 10px 0;
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
.link-item:active {
|
|
68
|
-
border-color: #1EA7FD;
|
|
69
|
-
transform: translate3d(0, 0, 0);
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
.link-item strong {
|
|
73
|
-
font-weight: 700;
|
|
74
|
-
display: block;
|
|
75
|
-
margin-bottom: 2px;
|
|
76
|
-
}
|
|
77
|
-
|
|
78
|
-
.link-item img {
|
|
79
|
-
height: 40px;
|
|
80
|
-
width: 40px;
|
|
81
|
-
margin-right: 15px;
|
|
82
|
-
flex: none;
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
.link-item span {
|
|
86
|
-
font-size: 14px;
|
|
87
|
-
line-height: 20px;
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
.tip {
|
|
91
|
-
display: inline-block;
|
|
92
|
-
border-radius: 1em;
|
|
93
|
-
font-size: 11px;
|
|
94
|
-
line-height: 12px;
|
|
95
|
-
font-weight: 700;
|
|
96
|
-
background: #E7FDD8;
|
|
97
|
-
color: #66BF3C;
|
|
98
|
-
padding: 4px 12px;
|
|
99
|
-
margin-right: 10px;
|
|
100
|
-
vertical-align: top;
|
|
101
|
-
}
|
|
102
|
-
|
|
103
|
-
.tip-wrapper {
|
|
104
|
-
font-size: 13px;
|
|
105
|
-
line-height: 20px;
|
|
106
|
-
margin-top: 40px;
|
|
107
|
-
margin-bottom: 40px;
|
|
108
|
-
}
|
|
109
|
-
|
|
110
|
-
.tip-wrapper code {
|
|
111
|
-
font-size: 12px;
|
|
112
|
-
display: inline-block;
|
|
113
|
-
}
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
`}</style>
|
|
117
|
-
|
|
118
|
-
# Welcome to Hawa
|
|
119
|
-
|
|
120
|
-
<div className="tip-wrapper">
|
|
121
|
-
<span className="tip">Notice</span>This page is still in progress
|
|
122
|
-
</div>
|
|
123
|
-
|
|
124
|
-
Storybook helps you build UI components in isolation from your app's business logic, data, and context.
|
|
125
|
-
That makes it easy to develop hard-to-reach states. Save these UI states as **stories** to revisit during development, testing, or QA.
|
|
126
|
-
|
|
127
|
-
Browse example stories now by navigating to them in the sidebar.
|
|
128
|
-
View their code in the `src/stories` directory to learn how they work.
|
|
129
|
-
We recommend building UIs with a [**component-driven**](https://componentdriven.org) process starting with atomic components and ending with pages.
|
|
130
|
-
|
|
131
|
-
<div className="subheading">Structure</div>
|
|
132
|
-
|
|
133
|
-
<div className="link-list">
|
|
134
|
-
<a
|
|
135
|
-
className="link-item"
|
|
136
|
-
href="https://storybook.js.org/docs/react/addons/addon-types"
|
|
137
|
-
target="_blank"
|
|
138
|
-
>
|
|
139
|
-
{/* <img src={Plugin} alt="plugin" /> */}
|
|
140
|
-
<h3>Layout</h3>
|
|
141
|
-
<span>
|
|
142
|
-
<strong>Presets for popular tools</strong>
|
|
143
|
-
Easy setup for TypeScript, SCSS and more.
|
|
144
|
-
</span>
|
|
145
|
-
</a>
|
|
146
|
-
<a
|
|
147
|
-
className="link-item"
|
|
148
|
-
href="https://storybook.js.org/docs/react/configure/webpack"
|
|
149
|
-
target="_blank"
|
|
150
|
-
>
|
|
151
|
-
{/* <img src={StackAlt} alt="Build" /> */}
|
|
152
|
-
<h3>Blocks</h3>
|
|
153
|
-
<span>
|
|
154
|
-
<strong>Build configuration</strong>
|
|
155
|
-
How to customize webpack and Babel
|
|
156
|
-
</span>
|
|
157
|
-
|
|
158
|
-
</a>
|
|
159
|
-
<a
|
|
160
|
-
className="link-item"
|
|
161
|
-
href="https://storybook.js.org/docs/react/configure/styling-and-css"
|
|
162
|
-
target="_blank"
|
|
163
|
-
>
|
|
164
|
-
{/* <img src={Colors} alt="colors" /> */}
|
|
165
|
-
<h3>Elements</h3>
|
|
166
|
-
<span>
|
|
167
|
-
<strong>Styling</strong>
|
|
168
|
-
How to load and configure CSS libraries
|
|
169
|
-
</span>
|
|
170
|
-
</a>
|
|
171
|
-
<a
|
|
172
|
-
className="link-item"
|
|
173
|
-
href="https://storybook.js.org/docs/react/get-started/setup#configure-storybook-for-your-stack"
|
|
174
|
-
target="_blank"
|
|
175
|
-
>
|
|
176
|
-
{/* <img src={Flow} alt="flow" /> */}
|
|
177
|
-
<h3>UI</h3>
|
|
178
|
-
<span>
|
|
179
|
-
<strong>Data</strong>
|
|
180
|
-
Providers and mocking for data libraries
|
|
181
|
-
</span>
|
|
182
|
-
</a>
|
|
183
|
-
</div>
|
|
184
|
-
|
|
185
|
-
<div className="subheading">Learn</div>
|
|
186
|
-
|
|
187
|
-
<div className="link-list">
|
|
188
|
-
<a className="link-item" href="https://storybook.js.org/docs" target="_blank">
|
|
189
|
-
{/* <img src={Repo} alt="repo" /> */}
|
|
190
|
-
<span>
|
|
191
|
-
<strong>Storybook documentation</strong>
|
|
192
|
-
Configure, customize, and extend
|
|
193
|
-
</span>
|
|
194
|
-
</a>
|
|
195
|
-
<a
|
|
196
|
-
className="link-item"
|
|
197
|
-
href="https://storybook.js.org/tutorials/"
|
|
198
|
-
target="_blank"
|
|
199
|
-
>
|
|
200
|
-
{/* <img src={Direction} alt="direction" /> */}
|
|
201
|
-
<span>
|
|
202
|
-
<strong>In-depth guides</strong>
|
|
203
|
-
Best practices from leading teams
|
|
204
|
-
</span>
|
|
205
|
-
</a>
|
|
206
|
-
<a
|
|
207
|
-
className="link-item"
|
|
208
|
-
href="https://github.com/storybookjs/storybook"
|
|
209
|
-
target="_blank"
|
|
210
|
-
>
|
|
211
|
-
{/* <img src={Code} alt="code" /> */}
|
|
212
|
-
<span>
|
|
213
|
-
<strong>GitHub project</strong>
|
|
214
|
-
View the source and add issues
|
|
215
|
-
</span>
|
|
216
|
-
</a>
|
|
217
|
-
<a className="link-item" href="https://discord.gg/storybook" target="_blank">
|
|
218
|
-
{/* <img src={Comments} alt="comments" /> */}
|
|
219
|
-
<span>
|
|
220
|
-
<strong>Discord chat</strong>
|
|
221
|
-
Chat with maintainers and the community
|
|
222
|
-
</span>
|
|
223
|
-
</a>
|
|
224
|
-
</div>
|
|
225
|
-
|
|
226
|
-
<div className="tip-wrapper">
|
|
227
|
-
<span className="tip">Tip</span>Edit the Markdown in{" "}
|
|
228
|
-
<code>src/stories/Introduction.stories.mdx</code>
|
|
229
|
-
</div>
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { HawaAppBar } from "../../elements";
|
|
3
|
-
|
|
4
|
-
const Template = (args) => {
|
|
5
|
-
return <HawaAppBar />;
|
|
6
|
-
};
|
|
7
|
-
export default {
|
|
8
|
-
title: "Layout/AppBar",
|
|
9
|
-
component: [HawaAppBar],
|
|
10
|
-
parameters: {
|
|
11
|
-
backgrounds: {
|
|
12
|
-
default: "light"
|
|
13
|
-
// values: [
|
|
14
|
-
// { name: "light", value: theme.lightBackground },
|
|
15
|
-
// { name: "dark", value: theme.darkBackground }
|
|
16
|
-
// ]
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
};
|
|
20
|
-
|
|
21
|
-
export const Normal = Template.bind({});
|
|
22
|
-
Normal.args = {
|
|
23
|
-
size: "large",
|
|
24
|
-
showText: true,
|
|
25
|
-
buttonLabel: "test",
|
|
26
|
-
// padding: theme.paddings,
|
|
27
|
-
textColor: "#000000",
|
|
28
|
-
buttonColor: "#f9f9f9"
|
|
29
|
-
};
|