@acoustte-digital-services/digitalstore-controls-dev 0.8.1-dev.20260423093014 → 0.8.1-dev.20260423095249
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +2 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.js +267 -261
- package/dist/index.mjs +213 -207
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -495,14 +495,14 @@ var HlsPlayer_exports = {};
|
|
|
495
495
|
__export(HlsPlayer_exports, {
|
|
496
496
|
default: () => HlsPlayer_default
|
|
497
497
|
});
|
|
498
|
-
var import_react35, import_hls,
|
|
498
|
+
var import_react35, import_hls, import_jsx_runtime45, HlsPlayer, HlsPlayer_default;
|
|
499
499
|
var init_HlsPlayer = __esm({
|
|
500
500
|
"src/components/HlsPlayer.tsx"() {
|
|
501
501
|
"use strict";
|
|
502
502
|
"use client";
|
|
503
503
|
import_react35 = __toESM(require("react"));
|
|
504
504
|
import_hls = __toESM(require("hls.js"));
|
|
505
|
-
|
|
505
|
+
import_jsx_runtime45 = require("react/jsx-runtime");
|
|
506
506
|
HlsPlayer = import_react35.default.memo(
|
|
507
507
|
({
|
|
508
508
|
sources,
|
|
@@ -645,7 +645,7 @@ var init_HlsPlayer = __esm({
|
|
|
645
645
|
const fallbackPoster = posterUrl ?? resolvedSources.find((s) => !s.media)?.posterUrl ?? resolvedSources[0]?.posterUrl;
|
|
646
646
|
const isPlayOnHover = playOptions === "playOnHover";
|
|
647
647
|
if (resolvedSources.length === 0) return null;
|
|
648
|
-
return /* @__PURE__ */ (0,
|
|
648
|
+
return /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)(
|
|
649
649
|
"div",
|
|
650
650
|
{
|
|
651
651
|
className: "relative w-full aspect-video bg-black",
|
|
@@ -653,7 +653,7 @@ var init_HlsPlayer = __esm({
|
|
|
653
653
|
onMouseLeave: handleMouseLeave,
|
|
654
654
|
onMouseMove: handleMouseMove,
|
|
655
655
|
children: [
|
|
656
|
-
/* @__PURE__ */ (0,
|
|
656
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
|
|
657
657
|
"video",
|
|
658
658
|
{
|
|
659
659
|
ref: videoRef,
|
|
@@ -665,7 +665,7 @@ var init_HlsPlayer = __esm({
|
|
|
665
665
|
loop,
|
|
666
666
|
playsInline: true,
|
|
667
667
|
onClick: !isMobile ? handlePlayPause : void 0,
|
|
668
|
-
children: resolvedSources.map(({ src, media }, i) => /* @__PURE__ */ (0,
|
|
668
|
+
children: resolvedSources.map(({ src, media }, i) => /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
|
|
669
669
|
"source",
|
|
670
670
|
{
|
|
671
671
|
src,
|
|
@@ -676,7 +676,7 @@ var init_HlsPlayer = __esm({
|
|
|
676
676
|
))
|
|
677
677
|
}
|
|
678
678
|
),
|
|
679
|
-
!isMobile && fallbackPoster && /* @__PURE__ */ (0,
|
|
679
|
+
!isMobile && fallbackPoster && /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)(
|
|
680
680
|
"picture",
|
|
681
681
|
{
|
|
682
682
|
className: "absolute inset-0 pointer-events-none",
|
|
@@ -685,8 +685,8 @@ var init_HlsPlayer = __esm({
|
|
|
685
685
|
transition: "opacity 0.4s ease"
|
|
686
686
|
},
|
|
687
687
|
children: [
|
|
688
|
-
posterSources.map(({ media, posterUrl: src }, i) => /* @__PURE__ */ (0,
|
|
689
|
-
/* @__PURE__ */ (0,
|
|
688
|
+
posterSources.map(({ media, posterUrl: src }, i) => /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("source", { media, srcSet: src }, i)),
|
|
689
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
|
|
690
690
|
"img",
|
|
691
691
|
{
|
|
692
692
|
src: fallbackPoster,
|
|
@@ -699,7 +699,7 @@ var init_HlsPlayer = __esm({
|
|
|
699
699
|
]
|
|
700
700
|
}
|
|
701
701
|
),
|
|
702
|
-
!isMobile && !isPlayOnHover && /* @__PURE__ */ (0,
|
|
702
|
+
!isMobile && !isPlayOnHover && /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
|
|
703
703
|
"div",
|
|
704
704
|
{
|
|
705
705
|
className: "absolute inset-0 flex items-center justify-center pointer-events-none",
|
|
@@ -707,7 +707,7 @@ var init_HlsPlayer = __esm({
|
|
|
707
707
|
opacity: isControlsVisible ? 1 : 0,
|
|
708
708
|
transition: "opacity 0.3s ease"
|
|
709
709
|
},
|
|
710
|
-
children: /* @__PURE__ */ (0,
|
|
710
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
|
|
711
711
|
"button",
|
|
712
712
|
{
|
|
713
713
|
type: "button",
|
|
@@ -746,13 +746,13 @@ var init_HlsPlayer = __esm({
|
|
|
746
746
|
},
|
|
747
747
|
children: isPlaying ? (
|
|
748
748
|
/* Pause — two rounded bars */
|
|
749
|
-
/* @__PURE__ */ (0,
|
|
750
|
-
/* @__PURE__ */ (0,
|
|
751
|
-
/* @__PURE__ */ (0,
|
|
749
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsxs)("svg", { width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: [
|
|
750
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)("rect", { x: "3.5", y: "2.5", width: "4.5", height: "15", rx: "1.5", fill: "white" }),
|
|
751
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)("rect", { x: "12", y: "2.5", width: "4.5", height: "15", rx: "1.5", fill: "white" })
|
|
752
752
|
] })
|
|
753
753
|
) : (
|
|
754
754
|
/* Play — solid triangle, nudged right for optical balance */
|
|
755
|
-
/* @__PURE__ */ (0,
|
|
755
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)("svg", { width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("path", { d: "M5 3.5L17 10L5 16.5V3.5Z", fill: "white" }) })
|
|
756
756
|
)
|
|
757
757
|
}
|
|
758
758
|
)
|
|
@@ -773,7 +773,7 @@ var LinkNodeButton_exports = {};
|
|
|
773
773
|
__export(LinkNodeButton_exports, {
|
|
774
774
|
default: () => LinkNodeButton_default
|
|
775
775
|
});
|
|
776
|
-
var import_react37,
|
|
776
|
+
var import_react37, import_jsx_runtime48, LinkNodeButton, LinkNodeButton_default;
|
|
777
777
|
var init_LinkNodeButton = __esm({
|
|
778
778
|
"src/components/pageRenderingEngine/nodes/LinkNodeButton.tsx"() {
|
|
779
779
|
"use strict";
|
|
@@ -782,7 +782,7 @@ var init_LinkNodeButton = __esm({
|
|
|
782
782
|
init_Button();
|
|
783
783
|
init_ServiceClient();
|
|
784
784
|
init_ToastService();
|
|
785
|
-
|
|
785
|
+
import_jsx_runtime48 = require("react/jsx-runtime");
|
|
786
786
|
LinkNodeButton = (props) => {
|
|
787
787
|
const { node, dataitem, children, linkText, linkType, linkUrl } = props;
|
|
788
788
|
const [isLoading, setIsLoading] = (0, import_react37.useState)(false);
|
|
@@ -925,11 +925,11 @@ var init_LinkNodeButton = __esm({
|
|
|
925
925
|
return children;
|
|
926
926
|
}
|
|
927
927
|
if (linkText) {
|
|
928
|
-
return /* @__PURE__ */ (0,
|
|
928
|
+
return /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("span", { children: linkText });
|
|
929
929
|
}
|
|
930
930
|
return node.title || "Button";
|
|
931
931
|
};
|
|
932
|
-
return /* @__PURE__ */ (0,
|
|
932
|
+
return /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("div", { className: "link-button-wrapper", children: /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
|
|
933
933
|
Button_default,
|
|
934
934
|
{
|
|
935
935
|
ButtonType: linkType,
|
|
@@ -967,13 +967,13 @@ function CopyButton({ text }) {
|
|
|
967
967
|
console.error("Failed to copy: ", err);
|
|
968
968
|
}
|
|
969
969
|
};
|
|
970
|
-
return /* @__PURE__ */ (0,
|
|
970
|
+
return /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(
|
|
971
971
|
"button",
|
|
972
972
|
{
|
|
973
973
|
onClick: handleCopy,
|
|
974
974
|
className: "flex gap-1 items-center hover:text-white transition",
|
|
975
975
|
children: [
|
|
976
|
-
/* @__PURE__ */ (0,
|
|
976
|
+
/* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
|
|
977
977
|
"svg",
|
|
978
978
|
{
|
|
979
979
|
width: "16",
|
|
@@ -981,7 +981,7 @@ function CopyButton({ text }) {
|
|
|
981
981
|
viewBox: "0 0 24 24",
|
|
982
982
|
className: "w-4 h-4",
|
|
983
983
|
fill: "currentColor",
|
|
984
|
-
children: /* @__PURE__ */ (0,
|
|
984
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
|
|
985
985
|
"path",
|
|
986
986
|
{
|
|
987
987
|
fillRule: "evenodd",
|
|
@@ -996,54 +996,54 @@ function CopyButton({ text }) {
|
|
|
996
996
|
}
|
|
997
997
|
);
|
|
998
998
|
}
|
|
999
|
-
var import_react44,
|
|
999
|
+
var import_react44, import_jsx_runtime58;
|
|
1000
1000
|
var init_CopyButton = __esm({
|
|
1001
1001
|
"src/components/CopyButton.tsx"() {
|
|
1002
1002
|
"use strict";
|
|
1003
1003
|
"use client";
|
|
1004
1004
|
import_react44 = require("react");
|
|
1005
|
-
|
|
1005
|
+
import_jsx_runtime58 = require("react/jsx-runtime");
|
|
1006
1006
|
}
|
|
1007
1007
|
});
|
|
1008
1008
|
|
|
1009
1009
|
// src/components/IFrameLoaderView.tsx
|
|
1010
|
-
var import_react48,
|
|
1010
|
+
var import_react48, import_jsx_runtime64, IFrameLoaderView, IFrameLoaderView_default;
|
|
1011
1011
|
var init_IFrameLoaderView = __esm({
|
|
1012
1012
|
"src/components/IFrameLoaderView.tsx"() {
|
|
1013
1013
|
"use strict";
|
|
1014
1014
|
import_react48 = __toESM(require("react"));
|
|
1015
|
-
|
|
1015
|
+
import_jsx_runtime64 = require("react/jsx-runtime");
|
|
1016
1016
|
IFrameLoaderView = (props) => {
|
|
1017
|
-
return /* @__PURE__ */ (0,
|
|
1018
|
-
props.isDataFound == null && /* @__PURE__ */ (0,
|
|
1019
|
-
/* @__PURE__ */ (0,
|
|
1020
|
-
/* @__PURE__ */ (0,
|
|
1021
|
-
/* @__PURE__ */ (0,
|
|
1022
|
-
/* @__PURE__ */ (0,
|
|
1023
|
-
/* @__PURE__ */ (0,
|
|
1017
|
+
return /* @__PURE__ */ (0, import_jsx_runtime64.jsxs)(import_react48.default.Fragment, { children: [
|
|
1018
|
+
props.isDataFound == null && /* @__PURE__ */ (0, import_jsx_runtime64.jsx)("div", { className: "", children: /* @__PURE__ */ (0, import_jsx_runtime64.jsxs)("div", { className: "mt-4 bg-gray-200 rounded-md p-4 animate-pulse", children: [
|
|
1019
|
+
/* @__PURE__ */ (0, import_jsx_runtime64.jsxs)("div", { className: "flex items-center mb-4", children: [
|
|
1020
|
+
/* @__PURE__ */ (0, import_jsx_runtime64.jsx)("div", { className: "bg-gray-300 h-8 w-8 rounded-full animate-pulse" }),
|
|
1021
|
+
/* @__PURE__ */ (0, import_jsx_runtime64.jsxs)("div", { className: "ml-2", children: [
|
|
1022
|
+
/* @__PURE__ */ (0, import_jsx_runtime64.jsx)("div", { className: "bg-gray-300 h-3 w-16 animate-pulse" }),
|
|
1023
|
+
/* @__PURE__ */ (0, import_jsx_runtime64.jsx)("div", { className: "bg-gray-300 h-2 w-12 animate-pulse" })
|
|
1024
1024
|
] })
|
|
1025
1025
|
] }),
|
|
1026
|
-
/* @__PURE__ */ (0,
|
|
1027
|
-
/* @__PURE__ */ (0,
|
|
1028
|
-
/* @__PURE__ */ (0,
|
|
1029
|
-
/* @__PURE__ */ (0,
|
|
1030
|
-
/* @__PURE__ */ (0,
|
|
1031
|
-
/* @__PURE__ */ (0,
|
|
1032
|
-
/* @__PURE__ */ (0,
|
|
1026
|
+
/* @__PURE__ */ (0, import_jsx_runtime64.jsxs)("div", { className: "grid grid-cols-3 gap-4 mt-6", children: [
|
|
1027
|
+
/* @__PURE__ */ (0, import_jsx_runtime64.jsxs)("div", { className: "animate-pulse", children: [
|
|
1028
|
+
/* @__PURE__ */ (0, import_jsx_runtime64.jsx)("div", { className: "bg-gray-300 rounded-full h-3 w-12 mb-2" }),
|
|
1029
|
+
/* @__PURE__ */ (0, import_jsx_runtime64.jsx)("div", { className: "bg-gray-300 rounded-full h-3 w-24 mb-2" }),
|
|
1030
|
+
/* @__PURE__ */ (0, import_jsx_runtime64.jsx)("div", { className: "bg-gray-300 rounded-full h-3 w-32 mb-2" }),
|
|
1031
|
+
/* @__PURE__ */ (0, import_jsx_runtime64.jsx)("div", { className: "bg-gray-300 rounded-full h-3 w-16 mb-2" }),
|
|
1032
|
+
/* @__PURE__ */ (0, import_jsx_runtime64.jsx)("div", { className: "bg-gray-300 rounded-full h-3 w-28 mb-2" })
|
|
1033
1033
|
] }),
|
|
1034
|
-
/* @__PURE__ */ (0,
|
|
1035
|
-
/* @__PURE__ */ (0,
|
|
1036
|
-
/* @__PURE__ */ (0,
|
|
1037
|
-
/* @__PURE__ */ (0,
|
|
1038
|
-
/* @__PURE__ */ (0,
|
|
1039
|
-
/* @__PURE__ */ (0,
|
|
1034
|
+
/* @__PURE__ */ (0, import_jsx_runtime64.jsxs)("div", { className: "animate-pulse", children: [
|
|
1035
|
+
/* @__PURE__ */ (0, import_jsx_runtime64.jsx)("div", { className: "bg-gray-300 rounded-full h-3 w-12 mb-2" }),
|
|
1036
|
+
/* @__PURE__ */ (0, import_jsx_runtime64.jsx)("div", { className: "bg-gray-300 rounded-full h-3 w-24 mb-2" }),
|
|
1037
|
+
/* @__PURE__ */ (0, import_jsx_runtime64.jsx)("div", { className: "bg-gray-300 rounded-full h-3 w-32 mb-2" }),
|
|
1038
|
+
/* @__PURE__ */ (0, import_jsx_runtime64.jsx)("div", { className: "bg-gray-300 rounded-full h-3 w-16 mb-2" }),
|
|
1039
|
+
/* @__PURE__ */ (0, import_jsx_runtime64.jsx)("div", { className: "bg-gray-300 rounded-full h-3 w-28 mb-2" })
|
|
1040
1040
|
] }),
|
|
1041
|
-
/* @__PURE__ */ (0,
|
|
1042
|
-
/* @__PURE__ */ (0,
|
|
1043
|
-
/* @__PURE__ */ (0,
|
|
1044
|
-
/* @__PURE__ */ (0,
|
|
1045
|
-
/* @__PURE__ */ (0,
|
|
1046
|
-
/* @__PURE__ */ (0,
|
|
1041
|
+
/* @__PURE__ */ (0, import_jsx_runtime64.jsxs)("div", { className: "animate-pulse", children: [
|
|
1042
|
+
/* @__PURE__ */ (0, import_jsx_runtime64.jsx)("div", { className: "bg-gray-300 rounded-full h-3 w-12 mb-2" }),
|
|
1043
|
+
/* @__PURE__ */ (0, import_jsx_runtime64.jsx)("div", { className: "bg-gray-300 rounded-full h-3 w-24 mb-2" }),
|
|
1044
|
+
/* @__PURE__ */ (0, import_jsx_runtime64.jsx)("div", { className: "bg-gray-300 rounded-full h-3 w-32 mb-2" }),
|
|
1045
|
+
/* @__PURE__ */ (0, import_jsx_runtime64.jsx)("div", { className: "bg-gray-300 rounded-full h-3 w-16 mb-2" }),
|
|
1046
|
+
/* @__PURE__ */ (0, import_jsx_runtime64.jsx)("div", { className: "bg-gray-300 rounded-full h-3 w-28 mb-2" })
|
|
1047
1047
|
] })
|
|
1048
1048
|
] })
|
|
1049
1049
|
] }) }),
|
|
@@ -1059,14 +1059,14 @@ var IframeClient_exports = {};
|
|
|
1059
1059
|
__export(IframeClient_exports, {
|
|
1060
1060
|
default: () => IframeClient_default
|
|
1061
1061
|
});
|
|
1062
|
-
var import_react49,
|
|
1062
|
+
var import_react49, import_jsx_runtime65, IframeClient, IframeClient_default;
|
|
1063
1063
|
var init_IframeClient = __esm({
|
|
1064
1064
|
"src/components/pageRenderingEngine/nodes/IframeClient.tsx"() {
|
|
1065
1065
|
"use strict";
|
|
1066
1066
|
"use client";
|
|
1067
1067
|
import_react49 = __toESM(require("react"));
|
|
1068
1068
|
init_IFrameLoaderView();
|
|
1069
|
-
|
|
1069
|
+
import_jsx_runtime65 = require("react/jsx-runtime");
|
|
1070
1070
|
IframeClient = ({ src }) => {
|
|
1071
1071
|
const iframeRef = (0, import_react49.useRef)(null);
|
|
1072
1072
|
const [iframeHeight, setIframeHeight] = (0, import_react49.useState)("100%");
|
|
@@ -1098,7 +1098,7 @@ var init_IframeClient = __esm({
|
|
|
1098
1098
|
const handleIframeLoad = () => {
|
|
1099
1099
|
setIsDataFound(true);
|
|
1100
1100
|
};
|
|
1101
|
-
return /* @__PURE__ */ (0,
|
|
1101
|
+
return /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(import_react49.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(IFrameLoaderView_default, { isDataFound, children: /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(
|
|
1102
1102
|
"iframe",
|
|
1103
1103
|
{
|
|
1104
1104
|
ref: iframeRef,
|
|
@@ -3573,8 +3573,51 @@ var DataList_default = DataList;
|
|
|
3573
3573
|
// src/components/dataForm/DataListRenderer.tsx
|
|
3574
3574
|
var import_react34 = __toESM(require("react"));
|
|
3575
3575
|
init_ServiceClient();
|
|
3576
|
+
var import_navigation3 = require("next/navigation");
|
|
3577
|
+
|
|
3578
|
+
// src/components/NavigationTabsV2.tsx
|
|
3579
|
+
var import_link2 = __toESM(require("next/link"));
|
|
3576
3580
|
var import_navigation2 = require("next/navigation");
|
|
3577
3581
|
var import_jsx_runtime41 = require("react/jsx-runtime");
|
|
3582
|
+
function resolveRoutePlaceholders(route, params) {
|
|
3583
|
+
return route.replace(/\{([^}]+)\}/g, (match, key) => {
|
|
3584
|
+
const value = params[key];
|
|
3585
|
+
if (value === void 0 || value === null) {
|
|
3586
|
+
console.warn(`No value found for route param: ${key}`);
|
|
3587
|
+
return "";
|
|
3588
|
+
}
|
|
3589
|
+
return value;
|
|
3590
|
+
});
|
|
3591
|
+
}
|
|
3592
|
+
var NavigationTabsV2 = ({ tabs, params = {} }) => {
|
|
3593
|
+
const pathname = (0, import_navigation2.usePathname)();
|
|
3594
|
+
const shouldHideTabs = pathname?.includes("/add");
|
|
3595
|
+
if (shouldHideTabs) return null;
|
|
3596
|
+
const mappedTabs = tabs?.sort((a, b) => a.displayOrder - b.displayOrder)?.map((tab) => ({
|
|
3597
|
+
tabTitle: tab.tabTitle,
|
|
3598
|
+
displayOrder: tab.displayOrder,
|
|
3599
|
+
landingPageUrl: resolveRoutePlaceholders(
|
|
3600
|
+
tab.landingPageUrl,
|
|
3601
|
+
params
|
|
3602
|
+
),
|
|
3603
|
+
isActive: tab.isActive
|
|
3604
|
+
})) || [];
|
|
3605
|
+
if (mappedTabs.length === 0) return null;
|
|
3606
|
+
return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("div", { className: "flex border-b bg-white rounded-t mb-3", children: mappedTabs.map(({ tabTitle, landingPageUrl, isActive }) => {
|
|
3607
|
+
return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(import_link2.default, { href: landingPageUrl, className: "-mb-px", children: /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
3608
|
+
"div",
|
|
3609
|
+
{
|
|
3610
|
+
className: `text-sm font-medium border-b-2 px-6 py-2 transition
|
|
3611
|
+
${isActive ? "bg-info-base" : "bg-neutral-weak "}`,
|
|
3612
|
+
children: tabTitle
|
|
3613
|
+
}
|
|
3614
|
+
) }, landingPageUrl);
|
|
3615
|
+
}) });
|
|
3616
|
+
};
|
|
3617
|
+
var NavigationTabsV2_default = NavigationTabsV2;
|
|
3618
|
+
|
|
3619
|
+
// src/components/dataForm/DataListRenderer.tsx
|
|
3620
|
+
var import_jsx_runtime42 = require("react/jsx-runtime");
|
|
3578
3621
|
var viewControlMap = {
|
|
3579
3622
|
number: ViewControlTypes.number,
|
|
3580
3623
|
lineText: ViewControlTypes.lineText,
|
|
@@ -3582,7 +3625,7 @@ var viewControlMap = {
|
|
|
3582
3625
|
date: ViewControlTypes.date,
|
|
3583
3626
|
boolean: ViewControlTypes.boolean
|
|
3584
3627
|
};
|
|
3585
|
-
function
|
|
3628
|
+
function resolveRoutePlaceholders2(route, params) {
|
|
3586
3629
|
return route.replace(/\{([^}]+)\}/g, (match, key) => {
|
|
3587
3630
|
const value = params[key];
|
|
3588
3631
|
if (value === void 0 || value === null) {
|
|
@@ -3622,6 +3665,7 @@ var DataListRenderer = ({
|
|
|
3622
3665
|
apiBaseUrl,
|
|
3623
3666
|
session,
|
|
3624
3667
|
params,
|
|
3668
|
+
tabs,
|
|
3625
3669
|
query,
|
|
3626
3670
|
path,
|
|
3627
3671
|
widgetProps
|
|
@@ -3633,14 +3677,14 @@ var DataListRenderer = ({
|
|
|
3633
3677
|
const [addLinkHref, setAddLinkHref] = (0, import_react34.useState)("");
|
|
3634
3678
|
const [addLinkText, setAddLinkText] = (0, import_react34.useState)("");
|
|
3635
3679
|
const [serviceRoute, setServiceRoute] = (0, import_react34.useState)("");
|
|
3636
|
-
const pathname = (0,
|
|
3680
|
+
const pathname = (0, import_navigation3.usePathname)();
|
|
3637
3681
|
(0, import_react34.useEffect)(() => {
|
|
3638
3682
|
if (!formDefinition) return;
|
|
3639
3683
|
setColumns(mapApiToColumns(formDefinition));
|
|
3640
3684
|
setFilters(mapApiToFilters(formDefinition));
|
|
3641
3685
|
setServiceRoute(formDefinition?.siteFormDataList?.serviceRoute ?? "/");
|
|
3642
3686
|
const rawAddLinkHref = formDefinition?.siteFormDataList?.addLinkHref ?? "";
|
|
3643
|
-
const resolvedAddLinkHref =
|
|
3687
|
+
const resolvedAddLinkHref = resolveRoutePlaceholders2(
|
|
3644
3688
|
rawAddLinkHref,
|
|
3645
3689
|
params
|
|
3646
3690
|
);
|
|
@@ -3650,7 +3694,7 @@ var DataListRenderer = ({
|
|
|
3650
3694
|
(0, import_react34.useEffect)(() => {
|
|
3651
3695
|
const fetchData = async () => {
|
|
3652
3696
|
if (!serviceRoute) return;
|
|
3653
|
-
const resolvedRoute =
|
|
3697
|
+
const resolvedRoute = resolveRoutePlaceholders2(serviceRoute, params);
|
|
3654
3698
|
const queryString = OdataBuilder.getOdataQueryString(query);
|
|
3655
3699
|
const separator = resolvedRoute.includes("?") ? "&" : "?";
|
|
3656
3700
|
const finalUrl = resolvedRoute + (queryString ? separator + queryString : "");
|
|
@@ -3661,21 +3705,24 @@ var DataListRenderer = ({
|
|
|
3661
3705
|
}, [serviceRoute, query, params]);
|
|
3662
3706
|
const [tabItem, setTabItem] = (0, import_react34.useState)();
|
|
3663
3707
|
const activeTab = tabItem?.find((tab) => tab.isActive);
|
|
3664
|
-
const activeHref = activeTab ?
|
|
3665
|
-
return /* @__PURE__ */ (0,
|
|
3666
|
-
|
|
3667
|
-
|
|
3668
|
-
|
|
3669
|
-
|
|
3670
|
-
|
|
3671
|
-
|
|
3672
|
-
|
|
3673
|
-
|
|
3674
|
-
|
|
3675
|
-
|
|
3676
|
-
|
|
3677
|
-
|
|
3678
|
-
|
|
3708
|
+
const activeHref = activeTab ? resolveRoutePlaceholders2(activeTab.landingPageUrl, params) : pathname;
|
|
3709
|
+
return /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(import_react34.default.Fragment, { children: [
|
|
3710
|
+
widgetProps && /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(NavigationTabsV2_default, { tabs, params: widgetProps.params }),
|
|
3711
|
+
/* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
|
|
3712
|
+
DataList_default,
|
|
3713
|
+
{
|
|
3714
|
+
addLinkHref,
|
|
3715
|
+
addLinkText,
|
|
3716
|
+
title: (formDefinition?.formTitle || "") + "-V2",
|
|
3717
|
+
path,
|
|
3718
|
+
columns,
|
|
3719
|
+
dataset,
|
|
3720
|
+
filters: filter,
|
|
3721
|
+
serviceClient,
|
|
3722
|
+
query
|
|
3723
|
+
}
|
|
3724
|
+
)
|
|
3725
|
+
] });
|
|
3679
3726
|
};
|
|
3680
3727
|
var DataListRenderer_default = DataListRenderer;
|
|
3681
3728
|
|
|
@@ -3686,7 +3733,7 @@ var import_react53 = __toESM(require("react"));
|
|
|
3686
3733
|
var import_react39 = __toESM(require("react"));
|
|
3687
3734
|
|
|
3688
3735
|
// src/components/pageRenderingEngine/nodes/TextNode.tsx
|
|
3689
|
-
var
|
|
3736
|
+
var import_jsx_runtime43 = require("react/jsx-runtime");
|
|
3690
3737
|
var TextNode = (props) => {
|
|
3691
3738
|
function cssStringToJson(cssString) {
|
|
3692
3739
|
const styleObject = {};
|
|
@@ -3744,24 +3791,24 @@ var TextNode = (props) => {
|
|
|
3744
3791
|
});
|
|
3745
3792
|
}
|
|
3746
3793
|
function renderWithLineBreaks(text) {
|
|
3747
|
-
return text.split("\n").map((line, index, arr) => /* @__PURE__ */ (0,
|
|
3794
|
+
return text.split("\n").map((line, index, arr) => /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)("span", { children: [
|
|
3748
3795
|
line,
|
|
3749
|
-
index < arr.length - 1 && /* @__PURE__ */ (0,
|
|
3796
|
+
index < arr.length - 1 && /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("br", {})
|
|
3750
3797
|
] }, index));
|
|
3751
3798
|
}
|
|
3752
3799
|
const displayText = props.linkText ? props.linkText : props.node.text;
|
|
3753
3800
|
const finalText = props.dataitem && props.linkText ? displayText : props.dataitem ? replacePlaceholders(props.node.text, props.dataitem) : props.node.text;
|
|
3754
3801
|
return (
|
|
3755
3802
|
// @ts-expect-error custom code
|
|
3756
|
-
/* @__PURE__ */ (0,
|
|
3803
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)("span", { style: { ...styles }, className: getFormatClass(props.node.format), children: typeof finalText === "string" ? renderWithLineBreaks(finalText) : finalText })
|
|
3757
3804
|
);
|
|
3758
3805
|
};
|
|
3759
3806
|
var TextNode_default = TextNode;
|
|
3760
3807
|
|
|
3761
3808
|
// src/components/pageRenderingEngine/nodes/LineBreakNode.tsx
|
|
3762
|
-
var
|
|
3809
|
+
var import_jsx_runtime44 = require("react/jsx-runtime");
|
|
3763
3810
|
var LineBreakNode = () => {
|
|
3764
|
-
return /* @__PURE__ */ (0,
|
|
3811
|
+
return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("div", { className: "py-0.5 lg:py-1.5" });
|
|
3765
3812
|
};
|
|
3766
3813
|
var LineBreakNode_default = LineBreakNode;
|
|
3767
3814
|
|
|
@@ -3797,7 +3844,7 @@ var import_dynamic = __toESM(require("next/dynamic"));
|
|
|
3797
3844
|
|
|
3798
3845
|
// src/components/DeviceAssetSelector.tsx
|
|
3799
3846
|
init_HlsPlayer();
|
|
3800
|
-
var
|
|
3847
|
+
var import_jsx_runtime46 = require("react/jsx-runtime");
|
|
3801
3848
|
var DeviceAssetSelector = ({
|
|
3802
3849
|
assets,
|
|
3803
3850
|
assetBaseUrl,
|
|
@@ -3872,7 +3919,7 @@ var DeviceAssetSelector = ({
|
|
|
3872
3919
|
const formatClasses = FormatClass[nodeProps?.format || ""] || "";
|
|
3873
3920
|
const renderMedia = () => {
|
|
3874
3921
|
if (isHls) {
|
|
3875
|
-
return /* @__PURE__ */ (0,
|
|
3922
|
+
return /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(
|
|
3876
3923
|
HlsPlayer_default,
|
|
3877
3924
|
{
|
|
3878
3925
|
assetUrl: resolvedAssetUrl,
|
|
@@ -3889,7 +3936,7 @@ var DeviceAssetSelector = ({
|
|
|
3889
3936
|
} else {
|
|
3890
3937
|
return (
|
|
3891
3938
|
/* eslint-disable-next-line @next/next/no-img-element */
|
|
3892
|
-
/* @__PURE__ */ (0,
|
|
3939
|
+
/* @__PURE__ */ (0, import_jsx_runtime46.jsx)(
|
|
3893
3940
|
"img",
|
|
3894
3941
|
{
|
|
3895
3942
|
style: styles,
|
|
@@ -3905,17 +3952,17 @@ var DeviceAssetSelector = ({
|
|
|
3905
3952
|
}
|
|
3906
3953
|
};
|
|
3907
3954
|
if (width) {
|
|
3908
|
-
return /* @__PURE__ */ (0,
|
|
3955
|
+
return /* @__PURE__ */ (0, import_jsx_runtime46.jsx)("div", { style: { width }, children: renderMedia() });
|
|
3909
3956
|
}
|
|
3910
3957
|
if (nodeProps?.format) {
|
|
3911
|
-
return /* @__PURE__ */ (0,
|
|
3958
|
+
return /* @__PURE__ */ (0, import_jsx_runtime46.jsx)("div", { className: `flex ${formatClasses}`, children: renderMedia() });
|
|
3912
3959
|
}
|
|
3913
3960
|
return renderMedia();
|
|
3914
3961
|
};
|
|
3915
3962
|
var DeviceAssetSelector_default = DeviceAssetSelector;
|
|
3916
3963
|
|
|
3917
3964
|
// src/components/pageRenderingEngine/nodes/ImageNode.tsx
|
|
3918
|
-
var
|
|
3965
|
+
var import_jsx_runtime47 = require("react/jsx-runtime");
|
|
3919
3966
|
var HlsPlayer2 = (0, import_dynamic.default)(() => Promise.resolve().then(() => (init_HlsPlayer(), HlsPlayer_exports)), {
|
|
3920
3967
|
ssr: false
|
|
3921
3968
|
});
|
|
@@ -3958,7 +4005,7 @@ var ImageNode = (props) => {
|
|
|
3958
4005
|
console.error("Error parsing assets in ImageNode:", error);
|
|
3959
4006
|
}
|
|
3960
4007
|
if (assets && assets.length > 0) {
|
|
3961
|
-
return /* @__PURE__ */ (0,
|
|
4008
|
+
return /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(import_jsx_runtime47.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
|
|
3962
4009
|
DeviceAssetSelector_default,
|
|
3963
4010
|
{
|
|
3964
4011
|
device: props.device,
|
|
@@ -4007,7 +4054,7 @@ var ImageNode = (props) => {
|
|
|
4007
4054
|
const isHls = imageUrl?.endsWith(".m3u8");
|
|
4008
4055
|
const renderMedia = () => {
|
|
4009
4056
|
if (isHls) {
|
|
4010
|
-
return /* @__PURE__ */ (0,
|
|
4057
|
+
return /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
|
|
4011
4058
|
HlsPlayer2,
|
|
4012
4059
|
{
|
|
4013
4060
|
assetUrl: imageUrl,
|
|
@@ -4022,7 +4069,7 @@ var ImageNode = (props) => {
|
|
|
4022
4069
|
}
|
|
4023
4070
|
);
|
|
4024
4071
|
} else {
|
|
4025
|
-
return /* @__PURE__ */ (0,
|
|
4072
|
+
return /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(import_react36.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
|
|
4026
4073
|
"img",
|
|
4027
4074
|
{
|
|
4028
4075
|
style: styles,
|
|
@@ -4037,7 +4084,7 @@ var ImageNode = (props) => {
|
|
|
4037
4084
|
}
|
|
4038
4085
|
};
|
|
4039
4086
|
if (props.node.width) {
|
|
4040
|
-
return /* @__PURE__ */ (0,
|
|
4087
|
+
return /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("div", { className: `flex ${formatClasses}`, children: renderMedia() });
|
|
4041
4088
|
}
|
|
4042
4089
|
return renderMedia();
|
|
4043
4090
|
};
|
|
@@ -4046,7 +4093,7 @@ var ImageNode_default = ImageNode;
|
|
|
4046
4093
|
// src/components/pageRenderingEngine/nodes/LinkNode.tsx
|
|
4047
4094
|
init_StyleTypes();
|
|
4048
4095
|
var import_dynamic2 = __toESM(require("next/dynamic"));
|
|
4049
|
-
var
|
|
4096
|
+
var import_jsx_runtime49 = require("react/jsx-runtime");
|
|
4050
4097
|
var LinkNodeButton2 = (0, import_dynamic2.default)(() => Promise.resolve().then(() => (init_LinkNodeButton(), LinkNodeButton_exports)), {
|
|
4051
4098
|
ssr: false
|
|
4052
4099
|
});
|
|
@@ -4093,13 +4140,13 @@ var LinkNode = (props) => {
|
|
|
4093
4140
|
const isButton = node.isButton === true;
|
|
4094
4141
|
const renderChildren = () => {
|
|
4095
4142
|
if (!node.children || node.children.length === 0) return null;
|
|
4096
|
-
return /* @__PURE__ */ (0,
|
|
4143
|
+
return /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(import_jsx_runtime49.Fragment, { children: node.children.map((childNode, index) => {
|
|
4097
4144
|
const SelectedNode = NodeTypes2[childNode.type];
|
|
4098
4145
|
if (!SelectedNode) {
|
|
4099
4146
|
console.warn("Unknown node type:", childNode.type);
|
|
4100
4147
|
return null;
|
|
4101
4148
|
}
|
|
4102
|
-
return /* @__PURE__ */ (0,
|
|
4149
|
+
return /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(import_react38.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
|
|
4103
4150
|
SelectedNode,
|
|
4104
4151
|
{
|
|
4105
4152
|
node: childNode,
|
|
@@ -4112,15 +4159,15 @@ var LinkNode = (props) => {
|
|
|
4112
4159
|
};
|
|
4113
4160
|
const renderFallback = () => {
|
|
4114
4161
|
if ((!node.children || node.children.length === 0) && linkText) {
|
|
4115
|
-
return /* @__PURE__ */ (0,
|
|
4162
|
+
return /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("span", { children: linkText });
|
|
4116
4163
|
}
|
|
4117
4164
|
if ((!node.children || node.children.length === 0) && !linkText) {
|
|
4118
|
-
return /* @__PURE__ */ (0,
|
|
4165
|
+
return /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("br", {});
|
|
4119
4166
|
}
|
|
4120
4167
|
return null;
|
|
4121
4168
|
};
|
|
4122
4169
|
if (isButton) {
|
|
4123
|
-
return /* @__PURE__ */ (0,
|
|
4170
|
+
return /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)(
|
|
4124
4171
|
LinkNodeButton2,
|
|
4125
4172
|
{
|
|
4126
4173
|
node,
|
|
@@ -4138,7 +4185,7 @@ var LinkNode = (props) => {
|
|
|
4138
4185
|
}
|
|
4139
4186
|
);
|
|
4140
4187
|
}
|
|
4141
|
-
return /* @__PURE__ */ (0,
|
|
4188
|
+
return /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)(
|
|
4142
4189
|
Hyperlink,
|
|
4143
4190
|
{
|
|
4144
4191
|
href: linkUrl || "#",
|
|
@@ -4154,10 +4201,10 @@ var LinkNode = (props) => {
|
|
|
4154
4201
|
var LinkNode_default = LinkNode;
|
|
4155
4202
|
|
|
4156
4203
|
// src/components/pageRenderingEngine/nodes/SVGIconNode.tsx
|
|
4157
|
-
var
|
|
4204
|
+
var import_jsx_runtime50 = require("react/jsx-runtime");
|
|
4158
4205
|
var SVGIconNode = ({ node }) => {
|
|
4159
4206
|
if (!node?.svgCode) return null;
|
|
4160
|
-
return /* @__PURE__ */ (0,
|
|
4207
|
+
return /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
|
|
4161
4208
|
"span",
|
|
4162
4209
|
{
|
|
4163
4210
|
style: {
|
|
@@ -4174,7 +4221,7 @@ var SVGIconNode_default = SVGIconNode;
|
|
|
4174
4221
|
|
|
4175
4222
|
// src/components/pageRenderingEngine/nodes/EquationNode.tsx
|
|
4176
4223
|
var import_katex = __toESM(require("katex"));
|
|
4177
|
-
var
|
|
4224
|
+
var import_jsx_runtime51 = require("react/jsx-runtime");
|
|
4178
4225
|
var EquationNode = ({ node }) => {
|
|
4179
4226
|
const { equation, inline } = node;
|
|
4180
4227
|
let html = "";
|
|
@@ -4189,7 +4236,7 @@ var EquationNode = ({ node }) => {
|
|
|
4189
4236
|
});
|
|
4190
4237
|
}
|
|
4191
4238
|
if (inline) {
|
|
4192
|
-
return /* @__PURE__ */ (0,
|
|
4239
|
+
return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
|
|
4193
4240
|
"span",
|
|
4194
4241
|
{
|
|
4195
4242
|
className: "katex-inline",
|
|
@@ -4197,7 +4244,7 @@ var EquationNode = ({ node }) => {
|
|
|
4197
4244
|
}
|
|
4198
4245
|
);
|
|
4199
4246
|
}
|
|
4200
|
-
return /* @__PURE__ */ (0,
|
|
4247
|
+
return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
|
|
4201
4248
|
"div",
|
|
4202
4249
|
{
|
|
4203
4250
|
className: "katex-block my-3 text-center",
|
|
@@ -4208,7 +4255,7 @@ var EquationNode = ({ node }) => {
|
|
|
4208
4255
|
var EquationNode_default = EquationNode;
|
|
4209
4256
|
|
|
4210
4257
|
// src/components/pageRenderingEngine/nodes/DatafieldNode.tsx
|
|
4211
|
-
var
|
|
4258
|
+
var import_jsx_runtime52 = require("react/jsx-runtime");
|
|
4212
4259
|
function getNestedProperty(obj, path) {
|
|
4213
4260
|
if (!obj || !path) return null;
|
|
4214
4261
|
if (path.includes(".")) {
|
|
@@ -4221,7 +4268,7 @@ function getNestedProperty(obj, path) {
|
|
|
4221
4268
|
}
|
|
4222
4269
|
const value = obj[path];
|
|
4223
4270
|
if (Array.isArray(value)) {
|
|
4224
|
-
return value.map((item, index) => /* @__PURE__ */ (0,
|
|
4271
|
+
return value.map((item, index) => /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("div", { children: String(item) }, index));
|
|
4225
4272
|
}
|
|
4226
4273
|
return value;
|
|
4227
4274
|
}
|
|
@@ -4282,7 +4329,7 @@ var DatafieldNode = (props) => {
|
|
|
4282
4329
|
const dataType = props.node.dataType;
|
|
4283
4330
|
if (isEmptyValue) return null;
|
|
4284
4331
|
if (dataType === "rawContent") {
|
|
4285
|
-
return /* @__PURE__ */ (0,
|
|
4332
|
+
return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
|
|
4286
4333
|
PageBodyRenderer_default,
|
|
4287
4334
|
{
|
|
4288
4335
|
rawBody: String(value ?? `@databound[${fieldName}]`),
|
|
@@ -4298,12 +4345,12 @@ var DatafieldNode = (props) => {
|
|
|
4298
4345
|
}
|
|
4299
4346
|
);
|
|
4300
4347
|
}
|
|
4301
|
-
return /* @__PURE__ */ (0,
|
|
4348
|
+
return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
|
|
4302
4349
|
"span",
|
|
4303
4350
|
{
|
|
4304
4351
|
className: `datafield-node ${props.node.format < Formats.length ? Formats[props.node.format] : ""}`,
|
|
4305
4352
|
style: styles,
|
|
4306
|
-
children: /* @__PURE__ */ (0,
|
|
4353
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
|
|
4307
4354
|
ViewControl_default,
|
|
4308
4355
|
{
|
|
4309
4356
|
controlType: dataType,
|
|
@@ -4316,7 +4363,7 @@ var DatafieldNode = (props) => {
|
|
|
4316
4363
|
var DatafieldNode_default = DatafieldNode;
|
|
4317
4364
|
|
|
4318
4365
|
// src/components/pageRenderingEngine/nodes/ParagraphNode.tsx
|
|
4319
|
-
var
|
|
4366
|
+
var import_jsx_runtime53 = require("react/jsx-runtime");
|
|
4320
4367
|
var ParagraphNode = (props) => {
|
|
4321
4368
|
const NodeTypes2 = {
|
|
4322
4369
|
["text"]: TextNode_default,
|
|
@@ -4336,9 +4383,9 @@ var ParagraphNode = (props) => {
|
|
|
4336
4383
|
const isInlineOnlyParent = props.parentTag === "summary";
|
|
4337
4384
|
const hasChildren = props.node.children && props.node.children.length > 0;
|
|
4338
4385
|
if (isInlineOnlyParent) {
|
|
4339
|
-
return /* @__PURE__ */ (0,
|
|
4386
|
+
return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(import_jsx_runtime53.Fragment, { children: hasChildren && props.node.children.map((node, index) => {
|
|
4340
4387
|
const SelectedNode = NodeTypes2[node.type];
|
|
4341
|
-
return /* @__PURE__ */ (0,
|
|
4388
|
+
return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(import_react39.default.Fragment, { children: SelectedNode && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
|
|
4342
4389
|
SelectedNode,
|
|
4343
4390
|
{
|
|
4344
4391
|
node,
|
|
@@ -4350,10 +4397,10 @@ var ParagraphNode = (props) => {
|
|
|
4350
4397
|
) }, index);
|
|
4351
4398
|
}) });
|
|
4352
4399
|
}
|
|
4353
|
-
return /* @__PURE__ */ (0,
|
|
4400
|
+
return /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("div", { className: " " + formatClasses, children: [
|
|
4354
4401
|
hasChildren && props.node.children.map((node, index) => {
|
|
4355
4402
|
const SelectedNode = NodeTypes2[node.type];
|
|
4356
|
-
return /* @__PURE__ */ (0,
|
|
4403
|
+
return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(import_react39.default.Fragment, { children: SelectedNode && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
|
|
4357
4404
|
SelectedNode,
|
|
4358
4405
|
{
|
|
4359
4406
|
node,
|
|
@@ -4364,14 +4411,14 @@ var ParagraphNode = (props) => {
|
|
|
4364
4411
|
}
|
|
4365
4412
|
) }, index);
|
|
4366
4413
|
}),
|
|
4367
|
-
!hasChildren && /* @__PURE__ */ (0,
|
|
4414
|
+
!hasChildren && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("div", { className: "py-1.5 lg:py-2" })
|
|
4368
4415
|
] });
|
|
4369
4416
|
};
|
|
4370
4417
|
var ParagraphNode_default = ParagraphNode;
|
|
4371
4418
|
|
|
4372
4419
|
// src/components/pageRenderingEngine/nodes/HeadingNode.tsx
|
|
4373
4420
|
var import_react40 = __toESM(require("react"));
|
|
4374
|
-
var
|
|
4421
|
+
var import_jsx_runtime54 = require("react/jsx-runtime");
|
|
4375
4422
|
var HeadingNode = (props) => {
|
|
4376
4423
|
const NodeTypes2 = {
|
|
4377
4424
|
["text"]: TextNode_default,
|
|
@@ -4387,12 +4434,12 @@ var HeadingNode = (props) => {
|
|
|
4387
4434
|
{
|
|
4388
4435
|
}
|
|
4389
4436
|
const formatClasses = FormatClass[props.node.format] || "";
|
|
4390
|
-
return /* @__PURE__ */ (0,
|
|
4437
|
+
return /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_jsx_runtime54.Fragment, { children: import_react40.default.createElement(
|
|
4391
4438
|
HeadingTag,
|
|
4392
4439
|
{ className: formatClasses },
|
|
4393
4440
|
props.node.children && props.node.children.map((childNode, index) => {
|
|
4394
4441
|
const SelectedNode = NodeTypes2[childNode.type];
|
|
4395
|
-
return /* @__PURE__ */ (0,
|
|
4442
|
+
return /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_react40.default.Fragment, { children: SelectedNode && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(SelectedNode, { node: childNode, dataitem: props.dataitem, session: props.session, apiBaseUrl: props.apiBaseUrl, routeParameters: props.routeParameters }) }, index);
|
|
4396
4443
|
})
|
|
4397
4444
|
) });
|
|
4398
4445
|
};
|
|
@@ -4403,7 +4450,7 @@ var import_react42 = __toESM(require("react"));
|
|
|
4403
4450
|
|
|
4404
4451
|
// src/components/pageRenderingEngine/nodes/ListItemNode.tsx
|
|
4405
4452
|
var import_react41 = __toESM(require("react"));
|
|
4406
|
-
var
|
|
4453
|
+
var import_jsx_runtime55 = require("react/jsx-runtime");
|
|
4407
4454
|
var ListItemNode = (props) => {
|
|
4408
4455
|
const NodeTypes2 = {
|
|
4409
4456
|
text: TextNode_default,
|
|
@@ -4420,37 +4467,37 @@ var ListItemNode = (props) => {
|
|
|
4420
4467
|
liStyle.fontSize = match[1].trim();
|
|
4421
4468
|
}
|
|
4422
4469
|
}
|
|
4423
|
-
return /* @__PURE__ */ (0,
|
|
4470
|
+
return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("li", { style: liStyle, children: props.node.children && props.node.children.map((node, index) => {
|
|
4424
4471
|
const SelectedNode = NodeTypes2[node.type];
|
|
4425
4472
|
if (node.type === "linebreak") {
|
|
4426
4473
|
if (!foundFirstBreak) {
|
|
4427
4474
|
foundFirstBreak = true;
|
|
4428
|
-
return /* @__PURE__ */ (0,
|
|
4475
|
+
return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("div", {}, index);
|
|
4429
4476
|
} else {
|
|
4430
|
-
return /* @__PURE__ */ (0,
|
|
4477
|
+
return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("div", { className: "py-1 lg:py-2" }, index);
|
|
4431
4478
|
}
|
|
4432
4479
|
} else {
|
|
4433
4480
|
foundFirstBreak = false;
|
|
4434
|
-
return /* @__PURE__ */ (0,
|
|
4481
|
+
return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(import_react41.default.Fragment, { children: SelectedNode && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(SelectedNode, { node, dataitem: props.dataitem, routeParameters: props.routeParameters }) }, index);
|
|
4435
4482
|
}
|
|
4436
4483
|
}) });
|
|
4437
4484
|
};
|
|
4438
4485
|
var ListItemNode_default = ListItemNode;
|
|
4439
4486
|
|
|
4440
4487
|
// src/components/pageRenderingEngine/nodes/ListNode.tsx
|
|
4441
|
-
var
|
|
4488
|
+
var import_jsx_runtime56 = require("react/jsx-runtime");
|
|
4442
4489
|
var ListNode = (props) => {
|
|
4443
4490
|
const NodeTypes2 = {
|
|
4444
4491
|
listitem: ListItemNode_default
|
|
4445
4492
|
};
|
|
4446
|
-
return /* @__PURE__ */ (0,
|
|
4447
|
-
props.node.listType == "bullet" && /* @__PURE__ */ (0,
|
|
4493
|
+
return /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(import_react42.default.Fragment, { children: [
|
|
4494
|
+
props.node.listType == "bullet" && /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("ul", { children: props.node.children && props.node.children.map((node, index) => {
|
|
4448
4495
|
const SelectedNode = NodeTypes2[node.type];
|
|
4449
|
-
return /* @__PURE__ */ (0,
|
|
4496
|
+
return /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(import_react42.default.Fragment, { children: SelectedNode && /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(SelectedNode, { node, dataitem: props.dataitem, routeParameters: props.routeParameters }) }, index);
|
|
4450
4497
|
}) }),
|
|
4451
|
-
props.node.listType == "number" && /* @__PURE__ */ (0,
|
|
4498
|
+
props.node.listType == "number" && /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("ol", { children: props.node.children && props.node.children.map((node, index) => {
|
|
4452
4499
|
const SelectedNode = NodeTypes2[node.type];
|
|
4453
|
-
return /* @__PURE__ */ (0,
|
|
4500
|
+
return /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(import_react42.default.Fragment, { children: SelectedNode && /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(SelectedNode, { node, dataitem: props.dataitem, routeParameters: props.routeParameters }) }, index);
|
|
4454
4501
|
}) })
|
|
4455
4502
|
] });
|
|
4456
4503
|
};
|
|
@@ -4458,16 +4505,16 @@ var ListNode_default = ListNode;
|
|
|
4458
4505
|
|
|
4459
4506
|
// src/components/pageRenderingEngine/nodes/QuoteNode.tsx
|
|
4460
4507
|
var import_react43 = __toESM(require("react"));
|
|
4461
|
-
var
|
|
4508
|
+
var import_jsx_runtime57 = require("react/jsx-runtime");
|
|
4462
4509
|
var QuoteNode = (props) => {
|
|
4463
4510
|
const NodeTypes2 = {
|
|
4464
4511
|
["text"]: TextNode_default,
|
|
4465
4512
|
["linebreak"]: LineBreakNode_default,
|
|
4466
4513
|
["link"]: LinkNode_default
|
|
4467
4514
|
};
|
|
4468
|
-
return /* @__PURE__ */ (0,
|
|
4515
|
+
return /* @__PURE__ */ (0, import_jsx_runtime57.jsx)("blockquote", { children: props.node.children && props.node.children.map((node, index) => {
|
|
4469
4516
|
const SelectedNode = NodeTypes2[node.type];
|
|
4470
|
-
return /* @__PURE__ */ (0,
|
|
4517
|
+
return /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(import_react43.default.Fragment, { children: SelectedNode && /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(SelectedNode, { node, session: props.session, apiBaseUrl: props.apiBaseUrl, routeParameters: props.routeParameters }) }, index);
|
|
4471
4518
|
}) });
|
|
4472
4519
|
};
|
|
4473
4520
|
var QuoteNode_default = QuoteNode;
|
|
@@ -4475,11 +4522,11 @@ var QuoteNode_default = QuoteNode;
|
|
|
4475
4522
|
// src/components/pageRenderingEngine/nodes/CodeNode.tsx
|
|
4476
4523
|
var import_react45 = __toESM(require("react"));
|
|
4477
4524
|
var import_dynamic3 = __toESM(require("next/dynamic"));
|
|
4478
|
-
var
|
|
4525
|
+
var import_jsx_runtime59 = require("react/jsx-runtime");
|
|
4479
4526
|
var CopyButton2 = (0, import_dynamic3.default)(() => Promise.resolve().then(() => (init_CopyButton(), CopyButton_exports)), {
|
|
4480
4527
|
ssr: false,
|
|
4481
4528
|
// optional: fallback UI while loading
|
|
4482
|
-
loading: () => /* @__PURE__ */ (0,
|
|
4529
|
+
loading: () => /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("span", { className: "text-gray-400 text-xs", children: "Copy" })
|
|
4483
4530
|
});
|
|
4484
4531
|
var CodeNode = (props) => {
|
|
4485
4532
|
const NodeTypes2 = {
|
|
@@ -4493,14 +4540,14 @@ var CodeNode = (props) => {
|
|
|
4493
4540
|
if (node.type === "link") return node.text || node.url || "";
|
|
4494
4541
|
return "";
|
|
4495
4542
|
}).join("") ?? "";
|
|
4496
|
-
return /* @__PURE__ */ (0,
|
|
4497
|
-
/* @__PURE__ */ (0,
|
|
4498
|
-
/* @__PURE__ */ (0,
|
|
4499
|
-
/* @__PURE__ */ (0,
|
|
4543
|
+
return /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("div", { children: [
|
|
4544
|
+
/* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("div", { className: "flex items-center relative bg-neutral-strong px-4 py-3 text-xs font-sans justify-between rounded-t-md ", children: [
|
|
4545
|
+
/* @__PURE__ */ (0, import_jsx_runtime59.jsx)("span", { children: "Code Snippet" }),
|
|
4546
|
+
/* @__PURE__ */ (0, import_jsx_runtime59.jsx)(CopyButton2, { text: textContent })
|
|
4500
4547
|
] }),
|
|
4501
|
-
/* @__PURE__ */ (0,
|
|
4548
|
+
/* @__PURE__ */ (0, import_jsx_runtime59.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) => {
|
|
4502
4549
|
const SelectedNode = NodeTypes2[node.type];
|
|
4503
|
-
return /* @__PURE__ */ (0,
|
|
4550
|
+
return /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(import_react45.default.Fragment, { children: SelectedNode && /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
|
|
4504
4551
|
SelectedNode,
|
|
4505
4552
|
{
|
|
4506
4553
|
node,
|
|
@@ -4515,15 +4562,15 @@ var CodeNode = (props) => {
|
|
|
4515
4562
|
var CodeNode_default = CodeNode;
|
|
4516
4563
|
|
|
4517
4564
|
// src/components/pageRenderingEngine/nodes/HorizontalRuleNode.tsx
|
|
4518
|
-
var
|
|
4565
|
+
var import_jsx_runtime60 = require("react/jsx-runtime");
|
|
4519
4566
|
var HorizontalRuleNode = () => {
|
|
4520
|
-
return /* @__PURE__ */ (0,
|
|
4567
|
+
return /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("hr", {});
|
|
4521
4568
|
};
|
|
4522
4569
|
var HorizontalRuleNode_default = HorizontalRuleNode;
|
|
4523
4570
|
|
|
4524
4571
|
// src/components/pageRenderingEngine/nodes/WidgetNode.tsx
|
|
4525
4572
|
var import_react46 = __toESM(require("react"));
|
|
4526
|
-
var
|
|
4573
|
+
var import_jsx_runtime61 = require("react/jsx-runtime");
|
|
4527
4574
|
var WidgetNode = (props) => {
|
|
4528
4575
|
const getWidgetParameters = () => {
|
|
4529
4576
|
const widgetInputParameters = {
|
|
@@ -4580,7 +4627,7 @@ var WidgetNode = (props) => {
|
|
|
4580
4627
|
};
|
|
4581
4628
|
const widgetCode = props.node?.widgetCode;
|
|
4582
4629
|
if (!widgetCode) {
|
|
4583
|
-
return /* @__PURE__ */ (0,
|
|
4630
|
+
return /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(import_jsx_runtime61.Fragment, { children: "Invalid widget" });
|
|
4584
4631
|
}
|
|
4585
4632
|
const widgetParams = getWidgetParameters();
|
|
4586
4633
|
const WidgetRenderer = props.widgetRenderer;
|
|
@@ -4589,7 +4636,7 @@ var WidgetNode = (props) => {
|
|
|
4589
4636
|
}
|
|
4590
4637
|
return (
|
|
4591
4638
|
// eslint-disable-next-line react-hooks/static-components
|
|
4592
|
-
/* @__PURE__ */ (0,
|
|
4639
|
+
/* @__PURE__ */ (0, import_jsx_runtime61.jsx)(import_react46.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
|
|
4593
4640
|
WidgetRenderer,
|
|
4594
4641
|
{
|
|
4595
4642
|
params: widgetParams,
|
|
@@ -4609,9 +4656,9 @@ var WidgetNode_default = WidgetNode;
|
|
|
4609
4656
|
var import_react47 = __toESM(require("react"));
|
|
4610
4657
|
|
|
4611
4658
|
// src/components/pageRenderingEngine/nodes/InputControlNode.tsx
|
|
4612
|
-
var
|
|
4659
|
+
var import_jsx_runtime62 = require("react/jsx-runtime");
|
|
4613
4660
|
var InputControlNode = (props) => {
|
|
4614
|
-
return /* @__PURE__ */ (0,
|
|
4661
|
+
return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
|
|
4615
4662
|
InputControl_default,
|
|
4616
4663
|
{
|
|
4617
4664
|
name: props.node.name,
|
|
@@ -4641,7 +4688,7 @@ var InputControlNode_default = InputControlNode;
|
|
|
4641
4688
|
|
|
4642
4689
|
// src/components/pageRenderingEngine/nodes/FormContainerNode.tsx
|
|
4643
4690
|
init_ServiceClient();
|
|
4644
|
-
var
|
|
4691
|
+
var import_jsx_runtime63 = require("react/jsx-runtime");
|
|
4645
4692
|
var FormContainerNode = (props) => {
|
|
4646
4693
|
const NodeTypes2 = {
|
|
4647
4694
|
["input-control"]: InputControlNode_default
|
|
@@ -4671,12 +4718,12 @@ var FormContainerNode = (props) => {
|
|
|
4671
4718
|
};
|
|
4672
4719
|
fetchInitialData();
|
|
4673
4720
|
}, [props.apiBaseUrl, props.node, props.session, props.routeParameters]);
|
|
4674
|
-
return /* @__PURE__ */ (0,
|
|
4721
|
+
return /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)("form", { className: "group space-y-6 pb-6 overflow-y-auto", noValidate: true, ref: formRef, children: [
|
|
4675
4722
|
node.children && node.children.map((node2, index) => {
|
|
4676
4723
|
{
|
|
4677
4724
|
}
|
|
4678
4725
|
const SelectedNode = NodeTypes2[node2.type];
|
|
4679
|
-
return /* @__PURE__ */ (0,
|
|
4726
|
+
return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(import_react47.default.Fragment, { children: SelectedNode && node2.type == "input-control" && /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
|
|
4680
4727
|
InputControlNode_default,
|
|
4681
4728
|
{
|
|
4682
4729
|
value: formState.inputValues[node2.name],
|
|
@@ -4685,7 +4732,7 @@ var FormContainerNode = (props) => {
|
|
|
4685
4732
|
}
|
|
4686
4733
|
) }, index);
|
|
4687
4734
|
}),
|
|
4688
|
-
node.children.length == 0 && /* @__PURE__ */ (0,
|
|
4735
|
+
node.children.length == 0 && /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("div", { className: "py-0.5 lg:py-1.5" })
|
|
4689
4736
|
] });
|
|
4690
4737
|
};
|
|
4691
4738
|
var FormContainerNode_default = FormContainerNode;
|
|
@@ -4695,7 +4742,7 @@ var import_react52 = __toESM(require("react"));
|
|
|
4695
4742
|
|
|
4696
4743
|
// src/components/pageRenderingEngine/nodes/EmbedNode.tsx
|
|
4697
4744
|
var import_dynamic4 = __toESM(require("next/dynamic"));
|
|
4698
|
-
var
|
|
4745
|
+
var import_jsx_runtime66 = require("react/jsx-runtime");
|
|
4699
4746
|
var IframeClient2 = (0, import_dynamic4.default)(() => Promise.resolve().then(() => (init_IframeClient(), IframeClient_exports)), {
|
|
4700
4747
|
ssr: false
|
|
4701
4748
|
});
|
|
@@ -4708,7 +4755,7 @@ var EmbedNode = (props) => {
|
|
|
4708
4755
|
} else {
|
|
4709
4756
|
src = props.node.embedSrc;
|
|
4710
4757
|
}
|
|
4711
|
-
return /* @__PURE__ */ (0,
|
|
4758
|
+
return /* @__PURE__ */ (0, import_jsx_runtime66.jsx)("div", { className: "aspect-video", children: src && /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(IframeClient2, { src }) });
|
|
4712
4759
|
};
|
|
4713
4760
|
var EmbedNode_default = EmbedNode;
|
|
4714
4761
|
|
|
@@ -4717,7 +4764,7 @@ init_ServiceClient();
|
|
|
4717
4764
|
|
|
4718
4765
|
// src/components/Slider.tsx
|
|
4719
4766
|
var import_react50 = __toESM(require("react"));
|
|
4720
|
-
var
|
|
4767
|
+
var import_jsx_runtime67 = require("react/jsx-runtime");
|
|
4721
4768
|
var Slider = ({
|
|
4722
4769
|
children,
|
|
4723
4770
|
slidesToShow = 4,
|
|
@@ -4814,7 +4861,7 @@ var Slider = ({
|
|
|
4814
4861
|
if (!import_react50.default.isValidElement(child)) return null;
|
|
4815
4862
|
const childProps = child.props;
|
|
4816
4863
|
const mergedClassName = `${childProps.className ?? ""} w-full`.trim();
|
|
4817
|
-
return /* @__PURE__ */ (0,
|
|
4864
|
+
return /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
|
|
4818
4865
|
"div",
|
|
4819
4866
|
{
|
|
4820
4867
|
className: `flex-none ${scaleOnHover ? "group hover:z-50" : ""} relative`,
|
|
@@ -4837,14 +4884,14 @@ var Slider = ({
|
|
|
4837
4884
|
return "bottom-4";
|
|
4838
4885
|
}
|
|
4839
4886
|
};
|
|
4840
|
-
return /* @__PURE__ */ (0,
|
|
4887
|
+
return /* @__PURE__ */ (0, import_jsx_runtime67.jsxs)(
|
|
4841
4888
|
"div",
|
|
4842
4889
|
{
|
|
4843
4890
|
className: `relative w-full overflow-hidden ${className}`,
|
|
4844
4891
|
onMouseEnter: handleMouseEnter,
|
|
4845
4892
|
onMouseLeave: handleMouseLeave,
|
|
4846
4893
|
children: [
|
|
4847
|
-
/* @__PURE__ */ (0,
|
|
4894
|
+
/* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
|
|
4848
4895
|
"div",
|
|
4849
4896
|
{
|
|
4850
4897
|
className: "flex h-full",
|
|
@@ -4855,18 +4902,18 @@ var Slider = ({
|
|
|
4855
4902
|
children: slides
|
|
4856
4903
|
}
|
|
4857
4904
|
),
|
|
4858
|
-
show_arrows && /* @__PURE__ */ (0,
|
|
4859
|
-
/* @__PURE__ */ (0,
|
|
4905
|
+
show_arrows && /* @__PURE__ */ (0, import_jsx_runtime67.jsxs)(import_jsx_runtime67.Fragment, { children: [
|
|
4906
|
+
/* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
|
|
4860
4907
|
ArrowButton,
|
|
4861
4908
|
{
|
|
4862
4909
|
direction: "left",
|
|
4863
4910
|
onClick: prevSlide,
|
|
4864
4911
|
visible: infinite_scroll || currentSlide > 0,
|
|
4865
4912
|
className: arrowClassName,
|
|
4866
|
-
children: /* @__PURE__ */ (0,
|
|
4913
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime67.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", strokeWidth: 1.5, stroke: "currentColor", className: "w-6 h-6", children: /* @__PURE__ */ (0, import_jsx_runtime67.jsx)("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M15.75 19.5 8.25 12l7.5-7.5" }) })
|
|
4867
4914
|
}
|
|
4868
4915
|
),
|
|
4869
|
-
/* @__PURE__ */ (0,
|
|
4916
|
+
/* @__PURE__ */ (0, import_jsx_runtime67.jsxs)(
|
|
4870
4917
|
ArrowButton,
|
|
4871
4918
|
{
|
|
4872
4919
|
direction: "right",
|
|
@@ -4874,13 +4921,13 @@ var Slider = ({
|
|
|
4874
4921
|
visible: infinite_scroll || currentSlide < maxSlide,
|
|
4875
4922
|
className: arrowClassName,
|
|
4876
4923
|
children: [
|
|
4877
|
-
/* @__PURE__ */ (0,
|
|
4924
|
+
/* @__PURE__ */ (0, import_jsx_runtime67.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", strokeWidth: 1.5, stroke: "currentColor", className: "w-6 h-6", children: /* @__PURE__ */ (0, import_jsx_runtime67.jsx)("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "m8.25 4.5 7.5 7.5-7.5 7.5" }) }),
|
|
4878
4925
|
" "
|
|
4879
4926
|
]
|
|
4880
4927
|
}
|
|
4881
4928
|
)
|
|
4882
4929
|
] }),
|
|
4883
|
-
show_dots && /* @__PURE__ */ (0,
|
|
4930
|
+
show_dots && /* @__PURE__ */ (0, import_jsx_runtime67.jsx)("div", { className: `absolute left-1/2 -translate-x-1/2 flex justify-center space-x-1.5 ${getProgressPositionClass()}`, children: Array.from({ length: totalSlides }).map((_, index) => /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
|
|
4884
4931
|
ProgressPill,
|
|
4885
4932
|
{
|
|
4886
4933
|
active: index === currentSlide,
|
|
@@ -4906,7 +4953,7 @@ var ArrowButton = ({
|
|
|
4906
4953
|
visible,
|
|
4907
4954
|
children,
|
|
4908
4955
|
className = ""
|
|
4909
|
-
}) => /* @__PURE__ */ (0,
|
|
4956
|
+
}) => /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
|
|
4910
4957
|
"button",
|
|
4911
4958
|
{
|
|
4912
4959
|
className: `
|
|
@@ -4993,7 +5040,7 @@ var ProgressPill = ({
|
|
|
4993
5040
|
const renderProgressBar = () => {
|
|
4994
5041
|
if (style === "modern" && isActive || style === "cumulative" && shouldShowProgress) {
|
|
4995
5042
|
const displayProgress = style === "cumulative" && isFilled ? 100 : progress;
|
|
4996
|
-
return /* @__PURE__ */ (0,
|
|
5043
|
+
return /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
|
|
4997
5044
|
"div",
|
|
4998
5045
|
{
|
|
4999
5046
|
className: `absolute top-0 left-0 h-full rounded-full ${style === "cumulative" && isFilled ? activeClassName || "bg-white" : activeClassName || "bg-white"} transition-all duration-50 ease-linear`,
|
|
@@ -5005,7 +5052,7 @@ var ProgressPill = ({
|
|
|
5005
5052
|
};
|
|
5006
5053
|
const renderCumulativeFill = () => {
|
|
5007
5054
|
if (style === "cumulative" && isFilled && !isActive) {
|
|
5008
|
-
return /* @__PURE__ */ (0,
|
|
5055
|
+
return /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
|
|
5009
5056
|
"div",
|
|
5010
5057
|
{
|
|
5011
5058
|
className: `absolute top-0 left-0 h-full rounded-full ${activeClassName || "bg-white"} transition-all duration-300`,
|
|
@@ -5015,7 +5062,7 @@ var ProgressPill = ({
|
|
|
5015
5062
|
}
|
|
5016
5063
|
return null;
|
|
5017
5064
|
};
|
|
5018
|
-
return /* @__PURE__ */ (0,
|
|
5065
|
+
return /* @__PURE__ */ (0, import_jsx_runtime67.jsxs)(
|
|
5019
5066
|
"button",
|
|
5020
5067
|
{
|
|
5021
5068
|
className: `${baseClasses} ${getStyleClasses()}`,
|
|
@@ -5191,10 +5238,10 @@ var PathUtility = class {
|
|
|
5191
5238
|
var PathUtility_default = new PathUtility();
|
|
5192
5239
|
|
|
5193
5240
|
// src/components/NoDataFound.tsx
|
|
5194
|
-
var
|
|
5241
|
+
var import_jsx_runtime68 = require("react/jsx-runtime");
|
|
5195
5242
|
var NoDataFound = () => {
|
|
5196
|
-
return /* @__PURE__ */ (0,
|
|
5197
|
-
/* @__PURE__ */ (0,
|
|
5243
|
+
return /* @__PURE__ */ (0, import_jsx_runtime68.jsxs)("div", { className: "flex flex-col items-center justify-center py-12 px-4 text-center bg-neutral-weak", children: [
|
|
5244
|
+
/* @__PURE__ */ (0, import_jsx_runtime68.jsx)("div", { className: "mb-5", children: /* @__PURE__ */ (0, import_jsx_runtime68.jsx)("div", { className: "mx-auto w-20 h-20 rounded-full flex items-center justify-center bg-neutral-soft", children: /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
|
|
5198
5245
|
"svg",
|
|
5199
5246
|
{
|
|
5200
5247
|
className: "w-10 h-10",
|
|
@@ -5202,7 +5249,7 @@ var NoDataFound = () => {
|
|
|
5202
5249
|
stroke: "currentColor",
|
|
5203
5250
|
viewBox: "0 0 24 24",
|
|
5204
5251
|
xmlns: "http://www.w3.org/2000/svg",
|
|
5205
|
-
children: /* @__PURE__ */ (0,
|
|
5252
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
|
|
5206
5253
|
"path",
|
|
5207
5254
|
{
|
|
5208
5255
|
strokeLinecap: "round",
|
|
@@ -5213,8 +5260,8 @@ var NoDataFound = () => {
|
|
|
5213
5260
|
)
|
|
5214
5261
|
}
|
|
5215
5262
|
) }) }),
|
|
5216
|
-
/* @__PURE__ */ (0,
|
|
5217
|
-
/* @__PURE__ */ (0,
|
|
5263
|
+
/* @__PURE__ */ (0, import_jsx_runtime68.jsx)("h3", { className: "text-lg font-medium mb-2", children: "No data available" }),
|
|
5264
|
+
/* @__PURE__ */ (0, import_jsx_runtime68.jsx)("p", { className: " max-w-sm mb-0", children: "No records found. Data may be empty or not available at the moment." })
|
|
5218
5265
|
] });
|
|
5219
5266
|
};
|
|
5220
5267
|
var NoDataFound_default = NoDataFound;
|
|
@@ -5222,7 +5269,7 @@ var NoDataFound_default = NoDataFound;
|
|
|
5222
5269
|
// src/components/Pagination.tsx
|
|
5223
5270
|
var import_react51 = require("react");
|
|
5224
5271
|
init_StyleTypes();
|
|
5225
|
-
var
|
|
5272
|
+
var import_jsx_runtime69 = require("react/jsx-runtime");
|
|
5226
5273
|
var Pagination = (props) => {
|
|
5227
5274
|
const { dataset, path, query, showPageSizeSelector = false, showJumpToPage = false } = props;
|
|
5228
5275
|
const builder = (0, import_react51.useMemo)(() => {
|
|
@@ -5266,7 +5313,7 @@ var Pagination = (props) => {
|
|
|
5266
5313
|
return range;
|
|
5267
5314
|
};
|
|
5268
5315
|
const paginationRange = getPaginationRange();
|
|
5269
|
-
const PageButton = ({ page, children }) => /* @__PURE__ */ (0,
|
|
5316
|
+
const PageButton = ({ page, children }) => /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(
|
|
5270
5317
|
Hyperlink,
|
|
5271
5318
|
{
|
|
5272
5319
|
linkType: "Link" /* Link */,
|
|
@@ -5281,9 +5328,9 @@ var Pagination = (props) => {
|
|
|
5281
5328
|
);
|
|
5282
5329
|
const NavigationButton = ({ page, disabled, children }) => {
|
|
5283
5330
|
if (disabled) {
|
|
5284
|
-
return /* @__PURE__ */ (0,
|
|
5331
|
+
return /* @__PURE__ */ (0, import_jsx_runtime69.jsx)("span", { className: "min-w-[20px] md:min-w-[40px] h-10 flex items-center justify-center px-2 md:px-3 border bg-neutral-base cursor-not-allowed", children });
|
|
5285
5332
|
}
|
|
5286
|
-
return /* @__PURE__ */ (0,
|
|
5333
|
+
return /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(
|
|
5287
5334
|
Hyperlink,
|
|
5288
5335
|
{
|
|
5289
5336
|
className: "min-w-[20px] md:min-w-[40px] h-10 flex items-center justify-center px-2 md:px-3 border transition-colors duration-150",
|
|
@@ -5293,35 +5340,35 @@ var Pagination = (props) => {
|
|
|
5293
5340
|
);
|
|
5294
5341
|
};
|
|
5295
5342
|
if (totalPages <= 1 && totalItems === 0) return null;
|
|
5296
|
-
return /* @__PURE__ */ (0,
|
|
5297
|
-
/* @__PURE__ */ (0,
|
|
5298
|
-
/* @__PURE__ */ (0,
|
|
5343
|
+
return /* @__PURE__ */ (0, import_jsx_runtime69.jsxs)("div", { className: "py-6 border-t bg-default", children: [
|
|
5344
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsxs)("div", { className: "flex flex-col sm:flex-row items-center justify-between gap-4", children: [
|
|
5345
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsxs)("div", { className: "text-sm", children: [
|
|
5299
5346
|
"Showing ",
|
|
5300
|
-
/* @__PURE__ */ (0,
|
|
5347
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsxs)("span", { className: "font-semibold", children: [
|
|
5301
5348
|
startItem,
|
|
5302
5349
|
"-",
|
|
5303
5350
|
endItem
|
|
5304
5351
|
] }),
|
|
5305
5352
|
" ",
|
|
5306
5353
|
"out of ",
|
|
5307
|
-
/* @__PURE__ */ (0,
|
|
5354
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)("span", { className: "font-semibold", children: totalItems.toLocaleString() }),
|
|
5308
5355
|
" results"
|
|
5309
5356
|
] }),
|
|
5310
|
-
totalPages > 1 && /* @__PURE__ */ (0,
|
|
5311
|
-
/* @__PURE__ */ (0,
|
|
5357
|
+
totalPages > 1 && /* @__PURE__ */ (0, import_jsx_runtime69.jsxs)("div", { className: "flex items-center space-x-1", children: [
|
|
5358
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsxs)(
|
|
5312
5359
|
NavigationButton,
|
|
5313
5360
|
{
|
|
5314
5361
|
page: activePageNumber - 1,
|
|
5315
5362
|
disabled: activePageNumber === 1,
|
|
5316
5363
|
children: [
|
|
5317
|
-
/* @__PURE__ */ (0,
|
|
5318
|
-
/* @__PURE__ */ (0,
|
|
5364
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)("span", { children: /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(Icon_default, { name: "chevronLeft", className: "w-4 h-4 mr-1" }) }),
|
|
5365
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)("span", { className: "text-sm", children: "Prev" })
|
|
5319
5366
|
]
|
|
5320
5367
|
}
|
|
5321
5368
|
),
|
|
5322
5369
|
paginationRange.map((item, index) => {
|
|
5323
5370
|
if (item === "...") {
|
|
5324
|
-
return /* @__PURE__ */ (0,
|
|
5371
|
+
return /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(
|
|
5325
5372
|
"span",
|
|
5326
5373
|
{
|
|
5327
5374
|
className: "min-w-[20px] md:min-w-[40px] h-10 flex items-center justify-center text-gray-500",
|
|
@@ -5331,23 +5378,23 @@ var Pagination = (props) => {
|
|
|
5331
5378
|
);
|
|
5332
5379
|
}
|
|
5333
5380
|
const page = item;
|
|
5334
|
-
return /* @__PURE__ */ (0,
|
|
5381
|
+
return /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(PageButton, { page, children: page }, page);
|
|
5335
5382
|
}),
|
|
5336
|
-
/* @__PURE__ */ (0,
|
|
5383
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsxs)(
|
|
5337
5384
|
NavigationButton,
|
|
5338
5385
|
{
|
|
5339
5386
|
page: activePageNumber + 1,
|
|
5340
5387
|
disabled: activePageNumber === totalPages,
|
|
5341
5388
|
children: [
|
|
5342
|
-
/* @__PURE__ */ (0,
|
|
5343
|
-
/* @__PURE__ */ (0,
|
|
5389
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)("span", { className: "text-sm", children: "Next" }),
|
|
5390
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)("span", { children: /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(Icon_default, { name: "chevronRight", className: "w-4 h-4 ml-1" }) })
|
|
5344
5391
|
]
|
|
5345
5392
|
}
|
|
5346
5393
|
)
|
|
5347
5394
|
] }),
|
|
5348
|
-
showJumpToPage && totalPages > 5 && /* @__PURE__ */ (0,
|
|
5349
|
-
/* @__PURE__ */ (0,
|
|
5350
|
-
/* @__PURE__ */ (0,
|
|
5395
|
+
showJumpToPage && totalPages > 5 && /* @__PURE__ */ (0, import_jsx_runtime69.jsxs)("div", { className: "flex items-center space-x-2", children: [
|
|
5396
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)("span", { className: "text-sm", children: "Go to:" }),
|
|
5397
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)("div", { className: "relative", children: /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(
|
|
5351
5398
|
"input",
|
|
5352
5399
|
{
|
|
5353
5400
|
type: "number",
|
|
@@ -5368,9 +5415,9 @@ var Pagination = (props) => {
|
|
|
5368
5415
|
) })
|
|
5369
5416
|
] })
|
|
5370
5417
|
] }),
|
|
5371
|
-
showPageSizeSelector && /* @__PURE__ */ (0,
|
|
5372
|
-
/* @__PURE__ */ (0,
|
|
5373
|
-
/* @__PURE__ */ (0,
|
|
5418
|
+
showPageSizeSelector && /* @__PURE__ */ (0, import_jsx_runtime69.jsx)("div", { className: "mt-4 pt-4 border-t bg-default", children: /* @__PURE__ */ (0, import_jsx_runtime69.jsxs)("div", { className: "flex items-center justify-center space-x-2", children: [
|
|
5419
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)("span", { className: "text-sm", children: "Show:" }),
|
|
5420
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)("div", { className: "flex space-x-1", children: [10, 25, 50, 100].map((size) => /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(
|
|
5374
5421
|
Hyperlink,
|
|
5375
5422
|
{
|
|
5376
5423
|
className: `
|
|
@@ -5382,7 +5429,7 @@ var Pagination = (props) => {
|
|
|
5382
5429
|
},
|
|
5383
5430
|
size
|
|
5384
5431
|
)) }),
|
|
5385
|
-
/* @__PURE__ */ (0,
|
|
5432
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)("span", { className: "text-sm", children: "per page" })
|
|
5386
5433
|
] }) })
|
|
5387
5434
|
] });
|
|
5388
5435
|
};
|
|
@@ -5390,7 +5437,7 @@ var Pagination_default = Pagination;
|
|
|
5390
5437
|
|
|
5391
5438
|
// src/components/pageRenderingEngine/nodes/ImageGalleryNode.tsx
|
|
5392
5439
|
var import_dynamic5 = __toESM(require("next/dynamic"));
|
|
5393
|
-
var
|
|
5440
|
+
var import_jsx_runtime70 = require("react/jsx-runtime");
|
|
5394
5441
|
var HlsPlayer3 = (0, import_dynamic5.default)(() => Promise.resolve().then(() => (init_HlsPlayer(), HlsPlayer_exports)), { ssr: false });
|
|
5395
5442
|
var deviceToMediaQuery = (device) => {
|
|
5396
5443
|
switch (device) {
|
|
@@ -5459,8 +5506,8 @@ var ImageGalleryNode = (props) => {
|
|
|
5459
5506
|
right: "justify-end"
|
|
5460
5507
|
};
|
|
5461
5508
|
const formatClasses = FormatClass[props.node.format || ""] || "";
|
|
5462
|
-
return /* @__PURE__ */ (0,
|
|
5463
|
-
hlsSources.length > 0 && /* @__PURE__ */ (0,
|
|
5509
|
+
return /* @__PURE__ */ (0, import_jsx_runtime70.jsxs)(import_jsx_runtime70.Fragment, { children: [
|
|
5510
|
+
hlsSources.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_jsx_runtime70.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(
|
|
5464
5511
|
HlsPlayer3,
|
|
5465
5512
|
{
|
|
5466
5513
|
sources: hlsSources,
|
|
@@ -5474,14 +5521,14 @@ var ImageGalleryNode = (props) => {
|
|
|
5474
5521
|
session: props.session
|
|
5475
5522
|
}
|
|
5476
5523
|
) }),
|
|
5477
|
-
staticFallback && /* @__PURE__ */ (0,
|
|
5524
|
+
staticFallback && /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_jsx_runtime70.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime70.jsxs)("picture", { children: [
|
|
5478
5525
|
DEVICE_ORDER.map((deviceKey) => {
|
|
5479
5526
|
const match = staticSources.find((img) => img.device === deviceKey);
|
|
5480
5527
|
if (!match) return null;
|
|
5481
5528
|
const srcUrl = resolveImageUrl(match.imageUrl);
|
|
5482
5529
|
if (!srcUrl) return null;
|
|
5483
5530
|
const mediaQuery = deviceToMediaQuery(match.device);
|
|
5484
|
-
return /* @__PURE__ */ (0,
|
|
5531
|
+
return /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(
|
|
5485
5532
|
"source",
|
|
5486
5533
|
{
|
|
5487
5534
|
media: mediaQuery,
|
|
@@ -5505,7 +5552,7 @@ var ImageGalleryNode = (props) => {
|
|
|
5505
5552
|
if (img.borderRadius) styles.borderRadius = img.borderRadius;
|
|
5506
5553
|
return (
|
|
5507
5554
|
// eslint-disable-next-line @next/next/no-img-element
|
|
5508
|
-
/* @__PURE__ */ (0,
|
|
5555
|
+
/* @__PURE__ */ (0, import_jsx_runtime70.jsx)(
|
|
5509
5556
|
"img",
|
|
5510
5557
|
{
|
|
5511
5558
|
loading: "lazy",
|
|
@@ -5525,8 +5572,8 @@ var ImageGalleryNode = (props) => {
|
|
|
5525
5572
|
var ImageGalleryNode_default = ImageGalleryNode;
|
|
5526
5573
|
|
|
5527
5574
|
// src/components/pageRenderingEngine/nodes/DivContainer.tsx
|
|
5528
|
-
var
|
|
5529
|
-
var
|
|
5575
|
+
var import_link3 = __toESM(require("next/link"));
|
|
5576
|
+
var import_jsx_runtime71 = require("react/jsx-runtime");
|
|
5530
5577
|
function toCamelCase(str) {
|
|
5531
5578
|
return str.replace(/-([a-z])/g, (_, letter) => letter.toUpperCase());
|
|
5532
5579
|
}
|
|
@@ -5731,7 +5778,7 @@ var DivContainer = async (props) => {
|
|
|
5731
5778
|
response = await serviceClient.get(endpoint);
|
|
5732
5779
|
result = response?.result;
|
|
5733
5780
|
if (dataBindingProperties.showNoResultsMessage && (result === void 0 || result.length == 0)) {
|
|
5734
|
-
return /* @__PURE__ */ (0,
|
|
5781
|
+
return /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(NoDataFound_default, {});
|
|
5735
5782
|
}
|
|
5736
5783
|
if (dataBindingProperties.childCollectionName && props.dataitem) {
|
|
5737
5784
|
childCollectionData = getNestedValue2(props.dataitem, dataBindingProperties.childCollectionName);
|
|
@@ -5748,7 +5795,7 @@ var DivContainer = async (props) => {
|
|
|
5748
5795
|
}
|
|
5749
5796
|
const SelectedNode = NodeTypes2[node.type];
|
|
5750
5797
|
if (!SelectedNode) return null;
|
|
5751
|
-
return /* @__PURE__ */ (0,
|
|
5798
|
+
return /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(import_react52.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(
|
|
5752
5799
|
SelectedNode,
|
|
5753
5800
|
{
|
|
5754
5801
|
node,
|
|
@@ -5818,7 +5865,7 @@ var DivContainer = async (props) => {
|
|
|
5818
5865
|
wrapperProps = { ...props.node.componentProperties, "slidesToShow": slidesToShow };
|
|
5819
5866
|
break;
|
|
5820
5867
|
case !!(props.node.href || props.href):
|
|
5821
|
-
Wrapper =
|
|
5868
|
+
Wrapper = import_link3.default;
|
|
5822
5869
|
let href = props.node.href || props.href;
|
|
5823
5870
|
if (href?.includes("{")) {
|
|
5824
5871
|
href = resolveHrefTemplate(href, props.dataitem);
|
|
@@ -5850,9 +5897,9 @@ var DivContainer = async (props) => {
|
|
|
5850
5897
|
props.node.autoFormat && "auto-format",
|
|
5851
5898
|
props.node.bgClass
|
|
5852
5899
|
].filter(Boolean).join(" ");
|
|
5853
|
-
return /* @__PURE__ */ (0,
|
|
5854
|
-
/* @__PURE__ */ (0,
|
|
5855
|
-
/* @__PURE__ */ (0,
|
|
5900
|
+
return /* @__PURE__ */ (0, import_jsx_runtime71.jsxs)(import_react52.default.Fragment, { children: [
|
|
5901
|
+
/* @__PURE__ */ (0, import_jsx_runtime71.jsx)("style", { dangerouslySetInnerHTML: { __html: cssResult.css + animationCSS } }),
|
|
5902
|
+
/* @__PURE__ */ (0, import_jsx_runtime71.jsx)(import_react52.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(
|
|
5856
5903
|
Wrapper,
|
|
5857
5904
|
{
|
|
5858
5905
|
id: guid,
|
|
@@ -5861,18 +5908,18 @@ var DivContainer = async (props) => {
|
|
|
5861
5908
|
...wrapperProps,
|
|
5862
5909
|
children: dataToRender.map(
|
|
5863
5910
|
(item, idx) => item?.links?.view && renderLink ? renderChildren(props.node.children, props, item, idx, props.href ? void 0 : item?.links?.view)?.map(
|
|
5864
|
-
(child, i) => /* @__PURE__ */ (0,
|
|
5911
|
+
(child, i) => /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(import_react52.default.Fragment, { children: child }, i)
|
|
5865
5912
|
) : renderChildren(props.node.children, props, item, idx)
|
|
5866
5913
|
)
|
|
5867
5914
|
}
|
|
5868
5915
|
) }),
|
|
5869
|
-
dataBindingProperties && props.node.dataBinding.enablePagination && /* @__PURE__ */ (0,
|
|
5916
|
+
dataBindingProperties && props.node.dataBinding.enablePagination && /* @__PURE__ */ (0, import_jsx_runtime71.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(Pagination_default, { path: props.path, query: props.query, dataset: response }) })
|
|
5870
5917
|
] });
|
|
5871
5918
|
};
|
|
5872
5919
|
var DivContainer_default = DivContainer;
|
|
5873
5920
|
|
|
5874
5921
|
// src/components/pageRenderingEngine/PageBodyRenderer.tsx
|
|
5875
|
-
var
|
|
5922
|
+
var import_jsx_runtime72 = require("react/jsx-runtime");
|
|
5876
5923
|
var NodeTypes = {
|
|
5877
5924
|
["paragraph"]: ParagraphNode_default,
|
|
5878
5925
|
["heading"]: HeadingNode_default,
|
|
@@ -5900,11 +5947,11 @@ var PageBodyRenderer = (props) => {
|
|
|
5900
5947
|
if (pageBodyTree && pageBodyTree.root) {
|
|
5901
5948
|
rootNode = pageBodyTree.root;
|
|
5902
5949
|
}
|
|
5903
|
-
return /* @__PURE__ */ (0,
|
|
5950
|
+
return /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_react53.default.Fragment, { children: rootNode && rootNode?.children?.map((node, index) => {
|
|
5904
5951
|
{
|
|
5905
5952
|
}
|
|
5906
5953
|
const SelectedNode = NodeTypes[node.type];
|
|
5907
|
-
return /* @__PURE__ */ (0,
|
|
5954
|
+
return /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_react53.default.Fragment, { children: SelectedNode && /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_react53.default.Fragment, { children: node.type == "layout-container" ? /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_react53.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(
|
|
5908
5955
|
SelectedNode,
|
|
5909
5956
|
{
|
|
5910
5957
|
node,
|
|
@@ -5920,7 +5967,7 @@ var PageBodyRenderer = (props) => {
|
|
|
5920
5967
|
device: props.device,
|
|
5921
5968
|
widgetRenderer: props.widgetRenderer
|
|
5922
5969
|
}
|
|
5923
|
-
) }) : /* @__PURE__ */ (0,
|
|
5970
|
+
) }) : /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_react53.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(
|
|
5924
5971
|
SelectedNode,
|
|
5925
5972
|
{
|
|
5926
5973
|
node,
|
|
@@ -5943,7 +5990,7 @@ var PageBodyRenderer_default = PageBodyRenderer;
|
|
|
5943
5990
|
// src/components/Toast.tsx
|
|
5944
5991
|
var import_react54 = require("react");
|
|
5945
5992
|
init_ToastService();
|
|
5946
|
-
var
|
|
5993
|
+
var import_jsx_runtime73 = require("react/jsx-runtime");
|
|
5947
5994
|
var Toast = () => {
|
|
5948
5995
|
const [showToast, setShowToast] = (0, import_react54.useState)(false);
|
|
5949
5996
|
const [message, setMessage] = (0, import_react54.useState)("");
|
|
@@ -5986,8 +6033,8 @@ var Toast = () => {
|
|
|
5986
6033
|
const closeToast = () => {
|
|
5987
6034
|
setShowToast(false);
|
|
5988
6035
|
};
|
|
5989
|
-
return /* @__PURE__ */ (0,
|
|
5990
|
-
/* @__PURE__ */ (0,
|
|
6036
|
+
return /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(import_jsx_runtime73.Fragment, { children: showToast && /* @__PURE__ */ (0, import_jsx_runtime73.jsx)("div", { className: "fixed top-2 flex justify-center w-1/2 max-w-xl left-1/2 -translate-x-1/2", style: { zIndex: 1e3 }, children: /* @__PURE__ */ (0, import_jsx_runtime73.jsxs)("div", { className: `w-full items-center flex justify-between p-3 rounded-md relative shadow border bg-${messageType}-soft`, children: [
|
|
6037
|
+
/* @__PURE__ */ (0, import_jsx_runtime73.jsx)(
|
|
5991
6038
|
"span",
|
|
5992
6039
|
{
|
|
5993
6040
|
className: "font-medium text-inherit text-sm",
|
|
@@ -5995,7 +6042,7 @@ var Toast = () => {
|
|
|
5995
6042
|
children: message
|
|
5996
6043
|
}
|
|
5997
6044
|
),
|
|
5998
|
-
/* @__PURE__ */ (0,
|
|
6045
|
+
/* @__PURE__ */ (0, import_jsx_runtime73.jsx)("button", { className: "absolute right-2 top-2 ml-2 focus:outline-none", onClick: closeToast, children: /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(
|
|
5999
6046
|
"svg",
|
|
6000
6047
|
{
|
|
6001
6048
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -6003,7 +6050,7 @@ var Toast = () => {
|
|
|
6003
6050
|
fill: "none",
|
|
6004
6051
|
viewBox: "0 0 24 24",
|
|
6005
6052
|
stroke: "currentColor",
|
|
6006
|
-
children: /* @__PURE__ */ (0,
|
|
6053
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime73.jsx)("path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: "2", d: "M6 18L18 6M6 6l12 12" })
|
|
6007
6054
|
}
|
|
6008
6055
|
) })
|
|
6009
6056
|
] }) }) });
|
|
@@ -6012,47 +6059,6 @@ var Toast_default = Toast;
|
|
|
6012
6059
|
|
|
6013
6060
|
// src/index.ts
|
|
6014
6061
|
init_ToastService();
|
|
6015
|
-
|
|
6016
|
-
// src/components/NavigationTabsV2.tsx
|
|
6017
|
-
var import_link3 = __toESM(require("next/link"));
|
|
6018
|
-
var import_navigation3 = require("next/navigation");
|
|
6019
|
-
var import_jsx_runtime73 = require("react/jsx-runtime");
|
|
6020
|
-
function resolveRoutePlaceholders2(route, params) {
|
|
6021
|
-
return route.replace(/\{([^}]+)\}/g, (match, key) => {
|
|
6022
|
-
const value = params[key];
|
|
6023
|
-
if (value === void 0 || value === null) {
|
|
6024
|
-
console.warn(`No value found for route param: ${key}`);
|
|
6025
|
-
return "";
|
|
6026
|
-
}
|
|
6027
|
-
return value;
|
|
6028
|
-
});
|
|
6029
|
-
}
|
|
6030
|
-
var NavigationTabsV2 = ({ tabs, params = {} }) => {
|
|
6031
|
-
const pathname = (0, import_navigation3.usePathname)();
|
|
6032
|
-
const shouldHideTabs = pathname?.includes("/add");
|
|
6033
|
-
if (shouldHideTabs) return null;
|
|
6034
|
-
const mappedTabs = tabs?.sort((a, b) => a.displayOrder - b.displayOrder)?.map((tab) => ({
|
|
6035
|
-
tabTitle: tab.tabTitle,
|
|
6036
|
-
displayOrder: tab.displayOrder,
|
|
6037
|
-
landingPageUrl: resolveRoutePlaceholders2(
|
|
6038
|
-
tab.landingPageUrl,
|
|
6039
|
-
params
|
|
6040
|
-
),
|
|
6041
|
-
isActive: tab.isActive
|
|
6042
|
-
})) || [];
|
|
6043
|
-
if (mappedTabs.length === 0) return null;
|
|
6044
|
-
return /* @__PURE__ */ (0, import_jsx_runtime73.jsx)("div", { className: "flex border-b bg-white rounded-t mb-3", children: mappedTabs.map(({ tabTitle, landingPageUrl, isActive }) => {
|
|
6045
|
-
return /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(import_link3.default, { href: landingPageUrl, className: "-mb-px", children: /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(
|
|
6046
|
-
"div",
|
|
6047
|
-
{
|
|
6048
|
-
className: `text-sm font-medium border-b-2 px-6 py-2 transition
|
|
6049
|
-
${isActive ? "bg-info-base" : "bg-neutral-weak "}`,
|
|
6050
|
-
children: tabTitle
|
|
6051
|
-
}
|
|
6052
|
-
) }, landingPageUrl);
|
|
6053
|
-
}) });
|
|
6054
|
-
};
|
|
6055
|
-
var NavigationTabsV2_default = NavigationTabsV2;
|
|
6056
6062
|
// Annotate the CommonJS export names for ESM import in node:
|
|
6057
6063
|
0 && (module.exports = {
|
|
6058
6064
|
BooleanSelect,
|