@sikka/hawa 0.0.243 → 0.0.245
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 +8 -3
- package/es/blocks/Account/HawaApiBox.d.ts +2 -2
- package/es/blocks/Account/UserProfileForm.d.ts +2 -2
- package/es/blocks/Account/UserSettingsForm.d.ts +2 -2
- package/es/blocks/AuthForms/AppLanding.d.ts +2 -2
- package/es/blocks/AuthForms/CodeConfirmation.d.ts +3 -3
- package/es/blocks/AuthForms/NewPasswordForm.d.ts +2 -2
- package/es/blocks/AuthForms/ResetPasswordForm.d.ts +2 -2
- package/es/blocks/AuthForms/SignInForm.d.ts +2 -2
- package/es/blocks/AuthForms/SignInPhone.d.ts +2 -2
- package/es/blocks/AuthForms/SignUpForm.d.ts +2 -2
- package/es/blocks/Misc/EmptyState.d.ts +7 -2
- package/es/blocks/Misc/LeadGenerator.d.ts +2 -2
- package/es/blocks/Misc/Newsletter.d.ts +2 -2
- package/es/blocks/Misc/NoPermission.d.ts +6 -2
- package/es/blocks/Misc/NotFound.d.ts +2 -2
- package/es/blocks/Misc/Testimonial.d.ts +2 -2
- package/es/blocks/Payment/ChargeWalletForm.d.ts +2 -2
- package/es/blocks/Payment/CheckoutForm.d.ts +2 -2
- package/es/blocks/Payment/Confirmation.d.ts +2 -2
- package/es/blocks/Payment/CreditCardForm.d.ts +2 -2
- package/es/blocks/Payment/PayWithWallet.d.ts +2 -2
- package/es/blocks/Payment/SelectPayment.d.ts +2 -2
- package/es/blocks/Pricing/ComparingPlans.d.ts +2 -2
- package/es/blocks/Pricing/PricingPlans.d.ts +2 -2
- package/es/blocks/Referral/ReferralAccount.d.ts +2 -2
- package/es/blocks/Referral/ReferralSettlement.d.ts +2 -2
- package/es/blocks/Referral/ReferralStats.d.ts +2 -2
- package/es/elements/ArrowCarousel.d.ts +2 -2
- package/es/elements/AutoCompleteField.d.ts +2 -2
- package/es/elements/BackToTop.d.ts +3 -3
- package/es/elements/Breadcrumb.d.ts +2 -4
- package/es/elements/DragDropImages.d.ts +2 -6
- package/es/elements/DraggableCard.d.ts +2 -2
- package/es/elements/HawaAccordion.d.ts +5 -11
- package/es/elements/HawaAdCard.d.ts +2 -2
- package/es/elements/HawaCardInput.d.ts +2 -2
- package/es/elements/HawaCheckbox.d.ts +2 -2
- package/es/elements/HawaChip.d.ts +9 -3
- package/es/elements/HawaColorPicker.d.ts +5 -3
- package/es/elements/HawaCopyrights.d.ts +8 -4
- package/es/elements/HawaDrawer.d.ts +2 -2
- package/es/elements/HawaIconCount.d.ts +5 -3
- package/es/elements/HawaItemCard.d.ts +10 -6
- package/es/elements/HawaLandingCard.d.ts +2 -2
- package/es/elements/HawaLogoButton.d.ts +2 -2
- package/es/elements/HawaMenu.d.ts +2 -2
- package/es/elements/HawaModal.d.ts +2 -2
- package/es/elements/HawaPanelTabs.d.ts +2 -2
- package/es/elements/HawaPhoneInput.d.ts +2 -2
- package/es/elements/HawaPinInput.d.ts +2 -2
- package/es/elements/HawaPricingCard.d.ts +2 -2
- package/es/elements/HawaRadio.d.ts +2 -2
- package/es/elements/HawaRange.d.ts +2 -2
- package/es/elements/HawaSearchBar.d.ts +2 -2
- package/es/elements/HawaSelect.d.ts +2 -2
- package/es/elements/HawaSettingsRow.d.ts +2 -2
- package/es/elements/HawaSpinner.d.ts +2 -2
- package/es/elements/HawaStats.d.ts +2 -2
- package/es/elements/HawaStepper.d.ts +2 -2
- package/es/elements/HawaStoreButtons.d.ts +2 -2
- package/es/elements/HawaSwitch.d.ts +2 -2
- package/es/elements/HawaTable.d.ts +2 -2
- package/es/elements/HawaTabs.d.ts +2 -2
- package/es/elements/HawaTextField.d.ts +3 -3
- package/es/elements/HawaTooltip.d.ts +3 -3
- package/es/elements/HawaTypography.d.ts +2 -2
- package/es/elements/InvoiceAccordion.d.ts +2 -2
- package/es/elements/SubsectionList.d.ts +2 -2
- package/es/elements/TabPanel.d.ts +2 -2
- package/es/elements/UsageCard.d.ts +2 -2
- package/es/elements/UserFeedback.d.ts +2 -2
- package/es/index.es.js +2 -2
- package/es/layout/HawaAppLayout.d.ts +1 -0
- package/es/layout/index.d.ts +0 -1
- package/lib/blocks/Account/HawaApiBox.d.ts +2 -2
- package/lib/blocks/Account/UserProfileForm.d.ts +2 -2
- package/lib/blocks/Account/UserSettingsForm.d.ts +2 -2
- package/lib/blocks/AuthForms/AppLanding.d.ts +2 -2
- package/lib/blocks/AuthForms/CodeConfirmation.d.ts +3 -3
- package/lib/blocks/AuthForms/NewPasswordForm.d.ts +2 -2
- package/lib/blocks/AuthForms/ResetPasswordForm.d.ts +2 -2
- package/lib/blocks/AuthForms/SignInForm.d.ts +2 -2
- package/lib/blocks/AuthForms/SignInPhone.d.ts +2 -2
- package/lib/blocks/AuthForms/SignUpForm.d.ts +2 -2
- package/lib/blocks/Misc/EmptyState.d.ts +7 -2
- package/lib/blocks/Misc/LeadGenerator.d.ts +2 -2
- package/lib/blocks/Misc/Newsletter.d.ts +2 -2
- package/lib/blocks/Misc/NoPermission.d.ts +6 -2
- package/lib/blocks/Misc/NotFound.d.ts +2 -2
- package/lib/blocks/Misc/Testimonial.d.ts +2 -2
- package/lib/blocks/Payment/ChargeWalletForm.d.ts +2 -2
- package/lib/blocks/Payment/CheckoutForm.d.ts +2 -2
- package/lib/blocks/Payment/Confirmation.d.ts +2 -2
- package/lib/blocks/Payment/CreditCardForm.d.ts +2 -2
- package/lib/blocks/Payment/PayWithWallet.d.ts +2 -2
- package/lib/blocks/Payment/SelectPayment.d.ts +2 -2
- package/lib/blocks/Pricing/ComparingPlans.d.ts +2 -2
- package/lib/blocks/Pricing/PricingPlans.d.ts +2 -2
- package/lib/blocks/Referral/ReferralAccount.d.ts +2 -2
- package/lib/blocks/Referral/ReferralSettlement.d.ts +2 -2
- package/lib/blocks/Referral/ReferralStats.d.ts +2 -2
- package/lib/elements/ArrowCarousel.d.ts +2 -2
- package/lib/elements/AutoCompleteField.d.ts +2 -2
- package/lib/elements/BackToTop.d.ts +3 -3
- package/lib/elements/Breadcrumb.d.ts +2 -4
- package/lib/elements/DragDropImages.d.ts +2 -6
- package/lib/elements/DraggableCard.d.ts +2 -2
- package/lib/elements/HawaAccordion.d.ts +5 -11
- package/lib/elements/HawaAdCard.d.ts +2 -2
- package/lib/elements/HawaCardInput.d.ts +2 -2
- package/lib/elements/HawaCheckbox.d.ts +2 -2
- package/lib/elements/HawaChip.d.ts +9 -3
- package/lib/elements/HawaColorPicker.d.ts +5 -3
- package/lib/elements/HawaCopyrights.d.ts +8 -4
- package/lib/elements/HawaDrawer.d.ts +2 -2
- package/lib/elements/HawaIconCount.d.ts +5 -3
- package/lib/elements/HawaItemCard.d.ts +10 -6
- package/lib/elements/HawaLandingCard.d.ts +2 -2
- package/lib/elements/HawaLogoButton.d.ts +2 -2
- package/lib/elements/HawaMenu.d.ts +2 -2
- package/lib/elements/HawaModal.d.ts +2 -2
- package/lib/elements/HawaPanelTabs.d.ts +2 -2
- package/lib/elements/HawaPhoneInput.d.ts +2 -2
- package/lib/elements/HawaPinInput.d.ts +2 -2
- package/lib/elements/HawaPricingCard.d.ts +2 -2
- package/lib/elements/HawaRadio.d.ts +2 -2
- package/lib/elements/HawaRange.d.ts +2 -2
- package/lib/elements/HawaSearchBar.d.ts +2 -2
- package/lib/elements/HawaSelect.d.ts +2 -2
- package/lib/elements/HawaSettingsRow.d.ts +2 -2
- package/lib/elements/HawaSpinner.d.ts +2 -2
- package/lib/elements/HawaStats.d.ts +2 -2
- package/lib/elements/HawaStepper.d.ts +2 -2
- package/lib/elements/HawaStoreButtons.d.ts +2 -2
- package/lib/elements/HawaSwitch.d.ts +2 -2
- package/lib/elements/HawaTable.d.ts +2 -2
- package/lib/elements/HawaTabs.d.ts +2 -2
- package/lib/elements/HawaTextField.d.ts +3 -3
- package/lib/elements/HawaTooltip.d.ts +3 -3
- package/lib/elements/HawaTypography.d.ts +2 -2
- package/lib/elements/InvoiceAccordion.d.ts +2 -2
- package/lib/elements/SubsectionList.d.ts +2 -2
- package/lib/elements/TabPanel.d.ts +2 -2
- package/lib/elements/UsageCard.d.ts +2 -2
- package/lib/elements/UserFeedback.d.ts +2 -2
- package/lib/index.js +2 -2
- package/lib/layout/HawaAppLayout.d.ts +1 -0
- package/lib/layout/index.d.ts +0 -1
- package/package.json +1 -1
- package/src/blocks/Account/HawaApiBox.tsx +2 -4
- package/src/blocks/Account/UserProfileForm.tsx +2 -4
- package/src/blocks/Account/UserSettingsForm.tsx +2 -6
- package/src/blocks/AuthForms/AppLanding.tsx +2 -2
- package/src/blocks/AuthForms/CodeConfirmation.tsx +3 -5
- package/src/blocks/AuthForms/NewPasswordForm.tsx +2 -4
- package/src/blocks/AuthForms/ResetPasswordForm.tsx +2 -4
- package/src/blocks/AuthForms/SignInForm.tsx +2 -2
- package/src/blocks/AuthForms/SignInPhone.tsx +2 -4
- package/src/blocks/AuthForms/SignUpForm.tsx +2 -2
- package/src/blocks/Misc/EmptyState.tsx +15 -7
- package/src/blocks/Misc/LeadGenerator.tsx +4 -6
- package/src/blocks/Misc/Newsletter.tsx +3 -3
- package/src/blocks/Misc/NoPermission.tsx +13 -10
- package/src/blocks/Misc/NotFound.tsx +4 -4
- package/src/blocks/Misc/Testimonial.tsx +25 -33
- package/src/blocks/Payment/ChargeWalletForm.tsx +9 -10
- package/src/blocks/Payment/CheckoutForm.tsx +20 -22
- package/src/blocks/Payment/Confirmation.tsx +7 -9
- package/src/blocks/Payment/CreditCardForm.tsx +2 -4
- package/src/blocks/Payment/PayWithWallet.tsx +2 -4
- package/src/blocks/Payment/SelectPayment.tsx +2 -4
- package/src/blocks/Pricing/ComparingPlans.tsx +4 -6
- package/src/blocks/Pricing/PricingPlans.tsx +2 -4
- package/src/blocks/Referral/ReferralAccount.tsx +2 -2
- package/src/blocks/Referral/ReferralSettlement.tsx +14 -7
- package/src/blocks/Referral/ReferralStats.tsx +2 -2
- package/src/elements/ArrowCarousel.tsx +2 -2
- package/src/elements/AutoCompleteField.tsx +5 -7
- package/src/elements/BackToTop.tsx +3 -3
- package/src/elements/Breadcrumb.tsx +3 -6
- package/src/elements/DragDropImages.tsx +3 -7
- package/src/elements/DraggableCard.tsx +2 -4
- package/src/elements/HawaAccordion.tsx +6 -14
- package/src/elements/HawaAdCard.tsx +2 -5
- package/src/elements/HawaCardInput.tsx +1 -1
- package/src/elements/HawaCheckbox.tsx +2 -4
- package/src/elements/HawaChip.tsx +10 -4
- package/src/elements/HawaColorPicker.tsx +7 -7
- package/src/elements/HawaCopyrights.tsx +8 -6
- package/src/elements/HawaDatepicker.tsx +1 -1
- package/src/elements/HawaDrawer.tsx +3 -3
- package/src/elements/HawaIconCount.tsx +5 -5
- package/src/elements/HawaItemCard.tsx +10 -10
- package/src/elements/HawaLandingCard.tsx +3 -3
- package/src/elements/HawaLogoButton.tsx +2 -4
- package/src/elements/HawaMenu.tsx +4 -4
- package/src/elements/HawaModal.tsx +2 -2
- package/src/elements/HawaPanelTabs.tsx +2 -4
- package/src/elements/HawaPhoneInput.tsx +3 -5
- package/src/elements/HawaPinInput.tsx +2 -2
- package/src/elements/HawaPricingCard.tsx +2 -2
- package/src/elements/HawaRadio.tsx +2 -2
- package/src/elements/HawaRange.tsx +3 -3
- package/src/elements/HawaSearchBar.tsx +2 -4
- package/src/elements/HawaSelect.tsx +5 -5
- package/src/elements/HawaSettingsRow.tsx +2 -2
- package/src/elements/HawaSnackbar.tsx +2 -2
- package/src/elements/HawaSpinner.tsx +2 -5
- package/src/elements/HawaStats.tsx +2 -2
- package/src/elements/HawaStepper.tsx +2 -2
- package/src/elements/HawaStoreButtons.tsx +3 -5
- package/src/elements/HawaSwitch.tsx +2 -5
- package/src/elements/HawaTable.tsx +5 -3
- package/src/elements/HawaTabs.tsx +4 -4
- package/src/elements/HawaTextField.tsx +4 -4
- package/src/elements/HawaTooltip.tsx +3 -3
- package/src/elements/HawaTypography.tsx +2 -4
- package/src/elements/InvoiceAccordion.tsx +2 -4
- package/src/elements/SubsectionList.tsx +3 -5
- package/src/elements/TabPanel.tsx +2 -2
- package/src/elements/UsageCard.tsx +2 -2
- package/src/elements/UserFeedback.tsx +2 -4
- package/src/layout/HawaAppLayout.tsx +86 -58
- package/src/layout/index.ts +0 -1
- package/src/styles.css +8 -3
- package/es/layout/SimpleGrid.d.ts +0 -10
- package/lib/layout/SimpleGrid.d.ts +0 -10
- package/src/layout/SimpleGrid.tsx +0 -41
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { ReactElement, useEffect, FC } from "react"
|
|
2
2
|
import clsx from "clsx"
|
|
3
3
|
|
|
4
4
|
type ModalTypes = {
|
|
@@ -29,7 +29,7 @@ type ModalTypes = {
|
|
|
29
29
|
*/
|
|
30
30
|
actions: any
|
|
31
31
|
}
|
|
32
|
-
export const HawaModal:
|
|
32
|
+
export const HawaModal: FC<ModalTypes> = ({
|
|
33
33
|
open,
|
|
34
34
|
title,
|
|
35
35
|
onClose,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { useState, FC } from "react"
|
|
2
2
|
|
|
3
3
|
type PanelTabsTypes = {
|
|
4
4
|
defaultValue: any
|
|
@@ -7,9 +7,7 @@ type PanelTabsTypes = {
|
|
|
7
7
|
handleChange: any
|
|
8
8
|
location: any
|
|
9
9
|
}
|
|
10
|
-
export const HawaPanelTabs:
|
|
11
|
-
props
|
|
12
|
-
) => {
|
|
10
|
+
export const HawaPanelTabs: FC<PanelTabsTypes> = (props) => {
|
|
13
11
|
const [value, setValue] = useState(props.defaultValue)
|
|
14
12
|
return (
|
|
15
13
|
<div>
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { useState, FC } from "react"
|
|
2
2
|
import Countries from "../countries"
|
|
3
3
|
import Select from "react-select"
|
|
4
4
|
|
|
@@ -10,7 +10,7 @@ type OptionTypes = {
|
|
|
10
10
|
innerProps: any
|
|
11
11
|
innerRef: any
|
|
12
12
|
}
|
|
13
|
-
const Option:
|
|
13
|
+
const Option: FC<OptionTypes> = ({
|
|
14
14
|
cx,
|
|
15
15
|
children,
|
|
16
16
|
getStyles,
|
|
@@ -39,9 +39,7 @@ type HawaPhoneInputTypes = {
|
|
|
39
39
|
country?: any
|
|
40
40
|
handleChange?: any
|
|
41
41
|
}
|
|
42
|
-
export const HawaPhoneInput:
|
|
43
|
-
props
|
|
44
|
-
) => {
|
|
42
|
+
export const HawaPhoneInput: FC<HawaPhoneInputTypes> = (props) => {
|
|
45
43
|
const [selectedCountry, setSelectedCountry] = useState("+966")
|
|
46
44
|
|
|
47
45
|
return (
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import clsx from "clsx"
|
|
2
|
-
import
|
|
2
|
+
import { useEffect, useState, FC } from "react"
|
|
3
3
|
|
|
4
4
|
type PinInputTypes = {
|
|
5
5
|
label?: string
|
|
@@ -8,7 +8,7 @@ type PinInputTypes = {
|
|
|
8
8
|
width?: "normal" | "full"
|
|
9
9
|
getPins?: any
|
|
10
10
|
}
|
|
11
|
-
export const HawaPinInput:
|
|
11
|
+
export const HawaPinInput: FC<PinInputTypes> = ({
|
|
12
12
|
label,
|
|
13
13
|
icon,
|
|
14
14
|
digits,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import clsx from "clsx"
|
|
2
|
-
import
|
|
2
|
+
import { FC } from "react"
|
|
3
3
|
import { HawaButton } from "./HawaButton"
|
|
4
4
|
|
|
5
5
|
// TODO: if feature.excluded is false, show gray and x
|
|
@@ -22,7 +22,7 @@ type PricingCardTypes = {
|
|
|
22
22
|
size: "small" | "medium" | "large"
|
|
23
23
|
}
|
|
24
24
|
|
|
25
|
-
export const HawaPricingCard:
|
|
25
|
+
export const HawaPricingCard: FC<PricingCardTypes> = ({
|
|
26
26
|
size = "medium",
|
|
27
27
|
direction = "ltr",
|
|
28
28
|
currentPlan = false,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { useState, FC } from "react"
|
|
2
2
|
import clsx from "clsx"
|
|
3
3
|
|
|
4
4
|
type RadioTypes = {
|
|
@@ -11,7 +11,7 @@ type RadioTypes = {
|
|
|
11
11
|
onChangeTab?: any
|
|
12
12
|
defaultValue?: any
|
|
13
13
|
}
|
|
14
|
-
export const HawaRadio:
|
|
14
|
+
export const HawaRadio: FC<RadioTypes> = (props) => {
|
|
15
15
|
const [selectedOption, setSelectedOption] = useState(props.defaultValue)
|
|
16
16
|
let activeTabStyle =
|
|
17
17
|
"inline-block py-2 px-4 w-full text-white bg-buttonPrimary-500 rounded active"
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { FC, useState } from "react"
|
|
2
2
|
|
|
3
3
|
type RangeTypes = {
|
|
4
4
|
value?: any
|
|
@@ -10,7 +10,7 @@ type RangeTypes = {
|
|
|
10
10
|
max?: any
|
|
11
11
|
}
|
|
12
12
|
|
|
13
|
-
export const HawaRange:
|
|
13
|
+
export const HawaRange: FC<RangeTypes> = ({
|
|
14
14
|
value,
|
|
15
15
|
handleChange,
|
|
16
16
|
startElement,
|
|
@@ -18,7 +18,7 @@ export const HawaRange: React.FunctionComponent<RangeTypes> = ({
|
|
|
18
18
|
label,
|
|
19
19
|
...props
|
|
20
20
|
}) => {
|
|
21
|
-
const [rangeValue, setRangeValue] =
|
|
21
|
+
const [rangeValue, setRangeValue] = useState(value)
|
|
22
22
|
|
|
23
23
|
return (
|
|
24
24
|
<div {...props}>
|
|
@@ -1,9 +1,7 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { FC } from "react"
|
|
2
2
|
import { HawaTextField } from "./HawaTextField"
|
|
3
3
|
|
|
4
4
|
type SearchBarTypes = {}
|
|
5
|
-
export const HawaSearchBar:
|
|
6
|
-
props
|
|
7
|
-
) => {
|
|
5
|
+
export const HawaSearchBar: FC<SearchBarTypes> = (props) => {
|
|
8
6
|
return <HawaTextField type={"search"} {...props} />
|
|
9
7
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import clsx from "clsx"
|
|
2
|
-
import
|
|
2
|
+
import { FC } from "react"
|
|
3
3
|
import Select from "react-select"
|
|
4
4
|
import CreatableSelect from "react-select/creatable"
|
|
5
5
|
|
|
@@ -12,7 +12,7 @@ type ControlTypes = {
|
|
|
12
12
|
innerRef: any
|
|
13
13
|
size?: "small" | "normal" | "large"
|
|
14
14
|
}
|
|
15
|
-
const Control:
|
|
15
|
+
const Control: FC<ControlTypes> = ({
|
|
16
16
|
cx,
|
|
17
17
|
children,
|
|
18
18
|
getStyles,
|
|
@@ -48,7 +48,7 @@ type MenuTypes = {
|
|
|
48
48
|
innerProps: any
|
|
49
49
|
innerRef: any
|
|
50
50
|
}
|
|
51
|
-
const Menu:
|
|
51
|
+
const Menu: FC<MenuTypes> = ({
|
|
52
52
|
cx,
|
|
53
53
|
children,
|
|
54
54
|
getStyles,
|
|
@@ -76,7 +76,7 @@ type OptionTypes = {
|
|
|
76
76
|
innerRef: any
|
|
77
77
|
size?: "small" | "normal" | "large"
|
|
78
78
|
}
|
|
79
|
-
const Option:
|
|
79
|
+
const Option: FC<OptionTypes> = ({
|
|
80
80
|
cx,
|
|
81
81
|
children,
|
|
82
82
|
getStyles,
|
|
@@ -114,7 +114,7 @@ type SelectTypes = {
|
|
|
114
114
|
getOptionLabel?: any
|
|
115
115
|
disabled?: boolean
|
|
116
116
|
}
|
|
117
|
-
export const HawaSelect:
|
|
117
|
+
export const HawaSelect: FC<SelectTypes> = (props) => {
|
|
118
118
|
return (
|
|
119
119
|
<div>
|
|
120
120
|
{props.label && (
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { FC } from "react"
|
|
2
2
|
import { HawaTextField } from "./HawaTextField"
|
|
3
3
|
import { HawaSwitch } from "./HawaSwitch"
|
|
4
4
|
import { HawaColorPicker } from "./HawaColorPicker"
|
|
@@ -45,7 +45,7 @@ type SettingsRowTypes = {
|
|
|
45
45
|
}
|
|
46
46
|
}
|
|
47
47
|
|
|
48
|
-
export const HawaSettingsRow:
|
|
48
|
+
export const HawaSettingsRow: FC<SettingsRowTypes> = ({
|
|
49
49
|
settingsLabel,
|
|
50
50
|
settingsType,
|
|
51
51
|
settingsDescription,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { FC, useEffect, useRef, useState } from "react"
|
|
2
2
|
import clsx from "clsx"
|
|
3
3
|
import { HawaButton } from "./HawaButton"
|
|
4
4
|
|
|
@@ -86,7 +86,7 @@ export const HawaSnackbar: FC<THawaSnackBar> = ({
|
|
|
86
86
|
closed ? "opacity-0" : "opacity-100"
|
|
87
87
|
)}
|
|
88
88
|
>
|
|
89
|
-
<div className="w-full
|
|
89
|
+
<div className="flex w-full flex-col gap-2 p-3">
|
|
90
90
|
<div className="text-sm font-bold">{title}</div>
|
|
91
91
|
<div className="text-sm font-normal">{description}</div>
|
|
92
92
|
{actions && (
|
|
@@ -1,14 +1,11 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { FC } from "react"
|
|
2
2
|
import clsx from "clsx"
|
|
3
3
|
|
|
4
4
|
type SpinnerTypes = {
|
|
5
5
|
size?: "button" | "sm" | "normal" | "lg" | "xl"
|
|
6
6
|
}
|
|
7
7
|
|
|
8
|
-
export const HawaSpinner:
|
|
9
|
-
size = "sm",
|
|
10
|
-
...props
|
|
11
|
-
}) => {
|
|
8
|
+
export const HawaSpinner: FC<SpinnerTypes> = ({ size = "sm", ...props }) => {
|
|
12
9
|
let sizeStyles = {
|
|
13
10
|
button: "h-4 w-4",
|
|
14
11
|
sm: "h-6 w-6",
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { FC } from "react"
|
|
2
2
|
import clsx from "clsx"
|
|
3
3
|
import { HawaSpinner } from "./HawaSpinner"
|
|
4
4
|
|
|
@@ -12,7 +12,7 @@ type StatTypes = {
|
|
|
12
12
|
isLoading?: boolean
|
|
13
13
|
handleClick?: () => void
|
|
14
14
|
}
|
|
15
|
-
export const HawaStats:
|
|
15
|
+
export const HawaStats: FC<StatTypes> = (props) => {
|
|
16
16
|
let defaultStyle = "flex flex-col gap-1 rounded p-4 text-sm h-fit max-h-fit"
|
|
17
17
|
let statStyles = {
|
|
18
18
|
plain: "",
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { FC } from "react"
|
|
2
2
|
import clsx from "clsx"
|
|
3
3
|
import { FaCheck } from "react-icons/fa"
|
|
4
4
|
|
|
@@ -8,7 +8,7 @@ type THawaTimeline = {
|
|
|
8
8
|
orientation: "vertical" | "horizontal"
|
|
9
9
|
}
|
|
10
10
|
|
|
11
|
-
export const HawaStepper:
|
|
11
|
+
export const HawaStepper: FC<THawaTimeline> = ({
|
|
12
12
|
orientation = "horizontal",
|
|
13
13
|
...props
|
|
14
14
|
}) => {
|
|
@@ -1,12 +1,10 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { FC } from "react"
|
|
2
2
|
|
|
3
3
|
type StoreButtonsTypes = {
|
|
4
4
|
store: "apple" | "google"
|
|
5
5
|
mode: "dark" | "light"
|
|
6
6
|
}
|
|
7
|
-
export const HawaStoreButtons:
|
|
8
|
-
props
|
|
9
|
-
) => {
|
|
7
|
+
export const HawaStoreButtons: FC<StoreButtonsTypes> = (props) => {
|
|
10
8
|
return (
|
|
11
9
|
<div className="flex justify-center">
|
|
12
10
|
<div>
|
|
@@ -77,7 +75,7 @@ export const HawaStoreButtons: React.FunctionComponent<StoreButtonsTypes> = (
|
|
|
77
75
|
</div>
|
|
78
76
|
</div>
|
|
79
77
|
) : (
|
|
80
|
-
<div className="mt-3 flex h-14 w-48 items-center justify-center rounded-lg
|
|
78
|
+
<div className="mt-3 flex h-14 w-48 items-center justify-center rounded-lg border border-black bg-white text-black">
|
|
81
79
|
<div className="mr-3">
|
|
82
80
|
<svg viewBox="30 336.7 120.9 129.2" width="30">
|
|
83
81
|
<path
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { FC } from "react"
|
|
2
2
|
import clsx from "clsx"
|
|
3
3
|
|
|
4
4
|
type SwitchTypes = {
|
|
@@ -6,10 +6,7 @@ type SwitchTypes = {
|
|
|
6
6
|
size?: "small" | "normal" | "large"
|
|
7
7
|
}
|
|
8
8
|
|
|
9
|
-
export const HawaSwitch:
|
|
10
|
-
size = "normal",
|
|
11
|
-
...props
|
|
12
|
-
}) => {
|
|
9
|
+
export const HawaSwitch: FC<SwitchTypes> = ({ size = "normal", ...props }) => {
|
|
13
10
|
let sizeStyles = {
|
|
14
11
|
small: "",
|
|
15
12
|
normal:
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { useEffect, useState, FC } from "react"
|
|
2
2
|
import clsx from "clsx"
|
|
3
3
|
import { HawaMenu } from "./HawaMenu"
|
|
4
4
|
import useTable from "../hooks/useTable"
|
|
@@ -43,7 +43,7 @@ type ActionItems = {
|
|
|
43
43
|
element?: any
|
|
44
44
|
}
|
|
45
45
|
|
|
46
|
-
export const HawaTable:
|
|
46
|
+
export const HawaTable: FC<TableTypes> = ({
|
|
47
47
|
size = "normal",
|
|
48
48
|
bodyColor = "white",
|
|
49
49
|
headerColor = "gray-200",
|
|
@@ -265,7 +265,9 @@ export const HawaTable: React.FunctionComponent<TableTypes> = ({
|
|
|
265
265
|
) : (
|
|
266
266
|
<div className="flex flex-row items-center justify-center gap-2 p-1">
|
|
267
267
|
{props.actions[0].map((act) => (
|
|
268
|
-
<div className=" p-1 hover:bg-gray-100
|
|
268
|
+
<div className=" p-1 transition-all hover:bg-gray-100">
|
|
269
|
+
{act.icon}
|
|
270
|
+
</div>
|
|
269
271
|
))}
|
|
270
272
|
</div>
|
|
271
273
|
)
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import clsx from "clsx"
|
|
2
|
-
import
|
|
2
|
+
import { useState, FC } from "react"
|
|
3
3
|
|
|
4
4
|
// TODO: fix wrapping issue when small screen
|
|
5
5
|
|
|
@@ -13,7 +13,7 @@ type TabsTypes = {
|
|
|
13
13
|
width?: "full" | "normal"
|
|
14
14
|
pill?: boolean
|
|
15
15
|
}
|
|
16
|
-
export const HawaTabs:
|
|
16
|
+
export const HawaTabs: FC<TabsTypes> = ({
|
|
17
17
|
orientation = "horizontal",
|
|
18
18
|
direction = "ltr",
|
|
19
19
|
width = "normal",
|
|
@@ -115,8 +115,8 @@ export const HawaTabs: React.FunctionComponent<TabsTypes> = ({
|
|
|
115
115
|
pill
|
|
116
116
|
? "rounded"
|
|
117
117
|
: orientation === "vertical"
|
|
118
|
-
? "rounded rounded-
|
|
119
|
-
: "rounded rounded-
|
|
118
|
+
? "rounded rounded-bl-none rounded-tl-none"
|
|
119
|
+
: "rounded rounded-bl-none rounded-br-none"
|
|
120
120
|
// direction === "rtl" ? "bg-yellow-400" : "bg-yellow-400"
|
|
121
121
|
)}
|
|
122
122
|
>
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { FC, PropsWithRef } from "react"
|
|
2
2
|
import clsx from "clsx"
|
|
3
3
|
|
|
4
4
|
// TODO: make icon based on direction
|
|
@@ -15,7 +15,7 @@ type TextFieldTypes = {
|
|
|
15
15
|
helperText?: any
|
|
16
16
|
/** The value of the input field */
|
|
17
17
|
value?: any
|
|
18
|
-
props?:
|
|
18
|
+
props?: PropsWithRef<"input">
|
|
19
19
|
/** The type of input field. Same as the types of <input/> component */
|
|
20
20
|
type?: any
|
|
21
21
|
/** The placeholder of the input field */
|
|
@@ -31,7 +31,7 @@ type TextFieldTypes = {
|
|
|
31
31
|
preview?: boolean
|
|
32
32
|
}
|
|
33
33
|
|
|
34
|
-
export const HawaTextField:
|
|
34
|
+
export const HawaTextField: FC<TextFieldTypes> = ({
|
|
35
35
|
margin = "normal",
|
|
36
36
|
width = "full",
|
|
37
37
|
preview = false,
|
|
@@ -50,7 +50,7 @@ export const HawaTextField: React.FunctionComponent<TextFieldTypes> = ({
|
|
|
50
50
|
|
|
51
51
|
let defaultStyle = "flex max-h-fit flex-col justify-center"
|
|
52
52
|
let defaultInputStyle =
|
|
53
|
-
"block w-full rounded outline outline-gray-300 bg-white p-2 text-sm text-gray-900 focus:border-blue-500 focus:ring-blue-500 dark:border-gray-600 dark:bg-gray-700 dark:text-white dark:placeholder-gray-400 dark:focus:border-blue-500 dark:focus:ring-blue-500"
|
|
53
|
+
"block w-full rounded outline outline-1 outline-gray-300 bg-white p-2 text-sm text-gray-900 focus:border-blue-500 focus:ring-blue-500 dark:border-gray-600 dark:bg-gray-700 dark:text-white dark:placeholder-gray-400 dark:focus:border-blue-500 dark:focus:ring-blue-500"
|
|
54
54
|
let previewInputStyle =
|
|
55
55
|
"block w-full rounded bg-gray-50 p-2 text-sm text-gray-900 focus:border-blue-500 focus:ring-blue-500 dark:border-gray-600 dark:bg-gray-700 dark:text-white dark:placeholder-gray-400 dark:focus:border-blue-500 dark:focus:ring-blue-500"
|
|
56
56
|
// "mb-0 block w-full rounded border border-gray-300 bg-gray-50 p-2 text-gray-900 focus:border-blue-500 focus:ring-blue-500 dark:border-gray-600 dark:bg-gray-700 dark:text-white dark:placeholder-gray-400 dark:focus:border-blue-500 dark:focus:ring-blue-500",
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
+
import { useEffect, useRef, useState, ReactElement, FC } from "react"
|
|
1
2
|
import clsx from "clsx"
|
|
2
|
-
import React, { useEffect, useRef, useState } from "react"
|
|
3
3
|
|
|
4
4
|
type THawaToolTip = {
|
|
5
|
-
children?:
|
|
5
|
+
children?: ReactElement
|
|
6
6
|
content?: string
|
|
7
7
|
btnHovered?: any
|
|
8
8
|
buttonRef?: any
|
|
@@ -19,7 +19,7 @@ type THawaToolTip = {
|
|
|
19
19
|
| "bottom-left"
|
|
20
20
|
}
|
|
21
21
|
|
|
22
|
-
export const HawaTooltip:
|
|
22
|
+
export const HawaTooltip: FC<THawaToolTip> = ({
|
|
23
23
|
children,
|
|
24
24
|
content,
|
|
25
25
|
size = "normal",
|
|
@@ -1,11 +1,9 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { FC } from "react"
|
|
2
2
|
|
|
3
3
|
type TypographyTypes = {
|
|
4
4
|
children: any
|
|
5
5
|
align?: any
|
|
6
6
|
}
|
|
7
|
-
export const HawaTypography:
|
|
8
|
-
props
|
|
9
|
-
) => {
|
|
7
|
+
export const HawaTypography: FC<TypographyTypes> = (props) => {
|
|
10
8
|
return <div>{props.children}</div>
|
|
11
9
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { useState, FC } from "react"
|
|
2
2
|
import clsx from "clsx"
|
|
3
3
|
import { HiChevronRight } from "react-icons/hi"
|
|
4
4
|
import { BsThreeDotsVertical } from "react-icons/bs"
|
|
@@ -33,9 +33,7 @@ type InvoiceAccordionTypes = {
|
|
|
33
33
|
direction?: "rtl" | "ltr"
|
|
34
34
|
status?: "paid" | "pending" | "overdue"
|
|
35
35
|
}
|
|
36
|
-
export const InvoiceAccordion:
|
|
37
|
-
InvoiceAccordionTypes
|
|
38
|
-
> = ({
|
|
36
|
+
export const InvoiceAccordion: FC<InvoiceAccordionTypes> = ({
|
|
39
37
|
direction = "ltr",
|
|
40
38
|
texts = {
|
|
41
39
|
total: "Total",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import clsx from "clsx"
|
|
2
|
-
import
|
|
2
|
+
import { useState, FC } from "react"
|
|
3
3
|
import { HawaChip } from "./HawaChip"
|
|
4
4
|
|
|
5
5
|
type SubsectionListTypes = {
|
|
@@ -18,9 +18,7 @@ type SubsectionListTypes = {
|
|
|
18
18
|
}
|
|
19
19
|
]
|
|
20
20
|
}
|
|
21
|
-
export const SubsectionList:
|
|
22
|
-
subsections,
|
|
23
|
-
}) => {
|
|
21
|
+
export const SubsectionList: FC<SubsectionListTypes> = ({ subsections }) => {
|
|
24
22
|
const [selectedSection, setSelectedSection] = useState(null)
|
|
25
23
|
return (
|
|
26
24
|
<div className="w-full max-w-2xs rounded bg-layoutPrimary-500 p-4 ">
|
|
@@ -52,7 +50,7 @@ type TSubsectionItem = {
|
|
|
52
50
|
selected?: any
|
|
53
51
|
onItemClick?: () => void
|
|
54
52
|
}
|
|
55
|
-
const SubsectionItem:
|
|
53
|
+
const SubsectionItem: FC<TSubsectionItem> = ({
|
|
56
54
|
title,
|
|
57
55
|
value,
|
|
58
56
|
icon,
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { FC } from "react"
|
|
2
2
|
|
|
3
3
|
type TabPanelTypes = {
|
|
4
4
|
children: any
|
|
5
5
|
value: any
|
|
6
6
|
index: any
|
|
7
7
|
}
|
|
8
|
-
export const TabPanel:
|
|
8
|
+
export const TabPanel: FC<TabPanelTypes> = (props) => {
|
|
9
9
|
const { children, value, index, ...other } = props
|
|
10
10
|
return (
|
|
11
11
|
<div
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { FC } from "react"
|
|
2
2
|
import { HawaTooltip } from "./HawaTooltip"
|
|
3
3
|
import { BsExclamationCircleFill } from "react-icons/bs"
|
|
4
4
|
|
|
@@ -8,7 +8,7 @@ type UsageCardTypes = {
|
|
|
8
8
|
percent: any
|
|
9
9
|
currentUsage: any
|
|
10
10
|
}
|
|
11
|
-
export const UsageCard:
|
|
11
|
+
export const UsageCard: FC<UsageCardTypes> = (props) => {
|
|
12
12
|
return (
|
|
13
13
|
<div className="flex w-full flex-col gap-0 border p-4">
|
|
14
14
|
<div className="flex flex-row items-center gap-2">
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { FC } from "react"
|
|
2
2
|
|
|
3
3
|
type ComponentTypes = {
|
|
4
4
|
title?: string
|
|
@@ -10,9 +10,7 @@ type ComponentTypes = {
|
|
|
10
10
|
}
|
|
11
11
|
onOptionClicked?: (option) => void
|
|
12
12
|
}
|
|
13
|
-
export const UserFeedback:
|
|
14
|
-
...props
|
|
15
|
-
}) => {
|
|
13
|
+
export const UserFeedback: FC<ComponentTypes> = ({ ...props }) => {
|
|
16
14
|
return (
|
|
17
15
|
<div className="relative flex w-full max-w-sm flex-col gap-2 rounded bg-white p-4 shadow-md">
|
|
18
16
|
<div className="absolute left-2 top-2 p-1.5 text-sm">{props.title}</div>
|