@sikka/hawa 0.0.14 → 0.0.17

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.
Files changed (70) hide show
  1. package/.github/workflows/hawa-publish-push.yml +1 -0
  2. package/es/index.es.js +1 -1
  3. package/lib/index.js +1 -1
  4. package/package.json +1 -1
  5. package/src/blocks/Account/UserProfileForm.js +79 -43
  6. package/src/blocks/Account/UserSettingsForm.js +7 -2
  7. package/src/blocks/AuthForms/NewPasswordForm.js +57 -38
  8. package/src/blocks/AuthForms/ResetPasswordForm.js +36 -39
  9. package/src/blocks/AuthForms/SignInForm.js +76 -59
  10. package/src/blocks/AuthForms/SignUpForm.js +65 -44
  11. package/src/blocks/Payment/ChargeWalletForm.js +29 -20
  12. package/src/blocks/Pricing/PricingPlans.js +19 -9
  13. package/src/elements/HawaAlert.js +1 -24
  14. package/src/elements/HawaAppBar.js +139 -0
  15. package/src/elements/HawaListItem.js +21 -0
  16. package/src/elements/HawaPricingCard.js +40 -22
  17. package/src/elements/HawaTextField.js +15 -149
  18. package/src/elements/HawaTypography.js +0 -19
  19. package/src/elements/OfflineBanner.js +19 -0
  20. package/src/elements/index.js +3 -0
  21. package/src/layout/HawaAppLayout.js +246 -0
  22. package/src/layout/index.js +1 -0
  23. package/storybook-static/{0.f47eb24a4893a96ec307.manager.bundle.js → 0.42b12e88e2d7c13fc83c.manager.bundle.js} +1 -1
  24. package/storybook-static/{4.0fcda1281dc1961dbe94.manager.bundle.js → 4.6efb4495a449edfbd0b0.manager.bundle.js} +2 -2
  25. package/storybook-static/{4.0fcda1281dc1961dbe94.manager.bundle.js.LICENSE.txt → 4.6efb4495a449edfbd0b0.manager.bundle.js.LICENSE.txt} +0 -0
  26. package/storybook-static/{5.63ab4f94d50a3acf080d.manager.bundle.js → 5.fdf5c7287259585b43a3.manager.bundle.js} +1 -1
  27. package/storybook-static/{6.a6d45262f7e98f3f18d3.manager.bundle.js → 6.8f7b9049856bdace5643.manager.bundle.js} +2 -2
  28. package/storybook-static/{6.a6d45262f7e98f3f18d3.manager.bundle.js.LICENSE.txt → 6.8f7b9049856bdace5643.manager.bundle.js.LICENSE.txt} +0 -0
  29. package/storybook-static/{6.704d1e8d.iframe.bundle.js → 6.f7101198.iframe.bundle.js} +0 -0
  30. package/storybook-static/{7.097710753af9a1c41b80.manager.bundle.js → 7.dfc01154563c92ef9ccf.manager.bundle.js} +1 -1
  31. package/storybook-static/{8.76c3cbf398692028e834.manager.bundle.js → 8.c1928a9f13347c159613.manager.bundle.js} +1 -1
  32. package/storybook-static/iframe.html +1 -1
  33. package/storybook-static/index.html +1 -1
  34. package/storybook-static/main.d9e1c87c8c22202eed3c.manager.bundle.js +1 -0
  35. package/storybook-static/main.fb3876e0.iframe.bundle.js +1 -0
  36. package/storybook-static/{runtime~main.c8dac23bc753439736f0.manager.bundle.js → runtime~main.1373976137528887a7ad.manager.bundle.js} +1 -1
  37. package/storybook-static/{runtime~main.f1ebae9b.iframe.bundle.js → runtime~main.1430538c.iframe.bundle.js} +1 -1
  38. package/storybook-static/vendors~main.3f680c6a.iframe.bundle.js +76 -0
  39. package/storybook-static/{vendors~main.5eab66d3.iframe.bundle.js.LICENSE.txt → vendors~main.3f680c6a.iframe.bundle.js.LICENSE.txt} +0 -0
  40. package/storybook-static/vendors~main.3f680c6a.iframe.bundle.js.map +1 -0
  41. package/storybook-static/vendors~main.41b22d5a0c6132a028f1.manager.bundle.js +2 -0
  42. package/storybook-static/{vendors~main.a697e07137d366f95f76.manager.bundle.js.LICENSE.txt → vendors~main.41b22d5a0c6132a028f1.manager.bundle.js.LICENSE.txt} +0 -0
  43. package/src/stories/BlocksStories/Account/UserProfile.stories.js +0 -21
  44. package/src/stories/BlocksStories/Account/UserSettings.stories.js +0 -55
  45. package/src/stories/BlocksStories/Auth/NewPassword.stories.js +0 -60
  46. package/src/stories/BlocksStories/Auth/ResetPassword.stories.js +0 -59
  47. package/src/stories/BlocksStories/Auth/SignIn.stories.js +0 -89
  48. package/src/stories/BlocksStories/Auth/SignUp.stories.js +0 -90
  49. package/src/stories/BlocksStories/Payment/ChargeWallet.stories.js +0 -30
  50. package/src/stories/BlocksStories/Payment/PayWithCreditCard.stories.js +0 -37
  51. package/src/stories/BlocksStories/Payment/PayWithWallet.stories.js +0 -17
  52. package/src/stories/BlocksStories/Payment/PaymentSelection.stories.js +0 -60
  53. package/src/stories/BlocksStories/Pricing/BillingPlans.stories.js +0 -46
  54. package/src/stories/BlocksStories/Pricing/LandingPlans.stories.js +0 -45
  55. package/src/stories/ElementsStories/AdaptiveButton.stories.js +0 -51
  56. package/src/stories/ElementsStories/Alert.stories.js +0 -41
  57. package/src/stories/ElementsStories/InputLabel.stories.js +0 -13
  58. package/src/stories/ElementsStories/ItemCard.stories.js +0 -18
  59. package/src/stories/ElementsStories/LogoButtons.stories.js +0 -73
  60. package/src/stories/ElementsStories/PricingCard.stories.js +0 -91
  61. package/src/stories/ElementsStories/RadioSelector.stories.js +0 -36
  62. package/src/stories/ElementsStories/SettingsRow.stories.js +0 -63
  63. package/src/stories/ElementsStories/TextField.stories.js +0 -49
  64. package/src/stories/Introduction.stories.mdx +0 -229
  65. package/src/stories/LayoutStories/Box.stories.js +0 -36
  66. package/storybook-static/main.ac6e4b72b033097dad76.manager.bundle.js +0 -1
  67. package/storybook-static/main.e382d866.iframe.bundle.js +0 -1
  68. package/storybook-static/vendors~main.5eab66d3.iframe.bundle.js +0 -76
  69. package/storybook-static/vendors~main.5eab66d3.iframe.bundle.js.map +0 -1
  70. package/storybook-static/vendors~main.a697e07137d366f95f76.manager.bundle.js +0 -2
