@sikka/hawa 0.0.25 → 0.0.28

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 (44) hide show
  1. package/README.md +11 -102
  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 +2 -4
  6. package/src/blocks/AuthForms/NewPasswordForm.js +5 -4
  7. package/src/blocks/AuthForms/ResetPasswordForm.js +6 -0
  8. package/src/blocks/AuthForms/SignInForm.js +12 -2
  9. package/src/blocks/AuthForms/SignUpForm.js +10 -8
  10. package/src/blocks/Payment/ChargeWalletForm.js +9 -7
  11. package/src/blocks/Payment/CheckoutForm.js +11 -1
  12. package/src/blocks/Payment/Confirmation.js +18 -23
  13. package/src/blocks/Payment/PaymentMethod.js +8 -3
  14. package/src/blocks/Payment/SelectPayment.js +18 -7
  15. package/src/blocks/Pricing/PricingPlans.js +6 -0
  16. package/src/elements/ActionButton.js +0 -33
  17. package/src/elements/AdaptiveButton.js +1 -0
  18. package/src/elements/HawaAlert.js +8 -1
  19. package/src/elements/HawaButton.js +0 -41
  20. package/src/elements/HawaCheckbox.js +0 -1
  21. package/src/elements/HawaInputLabel.js +1 -23
  22. package/src/elements/HawaItemCard.js +5 -5
  23. package/src/elements/HawaLogoButton.js +13 -1
  24. package/src/elements/HawaPopMenu.js +6 -0
  25. package/src/elements/HawaPricingCard.js +14 -0
  26. package/src/elements/HawaRadio.js +7 -0
  27. package/src/elements/HawaTextArea.js +20 -32
  28. package/src/elements/HawaTextField.js +16 -20
  29. package/src/elements/TabPanel.js +0 -1
  30. package/src/elements/index.js +2 -1
  31. package/src/layout/Box.js +1 -37
  32. package/src/styles.css +3 -351
  33. package/storybook-static/iframe.html +1 -1
  34. package/storybook-static/index.html +1 -1
  35. package/storybook-static/{main.ac6e4b72b033097dad76.manager.bundle.js → main.9d5968bcf15d21f5487c.manager.bundle.js} +0 -0
  36. package/storybook-static/main.9dd59e4f.iframe.bundle.js +1 -0
  37. package/storybook-static/vendors~main.b026595c.iframe.bundle.js +76 -0
  38. package/storybook-static/{vendors~main.741b86a0.iframe.bundle.js.LICENSE.txt → vendors~main.b026595c.iframe.bundle.js.LICENSE.txt} +0 -0
  39. package/storybook-static/vendors~main.b026595c.iframe.bundle.js.map +1 -0
  40. package/src/elements/Hawa.js +0 -3
  41. package/src/elements/Row.js +0 -21
  42. package/storybook-static/main.06257453.iframe.bundle.js +0 -1
  43. package/storybook-static/vendors~main.741b86a0.iframe.bundle.js +0 -76
  44. package/storybook-static/vendors~main.741b86a0.iframe.bundle.js.map +0 -1
@@ -1,38 +1,26 @@
1
+ import { useTheme } from "@mui/system";
1
2
  import React from "react";
2
- import { Controller, useFormContext } from "react-hook-form";
3
- import { StyledInputLabel } from ".";
4
3
 
5
4
  export const HawaTextArea = (props) => {
6
- const { control } = useFormContext();
7
- const { name, rules, shouldUnregister, inputLabel, helperText } = props;
8
-
5
+ const theme = useTheme();
6
+ console.log("theme is ", theme);
9
7
  return (
10
- <Controller
11
- render={({ field }) => (
12
- <label>
13
- {inputLabel ? <StyledInputLabel label={inputLabel} /> : null}
14
- <textarea
15
- style={{
16
- color: "black",
17
- backgroundColor: props.bgColor || "white",
18
- // borderRadius: props.bdRadius || 10,
19
- borderBottom: "none",
20
- border: "none",
21
- width: "100%",
22
- padding: 0,
23
- margin: 0,
24
- marginBottom: 0,
25
- resize: props.resize || "vertical"
26
- }}
27
- value={field.value ?? ""}
28
- {...field}
29
- />
30
- </label>
31
- )}
32
- name={name}
33
- rules={rules}
34
- control={control}
35
- shouldUnregister={shouldUnregister}
36
- />
8
+ <label>
9
+ {/* {inputLabel ? <StyledInputLabel label={inputLabel} /> : null} */}
10
+ <textarea
11
+ style={{
12
+ color: "black",
13
+ backgroundColor: props.bgColor || "white",
14
+ borderBottom: "none",
15
+ border: "none",
16
+ width: "100%",
17
+ padding: 0,
18
+ margin: 0,
19
+ marginBottom: 0,
20
+ resize: props.resize || "vertical"
21
+ }}
22
+ // value={field.value ?? ""}
23
+ />
24
+ </label>
37
25
  );
38
26
  };
