@underverse-ui/underverse 0.2.64 → 0.2.65
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/README.md +25 -1
- package/dist/Input-umeHzPJL.d.cts +110 -0
- package/dist/Input-umeHzPJL.d.ts +110 -0
- package/dist/chunk-A5NZI37V.js +1149 -0
- package/dist/chunk-A5NZI37V.js.map +1 -0
- package/dist/form.cjs +1287 -0
- package/dist/form.cjs.map +1 -0
- package/dist/form.d.cts +47 -0
- package/dist/form.d.ts +47 -0
- package/dist/form.js +167 -0
- package/dist/form.js.map +1 -0
- package/dist/index.cjs +117 -240
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +5 -150
- package/dist/index.d.ts +5 -150
- package/dist/index.js +1587 -2815
- package/dist/index.js.map +1 -1
- package/package.json +6 -1
package/dist/index.cjs
CHANGED
|
@@ -28,8 +28,8 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
28
28
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
29
|
|
|
30
30
|
// src/index.ts
|
|
31
|
-
var
|
|
32
|
-
__export(
|
|
31
|
+
var src_exports = {};
|
|
32
|
+
__export(src_exports, {
|
|
33
33
|
AccessDenied: () => AccessDenied,
|
|
34
34
|
Alert: () => Alert_default,
|
|
35
35
|
AreaChart: () => AreaChart,
|
|
@@ -64,17 +64,6 @@ __export(index_exports, {
|
|
|
64
64
|
FallingIcons: () => FallingIcons,
|
|
65
65
|
FloatingContacts: () => FloatingContacts,
|
|
66
66
|
ForceInternalTranslationsProvider: () => ForceInternalTranslationsProvider,
|
|
67
|
-
Form: () => Form,
|
|
68
|
-
FormActions: () => FormActions,
|
|
69
|
-
FormCheckbox: () => FormCheckbox,
|
|
70
|
-
FormControl: () => FormControl,
|
|
71
|
-
FormDescription: () => FormDescription,
|
|
72
|
-
FormField: () => FormField,
|
|
73
|
-
FormInput: () => FormInput,
|
|
74
|
-
FormItem: () => FormItem,
|
|
75
|
-
FormLabel: () => FormLabel,
|
|
76
|
-
FormMessage: () => FormMessage,
|
|
77
|
-
FormSubmitButton: () => FormSubmitButton,
|
|
78
67
|
GaugeChart: () => GaugeChart,
|
|
79
68
|
GlobalLoading: () => GlobalLoading,
|
|
80
69
|
GradientBadge: () => GradientBadge,
|
|
@@ -171,7 +160,6 @@ __export(index_exports, {
|
|
|
171
160
|
injectAnimationStyles: () => injectAnimationStyles,
|
|
172
161
|
shadcnAnimationStyles: () => shadcnAnimationStyles2,
|
|
173
162
|
underverseMessages: () => underverseMessages,
|
|
174
|
-
useFormField: () => useFormField,
|
|
175
163
|
useShadCNAnimations: () => useShadCNAnimations2,
|
|
176
164
|
useSmartLocale: () => useSmartLocale,
|
|
177
165
|
useSmartTranslations: () => useSmartTranslations,
|
|
@@ -181,7 +169,7 @@ __export(index_exports, {
|
|
|
181
169
|
useUnderverseLocale: () => useUnderverseLocale,
|
|
182
170
|
useUnderverseTranslations: () => useUnderverseTranslations
|
|
183
171
|
});
|
|
184
|
-
module.exports = __toCommonJS(
|
|
172
|
+
module.exports = __toCommonJS(src_exports);
|
|
185
173
|
|
|
186
174
|
// ../../components/ui/Button.tsx
|
|
187
175
|
var import_react = require("react");
|
|
@@ -13145,6 +13133,45 @@ function DataTable({
|
|
|
13145
13133
|
const cellPadding = density === "compact" ? "py-1.5 px-3" : density === "comfortable" ? "py-3 px-4" : "py-2.5 px-4";
|
|
13146
13134
|
const visibleColsSet = import_react32.default.useMemo(() => new Set(visibleCols), [visibleCols]);
|
|
13147
13135
|
const visibleColumns = columns.filter((c) => visibleColsSet.has(c.key));
|
|
13136
|
+
const stickyPositions = import_react32.default.useMemo(() => {
|
|
13137
|
+
const positions = {};
|
|
13138
|
+
let leftOffset = 0;
|
|
13139
|
+
for (const col of visibleColumns) {
|
|
13140
|
+
if (col.fixed === "left") {
|
|
13141
|
+
positions[col.key] = { left: leftOffset };
|
|
13142
|
+
const colWidth = typeof col.width === "number" ? col.width : parseInt(String(col.width) || "150", 10);
|
|
13143
|
+
leftOffset += colWidth;
|
|
13144
|
+
}
|
|
13145
|
+
}
|
|
13146
|
+
let rightOffset = 0;
|
|
13147
|
+
for (let i = visibleColumns.length - 1; i >= 0; i--) {
|
|
13148
|
+
const col = visibleColumns[i];
|
|
13149
|
+
if (col.fixed === "right") {
|
|
13150
|
+
positions[col.key] = { right: rightOffset };
|
|
13151
|
+
const colWidth = typeof col.width === "number" ? col.width : parseInt(String(col.width) || "150", 10);
|
|
13152
|
+
rightOffset += colWidth;
|
|
13153
|
+
}
|
|
13154
|
+
}
|
|
13155
|
+
return positions;
|
|
13156
|
+
}, [visibleColumns]);
|
|
13157
|
+
const getStickyColumnClass = (col, isHeader = false) => {
|
|
13158
|
+
if (!col.fixed) return "";
|
|
13159
|
+
return cn(
|
|
13160
|
+
"sticky z-10 bg-background",
|
|
13161
|
+
col.fixed === "left" && "shadow-[2px_0_5px_-2px_rgba(0,0,0,0.1)]",
|
|
13162
|
+
col.fixed === "right" && "shadow-[-2px_0_5px_-2px_rgba(0,0,0,0.1)]",
|
|
13163
|
+
isHeader && "z-20"
|
|
13164
|
+
// Header cần z-index cao hơn
|
|
13165
|
+
);
|
|
13166
|
+
};
|
|
13167
|
+
const getStickyColumnStyle = (col) => {
|
|
13168
|
+
if (!col.fixed) return {};
|
|
13169
|
+
const pos = stickyPositions[col.key];
|
|
13170
|
+
return {
|
|
13171
|
+
...pos?.left !== void 0 && { left: pos.left },
|
|
13172
|
+
...pos?.right !== void 0 && { right: pos.right }
|
|
13173
|
+
};
|
|
13174
|
+
};
|
|
13148
13175
|
const getRowKey = (row, idx) => {
|
|
13149
13176
|
if (!rowKey) return String(idx);
|
|
13150
13177
|
if (typeof rowKey === "function") return String(rowKey(row));
|
|
@@ -13205,12 +13232,13 @@ function DataTable({
|
|
|
13205
13232
|
const renderHeader = /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(TableRow, { children: visibleColumns.map((col, colIdx) => /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
|
|
13206
13233
|
TableHead,
|
|
13207
13234
|
{
|
|
13208
|
-
style: { width: col.width },
|
|
13235
|
+
style: { width: col.width, ...getStickyColumnStyle(col) },
|
|
13209
13236
|
className: cn(
|
|
13210
13237
|
// Use column-specific align if defined, otherwise use global headerAlign
|
|
13211
13238
|
(col.align === "right" || !col.align && headerAlign === "right") && "text-right",
|
|
13212
13239
|
(col.align === "center" || !col.align && headerAlign === "center") && "text-center",
|
|
13213
|
-
columnDividers && colIdx > 0 && "border-l border-border/60"
|
|
13240
|
+
columnDividers && colIdx > 0 && "border-l border-border/60",
|
|
13241
|
+
getStickyColumnClass(col, true)
|
|
13214
13242
|
),
|
|
13215
13243
|
children: (() => {
|
|
13216
13244
|
const isRightAlign = col.align === "right" || !col.align && headerAlign === "right";
|
|
@@ -13467,13 +13495,17 @@ function DataTable({
|
|
|
13467
13495
|
return /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
|
|
13468
13496
|
TableCell,
|
|
13469
13497
|
{
|
|
13498
|
+
style: getStickyColumnStyle(col),
|
|
13470
13499
|
className: cn(
|
|
13471
13500
|
cellPadding,
|
|
13472
13501
|
col.align === "right" && "text-right",
|
|
13473
13502
|
col.align === "center" && "text-center",
|
|
13474
13503
|
columnDividers && colIdx > 0 && "border-l border-border/60",
|
|
13475
13504
|
isLastRow && col === visibleColumns[0] && "rounded-bl-2xl md:rounded-bl-3xl",
|
|
13476
|
-
isLastRow && col === visibleColumns[visibleColumns.length - 1] && "rounded-br-2xl md:rounded-br-3xl"
|
|
13505
|
+
isLastRow && col === visibleColumns[visibleColumns.length - 1] && "rounded-br-2xl md:rounded-br-3xl",
|
|
13506
|
+
getStickyColumnClass(col),
|
|
13507
|
+
// Giữ màu nền striped cho cột cố định
|
|
13508
|
+
col.fixed && striped && idx % 2 === 0 && "bg-muted/50!"
|
|
13477
13509
|
),
|
|
13478
13510
|
children: col.render ? col.render(value, row, idx) : String(value ?? "")
|
|
13479
13511
|
},
|
|
@@ -13566,152 +13598,9 @@ function DataTable({
|
|
|
13566
13598
|
}
|
|
13567
13599
|
var DataTable_default = DataTable;
|
|
13568
13600
|
|
|
13569
|
-
// ../../components/ui/Form.tsx
|
|
13570
|
-
var React49 = __toESM(require("react"), 1);
|
|
13571
|
-
var import_react_hook_form = require("react-hook-form");
|
|
13572
|
-
var import_jsx_runtime58 = require("react/jsx-runtime");
|
|
13573
|
-
var FormConfigContext = React49.createContext({ size: "md" });
|
|
13574
|
-
var FormWrapper = ({
|
|
13575
|
-
children,
|
|
13576
|
-
onSubmit,
|
|
13577
|
-
initialValues,
|
|
13578
|
-
validationSchema,
|
|
13579
|
-
className,
|
|
13580
|
-
size = "md",
|
|
13581
|
-
...props
|
|
13582
|
-
}) => {
|
|
13583
|
-
const methods = (0, import_react_hook_form.useForm)({
|
|
13584
|
-
defaultValues: initialValues
|
|
13585
|
-
});
|
|
13586
|
-
React49.useEffect(() => {
|
|
13587
|
-
if (initialValues) {
|
|
13588
|
-
methods.reset(initialValues);
|
|
13589
|
-
}
|
|
13590
|
-
}, [JSON.stringify(initialValues)]);
|
|
13591
|
-
const { validationSchema: _, ...formProps } = props;
|
|
13592
|
-
return /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_react_hook_form.FormProvider, { ...methods, children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(FormConfigContext.Provider, { value: { size }, children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("form", { onSubmit: methods.handleSubmit(onSubmit), className, ...formProps, children }) }) });
|
|
13593
|
-
};
|
|
13594
|
-
var Form = FormWrapper;
|
|
13595
|
-
var FormFieldContext = React49.createContext({});
|
|
13596
|
-
var FormField = ({
|
|
13597
|
-
...props
|
|
13598
|
-
}) => {
|
|
13599
|
-
return /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(FormFieldContext.Provider, { value: { name: props.name }, children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_react_hook_form.Controller, { ...props }) });
|
|
13600
|
-
};
|
|
13601
|
-
var useFormField = () => {
|
|
13602
|
-
const fieldContext = React49.useContext(FormFieldContext);
|
|
13603
|
-
const itemContext = React49.useContext(FormItemContext);
|
|
13604
|
-
const { getFieldState, formState } = (0, import_react_hook_form.useFormContext)();
|
|
13605
|
-
if (!fieldContext) {
|
|
13606
|
-
try {
|
|
13607
|
-
const t = useTranslations("Form");
|
|
13608
|
-
throw new Error(t("validation.mustBeUsedWithinForm"));
|
|
13609
|
-
} catch {
|
|
13610
|
-
throw new Error("useFormField must be used within FormField");
|
|
13611
|
-
}
|
|
13612
|
-
}
|
|
13613
|
-
const fieldState = getFieldState(fieldContext.name, formState);
|
|
13614
|
-
const { id } = itemContext;
|
|
13615
|
-
return {
|
|
13616
|
-
id,
|
|
13617
|
-
name: fieldContext.name,
|
|
13618
|
-
formItemId: `${id}-form-item`,
|
|
13619
|
-
formDescriptionId: `${id}-form-item-description`,
|
|
13620
|
-
formMessageId: `${id}-form-item-message`,
|
|
13621
|
-
...fieldState
|
|
13622
|
-
};
|
|
13623
|
-
};
|
|
13624
|
-
var FormItemContext = React49.createContext({});
|
|
13625
|
-
var FormItem = React49.forwardRef(({ className, ...props }, ref) => {
|
|
13626
|
-
const id = React49.useId();
|
|
13627
|
-
return /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(FormItemContext.Provider, { value: { id }, children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { ref, className: cn("space-y-2", className), ...props }) });
|
|
13628
|
-
});
|
|
13629
|
-
FormItem.displayName = "FormItem";
|
|
13630
|
-
var FormLabel = React49.forwardRef(
|
|
13631
|
-
({ className, children, required, ...props }, ref) => {
|
|
13632
|
-
const { error, formItemId } = useFormField();
|
|
13633
|
-
const config = React49.useContext(FormConfigContext);
|
|
13634
|
-
const sizeClass = config.size === "sm" ? "text-xs" : config.size === "lg" ? "text-base" : "text-sm";
|
|
13635
|
-
return /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(Label, { ref, className: cn(sizeClass, error && "text-destructive", className), htmlFor: formItemId, ...props, children: [
|
|
13636
|
-
children,
|
|
13637
|
-
required && /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("span", { className: "text-destructive ml-1", children: "*" })
|
|
13638
|
-
] });
|
|
13639
|
-
}
|
|
13640
|
-
);
|
|
13641
|
-
FormLabel.displayName = "FormLabel";
|
|
13642
|
-
var FormControl = React49.forwardRef(({ ...props }, ref) => {
|
|
13643
|
-
const { error, formItemId, formDescriptionId, formMessageId } = useFormField();
|
|
13644
|
-
return /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
|
|
13645
|
-
"div",
|
|
13646
|
-
{
|
|
13647
|
-
ref,
|
|
13648
|
-
id: formItemId,
|
|
13649
|
-
"aria-describedby": !error ? `${formDescriptionId}` : `${formDescriptionId} ${formMessageId}`,
|
|
13650
|
-
"aria-invalid": !!error,
|
|
13651
|
-
...props
|
|
13652
|
-
}
|
|
13653
|
-
);
|
|
13654
|
-
});
|
|
13655
|
-
FormControl.displayName = "FormControl";
|
|
13656
|
-
var FormDescription = React49.forwardRef(({ className, ...props }, ref) => {
|
|
13657
|
-
const { formDescriptionId } = useFormField();
|
|
13658
|
-
return /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("p", { ref, id: formDescriptionId, className: cn("text-sm text-muted-foreground", className), ...props });
|
|
13659
|
-
});
|
|
13660
|
-
FormDescription.displayName = "FormDescription";
|
|
13661
|
-
var FormMessage = React49.forwardRef(({ className, children, ...props }, ref) => {
|
|
13662
|
-
const { error, formMessageId } = useFormField();
|
|
13663
|
-
const body = error ? String(error?.message) : children;
|
|
13664
|
-
if (!body) {
|
|
13665
|
-
return null;
|
|
13666
|
-
}
|
|
13667
|
-
return /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("p", { ref, id: formMessageId, className: cn("text-sm font-medium text-destructive", className), ...props, children: body });
|
|
13668
|
-
});
|
|
13669
|
-
FormMessage.displayName = "FormMessage";
|
|
13670
|
-
var FormInput = React49.forwardRef(({ name, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(FormConfigContext.Consumer, { children: ({ size }) => /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
|
|
13671
|
-
FormField,
|
|
13672
|
-
{
|
|
13673
|
-
name,
|
|
13674
|
-
render: ({ field }) => /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(FormItem, { children: [
|
|
13675
|
-
/* @__PURE__ */ (0, import_jsx_runtime58.jsx)(FormControl, { children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(Input_default, { size: props.size ?? size, ...field, ...props }) }),
|
|
13676
|
-
/* @__PURE__ */ (0, import_jsx_runtime58.jsx)(FormMessage, {})
|
|
13677
|
-
] })
|
|
13678
|
-
}
|
|
13679
|
-
) }));
|
|
13680
|
-
FormInput.displayName = "FormInput";
|
|
13681
|
-
var FormCheckbox = React49.forwardRef(({ name, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(FormConfigContext.Consumer, { children: ({ size }) => /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
|
|
13682
|
-
FormField,
|
|
13683
|
-
{
|
|
13684
|
-
name,
|
|
13685
|
-
render: ({ field }) => /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(FormItem, { children: [
|
|
13686
|
-
/* @__PURE__ */ (0, import_jsx_runtime58.jsx)(FormControl, { children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
|
|
13687
|
-
Checkbox,
|
|
13688
|
-
{
|
|
13689
|
-
ref,
|
|
13690
|
-
checked: field.value,
|
|
13691
|
-
onChange: (e) => field.onChange(e.target.checked),
|
|
13692
|
-
labelClassName: cn(
|
|
13693
|
-
// align label text size with inputs/buttons by form size
|
|
13694
|
-
size === "sm" ? "text-xs" : size === "lg" ? "text-base" : "text-sm",
|
|
13695
|
-
props.labelClassName
|
|
13696
|
-
),
|
|
13697
|
-
...props
|
|
13698
|
-
}
|
|
13699
|
-
) }),
|
|
13700
|
-
/* @__PURE__ */ (0, import_jsx_runtime58.jsx)(FormMessage, {})
|
|
13701
|
-
] })
|
|
13702
|
-
}
|
|
13703
|
-
) }));
|
|
13704
|
-
FormCheckbox.displayName = "FormCheckbox";
|
|
13705
|
-
var FormActions = React49.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { ref, className: cn("flex gap-2 justify-end", className), ...props }));
|
|
13706
|
-
FormActions.displayName = "FormActions";
|
|
13707
|
-
var FormSubmitButton = React49.forwardRef(
|
|
13708
|
-
({ children, loading: loading2, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(FormConfigContext.Consumer, { children: ({ size }) => /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(Button_default, { ref, type: "submit", size: props.size ?? size, disabled: loading2, ...props, children }) })
|
|
13709
|
-
);
|
|
13710
|
-
FormSubmitButton.displayName = "FormSubmitButton";
|
|
13711
|
-
|
|
13712
13601
|
// ../../components/ui/NotificationModal.tsx
|
|
13713
13602
|
var import_lucide_react28 = require("lucide-react");
|
|
13714
|
-
var
|
|
13603
|
+
var import_jsx_runtime58 = require("react/jsx-runtime");
|
|
13715
13604
|
function NotificationModal({ isOpen, onClose, notification, titleText, openLinkText, closeText }) {
|
|
13716
13605
|
const t = useTranslations("Common");
|
|
13717
13606
|
if (!notification) return null;
|
|
@@ -13732,20 +13621,20 @@ function NotificationModal({ isOpen, onClose, notification, titleText, openLinkT
|
|
|
13732
13621
|
onClose();
|
|
13733
13622
|
}
|
|
13734
13623
|
};
|
|
13735
|
-
return /* @__PURE__ */ (0,
|
|
13736
|
-
/* @__PURE__ */ (0,
|
|
13737
|
-
/* @__PURE__ */ (0,
|
|
13738
|
-
/* @__PURE__ */ (0,
|
|
13624
|
+
return /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(Modal_default, { isOpen, onClose, title: titleText || t("notifications"), size: "md", children: /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "space-y-4", children: [
|
|
13625
|
+
/* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "flex items-center gap-2 pb-2 border-b border-border", children: [
|
|
13626
|
+
/* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { className: cn("w-2 h-2 rounded-full", !notification.is_read ? "bg-primary" : "bg-border") }),
|
|
13627
|
+
/* @__PURE__ */ (0, import_jsx_runtime58.jsx)("span", { className: "text-xs text-muted-foreground", children: !notification.is_read ? t("newNotification") : t("readStatus") })
|
|
13739
13628
|
] }),
|
|
13740
|
-
notification.title && /* @__PURE__ */ (0,
|
|
13741
|
-
notification.body && /* @__PURE__ */ (0,
|
|
13742
|
-
/* @__PURE__ */ (0,
|
|
13743
|
-
/* @__PURE__ */ (0,
|
|
13744
|
-
hasLink && /* @__PURE__ */ (0,
|
|
13745
|
-
/* @__PURE__ */ (0,
|
|
13629
|
+
notification.title && /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("h3", { className: "text-lg font-semibold text-foreground", children: notification.title }),
|
|
13630
|
+
notification.body && /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { className: "text-sm text-muted-foreground whitespace-pre-wrap leading-relaxed", children: notification.body }),
|
|
13631
|
+
/* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { className: "text-xs text-muted-foreground border-t border-border pt-2", children: formatTime3(notification.created_at) }),
|
|
13632
|
+
/* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "flex gap-2 justify-end pt-2", children: [
|
|
13633
|
+
hasLink && /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(Button_default, { variant: "primary", size: "sm", onClick: handleLinkClick, className: "gap-2", children: [
|
|
13634
|
+
/* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_lucide_react28.ExternalLink, { className: "w-4 h-4" }),
|
|
13746
13635
|
openLinkText || t("openLink")
|
|
13747
13636
|
] }),
|
|
13748
|
-
/* @__PURE__ */ (0,
|
|
13637
|
+
/* @__PURE__ */ (0, import_jsx_runtime58.jsx)(Button_default, { variant: "ghost", size: "sm", onClick: onClose, children: closeText || t("close") })
|
|
13749
13638
|
] })
|
|
13750
13639
|
] }) });
|
|
13751
13640
|
}
|
|
@@ -13755,9 +13644,9 @@ var NotificationModal_default = NotificationModal;
|
|
|
13755
13644
|
var import_link2 = __toESM(require("next/link"), 1);
|
|
13756
13645
|
var import_navigation = require("next/navigation");
|
|
13757
13646
|
var import_lucide_react29 = require("lucide-react");
|
|
13758
|
-
var
|
|
13647
|
+
var import_jsx_runtime59 = require("react/jsx-runtime");
|
|
13759
13648
|
function MessengerIcon(props) {
|
|
13760
|
-
return /* @__PURE__ */ (0,
|
|
13649
|
+
return /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("svg", { viewBox: "0 0 24 24", width: 24, height: 24, "aria-hidden": "true", ...props, children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
|
|
13761
13650
|
"path",
|
|
13762
13651
|
{
|
|
13763
13652
|
d: "M12 2C6.477 2 2 6.145 2 11.235c0 2.93 1.35 5.542 3.464 7.25v3.515l3.344-1.836c.894.247 1.843.375 2.192.375 5.523 0 10-4.145 10-9.235S17.523 2 12 2zm.994 12.444l-2.563-2.73-5.004 2.73 5.507-5.84 2.626 2.729 4.942-2.729-5.508 5.84z",
|
|
@@ -13766,7 +13655,7 @@ function MessengerIcon(props) {
|
|
|
13766
13655
|
) });
|
|
13767
13656
|
}
|
|
13768
13657
|
function ZaloIcon(props) {
|
|
13769
|
-
return /* @__PURE__ */ (0,
|
|
13658
|
+
return /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("svg", { viewBox: "0 0 48 48", width: 20, height: 20, "aria-hidden": "true", ...props, children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
|
|
13770
13659
|
"path",
|
|
13771
13660
|
{
|
|
13772
13661
|
fill: "white",
|
|
@@ -13775,7 +13664,7 @@ function ZaloIcon(props) {
|
|
|
13775
13664
|
) });
|
|
13776
13665
|
}
|
|
13777
13666
|
function InstagramIcon(props) {
|
|
13778
|
-
return /* @__PURE__ */ (0,
|
|
13667
|
+
return /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("svg", { viewBox: "0 0 24 24", width: 20, height: 20, "aria-hidden": "true", fill: "white", ...props, children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("path", { d: "M12 2.163c3.204 0 3.584.012 4.85.07 3.252.148 4.771 1.691 4.919 4.919.058 1.265.069 1.645.069 4.849 0 3.205-.012 3.584-.069 4.849-.149 3.225-1.664 4.771-4.919 4.919-1.266.058-1.644.07-4.85.07-3.204 0-3.584-.012-4.849-.07-3.26-.149-4.771-1.699-4.919-4.92-.058-1.265-.07-1.644-.07-4.849 0-3.204.013-3.583.07-4.849.149-3.227 1.664-4.771 4.919-4.919 1.266-.057 1.645-.069 4.849-.069zm0-2.163c-3.259 0-3.667.014-4.947.072-4.358.2-6.78 2.618-6.98 6.98-.059 1.281-.073 1.689-.073 4.948 0 3.259.014 3.668.072 4.948.2 4.358 2.618 6.78 6.98 6.98 1.281.058 1.689.072 4.948.072 3.259 0 3.668-.014 4.948-.072 4.354-.2 6.782-2.618 6.979-6.98.059-1.28.073-1.689.073-4.948 0-3.259-.014-3.667-.072-4.947-.196-4.354-2.617-6.78-6.979-6.98-1.281-.059-1.69-.073-4.949-.073zm0 5.838c-3.403 0-6.162 2.759-6.162 6.162s2.759 6.163 6.162 6.163 6.162-2.759 6.162-6.163c0-3.403-2.759-6.162-6.162-6.162zm0 10.162c-2.209 0-4-1.79-4-4 0-2.209 1.791-4 4-4s4 1.791 4 4c0 2.21-1.791 4-4 4zm6.406-11.845c-.796 0-1.441.645-1.441 1.44s.645 1.44 1.441 1.44c.795 0 1.439-.645 1.439-1.44s-.644-1.44-1.439-1.44z" }) });
|
|
13779
13668
|
}
|
|
13780
13669
|
function FloatingContacts({ className }) {
|
|
13781
13670
|
const pathname = (0, import_navigation.usePathname)();
|
|
@@ -13810,8 +13699,8 @@ function FloatingContacts({ className }) {
|
|
|
13810
13699
|
external: true
|
|
13811
13700
|
}
|
|
13812
13701
|
];
|
|
13813
|
-
return /* @__PURE__ */ (0,
|
|
13814
|
-
/* @__PURE__ */ (0,
|
|
13702
|
+
return /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("div", { className: cn("fixed bottom-6 right-4 z-100000", "flex flex-col items-end gap-3", className), "aria-label": "Quick contacts", children: [
|
|
13703
|
+
/* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
|
|
13815
13704
|
import_link2.default,
|
|
13816
13705
|
{
|
|
13817
13706
|
href: `tel:${hotline.replace(/\D/g, "")}`,
|
|
@@ -13822,10 +13711,10 @@ function FloatingContacts({ className }) {
|
|
|
13822
13711
|
"hover:scale-105 active:scale-95 transition-transform",
|
|
13823
13712
|
"bg-[#22c55e]"
|
|
13824
13713
|
),
|
|
13825
|
-
children: /* @__PURE__ */ (0,
|
|
13714
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(import_lucide_react29.Phone, { className: "w-6 h-6" })
|
|
13826
13715
|
}
|
|
13827
13716
|
),
|
|
13828
|
-
moreItems.map(({ key, href, label, bg, Icon, external }) => /* @__PURE__ */ (0,
|
|
13717
|
+
moreItems.map(({ key, href, label, bg, Icon, external }) => /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
|
|
13829
13718
|
import_link2.default,
|
|
13830
13719
|
{
|
|
13831
13720
|
href,
|
|
@@ -13837,7 +13726,7 @@ function FloatingContacts({ className }) {
|
|
|
13837
13726
|
"hover:scale-105 active:scale-95 transition-transform",
|
|
13838
13727
|
bg
|
|
13839
13728
|
),
|
|
13840
|
-
children: /* @__PURE__ */ (0,
|
|
13729
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(Icon, { className: "w-6 h-6" })
|
|
13841
13730
|
},
|
|
13842
13731
|
key
|
|
13843
13732
|
))
|
|
@@ -13846,7 +13735,7 @@ function FloatingContacts({ className }) {
|
|
|
13846
13735
|
|
|
13847
13736
|
// ../../components/ui/AccessDenied.tsx
|
|
13848
13737
|
var import_lucide_react30 = require("lucide-react");
|
|
13849
|
-
var
|
|
13738
|
+
var import_jsx_runtime60 = require("react/jsx-runtime");
|
|
13850
13739
|
var VARIANT_STYLES = {
|
|
13851
13740
|
destructive: { bg: "bg-destructive/5", border: "border-destructive/20", text: "text-destructive" },
|
|
13852
13741
|
warning: { bg: "bg-warning/5", border: "border-warning/20", text: "text-warning" },
|
|
@@ -13867,13 +13756,13 @@ function AccessDenied({
|
|
|
13867
13756
|
}) {
|
|
13868
13757
|
const styles = VARIANT_STYLES[variant];
|
|
13869
13758
|
const UsedIcon = Icon || DEFAULT_ICONS[variant];
|
|
13870
|
-
return /* @__PURE__ */ (0,
|
|
13871
|
-
/* @__PURE__ */ (0,
|
|
13872
|
-
/* @__PURE__ */ (0,
|
|
13873
|
-
/* @__PURE__ */ (0,
|
|
13874
|
-
/* @__PURE__ */ (0,
|
|
13759
|
+
return /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(Card_default, { className: cn("p-8 text-center shadow-sm", styles.bg, styles.border, className), children: /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("div", { className: "flex flex-col items-center gap-4", children: [
|
|
13760
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { className: cn("p-3 rounded-lg", styles.bg.replace("/5", "/10")), children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(UsedIcon, { className: cn("w-8 h-8", styles.text) }) }),
|
|
13761
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("div", { children: [
|
|
13762
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)("h3", { className: cn("font-semibold mb-2", styles.text), children: title }),
|
|
13763
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)("p", { className: cn(styles.text.replace("text-", "text-") + "/80", "text-sm"), children: description })
|
|
13875
13764
|
] }),
|
|
13876
|
-
children && /* @__PURE__ */ (0,
|
|
13765
|
+
children && /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { className: "mt-2 flex flex-wrap gap-2 justify-center", children })
|
|
13877
13766
|
] }) });
|
|
13878
13767
|
}
|
|
13879
13768
|
|
|
@@ -13881,7 +13770,7 @@ function AccessDenied({
|
|
|
13881
13770
|
var import_lucide_react31 = require("lucide-react");
|
|
13882
13771
|
var import_react33 = require("react");
|
|
13883
13772
|
var import_react_dom7 = require("react-dom");
|
|
13884
|
-
var
|
|
13773
|
+
var import_jsx_runtime61 = require("react/jsx-runtime");
|
|
13885
13774
|
function ThemeToggleHeadless({
|
|
13886
13775
|
theme,
|
|
13887
13776
|
onChange,
|
|
@@ -13910,8 +13799,8 @@ function ThemeToggleHeadless({
|
|
|
13910
13799
|
const top = rect.bottom + scrollTop + 8;
|
|
13911
13800
|
return { top, left, width };
|
|
13912
13801
|
};
|
|
13913
|
-
return /* @__PURE__ */ (0,
|
|
13914
|
-
/* @__PURE__ */ (0,
|
|
13802
|
+
return /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)("div", { className: cn("relative", className), children: [
|
|
13803
|
+
/* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
|
|
13915
13804
|
Button_default,
|
|
13916
13805
|
{
|
|
13917
13806
|
variant: "ghost",
|
|
@@ -13929,25 +13818,25 @@ function ThemeToggleHeadless({
|
|
|
13929
13818
|
"aria-haspopup": "menu",
|
|
13930
13819
|
"aria-expanded": isOpen,
|
|
13931
13820
|
"aria-label": labels?.heading ?? "Theme",
|
|
13932
|
-
children: /* @__PURE__ */ (0,
|
|
13821
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(CurrentIcon, { className: "h-5 w-5" })
|
|
13933
13822
|
}
|
|
13934
13823
|
),
|
|
13935
|
-
isOpen && /* @__PURE__ */ (0,
|
|
13936
|
-
typeof window !== "undefined" && (0, import_react_dom7.createPortal)(/* @__PURE__ */ (0,
|
|
13824
|
+
isOpen && /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)(import_jsx_runtime61.Fragment, { children: [
|
|
13825
|
+
typeof window !== "undefined" && (0, import_react_dom7.createPortal)(/* @__PURE__ */ (0, import_jsx_runtime61.jsx)("div", { className: "fixed inset-0 z-9998", onClick: () => setIsOpen(false) }), document.body),
|
|
13937
13826
|
typeof window !== "undefined" && dropdownPosition && (0, import_react_dom7.createPortal)(
|
|
13938
|
-
/* @__PURE__ */ (0,
|
|
13827
|
+
/* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
|
|
13939
13828
|
"div",
|
|
13940
13829
|
{
|
|
13941
13830
|
className: "z-9999 bg-card border border-border rounded-lg shadow-lg overflow-hidden",
|
|
13942
13831
|
style: { position: "absolute", top: dropdownPosition.top, left: dropdownPosition.left, width: dropdownPosition.width },
|
|
13943
13832
|
onMouseDown: (e) => e.stopPropagation(),
|
|
13944
13833
|
role: "menu",
|
|
13945
|
-
children: /* @__PURE__ */ (0,
|
|
13946
|
-
/* @__PURE__ */ (0,
|
|
13834
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)("div", { className: "p-2", children: [
|
|
13835
|
+
/* @__PURE__ */ (0, import_jsx_runtime61.jsx)("div", { className: "px-3 py-2 text-sm font-medium text-muted-foreground border-b border-border mb-2", children: labels?.heading ?? "Theme" }),
|
|
13947
13836
|
themes.map((opt) => {
|
|
13948
13837
|
const Icon = opt.icon;
|
|
13949
13838
|
const active = theme === opt.value;
|
|
13950
|
-
return /* @__PURE__ */ (0,
|
|
13839
|
+
return /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)(
|
|
13951
13840
|
Button_default,
|
|
13952
13841
|
{
|
|
13953
13842
|
variant: "ghost",
|
|
@@ -13963,9 +13852,9 @@ function ThemeToggleHeadless({
|
|
|
13963
13852
|
role: "menuitemradio",
|
|
13964
13853
|
"aria-checked": active,
|
|
13965
13854
|
children: [
|
|
13966
|
-
/* @__PURE__ */ (0,
|
|
13967
|
-
/* @__PURE__ */ (0,
|
|
13968
|
-
active && /* @__PURE__ */ (0,
|
|
13855
|
+
/* @__PURE__ */ (0, import_jsx_runtime61.jsx)(Icon, { className: "h-4 w-4" }),
|
|
13856
|
+
/* @__PURE__ */ (0, import_jsx_runtime61.jsx)("span", { className: "flex-1 text-left", children: opt.label }),
|
|
13857
|
+
active && /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("div", { className: "w-2 h-2 rounded-full bg-primary" })
|
|
13969
13858
|
]
|
|
13970
13859
|
},
|
|
13971
13860
|
opt.value
|
|
@@ -13984,7 +13873,7 @@ function ThemeToggleHeadless({
|
|
|
13984
13873
|
var import_react34 = require("react");
|
|
13985
13874
|
var import_react_dom8 = require("react-dom");
|
|
13986
13875
|
var import_lucide_react32 = require("lucide-react");
|
|
13987
|
-
var
|
|
13876
|
+
var import_jsx_runtime62 = require("react/jsx-runtime");
|
|
13988
13877
|
function LanguageSwitcherHeadless({
|
|
13989
13878
|
locales,
|
|
13990
13879
|
currentLocale,
|
|
@@ -14006,8 +13895,8 @@ function LanguageSwitcherHeadless({
|
|
|
14006
13895
|
const top = rect.bottom + scrollTop + 8;
|
|
14007
13896
|
return { top, left, width };
|
|
14008
13897
|
};
|
|
14009
|
-
return /* @__PURE__ */ (0,
|
|
14010
|
-
/* @__PURE__ */ (0,
|
|
13898
|
+
return /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)("div", { className: cn("relative", className), children: [
|
|
13899
|
+
/* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
|
|
14011
13900
|
Button_default,
|
|
14012
13901
|
{
|
|
14013
13902
|
variant: "ghost",
|
|
@@ -14026,22 +13915,22 @@ function LanguageSwitcherHeadless({
|
|
|
14026
13915
|
"aria-expanded": isOpen,
|
|
14027
13916
|
"aria-label": labels?.heading ?? "Language",
|
|
14028
13917
|
title: labels?.heading ?? "Language",
|
|
14029
|
-
children: /* @__PURE__ */ (0,
|
|
13918
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(import_lucide_react32.Globe, { className: "h-5 w-5" })
|
|
14030
13919
|
}
|
|
14031
13920
|
),
|
|
14032
|
-
isOpen && /* @__PURE__ */ (0,
|
|
14033
|
-
typeof window !== "undefined" && (0, import_react_dom8.createPortal)(/* @__PURE__ */ (0,
|
|
13921
|
+
isOpen && /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)(import_jsx_runtime62.Fragment, { children: [
|
|
13922
|
+
typeof window !== "undefined" && (0, import_react_dom8.createPortal)(/* @__PURE__ */ (0, import_jsx_runtime62.jsx)("div", { className: "fixed inset-0 z-9998", onClick: () => setIsOpen(false) }), document.body),
|
|
14034
13923
|
typeof window !== "undefined" && dropdownPosition && (0, import_react_dom8.createPortal)(
|
|
14035
|
-
/* @__PURE__ */ (0,
|
|
13924
|
+
/* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
|
|
14036
13925
|
"div",
|
|
14037
13926
|
{
|
|
14038
13927
|
className: "z-9999 bg-card border border-border rounded-lg shadow-lg overflow-hidden",
|
|
14039
13928
|
style: { position: "absolute", top: dropdownPosition.top, left: dropdownPosition.left, width: dropdownPosition.width },
|
|
14040
13929
|
onMouseDown: (e) => e.stopPropagation(),
|
|
14041
13930
|
role: "menu",
|
|
14042
|
-
children: /* @__PURE__ */ (0,
|
|
14043
|
-
/* @__PURE__ */ (0,
|
|
14044
|
-
locales.map((language) => /* @__PURE__ */ (0,
|
|
13931
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)("div", { className: "p-2", children: [
|
|
13932
|
+
/* @__PURE__ */ (0, import_jsx_runtime62.jsx)("div", { className: "px-3 py-2 text-sm font-medium text-muted-foreground border-b border-border mb-2", children: labels?.heading ?? "Language" }),
|
|
13933
|
+
locales.map((language) => /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)(
|
|
14045
13934
|
Button_default,
|
|
14046
13935
|
{
|
|
14047
13936
|
variant: "ghost",
|
|
@@ -14054,9 +13943,9 @@ function LanguageSwitcherHeadless({
|
|
|
14054
13943
|
role: "menuitemradio",
|
|
14055
13944
|
"aria-checked": currentLocale === language.code,
|
|
14056
13945
|
children: [
|
|
14057
|
-
language.flag && /* @__PURE__ */ (0,
|
|
14058
|
-
/* @__PURE__ */ (0,
|
|
14059
|
-
currentLocale === language.code && /* @__PURE__ */ (0,
|
|
13946
|
+
language.flag && /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("span", { className: "text-lg", children: language.flag }),
|
|
13947
|
+
/* @__PURE__ */ (0, import_jsx_runtime62.jsx)("span", { className: "flex-1 text-left", children: language.name }),
|
|
13948
|
+
currentLocale === language.code && /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("div", { className: "w-2 h-2 rounded-full bg-primary" })
|
|
14060
13949
|
]
|
|
14061
13950
|
},
|
|
14062
13951
|
language.code
|
|
@@ -14486,7 +14375,7 @@ var VARIANT_STYLES_ALERT = {
|
|
|
14486
14375
|
};
|
|
14487
14376
|
|
|
14488
14377
|
// src/contexts/TranslationContext.tsx
|
|
14489
|
-
var
|
|
14378
|
+
var React50 = __toESM(require("react"), 1);
|
|
14490
14379
|
|
|
14491
14380
|
// locales/en.json
|
|
14492
14381
|
var en_default = {
|
|
@@ -14789,16 +14678,16 @@ var ja_default = {
|
|
|
14789
14678
|
};
|
|
14790
14679
|
|
|
14791
14680
|
// src/contexts/TranslationContext.tsx
|
|
14792
|
-
var
|
|
14681
|
+
var import_jsx_runtime63 = require("react/jsx-runtime");
|
|
14793
14682
|
var defaultTranslations2 = {
|
|
14794
14683
|
en: en_default,
|
|
14795
14684
|
vi: vi_default,
|
|
14796
14685
|
ko: ko_default,
|
|
14797
14686
|
ja: ja_default
|
|
14798
14687
|
};
|
|
14799
|
-
var TranslationContext2 =
|
|
14688
|
+
var TranslationContext2 = React50.createContext(null);
|
|
14800
14689
|
var TranslationProvider = ({ children, locale = "en", translations }) => {
|
|
14801
|
-
const t =
|
|
14690
|
+
const t = React50.useCallback(
|
|
14802
14691
|
(namespace) => {
|
|
14803
14692
|
return (key) => {
|
|
14804
14693
|
const mergedTranslations = {
|
|
@@ -14823,10 +14712,10 @@ var TranslationProvider = ({ children, locale = "en", translations }) => {
|
|
|
14823
14712
|
},
|
|
14824
14713
|
[locale, translations]
|
|
14825
14714
|
);
|
|
14826
|
-
return /* @__PURE__ */ (0,
|
|
14715
|
+
return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(TranslationContext2.Provider, { value: { locale, t }, children });
|
|
14827
14716
|
};
|
|
14828
14717
|
var useUnderverseTranslations = (namespace) => {
|
|
14829
|
-
const context =
|
|
14718
|
+
const context = React50.useContext(TranslationContext2);
|
|
14830
14719
|
if (!context) {
|
|
14831
14720
|
return (key) => {
|
|
14832
14721
|
const parts = namespace.split(".");
|
|
@@ -14848,13 +14737,13 @@ var useUnderverseTranslations = (namespace) => {
|
|
|
14848
14737
|
return context.t(namespace);
|
|
14849
14738
|
};
|
|
14850
14739
|
var useUnderverseLocale = () => {
|
|
14851
|
-
const context =
|
|
14740
|
+
const context = React50.useContext(TranslationContext2);
|
|
14852
14741
|
return context?.locale || "en";
|
|
14853
14742
|
};
|
|
14854
14743
|
|
|
14855
14744
|
// src/hooks/useSmartTranslations.tsx
|
|
14856
|
-
var
|
|
14857
|
-
var
|
|
14745
|
+
var React51 = __toESM(require("react"), 1);
|
|
14746
|
+
var import_jsx_runtime64 = require("react/jsx-runtime");
|
|
14858
14747
|
var nextIntlHooks = null;
|
|
14859
14748
|
try {
|
|
14860
14749
|
const nextIntl = require("next-intl");
|
|
@@ -14865,12 +14754,12 @@ try {
|
|
|
14865
14754
|
} catch {
|
|
14866
14755
|
nextIntlHooks = null;
|
|
14867
14756
|
}
|
|
14868
|
-
var ForceInternalContext =
|
|
14757
|
+
var ForceInternalContext = React51.createContext(false);
|
|
14869
14758
|
var ForceInternalTranslationsProvider = ({ children }) => {
|
|
14870
|
-
return /* @__PURE__ */ (0,
|
|
14759
|
+
return /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(ForceInternalContext.Provider, { value: true, children });
|
|
14871
14760
|
};
|
|
14872
14761
|
function useSmartTranslations(namespace) {
|
|
14873
|
-
const forceInternal =
|
|
14762
|
+
const forceInternal = React51.useContext(ForceInternalContext);
|
|
14874
14763
|
const internalT = useUnderverseTranslations(namespace);
|
|
14875
14764
|
if (forceInternal || !nextIntlHooks?.useTranslations) {
|
|
14876
14765
|
return internalT;
|
|
@@ -14883,7 +14772,7 @@ function useSmartTranslations(namespace) {
|
|
|
14883
14772
|
}
|
|
14884
14773
|
}
|
|
14885
14774
|
function useSmartLocale() {
|
|
14886
|
-
const forceInternal =
|
|
14775
|
+
const forceInternal = React51.useContext(ForceInternalContext);
|
|
14887
14776
|
const internalLocale = useUnderverseLocale();
|
|
14888
14777
|
if (forceInternal || !nextIntlHooks?.useLocale) {
|
|
14889
14778
|
return internalLocale;
|
|
@@ -14937,17 +14826,6 @@ function getUnderverseMessages(locale = "en") {
|
|
|
14937
14826
|
FallingIcons,
|
|
14938
14827
|
FloatingContacts,
|
|
14939
14828
|
ForceInternalTranslationsProvider,
|
|
14940
|
-
Form,
|
|
14941
|
-
FormActions,
|
|
14942
|
-
FormCheckbox,
|
|
14943
|
-
FormControl,
|
|
14944
|
-
FormDescription,
|
|
14945
|
-
FormField,
|
|
14946
|
-
FormInput,
|
|
14947
|
-
FormItem,
|
|
14948
|
-
FormLabel,
|
|
14949
|
-
FormMessage,
|
|
14950
|
-
FormSubmitButton,
|
|
14951
14829
|
GaugeChart,
|
|
14952
14830
|
GlobalLoading,
|
|
14953
14831
|
GradientBadge,
|
|
@@ -15044,7 +14922,6 @@ function getUnderverseMessages(locale = "en") {
|
|
|
15044
14922
|
injectAnimationStyles,
|
|
15045
14923
|
shadcnAnimationStyles,
|
|
15046
14924
|
underverseMessages,
|
|
15047
|
-
useFormField,
|
|
15048
14925
|
useShadCNAnimations,
|
|
15049
14926
|
useSmartLocale,
|
|
15050
14927
|
useSmartTranslations,
|