@@ -1,21 +0,0 @@
1
- import React from "react";
2
- import { UserProfileForm } from "../../../blocks/Account";
3
-
4
- export default {
5
- title: "Blocks/Account/User Profile",
6
- component: [UserProfile],
7
- argTypes: {}
8
- };
9
-
10
- const ProfileTemplate = (args) => {
11
- return <UserProfileForm {...args} />;
12
- };
13
- export const UserProfile = ProfileTemplate.bind({});
14
- UserProfile.args = {
15
- viaGoogle: true,
16
- viaGithub: true,
17
- viaTwitter: true,
18
- showError: false,
19
- errorTitle: "Error",
20
- errorText: "Something went wrong"
21
- };
@@ -1,55 +0,0 @@
1
- import React from "react";
2
- import { UserSettingsForm } from "../../../blocks/Account";
3
- import { HawaSettingsRow } from "../../../elements";
4
-
5
- export default {
6
- title: "Blocks/Account/User Settings",
7
- component: UserSettingsForm,
8
- argTypes: {
9
- theme: {
10
- options: ["primary", "secondary", "default"],
11
- control: { type: "select" }
12
- }
13
- }
14
- };
15
- export const UserSettings = (args) => {
16
- return (
17
- <UserSettingsForm {...args}>
18
- <HawaSettingsRow settingsType="checkbox" settingsLabel="Hide Watermark" />
19
- <HawaSettingsRow
20
- settingsType="text"
21
- placeholder="Your handle"
22
- settingsLabel="Custom Handle"
23
- />
24
- <HawaSettingsRow
25
- handleChange={(e) => console.log("changing to ", e)}
26
- settingsType="radio"
27
- defaultValue="sar"
28
- options={[
29
- { value: "sar", label: "SAR" },
30
- { value: "usd", label: "USD" }
31
- ]}
32
- settingsLabel="Currency"
33
- />
34
- <HawaSettingsRow
35
- handleChange={(e) => console.log("changing to ", e)}
36
- settingsType="radio"
37
- defaultValue="en"
38
- options={[
39
- { value: "en", label: "English" },
40
- { value: "ar", label: "Arabic" }
41
- ]}
42
- settingsLabel="Language"
43
- />
44
- <HawaSettingsRow
45
- settingsType="boolean"
46
- placeholder="Your handle"
47
- settingsLabel="Show Analytics"
48
- />
49
- </UserSettingsForm>
50
- );
51
- };
52
- UserSettings.args = {
53
- theme: "primary",
54
- title: "red"
55
- };
@@ -1,60 +0,0 @@
1
- import React from "react";
2
- import { NewPasswordForm } from "../../../blocks/AuthForms";
3
-
4
- export default {
5
- title: "Blocks/Auth/New Password",
6
- component: [NewPasswordForm],
7
- argTypes: {
8
-
9
- showError: {
10
- default: false,
11
- control: "boolean",
12
- description: "Display the error when auth fails",
13
- table: { defaultValue: { summary: true } }
14
- },
15
- errorTitle: {
16
- default: " ",
17
- control: "text",
18
- description: "The error text for the auth failure",
19
- table: { defaultValue: { summary: "" } }
20
- },
21
- errorText: {
22
- default: "Something went wrong",
23
- control: "text",
24
- description: "The error text for the auth failure",
25
- table: { defaultValue: { summary: "Something went wrong" } }
26
- }
27
- }
28
- };
29
-
30
- const NewPasswordTemplate = (args) => {
31
- return (
32
- <NewPasswordForm
33
- {...args}
34
- texts={{
35
- emailLabel: "Email",
36
- emailPlaceholder: "Enter your email",
37
- emailRequiredText: "Email is required",
38
- passwordPlaceholder: "Enter password",
39
- updatePassword: "Update Password",
40
- passwordRequiredText: "Password is required",
41
- passwordLabel: "Choose new password",
42
- confirmPasswordPlaceholder: "Confirm password",
43
- confirmPasswordLabel: "Confirm",
44
- forgotPasswordText: "Forgot password?",
45
- newUserText: "New user?",
46
- signUpText: "Sign up",
47
- signInText: "Sign in",
48
- googleButtonLabel: "Sign in with Google",
49
- githubButtonLabel: "Sign in with Github",
50
- twitterButtonLabel: "Sign in with Twitter"
51
- }}
52
- error={args.showError}
53
- />
54
- );
55
- };
56
- export const NewPassword = NewPasswordTemplate.bind({});
57
- NewPassword.args = {
58
- showError: false,
59
- passwordChanged: false
60
- };
@@ -1,59 +0,0 @@
1
- import React from "react";
2
- import { ResetPasswordForm } from "../../../blocks/AuthForms";
3
-
4
- export default {
5
- title: "Blocks/Auth/Reset Password",
6
- component: [ResetPasswordForm],
7
- argTypes: {
8
-
9
- showError: {
10
- default: false,
11
- control: "boolean",
12
- description: "Display the error when auth fails",
13
- table: { defaultValue: { summary: true } }
14
- },
15
- errorTitle: {
16
- default: " ",
17
- control: "text",
18
- description: "The error text for the auth failure",
19
- table: { defaultValue: { summary: "" } }
20
- },
21
- errorText: {
22
- default: "Something went wrong",
23
- control: "text",
24
- description: "The error text for the auth failure",
25
- table: { defaultValue: { summary: "Something went wrong" } }
26
- }
27
- }
28
- };
29
-
30
- const ResetPasswordTemplate = (args) => {
31
- return (
32
- <ResetPasswordForm
33
- error={args.showError}
34
- texts={{
35
- emailLabel: "Email",
36
- emailPlaceholder: "Enter your email",
37
- emailRequiredText: "Email is required",
38
- emailInvalidText: "Invalid email address",
39
- passwordLabel: "Password",
40
- resetPassword: "Reset Password",
41
- passwordRequiredText: "Password is required",
42
- forgotPasswordText: "Forgot password?",
43
- newUserText: "New user?",
44
- signUpText: "Sign up",
45
- signInText: "Sign in",
46
- googleButtonLabel: "Sign in with Google",
47
- githubButtonLabel: "Sign in with Github",
48
- twitterButtonLabel: "Sign in with Twitter"
49
- }}
50
- {...args}
51
- handleResetPassword={() => console.log("resetting password")}
52
- />
53
- );
54
- };
55
- export const ResetPassword = ResetPasswordTemplate.bind({});
56
- ResetPassword.args = {
57
- showError: false,
58
- sent: false
59
- };
@@ -1,89 +0,0 @@
1
- import React from "react";
2
- import { SignInForm } from "../../../blocks/AuthForms";
3
-
4
- export default {
5
- title: "Blocks/Auth/Sign In",
6
- component: [SignInForm],
7
- argTypes: {
8
- viaGoogle: {
9
- default: true,
10
- control: "boolean",
11
- description: "Display the sign in via Google button",
12
- table: { defaultValue: { summary: true } }
13
- },
14
- viaTwitter: {
15
- default: true,
16
- control: "boolean",
17
- description: "Display the sign in via Twitter button",
18
- table: { defaultValue: { summary: true } }
19
- },
20
- viaGithub: {
21
- default: true,
22
- control: "boolean",
23
- description: "Display the sign in via Github button",
24
- table: { defaultValue: { summary: true } }
25
- },
26
- showError: {
27
- default: false,
28
- control: "boolean",
29
- description: "Display the error when auth fails",
30
- table: { defaultValue: { summary: true } }
31
- },
32
- errorTitle: {
33
- default: " ",
34
- control: "text",
35
- description: "The error text for the auth failure",
36
- table: { defaultValue: { summary: "" } }
37
- },
38
- errorText: {
39
- default: "Something went wrong",
40
- control: "text",
41
- description: "The error text for the auth failure",
42
- table: { defaultValue: { summary: "Something went wrong" } }
43
- }
44
- }
45
- };
46
-
47
- const SignInTemplate = (args) => {
48
- return (
49
- <SignInForm
50
- {...args}
51
- error={args.showError}
52
- texts={{
53
- emailLabel: "Email",
54
- emailPlaceholder: "Enter your email",
55
- emailRequiredText: "Email is required",
56
- emailInvalidText: "Invalid email address",
57
- passwordLabel: "Password",
58
- passwordPlaceholder: "Enter password",
59
- passwordRequiredText: "Password is required",
60
- forgotPasswordText: "Forgot password?",
61
- newUserText: "New user?",
62
- signUpText: "Sign up",
63
- signInText: "Sign in",
64
- googleButtonLabel: "Sign in with Google",
65
- githubButtonLabel: "Sign in with Github",
66
- twitterButtonLabel: "Sign in with Twitter"
67
- }}
68
- handleSignIn={(e) => console.log("singing in via email", e)}
69
- handleForgotPassword={() => console.log("user forgot password")}
70
- handleGoogleSignIn={() => console.log("signing in via google")}
71
- handleGithubSignIn={() => console.log("signing in via github")}
72
- handleTwitterSignIn={() => console.log("signing in via Twitter")}
73
- handleRouteToSignUp={() => console.log("switching to sign up")}
74
- viaGoogle={args.viaGoogle}
75
- viaGithub={args.viaGithub}
76
- viaTwitter={args.viaTwitter}
77
- />
78
- );
79
- };
80
-
81
- export const SignIn = SignInTemplate.bind({});
82
- SignIn.args = {
83
- viaGoogle: true,
84
- viaGithub: true,
85
- viaTwitter: true,
86
- showError: false,
87
- errorTitle: "Error",
88
- errorText: "Something went wrong"
89
- };
@@ -1,90 +0,0 @@
1
- import React from "react";
2
- import { SignUpForm } from "../../../blocks/AuthForms";
3
-
4
- export default {
5
- title: "Blocks/Auth/Sign Up",
6
- component: [SignUpForm],
7
- argTypes: {
8
- viaGoogle: {
9
- default: true,
10
- control: "boolean",
11
- description: "Display the sign in via Google button",
12
- table: { defaultValue: { summary: true } }
13
- },
14
- viaTwitter: {
15
- default: true,
16
- control: "boolean",
17
- description: "Display the sign in via Twitter button",
18
- table: { defaultValue: { summary: true } }
19
- },
20
- viaGithub: {
21
- default: true,
22
- control: "boolean",
23
- description: "Display the sign in via Github button",
24
- table: { defaultValue: { summary: true } }
25
- },
26
- showError: {
27
- default: false,
28
- control: "boolean",
29
- description: "Display the error when auth fails",
30
- table: { defaultValue: { summary: true } }
31
- },
32
- errorTitle: {
33
- default: " ",
34
- control: "text",
35
- description: "The error text for the auth failure",
36
- table: { defaultValue: { summary: "" } }
37
- },
38
- errorText: {
39
- default: "Something went wrong",
40
- control: "text",
41
- description: "The error text for the auth failure",
42
- table: { defaultValue: { summary: "Something went wrong" } }
43
- }
44
- }
45
- };
46
-
47
- const SignUpTemplate = (args) => {
48
- return (
49
- <SignUpForm
50
- {...args}
51
- texts={{
52
- fullNameLabel: "Full Name",
53
- fullNamePlaceholder: "Fulan AlFulani",
54
- emailLabel: "Email",
55
- emailPlaceholder: "Enter your email",
56
- emailRequiredText: "Email is required",
57
- emailInvalidText: "Invalid email address",
58
- passwordLabel: "Password",
59
- passwordPlaceholder: "Minimum 8 characters",
60
- passwordRequiredText: "Password is required",
61
- passwordTooShortText: "Password too short",
62
- forgotPasswordText: "Forgot password?",
63
- newUserText: "New user?",
64
- signUpText: "Sign up",
65
- signInText: "Sign in",
66
- googleButtonLabel: "Sign in with Google",
67
- githubButtonLabel: "Sign in with Github",
68
- twitterButtonLabel: "Sign in with Twitter"
69
- }}
70
- error={args.showError}
71
- viaGoogle={args.viaGoogle}
72
- viaGithub={args.viaGithub}
73
- viaTwitter={args.viaTwitter}
74
- handleSignUp={() => console.log("singing up via email")}
75
- handleGoogleSignUp={() => console.log("signing up via google")}
76
- handleGithubSignUp={() => console.log("signing up via github")}
77
- handleTwitterSignUp={() => console.log("signing up via Twitter")}
78
- handleRouteToSignIn={() => console.log("switching to sign in")}
79
- />
80
- );
81
- };
82
- export const SignUp = SignUpTemplate.bind({});
83
- SignUp.args = {
84
- viaGoogle: true,
85
- viaGithub: true,
86
- viaTwitter: true,
87
- showError: false,
88
- errorTitle: "Error",
89
- errorText: "Something went wrong"
90
- };
@@ -1,30 +0,0 @@
1
- import React from "react";
2
- import { ChargeWalletForm } from "../../../blocks/Payment";
3
-
4
- export default {
5
- title: "Blocks/Payment/Charge Wallet",
6
- component: [ChargeWalletForm],
7
- argTypes: {
8
- viaWallet: { control: "boolean" },
9
- viaApplePay: { control: "boolean" },
10
- viaGooglePay: { control: "boolean" },
11
- viaSTCPay: { control: "boolean" },
12
- viaCreditCard: { control: "boolean" },
13
- viaPayPal: { control: "boolean" }
14
- },
15
- args: {
16
- viaWallet: true,
17
- viaMada: true,
18
- viaApplePay: true,
19
- viaGooglePay: true,
20
- viaSTCPay: true,
21
- viaCreditCard: true,
22
- viaPayPal: true
23
- }
24
- };
25
-
26
- export const ChargeWallet = (args) => {
27
- return <ChargeWalletForm {...args} />;
28
- };
29
-
30
- ChargeWallet.args = { currency: "SAR" };
@@ -1,37 +0,0 @@
1
- import React from "react";
2
- import { CreditCardForm } from "../../../blocks/Payment";
3
-
4
- export default {
5
- title: "Blocks/Payment/Pay Via Credit Card",
6
- component: [CreditCardForm],
7
- argTypes: {
8
- theme: {
9
- options: ["primary", "secondary", "default"],
10
- control: { type: "select" }
11
- },
12
- viaWallet: { control: "boolean" },
13
- viaApplePay: { control: "boolean" },
14
- viaGooglePay: { control: "boolean" },
15
- viaSTCPay: { control: "boolean" },
16
- viaCreditCard: { control: "boolean" },
17
- viaPayPal: { control: "boolean" }
18
- },
19
- args: {
20
- theme: "primary",
21
- viaWallet: true,
22
- viaMada: true,
23
- viaApplePay: true,
24
- viaGooglePay: true,
25
- viaSTCPay: true,
26
- viaCreditCard: true,
27
- viaPayPal: true
28
- }
29
- };
30
-
31
- export const PayViaCreditCard = (args) => {
32
- return <CreditCardForm theme={args.theme} />;
33
- };
34
-
35
- PayViaCreditCard.args = {
36
- theme: "secondary"
37
- };
@@ -1,17 +0,0 @@
1
- import React from "react";
2
- import { PayWithWallet } from "../../../blocks/Payment";
3
-
4
- export default {
5
- title: "Blocks/Payment/Pay Via Wallet",
6
- component: [PayWithWallet],
7
- argTypes: {
8
- walletBalance: { control: "number" }
9
- },
10
- args: {
11
- walletBalance: 20
12
- }
13
- };
14
-
15
- export const PayViaWallet = (args) => {
16
- return <PayWithWallet {...args} />;
17
- };
@@ -1,60 +0,0 @@
1
- import React from "react";
2
- import { SelectPayment } from "../../../blocks/Payment";
3
-
4
- export default {
5
- title: "Blocks/Payment/Payment Selection",
6
- component: [SelectPayment],
7
- argTypes: {
8
- theme: {
9
- options: ["primary", "secondary", "default"],
10
- control: { type: "select" }
11
- },
12
- viaWallet: { control: "boolean" },
13
- viaApplePay: { control: "boolean" },
14
- viaGooglePay: { control: "boolean" },
15
- viaSTCPay: { control: "boolean" },
16
- viaCreditCard: { control: "boolean" },
17
- viaPayPal: { control: "boolean" }
18
- },
19
- args: {
20
- theme: "primary",
21
- viaWallet: true,
22
- viaMada: true,
23
- viaApplePay: true,
24
- viaGooglePay: true,
25
- viaSTCPay: true,
26
- viaCreditCard: true,
27
- viaPayPal: true
28
- }
29
- };
30
-
31
- const PaymentSelectionTemplate = (args) => {
32
- return (
33
- <SelectPayment
34
- {...args}
35
- walletLabel="Wallet Balance"
36
- handleWallet={() => console.log("paying via wallet")}
37
- visaMasterLabel="Credit Card"
38
- handleCreditCard={() => console.log("paying via Credit Card")}
39
- madaLabel="Mada"
40
- handleMada={() => console.log("paying via Mada")}
41
- paypalLabel="PayPal"
42
- handlePayPal={() => console.log("paying via PayPal")}
43
- applePayLabel="Apple Pay"
44
- handleApplePay={() => console.log("paying via Apple Pay")}
45
- googlePayLabel="Google Pay"
46
- handleGooglePay={() => console.log("paying via Google Pay")}
47
- stcPayLabel="STC Pay"
48
- handleSTCPay={() => console.log("paying via STC Pay")}
49
- />
50
- );
51
- };
52
- export const PaymentSelection = PaymentSelectionTemplate.bind({});
53
- PaymentSelection.args = {
54
- viaGoogle: true,
55
- viaGithub: true,
56
- viaTwitter: true,
57
- showError: false,
58
- errorTitle: "Error",
59
- errorText: "Something went wrong"
60
- };
@@ -1,46 +0,0 @@
1
- import React from "react";
2
- import { PricingPlans } from "../../../blocks/Pricing/PricingPlans";
3
-
4
- export default {
5
- title: "Blocks/Pricing/In Billing",
6
- component: [PricingPlans],
7
- argTypes: {}
8
- };
9
-
10
- export const InBilling = (args) => {
11
- return (
12
- <PricingPlans
13
- {...args}
14
- plans={[
15
- {
16
- title: "Free",
17
- subtitle: "For everyone",
18
- price: 0,
19
- currency: "SAR",
20
- cycleText: "Monthly",
21
- buttonText: "Select Plan",
22
- features: ["one", "two", "three"]
23
- },
24
- {
25
- title: "Intro",
26
- subtitle: "For beginners",
27
- selectedPlan: true,
28
- price: 10,
29
- currency: "SAR",
30
- cycleText: "Monthly",
31
- buttonText: "Current Plan",
32
- features: ["one", "two", "three"]
33
- },
34
- {
35
- title: "Pro",
36
- subtitle: "For professionals",
37
- price: 30,
38
- currency: "SAR",
39
- cycleText: "Monthly",
40
- buttonText: "Select Plan",
41
- features: ["one", "two", "three"]
42
- }
43
- ]}
44
- />
45
- );
46
- };
@@ -1,45 +0,0 @@
1
- import React from "react";
2
- import { PricingPlans } from "../../../blocks/Pricing/PricingPlans";
3
-
4
- export default {
5
- title: "Blocks/Pricing/In Landing",
6
- component: [PricingPlans],
7
- argTypes: {}
8
- };
9
-
10
- export const InLanding = (args) => {
11
- return (
12
- <PricingPlans
13
- {...args}
14
- plans={[
15
- {
16
- title: "Free",
17
- subtitle: "For everyone",
18
- price: 0,
19
- currency: "SAR",
20
- cycleText: "Monthly",
21
- buttonText: "Select Plan",
22
- features: ["one", "two", "three"]
23
- },
24
- {
25
- title: "Intro",
26
- subtitle: "For beginners",
27
- price: 10,
28
- currency: "SAR",
29
- cycleText: "Monthly",
30
- buttonText: "Select Plan",
31
- features: ["one", "two", "three"]
32
- },
33
- {
34
- title: "Pro",
35
- subtitle: "For professionals",
36
- price: 30,
37
- currency: "SAR",
38
- cycleText: "Monthly",
39
- buttonText: "Select Plan",
40
- features: ["one", "two", "three"]
41
- }
42
- ]}
43
- />
44
- );
45
- };
@@ -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
- };