@@ -5,28 +5,24 @@ import Typography from "@mui/material/Typography";
5
5
 
6
6
  export const HawaTextField = (props) => {
7
7
  return (
8
- <div
9
- style={
10
- props.inForm && {
11
- width: "100%"
12
- }
13
- }
14
- >
15
- <div
16
- style={{
17
- display: "flex",
18
- flexDirection: "row",
19
- justifyContent: "space-between",
20
- alignItems: "center"
21
- }}
22
- >
23
- {props.label && <InputLabel>{props.label}</InputLabel>}
8
+ <div style={props.inForm && { width: "100%" }}>
9
+ <div style={{ width: props.fullWidth ? "100%" : "fit-content" }}>
10
+ <div
11
+ style={{
12
+ display: "flex",
13
+ flexDirection: "row",
14
+ justifyContent: "space-between",
15
+ alignItems: "center"
16
+ }}
17
+ >
18
+ {props.label && <InputLabel>{props.label}</InputLabel>}
24
19
 
25
- {props.helperText && (
26
- <Typography variant="validation">{props.helperText}</Typography>
27
- )}
20
+ {props.helperText && (
21
+ <Typography variant="validation">{props.helperText}</Typography>
22
+ )}
23
+ </div>
24
+ <Input disableUnderline {...props} />
28
25
  </div>
29
- <Input disableUnderline {...props} />
30
26
  </div>
31
27
  );
32
28
  };
