@sikka/hawa 0.0.211 → 0.0.213
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/styles.css +49 -59
- package/es/blocks/Misc/Newsletter.d.ts +1 -0
- package/es/blocks/Misc/NotFound.d.ts +5 -0
- package/es/blocks/Pricing/ComparingPlans.d.ts +1 -0
- package/es/elements/HawaPanelTabs.d.ts +4 -1
- package/es/elements/HawaRange.d.ts +1 -1
- package/es/elements/HawaSelect.d.ts +5 -5
- package/es/elements/HawaSettingsRow.d.ts +1 -1
- package/es/elements/HawaSwitch.d.ts +1 -0
- package/es/elements/InvoiceAccordion.d.ts +4 -4
- package/es/index.es.js +1 -1
- package/es/layout/AppSidebar.d.ts +1 -1
- package/lib/blocks/Misc/Newsletter.d.ts +1 -0
- package/lib/blocks/Misc/NotFound.d.ts +5 -0
- package/lib/blocks/Pricing/ComparingPlans.d.ts +1 -0
- package/lib/elements/HawaPanelTabs.d.ts +4 -1
- package/lib/elements/HawaRange.d.ts +1 -1
- package/lib/elements/HawaSelect.d.ts +5 -5
- package/lib/elements/HawaSettingsRow.d.ts +1 -1
- package/lib/elements/HawaSwitch.d.ts +1 -0
- package/lib/elements/InvoiceAccordion.d.ts +4 -4
- package/lib/index.js +1 -1
- package/lib/layout/AppSidebar.d.ts +1 -1
- package/package.json +1 -1
- package/src/blocks/AuthForms/CodeConfirmation.tsx +1 -7
- package/src/blocks/Misc/EmptyState.tsx +1 -0
- package/src/blocks/Misc/Newsletter.tsx +8 -3
- package/src/blocks/Misc/NotFound.tsx +11 -3
- package/src/blocks/Payment/ChargeWalletForm.tsx +23 -14
- package/src/blocks/Payment/CheckoutForm.tsx +1 -14
- package/src/blocks/Payment/Confirmation.tsx +0 -1
- package/src/blocks/Payment/PayWithWallet.tsx +0 -1
- package/src/blocks/Payment/index.ts +6 -20
- package/src/blocks/Pricing/ComparingPlans.tsx +15 -10
- package/src/blocks/Pricing/PricingPlans.tsx +1 -0
- package/src/blocks/Referral/ReferralAccount.tsx +1 -1
- package/src/blocks/Referral/ReferralStats.tsx +0 -1
- package/src/elements/DragDropImages.tsx +156 -158
- package/src/elements/DraggableCard.tsx +2 -1
- package/src/elements/HawaAccordion.tsx +1 -1
- package/src/elements/HawaChip.tsx +2 -1
- package/src/elements/HawaColorPicker.tsx +3 -5
- package/src/elements/HawaItemCard.tsx +1 -2
- package/src/elements/HawaMenu.tsx +2 -3
- package/src/elements/HawaModal.tsx +1 -1
- package/src/elements/HawaPanelTabs.tsx +1 -7
- package/src/elements/HawaPricingCard.tsx +1 -7
- package/src/elements/HawaRadio.tsx +1 -1
- package/src/elements/HawaRange.tsx +1 -1
- package/src/elements/HawaSelect.tsx +38 -36
- package/src/elements/HawaSettingsRow.tsx +7 -5
- package/src/elements/HawaSnackbar.tsx +1 -1
- package/src/elements/HawaSpinner.tsx +2 -2
- package/src/elements/HawaSwitch.tsx +19 -2
- package/src/elements/HawaTable.tsx +3 -1
- package/src/elements/HawaTabs.tsx +2 -0
- package/src/elements/HawaTextField.tsx +1 -0
- package/src/elements/HawaTooltip.tsx +1 -3
- package/src/elements/InvoiceAccordion.tsx +5 -5
- package/src/layout/AppSidebar.tsx +1 -1
- package/src/layout/HawaAppLayout.tsx +5 -4
- package/src/layout/HawaContainer.tsx +0 -1
- package/src/layout/HawaSiteLayout.tsx +1 -3
- package/src/layout/SimpleGrid.tsx +2 -3
- package/src/styles.css +49 -59
- package/src/tailwind.css +4 -8
- package/tailwind.config.js +3 -1
package/package.json
CHANGED
|
@@ -1,11 +1,5 @@
|
|
|
1
1
|
import React, { useState } from "react"
|
|
2
|
-
import {
|
|
3
|
-
HawaTextField,
|
|
4
|
-
HawaAlert,
|
|
5
|
-
HawaButton,
|
|
6
|
-
HawaPinInput,
|
|
7
|
-
} from "../../elements"
|
|
8
|
-
import { Controller, useForm } from "react-hook-form"
|
|
2
|
+
import { HawaAlert, HawaButton, HawaPinInput } from "../../elements"
|
|
9
3
|
import { HawaContainer } from "../../layout"
|
|
10
4
|
|
|
11
5
|
type TConfirmation = {
|
|
@@ -7,6 +7,7 @@ type TNewsletter = {
|
|
|
7
7
|
texts: {
|
|
8
8
|
wantToStayUpdated: string
|
|
9
9
|
subscribeToNewsletter: string
|
|
10
|
+
submit: string
|
|
10
11
|
}
|
|
11
12
|
handleNewsletterSub: (e: string) => void
|
|
12
13
|
}
|
|
@@ -19,8 +20,12 @@ export const Newsletter: React.FunctionComponent<TNewsletter> = ({
|
|
|
19
20
|
return (
|
|
20
21
|
<HawaContainer variant={variant} centered={true}>
|
|
21
22
|
<div className="p-4 pt-0">
|
|
22
|
-
<h1 className="font-bold">
|
|
23
|
-
|
|
23
|
+
<h1 className="font-bold">
|
|
24
|
+
{texts.wantToStayUpdated ?? "Want to stay updated?"}
|
|
25
|
+
</h1>
|
|
26
|
+
<span>
|
|
27
|
+
{texts.subscribeToNewsletter ?? "Subscribe to our newsletter"}
|
|
28
|
+
</span>
|
|
24
29
|
</div>
|
|
25
30
|
<form
|
|
26
31
|
className="flex flex-row gap-2"
|
|
@@ -37,7 +42,7 @@ export const Newsletter: React.FunctionComponent<TNewsletter> = ({
|
|
|
37
42
|
margin="none"
|
|
38
43
|
/>
|
|
39
44
|
<HawaButton size="full" margins="none">
|
|
40
|
-
Submit
|
|
45
|
+
{texts.submit ?? "Submit"}
|
|
41
46
|
</HawaButton>
|
|
42
47
|
</form>
|
|
43
48
|
</HawaContainer>
|
|
@@ -4,21 +4,29 @@ import { HawaContainer } from "../../layout"
|
|
|
4
4
|
|
|
5
5
|
type NotFoundTypes = {
|
|
6
6
|
variant?: "outlined" | "contained" | "neobrutalism"
|
|
7
|
+
texts?: {
|
|
8
|
+
pageNotFound: string
|
|
9
|
+
ifLost: string
|
|
10
|
+
home: string
|
|
11
|
+
}
|
|
7
12
|
}
|
|
8
13
|
|
|
9
14
|
export const NotFound: React.FunctionComponent<NotFoundTypes> = ({
|
|
10
15
|
variant,
|
|
16
|
+
texts,
|
|
11
17
|
}) => {
|
|
12
18
|
return (
|
|
13
19
|
<HawaContainer variant={variant}>
|
|
14
20
|
<div className="flex flex-col items-center dark:text-white">
|
|
15
21
|
<div className="text-center text-6xl font-bold ">404</div>
|
|
16
|
-
<div className="m-2 text-center text-xl font-bold ">
|
|
22
|
+
<div className="m-2 text-center text-xl font-bold ">
|
|
23
|
+
{texts.pageNotFound ?? "Page Not Found"}
|
|
24
|
+
</div>
|
|
17
25
|
<div className="text-center ">
|
|
18
|
-
If you're lost please contact us help@sikka.io
|
|
26
|
+
{texts.ifLost ?? "If you're lost please contact us help@sikka.io"}
|
|
19
27
|
</div>
|
|
20
28
|
<HawaButton color="primary" width="full">
|
|
21
|
-
Home
|
|
29
|
+
{texts.home ?? "Home"}
|
|
22
30
|
</HawaButton>
|
|
23
31
|
</div>
|
|
24
32
|
</HawaContainer>
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import React, { useState } from "react"
|
|
2
|
-
import { HawaButton
|
|
3
|
-
import { Controller, FormProvider, useForm } from "react-hook-form"
|
|
2
|
+
import { HawaButton } from "../../elements"
|
|
4
3
|
import { HawaContainer } from "../../layout"
|
|
5
4
|
|
|
6
5
|
type ChargeWalletTypes = {
|
|
@@ -16,21 +15,28 @@ export const ChargeWalletForm: React.FunctionComponent<ChargeWalletTypes> = (
|
|
|
16
15
|
props
|
|
17
16
|
) => {
|
|
18
17
|
const [walletAmount, setWalletAmount] = useState(0)
|
|
19
|
-
const methods = useForm()
|
|
20
|
-
const {
|
|
21
|
-
formState: { errors },
|
|
22
|
-
handleSubmit,
|
|
23
|
-
control,
|
|
24
|
-
} = methods
|
|
25
18
|
|
|
26
19
|
return (
|
|
27
20
|
<HawaContainer>
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
21
|
+
<div className="p-4 text-center">
|
|
22
|
+
<div className=" text-5xl font-extrabold">
|
|
23
|
+
{Number(walletAmount).toLocaleString("en") || "0"}
|
|
24
|
+
</div>
|
|
31
25
|
<div className="text-sm font-normal">{props.currency || "SAR"}</div>
|
|
32
26
|
</div>
|
|
33
|
-
<
|
|
27
|
+
<div className="mb-2 flex w-full flex-row gap-2 text-center">
|
|
28
|
+
<div className="w-40 whitespace-nowrap rounded bg-gray-100 p-4">
|
|
29
|
+
10 SAR
|
|
30
|
+
</div>
|
|
31
|
+
<div className="w-40 whitespace-nowrap rounded bg-gray-100 p-4">
|
|
32
|
+
100 SAR
|
|
33
|
+
</div>
|
|
34
|
+
<input
|
|
35
|
+
placeholder="Custom"
|
|
36
|
+
className="h-auto rounded bg-gray-100 p-4"
|
|
37
|
+
/>
|
|
38
|
+
</div>
|
|
39
|
+
{/* <FormProvider {...methods}>
|
|
34
40
|
<form onSubmit={handleSubmit(props.handleChargeWallet)}>
|
|
35
41
|
<Controller
|
|
36
42
|
control={control}
|
|
@@ -67,8 +73,11 @@ export const ChargeWalletForm: React.FunctionComponent<ChargeWalletTypes> = (
|
|
|
67
73
|
>
|
|
68
74
|
{props.texts.chargeWallet}
|
|
69
75
|
</HawaButton>
|
|
70
|
-
|
|
71
|
-
|
|
76
|
+
</form>
|
|
77
|
+
</FormProvider> */}
|
|
78
|
+
<HawaButton color="primary" width="full">
|
|
79
|
+
{props.texts.chargeWallet}
|
|
80
|
+
</HawaButton>
|
|
72
81
|
</HawaContainer>
|
|
73
82
|
)
|
|
74
83
|
}
|
|
@@ -109,7 +109,6 @@ export const CheckoutForm: React.FunctionComponent<CheckoutFormTypes> = (
|
|
|
109
109
|
rules={{ required: props.texts?.required }}
|
|
110
110
|
render={({ field }) => (
|
|
111
111
|
<HawaTextField
|
|
112
|
-
// inForm
|
|
113
112
|
width="full"
|
|
114
113
|
type="text"
|
|
115
114
|
label={props.texts?.lastNameLabel + " *"}
|
|
@@ -125,7 +124,6 @@ export const CheckoutForm: React.FunctionComponent<CheckoutFormTypes> = (
|
|
|
125
124
|
name="email"
|
|
126
125
|
render={({ field }) => (
|
|
127
126
|
<HawaTextField
|
|
128
|
-
// inForm
|
|
129
127
|
width="full"
|
|
130
128
|
type="text"
|
|
131
129
|
label={props.texts?.emailLabel + " *"}
|
|
@@ -150,7 +148,6 @@ export const CheckoutForm: React.FunctionComponent<CheckoutFormTypes> = (
|
|
|
150
148
|
rules={{ required: props.texts?.required }}
|
|
151
149
|
render={({ field }) => (
|
|
152
150
|
<HawaTextField
|
|
153
|
-
// inForm
|
|
154
151
|
width="full"
|
|
155
152
|
type="text"
|
|
156
153
|
label={props.texts?.streetAddressLabel + " *"}
|
|
@@ -168,7 +165,6 @@ export const CheckoutForm: React.FunctionComponent<CheckoutFormTypes> = (
|
|
|
168
165
|
rules={{ required: props.texts?.required }}
|
|
169
166
|
render={({ field }) => (
|
|
170
167
|
<HawaTextField
|
|
171
|
-
// inForm
|
|
172
168
|
width="full"
|
|
173
169
|
type="text"
|
|
174
170
|
label={props.texts?.buildingNumberLabel + " *"}
|
|
@@ -187,7 +183,6 @@ export const CheckoutForm: React.FunctionComponent<CheckoutFormTypes> = (
|
|
|
187
183
|
rules={{ required: props.texts?.required }}
|
|
188
184
|
render={({ field }) => (
|
|
189
185
|
<HawaTextField
|
|
190
|
-
// inForm
|
|
191
186
|
width="full"
|
|
192
187
|
type="text"
|
|
193
188
|
label={props.texts?.stateLabel + " *"}
|
|
@@ -205,7 +200,6 @@ export const CheckoutForm: React.FunctionComponent<CheckoutFormTypes> = (
|
|
|
205
200
|
rules={{ required: props.texts?.required }}
|
|
206
201
|
render={({ field }) => (
|
|
207
202
|
<HawaTextField
|
|
208
|
-
// inForm
|
|
209
203
|
width="full"
|
|
210
204
|
type="text"
|
|
211
205
|
label={props.texts?.cityLabel + " *"}
|
|
@@ -223,10 +217,8 @@ export const CheckoutForm: React.FunctionComponent<CheckoutFormTypes> = (
|
|
|
223
217
|
rules={{ required: props.texts?.required }}
|
|
224
218
|
render={({ field }) => (
|
|
225
219
|
<HawaTextField
|
|
226
|
-
// inForm
|
|
227
220
|
width="full"
|
|
228
221
|
type="number"
|
|
229
|
-
// variant="unscrollable"
|
|
230
222
|
label={props.texts?.zipCodeLabel + " *"}
|
|
231
223
|
helperText={errors.zipCode?.message}
|
|
232
224
|
{...field}
|
|
@@ -248,7 +240,6 @@ export const CheckoutForm: React.FunctionComponent<CheckoutFormTypes> = (
|
|
|
248
240
|
helperText={errors.country?.message}
|
|
249
241
|
options={countries}
|
|
250
242
|
getOptionLabel={(countries) => countries.country_label}
|
|
251
|
-
// {...field}
|
|
252
243
|
onChange={(e) => field.onChange(e.country_label)}
|
|
253
244
|
value={field.value ?? ""}
|
|
254
245
|
>
|
|
@@ -260,11 +251,7 @@ export const CheckoutForm: React.FunctionComponent<CheckoutFormTypes> = (
|
|
|
260
251
|
)}
|
|
261
252
|
/>
|
|
262
253
|
</div>
|
|
263
|
-
<HawaButton
|
|
264
|
-
color="primary"
|
|
265
|
-
// type="submit"
|
|
266
|
-
width="full"
|
|
267
|
-
>
|
|
254
|
+
<HawaButton color="primary" width="full">
|
|
268
255
|
{props.texts.payNow}
|
|
269
256
|
</HawaButton>
|
|
270
257
|
</form>
|
|
@@ -17,7 +17,6 @@ export const PayWithWallet: React.FunctionComponent<PayWithWalletTypes> = (
|
|
|
17
17
|
<div className="text-sm font-normal">{props.currency || "SAR"}</div>
|
|
18
18
|
</div>
|
|
19
19
|
<HawaButton
|
|
20
|
-
// type="submit"
|
|
21
20
|
width="full"
|
|
22
21
|
color="primary"
|
|
23
22
|
onClick={props.handlePayWithWallet}
|
|
@@ -1,20 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
// var _PaymentMethod = require("./PaymentMethod");
|
|
8
|
-
|
|
9
|
-
// exports.GooglePay = _GooglePay.default;
|
|
10
|
-
// exports.Payfort = _Payfort.default;
|
|
11
|
-
// exports.Paypal = _Paypal.default;
|
|
12
|
-
// exports.Wallet = _Wallet.default;
|
|
13
|
-
// exports.PaymentMethod = _PaymentMethod.default;
|
|
14
|
-
|
|
15
|
-
export * from "./SelectPayment";
|
|
16
|
-
export * from "./CreditCardForm";
|
|
17
|
-
export * from "./ChargeWalletForm";
|
|
18
|
-
export * from "./PayWithWallet";
|
|
19
|
-
export * from "./CheckoutForm";
|
|
20
|
-
export * from "./Confirmation";
|
|
1
|
+
export * from "./SelectPayment"
|
|
2
|
+
export * from "./CreditCardForm"
|
|
3
|
+
export * from "./ChargeWalletForm"
|
|
4
|
+
export * from "./PayWithWallet"
|
|
5
|
+
export * from "./CheckoutForm"
|
|
6
|
+
export * from "./Confirmation"
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import React, { useState } from "react"
|
|
2
|
-
import {
|
|
2
|
+
import { BsExclamationCircleFill } from "react-icons/bs"
|
|
3
|
+
import { HawaTabs, HawaTooltip } from "../../elements"
|
|
3
4
|
|
|
4
5
|
const CheckMark = () => (
|
|
5
6
|
<svg
|
|
@@ -37,7 +38,7 @@ type ComparingPlansTypes = {
|
|
|
37
38
|
plans: [
|
|
38
39
|
{
|
|
39
40
|
direction: "rtl" | "ltr"
|
|
40
|
-
features: [{ included: boolean; text: string }]
|
|
41
|
+
features: [{ included: boolean; text: string; description?: string }]
|
|
41
42
|
price: number
|
|
42
43
|
texts: {
|
|
43
44
|
title: string
|
|
@@ -93,8 +94,8 @@ export const ComparingPlans: React.FunctionComponent<ComparingPlansTypes> = (
|
|
|
93
94
|
}}
|
|
94
95
|
/>
|
|
95
96
|
</div>
|
|
96
|
-
<div className="
|
|
97
|
-
<div className="grid grid-cols-4 gap-x-
|
|
97
|
+
<div className=" overflow-hidden rounded">
|
|
98
|
+
<div className="grid grid-cols-4 gap-x-2 border-t border-b border-gray-200 bg-gray-100 p-4 text-sm font-medium text-gray-900 dark:border-gray-700 dark:bg-gray-800 dark:text-white">
|
|
98
99
|
<div className="flex items-center"></div>
|
|
99
100
|
{props.plans.map((plan: any) => (
|
|
100
101
|
<div>
|
|
@@ -125,12 +126,16 @@ export const ComparingPlans: React.FunctionComponent<ComparingPlansTypes> = (
|
|
|
125
126
|
return plan.features.map((feature) => {
|
|
126
127
|
return (
|
|
127
128
|
<div className="grid grid-cols-4 gap-x-16 border-b border-gray-200 py-5 px-4 text-sm text-gray-700 dark:border-gray-700">
|
|
128
|
-
<div className="text-gray-500 dark:text-gray-400">
|
|
129
|
-
{feature.text}
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
129
|
+
<div className=" flex flex-row items-center gap-2 text-gray-500 dark:text-gray-400">
|
|
130
|
+
{feature.text}
|
|
131
|
+
{feature.description && (
|
|
132
|
+
<HawaTooltip
|
|
133
|
+
position="top-right"
|
|
134
|
+
content={feature.description}
|
|
135
|
+
>
|
|
136
|
+
<BsExclamationCircleFill />
|
|
137
|
+
</HawaTooltip>
|
|
138
|
+
)}
|
|
134
139
|
</div>
|
|
135
140
|
<UncheckMark />
|
|
136
141
|
<CheckMark />
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from "react"
|
|
2
2
|
import { FaClone } from "react-icons/fa"
|
|
3
|
-
import {
|
|
3
|
+
import { HawaButton } from "../../elements"
|
|
4
4
|
import { HawaContainer } from "../../layout"
|
|
5
5
|
|
|
6
6
|
type ReferralAccount = {
|