@sikka/hawa 0.2.5-beta → 0.2.6-beta
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-beta.yml +1 -6
- package/dist/index.d.mts +14 -6
- package/dist/index.d.ts +14 -6
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +4 -4
- package/dist/index.mjs.map +1 -1
- package/dist/styles.css +19 -0
- package/package.json +1 -1
- package/src/blocks/Account/index.ts +2 -2
- package/src/elements/Button.tsx +3 -3
- package/src/elements/FeedbackByEmoji.tsx +220 -0
- package/src/elements/{UserFeedback.tsx → FeedbackRating.tsx} +1 -1
- package/src/elements/HawaLoading.tsx +2 -1
- package/src/elements/HawaTextField.tsx +2 -2
- package/src/elements/Popover.tsx +3 -1
- package/src/elements/Textarea.tsx +11 -4
- package/src/elements/UserReferralSource.tsx +1 -1
- package/src/elements/index.ts +2 -1
- package/src/layout/Footer.tsx +1 -0
- package/src/styles.css +19 -0
package/dist/styles.css
CHANGED
|
@@ -1172,6 +1172,9 @@ video {
|
|
|
1172
1172
|
.h-\[150px\] {
|
|
1173
1173
|
height: 150px;
|
|
1174
1174
|
}
|
|
1175
|
+
.h-\[165px\] {
|
|
1176
|
+
height: 165px;
|
|
1177
|
+
}
|
|
1175
1178
|
.h-\[16px\] {
|
|
1176
1179
|
height: 16px;
|
|
1177
1180
|
}
|
|
@@ -1199,6 +1202,9 @@ video {
|
|
|
1199
1202
|
.h-\[400px\] {
|
|
1200
1203
|
height: 400px;
|
|
1201
1204
|
}
|
|
1205
|
+
.h-\[44px\] {
|
|
1206
|
+
height: 44px;
|
|
1207
|
+
}
|
|
1202
1208
|
.h-\[80px\] {
|
|
1203
1209
|
height: 80px;
|
|
1204
1210
|
}
|
|
@@ -1440,6 +1446,9 @@ video {
|
|
|
1440
1446
|
.max-w-\[200px\] {
|
|
1441
1447
|
max-width: 200px;
|
|
1442
1448
|
}
|
|
1449
|
+
.max-w-\[300px\] {
|
|
1450
|
+
max-width: 300px;
|
|
1451
|
+
}
|
|
1443
1452
|
.max-w-\[52px\] {
|
|
1444
1453
|
max-width: 52px;
|
|
1445
1454
|
}
|
|
@@ -2565,6 +2574,10 @@ video {
|
|
|
2565
2574
|
.tracking-widest {
|
|
2566
2575
|
letter-spacing: 0.1em;
|
|
2567
2576
|
}
|
|
2577
|
+
.text-\[\#666666\] {
|
|
2578
|
+
--tw-text-opacity: 1;
|
|
2579
|
+
color: rgb(102 102 102 / var(--tw-text-opacity));
|
|
2580
|
+
}
|
|
2568
2581
|
.text-black {
|
|
2569
2582
|
--tw-text-opacity: 1;
|
|
2570
2583
|
color: rgb(0 0 0 / var(--tw-text-opacity));
|
|
@@ -2897,6 +2910,9 @@ video {
|
|
|
2897
2910
|
.duration-500 {
|
|
2898
2911
|
transition-duration: 500ms;
|
|
2899
2912
|
}
|
|
2913
|
+
.ease-in-out {
|
|
2914
|
+
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
|
|
2915
|
+
}
|
|
2900
2916
|
.will-change-transform {
|
|
2901
2917
|
will-change: transform;
|
|
2902
2918
|
}
|
|
@@ -2953,6 +2969,9 @@ video {
|
|
|
2953
2969
|
.delay-300 {
|
|
2954
2970
|
animation-delay: 300ms;
|
|
2955
2971
|
}
|
|
2972
|
+
.ease-in-out {
|
|
2973
|
+
animation-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
|
|
2974
|
+
}
|
|
2956
2975
|
.repeat-infinite {
|
|
2957
2976
|
animation-iteration-count: infinite;
|
|
2958
2977
|
}
|
package/package.json
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export * from "./UserProfileForm"
|
|
2
|
-
export * from "./UserSettingsForm"
|
|
1
|
+
export * from "./UserProfileForm"
|
|
2
|
+
export * from "./UserSettingsForm"
|
package/src/elements/Button.tsx
CHANGED
|
@@ -25,8 +25,8 @@ const buttonVariants = cva(
|
|
|
25
25
|
size: {
|
|
26
26
|
default: "h-10 px-4 py-2",
|
|
27
27
|
heightless: "px-4 py-4",
|
|
28
|
-
xs: "h-fit py-1 text-[10px] px-2",
|
|
29
|
-
sm: "h-9 rounded-md px-3",
|
|
28
|
+
xs: "h-fit py-1 text-[10px] px-2 ",
|
|
29
|
+
sm: "h-9 text-[11px] rounded-md px-3",
|
|
30
30
|
lg: "h-11 rounded-md px-8",
|
|
31
31
|
xl: "h-14 rounded-md px-10",
|
|
32
32
|
icon: "h-10 w-10",
|
|
@@ -78,7 +78,7 @@ const Button = React.forwardRef<HTMLButtonElement, ButtonProps>(
|
|
|
78
78
|
<HawaLoading
|
|
79
79
|
design="dots-pulse"
|
|
80
80
|
color={loadingColor} // Apply the computed color here
|
|
81
|
-
size="
|
|
81
|
+
size={size === "sm" ? "xs" : "normal"}
|
|
82
82
|
/>
|
|
83
83
|
) : (
|
|
84
84
|
children
|
|
@@ -0,0 +1,220 @@
|
|
|
1
|
+
import React, { FC, useState } from "react"
|
|
2
|
+
import { Button } from "./Button"
|
|
3
|
+
import { Textarea } from "./Textarea"
|
|
4
|
+
import { cn } from "../util"
|
|
5
|
+
import { Popover } from "./Popover"
|
|
6
|
+
|
|
7
|
+
type ComponentTypes = {
|
|
8
|
+
handleSubmit: ({}) => void
|
|
9
|
+
showSuccess?: boolean
|
|
10
|
+
}
|
|
11
|
+
export const FeedbackByEmoji: FC<ComponentTypes> = (props) => {
|
|
12
|
+
const [selectedEmoji, setSelectedEmoji] = useState(null)
|
|
13
|
+
const [loadingSubmit, setLoadingSubmit] = useState(false)
|
|
14
|
+
const [feedbackText, setFeedbackText] = useState("")
|
|
15
|
+
const [helperText, setHelperText] = useState(false)
|
|
16
|
+
|
|
17
|
+
let emojis = [
|
|
18
|
+
{ icon: <VeryGoodEmoji />, value: "very-good" },
|
|
19
|
+
{ icon: <GoodEmoji />, value: "good" },
|
|
20
|
+
{ icon: <BadEmoji />, value: "bad" },
|
|
21
|
+
{ icon: <VeryBadEmoji />, value: "very-bad" },
|
|
22
|
+
]
|
|
23
|
+
|
|
24
|
+
const onFeedbackSubmit = async () => {
|
|
25
|
+
console.log("submitting")
|
|
26
|
+
if (feedbackText) {
|
|
27
|
+
setLoadingSubmit(true)
|
|
28
|
+
try {
|
|
29
|
+
await props.handleSubmit({
|
|
30
|
+
choice: selectedEmoji,
|
|
31
|
+
feedback: feedbackText,
|
|
32
|
+
})
|
|
33
|
+
} catch (error) {
|
|
34
|
+
console.error("Error during submission:", error)
|
|
35
|
+
setLoadingSubmit(false)
|
|
36
|
+
}
|
|
37
|
+
await setLoadingSubmit(false)
|
|
38
|
+
} else {
|
|
39
|
+
setLoadingSubmit(false)
|
|
40
|
+
setHelperText(true)
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
return (
|
|
44
|
+
<div
|
|
45
|
+
className={cn(
|
|
46
|
+
"flex flex-col gap-2 rounded border p-2 transition-all",
|
|
47
|
+
selectedEmoji ? "h-[165px] min-w-fit" : "h-[44px] "
|
|
48
|
+
)}
|
|
49
|
+
>
|
|
50
|
+
<div className="flex flex-row items-center justify-center gap-2 ">
|
|
51
|
+
{/* <span className="whitespace-nowrap text-sm">
|
|
52
|
+
Was this helpful?
|
|
53
|
+
</span>*/}
|
|
54
|
+
<div className="flex flex-row justify-center gap-0.5 ">
|
|
55
|
+
{emojis.map((emoji, i) => (
|
|
56
|
+
<Button
|
|
57
|
+
key={i}
|
|
58
|
+
onClick={() => {
|
|
59
|
+
if (selectedEmoji === emoji.value) {
|
|
60
|
+
setSelectedEmoji("")
|
|
61
|
+
} else {
|
|
62
|
+
setSelectedEmoji(emoji.value)
|
|
63
|
+
}
|
|
64
|
+
}}
|
|
65
|
+
variant="ghost"
|
|
66
|
+
size="smallIcon"
|
|
67
|
+
className={cn(
|
|
68
|
+
selectedEmoji === emoji.value
|
|
69
|
+
? "bg-primary/10 hover:bg-primary/10 "
|
|
70
|
+
: "text-[#666666]"
|
|
71
|
+
)}
|
|
72
|
+
>
|
|
73
|
+
{emoji.icon}
|
|
74
|
+
</Button>
|
|
75
|
+
))}
|
|
76
|
+
</div>
|
|
77
|
+
</div>
|
|
78
|
+
<div
|
|
79
|
+
className={cn(
|
|
80
|
+
"flex flex-col overflow-clip transition-all duration-500 ease-in-out ",
|
|
81
|
+
selectedEmoji ? "visible opacity-100" : "invisible opacity-0 "
|
|
82
|
+
)}
|
|
83
|
+
>
|
|
84
|
+
{props.showSuccess ? (
|
|
85
|
+
<div className="flex h-full flex-col items-center justify-center gap-2 pt-4">
|
|
86
|
+
<div className="rounded bg-primary p-2 text-primary-foreground">
|
|
87
|
+
<svg
|
|
88
|
+
stroke="currentColor"
|
|
89
|
+
fill="currentColor"
|
|
90
|
+
strokeWidth="0"
|
|
91
|
+
viewBox="0 0 512 512"
|
|
92
|
+
height="0.5em"
|
|
93
|
+
width="0.5em"
|
|
94
|
+
>
|
|
95
|
+
<path d="M173.898 439.404l-166.4-166.4c-9.997-9.997-9.997-26.206 0-36.204l36.203-36.204c9.997-9.998 26.207-9.998 36.204 0L192 312.69 432.095 72.596c9.997-9.997 26.207-9.997 36.204 0l36.203 36.204c9.997 9.997 9.997 26.206 0 36.204l-294.4 294.401c-9.998 9.997-26.207 9.997-36.204-.001z"></path>
|
|
96
|
+
</svg>
|
|
97
|
+
</div>
|
|
98
|
+
<div className="text-sm flex flex-col text-center">
|
|
99
|
+
<span>Your feedback has been received!</span>
|
|
100
|
+
<span>Thank you for your help</span>
|
|
101
|
+
</div>
|
|
102
|
+
</div>
|
|
103
|
+
) : (
|
|
104
|
+
<>
|
|
105
|
+
<Popover
|
|
106
|
+
className="select-none p-1 text-xs "
|
|
107
|
+
open={helperText}
|
|
108
|
+
trigger={
|
|
109
|
+
<Textarea
|
|
110
|
+
className={cn("mb-2 h-full resize-none")}
|
|
111
|
+
placeholder="Your feedback"
|
|
112
|
+
onChange={(e) => {
|
|
113
|
+
if (e.target.value) {
|
|
114
|
+
setHelperText(false)
|
|
115
|
+
}
|
|
116
|
+
setFeedbackText(e.target.value)
|
|
117
|
+
console.log("changing to", e.target.value)
|
|
118
|
+
}}
|
|
119
|
+
/>
|
|
120
|
+
}
|
|
121
|
+
>
|
|
122
|
+
<span>Please enter your feedback</span>{" "}
|
|
123
|
+
</Popover>
|
|
124
|
+
<Button
|
|
125
|
+
isLoading={loadingSubmit}
|
|
126
|
+
onClick={onFeedbackSubmit}
|
|
127
|
+
className="w-full"
|
|
128
|
+
size="sm"
|
|
129
|
+
>
|
|
130
|
+
Submit
|
|
131
|
+
</Button>
|
|
132
|
+
</>
|
|
133
|
+
)}
|
|
134
|
+
</div>
|
|
135
|
+
</div>
|
|
136
|
+
)
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
const VeryGoodEmoji = () => (
|
|
140
|
+
<svg
|
|
141
|
+
fill="none"
|
|
142
|
+
height="16"
|
|
143
|
+
viewBox="0 0 16 16"
|
|
144
|
+
width="16"
|
|
145
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
146
|
+
>
|
|
147
|
+
<g clipPath="url(#clip0_53_166)">
|
|
148
|
+
<path
|
|
149
|
+
clipRule="evenodd"
|
|
150
|
+
d="M14.5 8C14.5 11.5899 11.5899 14.5 8 14.5C4.41015 14.5 1.5 11.5899 1.5 8C1.5 4.41015 4.41015 1.5 8 1.5C11.5899 1.5 14.5 4.41015 14.5 8ZM16 8C16 12.4183 12.4183 16 8 16C3.58172 16 0 12.4183 0 8C0 3.58172 3.58172 0 8 0C12.4183 0 16 3.58172 16 8ZM4.5 8.97498H3.875V9.59998C3.875 11.4747 5.81046 12.8637 7.99817 12.8637C10.1879 12.8637 12.125 11.4832 12.125 9.59998V8.97498H11.5H4.5ZM7.99817 11.6137C6.59406 11.6137 5.63842 10.9482 5.28118 10.225H10.7202C10.3641 10.9504 9.40797 11.6137 7.99817 11.6137Z"
|
|
151
|
+
fill="currentColor"
|
|
152
|
+
fillRule="evenodd"
|
|
153
|
+
></path>
|
|
154
|
+
<path
|
|
155
|
+
clipRule="evenodd"
|
|
156
|
+
d="M6.15295 4.92093L5.375 3.5L4.59705 4.92093L3 5.21885L4.11625 6.39495L3.90717 8L5.375 7.30593L6.84283 8L6.63375 6.39495L7.75 5.21885L6.15295 4.92093ZM11.403 4.92093L10.625 3.5L9.84705 4.92093L8.25 5.21885L9.36625 6.39495L9.15717 8L10.625 7.30593L12.0928 8L11.8837 6.39495L13 5.21885L11.403 4.92093Z"
|
|
157
|
+
fill="#FF990A"
|
|
158
|
+
fillRule="evenodd"
|
|
159
|
+
></path>
|
|
160
|
+
</g>
|
|
161
|
+
</svg>
|
|
162
|
+
)
|
|
163
|
+
const GoodEmoji = () => (
|
|
164
|
+
<svg
|
|
165
|
+
fill="none"
|
|
166
|
+
height="16"
|
|
167
|
+
viewBox="0 0 16 16"
|
|
168
|
+
width="16"
|
|
169
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
170
|
+
>
|
|
171
|
+
<g clipPath="url(#clip0_53_167)">
|
|
172
|
+
<path
|
|
173
|
+
clipRule="evenodd"
|
|
174
|
+
d="M14.5 8C14.5 11.5899 11.5899 14.5 8 14.5C4.41015 14.5 1.5 11.5899 1.5 8C1.5 4.41015 4.41015 1.5 8 1.5C11.5899 1.5 14.5 4.41015 14.5 8ZM16 8C16 12.4183 12.4183 16 8 16C3.58172 16 0 12.4183 0 8C0 3.58172 3.58172 0 8 0C12.4183 0 16 3.58172 16 8ZM11.5249 10.8478L11.8727 10.3286L10.8342 9.6329L10.4863 10.1522C9.94904 10.9543 9.0363 11.4802 8.00098 11.4802C6.96759 11.4802 6.05634 10.9563 5.51863 10.1567L5.16986 9.63804L4.13259 10.3356L4.48137 10.8542C5.2414 11.9844 6.53398 12.7302 8.00098 12.7302C9.47073 12.7302 10.7654 11.9816 11.5249 10.8478ZM6.75 6.75C6.75 7.30228 6.30228 7.75 5.75 7.75C5.19772 7.75 4.75 7.30228 4.75 6.75C4.75 6.19772 5.19772 5.75 5.75 5.75C6.30228 5.75 6.75 6.19772 6.75 6.75ZM10.25 7.75C10.8023 7.75 11.25 7.30228 11.25 6.75C11.25 6.19772 10.8023 5.75 10.25 5.75C9.69771 5.75 9.25 6.19772 9.25 6.75C9.25 7.30228 9.69771 7.75 10.25 7.75Z"
|
|
175
|
+
fill="currentColor"
|
|
176
|
+
fillRule="evenodd"
|
|
177
|
+
></path>
|
|
178
|
+
</g>
|
|
179
|
+
</svg>
|
|
180
|
+
)
|
|
181
|
+
const BadEmoji = () => (
|
|
182
|
+
<svg
|
|
183
|
+
fill="none"
|
|
184
|
+
height="16"
|
|
185
|
+
viewBox="0 0 16 16"
|
|
186
|
+
width="16"
|
|
187
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
188
|
+
>
|
|
189
|
+
<g clipPath="url(#clip0_53_152)">
|
|
190
|
+
<path
|
|
191
|
+
clipRule="evenodd"
|
|
192
|
+
d="M14.5 8C14.5 11.5899 11.5899 14.5 8 14.5C4.41015 14.5 1.5 11.5899 1.5 8C1.5 4.41015 4.41015 1.5 8 1.5C11.5899 1.5 14.5 4.41015 14.5 8ZM16 8C16 12.4183 12.4183 16 8 16C3.58172 16 0 12.4183 0 8C0 3.58172 3.58172 0 8 0C12.4183 0 16 3.58172 16 8ZM5.75 7.75C6.30228 7.75 6.75 7.30228 6.75 6.75C6.75 6.19772 6.30228 5.75 5.75 5.75C5.19772 5.75 4.75 6.19772 4.75 6.75C4.75 7.30228 5.19772 7.75 5.75 7.75ZM11.25 6.75C11.25 7.30228 10.8023 7.75 10.25 7.75C9.69771 7.75 9.25 7.30228 9.25 6.75C9.25 6.19772 9.69771 5.75 10.25 5.75C10.8023 5.75 11.25 6.19772 11.25 6.75ZM11.5249 11.2622L11.8727 11.7814L10.8342 12.4771L10.4863 11.9578C9.94904 11.1557 9.0363 10.6298 8.00098 10.6298C6.96759 10.6298 6.05634 11.1537 5.51863 11.9533L5.16986 12.4719L4.13259 11.7744L4.48137 11.2558C5.2414 10.1256 6.53398 9.37982 8.00098 9.37982C9.47073 9.37982 10.7654 10.1284 11.5249 11.2622Z"
|
|
193
|
+
fill="currentColor"
|
|
194
|
+
fillRule="evenodd"
|
|
195
|
+
></path>
|
|
196
|
+
</g>
|
|
197
|
+
</svg>
|
|
198
|
+
)
|
|
199
|
+
const VeryBadEmoji = () => (
|
|
200
|
+
<svg
|
|
201
|
+
fill="none"
|
|
202
|
+
height="16"
|
|
203
|
+
viewBox="0 0 16 16"
|
|
204
|
+
width="16"
|
|
205
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
206
|
+
>
|
|
207
|
+
<g clipPath="url(#clip0_53_151)">
|
|
208
|
+
<path
|
|
209
|
+
d="M11.841 12.0225C12.7197 12.9324 12.7197 14.4077 11.841 15.3176C10.9623 16.2275 9.53769 16.2275 8.65901 15.3176C7.78033 14.4077 7.78033 12.9324 8.65901 12.0225L10.25 10.375L11.841 12.0225Z"
|
|
210
|
+
fill="#0070F3"
|
|
211
|
+
></path>
|
|
212
|
+
<path
|
|
213
|
+
clipRule="evenodd"
|
|
214
|
+
d="M8 1.5C4.41015 1.5 1.5 4.41015 1.5 8C1.5 10.9668 3.48826 13.4711 6.20649 14.2496L5.79351 15.6916C2.44895 14.7338 0 11.6539 0 8C0 3.58172 3.58172 0 8 0C12.4183 0 16 3.58172 16 8C16 9.4652 15.6054 10.8405 14.9162 12.023L13.6203 11.2677C14.1794 10.3083 14.5 9.19272 14.5 8C14.5 4.41015 11.5899 1.5 8 1.5ZM6.75 6.75C6.75 7.30228 6.30228 7.75 5.75 7.75C5.19772 7.75 4.75 7.30228 4.75 6.75C4.75 6.19772 5.19772 5.75 5.75 5.75C6.30228 5.75 6.75 6.19772 6.75 6.75ZM10.25 7.75C10.8023 7.75 11.25 7.30228 11.25 6.75C11.25 6.19772 10.8023 5.75 10.25 5.75C9.69771 5.75 9.25 6.19772 9.25 6.75C9.25 7.30228 9.69771 7.75 10.25 7.75Z"
|
|
215
|
+
fill="currentColor"
|
|
216
|
+
fillRule="evenodd"
|
|
217
|
+
></path>
|
|
218
|
+
</g>
|
|
219
|
+
</svg>
|
|
220
|
+
)
|
|
@@ -13,7 +13,7 @@ type ComponentTypes = {
|
|
|
13
13
|
position?: "bottom-right" | "bottom-left"
|
|
14
14
|
onOptionClicked?: (option) => void
|
|
15
15
|
}
|
|
16
|
-
export const
|
|
16
|
+
export const FeedbackRating: FC<ComponentTypes> = ({
|
|
17
17
|
position = "bottom-right",
|
|
18
18
|
...props
|
|
19
19
|
}) => {
|
|
@@ -2,7 +2,7 @@ import React, { FC } from "react"
|
|
|
2
2
|
import clsx from "clsx"
|
|
3
3
|
|
|
4
4
|
type LoadingTypes = {
|
|
5
|
-
size?: "button" | "sm" | "normal" | "lg" | "xl"
|
|
5
|
+
size?: "button" | "xs" | "sm" | "normal" | "lg" | "xl"
|
|
6
6
|
design?: "spinner" | "dots-bounce" | "dots-pulse" | "pulse" | "spinner-dots"
|
|
7
7
|
color?: any
|
|
8
8
|
}
|
|
@@ -15,6 +15,7 @@ export const HawaLoading: FC<LoadingTypes> = ({
|
|
|
15
15
|
}) => {
|
|
16
16
|
let sizeStyles = {
|
|
17
17
|
button: "h-4 w-4",
|
|
18
|
+
xs: "h-1 w-1",
|
|
18
19
|
sm: "h-6 w-6",
|
|
19
20
|
normal: "h-8 w-8",
|
|
20
21
|
lg: "h-14 w-14",
|
|
@@ -96,11 +96,11 @@ export const HawaTextField: FC<TextFieldTypes> = ({
|
|
|
96
96
|
{props.iconInside}
|
|
97
97
|
</div>
|
|
98
98
|
)}
|
|
99
|
-
{props.helpertext
|
|
99
|
+
{props.helpertext && (
|
|
100
100
|
<p className="mb-0 mt-0 text-xs text-red-600 dark:text-red-500">
|
|
101
101
|
{props.helpertext}
|
|
102
102
|
</p>
|
|
103
|
-
)
|
|
103
|
+
)}
|
|
104
104
|
</>
|
|
105
105
|
</>
|
|
106
106
|
)}
|
package/src/elements/Popover.tsx
CHANGED
|
@@ -28,6 +28,7 @@ interface PopoverProps {
|
|
|
28
28
|
children: React.ReactNode
|
|
29
29
|
className?: string
|
|
30
30
|
sideOffset?: number
|
|
31
|
+
open?: boolean
|
|
31
32
|
}
|
|
32
33
|
|
|
33
34
|
const Popover: React.FC<PopoverProps> = ({
|
|
@@ -37,8 +38,9 @@ const Popover: React.FC<PopoverProps> = ({
|
|
|
37
38
|
align = "center",
|
|
38
39
|
side,
|
|
39
40
|
sideOffset = 4,
|
|
41
|
+
open,
|
|
40
42
|
}) => (
|
|
41
|
-
<PopoverPrimitive.Root>
|
|
43
|
+
<PopoverPrimitive.Root open={open}>
|
|
42
44
|
<PopoverPrimitive.Trigger>{trigger}</PopoverPrimitive.Trigger>
|
|
43
45
|
<PopoverContent
|
|
44
46
|
side={side}
|
|
@@ -5,22 +5,29 @@ import { Label } from "./Label"
|
|
|
5
5
|
export interface TextareaProps
|
|
6
6
|
extends React.TextareaHTMLAttributes<HTMLTextAreaElement> {
|
|
7
7
|
label?: string
|
|
8
|
+
helperText?: string
|
|
8
9
|
}
|
|
9
10
|
|
|
10
11
|
const Textarea = React.forwardRef<HTMLTextAreaElement, TextareaProps>(
|
|
11
|
-
({ className, label, ...props }, ref) => {
|
|
12
|
+
({ className, label, helperText, ...props }, ref) => {
|
|
12
13
|
return (
|
|
13
|
-
|
|
14
|
+
<div className="flex flex-col gap-2">
|
|
14
15
|
{label && <Label htmlFor={props.id}>{label}</Label>}
|
|
15
16
|
<textarea
|
|
16
17
|
className={cn(
|
|
17
|
-
"flex min-h-[80px] w-full rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background placeholder:text-muted-foreground
|
|
18
|
+
"flex min-h-[80px] w-full rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50",
|
|
19
|
+
// focus-visible:ring-offset-2
|
|
18
20
|
className
|
|
19
21
|
)}
|
|
20
22
|
ref={ref}
|
|
21
23
|
{...props}
|
|
22
24
|
/>
|
|
23
|
-
|
|
25
|
+
{helperText && (
|
|
26
|
+
<p className="mb-0 mt-0 text-xs text-red-600 dark:text-red-500">
|
|
27
|
+
{helperText}
|
|
28
|
+
</p>
|
|
29
|
+
)}
|
|
30
|
+
</div>
|
|
24
31
|
)
|
|
25
32
|
}
|
|
26
33
|
)
|
|
@@ -52,7 +52,7 @@ export const UserReferralSource: FC<ComponentTypes> = ({
|
|
|
52
52
|
return (
|
|
53
53
|
<Card
|
|
54
54
|
ref={popUpRef}
|
|
55
|
-
className={clsx("fixed bottom-4 p-
|
|
55
|
+
className={clsx("fixed bottom-4 p-0 ", boxPosition[position])}
|
|
56
56
|
>
|
|
57
57
|
<button
|
|
58
58
|
type="button"
|
package/src/elements/index.ts
CHANGED
|
@@ -28,7 +28,8 @@ export * from "./Breadcrumb"
|
|
|
28
28
|
export * from "./SubsectionList"
|
|
29
29
|
export * from "./UsageCard"
|
|
30
30
|
export * from "./InvoiceAccordion"
|
|
31
|
-
export * from "./
|
|
31
|
+
export * from "./FeedbackRating"
|
|
32
|
+
export * from "./FeedbackByEmoji"
|
|
32
33
|
export * from "./ArrowCarousel"
|
|
33
34
|
export * from "./FloatingComment"
|
|
34
35
|
export * from "./FloatingCommentSlate"
|
package/src/layout/Footer.tsx
CHANGED
package/src/styles.css
CHANGED
|
@@ -1172,6 +1172,9 @@ video {
|
|
|
1172
1172
|
.h-\[150px\] {
|
|
1173
1173
|
height: 150px;
|
|
1174
1174
|
}
|
|
1175
|
+
.h-\[165px\] {
|
|
1176
|
+
height: 165px;
|
|
1177
|
+
}
|
|
1175
1178
|
.h-\[16px\] {
|
|
1176
1179
|
height: 16px;
|
|
1177
1180
|
}
|
|
@@ -1199,6 +1202,9 @@ video {
|
|
|
1199
1202
|
.h-\[400px\] {
|
|
1200
1203
|
height: 400px;
|
|
1201
1204
|
}
|
|
1205
|
+
.h-\[44px\] {
|
|
1206
|
+
height: 44px;
|
|
1207
|
+
}
|
|
1202
1208
|
.h-\[80px\] {
|
|
1203
1209
|
height: 80px;
|
|
1204
1210
|
}
|
|
@@ -1440,6 +1446,9 @@ video {
|
|
|
1440
1446
|
.max-w-\[200px\] {
|
|
1441
1447
|
max-width: 200px;
|
|
1442
1448
|
}
|
|
1449
|
+
.max-w-\[300px\] {
|
|
1450
|
+
max-width: 300px;
|
|
1451
|
+
}
|
|
1443
1452
|
.max-w-\[52px\] {
|
|
1444
1453
|
max-width: 52px;
|
|
1445
1454
|
}
|
|
@@ -2565,6 +2574,10 @@ video {
|
|
|
2565
2574
|
.tracking-widest {
|
|
2566
2575
|
letter-spacing: 0.1em;
|
|
2567
2576
|
}
|
|
2577
|
+
.text-\[\#666666\] {
|
|
2578
|
+
--tw-text-opacity: 1;
|
|
2579
|
+
color: rgb(102 102 102 / var(--tw-text-opacity));
|
|
2580
|
+
}
|
|
2568
2581
|
.text-black {
|
|
2569
2582
|
--tw-text-opacity: 1;
|
|
2570
2583
|
color: rgb(0 0 0 / var(--tw-text-opacity));
|
|
@@ -2897,6 +2910,9 @@ video {
|
|
|
2897
2910
|
.duration-500 {
|
|
2898
2911
|
transition-duration: 500ms;
|
|
2899
2912
|
}
|
|
2913
|
+
.ease-in-out {
|
|
2914
|
+
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
|
|
2915
|
+
}
|
|
2900
2916
|
.will-change-transform {
|
|
2901
2917
|
will-change: transform;
|
|
2902
2918
|
}
|
|
@@ -2953,6 +2969,9 @@ video {
|
|
|
2953
2969
|
.delay-300 {
|
|
2954
2970
|
animation-delay: 300ms;
|
|
2955
2971
|
}
|
|
2972
|
+
.ease-in-out {
|
|
2973
|
+
animation-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
|
|
2974
|
+
}
|
|
2956
2975
|
.repeat-infinite {
|
|
2957
2976
|
animation-iteration-count: infinite;
|
|
2958
2977
|
}
|