@@ -8,7 +8,6 @@ const useStyles = makeStyles((theme) => ({
8
8
  },
9
9
  panel: {
10
10
  backgroundColor: "var(--lightGrey)",
11
- // borderRadius: "var(--borderR)",
12
11
  height: "100%",
13
12
  width: "100%",
14
13
  padding: 10
@@ -1,5 +1,6 @@
1
1
  export * from "./AdaptiveButton";
2
2
  export * from "./ActionButton";
3
+ export * from "./OfflineBanner";
3
4
  export * from "./HawaCheckbox";
4
5
  export * from "./HawaRadio";
5
6
  export * from "./HawaItemCard";
@@ -9,8 +10,8 @@ export * from "./HawaLogoButton";
9
10
  export * from "./HawaButton";
10
11
  export * from "./HawaSelect";
11
12
  export * from "./HawaTextField";
13
+ export * from "./HawaTextArea";
12
14
  export * from "./HawaInputLabel";
13
15
  export * from "./HawaTypography";
14
16
  export * from "./HawaAlert";
15
17
  export * from "./HawaTable";
16
- export * from "./OfflineBanner";
package/src/layout/Box.js CHANGED
@@ -1,41 +1,5 @@
1
1
  import React from "react";
2
2
 
3
3
  export const Box = (props) => {
4
- // let boxStyle = {};
5
-
6
- // let currentTheme = Object.keys(hawaTheme.layout).find(
7
- // (tName) => tName.toLowerCase() === themeName?.toLowerCase()
8
- // );
9
- // if (currentTheme) {
10
- // boxStyle = {
11
- // display: "flex",
12
- // flexDirection: props.horizontal ? "row" : "column",
13
- // ...hawaTheme?.layout[currentTheme],
14
- // backgroundColor: props.noColor
15
- // ? "none"
16
- // : hawaTheme.layout[currentTheme].backgroundColor,
17
- // padding: props.noPadding ? 0 : hawaTheme?.layout[currentTheme].padding,
18
- // margin: props.noMargin ? 0 : hawaTheme?.layout[currentTheme].margin,
19
- // maxWidth: props.maxWidth
20
- // };
21
- // } else {
22
- // boxStyle = {
23
- // display: "flex",
24
- // flexDirection: props.horizontal ? "row" : "column",
25
- // color: "white",
26
- // marginTop: props.last ? 10 * 2 : 0,
27
- // backgroundColor: props.noColor ? "none" : "lightGrey",
28
- // padding: props.noPadding ? 0 : 10,
29
- // margin: props.noMargin ? 0 : 10,
30
- // maxWidth: props.maxWidth,
31
- // };
32
- // }
33
-
34
- return (
35
- <div
36
- // style={boxStyle}
37
- >
38
- {props.children}
39
- </div>
40
- );
4
+ return <div>{props.children}</div>;
41
5
  };
package/src/styles.css CHANGED
@@ -1,98 +1,3 @@
1
-
2
- .reset_password_root {
3
- display: flex;
4
- flex-direction: column;
5
- justify-content: center;
6
- align-items: center;
7
- flex-grow: 1;
8
- background-color: var(--light);
9
- }
10
- .reset_password_paper {
11
- margin-top: 8px;
12
- display: flex;
13
- flex-direction: column;
14
- align-items: center;
15
- }
16
- /* START INDEX.JS */
17
- .index_root {
18
- height: 100vh;
19
- display: flex;
20
- flex-direction: column;
21
- justify-content: center;
22
- align-items: center;
23
- }
24
- .index_logo {
25
- height: 70px;
26
- display: flex;
27
- flex-direction: column;
28
- justify-content: center;
29
- align-items: center;
30
- }
31
- .index_buttons_container {
32
- margin-top: 20px;
33
- display: flex;
34
- flex-direction: column;
35
- justify-content: center;
36
- align-items: center;
37
- }
38
- /* END INDEX.js */
39
- .account_section {
40
- display: flex;
41
- flex-direction: column;
42
- align-items: center;
43
- margin: 10px;
44
- /* max-width: 400px; */
45
- /* background-color: black; */
46
- }
47
- .account_deactivate {
48
- text-align: center;
49
- opacity: 1;
50
- font-size: 13px;
51
- color: red;
52
- padding: 5px;
53
- cursor: pointer;
54
- width: fit-content;
55
- }
56
- .text_button {
57
- cursor: pointer;
58
- color: var(--blue);
59
- font-weight: 500;
60
- }
61
- .bottom_text {
62
- margin-top: 10px;
63
- font-size: 14px;
64
- }
65
- .newsletter_container {
66
- display: flex;
67
- align-items: center;
68
- justify-content: flex-start;
69
- flex-direction: row;
70
- margin-top: 15px;
71
- }
72
- .modalTEST {
73
- background-color: red;
74
- width: 10px;
75
- }
76
- .modal_theme {
77
- background-color: black;
78
- opacity: 0.3;
79
- border: none;
80
- }
81
- .user_form {
82
- background-color: var(--lightGrey);
83
- padding: 20px;
84
- border-radius: var(--borderR);
85
- margin-bottom: 20px;
86
- margin-top: 10px;
87
- }
88
- .user_form_container {
89
- display: flex;
90
- flex-direction: column;
91
- justify-content: center;
92
- width: 90%;
93
- max-width: 400px;
94
- height: 100vh;
95
- }
96
1
  .input {
97
2
  color: black;
98
3
  background-color: var(--light);
@@ -101,14 +6,7 @@
101
6
  border-bottom: none;
102
7
  border: none;
103
8
  }
104
- .balanceInput {
105
- color: black;
106
- background-color: var(--light);
107
- padding: 10px;
108
- border-radius: var(--borderR);
109
- border-bottom: none;
110
- border: none;
111
- }
9
+
112
10
  .theme_form_input {
113
11
  color: black;
114
12
  background-color: var(--light);
@@ -117,33 +15,7 @@
117
15
  border: none;
118
16
  width: 100%;
119
17
  }
120
- .theme_input {
121
- color: black;
122
- background-color: var(--light);
123
- padding: 10px;
124
- border-radius: var(--borderR);
125
- border-bottom: none;
126
- border: none;
127
- width: 100%;
128
- }
129
- .theme_input2 {
130
- color: black;
131
- background-color: var(--light);
132
- /* padding: 10px; */
133
- border-radius: var(--borderR);
134
- border-bottom: none;
135
- border: none;
136
- width: 100%;
137
- }
138
- .theme_input2 input {
139
- color: black;
140
- background-color: var(--light);
141
- padding: 10px;
142
- border-radius: var(--borderR);
143
- border-bottom: none;
144
- border: none;
145
- width: 100%;
146
- }
18
+
147
19
  .theme_form_input input {
148
20
  color: black;
149
21
  background-color: var(--light);
@@ -153,37 +25,7 @@
153
25
  border: none;
154
26
  width: 100%;
155
27
  }
156
- .form_textarea {
157
- color: black;
158
- background-color: var(--light);
159
- border-radius: var(--borderR);
160
- border-bottom: none;
161
- border: none;
162
- width: 100%;
163
- padding: 0px;
164
- margin: 0px;
165
- margin-bottom: 0px;
166
- resize: vertical;
167
- }
168
28
 
169
- .input_label {
170
- font-size: 15px;
171
- font-weight: 500;
172
- position: relative;
173
- /* margin-top: 10px; */
174
- margin: 15px;
175
- margin-left: 0px;
176
- }
177
- .loading_overlay {
178
- position: absolute;
179
- display: grid;
180
- place-items: center;
181
- height: 100%;
182
- width: 100%;
183
- z-index: 2;
184
- padding: 0;
185
- margin: 0px;
186
- }
187
29
  .inputLabel {
188
30
  font-size: 20px;
189
31
  margin-bottom: 10px;
@@ -191,173 +33,7 @@
191
33
 
192
34
  position: relative;
193
35
  }
194
- .navbar_root_container {
195
- /* flex-grow: 1; */
196
- padding-right: 10px;
197
- padding-left: 10px;
198
- width: 100%;
199
- background-color: blue;
200
- }
201
- .navbar_container {
202
- display: flex;
203
- flex-direction: row;
204
- justify-content: space-between;
205
- align-items: center;
206
- padding-right: 10px;
207
- padding-left: 10px;
208
- /* background-color: white; */
209
- }
210
- .navbar_logo {
211
- display: flex;
212
- justify-content: flex-start;
213
- align-items: center;
214
- height: 70px;
215
- cursor: pointer;
216
- padding: 0px;
217
- }
218
- .navbar_button {
219
- color: black;
220
- background-color: var(--light);
221
- box-shadow: none;
222
- /* border: 1px solid var(--blue); */
223
- }
224
- .navbar_button_primary {
225
- color: var(--light);
226
- background-color: var(--blue);
227
- box-shadow: none;
228
- }
229
- .error_page {
230
- /* background-color: green; */
231
- display: flex;
232
- flex-direction: column;
233
- justify-content: center;
234
- align-items: center;
235
- text-align: center;
236
- height: 100vh;
237
- }
238
- .error_page_text_main {
239
- /* background-color: darkgoldenrod; */
240
- padding: 10px;
241
- font-size: 30px;
242
- font-weight: 500;
243
- }
244
- .error_page_text_second {
245
- /* background-color: darkorchid; */
246
- padding: 10px;
247
- }
248
- .radio_selector_container {
249
- background-color: white;
250
- display: flex;
251
- flex-direction: row;
252
- border-radius: var(--borderR);
253
- margin-bottom: 10px;
254
- }
255
- .radio_option {
256
- background-color: var(--lightGrey);
257
- border-radius: var(--borderR);
258
- margin: 5px;
259
- padding: 10px;
260
- width: 100%;
261
- justify-content: center;
262
- align-items: center;
263
- text-align: center;
264
- font-size: 14px;
265
- cursor: pointer;
266
- white-space: nowrap;
267
- }
268
- .settings_row {
269
- background-color: var(--light);
270
- border-radius: var(--borderR);
271
- display: flex;
272
- flex-direction: row;
273
- justify-content: space-between;
274
- align-items: center;
275
- height: 50px;
276
- padding: 10px;
277
- width: 100%;
278
- }
279
- .settings_row_actions {
280
- background-color: rgb(223, 221, 221);
281
- width: 100%;
282
- max-width: 200px;
283
- border-radius: var(--borderR);
284
- }
285
- .white_button {
286
- background-color: rgb(223, 221, 221);
287
- padding: 10px;
288
- /* margin: 10px; */
289
- width: 100px;
290
- text-align: center;
291
- cursor: pointer;
292
- border-radius: var(--borderR);
293
- /* border-radius: 0 var(--borderR) var(--borderR) 0; */
294
- }
295
- .blue_button {
296
- background-color: var(--blue);
297
- color: white;
298
- padding: 10px;
299
- /* margin: 10px; */
300
- width: 100px;
301
- text-align: center;
302
- cursor: pointer;
303
- border-radius: var(--borderR);
304
- /* border-radius: var(--borderR) 0 0 var(--borderR); */
305
- }
306
- .route_loading {
307
- position: fixed;
308
- bottom: 20px;
309
- right: 20px;
310
- background-color: var(--blue);
311
- border-radius: var(--borderR);
312
- padding: 10px;
313
- height: 50px;
314
- width: 50px;
315
- display: flex;
316
- justify-content: center;
317
- align-items: center;
318
- z-index: 400;
319
- }
320
- .offline_banner {
321
- position: fixed;
322
- bottom: 20px;
323
- left: 20px;
324
- /* background-color: var(--red); */
325
- background-color: red;
326
- border-radius: var(--borderR);
327
- padding: 10px;
328
- height: 50px;
329
- /* width: 50px; */
330
- display: flex;
331
- justify-content: center;
332
- align-items: center;
333
- z-index: 400;
334
- color: white;
335
- }
336
- .language_modal_button {
337
- background-color: var(--blue);
338
- padding: 10px;
339
- height: 100%;
340
- width: 100%;
341
- border-radius: var(--borderR);
342
- text-align: center;
343
- color: white;
344
- margin: 10px;
345
- }
346
- .language_modal_buttons_container {
347
- margin: 10px;
348
- display: flex;
349
- flex-direction: row;
350
- justify-content: space-between;
351
- }
352
- .language_modal_root {
353
- display: flex;
354
- flex-direction: row;
355
- justify-content: space-between;
356
- padding: 20px;
357
- font-size: 20px;
358
- font-weight: 700px;
359
- width: 100%;
360
- }
36
+
361
37
  /* DragDropMenuLogo */
362
38
  .upload_error_container {
363
39
  background-color: #f44336;
@@ -375,27 +51,3 @@
375
51
  border-width: 2px;
376
52
  cursor: pointer;
377
53
  }
378
- @media (max-width: 600px) {
379
- .radio_selector_container {
380
- width: 100%;
381
- flex-wrap: wrap;
382
- }
383
- .settings_row {
384
- flex-wrap: wrap;
385
- height: auto;
386
- }
387
- .white_button {
388
- width: 100%;
389
- }
390
- .blue_button {
391
- width: 100%;
392
- }
393
- .settings_row_actions {
394
- width: 100%;
395
- max-width: 100%;
396
- }
397
- .settings_row_title {
398
- margin-bottom: 10px;
399
- margin-top: 10px;
400
- }
401
- }
@@ -345,4 +345,4 @@
345
345
 
346
346
 
347
347
 
348
- window['STORIES'] = [{"titlePrefix":"","directory":"./src","files":"**/*.stories.mdx","importPathMatcher":"^\\.[\\\\/](?:src(?:[\\\\/](?!\\.)(?:(?:(?!(?:^|[\\\\/])\\.).)*?)[\\\\/]|[\\\\/]|$)(?!\\.)(?=.)[^\\\\/]*?\\.stories\\.mdx)$"},{"titlePrefix":"","directory":"./src","files":"**/*.stories.@(js|jsx|ts|tsx)","importPathMatcher":"^\\.[\\\\/](?:src(?:[\\\\/](?!\\.)(?:(?:(?!(?:^|[\\\\/])\\.).)*?)[\\\\/]|[\\\\/]|$)(?!\\.)(?=.)[^\\\\/]*?\\.stories\\.(js|jsx|ts|tsx))$"}];</script><script src="runtime~main.708d7ac1.iframe.bundle.js"></script><script src="vendors~main.741b86a0.iframe.bundle.js"></script><script src="main.06257453.iframe.bundle.js"></script></body></html>
348
+ window['STORIES'] = [{"titlePrefix":"","directory":"./src","files":"**/*.stories.mdx","importPathMatcher":"^\\.[\\\\/](?:src(?:[\\\\/](?!\\.)(?:(?:(?!(?:^|[\\\\/])\\.).)*?)[\\\\/]|[\\\\/]|$)(?!\\.)(?=.)[^\\\\/]*?\\.stories\\.mdx)$"},{"titlePrefix":"","directory":"./src","files":"**/*.stories.@(js|jsx|ts|tsx)","importPathMatcher":"^\\.[\\\\/](?:src(?:[\\\\/](?!\\.)(?:(?:(?!(?:^|[\\\\/])\\.).)*?)[\\\\/]|[\\\\/]|$)(?!\\.)(?=.)[^\\\\/]*?\\.stories\\.(js|jsx|ts|tsx))$"}];</script><script src="runtime~main.708d7ac1.iframe.bundle.js"></script><script src="vendors~main.b026595c.iframe.bundle.js"></script><script src="main.9dd59e4f.iframe.bundle.js"></script></body></html>
@@ -56,4 +56,4 @@
56
56
 
57
57
 
58
58
 
59
- window['DOCS_MODE'] = false;</script><script src="runtime~main.c8dac23bc753439736f0.manager.bundle.js"></script><script src="vendors~main.a697e07137d366f95f76.manager.bundle.js"></script><script src="main.ac6e4b72b033097dad76.manager.bundle.js"></script></body></html>
59
+ window['DOCS_MODE'] = false;</script><script src="runtime~main.c8dac23bc753439736f0.manager.bundle.js"></script><script src="vendors~main.a697e07137d366f95f76.manager.bundle.js"></script><script src="main.9d5968bcf15d21f5487c.manager.bundle.js"></script></body></html>