@clyrex-digital/clyrex-controls-dev 0.8.1-dev.20260903063823 → 0.8.1-dev.20260905065929
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/AvatarViewClient-4GOKYZYT.mjs +108 -0
- package/dist/AvatarViewClient-S3GJZZZS.mjs +106 -0
- package/dist/{DataBindingControls-GWNAJ7PR.mjs → DataBindingControls-UUDERFAD.mjs} +1 -1
- package/dist/{Slider-554BKC7N.mjs → Slider-6GJY6M4D.mjs} +8 -6
- package/dist/{Slider-PEIVH6A5.mjs → Slider-ZA2GRRGS.mjs} +10 -4
- package/dist/{chunk-Q3LFGHLM.mjs → chunk-7JWVEYJY.mjs} +1 -1
- package/dist/index.js +385 -316
- package/dist/index.mjs +303 -349
- package/dist/server.js +298 -229
- package/dist/server.mjs +133 -179
- package/package.json +1 -1
- package/dist/{InputControlClient-GRH7VSJR.mjs → InputControlClient-5NX4CEZB.mjs} +5 -5
- package/dist/{Pagination-PGAK7KDA.mjs → Pagination-CQKMBXXJ.mjs} +1 -1
package/dist/server.js
CHANGED
|
@@ -2857,15 +2857,126 @@ var init_CommentRendererClient = __esm({
|
|
|
2857
2857
|
}
|
|
2858
2858
|
});
|
|
2859
2859
|
|
|
2860
|
+
// src/components/controls/view/AvatarViewClient.tsx
|
|
2861
|
+
var AvatarViewClient_exports = {};
|
|
2862
|
+
__export(AvatarViewClient_exports, {
|
|
2863
|
+
default: () => AvatarViewClient_default
|
|
2864
|
+
});
|
|
2865
|
+
var import_react26, import_jsx_runtime39, AVATAR_COLORS, getAvatarColor, getInitials, getContactImageInfo, AvatarViewClient, AvatarViewClient_default;
|
|
2866
|
+
var init_AvatarViewClient = __esm({
|
|
2867
|
+
"src/components/controls/view/AvatarViewClient.tsx"() {
|
|
2868
|
+
"use strict";
|
|
2869
|
+
"use client";
|
|
2870
|
+
import_react26 = __toESM(require("react"));
|
|
2871
|
+
init_AssetUtility();
|
|
2872
|
+
import_jsx_runtime39 = require("react/jsx-runtime");
|
|
2873
|
+
AVATAR_COLORS = [
|
|
2874
|
+
"bg-error-strong",
|
|
2875
|
+
"bg-accent-base",
|
|
2876
|
+
"bg-warning-base",
|
|
2877
|
+
"bg-success-base",
|
|
2878
|
+
"bg-info-base",
|
|
2879
|
+
"bg-primary-base",
|
|
2880
|
+
"bg-secondary-base"
|
|
2881
|
+
];
|
|
2882
|
+
getAvatarColor = (text) => {
|
|
2883
|
+
let hash = 0;
|
|
2884
|
+
for (let i = 0; i < text.length; i += 1) {
|
|
2885
|
+
hash = hash * 31 + text.charCodeAt(i) >>> 0;
|
|
2886
|
+
}
|
|
2887
|
+
return AVATAR_COLORS[hash % AVATAR_COLORS.length];
|
|
2888
|
+
};
|
|
2889
|
+
getInitials = (text) => {
|
|
2890
|
+
const words = text.trim().split(/\s+/).filter(Boolean);
|
|
2891
|
+
if (words.length === 0) {
|
|
2892
|
+
return "?";
|
|
2893
|
+
}
|
|
2894
|
+
if (words.length === 1) {
|
|
2895
|
+
return words[0].slice(0, 2).toUpperCase();
|
|
2896
|
+
}
|
|
2897
|
+
return `${words[0][0]}${words[words.length - 1][0]}`.toUpperCase();
|
|
2898
|
+
};
|
|
2899
|
+
getContactImageInfo = (text) => {
|
|
2900
|
+
if (!text.includes("-")) {
|
|
2901
|
+
return null;
|
|
2902
|
+
}
|
|
2903
|
+
const parts = text.split("-");
|
|
2904
|
+
if (parts.length <= 1) {
|
|
2905
|
+
return null;
|
|
2906
|
+
}
|
|
2907
|
+
const first = parts[0].trim();
|
|
2908
|
+
if (!/^\d+$/.test(first)) {
|
|
2909
|
+
return null;
|
|
2910
|
+
}
|
|
2911
|
+
return {
|
|
2912
|
+
contactId: first,
|
|
2913
|
+
name: parts.slice(1).join("-").trim() || text
|
|
2914
|
+
};
|
|
2915
|
+
};
|
|
2916
|
+
AvatarViewClient = (props) => {
|
|
2917
|
+
const text = props.value === null || props.value === void 0 ? "" : String(props.value).trim();
|
|
2918
|
+
const [imageFailed, setImageFailed] = import_react26.default.useState(false);
|
|
2919
|
+
import_react26.default.useEffect(() => {
|
|
2920
|
+
setImageFailed(false);
|
|
2921
|
+
}, [text, props.assetBaseUrl]);
|
|
2922
|
+
if (!text) {
|
|
2923
|
+
return null;
|
|
2924
|
+
}
|
|
2925
|
+
const size = props.width ?? "1.75rem";
|
|
2926
|
+
const contactInfo = getContactImageInfo(text);
|
|
2927
|
+
const imageUrl = contactInfo ? AssetUtility_default.resolveUrl(
|
|
2928
|
+
props.assetBaseUrl,
|
|
2929
|
+
`itemassets/contacts/contact-${contactInfo.contactId}`
|
|
2930
|
+
) : void 0;
|
|
2931
|
+
const displayName = contactInfo?.name ?? text;
|
|
2932
|
+
if (imageUrl && !imageFailed) {
|
|
2933
|
+
return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
2934
|
+
"img",
|
|
2935
|
+
{
|
|
2936
|
+
className: "avatar-view inline-block flex-shrink-0 rounded-full object-cover select-none",
|
|
2937
|
+
src: imageUrl,
|
|
2938
|
+
alt: displayName,
|
|
2939
|
+
title: displayName,
|
|
2940
|
+
"aria-label": displayName,
|
|
2941
|
+
loading: "lazy",
|
|
2942
|
+
onError: () => setImageFailed(true),
|
|
2943
|
+
style: {
|
|
2944
|
+
width: size,
|
|
2945
|
+
height: size
|
|
2946
|
+
}
|
|
2947
|
+
}
|
|
2948
|
+
);
|
|
2949
|
+
}
|
|
2950
|
+
return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
2951
|
+
"span",
|
|
2952
|
+
{
|
|
2953
|
+
className: `avatar-view inline-flex flex-shrink-0 items-center justify-center rounded-full font-semibold uppercase select-none overflow-hidden ${getAvatarColor(displayName)}`,
|
|
2954
|
+
title: displayName,
|
|
2955
|
+
"aria-label": displayName,
|
|
2956
|
+
style: {
|
|
2957
|
+
width: size,
|
|
2958
|
+
height: size,
|
|
2959
|
+
fontSize: "0.6875rem",
|
|
2960
|
+
letterSpacing: "0.02em",
|
|
2961
|
+
lineHeight: 1
|
|
2962
|
+
},
|
|
2963
|
+
children: getInitials(displayName)
|
|
2964
|
+
}
|
|
2965
|
+
);
|
|
2966
|
+
};
|
|
2967
|
+
AvatarViewClient_default = AvatarViewClient;
|
|
2968
|
+
}
|
|
2969
|
+
});
|
|
2970
|
+
|
|
2860
2971
|
// src/components/CopyButton.tsx
|
|
2861
2972
|
var CopyButton_exports = {};
|
|
2862
2973
|
__export(CopyButton_exports, {
|
|
2863
2974
|
default: () => CopyButton
|
|
2864
2975
|
});
|
|
2865
2976
|
function CopyButton({ text }) {
|
|
2866
|
-
const [copied, setCopied] = (0,
|
|
2867
|
-
const timeoutRef = (0,
|
|
2868
|
-
(0,
|
|
2977
|
+
const [copied, setCopied] = (0, import_react33.useState)(false);
|
|
2978
|
+
const timeoutRef = (0, import_react33.useRef)(null);
|
|
2979
|
+
(0, import_react33.useEffect)(() => {
|
|
2869
2980
|
return () => {
|
|
2870
2981
|
if (timeoutRef.current) clearTimeout(timeoutRef.current);
|
|
2871
2982
|
};
|
|
@@ -2909,25 +3020,25 @@ function CopyButton({ text }) {
|
|
|
2909
3020
|
}
|
|
2910
3021
|
);
|
|
2911
3022
|
}
|
|
2912
|
-
var
|
|
3023
|
+
var import_react33, import_jsx_runtime47;
|
|
2913
3024
|
var init_CopyButton = __esm({
|
|
2914
3025
|
"src/components/CopyButton.tsx"() {
|
|
2915
3026
|
"use strict";
|
|
2916
3027
|
"use client";
|
|
2917
|
-
|
|
3028
|
+
import_react33 = require("react");
|
|
2918
3029
|
import_jsx_runtime47 = require("react/jsx-runtime");
|
|
2919
3030
|
}
|
|
2920
3031
|
});
|
|
2921
3032
|
|
|
2922
3033
|
// src/components/IFrameLoaderView.tsx
|
|
2923
|
-
var
|
|
3034
|
+
var import_react36, import_jsx_runtime51, IFrameLoaderView, IFrameLoaderView_default;
|
|
2924
3035
|
var init_IFrameLoaderView = __esm({
|
|
2925
3036
|
"src/components/IFrameLoaderView.tsx"() {
|
|
2926
3037
|
"use strict";
|
|
2927
|
-
|
|
3038
|
+
import_react36 = __toESM(require("react"));
|
|
2928
3039
|
import_jsx_runtime51 = require("react/jsx-runtime");
|
|
2929
3040
|
IFrameLoaderView = (props) => {
|
|
2930
|
-
return /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(
|
|
3041
|
+
return /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(import_react36.default.Fragment, { children: [
|
|
2931
3042
|
props.isDataFound == null && /* @__PURE__ */ (0, import_jsx_runtime51.jsx)("div", { className: "", children: /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)("div", { className: "mt-4 bg-gray-200 rounded-md p-4 animate-pulse", children: [
|
|
2932
3043
|
/* @__PURE__ */ (0, import_jsx_runtime51.jsxs)("div", { className: "flex items-center mb-4", children: [
|
|
2933
3044
|
/* @__PURE__ */ (0, import_jsx_runtime51.jsx)("div", { className: "bg-gray-300 h-8 w-8 rounded-full animate-pulse" }),
|
|
@@ -2972,12 +3083,12 @@ var IframeClient_exports = {};
|
|
|
2972
3083
|
__export(IframeClient_exports, {
|
|
2973
3084
|
default: () => IframeClient_default
|
|
2974
3085
|
});
|
|
2975
|
-
var
|
|
3086
|
+
var import_react37, import_jsx_runtime52, IframeClient, IframeClient_default;
|
|
2976
3087
|
var init_IframeClient = __esm({
|
|
2977
3088
|
"src/components/pageRenderingEngine/nodes/IframeClient.tsx"() {
|
|
2978
3089
|
"use strict";
|
|
2979
3090
|
"use client";
|
|
2980
|
-
|
|
3091
|
+
import_react37 = __toESM(require("react"));
|
|
2981
3092
|
init_IFrameLoaderView();
|
|
2982
3093
|
import_jsx_runtime52 = require("react/jsx-runtime");
|
|
2983
3094
|
IframeClient = ({
|
|
@@ -2985,10 +3096,10 @@ var init_IframeClient = __esm({
|
|
|
2985
3096
|
width,
|
|
2986
3097
|
height
|
|
2987
3098
|
}) => {
|
|
2988
|
-
const iframeRef = (0,
|
|
2989
|
-
const [iframeHeight, setIframeHeight] = (0,
|
|
2990
|
-
const [isDataFound, setIsDataFound] = (0,
|
|
2991
|
-
(0,
|
|
3099
|
+
const iframeRef = (0, import_react37.useRef)(null);
|
|
3100
|
+
const [iframeHeight, setIframeHeight] = (0, import_react37.useState)("100%");
|
|
3101
|
+
const [isDataFound, setIsDataFound] = (0, import_react37.useState)(null);
|
|
3102
|
+
(0, import_react37.useEffect)(() => {
|
|
2992
3103
|
const handleReceiveMessage = (event) => {
|
|
2993
3104
|
const eventName = event?.data?.eventName;
|
|
2994
3105
|
const payload = event?.data?.payload;
|
|
@@ -3003,7 +3114,7 @@ var init_IframeClient = __esm({
|
|
|
3003
3114
|
window.addEventListener("message", handleReceiveMessage);
|
|
3004
3115
|
return () => window.removeEventListener("message", handleReceiveMessage);
|
|
3005
3116
|
}, []);
|
|
3006
|
-
(0,
|
|
3117
|
+
(0, import_react37.useEffect)(() => {
|
|
3007
3118
|
const handleResize = () => {
|
|
3008
3119
|
if (iframeRef.current) {
|
|
3009
3120
|
iframeRef.current.contentWindow?.postMessage(
|
|
@@ -3018,7 +3129,7 @@ var init_IframeClient = __esm({
|
|
|
3018
3129
|
const handleIframeLoad = () => {
|
|
3019
3130
|
setIsDataFound(true);
|
|
3020
3131
|
};
|
|
3021
|
-
return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
|
|
3132
|
+
return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(import_react37.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(IFrameLoaderView_default, { isDataFound, children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
|
|
3022
3133
|
"iframe",
|
|
3023
3134
|
{
|
|
3024
3135
|
ref: iframeRef,
|
|
@@ -3402,12 +3513,12 @@ var Pagination_exports = {};
|
|
|
3402
3513
|
__export(Pagination_exports, {
|
|
3403
3514
|
default: () => Pagination_default
|
|
3404
3515
|
});
|
|
3405
|
-
var
|
|
3516
|
+
var import_react38, import_jsx_runtime63, Pagination, Pagination_default;
|
|
3406
3517
|
var init_Pagination = __esm({
|
|
3407
3518
|
"src/components/Pagination.tsx"() {
|
|
3408
3519
|
"use strict";
|
|
3409
3520
|
"use client";
|
|
3410
|
-
|
|
3521
|
+
import_react38 = require("react");
|
|
3411
3522
|
init_OdataBuilder();
|
|
3412
3523
|
init_Icon();
|
|
3413
3524
|
init_StyleTypes();
|
|
@@ -3416,7 +3527,7 @@ var init_Pagination = __esm({
|
|
|
3416
3527
|
import_jsx_runtime63 = require("react/jsx-runtime");
|
|
3417
3528
|
Pagination = (props) => {
|
|
3418
3529
|
const { dataset, path, query, showPageSizeSelector = false, showJumpToPage = false } = props;
|
|
3419
|
-
const builder = (0,
|
|
3530
|
+
const builder = (0, import_react38.useMemo)(() => {
|
|
3420
3531
|
const b = new OdataBuilder(path);
|
|
3421
3532
|
if (query) b.setQuery(query);
|
|
3422
3533
|
return b;
|
|
@@ -3582,11 +3693,11 @@ var init_Pagination = __esm({
|
|
|
3582
3693
|
});
|
|
3583
3694
|
|
|
3584
3695
|
// src/components/controls/edit/MultilineTextInput.tsx
|
|
3585
|
-
var
|
|
3696
|
+
var import_react39, import_jsx_runtime64, MultilineTextInput, MultilineTextInput_default;
|
|
3586
3697
|
var init_MultilineTextInput = __esm({
|
|
3587
3698
|
"src/components/controls/edit/MultilineTextInput.tsx"() {
|
|
3588
3699
|
"use strict";
|
|
3589
|
-
|
|
3700
|
+
import_react39 = __toESM(require("react"));
|
|
3590
3701
|
import_jsx_runtime64 = require("react/jsx-runtime");
|
|
3591
3702
|
MultilineTextInput = (props) => {
|
|
3592
3703
|
const textChangeHandler = (event) => {
|
|
@@ -3606,7 +3717,7 @@ var init_MultilineTextInput = __esm({
|
|
|
3606
3717
|
if (props.value !== void 0 && props.value !== null) {
|
|
3607
3718
|
value = props.value;
|
|
3608
3719
|
}
|
|
3609
|
-
return /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(
|
|
3720
|
+
return /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(import_react39.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime64.jsxs)("label", { className: "block mb-1", children: [
|
|
3610
3721
|
/* @__PURE__ */ (0, import_jsx_runtime64.jsx)("span", { className: "text-sm font-medium ", children: props?.attributes?.label }),
|
|
3611
3722
|
" ",
|
|
3612
3723
|
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */ (0, import_jsx_runtime64.jsx)("span", { className: "bg-error-weak", children: "*" }),
|
|
@@ -3635,11 +3746,11 @@ var init_MultilineTextInput = __esm({
|
|
|
3635
3746
|
});
|
|
3636
3747
|
|
|
3637
3748
|
// src/components/controls/edit/LineTextInput.tsx
|
|
3638
|
-
var
|
|
3749
|
+
var import_react40, import_jsx_runtime65, LineTextInput, LineTextInput_default;
|
|
3639
3750
|
var init_LineTextInput = __esm({
|
|
3640
3751
|
"src/components/controls/edit/LineTextInput.tsx"() {
|
|
3641
3752
|
"use strict";
|
|
3642
|
-
|
|
3753
|
+
import_react40 = __toESM(require("react"));
|
|
3643
3754
|
import_jsx_runtime65 = require("react/jsx-runtime");
|
|
3644
3755
|
LineTextInput = (props) => {
|
|
3645
3756
|
const textChangeHandler = (event) => {
|
|
@@ -3659,7 +3770,7 @@ var init_LineTextInput = __esm({
|
|
|
3659
3770
|
if (props.value !== void 0 && props.value !== null) {
|
|
3660
3771
|
value = props.value;
|
|
3661
3772
|
}
|
|
3662
|
-
return /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(
|
|
3773
|
+
return /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(import_react40.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime65.jsxs)("label", { className: "block", children: [
|
|
3663
3774
|
props?.attributes?.label && /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("span", { className: "text-sm inline-block pb-1 font-medium ", children: props?.attributes?.label }),
|
|
3664
3775
|
" ",
|
|
3665
3776
|
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("span", { className: "bg-error-weak !bg-transparent", children: "*" }),
|
|
@@ -3692,11 +3803,11 @@ var init_LineTextInput = __esm({
|
|
|
3692
3803
|
});
|
|
3693
3804
|
|
|
3694
3805
|
// src/components/controls/edit/MoneyInput.tsx
|
|
3695
|
-
var
|
|
3806
|
+
var import_react41, import_jsx_runtime66, MoneyInput, MoneyInput_default;
|
|
3696
3807
|
var init_MoneyInput = __esm({
|
|
3697
3808
|
"src/components/controls/edit/MoneyInput.tsx"() {
|
|
3698
3809
|
"use strict";
|
|
3699
|
-
|
|
3810
|
+
import_react41 = __toESM(require("react"));
|
|
3700
3811
|
import_jsx_runtime66 = require("react/jsx-runtime");
|
|
3701
3812
|
MoneyInput = (props) => {
|
|
3702
3813
|
const textChangeHandler = (event) => {
|
|
@@ -3726,7 +3837,7 @@ var init_MoneyInput = __esm({
|
|
|
3726
3837
|
e.preventDefault();
|
|
3727
3838
|
}
|
|
3728
3839
|
};
|
|
3729
|
-
return /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(
|
|
3840
|
+
return /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(import_react41.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime66.jsxs)("label", { className: "block mb-1", children: [
|
|
3730
3841
|
/* @__PURE__ */ (0, import_jsx_runtime66.jsx)("span", { className: "text-sm font-medium ", children: props?.attributes?.label }),
|
|
3731
3842
|
" ",
|
|
3732
3843
|
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */ (0, import_jsx_runtime66.jsx)("span", { className: "bg-error-weak", children: "*" }),
|
|
@@ -3758,14 +3869,14 @@ var init_MoneyInput = __esm({
|
|
|
3758
3869
|
});
|
|
3759
3870
|
|
|
3760
3871
|
// src/components/controls/edit/Select.tsx
|
|
3761
|
-
var
|
|
3872
|
+
var import_react42, import_jsx_runtime67, Select, Select_default;
|
|
3762
3873
|
var init_Select = __esm({
|
|
3763
3874
|
"src/components/controls/edit/Select.tsx"() {
|
|
3764
3875
|
"use strict";
|
|
3765
|
-
|
|
3876
|
+
import_react42 = require("react");
|
|
3766
3877
|
import_jsx_runtime67 = require("react/jsx-runtime");
|
|
3767
3878
|
Select = (props) => {
|
|
3768
|
-
const [list, setList] = (0,
|
|
3879
|
+
const [list, setList] = (0, import_react42.useState)();
|
|
3769
3880
|
const getSafeValue = (val) => {
|
|
3770
3881
|
if (val === null || val === void 0) return "";
|
|
3771
3882
|
if (typeof val === "boolean") return val ? "1" : "0";
|
|
@@ -3802,7 +3913,7 @@ var init_Select = __esm({
|
|
|
3802
3913
|
groupKey: props.groupKey
|
|
3803
3914
|
});
|
|
3804
3915
|
};
|
|
3805
|
-
(0,
|
|
3916
|
+
(0, import_react42.useEffect)(() => {
|
|
3806
3917
|
async function fetchData() {
|
|
3807
3918
|
if (props.dataset) {
|
|
3808
3919
|
setList(props.dataset);
|
|
@@ -3886,11 +3997,11 @@ var init_Select = __esm({
|
|
|
3886
3997
|
});
|
|
3887
3998
|
|
|
3888
3999
|
// src/components/controls/edit/PercentageInput.tsx
|
|
3889
|
-
var
|
|
4000
|
+
var import_react43, import_jsx_runtime68, PercentageInput, PercentageInput_default;
|
|
3890
4001
|
var init_PercentageInput = __esm({
|
|
3891
4002
|
"src/components/controls/edit/PercentageInput.tsx"() {
|
|
3892
4003
|
"use strict";
|
|
3893
|
-
|
|
4004
|
+
import_react43 = __toESM(require("react"));
|
|
3894
4005
|
import_jsx_runtime68 = require("react/jsx-runtime");
|
|
3895
4006
|
PercentageInput = (props) => {
|
|
3896
4007
|
const textChangeHandler = (event) => {
|
|
@@ -3920,7 +4031,7 @@ var init_PercentageInput = __esm({
|
|
|
3920
4031
|
e.preventDefault();
|
|
3921
4032
|
}
|
|
3922
4033
|
};
|
|
3923
|
-
return /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
|
|
4034
|
+
return /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(import_react43.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime68.jsxs)("label", { className: "block mb-1", children: [
|
|
3924
4035
|
/* @__PURE__ */ (0, import_jsx_runtime68.jsx)("span", { className: "text-sm font-medium ", children: props?.attributes?.label ? props?.attributes?.label + " %" : "" }),
|
|
3925
4036
|
" ",
|
|
3926
4037
|
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */ (0, import_jsx_runtime68.jsx)("span", { className: "bg-error-weak", children: "*" }),
|
|
@@ -3951,11 +4062,11 @@ var init_PercentageInput = __esm({
|
|
|
3951
4062
|
});
|
|
3952
4063
|
|
|
3953
4064
|
// src/components/controls/edit/PhoneInput.tsx
|
|
3954
|
-
var
|
|
4065
|
+
var import_react44, import_jsx_runtime69, PhoneInput, PhoneInput_default;
|
|
3955
4066
|
var init_PhoneInput = __esm({
|
|
3956
4067
|
"src/components/controls/edit/PhoneInput.tsx"() {
|
|
3957
4068
|
"use strict";
|
|
3958
|
-
|
|
4069
|
+
import_react44 = __toESM(require("react"));
|
|
3959
4070
|
import_jsx_runtime69 = require("react/jsx-runtime");
|
|
3960
4071
|
PhoneInput = (props) => {
|
|
3961
4072
|
const textChangeHandler = (event) => {
|
|
@@ -3975,7 +4086,7 @@ var init_PhoneInput = __esm({
|
|
|
3975
4086
|
if (props.value !== void 0 && props.value !== null) {
|
|
3976
4087
|
value = props.value;
|
|
3977
4088
|
}
|
|
3978
|
-
return /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(
|
|
4089
|
+
return /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(import_react44.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime69.jsxs)("label", { className: "block mb-1", children: [
|
|
3979
4090
|
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)("span", { className: "text-sm font-medium ", children: props?.attributes?.label }),
|
|
3980
4091
|
" ",
|
|
3981
4092
|
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */ (0, import_jsx_runtime69.jsx)("span", { className: "bg-error-weak", children: "*" }),
|
|
@@ -4007,11 +4118,11 @@ var init_PhoneInput = __esm({
|
|
|
4007
4118
|
});
|
|
4008
4119
|
|
|
4009
4120
|
// src/components/controls/edit/NumberInput.tsx
|
|
4010
|
-
var
|
|
4121
|
+
var import_react45, import_jsx_runtime70, NumberInput, NumberInput_default;
|
|
4011
4122
|
var init_NumberInput = __esm({
|
|
4012
4123
|
"src/components/controls/edit/NumberInput.tsx"() {
|
|
4013
4124
|
"use strict";
|
|
4014
|
-
|
|
4125
|
+
import_react45 = __toESM(require("react"));
|
|
4015
4126
|
import_jsx_runtime70 = require("react/jsx-runtime");
|
|
4016
4127
|
NumberInput = (props) => {
|
|
4017
4128
|
const textChangeHandler = (event) => {
|
|
@@ -4035,7 +4146,7 @@ var init_NumberInput = __esm({
|
|
|
4035
4146
|
if (props.value !== void 0 && props.value !== null) {
|
|
4036
4147
|
value = props.value;
|
|
4037
4148
|
}
|
|
4038
|
-
return /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(
|
|
4149
|
+
return /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_react45.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime70.jsxs)("label", { className: "block", children: [
|
|
4039
4150
|
props?.attributes?.label && /* @__PURE__ */ (0, import_jsx_runtime70.jsx)("span", { className: "text-sm inline-block pb-1 font-medium ", children: props?.attributes?.label }),
|
|
4040
4151
|
" ",
|
|
4041
4152
|
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */ (0, import_jsx_runtime70.jsx)("span", { className: "bg-error-weak", children: "*" }),
|
|
@@ -4066,11 +4177,11 @@ var init_NumberInput = __esm({
|
|
|
4066
4177
|
});
|
|
4067
4178
|
|
|
4068
4179
|
// src/components/controls/edit/CheckboxInput.tsx
|
|
4069
|
-
var
|
|
4180
|
+
var import_react46, import_jsx_runtime71, CheckboxInput, CheckboxInput_default;
|
|
4070
4181
|
var init_CheckboxInput = __esm({
|
|
4071
4182
|
"src/components/controls/edit/CheckboxInput.tsx"() {
|
|
4072
4183
|
"use strict";
|
|
4073
|
-
|
|
4184
|
+
import_react46 = __toESM(require("react"));
|
|
4074
4185
|
import_jsx_runtime71 = require("react/jsx-runtime");
|
|
4075
4186
|
CheckboxInput = (props) => {
|
|
4076
4187
|
const textChangeHandler = (event) => {
|
|
@@ -4088,7 +4199,7 @@ var init_CheckboxInput = __esm({
|
|
|
4088
4199
|
if (props.value != void 0 && props.value != null && props.value != "" && (props.value == "true" || props.value.toString() == "true")) {
|
|
4089
4200
|
value = true;
|
|
4090
4201
|
}
|
|
4091
|
-
return /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(
|
|
4202
|
+
return /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(import_react46.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime71.jsxs)("div", { className: "mb-1", children: [
|
|
4092
4203
|
props?.attributes?.label && /* @__PURE__ */ (0, import_jsx_runtime71.jsxs)(import_jsx_runtime71.Fragment, { children: [
|
|
4093
4204
|
/* @__PURE__ */ (0, import_jsx_runtime71.jsx)(
|
|
4094
4205
|
"label",
|
|
@@ -4125,11 +4236,11 @@ var init_CheckboxInput = __esm({
|
|
|
4125
4236
|
});
|
|
4126
4237
|
|
|
4127
4238
|
// src/components/controls/edit/OtpInput.tsx
|
|
4128
|
-
var
|
|
4239
|
+
var import_react47, import_jsx_runtime72, OtpInput, OtpInput_default;
|
|
4129
4240
|
var init_OtpInput = __esm({
|
|
4130
4241
|
"src/components/controls/edit/OtpInput.tsx"() {
|
|
4131
4242
|
"use strict";
|
|
4132
|
-
|
|
4243
|
+
import_react47 = __toESM(require("react"));
|
|
4133
4244
|
import_jsx_runtime72 = require("react/jsx-runtime");
|
|
4134
4245
|
OtpInput = (props) => {
|
|
4135
4246
|
const textChangeHandler = (event) => {
|
|
@@ -4152,7 +4263,7 @@ var init_OtpInput = __esm({
|
|
|
4152
4263
|
if (props.value !== void 0 && props.value !== null) {
|
|
4153
4264
|
value = props.value;
|
|
4154
4265
|
}
|
|
4155
|
-
return /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(
|
|
4266
|
+
return /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_react47.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime72.jsxs)("label", { htmlFor: props.name, className: "block mb-1 w-full", children: [
|
|
4156
4267
|
/* @__PURE__ */ (0, import_jsx_runtime72.jsx)("span", { className: "text-sm font-medium ", children: props?.attributes?.label }),
|
|
4157
4268
|
" ",
|
|
4158
4269
|
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */ (0, import_jsx_runtime72.jsx)("span", { className: "bg-error-weak", children: "*" }),
|
|
@@ -4184,11 +4295,11 @@ var init_OtpInput = __esm({
|
|
|
4184
4295
|
});
|
|
4185
4296
|
|
|
4186
4297
|
// src/components/controls/edit/DateTimeInput.tsx
|
|
4187
|
-
var
|
|
4298
|
+
var import_react48, import_jsx_runtime73, DateTimeInput, DateTimeInput_default;
|
|
4188
4299
|
var init_DateTimeInput = __esm({
|
|
4189
4300
|
"src/components/controls/edit/DateTimeInput.tsx"() {
|
|
4190
4301
|
"use strict";
|
|
4191
|
-
|
|
4302
|
+
import_react48 = __toESM(require("react"));
|
|
4192
4303
|
import_jsx_runtime73 = require("react/jsx-runtime");
|
|
4193
4304
|
DateTimeInput = (props) => {
|
|
4194
4305
|
const textChangeHandler = (event) => {
|
|
@@ -4221,7 +4332,7 @@ var init_DateTimeInput = __esm({
|
|
|
4221
4332
|
e.preventDefault();
|
|
4222
4333
|
}
|
|
4223
4334
|
};
|
|
4224
|
-
return /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(
|
|
4335
|
+
return /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(import_react48.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime73.jsxs)("label", { className: "block mb-1", children: [
|
|
4225
4336
|
/* @__PURE__ */ (0, import_jsx_runtime73.jsx)("span", { className: "text-sm font-medium ", children: props?.attributes?.label }),
|
|
4226
4337
|
" ",
|
|
4227
4338
|
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */ (0, import_jsx_runtime73.jsx)("span", { className: "bg-error-weak", children: "*" }),
|
|
@@ -4254,15 +4365,15 @@ var init_DateTimeInput = __esm({
|
|
|
4254
4365
|
});
|
|
4255
4366
|
|
|
4256
4367
|
// src/components/controls/edit/ColorInput.tsx
|
|
4257
|
-
var
|
|
4368
|
+
var import_react49, import_jsx_runtime74, ColorInput, ColorInput_default;
|
|
4258
4369
|
var init_ColorInput = __esm({
|
|
4259
4370
|
"src/components/controls/edit/ColorInput.tsx"() {
|
|
4260
4371
|
"use strict";
|
|
4261
|
-
|
|
4372
|
+
import_react49 = __toESM(require("react"));
|
|
4262
4373
|
import_jsx_runtime74 = require("react/jsx-runtime");
|
|
4263
4374
|
ColorInput = (props) => {
|
|
4264
|
-
const [color, setColor] =
|
|
4265
|
-
(0,
|
|
4375
|
+
const [color, setColor] = import_react49.default.useState("#3b82f6");
|
|
4376
|
+
(0, import_react49.useEffect)(() => {
|
|
4266
4377
|
if (props.value !== void 0 && props.value !== null) {
|
|
4267
4378
|
if (typeof props.value === "string") {
|
|
4268
4379
|
setColor(props.value);
|
|
@@ -4306,22 +4417,22 @@ var init_ColorInput = __esm({
|
|
|
4306
4417
|
});
|
|
4307
4418
|
|
|
4308
4419
|
// src/components/controls/edit/SelectWithSearchInput.tsx
|
|
4309
|
-
var
|
|
4420
|
+
var import_react50, import_jsx_runtime75, SelectWithSearchInput, SelectWithSearchInput_default;
|
|
4310
4421
|
var init_SelectWithSearchInput = __esm({
|
|
4311
4422
|
"src/components/controls/edit/SelectWithSearchInput.tsx"() {
|
|
4312
4423
|
"use strict";
|
|
4313
4424
|
"use client";
|
|
4314
|
-
|
|
4425
|
+
import_react50 = __toESM(require("react"));
|
|
4315
4426
|
import_jsx_runtime75 = require("react/jsx-runtime");
|
|
4316
4427
|
SelectWithSearchInput = (props) => {
|
|
4317
|
-
const [isOpen, setIsOpen] = (0,
|
|
4318
|
-
const [searchTerm, setSearchTerm] = (0,
|
|
4319
|
-
const [highlightedIndex, setHighlightedIndex] = (0,
|
|
4320
|
-
const [selectedItem, setSelectedItem] = (0,
|
|
4428
|
+
const [isOpen, setIsOpen] = (0, import_react50.useState)(false);
|
|
4429
|
+
const [searchTerm, setSearchTerm] = (0, import_react50.useState)("");
|
|
4430
|
+
const [highlightedIndex, setHighlightedIndex] = (0, import_react50.useState)(-1);
|
|
4431
|
+
const [selectedItem, setSelectedItem] = (0, import_react50.useState)(
|
|
4321
4432
|
null
|
|
4322
4433
|
);
|
|
4323
|
-
const [list, setList] = (0,
|
|
4324
|
-
const loadData =
|
|
4434
|
+
const [list, setList] = (0, import_react50.useState)([]);
|
|
4435
|
+
const loadData = import_react50.default.useCallback(async () => {
|
|
4325
4436
|
if (props.dataset) {
|
|
4326
4437
|
setList(props.dataset);
|
|
4327
4438
|
return;
|
|
@@ -4346,10 +4457,10 @@ var init_SelectWithSearchInput = __esm({
|
|
|
4346
4457
|
props.dataSourceDependsOn,
|
|
4347
4458
|
props.dependentValue
|
|
4348
4459
|
]);
|
|
4349
|
-
(0,
|
|
4460
|
+
(0, import_react50.useEffect)(() => {
|
|
4350
4461
|
loadData();
|
|
4351
4462
|
}, [loadData]);
|
|
4352
|
-
(0,
|
|
4463
|
+
(0, import_react50.useEffect)(() => {
|
|
4353
4464
|
if (props.value && list.length && props.dataKeyFieldName && props.dataTextFieldName) {
|
|
4354
4465
|
const selected = list.find(
|
|
4355
4466
|
(x) => x[props.dataKeyFieldName] == props.value
|
|
@@ -4396,8 +4507,8 @@ var init_SelectWithSearchInput = __esm({
|
|
|
4396
4507
|
handleSelect(e, filteredItems[highlightedIndex]);
|
|
4397
4508
|
}
|
|
4398
4509
|
};
|
|
4399
|
-
const dropdownRef = (0,
|
|
4400
|
-
(0,
|
|
4510
|
+
const dropdownRef = (0, import_react50.useRef)(null);
|
|
4511
|
+
(0, import_react50.useEffect)(() => {
|
|
4401
4512
|
if (highlightedIndex >= 0 && dropdownRef.current) {
|
|
4402
4513
|
const highlightedItem = dropdownRef.current.children[highlightedIndex];
|
|
4403
4514
|
highlightedItem?.scrollIntoView({
|
|
@@ -4495,28 +4606,28 @@ var init_SelectWithSearchInput = __esm({
|
|
|
4495
4606
|
});
|
|
4496
4607
|
|
|
4497
4608
|
// src/components/controls/edit/SelectWithSearchPanel.tsx
|
|
4498
|
-
var
|
|
4609
|
+
var import_react51, import_jsx_runtime76, SelectWithSearchPanel, SelectWithSearchPanel_default;
|
|
4499
4610
|
var init_SelectWithSearchPanel = __esm({
|
|
4500
4611
|
"src/components/controls/edit/SelectWithSearchPanel.tsx"() {
|
|
4501
4612
|
"use strict";
|
|
4502
4613
|
"use client";
|
|
4503
4614
|
init_Button();
|
|
4504
|
-
|
|
4615
|
+
import_react51 = __toESM(require("react"));
|
|
4505
4616
|
import_jsx_runtime76 = require("react/jsx-runtime");
|
|
4506
4617
|
SelectWithSearchPanel = (props) => {
|
|
4507
|
-
const [isOpen, setIsOpen] = (0,
|
|
4508
|
-
const [searchTerm, setSearchTerm] = (0,
|
|
4509
|
-
const [highlightedIndex, setHighlightedIndex] = (0,
|
|
4510
|
-
const [list, setList] = (0,
|
|
4511
|
-
const listRef = (0,
|
|
4512
|
-
const [isError, setIsError] = (0,
|
|
4513
|
-
const containerRef = (0,
|
|
4514
|
-
const [isCreateOpen, setIsCreateOpen] = (0,
|
|
4515
|
-
const [formData, setFormData] = (0,
|
|
4618
|
+
const [isOpen, setIsOpen] = (0, import_react51.useState)(false);
|
|
4619
|
+
const [searchTerm, setSearchTerm] = (0, import_react51.useState)("");
|
|
4620
|
+
const [highlightedIndex, setHighlightedIndex] = (0, import_react51.useState)(0);
|
|
4621
|
+
const [list, setList] = (0, import_react51.useState)([]);
|
|
4622
|
+
const listRef = (0, import_react51.useRef)(null);
|
|
4623
|
+
const [isError, setIsError] = (0, import_react51.useState)(false);
|
|
4624
|
+
const containerRef = (0, import_react51.useRef)(null);
|
|
4625
|
+
const [isCreateOpen, setIsCreateOpen] = (0, import_react51.useState)(false);
|
|
4626
|
+
const [formData, setFormData] = (0, import_react51.useState)({});
|
|
4516
4627
|
const getNestedValue7 = (obj, path) => {
|
|
4517
4628
|
return path.split(".").reduce((acc, key) => acc?.[key], obj);
|
|
4518
4629
|
};
|
|
4519
|
-
(0,
|
|
4630
|
+
(0, import_react51.useEffect)(() => {
|
|
4520
4631
|
const handleClickOutside = (event) => {
|
|
4521
4632
|
if (containerRef.current && !containerRef.current.contains(event.target)) {
|
|
4522
4633
|
setIsOpen(false);
|
|
@@ -4527,7 +4638,7 @@ var init_SelectWithSearchPanel = __esm({
|
|
|
4527
4638
|
document.removeEventListener("mousedown", handleClickOutside);
|
|
4528
4639
|
};
|
|
4529
4640
|
}, []);
|
|
4530
|
-
(0,
|
|
4641
|
+
(0, import_react51.useEffect)(() => {
|
|
4531
4642
|
async function fetchData() {
|
|
4532
4643
|
if (props.dataset) {
|
|
4533
4644
|
setList(props.dataset);
|
|
@@ -4569,7 +4680,7 @@ var init_SelectWithSearchPanel = __esm({
|
|
|
4569
4680
|
audioCtx.close();
|
|
4570
4681
|
}, 250);
|
|
4571
4682
|
};
|
|
4572
|
-
(0,
|
|
4683
|
+
(0, import_react51.useEffect)(() => {
|
|
4573
4684
|
const filteredItems2 = list?.filter(
|
|
4574
4685
|
(item) => item[props?.dataTextFieldName]?.toLowerCase().includes(searchTerm?.toLowerCase())
|
|
4575
4686
|
);
|
|
@@ -4634,7 +4745,7 @@ var init_SelectWithSearchPanel = __esm({
|
|
|
4634
4745
|
const handleInputChange = (event, field) => {
|
|
4635
4746
|
setFormData((prev) => ({ ...prev, [field]: event.target.value }));
|
|
4636
4747
|
};
|
|
4637
|
-
const handleSaveModal = (0,
|
|
4748
|
+
const handleSaveModal = (0, import_react51.useCallback)(async () => {
|
|
4638
4749
|
console.log("Form Data:", formData);
|
|
4639
4750
|
return formData;
|
|
4640
4751
|
}, []);
|
|
@@ -4659,7 +4770,7 @@ var init_SelectWithSearchPanel = __esm({
|
|
|
4659
4770
|
disabled:bg-slate-50 disabled:text-slate-500 disabled:border-slate-200 disabled:shadow-none`
|
|
4660
4771
|
}
|
|
4661
4772
|
) }),
|
|
4662
|
-
/* @__PURE__ */ (0, import_jsx_runtime76.jsx)("div", { ref: containerRef, children: isOpen && /* @__PURE__ */ (0, import_jsx_runtime76.jsxs)(
|
|
4773
|
+
/* @__PURE__ */ (0, import_jsx_runtime76.jsx)("div", { ref: containerRef, children: isOpen && /* @__PURE__ */ (0, import_jsx_runtime76.jsxs)(import_react51.default.Fragment, { children: [
|
|
4663
4774
|
/* @__PURE__ */ (0, import_jsx_runtime76.jsxs)("div", { className: "fixed z-50 right-0 bg-white top-[62px] w-1/4 border-l border-gray-200", children: [
|
|
4664
4775
|
/* @__PURE__ */ (0, import_jsx_runtime76.jsx)("div", { className: "flex flex-col p-2 bg-accent-950 text-white", children: /* @__PURE__ */ (0, import_jsx_runtime76.jsxs)("h5", { className: "text-md text-white font-medium", children: [
|
|
4665
4776
|
"Select a",
|
|
@@ -4750,11 +4861,11 @@ var init_SelectWithSearchPanel = __esm({
|
|
|
4750
4861
|
});
|
|
4751
4862
|
|
|
4752
4863
|
// src/components/controls/edit/EmailInput.tsx
|
|
4753
|
-
var
|
|
4864
|
+
var import_react52, import_jsx_runtime77, EmailInput, EmailInput_default;
|
|
4754
4865
|
var init_EmailInput = __esm({
|
|
4755
4866
|
"src/components/controls/edit/EmailInput.tsx"() {
|
|
4756
4867
|
"use strict";
|
|
4757
|
-
|
|
4868
|
+
import_react52 = __toESM(require("react"));
|
|
4758
4869
|
import_jsx_runtime77 = require("react/jsx-runtime");
|
|
4759
4870
|
EmailInput = (props) => {
|
|
4760
4871
|
const textChangeHandler = (event) => {
|
|
@@ -4780,7 +4891,7 @@ var init_EmailInput = __esm({
|
|
|
4780
4891
|
if (props.value !== void 0 && props.value !== null) {
|
|
4781
4892
|
value = props.value;
|
|
4782
4893
|
}
|
|
4783
|
-
return /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(
|
|
4894
|
+
return /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(import_react52.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime77.jsxs)("label", { className: "block mb-1", children: [
|
|
4784
4895
|
/* @__PURE__ */ (0, import_jsx_runtime77.jsx)("span", { className: "text-sm font-medium text-slate-700", children: props?.attributes?.label }),
|
|
4785
4896
|
" ",
|
|
4786
4897
|
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */ (0, import_jsx_runtime77.jsx)("span", { className: "bg-error-weak", children: "*" }),
|
|
@@ -4808,12 +4919,12 @@ var init_EmailInput = __esm({
|
|
|
4808
4919
|
});
|
|
4809
4920
|
|
|
4810
4921
|
// src/components/controls/edit/TimeInput.tsx
|
|
4811
|
-
var
|
|
4922
|
+
var import_react53, import_jsx_runtime78, TimeInput, TimeInput_default;
|
|
4812
4923
|
var init_TimeInput = __esm({
|
|
4813
4924
|
"src/components/controls/edit/TimeInput.tsx"() {
|
|
4814
4925
|
"use strict";
|
|
4815
4926
|
"use client";
|
|
4816
|
-
|
|
4927
|
+
import_react53 = __toESM(require("react"));
|
|
4817
4928
|
import_jsx_runtime78 = require("react/jsx-runtime");
|
|
4818
4929
|
TimeInput = (props) => {
|
|
4819
4930
|
const timeChangeHandler = (event) => {
|
|
@@ -4827,7 +4938,7 @@ var init_TimeInput = __esm({
|
|
|
4827
4938
|
});
|
|
4828
4939
|
}
|
|
4829
4940
|
};
|
|
4830
|
-
return /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(
|
|
4941
|
+
return /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(import_react53.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime78.jsxs)("label", { className: "block mb-1", children: [
|
|
4831
4942
|
/* @__PURE__ */ (0, import_jsx_runtime78.jsx)("span", { className: "text-sm font-medium", children: props?.attributes?.label }),
|
|
4832
4943
|
" ",
|
|
4833
4944
|
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */ (0, import_jsx_runtime78.jsx)("span", { className: "bg-error-weak", children: "*" }),
|
|
@@ -4852,12 +4963,12 @@ var init_TimeInput = __esm({
|
|
|
4852
4963
|
});
|
|
4853
4964
|
|
|
4854
4965
|
// src/components/controls/edit/AssetUpload.tsx
|
|
4855
|
-
var
|
|
4966
|
+
var import_react54, import_jsx_runtime79, AssetUpload, AssetUpload_default;
|
|
4856
4967
|
var init_AssetUpload = __esm({
|
|
4857
4968
|
"src/components/controls/edit/AssetUpload.tsx"() {
|
|
4858
4969
|
"use strict";
|
|
4859
4970
|
"use client";
|
|
4860
|
-
|
|
4971
|
+
import_react54 = __toESM(require("react"));
|
|
4861
4972
|
init_ClientButton();
|
|
4862
4973
|
init_StyleTypes();
|
|
4863
4974
|
init_AssetUtility();
|
|
@@ -4884,8 +4995,8 @@ var init_AssetUpload = __esm({
|
|
|
4884
4995
|
}
|
|
4885
4996
|
return "image";
|
|
4886
4997
|
};
|
|
4887
|
-
const [assetType, setAssetType] =
|
|
4888
|
-
(0,
|
|
4998
|
+
const [assetType, setAssetType] = import_react54.default.useState(getInitialTab);
|
|
4999
|
+
(0, import_react54.useEffect)(() => {
|
|
4889
5000
|
setAssetType(getInitialTab());
|
|
4890
5001
|
}, [props.value]);
|
|
4891
5002
|
const assetUploadCallback = (newAsset) => {
|
|
@@ -4960,7 +5071,7 @@ var init_AssetUpload = __esm({
|
|
|
4960
5071
|
}
|
|
4961
5072
|
return false;
|
|
4962
5073
|
};
|
|
4963
|
-
return /* @__PURE__ */ (0, import_jsx_runtime79.jsxs)(
|
|
5074
|
+
return /* @__PURE__ */ (0, import_jsx_runtime79.jsxs)(import_react54.default.Fragment, { children: [
|
|
4964
5075
|
/* @__PURE__ */ (0, import_jsx_runtime79.jsx)("label", { className: "block mb-1", children: /* @__PURE__ */ (0, import_jsx_runtime79.jsx)("span", { className: "text-sm font-medium", children: props?.attributes?.label }) }),
|
|
4965
5076
|
/* @__PURE__ */ (0, import_jsx_runtime79.jsxs)("div", { className: "flex gap-6 bg-neutral-100 rounded p-2", children: [
|
|
4966
5077
|
/* @__PURE__ */ (0, import_jsx_runtime79.jsx)(
|
|
@@ -5061,11 +5172,11 @@ var init_AssetUpload = __esm({
|
|
|
5061
5172
|
});
|
|
5062
5173
|
|
|
5063
5174
|
// src/components/controls/edit/SwitchInput.tsx
|
|
5064
|
-
var
|
|
5175
|
+
var import_react55, import_jsx_runtime80, SwitchInput, SwitchInput_default;
|
|
5065
5176
|
var init_SwitchInput = __esm({
|
|
5066
5177
|
"src/components/controls/edit/SwitchInput.tsx"() {
|
|
5067
5178
|
"use strict";
|
|
5068
|
-
|
|
5179
|
+
import_react55 = __toESM(require("react"));
|
|
5069
5180
|
import_jsx_runtime80 = require("react/jsx-runtime");
|
|
5070
5181
|
SwitchInput = (props) => {
|
|
5071
5182
|
const textChangeHandler = (event) => {
|
|
@@ -5083,7 +5194,7 @@ var init_SwitchInput = __esm({
|
|
|
5083
5194
|
if (props.value != void 0 && props.value != null && props.value != "" && (props.value == "true" || props.value.toString() == "true")) {
|
|
5084
5195
|
value = true;
|
|
5085
5196
|
}
|
|
5086
|
-
return /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(
|
|
5197
|
+
return /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(import_react55.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime80.jsxs)("div", { className: "flex items-start justify-between gap-4 py-3", children: [
|
|
5087
5198
|
/* @__PURE__ */ (0, import_jsx_runtime80.jsxs)("div", { className: "min-w-0", children: [
|
|
5088
5199
|
props?.attributes?.label && /* @__PURE__ */ (0, import_jsx_runtime80.jsxs)(
|
|
5089
5200
|
"label",
|
|
@@ -5221,15 +5332,15 @@ var init_DateTimeUtility = __esm({
|
|
|
5221
5332
|
});
|
|
5222
5333
|
|
|
5223
5334
|
// src/components/controls/edit/DateInput.tsx
|
|
5224
|
-
var
|
|
5335
|
+
var import_react56, import_jsx_runtime81, DateInput, DateInput_default;
|
|
5225
5336
|
var init_DateInput = __esm({
|
|
5226
5337
|
"src/components/controls/edit/DateInput.tsx"() {
|
|
5227
5338
|
"use strict";
|
|
5228
|
-
|
|
5339
|
+
import_react56 = require("react");
|
|
5229
5340
|
init_DateTimeUtility();
|
|
5230
5341
|
import_jsx_runtime81 = require("react/jsx-runtime");
|
|
5231
5342
|
DateInput = (props) => {
|
|
5232
|
-
const value = (0,
|
|
5343
|
+
const value = (0, import_react56.useMemo)(() => {
|
|
5233
5344
|
if (props.value === void 0 || props.value === null || props.value === "") {
|
|
5234
5345
|
return "";
|
|
5235
5346
|
}
|
|
@@ -5287,16 +5398,16 @@ var init_DateInput = __esm({
|
|
|
5287
5398
|
});
|
|
5288
5399
|
|
|
5289
5400
|
// src/components/controls/edit/RadioInput.tsx
|
|
5290
|
-
var
|
|
5401
|
+
var import_react57, import_jsx_runtime82, RadioInput, RadioInput_default;
|
|
5291
5402
|
var init_RadioInput = __esm({
|
|
5292
5403
|
"src/components/controls/edit/RadioInput.tsx"() {
|
|
5293
5404
|
"use strict";
|
|
5294
|
-
|
|
5405
|
+
import_react57 = require("react");
|
|
5295
5406
|
init_Icon();
|
|
5296
5407
|
import_jsx_runtime82 = require("react/jsx-runtime");
|
|
5297
5408
|
RadioInput = (props) => {
|
|
5298
|
-
const [list, setList] = (0,
|
|
5299
|
-
(0,
|
|
5409
|
+
const [list, setList] = (0, import_react57.useState)([]);
|
|
5410
|
+
(0, import_react57.useEffect)(() => {
|
|
5300
5411
|
async function loadData() {
|
|
5301
5412
|
if (props.dataset) {
|
|
5302
5413
|
setList(props.dataset);
|
|
@@ -5401,12 +5512,12 @@ var InputControlClient_exports = {};
|
|
|
5401
5512
|
__export(InputControlClient_exports, {
|
|
5402
5513
|
default: () => InputControlClient_default
|
|
5403
5514
|
});
|
|
5404
|
-
var
|
|
5515
|
+
var import_react58, import_jsx_runtime84, InputControl, InputControlClient_default;
|
|
5405
5516
|
var init_InputControlClient = __esm({
|
|
5406
5517
|
"src/components/controls/edit/InputControlClient.tsx"() {
|
|
5407
5518
|
"use strict";
|
|
5408
5519
|
"use client";
|
|
5409
|
-
|
|
5520
|
+
import_react58 = __toESM(require("react"));
|
|
5410
5521
|
init_MultilineTextInput();
|
|
5411
5522
|
init_LineTextInput();
|
|
5412
5523
|
init_MoneyInput();
|
|
@@ -5429,7 +5540,7 @@ var init_InputControlClient = __esm({
|
|
|
5429
5540
|
init_RadioInput();
|
|
5430
5541
|
init_ReferenceInput();
|
|
5431
5542
|
import_jsx_runtime84 = require("react/jsx-runtime");
|
|
5432
|
-
InputControl =
|
|
5543
|
+
InputControl = import_react58.default.forwardRef(
|
|
5433
5544
|
(props, ref) => {
|
|
5434
5545
|
const ControlComponents = {
|
|
5435
5546
|
[InputControlType_default.lineTextInput]: LineTextInput_default,
|
|
@@ -5454,7 +5565,7 @@ var init_InputControlClient = __esm({
|
|
|
5454
5565
|
[InputControlType_default.referenceInput]: ReferenceInput_default
|
|
5455
5566
|
};
|
|
5456
5567
|
const SelectedControlComponent = ControlComponents[props.controlType];
|
|
5457
|
-
return /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(
|
|
5568
|
+
return /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(import_react58.default.Fragment, { children: SelectedControlComponent ? /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(SelectedControlComponent, { ...props }) : "Control not found:" + props.controlType });
|
|
5458
5569
|
}
|
|
5459
5570
|
);
|
|
5460
5571
|
InputControl.displayName = "InputControl";
|
|
@@ -5463,12 +5574,12 @@ var init_InputControlClient = __esm({
|
|
|
5463
5574
|
});
|
|
5464
5575
|
|
|
5465
5576
|
// src/components/controls/edit/InputControl.tsx
|
|
5466
|
-
var
|
|
5577
|
+
var import_dynamic13, InputControl2, InputControl_default;
|
|
5467
5578
|
var init_InputControl = __esm({
|
|
5468
5579
|
"src/components/controls/edit/InputControl.tsx"() {
|
|
5469
5580
|
"use strict";
|
|
5470
|
-
|
|
5471
|
-
InputControl2 = (0,
|
|
5581
|
+
import_dynamic13 = __toESM(require("next/dynamic"));
|
|
5582
|
+
InputControl2 = (0, import_dynamic13.default)(() => Promise.resolve().then(() => (init_InputControlClient(), InputControlClient_exports)), {
|
|
5472
5583
|
ssr: false
|
|
5473
5584
|
});
|
|
5474
5585
|
InputControl_default = InputControl2;
|
|
@@ -5480,12 +5591,12 @@ var DataBindingControls_exports = {};
|
|
|
5480
5591
|
__export(DataBindingControls_exports, {
|
|
5481
5592
|
default: () => DataBindingControls_default
|
|
5482
5593
|
});
|
|
5483
|
-
var
|
|
5594
|
+
var import_react59, import_navigation, import_jsx_runtime85, humanize, escapeODataString, parseFacetSelections, buildFacetFilter, parseODataSearch, normalizeSortOption, DUMMY_FACETS, DUMMY_SORT_OPTIONS, DataBindingControls, DataBindingControls_default;
|
|
5484
5595
|
var init_DataBindingControls = __esm({
|
|
5485
5596
|
"src/components/pageRenderingEngine/nodes/DataBindingControls.tsx"() {
|
|
5486
5597
|
"use strict";
|
|
5487
5598
|
"use client";
|
|
5488
|
-
|
|
5599
|
+
import_react59 = require("react");
|
|
5489
5600
|
import_navigation = require("next/navigation");
|
|
5490
5601
|
init_InputControl();
|
|
5491
5602
|
init_InputControlType();
|
|
@@ -5566,12 +5677,12 @@ var init_DataBindingControls = __esm({
|
|
|
5566
5677
|
const selectedFacetValues = parseFacetSelections(currentFilter);
|
|
5567
5678
|
const currentSort = query?.["$orderby"] ?? query?.orderBy ?? "";
|
|
5568
5679
|
const currentSearch = parseODataSearch(query?.["$search"]);
|
|
5569
|
-
const [searchText, setSearchText] = (0,
|
|
5570
|
-
const lastNavigationUrl = (0,
|
|
5571
|
-
(0,
|
|
5680
|
+
const [searchText, setSearchText] = (0, import_react59.useState)(currentSearch);
|
|
5681
|
+
const lastNavigationUrl = (0, import_react59.useRef)(null);
|
|
5682
|
+
(0, import_react59.useEffect)(() => {
|
|
5572
5683
|
setSearchText(currentSearch);
|
|
5573
5684
|
}, [currentSearch]);
|
|
5574
|
-
const getQueryUrl = (0,
|
|
5685
|
+
const getQueryUrl = (0, import_react59.useCallback)(
|
|
5575
5686
|
(updates) => {
|
|
5576
5687
|
const params = new URLSearchParams(query ?? {});
|
|
5577
5688
|
Object.entries(updates).forEach(([key, value]) => {
|
|
@@ -5601,7 +5712,7 @@ var init_DataBindingControls = __esm({
|
|
|
5601
5712
|
filter: void 0
|
|
5602
5713
|
});
|
|
5603
5714
|
};
|
|
5604
|
-
const navigateWithoutReload = (0,
|
|
5715
|
+
const navigateWithoutReload = (0, import_react59.useCallback)(
|
|
5605
5716
|
(url) => {
|
|
5606
5717
|
if (lastNavigationUrl.current === url) {
|
|
5607
5718
|
return;
|
|
@@ -5617,7 +5728,7 @@ var init_DataBindingControls = __esm({
|
|
|
5617
5728
|
},
|
|
5618
5729
|
[router]
|
|
5619
5730
|
);
|
|
5620
|
-
(0,
|
|
5731
|
+
(0, import_react59.useEffect)(() => {
|
|
5621
5732
|
const trimmedSearchText = searchText.trim();
|
|
5622
5733
|
if (trimmedSearchText === currentSearch.trim()) {
|
|
5623
5734
|
return;
|
|
@@ -5721,12 +5832,12 @@ var Slider_exports = {};
|
|
|
5721
5832
|
__export(Slider_exports, {
|
|
5722
5833
|
default: () => Slider_default
|
|
5723
5834
|
});
|
|
5724
|
-
var
|
|
5835
|
+
var import_react60, import_jsx_runtime86, Slider, ArrowButton, ProgressPill, Slider_default;
|
|
5725
5836
|
var init_Slider = __esm({
|
|
5726
5837
|
"src/components/Slider.tsx"() {
|
|
5727
5838
|
"use strict";
|
|
5728
5839
|
"use client";
|
|
5729
|
-
|
|
5840
|
+
import_react60 = __toESM(require("react"));
|
|
5730
5841
|
import_jsx_runtime86 = require("react/jsx-runtime");
|
|
5731
5842
|
Slider = ({
|
|
5732
5843
|
children,
|
|
@@ -5743,15 +5854,16 @@ var init_Slider = __esm({
|
|
|
5743
5854
|
dotInactiveClassName = "bg-gray-600",
|
|
5744
5855
|
gap,
|
|
5745
5856
|
pillStyle = "cumulative",
|
|
5746
|
-
progressPosition = "bottom"
|
|
5857
|
+
progressPosition = "bottom",
|
|
5858
|
+
scrollByColumns = false
|
|
5747
5859
|
}) => {
|
|
5748
|
-
const [currentSlide, setCurrentSlide] = (0,
|
|
5749
|
-
const [transition, setTransition] = (0,
|
|
5750
|
-
const [slidesToShowState, setSlidesToShowState] = (0,
|
|
5860
|
+
const [currentSlide, setCurrentSlide] = (0, import_react60.useState)(0);
|
|
5861
|
+
const [transition, setTransition] = (0, import_react60.useState)(true);
|
|
5862
|
+
const [slidesToShowState, setSlidesToShowState] = (0, import_react60.useState)(
|
|
5751
5863
|
typeof slidesToShow === "number" ? slidesToShow : slidesToShow.large
|
|
5752
5864
|
);
|
|
5753
|
-
const [isPlaying, setIsPlaying] = (0,
|
|
5754
|
-
(0,
|
|
5865
|
+
const [isPlaying, setIsPlaying] = (0, import_react60.useState)(autoplay);
|
|
5866
|
+
(0, import_react60.useEffect)(() => {
|
|
5755
5867
|
if (typeof slidesToShow === "number") return;
|
|
5756
5868
|
const handleResize = () => {
|
|
5757
5869
|
if (window.innerWidth >= 1024) {
|
|
@@ -5766,7 +5878,7 @@ var init_Slider = __esm({
|
|
|
5766
5878
|
window.addEventListener("resize", handleResize);
|
|
5767
5879
|
return () => window.removeEventListener("resize", handleResize);
|
|
5768
5880
|
}, [slidesToShow]);
|
|
5769
|
-
(0,
|
|
5881
|
+
(0, import_react60.useEffect)(() => {
|
|
5770
5882
|
if (!autoplay) return;
|
|
5771
5883
|
const timer = setInterval(() => {
|
|
5772
5884
|
if (isPlaying) {
|
|
@@ -5775,8 +5887,9 @@ var init_Slider = __esm({
|
|
|
5775
5887
|
}, autoplay_speed);
|
|
5776
5888
|
return () => clearInterval(timer);
|
|
5777
5889
|
}, [autoplay, autoplay_speed, currentSlide, isPlaying]);
|
|
5778
|
-
const totalSlides =
|
|
5779
|
-
const maxSlide = totalSlides - slidesToShowState;
|
|
5890
|
+
const totalSlides = import_react60.Children.count(children);
|
|
5891
|
+
const maxSlide = Math.max(0, totalSlides - slidesToShowState);
|
|
5892
|
+
const step = scrollByColumns ? typeof slidesToShowState === "number" && slidesToShowState > 0 ? Math.floor(slidesToShowState) : 1 : 1;
|
|
5780
5893
|
const nextSlide = () => {
|
|
5781
5894
|
if (currentSlide >= maxSlide) {
|
|
5782
5895
|
if (infinite_scroll) {
|
|
@@ -5785,7 +5898,8 @@ var init_Slider = __esm({
|
|
|
5785
5898
|
}
|
|
5786
5899
|
} else {
|
|
5787
5900
|
setTransition(true);
|
|
5788
|
-
|
|
5901
|
+
const nextIndex = currentSlide + step;
|
|
5902
|
+
setCurrentSlide(nextIndex > maxSlide ? maxSlide : nextIndex);
|
|
5789
5903
|
}
|
|
5790
5904
|
};
|
|
5791
5905
|
const prevSlide = () => {
|
|
@@ -5796,7 +5910,8 @@ var init_Slider = __esm({
|
|
|
5796
5910
|
}
|
|
5797
5911
|
} else {
|
|
5798
5912
|
setTransition(true);
|
|
5799
|
-
|
|
5913
|
+
const prevIndex = currentSlide - step;
|
|
5914
|
+
setCurrentSlide(prevIndex < 0 ? 0 : prevIndex);
|
|
5800
5915
|
}
|
|
5801
5916
|
};
|
|
5802
5917
|
const goToSlide = (index) => {
|
|
@@ -5820,8 +5935,8 @@ var init_Slider = __esm({
|
|
|
5820
5935
|
}
|
|
5821
5936
|
};
|
|
5822
5937
|
const translateX = -currentSlide * (100 / slidesToShowState);
|
|
5823
|
-
const slides =
|
|
5824
|
-
if (!
|
|
5938
|
+
const slides = import_react60.Children.map(children, (child, index) => {
|
|
5939
|
+
if (!import_react60.default.isValidElement(child)) return null;
|
|
5825
5940
|
const childProps = child.props;
|
|
5826
5941
|
const mergedClassName = `${childProps.className ?? ""} w-full`.trim();
|
|
5827
5942
|
return /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(
|
|
@@ -5829,7 +5944,7 @@ var init_Slider = __esm({
|
|
|
5829
5944
|
{
|
|
5830
5945
|
className: `flex-none ${scaleOnHover ? "group hover:z-50" : ""} relative`,
|
|
5831
5946
|
style: { width: `calc(${100 / slidesToShowState}%)`, paddingRight: gap },
|
|
5832
|
-
children: (0,
|
|
5947
|
+
children: (0, import_react60.cloneElement)(child, {
|
|
5833
5948
|
className: mergedClassName
|
|
5834
5949
|
})
|
|
5835
5950
|
},
|
|
@@ -5942,13 +6057,13 @@ var init_Slider = __esm({
|
|
|
5942
6057
|
currentSlide,
|
|
5943
6058
|
totalSlides
|
|
5944
6059
|
}) => {
|
|
5945
|
-
const [progress, setProgress] = (0,
|
|
5946
|
-
(0,
|
|
6060
|
+
const [progress, setProgress] = (0, import_react60.useState)(0);
|
|
6061
|
+
(0, import_react60.useEffect)(() => {
|
|
5947
6062
|
if (active) {
|
|
5948
6063
|
setProgress(0);
|
|
5949
6064
|
}
|
|
5950
6065
|
}, [active, index]);
|
|
5951
|
-
(0,
|
|
6066
|
+
(0, import_react60.useEffect)(() => {
|
|
5952
6067
|
if (!active || !isPlaying) {
|
|
5953
6068
|
if (!active) {
|
|
5954
6069
|
setProgress(0);
|
|
@@ -6053,10 +6168,10 @@ __export(server_exports, {
|
|
|
6053
6168
|
module.exports = __toCommonJS(server_exports);
|
|
6054
6169
|
|
|
6055
6170
|
// src/components/pageRenderingEngine/PageBodyRenderer.tsx
|
|
6056
|
-
var
|
|
6171
|
+
var import_react62 = __toESM(require("react"));
|
|
6057
6172
|
|
|
6058
6173
|
// src/components/pageRenderingEngine/nodes/ParagraphNode.tsx
|
|
6059
|
-
var
|
|
6174
|
+
var import_react28 = __toESM(require("react"));
|
|
6060
6175
|
|
|
6061
6176
|
// src/components/pageRenderingEngine/nodes/TextNode.tsx
|
|
6062
6177
|
var import_jsx_runtime = require("react/jsx-runtime");
|
|
@@ -6500,7 +6615,7 @@ var EquationNode = ({ node }) => {
|
|
|
6500
6615
|
var EquationNode_default = EquationNode;
|
|
6501
6616
|
|
|
6502
6617
|
// src/components/controls/view/ViewControl.tsx
|
|
6503
|
-
var
|
|
6618
|
+
var import_react27 = __toESM(require("react"));
|
|
6504
6619
|
|
|
6505
6620
|
// src/components/controls/view/ViewControlTypes.tsx
|
|
6506
6621
|
var ViewControlTypes = {
|
|
@@ -6792,56 +6907,10 @@ var CommentRenderer = (0, import_dynamic7.default)(() => Promise.resolve().then(
|
|
|
6792
6907
|
var Commentrenderer_default = CommentRenderer;
|
|
6793
6908
|
|
|
6794
6909
|
// src/components/controls/view/AvatarView.tsx
|
|
6795
|
-
var
|
|
6796
|
-
var
|
|
6797
|
-
|
|
6798
|
-
|
|
6799
|
-
"bg-warning-base",
|
|
6800
|
-
"bg-success-base",
|
|
6801
|
-
"bg-info-base",
|
|
6802
|
-
"bg-primary-base",
|
|
6803
|
-
"bg-secondary-base"
|
|
6804
|
-
];
|
|
6805
|
-
var getAvatarColor = (text) => {
|
|
6806
|
-
let hash = 0;
|
|
6807
|
-
for (let i = 0; i < text.length; i += 1) {
|
|
6808
|
-
hash = hash * 31 + text.charCodeAt(i) >>> 0;
|
|
6809
|
-
}
|
|
6810
|
-
return AVATAR_COLORS[hash % AVATAR_COLORS.length];
|
|
6811
|
-
};
|
|
6812
|
-
var getInitials = (text) => {
|
|
6813
|
-
const words = text.trim().split(/\s+/).filter(Boolean);
|
|
6814
|
-
if (words.length === 0) {
|
|
6815
|
-
return "?";
|
|
6816
|
-
}
|
|
6817
|
-
if (words.length === 1) {
|
|
6818
|
-
return words[0].slice(0, 2).toUpperCase();
|
|
6819
|
-
}
|
|
6820
|
-
return `${words[0][0]}${words[words.length - 1][0]}`.toUpperCase();
|
|
6821
|
-
};
|
|
6822
|
-
var AvatarView = (props) => {
|
|
6823
|
-
const text = props.value === null || props.value === void 0 ? "" : String(props.value).trim();
|
|
6824
|
-
if (!text) {
|
|
6825
|
-
return null;
|
|
6826
|
-
}
|
|
6827
|
-
const size = props.width ?? "1.75rem";
|
|
6828
|
-
return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
6829
|
-
"span",
|
|
6830
|
-
{
|
|
6831
|
-
className: `avatar-view inline-flex flex-shrink-0 items-center justify-center rounded-full font-semibold uppercase select-none overflow-hidden ${getAvatarColor(text)}`,
|
|
6832
|
-
title: text,
|
|
6833
|
-
"aria-label": text,
|
|
6834
|
-
style: {
|
|
6835
|
-
width: size,
|
|
6836
|
-
height: size,
|
|
6837
|
-
fontSize: "0.6875rem",
|
|
6838
|
-
letterSpacing: "0.02em",
|
|
6839
|
-
lineHeight: 1
|
|
6840
|
-
},
|
|
6841
|
-
children: getInitials(text)
|
|
6842
|
-
}
|
|
6843
|
-
);
|
|
6844
|
-
};
|
|
6910
|
+
var import_dynamic8 = __toESM(require("next/dynamic"));
|
|
6911
|
+
var AvatarView = (0, import_dynamic8.default)(() => Promise.resolve().then(() => (init_AvatarViewClient(), AvatarViewClient_exports)), {
|
|
6912
|
+
ssr: false
|
|
6913
|
+
});
|
|
6845
6914
|
var AvatarView_default = AvatarView;
|
|
6846
6915
|
|
|
6847
6916
|
// src/components/controls/view/ViewControl.tsx
|
|
@@ -6877,7 +6946,7 @@ var ViewControl = (props) => {
|
|
|
6877
6946
|
[ViewControlTypes_default.avatar]: AvatarView_default
|
|
6878
6947
|
};
|
|
6879
6948
|
const SelectedControlComponent = props.controlType ? ControlComponents[props.controlType] : void 0;
|
|
6880
|
-
return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
|
|
6949
|
+
return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_react27.default.Fragment, { children: SelectedControlComponent ? /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(SelectedControlComponent, { ...props }) : "Control not found:" + props.controlType });
|
|
6881
6950
|
};
|
|
6882
6951
|
var ViewControl_default = ViewControl;
|
|
6883
6952
|
|
|
@@ -7017,7 +7086,7 @@ var ParagraphNode = (props) => {
|
|
|
7017
7086
|
if (isInlineOnlyParent) {
|
|
7018
7087
|
return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(import_jsx_runtime42.Fragment, { children: hasChildren && props.node.children.map((node, index) => {
|
|
7019
7088
|
const SelectedNode = NodeTypes2[node.type];
|
|
7020
|
-
return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
|
|
7089
|
+
return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(import_react28.default.Fragment, { children: SelectedNode && /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
|
|
7021
7090
|
SelectedNode,
|
|
7022
7091
|
{
|
|
7023
7092
|
node,
|
|
@@ -7033,7 +7102,7 @@ var ParagraphNode = (props) => {
|
|
|
7033
7102
|
return /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)("div", { className: " " + formatClasses, children: [
|
|
7034
7103
|
hasChildren && props.node.children.map((node, index) => {
|
|
7035
7104
|
const SelectedNode = NodeTypes2[node.type];
|
|
7036
|
-
return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
|
|
7105
|
+
return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(import_react28.default.Fragment, { children: SelectedNode && /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
|
|
7037
7106
|
SelectedNode,
|
|
7038
7107
|
{
|
|
7039
7108
|
node,
|
|
@@ -7051,7 +7120,7 @@ var ParagraphNode = (props) => {
|
|
|
7051
7120
|
var ParagraphNode_default = ParagraphNode;
|
|
7052
7121
|
|
|
7053
7122
|
// src/components/pageRenderingEngine/nodes/HeadingNode.tsx
|
|
7054
|
-
var
|
|
7123
|
+
var import_react29 = __toESM(require("react"));
|
|
7055
7124
|
var import_jsx_runtime43 = require("react/jsx-runtime");
|
|
7056
7125
|
var HeadingNode = (props) => {
|
|
7057
7126
|
const NodeTypes2 = {
|
|
@@ -7068,22 +7137,22 @@ var HeadingNode = (props) => {
|
|
|
7068
7137
|
{
|
|
7069
7138
|
}
|
|
7070
7139
|
const formatClasses = FormatClass[props.node.format] || "";
|
|
7071
|
-
return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(import_jsx_runtime43.Fragment, { children:
|
|
7140
|
+
return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(import_jsx_runtime43.Fragment, { children: import_react29.default.createElement(
|
|
7072
7141
|
HeadingTag,
|
|
7073
7142
|
{ className: formatClasses },
|
|
7074
7143
|
props.node.children && props.node.children.map((childNode, index) => {
|
|
7075
7144
|
const SelectedNode = NodeTypes2[childNode.type];
|
|
7076
|
-
return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
|
|
7145
|
+
return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(import_react29.default.Fragment, { children: SelectedNode && /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(SelectedNode, { node: childNode, dataitem: props.dataitem, session: props.session, apiBaseUrl: props.apiBaseUrl, assetBaseUrl: props.assetBaseUrl, routeParameters: props.routeParameters }) }, index);
|
|
7077
7146
|
})
|
|
7078
7147
|
) });
|
|
7079
7148
|
};
|
|
7080
7149
|
var HeadingNode_default = HeadingNode;
|
|
7081
7150
|
|
|
7082
7151
|
// src/components/pageRenderingEngine/nodes/ListNode.tsx
|
|
7083
|
-
var
|
|
7152
|
+
var import_react31 = __toESM(require("react"));
|
|
7084
7153
|
|
|
7085
7154
|
// src/components/pageRenderingEngine/nodes/ListItemNode.tsx
|
|
7086
|
-
var
|
|
7155
|
+
var import_react30 = __toESM(require("react"));
|
|
7087
7156
|
var import_jsx_runtime44 = require("react/jsx-runtime");
|
|
7088
7157
|
var ListItemNode = (props) => {
|
|
7089
7158
|
const NodeTypes2 = {
|
|
@@ -7112,7 +7181,7 @@ var ListItemNode = (props) => {
|
|
|
7112
7181
|
}
|
|
7113
7182
|
} else {
|
|
7114
7183
|
foundFirstBreak = false;
|
|
7115
|
-
return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
7184
|
+
return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_react30.default.Fragment, { children: SelectedNode && /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(SelectedNode, { node, dataitem: props.dataitem, routeParameters: props.routeParameters }) }, index);
|
|
7116
7185
|
}
|
|
7117
7186
|
}) });
|
|
7118
7187
|
};
|
|
@@ -7124,21 +7193,21 @@ var ListNode = (props) => {
|
|
|
7124
7193
|
const NodeTypes2 = {
|
|
7125
7194
|
listitem: ListItemNode_default
|
|
7126
7195
|
};
|
|
7127
|
-
return /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)(
|
|
7196
|
+
return /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)(import_react31.default.Fragment, { children: [
|
|
7128
7197
|
props.node.listType == "bullet" && /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("ul", { children: props.node.children && props.node.children.map((node, index) => {
|
|
7129
7198
|
const SelectedNode = NodeTypes2[node.type];
|
|
7130
|
-
return /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
|
|
7199
|
+
return /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(import_react31.default.Fragment, { children: SelectedNode && /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(SelectedNode, { node, dataitem: props.dataitem, routeParameters: props.routeParameters }) }, index);
|
|
7131
7200
|
}) }),
|
|
7132
7201
|
props.node.listType == "number" && /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("ol", { children: props.node.children && props.node.children.map((node, index) => {
|
|
7133
7202
|
const SelectedNode = NodeTypes2[node.type];
|
|
7134
|
-
return /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
|
|
7203
|
+
return /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(import_react31.default.Fragment, { children: SelectedNode && /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(SelectedNode, { node, dataitem: props.dataitem, routeParameters: props.routeParameters }) }, index);
|
|
7135
7204
|
}) })
|
|
7136
7205
|
] });
|
|
7137
7206
|
};
|
|
7138
7207
|
var ListNode_default = ListNode;
|
|
7139
7208
|
|
|
7140
7209
|
// src/components/pageRenderingEngine/nodes/QuoteNode.tsx
|
|
7141
|
-
var
|
|
7210
|
+
var import_react32 = __toESM(require("react"));
|
|
7142
7211
|
var import_jsx_runtime46 = require("react/jsx-runtime");
|
|
7143
7212
|
var QuoteNode = (props) => {
|
|
7144
7213
|
const NodeTypes2 = {
|
|
@@ -7148,16 +7217,16 @@ var QuoteNode = (props) => {
|
|
|
7148
7217
|
};
|
|
7149
7218
|
return /* @__PURE__ */ (0, import_jsx_runtime46.jsx)("blockquote", { children: props.node.children && props.node.children.map((node, index) => {
|
|
7150
7219
|
const SelectedNode = NodeTypes2[node.type];
|
|
7151
|
-
return /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(
|
|
7220
|
+
return /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(import_react32.default.Fragment, { children: SelectedNode && /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(SelectedNode, { node, session: props.session, apiBaseUrl: props.apiBaseUrl, routeParameters: props.routeParameters }) }, index);
|
|
7152
7221
|
}) });
|
|
7153
7222
|
};
|
|
7154
7223
|
var QuoteNode_default = QuoteNode;
|
|
7155
7224
|
|
|
7156
7225
|
// src/components/pageRenderingEngine/nodes/CodeNode.tsx
|
|
7157
|
-
var
|
|
7158
|
-
var
|
|
7226
|
+
var import_react34 = __toESM(require("react"));
|
|
7227
|
+
var import_dynamic9 = __toESM(require("next/dynamic"));
|
|
7159
7228
|
var import_jsx_runtime48 = require("react/jsx-runtime");
|
|
7160
|
-
var CopyButton2 = (0,
|
|
7229
|
+
var CopyButton2 = (0, import_dynamic9.default)(() => Promise.resolve().then(() => (init_CopyButton(), CopyButton_exports)), {
|
|
7161
7230
|
ssr: false,
|
|
7162
7231
|
// optional: fallback UI while loading
|
|
7163
7232
|
loading: () => /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("span", { className: "text-gray-400 text-xs", children: "Copy" })
|
|
@@ -7181,7 +7250,7 @@ var CodeNode = (props) => {
|
|
|
7181
7250
|
] }),
|
|
7182
7251
|
/* @__PURE__ */ (0, import_jsx_runtime48.jsx)("code", { className: "bg-neutral-soft p-4 text-sm whitespace-pre-wrap border border-2 block", children: props.node.children && props.node.children.map((node, index) => {
|
|
7183
7252
|
const SelectedNode = NodeTypes2[node.type];
|
|
7184
|
-
return /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
|
|
7253
|
+
return /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(import_react34.default.Fragment, { children: SelectedNode && /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
|
|
7185
7254
|
SelectedNode,
|
|
7186
7255
|
{
|
|
7187
7256
|
node,
|
|
@@ -7203,7 +7272,7 @@ var HorizontalRuleNode = () => {
|
|
|
7203
7272
|
var HorizontalRuleNode_default = HorizontalRuleNode;
|
|
7204
7273
|
|
|
7205
7274
|
// src/components/pageRenderingEngine/nodes/WidgetNode.tsx
|
|
7206
|
-
var
|
|
7275
|
+
var import_react35 = __toESM(require("react"));
|
|
7207
7276
|
var import_jsx_runtime50 = require("react/jsx-runtime");
|
|
7208
7277
|
var WidgetNode = (props) => {
|
|
7209
7278
|
const getWidgetParameters = () => {
|
|
@@ -7277,7 +7346,7 @@ var WidgetNode = (props) => {
|
|
|
7277
7346
|
}
|
|
7278
7347
|
return (
|
|
7279
7348
|
// eslint-disable-next-line react-hooks/static-components
|
|
7280
|
-
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
|
|
7349
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(import_react35.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
|
|
7281
7350
|
WidgetRenderer,
|
|
7282
7351
|
{
|
|
7283
7352
|
params: widgetParams,
|
|
@@ -7294,13 +7363,13 @@ var WidgetNode = (props) => {
|
|
|
7294
7363
|
var WidgetNode_default = WidgetNode;
|
|
7295
7364
|
|
|
7296
7365
|
// src/components/pageRenderingEngine/nodes/DivContainer.tsx
|
|
7297
|
-
var
|
|
7298
|
-
var
|
|
7366
|
+
var import_dynamic14 = __toESM(require("next/dynamic"));
|
|
7367
|
+
var import_react61 = __toESM(require("react"));
|
|
7299
7368
|
|
|
7300
7369
|
// src/components/pageRenderingEngine/nodes/EmbedNode.tsx
|
|
7301
|
-
var
|
|
7370
|
+
var import_dynamic10 = __toESM(require("next/dynamic"));
|
|
7302
7371
|
var import_jsx_runtime53 = require("react/jsx-runtime");
|
|
7303
|
-
var IframeClient2 = (0,
|
|
7372
|
+
var IframeClient2 = (0, import_dynamic10.default)(() => Promise.resolve().then(() => (init_IframeClient(), IframeClient_exports)), {
|
|
7304
7373
|
ssr: false
|
|
7305
7374
|
});
|
|
7306
7375
|
var EmbedNode = (props) => {
|
|
@@ -7542,9 +7611,9 @@ var NoDataFound_default = NoDataFound;
|
|
|
7542
7611
|
|
|
7543
7612
|
// src/components/pageRenderingEngine/nodes/ImageGalleryNode.tsx
|
|
7544
7613
|
init_AssetUtility();
|
|
7545
|
-
var
|
|
7614
|
+
var import_dynamic11 = __toESM(require("next/dynamic"));
|
|
7546
7615
|
var import_jsx_runtime55 = require("react/jsx-runtime");
|
|
7547
|
-
var HlsPlayer4 = (0,
|
|
7616
|
+
var HlsPlayer4 = (0, import_dynamic11.default)(() => Promise.resolve().then(() => (init_HlsPlayer(), HlsPlayer_exports)), { ssr: false });
|
|
7548
7617
|
var deviceToMediaQuery = (device) => {
|
|
7549
7618
|
switch (device) {
|
|
7550
7619
|
case "lg":
|
|
@@ -8391,9 +8460,9 @@ var DocumentNode = (props) => {
|
|
|
8391
8460
|
var DocumentNode_default = DocumentNode;
|
|
8392
8461
|
|
|
8393
8462
|
// src/components/pageRenderingEngine/nodes/GoogleMapNode.tsx
|
|
8394
|
-
var
|
|
8463
|
+
var import_dynamic12 = __toESM(require("next/dynamic"));
|
|
8395
8464
|
var import_jsx_runtime57 = require("react/jsx-runtime");
|
|
8396
|
-
var IframeClient3 = (0,
|
|
8465
|
+
var IframeClient3 = (0, import_dynamic12.default)(() => Promise.resolve().then(() => (init_IframeClient(), IframeClient_exports)), {
|
|
8397
8466
|
ssr: false
|
|
8398
8467
|
});
|
|
8399
8468
|
var GoogleMapNode = (props) => {
|
|
@@ -8411,11 +8480,11 @@ var GoogleMapNode_default = GoogleMapNode;
|
|
|
8411
8480
|
|
|
8412
8481
|
// src/components/pageRenderingEngine/nodes/DivContainer.tsx
|
|
8413
8482
|
var import_jsx_runtime87 = require("react/jsx-runtime");
|
|
8414
|
-
var Pagination2 = (0,
|
|
8415
|
-
var DataBindingControls2 = (0,
|
|
8483
|
+
var Pagination2 = (0, import_dynamic14.default)(() => Promise.resolve().then(() => (init_Pagination(), Pagination_exports)), { ssr: true });
|
|
8484
|
+
var DataBindingControls2 = (0, import_dynamic14.default)(() => Promise.resolve().then(() => (init_DataBindingControls(), DataBindingControls_exports)), {
|
|
8416
8485
|
ssr: true
|
|
8417
8486
|
});
|
|
8418
|
-
var Slider2 = (0,
|
|
8487
|
+
var Slider2 = (0, import_dynamic14.default)(() => Promise.resolve().then(() => (init_Slider(), Slider_exports)), {
|
|
8419
8488
|
ssr: false
|
|
8420
8489
|
});
|
|
8421
8490
|
function toCamelCase(str) {
|
|
@@ -8694,7 +8763,7 @@ var DivContainer = async (props) => {
|
|
|
8694
8763
|
}
|
|
8695
8764
|
const SelectedNode = NodeTypes2[node.type];
|
|
8696
8765
|
if (!SelectedNode) return null;
|
|
8697
|
-
return /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(
|
|
8766
|
+
return /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(import_react61.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(
|
|
8698
8767
|
SelectedNode,
|
|
8699
8768
|
{
|
|
8700
8769
|
node,
|
|
@@ -8786,7 +8855,7 @@ var DivContainer = async (props) => {
|
|
|
8786
8855
|
item,
|
|
8787
8856
|
idx,
|
|
8788
8857
|
props.href ? void 0 : item?.links?.view
|
|
8789
|
-
)?.map((child, i) => /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(
|
|
8858
|
+
)?.map((child, i) => /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(import_react61.default.Fragment, { children: child }, i)) : renderChildren2(props.node.children, props, item, idx)
|
|
8790
8859
|
);
|
|
8791
8860
|
}
|
|
8792
8861
|
return props.node.children.flatMap((node, childIndex) => {
|
|
@@ -8918,14 +8987,14 @@ var DivContainer = async (props) => {
|
|
|
8918
8987
|
dataset: response
|
|
8919
8988
|
}
|
|
8920
8989
|
) : null;
|
|
8921
|
-
return /* @__PURE__ */ (0, import_jsx_runtime87.jsxs)(
|
|
8990
|
+
return /* @__PURE__ */ (0, import_jsx_runtime87.jsxs)(import_react61.default.Fragment, { children: [
|
|
8922
8991
|
/* @__PURE__ */ (0, import_jsx_runtime87.jsx)(
|
|
8923
8992
|
"style",
|
|
8924
8993
|
{
|
|
8925
8994
|
dangerouslySetInnerHTML: { __html: cssResult.css + animationCSS }
|
|
8926
8995
|
}
|
|
8927
8996
|
),
|
|
8928
|
-
showDataBindingControls ? /* @__PURE__ */ (0, import_jsx_runtime87.jsxs)(
|
|
8997
|
+
showDataBindingControls ? /* @__PURE__ */ (0, import_jsx_runtime87.jsxs)(import_react61.default.Fragment, { children: [
|
|
8929
8998
|
/* @__PURE__ */ (0, import_jsx_runtime87.jsx)(
|
|
8930
8999
|
DataBindingControls2,
|
|
8931
9000
|
{
|
|
@@ -8963,7 +9032,7 @@ var DivContainer = async (props) => {
|
|
|
8963
9032
|
]
|
|
8964
9033
|
}
|
|
8965
9034
|
)
|
|
8966
|
-
] }) : /* @__PURE__ */ (0, import_jsx_runtime87.jsxs)(
|
|
9035
|
+
] }) : /* @__PURE__ */ (0, import_jsx_runtime87.jsxs)(import_react61.default.Fragment, { children: [
|
|
8967
9036
|
renderedContainer,
|
|
8968
9037
|
paginationControl && /* @__PURE__ */ (0, import_jsx_runtime87.jsx)("div", { children: paginationControl })
|
|
8969
9038
|
] })
|
|
@@ -9010,14 +9079,14 @@ var PageBodyRenderer = (props) => {
|
|
|
9010
9079
|
}
|
|
9011
9080
|
return true;
|
|
9012
9081
|
};
|
|
9013
|
-
return /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(
|
|
9082
|
+
return /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(import_react62.default.Fragment, { children: rootNode && rootNode?.children?.map((node, index) => {
|
|
9014
9083
|
{
|
|
9015
9084
|
}
|
|
9016
9085
|
const SelectedNode = NodeTypes[node.type];
|
|
9017
9086
|
if (!shouldRenderNode(node)) {
|
|
9018
9087
|
return null;
|
|
9019
9088
|
}
|
|
9020
|
-
return /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(
|
|
9089
|
+
return /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(import_react62.default.Fragment, { children: SelectedNode && /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(import_react62.default.Fragment, { children: node.type == "layout-container" ? /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(import_react62.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(
|
|
9021
9090
|
SelectedNode,
|
|
9022
9091
|
{
|
|
9023
9092
|
node,
|
|
@@ -9033,7 +9102,7 @@ var PageBodyRenderer = (props) => {
|
|
|
9033
9102
|
device: props.device,
|
|
9034
9103
|
widgetRenderer: props.widgetRenderer
|
|
9035
9104
|
}
|
|
9036
|
-
) }) : /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(
|
|
9105
|
+
) }) : /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(import_react62.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(
|
|
9037
9106
|
SelectedNode,
|
|
9038
9107
|
{
|
|
9039
9108
|
node,
|