@sikka/hawa 0.13.10-next → 0.13.12-next
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/index.css +30 -7
- package/dist/index.d.mts +2 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +804 -756
- package/dist/index.mjs +691 -639
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -919,7 +919,7 @@ var AdCard = function(_param) {
|
|
|
919
919
|
var import_clsx3 = __toESM(require("clsx"));
|
|
920
920
|
var import_react4 = __toESM(require("react"));
|
|
921
921
|
// components/elements/Button.tsx
|
|
922
|
-
var
|
|
922
|
+
var React4 = __toESM(require("react"));
|
|
923
923
|
var import_class_variance_authority = require("class-variance-authority");
|
|
924
924
|
// components/util.ts
|
|
925
925
|
var import_clsx2 = require("clsx");
|
|
@@ -1009,7 +1009,7 @@ var buttonVariants = (0, import_class_variance_authority.cva)("hawa-inline-flex
|
|
|
1009
1009
|
size: "default"
|
|
1010
1010
|
}
|
|
1011
1011
|
});
|
|
1012
|
-
var Button =
|
|
1012
|
+
var Button = React4.forwardRef(function(_param, ref) {
|
|
1013
1013
|
var className = _param.className, variant = _param.variant, size = _param.size, _param_asChild = _param.asChild, asChild = _param_asChild === void 0 ? false : _param_asChild, _param_centered = _param.centered, centered = _param_centered === void 0 ? true : _param_centered, isLoading = _param.isLoading, children = _param.children, props = _object_without_properties(_param, [
|
|
1014
1014
|
"className",
|
|
1015
1015
|
"variant",
|
|
@@ -1021,14 +1021,14 @@ var Button = React5.forwardRef(function(_param, ref) {
|
|
|
1021
1021
|
]);
|
|
1022
1022
|
var Comp = "button";
|
|
1023
1023
|
var loadingColor = variant === "outline" || variant === "ghost" || variant === "neoBrutalism" ? "hawa-bg-primary" : "hawa-bg-primary-foreground";
|
|
1024
|
-
return /* @__PURE__ */
|
|
1024
|
+
return /* @__PURE__ */ React4.createElement(Comp, _object_spread({
|
|
1025
1025
|
className: cn(buttonVariants({
|
|
1026
1026
|
variant: variant,
|
|
1027
1027
|
size: size,
|
|
1028
1028
|
className: className
|
|
1029
1029
|
}), centered && "hawa-justify-center"),
|
|
1030
1030
|
ref: ref
|
|
1031
|
-
}, props), isLoading ? /* @__PURE__ */
|
|
1031
|
+
}, props), isLoading ? /* @__PURE__ */ React4.createElement(Loading, {
|
|
1032
1032
|
design: "dots-pulse",
|
|
1033
1033
|
color: loadingColor,
|
|
1034
1034
|
size: size === "sm" ? "xs" : "button"
|
|
@@ -1036,8 +1036,8 @@ var Button = React5.forwardRef(function(_param, ref) {
|
|
|
1036
1036
|
});
|
|
1037
1037
|
Button.displayName = "Button";
|
|
1038
1038
|
// components/elements/Card.tsx
|
|
1039
|
-
var
|
|
1040
|
-
var Card =
|
|
1039
|
+
var React5 = __toESM(require("react"));
|
|
1040
|
+
var Card = React5.forwardRef(function(_param, ref) {
|
|
1041
1041
|
var className = _param.className, _param_variant = _param.variant, variant = _param_variant === void 0 ? "default" : _param_variant, _param_clickable = _param.clickable, clickable = _param_clickable === void 0 ? false : _param_clickable, props = _object_without_properties(_param, [
|
|
1042
1042
|
"className",
|
|
1043
1043
|
"variant",
|
|
@@ -1047,59 +1047,59 @@ var Card = React6.forwardRef(function(_param, ref) {
|
|
|
1047
1047
|
default: cn("hawa-rounded-lg hawa-border hawa-bg-card hawa-text-card-foreground hawa-shadow-sm", clickable && "hawa-cursor-pointer hawa-transition-all hover:hawa-drop-shadow-md dark:hover:dark-shadow"),
|
|
1048
1048
|
neoBrutalism: cn("hawa-transition-all hawa-uppercase hawa-font-mono dark:hawa-bg-black hawa-font-bold hawa-py-2 hawa-px-4 hawa-rounded hawa-border-2 hawa-border-primary hawa-shadow-color-primary hawa-transition-[hawa-transform_50ms, hawa-box-shadow_50ms] transition-all uppercase font-mono dark:bg-black font-bold py-2 px-4 rounded border-2 border-primary shadow-color-primary transition-[transform_50ms, box-shadow_50ms]", clickable && "hawa-cursor-pointer active:hawa-translate-x-0.5 active:hawa-translate-y-0.5 active:hawa-shadow-color-primary-active active:translate-x-0.5 active:translate-y-0.5 active:shadow-color-primary-active")
|
|
1049
1049
|
};
|
|
1050
|
-
return /* @__PURE__ */
|
|
1050
|
+
return /* @__PURE__ */ React5.createElement("div", _object_spread({
|
|
1051
1051
|
ref: ref,
|
|
1052
1052
|
className: cn(className, variantStyles[variant])
|
|
1053
1053
|
}, props));
|
|
1054
1054
|
});
|
|
1055
1055
|
Card.displayName = "Card";
|
|
1056
|
-
var CardHeader =
|
|
1056
|
+
var CardHeader = React5.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
1057
1057
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
1058
1058
|
"className"
|
|
1059
1059
|
]);
|
|
1060
|
-
return
|
|
1060
|
+
return React5.createElement("div", _object_spread({
|
|
1061
1061
|
ref: ref,
|
|
1062
1062
|
className: cn("hawa-flex hawa-flex-col hawa-space-y-1.5 hawa-p-6", className)
|
|
1063
1063
|
}, props));
|
|
1064
1064
|
});
|
|
1065
1065
|
CardHeader.displayName = "CardHeader";
|
|
1066
|
-
var CardTitle =
|
|
1066
|
+
var CardTitle = React5.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
1067
1067
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
1068
1068
|
"className"
|
|
1069
1069
|
]);
|
|
1070
|
-
return
|
|
1070
|
+
return React5.createElement("h3", _object_spread({
|
|
1071
1071
|
ref: ref,
|
|
1072
1072
|
className: cn("hawa-text-2xl hawa-font-semibold ", className)
|
|
1073
1073
|
}, props));
|
|
1074
1074
|
});
|
|
1075
1075
|
CardTitle.displayName = "CardTitle";
|
|
1076
|
-
var CardDescription =
|
|
1076
|
+
var CardDescription = React5.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
1077
1077
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
1078
1078
|
"className"
|
|
1079
1079
|
]);
|
|
1080
|
-
return
|
|
1080
|
+
return React5.createElement("p", _object_spread({
|
|
1081
1081
|
ref: ref,
|
|
1082
1082
|
className: cn("hawa-text-sm hawa-text-muted-foreground", className)
|
|
1083
1083
|
}, props));
|
|
1084
1084
|
});
|
|
1085
1085
|
CardDescription.displayName = "CardDescription";
|
|
1086
|
-
var CardContent =
|
|
1086
|
+
var CardContent = React5.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
1087
1087
|
var headless = _param.headless, noPadding = _param.noPadding, className = _param.className, props = _object_without_properties(_param, [
|
|
1088
1088
|
"headless",
|
|
1089
1089
|
"noPadding",
|
|
1090
1090
|
"className"
|
|
1091
1091
|
]);
|
|
1092
|
-
return
|
|
1092
|
+
return React5.createElement("div", _object_spread({
|
|
1093
1093
|
ref: ref,
|
|
1094
1094
|
className: cn(noPadding ? "hawa-p-0" : "hawa-p-6", headless ? "hawa-pt-6" : "hawa-pt-0", className)
|
|
1095
1095
|
}, props));
|
|
1096
1096
|
});
|
|
1097
1097
|
CardContent.displayName = "CardContent";
|
|
1098
|
-
var CardFooter =
|
|
1098
|
+
var CardFooter = React5.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
1099
1099
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
1100
1100
|
"className"
|
|
1101
1101
|
]);
|
|
1102
|
-
return
|
|
1102
|
+
return React5.createElement("div", _object_spread({
|
|
1103
1103
|
ref: ref,
|
|
1104
1104
|
className: cn("hawa-flex hawa-items-center hawa-p-6 hawa-pt-0", className)
|
|
1105
1105
|
}, props));
|
|
@@ -1163,24 +1163,24 @@ var PricingCard = function(_param) {
|
|
|
1163
1163
|
var import_react6 = __toESM(require("react"));
|
|
1164
1164
|
var import_clsx4 = __toESM(require("clsx"));
|
|
1165
1165
|
// components/elements/DropdownMenu.tsx
|
|
1166
|
-
var
|
|
1166
|
+
var React7 = __toESM(require("react"));
|
|
1167
1167
|
var DropdownMenuPrimitive = __toESM(require("@radix-ui/react-dropdown-menu"));
|
|
1168
1168
|
var DropdownMenuRoot = DropdownMenuPrimitive.Root;
|
|
1169
1169
|
var DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;
|
|
1170
1170
|
var DropdownMenuPortal = DropdownMenuPrimitive.Portal;
|
|
1171
1171
|
var DropdownMenuSub = DropdownMenuPrimitive.Sub;
|
|
1172
|
-
var DropdownMenuSubTrigger =
|
|
1172
|
+
var DropdownMenuSubTrigger = React7.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
1173
1173
|
var className = _param.className, inset = _param.inset, children = _param.children, props = _object_without_properties(_param, [
|
|
1174
1174
|
"className",
|
|
1175
1175
|
"inset",
|
|
1176
1176
|
"children"
|
|
1177
1177
|
]);
|
|
1178
|
-
return
|
|
1178
|
+
return React7.createElement(DropdownMenuPrimitive.SubTrigger, _object_spread({
|
|
1179
1179
|
ref: ref,
|
|
1180
1180
|
className: cn("hawa-flex hawa-cursor-default hawa-select-none hawa-items-center hawa-justify-between hawa-rounded-sm hawa-text-sm hawa-outline-none focus:hawa-bg-accent data-[state=open]:hawa-bg-accent", inset && "hawa-pl-8", className)
|
|
1181
|
-
}, props), /* @__PURE__ */
|
|
1181
|
+
}, props), /* @__PURE__ */ React7.createElement("div", {
|
|
1182
1182
|
className: "hawa-flex hawa-flex-row hawa-items-center hawa-gap-2"
|
|
1183
|
-
}, children), " ", /* @__PURE__ */
|
|
1183
|
+
}, children), " ", /* @__PURE__ */ React7.createElement("svg", {
|
|
1184
1184
|
"aria-label": "Chevron Right Icon",
|
|
1185
1185
|
stroke: "currentColor",
|
|
1186
1186
|
fill: "currentColor",
|
|
@@ -1189,61 +1189,61 @@ var DropdownMenuSubTrigger = React8.forwardRef(function(_param, ref) /* @__PURE_
|
|
|
1189
1189
|
height: "1em",
|
|
1190
1190
|
width: "1em",
|
|
1191
1191
|
className: cn(props.dir === "rtl" ? "hawa-rotate-180" : "")
|
|
1192
|
-
}, /* @__PURE__ */
|
|
1192
|
+
}, /* @__PURE__ */ React7.createElement("path", {
|
|
1193
1193
|
fillRule: "evenodd",
|
|
1194
1194
|
d: "M4.646 1.646a.5.5 0 0 1 .708 0l6 6a.5.5 0 0 1 0 .708l-6 6a.5.5 0 0 1-.708-.708L10.293 8 4.646 2.354a.5.5 0 0 1 0-.708z"
|
|
1195
1195
|
})));
|
|
1196
1196
|
});
|
|
1197
1197
|
DropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;
|
|
1198
|
-
var DropdownMenuSubContent =
|
|
1198
|
+
var DropdownMenuSubContent = React7.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
1199
1199
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
1200
1200
|
"className"
|
|
1201
1201
|
]);
|
|
1202
|
-
return
|
|
1202
|
+
return React7.createElement(DropdownMenuPrimitive.SubContent, _object_spread({
|
|
1203
1203
|
ref: ref,
|
|
1204
1204
|
className: cn("hawa-z-50 hawa-min-w-[8rem] hawa-gap-1 hawa-overflow-hidden hawa-rounded-md hawa-border hawa-bg-popover hawa-p-1 hawa-text-popover-foreground hawa-shadow-lg data-[state=open]:hawa-animate-in data-[state=closed]:hawa-animate-out data-[state=closed]:hawa-fade-out-0 data-[state=open]:hawa-fade-in-0 data-[state=closed]:hawa-zoom-out-95 data-[state=open]:hawa-zoom-in-95 data-[side=bottom]:hawa-slide-in-from-top-2 data-[side=left]:hawa-slide-in-from-right-2 data-[side=right]:hawa-slide-in-from-left-2 data-[side=top]:hawa-slide-in-from-bottom-2", className)
|
|
1205
1205
|
}, props));
|
|
1206
1206
|
});
|
|
1207
1207
|
DropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;
|
|
1208
|
-
var DropdownMenuContent =
|
|
1208
|
+
var DropdownMenuContent = React7.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
1209
1209
|
var className = _param.className, _param_sideOffset = _param.sideOffset, sideOffset = _param_sideOffset === void 0 ? 4 : _param_sideOffset, props = _object_without_properties(_param, [
|
|
1210
1210
|
"className",
|
|
1211
1211
|
"sideOffset"
|
|
1212
1212
|
]);
|
|
1213
|
-
return
|
|
1213
|
+
return React7.createElement(DropdownMenuPrimitive.Portal, null, /* @__PURE__ */ React7.createElement(DropdownMenuPrimitive.Content, _object_spread({
|
|
1214
1214
|
ref: ref,
|
|
1215
1215
|
sideOffset: sideOffset,
|
|
1216
1216
|
className: cn("hawa-z-50 hawa-overflow-hidden hawa-rounded-md hawa-border hawa-bg-popover hawa-p-1 hawa-text-popover-foreground hawa-shadow-md data-[state=open]:hawa-animate-in data-[state=closed]:hawa-animate-out data-[state=closed]:hawa-fade-out-0 data-[state=open]:hawa-fade-in-0 data-[state=closed]:hawa-zoom-out-95 data-[state=open]:hawa-zoom-in-95 data-[side=bottom]:hawa-slide-in-from-top-2 data-[side=left]:hawa-slide-in-from-right-2 data-[side=right]:hawa-slide-in-from-left-2 data-[side=top]:hawa-slide-in-from-bottom-2", className)
|
|
1217
1217
|
}, props)));
|
|
1218
1218
|
});
|
|
1219
1219
|
DropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;
|
|
1220
|
-
var DropdownMenuItem =
|
|
1220
|
+
var DropdownMenuItem = React7.forwardRef(function(_param, ref) {
|
|
1221
1221
|
var className = _param.className, inset = _param.inset, props = _object_without_properties(_param, [
|
|
1222
1222
|
"className",
|
|
1223
1223
|
"inset"
|
|
1224
1224
|
]);
|
|
1225
|
-
return /* @__PURE__ */
|
|
1225
|
+
return /* @__PURE__ */ React7.createElement(DropdownMenuPrimitive.Item, _object_spread({
|
|
1226
1226
|
disabled: props.disabled,
|
|
1227
1227
|
ref: ref,
|
|
1228
1228
|
className: cn("hawa-relative hawa-flex hawa-cursor-pointer hawa-select-none hawa-items-center hawa-justify-between hawa-rounded-sm hawa-text-sm hawa-outline-none hawa-transition-colors focus:hawa-text-accent-foreground data-[disabled]:hawa-pointer-events-none data-[disabled]:hawa-opacity-50", inset && "hawa-pl-8", props.end && Array.isArray(props.children) && props.children[1] && "hawa-gap-6", className)
|
|
1229
|
-
}, props), /* @__PURE__ */
|
|
1229
|
+
}, props), /* @__PURE__ */ React7.createElement("div", {
|
|
1230
1230
|
className: "hawa-flex hawa-flex-row hawa-items-center hawa-gap-2 "
|
|
1231
1231
|
}, props.children), props.end && props.end);
|
|
1232
1232
|
});
|
|
1233
1233
|
DropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;
|
|
1234
|
-
var DropdownMenuCheckboxItem =
|
|
1234
|
+
var DropdownMenuCheckboxItem = React7.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
1235
1235
|
var className = _param.className, children = _param.children, checked = _param.checked, props = _object_without_properties(_param, [
|
|
1236
1236
|
"className",
|
|
1237
1237
|
"children",
|
|
1238
1238
|
"checked"
|
|
1239
1239
|
]);
|
|
1240
|
-
return
|
|
1240
|
+
return React7.createElement(DropdownMenuPrimitive.CheckboxItem, _object_spread({
|
|
1241
1241
|
ref: ref,
|
|
1242
1242
|
className: cn("hawa-relative hawa-flex hawa-cursor-default hawa-select-none hawa-items-center hawa-rounded-sm hawa-py-1.5 hawa-pl-8 hawa-pr-2 hawa-text-sm hawa-outline-none hawa-transition-colors focus:hawa-bg-accent focus:hawa-text-accent-foreground data-[disabled]:hawa-pointer-events-none data-[disabled]:hawa-opacity-50", className),
|
|
1243
1243
|
checked: checked
|
|
1244
|
-
}, props), /* @__PURE__ */
|
|
1244
|
+
}, props), /* @__PURE__ */ React7.createElement("span", {
|
|
1245
1245
|
className: "hawa-absolute hawa-left-2 hawa-flex hawa-h-3.5 hawa-w-3.5 hawa-items-center hawa-justify-center"
|
|
1246
|
-
}, /* @__PURE__ */
|
|
1246
|
+
}, /* @__PURE__ */ React7.createElement(DropdownMenuPrimitive.ItemIndicator, null, /* @__PURE__ */ React7.createElement("svg", {
|
|
1247
1247
|
"aria-label": "Check Mark",
|
|
1248
1248
|
stroke: "currentColor",
|
|
1249
1249
|
fill: "currentColor",
|
|
@@ -1251,22 +1251,22 @@ var DropdownMenuCheckboxItem = React8.forwardRef(function(_param, ref) /* @__PUR
|
|
|
1251
1251
|
viewBox: "0 0 512 512",
|
|
1252
1252
|
height: "0.60em",
|
|
1253
1253
|
width: "0.60em"
|
|
1254
|
-
}, /* @__PURE__ */
|
|
1254
|
+
}, /* @__PURE__ */ React7.createElement("path", {
|
|
1255
1255
|
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"
|
|
1256
1256
|
})), " ")), children);
|
|
1257
1257
|
});
|
|
1258
1258
|
DropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;
|
|
1259
|
-
var DropdownMenuRadioItem =
|
|
1259
|
+
var DropdownMenuRadioItem = React7.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
1260
1260
|
var className = _param.className, children = _param.children, props = _object_without_properties(_param, [
|
|
1261
1261
|
"className",
|
|
1262
1262
|
"children"
|
|
1263
1263
|
]);
|
|
1264
|
-
return
|
|
1264
|
+
return React7.createElement(DropdownMenuPrimitive.RadioItem, _object_spread({
|
|
1265
1265
|
ref: ref,
|
|
1266
1266
|
className: cn("hawa-relative hawa-flex hawa-cursor-default hawa-select-none hawa-items-center hawa-rounded-sm hawa-py-1.5 hawa-pl-8 hawa-pr-2 hawa-text-sm hawa-outline-none hawa-transition-colors focus:hawa-bg-accent focus:hawa-text-accent-foreground data-[disabled]:hawa-pointer-events-none data-[disabled]:hawa-opacity-50", className)
|
|
1267
|
-
}, props), /* @__PURE__ */
|
|
1267
|
+
}, props), /* @__PURE__ */ React7.createElement("span", {
|
|
1268
1268
|
className: "hawa-absolute hawa-left-2 hawa-flex hawa-h-3.5 hawa-w-3.5 hawa-items-center hawa-justify-center"
|
|
1269
|
-
}, /* @__PURE__ */
|
|
1269
|
+
}, /* @__PURE__ */ React7.createElement(DropdownMenuPrimitive.ItemIndicator, null, /* @__PURE__ */ React7.createElement("svg", {
|
|
1270
1270
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1271
1271
|
width: "24",
|
|
1272
1272
|
"aria-label": "Circle",
|
|
@@ -1278,29 +1278,29 @@ var DropdownMenuRadioItem = React8.forwardRef(function(_param, ref) /* @__PURE__
|
|
|
1278
1278
|
strokeLinecap: "round",
|
|
1279
1279
|
strokeLinejoin: "round",
|
|
1280
1280
|
className: "hawa-h-2 hawa-w-2 hawa-fill-current"
|
|
1281
|
-
}, /* @__PURE__ */
|
|
1281
|
+
}, /* @__PURE__ */ React7.createElement("circle", {
|
|
1282
1282
|
cx: "12",
|
|
1283
1283
|
cy: "12",
|
|
1284
1284
|
r: "10"
|
|
1285
1285
|
})))), children);
|
|
1286
1286
|
});
|
|
1287
1287
|
DropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;
|
|
1288
|
-
var DropdownMenuLabel =
|
|
1288
|
+
var DropdownMenuLabel = React7.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
1289
1289
|
var className = _param.className, inset = _param.inset, props = _object_without_properties(_param, [
|
|
1290
1290
|
"className",
|
|
1291
1291
|
"inset"
|
|
1292
1292
|
]);
|
|
1293
|
-
return
|
|
1293
|
+
return React7.createElement(DropdownMenuPrimitive.Label, _object_spread({
|
|
1294
1294
|
ref: ref,
|
|
1295
1295
|
className: cn("hawa-px-2 hawa-py-1.5 hawa-text-sm hawa-font-semibold", inset && "hawa-pl-8", className)
|
|
1296
1296
|
}, props));
|
|
1297
1297
|
});
|
|
1298
1298
|
DropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;
|
|
1299
|
-
var DropdownMenuSeparator =
|
|
1299
|
+
var DropdownMenuSeparator = React7.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
1300
1300
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
1301
1301
|
"className"
|
|
1302
1302
|
]);
|
|
1303
|
-
return
|
|
1303
|
+
return React7.createElement(DropdownMenuPrimitive.Separator, _object_spread({
|
|
1304
1304
|
ref: ref,
|
|
1305
1305
|
className: cn("hawa--mx-1 hawa-my-1 hawa-h-px hawa-bg-muted", className)
|
|
1306
1306
|
}, props));
|
|
@@ -1310,7 +1310,7 @@ var DropdownMenuShortcut = function(_param) {
|
|
|
1310
1310
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
1311
1311
|
"className"
|
|
1312
1312
|
]);
|
|
1313
|
-
return /* @__PURE__ */
|
|
1313
|
+
return /* @__PURE__ */ React7.createElement("span", _object_spread({
|
|
1314
1314
|
className: cn("hawa-ml-auto hawa-text-xs hawa-tracking-widest hawa-opacity-60", className)
|
|
1315
1315
|
}, props));
|
|
1316
1316
|
};
|
|
@@ -1327,15 +1327,15 @@ var DropdownMenu = function(param) {
|
|
|
1327
1327
|
default: "hawa-px-2 hawa-py-3 ",
|
|
1328
1328
|
sm: "hawa-text-xs hawa-px-1.5 hawa-py-1.5 "
|
|
1329
1329
|
};
|
|
1330
|
-
return /* @__PURE__ */
|
|
1330
|
+
return /* @__PURE__ */ React7.createElement(DropdownMenuRoot, {
|
|
1331
1331
|
onOpenChange: onOpenChange,
|
|
1332
1332
|
open: open,
|
|
1333
1333
|
modal: false,
|
|
1334
1334
|
dir: direction
|
|
1335
|
-
}, /* @__PURE__ */
|
|
1335
|
+
}, /* @__PURE__ */ React7.createElement(DropdownMenuTrigger, {
|
|
1336
1336
|
asChild: true,
|
|
1337
1337
|
className: triggerClassname
|
|
1338
|
-
}, trigger), /* @__PURE__ */
|
|
1338
|
+
}, trigger), /* @__PURE__ */ React7.createElement(DropdownMenuPortal, null, /* @__PURE__ */ React7.createElement(DropdownMenuContent, {
|
|
1339
1339
|
side: side,
|
|
1340
1340
|
sideOffset: sideOffset,
|
|
1341
1341
|
className: cn(className, widthStyles[width], "hawa-flex hawa-flex-col hawa-gap-1"),
|
|
@@ -1343,25 +1343,25 @@ var DropdownMenu = function(param) {
|
|
|
1343
1343
|
alignOffset: alignOffset
|
|
1344
1344
|
}, items && items.map(function(item, index) {
|
|
1345
1345
|
if (item.itemType === "separator") {
|
|
1346
|
-
return /* @__PURE__ */
|
|
1346
|
+
return /* @__PURE__ */ React7.createElement(DropdownMenuSeparator, {
|
|
1347
1347
|
key: index
|
|
1348
1348
|
});
|
|
1349
1349
|
} else if (item.itemType === "label") {
|
|
1350
|
-
return /* @__PURE__ */
|
|
1350
|
+
return /* @__PURE__ */ React7.createElement(DropdownMenuLabel, {
|
|
1351
1351
|
key: index
|
|
1352
1352
|
}, item.label);
|
|
1353
1353
|
} else if (item.itemType === "custom") {
|
|
1354
|
-
return /* @__PURE__ */
|
|
1354
|
+
return /* @__PURE__ */ React7.createElement("div", {
|
|
1355
1355
|
key: index
|
|
1356
1356
|
}, item.content);
|
|
1357
1357
|
} else {
|
|
1358
|
-
return item.subitems ? /* @__PURE__ */
|
|
1358
|
+
return item.subitems ? /* @__PURE__ */ React7.createElement(DropdownMenuSub, {
|
|
1359
1359
|
key: index
|
|
1360
|
-
}, /* @__PURE__ */
|
|
1360
|
+
}, /* @__PURE__ */ React7.createElement(DropdownMenuSubTrigger, {
|
|
1361
1361
|
className: cn(sizeStyles[size]),
|
|
1362
1362
|
dir: direction
|
|
1363
|
-
}, item.icon && item.icon, item.label && item.label), /* @__PURE__ */
|
|
1364
|
-
return /* @__PURE__ */
|
|
1363
|
+
}, item.icon && item.icon, item.label && item.label), /* @__PURE__ */ React7.createElement(DropdownMenuPortal, null, /* @__PURE__ */ React7.createElement(DropdownMenuSubContent, null, item.subitems.map(function(subitem, subIndex) {
|
|
1364
|
+
return /* @__PURE__ */ React7.createElement(DropdownMenuItem, {
|
|
1365
1365
|
key: subIndex,
|
|
1366
1366
|
className: cn(sizeStyles[size], !item.icon && !item.label ? "hawa-px-0 hawa-py-0 focus:hawa-bg-transparent" : "focus:hawa-bg-accent"),
|
|
1367
1367
|
disabled: subitem.disabled,
|
|
@@ -1372,7 +1372,7 @@ var DropdownMenu = function(param) {
|
|
|
1372
1372
|
}
|
|
1373
1373
|
}
|
|
1374
1374
|
}, subitem.icon && subitem.icon, subitem.label && subitem.label);
|
|
1375
|
-
})))) : /* @__PURE__ */
|
|
1375
|
+
})))) : /* @__PURE__ */ React7.createElement(DropdownMenuItem, {
|
|
1376
1376
|
key: index,
|
|
1377
1377
|
disabled: item.disabled,
|
|
1378
1378
|
onMouseDown: function(event) {
|
|
@@ -1547,7 +1547,7 @@ var LandingCard = function(props) {
|
|
|
1547
1547
|
}, /* @__PURE__ */ import_react7.default.createElement(CardHeader, null, props.icon, /* @__PURE__ */ import_react7.default.createElement(CardTitle, null, props.title), /* @__PURE__ */ import_react7.default.createElement(CardDescription, null, props.subtitle)));
|
|
1548
1548
|
};
|
|
1549
1549
|
// components/elements/SplitButton.tsx
|
|
1550
|
-
var
|
|
1550
|
+
var React11 = __toESM(require("react"));
|
|
1551
1551
|
var SplitButton = function(_param) /* @__PURE__ */ {
|
|
1552
1552
|
var variant = _param.variant, _param_direction = _param.direction, direction = _param_direction === void 0 ? "ltr" : _param_direction, _param_menuItems = _param.menuItems, menuItems = _param_menuItems === void 0 ? [] : _param_menuItems, children = _param.children, props = _object_without_properties(_param, [
|
|
1553
1553
|
"variant",
|
|
@@ -1555,25 +1555,25 @@ var SplitButton = function(_param) /* @__PURE__ */ {
|
|
|
1555
1555
|
"menuItems",
|
|
1556
1556
|
"children"
|
|
1557
1557
|
]);
|
|
1558
|
-
return
|
|
1558
|
+
return React11.createElement("div", {
|
|
1559
1559
|
className: cn("hawa-h-fit hawa-flex hawa-justify-center", direction === "rtl" ? "hawa-flex-row-reverse" : "hawa-flex-row")
|
|
1560
|
-
}, /* @__PURE__ */
|
|
1560
|
+
}, /* @__PURE__ */ React11.createElement(Button, {
|
|
1561
1561
|
variant: variant,
|
|
1562
1562
|
onClick: function() {
|
|
1563
1563
|
return console.log("btn clicked");
|
|
1564
1564
|
},
|
|
1565
1565
|
className: cn(direction === "rtl" ? "hawa-rounded-r-none" : "hawa-rounded-l-none", props.className)
|
|
1566
|
-
}, children), /* @__PURE__ */
|
|
1566
|
+
}, children), /* @__PURE__ */ React11.createElement(DropdownMenu, {
|
|
1567
1567
|
size: "sm",
|
|
1568
1568
|
width: "sm",
|
|
1569
1569
|
direction: direction,
|
|
1570
1570
|
items: menuItems,
|
|
1571
|
-
trigger: /* @__PURE__ */
|
|
1571
|
+
trigger: /* @__PURE__ */ React11.createElement(Button, {
|
|
1572
1572
|
asChild: true,
|
|
1573
1573
|
variant: variant,
|
|
1574
1574
|
size: "icon",
|
|
1575
1575
|
className: cn("hawa-h-10 hawa-w-fit hawa-px-1", direction === "rtl" ? "hawa-rounded-l-none hawa-border-rl0" : "hawa-border-r-0 hawa-rounded-r-none", props.className)
|
|
1576
|
-
}, /* @__PURE__ */
|
|
1576
|
+
}, /* @__PURE__ */ React11.createElement("svg", {
|
|
1577
1577
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1578
1578
|
width: "18",
|
|
1579
1579
|
height: "18",
|
|
@@ -1583,38 +1583,38 @@ var SplitButton = function(_param) /* @__PURE__ */ {
|
|
|
1583
1583
|
strokeWidth: "2",
|
|
1584
1584
|
strokeLinecap: "round",
|
|
1585
1585
|
strokeLinejoin: "round"
|
|
1586
|
-
}, /* @__PURE__ */
|
|
1586
|
+
}, /* @__PURE__ */ React11.createElement("path", {
|
|
1587
1587
|
d: "m6 9 6 6 6-6"
|
|
1588
1588
|
})))
|
|
1589
1589
|
}));
|
|
1590
1590
|
};
|
|
1591
1591
|
SplitButton.displayName = "SplitButton";
|
|
1592
1592
|
// components/elements/Dialog.tsx
|
|
1593
|
-
var
|
|
1593
|
+
var React12 = __toESM(require("react"));
|
|
1594
1594
|
var DialogPrimitive = __toESM(require("@radix-ui/react-dialog"));
|
|
1595
1595
|
var Dialog = DialogPrimitive.Root;
|
|
1596
1596
|
var DialogTrigger = DialogPrimitive.Trigger;
|
|
1597
1597
|
var DialogPortal = function(_param) /* @__PURE__ */ {
|
|
1598
1598
|
var props = _extends({}, _object_destructuring_empty(_param));
|
|
1599
|
-
return
|
|
1599
|
+
return React12.createElement(DialogPrimitive.Portal, _object_spread({}, props));
|
|
1600
1600
|
};
|
|
1601
1601
|
DialogPortal.displayName = DialogPrimitive.Portal.displayName;
|
|
1602
|
-
var DialogOverlay =
|
|
1602
|
+
var DialogOverlay = React12.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
1603
1603
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
1604
1604
|
"className"
|
|
1605
1605
|
]);
|
|
1606
|
-
return
|
|
1606
|
+
return React12.createElement(DialogPrimitive.Overlay, _object_spread({
|
|
1607
1607
|
ref: ref,
|
|
1608
1608
|
className: cn("hawa-fixed hawa-inset-0 hawa-z-50 hawa-bg-background/80 hawa-backdrop-blur-sm data-[state=open]:hawa-animate-in data-[state=closed]:hawa-animate-out data-[state=closed]:hawa-fade-out-0 data-[state=open]:hawa-fade-in-0", className)
|
|
1609
1609
|
}, props));
|
|
1610
1610
|
});
|
|
1611
1611
|
DialogOverlay.displayName = DialogPrimitive.Overlay.displayName;
|
|
1612
|
-
var DialogContent =
|
|
1612
|
+
var DialogContent = React12.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
1613
1613
|
var className = _param.className, children = _param.children, props = _object_without_properties(_param, [
|
|
1614
1614
|
"className",
|
|
1615
1615
|
"children"
|
|
1616
1616
|
]);
|
|
1617
|
-
return
|
|
1617
|
+
return React12.createElement(DialogPortal, null, /* @__PURE__ */ React12.createElement(DialogOverlay, null), /* @__PURE__ */ React12.createElement(DialogPrimitive.Content, _object_spread({
|
|
1618
1618
|
onPointerDownOutside: function(e) {
|
|
1619
1619
|
if (props.persist) {
|
|
1620
1620
|
e.preventDefault();
|
|
@@ -1622,19 +1622,19 @@ var DialogContent = React13.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
|
1622
1622
|
},
|
|
1623
1623
|
ref: ref,
|
|
1624
1624
|
className: cn("hawa-fixed hawa-left-[50%] hawa-top-[50%] hawa-z-50 hawa-grid hawa-w-full hawa-max-w-lg hawa-translate-x-[-50%] hawa-translate-y-[-50%] hawa-gap-4 hawa-border hawa-bg-background hawa-p-6 hawa-shadow-lg hawa-duration-200 data-[state=open]:hawa-animate-in data-[state=closed]:hawa-animate-out data-[state=closed]:hawa-fade-out-0 data-[state=open]:hawa-fade-in-0 data-[state=closed]:hawa-zoom-out-95 data-[state=open]:hawa-zoom-in-95 data-[state=closed]:hawa-slide-out-to-left-1/2 data-[state=closed]:hawa-slide-out-to-top-[48%] data-[state=open]:hawa-slide-in-from-left-1/2 data-[state=open]:hawa-slide-in-from-top-[48%] sm:hawa-rounded md:hawa-w-full", className)
|
|
1625
|
-
}, props), children, /* @__PURE__ */
|
|
1625
|
+
}, props), children, /* @__PURE__ */ React12.createElement(DialogPrimitive.Close, {
|
|
1626
1626
|
className: cn("hawa-absolute hawa-top-4 hawa-rounded hawa-opacity-70 hawa-ring-offset-background hawa-transition-opacity hover:hawa-opacity-100 focus:hawa-outline-none focus:hawa-ring-2 focus:hawa-ring-ring focus:hawa-ring-offset-2 disabled:hawa-pointer-events-none data-[state=open]:hawa-bg-accent data-[state=open]:hawa-text-muted-foreground", props.dir === "rtl" ? " hawa-left-4" : " hawa-right-4")
|
|
1627
|
-
}, /* @__PURE__ */
|
|
1627
|
+
}, /* @__PURE__ */ React12.createElement("svg", {
|
|
1628
1628
|
"aria-label": "Close Icon",
|
|
1629
1629
|
"aria-hidden": "true",
|
|
1630
1630
|
className: "hawa-h-5 hawa-w-5",
|
|
1631
1631
|
fill: "currentColor",
|
|
1632
1632
|
viewBox: "0 0 20 20"
|
|
1633
|
-
}, /* @__PURE__ */
|
|
1633
|
+
}, /* @__PURE__ */ React12.createElement("path", {
|
|
1634
1634
|
fillRule: "evenodd",
|
|
1635
1635
|
d: "M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z",
|
|
1636
1636
|
clipRule: "evenodd"
|
|
1637
|
-
})), /* @__PURE__ */
|
|
1637
|
+
})), /* @__PURE__ */ React12.createElement("span", {
|
|
1638
1638
|
className: "hawa-sr-only"
|
|
1639
1639
|
}, "Close"))));
|
|
1640
1640
|
});
|
|
@@ -1643,26 +1643,26 @@ var DialogHeader = function(_param) /* @__PURE__ */ {
|
|
|
1643
1643
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
1644
1644
|
"className"
|
|
1645
1645
|
]);
|
|
1646
|
-
return
|
|
1646
|
+
return React12.createElement("div", _object_spread({
|
|
1647
1647
|
className: cn("hawa-flex hawa-flex-col hawa-space-y-1.5 hawa-text-center sm:hawa-text-left", className)
|
|
1648
1648
|
}, props));
|
|
1649
1649
|
};
|
|
1650
1650
|
DialogHeader.displayName = "DialogHeader";
|
|
1651
|
-
var DialogTitle =
|
|
1651
|
+
var DialogTitle = React12.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
1652
1652
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
1653
1653
|
"className"
|
|
1654
1654
|
]);
|
|
1655
|
-
return
|
|
1655
|
+
return React12.createElement(DialogPrimitive.Title, _object_spread({
|
|
1656
1656
|
ref: ref,
|
|
1657
1657
|
className: cn("hawa-text-start hawa-text-lg hawa-font-semibold hawa-leading-none hawa-tracking-tight", className)
|
|
1658
1658
|
}, props));
|
|
1659
1659
|
});
|
|
1660
1660
|
DialogTitle.displayName = DialogPrimitive.Title.displayName;
|
|
1661
|
-
var DialogDescription =
|
|
1661
|
+
var DialogDescription = React12.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
1662
1662
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
1663
1663
|
"className"
|
|
1664
1664
|
]);
|
|
1665
|
-
return
|
|
1665
|
+
return React12.createElement(DialogPrimitive.Description, _object_spread({
|
|
1666
1666
|
ref: ref,
|
|
1667
1667
|
className: cn("hawa-text-start hawa-text-sm hawa-text-muted-foreground", className)
|
|
1668
1668
|
}, props));
|
|
@@ -1672,7 +1672,7 @@ var DialogFooter = function(_param) /* @__PURE__ */ {
|
|
|
1672
1672
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
1673
1673
|
"className"
|
|
1674
1674
|
]);
|
|
1675
|
-
return
|
|
1675
|
+
return React12.createElement("div", _object_spread({
|
|
1676
1676
|
className: cn("hawa-flex hawa-flex-col-reverse sm:hawa-flex-row sm:hawa-justify-end sm:hawa-gap-2", className)
|
|
1677
1677
|
}, props));
|
|
1678
1678
|
};
|
|
@@ -1880,7 +1880,7 @@ var CodeBlock = function(_param) {
|
|
|
1880
1880
|
})))))));
|
|
1881
1881
|
};
|
|
1882
1882
|
// components/elements/Checkbox.tsx
|
|
1883
|
-
var
|
|
1883
|
+
var React16 = __toESM(require("react"));
|
|
1884
1884
|
var CheckboxPrimitive = __toESM(require("@radix-ui/react-checkbox"));
|
|
1885
1885
|
var Checkbox = function(_param) {
|
|
1886
1886
|
var id = _param.id, label = _param.label, sublabel = _param.sublabel, helperText = _param.helperText, checkboxProps = _object_without_properties(_param, [
|
|
@@ -1889,33 +1889,33 @@ var Checkbox = function(_param) {
|
|
|
1889
1889
|
"sublabel",
|
|
1890
1890
|
"helperText"
|
|
1891
1891
|
]);
|
|
1892
|
-
return /* @__PURE__ */
|
|
1892
|
+
return /* @__PURE__ */ React16.createElement("div", {
|
|
1893
1893
|
className: "hawa-items-top hawa-flex hawa-gap-2 "
|
|
1894
|
-
}, /* @__PURE__ */
|
|
1894
|
+
}, /* @__PURE__ */ React16.createElement(CheckboxElement, _object_spread({
|
|
1895
1895
|
id: id
|
|
1896
|
-
}, checkboxProps)), (label || helperText) && /* @__PURE__ */
|
|
1896
|
+
}, checkboxProps)), (label || helperText) && /* @__PURE__ */ React16.createElement("div", {
|
|
1897
1897
|
className: "hawa-grid hawa-gap-1.5 hawa-leading-none"
|
|
1898
|
-
}, label && /* @__PURE__ */
|
|
1898
|
+
}, label && /* @__PURE__ */ React16.createElement("label", {
|
|
1899
1899
|
htmlFor: id,
|
|
1900
1900
|
className: cn("hawa-cursor-pointer hawa-select-none hawa-text-sm hawa-font-medium hawa-leading-none hawa-pt-0.5", checkboxProps.disabled && "hawa-cursor-not-allowed hawa-text-muted-foreground hawa-opacity-70 ")
|
|
1901
|
-
}, label), sublabel && /* @__PURE__ */
|
|
1901
|
+
}, label), sublabel && /* @__PURE__ */ React16.createElement("label", {
|
|
1902
1902
|
htmlFor: id,
|
|
1903
1903
|
className: cn("hawa-cursor-pointer hawa-select-none hawa-text-sm hawa-text-muted-foreground", checkboxProps.disabled && "hawa-cursor-not-allowed hawa-text-muted-foreground hawa-opacity-70")
|
|
1904
|
-
}, sublabel), helperText && !checkboxProps.disabled && /* @__PURE__ */
|
|
1904
|
+
}, sublabel), helperText && !checkboxProps.disabled && /* @__PURE__ */ React16.createElement("label", {
|
|
1905
1905
|
htmlFor: id,
|
|
1906
1906
|
className: cn("hawa-select-none hawa-text-xs hawa-text-helper-color", checkboxProps.disabled && "hawa-cursor-not-allowed hawa-opacity-70")
|
|
1907
1907
|
}, helperText)));
|
|
1908
1908
|
};
|
|
1909
|
-
var CheckboxElement =
|
|
1909
|
+
var CheckboxElement = React16.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
1910
1910
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
1911
1911
|
"className"
|
|
1912
1912
|
]);
|
|
1913
|
-
return
|
|
1913
|
+
return React16.createElement(CheckboxPrimitive.Root, _object_spread({
|
|
1914
1914
|
ref: ref,
|
|
1915
1915
|
className: cn("hawa-peer hawa-h-4 hawa-w-4 hawa-shrink-0 hawa-rounded-sm hawa-border hawa-border-primary hawa-ring-offset-background focus-visible:hawa-outline-none focus-visible:hawa-ring-2 focus-visible:hawa-ring-ring focus-visible:hawa-ring-offset-2 disabled:hawa-cursor-not-allowed disabled:hawa-opacity-50 data-[state=checked]:hawa-bg-primary data-[state=checked]:hawa-text-primary-foreground", className)
|
|
1916
|
-
}, props), /* @__PURE__ */
|
|
1916
|
+
}, props), /* @__PURE__ */ React16.createElement(CheckboxPrimitive.Indicator, {
|
|
1917
1917
|
className: cn("hawa-flex hawa-items-center hawa-justify-center hawa-text-current")
|
|
1918
|
-
}, /* @__PURE__ */
|
|
1918
|
+
}, /* @__PURE__ */ React16.createElement("svg", {
|
|
1919
1919
|
"aria-label": "Check Mark",
|
|
1920
1920
|
stroke: "currentColor",
|
|
1921
1921
|
fill: "currentColor",
|
|
@@ -1923,13 +1923,13 @@ var CheckboxElement = React17.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
|
1923
1923
|
viewBox: "0 0 512 512",
|
|
1924
1924
|
height: "0.60em",
|
|
1925
1925
|
width: "0.60em"
|
|
1926
|
-
}, /* @__PURE__ */
|
|
1926
|
+
}, /* @__PURE__ */ React16.createElement("path", {
|
|
1927
1927
|
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"
|
|
1928
1928
|
})), " "));
|
|
1929
1929
|
});
|
|
1930
1930
|
CheckboxElement.displayName = CheckboxPrimitive.Root.displayName;
|
|
1931
1931
|
// components/elements/Toast.tsx
|
|
1932
|
-
var
|
|
1932
|
+
var React17 = __toESM(require("react"));
|
|
1933
1933
|
var ToastPrimitives = __toESM(require("@radix-ui/react-toast"));
|
|
1934
1934
|
var import_class_variance_authority2 = require("class-variance-authority");
|
|
1935
1935
|
var toastVariants = (0, import_class_variance_authority2.cva)("hawa-group hawa-pointer-events-auto hawa-relative hawa-flex hawa-w-full hawa-items-center hawa-justify-between hawa-space-x-4 hawa-overflow-hidden hawa-rounded-md hawa-border hawa-shadow-lg hawa-transition-all data-[swipe=cancel]:hawa-translate-x-0 data-[swipe=end]:hawa-translate-x-[var(--radix-toast-swipe-end-x)] data-[swipe=move]:hawa-translate-x-[var(--radix-toast-swipe-move-x)] data-[swipe=move]:hawa-transition-none data-[state=open]:hawa-animate-in data-[state=closed]:hawa-animate-out data-[swipe=end]:hawa-animate-out data-[state=closed]:hawa-fade-out-80 data-[state=open]:hawa-slide-in-from-top-full data-[state=open]:sm:hawa-slide-in-from-bottom-full", {
|
|
@@ -1951,24 +1951,24 @@ var toastVariants = (0, import_class_variance_authority2.cva)("hawa-group hawa-p
|
|
|
1951
1951
|
}
|
|
1952
1952
|
});
|
|
1953
1953
|
var ToastProvider = ToastPrimitives.Provider;
|
|
1954
|
-
var ToastViewport =
|
|
1954
|
+
var ToastViewport = React17.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
1955
1955
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
1956
1956
|
"className"
|
|
1957
1957
|
]);
|
|
1958
|
-
return
|
|
1958
|
+
return React17.createElement(ToastPrimitives.Viewport, _object_spread({
|
|
1959
1959
|
ref: ref,
|
|
1960
1960
|
className: cn("hawa-fixed hawa-top-0 hawa-z-[100] hawa-flex hawa-max-h-screen hawa-w-full hawa-flex-col-reverse hawa-p-4 sm:hawa-bottom-0 sm:hawa-right-0 sm:hawa-top-auto sm:hawa-flex-col md:hawa-max-w-[420px]", className)
|
|
1961
1961
|
}, props));
|
|
1962
1962
|
});
|
|
1963
1963
|
ToastViewport.displayName = ToastPrimitives.Viewport.displayName;
|
|
1964
|
-
var Toast =
|
|
1964
|
+
var Toast = React17.forwardRef(function(_param, ref) {
|
|
1965
1965
|
var className = _param.className, variant = _param.variant, _param_severity = _param.severity, severity = _param_severity === void 0 ? "none" : _param_severity, direction = _param.direction, props = _object_without_properties(_param, [
|
|
1966
1966
|
"className",
|
|
1967
1967
|
"variant",
|
|
1968
1968
|
"severity",
|
|
1969
1969
|
"direction"
|
|
1970
1970
|
]);
|
|
1971
|
-
return /* @__PURE__ */
|
|
1971
|
+
return /* @__PURE__ */ React17.createElement(ToastPrimitives.Root, _object_spread({
|
|
1972
1972
|
ref: ref,
|
|
1973
1973
|
className: cn(toastVariants({
|
|
1974
1974
|
variant: variant,
|
|
@@ -1978,52 +1978,52 @@ var Toast = React18.forwardRef(function(_param, ref) {
|
|
|
1978
1978
|
}, props));
|
|
1979
1979
|
});
|
|
1980
1980
|
Toast.displayName = ToastPrimitives.Root.displayName;
|
|
1981
|
-
var ToastAction =
|
|
1981
|
+
var ToastAction = React17.forwardRef(function(_param, ref) {
|
|
1982
1982
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
1983
1983
|
"className"
|
|
1984
1984
|
]);
|
|
1985
|
-
return /* @__PURE__ */
|
|
1985
|
+
return /* @__PURE__ */ React17.createElement(ToastPrimitives.Action, _object_spread({
|
|
1986
1986
|
ref: ref,
|
|
1987
1987
|
className: cn("hawa-inline-flex hawa-h-8 hawa-shrink-0 hawa-items-center hawa-justify-center hawa-rounded-md hawa-border hawa-bg-transparent hawa-px-3 hawa-text-sm hawa-font-medium hawa-ring-offset-background hawa-transition-colors hover:hawa-bg-secondary hover:hawa-text-secondary-foreground focus:hawa-outline-none focus:hawa-ring-2 focus:hawa-ring-ring focus:hawa-ring-offset-2 disabled:hawa-pointer-events-none disabled:hawa-opacity-50", "group-[.info]:hawa-border-muted/40 group-[.info]:hover:hawa-border-info/30 group-[.info]:hover:hawa-bg-info group-[.info]:hover:hawa-text-info-foreground group-[.info]:focus:hawa-ring-info", "group-[.error]:hawa-border-muted/40 group-[.error]:hover:hawa-border-error/30 group-[.error]:hover:hawa-bg-error group-[.error]:hover:hawa-text-error-foreground group-[.error]:focus:hawa-ring-error", "group-[.success]:hawa-border-muted/40 group-[.success]:hover:hawa-border-success/30 group-[.success]:hover:hawa-bg-success group-[.success]:hover:hawa-text-success-foreground group-[.success]:focus:hawa-ring-success", "group-[.warning]:hawa-border-muted/40 group-[.warning]:hover:hawa-border-warning/30 group-[.warning]:hover:hawa-bg-warning group-[.warning]:hover:hawa-text-warning-foreground group-[.warning]:focus:hawa-ring-warning", className)
|
|
1988
1988
|
}, props));
|
|
1989
1989
|
});
|
|
1990
1990
|
ToastAction.displayName = ToastPrimitives.Action.displayName;
|
|
1991
|
-
var ToastClose =
|
|
1991
|
+
var ToastClose = React17.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
1992
1992
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
1993
1993
|
"className"
|
|
1994
1994
|
]);
|
|
1995
|
-
return
|
|
1995
|
+
return React17.createElement(ToastPrimitives.Close, _object_spread({
|
|
1996
1996
|
ref: ref,
|
|
1997
1997
|
className: cn("hawa-absolute hawa-right-2 hawa-top-2 hawa-rounded-md hawa-p-1 hawa-text-foreground/50 hawa-opacity-0 hawa-transition-opacity hover:hawa-text-foreground focus:hawa-opacity-100 focus:hawa-outline-none focus:hawa-ring-2 group-hover:hawa-opacity-100 group-[.destructive]:hawa-text-red-300 group-[.destructive]:hover:hawa-text-red-50 group-[.destructive]:focus:hawa-ring-red-400 group-[.destructive]:focus:hawa-ring-offset-red-600", className),
|
|
1998
1998
|
"toast-close": ""
|
|
1999
|
-
}, props), /* @__PURE__ */
|
|
1999
|
+
}, props), /* @__PURE__ */ React17.createElement("svg", {
|
|
2000
2000
|
"aria-label": "Close Icon",
|
|
2001
2001
|
"aria-hidden": "true",
|
|
2002
2002
|
className: "hawa-h-4 hawa-w-4",
|
|
2003
2003
|
fill: "currentColor",
|
|
2004
2004
|
viewBox: "0 0 20 20"
|
|
2005
|
-
}, /* @__PURE__ */
|
|
2005
|
+
}, /* @__PURE__ */ React17.createElement("path", {
|
|
2006
2006
|
fillRule: "evenodd",
|
|
2007
2007
|
d: "M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z",
|
|
2008
2008
|
clipRule: "evenodd"
|
|
2009
2009
|
})));
|
|
2010
2010
|
});
|
|
2011
2011
|
ToastClose.displayName = ToastPrimitives.Close.displayName;
|
|
2012
|
-
var ToastTitle =
|
|
2012
|
+
var ToastTitle = React17.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
2013
2013
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
2014
2014
|
"className"
|
|
2015
2015
|
]);
|
|
2016
|
-
return
|
|
2016
|
+
return React17.createElement(ToastPrimitives.Title, _object_spread({
|
|
2017
2017
|
ref: ref,
|
|
2018
2018
|
className: cn("hawa-text-sm hawa-font-semibold", className)
|
|
2019
2019
|
}, props));
|
|
2020
2020
|
});
|
|
2021
2021
|
ToastTitle.displayName = ToastPrimitives.Title.displayName;
|
|
2022
|
-
var ToastDescription =
|
|
2022
|
+
var ToastDescription = React17.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
2023
2023
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
2024
2024
|
"className"
|
|
2025
2025
|
]);
|
|
2026
|
-
return
|
|
2026
|
+
return React17.createElement(ToastPrimitives.Description, _object_spread({
|
|
2027
2027
|
ref: ref,
|
|
2028
2028
|
className: cn("hawa-text-sm hawa-opacity-90", className)
|
|
2029
2029
|
}, props));
|
|
@@ -2032,7 +2032,7 @@ ToastDescription.displayName = ToastPrimitives.Description.displayName;
|
|
|
2032
2032
|
// components/elements/Toaster.tsx
|
|
2033
2033
|
var import_react12 = __toESM(require("react"));
|
|
2034
2034
|
// components/hooks/useToast.ts
|
|
2035
|
-
var
|
|
2035
|
+
var React18 = __toESM(require("react"));
|
|
2036
2036
|
var TOAST_LIMIT = 5;
|
|
2037
2037
|
var TOAST_REMOVE_DELAY = 1e5;
|
|
2038
2038
|
var count = 0;
|
|
@@ -2143,8 +2143,8 @@ function toast(_param) {
|
|
|
2143
2143
|
};
|
|
2144
2144
|
}
|
|
2145
2145
|
function useToast() {
|
|
2146
|
-
var
|
|
2147
|
-
|
|
2146
|
+
var _React18_useState = _sliced_to_array(React18.useState(memoryState), 2), state = _React18_useState[0], setState = _React18_useState[1];
|
|
2147
|
+
React18.useEffect(function() {
|
|
2148
2148
|
listeners.push(setState);
|
|
2149
2149
|
return function() {
|
|
2150
2150
|
var index = listeners.indexOf(setState);
|
|
@@ -2189,7 +2189,7 @@ function Toaster(props) {
|
|
|
2189
2189
|
}));
|
|
2190
2190
|
}
|
|
2191
2191
|
// components/elements/Switch.tsx
|
|
2192
|
-
var
|
|
2192
|
+
var React20 = __toESM(require("react"));
|
|
2193
2193
|
var SwitchPrimitives = __toESM(require("@radix-ui/react-switch"));
|
|
2194
2194
|
var rootSize = {
|
|
2195
2195
|
default: "hawa-h-[25px] hawa-w-[42px]",
|
|
@@ -2201,16 +2201,16 @@ var thumbSize = {
|
|
|
2201
2201
|
sm: "hawa-h-[16px] hawa-w-[16px]",
|
|
2202
2202
|
lg: "hawa-h-[26px] hawa-w-[26px]"
|
|
2203
2203
|
};
|
|
2204
|
-
var Switch =
|
|
2204
|
+
var Switch = React20.forwardRef(function(_param, ref) {
|
|
2205
2205
|
var className = _param.className, _param_size = _param.size, size = _param_size === void 0 ? "default" : _param_size, _param_roundedness = _param.roundedness, roundedness = _param_roundedness === void 0 ? "inherit" : _param_roundedness, label = _param.label, props = _object_without_properties(_param, [
|
|
2206
2206
|
"className",
|
|
2207
2207
|
"size",
|
|
2208
2208
|
"roundedness",
|
|
2209
2209
|
"label"
|
|
2210
2210
|
]);
|
|
2211
|
-
var
|
|
2212
|
-
var parentRef =
|
|
2213
|
-
|
|
2211
|
+
var _React20_useState = _sliced_to_array(React20.useState(null), 2), parentDirection = _React20_useState[0], setParentDirection = _React20_useState[1];
|
|
2212
|
+
var parentRef = React20.useRef(null);
|
|
2213
|
+
React20.useEffect(function() {
|
|
2214
2214
|
var _parentRef_current;
|
|
2215
2215
|
var parentNode = (_parentRef_current = parentRef.current) === null || _parentRef_current === void 0 ? void 0 : _parentRef_current.parentNode;
|
|
2216
2216
|
if (parentNode) {
|
|
@@ -2228,16 +2228,16 @@ var Switch = React21.forwardRef(function(_param, ref) {
|
|
|
2228
2228
|
full: "hawa-rounded-full",
|
|
2229
2229
|
inherit: "hawa-rounded-inner"
|
|
2230
2230
|
};
|
|
2231
|
-
return /* @__PURE__ */
|
|
2231
|
+
return /* @__PURE__ */ React20.createElement("div", {
|
|
2232
2232
|
className: "hawa-flex hawa-flex-row hawa-items-center",
|
|
2233
2233
|
ref: parentRef
|
|
2234
|
-
}, /* @__PURE__ */
|
|
2234
|
+
}, /* @__PURE__ */ React20.createElement(SwitchPrimitives.Root, _object_spread_props(_object_spread({
|
|
2235
2235
|
className: cn("hawa-relative hawa-cursor-pointer hawa-rounded hawa-bg-primary/20 hawa-outline-none data-[state=checked]:hawa-bg-primary", rootRoundednessStyles[roundedness], className, rootSize[size])
|
|
2236
2236
|
}, props), {
|
|
2237
2237
|
ref: ref
|
|
2238
|
-
}), /* @__PURE__ */
|
|
2238
|
+
}), /* @__PURE__ */ React20.createElement(SwitchPrimitives.Thumb, {
|
|
2239
2239
|
className: cn(thumbSize[size], "hawa-block hawa-rounded hawa-bg-white hawa-transition-transform hawa-duration-100 hawa-will-change-transform data-[state=checked]:hawa-bg-primary-foreground dark:hawa-bg-background", thumbRoundednessStyles[roundedness], parentDirection === "rtl" ? "hawa--translate-x-0.5 data-[state=checked]:hawa--translate-x-[19px]" : "hawa-translate-x-0.5 data-[state=checked]:hawa-translate-x-[19px]")
|
|
2240
|
-
})), label && /* @__PURE__ */
|
|
2240
|
+
})), label && /* @__PURE__ */ React20.createElement("span", {
|
|
2241
2241
|
className: "hawa-mx-2 hawa-text-sm hawa-font-medium hawa-text-gray-900 dark:hawa-text-gray-300"
|
|
2242
2242
|
}, label));
|
|
2243
2243
|
});
|
|
@@ -2245,8 +2245,8 @@ Switch.displayName = SwitchPrimitives.Root.displayName;
|
|
|
2245
2245
|
// components/elements/Radio.tsx
|
|
2246
2246
|
var import_react13 = __toESM(require("react"));
|
|
2247
2247
|
// components/elements/Label.tsx
|
|
2248
|
-
var
|
|
2249
|
-
var Label2 =
|
|
2248
|
+
var React21 = __toESM(require("react"));
|
|
2249
|
+
var Label2 = React21.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
2250
2250
|
var className = _param.className, hint = _param.hint, hintSide = _param.hintSide, required = _param.required, children = _param.children, props = _object_without_properties(_param, [
|
|
2251
2251
|
"className",
|
|
2252
2252
|
"hint",
|
|
@@ -2254,17 +2254,17 @@ var Label2 = React22.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
|
2254
2254
|
"required",
|
|
2255
2255
|
"children"
|
|
2256
2256
|
]);
|
|
2257
|
-
return
|
|
2257
|
+
return React21.createElement("div", {
|
|
2258
2258
|
className: "hawa-flex hawa-flex-row hawa-gap-2 hawa-items-center"
|
|
2259
|
-
}, /* @__PURE__ */
|
|
2259
|
+
}, /* @__PURE__ */ React21.createElement("label", _object_spread({
|
|
2260
2260
|
ref: ref,
|
|
2261
2261
|
className: cn("hawa-text-sm hawa-font-medium hawa-leading-none peer-disabled:hawa-cursor-not-allowed peer-disabled:hawa-opacity-70", className)
|
|
2262
|
-
}, props), children, required && /* @__PURE__ */
|
|
2262
|
+
}, props), children, required && /* @__PURE__ */ React21.createElement("span", {
|
|
2263
2263
|
className: "hawa-text-red-500 hawa-mx-0.5"
|
|
2264
|
-
}, "*")), hint && /* @__PURE__ */
|
|
2264
|
+
}, "*")), hint && /* @__PURE__ */ React21.createElement(Tooltip, {
|
|
2265
2265
|
content: hint,
|
|
2266
2266
|
side: hintSide
|
|
2267
|
-
}, /* @__PURE__ */
|
|
2267
|
+
}, /* @__PURE__ */ React21.createElement("svg", {
|
|
2268
2268
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2269
2269
|
className: "hawa-w-[14px] hawa-h-[14px] hawa-cursor-help",
|
|
2270
2270
|
viewBox: "0 0 24 24",
|
|
@@ -2273,16 +2273,16 @@ var Label2 = React22.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
|
2273
2273
|
strokeWidth: "2",
|
|
2274
2274
|
strokeLinecap: "round",
|
|
2275
2275
|
strokeLinejoin: "round"
|
|
2276
|
-
}, /* @__PURE__ */
|
|
2276
|
+
}, /* @__PURE__ */ React21.createElement("circle", {
|
|
2277
2277
|
cx: "12",
|
|
2278
2278
|
cy: "12",
|
|
2279
2279
|
r: "10"
|
|
2280
|
-
}), /* @__PURE__ */
|
|
2280
|
+
}), /* @__PURE__ */ React21.createElement("line", {
|
|
2281
2281
|
x1: "12",
|
|
2282
2282
|
x2: "12",
|
|
2283
2283
|
y1: "8",
|
|
2284
2284
|
y2: "12"
|
|
2285
|
-
}), /* @__PURE__ */
|
|
2285
|
+
}), /* @__PURE__ */ React21.createElement("line", {
|
|
2286
2286
|
x1: "12",
|
|
2287
2287
|
x2: "12.01",
|
|
2288
2288
|
y1: "16",
|
|
@@ -2579,15 +2579,15 @@ var Alert = function(_param) {
|
|
|
2579
2579
|
})))));
|
|
2580
2580
|
};
|
|
2581
2581
|
// components/elements/Popover.tsx
|
|
2582
|
-
var
|
|
2582
|
+
var React26 = __toESM(require("react"));
|
|
2583
2583
|
var PopoverPrimitive = __toESM(require("@radix-ui/react-popover"));
|
|
2584
|
-
var PopoverContent =
|
|
2584
|
+
var PopoverContent = React26.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
2585
2585
|
var className = _param.className, _param_align = _param.align, align = _param_align === void 0 ? "center" : _param_align, _param_sideOffset = _param.sideOffset, sideOffset = _param_sideOffset === void 0 ? 4 : _param_sideOffset, props = _object_without_properties(_param, [
|
|
2586
2586
|
"className",
|
|
2587
2587
|
"align",
|
|
2588
2588
|
"sideOffset"
|
|
2589
2589
|
]);
|
|
2590
|
-
return
|
|
2590
|
+
return React26.createElement(PopoverPrimitive.Portal, null, /* @__PURE__ */ React26.createElement(PopoverPrimitive.Content, _object_spread({
|
|
2591
2591
|
ref: ref,
|
|
2592
2592
|
align: align,
|
|
2593
2593
|
sideOffset: sideOffset,
|
|
@@ -2606,11 +2606,11 @@ var Popover = function(_param) /* @__PURE__ */ {
|
|
|
2606
2606
|
"open",
|
|
2607
2607
|
"disableTrigger"
|
|
2608
2608
|
]);
|
|
2609
|
-
return
|
|
2609
|
+
return React26.createElement(PopoverPrimitive.Root, _object_spread({
|
|
2610
2610
|
open: open
|
|
2611
|
-
}, props), /* @__PURE__ */
|
|
2611
|
+
}, props), /* @__PURE__ */ React26.createElement(PopoverPrimitive.Trigger, {
|
|
2612
2612
|
disabled: disableTrigger
|
|
2613
|
-
}, trigger), /* @__PURE__ */
|
|
2613
|
+
}, trigger), /* @__PURE__ */ React26.createElement(PopoverContent, {
|
|
2614
2614
|
side: side,
|
|
2615
2615
|
className: className,
|
|
2616
2616
|
align: align,
|
|
@@ -2619,36 +2619,36 @@ var Popover = function(_param) /* @__PURE__ */ {
|
|
|
2619
2619
|
};
|
|
2620
2620
|
var PopoverTrigger = PopoverPrimitive.Trigger;
|
|
2621
2621
|
// components/elements/Textarea.tsx
|
|
2622
|
-
var
|
|
2623
|
-
var Textarea =
|
|
2622
|
+
var React27 = __toESM(require("react"));
|
|
2623
|
+
var Textarea = React27.forwardRef(function(_param, ref) {
|
|
2624
2624
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
2625
2625
|
"className"
|
|
2626
2626
|
]);
|
|
2627
|
-
return /* @__PURE__ */
|
|
2627
|
+
return /* @__PURE__ */ React27.createElement("div", {
|
|
2628
2628
|
className: "hawa-flex hawa-flex-col hawa-gap-2"
|
|
2629
|
-
}, /* @__PURE__ */
|
|
2629
|
+
}, /* @__PURE__ */ React27.createElement("textarea", _object_spread({
|
|
2630
2630
|
className: cn("hawa-flex hawa-min-h-[80px] hawa-w-full hawa-rounded-md hawa-border hawa-border-input hawa-bg-background hawa-px-3 hawa-py-2 hawa-text-sm hawa-ring-offset-background placeholder:hawa-text-muted-foreground focus-visible:hawa-outline-none focus-visible:hawa-ring-2 focus-visible:hawa-ring-ring focus-visible:hawa-ring-offset-2 disabled:hawa-cursor-not-allowed disabled:hawa-opacity-50", className),
|
|
2631
2631
|
ref: ref
|
|
2632
|
-
}, props)), props.helperText && /* @__PURE__ */
|
|
2632
|
+
}, props)), props.helperText && /* @__PURE__ */ React27.createElement("p", {
|
|
2633
2633
|
className: "hawa-text-xs hawa-text-helper-color"
|
|
2634
2634
|
}, props.helperText));
|
|
2635
2635
|
});
|
|
2636
2636
|
Textarea.displayName = "Textarea";
|
|
2637
2637
|
// components/elements/Slider.tsx
|
|
2638
|
-
var
|
|
2638
|
+
var React28 = __toESM(require("react"));
|
|
2639
2639
|
var SliderPrimitive = __toESM(require("@radix-ui/react-slider"));
|
|
2640
|
-
var Slider =
|
|
2640
|
+
var Slider = React28.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
2641
2641
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
2642
2642
|
"className"
|
|
2643
2643
|
]);
|
|
2644
|
-
return
|
|
2644
|
+
return React28.createElement(SliderPrimitive.Root, _object_spread({
|
|
2645
2645
|
ref: ref,
|
|
2646
2646
|
className: cn("hawa-relative hawa-flex hawa-w-full hawa-touch-none hawa-select-none hawa-items-center", className)
|
|
2647
|
-
}, props), /* @__PURE__ */
|
|
2647
|
+
}, props), /* @__PURE__ */ React28.createElement(SliderPrimitive.Track, {
|
|
2648
2648
|
className: "hawa-relative hawa-h-2 hawa-w-full hawa-grow hawa-overflow-hidden hawa-rounded-full hawa-bg-background hawa-border"
|
|
2649
|
-
}, /* @__PURE__ */
|
|
2649
|
+
}, /* @__PURE__ */ React28.createElement(SliderPrimitive.Range, {
|
|
2650
2650
|
className: "hawa-absolute hawa-h-full hawa-bg-primary"
|
|
2651
|
-
})), /* @__PURE__ */
|
|
2651
|
+
})), /* @__PURE__ */ React28.createElement(SliderPrimitive.Thumb, {
|
|
2652
2652
|
className: "hawa-block hawa-h-5 hawa-w-5 hawa-rounded-full hawa-border-2 hawa-border-primary hawa-bg-background hawa-ring-offset-background hawa-transition-colors focus-visible:hawa-outline-none focus-visible:hawa-ring-2 focus-visible:hawa-ring-ring focus-visible:hawa-ring-offset-2 disabled:hawa-pointer-events-none disabled:hawa-opacity-50"
|
|
2653
2653
|
}));
|
|
2654
2654
|
});
|
|
@@ -5040,37 +5040,37 @@ var SortButton = function(props) {
|
|
|
5040
5040
|
})));
|
|
5041
5041
|
};
|
|
5042
5042
|
// components/elements/DataTable.tsx
|
|
5043
|
-
var
|
|
5043
|
+
var React39 = __toESM(require("react"));
|
|
5044
5044
|
var import_react_table = require("@tanstack/react-table");
|
|
5045
5045
|
// components/elements/Table.tsx
|
|
5046
|
-
var
|
|
5047
|
-
var Table =
|
|
5046
|
+
var React37 = __toESM(require("react"));
|
|
5047
|
+
var Table = React37.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
5048
5048
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
5049
5049
|
"className"
|
|
5050
5050
|
]);
|
|
5051
|
-
return
|
|
5051
|
+
return React37.createElement("div", {
|
|
5052
5052
|
className: "hawa-relative hawa-w-full hawa-overflow-auto hawa-rounded hawa-border"
|
|
5053
|
-
}, /* @__PURE__ */
|
|
5053
|
+
}, /* @__PURE__ */ React37.createElement("table", _object_spread({
|
|
5054
5054
|
ref: ref,
|
|
5055
5055
|
className: cn("hawa-w-full hawa-caption-bottom hawa-text-sm", className)
|
|
5056
5056
|
}, props)));
|
|
5057
5057
|
});
|
|
5058
5058
|
Table.displayName = "Table";
|
|
5059
|
-
var TableHeader =
|
|
5059
|
+
var TableHeader = React37.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
5060
5060
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
5061
5061
|
"className"
|
|
5062
5062
|
]);
|
|
5063
|
-
return
|
|
5063
|
+
return React37.createElement("thead", _object_spread({
|
|
5064
5064
|
ref: ref,
|
|
5065
5065
|
className: cn("[&_tr]:hawa-border-b", "hawa-bg-muted/50", className)
|
|
5066
5066
|
}, props));
|
|
5067
5067
|
});
|
|
5068
5068
|
TableHeader.displayName = "TableHeader";
|
|
5069
|
-
var TableHead =
|
|
5069
|
+
var TableHead = React37.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
5070
5070
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
5071
5071
|
"className"
|
|
5072
5072
|
]);
|
|
5073
|
-
return
|
|
5073
|
+
return React37.createElement("th", _object_spread({
|
|
5074
5074
|
ref: ref,
|
|
5075
5075
|
className: cn("hawa-bg-muted/60 dark:hawa-bg-muted/40 hawa-text-start hawa-align-middle hawa-font-medium hawa-text-muted-foreground [&:has([role=checkbox])]:hawa-pr-0 [&:not(:last-child)&:not(:first-child)]:hawa-border-x", props.dir === "rtl" ? "[&:not(:last-child)]:hawa-border-l" : "[&:not(:last-child)]:hawa-border-r", props.condensed ? "hawa-h-8" : "hawa-h-12", props.clickable ? "hawa-px-1" : "hawa-px-4", //First and last columns
|
|
5076
5076
|
props.clickable ? " [&:not(:last-child)&:not(:first-child)]:hawa-p-1" : "hawa-px-4", //Columns in between
|
|
@@ -5078,32 +5078,32 @@ var TableHead = React38.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
|
5078
5078
|
}, props));
|
|
5079
5079
|
});
|
|
5080
5080
|
TableHead.displayName = "TableHead";
|
|
5081
|
-
var TableBody =
|
|
5081
|
+
var TableBody = React37.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
5082
5082
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
5083
5083
|
"className"
|
|
5084
5084
|
]);
|
|
5085
|
-
return
|
|
5085
|
+
return React37.createElement("tbody", _object_spread({
|
|
5086
5086
|
ref: ref,
|
|
5087
5087
|
className: cn(// "[&_tr:last-child]:border-0"
|
|
5088
5088
|
"hawa-border-none", className)
|
|
5089
5089
|
}, props));
|
|
5090
5090
|
});
|
|
5091
5091
|
TableBody.displayName = "TableBody";
|
|
5092
|
-
var TableFooter =
|
|
5092
|
+
var TableFooter = React37.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
5093
5093
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
5094
5094
|
"className"
|
|
5095
5095
|
]);
|
|
5096
|
-
return
|
|
5096
|
+
return React37.createElement("tfoot", _object_spread({
|
|
5097
5097
|
ref: ref,
|
|
5098
5098
|
className: cn("hawa-bg-primary hawa-font-medium hawa-text-primary-foreground", className)
|
|
5099
5099
|
}, props));
|
|
5100
5100
|
});
|
|
5101
5101
|
TableFooter.displayName = "TableFooter";
|
|
5102
|
-
var TableRow =
|
|
5102
|
+
var TableRow = React37.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
5103
5103
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
5104
5104
|
"className"
|
|
5105
5105
|
]);
|
|
5106
|
-
return
|
|
5106
|
+
return React37.createElement("tr", _object_spread({
|
|
5107
5107
|
ref: ref,
|
|
5108
5108
|
className: cn(// "border-b",
|
|
5109
5109
|
"hawa-transition-colors data-[state=selected]:hawa-bg-muted hawa-bg-background", // hover:bg-muted/50
|
|
@@ -5111,11 +5111,11 @@ var TableRow = React38.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
|
5111
5111
|
}, props));
|
|
5112
5112
|
});
|
|
5113
5113
|
TableRow.displayName = "TableRow";
|
|
5114
|
-
var TableCell =
|
|
5114
|
+
var TableCell = React37.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
5115
5115
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
5116
5116
|
"className"
|
|
5117
5117
|
]);
|
|
5118
|
-
return
|
|
5118
|
+
return React37.createElement("td", _object_spread({
|
|
5119
5119
|
ref: ref,
|
|
5120
5120
|
className: cn(// "border-x",
|
|
5121
5121
|
props.condensed ? "hawa-p-0 hawa-px-4" : "hawa-p-4", "hawa-align-middle [&:has([role=checkbox])]:hawa-pr-0 ", "[&:not(:last-child)&:not(:first-child)]:hawa-border-x", // "[&:not(:last-child)]:hawa-border-r",
|
|
@@ -5123,11 +5123,11 @@ var TableCell = React38.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
|
5123
5123
|
}, props));
|
|
5124
5124
|
});
|
|
5125
5125
|
TableCell.displayName = "TableCell";
|
|
5126
|
-
var TableCaption =
|
|
5126
|
+
var TableCaption = React37.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
5127
5127
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
5128
5128
|
"className"
|
|
5129
5129
|
]);
|
|
5130
|
-
return
|
|
5130
|
+
return React37.createElement("caption", _object_spread({
|
|
5131
5131
|
ref: ref,
|
|
5132
5132
|
className: cn("hawa-mt-4 hawa-text-sm hawa-text-muted-foreground", className)
|
|
5133
5133
|
}, props));
|
|
@@ -5201,17 +5201,17 @@ var DataTable = function(_param) {
|
|
|
5201
5201
|
"paginationPosition"
|
|
5202
5202
|
]);
|
|
5203
5203
|
var _props_texts, _props_itemsPerPage, _props_texts1, _table_getRowModel_rows, _props_texts2, _props_texts3, _props_texts4, _props_texts5, _props_texts6, _props_texts7;
|
|
5204
|
-
var
|
|
5204
|
+
var _React39_useState = _sliced_to_array(React39.useState([
|
|
5205
5205
|
{
|
|
5206
5206
|
id: props.defaultSort || "",
|
|
5207
5207
|
desc: false
|
|
5208
5208
|
}
|
|
5209
|
-
]), 2), sorting =
|
|
5210
|
-
var
|
|
5211
|
-
var
|
|
5212
|
-
var
|
|
5213
|
-
var
|
|
5214
|
-
var
|
|
5209
|
+
]), 2), sorting = _React39_useState[0], setSorting = _React39_useState[1];
|
|
5210
|
+
var _React39_useState1 = _sliced_to_array(React39.useState([]), 2), columnFilters = _React39_useState1[0], setColumnFilters = _React39_useState1[1];
|
|
5211
|
+
var _React39_useState2 = _sliced_to_array(React39.useState(""), 2), globalFilter = _React39_useState2[0], setGlobalFilter = _React39_useState2[1];
|
|
5212
|
+
var _React39_useState3 = _sliced_to_array(React39.useState({}), 2), expanded = _React39_useState3[0], setExpanded = _React39_useState3[1];
|
|
5213
|
+
var _React39_useState4 = _sliced_to_array(React39.useState({}), 2), columnVisibility = _React39_useState4[0], setColumnVisibility = _React39_useState4[1];
|
|
5214
|
+
var _React39_useState5 = _sliced_to_array(React39.useState({}), 2), rowSelection = _React39_useState5[0], setRowSelection = _React39_useState5[1];
|
|
5215
5215
|
var table = (0, import_react_table.useReactTable)({
|
|
5216
5216
|
data: data,
|
|
5217
5217
|
columns: columns,
|
|
@@ -5242,11 +5242,11 @@ var DataTable = function(_param) {
|
|
|
5242
5242
|
value: item
|
|
5243
5243
|
};
|
|
5244
5244
|
});
|
|
5245
|
-
return /* @__PURE__ */
|
|
5245
|
+
return /* @__PURE__ */ React39.createElement("div", {
|
|
5246
5246
|
className: "hawa-flex hawa-w-full hawa-flex-col hawa-gap-4"
|
|
5247
|
-
}, /* @__PURE__ */
|
|
5247
|
+
}, /* @__PURE__ */ React39.createElement("div", {
|
|
5248
5248
|
className: "hawa-flex hawa-items-center"
|
|
5249
|
-
}, /* @__PURE__ */
|
|
5249
|
+
}, /* @__PURE__ */ React39.createElement(Input, {
|
|
5250
5250
|
forceHideHelperText: true,
|
|
5251
5251
|
placeholder: (_props_texts1 = props.texts) === null || _props_texts1 === void 0 ? void 0 : _props_texts1.searchPlaceholder,
|
|
5252
5252
|
value: globalFilter !== null && globalFilter !== void 0 ? globalFilter : "",
|
|
@@ -5255,53 +5255,53 @@ var DataTable = function(_param) {
|
|
|
5255
5255
|
},
|
|
5256
5256
|
margin: "none",
|
|
5257
5257
|
className: "hawa-w-full md:hawa-max-w-sm"
|
|
5258
|
-
})), props.isLoading ? /* @__PURE__ */
|
|
5258
|
+
})), props.isLoading ? /* @__PURE__ */ React39.createElement(Skeleton, {
|
|
5259
5259
|
className: "hawa-h-[130px] hawa-w-full"
|
|
5260
|
-
}) : /* @__PURE__ */
|
|
5260
|
+
}) : /* @__PURE__ */ React39.createElement("div", {
|
|
5261
5261
|
className: cn("hawa-flex hawa-w-full hawa-gap-4", paginationPosition === "top" ? "hawa-flex-col-reverse" : "hawa-flex-col")
|
|
5262
|
-
}, /* @__PURE__ */
|
|
5262
|
+
}, /* @__PURE__ */ React39.createElement("div", {
|
|
5263
5263
|
className: "hawa-rounded-md"
|
|
5264
|
-
}, /* @__PURE__ */
|
|
5265
|
-
return /* @__PURE__ */
|
|
5264
|
+
}, /* @__PURE__ */ React39.createElement(Table, null, table.getAllColumns().length > 0 && /* @__PURE__ */ React39.createElement(TableHeader, null, table.getHeaderGroups().map(function(headerGroup) {
|
|
5265
|
+
return /* @__PURE__ */ React39.createElement(TableRow, {
|
|
5266
5266
|
key: headerGroup.id
|
|
5267
5267
|
}, headerGroup.headers.map(function(header) {
|
|
5268
5268
|
var _header_column_columnDef_meta;
|
|
5269
5269
|
var isSortable = (_header_column_columnDef_meta = header.column.columnDef.meta) === null || _header_column_columnDef_meta === void 0 ? void 0 : _header_column_columnDef_meta.sortable;
|
|
5270
|
-
return /* @__PURE__ */
|
|
5270
|
+
return /* @__PURE__ */ React39.createElement(TableHead, {
|
|
5271
5271
|
dir: props.direction,
|
|
5272
5272
|
condensed: props.condensed,
|
|
5273
5273
|
clickable: isSortable,
|
|
5274
5274
|
key: header.id
|
|
5275
5275
|
}, header.isPlaceholder ? null : (0, import_react_table.flexRender)(header.column.columnDef.header, header.getContext()));
|
|
5276
5276
|
}));
|
|
5277
|
-
})), /* @__PURE__ */
|
|
5278
|
-
return /* @__PURE__ */
|
|
5277
|
+
})), /* @__PURE__ */ React39.createElement(TableBody, null, ((_table_getRowModel_rows = table.getRowModel().rows) === null || _table_getRowModel_rows === void 0 ? void 0 : _table_getRowModel_rows.length) ? table.getRowModel().rows.map(function(row) {
|
|
5278
|
+
return /* @__PURE__ */ React39.createElement(TableRow, {
|
|
5279
5279
|
key: row.id,
|
|
5280
5280
|
"data-state": row.getIsSelected() && "selected"
|
|
5281
5281
|
}, row.getVisibleCells().map(function(cell) {
|
|
5282
|
-
return /* @__PURE__ */
|
|
5282
|
+
return /* @__PURE__ */ React39.createElement(TableCell, {
|
|
5283
5283
|
dir: props.direction,
|
|
5284
5284
|
condensed: props.condensed,
|
|
5285
5285
|
key: cell.id
|
|
5286
5286
|
}, (0, import_react_table.flexRender)(cell.column.columnDef.cell, cell.getContext()));
|
|
5287
5287
|
}));
|
|
5288
|
-
}) : /* @__PURE__ */
|
|
5288
|
+
}) : /* @__PURE__ */ React39.createElement(TableRow, null, /* @__PURE__ */ React39.createElement(TableCell, {
|
|
5289
5289
|
colSpan: columns.length,
|
|
5290
5290
|
className: "hawa-h-24 hawa-text-center"
|
|
5291
|
-
}, (_props_texts2 = props.texts) === null || _props_texts2 === void 0 ? void 0 : _props_texts2.noData))))), /* @__PURE__ */
|
|
5291
|
+
}, (_props_texts2 = props.texts) === null || _props_texts2 === void 0 ? void 0 : _props_texts2.noData))))), /* @__PURE__ */ React39.createElement("div", {
|
|
5292
5292
|
className: "hawa-flex hawa-items-center hawa-justify-between"
|
|
5293
|
-
}, !props.showCount && /* @__PURE__ */
|
|
5293
|
+
}, !props.showCount && /* @__PURE__ */ React39.createElement("div", {
|
|
5294
5294
|
className: "hawa-flex hawa-w-fit hawa-flex-row hawa-items-center hawa-gap-2 hawa-text-sm hawa-text-muted-foreground"
|
|
5295
|
-
}), props.showCount && /* @__PURE__ */
|
|
5295
|
+
}), props.showCount && /* @__PURE__ */ React39.createElement("div", {
|
|
5296
5296
|
className: "text-sm text-muted-foreground",
|
|
5297
5297
|
dir: props.direction
|
|
5298
|
-
}, /* @__PURE__ */
|
|
5298
|
+
}, /* @__PURE__ */ React39.createElement("span", null, (_props_texts3 = props.texts) === null || _props_texts3 === void 0 ? void 0 : _props_texts3.total), " ", /* @__PURE__ */ React39.createElement("span", null, table.getFilteredRowModel().rows.length.toLocaleString())), table.getPageCount() !== 0 && /* @__PURE__ */ React39.createElement("div", {
|
|
5299
5299
|
className: "hawa-flex hawa-w-fit hawa-flex-row hawa-items-center hawa-gap-2 "
|
|
5300
|
-
}, props.enableGoTo && /* @__PURE__ */
|
|
5300
|
+
}, props.enableGoTo && /* @__PURE__ */ React39.createElement("div", {
|
|
5301
5301
|
className: "hawa-flex hawa-flex-row hawa-justify-center hawa-items-center hawa-gap-2"
|
|
5302
|
-
}, /* @__PURE__ */
|
|
5302
|
+
}, /* @__PURE__ */ React39.createElement("span", {
|
|
5303
5303
|
className: "hawa-text-sm"
|
|
5304
|
-
}, (_props_texts4 = props.texts) === null || _props_texts4 === void 0 ? void 0 : _props_texts4.goTo), /* @__PURE__ */
|
|
5304
|
+
}, (_props_texts4 = props.texts) === null || _props_texts4 === void 0 ? void 0 : _props_texts4.goTo), /* @__PURE__ */ React39.createElement("input", {
|
|
5305
5305
|
max: table.getPageCount(),
|
|
5306
5306
|
min: 0,
|
|
5307
5307
|
type: "number",
|
|
@@ -5315,7 +5315,7 @@ var DataTable = function(_param) {
|
|
|
5315
5315
|
table.setPageIndex(page);
|
|
5316
5316
|
},
|
|
5317
5317
|
className: "hawa-w-16 hawa-text-sm hawa-border hawa-rounded hawa-p-1 hawa-px-2"
|
|
5318
|
-
})), /* @__PURE__ */
|
|
5318
|
+
})), /* @__PURE__ */ React39.createElement(DropdownMenu, {
|
|
5319
5319
|
size: "sm",
|
|
5320
5320
|
width: "sm",
|
|
5321
5321
|
direction: props.direction,
|
|
@@ -5341,7 +5341,7 @@ var DataTable = function(_param) {
|
|
|
5341
5341
|
value: 50
|
|
5342
5342
|
}
|
|
5343
5343
|
],
|
|
5344
|
-
trigger: /* @__PURE__ */
|
|
5344
|
+
trigger: /* @__PURE__ */ React39.createElement(Button, {
|
|
5345
5345
|
variant: "outline",
|
|
5346
5346
|
size: "icon",
|
|
5347
5347
|
className: "hawa-h-fit hawa-w-fit hawa-p-0 hawa-px-2 hawa-py-1 "
|
|
@@ -5349,17 +5349,17 @@ var DataTable = function(_param) {
|
|
|
5349
5349
|
onItemSelect: function(e) {
|
|
5350
5350
|
return table.setPageSize(Number(e));
|
|
5351
5351
|
}
|
|
5352
|
-
}), /* @__PURE__ */
|
|
5352
|
+
}), /* @__PURE__ */ React39.createElement("div", {
|
|
5353
5353
|
className: "hawa-flex hawa-w-fit hawa-flex-row hawa-items-center hawa-gap-2 hawa-text-sm "
|
|
5354
|
-
}, /* @__PURE__ */
|
|
5354
|
+
}, /* @__PURE__ */ React39.createElement("span", {
|
|
5355
5355
|
className: "hawa-flex hawa-items-center hawa-gap-1"
|
|
5356
|
-
}, /* @__PURE__ */
|
|
5356
|
+
}, /* @__PURE__ */ React39.createElement("div", null, (_props_texts6 = props.texts) === null || _props_texts6 === void 0 ? void 0 : _props_texts6.page), /* @__PURE__ */ React39.createElement("div", {
|
|
5357
5357
|
className: "hawa-flex hawa-flex-row hawa-gap-1"
|
|
5358
|
-
}, /* @__PURE__ */
|
|
5358
|
+
}, /* @__PURE__ */ React39.createElement("span", {
|
|
5359
5359
|
className: "hawa-font-bold"
|
|
5360
|
-
}, table.getState().pagination.pageIndex + 1), /* @__PURE__ */
|
|
5360
|
+
}, table.getState().pagination.pageIndex + 1), /* @__PURE__ */ React39.createElement("span", null, (_props_texts7 = props.texts) === null || _props_texts7 === void 0 ? void 0 : _props_texts7.of), /* @__PURE__ */ React39.createElement("span", {
|
|
5361
5361
|
className: "hawa-font-bold"
|
|
5362
|
-
}, table.getPageCount())))), /* @__PURE__ */
|
|
5362
|
+
}, table.getPageCount())))), /* @__PURE__ */ React39.createElement(Button, {
|
|
5363
5363
|
"aria-label": "Previous Table Page",
|
|
5364
5364
|
variant: "outline",
|
|
5365
5365
|
size: "smallIcon",
|
|
@@ -5368,7 +5368,7 @@ var DataTable = function(_param) {
|
|
|
5368
5368
|
},
|
|
5369
5369
|
disabled: !table.getCanPreviousPage(),
|
|
5370
5370
|
className: cn(props.direction === "ltr" && "hawa-rotate-180")
|
|
5371
|
-
}, /* @__PURE__ */
|
|
5371
|
+
}, /* @__PURE__ */ React39.createElement("svg", {
|
|
5372
5372
|
"aria-label": "Chevron Right Icon",
|
|
5373
5373
|
stroke: "currentColor",
|
|
5374
5374
|
fill: "currentColor",
|
|
@@ -5376,10 +5376,10 @@ var DataTable = function(_param) {
|
|
|
5376
5376
|
viewBox: "0 0 16 16",
|
|
5377
5377
|
height: "1em",
|
|
5378
5378
|
width: "1em"
|
|
5379
|
-
}, /* @__PURE__ */
|
|
5379
|
+
}, /* @__PURE__ */ React39.createElement("path", {
|
|
5380
5380
|
fillRule: "evenodd",
|
|
5381
5381
|
d: "M4.646 1.646a.5.5 0 0 1 .708 0l6 6a.5.5 0 0 1 0 .708l-6 6a.5.5 0 0 1-.708-.708L10.293 8 4.646 2.354a.5.5 0 0 1 0-.708z"
|
|
5382
|
-
}))), /* @__PURE__ */
|
|
5382
|
+
}))), /* @__PURE__ */ React39.createElement(Button, {
|
|
5383
5383
|
"aria-label": "Next Table Page",
|
|
5384
5384
|
variant: "outline",
|
|
5385
5385
|
size: "smallIcon",
|
|
@@ -5388,7 +5388,7 @@ var DataTable = function(_param) {
|
|
|
5388
5388
|
},
|
|
5389
5389
|
disabled: !table.getCanNextPage(),
|
|
5390
5390
|
className: cn(props.direction === "rtl" && "hawa-rotate-180")
|
|
5391
|
-
}, /* @__PURE__ */
|
|
5391
|
+
}, /* @__PURE__ */ React39.createElement("svg", {
|
|
5392
5392
|
"aria-label": "Chevron Right Icon",
|
|
5393
5393
|
fill: "currentColor",
|
|
5394
5394
|
stroke: "currentColor",
|
|
@@ -5396,13 +5396,13 @@ var DataTable = function(_param) {
|
|
|
5396
5396
|
height: "1em",
|
|
5397
5397
|
strokeWidth: "0",
|
|
5398
5398
|
viewBox: "0 0 16 16"
|
|
5399
|
-
}, /* @__PURE__ */
|
|
5399
|
+
}, /* @__PURE__ */ React39.createElement("path", {
|
|
5400
5400
|
fillRule: "evenodd",
|
|
5401
5401
|
d: "M4.646 1.646a.5.5 0 0 1 .708 0l6 6a.5.5 0 0 1 0 .708l-6 6a.5.5 0 0 1-.708-.708L10.293 8 4.646 2.354a.5.5 0 0 1 0-.708z"
|
|
5402
5402
|
})))))));
|
|
5403
5403
|
};
|
|
5404
5404
|
// components/elements/SimpleTable.tsx
|
|
5405
|
-
var
|
|
5405
|
+
var React40 = __toESM(require("react"));
|
|
5406
5406
|
var import_react_table2 = require("@tanstack/react-table");
|
|
5407
5407
|
var SimpleTable = function(_param) {
|
|
5408
5408
|
var columns = _param.columns, data = _param.data, props = _object_without_properties(_param, [
|
|
@@ -5415,42 +5415,42 @@ var SimpleTable = function(_param) {
|
|
|
5415
5415
|
columns: columns,
|
|
5416
5416
|
getCoreRowModel: (0, import_react_table2.getCoreRowModel)()
|
|
5417
5417
|
});
|
|
5418
|
-
return /* @__PURE__ */
|
|
5418
|
+
return /* @__PURE__ */ React40.createElement("div", {
|
|
5419
5419
|
className: "hawa-flex hawa-w-full hawa-flex-col hawa-gap-4"
|
|
5420
|
-
}, props.isLoading ? /* @__PURE__ */
|
|
5420
|
+
}, props.isLoading ? /* @__PURE__ */ React40.createElement(Skeleton, {
|
|
5421
5421
|
className: "h-[130px] w-full"
|
|
5422
|
-
}) : /* @__PURE__ */
|
|
5422
|
+
}) : /* @__PURE__ */ React40.createElement(React40.Fragment, null, /* @__PURE__ */ React40.createElement("div", {
|
|
5423
5423
|
className: "hawa-rounded"
|
|
5424
|
-
}, /* @__PURE__ */
|
|
5425
|
-
return /* @__PURE__ */
|
|
5424
|
+
}, /* @__PURE__ */ React40.createElement(Table, null, table.getAllColumns().length > 0 && /* @__PURE__ */ React40.createElement(TableHeader, null, table.getHeaderGroups().map(function(headerGroup) {
|
|
5425
|
+
return /* @__PURE__ */ React40.createElement(TableRow, {
|
|
5426
5426
|
key: headerGroup.id
|
|
5427
5427
|
}, headerGroup.headers.map(function(header) {
|
|
5428
|
-
return /* @__PURE__ */
|
|
5428
|
+
return /* @__PURE__ */ React40.createElement(TableHead, {
|
|
5429
5429
|
condensed: props.condensed,
|
|
5430
5430
|
dir: props.direction,
|
|
5431
5431
|
key: header.id
|
|
5432
5432
|
}, header.isPlaceholder ? null : (0, import_react_table2.flexRender)(header.column.columnDef.header, header.getContext()));
|
|
5433
5433
|
}));
|
|
5434
|
-
})), /* @__PURE__ */
|
|
5435
|
-
return /* @__PURE__ */
|
|
5434
|
+
})), /* @__PURE__ */ React40.createElement(TableBody, null, ((_table_getRowModel_rows = table.getRowModel().rows) === null || _table_getRowModel_rows === void 0 ? void 0 : _table_getRowModel_rows.length) ? table.getRowModel().rows.map(function(row) {
|
|
5435
|
+
return /* @__PURE__ */ React40.createElement(TableRow, {
|
|
5436
5436
|
key: row.id,
|
|
5437
5437
|
"data-state": row.getIsSelected() && "selected"
|
|
5438
5438
|
}, row.getVisibleCells().map(function(cell) {
|
|
5439
|
-
return /* @__PURE__ */
|
|
5439
|
+
return /* @__PURE__ */ React40.createElement(TableCell, {
|
|
5440
5440
|
dir: props.direction,
|
|
5441
5441
|
condensed: props.condensed,
|
|
5442
5442
|
key: cell.id
|
|
5443
5443
|
}, (0, import_react_table2.flexRender)(cell.column.columnDef.cell, cell.getContext()));
|
|
5444
5444
|
}));
|
|
5445
|
-
}) : /* @__PURE__ */
|
|
5445
|
+
}) : /* @__PURE__ */ React40.createElement(TableRow, null, /* @__PURE__ */ React40.createElement(TableCell, {
|
|
5446
5446
|
colSpan: columns.length,
|
|
5447
5447
|
className: "hawa-h-24 hawa-text-center"
|
|
5448
5448
|
}, (_props_texts = props.texts) === null || _props_texts === void 0 ? void 0 : _props_texts.noData)))))));
|
|
5449
5449
|
};
|
|
5450
5450
|
// components/elements/Accordion.tsx
|
|
5451
|
-
var
|
|
5451
|
+
var React41 = __toESM(require("react"));
|
|
5452
5452
|
var AccordionPrimitive = __toESM(require("@radix-ui/react-accordion"));
|
|
5453
|
-
var Accordion =
|
|
5453
|
+
var Accordion = React41.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
5454
5454
|
var items = _param.items, itemClassNames = _param.itemClassNames, triggerclassNames = _param.triggerclassNames, contentclassNames = _param.contentclassNames, className = _param.className, props = _object_without_properties(_param, [
|
|
5455
5455
|
"items",
|
|
5456
5456
|
"itemClassNames",
|
|
@@ -5458,43 +5458,43 @@ var Accordion = React42.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
|
5458
5458
|
"contentclassNames",
|
|
5459
5459
|
"className"
|
|
5460
5460
|
]);
|
|
5461
|
-
return
|
|
5461
|
+
return React41.createElement(AccordionPrimitive.Root, {
|
|
5462
5462
|
type: props.type,
|
|
5463
5463
|
collapsible: true
|
|
5464
5464
|
}, items.map(function(item, index) {
|
|
5465
|
-
return /* @__PURE__ */
|
|
5465
|
+
return /* @__PURE__ */ React41.createElement(AccordionItem, {
|
|
5466
5466
|
className: itemClassNames,
|
|
5467
5467
|
key: index,
|
|
5468
5468
|
value: "item-".concat(index)
|
|
5469
|
-
}, /* @__PURE__ */
|
|
5469
|
+
}, /* @__PURE__ */ React41.createElement(AccordionTrigger, {
|
|
5470
5470
|
className: triggerclassNames
|
|
5471
|
-
}, item.trigger), /* @__PURE__ */
|
|
5471
|
+
}, item.trigger), /* @__PURE__ */ React41.createElement(AccordionContent, {
|
|
5472
5472
|
className: contentclassNames
|
|
5473
5473
|
}, item.content));
|
|
5474
5474
|
}));
|
|
5475
5475
|
});
|
|
5476
5476
|
Accordion.displayName = "Accordion";
|
|
5477
|
-
var AccordionItem =
|
|
5477
|
+
var AccordionItem = React41.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
5478
5478
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
5479
5479
|
"className"
|
|
5480
5480
|
]);
|
|
5481
|
-
return
|
|
5481
|
+
return React41.createElement(AccordionPrimitive.Item, _object_spread({
|
|
5482
5482
|
ref: ref,
|
|
5483
5483
|
className: cn(className)
|
|
5484
5484
|
}, props));
|
|
5485
5485
|
});
|
|
5486
5486
|
AccordionItem.displayName = "AccordionItem";
|
|
5487
|
-
var AccordionTrigger =
|
|
5487
|
+
var AccordionTrigger = React41.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
5488
5488
|
var className = _param.className, children = _param.children, props = _object_without_properties(_param, [
|
|
5489
5489
|
"className",
|
|
5490
5490
|
"children"
|
|
5491
5491
|
]);
|
|
5492
|
-
return
|
|
5492
|
+
return React41.createElement(AccordionPrimitive.Header, {
|
|
5493
5493
|
className: "hawa-flex"
|
|
5494
|
-
}, /* @__PURE__ */
|
|
5494
|
+
}, /* @__PURE__ */ React41.createElement(AccordionPrimitive.Trigger, _object_spread({
|
|
5495
5495
|
ref: ref,
|
|
5496
5496
|
className: cn("hawa-flex hawa-bg-muted/50 hawa-flex-1 hover:hawa-bg-muted hawa-items-center hawa-justify-between hawa-p-4 hawa-font-medium hawa-transition-all [&[data-state=open]>svg]:hawa-rotate-180", className)
|
|
5497
|
-
}, props), children, /* @__PURE__ */
|
|
5497
|
+
}, props), children, /* @__PURE__ */ React41.createElement("svg", {
|
|
5498
5498
|
xmlns: "http://www.w3.org/2000/svg",
|
|
5499
5499
|
width: "24",
|
|
5500
5500
|
height: "24",
|
|
@@ -5505,48 +5505,48 @@ var AccordionTrigger = React42.forwardRef(function(_param, ref) /* @__PURE__ */
|
|
|
5505
5505
|
strokeLinecap: "round",
|
|
5506
5506
|
strokeLinejoin: "round",
|
|
5507
5507
|
className: "hawa-h-4 hawa-w-4 hawa-shrink-0 hawa-transition-transform hawa-duration-200"
|
|
5508
|
-
}, /* @__PURE__ */
|
|
5508
|
+
}, /* @__PURE__ */ React41.createElement("path", {
|
|
5509
5509
|
d: "m6 9 6 6 6-6"
|
|
5510
5510
|
}))));
|
|
5511
5511
|
});
|
|
5512
5512
|
AccordionTrigger.displayName = AccordionPrimitive.Trigger.displayName;
|
|
5513
|
-
var AccordionContent =
|
|
5513
|
+
var AccordionContent = React41.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
5514
5514
|
var className = _param.className, children = _param.children, props = _object_without_properties(_param, [
|
|
5515
5515
|
"className",
|
|
5516
5516
|
"children"
|
|
5517
5517
|
]);
|
|
5518
|
-
return
|
|
5518
|
+
return React41.createElement(AccordionPrimitive.Content, _object_spread({
|
|
5519
5519
|
ref: ref,
|
|
5520
5520
|
className: cn("hawa-overflow-hidden hawa-text-sm hawa-transition-all data-[state=closed]:hawa-animate-accordion-up data-[state=open]:hawa-animate-accordion-down", className)
|
|
5521
|
-
}, props), /* @__PURE__ */
|
|
5521
|
+
}, props), /* @__PURE__ */ React41.createElement("div", {
|
|
5522
5522
|
className: "hawa-bg-background hawa-border hawa-p-4"
|
|
5523
5523
|
}, children));
|
|
5524
5524
|
});
|
|
5525
5525
|
AccordionContent.displayName = AccordionPrimitive.Content.displayName;
|
|
5526
5526
|
var AccordionRoot = AccordionPrimitive.Root;
|
|
5527
5527
|
// components/elements/Separator.tsx
|
|
5528
|
-
var
|
|
5528
|
+
var React42 = __toESM(require("react"));
|
|
5529
5529
|
var Separator2 = function(_param) /* @__PURE__ */ {
|
|
5530
5530
|
var className = _param.className, _param_orientation = _param.orientation, orientation = _param_orientation === void 0 ? "horizontal" : _param_orientation, props = _object_without_properties(_param, [
|
|
5531
5531
|
"className",
|
|
5532
5532
|
"orientation"
|
|
5533
5533
|
]);
|
|
5534
|
-
return
|
|
5534
|
+
return React42.createElement("div", _object_spread({
|
|
5535
5535
|
className: cn("hawa-shrink-0 hawa-bg-border", orientation === "horizontal" ? "hawa-h-[1px] hawa-w-full" : "hawa-h-full hawa-w-[1px]", className)
|
|
5536
5536
|
}, props));
|
|
5537
5537
|
};
|
|
5538
5538
|
// components/elements/Progress.tsx
|
|
5539
|
-
var
|
|
5539
|
+
var React43 = __toESM(require("react"));
|
|
5540
5540
|
var ProgressPrimitive = __toESM(require("@radix-ui/react-progress"));
|
|
5541
|
-
var Progress =
|
|
5541
|
+
var Progress = React43.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
5542
5542
|
var className = _param.className, value = _param.value, props = _object_without_properties(_param, [
|
|
5543
5543
|
"className",
|
|
5544
5544
|
"value"
|
|
5545
5545
|
]);
|
|
5546
|
-
return
|
|
5546
|
+
return React43.createElement(ProgressPrimitive.Root, _object_spread({
|
|
5547
5547
|
ref: ref,
|
|
5548
5548
|
className: cn("hawa-relative hawa-h-4 hawa-w-full hawa-overflow-hidden hawa-rounded hawa-bg-secondary", className)
|
|
5549
|
-
}, props), /* @__PURE__ */
|
|
5549
|
+
}, props), /* @__PURE__ */ React43.createElement(ProgressPrimitive.Indicator, {
|
|
5550
5550
|
className: "hawa-h-full hawa-w-full hawa-flex-1 hawa-bg-primary hawa-transition-all",
|
|
5551
5551
|
style: {
|
|
5552
5552
|
transform: "translateX(-".concat(100 - (value || 0), "%)")
|
|
@@ -5739,88 +5739,88 @@ var BadgedComponent = function(param) {
|
|
|
5739
5739
|
}), children);
|
|
5740
5740
|
};
|
|
5741
5741
|
// components/elements/Tabs.tsx
|
|
5742
|
-
var
|
|
5742
|
+
var React47 = __toESM(require("react"));
|
|
5743
5743
|
var TabsPrimitive = __toESM(require("@radix-ui/react-tabs"));
|
|
5744
|
-
var TabsContext =
|
|
5744
|
+
var TabsContext = React47.createContext({
|
|
5745
5745
|
orientation: "vertical"
|
|
5746
5746
|
});
|
|
5747
|
-
var Tabs =
|
|
5747
|
+
var Tabs = React47.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
5748
5748
|
var className = _param.className, orientation = _param.orientation, props = _object_without_properties(_param, [
|
|
5749
5749
|
"className",
|
|
5750
5750
|
"orientation"
|
|
5751
5751
|
]);
|
|
5752
|
-
return
|
|
5752
|
+
return React47.createElement(TabsPrimitive.Root, _object_spread({
|
|
5753
5753
|
ref: ref,
|
|
5754
5754
|
className: cn("hawa-flex hawa-gap-2", orientation === "vertical" ? "hawa-flex-row" : "hawa-flex-col", className)
|
|
5755
|
-
}, props), /* @__PURE__ */
|
|
5755
|
+
}, props), /* @__PURE__ */ React47.createElement(TabsContext.Provider, {
|
|
5756
5756
|
value: {
|
|
5757
5757
|
orientation: orientation
|
|
5758
5758
|
}
|
|
5759
5759
|
}, props.children));
|
|
5760
5760
|
});
|
|
5761
5761
|
Tabs.displayName = TabsPrimitive.Root.displayName;
|
|
5762
|
-
var TabsList =
|
|
5762
|
+
var TabsList = React47.forwardRef(function(_param, ref) {
|
|
5763
5763
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
5764
5764
|
"className"
|
|
5765
5765
|
]);
|
|
5766
|
-
var orientation =
|
|
5766
|
+
var orientation = React47.useContext(TabsContext).orientation;
|
|
5767
5767
|
console.log("orient ", orientation);
|
|
5768
|
-
return /* @__PURE__ */
|
|
5768
|
+
return /* @__PURE__ */ React47.createElement(TabsPrimitive.List, _object_spread({
|
|
5769
5769
|
ref: ref,
|
|
5770
5770
|
className: cn("hawa-flex hawa-w-fit hawa-flex-wrap hawa-items-center hawa-justify-start hawa-gap-1 hawa-rounded hawa-border hawa-bg-muted hawa-p-1 hawa-text-muted-foreground dark:hawa-border-primary/10", orientation === "vertical" ? "hawa-flex-col" : "hawa-flex-row", className)
|
|
5771
5771
|
}, props));
|
|
5772
5772
|
});
|
|
5773
5773
|
TabsList.displayName = TabsPrimitive.List.displayName;
|
|
5774
|
-
var TabsTrigger =
|
|
5774
|
+
var TabsTrigger = React47.forwardRef(function(_param, ref) {
|
|
5775
5775
|
var className = _param.className, chipProps = _param.chipProps, props = _object_without_properties(_param, [
|
|
5776
5776
|
"className",
|
|
5777
5777
|
"chipProps"
|
|
5778
5778
|
]);
|
|
5779
|
-
return /* @__PURE__ */
|
|
5779
|
+
return /* @__PURE__ */ React47.createElement(TabsPrimitive.Trigger, _object_spread({
|
|
5780
5780
|
ref: ref,
|
|
5781
5781
|
className: cn("hawa-inline-flex hawa-gap-2 hawa-w-full hawa-flex-1 hawa-select-none hawa-items-center hawa-justify-center hawa-whitespace-nowrap hawa-rounded hawa-border hawa-px-3 hawa-py-1.5 hawa-text-sm hawa-font-medium hawa-ring-offset-background hawa-transition-all focus-visible:hawa-outline-none focus-visible:hawa-ring-2 focus-visible:hawa-ring-ring focus-visible:hawa-ring-offset-2 disabled:hawa-pointer-events-none disabled:hawa-opacity-50 data-[state=active]:hawa-bg-primary data-[state=active]:hawa-text-primary-foreground data-[state=active]:hawa-shadow-sm dark:hawa-border-primary/10", className)
|
|
5782
|
-
}, props), props.children, chipProps && /* @__PURE__ */
|
|
5782
|
+
}, props), props.children, chipProps && /* @__PURE__ */ React47.createElement(Chip, _object_spread({}, chipProps)));
|
|
5783
5783
|
});
|
|
5784
5784
|
TabsTrigger.displayName = TabsPrimitive.Trigger.displayName;
|
|
5785
|
-
var TabsContent =
|
|
5785
|
+
var TabsContent = React47.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
5786
5786
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
5787
5787
|
"className"
|
|
5788
5788
|
]);
|
|
5789
|
-
return
|
|
5789
|
+
return React47.createElement(TabsPrimitive.Content, _object_spread({
|
|
5790
5790
|
ref: ref,
|
|
5791
5791
|
className: cn("hawa-w-full hawa-ring-offset-hawa-background focus-visible:hawa-outline-none focus-visible:hawa-ring-2 focus-visible:hawa-ring-ring focus-visible:hawa-ring-offset-2", className)
|
|
5792
5792
|
}, props));
|
|
5793
5793
|
});
|
|
5794
5794
|
TabsContent.displayName = TabsPrimitive.Content.displayName;
|
|
5795
5795
|
// components/elements/ScrollArea.tsx
|
|
5796
|
-
var
|
|
5796
|
+
var React48 = __toESM(require("react"));
|
|
5797
5797
|
var ScrollAreaPrimitive = __toESM(require("@radix-ui/react-scroll-area"));
|
|
5798
|
-
var ScrollArea =
|
|
5798
|
+
var ScrollArea = React48.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
5799
5799
|
var className = _param.className, children = _param.children, _param_orientation = _param.orientation, orientation = _param_orientation === void 0 ? "vertical" : _param_orientation, props = _object_without_properties(_param, [
|
|
5800
5800
|
"className",
|
|
5801
5801
|
"children",
|
|
5802
5802
|
"orientation"
|
|
5803
5803
|
]);
|
|
5804
|
-
return
|
|
5804
|
+
return React48.createElement(ScrollAreaPrimitive.Root, _object_spread({
|
|
5805
5805
|
ref: ref,
|
|
5806
5806
|
className: cn("hawa-relative hawa-overflow-hidden", className)
|
|
5807
|
-
}, props), /* @__PURE__ */
|
|
5807
|
+
}, props), /* @__PURE__ */ React48.createElement(ScrollAreaPrimitive.Viewport, {
|
|
5808
5808
|
className: "hawa-h-full hawa-w-full hawa-rounded-[inherit]"
|
|
5809
|
-
}, children), /* @__PURE__ */
|
|
5809
|
+
}, children), /* @__PURE__ */ React48.createElement(ScrollBar, {
|
|
5810
5810
|
orientation: orientation
|
|
5811
|
-
}), /* @__PURE__ */
|
|
5811
|
+
}), /* @__PURE__ */ React48.createElement(ScrollAreaPrimitive.Corner, null));
|
|
5812
5812
|
});
|
|
5813
5813
|
ScrollArea.displayName = ScrollAreaPrimitive.Root.displayName;
|
|
5814
|
-
var ScrollBar =
|
|
5814
|
+
var ScrollBar = React48.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
5815
5815
|
var className = _param.className, _param_orientation = _param.orientation, orientation = _param_orientation === void 0 ? "vertical" : _param_orientation, props = _object_without_properties(_param, [
|
|
5816
5816
|
"className",
|
|
5817
5817
|
"orientation"
|
|
5818
5818
|
]);
|
|
5819
|
-
return
|
|
5819
|
+
return React48.createElement(ScrollAreaPrimitive.ScrollAreaScrollbar, _object_spread({
|
|
5820
5820
|
ref: ref,
|
|
5821
5821
|
orientation: orientation,
|
|
5822
5822
|
className: cn("hawa-flex hawa-touch-none hawa-select-none hawa-transition-colors", orientation === "vertical" && "hawa-h-full hawa-w-2.5 hawa-border-l hawa-border-l-transparent hawa-p-[1px]", orientation === "horizontal" && "hawa-h-2.5 hawa-border-t hawa-border-t-transparent hawa-p-[1px]", className)
|
|
5823
|
-
}, props), /* @__PURE__ */
|
|
5823
|
+
}, props), /* @__PURE__ */ React48.createElement(ScrollAreaPrimitive.ScrollAreaThumb, {
|
|
5824
5824
|
className: cn("hawa-relative hawa-rounded-full hawa-bg-border", orientation === "vertical" && "hawa-flex-1")
|
|
5825
5825
|
}));
|
|
5826
5826
|
});
|
|
@@ -6057,13 +6057,13 @@ var Logos = {
|
|
|
6057
6057
|
}
|
|
6058
6058
|
};
|
|
6059
6059
|
// components/elements/Command.tsx
|
|
6060
|
-
var
|
|
6060
|
+
var React50 = __toESM(require("react"));
|
|
6061
6061
|
var import_cmdk = require("cmdk");
|
|
6062
|
-
var Command =
|
|
6062
|
+
var Command = React50.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
6063
6063
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
6064
6064
|
"className"
|
|
6065
6065
|
]);
|
|
6066
|
-
return
|
|
6066
|
+
return React50.createElement(import_cmdk.Command, _object_spread({
|
|
6067
6067
|
ref: ref,
|
|
6068
6068
|
className: cn("hawa-flex hawa-h-full hawa-w-full hawa-flex-col hawa-overflow-hidden hawa-rounded-md hawa-bg-popover hawa-text-popover-foreground", className)
|
|
6069
6069
|
}, props));
|
|
@@ -6073,20 +6073,20 @@ var CommandDialog = function(_param) {
|
|
|
6073
6073
|
var children = _param.children, props = _object_without_properties(_param, [
|
|
6074
6074
|
"children"
|
|
6075
6075
|
]);
|
|
6076
|
-
return /* @__PURE__ */
|
|
6076
|
+
return /* @__PURE__ */ React50.createElement(Dialog, _object_spread({}, props), /* @__PURE__ */ React50.createElement(DialogContent, {
|
|
6077
6077
|
className: "hawa-overflow-hidden hawa-p-0 hawa-shadow-lg"
|
|
6078
|
-
}, /* @__PURE__ */
|
|
6078
|
+
}, /* @__PURE__ */ React50.createElement(Command, {
|
|
6079
6079
|
className: "[&_[cmdk-group-heading]]:hawa-px-2 [&_[cmdk-group-heading]]:hawa-font-medium [&_[cmdk-group-heading]]:hawa-text-muted-foreground [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:hawa-pt-0 [&_[cmdk-group]]:hawa-px-2 [&_[cmdk-input-wrapper]_svg]:hawa-h-5 [&_[cmdk-input-wrapper]_svg]:hawa-w-5 [&_[cmdk-input]]:hawa-h-12 [&_[cmdk-item]]:hawa-px-2 [&_[cmdk-item]]:hawa-py-3 [&_[cmdk-item]_svg]:hawa-h-5 [&_[cmdk-item]_svg]:hawa-w-5"
|
|
6080
6080
|
}, children)));
|
|
6081
6081
|
};
|
|
6082
|
-
var CommandInput =
|
|
6082
|
+
var CommandInput = React50.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
6083
6083
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
6084
6084
|
"className"
|
|
6085
6085
|
]);
|
|
6086
|
-
return
|
|
6086
|
+
return React50.createElement("div", {
|
|
6087
6087
|
className: "hawa-flex hawa-items-center hawa-border-b hawa-px-3",
|
|
6088
6088
|
"cmdk-input-wrapper": ""
|
|
6089
|
-
}, /* @__PURE__ */
|
|
6089
|
+
}, /* @__PURE__ */ React50.createElement("svg", {
|
|
6090
6090
|
xmlns: "http://www.w3.org/2000/svg",
|
|
6091
6091
|
width: "24",
|
|
6092
6092
|
height: "24",
|
|
@@ -6097,60 +6097,60 @@ var CommandInput = React51.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
|
6097
6097
|
strokeLinecap: "round",
|
|
6098
6098
|
strokeLinejoin: "round",
|
|
6099
6099
|
className: "hawa-mr-2 hawa-h-4 hawa-w-4 hawa-shrink-0 hawa-opacity-50"
|
|
6100
|
-
}, /* @__PURE__ */
|
|
6100
|
+
}, /* @__PURE__ */ React50.createElement("circle", {
|
|
6101
6101
|
cx: "11",
|
|
6102
6102
|
cy: "11",
|
|
6103
6103
|
r: "8"
|
|
6104
|
-
}), /* @__PURE__ */
|
|
6104
|
+
}), /* @__PURE__ */ React50.createElement("path", {
|
|
6105
6105
|
d: "m21 21-4.3-4.3"
|
|
6106
|
-
})), /* @__PURE__ */
|
|
6106
|
+
})), /* @__PURE__ */ React50.createElement(import_cmdk.Command.Input, _object_spread({
|
|
6107
6107
|
ref: ref,
|
|
6108
6108
|
className: cn("hawa-flex hawa-h-11 hawa-w-full hawa-rounded-md hawa-bg-transparent hawa-py-3 hawa-text-sm hawa-outline-none placeholder:hawa-text-muted-foreground disabled:hawa-cursor-not-allowed disabled:hawa-opacity-50", className)
|
|
6109
6109
|
}, props)));
|
|
6110
6110
|
});
|
|
6111
6111
|
CommandInput.displayName = import_cmdk.Command.Input.displayName;
|
|
6112
|
-
var CommandList =
|
|
6112
|
+
var CommandList = React50.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
6113
6113
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
6114
6114
|
"className"
|
|
6115
6115
|
]);
|
|
6116
|
-
return
|
|
6116
|
+
return React50.createElement(import_cmdk.Command.List, _object_spread({
|
|
6117
6117
|
ref: ref,
|
|
6118
6118
|
className: cn("hawa-max-h-[300px] hawa-overflow-y-auto hawa-overflow-x-hidden", className)
|
|
6119
6119
|
}, props));
|
|
6120
6120
|
});
|
|
6121
6121
|
CommandList.displayName = import_cmdk.Command.List.displayName;
|
|
6122
|
-
var CommandEmpty =
|
|
6123
|
-
return /* @__PURE__ */
|
|
6122
|
+
var CommandEmpty = React50.forwardRef(function(props, ref) {
|
|
6123
|
+
return /* @__PURE__ */ React50.createElement(import_cmdk.Command.Empty, _object_spread({
|
|
6124
6124
|
ref: ref,
|
|
6125
6125
|
className: "hawa-py-6 hawa-text-center hawa-text-sm"
|
|
6126
6126
|
}, props));
|
|
6127
6127
|
});
|
|
6128
6128
|
CommandEmpty.displayName = import_cmdk.Command.Empty.displayName;
|
|
6129
|
-
var CommandGroup =
|
|
6129
|
+
var CommandGroup = React50.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
6130
6130
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
6131
6131
|
"className"
|
|
6132
6132
|
]);
|
|
6133
|
-
return
|
|
6133
|
+
return React50.createElement(import_cmdk.Command.Group, _object_spread({
|
|
6134
6134
|
ref: ref,
|
|
6135
6135
|
className: cn("hawa-overflow-hidden hawa-p-1 hawa-text-foreground [&_[cmdk-group-heading]]:hawa-px-2 [&_[cmdk-group-heading]]:hawa-py-1.5 [&_[cmdk-group-heading]]:hawa-text-xs [&_[cmdk-group-heading]]:hawa-font-medium [&_[cmdk-group-heading]]:hawa-text-muted-foreground", className)
|
|
6136
6136
|
}, props));
|
|
6137
6137
|
});
|
|
6138
6138
|
CommandGroup.displayName = import_cmdk.Command.Group.displayName;
|
|
6139
|
-
var CommandSeparator =
|
|
6139
|
+
var CommandSeparator = React50.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
6140
6140
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
6141
6141
|
"className"
|
|
6142
6142
|
]);
|
|
6143
|
-
return
|
|
6143
|
+
return React50.createElement(import_cmdk.Command.Separator, _object_spread({
|
|
6144
6144
|
ref: ref,
|
|
6145
6145
|
className: cn("hawa--mx-1 hawa-h-px hawa-bg-border", className)
|
|
6146
6146
|
}, props));
|
|
6147
6147
|
});
|
|
6148
6148
|
CommandSeparator.displayName = import_cmdk.Command.Separator.displayName;
|
|
6149
|
-
var CommandItem =
|
|
6149
|
+
var CommandItem = React50.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
6150
6150
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
6151
6151
|
"className"
|
|
6152
6152
|
]);
|
|
6153
|
-
return
|
|
6153
|
+
return React50.createElement(import_cmdk.Command.Item, _object_spread({
|
|
6154
6154
|
ref: ref,
|
|
6155
6155
|
className: cn("hawa-relative hawa-flex hawa-cursor-default hawa-select-none hawa-items-center hawa-rounded-sm hawa-px-2 hawa-py-1.5 hawa-text-sm hawa-outline-none aria-selected:hawa-bg-accent aria-selected:hawa-text-accent-foreground data-[disabled]:hawa-pointer-events-none data-[disabled]:hawa-opacity-50", className)
|
|
6156
6156
|
}, props));
|
|
@@ -6160,13 +6160,13 @@ var CommandShortcut = function(_param) {
|
|
|
6160
6160
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
6161
6161
|
"className"
|
|
6162
6162
|
]);
|
|
6163
|
-
return /* @__PURE__ */
|
|
6163
|
+
return /* @__PURE__ */ React50.createElement("span", _object_spread({
|
|
6164
6164
|
className: cn("hawa-ml-auto hawa-text-xs hawa-tracking-widest hawa-text-muted-foreground", className)
|
|
6165
6165
|
}, props));
|
|
6166
6166
|
};
|
|
6167
6167
|
CommandShortcut.displayName = "CommandShortcut";
|
|
6168
6168
|
// components/elements/Combobox.tsx
|
|
6169
|
-
var
|
|
6169
|
+
var React51 = __toESM(require("react"));
|
|
6170
6170
|
var PopoverPrimitive2 = __toESM(require("@radix-ui/react-popover"));
|
|
6171
6171
|
var Combobox = function(_param) {
|
|
6172
6172
|
var getProperty = function getProperty(obj, key) {
|
|
@@ -6179,30 +6179,30 @@ var Combobox = function(_param) {
|
|
|
6179
6179
|
"popoverClassName",
|
|
6180
6180
|
"data"
|
|
6181
6181
|
]);
|
|
6182
|
-
var
|
|
6183
|
-
var
|
|
6184
|
-
return /* @__PURE__ */
|
|
6182
|
+
var _React51_useState = _sliced_to_array(React51.useState(false), 2), open = _React51_useState[0], setOpen = _React51_useState[1];
|
|
6183
|
+
var _React51_useState1 = _sliced_to_array(React51.useState(defaultValue), 2), value = _React51_useState1[0], setValue = _React51_useState1[1];
|
|
6184
|
+
return /* @__PURE__ */ React51.createElement("div", {
|
|
6185
6185
|
className: cn("hawa-flex hawa-flex-col hawa-gap-2 hawa-relative hawa-h-fit", props.width === "fit" ? "hawa-w-fit" : "hawa-w-full")
|
|
6186
|
-
}, props.label && /* @__PURE__ */
|
|
6186
|
+
}, props.label && /* @__PURE__ */ React51.createElement(Label2, null, props.label), /* @__PURE__ */ React51.createElement(PopoverPrimitive2.Root, {
|
|
6187
6187
|
open: open,
|
|
6188
6188
|
onOpenChange: setOpen
|
|
6189
|
-
}, /* @__PURE__ */
|
|
6189
|
+
}, /* @__PURE__ */ React51.createElement(PopoverTrigger, {
|
|
6190
6190
|
disabled: props.isLoading || props.preview
|
|
6191
|
-
}, props.isLoading ? /* @__PURE__ */
|
|
6191
|
+
}, props.isLoading ? /* @__PURE__ */ React51.createElement("div", {
|
|
6192
6192
|
className: "hawa-pb-2"
|
|
6193
|
-
}, /* @__PURE__ */
|
|
6193
|
+
}, /* @__PURE__ */ React51.createElement(Skeleton, {
|
|
6194
6194
|
className: "hawa-h-[40px] hawa-w-full"
|
|
6195
|
-
})) : /* @__PURE__ */
|
|
6195
|
+
})) : /* @__PURE__ */ React51.createElement("div", {
|
|
6196
6196
|
className: "hawa-flex hawa-flex-col hawa-gap-2 "
|
|
6197
|
-
}, /* @__PURE__ */
|
|
6197
|
+
}, /* @__PURE__ */ React51.createElement("div", {
|
|
6198
6198
|
className: cn("hawa-absolute hawa-top-[22px] hawa-h-[0.8px] hawa-w-full hawa-bg-gray-200 hawa-transition-all dark:hawa-bg-gray-800", props.preview ? "hawa-opacity-100" : "hawa-opacity-0")
|
|
6199
|
-
}), /* @__PURE__ */
|
|
6199
|
+
}), /* @__PURE__ */ React51.createElement("button", {
|
|
6200
6200
|
role: "combobox",
|
|
6201
6201
|
"aria-expanded": open,
|
|
6202
6202
|
className: cn("hawa-text-primary hawa-border hawa-h-10 hawa-py-2 hawa-justify-between hawa-w-full hawa-font-normal hawa-inline-flex hawa-items-center hawa-transition-all hawa-select-none hawa-rounded-md hawa-text-sm hawa-ring-offset-background focus-visible:hawa-outline-none focus-visible:hawa-ring-2 focus-visible:hawa-ring-ring focus-visible:hawa-ring-offset-2 disabled:hawa-pointer-events-none disabled:hawa-opacity-50", props.preview ? "hawa-px-0 hawa-rounded-none hawa-border-transparent hawa-cursor-default" : "hawa-px-3 hawa-bg-background ")
|
|
6203
6203
|
}, value ? getProperty(data.find(function(item) {
|
|
6204
6204
|
return item[valueKey] === value;
|
|
6205
|
-
}) || {}, labelKey) : props.placeholder || "...", /* @__PURE__ */
|
|
6205
|
+
}) || {}, labelKey) : props.placeholder || "...", /* @__PURE__ */ React51.createElement("svg", {
|
|
6206
6206
|
xmlns: "http://www.w3.org/2000/svg",
|
|
6207
6207
|
className: cn("hawa-w-4 hawa-h-4 hawa-transition-all", !props.preview ? "hawa-opacity-100 hawa-visible" : "hawa-opacity-0 hawa-invisible"),
|
|
6208
6208
|
viewBox: "0 0 24 24",
|
|
@@ -6211,18 +6211,18 @@ var Combobox = function(_param) {
|
|
|
6211
6211
|
strokeWidth: "2",
|
|
6212
6212
|
strokeLinecap: "round",
|
|
6213
6213
|
strokeLinejoin: "round"
|
|
6214
|
-
}, /* @__PURE__ */
|
|
6214
|
+
}, /* @__PURE__ */ React51.createElement("path", {
|
|
6215
6215
|
d: "m6 9 6 6 6-6"
|
|
6216
|
-
}))), /* @__PURE__ */
|
|
6216
|
+
}))), /* @__PURE__ */ React51.createElement("p", {
|
|
6217
6217
|
className: cn("hawa-my-0 hawa-text-xs hawa-text-helper-color hawa-transition-all", props.helperText ? "hawa-opacity-100 hawa-h-4" : "hawa-opacity-0 hawa-h-0")
|
|
6218
|
-
}, props.helperText), " ")), /* @__PURE__ */
|
|
6218
|
+
}, props.helperText), " ")), /* @__PURE__ */ React51.createElement(PopoverContent, {
|
|
6219
6219
|
className: cn("popover-w-parent")
|
|
6220
|
-
}, /* @__PURE__ */
|
|
6220
|
+
}, /* @__PURE__ */ React51.createElement(Command, null, !props.hideInput && /* @__PURE__ */ React51.createElement(CommandInput, {
|
|
6221
6221
|
placeholder: props.searchPlaceholder
|
|
6222
|
-
}), /* @__PURE__ */
|
|
6222
|
+
}), /* @__PURE__ */ React51.createElement(CommandEmpty, null, "No framework found."), /* @__PURE__ */ React51.createElement(CommandGroup, {
|
|
6223
6223
|
className: " hawa-max-h-[200px] hawa-overflow-y-auto"
|
|
6224
6224
|
}, data.map(function(item) {
|
|
6225
|
-
return /* @__PURE__ */
|
|
6225
|
+
return /* @__PURE__ */ React51.createElement(CommandItem, {
|
|
6226
6226
|
key: getProperty(item, valueKey),
|
|
6227
6227
|
onSelect: function() {
|
|
6228
6228
|
var newValue = getProperty(item, valueKey);
|
|
@@ -6232,7 +6232,7 @@ var Combobox = function(_param) {
|
|
|
6232
6232
|
}
|
|
6233
6233
|
setOpen(false);
|
|
6234
6234
|
}
|
|
6235
|
-
}, /* @__PURE__ */
|
|
6235
|
+
}, /* @__PURE__ */ React51.createElement("svg", {
|
|
6236
6236
|
xmlns: "http://www.w3.org/2000/svg",
|
|
6237
6237
|
width: "24",
|
|
6238
6238
|
height: "24",
|
|
@@ -6243,7 +6243,7 @@ var Combobox = function(_param) {
|
|
|
6243
6243
|
strokeLinecap: "round",
|
|
6244
6244
|
strokeLinejoin: "round",
|
|
6245
6245
|
className: cn("hawa-mr-2 hawa-h-4 hawa-w-4", value === getProperty(item, valueKey) ? "hawa-opacity-100" : "hawa-opacity-0")
|
|
6246
|
-
}, /* @__PURE__ */
|
|
6246
|
+
}, /* @__PURE__ */ React51.createElement("polyline", {
|
|
6247
6247
|
points: "20 6 9 17 4 12"
|
|
6248
6248
|
})), getProperty(item, labelKey));
|
|
6249
6249
|
}))))));
|
|
@@ -6331,18 +6331,18 @@ var InterfaceSettings = function(_param) {
|
|
|
6331
6331
|
}));
|
|
6332
6332
|
};
|
|
6333
6333
|
// components/elements/Sheet.tsx
|
|
6334
|
-
var
|
|
6334
|
+
var React54 = __toESM(require("react"));
|
|
6335
6335
|
var SheetPrimitive = __toESM(require("@radix-ui/react-dialog"));
|
|
6336
6336
|
var import_class_variance_authority3 = require("class-variance-authority");
|
|
6337
6337
|
var Sheet = SheetPrimitive.Root;
|
|
6338
6338
|
var SheetTrigger = SheetPrimitive.Trigger;
|
|
6339
6339
|
var SheetClose = SheetPrimitive.Close;
|
|
6340
6340
|
var SheetPortal = SheetPrimitive.Portal;
|
|
6341
|
-
var SheetOverlay =
|
|
6341
|
+
var SheetOverlay = React54.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
6342
6342
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
6343
6343
|
"className"
|
|
6344
6344
|
]);
|
|
6345
|
-
return
|
|
6345
|
+
return React54.createElement(SheetPrimitive.Overlay, _object_spread_props(_object_spread({
|
|
6346
6346
|
className: cn("hawa-fixed hawa-inset-0 hawa-z-50 hawa-bg-background/80 hawa-backdrop-blur-sm data-[state=open]:hawa-animate-in data-[state=closed]:hawa-animate-out data-[state=closed]:hawa-fade-out-0 data-[state=open]:hawa-fade-in-0", className)
|
|
6347
6347
|
}, props), {
|
|
6348
6348
|
ref: ref
|
|
@@ -6362,30 +6362,30 @@ var sheetVariants = (0, import_class_variance_authority3.cva)("hawa-fixed hawa-z
|
|
|
6362
6362
|
side: "right"
|
|
6363
6363
|
}
|
|
6364
6364
|
});
|
|
6365
|
-
var SheetContent =
|
|
6365
|
+
var SheetContent = React54.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
6366
6366
|
var _param_side = _param.side, side = _param_side === void 0 ? "right" : _param_side, className = _param.className, children = _param.children, props = _object_without_properties(_param, [
|
|
6367
6367
|
"side",
|
|
6368
6368
|
"className",
|
|
6369
6369
|
"children"
|
|
6370
6370
|
]);
|
|
6371
|
-
return
|
|
6371
|
+
return React54.createElement(SheetPortal, null, /* @__PURE__ */ React54.createElement(SheetOverlay, null), /* @__PURE__ */ React54.createElement(SheetPrimitive.Content, _object_spread({
|
|
6372
6372
|
ref: ref,
|
|
6373
6373
|
className: cn(sheetVariants({
|
|
6374
6374
|
side: side
|
|
6375
6375
|
}), className)
|
|
6376
|
-
}, props), children, /* @__PURE__ */
|
|
6376
|
+
}, props), children, /* @__PURE__ */ React54.createElement(SheetPrimitive.Close, {
|
|
6377
6377
|
className: "hawa-absolute hawa-right-4 hawa-top-4 hawa-rounded-sm hawa-opacity-70 hawa-ring-offset-background hawa-transition-opacity hover:hawa-opacity-100 focus:hawa-outline-none focus:hawa-ring-2 focus:hawa-ring-ring focus:hawa-ring-offset-2 disabled:hawa-pointer-events-none data-[state=open]:hawa-bg-secondary"
|
|
6378
|
-
}, /* @__PURE__ */
|
|
6378
|
+
}, /* @__PURE__ */ React54.createElement("svg", {
|
|
6379
6379
|
"aria-label": "Close Icon",
|
|
6380
6380
|
"aria-hidden": "true",
|
|
6381
6381
|
className: "hawa-h-5 hawa-w-5",
|
|
6382
6382
|
fill: "currentColor",
|
|
6383
6383
|
viewBox: "0 0 20 20"
|
|
6384
|
-
}, /* @__PURE__ */
|
|
6384
|
+
}, /* @__PURE__ */ React54.createElement("path", {
|
|
6385
6385
|
fillRule: "evenodd",
|
|
6386
6386
|
d: "M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z",
|
|
6387
6387
|
clipRule: "evenodd"
|
|
6388
|
-
})), /* @__PURE__ */
|
|
6388
|
+
})), /* @__PURE__ */ React54.createElement("span", {
|
|
6389
6389
|
className: "hawa-sr-only"
|
|
6390
6390
|
}, "Close"))));
|
|
6391
6391
|
});
|
|
@@ -6394,7 +6394,7 @@ var SheetHeader = function(_param) /* @__PURE__ */ {
|
|
|
6394
6394
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
6395
6395
|
"className"
|
|
6396
6396
|
]);
|
|
6397
|
-
return
|
|
6397
|
+
return React54.createElement("div", _object_spread({
|
|
6398
6398
|
className: cn("hawa-flex hawa-flex-col hawa-space-y-2 hawa-text-center sm:hawa-text-left", className)
|
|
6399
6399
|
}, props));
|
|
6400
6400
|
};
|
|
@@ -6403,26 +6403,26 @@ var SheetFooter = function(_param) /* @__PURE__ */ {
|
|
|
6403
6403
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
6404
6404
|
"className"
|
|
6405
6405
|
]);
|
|
6406
|
-
return
|
|
6406
|
+
return React54.createElement("div", _object_spread({
|
|
6407
6407
|
className: cn("hawa-flex hawa-flex-col-reverse sm:hawa-flex-row sm:hawa-justify-end sm:hawa-space-x-2", className)
|
|
6408
6408
|
}, props));
|
|
6409
6409
|
};
|
|
6410
6410
|
SheetFooter.displayName = "SheetFooter";
|
|
6411
|
-
var SheetTitle =
|
|
6411
|
+
var SheetTitle = React54.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
6412
6412
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
6413
6413
|
"className"
|
|
6414
6414
|
]);
|
|
6415
|
-
return
|
|
6415
|
+
return React54.createElement(SheetPrimitive.Title, _object_spread({
|
|
6416
6416
|
ref: ref,
|
|
6417
6417
|
className: cn("hawa-text-lg hawa-font-semibold hawa-text-foreground", className)
|
|
6418
6418
|
}, props));
|
|
6419
6419
|
});
|
|
6420
6420
|
SheetTitle.displayName = SheetPrimitive.Title.displayName;
|
|
6421
|
-
var SheetDescription =
|
|
6421
|
+
var SheetDescription = React54.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
6422
6422
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
6423
6423
|
"className"
|
|
6424
6424
|
]);
|
|
6425
|
-
return
|
|
6425
|
+
return React54.createElement(SheetPrimitive.Description, _object_spread({
|
|
6426
6426
|
ref: ref,
|
|
6427
6427
|
className: cn("hawa-text-sm hawa-text-muted-foreground", className)
|
|
6428
6428
|
}, props));
|
|
@@ -6515,28 +6515,28 @@ var ProgressCircle = import_react32.default.forwardRef(function(props, ref) {
|
|
|
6515
6515
|
});
|
|
6516
6516
|
ProgressCircle.displayName = "ProgressCircle";
|
|
6517
6517
|
// components/elements/NavigationMenu.tsx
|
|
6518
|
-
var
|
|
6518
|
+
var React56 = __toESM(require("react"));
|
|
6519
6519
|
var NavigationMenuPrimitive = __toESM(require("@radix-ui/react-navigation-menu"));
|
|
6520
6520
|
var import_class_variance_authority4 = require("class-variance-authority");
|
|
6521
|
-
var NavigationMenuRoot =
|
|
6521
|
+
var NavigationMenuRoot = React56.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
6522
6522
|
var className = _param.className, children = _param.children, props = _object_without_properties(_param, [
|
|
6523
6523
|
"className",
|
|
6524
6524
|
"children"
|
|
6525
6525
|
]);
|
|
6526
|
-
return
|
|
6526
|
+
return React56.createElement(NavigationMenuPrimitive.Root, _object_spread({
|
|
6527
6527
|
ref: ref,
|
|
6528
6528
|
className: cn("hawa-relative hawa-z-10 hawa-flex hawa-flex-1 hawa-items-center hawa-justify-center", // "hawa-max-w-max",
|
|
6529
6529
|
className)
|
|
6530
|
-
}, props), children, /* @__PURE__ */
|
|
6530
|
+
}, props), children, /* @__PURE__ */ React56.createElement(NavigationMenuViewport, {
|
|
6531
6531
|
className: props.viewportClassNames
|
|
6532
6532
|
}));
|
|
6533
6533
|
});
|
|
6534
6534
|
NavigationMenuRoot.displayName = NavigationMenuPrimitive.Root.displayName;
|
|
6535
|
-
var NavigationMenuList =
|
|
6535
|
+
var NavigationMenuList = React56.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
6536
6536
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
6537
6537
|
"className"
|
|
6538
6538
|
]);
|
|
6539
|
-
return
|
|
6539
|
+
return React56.createElement(NavigationMenuPrimitive.List, _object_spread({
|
|
6540
6540
|
ref: ref,
|
|
6541
6541
|
className: cn("hawa-group hawa-flex hawa-flex-1 hawa-list-none hawa-items-center hawa-justify-center hawa-gap-1", className)
|
|
6542
6542
|
}, props));
|
|
@@ -6544,15 +6544,15 @@ var NavigationMenuList = React57.forwardRef(function(_param, ref) /* @__PURE__ *
|
|
|
6544
6544
|
NavigationMenuList.displayName = NavigationMenuPrimitive.List.displayName;
|
|
6545
6545
|
var NavigationMenuItem = NavigationMenuPrimitive.Item;
|
|
6546
6546
|
var navigationMenuTriggerStyle = (0, import_class_variance_authority4.cva)("hawa-group hawa-inline-flex hawa-h-10 hawa-w-max hawa-items-center hawa-gap-1 hawa-justify-center hawa-rounded-md hawa-bg-background hawa-px-4 hawa-py-2 hawa-text-sm hawa-font-medium hawa-transition-colors hover:hawa-bg-accent hover:hawa-text-accent-foreground focus:hawa-bg-accent focus:hawa-text-accent-foreground focus:hawa-outline-none disabled:hawa-pointer-events-none disabled:hawa-opacity-50 data-[active]:hawa-bg-accent/50 ");
|
|
6547
|
-
var NavigationMenuTrigger =
|
|
6547
|
+
var NavigationMenuTrigger = React56.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
6548
6548
|
var className = _param.className, children = _param.children, props = _object_without_properties(_param, [
|
|
6549
6549
|
"className",
|
|
6550
6550
|
"children"
|
|
6551
6551
|
]);
|
|
6552
|
-
return
|
|
6552
|
+
return React56.createElement(NavigationMenuPrimitive.Trigger, _object_spread({
|
|
6553
6553
|
ref: ref,
|
|
6554
6554
|
className: cn(navigationMenuTriggerStyle(), "hawa-group", className)
|
|
6555
|
-
}, props), children, " ", /* @__PURE__ */
|
|
6555
|
+
}, props), children, " ", /* @__PURE__ */ React56.createElement("svg", {
|
|
6556
6556
|
xmlns: "http://www.w3.org/2000/svg",
|
|
6557
6557
|
width: "24",
|
|
6558
6558
|
height: "24",
|
|
@@ -6564,16 +6564,16 @@ var NavigationMenuTrigger = React57.forwardRef(function(_param, ref) /* @__PURE_
|
|
|
6564
6564
|
"stroke-linejoin": "round",
|
|
6565
6565
|
"aria-hidden": "true",
|
|
6566
6566
|
className: "hawa-relative hawa-top-[1px] hawa-h-4 hawa-w-4 hawa-transition hawa-duration-200 group-data-[state=open]:hawa-rotate-180"
|
|
6567
|
-
}, /* @__PURE__ */
|
|
6567
|
+
}, /* @__PURE__ */ React56.createElement("path", {
|
|
6568
6568
|
d: "m6 9 6 6 6-6"
|
|
6569
6569
|
})));
|
|
6570
6570
|
});
|
|
6571
6571
|
NavigationMenuTrigger.displayName = NavigationMenuPrimitive.Trigger.displayName;
|
|
6572
|
-
var NavigationMenuContent =
|
|
6572
|
+
var NavigationMenuContent = React56.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
6573
6573
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
6574
6574
|
"className"
|
|
6575
6575
|
]);
|
|
6576
|
-
return
|
|
6576
|
+
return React56.createElement(NavigationMenuPrimitive.Content, _object_spread({
|
|
6577
6577
|
ref: ref,
|
|
6578
6578
|
className: cn("hawa-absolute hawa-w-full hawa-left-0 hawa-top-0 ", // "md:hawa-absolute md:hawa-w-auto hawa-left-0 hawa-top-0 ",
|
|
6579
6579
|
// animation
|
|
@@ -6583,51 +6583,51 @@ var NavigationMenuContent = React57.forwardRef(function(_param, ref) /* @__PURE_
|
|
|
6583
6583
|
NavigationMenuContent.displayName = NavigationMenuPrimitive.Content.displayName;
|
|
6584
6584
|
var NavigationMenuLink = NavigationMenuPrimitive.Link;
|
|
6585
6585
|
var NavMenuItem = function(props) {
|
|
6586
|
-
return /* @__PURE__ */
|
|
6586
|
+
return /* @__PURE__ */ React56.createElement(NavigationMenuLink, null, /* @__PURE__ */ React56.createElement("div", {
|
|
6587
6587
|
className: "hawa-max-w-md hawa-cursor-pointer hawa-p-4 hawa-py-2 hawa-rounded hawa-flex hawa-flex-row hawa-gap-4 hawa-items-center hawa-transition-all hover:hawa-bg-muted"
|
|
6588
|
-
}, props.icon && props.icon, /* @__PURE__ */
|
|
6588
|
+
}, props.icon && props.icon, /* @__PURE__ */ React56.createElement("div", {
|
|
6589
6589
|
className: "hawa-flex hawa-flex-col"
|
|
6590
|
-
}, /* @__PURE__ */
|
|
6590
|
+
}, /* @__PURE__ */ React56.createElement("h1", {
|
|
6591
6591
|
className: "hawa-font-bold hawa-text-xl"
|
|
6592
|
-
}, props.title), /* @__PURE__ */
|
|
6592
|
+
}, props.title), /* @__PURE__ */ React56.createElement("p", {
|
|
6593
6593
|
className: "hawa-text-sm"
|
|
6594
6594
|
}, props.subtitle))));
|
|
6595
6595
|
};
|
|
6596
|
-
var NavigationMenuViewport =
|
|
6596
|
+
var NavigationMenuViewport = React56.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
6597
6597
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
6598
6598
|
"className"
|
|
6599
6599
|
]);
|
|
6600
|
-
return
|
|
6600
|
+
return React56.createElement("div", {
|
|
6601
6601
|
className: cn("hawa-absolute hawa-w-full hawa-top-full hawa-flex hawa-justify-center")
|
|
6602
|
-
}, /* @__PURE__ */
|
|
6602
|
+
}, /* @__PURE__ */ React56.createElement(NavigationMenuPrimitive.Viewport, _object_spread({
|
|
6603
6603
|
className: cn("hawa-origin-top-center hawa-relative hawa-mt-1.5 hawa-h-[var(--radix-navigation-menu-viewport-height)] hawa-w-full hawa-overflow-hidden hawa-rounded-md hawa-border hawa-bg-popover hawa-text-popover-foreground hawa-shadow-lg data-[state=open]:hawa-animate-in data-[state=closed]:hawa-animate-out data-[state=closed]:hawa-zoom-out-95 data-[state=open]:hawa-zoom-in-90 ", // "md:hawa-w-[var(--radix-navigation-menu-viewport-width)]",
|
|
6604
6604
|
className),
|
|
6605
6605
|
ref: ref
|
|
6606
6606
|
}, props)));
|
|
6607
6607
|
});
|
|
6608
6608
|
NavigationMenuViewport.displayName = NavigationMenuPrimitive.Viewport.displayName;
|
|
6609
|
-
var NavigationMenuIndicator =
|
|
6609
|
+
var NavigationMenuIndicator = React56.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
6610
6610
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
6611
6611
|
"className"
|
|
6612
6612
|
]);
|
|
6613
|
-
return
|
|
6613
|
+
return React56.createElement(NavigationMenuPrimitive.Indicator, _object_spread({
|
|
6614
6614
|
ref: ref,
|
|
6615
6615
|
className: cn("hawa-top-full hawa-z-[1] hawa-flex hawa-h-1.5 hawa-items-end hawa-justify-center hawa-overflow-hidden data-[state=visible]:hawa-animate-in data-[state=hidden]:hawa-animate-out data-[state=hidden]:hawa-fade-out data-[state=visible]:hawa-fade-in", className)
|
|
6616
|
-
}, props), /* @__PURE__ */
|
|
6616
|
+
}, props), /* @__PURE__ */ React56.createElement("div", {
|
|
6617
6617
|
className: "hawa-relative hawa-top-[60%] hawa-h-2 hawa-w-2 hawa-rotate-45 hawa-rounded-tl-sm hawa-bg-border hawa-shadow-md"
|
|
6618
6618
|
}));
|
|
6619
6619
|
});
|
|
6620
6620
|
NavigationMenuIndicator.displayName = NavigationMenuPrimitive.Indicator.displayName;
|
|
6621
6621
|
var NavigationMenu = function(props) {
|
|
6622
|
-
return /* @__PURE__ */
|
|
6622
|
+
return /* @__PURE__ */ React56.createElement(NavigationMenuRoot, {
|
|
6623
6623
|
dir: props.direction,
|
|
6624
6624
|
delayDuration: 0,
|
|
6625
6625
|
className: props.rootClassNames,
|
|
6626
6626
|
viewportClassNames: props.viewportClassNames
|
|
6627
|
-
}, /* @__PURE__ */
|
|
6628
|
-
return /* @__PURE__ */
|
|
6627
|
+
}, /* @__PURE__ */ React56.createElement(NavigationMenuList, null, props.items.map(function(item, i) {
|
|
6628
|
+
return /* @__PURE__ */ React56.createElement(NavigationMenuItem, {
|
|
6629
6629
|
key: i
|
|
6630
|
-
}, item.content ? /* @__PURE__ */
|
|
6630
|
+
}, item.content ? /* @__PURE__ */ React56.createElement(React56.Fragment, null, /* @__PURE__ */ React56.createElement(NavigationMenuTrigger, null, item.trigger), /* @__PURE__ */ React56.createElement(NavigationMenuContent, null, item.content)) : /* @__PURE__ */ React56.createElement(NavigationMenuLink, {
|
|
6631
6631
|
onClick: function() {
|
|
6632
6632
|
if (item.action) {
|
|
6633
6633
|
item.action();
|
|
@@ -6664,32 +6664,32 @@ var Stats = function(_param) {
|
|
|
6664
6664
|
}) : props.chart));
|
|
6665
6665
|
};
|
|
6666
6666
|
// components/layout/Sidebar.tsx
|
|
6667
|
-
var
|
|
6667
|
+
var React58 = __toESM(require("react"));
|
|
6668
6668
|
var AccordionPrimitive2 = __toESM(require("@radix-ui/react-accordion"));
|
|
6669
6669
|
var Accordion2 = AccordionPrimitive2.Root;
|
|
6670
6670
|
var triggerStyles = "hawa-flex hawa-flex-1 hawa-items-center hawa-duration-75 hawa-select-none hawa-cursor-pointer hawa-rounded hawa-justify-between hawa-p-2 hawa-px-3 hawa-font-medium hawa-transition-all [&[data-state=open]>svg]:hawa--rotate-90";
|
|
6671
|
-
var AccordionItem2 =
|
|
6671
|
+
var AccordionItem2 = React58.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
6672
6672
|
var className = _param.className, props = _object_without_properties(_param, [
|
|
6673
6673
|
"className"
|
|
6674
6674
|
]);
|
|
6675
|
-
return
|
|
6675
|
+
return React58.createElement(AccordionPrimitive2.Item, _object_spread({
|
|
6676
6676
|
ref: ref,
|
|
6677
6677
|
className: cn(className)
|
|
6678
6678
|
}, props));
|
|
6679
6679
|
});
|
|
6680
6680
|
AccordionItem2.displayName = "AccordionItem";
|
|
6681
|
-
var AccordionTrigger2 =
|
|
6681
|
+
var AccordionTrigger2 = React58.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
6682
6682
|
var className = _param.className, showArrow = _param.showArrow, children = _param.children, props = _object_without_properties(_param, [
|
|
6683
6683
|
"className",
|
|
6684
6684
|
"showArrow",
|
|
6685
6685
|
"children"
|
|
6686
6686
|
]);
|
|
6687
|
-
return
|
|
6687
|
+
return React58.createElement(AccordionPrimitive2.Header, {
|
|
6688
6688
|
className: "flex"
|
|
6689
|
-
}, /* @__PURE__ */
|
|
6689
|
+
}, /* @__PURE__ */ React58.createElement(AccordionPrimitive2.Trigger, _object_spread({
|
|
6690
6690
|
ref: ref,
|
|
6691
6691
|
className: cn(triggerStyles, className)
|
|
6692
|
-
}, props), children, showArrow && /* @__PURE__ */
|
|
6692
|
+
}, props), children, showArrow && /* @__PURE__ */ React58.createElement("svg", {
|
|
6693
6693
|
"aria-label": "Chevron Right Icon",
|
|
6694
6694
|
stroke: "currentColor",
|
|
6695
6695
|
fill: "currentColor",
|
|
@@ -6697,31 +6697,31 @@ var AccordionTrigger2 = React59.forwardRef(function(_param, ref) /* @__PURE__ */
|
|
|
6697
6697
|
height: "1em",
|
|
6698
6698
|
width: "1em",
|
|
6699
6699
|
className: "hawa-h-4 hawa-w-4 hawa-shrink-0 hawa-rotate-90 hawa-transition-transform hawa-duration-200"
|
|
6700
|
-
}, /* @__PURE__ */
|
|
6700
|
+
}, /* @__PURE__ */ React58.createElement("path", {
|
|
6701
6701
|
d: "M4.646 1.646a.5.5 0 0 1 .708 0l6 6a.5.5 0 0 1 0 .708l-6 6a.5.5 0 0 1-.708-.708L10.293 8 4.646 2.354a.5.5 0 0 1 0-.708z"
|
|
6702
6702
|
}))));
|
|
6703
6703
|
});
|
|
6704
6704
|
AccordionTrigger2.displayName = AccordionPrimitive2.Trigger.displayName;
|
|
6705
|
-
var AccordionContent2 =
|
|
6705
|
+
var AccordionContent2 = React58.forwardRef(function(_param, ref) /* @__PURE__ */ {
|
|
6706
6706
|
var className = _param.className, children = _param.children, props = _object_without_properties(_param, [
|
|
6707
6707
|
"className",
|
|
6708
6708
|
"children"
|
|
6709
6709
|
]);
|
|
6710
|
-
return
|
|
6710
|
+
return React58.createElement(AccordionPrimitive2.Content, _object_spread({
|
|
6711
6711
|
ref: ref,
|
|
6712
6712
|
className: cn("hawa-overflow-hidden hawa-text-sm hawa-transition-all data-[state=closed]:hawa-animate-accordion-up data-[state=open]:hawa-animate-accordion-down", className)
|
|
6713
|
-
}, props), /* @__PURE__ */
|
|
6713
|
+
}, props), /* @__PURE__ */ React58.createElement("div", null, children));
|
|
6714
6714
|
});
|
|
6715
6715
|
AccordionContent2.displayName = AccordionPrimitive2.Content.displayName;
|
|
6716
6716
|
var SidebarGroup = function(param) {
|
|
6717
6717
|
var title = param.title, items = param.items, selectedItem = param.selectedItem, openedItem = param.openedItem, setOpenedItem = param.setOpenedItem, onItemClick = param.onItemClick, onSubItemClick = param.onSubItemClick, direction = param.direction, isOpen = param.isOpen;
|
|
6718
|
-
return /* @__PURE__ */
|
|
6718
|
+
return /* @__PURE__ */ React58.createElement("div", {
|
|
6719
6719
|
className: "hawa-m-2"
|
|
6720
|
-
}, title && /* @__PURE__ */
|
|
6720
|
+
}, title && /* @__PURE__ */ React58.createElement("h3", {
|
|
6721
6721
|
className: "hawa-mb-1 hawa-font-bold"
|
|
6722
|
-
}, title), /* @__PURE__ */
|
|
6722
|
+
}, title), /* @__PURE__ */ React58.createElement("ul", {
|
|
6723
6723
|
className: "hawa-flex hawa-flex-col hawa-gap-2"
|
|
6724
|
-
}, /* @__PURE__ */
|
|
6724
|
+
}, /* @__PURE__ */ React58.createElement(Accordion2, {
|
|
6725
6725
|
value: openedItem,
|
|
6726
6726
|
type: "single",
|
|
6727
6727
|
onValueChange: function(e) {
|
|
@@ -6730,7 +6730,7 @@ var SidebarGroup = function(param) {
|
|
|
6730
6730
|
collapsible: true,
|
|
6731
6731
|
className: "hawa-flex hawa-flex-col hawa-gap-1"
|
|
6732
6732
|
}, items.map(function(item, idx) {
|
|
6733
|
-
return /* @__PURE__ */
|
|
6733
|
+
return /* @__PURE__ */ React58.createElement(SidebarItem, {
|
|
6734
6734
|
isOpen: isOpen,
|
|
6735
6735
|
selectedItem: selectedItem,
|
|
6736
6736
|
key: idx,
|
|
@@ -6753,25 +6753,25 @@ var SidebarItem = function(_param) {
|
|
|
6753
6753
|
return props.selectedItem === value ? "hawa-bg-primary hawa-text-primary-foreground hawa-cursor-default" : "hover:hawa-bg-primary/10";
|
|
6754
6754
|
};
|
|
6755
6755
|
if (item.subitems) {
|
|
6756
|
-
return /* @__PURE__ */
|
|
6756
|
+
return /* @__PURE__ */ React58.createElement(AccordionItem2, {
|
|
6757
6757
|
value: item.value,
|
|
6758
6758
|
className: "hawa-overflow-x-clip",
|
|
6759
6759
|
dir: direction
|
|
6760
|
-
}, /* @__PURE__ */
|
|
6760
|
+
}, /* @__PURE__ */ React58.createElement(AccordionTrigger2, {
|
|
6761
6761
|
className: cn("hawa-overflow-x-clip hawa-w-full", props.selectedItem === item.value ? "hawa-cursor-default hawa-bg-primary hawa-text-primary-foreground" : "hover:hawa-bg-primary/10 hawa-h-10", item.subitems && item.subitems.some(function(subitem) {
|
|
6762
6762
|
return props.selectedItem === subitem.value;
|
|
6763
6763
|
}) ? "hawa-bg-primary/90 hawa-text-primary-foreground hover:hawa-bg-primary/90" : ""),
|
|
6764
6764
|
showArrow: isOpen
|
|
6765
|
-
}, /* @__PURE__ */
|
|
6765
|
+
}, /* @__PURE__ */ React58.createElement("div", {
|
|
6766
6766
|
className: cn(!isOpen && "hawa-py-1", "hawa-flex hawa-w-fit hawa-flex-row hawa-items-center hawa-gap-2")
|
|
6767
|
-
}, item.icon && item.icon, /* @__PURE__ */
|
|
6767
|
+
}, item.icon && item.icon, /* @__PURE__ */ React58.createElement("span", {
|
|
6768
6768
|
className: cn("hawa-transition-all ", isOpen ? "hawa-opacity-100" : "hawa-opacity-0")
|
|
6769
|
-
}, item.label))), item.subitems && /* @__PURE__ */
|
|
6769
|
+
}, item.label))), item.subitems && /* @__PURE__ */ React58.createElement(AccordionContent2, {
|
|
6770
6770
|
className: "hawa-mt-1 hawa-h-full hawa-rounded"
|
|
6771
|
-
}, /* @__PURE__ */
|
|
6771
|
+
}, /* @__PURE__ */ React58.createElement("div", {
|
|
6772
6772
|
className: cn("hawa-flex hawa-h-full hawa-flex-col hawa-gap-2 hawa-bg-foreground/5 hawa-p-1")
|
|
6773
6773
|
}, item.subitems.map(function(subitem, idx) {
|
|
6774
|
-
return /* @__PURE__ */
|
|
6774
|
+
return /* @__PURE__ */ React58.createElement("li", {
|
|
6775
6775
|
key: idx,
|
|
6776
6776
|
onClick: function(e) {
|
|
6777
6777
|
e.stopPropagation();
|
|
@@ -6790,7 +6790,7 @@ var SidebarItem = function(_param) {
|
|
|
6790
6790
|
}, subitem.icon && subitem.icon, subitem.label);
|
|
6791
6791
|
}))));
|
|
6792
6792
|
} else {
|
|
6793
|
-
return /* @__PURE__ */
|
|
6793
|
+
return /* @__PURE__ */ React58.createElement("div", {
|
|
6794
6794
|
dir: direction,
|
|
6795
6795
|
onClick: function() {
|
|
6796
6796
|
if (item.onClick) {
|
|
@@ -6803,9 +6803,9 @@ var SidebarItem = function(_param) {
|
|
|
6803
6803
|
}
|
|
6804
6804
|
},
|
|
6805
6805
|
className: cn(triggerStyles, getSelectedStyle(item.value), "hawa-overflow-x-clip ")
|
|
6806
|
-
}, /* @__PURE__ */
|
|
6806
|
+
}, /* @__PURE__ */ React58.createElement("div", {
|
|
6807
6807
|
className: "hawa-flex hawa-flex-row hawa-items-center hawa-gap-2"
|
|
6808
|
-
}, item.icon && item.icon, /* @__PURE__ */
|
|
6808
|
+
}, item.icon && item.icon, /* @__PURE__ */ React58.createElement("span", {
|
|
6809
6809
|
className: cn("hawa-whitespace-nowrap hawa-transition-all", isOpen ? "hawa-opacity-100" : "hawa-opacity-0")
|
|
6810
6810
|
}, item.label)));
|
|
6811
6811
|
}
|
|
@@ -6833,51 +6833,98 @@ var Collapsible = CollapsiblePrimitive.Root;
|
|
|
6833
6833
|
var CollapsibleTrigger2 = CollapsiblePrimitive.CollapsibleTrigger;
|
|
6834
6834
|
var CollapsibleContent2 = CollapsiblePrimitive.CollapsibleContent;
|
|
6835
6835
|
// components/layout/Navbar.tsx
|
|
6836
|
-
var Navbar = function(
|
|
6837
|
-
var
|
|
6836
|
+
var Navbar = function(_param) {
|
|
6837
|
+
var backgroundColor = _param.backgroundColor, logo = _param.logo, handleLogoClick = _param.handleLogoClick, props = _object_without_properties(_param, [
|
|
6838
|
+
"backgroundColor",
|
|
6839
|
+
"logo",
|
|
6840
|
+
"handleLogoClick"
|
|
6841
|
+
]);
|
|
6842
|
+
var _props_menuItems, _props_menuItems1;
|
|
6838
6843
|
var _ref = _sliced_to_array((0, import_react35.useState)(false), 2), isOpen = _ref[0], setIsOpen = _ref[1];
|
|
6839
6844
|
return /* @__PURE__ */ import_react35.default.createElement("nav", {
|
|
6840
6845
|
className: " hawa-transition-all hawa-sticky hawa-top-2"
|
|
6841
6846
|
}, /* @__PURE__ */ import_react35.default.createElement(Collapsible, {
|
|
6842
|
-
className: "hawa-
|
|
6847
|
+
className: "hawa-p-2 hawa-relative hawa-m-2 hawa-rounded",
|
|
6848
|
+
style: {
|
|
6849
|
+
backgroundColor: backgroundColor || "#1f2937"
|
|
6850
|
+
}
|
|
6843
6851
|
}, /* @__PURE__ */ import_react35.default.createElement("div", {
|
|
6844
|
-
className: "hawa-flex hawa-justify-between hawa-items-center"
|
|
6852
|
+
className: "hawa-flex hawa-justify-between hawa-items-center hawa-px-3 "
|
|
6845
6853
|
}, /* @__PURE__ */ import_react35.default.createElement("div", {
|
|
6846
6854
|
className: "hawa-flex hawa-items-center"
|
|
6847
6855
|
}, /* @__PURE__ */ import_react35.default.createElement("div", {
|
|
6848
|
-
className: "hawa-text-white hawa-text-xl hawa-font-bold"
|
|
6849
|
-
|
|
6850
|
-
|
|
6851
|
-
|
|
6852
|
-
|
|
6853
|
-
|
|
6856
|
+
className: "hawa-text-white hawa-text-xl hawa-p-1.5 hawa-font-bold",
|
|
6857
|
+
onClick: function() {
|
|
6858
|
+
if (handleLogoClick) {
|
|
6859
|
+
handleLogoClick();
|
|
6860
|
+
}
|
|
6861
|
+
}
|
|
6862
|
+
}, logo)), /* @__PURE__ */ import_react35.default.createElement("div", {
|
|
6863
|
+
className: "hawa-hidden md:hawa-flex "
|
|
6864
|
+
}, (_props_menuItems = props.menuItems) === null || _props_menuItems === void 0 ? void 0 : _props_menuItems.map(function(item) {
|
|
6865
|
+
return /* @__PURE__ */ import_react35.default.createElement("div", {
|
|
6866
|
+
onClick: item.action,
|
|
6867
|
+
className: "hawa-p-1.5 hawa-px-2 hawa-text-sm hawa-text-center hawa-rounded hawa-text-white hover:hawa-text-black hover:hawa-bg-gray-300 hawa-transition-all hawa-cursor-pointer"
|
|
6868
|
+
}, item.label);
|
|
6869
|
+
})), /* @__PURE__ */ import_react35.default.createElement("div", {
|
|
6870
|
+
className: "md:hawa-hidden hawa-flex hawa-h-fit hawa-p-0 hawa-m-0"
|
|
6854
6871
|
}, /* @__PURE__ */ import_react35.default.createElement(CollapsibleTrigger2, {
|
|
6855
6872
|
onClick: function() {
|
|
6856
6873
|
return setIsOpen(!isOpen);
|
|
6857
6874
|
},
|
|
6858
|
-
className: "hawa-text-white hawa-p-
|
|
6875
|
+
className: "hawa-text-white selection:hawa-p-0 hawa-h-full ",
|
|
6859
6876
|
"aria-label": "Toggle menu"
|
|
6860
6877
|
}, /* @__PURE__ */ import_react35.default.createElement("svg", {
|
|
6861
|
-
|
|
6878
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
6879
|
+
width: "24",
|
|
6880
|
+
height: "24",
|
|
6881
|
+
viewBox: "0 0 24 24",
|
|
6862
6882
|
fill: "none",
|
|
6863
6883
|
stroke: "currentColor",
|
|
6884
|
+
"stroke-width": "2",
|
|
6885
|
+
"stroke-linecap": "round",
|
|
6886
|
+
"stroke-linejoin": "round",
|
|
6887
|
+
className: cn("hawa-w-6 hawa-h-6 hawa-fixed", isOpen ? "hawa-invisible" : "hawa-visible")
|
|
6888
|
+
}, /* @__PURE__ */ import_react35.default.createElement("line", {
|
|
6889
|
+
x1: "4",
|
|
6890
|
+
x2: "20",
|
|
6891
|
+
y1: "12",
|
|
6892
|
+
y2: "12"
|
|
6893
|
+
}), /* @__PURE__ */ import_react35.default.createElement("line", {
|
|
6894
|
+
x1: "4",
|
|
6895
|
+
x2: "20",
|
|
6896
|
+
y1: "6",
|
|
6897
|
+
y2: "6"
|
|
6898
|
+
}), /* @__PURE__ */ import_react35.default.createElement("line", {
|
|
6899
|
+
x1: "4",
|
|
6900
|
+
x2: "20",
|
|
6901
|
+
y1: "18",
|
|
6902
|
+
y2: "18"
|
|
6903
|
+
})), /* @__PURE__ */ import_react35.default.createElement("svg", {
|
|
6904
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
6905
|
+
width: "24",
|
|
6906
|
+
height: "24",
|
|
6864
6907
|
viewBox: "0 0 24 24",
|
|
6865
|
-
|
|
6908
|
+
fill: "none",
|
|
6909
|
+
stroke: "currentColor",
|
|
6910
|
+
"stroke-width": "2",
|
|
6911
|
+
"stroke-linecap": "round",
|
|
6912
|
+
"stroke-linejoin": "round",
|
|
6913
|
+
className: cn("hawa-w-6 hawa-h-6", !isOpen ? "hawa-invisible" : "hawa-visible")
|
|
6866
6914
|
}, /* @__PURE__ */ import_react35.default.createElement("path", {
|
|
6867
|
-
|
|
6868
|
-
|
|
6869
|
-
|
|
6870
|
-
d: "M4 6h16M4 12h16m-7 6h7"
|
|
6915
|
+
d: "M18 6 6 18"
|
|
6916
|
+
}), /* @__PURE__ */ import_react35.default.createElement("path", {
|
|
6917
|
+
d: "m6 6 12 12"
|
|
6871
6918
|
}))))), /* @__PURE__ */ import_react35.default.createElement(CollapsibleContent2, {
|
|
6872
|
-
className: cn("data-[state=open]:hawa-animate-in", "data-[state=open]:hawa-fade-in-90", "hawa-transition-all hawa-bg-gray-
|
|
6919
|
+
className: cn("data-[state=closed]:hawa-opacity-0", "data-[state=open]:hawa-animate-in", "data-[state=open]:hawa-fade-in-90", "hawa-transition-all hawa-bg-gray-200 hawa-border hawa-absolute hawa-p-1 hawa-left-0 hawa-top-[60px] hawa-flex hawa-flex-col hawa-rounded"),
|
|
6873
6920
|
style: {
|
|
6874
|
-
width: "calc(100%
|
|
6921
|
+
width: "calc(100%)",
|
|
6875
6922
|
zIndex: -100
|
|
6876
6923
|
}
|
|
6877
|
-
}, (
|
|
6924
|
+
}, (_props_menuItems1 = props.menuItems) === null || _props_menuItems1 === void 0 ? void 0 : _props_menuItems1.map(function(item) {
|
|
6878
6925
|
return /* @__PURE__ */ import_react35.default.createElement("div", {
|
|
6879
6926
|
onClick: item.action,
|
|
6880
|
-
className: "hawa-text-
|
|
6927
|
+
className: "hawa-text-black hawa-p-2 hawa-px-10 hawa-text-center hawa-rounded hover:hawa-bg-gray-300 hawa-transition-all hawa-cursor-pointer"
|
|
6881
6928
|
}, item.label);
|
|
6882
6929
|
}))));
|
|
6883
6930
|
};
|
|
@@ -7367,7 +7414,7 @@ var DocsLayout = function(_param) {
|
|
|
7367
7414
|
}, props.children));
|
|
7368
7415
|
};
|
|
7369
7416
|
// components/blocks/auth/LoginForm.tsx
|
|
7370
|
-
var
|
|
7417
|
+
var import_react43 = __toESM(require("react"));
|
|
7371
7418
|
var import_react_hook_form = require("react-hook-form");
|
|
7372
7419
|
var import_zod = require("@hookform/resolvers/zod");
|
|
7373
7420
|
var import_libphonenumber_js = require("libphonenumber-js");
|
|
@@ -7424,10 +7471,11 @@ var AuthButtons = function(props) {
|
|
|
7424
7471
|
}), (_props_texts_continueWithPhone = (_props_texts6 = props.texts) === null || _props_texts6 === void 0 ? void 0 : _props_texts6.continueWithPhone) !== null && _props_texts_continueWithPhone !== void 0 ? _props_texts_continueWithPhone : "Continue With Phone"));
|
|
7425
7472
|
};
|
|
7426
7473
|
// components/icons/index.tsx
|
|
7474
|
+
var import_react42 = __toESM(require("react"));
|
|
7427
7475
|
var EyeIcon = function(props) {
|
|
7428
|
-
return /* @__PURE__ */
|
|
7476
|
+
return /* @__PURE__ */ import_react42.default.createElement("div", {
|
|
7429
7477
|
className: props.classNames
|
|
7430
|
-
}, /* @__PURE__ */
|
|
7478
|
+
}, /* @__PURE__ */ import_react42.default.createElement("svg", {
|
|
7431
7479
|
xmlns: "http://www.w3.org/2000/svg",
|
|
7432
7480
|
width: "24",
|
|
7433
7481
|
height: "24",
|
|
@@ -7437,18 +7485,18 @@ var EyeIcon = function(props) {
|
|
|
7437
7485
|
"stroke-width": "2",
|
|
7438
7486
|
"stroke-linecap": "round",
|
|
7439
7487
|
"stroke-linejoin": "round"
|
|
7440
|
-
}, /* @__PURE__ */
|
|
7488
|
+
}, /* @__PURE__ */ import_react42.default.createElement("path", {
|
|
7441
7489
|
d: "M2 12s3-7 10-7 10 7 10 7-3 7-10 7-10-7-10-7Z"
|
|
7442
|
-
}), /* @__PURE__ */
|
|
7490
|
+
}), /* @__PURE__ */ import_react42.default.createElement("circle", {
|
|
7443
7491
|
cx: "12",
|
|
7444
7492
|
cy: "12",
|
|
7445
7493
|
r: "3"
|
|
7446
7494
|
})));
|
|
7447
7495
|
};
|
|
7448
7496
|
var HiddenEyeIcon = function(props) {
|
|
7449
|
-
return /* @__PURE__ */
|
|
7497
|
+
return /* @__PURE__ */ import_react42.default.createElement("div", {
|
|
7450
7498
|
className: props.classNames
|
|
7451
|
-
}, /* @__PURE__ */
|
|
7499
|
+
}, /* @__PURE__ */ import_react42.default.createElement("svg", {
|
|
7452
7500
|
xmlns: "http://www.w3.org/2000/svg",
|
|
7453
7501
|
width: "24",
|
|
7454
7502
|
height: "24",
|
|
@@ -7458,13 +7506,13 @@ var HiddenEyeIcon = function(props) {
|
|
|
7458
7506
|
"stroke-width": "2",
|
|
7459
7507
|
"stroke-linecap": "round",
|
|
7460
7508
|
"stroke-linejoin": "round"
|
|
7461
|
-
}, /* @__PURE__ */
|
|
7509
|
+
}, /* @__PURE__ */ import_react42.default.createElement("path", {
|
|
7462
7510
|
d: "M9.88 9.88a3 3 0 1 0 4.24 4.24"
|
|
7463
|
-
}), /* @__PURE__ */
|
|
7511
|
+
}), /* @__PURE__ */ import_react42.default.createElement("path", {
|
|
7464
7512
|
d: "M10.73 5.08A10.43 10.43 0 0 1 12 5c7 0 10 7 10 7a13.16 13.16 0 0 1-1.67 2.68"
|
|
7465
|
-
}), /* @__PURE__ */
|
|
7513
|
+
}), /* @__PURE__ */ import_react42.default.createElement("path", {
|
|
7466
7514
|
d: "M6.61 6.61A13.526 13.526 0 0 0 2 12s3 7 10 7a9.74 9.74 0 0 0 5.39-1.61"
|
|
7467
|
-
}), /* @__PURE__ */
|
|
7515
|
+
}), /* @__PURE__ */ import_react42.default.createElement("line", {
|
|
7468
7516
|
x1: "2",
|
|
7469
7517
|
x2: "22",
|
|
7470
7518
|
y1: "2",
|
|
@@ -7478,7 +7526,7 @@ var LoginForm = function(_param) {
|
|
|
7478
7526
|
"texts",
|
|
7479
7527
|
"passwordLength"
|
|
7480
7528
|
]);
|
|
7481
|
-
var _ref = _sliced_to_array((0,
|
|
7529
|
+
var _ref = _sliced_to_array((0, import_react43.useState)(false), 2), passwordVisible = _ref[0], setPasswordVisible = _ref[1];
|
|
7482
7530
|
var thirdPartyAuthTexts = {
|
|
7483
7531
|
continueWithGoogle: texts === null || texts === void 0 ? void 0 : texts.continueWithGoogle,
|
|
7484
7532
|
continueWithTwitter: texts === null || texts === void 0 ? void 0 : texts.continueWithTwitter,
|
|
@@ -7560,13 +7608,13 @@ var LoginForm = function(_param) {
|
|
|
7560
7608
|
var renderFields = function() {
|
|
7561
7609
|
switch(loginType){
|
|
7562
7610
|
case "email":
|
|
7563
|
-
return /* @__PURE__ */
|
|
7611
|
+
return /* @__PURE__ */ import_react43.default.createElement(import_react43.default.Fragment, null, /* @__PURE__ */ import_react43.default.createElement(import_react_hook_form.Controller, {
|
|
7564
7612
|
control: control,
|
|
7565
7613
|
name: "email",
|
|
7566
7614
|
render: function(param) {
|
|
7567
7615
|
var field = param.field;
|
|
7568
7616
|
var _texts_email, _formState_errors_email, _texts_email1;
|
|
7569
|
-
return /* @__PURE__ */
|
|
7617
|
+
return /* @__PURE__ */ import_react43.default.createElement(Input, _object_spread({
|
|
7570
7618
|
width: "full",
|
|
7571
7619
|
autoComplete: "email",
|
|
7572
7620
|
label: texts === null || texts === void 0 ? void 0 : (_texts_email = texts.email) === null || _texts_email === void 0 ? void 0 : _texts_email.label,
|
|
@@ -7574,43 +7622,43 @@ var LoginForm = function(_param) {
|
|
|
7574
7622
|
placeholder: (texts === null || texts === void 0 ? void 0 : (_texts_email1 = texts.email) === null || _texts_email1 === void 0 ? void 0 : _texts_email1.placeholder) || "contact@sikka.io"
|
|
7575
7623
|
}, field));
|
|
7576
7624
|
}
|
|
7577
|
-
}), /* @__PURE__ */
|
|
7625
|
+
}), /* @__PURE__ */ import_react43.default.createElement("div", null, /* @__PURE__ */ import_react43.default.createElement(import_react_hook_form.Controller, {
|
|
7578
7626
|
control: control,
|
|
7579
7627
|
name: "password",
|
|
7580
7628
|
render: function(param) {
|
|
7581
7629
|
var field = param.field;
|
|
7582
7630
|
var _texts_password, _texts_password1, _formState_errors_password;
|
|
7583
|
-
return /* @__PURE__ */
|
|
7631
|
+
return /* @__PURE__ */ import_react43.default.createElement(Input, _object_spread({
|
|
7584
7632
|
width: "full",
|
|
7585
7633
|
autoComplete: "current-password",
|
|
7586
7634
|
type: passwordVisible ? "text" : "password",
|
|
7587
7635
|
label: (texts === null || texts === void 0 ? void 0 : (_texts_password = texts.password) === null || _texts_password === void 0 ? void 0 : _texts_password.label) || "Password",
|
|
7588
|
-
iconInside: /* @__PURE__ */
|
|
7636
|
+
iconInside: /* @__PURE__ */ import_react43.default.createElement("div", {
|
|
7589
7637
|
className: "hawa-cursor-pointer",
|
|
7590
7638
|
onClick: function() {
|
|
7591
7639
|
return setPasswordVisible(!passwordVisible);
|
|
7592
7640
|
}
|
|
7593
|
-
}, passwordVisible ? /* @__PURE__ */
|
|
7641
|
+
}, passwordVisible ? /* @__PURE__ */ import_react43.default.createElement(EyeIcon, {
|
|
7594
7642
|
classNames: "hawa-text-gray-500"
|
|
7595
|
-
}) : /* @__PURE__ */
|
|
7643
|
+
}) : /* @__PURE__ */ import_react43.default.createElement(HiddenEyeIcon, {
|
|
7596
7644
|
classNames: "hawa-text-gray-500"
|
|
7597
7645
|
})),
|
|
7598
7646
|
placeholder: (texts === null || texts === void 0 ? void 0 : (_texts_password1 = texts.password) === null || _texts_password1 === void 0 ? void 0 : _texts_password1.placeholder) || "Enter your password",
|
|
7599
7647
|
helperText: (_formState_errors_password = formState.errors.password) === null || _formState_errors_password === void 0 ? void 0 : _formState_errors_password.message
|
|
7600
7648
|
}, field));
|
|
7601
7649
|
}
|
|
7602
|
-
}), !props.withoutResetPassword && /* @__PURE__ */
|
|
7650
|
+
}), !props.withoutResetPassword && /* @__PURE__ */ import_react43.default.createElement("div", {
|
|
7603
7651
|
onClick: props.onForgotPassword,
|
|
7604
7652
|
className: "hawa-mb-3 hawa-select-none hawa-mt-2 hawa-w-fit hawa-cursor-pointer hawa-text-xs dark:hawa-text-gray-300"
|
|
7605
7653
|
}, (texts === null || texts === void 0 ? void 0 : texts.forgotPassword) || "Forgot Password?")));
|
|
7606
7654
|
case "username":
|
|
7607
|
-
return /* @__PURE__ */
|
|
7655
|
+
return /* @__PURE__ */ import_react43.default.createElement(import_react43.default.Fragment, null, /* @__PURE__ */ import_react43.default.createElement(import_react_hook_form.Controller, {
|
|
7608
7656
|
control: control,
|
|
7609
7657
|
name: "username",
|
|
7610
7658
|
render: function(param) {
|
|
7611
7659
|
var field = param.field;
|
|
7612
7660
|
var _texts_username, _formState_errors_username, _texts_username1;
|
|
7613
|
-
return /* @__PURE__ */
|
|
7661
|
+
return /* @__PURE__ */ import_react43.default.createElement(Input, _object_spread({
|
|
7614
7662
|
width: "full",
|
|
7615
7663
|
autoComplete: "username",
|
|
7616
7664
|
label: (texts === null || texts === void 0 ? void 0 : (_texts_username = texts.username) === null || _texts_username === void 0 ? void 0 : _texts_username.label) || "Username",
|
|
@@ -7618,43 +7666,43 @@ var LoginForm = function(_param) {
|
|
|
7618
7666
|
placeholder: (texts === null || texts === void 0 ? void 0 : (_texts_username1 = texts.username) === null || _texts_username1 === void 0 ? void 0 : _texts_username1.placeholder) || "sikka_sa"
|
|
7619
7667
|
}, field));
|
|
7620
7668
|
}
|
|
7621
|
-
}), /* @__PURE__ */
|
|
7669
|
+
}), /* @__PURE__ */ import_react43.default.createElement("div", null, /* @__PURE__ */ import_react43.default.createElement(import_react_hook_form.Controller, {
|
|
7622
7670
|
control: control,
|
|
7623
7671
|
name: "password",
|
|
7624
7672
|
render: function(param) {
|
|
7625
7673
|
var field = param.field;
|
|
7626
7674
|
var _texts_password, _texts_password1, _formState_errors_password;
|
|
7627
|
-
return /* @__PURE__ */
|
|
7675
|
+
return /* @__PURE__ */ import_react43.default.createElement(Input, _object_spread({
|
|
7628
7676
|
width: "full",
|
|
7629
7677
|
autoComplete: "current-password",
|
|
7630
7678
|
type: passwordVisible ? "text" : "password",
|
|
7631
7679
|
label: texts === null || texts === void 0 ? void 0 : (_texts_password = texts.password) === null || _texts_password === void 0 ? void 0 : _texts_password.label,
|
|
7632
|
-
iconInside: /* @__PURE__ */
|
|
7680
|
+
iconInside: /* @__PURE__ */ import_react43.default.createElement("div", {
|
|
7633
7681
|
className: "hawa-cursor-pointer",
|
|
7634
7682
|
onClick: function() {
|
|
7635
7683
|
return setPasswordVisible(!passwordVisible);
|
|
7636
7684
|
}
|
|
7637
|
-
}, passwordVisible ? /* @__PURE__ */
|
|
7685
|
+
}, passwordVisible ? /* @__PURE__ */ import_react43.default.createElement(EyeIcon, {
|
|
7638
7686
|
classNames: "hawa-text-gray-500"
|
|
7639
|
-
}) : /* @__PURE__ */
|
|
7687
|
+
}) : /* @__PURE__ */ import_react43.default.createElement(HiddenEyeIcon, {
|
|
7640
7688
|
classNames: "hawa-text-gray-500"
|
|
7641
7689
|
}), " "),
|
|
7642
7690
|
placeholder: (texts === null || texts === void 0 ? void 0 : (_texts_password1 = texts.password) === null || _texts_password1 === void 0 ? void 0 : _texts_password1.placeholder) || "Enter your password",
|
|
7643
7691
|
helperText: (_formState_errors_password = formState.errors.password) === null || _formState_errors_password === void 0 ? void 0 : _formState_errors_password.message
|
|
7644
7692
|
}, field));
|
|
7645
7693
|
}
|
|
7646
|
-
}), !props.withoutResetPassword && /* @__PURE__ */
|
|
7694
|
+
}), !props.withoutResetPassword && /* @__PURE__ */ import_react43.default.createElement("div", {
|
|
7647
7695
|
onClick: props.onForgotPassword,
|
|
7648
7696
|
className: "hawa-mb-3 hawa-select-none hawa-mt-2 hawa-w-fit hawa-cursor-pointer hawa-text-xs dark:hawa-text-gray-300"
|
|
7649
7697
|
}, (texts === null || texts === void 0 ? void 0 : texts.forgotPassword) || "Forgot Password?")));
|
|
7650
7698
|
case "phone":
|
|
7651
|
-
return /* @__PURE__ */
|
|
7699
|
+
return /* @__PURE__ */ import_react43.default.createElement(import_react43.default.Fragment, null, /* @__PURE__ */ import_react43.default.createElement(import_react_hook_form.Controller, {
|
|
7652
7700
|
control: control,
|
|
7653
7701
|
name: "phone",
|
|
7654
7702
|
render: function(param) {
|
|
7655
7703
|
var field = param.field;
|
|
7656
7704
|
var _texts_phone, _formState_errors_phone;
|
|
7657
|
-
return /* @__PURE__ */
|
|
7705
|
+
return /* @__PURE__ */ import_react43.default.createElement(PhoneInput, {
|
|
7658
7706
|
label: texts === null || texts === void 0 ? void 0 : (_texts_phone = texts.phone) === null || _texts_phone === void 0 ? void 0 : _texts_phone.label,
|
|
7659
7707
|
helperText: (_formState_errors_phone = formState.errors.phone) === null || _formState_errors_phone === void 0 ? void 0 : _formState_errors_phone.message,
|
|
7660
7708
|
preferredCountry: {
|
|
@@ -7667,13 +7715,13 @@ var LoginForm = function(_param) {
|
|
|
7667
7715
|
}
|
|
7668
7716
|
}));
|
|
7669
7717
|
case "link":
|
|
7670
|
-
return /* @__PURE__ */
|
|
7718
|
+
return /* @__PURE__ */ import_react43.default.createElement(import_react43.default.Fragment, null, /* @__PURE__ */ import_react43.default.createElement(import_react_hook_form.Controller, {
|
|
7671
7719
|
control: control,
|
|
7672
7720
|
name: "email",
|
|
7673
7721
|
render: function(param) {
|
|
7674
7722
|
var field = param.field;
|
|
7675
7723
|
var _texts_email, _formState_errors_email, _texts_email1;
|
|
7676
|
-
return /* @__PURE__ */
|
|
7724
|
+
return /* @__PURE__ */ import_react43.default.createElement(Input, _object_spread({
|
|
7677
7725
|
width: "full",
|
|
7678
7726
|
autoComplete: "email",
|
|
7679
7727
|
label: (texts === null || texts === void 0 ? void 0 : (_texts_email = texts.email) === null || _texts_email === void 0 ? void 0 : _texts_email.label) || "Email",
|
|
@@ -7686,17 +7734,17 @@ var LoginForm = function(_param) {
|
|
|
7686
7734
|
break;
|
|
7687
7735
|
}
|
|
7688
7736
|
};
|
|
7689
|
-
return /* @__PURE__ */
|
|
7737
|
+
return /* @__PURE__ */ import_react43.default.createElement("div", {
|
|
7690
7738
|
className: "hawa-flex hawa-flex-col hawa-gap-4"
|
|
7691
|
-
}, /* @__PURE__ */
|
|
7739
|
+
}, /* @__PURE__ */ import_react43.default.createElement(Card, {
|
|
7692
7740
|
dir: props.direction
|
|
7693
|
-
}, /* @__PURE__ */
|
|
7741
|
+
}, /* @__PURE__ */ import_react43.default.createElement(CardContent, {
|
|
7694
7742
|
headless: true
|
|
7695
|
-
}, props.showError && /* @__PURE__ */
|
|
7743
|
+
}, props.showError && /* @__PURE__ */ import_react43.default.createElement(Alert, {
|
|
7696
7744
|
title: props.errorTitle,
|
|
7697
7745
|
text: props.errorText,
|
|
7698
7746
|
severity: "error"
|
|
7699
|
-
}), /* @__PURE__ */
|
|
7747
|
+
}), /* @__PURE__ */ import_react43.default.createElement("form", {
|
|
7700
7748
|
noValidate: true,
|
|
7701
7749
|
className: "hawa-flex hawa-flex-col hawa-gap-4",
|
|
7702
7750
|
onSubmit: handleSubmit(function(e) {
|
|
@@ -7706,18 +7754,18 @@ var LoginForm = function(_param) {
|
|
|
7706
7754
|
console.log("Form is submitted but onLogin prop is missing");
|
|
7707
7755
|
}
|
|
7708
7756
|
})
|
|
7709
|
-
}, renderFields(), /* @__PURE__ */
|
|
7757
|
+
}, renderFields(), /* @__PURE__ */ import_react43.default.createElement(Button, {
|
|
7710
7758
|
className: "hawa-mt-0 hawa-w-full",
|
|
7711
7759
|
type: "submit",
|
|
7712
7760
|
isLoading: props.isLoading
|
|
7713
|
-
}, (texts === null || texts === void 0 ? void 0 : texts.loginText) || "Login"), props.additionalButtons, props.allowRegister && /* @__PURE__ */
|
|
7761
|
+
}, (texts === null || texts === void 0 ? void 0 : texts.loginText) || "Login"), props.additionalButtons, props.allowRegister && /* @__PURE__ */ import_react43.default.createElement("div", {
|
|
7714
7762
|
className: "hawa-p-3 hawa-text-center hawa-text-sm hawa-font-normal hawa-select-none dark:hawa-text-gray-300"
|
|
7715
|
-
}, (texts === null || texts === void 0 ? void 0 : texts.newUserText) || "New user?", " ", /* @__PURE__ */
|
|
7763
|
+
}, (texts === null || texts === void 0 ? void 0 : texts.newUserText) || "New user?", " ", /* @__PURE__ */ import_react43.default.createElement("span", {
|
|
7716
7764
|
onClick: props.onRouteToRegister,
|
|
7717
7765
|
className: "clickable-link"
|
|
7718
|
-
}, (texts === null || texts === void 0 ? void 0 : texts.createAccount) || "Create Account")))), props.viaGithub || props.viaGoogle || props.viaTwitter ? /* @__PURE__ */
|
|
7766
|
+
}, (texts === null || texts === void 0 ? void 0 : texts.createAccount) || "Create Account")))), props.viaGithub || props.viaGoogle || props.viaTwitter ? /* @__PURE__ */ import_react43.default.createElement(CardFooter, {
|
|
7719
7767
|
className: cn(props.logosOnly ? "hawa-flex hawa-flex-row hawa-justify-center hawa-gap-2" : "hawa-grid hawa-grid-cols-1 hawa-gap-2")
|
|
7720
|
-
}, /* @__PURE__ */
|
|
7768
|
+
}, /* @__PURE__ */ import_react43.default.createElement(AuthButtons, {
|
|
7721
7769
|
texts: thirdPartyAuthTexts,
|
|
7722
7770
|
viaGoogle: props.viaGoogle,
|
|
7723
7771
|
viaGithub: props.viaGithub,
|
|
@@ -7725,7 +7773,7 @@ var LoginForm = function(_param) {
|
|
|
7725
7773
|
handleGoogle: props.onGoogleLogin,
|
|
7726
7774
|
handleGithub: props.onGithubLogin,
|
|
7727
7775
|
handleTwitter: props.onTwitterLogin
|
|
7728
|
-
})) : null), props.handleColorMode && props.handleLanguage && /* @__PURE__ */
|
|
7776
|
+
})) : null), props.handleColorMode && props.handleLanguage && /* @__PURE__ */ import_react43.default.createElement(InterfaceSettings, {
|
|
7729
7777
|
currentColorMode: props.currentColorMode,
|
|
7730
7778
|
currentLanguage: props.currentLanguage,
|
|
7731
7779
|
handleColorMode: props.handleColorMode,
|
|
@@ -7733,7 +7781,7 @@ var LoginForm = function(_param) {
|
|
|
7733
7781
|
}));
|
|
7734
7782
|
};
|
|
7735
7783
|
// components/blocks/auth/RegisterForm.tsx
|
|
7736
|
-
var
|
|
7784
|
+
var import_react44 = __toESM(require("react"));
|
|
7737
7785
|
var import_react_hook_form2 = require("react-hook-form");
|
|
7738
7786
|
var import_zod2 = require("@hookform/resolvers/zod");
|
|
7739
7787
|
var z2 = __toESM(require("zod"));
|
|
@@ -7742,7 +7790,7 @@ var RegisterForm = function(_param) {
|
|
|
7742
7790
|
"texts"
|
|
7743
7791
|
]);
|
|
7744
7792
|
var _texts_password, _texts_password1, _texts_password2, _texts_confirm, _texts_password3, _texts_confirm1;
|
|
7745
|
-
var _ref = _sliced_to_array((0,
|
|
7793
|
+
var _ref = _sliced_to_array((0, import_react44.useState)(false), 2), passwordVisible = _ref[0], setPasswordVisible = _ref[1];
|
|
7746
7794
|
var thirdPartyAuthTexts = {
|
|
7747
7795
|
continueWithGoogle: texts === null || texts === void 0 ? void 0 : texts.continueWithGoogle,
|
|
7748
7796
|
continueWithTwitter: texts === null || texts === void 0 ? void 0 : texts.continueWithTwitter,
|
|
@@ -7822,17 +7870,17 @@ var RegisterForm = function(_param) {
|
|
|
7822
7870
|
var _ref1 = (0, import_react_hook_form2.useForm)({
|
|
7823
7871
|
resolver: (0, import_zod2.zodResolver)(formSchema)
|
|
7824
7872
|
}), handleSubmit = _ref1.handleSubmit, control = _ref1.control, formState = _ref1.formState;
|
|
7825
|
-
return /* @__PURE__ */
|
|
7873
|
+
return /* @__PURE__ */ import_react44.default.createElement("div", {
|
|
7826
7874
|
className: "hawa-flex hawa-flex-col hawa-gap-4"
|
|
7827
|
-
}, /* @__PURE__ */
|
|
7875
|
+
}, /* @__PURE__ */ import_react44.default.createElement(Card, {
|
|
7828
7876
|
dir: props.direction
|
|
7829
|
-
}, /* @__PURE__ */
|
|
7877
|
+
}, /* @__PURE__ */ import_react44.default.createElement(CardContent, {
|
|
7830
7878
|
headless: true
|
|
7831
|
-
}, /* @__PURE__ */
|
|
7879
|
+
}, /* @__PURE__ */ import_react44.default.createElement("div", null, props.showError && /* @__PURE__ */ import_react44.default.createElement(Alert, {
|
|
7832
7880
|
title: props.errorTitle,
|
|
7833
7881
|
text: props.errorText,
|
|
7834
7882
|
severity: "error"
|
|
7835
|
-
}), /* @__PURE__ */
|
|
7883
|
+
}), /* @__PURE__ */ import_react44.default.createElement(import_react_hook_form2.FormProvider, _object_spread({}, methods), /* @__PURE__ */ import_react44.default.createElement("form", {
|
|
7836
7884
|
noValidate: true,
|
|
7837
7885
|
onSubmit: handleSubmit(function(e) {
|
|
7838
7886
|
if (props.onRegister) {
|
|
@@ -7842,18 +7890,18 @@ var RegisterForm = function(_param) {
|
|
|
7842
7890
|
}
|
|
7843
7891
|
}),
|
|
7844
7892
|
className: "hawa-flex hawa-flex-col hawa-gap-4"
|
|
7845
|
-
}, /* @__PURE__ */
|
|
7893
|
+
}, /* @__PURE__ */ import_react44.default.createElement("div", {
|
|
7846
7894
|
className: "hawa-flex hawa-flex-col hawa-gap-4"
|
|
7847
7895
|
}, props.registerFields.map(function(fld, i) {
|
|
7848
7896
|
if (fld === "fullname") {
|
|
7849
|
-
return /* @__PURE__ */
|
|
7897
|
+
return /* @__PURE__ */ import_react44.default.createElement(import_react_hook_form2.Controller, {
|
|
7850
7898
|
key: i,
|
|
7851
7899
|
control: control,
|
|
7852
7900
|
name: "fullName",
|
|
7853
7901
|
render: function(param) {
|
|
7854
7902
|
var field = param.field;
|
|
7855
7903
|
var _texts_fullName, _texts_fullName1, _formState_errors_fullName;
|
|
7856
|
-
return /* @__PURE__ */
|
|
7904
|
+
return /* @__PURE__ */ import_react44.default.createElement(Input, _object_spread({
|
|
7857
7905
|
width: "full",
|
|
7858
7906
|
label: texts === null || texts === void 0 ? void 0 : (_texts_fullName = texts.fullName) === null || _texts_fullName === void 0 ? void 0 : _texts_fullName.label,
|
|
7859
7907
|
placeholder: texts === null || texts === void 0 ? void 0 : (_texts_fullName1 = texts.fullName) === null || _texts_fullName1 === void 0 ? void 0 : _texts_fullName1.placeholder,
|
|
@@ -7863,14 +7911,14 @@ var RegisterForm = function(_param) {
|
|
|
7863
7911
|
});
|
|
7864
7912
|
}
|
|
7865
7913
|
if (fld === "email") {
|
|
7866
|
-
return /* @__PURE__ */
|
|
7914
|
+
return /* @__PURE__ */ import_react44.default.createElement(import_react_hook_form2.Controller, {
|
|
7867
7915
|
key: i,
|
|
7868
7916
|
control: control,
|
|
7869
7917
|
name: "email",
|
|
7870
7918
|
render: function(param) {
|
|
7871
7919
|
var field = param.field;
|
|
7872
7920
|
var _texts_email, _formState_errors_email, _texts_email1;
|
|
7873
|
-
return /* @__PURE__ */
|
|
7921
|
+
return /* @__PURE__ */ import_react44.default.createElement(Input, _object_spread({
|
|
7874
7922
|
width: "full",
|
|
7875
7923
|
autoComplete: "email",
|
|
7876
7924
|
label: texts === null || texts === void 0 ? void 0 : (_texts_email = texts.email) === null || _texts_email === void 0 ? void 0 : _texts_email.label,
|
|
@@ -7881,14 +7929,14 @@ var RegisterForm = function(_param) {
|
|
|
7881
7929
|
});
|
|
7882
7930
|
}
|
|
7883
7931
|
if (fld === "username") {
|
|
7884
|
-
return /* @__PURE__ */
|
|
7932
|
+
return /* @__PURE__ */ import_react44.default.createElement(import_react_hook_form2.Controller, {
|
|
7885
7933
|
key: i,
|
|
7886
7934
|
control: control,
|
|
7887
7935
|
name: "username",
|
|
7888
7936
|
render: function(param) {
|
|
7889
7937
|
var field = param.field;
|
|
7890
7938
|
var _texts_username, _formState_errors_username, _texts_username1;
|
|
7891
|
-
return /* @__PURE__ */
|
|
7939
|
+
return /* @__PURE__ */ import_react44.default.createElement(Input, _object_spread({
|
|
7892
7940
|
width: "full",
|
|
7893
7941
|
autoComplete: "username",
|
|
7894
7942
|
label: texts === null || texts === void 0 ? void 0 : (_texts_username = texts.username) === null || _texts_username === void 0 ? void 0 : _texts_username.label,
|
|
@@ -7898,23 +7946,23 @@ var RegisterForm = function(_param) {
|
|
|
7898
7946
|
}
|
|
7899
7947
|
});
|
|
7900
7948
|
}
|
|
7901
|
-
})), /* @__PURE__ */
|
|
7949
|
+
})), /* @__PURE__ */ import_react44.default.createElement(import_react_hook_form2.Controller, {
|
|
7902
7950
|
control: control,
|
|
7903
7951
|
name: "password",
|
|
7904
7952
|
render: function(param) {
|
|
7905
7953
|
var field = param.field;
|
|
7906
7954
|
var _texts_password, _texts_password1, _formState_errors_password;
|
|
7907
|
-
return /* @__PURE__ */
|
|
7955
|
+
return /* @__PURE__ */ import_react44.default.createElement(Input, _object_spread({
|
|
7908
7956
|
width: "full",
|
|
7909
7957
|
type: passwordVisible ? "text" : "password",
|
|
7910
|
-
iconInside: /* @__PURE__ */
|
|
7958
|
+
iconInside: /* @__PURE__ */ import_react44.default.createElement("div", {
|
|
7911
7959
|
className: "hawa-cursor-pointer",
|
|
7912
7960
|
onClick: function() {
|
|
7913
7961
|
return setPasswordVisible(!passwordVisible);
|
|
7914
7962
|
}
|
|
7915
|
-
}, passwordVisible ? /* @__PURE__ */
|
|
7963
|
+
}, passwordVisible ? /* @__PURE__ */ import_react44.default.createElement(EyeIcon, {
|
|
7916
7964
|
classNames: "hawa-text-gray-500"
|
|
7917
|
-
}) : /* @__PURE__ */
|
|
7965
|
+
}) : /* @__PURE__ */ import_react44.default.createElement(HiddenEyeIcon, {
|
|
7918
7966
|
classNames: "hawa-text-gray-500"
|
|
7919
7967
|
}), " "),
|
|
7920
7968
|
autoComplete: "new-password",
|
|
@@ -7923,13 +7971,13 @@ var RegisterForm = function(_param) {
|
|
|
7923
7971
|
helperText: (_formState_errors_password = formState.errors.password) === null || _formState_errors_password === void 0 ? void 0 : _formState_errors_password.message
|
|
7924
7972
|
}, field));
|
|
7925
7973
|
}
|
|
7926
|
-
}), /* @__PURE__ */
|
|
7974
|
+
}), /* @__PURE__ */ import_react44.default.createElement(import_react_hook_form2.Controller, {
|
|
7927
7975
|
control: control,
|
|
7928
7976
|
name: "confirm_password",
|
|
7929
7977
|
render: function(param) {
|
|
7930
7978
|
var field = param.field;
|
|
7931
7979
|
var _texts_confirm, _texts_confirm1, _formState_errors_confirm_password;
|
|
7932
|
-
return /* @__PURE__ */
|
|
7980
|
+
return /* @__PURE__ */ import_react44.default.createElement(Input, _object_spread({
|
|
7933
7981
|
width: "full",
|
|
7934
7982
|
type: "password",
|
|
7935
7983
|
autoComplete: "new-password",
|
|
@@ -7938,25 +7986,25 @@ var RegisterForm = function(_param) {
|
|
|
7938
7986
|
helperText: (_formState_errors_confirm_password = formState.errors.confirm_password) === null || _formState_errors_confirm_password === void 0 ? void 0 : _formState_errors_confirm_password.message
|
|
7939
7987
|
}, field));
|
|
7940
7988
|
}
|
|
7941
|
-
}), props.additionalInputs, props.showRefCode && /* @__PURE__ */
|
|
7989
|
+
}), props.additionalInputs, props.showRefCode && /* @__PURE__ */ import_react44.default.createElement(import_react_hook_form2.Controller, {
|
|
7942
7990
|
control: control,
|
|
7943
7991
|
name: "refCode",
|
|
7944
7992
|
render: function(param) {
|
|
7945
7993
|
var field = param.field;
|
|
7946
7994
|
var _formState_errors_refCode;
|
|
7947
|
-
return /* @__PURE__ */
|
|
7995
|
+
return /* @__PURE__ */ import_react44.default.createElement(Input, _object_spread({
|
|
7948
7996
|
width: "full",
|
|
7949
7997
|
label: texts === null || texts === void 0 ? void 0 : texts.refCode,
|
|
7950
7998
|
placeholder: (texts === null || texts === void 0 ? void 0 : texts.refCodePlaceholder) || "Enter the referral code",
|
|
7951
7999
|
helperText: (_formState_errors_refCode = formState.errors.refCode) === null || _formState_errors_refCode === void 0 ? void 0 : _formState_errors_refCode.message
|
|
7952
8000
|
}, field));
|
|
7953
8001
|
}
|
|
7954
|
-
}), props.showUserSource && /* @__PURE__ */
|
|
8002
|
+
}), props.showUserSource && /* @__PURE__ */ import_react44.default.createElement(import_react_hook_form2.Controller, {
|
|
7955
8003
|
control: control,
|
|
7956
8004
|
name: "reference",
|
|
7957
8005
|
render: function(param) {
|
|
7958
8006
|
var field = param.field;
|
|
7959
|
-
return /* @__PURE__ */
|
|
8007
|
+
return /* @__PURE__ */ import_react44.default.createElement(Select, {
|
|
7960
8008
|
label: (texts === null || texts === void 0 ? void 0 : texts.userReference.label) || "How did you learn about us?",
|
|
7961
8009
|
placeholder: texts === null || texts === void 0 ? void 0 : texts.userReference.placeholder,
|
|
7962
8010
|
isCreatable: false,
|
|
@@ -7969,50 +8017,50 @@ var RegisterForm = function(_param) {
|
|
|
7969
8017
|
}
|
|
7970
8018
|
});
|
|
7971
8019
|
}
|
|
7972
|
-
}), /* @__PURE__ */
|
|
8020
|
+
}), /* @__PURE__ */ import_react44.default.createElement("div", {
|
|
7973
8021
|
className: "hawa-flex hawa-flex-col hawa-gap-3"
|
|
7974
|
-
}, props.showTermsOption && /* @__PURE__ */
|
|
8022
|
+
}, props.showTermsOption && /* @__PURE__ */ import_react44.default.createElement(import_react_hook_form2.Controller, {
|
|
7975
8023
|
control: control,
|
|
7976
8024
|
name: "terms_accepted",
|
|
7977
8025
|
render: function(param) {
|
|
7978
8026
|
var field = param.field;
|
|
7979
8027
|
var _formState_errors_terms_accepted_message, _formState_errors_terms_accepted;
|
|
7980
|
-
return /* @__PURE__ */
|
|
8028
|
+
return /* @__PURE__ */ import_react44.default.createElement(Checkbox, {
|
|
7981
8029
|
id: "terms_accepted",
|
|
7982
8030
|
helperText: (_formState_errors_terms_accepted = formState.errors.terms_accepted) === null || _formState_errors_terms_accepted === void 0 ? void 0 : (_formState_errors_terms_accepted_message = _formState_errors_terms_accepted.message) === null || _formState_errors_terms_accepted_message === void 0 ? void 0 : _formState_errors_terms_accepted_message.toString(),
|
|
7983
8031
|
onCheckedChange: function(e) {
|
|
7984
8032
|
return field.onChange(e);
|
|
7985
8033
|
},
|
|
7986
|
-
label: /* @__PURE__ */
|
|
8034
|
+
label: /* @__PURE__ */ import_react44.default.createElement("div", {
|
|
7987
8035
|
className: "hawa-flex hawa-flex-row hawa-gap-0.5"
|
|
7988
|
-
}, /* @__PURE__ */
|
|
8036
|
+
}, /* @__PURE__ */ import_react44.default.createElement("span", null, texts === null || texts === void 0 ? void 0 : texts.iAcceptText), " ", /* @__PURE__ */ import_react44.default.createElement(StopPropagationWrapper, null, /* @__PURE__ */ import_react44.default.createElement("a", {
|
|
7989
8037
|
onClick: props.onRouteToTOS,
|
|
7990
8038
|
className: "clickable-link"
|
|
7991
8039
|
}, texts === null || texts === void 0 ? void 0 : texts.termsText)))
|
|
7992
8040
|
});
|
|
7993
8041
|
}
|
|
7994
|
-
}), props.showNewsletterOption && /* @__PURE__ */
|
|
8042
|
+
}), props.showNewsletterOption && /* @__PURE__ */ import_react44.default.createElement(import_react_hook_form2.Controller, {
|
|
7995
8043
|
control: control,
|
|
7996
8044
|
name: "newsletter_accepted",
|
|
7997
8045
|
render: function(param) {
|
|
7998
8046
|
var field = param.field;
|
|
7999
|
-
return /* @__PURE__ */
|
|
8047
|
+
return /* @__PURE__ */ import_react44.default.createElement(Checkbox, {
|
|
8000
8048
|
id: "newsletter_accepted",
|
|
8001
8049
|
label: texts === null || texts === void 0 ? void 0 : texts.subscribeToNewsletter,
|
|
8002
8050
|
onCheckedChange: field.onChange
|
|
8003
8051
|
});
|
|
8004
8052
|
}
|
|
8005
|
-
})), /* @__PURE__ */
|
|
8053
|
+
})), /* @__PURE__ */ import_react44.default.createElement(Button, {
|
|
8006
8054
|
isLoading: props.isLoading,
|
|
8007
8055
|
className: "hawa-w-full hawa-mt-4"
|
|
8008
|
-
}, texts === null || texts === void 0 ? void 0 : texts.registerText), props.additionalButtons)), /* @__PURE__ */
|
|
8056
|
+
}, texts === null || texts === void 0 ? void 0 : texts.registerText), props.additionalButtons)), /* @__PURE__ */ import_react44.default.createElement("div", {
|
|
8009
8057
|
className: "hawa-flex hawa-flex-row hawa-items-center hawa-justify-center hawa-gap-1 hawa-p-3 hawa-text-center hawa-text-sm hawa-font-normal dark:hawa-text-white"
|
|
8010
|
-
}, /* @__PURE__ */
|
|
8058
|
+
}, /* @__PURE__ */ import_react44.default.createElement("span", null, texts === null || texts === void 0 ? void 0 : texts.existingUserText), /* @__PURE__ */ import_react44.default.createElement("span", {
|
|
8011
8059
|
onClick: props.onRouteToLogin,
|
|
8012
8060
|
className: "clickable-link"
|
|
8013
|
-
}, (texts === null || texts === void 0 ? void 0 : texts.loginText) || "Login")))), props.viaGithub || props.viaGoogle || props.viaTwitter ? /* @__PURE__ */
|
|
8061
|
+
}, (texts === null || texts === void 0 ? void 0 : texts.loginText) || "Login")))), props.viaGithub || props.viaGoogle || props.viaTwitter ? /* @__PURE__ */ import_react44.default.createElement(CardFooter, {
|
|
8014
8062
|
className: cn(props.logosOnly ? "hawa-flex hawa-flex-row hawa-justify-center hawa-gap-2" : "hawa-grid hawa-grid-cols-1 hawa-gap-2")
|
|
8015
|
-
}, /* @__PURE__ */
|
|
8063
|
+
}, /* @__PURE__ */ import_react44.default.createElement(AuthButtons, {
|
|
8016
8064
|
texts: thirdPartyAuthTexts,
|
|
8017
8065
|
viaGoogle: props.viaGoogle,
|
|
8018
8066
|
viaGithub: props.viaGithub,
|
|
@@ -8020,7 +8068,7 @@ var RegisterForm = function(_param) {
|
|
|
8020
8068
|
handleGoogle: props.onGoogleRegister,
|
|
8021
8069
|
handleGithub: props.onGithubRegister,
|
|
8022
8070
|
handleTwitter: props.onTwitterRegister
|
|
8023
|
-
})) : null), props.handleColorMode && props.handleLanguage && /* @__PURE__ */
|
|
8071
|
+
})) : null), props.handleColorMode && props.handleLanguage && /* @__PURE__ */ import_react44.default.createElement(InterfaceSettings, {
|
|
8024
8072
|
currentColorMode: props.currentColorMode,
|
|
8025
8073
|
currentLanguage: props.currentLanguage,
|
|
8026
8074
|
handleColorMode: props.handleColorMode,
|
|
@@ -8028,7 +8076,7 @@ var RegisterForm = function(_param) {
|
|
|
8028
8076
|
}));
|
|
8029
8077
|
};
|
|
8030
8078
|
// components/blocks/auth/AppLanding.tsx
|
|
8031
|
-
var
|
|
8079
|
+
var import_react45 = __toESM(require("react"));
|
|
8032
8080
|
var AppLanding = function(_param) {
|
|
8033
8081
|
var texts = _param.texts, props = _object_without_properties(_param, [
|
|
8034
8082
|
"texts"
|
|
@@ -8042,12 +8090,12 @@ var AppLanding = function(_param) {
|
|
|
8042
8090
|
continueWithEmail: texts === null || texts === void 0 ? void 0 : texts.continueWithEmail,
|
|
8043
8091
|
continueWithPhone: texts === null || texts === void 0 ? void 0 : texts.continueWithPhone
|
|
8044
8092
|
};
|
|
8045
|
-
return /* @__PURE__ */
|
|
8093
|
+
return /* @__PURE__ */ import_react45.default.createElement("div", {
|
|
8046
8094
|
dir: props.direction
|
|
8047
|
-
}, /* @__PURE__ */
|
|
8095
|
+
}, /* @__PURE__ */ import_react45.default.createElement(Card, null, /* @__PURE__ */ import_react45.default.createElement(CardContent, {
|
|
8048
8096
|
headless: true,
|
|
8049
8097
|
className: "hawa-flex hawa-flex-col hawa-gap-6"
|
|
8050
|
-
}, /* @__PURE__ */
|
|
8098
|
+
}, /* @__PURE__ */ import_react45.default.createElement(AuthButtons, {
|
|
8051
8099
|
texts: thirdPartyAuthTexts,
|
|
8052
8100
|
viaApple: props.viaApple,
|
|
8053
8101
|
viaGoogle: props.viaGoogle,
|
|
@@ -8064,14 +8112,14 @@ var AppLanding = function(_param) {
|
|
|
8064
8112
|
handleEmail: props.handleEmail,
|
|
8065
8113
|
handlePhone: props.handlePhone
|
|
8066
8114
|
}), !props.withoutSignUp && //TODO: change to "register"
|
|
8067
|
-
/* @__PURE__ */
|
|
8115
|
+
/* @__PURE__ */ import_react45.default.createElement("div", {
|
|
8068
8116
|
className: "hawa-p-3 hawa-text-center hawa-text-sm hawa-font-normal dark:hawa-text-gray-300"
|
|
8069
|
-
}, texts === null || texts === void 0 ? void 0 : texts.newUserText, " ", /* @__PURE__ */
|
|
8117
|
+
}, texts === null || texts === void 0 ? void 0 : texts.newUserText, " ", /* @__PURE__ */ import_react45.default.createElement("span", {
|
|
8070
8118
|
onClick: props.handleRouteToRegister,
|
|
8071
8119
|
className: "clickable-link"
|
|
8072
|
-
}, texts === null || texts === void 0 ? void 0 : texts.createAccount)))), /* @__PURE__ */
|
|
8120
|
+
}, texts === null || texts === void 0 ? void 0 : texts.createAccount)))), /* @__PURE__ */ import_react45.default.createElement("div", {
|
|
8073
8121
|
className: "hawa-mt-4 hawa-flex hawa-flex-row hawa-justify-between"
|
|
8074
|
-
}, /* @__PURE__ */
|
|
8122
|
+
}, /* @__PURE__ */ import_react45.default.createElement(Radio, {
|
|
8075
8123
|
onChangeTab: props.handleLanguage,
|
|
8076
8124
|
design: "tabs",
|
|
8077
8125
|
options: [
|
|
@@ -8084,20 +8132,20 @@ var AppLanding = function(_param) {
|
|
|
8084
8132
|
label: "English"
|
|
8085
8133
|
}
|
|
8086
8134
|
]
|
|
8087
|
-
}), /* @__PURE__ */
|
|
8135
|
+
}), /* @__PURE__ */ import_react45.default.createElement(Radio, {
|
|
8088
8136
|
onChangeTab: props.handleColorMode,
|
|
8089
8137
|
design: "tabs",
|
|
8090
8138
|
options: [
|
|
8091
8139
|
{
|
|
8092
8140
|
value: "light",
|
|
8093
|
-
label: /* @__PURE__ */
|
|
8141
|
+
label: /* @__PURE__ */ import_react45.default.createElement("svg", {
|
|
8094
8142
|
width: "15",
|
|
8095
8143
|
height: "15",
|
|
8096
8144
|
viewBox: "0 0 15 15",
|
|
8097
8145
|
fill: "none",
|
|
8098
8146
|
xmlns: "http://www.w3.org/2000/svg",
|
|
8099
8147
|
className: "hawa-h-[1.2rem] hawa-w-[1.2rem] hawa-rotate-0 hawa-scale-100 hawa-transition-all dark:hawa--rotate-90"
|
|
8100
|
-
}, /* @__PURE__ */
|
|
8148
|
+
}, /* @__PURE__ */ import_react45.default.createElement("path", {
|
|
8101
8149
|
d: "M7.5 0C7.77614 0 8 0.223858 8 0.5V2.5C8 2.77614 7.77614 3 7.5 3C7.22386 3 7 2.77614 7 2.5V0.5C7 0.223858 7.22386 0 7.5 0ZM2.1967 2.1967C2.39196 2.00144 2.70854 2.00144 2.90381 2.1967L4.31802 3.61091C4.51328 3.80617 4.51328 4.12276 4.31802 4.31802C4.12276 4.51328 3.80617 4.51328 3.61091 4.31802L2.1967 2.90381C2.00144 2.70854 2.00144 2.39196 2.1967 2.1967ZM0.5 7C0.223858 7 0 7.22386 0 7.5C0 7.77614 0.223858 8 0.5 8H2.5C2.77614 8 3 7.77614 3 7.5C3 7.22386 2.77614 7 2.5 7H0.5ZM2.1967 12.8033C2.00144 12.608 2.00144 12.2915 2.1967 12.0962L3.61091 10.682C3.80617 10.4867 4.12276 10.4867 4.31802 10.682C4.51328 10.8772 4.51328 11.1938 4.31802 11.3891L2.90381 12.8033C2.70854 12.9986 2.39196 12.9986 2.1967 12.8033ZM12.5 7C12.2239 7 12 7.22386 12 7.5C12 7.77614 12.2239 8 12.5 8H14.5C14.7761 8 15 7.77614 15 7.5C15 7.22386 14.7761 7 14.5 7H12.5ZM10.682 4.31802C10.4867 4.12276 10.4867 3.80617 10.682 3.61091L12.0962 2.1967C12.2915 2.00144 12.608 2.00144 12.8033 2.1967C12.9986 2.39196 12.9986 2.70854 12.8033 2.90381L11.3891 4.31802C11.1938 4.51328 10.8772 4.51328 10.682 4.31802ZM8 12.5C8 12.2239 7.77614 12 7.5 12C7.22386 12 7 12.2239 7 12.5V14.5C7 14.7761 7.22386 15 7.5 15C7.77614 15 8 14.7761 8 14.5V12.5ZM10.682 10.682C10.8772 10.4867 11.1938 10.4867 11.3891 10.682L12.8033 12.0962C12.9986 12.2915 12.9986 12.608 12.8033 12.8033C12.608 12.9986 12.2915 12.9986 12.0962 12.8033L10.682 11.3891C10.4867 11.1938 10.4867 10.8772 10.682 10.682ZM5.5 7.5C5.5 6.39543 6.39543 5.5 7.5 5.5C8.60457 5.5 9.5 6.39543 9.5 7.5C9.5 8.60457 8.60457 9.5 7.5 9.5C6.39543 9.5 5.5 8.60457 5.5 7.5ZM7.5 4.5C5.84315 4.5 4.5 5.84315 4.5 7.5C4.5 9.15685 5.84315 10.5 7.5 10.5C9.15685 10.5 10.5 9.15685 10.5 7.5C10.5 5.84315 9.15685 4.5 7.5 4.5Z",
|
|
8102
8150
|
fill: "currentColor",
|
|
8103
8151
|
fillRule: "evenodd",
|
|
@@ -8106,7 +8154,7 @@ var AppLanding = function(_param) {
|
|
|
8106
8154
|
},
|
|
8107
8155
|
{
|
|
8108
8156
|
value: "dark",
|
|
8109
|
-
label: /* @__PURE__ */
|
|
8157
|
+
label: /* @__PURE__ */ import_react45.default.createElement("svg", {
|
|
8110
8158
|
xmlns: "http://www.w3.org/2000/svg",
|
|
8111
8159
|
width: "24",
|
|
8112
8160
|
height: "24",
|
|
@@ -8117,7 +8165,7 @@ var AppLanding = function(_param) {
|
|
|
8117
8165
|
strokeLinecap: "round",
|
|
8118
8166
|
strokeLinejoin: "round",
|
|
8119
8167
|
className: "hawa-h-[1.2rem] hawa-w-[1.2rem] hawa-transition-all dark:hawa-rotate-0 dark:hawa-scale-100"
|
|
8120
|
-
}, /* @__PURE__ */
|
|
8168
|
+
}, /* @__PURE__ */ import_react45.default.createElement("path", {
|
|
8121
8169
|
d: "M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z"
|
|
8122
8170
|
}))
|
|
8123
8171
|
}
|
|
@@ -8125,16 +8173,16 @@ var AppLanding = function(_param) {
|
|
|
8125
8173
|
})));
|
|
8126
8174
|
};
|
|
8127
8175
|
// components/blocks/auth/CheckEmail.tsx
|
|
8128
|
-
var
|
|
8176
|
+
var import_react46 = __toESM(require("react"));
|
|
8129
8177
|
var CheckEmail = function(param) {
|
|
8130
8178
|
var texts = param.texts, handleResend = param.handleResend;
|
|
8131
|
-
return /* @__PURE__ */
|
|
8179
|
+
return /* @__PURE__ */ import_react46.default.createElement(Card, null, /* @__PURE__ */ import_react46.default.createElement(CardContent, {
|
|
8132
8180
|
headless: true
|
|
8133
|
-
}, /* @__PURE__ */
|
|
8181
|
+
}, /* @__PURE__ */ import_react46.default.createElement("div", {
|
|
8134
8182
|
className: "hawa-flex hawa-flex-col hawa-items-center hawa-justify-center hawa-text-center"
|
|
8135
|
-
}, /* @__PURE__ */
|
|
8183
|
+
}, /* @__PURE__ */ import_react46.default.createElement("div", {
|
|
8136
8184
|
className: "hawa-flex hawa-h-16 hawa-w-16 hawa-flex-col hawa-items-center hawa-justify-center hawa-rounded-3xl hawa-bg-primary hawa-text-6xl hawa-font-bold hawa-text-primary-foreground"
|
|
8137
|
-
}, /* @__PURE__ */
|
|
8185
|
+
}, /* @__PURE__ */ import_react46.default.createElement("svg", {
|
|
8138
8186
|
stroke: "currentColor",
|
|
8139
8187
|
fill: "none",
|
|
8140
8188
|
"stroke-width": "2",
|
|
@@ -8144,23 +8192,23 @@ var CheckEmail = function(param) {
|
|
|
8144
8192
|
height: "0.5em",
|
|
8145
8193
|
width: "0.5em",
|
|
8146
8194
|
xmlns: "http://www.w3.org/2000/svg"
|
|
8147
|
-
}, /* @__PURE__ */
|
|
8195
|
+
}, /* @__PURE__ */ import_react46.default.createElement("path", {
|
|
8148
8196
|
d: "M4 4h16c1.1 0 2 .9 2 2v12c0 1.1-.9 2-2 2H4c-1.1 0-2-.9-2-2V6c0-1.1.9-2 2-2z"
|
|
8149
|
-
}), /* @__PURE__ */
|
|
8197
|
+
}), /* @__PURE__ */ import_react46.default.createElement("polyline", {
|
|
8150
8198
|
points: "22,6 12,13 2,6"
|
|
8151
|
-
}))), /* @__PURE__ */
|
|
8199
|
+
}))), /* @__PURE__ */ import_react46.default.createElement("div", {
|
|
8152
8200
|
className: "hawa-m-2 hawa-text-xl hawa-font-bold"
|
|
8153
|
-
}, (texts === null || texts === void 0 ? void 0 : texts.checkEmail) || "Check your Email"), /* @__PURE__ */
|
|
8201
|
+
}, (texts === null || texts === void 0 ? void 0 : texts.checkEmail) || "Check your Email"), /* @__PURE__ */ import_react46.default.createElement("div", {
|
|
8154
8202
|
className: "hawa-text-sm"
|
|
8155
|
-
}, (texts === null || texts === void 0 ? void 0 : texts.pleaseVerify) || "Thank you for signing up! To complete your registration, we've sent a verification email to the address you provided. Please check your inbox and follow the instructions in the email to activate your account."))), /* @__PURE__ */
|
|
8203
|
+
}, (texts === null || texts === void 0 ? void 0 : texts.pleaseVerify) || "Thank you for signing up! To complete your registration, we've sent a verification email to the address you provided. Please check your inbox and follow the instructions in the email to activate your account."))), /* @__PURE__ */ import_react46.default.createElement(CardFooter, {
|
|
8156
8204
|
className: "hawa-flex hawa-flex-col hawa-justify-center "
|
|
8157
|
-
}, /* @__PURE__ */
|
|
8205
|
+
}, /* @__PURE__ */ import_react46.default.createElement("span", {
|
|
8158
8206
|
className: "clickable-link hawa-text-sm",
|
|
8159
8207
|
onClick: handleResend
|
|
8160
8208
|
}, (texts === null || texts === void 0 ? void 0 : texts.resendEmail) || "Resend Email")));
|
|
8161
8209
|
};
|
|
8162
8210
|
// components/blocks/auth/NewPassword.tsx
|
|
8163
|
-
var
|
|
8211
|
+
var import_react47 = __toESM(require("react"));
|
|
8164
8212
|
var import_react_hook_form3 = require("react-hook-form");
|
|
8165
8213
|
var import_zod3 = require("@hookform/resolvers/zod");
|
|
8166
8214
|
var z3 = __toESM(require("zod"));
|
|
@@ -8195,18 +8243,18 @@ var NewPasswordForm = function(_param) {
|
|
|
8195
8243
|
var _ref = (0, import_react_hook_form3.useForm)({
|
|
8196
8244
|
resolver: (0, import_zod3.zodResolver)(formSchema)
|
|
8197
8245
|
}), handleSubmit = _ref.handleSubmit, control = _ref.control, formState = _ref.formState;
|
|
8198
|
-
var _ref1 = _sliced_to_array((0,
|
|
8246
|
+
var _ref1 = _sliced_to_array((0, import_react47.useState)(false), 2), matchError = _ref1[0], setMatchError = _ref1[1];
|
|
8199
8247
|
var _texts_dontHaveAccount, _texts_registerText;
|
|
8200
|
-
return /* @__PURE__ */
|
|
8248
|
+
return /* @__PURE__ */ import_react47.default.createElement(Card, {
|
|
8201
8249
|
dir: props.direction
|
|
8202
|
-
}, matchError && /* @__PURE__ */
|
|
8250
|
+
}, matchError && /* @__PURE__ */ import_react47.default.createElement(Alert, {
|
|
8203
8251
|
text: texts === null || texts === void 0 ? void 0 : (_texts_confirm2 = texts.confirm) === null || _texts_confirm2 === void 0 ? void 0 : _texts_confirm2.dontMatch,
|
|
8204
8252
|
severity: "error"
|
|
8205
|
-
}), props.passwordChanged ? /* @__PURE__ */
|
|
8253
|
+
}), props.passwordChanged ? /* @__PURE__ */ import_react47.default.createElement(CardContent, {
|
|
8206
8254
|
headless: true
|
|
8207
|
-
}, /* @__PURE__ */
|
|
8255
|
+
}, /* @__PURE__ */ import_react47.default.createElement("div", {
|
|
8208
8256
|
className: "hawa-text-center"
|
|
8209
|
-
}, texts === null || texts === void 0 ? void 0 : texts.passwordChanged)) : /* @__PURE__ */
|
|
8257
|
+
}, texts === null || texts === void 0 ? void 0 : texts.passwordChanged)) : /* @__PURE__ */ import_react47.default.createElement("form", {
|
|
8210
8258
|
noValidate: true,
|
|
8211
8259
|
onSubmit: handleSubmit(function(e) {
|
|
8212
8260
|
if (props.handleNewPassword) {
|
|
@@ -8215,16 +8263,16 @@ var NewPasswordForm = function(_param) {
|
|
|
8215
8263
|
console.log("Form is submitted but handleSubmission prop is missing");
|
|
8216
8264
|
}
|
|
8217
8265
|
})
|
|
8218
|
-
}, !props.headless && /* @__PURE__ */
|
|
8266
|
+
}, !props.headless && /* @__PURE__ */ import_react47.default.createElement(CardHeader, null, /* @__PURE__ */ import_react47.default.createElement(CardTitle, null, "Create Password"), /* @__PURE__ */ import_react47.default.createElement(CardDescription, null, "Set a new password for your account")), /* @__PURE__ */ import_react47.default.createElement(CardContent, {
|
|
8219
8267
|
headless: props.headless,
|
|
8220
8268
|
className: "hawa-flex hawa-flex-col hawa-gap-4"
|
|
8221
|
-
}, /* @__PURE__ */
|
|
8269
|
+
}, /* @__PURE__ */ import_react47.default.createElement(import_react_hook_form3.Controller, {
|
|
8222
8270
|
control: control,
|
|
8223
8271
|
name: "password",
|
|
8224
8272
|
render: function(param) {
|
|
8225
8273
|
var field = param.field;
|
|
8226
8274
|
var _texts_password, _texts_password1, _formState_errors_password;
|
|
8227
|
-
return /* @__PURE__ */
|
|
8275
|
+
return /* @__PURE__ */ import_react47.default.createElement(Input, _object_spread({
|
|
8228
8276
|
width: "full",
|
|
8229
8277
|
type: "password",
|
|
8230
8278
|
autoComplete: "new-password",
|
|
@@ -8233,13 +8281,13 @@ var NewPasswordForm = function(_param) {
|
|
|
8233
8281
|
helperText: (_formState_errors_password = formState.errors.password) === null || _formState_errors_password === void 0 ? void 0 : _formState_errors_password.message
|
|
8234
8282
|
}, field));
|
|
8235
8283
|
}
|
|
8236
|
-
}), /* @__PURE__ */
|
|
8284
|
+
}), /* @__PURE__ */ import_react47.default.createElement(import_react_hook_form3.Controller, {
|
|
8237
8285
|
control: control,
|
|
8238
8286
|
name: "confirm_password",
|
|
8239
8287
|
render: function(param) {
|
|
8240
8288
|
var field = param.field;
|
|
8241
8289
|
var _texts_confirm, _texts_confirm1, _formState_errors_confirm_password;
|
|
8242
|
-
return /* @__PURE__ */
|
|
8290
|
+
return /* @__PURE__ */ import_react47.default.createElement(Input, _object_spread({
|
|
8243
8291
|
width: "full",
|
|
8244
8292
|
type: "password",
|
|
8245
8293
|
autoComplete: "new-password",
|
|
@@ -8248,20 +8296,20 @@ var NewPasswordForm = function(_param) {
|
|
|
8248
8296
|
helperText: (_formState_errors_confirm_password = formState.errors.confirm_password) === null || _formState_errors_confirm_password === void 0 ? void 0 : _formState_errors_confirm_password.message
|
|
8249
8297
|
}, field));
|
|
8250
8298
|
}
|
|
8251
|
-
})), /* @__PURE__ */
|
|
8299
|
+
})), /* @__PURE__ */ import_react47.default.createElement(CardFooter, {
|
|
8252
8300
|
className: "hawa-flex hawa-flex-col"
|
|
8253
|
-
}, /* @__PURE__ */
|
|
8301
|
+
}, /* @__PURE__ */ import_react47.default.createElement(Button, {
|
|
8254
8302
|
className: "hawa-w-full",
|
|
8255
8303
|
type: "submit"
|
|
8256
|
-
}, texts === null || texts === void 0 ? void 0 : texts.updatePassword), props.allowRegister && /* @__PURE__ */
|
|
8304
|
+
}, texts === null || texts === void 0 ? void 0 : texts.updatePassword), props.allowRegister && /* @__PURE__ */ import_react47.default.createElement("div", {
|
|
8257
8305
|
className: "hawa-mt-4 hawa-pb-0 hawa-text-center hawa-text-sm dark:hawa-text-gray-300"
|
|
8258
|
-
}, (_texts_dontHaveAccount = texts === null || texts === void 0 ? void 0 : texts.dontHaveAccount) !== null && _texts_dontHaveAccount !== void 0 ? _texts_dontHaveAccount : "Don't have an account? ", /* @__PURE__ */
|
|
8306
|
+
}, (_texts_dontHaveAccount = texts === null || texts === void 0 ? void 0 : texts.dontHaveAccount) !== null && _texts_dontHaveAccount !== void 0 ? _texts_dontHaveAccount : "Don't have an account? ", /* @__PURE__ */ import_react47.default.createElement("span", {
|
|
8259
8307
|
className: "clickable-link",
|
|
8260
8308
|
onClick: props.handleRouteToRegister
|
|
8261
8309
|
}, (_texts_registerText = texts === null || texts === void 0 ? void 0 : texts.registerText) !== null && _texts_registerText !== void 0 ? _texts_registerText : "Register")))));
|
|
8262
8310
|
};
|
|
8263
8311
|
// components/blocks/auth/ResetPassword.tsx
|
|
8264
|
-
var
|
|
8312
|
+
var import_react48 = __toESM(require("react"));
|
|
8265
8313
|
var import_react_hook_form4 = require("react-hook-form");
|
|
8266
8314
|
var import_zod4 = require("@hookform/resolvers/zod");
|
|
8267
8315
|
var z4 = __toESM(require("zod"));
|
|
@@ -8280,9 +8328,9 @@ var ResetPasswordForm = function(props) {
|
|
|
8280
8328
|
resolver: (0, import_zod4.zodResolver)(formSchema)
|
|
8281
8329
|
}), handleSubmit = _ref.handleSubmit, control = _ref.control, formState = _ref.formState;
|
|
8282
8330
|
var _props_texts_dontHaveAccount, _props_texts_registerText;
|
|
8283
|
-
return /* @__PURE__ */
|
|
8331
|
+
return /* @__PURE__ */ import_react48.default.createElement(Card, {
|
|
8284
8332
|
dir: props.direction
|
|
8285
|
-
}, !props.sent ? /* @__PURE__ */
|
|
8333
|
+
}, !props.sent ? /* @__PURE__ */ import_react48.default.createElement(import_react48.default.Fragment, null, !props.headless && /* @__PURE__ */ import_react48.default.createElement(CardHeader, null, /* @__PURE__ */ import_react48.default.createElement(CardTitle, null, " ", ((_props_texts3 = props.texts) === null || _props_texts3 === void 0 ? void 0 : _props_texts3.headTitle) || "Reset Password"), /* @__PURE__ */ import_react48.default.createElement(CardDescription, null, ((_props_texts4 = props.texts) === null || _props_texts4 === void 0 ? void 0 : _props_texts4.headDescription) || "Enter your email to reset your account password")), /* @__PURE__ */ import_react48.default.createElement("form", {
|
|
8286
8334
|
noValidate: true,
|
|
8287
8335
|
onSubmit: handleSubmit(function(e) {
|
|
8288
8336
|
if (props.handleResetPassword) {
|
|
@@ -8291,39 +8339,39 @@ var ResetPasswordForm = function(props) {
|
|
|
8291
8339
|
console.log("handleResetPassword prop is missing");
|
|
8292
8340
|
}
|
|
8293
8341
|
})
|
|
8294
|
-
}, /* @__PURE__ */
|
|
8342
|
+
}, /* @__PURE__ */ import_react48.default.createElement(CardContent, {
|
|
8295
8343
|
headless: props.headless
|
|
8296
|
-
}, /* @__PURE__ */
|
|
8344
|
+
}, /* @__PURE__ */ import_react48.default.createElement(import_react_hook_form4.Controller, {
|
|
8297
8345
|
control: control,
|
|
8298
8346
|
name: "email",
|
|
8299
8347
|
render: function(param) {
|
|
8300
8348
|
var field = param.field;
|
|
8301
8349
|
var _props_texts_email, _props_texts, _formState_errors_email, _props_texts_email1, _props_texts1;
|
|
8302
|
-
return /* @__PURE__ */
|
|
8350
|
+
return /* @__PURE__ */ import_react48.default.createElement(Input, _object_spread({
|
|
8303
8351
|
width: "full",
|
|
8304
8352
|
label: (_props_texts = props.texts) === null || _props_texts === void 0 ? void 0 : (_props_texts_email = _props_texts.email) === null || _props_texts_email === void 0 ? void 0 : _props_texts_email.label,
|
|
8305
8353
|
helperText: (_formState_errors_email = formState.errors.email) === null || _formState_errors_email === void 0 ? void 0 : _formState_errors_email.message,
|
|
8306
8354
|
placeholder: (_props_texts1 = props.texts) === null || _props_texts1 === void 0 ? void 0 : (_props_texts_email1 = _props_texts1.email) === null || _props_texts_email1 === void 0 ? void 0 : _props_texts_email1.placeholder
|
|
8307
8355
|
}, field));
|
|
8308
8356
|
}
|
|
8309
|
-
})), /* @__PURE__ */
|
|
8357
|
+
})), /* @__PURE__ */ import_react48.default.createElement(CardFooter, {
|
|
8310
8358
|
className: "hawa-flex hawa-flex-col"
|
|
8311
|
-
}, /* @__PURE__ */
|
|
8359
|
+
}, /* @__PURE__ */ import_react48.default.createElement(Button, {
|
|
8312
8360
|
type: "submit",
|
|
8313
8361
|
className: "hawa-w-full"
|
|
8314
|
-
}, (_props_texts5 = props.texts) === null || _props_texts5 === void 0 ? void 0 : _props_texts5.resetPassword), props.allowRegister && /* @__PURE__ */
|
|
8362
|
+
}, (_props_texts5 = props.texts) === null || _props_texts5 === void 0 ? void 0 : _props_texts5.resetPassword), props.allowRegister && /* @__PURE__ */ import_react48.default.createElement("div", {
|
|
8315
8363
|
className: "hawa-mt-4 hawa-pb-0 hawa-text-center hawa-text-sm dark:hawa-text-gray-300"
|
|
8316
|
-
}, (_props_texts_dontHaveAccount = (_props_texts6 = props.texts) === null || _props_texts6 === void 0 ? void 0 : _props_texts6.dontHaveAccount) !== null && _props_texts_dontHaveAccount !== void 0 ? _props_texts_dontHaveAccount : "Don't have an account? ", /* @__PURE__ */
|
|
8364
|
+
}, (_props_texts_dontHaveAccount = (_props_texts6 = props.texts) === null || _props_texts6 === void 0 ? void 0 : _props_texts6.dontHaveAccount) !== null && _props_texts_dontHaveAccount !== void 0 ? _props_texts_dontHaveAccount : "Don't have an account? ", /* @__PURE__ */ import_react48.default.createElement("span", {
|
|
8317
8365
|
className: "clickable-link",
|
|
8318
8366
|
onClick: props.handleRouteToRegister
|
|
8319
|
-
}, (_props_texts_registerText = (_props_texts7 = props.texts) === null || _props_texts7 === void 0 ? void 0 : _props_texts7.registerText) !== null && _props_texts_registerText !== void 0 ? _props_texts_registerText : "Register"))))) : /* @__PURE__ */
|
|
8367
|
+
}, (_props_texts_registerText = (_props_texts7 = props.texts) === null || _props_texts7 === void 0 ? void 0 : _props_texts7.registerText) !== null && _props_texts_registerText !== void 0 ? _props_texts_registerText : "Register"))))) : /* @__PURE__ */ import_react48.default.createElement(CardContent, {
|
|
8320
8368
|
headless: true
|
|
8321
|
-
}, /* @__PURE__ */
|
|
8369
|
+
}, /* @__PURE__ */ import_react48.default.createElement("div", {
|
|
8322
8370
|
className: "hawa-text-center"
|
|
8323
8371
|
}, (_props_texts8 = props.texts) === null || _props_texts8 === void 0 ? void 0 : _props_texts8.emailSentText)));
|
|
8324
8372
|
};
|
|
8325
8373
|
// components/blocks/auth/CodeConfirmation.tsx
|
|
8326
|
-
var
|
|
8374
|
+
var import_react49 = __toESM(require("react"));
|
|
8327
8375
|
var import_react_hook_form5 = require("react-hook-form");
|
|
8328
8376
|
var import_zod5 = require("@hookform/resolvers/zod");
|
|
8329
8377
|
var z5 = __toESM(require("zod"));
|
|
@@ -8340,19 +8388,19 @@ var CodeConfirmation = function(props) {
|
|
|
8340
8388
|
resolver: (0, import_zod5.zodResolver)(formSchema)
|
|
8341
8389
|
}), handleSubmit = _ref.handleSubmit, control = _ref.control, formState = _ref.formState, setValue = _ref.setValue;
|
|
8342
8390
|
var _props_texts_checkYourPhone, _props_texts_weSentCode, _props_texts_didntGetCode, _props_texts_resendCode, _props_texts_cancel, _props_texts_confirm;
|
|
8343
|
-
return /* @__PURE__ */
|
|
8391
|
+
return /* @__PURE__ */ import_react49.default.createElement(Card, null, /* @__PURE__ */ import_react49.default.createElement(CardContent, {
|
|
8344
8392
|
headless: true
|
|
8345
|
-
}, props.showError && /* @__PURE__ */
|
|
8393
|
+
}, props.showError && /* @__PURE__ */ import_react49.default.createElement(Alert, {
|
|
8346
8394
|
title: props.errorTitle,
|
|
8347
8395
|
text: props.errorText,
|
|
8348
8396
|
severity: "error"
|
|
8349
|
-
}), /* @__PURE__ */
|
|
8397
|
+
}), /* @__PURE__ */ import_react49.default.createElement("div", {
|
|
8350
8398
|
className: "hawa-mb-4 dark:hawa-text-white"
|
|
8351
|
-
}, /* @__PURE__ */
|
|
8399
|
+
}, /* @__PURE__ */ import_react49.default.createElement("div", {
|
|
8352
8400
|
className: "hawa-text-lg hawa-font-bold"
|
|
8353
|
-
}, (_props_texts_checkYourPhone = (_props_texts2 = props.texts) === null || _props_texts2 === void 0 ? void 0 : _props_texts2.checkYourPhone) !== null && _props_texts_checkYourPhone !== void 0 ? _props_texts_checkYourPhone : "Please check your phone"), /* @__PURE__ */
|
|
8401
|
+
}, (_props_texts_checkYourPhone = (_props_texts2 = props.texts) === null || _props_texts2 === void 0 ? void 0 : _props_texts2.checkYourPhone) !== null && _props_texts_checkYourPhone !== void 0 ? _props_texts_checkYourPhone : "Please check your phone"), /* @__PURE__ */ import_react49.default.createElement("div", {
|
|
8354
8402
|
className: "hawa-text-muted-foreground"
|
|
8355
|
-
}, /* @__PURE__ */
|
|
8403
|
+
}, /* @__PURE__ */ import_react49.default.createElement("span", null, (_props_texts_weSentCode = (_props_texts3 = props.texts) === null || _props_texts3 === void 0 ? void 0 : _props_texts3.weSentCode) !== null && _props_texts_weSentCode !== void 0 ? _props_texts_weSentCode : "We've sent a code to "), /* @__PURE__ */ import_react49.default.createElement("span", null, props.phoneNumber)), " "), /* @__PURE__ */ import_react49.default.createElement("form", {
|
|
8356
8404
|
noValidate: true,
|
|
8357
8405
|
onSubmit: handleSubmit(function(e) {
|
|
8358
8406
|
if (props.handleConfirm) {
|
|
@@ -8361,13 +8409,13 @@ var CodeConfirmation = function(props) {
|
|
|
8361
8409
|
console.log("Form is submitted but handleConfirm prop is missing");
|
|
8362
8410
|
}
|
|
8363
8411
|
})
|
|
8364
|
-
}, /* @__PURE__ */
|
|
8412
|
+
}, /* @__PURE__ */ import_react49.default.createElement(import_react_hook_form5.Controller, {
|
|
8365
8413
|
control: control,
|
|
8366
8414
|
name: "otp_code",
|
|
8367
8415
|
render: function(param) {
|
|
8368
8416
|
var field = param.field;
|
|
8369
8417
|
var _formState_errors_otp_code;
|
|
8370
|
-
return /* @__PURE__ */
|
|
8418
|
+
return /* @__PURE__ */ import_react49.default.createElement(PinInput, {
|
|
8371
8419
|
width: "full",
|
|
8372
8420
|
digits: 6,
|
|
8373
8421
|
getPins: function(e) {
|
|
@@ -8376,18 +8424,18 @@ var CodeConfirmation = function(props) {
|
|
|
8376
8424
|
helperText: (_formState_errors_otp_code = formState.errors.otp_code) === null || _formState_errors_otp_code === void 0 ? void 0 : _formState_errors_otp_code.message
|
|
8377
8425
|
});
|
|
8378
8426
|
}
|
|
8379
|
-
}), /* @__PURE__ */
|
|
8427
|
+
}), /* @__PURE__ */ import_react49.default.createElement("div", {
|
|
8380
8428
|
className: " hawa-py-2 hawa-text-center hawa-text-xs hawa-text-muted-foreground"
|
|
8381
|
-
}, /* @__PURE__ */
|
|
8429
|
+
}, /* @__PURE__ */ import_react49.default.createElement("span", null, (_props_texts_didntGetCode = (_props_texts4 = props.texts) === null || _props_texts4 === void 0 ? void 0 : _props_texts4.didntGetCode) !== null && _props_texts_didntGetCode !== void 0 ? _props_texts_didntGetCode : "Didn't get the code?"), " ", /* @__PURE__ */ import_react49.default.createElement("span", {
|
|
8382
8430
|
className: "clickable-link"
|
|
8383
|
-
}, (_props_texts_resendCode = (_props_texts5 = props.texts) === null || _props_texts5 === void 0 ? void 0 : _props_texts5.resendCode) !== null && _props_texts_resendCode !== void 0 ? _props_texts_resendCode : "Click to resend")), /* @__PURE__ */
|
|
8431
|
+
}, (_props_texts_resendCode = (_props_texts5 = props.texts) === null || _props_texts5 === void 0 ? void 0 : _props_texts5.resendCode) !== null && _props_texts_resendCode !== void 0 ? _props_texts_resendCode : "Click to resend")), /* @__PURE__ */ import_react49.default.createElement("div", {
|
|
8384
8432
|
className: "hawa-mt-4 hawa-grid hawa-grid-cols-2 hawa-gap-2"
|
|
8385
|
-
}, /* @__PURE__ */
|
|
8433
|
+
}, /* @__PURE__ */ import_react49.default.createElement(Button, {
|
|
8386
8434
|
variant: "secondary"
|
|
8387
|
-
}, (_props_texts_cancel = (_props_texts6 = props.texts) === null || _props_texts6 === void 0 ? void 0 : _props_texts6.cancel) !== null && _props_texts_cancel !== void 0 ? _props_texts_cancel : "Cancel"), /* @__PURE__ */
|
|
8435
|
+
}, (_props_texts_cancel = (_props_texts6 = props.texts) === null || _props_texts6 === void 0 ? void 0 : _props_texts6.cancel) !== null && _props_texts_cancel !== void 0 ? _props_texts_cancel : "Cancel"), /* @__PURE__ */ import_react49.default.createElement(Button, null, (_props_texts_confirm = (_props_texts7 = props.texts) === null || _props_texts7 === void 0 ? void 0 : _props_texts7.confirm) !== null && _props_texts_confirm !== void 0 ? _props_texts_confirm : "Confirm")))));
|
|
8388
8436
|
};
|
|
8389
8437
|
// components/blocks/feedback/UserReferralSource.tsx
|
|
8390
|
-
var
|
|
8438
|
+
var import_react50 = __toESM(require("react"));
|
|
8391
8439
|
var import_react_hook_form6 = require("react-hook-form");
|
|
8392
8440
|
var import_zod6 = require("@hookform/resolvers/zod");
|
|
8393
8441
|
var z6 = __toESM(require("zod"));
|
|
@@ -8397,8 +8445,8 @@ var UserReferralSource = function(_param) {
|
|
|
8397
8445
|
"options"
|
|
8398
8446
|
]);
|
|
8399
8447
|
var _props_texts, _props_texts1;
|
|
8400
|
-
var _ref = _sliced_to_array((0,
|
|
8401
|
-
var popUpRef = (0,
|
|
8448
|
+
var _ref = _sliced_to_array((0, import_react50.useState)(false), 2), closed = _ref[0], setClosed = _ref[1];
|
|
8449
|
+
var popUpRef = (0, import_react50.useRef)(null);
|
|
8402
8450
|
var formSchema = z6.object({
|
|
8403
8451
|
source: z6.string({
|
|
8404
8452
|
required_error: (_props_texts = props.texts) === null || _props_texts === void 0 ? void 0 : _props_texts.pleaseSelectOption
|
|
@@ -8412,13 +8460,13 @@ var UserReferralSource = function(_param) {
|
|
|
8412
8460
|
"bottom-right": "hawa-right-4",
|
|
8413
8461
|
"bottom-left": "hawa-left-4"
|
|
8414
8462
|
};
|
|
8415
|
-
return /* @__PURE__ */
|
|
8463
|
+
return /* @__PURE__ */ import_react50.default.createElement("div", {
|
|
8416
8464
|
className: cn("hawa-transition-all", closed ? "hawa-opacity-0" : "hawa-opacity-100"),
|
|
8417
8465
|
ref: popUpRef
|
|
8418
|
-
}, /* @__PURE__ */
|
|
8466
|
+
}, /* @__PURE__ */ import_react50.default.createElement(Card, {
|
|
8419
8467
|
className: cn("hawa-fixed hawa-bottom-4 hawa-p-0 ", boxPosition[position]),
|
|
8420
8468
|
dir: props.direction
|
|
8421
|
-
}, /* @__PURE__ */
|
|
8469
|
+
}, /* @__PURE__ */ import_react50.default.createElement("button", {
|
|
8422
8470
|
type: "button",
|
|
8423
8471
|
className: cn(props.direction === "rtl" ? "hawa-left-2" : "hawa-right-2", "hawa-absolute hawa-top-2 hawa-inline-flex hawa-h-8 hawa-w-8 hawa-rounded hawa-p-1.5 hawa-text-gray-400 hawa-transition-all hover:hawa-bg-gray-100 hover:hawa-text-gray-900 focus:hawa-ring-2 focus:hawa-ring-gray-300 dark:hawa-bg-gray-800 dark:hawa-text-gray-500 dark:hover:hawa-bg-gray-700 dark:hover:hawa-text-white"),
|
|
8424
8472
|
"data-dismiss-target": "#toast-default",
|
|
@@ -8431,18 +8479,18 @@ var UserReferralSource = function(_param) {
|
|
|
8431
8479
|
}
|
|
8432
8480
|
}, 200);
|
|
8433
8481
|
}
|
|
8434
|
-
}, /* @__PURE__ */
|
|
8482
|
+
}, /* @__PURE__ */ import_react50.default.createElement("svg", {
|
|
8435
8483
|
"aria-hidden": "true",
|
|
8436
8484
|
className: "hawa-h-5 hawa-w-5",
|
|
8437
8485
|
fill: "currentColor",
|
|
8438
8486
|
viewBox: "0 0 20 20"
|
|
8439
|
-
}, /* @__PURE__ */
|
|
8487
|
+
}, /* @__PURE__ */ import_react50.default.createElement("path", {
|
|
8440
8488
|
fillRule: "evenodd",
|
|
8441
8489
|
d: "M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z",
|
|
8442
8490
|
clipRule: "evenodd"
|
|
8443
|
-
}))), /* @__PURE__ */
|
|
8491
|
+
}))), /* @__PURE__ */ import_react50.default.createElement(CardContent, {
|
|
8444
8492
|
headless: true
|
|
8445
|
-
}, /* @__PURE__ */
|
|
8493
|
+
}, /* @__PURE__ */ import_react50.default.createElement("form", {
|
|
8446
8494
|
noValidate: true,
|
|
8447
8495
|
onSubmit: handleSubmit(function(e) {
|
|
8448
8496
|
if (props.onSubmitForm) {
|
|
@@ -8450,19 +8498,19 @@ var UserReferralSource = function(_param) {
|
|
|
8450
8498
|
}
|
|
8451
8499
|
console.log("onSubmitForm was not provided");
|
|
8452
8500
|
})
|
|
8453
|
-
}, /* @__PURE__ */
|
|
8501
|
+
}, /* @__PURE__ */ import_react50.default.createElement("div", {
|
|
8454
8502
|
className: cn("hawa-flex hawa-flex-col hawa-gap-4 hawa-transition-all", closed ? "hawa-opacity-0" : "hawa-opacity-100")
|
|
8455
|
-
}, /* @__PURE__ */
|
|
8503
|
+
}, /* @__PURE__ */ import_react50.default.createElement("div", {
|
|
8456
8504
|
className: "hawa-mt-4 hawa-font-bold"
|
|
8457
|
-
}, props.question), /* @__PURE__ */
|
|
8505
|
+
}, props.question), /* @__PURE__ */ import_react50.default.createElement("div", {
|
|
8458
8506
|
className: "hawa-flex hawa-w-full hawa-flex-row hawa-gap-1 hawa-rounded "
|
|
8459
|
-
}, /* @__PURE__ */
|
|
8507
|
+
}, /* @__PURE__ */ import_react50.default.createElement(import_react_hook_form6.Controller, {
|
|
8460
8508
|
control: control,
|
|
8461
8509
|
name: "source",
|
|
8462
8510
|
render: function(param) {
|
|
8463
8511
|
var field = param.field;
|
|
8464
8512
|
var _formState_errors_source_message, _formState_errors_source;
|
|
8465
|
-
return /* @__PURE__ */
|
|
8513
|
+
return /* @__PURE__ */ import_react50.default.createElement(Radio, {
|
|
8466
8514
|
direction: props.direction,
|
|
8467
8515
|
orientation: "vertical",
|
|
8468
8516
|
options: options,
|
|
@@ -8473,38 +8521,38 @@ var UserReferralSource = function(_param) {
|
|
|
8473
8521
|
helperText: (_formState_errors_source = formState.errors.source) === null || _formState_errors_source === void 0 ? void 0 : (_formState_errors_source_message = _formState_errors_source.message) === null || _formState_errors_source_message === void 0 ? void 0 : _formState_errors_source_message.toString()
|
|
8474
8522
|
});
|
|
8475
8523
|
}
|
|
8476
|
-
})), /* @__PURE__ */
|
|
8524
|
+
})), /* @__PURE__ */ import_react50.default.createElement("div", null, /* @__PURE__ */ import_react50.default.createElement(import_react_hook_form6.Controller, {
|
|
8477
8525
|
control: control,
|
|
8478
8526
|
name: "feedback",
|
|
8479
8527
|
render: function(param) {
|
|
8480
8528
|
var field = param.field;
|
|
8481
8529
|
var _formState_errors_feedback_message, _formState_errors_feedback;
|
|
8482
|
-
return /* @__PURE__ */
|
|
8530
|
+
return /* @__PURE__ */ import_react50.default.createElement(Textarea, _object_spread_props(_object_spread({}, field), {
|
|
8483
8531
|
helperText: (_formState_errors_feedback = formState.errors.feedback) === null || _formState_errors_feedback === void 0 ? void 0 : (_formState_errors_feedback_message = _formState_errors_feedback.message) === null || _formState_errors_feedback_message === void 0 ? void 0 : _formState_errors_feedback_message.toString()
|
|
8484
8532
|
}));
|
|
8485
8533
|
}
|
|
8486
|
-
}))), /* @__PURE__ */
|
|
8534
|
+
}))), /* @__PURE__ */ import_react50.default.createElement(Button, {
|
|
8487
8535
|
type: "submit",
|
|
8488
8536
|
className: "hawa-mt-4 hawa-w-full"
|
|
8489
8537
|
}, ((_props_texts1 = props.texts) === null || _props_texts1 === void 0 ? void 0 : _props_texts1.submit) || "Submit")))));
|
|
8490
8538
|
};
|
|
8491
8539
|
// components/blocks/feedback/FeedbackRating.tsx
|
|
8492
|
-
var
|
|
8540
|
+
var import_react51 = __toESM(require("react"));
|
|
8493
8541
|
var import_clsx11 = __toESM(require("clsx"));
|
|
8494
8542
|
var FeedbackRating = function(_param) {
|
|
8495
8543
|
var _param_position = _param.position, position = _param_position === void 0 ? "bottom-right" : _param_position, props = _object_without_properties(_param, [
|
|
8496
8544
|
"position"
|
|
8497
8545
|
]);
|
|
8498
|
-
var _ref = _sliced_to_array((0,
|
|
8499
|
-
var _ref1 = _sliced_to_array((0,
|
|
8500
|
-
var _ref2 = _sliced_to_array((0,
|
|
8501
|
-
var _ref3 = _sliced_to_array((0,
|
|
8502
|
-
var popUpRef = (0,
|
|
8546
|
+
var _ref = _sliced_to_array((0, import_react51.useState)(false), 2), closed = _ref[0], setClosed = _ref[1];
|
|
8547
|
+
var _ref1 = _sliced_to_array((0, import_react51.useState)(false), 2), answered = _ref1[0], setAnswered = _ref1[1];
|
|
8548
|
+
var _ref2 = _sliced_to_array((0, import_react51.useState)(null), 2), clickedOption = _ref2[0], setClickedOption = _ref2[1];
|
|
8549
|
+
var _ref3 = _sliced_to_array((0, import_react51.useState)(5), 2), closingTimer = _ref3[0], setClosingTimer = _ref3[1];
|
|
8550
|
+
var popUpRef = (0, import_react51.useRef)(null);
|
|
8503
8551
|
var boxPosition = {
|
|
8504
8552
|
"bottom-right": "hawa-right-4",
|
|
8505
8553
|
"bottom-left": "hawa-left-4"
|
|
8506
8554
|
};
|
|
8507
|
-
(0,
|
|
8555
|
+
(0, import_react51.useEffect)(function() {
|
|
8508
8556
|
var timeoutHide = setTimeout(function() {
|
|
8509
8557
|
if (closingTimer >= 0) {
|
|
8510
8558
|
setClosingTimer(closingTimer - 1);
|
|
@@ -8524,14 +8572,14 @@ var FeedbackRating = function(_param) {
|
|
|
8524
8572
|
}
|
|
8525
8573
|
}, 200);
|
|
8526
8574
|
};
|
|
8527
|
-
return /* @__PURE__ */
|
|
8575
|
+
return /* @__PURE__ */ import_react51.default.createElement("div", {
|
|
8528
8576
|
ref: popUpRef,
|
|
8529
8577
|
className: (0, import_clsx11.default)(props.banner ? "hawa-w-full hawa-left-0 hawa-fixed hawa-bottom-0 hawa-px-0 md:hawa-px-4" : "hawa-fixed hawa-bottom-4 ", boxPosition[position])
|
|
8530
|
-
}, /* @__PURE__ */
|
|
8578
|
+
}, /* @__PURE__ */ import_react51.default.createElement("div", {
|
|
8531
8579
|
className: (0, import_clsx11.default)("hawa-relative hawa-flex hawa-w-full hawa-flex-col hawa-gap-2 hawa-rounded hawa-border hawa-bg-background hawa-p-4 hawa-shadow-md hawa-transition-all", closed ? "hawa-opacity-0" : "hawa-opacity-100", props.banner && "hawa-rounded-none md:hawa-rounded hawa-px-4 md:hawa-px-64")
|
|
8532
|
-
}, /* @__PURE__ */
|
|
8580
|
+
}, /* @__PURE__ */ import_react51.default.createElement("div", {
|
|
8533
8581
|
className: "hawa-absolute hawa-left-2 hawa-top-2 hawa-p-1.5 hawa-text-sm"
|
|
8534
|
-
}, props.title), /* @__PURE__ */
|
|
8582
|
+
}, props.title), /* @__PURE__ */ import_react51.default.createElement("button", {
|
|
8535
8583
|
type: "button",
|
|
8536
8584
|
className: "hawa-absolute hawa-right-2 hawa-top-2 hawa-inline-flex hawa-h-8 hawa-w-8 hawa-rounded hawa-p-1.5 hawa-text-gray-400 hover:hawa-bg-gray-100 hover:hawa-text-gray-900 focus:hawa-ring-2 focus:hawa-ring-gray-300 dark:hawa-bg-gray-800 dark:hawa-text-gray-500 dark:hover:hawa-bg-gray-700 dark:hover:hawa-text-white",
|
|
8537
8585
|
"data-dismiss-target": "#toast-default",
|
|
@@ -8539,21 +8587,21 @@ var FeedbackRating = function(_param) {
|
|
|
8539
8587
|
onClick: function() {
|
|
8540
8588
|
return slowClose();
|
|
8541
8589
|
}
|
|
8542
|
-
}, /* @__PURE__ */
|
|
8590
|
+
}, /* @__PURE__ */ import_react51.default.createElement("svg", {
|
|
8543
8591
|
"aria-hidden": "true",
|
|
8544
8592
|
className: "hawa-h-5 hawa-w-5",
|
|
8545
8593
|
fill: "currentColor",
|
|
8546
8594
|
viewBox: "0 0 20 20"
|
|
8547
|
-
}, /* @__PURE__ */
|
|
8595
|
+
}, /* @__PURE__ */ import_react51.default.createElement("path", {
|
|
8548
8596
|
fillRule: "evenodd",
|
|
8549
8597
|
d: "M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z",
|
|
8550
8598
|
clipRule: "evenodd"
|
|
8551
|
-
}))), /* @__PURE__ */
|
|
8599
|
+
}))), /* @__PURE__ */ import_react51.default.createElement("div", {
|
|
8552
8600
|
className: "hawa-mt-8"
|
|
8553
|
-
}, props.question), /* @__PURE__ */
|
|
8601
|
+
}, props.question), /* @__PURE__ */ import_react51.default.createElement("div", {
|
|
8554
8602
|
className: "hawa-flex hawa-w-full hawa-flex-row hawa-gap-1 hawa-rounded"
|
|
8555
8603
|
}, props.options && props.options.map(function(op, i) {
|
|
8556
|
-
return /* @__PURE__ */
|
|
8604
|
+
return /* @__PURE__ */ import_react51.default.createElement("span", {
|
|
8557
8605
|
key: i,
|
|
8558
8606
|
onClick: function() {
|
|
8559
8607
|
if (props.onOptionClicked) {
|
|
@@ -8572,15 +8620,15 @@ var FeedbackRating = function(_param) {
|
|
|
8572
8620
|
},
|
|
8573
8621
|
className: (0, import_clsx11.default)("hawa-w-full hawa-cursor-pointer hawa-rounded hawa-border hawa-p-4 hawa-text-center hawa-transition-all ", clickedOption === op ? "hawa-bg-gray-500 hawa-text-white" : "hawa-border hawa-bg-background hover:hawa-bg-gray-300 dark:hover:hawa-bg-gray-700")
|
|
8574
8622
|
}, op);
|
|
8575
|
-
})), props.texts && /* @__PURE__ */
|
|
8623
|
+
})), props.texts && /* @__PURE__ */ import_react51.default.createElement("div", {
|
|
8576
8624
|
className: " hawa-flex hawa-flex-row hawa-justify-between hawa-text-xs"
|
|
8577
|
-
}, /* @__PURE__ */
|
|
8625
|
+
}, /* @__PURE__ */ import_react51.default.createElement("span", null, props.texts.least), /* @__PURE__ */ import_react51.default.createElement("span", null, props.texts.most)), answered && /* @__PURE__ */ import_react51.default.createElement("div", {
|
|
8578
8626
|
className: "hawa-absolute hawa-left-0 hawa-top-0 hawa-gap-2 hawa-flex hawa-h-full hawa-w-full hawa-flex-col hawa-items-center hawa-justify-center hawa-rounded hawa-bg-black hawa-bg-opacity-80 hawa-p-4 hawa-text-center hawa-transition-all"
|
|
8579
|
-
}, /* @__PURE__ */
|
|
8627
|
+
}, /* @__PURE__ */ import_react51.default.createElement("span", {
|
|
8580
8628
|
className: "hawa-font-bold hawa-text-white"
|
|
8581
|
-
}, "Thank you for your answer. This box will disappear in", " " + closingTimer, " seconds"), /* @__PURE__ */
|
|
8629
|
+
}, "Thank you for your answer. This box will disappear in", " " + closingTimer, " seconds"), /* @__PURE__ */ import_react51.default.createElement("div", {
|
|
8582
8630
|
className: "hawa-flex hawa-flex-row hawa-gap-2"
|
|
8583
|
-
}, /* @__PURE__ */
|
|
8631
|
+
}, /* @__PURE__ */ import_react51.default.createElement(Button, {
|
|
8584
8632
|
variant: "secondary",
|
|
8585
8633
|
onClick: function() {
|
|
8586
8634
|
return slowClose();
|
|
@@ -8588,27 +8636,27 @@ var FeedbackRating = function(_param) {
|
|
|
8588
8636
|
}, "Close")))));
|
|
8589
8637
|
};
|
|
8590
8638
|
// components/blocks/feedback/FeedbackEmoji.tsx
|
|
8591
|
-
var
|
|
8639
|
+
var import_react52 = __toESM(require("react"));
|
|
8592
8640
|
var FeedbackEmoji = function(props) {
|
|
8593
|
-
var _ref = _sliced_to_array((0,
|
|
8594
|
-
var _ref1 = _sliced_to_array((0,
|
|
8595
|
-
var _ref2 = _sliced_to_array((0,
|
|
8596
|
-
var _ref3 = _sliced_to_array((0,
|
|
8641
|
+
var _ref = _sliced_to_array((0, import_react52.useState)(null), 2), selectedEmoji = _ref[0], setSelectedEmoji = _ref[1];
|
|
8642
|
+
var _ref1 = _sliced_to_array((0, import_react52.useState)(false), 2), loadingSubmit = _ref1[0], setLoadingSubmit = _ref1[1];
|
|
8643
|
+
var _ref2 = _sliced_to_array((0, import_react52.useState)(""), 2), feedbackText = _ref2[0], setFeedbackText = _ref2[1];
|
|
8644
|
+
var _ref3 = _sliced_to_array((0, import_react52.useState)(false), 2), helperText = _ref3[0], setHelperText = _ref3[1];
|
|
8597
8645
|
var emojis = [
|
|
8598
8646
|
{
|
|
8599
|
-
icon: /* @__PURE__ */
|
|
8647
|
+
icon: /* @__PURE__ */ import_react52.default.createElement(VeryGoodEmoji, null),
|
|
8600
8648
|
value: "very-good"
|
|
8601
8649
|
},
|
|
8602
8650
|
{
|
|
8603
|
-
icon: /* @__PURE__ */
|
|
8651
|
+
icon: /* @__PURE__ */ import_react52.default.createElement(GoodEmoji, null),
|
|
8604
8652
|
value: "good"
|
|
8605
8653
|
},
|
|
8606
8654
|
{
|
|
8607
|
-
icon: /* @__PURE__ */
|
|
8655
|
+
icon: /* @__PURE__ */ import_react52.default.createElement(BadEmoji, null),
|
|
8608
8656
|
value: "bad"
|
|
8609
8657
|
},
|
|
8610
8658
|
{
|
|
8611
|
-
icon: /* @__PURE__ */
|
|
8659
|
+
icon: /* @__PURE__ */ import_react52.default.createElement(VeryBadEmoji, null),
|
|
8612
8660
|
value: "very-bad"
|
|
8613
8661
|
}
|
|
8614
8662
|
];
|
|
@@ -8679,14 +8727,14 @@ var FeedbackEmoji = function(props) {
|
|
|
8679
8727
|
return _ref.apply(this, arguments);
|
|
8680
8728
|
};
|
|
8681
8729
|
}();
|
|
8682
|
-
return /* @__PURE__ */
|
|
8730
|
+
return /* @__PURE__ */ import_react52.default.createElement("div", {
|
|
8683
8731
|
className: cn("hawa-flex hawa-flex-col hawa-gap-2 hawa-rounded hawa-border hawa-p-2 hawa-transition-all", selectedEmoji ? "hawa-h-[185px] hawa-min-w-fit" : "hawa-h-[44px] ")
|
|
8684
|
-
}, /* @__PURE__ */
|
|
8732
|
+
}, /* @__PURE__ */ import_react52.default.createElement("div", {
|
|
8685
8733
|
className: "hawa-flex hawa-flex-row hawa-items-center hawa-justify-center hawa-gap-2 "
|
|
8686
|
-
}, /* @__PURE__ */
|
|
8734
|
+
}, /* @__PURE__ */ import_react52.default.createElement("div", {
|
|
8687
8735
|
className: "hawa-flex hawa-flex-row hawa-justify-center hawa-gap-0.5 "
|
|
8688
8736
|
}, emojis.map(function(emoji, i) {
|
|
8689
|
-
return /* @__PURE__ */
|
|
8737
|
+
return /* @__PURE__ */ import_react52.default.createElement(Button, {
|
|
8690
8738
|
key: i,
|
|
8691
8739
|
onClick: function() {
|
|
8692
8740
|
if (selectedEmoji === emoji.value) {
|
|
@@ -8699,29 +8747,29 @@ var FeedbackEmoji = function(props) {
|
|
|
8699
8747
|
size: "smallIcon",
|
|
8700
8748
|
className: cn(selectedEmoji === emoji.value ? "hawa-bg-primary/10 hover:hawa-bg-primary/10 " : "hawa-text-[#666666]")
|
|
8701
8749
|
}, emoji.icon);
|
|
8702
|
-
}))), /* @__PURE__ */
|
|
8750
|
+
}))), /* @__PURE__ */ import_react52.default.createElement("div", {
|
|
8703
8751
|
className: cn("hawa-flex hawa-flex-col hawa-overflow-clip hawa-transition-all hawa-duration-500 hawa-ease-in-out ", selectedEmoji ? "hawa-visible hawa-opacity-100" : "hawa-invisible hawa-opacity-0 ")
|
|
8704
|
-
}, props.showSuccess ? /* @__PURE__ */
|
|
8752
|
+
}, props.showSuccess ? /* @__PURE__ */ import_react52.default.createElement("div", {
|
|
8705
8753
|
className: "hawa-flex hawa-h-full hawa-flex-col hawa-items-center hawa-justify-center hawa-gap-2 hawa-pt-4"
|
|
8706
|
-
}, /* @__PURE__ */
|
|
8754
|
+
}, /* @__PURE__ */ import_react52.default.createElement("div", {
|
|
8707
8755
|
className: "hawa-rounded hawa-bg-primary hawa-p-2 hawa-text-primary-foreground"
|
|
8708
|
-
}, /* @__PURE__ */
|
|
8756
|
+
}, /* @__PURE__ */ import_react52.default.createElement("svg", {
|
|
8709
8757
|
stroke: "currentColor",
|
|
8710
8758
|
fill: "currentColor",
|
|
8711
8759
|
strokeWidth: "0",
|
|
8712
8760
|
viewBox: "0 0 512 512",
|
|
8713
8761
|
height: "0.5em",
|
|
8714
8762
|
width: "0.5em"
|
|
8715
|
-
}, /* @__PURE__ */
|
|
8763
|
+
}, /* @__PURE__ */ import_react52.default.createElement("path", {
|
|
8716
8764
|
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"
|
|
8717
|
-
}))), /* @__PURE__ */
|
|
8765
|
+
}))), /* @__PURE__ */ import_react52.default.createElement("div", {
|
|
8718
8766
|
className: "hawa-text-sm hawa-flex hawa-flex-col hawa-text-center"
|
|
8719
|
-
}, /* @__PURE__ */
|
|
8767
|
+
}, /* @__PURE__ */ import_react52.default.createElement("span", null, "Your feedback has been received!"), /* @__PURE__ */ import_react52.default.createElement("span", null, "Thank you for your help"))) : /* @__PURE__ */ import_react52.default.createElement("div", {
|
|
8720
8768
|
className: "hawa-flex hawa-flex-col hawa-gap-2"
|
|
8721
|
-
}, /* @__PURE__ */
|
|
8769
|
+
}, /* @__PURE__ */ import_react52.default.createElement(Popover, {
|
|
8722
8770
|
className: "hawa-select-none hawa-p-1 hawa-text-xs ",
|
|
8723
8771
|
open: helperText,
|
|
8724
|
-
trigger: /* @__PURE__ */
|
|
8772
|
+
trigger: /* @__PURE__ */ import_react52.default.createElement(Textarea, {
|
|
8725
8773
|
className: cn("hawa-mb-2 hawa-h-full hawa-resize-none"),
|
|
8726
8774
|
placeholder: "Your feedback",
|
|
8727
8775
|
onChange: function(e) {
|
|
@@ -8732,9 +8780,9 @@ var FeedbackEmoji = function(props) {
|
|
|
8732
8780
|
console.log("changing to", e.target.value);
|
|
8733
8781
|
}
|
|
8734
8782
|
})
|
|
8735
|
-
}, /* @__PURE__ */
|
|
8783
|
+
}, /* @__PURE__ */ import_react52.default.createElement("span", {
|
|
8736
8784
|
className: "hawa-m-2"
|
|
8737
|
-
}, "Please enter your feedback"), " "), /* @__PURE__ */
|
|
8785
|
+
}, "Please enter your feedback"), " "), /* @__PURE__ */ import_react52.default.createElement(Button, {
|
|
8738
8786
|
isLoading: loadingSubmit,
|
|
8739
8787
|
onClick: onFeedbackSubmit,
|
|
8740
8788
|
className: "hawa-w-full",
|
|
@@ -8742,20 +8790,20 @@ var FeedbackEmoji = function(props) {
|
|
|
8742
8790
|
}, "Submit"))));
|
|
8743
8791
|
};
|
|
8744
8792
|
var VeryGoodEmoji = function() {
|
|
8745
|
-
return /* @__PURE__ */
|
|
8793
|
+
return /* @__PURE__ */ import_react52.default.createElement("svg", {
|
|
8746
8794
|
fill: "none",
|
|
8747
8795
|
height: "16",
|
|
8748
8796
|
viewBox: "0 0 16 16",
|
|
8749
8797
|
width: "16",
|
|
8750
8798
|
xmlns: "http://www.w3.org/2000/svg"
|
|
8751
|
-
}, /* @__PURE__ */
|
|
8799
|
+
}, /* @__PURE__ */ import_react52.default.createElement("g", {
|
|
8752
8800
|
clipPath: "url(#clip0_53_166)"
|
|
8753
|
-
}, /* @__PURE__ */
|
|
8801
|
+
}, /* @__PURE__ */ import_react52.default.createElement("path", {
|
|
8754
8802
|
clipRule: "evenodd",
|
|
8755
8803
|
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",
|
|
8756
8804
|
fill: "currentColor",
|
|
8757
8805
|
fillRule: "evenodd"
|
|
8758
|
-
}), /* @__PURE__ */
|
|
8806
|
+
}), /* @__PURE__ */ import_react52.default.createElement("path", {
|
|
8759
8807
|
clipRule: "evenodd",
|
|
8760
8808
|
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",
|
|
8761
8809
|
fill: "#FF990A",
|
|
@@ -8763,15 +8811,15 @@ var VeryGoodEmoji = function() {
|
|
|
8763
8811
|
})));
|
|
8764
8812
|
};
|
|
8765
8813
|
var GoodEmoji = function() {
|
|
8766
|
-
return /* @__PURE__ */
|
|
8814
|
+
return /* @__PURE__ */ import_react52.default.createElement("svg", {
|
|
8767
8815
|
fill: "none",
|
|
8768
8816
|
height: "16",
|
|
8769
8817
|
viewBox: "0 0 16 16",
|
|
8770
8818
|
width: "16",
|
|
8771
8819
|
xmlns: "http://www.w3.org/2000/svg"
|
|
8772
|
-
}, /* @__PURE__ */
|
|
8820
|
+
}, /* @__PURE__ */ import_react52.default.createElement("g", {
|
|
8773
8821
|
clipPath: "url(#clip0_53_167)"
|
|
8774
|
-
}, /* @__PURE__ */
|
|
8822
|
+
}, /* @__PURE__ */ import_react52.default.createElement("path", {
|
|
8775
8823
|
clipRule: "evenodd",
|
|
8776
8824
|
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",
|
|
8777
8825
|
fill: "currentColor",
|
|
@@ -8779,15 +8827,15 @@ var GoodEmoji = function() {
|
|
|
8779
8827
|
})));
|
|
8780
8828
|
};
|
|
8781
8829
|
var BadEmoji = function() {
|
|
8782
|
-
return /* @__PURE__ */
|
|
8830
|
+
return /* @__PURE__ */ import_react52.default.createElement("svg", {
|
|
8783
8831
|
fill: "none",
|
|
8784
8832
|
height: "16",
|
|
8785
8833
|
viewBox: "0 0 16 16",
|
|
8786
8834
|
width: "16",
|
|
8787
8835
|
xmlns: "http://www.w3.org/2000/svg"
|
|
8788
|
-
}, /* @__PURE__ */
|
|
8836
|
+
}, /* @__PURE__ */ import_react52.default.createElement("g", {
|
|
8789
8837
|
clipPath: "url(#clip0_53_152)"
|
|
8790
|
-
}, /* @__PURE__ */
|
|
8838
|
+
}, /* @__PURE__ */ import_react52.default.createElement("path", {
|
|
8791
8839
|
clipRule: "evenodd",
|
|
8792
8840
|
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",
|
|
8793
8841
|
fill: "currentColor",
|
|
@@ -8795,18 +8843,18 @@ var BadEmoji = function() {
|
|
|
8795
8843
|
})));
|
|
8796
8844
|
};
|
|
8797
8845
|
var VeryBadEmoji = function() {
|
|
8798
|
-
return /* @__PURE__ */
|
|
8846
|
+
return /* @__PURE__ */ import_react52.default.createElement("svg", {
|
|
8799
8847
|
fill: "none",
|
|
8800
8848
|
height: "16",
|
|
8801
8849
|
viewBox: "0 0 16 16",
|
|
8802
8850
|
width: "16",
|
|
8803
8851
|
xmlns: "http://www.w3.org/2000/svg"
|
|
8804
|
-
}, /* @__PURE__ */
|
|
8852
|
+
}, /* @__PURE__ */ import_react52.default.createElement("g", {
|
|
8805
8853
|
clipPath: "url(#clip0_53_151)"
|
|
8806
|
-
}, /* @__PURE__ */
|
|
8854
|
+
}, /* @__PURE__ */ import_react52.default.createElement("path", {
|
|
8807
8855
|
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",
|
|
8808
8856
|
fill: "#0070F3"
|
|
8809
|
-
}), /* @__PURE__ */
|
|
8857
|
+
}), /* @__PURE__ */ import_react52.default.createElement("path", {
|
|
8810
8858
|
clipRule: "evenodd",
|
|
8811
8859
|
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",
|
|
8812
8860
|
fill: "currentColor",
|
|
@@ -8814,7 +8862,7 @@ var VeryBadEmoji = function() {
|
|
|
8814
8862
|
})));
|
|
8815
8863
|
};
|
|
8816
8864
|
// components/blocks/feedback/FeedbackForm.tsx
|
|
8817
|
-
var
|
|
8865
|
+
var import_react53 = __toESM(require("react"));
|
|
8818
8866
|
var import_react_hook_form7 = require("react-hook-form");
|
|
8819
8867
|
var import_zod7 = require("@hookform/resolvers/zod");
|
|
8820
8868
|
var z7 = __toESM(require("zod"));
|
|
@@ -8835,9 +8883,9 @@ var FeedbackForm = function(props) {
|
|
|
8835
8883
|
var _ref = (0, import_react_hook_form7.useForm)({
|
|
8836
8884
|
resolver: (0, import_zod7.zodResolver)(formSchema)
|
|
8837
8885
|
}), handleSubmit = _ref.handleSubmit, control = _ref.control, formState = _ref.formState;
|
|
8838
|
-
return /* @__PURE__ */
|
|
8886
|
+
return /* @__PURE__ */ import_react53.default.createElement(Card, null, /* @__PURE__ */ import_react53.default.createElement(CardContent, {
|
|
8839
8887
|
headless: true
|
|
8840
|
-
}, /* @__PURE__ */
|
|
8888
|
+
}, /* @__PURE__ */ import_react53.default.createElement("form", {
|
|
8841
8889
|
noValidate: true,
|
|
8842
8890
|
onSubmit: handleSubmit(function(e) {
|
|
8843
8891
|
if (props.onSubmit) {
|
|
@@ -8847,13 +8895,13 @@ var FeedbackForm = function(props) {
|
|
|
8847
8895
|
}
|
|
8848
8896
|
}),
|
|
8849
8897
|
className: "hawa-flex hawa-flex-col hawa-gap-4"
|
|
8850
|
-
}, /* @__PURE__ */
|
|
8898
|
+
}, /* @__PURE__ */ import_react53.default.createElement(Label2, null, (_props_texts = props.texts) === null || _props_texts === void 0 ? void 0 : _props_texts.requestType), /* @__PURE__ */ import_react53.default.createElement(import_react_hook_form7.Controller, {
|
|
8851
8899
|
name: "requestType",
|
|
8852
8900
|
control: control,
|
|
8853
8901
|
render: function(param) {
|
|
8854
8902
|
var field = param.field;
|
|
8855
8903
|
var _formState_errors_requestType_message, _formState_errors_requestType;
|
|
8856
|
-
return /* @__PURE__ */
|
|
8904
|
+
return /* @__PURE__ */ import_react53.default.createElement(Select, _object_spread_props(_object_spread({}, field), {
|
|
8857
8905
|
onChange: function(option) {
|
|
8858
8906
|
return field.onChange(option.value);
|
|
8859
8907
|
},
|
|
@@ -8861,70 +8909,70 @@ var FeedbackForm = function(props) {
|
|
|
8861
8909
|
helperText: (_formState_errors_requestType = formState.errors.requestType) === null || _formState_errors_requestType === void 0 ? void 0 : (_formState_errors_requestType_message = _formState_errors_requestType.message) === null || _formState_errors_requestType_message === void 0 ? void 0 : _formState_errors_requestType_message.toString()
|
|
8862
8910
|
}));
|
|
8863
8911
|
}
|
|
8864
|
-
}), /* @__PURE__ */
|
|
8912
|
+
}), /* @__PURE__ */ import_react53.default.createElement(Label2, null, props.texts.description), /* @__PURE__ */ import_react53.default.createElement(import_react_hook_form7.Controller, {
|
|
8865
8913
|
name: "description",
|
|
8866
8914
|
control: control,
|
|
8867
8915
|
render: function(param) {
|
|
8868
8916
|
var field = param.field;
|
|
8869
8917
|
var _formState_errors_description_message, _formState_errors_description;
|
|
8870
|
-
return /* @__PURE__ */
|
|
8918
|
+
return /* @__PURE__ */ import_react53.default.createElement(Textarea, _object_spread_props(_object_spread({}, field), {
|
|
8871
8919
|
helperText: formState.errors.description && ((_formState_errors_description = formState.errors.description) === null || _formState_errors_description === void 0 ? void 0 : (_formState_errors_description_message = _formState_errors_description.message) === null || _formState_errors_description_message === void 0 ? void 0 : _formState_errors_description_message.toString())
|
|
8872
8920
|
}));
|
|
8873
8921
|
}
|
|
8874
|
-
}), /* @__PURE__ */
|
|
8922
|
+
}), /* @__PURE__ */ import_react53.default.createElement(Button, {
|
|
8875
8923
|
type: "submit"
|
|
8876
8924
|
}, (_props_texts1 = props.texts) === null || _props_texts1 === void 0 ? void 0 : _props_texts1.submit))));
|
|
8877
8925
|
};
|
|
8878
8926
|
// components/blocks/misc/LegalTexts.tsx
|
|
8879
|
-
var
|
|
8927
|
+
var import_react54 = __toESM(require("react"));
|
|
8880
8928
|
var LegalTexts = function(_param) {
|
|
8881
8929
|
var tabs = _param.tabs, props = _object_without_properties(_param, [
|
|
8882
8930
|
"tabs"
|
|
8883
8931
|
]);
|
|
8884
|
-
return /* @__PURE__ */
|
|
8932
|
+
return /* @__PURE__ */ import_react54.default.createElement(Tabs, {
|
|
8885
8933
|
value: props.activeTab,
|
|
8886
8934
|
onValueChange: props.handleTabChange,
|
|
8887
8935
|
defaultValue: props.defaultTab || tabs[0].value,
|
|
8888
8936
|
dir: props.direction
|
|
8889
|
-
}, /* @__PURE__ */
|
|
8937
|
+
}, /* @__PURE__ */ import_react54.default.createElement(TabsList, {
|
|
8890
8938
|
className: "hawa-w-full"
|
|
8891
8939
|
}, tabs.map(function(tab, index) {
|
|
8892
|
-
return /* @__PURE__ */
|
|
8940
|
+
return /* @__PURE__ */ import_react54.default.createElement(TabsTrigger, {
|
|
8893
8941
|
key: index,
|
|
8894
8942
|
value: tab.value
|
|
8895
8943
|
}, tab.title);
|
|
8896
8944
|
})), tabs.map(function(tab, index) {
|
|
8897
|
-
return /* @__PURE__ */
|
|
8945
|
+
return /* @__PURE__ */ import_react54.default.createElement(TabsContent, {
|
|
8898
8946
|
key: index,
|
|
8899
8947
|
value: tab.value
|
|
8900
|
-
}, /* @__PURE__ */
|
|
8948
|
+
}, /* @__PURE__ */ import_react54.default.createElement(ScrollArea, {
|
|
8901
8949
|
className: cn("hawa-p-4 hawa-rounded hawa-bg-muted hawa-border", props.scrollAreaClassName)
|
|
8902
8950
|
}, tab.content));
|
|
8903
8951
|
}));
|
|
8904
8952
|
};
|
|
8905
8953
|
// components/blocks/misc/EmptyState.tsx
|
|
8906
|
-
var
|
|
8954
|
+
var import_react55 = __toESM(require("react"));
|
|
8907
8955
|
var EmptyState = function(param) {
|
|
8908
8956
|
var texts = param.texts, onActionClick = param.onActionClick;
|
|
8909
8957
|
var _texts_youreCaughtUp, _texts_actionText;
|
|
8910
|
-
return /* @__PURE__ */
|
|
8958
|
+
return /* @__PURE__ */ import_react55.default.createElement(Card, null, /* @__PURE__ */ import_react55.default.createElement(CardContent, {
|
|
8911
8959
|
headless: true
|
|
8912
|
-
}, /* @__PURE__ */
|
|
8960
|
+
}, /* @__PURE__ */ import_react55.default.createElement("div", {
|
|
8913
8961
|
className: "hawa-flex hawa-flex-col hawa-items-center hawa-justify-center hawa-text-center "
|
|
8914
|
-
}, /* @__PURE__ */
|
|
8962
|
+
}, /* @__PURE__ */ import_react55.default.createElement("div", {
|
|
8915
8963
|
className: "hawa-flex hawa-h-10 hawa-w-10 hawa-flex-col hawa-items-center hawa-justify-center hawa-rounded-3xl hawa-bg-primary hawa-text-6xl hawa-font-bold hawa-text-primary-foreground"
|
|
8916
|
-
}, /* @__PURE__ */
|
|
8964
|
+
}, /* @__PURE__ */ import_react55.default.createElement("svg", {
|
|
8917
8965
|
stroke: "currentColor",
|
|
8918
8966
|
fill: "currentColor",
|
|
8919
8967
|
strokeWidth: "0",
|
|
8920
8968
|
viewBox: "0 0 512 512",
|
|
8921
8969
|
height: "0.35em",
|
|
8922
8970
|
width: "0.35em"
|
|
8923
|
-
}, /* @__PURE__ */
|
|
8971
|
+
}, /* @__PURE__ */ import_react55.default.createElement("path", {
|
|
8924
8972
|
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"
|
|
8925
|
-
}))), /* @__PURE__ */
|
|
8973
|
+
}))), /* @__PURE__ */ import_react55.default.createElement("div", {
|
|
8926
8974
|
className: "hawa-m-2 hawa-text-xl hawa-font-bold"
|
|
8927
|
-
}, (_texts_youreCaughtUp = texts === null || texts === void 0 ? void 0 : texts.youreCaughtUp) !== null && _texts_youreCaughtUp !== void 0 ? _texts_youreCaughtUp : "You're all caught up"))), /* @__PURE__ */
|
|
8975
|
+
}, (_texts_youreCaughtUp = texts === null || texts === void 0 ? void 0 : texts.youreCaughtUp) !== null && _texts_youreCaughtUp !== void 0 ? _texts_youreCaughtUp : "You're all caught up"))), /* @__PURE__ */ import_react55.default.createElement(CardFooter, null, /* @__PURE__ */ import_react55.default.createElement(Button, {
|
|
8928
8976
|
className: "hawa-w-full",
|
|
8929
8977
|
onClick: function() {
|
|
8930
8978
|
return onActionClick();
|
|
@@ -8932,36 +8980,36 @@ var EmptyState = function(param) {
|
|
|
8932
8980
|
}, (_texts_actionText = texts === null || texts === void 0 ? void 0 : texts.actionText) !== null && _texts_actionText !== void 0 ? _texts_actionText : "Go Home")));
|
|
8933
8981
|
};
|
|
8934
8982
|
// components/blocks/misc/Testimonial.tsx
|
|
8935
|
-
var
|
|
8983
|
+
var import_react56 = __toESM(require("react"));
|
|
8936
8984
|
var Testimonial = function(props) {
|
|
8937
|
-
return /* @__PURE__ */
|
|
8985
|
+
return /* @__PURE__ */ import_react56.default.createElement(Card, null, /* @__PURE__ */ import_react56.default.createElement(CardContent, {
|
|
8938
8986
|
headless: true
|
|
8939
|
-
}, /* @__PURE__ */
|
|
8987
|
+
}, /* @__PURE__ */ import_react56.default.createElement("div", null, /* @__PURE__ */ import_react56.default.createElement("p", {
|
|
8940
8988
|
className: "mb-4 max-w-sm"
|
|
8941
|
-
}, "The team at Sikka Software is simply amazing. The tech is easy to follow, easy to work with, and infinitely flexible. The solution opportunities created by Tines are endless.")), /* @__PURE__ */
|
|
8989
|
+
}, "The team at Sikka Software is simply amazing. The tech is easy to follow, easy to work with, and infinitely flexible. The solution opportunities created by Tines are endless.")), /* @__PURE__ */ import_react56.default.createElement("div", {
|
|
8942
8990
|
className: "flex flex-row gap-4"
|
|
8943
|
-
}, /* @__PURE__ */
|
|
8991
|
+
}, /* @__PURE__ */ import_react56.default.createElement("svg", {
|
|
8944
8992
|
width: "48",
|
|
8945
8993
|
height: "48",
|
|
8946
8994
|
viewBox: "0 0 48 48",
|
|
8947
8995
|
fill: "none"
|
|
8948
|
-
}, /* @__PURE__ */
|
|
8996
|
+
}, /* @__PURE__ */ import_react56.default.createElement("rect", {
|
|
8949
8997
|
width: "48",
|
|
8950
8998
|
height: "48",
|
|
8951
8999
|
rx: "24",
|
|
8952
9000
|
fill: "#45BE8B"
|
|
8953
|
-
}), /* @__PURE__ */
|
|
9001
|
+
}), /* @__PURE__ */ import_react56.default.createElement("path", {
|
|
8954
9002
|
d: "M14.1412 22.4427L17.5803 16.5199C17.7671 16.1981 18.1112 16 18.4834 16H20.8581C21.653 16 22.1565 16.8528 21.7725 17.5488L19.3042 22.0225C19.2202 22.1747 19.1762 22.3458 19.1762 22.5196C19.1762 23.0879 19.6369 23.5486 20.2052 23.5486H21.5827C22.1594 23.5486 22.627 24.0162 22.627 24.5929V31.347C22.627 31.9237 22.1594 32.3913 21.5827 32.3913H15.0443C14.4676 32.3913 14 31.9237 14 31.347V22.9671C14 22.7829 14.0487 22.602 14.1412 22.4427Z",
|
|
8955
9003
|
fill: "#FFFFFF"
|
|
8956
|
-
}), /* @__PURE__ */
|
|
9004
|
+
}), /* @__PURE__ */ import_react56.default.createElement("path", {
|
|
8957
9005
|
d: "M25.356 22.4427L28.7951 16.5199C28.982 16.1981 29.326 16 29.6982 16H32.0729C32.8679 16 33.3713 16.8528 32.9873 17.5488L30.5191 22.0225C30.4351 22.1747 30.391 22.3458 30.391 22.5196C30.391 23.0879 30.8518 23.5486 31.4201 23.5486H32.7975C33.3743 23.5486 33.8418 24.0162 33.8418 24.5929V31.347C33.8418 31.9237 33.3743 32.3913 32.7975 32.3913H26.2592C25.6824 32.3913 25.2148 31.9237 25.2148 31.347V22.9671C25.2148 22.7829 25.2636 22.602 25.356 22.4427Z",
|
|
8958
9006
|
fill: "#FFFFFF"
|
|
8959
|
-
})), /* @__PURE__ */
|
|
9007
|
+
})), /* @__PURE__ */ import_react56.default.createElement("span", {
|
|
8960
9008
|
className: "border border-l "
|
|
8961
|
-
}), " ", /* @__PURE__ */
|
|
9009
|
+
}), " ", /* @__PURE__ */ import_react56.default.createElement("div", null, /* @__PURE__ */ import_react56.default.createElement("strong", null, "Brent Lassi"), /* @__PURE__ */ import_react56.default.createElement("div", null, " Chief Information Security Officer")))));
|
|
8962
9010
|
};
|
|
8963
9011
|
// components/blocks/misc/LeadGenerator.tsx
|
|
8964
|
-
var
|
|
9012
|
+
var import_react57 = __toESM(require("react"));
|
|
8965
9013
|
var import_react_hook_form8 = require("react-hook-form");
|
|
8966
9014
|
var LeadGenerator = function(param) {
|
|
8967
9015
|
var texts = param.texts, submitHandler = param.submitHandler;
|
|
@@ -8974,11 +9022,11 @@ var LeadGenerator = function(param) {
|
|
|
8974
9022
|
}
|
|
8975
9023
|
};
|
|
8976
9024
|
var _texts_submit;
|
|
8977
|
-
return /* @__PURE__ */
|
|
9025
|
+
return /* @__PURE__ */ import_react57.default.createElement(Card, null, /* @__PURE__ */ import_react57.default.createElement(CardHeader, null, /* @__PURE__ */ import_react57.default.createElement(CardTitle, null, texts === null || texts === void 0 ? void 0 : texts.title), /* @__PURE__ */ import_react57.default.createElement(CardDescription, null, texts === null || texts === void 0 ? void 0 : texts.subtitle)), /* @__PURE__ */ import_react57.default.createElement(CardContent, null, /* @__PURE__ */ import_react57.default.createElement("form", {
|
|
8978
9026
|
noValidate: true,
|
|
8979
9027
|
className: "hawa-flex hawa-flex-row hawa-gap-2",
|
|
8980
9028
|
onSubmit: handleSubmit(onSubmit)
|
|
8981
|
-
}, /* @__PURE__ */
|
|
9029
|
+
}, /* @__PURE__ */ import_react57.default.createElement(import_react_hook_form8.Controller, {
|
|
8982
9030
|
name: "email",
|
|
8983
9031
|
control: control,
|
|
8984
9032
|
rules: {
|
|
@@ -8991,32 +9039,32 @@ var LeadGenerator = function(param) {
|
|
|
8991
9039
|
defaultValue: "",
|
|
8992
9040
|
render: function(param) {
|
|
8993
9041
|
var field = param.field;
|
|
8994
|
-
return /* @__PURE__ */
|
|
9042
|
+
return /* @__PURE__ */ import_react57.default.createElement(Input, _object_spread_props(_object_spread({}, field), {
|
|
8995
9043
|
type: "email",
|
|
8996
9044
|
placeholder: "example@sikka.io"
|
|
8997
9045
|
}));
|
|
8998
9046
|
}
|
|
8999
|
-
}), /* @__PURE__ */
|
|
9047
|
+
}), /* @__PURE__ */ import_react57.default.createElement(Button, {
|
|
9000
9048
|
type: "submit",
|
|
9001
9049
|
disabled: !formState.isValid
|
|
9002
9050
|
}, (_texts_submit = texts === null || texts === void 0 ? void 0 : texts.submit) !== null && _texts_submit !== void 0 ? _texts_submit : "Submit"))));
|
|
9003
9051
|
};
|
|
9004
9052
|
// components/blocks/misc/Announcement.tsx
|
|
9005
|
-
var
|
|
9053
|
+
var import_react58 = __toESM(require("react"));
|
|
9006
9054
|
var Announcement = function(_param) {
|
|
9007
9055
|
var onActionClick = _param.onActionClick, props = _object_without_properties(_param, [
|
|
9008
9056
|
"onActionClick"
|
|
9009
9057
|
]);
|
|
9010
|
-
return /* @__PURE__ */
|
|
9058
|
+
return /* @__PURE__ */ import_react58.default.createElement(Card, null, /* @__PURE__ */ import_react58.default.createElement(CardContent, {
|
|
9011
9059
|
headless: true,
|
|
9012
9060
|
className: "hawa-flex hawa-flex-row hawa-items-center hawa-justify-between"
|
|
9013
|
-
}, /* @__PURE__ */
|
|
9061
|
+
}, /* @__PURE__ */ import_react58.default.createElement("div", {
|
|
9014
9062
|
className: "hawa-flex hawa-flex-col hawa-items-start hawa-justify-center "
|
|
9015
|
-
}, /* @__PURE__ */
|
|
9063
|
+
}, /* @__PURE__ */ import_react58.default.createElement("span", {
|
|
9016
9064
|
className: "hawa-text-lg hawa-font-bold"
|
|
9017
|
-
}, props.title), /* @__PURE__ */
|
|
9065
|
+
}, props.title), /* @__PURE__ */ import_react58.default.createElement("span", {
|
|
9018
9066
|
className: "hawa-text-sm"
|
|
9019
|
-
}, props.subtitle)), /* @__PURE__ */
|
|
9067
|
+
}, props.subtitle)), /* @__PURE__ */ import_react58.default.createElement(Button, {
|
|
9020
9068
|
onClick: function() {
|
|
9021
9069
|
return onActionClick();
|
|
9022
9070
|
},
|
|
@@ -9024,56 +9072,56 @@ var Announcement = function(_param) {
|
|
|
9024
9072
|
}, props.actionText)));
|
|
9025
9073
|
};
|
|
9026
9074
|
// components/blocks/misc/NotFound.tsx
|
|
9027
|
-
var
|
|
9075
|
+
var import_react59 = __toESM(require("react"));
|
|
9028
9076
|
var NotFound = function(param) {
|
|
9029
9077
|
var _param_variant = param.variant, variant = _param_variant === void 0 ? "contained" : _param_variant, texts = param.texts;
|
|
9030
9078
|
var _texts_pageNotFound, _texts_ifLost, _texts_home;
|
|
9031
|
-
return /* @__PURE__ */
|
|
9079
|
+
return /* @__PURE__ */ import_react59.default.createElement(Card, null, /* @__PURE__ */ import_react59.default.createElement(CardContent, {
|
|
9032
9080
|
headless: true
|
|
9033
|
-
}, /* @__PURE__ */
|
|
9081
|
+
}, /* @__PURE__ */ import_react59.default.createElement("div", {
|
|
9034
9082
|
className: "hawa-flex hawa-flex-col hawa-items-center dark:hawa-text-white"
|
|
9035
|
-
}, /* @__PURE__ */
|
|
9083
|
+
}, /* @__PURE__ */ import_react59.default.createElement("div", {
|
|
9036
9084
|
className: "hawa-text-center hawa-text-6xl hawa-font-bold "
|
|
9037
|
-
}, "404"), /* @__PURE__ */
|
|
9085
|
+
}, "404"), /* @__PURE__ */ import_react59.default.createElement("div", {
|
|
9038
9086
|
className: "hawa-m-2 hawa-text-center hawa-text-xl hawa-font-bold "
|
|
9039
|
-
}, (_texts_pageNotFound = texts === null || texts === void 0 ? void 0 : texts.pageNotFound) !== null && _texts_pageNotFound !== void 0 ? _texts_pageNotFound : "Page Not Found"), /* @__PURE__ */
|
|
9087
|
+
}, (_texts_pageNotFound = texts === null || texts === void 0 ? void 0 : texts.pageNotFound) !== null && _texts_pageNotFound !== void 0 ? _texts_pageNotFound : "Page Not Found"), /* @__PURE__ */ import_react59.default.createElement("div", {
|
|
9040
9088
|
className: "hawa-mb-4 hawa-text-center"
|
|
9041
|
-
}, (_texts_ifLost = texts === null || texts === void 0 ? void 0 : texts.ifLost) !== null && _texts_ifLost !== void 0 ? _texts_ifLost : /* @__PURE__ */
|
|
9089
|
+
}, (_texts_ifLost = texts === null || texts === void 0 ? void 0 : texts.ifLost) !== null && _texts_ifLost !== void 0 ? _texts_ifLost : /* @__PURE__ */ import_react59.default.createElement(import_react59.default.Fragment, null, "If you're lost please contact us ", /* @__PURE__ */ import_react59.default.createElement("span", {
|
|
9042
9090
|
className: "clickable-link"
|
|
9043
|
-
}, "help@sikka.io"))), /* @__PURE__ */
|
|
9091
|
+
}, "help@sikka.io"))), /* @__PURE__ */ import_react59.default.createElement(Button, {
|
|
9044
9092
|
className: "hawa-w-full"
|
|
9045
9093
|
}, (_texts_home = texts === null || texts === void 0 ? void 0 : texts.home) !== null && _texts_home !== void 0 ? _texts_home : "Home"))));
|
|
9046
9094
|
};
|
|
9047
9095
|
// components/blocks/misc/NoPermission.tsx
|
|
9048
|
-
var
|
|
9096
|
+
var import_react60 = __toESM(require("react"));
|
|
9049
9097
|
var NoPermission = function(param) {
|
|
9050
9098
|
var texts = param.texts;
|
|
9051
9099
|
var _texts_title, _texts_subtitle;
|
|
9052
|
-
return /* @__PURE__ */
|
|
9100
|
+
return /* @__PURE__ */ import_react60.default.createElement(Card, null, /* @__PURE__ */ import_react60.default.createElement(CardContent, {
|
|
9053
9101
|
headless: true
|
|
9054
|
-
}, /* @__PURE__ */
|
|
9102
|
+
}, /* @__PURE__ */ import_react60.default.createElement("div", {
|
|
9055
9103
|
className: "hawa-flex hawa-flex-col hawa-items-center hawa-justify-center hawa-text-center"
|
|
9056
|
-
}, /* @__PURE__ */
|
|
9104
|
+
}, /* @__PURE__ */ import_react60.default.createElement("div", {
|
|
9057
9105
|
className: "hawa-flex hawa-h-10 hawa-w-10 hawa-flex-col hawa-items-center hawa-justify-center hawa-rounded-3xl hawa-bg-primary hawa-text-6xl hawa-font-bold hawa-text-primary-foreground"
|
|
9058
|
-
}, /* @__PURE__ */
|
|
9106
|
+
}, /* @__PURE__ */ import_react60.default.createElement("svg", {
|
|
9059
9107
|
stroke: "currentColor",
|
|
9060
9108
|
fill: "currentColor",
|
|
9061
9109
|
strokeWidth: "0",
|
|
9062
9110
|
viewBox: "0 0 448 512",
|
|
9063
9111
|
height: "0.35em",
|
|
9064
9112
|
width: "0.35em"
|
|
9065
|
-
}, /* @__PURE__ */
|
|
9113
|
+
}, /* @__PURE__ */ import_react60.default.createElement("path", {
|
|
9066
9114
|
d: "M400 224h-24v-72C376 68.2 307.8 0 224 0S72 68.2 72 152v72H48c-26.5 0-48 21.5-48 48v192c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48V272c0-26.5-21.5-48-48-48zm-104 0H152v-72c0-39.7 32.3-72 72-72s72 32.3 72 72v72z"
|
|
9067
|
-
})), " "), /* @__PURE__ */
|
|
9115
|
+
})), " "), /* @__PURE__ */ import_react60.default.createElement("div", {
|
|
9068
9116
|
className: "hawa-m-2 hawa-text-xl hawa-font-bold"
|
|
9069
|
-
}, (_texts_title = texts === null || texts === void 0 ? void 0 : texts.title) !== null && _texts_title !== void 0 ? _texts_title : "You don't have permission"), /* @__PURE__ */
|
|
9117
|
+
}, (_texts_title = texts === null || texts === void 0 ? void 0 : texts.title) !== null && _texts_title !== void 0 ? _texts_title : "You don't have permission"), /* @__PURE__ */ import_react60.default.createElement("div", null, (_texts_subtitle = texts === null || texts === void 0 ? void 0 : texts.subtitle) !== null && _texts_subtitle !== void 0 ? _texts_subtitle : "If you think this is a problem please contact your administrator or our customer support"))));
|
|
9070
9118
|
};
|
|
9071
9119
|
// components/blocks/pricing/PricingPlans.tsx
|
|
9072
|
-
var
|
|
9120
|
+
var import_react61 = __toESM(require("react"));
|
|
9073
9121
|
var PricingPlans = function(props) {
|
|
9074
|
-
return /* @__PURE__ */
|
|
9122
|
+
return /* @__PURE__ */ import_react61.default.createElement("div", null, /* @__PURE__ */ import_react61.default.createElement("div", {
|
|
9075
9123
|
className: "hawa-mb-2 hawa-flex hawa-w-full hawa-justify-between"
|
|
9076
|
-
}, /* @__PURE__ */
|
|
9124
|
+
}, /* @__PURE__ */ import_react61.default.createElement(Radio, {
|
|
9077
9125
|
design: "tabs",
|
|
9078
9126
|
defaultValue: props.currentCycle,
|
|
9079
9127
|
options: props.billingCycles,
|
|
@@ -9082,7 +9130,7 @@ var PricingPlans = function(props) {
|
|
|
9082
9130
|
props.onCycleChange(e);
|
|
9083
9131
|
}
|
|
9084
9132
|
}
|
|
9085
|
-
}), /* @__PURE__ */
|
|
9133
|
+
}), /* @__PURE__ */ import_react61.default.createElement(Radio, {
|
|
9086
9134
|
design: "tabs",
|
|
9087
9135
|
defaultValue: props.currentCurrency,
|
|
9088
9136
|
options: props.currencies,
|
|
@@ -9091,10 +9139,10 @@ var PricingPlans = function(props) {
|
|
|
9091
9139
|
props.onCurrencyChange(e);
|
|
9092
9140
|
}
|
|
9093
9141
|
}
|
|
9094
|
-
})), /* @__PURE__ */
|
|
9142
|
+
})), /* @__PURE__ */ import_react61.default.createElement("div", {
|
|
9095
9143
|
className: "hawa-flex hawa-flex-row hawa-justify-between"
|
|
9096
9144
|
}, props.plans.map(function(plan, index) {
|
|
9097
|
-
return /* @__PURE__ */
|
|
9145
|
+
return /* @__PURE__ */ import_react61.default.createElement(PricingCard, _object_spread_props(_object_spread({
|
|
9098
9146
|
key: index,
|
|
9099
9147
|
onPlanClicked: function() {
|
|
9100
9148
|
if (props.onPlanClicked) {
|
|
@@ -9115,26 +9163,26 @@ var PricingPlans = function(props) {
|
|
|
9115
9163
|
})));
|
|
9116
9164
|
};
|
|
9117
9165
|
// components/blocks/pricing/ComparingPlans.tsx
|
|
9118
|
-
var
|
|
9166
|
+
var import_react62 = __toESM(require("react"));
|
|
9119
9167
|
var CheckMark = function() {
|
|
9120
|
-
return /* @__PURE__ */
|
|
9168
|
+
return /* @__PURE__ */ import_react62.default.createElement("svg", {
|
|
9121
9169
|
className: "hawa-h-5 hawa-w-5 hawa-text-green-500",
|
|
9122
9170
|
"aria-hidden": "true",
|
|
9123
9171
|
fill: "currentColor",
|
|
9124
9172
|
viewBox: "0 0 20 20"
|
|
9125
|
-
}, /* @__PURE__ */
|
|
9173
|
+
}, /* @__PURE__ */ import_react62.default.createElement("path", {
|
|
9126
9174
|
fillRule: "evenodd",
|
|
9127
9175
|
d: "M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z",
|
|
9128
9176
|
clipRule: "evenodd"
|
|
9129
9177
|
}));
|
|
9130
9178
|
};
|
|
9131
9179
|
var UncheckMark = function() {
|
|
9132
|
-
return /* @__PURE__ */
|
|
9180
|
+
return /* @__PURE__ */ import_react62.default.createElement("svg", {
|
|
9133
9181
|
className: "hawa-h-5 hawa-w-5 hawa-text-red-500",
|
|
9134
9182
|
"aria-hidden": "true",
|
|
9135
9183
|
fill: "currentColor",
|
|
9136
9184
|
viewBox: "0 0 20 20"
|
|
9137
|
-
}, /* @__PURE__ */
|
|
9185
|
+
}, /* @__PURE__ */ import_react62.default.createElement("path", {
|
|
9138
9186
|
fillRule: "evenodd",
|
|
9139
9187
|
d: "M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z",
|
|
9140
9188
|
clipRule: "evenodd"
|
|
@@ -9142,14 +9190,14 @@ var UncheckMark = function() {
|
|
|
9142
9190
|
};
|
|
9143
9191
|
var ComparingPlans = function(props) {
|
|
9144
9192
|
var _props_plans;
|
|
9145
|
-
var _ref = _sliced_to_array((0,
|
|
9146
|
-
var _ref1 = _sliced_to_array((0,
|
|
9147
|
-
return /* @__PURE__ */
|
|
9193
|
+
var _ref = _sliced_to_array((0, import_react62.useState)("sar"), 2), currentCurrency = _ref[0], setCurrentCurrency = _ref[1];
|
|
9194
|
+
var _ref1 = _sliced_to_array((0, import_react62.useState)("month"), 2), currentCycle = _ref1[0], setCurrentCycle = _ref1[1];
|
|
9195
|
+
return /* @__PURE__ */ import_react62.default.createElement("div", {
|
|
9148
9196
|
id: "detailed-pricing",
|
|
9149
9197
|
className: "hawa-w-full hawa-overflow-x-auto"
|
|
9150
|
-
}, /* @__PURE__ */
|
|
9198
|
+
}, /* @__PURE__ */ import_react62.default.createElement("div", {
|
|
9151
9199
|
className: "hawa-mb-2 hawa-flex hawa-w-full hawa-justify-between"
|
|
9152
|
-
}, /* @__PURE__ */
|
|
9200
|
+
}, /* @__PURE__ */ import_react62.default.createElement(Radio, {
|
|
9153
9201
|
design: "tabs",
|
|
9154
9202
|
defaultValue: currentCycle,
|
|
9155
9203
|
options: props.billingCycles,
|
|
@@ -9160,7 +9208,7 @@ var ComparingPlans = function(props) {
|
|
|
9160
9208
|
console.log("onCycleChange was not provided");
|
|
9161
9209
|
}
|
|
9162
9210
|
}
|
|
9163
|
-
}), /* @__PURE__ */
|
|
9211
|
+
}), /* @__PURE__ */ import_react62.default.createElement(Radio, {
|
|
9164
9212
|
design: "tabs",
|
|
9165
9213
|
defaultValue: currentCurrency,
|
|
9166
9214
|
options: props.currencies,
|
|
@@ -9171,56 +9219,56 @@ var ComparingPlans = function(props) {
|
|
|
9171
9219
|
console.log("onCurrencyChange was not provided");
|
|
9172
9220
|
}
|
|
9173
9221
|
}
|
|
9174
|
-
})), /* @__PURE__ */
|
|
9222
|
+
})), /* @__PURE__ */ import_react62.default.createElement("div", {
|
|
9175
9223
|
className: " hawa-overflow-hidden hawa-rounded"
|
|
9176
|
-
}, /* @__PURE__ */
|
|
9224
|
+
}, /* @__PURE__ */ import_react62.default.createElement("div", {
|
|
9177
9225
|
className: "hawa-grid hawa-grid-cols-4 hawa-gap-x-2 hawa-border-b hawa-border-t hawa-border-gray-200 hawa-bg-gray-100 hawa-p-4 hawa-text-sm hawa-font-medium hawa-text-gray-900 dark:hawa-border-gray-700 dark:hawa-bg-gray-800 dark:hawa-text-white"
|
|
9178
|
-
}, /* @__PURE__ */
|
|
9226
|
+
}, /* @__PURE__ */ import_react62.default.createElement("div", {
|
|
9179
9227
|
className: "hawa-flex hawa-items-center"
|
|
9180
9228
|
}), props.plans.map(function(plan, i) {
|
|
9181
|
-
return /* @__PURE__ */
|
|
9229
|
+
return /* @__PURE__ */ import_react62.default.createElement("div", {
|
|
9182
9230
|
key: i
|
|
9183
|
-
}, /* @__PURE__ */
|
|
9231
|
+
}, /* @__PURE__ */ import_react62.default.createElement("h5", {
|
|
9184
9232
|
className: "hawa-text-md hawa-font-bold hawa-text-gray-500 dark:hawa-text-gray-400"
|
|
9185
|
-
}, plan.texts.title), /* @__PURE__ */
|
|
9233
|
+
}, plan.texts.title), /* @__PURE__ */ import_react62.default.createElement("div", {
|
|
9186
9234
|
className: " hawa-flex hawa-items-baseline hawa-text-gray-900 dark:hawa-text-white"
|
|
9187
|
-
}, /* @__PURE__ */
|
|
9235
|
+
}, /* @__PURE__ */ import_react62.default.createElement(import_react62.default.Fragment, null, /* @__PURE__ */ import_react62.default.createElement("span", {
|
|
9188
9236
|
className: "hawa-text-5xl hawa-font-extrabold hawa-tracking-tight"
|
|
9189
|
-
}, plan.price), /* @__PURE__ */
|
|
9237
|
+
}, plan.price), /* @__PURE__ */ import_react62.default.createElement("span", {
|
|
9190
9238
|
className: "hawa-mx-1 hawa-text-sm hawa-font-semibold"
|
|
9191
|
-
}, plan.texts.currencyText)), /* @__PURE__ */
|
|
9239
|
+
}, plan.texts.currencyText)), /* @__PURE__ */ import_react62.default.createElement("span", {
|
|
9192
9240
|
className: "hawa-ml-1 hawa-text-xl hawa-font-normal hawa-text-gray-500 dark:hawa-text-gray-400"
|
|
9193
|
-
}, "/ ", plan.texts.cycleText)), /* @__PURE__ */
|
|
9241
|
+
}, "/ ", plan.texts.cycleText)), /* @__PURE__ */ import_react62.default.createElement("h5", {
|
|
9194
9242
|
className: "hawa-text-md hawa-font-normal hawa-text-gray-500 dark:hawa-text-gray-400"
|
|
9195
9243
|
}, plan.texts.subtitle));
|
|
9196
9244
|
})), (_props_plans = props.plans) === null || _props_plans === void 0 ? void 0 : _props_plans.map(function(plan) {
|
|
9197
9245
|
return plan.features.map(function(feature, j) {
|
|
9198
|
-
return /* @__PURE__ */
|
|
9246
|
+
return /* @__PURE__ */ import_react62.default.createElement("div", {
|
|
9199
9247
|
key: j,
|
|
9200
9248
|
className: "hawa-grid hawa-grid-cols-4 hawa-gap-x-16 hawa-border-b hawa-border-gray-200 hawa-px-4 hawa-py-5 hawa-text-sm hawa-text-gray-700 dark:hawa-border-gray-700"
|
|
9201
|
-
}, /* @__PURE__ */
|
|
9249
|
+
}, /* @__PURE__ */ import_react62.default.createElement("div", {
|
|
9202
9250
|
className: " hawa-flex hawa-flex-row hawa-items-center hawa-gap-2 hawa-text-gray-500 dark:hawa-text-gray-400"
|
|
9203
|
-
}, feature.text, feature.description && /* @__PURE__ */
|
|
9251
|
+
}, feature.text, feature.description && /* @__PURE__ */ import_react62.default.createElement(Tooltip, {
|
|
9204
9252
|
side: "right",
|
|
9205
9253
|
content: feature.description
|
|
9206
|
-
}, /* @__PURE__ */
|
|
9254
|
+
}, /* @__PURE__ */ import_react62.default.createElement("svg", {
|
|
9207
9255
|
stroke: "currentColor",
|
|
9208
9256
|
fill: "currentColor",
|
|
9209
9257
|
strokeWidth: "0",
|
|
9210
9258
|
viewBox: "0 0 16 16",
|
|
9211
9259
|
height: "1em",
|
|
9212
9260
|
width: "1em"
|
|
9213
|
-
}, /* @__PURE__ */
|
|
9261
|
+
}, /* @__PURE__ */ import_react62.default.createElement("path", {
|
|
9214
9262
|
d: "M16 8A8 8 0 1 1 0 8a8 8 0 0 1 16 0zM8 4a.905.905 0 0 0-.9.995l.35 3.507a.552.552 0 0 0 1.1 0l.35-3.507A.905.905 0 0 0 8 4zm.002 6a1 1 0 1 0 0 2 1 1 0 0 0 0-2z"
|
|
9215
|
-
})))), /* @__PURE__ */
|
|
9263
|
+
})))), /* @__PURE__ */ import_react62.default.createElement(UncheckMark, null), /* @__PURE__ */ import_react62.default.createElement(CheckMark, null), /* @__PURE__ */ import_react62.default.createElement(UncheckMark, null));
|
|
9216
9264
|
});
|
|
9217
9265
|
})));
|
|
9218
9266
|
};
|
|
9219
9267
|
// components/blocks/pricing/HorizontalPricing.tsx
|
|
9220
|
-
var
|
|
9268
|
+
var import_react63 = __toESM(require("react"));
|
|
9221
9269
|
var import_clsx12 = __toESM(require("clsx"));
|
|
9222
9270
|
var HorizontalPricing = function(props) {
|
|
9223
|
-
var _ref = _sliced_to_array((0,
|
|
9271
|
+
var _ref = _sliced_to_array((0, import_react63.useState)(""), 2), selectedCard = _ref[0], setSelectedCard = _ref[1];
|
|
9224
9272
|
var data = [
|
|
9225
9273
|
{
|
|
9226
9274
|
title: "basic",
|
|
@@ -9238,96 +9286,96 @@ var HorizontalPricing = function(props) {
|
|
|
9238
9286
|
cycle: "/mo"
|
|
9239
9287
|
}
|
|
9240
9288
|
];
|
|
9241
|
-
return /* @__PURE__ */
|
|
9289
|
+
return /* @__PURE__ */ import_react63.default.createElement("div", {
|
|
9242
9290
|
className: "hawa-z-10 hawa-w-full hawa-max-w-screen-sm"
|
|
9243
|
-
}, /* @__PURE__ */
|
|
9291
|
+
}, /* @__PURE__ */ import_react63.default.createElement("div", {
|
|
9244
9292
|
className: "hawa-max-w-2xl "
|
|
9245
|
-
}, /* @__PURE__ */
|
|
9293
|
+
}, /* @__PURE__ */ import_react63.default.createElement("div", {
|
|
9246
9294
|
className: "hawa-flex hawa-flex-row hawa-justify-between"
|
|
9247
|
-
}, /* @__PURE__ */
|
|
9295
|
+
}, /* @__PURE__ */ import_react63.default.createElement(Radio, {
|
|
9248
9296
|
design: "tabs",
|
|
9249
9297
|
options: props.currencies,
|
|
9250
9298
|
defaultValue: props.currentCurrency
|
|
9251
|
-
}), /* @__PURE__ */
|
|
9299
|
+
}), /* @__PURE__ */ import_react63.default.createElement(Radio, {
|
|
9252
9300
|
design: "tabs",
|
|
9253
9301
|
options: props.billingCycles,
|
|
9254
9302
|
defaultValue: props.currentCycle
|
|
9255
9303
|
})), data.map(function(d, i) {
|
|
9256
|
-
return /* @__PURE__ */
|
|
9304
|
+
return /* @__PURE__ */ import_react63.default.createElement("label", {
|
|
9257
9305
|
key: i,
|
|
9258
9306
|
htmlFor: d.title,
|
|
9259
9307
|
className: "",
|
|
9260
9308
|
onClick: function() {
|
|
9261
9309
|
return setSelectedCard(d.title);
|
|
9262
9310
|
}
|
|
9263
|
-
}, /* @__PURE__ */
|
|
9311
|
+
}, /* @__PURE__ */ import_react63.default.createElement("input", {
|
|
9264
9312
|
type: "radio",
|
|
9265
9313
|
name: "radio",
|
|
9266
9314
|
id: d.title,
|
|
9267
9315
|
className: "hawa-peer hawa-appearance-none"
|
|
9268
|
-
}), /* @__PURE__ */
|
|
9316
|
+
}), /* @__PURE__ */ import_react63.default.createElement("div", {
|
|
9269
9317
|
className: (0, import_clsx12.default)(selectedCard === d.title ? "peer-checked:hawa-border-primary peer-checked:hawa-ring-primary/20 peer-checked:hawa-ring-4 " : "", "hawa-peer hawa-flex hawa-cursor-pointer hawa-items-center hawa-justify-between hawa-rounded-xl hawa-border hawa-bg-background hawa-px-5 hawa-py-4 hawa-shadow dark:hawa-text-white peer-checked:[&_.active]:hawa-block peer-checked:[&_.default]:hawa-hidden")
|
|
9270
|
-
}, /* @__PURE__ */
|
|
9318
|
+
}, /* @__PURE__ */ import_react63.default.createElement("div", {
|
|
9271
9319
|
className: "hawa-peer hawa-flex hawa-items-center hawa-gap-4"
|
|
9272
|
-
}, /* @__PURE__ */
|
|
9320
|
+
}, /* @__PURE__ */ import_react63.default.createElement(CheckIcons, null), /* @__PURE__ */ import_react63.default.createElement(CardText, {
|
|
9273
9321
|
title: "Enterprise",
|
|
9274
9322
|
subtitle: "For startups and new businesses"
|
|
9275
|
-
})), /* @__PURE__ */
|
|
9323
|
+
})), /* @__PURE__ */ import_react63.default.createElement(CardPrice, {
|
|
9276
9324
|
amount: d.price,
|
|
9277
9325
|
cycle: d.cycle
|
|
9278
9326
|
})));
|
|
9279
9327
|
})));
|
|
9280
9328
|
};
|
|
9281
9329
|
var CheckIcons = function() {
|
|
9282
|
-
return /* @__PURE__ */
|
|
9330
|
+
return /* @__PURE__ */ import_react63.default.createElement(import_react63.default.Fragment, null, /* @__PURE__ */ import_react63.default.createElement("svg", {
|
|
9283
9331
|
fill: "none",
|
|
9284
9332
|
viewBox: "0 0 24 24",
|
|
9285
9333
|
strokeWidth: "1.5",
|
|
9286
9334
|
stroke: "currentColor",
|
|
9287
9335
|
className: "hawa-default hawa-h-8 hawa-w-8 hawa-text-neutral-500"
|
|
9288
|
-
}, /* @__PURE__ */
|
|
9336
|
+
}, /* @__PURE__ */ import_react63.default.createElement("path", {
|
|
9289
9337
|
strokeLinecap: "round",
|
|
9290
9338
|
strokeLinejoin: "round",
|
|
9291
9339
|
d: "M9 12.75L11.25 15 15 9.75M21 12a9 9 0 11-18 0 9 9 0 0118 0z"
|
|
9292
|
-
})), /* @__PURE__ */
|
|
9340
|
+
})), /* @__PURE__ */ import_react63.default.createElement("svg", {
|
|
9293
9341
|
viewBox: "0 0 24 24",
|
|
9294
9342
|
fill: "currentColor",
|
|
9295
9343
|
className: "hawa-active hawa-hidden hawa-h-8 hawa-w-8 hawa-text-blue-500"
|
|
9296
|
-
}, /* @__PURE__ */
|
|
9344
|
+
}, /* @__PURE__ */ import_react63.default.createElement("path", {
|
|
9297
9345
|
fillRule: "evenodd",
|
|
9298
9346
|
clipRule: "evenodd",
|
|
9299
9347
|
d: "M2.25 12c0-5.385 4.365-9.75 9.75-9.75s9.75 4.365 9.75 9.75-4.365 9.75-9.75 9.75S2.25 17.385 2.25 12zm13.36-1.814a.75.75 0 10-1.22-.872l-3.236 4.53L9.53 12.22a.75.75 0 00-1.06 1.06l2.25 2.25a.75.75 0 001.14-.094l3.75-5.25z"
|
|
9300
9348
|
})));
|
|
9301
9349
|
};
|
|
9302
9350
|
var CardText = function(props) {
|
|
9303
|
-
return /* @__PURE__ */
|
|
9351
|
+
return /* @__PURE__ */ import_react63.default.createElement("div", {
|
|
9304
9352
|
className: "hawa-peer hawa-flex hawa-flex-col hawa-items-start "
|
|
9305
|
-
}, /* @__PURE__ */
|
|
9353
|
+
}, /* @__PURE__ */ import_react63.default.createElement("h2", {
|
|
9306
9354
|
className: "hawa-font-medium hawa-text-primary/90 sm:hawa-text-xl"
|
|
9307
|
-
}, props.title), /* @__PURE__ */
|
|
9355
|
+
}, props.title), /* @__PURE__ */ import_react63.default.createElement("p", {
|
|
9308
9356
|
className: "hawa-text-sm hawa-text-primary/60"
|
|
9309
9357
|
}, props.subtitle, " "));
|
|
9310
9358
|
};
|
|
9311
9359
|
var CardPrice = function(props) {
|
|
9312
|
-
return /* @__PURE__ */
|
|
9360
|
+
return /* @__PURE__ */ import_react63.default.createElement("h2", {
|
|
9313
9361
|
className: "hawa-peer hawa-text-xl hawa-font-semibold hawa-text-primary sm:hawa-text-2xl"
|
|
9314
|
-
}, props.amount, /* @__PURE__ */
|
|
9362
|
+
}, props.amount, /* @__PURE__ */ import_react63.default.createElement("span", {
|
|
9315
9363
|
className: "hawa-text-base hawa-font-medium hawa-text-neutral-400"
|
|
9316
9364
|
}, props.cycle));
|
|
9317
9365
|
};
|
|
9318
9366
|
// components/blocks/Usage.tsx
|
|
9319
|
-
var
|
|
9367
|
+
var import_react64 = __toESM(require("react"));
|
|
9320
9368
|
var Usage = function(props) {
|
|
9321
9369
|
var _props_percent;
|
|
9322
|
-
return /* @__PURE__ */
|
|
9370
|
+
return /* @__PURE__ */ import_react64.default.createElement("div", {
|
|
9323
9371
|
className: "hawa-flex hawa-w-full hawa-flex-col hawa-gap-1 hawa-rounded hawa-border hawa-bg-card hawa-p-4"
|
|
9324
|
-
}, /* @__PURE__ */
|
|
9372
|
+
}, /* @__PURE__ */ import_react64.default.createElement("div", {
|
|
9325
9373
|
className: "hawa-flex hawa-flex-row hawa-items-center hawa-gap-2"
|
|
9326
|
-
}, /* @__PURE__ */
|
|
9374
|
+
}, /* @__PURE__ */ import_react64.default.createElement("span", {
|
|
9327
9375
|
className: "hawa-bg-white-200"
|
|
9328
|
-
}, props.title), props.tooltip && /* @__PURE__ */
|
|
9376
|
+
}, props.title), props.tooltip && /* @__PURE__ */ import_react64.default.createElement(Tooltip, {
|
|
9329
9377
|
content: props.tooltip
|
|
9330
|
-
}, /* @__PURE__ */
|
|
9378
|
+
}, /* @__PURE__ */ import_react64.default.createElement("svg", {
|
|
9331
9379
|
stroke: "currentColor",
|
|
9332
9380
|
"aria-label": "Exclamation Circle",
|
|
9333
9381
|
fill: "currentColor",
|
|
@@ -9335,28 +9383,28 @@ var Usage = function(props) {
|
|
|
9335
9383
|
viewBox: "0 0 16 16",
|
|
9336
9384
|
height: "1em",
|
|
9337
9385
|
width: "1em"
|
|
9338
|
-
}, /* @__PURE__ */
|
|
9386
|
+
}, /* @__PURE__ */ import_react64.default.createElement("path", {
|
|
9339
9387
|
d: "M16 8A8 8 0 1 1 0 8a8 8 0 0 1 16 0zM8 4a.905.905 0 0 0-.9.995l.35 3.507a.552.552 0 0 0 1.1 0l.35-3.507A.905.905 0 0 0 8 4zm.002 6a1 1 0 1 0 0 2 1 1 0 0 0 0-2z"
|
|
9340
|
-
})))), /* @__PURE__ */
|
|
9388
|
+
})))), /* @__PURE__ */ import_react64.default.createElement("div", {
|
|
9341
9389
|
className: "hawa-bg-white-100 hawa-flex hawa-flex-row"
|
|
9342
|
-
}, /* @__PURE__ */
|
|
9390
|
+
}, /* @__PURE__ */ import_react64.default.createElement("div", null, props.currentUsage), /* @__PURE__ */ import_react64.default.createElement("div", null, " (", props.percent, "%)")), /* @__PURE__ */ import_react64.default.createElement(Progress, {
|
|
9343
9391
|
value: (_props_percent = props.percent) !== null && _props_percent !== void 0 ? _props_percent : 0
|
|
9344
9392
|
}));
|
|
9345
9393
|
};
|
|
9346
9394
|
// components/hooks/useDiscloser.ts
|
|
9347
|
-
var import_react64 = require("react");
|
|
9348
|
-
// components/hooks/useHover.ts
|
|
9349
9395
|
var import_react65 = require("react");
|
|
9350
|
-
// components/hooks/
|
|
9396
|
+
// components/hooks/useHover.ts
|
|
9351
9397
|
var import_react66 = require("react");
|
|
9352
|
-
// components/hooks/
|
|
9398
|
+
// components/hooks/useCarousel.ts
|
|
9353
9399
|
var import_react67 = require("react");
|
|
9400
|
+
// components/hooks/useWindowSize.ts
|
|
9401
|
+
var import_react68 = require("react");
|
|
9354
9402
|
var useWindowSize = function() {
|
|
9355
|
-
var _ref = _sliced_to_array((0,
|
|
9403
|
+
var _ref = _sliced_to_array((0, import_react68.useState)({
|
|
9356
9404
|
width: void 0,
|
|
9357
9405
|
height: void 0
|
|
9358
9406
|
}), 2), windowSize = _ref[0], setWindowSize = _ref[1];
|
|
9359
|
-
(0,
|
|
9407
|
+
(0, import_react68.useEffect)(function() {
|
|
9360
9408
|
var handleResize = function handleResize() {
|
|
9361
9409
|
setWindowSize({
|
|
9362
9410
|
width: window.innerWidth,
|
|
@@ -9372,7 +9420,7 @@ var useWindowSize = function() {
|
|
|
9372
9420
|
return windowSize;
|
|
9373
9421
|
};
|
|
9374
9422
|
// components/hooks/useFocusWithin.ts
|
|
9375
|
-
var
|
|
9423
|
+
var import_react69 = require("react");
|
|
9376
9424
|
function containsRelatedTarget(event) {
|
|
9377
9425
|
if (_instanceof(event.currentTarget, HTMLElement) && _instanceof(event.relatedTarget, HTMLElement)) {
|
|
9378
9426
|
return event.currentTarget.contains(event.relatedTarget);
|
|
@@ -9381,9 +9429,9 @@ function containsRelatedTarget(event) {
|
|
|
9381
9429
|
}
|
|
9382
9430
|
function useFocusWithin() {
|
|
9383
9431
|
var _ref = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, onBlur = _ref.onBlur, onFocus = _ref.onFocus;
|
|
9384
|
-
var ref = (0,
|
|
9385
|
-
var _ref1 = _sliced_to_array((0,
|
|
9386
|
-
var focusedRef = (0,
|
|
9432
|
+
var ref = (0, import_react69.useRef)(null);
|
|
9433
|
+
var _ref1 = _sliced_to_array((0, import_react69.useState)(false), 2), focused = _ref1[0], _setFocused = _ref1[1];
|
|
9434
|
+
var focusedRef = (0, import_react69.useRef)(false);
|
|
9387
9435
|
var setFocused = function(value) {
|
|
9388
9436
|
_setFocused(value);
|
|
9389
9437
|
focusedRef.current = value;
|
|
@@ -9400,7 +9448,7 @@ function useFocusWithin() {
|
|
|
9400
9448
|
onBlur === null || onBlur === void 0 ? void 0 : onBlur(event);
|
|
9401
9449
|
}
|
|
9402
9450
|
};
|
|
9403
|
-
(0,
|
|
9451
|
+
(0, import_react69.useEffect)(function() {
|
|
9404
9452
|
if (ref.current) {
|
|
9405
9453
|
ref.current.addEventListener("focusin", handleFocusIn);
|
|
9406
9454
|
ref.current.addEventListener("focusout", handleFocusOut);
|
|
@@ -9421,7 +9469,7 @@ function useFocusWithin() {
|
|
|
9421
9469
|
};
|
|
9422
9470
|
}
|
|
9423
9471
|
// components/hooks/useMediaQuery.ts
|
|
9424
|
-
var
|
|
9472
|
+
var import_react70 = require("react");
|
|
9425
9473
|
function attachMediaListener(query, callback) {
|
|
9426
9474
|
try {
|
|
9427
9475
|
query.addEventListener("change", callback);
|
|
@@ -9448,9 +9496,9 @@ function useMediaQuery(query, initialValue) {
|
|
|
9448
9496
|
var getInitialValueInEffect = (arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {
|
|
9449
9497
|
getInitialValueInEffect: true
|
|
9450
9498
|
}).getInitialValueInEffect;
|
|
9451
|
-
var _ref = _sliced_to_array((0,
|
|
9452
|
-
var queryRef = (0,
|
|
9453
|
-
(0,
|
|
9499
|
+
var _ref = _sliced_to_array((0, import_react70.useState)(getInitialValueInEffect ? initialValue : getInitialValue(query, initialValue)), 2), matches = _ref[0], setMatches = _ref[1];
|
|
9500
|
+
var queryRef = (0, import_react70.useRef)();
|
|
9501
|
+
(0, import_react70.useEffect)(function() {
|
|
9454
9502
|
if ("matchMedia" in window) {
|
|
9455
9503
|
queryRef.current = window.matchMedia(query);
|
|
9456
9504
|
setMatches(queryRef.current.matches);
|
|
@@ -9465,15 +9513,15 @@ function useMediaQuery(query, initialValue) {
|
|
|
9465
9513
|
return matches;
|
|
9466
9514
|
}
|
|
9467
9515
|
// components/hooks/useScrollPosition.ts
|
|
9468
|
-
var import_react70 = require("react");
|
|
9469
|
-
// components/hooks/useTable.ts
|
|
9470
9516
|
var import_react71 = require("react");
|
|
9471
|
-
// components/hooks/
|
|
9517
|
+
// components/hooks/useTable.ts
|
|
9472
9518
|
var import_react72 = require("react");
|
|
9519
|
+
// components/hooks/useTabs.ts
|
|
9520
|
+
var import_react73 = require("react");
|
|
9473
9521
|
function useTabs() {
|
|
9474
9522
|
var initialTab = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : "";
|
|
9475
|
-
var _ref = _sliced_to_array((0,
|
|
9476
|
-
(0,
|
|
9523
|
+
var _ref = _sliced_to_array((0, import_react73.useState)(initialTab), 2), activeTab = _ref[0], setActiveTab = _ref[1];
|
|
9524
|
+
(0, import_react73.useEffect)(function() {
|
|
9477
9525
|
var handleHashChange = function() {
|
|
9478
9526
|
var hash = window.location.hash.substring(1);
|
|
9479
9527
|
setActiveTab(hash || initialTab);
|