@acoustte-digital-services/digitalstore-controls-dev 0.8.1-dev.20260429063933 → 0.8.1-dev.20260429112313
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/DateViewClient-UCGTXQNC.mjs +231 -0
- package/dist/index.js +257 -230
- package/dist/index.mjs +556 -772
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
} from "./chunk-MCGXO6OE.mjs";
|
|
11
11
|
|
|
12
12
|
// src/components/controls/view/ViewControl.tsx
|
|
13
|
-
import
|
|
13
|
+
import React9 from "react";
|
|
14
14
|
|
|
15
15
|
// src/components/controls/view/ViewControlTypes.tsx
|
|
16
16
|
var ViewControlTypes = {
|
|
@@ -43,231 +43,15 @@ var NumberView = (props) => {
|
|
|
43
43
|
var NumberView_default = NumberView;
|
|
44
44
|
|
|
45
45
|
// src/components/controls/view/DateView.tsx
|
|
46
|
-
import
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
"Asia/Calcutta": "IST",
|
|
51
|
-
"Asia/Kolkata": "IST",
|
|
52
|
-
"America/New_York": "EST",
|
|
53
|
-
"America/Los_Angeles": "PST",
|
|
54
|
-
"Europe/London": "GMT",
|
|
55
|
-
"Europe/Paris": "CET",
|
|
56
|
-
"Asia/Tokyo": "JST",
|
|
57
|
-
"America/Chicago": "CST",
|
|
58
|
-
"America/Denver": "MST",
|
|
59
|
-
"Asia/Shanghai": "CST",
|
|
60
|
-
"Asia/Hong_Kong": "HKT",
|
|
61
|
-
"Australia/Sydney": "AEST",
|
|
62
|
-
"Australia/Melbourne": "AEST",
|
|
63
|
-
"Australia/Perth": "AWST",
|
|
64
|
-
"Pacific/Auckland": "NZST",
|
|
65
|
-
"Europe/Berlin": "CET",
|
|
66
|
-
"Europe/Madrid": "CET",
|
|
67
|
-
"Europe/Rome": "CET",
|
|
68
|
-
"Europe/Athens": "EET",
|
|
69
|
-
"Europe/Istanbul": "TRT",
|
|
70
|
-
"Africa/Cairo": "EET",
|
|
71
|
-
"Africa/Johannesburg": "SAST",
|
|
72
|
-
"Asia/Dubai": "GST",
|
|
73
|
-
"Asia/Singapore": "SGT",
|
|
74
|
-
"Asia/Seoul": "KST",
|
|
75
|
-
"America/Toronto": "EST",
|
|
76
|
-
"America/Vancouver": "PST",
|
|
77
|
-
"America/Sao_Paulo": "BRT",
|
|
78
|
-
"America/Mexico_City": "CST",
|
|
79
|
-
"Asia/Manila": "PHT",
|
|
80
|
-
"Asia/Jakarta": "WIB",
|
|
81
|
-
"Asia/Bangkok": "ICT",
|
|
82
|
-
"Asia/Karachi": "PKT",
|
|
83
|
-
"Asia/Tehran": "IRST",
|
|
84
|
-
"Asia/Baghdad": "AST",
|
|
85
|
-
"Europe/Moscow": "MSK",
|
|
86
|
-
"Europe/Amsterdam": "CET",
|
|
87
|
-
"Europe/Brussels": "CET",
|
|
88
|
-
"Europe/Zurich": "CET",
|
|
89
|
-
"America/Anchorage": "AKST",
|
|
90
|
-
"Pacific/Honolulu": "HST",
|
|
91
|
-
"Antarctica/McMurdo": "NZST",
|
|
92
|
-
"Atlantic/Reykjavik": "GMT",
|
|
93
|
-
"Asia/Riyadh": "AST",
|
|
94
|
-
"America/Argentina/Buenos_Aires": "ART",
|
|
95
|
-
"America/Bogota": "COT",
|
|
96
|
-
"Africa/Nairobi": "EAT",
|
|
97
|
-
"Asia/Kuala_Lumpur": "MYT",
|
|
98
|
-
"Asia/Ho_Chi_Minh": "ICT",
|
|
99
|
-
"Europe/Warsaw": "CET",
|
|
100
|
-
"Europe/Prague": "CET",
|
|
101
|
-
"America/Phoenix": "MST",
|
|
102
|
-
"America/Indianapolis": "EST",
|
|
103
|
-
"Pacific/Fiji": "FJT",
|
|
104
|
-
"Asia/Colombo": "IST",
|
|
105
|
-
"Africa/Lagos": "WAT",
|
|
106
|
-
"America/Caracas": "VET",
|
|
107
|
-
"America/Halifax": "AST",
|
|
108
|
-
"Pacific/Tahiti": "TAHT",
|
|
109
|
-
"America/St_Johns": "NST",
|
|
110
|
-
"Europe/Bucharest": "EET",
|
|
111
|
-
"Europe/Helsinki": "EET",
|
|
112
|
-
"Europe/Kiev": "EET",
|
|
113
|
-
"Europe/Oslo": "CET",
|
|
114
|
-
"Europe/Stockholm": "CET",
|
|
115
|
-
"Europe/Lisbon": "WET",
|
|
116
|
-
"Asia/Beirut": "EET",
|
|
117
|
-
"Asia/Damascus": "EET",
|
|
118
|
-
"Asia/Jerusalem": "IST",
|
|
119
|
-
"Asia/Amman": "EET",
|
|
120
|
-
"America/Santiago": "CLT",
|
|
121
|
-
"America/Lima": "PET",
|
|
122
|
-
"America/Montevideo": "UYT",
|
|
123
|
-
"Asia/Tashkent": "UZT",
|
|
124
|
-
"Asia/Yerevan": "AMT",
|
|
125
|
-
"Asia/Baku": "AZT",
|
|
126
|
-
"Europe/Vilnius": "EET",
|
|
127
|
-
"Europe/Riga": "EET",
|
|
128
|
-
"Europe/Tallinn": "EET",
|
|
129
|
-
"Europe/Sofia": "EET",
|
|
130
|
-
"Africa/Casablanca": "WET",
|
|
131
|
-
"America/Guatemala": "CST",
|
|
132
|
-
"America/Panama": "EST",
|
|
133
|
-
"America/Costa_Rica": "CST",
|
|
134
|
-
"Pacific/Port_Moresby": "PGT",
|
|
135
|
-
"Asia/Makassar": "WITA",
|
|
136
|
-
"Asia/Vladivostok": "VLAT",
|
|
137
|
-
"Asia/Krasnoyarsk": "KRAT",
|
|
138
|
-
"Asia/Novosibirsk": "NOVT",
|
|
139
|
-
"Asia/Yakutsk": "YAKT",
|
|
140
|
-
"Asia/Sakhalin": "SAKT",
|
|
141
|
-
"Asia/Ulaanbaatar": "ULAT",
|
|
142
|
-
"Asia/Choibalsan": "CHOT",
|
|
143
|
-
"Asia/Omsk": "OMST",
|
|
144
|
-
"Asia/Kamchatka": "PETT",
|
|
145
|
-
"Pacific/Pago_Pago": "SST",
|
|
146
|
-
"Pacific/Guam": "ChST",
|
|
147
|
-
"Pacific/Saipan": "ChST",
|
|
148
|
-
"Pacific/Palau": "PWT",
|
|
149
|
-
"Pacific/Efate": "VUT",
|
|
150
|
-
"Pacific/Kosrae": "KOST",
|
|
151
|
-
"Pacific/Nauru": "NRT",
|
|
152
|
-
"Pacific/Tarawa": "GILT",
|
|
153
|
-
"Pacific/Enderbury": "PHOT",
|
|
154
|
-
"Pacific/Fakaofo": "TKT",
|
|
155
|
-
"Pacific/Chatham": "CHAST",
|
|
156
|
-
"Pacific/Tongatapu": "TOT",
|
|
157
|
-
"Pacific/Funafuti": "TVT",
|
|
158
|
-
"Pacific/Majuro": "MHT",
|
|
159
|
-
"Pacific/Kwajalein": "MHT",
|
|
160
|
-
"Pacific/Wake": "WAKT",
|
|
161
|
-
"Pacific/Wallis": "WFT"
|
|
162
|
-
};
|
|
163
|
-
|
|
164
|
-
// src/components/controls/view/DateView.tsx
|
|
165
|
-
import { jsx as jsx2, jsxs } from "react/jsx-runtime";
|
|
166
|
-
var DateView = (props) => {
|
|
167
|
-
const userTimeZone = Intl.DateTimeFormat().resolvedOptions().timeZone;
|
|
168
|
-
const getTimeZoneAbbreviation = (timeZone) => {
|
|
169
|
-
return timeZoneAbbreviations[timeZone] || timeZone;
|
|
170
|
-
};
|
|
171
|
-
const getRelativeTime = (dateString) => {
|
|
172
|
-
const now = /* @__PURE__ */ new Date();
|
|
173
|
-
const date = /* @__PURE__ */ new Date(dateString + "Z");
|
|
174
|
-
const diffMs = now.getTime() - date.getTime();
|
|
175
|
-
const diffSec = Math.floor(diffMs / 1e3);
|
|
176
|
-
const diffMin = Math.floor(diffSec / 60);
|
|
177
|
-
const diffHr = Math.floor(diffMin / 60);
|
|
178
|
-
const diffDay = Math.floor(diffHr / 24);
|
|
179
|
-
if (diffSec < 60) return "Just now";
|
|
180
|
-
if (diffMin < 60) return `${diffMin} minute${diffMin > 1 ? "s" : ""} ago`;
|
|
181
|
-
if (diffHr < 24) return `${diffHr} hour${diffHr > 1 ? "s" : ""} ago`;
|
|
182
|
-
if (diffDay < 7) return `${diffDay} day${diffDay > 1 ? "s" : ""} ago`;
|
|
183
|
-
return new Intl.DateTimeFormat("en", {
|
|
184
|
-
day: "2-digit",
|
|
185
|
-
month: "short",
|
|
186
|
-
year: "numeric",
|
|
187
|
-
timeZone: userTimeZone
|
|
188
|
-
}).format(date);
|
|
189
|
-
};
|
|
190
|
-
console.log("DateView props:", props);
|
|
191
|
-
const parseAndFormatDate = (dateString, format) => {
|
|
192
|
-
const parsedDate = /* @__PURE__ */ new Date(dateString + "Z");
|
|
193
|
-
if (format === "relative") {
|
|
194
|
-
return getRelativeTime(dateString);
|
|
195
|
-
}
|
|
196
|
-
switch (props.controlType) {
|
|
197
|
-
case "date":
|
|
198
|
-
return new Intl.DateTimeFormat("en", {
|
|
199
|
-
day: "2-digit",
|
|
200
|
-
month: "short",
|
|
201
|
-
year: "numeric",
|
|
202
|
-
timeZone: userTimeZone
|
|
203
|
-
}).format(parsedDate);
|
|
204
|
-
case "time":
|
|
205
|
-
return `${formatTime(parsedDate)} ${getTimeZoneAbbreviation(userTimeZone)} (${getTimePeriod(parsedDate)})`;
|
|
206
|
-
default:
|
|
207
|
-
return parsedDate.getSeconds() === 0 ? new Intl.DateTimeFormat("en", {
|
|
208
|
-
day: "2-digit",
|
|
209
|
-
month: "short",
|
|
210
|
-
year: "numeric",
|
|
211
|
-
hour: "2-digit",
|
|
212
|
-
minute: "2-digit",
|
|
213
|
-
timeZone: userTimeZone
|
|
214
|
-
}).format(parsedDate) : new Intl.DateTimeFormat("en", {
|
|
215
|
-
day: "2-digit",
|
|
216
|
-
month: "short",
|
|
217
|
-
year: "numeric",
|
|
218
|
-
hour: "2-digit",
|
|
219
|
-
minute: "2-digit",
|
|
220
|
-
second: "2-digit",
|
|
221
|
-
timeZone: userTimeZone
|
|
222
|
-
}).format(parsedDate);
|
|
223
|
-
}
|
|
224
|
-
};
|
|
225
|
-
const formatTime = (date) => {
|
|
226
|
-
return date.getSeconds() === 0 ? new Intl.DateTimeFormat("en", {
|
|
227
|
-
hour: "2-digit",
|
|
228
|
-
minute: "2-digit",
|
|
229
|
-
timeZone: userTimeZone
|
|
230
|
-
}).format(date) : new Intl.DateTimeFormat("en", {
|
|
231
|
-
hour: "2-digit",
|
|
232
|
-
minute: "2-digit",
|
|
233
|
-
second: "2-digit",
|
|
234
|
-
timeZone: userTimeZone
|
|
235
|
-
}).format(date);
|
|
236
|
-
};
|
|
237
|
-
const getTimePeriod = (date) => {
|
|
238
|
-
const localHours = Number(
|
|
239
|
-
new Intl.DateTimeFormat("en", {
|
|
240
|
-
hour: "numeric",
|
|
241
|
-
hour12: false,
|
|
242
|
-
timeZone: userTimeZone
|
|
243
|
-
}).format(date)
|
|
244
|
-
);
|
|
245
|
-
if (localHours >= 5 && localHours < 8) return "Early Morning";
|
|
246
|
-
if (localHours >= 8 && localHours < 12) return "Morning";
|
|
247
|
-
if (localHours >= 12 && localHours < 14) return "Noon";
|
|
248
|
-
if (localHours >= 14 && localHours < 17) return "Afternoon";
|
|
249
|
-
if (localHours >= 17 && localHours < 20) return "Evening";
|
|
250
|
-
if (localHours >= 20 && localHours < 22) return "Late Evening";
|
|
251
|
-
return "Night";
|
|
252
|
-
};
|
|
253
|
-
let localDateTime = "";
|
|
254
|
-
let timeZoneAbbreviation = "";
|
|
255
|
-
try {
|
|
256
|
-
localDateTime = parseAndFormatDate(props.value, props.format);
|
|
257
|
-
timeZoneAbbreviation = getTimeZoneAbbreviation(userTimeZone);
|
|
258
|
-
} catch (error) {
|
|
259
|
-
console.error("Error parsing date:", props.value, error);
|
|
260
|
-
}
|
|
261
|
-
return /* @__PURE__ */ jsx2(React2.Fragment, { children: /* @__PURE__ */ jsxs("div", { className: "inline-flex flex-wrap gap-1", children: [
|
|
262
|
-
/* @__PURE__ */ jsx2("span", { children: localDateTime }),
|
|
263
|
-
!props.format && props.controlType != "date" && /* @__PURE__ */ jsx2("span", { children: timeZoneAbbreviation })
|
|
264
|
-
] }) });
|
|
265
|
-
};
|
|
46
|
+
import dynamic from "next/dynamic";
|
|
47
|
+
var DateView = dynamic(() => import("./DateViewClient-UCGTXQNC.mjs"), {
|
|
48
|
+
ssr: false
|
|
49
|
+
});
|
|
266
50
|
var DateView_default = DateView;
|
|
267
51
|
|
|
268
52
|
// src/components/controls/view/BooleanView.tsx
|
|
269
|
-
import
|
|
270
|
-
import { jsx as
|
|
53
|
+
import React2 from "react";
|
|
54
|
+
import { jsx as jsx2 } from "react/jsx-runtime";
|
|
271
55
|
var BooleanView = (props) => {
|
|
272
56
|
const { value, customProps } = props;
|
|
273
57
|
const showOnlyTrueIcon = customProps?.showOnlyTrueIcon;
|
|
@@ -277,7 +61,7 @@ var BooleanView = (props) => {
|
|
|
277
61
|
customProps,
|
|
278
62
|
showOnlyTrueIcon
|
|
279
63
|
});
|
|
280
|
-
const booleanValue =
|
|
64
|
+
const booleanValue = React2.useMemo(() => {
|
|
281
65
|
if (typeof value === "boolean") return value;
|
|
282
66
|
if (typeof value === "string") {
|
|
283
67
|
return value.toLowerCase() === "true";
|
|
@@ -288,13 +72,13 @@ var BooleanView = (props) => {
|
|
|
288
72
|
return false;
|
|
289
73
|
}, [value]);
|
|
290
74
|
if (showOnlyTrueIcon) {
|
|
291
|
-
return /* @__PURE__ */
|
|
75
|
+
return /* @__PURE__ */ jsx2(React2.Fragment, { children: booleanValue === true && /* @__PURE__ */ jsx2(
|
|
292
76
|
"svg",
|
|
293
77
|
{
|
|
294
78
|
className: "w-15 h-8 text-green-600",
|
|
295
79
|
fill: "currentColor",
|
|
296
80
|
viewBox: "0 0 20 20",
|
|
297
|
-
children: /* @__PURE__ */
|
|
81
|
+
children: /* @__PURE__ */ jsx2(
|
|
298
82
|
"path",
|
|
299
83
|
{
|
|
300
84
|
fillRule: "evenodd",
|
|
@@ -305,54 +89,54 @@ var BooleanView = (props) => {
|
|
|
305
89
|
}
|
|
306
90
|
) });
|
|
307
91
|
}
|
|
308
|
-
return /* @__PURE__ */
|
|
92
|
+
return /* @__PURE__ */ jsx2(React2.Fragment, { children: booleanValue ? "true" : "false" });
|
|
309
93
|
};
|
|
310
94
|
var BooleanView_default = BooleanView;
|
|
311
95
|
|
|
312
96
|
// src/components/controls/view/LineTextView.tsx
|
|
313
|
-
import
|
|
314
|
-
import { jsx as
|
|
97
|
+
import React3 from "react";
|
|
98
|
+
import { jsx as jsx3 } from "react/jsx-runtime";
|
|
315
99
|
var LineText = (props) => {
|
|
316
|
-
return /* @__PURE__ */
|
|
100
|
+
return /* @__PURE__ */ jsx3(React3.Fragment, { children: props.value });
|
|
317
101
|
};
|
|
318
102
|
var LineTextView_default = LineText;
|
|
319
103
|
|
|
320
104
|
// src/components/controls/view/MoneyView.tsx
|
|
321
|
-
import
|
|
322
|
-
import { jsx as
|
|
105
|
+
import React4 from "react";
|
|
106
|
+
import { jsx as jsx4, jsxs } from "react/jsx-runtime";
|
|
323
107
|
var Money = (props) => {
|
|
324
108
|
const parsedNumber = parseFloat(props.value);
|
|
325
|
-
return /* @__PURE__ */
|
|
326
|
-
/* @__PURE__ */
|
|
109
|
+
return /* @__PURE__ */ jsx4(React4.Fragment, { children: !Number.isNaN(parsedNumber) && /* @__PURE__ */ jsxs("span", { className: parsedNumber < 0 ? "text-alert" : "", children: [
|
|
110
|
+
/* @__PURE__ */ jsx4("span", { className: "mr-0.5", children: "\u20B9" }),
|
|
327
111
|
parsedNumber.toLocaleString()
|
|
328
112
|
] }) });
|
|
329
113
|
};
|
|
330
114
|
var MoneyView_default = Money;
|
|
331
115
|
|
|
332
116
|
// src/components/controls/view/MultilineTextBulletsView.tsx
|
|
333
|
-
import
|
|
334
|
-
import { jsx as
|
|
117
|
+
import React5 from "react";
|
|
118
|
+
import { jsx as jsx5 } from "react/jsx-runtime";
|
|
335
119
|
var MultilineTextBullets = (props) => {
|
|
336
120
|
const lines = props.value?.split("\\n");
|
|
337
|
-
return /* @__PURE__ */
|
|
338
|
-
return /* @__PURE__ */
|
|
121
|
+
return /* @__PURE__ */ jsx5(React5.Fragment, { children: /* @__PURE__ */ jsx5("ul", { className: "list-disc", children: lines && lines.map((line, index) => {
|
|
122
|
+
return /* @__PURE__ */ jsx5("li", { children: line }, index);
|
|
339
123
|
}) }) });
|
|
340
124
|
};
|
|
341
125
|
var MultilineTextBulletsView_default = MultilineTextBullets;
|
|
342
126
|
|
|
343
127
|
// src/components/controls/view/MultilineTextView.tsx
|
|
344
|
-
import
|
|
345
|
-
import { jsx as
|
|
128
|
+
import React6 from "react";
|
|
129
|
+
import { jsx as jsx6 } from "react/jsx-runtime";
|
|
346
130
|
var MultilineText = (props) => {
|
|
347
|
-
return /* @__PURE__ */
|
|
131
|
+
return /* @__PURE__ */ jsx6(React6.Fragment, { children: /* @__PURE__ */ jsx6("span", { className: "whitespace-pre-line", children: props.value }) });
|
|
348
132
|
};
|
|
349
133
|
var MultilineTextView_default = MultilineText;
|
|
350
134
|
|
|
351
135
|
// src/components/controls/view/PercentageView.tsx
|
|
352
|
-
import
|
|
353
|
-
import { jsxs as
|
|
136
|
+
import React7 from "react";
|
|
137
|
+
import { jsxs as jsxs2 } from "react/jsx-runtime";
|
|
354
138
|
var PercentageView = (props) => {
|
|
355
|
-
return /* @__PURE__ */
|
|
139
|
+
return /* @__PURE__ */ jsxs2(React7.Fragment, { children: [
|
|
356
140
|
props.value,
|
|
357
141
|
"%"
|
|
358
142
|
] });
|
|
@@ -360,16 +144,16 @@ var PercentageView = (props) => {
|
|
|
360
144
|
var PercentageView_default = PercentageView;
|
|
361
145
|
|
|
362
146
|
// src/components/controls/view/ProgressIndicator.tsx
|
|
363
|
-
import
|
|
364
|
-
import { jsx as
|
|
147
|
+
import React8 from "react";
|
|
148
|
+
import { jsx as jsx7, jsxs as jsxs3 } from "react/jsx-runtime";
|
|
365
149
|
var ProgressIndicator = (props) => {
|
|
366
150
|
const percentage = 100;
|
|
367
151
|
const circumference = Math.PI * 56;
|
|
368
152
|
const offset = circumference * (1 - percentage / 100);
|
|
369
|
-
return /* @__PURE__ */
|
|
370
|
-
/* @__PURE__ */
|
|
371
|
-
/* @__PURE__ */
|
|
372
|
-
/* @__PURE__ */
|
|
153
|
+
return /* @__PURE__ */ jsx7(React8.Fragment, { children: /* @__PURE__ */ jsxs3("div", { className: "relative w-48 h-48", children: [
|
|
154
|
+
/* @__PURE__ */ jsx7("div", { className: "absolute top-0 left-0 w-full h-full rounded-full border border-gray-200" }),
|
|
155
|
+
/* @__PURE__ */ jsx7("div", { className: "absolute top-0 left-0 w-full h-full rounded-full overflow-hidden", children: /* @__PURE__ */ jsx7("div", { className: "w-full h-full rounded-full border-t-8 border-green-500", style: { transform: `rotate(-90deg)`, clipPath: `inset(0px ${offset}px 0px 0px)` } }) }),
|
|
156
|
+
/* @__PURE__ */ jsx7("div", { className: "absolute top-0 left-0 w-full h-full flex items-center justify-center text-lg font-bold text-gray-800", children: /* @__PURE__ */ jsxs3("span", { children: [
|
|
373
157
|
percentage,
|
|
374
158
|
"%"
|
|
375
159
|
] }) })
|
|
@@ -378,24 +162,24 @@ var ProgressIndicator = (props) => {
|
|
|
378
162
|
var ProgressIndicator_default = ProgressIndicator;
|
|
379
163
|
|
|
380
164
|
// src/components/controls/view/AiGeneratedSummary.tsx
|
|
381
|
-
import { jsx as
|
|
165
|
+
import { jsx as jsx8, jsxs as jsxs4 } from "react/jsx-runtime";
|
|
382
166
|
var AiGeneratedSummary = (props) => {
|
|
383
167
|
const lines = props.value?.split("\n").filter((line) => line.trim() !== "") || [];
|
|
384
|
-
return /* @__PURE__ */
|
|
385
|
-
/* @__PURE__ */
|
|
386
|
-
/* @__PURE__ */
|
|
387
|
-
/* @__PURE__ */
|
|
388
|
-
/* @__PURE__ */
|
|
389
|
-
/* @__PURE__ */
|
|
168
|
+
return /* @__PURE__ */ jsxs4("details", { className: "group rounded-xl border-2 bg-white shadow-sm border-p overflow-hidden", children: [
|
|
169
|
+
/* @__PURE__ */ jsx8("summary", { className: "flex items-start justify-between cursor-pointer list-none", children: /* @__PURE__ */ jsxs4("div", { className: "flex items-start gap-3 ", children: [
|
|
170
|
+
/* @__PURE__ */ jsx8("div", { className: "bg-primary-base bg-transparent rounded mt-1 p-1", children: /* @__PURE__ */ jsx8("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", strokeWidth: "1.5", stroke: "currentColor", className: "w-5", children: /* @__PURE__ */ jsx8("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M9.813 15.904 9 18.75l-.813-2.846a4.5 4.5 0 0 0-3.09-3.09L2.25 12l2.846-.813a4.5 4.5 0 0 0 3.09-3.09L9 5.25l.813 2.846a4.5 4.5 0 0 0 3.09 3.09L15.75 12l-2.846.813a4.5 4.5 0 0 0-3.09 3.09ZM18.259 8.715 18 9.75l-.259-1.035a3.375 3.375 0 0 0-2.455-2.456L14.25 6l1.036-.259a3.375 3.375 0 0 0 2.455-2.456L18 2.25l.259 1.035a3.375 3.375 0 0 0 2.456 2.456L21.75 6l-1.035.259a3.375 3.375 0 0 0-2.456 2.456ZM16.894 20.567 16.5 21.75l-.394-1.183a2.25 2.25 0 0 0-1.423-1.423L13.5 18.75l1.183-.394a2.25 2.25 0 0 0 1.423-1.423l.394-1.183.394 1.183a2.25 2.25 0 0 0 1.423 1.423l1.183.394-1.183.394a2.25 2.25 0 0 0-1.423 1.423Z" }) }) }),
|
|
171
|
+
/* @__PURE__ */ jsxs4("div", { children: [
|
|
172
|
+
/* @__PURE__ */ jsx8("h3", { className: "text-lg font-semibold ", children: "Quick Read" }),
|
|
173
|
+
/* @__PURE__ */ jsx8("p", { className: "text-sm text-gray-500 mb-0", children: "Summary is AI-generated, author-reviewed" })
|
|
390
174
|
] })
|
|
391
175
|
] }) }),
|
|
392
|
-
/* @__PURE__ */
|
|
176
|
+
/* @__PURE__ */ jsx8("div", { children: /* @__PURE__ */ jsx8("ul", { className: "list-disc pl-6 space-y-3 text-gray-700", children: lines.map((line, index) => /* @__PURE__ */ jsx8("li", { className: "m-0", children: line }, index)) }) })
|
|
393
177
|
] });
|
|
394
178
|
};
|
|
395
179
|
var AiGeneratedSummary_default = AiGeneratedSummary;
|
|
396
180
|
|
|
397
181
|
// src/components/controls/view/ViewControl.tsx
|
|
398
|
-
import { jsx as
|
|
182
|
+
import { jsx as jsx9 } from "react/jsx-runtime";
|
|
399
183
|
var ViewControl = (props) => {
|
|
400
184
|
const ControlComponents = {
|
|
401
185
|
[ViewControlTypes_default.lineText]: LineTextView_default,
|
|
@@ -417,16 +201,16 @@ var ViewControl = (props) => {
|
|
|
417
201
|
[ViewControlTypes_default.aiGeneratedSummary]: AiGeneratedSummary_default
|
|
418
202
|
};
|
|
419
203
|
const SelectedControlComponent = props.controlType ? ControlComponents[props.controlType] : void 0;
|
|
420
|
-
return /* @__PURE__ */
|
|
204
|
+
return /* @__PURE__ */ jsx9(React9.Fragment, { children: SelectedControlComponent ? /* @__PURE__ */ jsx9(SelectedControlComponent, { ...props }) : "Control not found:" + props.controlType });
|
|
421
205
|
};
|
|
422
206
|
var ViewControl_default = ViewControl;
|
|
423
207
|
|
|
424
208
|
// src/components/controls/edit/InputControl.tsx
|
|
425
|
-
import
|
|
209
|
+
import React27 from "react";
|
|
426
210
|
|
|
427
211
|
// src/components/controls/edit/MultilineTextInput.tsx
|
|
428
|
-
import
|
|
429
|
-
import { jsx as
|
|
212
|
+
import React10 from "react";
|
|
213
|
+
import { jsx as jsx10, jsxs as jsxs5 } from "react/jsx-runtime";
|
|
430
214
|
var MultilineTextInput = (props) => {
|
|
431
215
|
const textChangeHandler = (event) => {
|
|
432
216
|
const text = event.target.value;
|
|
@@ -445,11 +229,11 @@ var MultilineTextInput = (props) => {
|
|
|
445
229
|
if (props.value !== void 0 && props.value !== null) {
|
|
446
230
|
value = props.value;
|
|
447
231
|
}
|
|
448
|
-
return /* @__PURE__ */
|
|
449
|
-
/* @__PURE__ */
|
|
232
|
+
return /* @__PURE__ */ jsx10(React10.Fragment, { children: /* @__PURE__ */ jsxs5("label", { className: "block mb-1", children: [
|
|
233
|
+
/* @__PURE__ */ jsx10("span", { className: "text-sm font-medium ", children: props?.attributes?.label }),
|
|
450
234
|
" ",
|
|
451
|
-
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */
|
|
452
|
-
/* @__PURE__ */
|
|
235
|
+
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */ jsx10("span", { className: "bg-error-weak", children: "*" }),
|
|
236
|
+
/* @__PURE__ */ jsx10(
|
|
453
237
|
"textarea",
|
|
454
238
|
{
|
|
455
239
|
name: props.name,
|
|
@@ -466,14 +250,14 @@ var MultilineTextInput = (props) => {
|
|
|
466
250
|
className: "peer mt-1 py-1.5 block w-full rounded shadow-sm input"
|
|
467
251
|
}
|
|
468
252
|
),
|
|
469
|
-
/* @__PURE__ */
|
|
253
|
+
/* @__PURE__ */ jsx10("p", { className: "hidden group-[.validated]:peer-invalid:block mt-1 bg-error-weak text-sm", children: props?.attributes?.errorMessage ? props.attributes.errorMessage : "" })
|
|
470
254
|
] }) });
|
|
471
255
|
};
|
|
472
256
|
var MultilineTextInput_default = MultilineTextInput;
|
|
473
257
|
|
|
474
258
|
// src/components/controls/edit/LineTextInput.tsx
|
|
475
|
-
import
|
|
476
|
-
import { jsx as
|
|
259
|
+
import React11 from "react";
|
|
260
|
+
import { jsx as jsx11, jsxs as jsxs6 } from "react/jsx-runtime";
|
|
477
261
|
var LineTextInput = (props) => {
|
|
478
262
|
const textChangeHandler = (event) => {
|
|
479
263
|
const text = event.target.value;
|
|
@@ -492,11 +276,11 @@ var LineTextInput = (props) => {
|
|
|
492
276
|
if (props.value !== void 0 && props.value !== null) {
|
|
493
277
|
value = props.value;
|
|
494
278
|
}
|
|
495
|
-
return /* @__PURE__ */
|
|
496
|
-
props?.attributes?.label && /* @__PURE__ */
|
|
279
|
+
return /* @__PURE__ */ jsx11(React11.Fragment, { children: /* @__PURE__ */ jsxs6("label", { className: "block", children: [
|
|
280
|
+
props?.attributes?.label && /* @__PURE__ */ jsx11("span", { className: "text-sm inline-block pb-1 font-medium ", children: props?.attributes?.label }),
|
|
497
281
|
" ",
|
|
498
|
-
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */
|
|
499
|
-
/* @__PURE__ */
|
|
282
|
+
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */ jsx11("span", { className: "bg-error-weak", children: "*" }),
|
|
283
|
+
/* @__PURE__ */ jsx11(
|
|
500
284
|
"input",
|
|
501
285
|
{
|
|
502
286
|
type: "text",
|
|
@@ -516,14 +300,14 @@ var LineTextInput = (props) => {
|
|
|
516
300
|
`
|
|
517
301
|
}
|
|
518
302
|
),
|
|
519
|
-
/* @__PURE__ */
|
|
303
|
+
/* @__PURE__ */ jsx11("p", { className: "hidden group-[.validated]:peer-invalid:block mt-1 bg-error-weak text-sm", children: props?.attributes?.errorMessage ? props.attributes.errorMessage : "" })
|
|
520
304
|
] }) });
|
|
521
305
|
};
|
|
522
306
|
var LineTextInput_default = LineTextInput;
|
|
523
307
|
|
|
524
308
|
// src/components/controls/edit/MoneyInput.tsx
|
|
525
|
-
import
|
|
526
|
-
import { jsx as
|
|
309
|
+
import React12 from "react";
|
|
310
|
+
import { jsx as jsx12, jsxs as jsxs7 } from "react/jsx-runtime";
|
|
527
311
|
var MoneyInput = (props) => {
|
|
528
312
|
const textChangeHandler = (event) => {
|
|
529
313
|
const rawValue = event.target.value;
|
|
@@ -552,11 +336,11 @@ var MoneyInput = (props) => {
|
|
|
552
336
|
e.preventDefault();
|
|
553
337
|
}
|
|
554
338
|
};
|
|
555
|
-
return /* @__PURE__ */
|
|
556
|
-
/* @__PURE__ */
|
|
339
|
+
return /* @__PURE__ */ jsx12(React12.Fragment, { children: /* @__PURE__ */ jsxs7("label", { className: "block mb-1", children: [
|
|
340
|
+
/* @__PURE__ */ jsx12("span", { className: "text-sm font-medium ", children: props?.attributes?.label }),
|
|
557
341
|
" ",
|
|
558
|
-
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */
|
|
559
|
-
/* @__PURE__ */
|
|
342
|
+
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */ jsx12("span", { className: "bg-error-weak", children: "*" }),
|
|
343
|
+
/* @__PURE__ */ jsx12(
|
|
560
344
|
"input",
|
|
561
345
|
{
|
|
562
346
|
type: "number",
|
|
@@ -576,7 +360,7 @@ var MoneyInput = (props) => {
|
|
|
576
360
|
className: "peer mt-1 py-1.5 block w-full rounded shadow-sm number-input"
|
|
577
361
|
}
|
|
578
362
|
),
|
|
579
|
-
/* @__PURE__ */
|
|
363
|
+
/* @__PURE__ */ jsx12("p", { className: "hidden group-[.validated]:peer-invalid:block mt-1 bg-error-weak text-sm", children: props?.attributes?.errorMessage ? props.attributes.errorMessage : "" })
|
|
580
364
|
] }) });
|
|
581
365
|
};
|
|
582
366
|
var MoneyInput_default = MoneyInput;
|
|
@@ -608,7 +392,7 @@ var InputControlType_default = InputControlType;
|
|
|
608
392
|
|
|
609
393
|
// src/components/controls/edit/Select.tsx
|
|
610
394
|
import { useState, useEffect } from "react";
|
|
611
|
-
import { jsx as
|
|
395
|
+
import { jsx as jsx13, jsxs as jsxs8 } from "react/jsx-runtime";
|
|
612
396
|
var Select = (props) => {
|
|
613
397
|
const [list, setList] = useState([]);
|
|
614
398
|
const getSafeValue = (val) => {
|
|
@@ -666,11 +450,11 @@ var Select = (props) => {
|
|
|
666
450
|
props.dataSourceDependsOn
|
|
667
451
|
]);
|
|
668
452
|
const value = getSafeValue(props.value);
|
|
669
|
-
return /* @__PURE__ */
|
|
670
|
-
props.attributes?.label && /* @__PURE__ */
|
|
453
|
+
return /* @__PURE__ */ jsxs8("label", { className: "block", children: [
|
|
454
|
+
props.attributes?.label && /* @__PURE__ */ jsx13("span", { className: "text-sm font-medium inline-block pb-1", children: props.attributes?.label }),
|
|
671
455
|
" ",
|
|
672
|
-
props.attributes?.label && props.attributes?.required && /* @__PURE__ */
|
|
673
|
-
/* @__PURE__ */
|
|
456
|
+
props.attributes?.label && props.attributes?.required && /* @__PURE__ */ jsx13("span", { className: "bg-error-weak", children: "*" }),
|
|
457
|
+
/* @__PURE__ */ jsxs8(
|
|
674
458
|
"select",
|
|
675
459
|
{
|
|
676
460
|
name: props.name,
|
|
@@ -681,23 +465,23 @@ var Select = (props) => {
|
|
|
681
465
|
disabled: props.attributes?.readOnly,
|
|
682
466
|
className: "peer select py-1.5 block w-full text-black rounded border-gray-300 shadow-sm\n focus:border-indigo-300 focus:ring focus:ring-indigo-200 focus:ring-opacity-50\n disabled:bg-slate-50 disabled:text-slate-500 disabled:border-slate-200 disabled:shadow-none",
|
|
683
467
|
children: [
|
|
684
|
-
/* @__PURE__ */
|
|
468
|
+
/* @__PURE__ */ jsx13("option", { value: "", children: props.attributes?.placeholder || "Select" }),
|
|
685
469
|
list.map((item, index) => {
|
|
686
470
|
const keyField = props.dataKeyFieldName;
|
|
687
471
|
const textField = props.dataTextFieldName;
|
|
688
|
-
return /* @__PURE__ */
|
|
472
|
+
return /* @__PURE__ */ jsx13("option", { value: item[keyField], children: item[textField] }, index);
|
|
689
473
|
})
|
|
690
474
|
]
|
|
691
475
|
}
|
|
692
476
|
),
|
|
693
|
-
/* @__PURE__ */
|
|
477
|
+
/* @__PURE__ */ jsx13("p", { className: "hidden group-[.validated]:peer-invalid:block mt-1 text-alert text-sm", children: props.attributes?.errorMessage || "" })
|
|
694
478
|
] });
|
|
695
479
|
};
|
|
696
480
|
var Select_default = Select;
|
|
697
481
|
|
|
698
482
|
// src/components/controls/edit/PercentageInput.tsx
|
|
699
|
-
import
|
|
700
|
-
import { jsx as
|
|
483
|
+
import React14 from "react";
|
|
484
|
+
import { jsx as jsx14, jsxs as jsxs9 } from "react/jsx-runtime";
|
|
701
485
|
var PercentageInput = (props) => {
|
|
702
486
|
const textChangeHandler = (event) => {
|
|
703
487
|
const rawValue = event.target.value;
|
|
@@ -726,11 +510,11 @@ var PercentageInput = (props) => {
|
|
|
726
510
|
e.preventDefault();
|
|
727
511
|
}
|
|
728
512
|
};
|
|
729
|
-
return /* @__PURE__ */
|
|
730
|
-
/* @__PURE__ */
|
|
513
|
+
return /* @__PURE__ */ jsx14(React14.Fragment, { children: /* @__PURE__ */ jsxs9("label", { className: "block mb-1", children: [
|
|
514
|
+
/* @__PURE__ */ jsx14("span", { className: "text-sm font-medium ", children: props?.attributes?.label ? props?.attributes?.label + " %" : "" }),
|
|
731
515
|
" ",
|
|
732
|
-
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */
|
|
733
|
-
/* @__PURE__ */
|
|
516
|
+
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */ jsx14("span", { className: "bg-error-weak", children: "*" }),
|
|
517
|
+
/* @__PURE__ */ jsx14(
|
|
734
518
|
"input",
|
|
735
519
|
{
|
|
736
520
|
type: "number",
|
|
@@ -749,14 +533,14 @@ var PercentageInput = (props) => {
|
|
|
749
533
|
className: "peer mt-1 py-1.5 block w-full rounded shadow-sm number-input"
|
|
750
534
|
}
|
|
751
535
|
),
|
|
752
|
-
/* @__PURE__ */
|
|
536
|
+
/* @__PURE__ */ jsx14("p", { className: "hidden group-[.validated]:peer-invalid:block mt-1 bg-error-weak text-sm", children: props?.attributes?.errorMessage ? props.attributes.errorMessage : "" })
|
|
753
537
|
] }) });
|
|
754
538
|
};
|
|
755
539
|
var PercentageInput_default = PercentageInput;
|
|
756
540
|
|
|
757
541
|
// src/components/controls/edit/PhoneInput.tsx
|
|
758
|
-
import
|
|
759
|
-
import { jsx as
|
|
542
|
+
import React15 from "react";
|
|
543
|
+
import { jsx as jsx15, jsxs as jsxs10 } from "react/jsx-runtime";
|
|
760
544
|
var PhoneInput = (props) => {
|
|
761
545
|
const textChangeHandler = (event) => {
|
|
762
546
|
const text = event.target.value;
|
|
@@ -775,13 +559,13 @@ var PhoneInput = (props) => {
|
|
|
775
559
|
if (props.value !== void 0 && props.value !== null) {
|
|
776
560
|
value = props.value;
|
|
777
561
|
}
|
|
778
|
-
return /* @__PURE__ */
|
|
779
|
-
/* @__PURE__ */
|
|
562
|
+
return /* @__PURE__ */ jsx15(React15.Fragment, { children: /* @__PURE__ */ jsxs10("label", { className: "block mb-1", children: [
|
|
563
|
+
/* @__PURE__ */ jsx15("span", { className: "text-sm font-medium ", children: props?.attributes?.label }),
|
|
780
564
|
" ",
|
|
781
|
-
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */
|
|
782
|
-
/* @__PURE__ */
|
|
783
|
-
/* @__PURE__ */
|
|
784
|
-
/* @__PURE__ */
|
|
565
|
+
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */ jsx15("span", { className: "bg-error-weak", children: "*" }),
|
|
566
|
+
/* @__PURE__ */ jsxs10("div", { className: "flex items-center rounded border ", children: [
|
|
567
|
+
/* @__PURE__ */ jsx15("span", { className: "px-3", children: props.prefix }),
|
|
568
|
+
/* @__PURE__ */ jsx15(
|
|
785
569
|
"input",
|
|
786
570
|
{
|
|
787
571
|
type: "text",
|
|
@@ -799,14 +583,14 @@ var PhoneInput = (props) => {
|
|
|
799
583
|
}
|
|
800
584
|
)
|
|
801
585
|
] }),
|
|
802
|
-
/* @__PURE__ */
|
|
586
|
+
/* @__PURE__ */ jsx15("p", { className: "hidden group-[.validated]:peer-invalid:block mt-1 bg-error-weak text-sm", children: props?.attributes?.errorMessage ? props.attributes.errorMessage : "" })
|
|
803
587
|
] }) });
|
|
804
588
|
};
|
|
805
589
|
var PhoneInput_default = PhoneInput;
|
|
806
590
|
|
|
807
591
|
// src/components/controls/edit/NumberInput.tsx
|
|
808
|
-
import
|
|
809
|
-
import { jsx as
|
|
592
|
+
import React16 from "react";
|
|
593
|
+
import { jsx as jsx16, jsxs as jsxs11 } from "react/jsx-runtime";
|
|
810
594
|
var NumberInput = (props) => {
|
|
811
595
|
const textChangeHandler = (event) => {
|
|
812
596
|
const text = event.target.value;
|
|
@@ -829,11 +613,11 @@ var NumberInput = (props) => {
|
|
|
829
613
|
if (props.value !== void 0 && props.value !== null) {
|
|
830
614
|
value = props.value;
|
|
831
615
|
}
|
|
832
|
-
return /* @__PURE__ */
|
|
833
|
-
props?.attributes?.label && /* @__PURE__ */
|
|
616
|
+
return /* @__PURE__ */ jsx16(React16.Fragment, { children: /* @__PURE__ */ jsxs11("label", { className: "block", children: [
|
|
617
|
+
props?.attributes?.label && /* @__PURE__ */ jsx16("span", { className: "text-sm inline-block pb-1 font-medium ", children: props?.attributes?.label }),
|
|
834
618
|
" ",
|
|
835
|
-
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */
|
|
836
|
-
/* @__PURE__ */
|
|
619
|
+
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */ jsx16("span", { className: "bg-error-weak", children: "*" }),
|
|
620
|
+
/* @__PURE__ */ jsx16(
|
|
837
621
|
"input",
|
|
838
622
|
{
|
|
839
623
|
type: "number",
|
|
@@ -852,14 +636,14 @@ var NumberInput = (props) => {
|
|
|
852
636
|
className: "peer py-1.5 block w-full rounded shadow-sm number-input input\n disabled:bg-slate-50 disabled:text-slate-500 disabled:border-slate-200 disabled:shadow-none\n "
|
|
853
637
|
}
|
|
854
638
|
),
|
|
855
|
-
/* @__PURE__ */
|
|
639
|
+
/* @__PURE__ */ jsx16("p", { className: "hidden group-[.validated]:peer-invalid:block mt-1 bg-error-weak text-sm", children: props?.attributes?.errorMessage ? props.attributes.errorMessage : "" })
|
|
856
640
|
] }) });
|
|
857
641
|
};
|
|
858
642
|
var NumberInput_default = NumberInput;
|
|
859
643
|
|
|
860
644
|
// src/components/controls/edit/CheckboxInput.tsx
|
|
861
|
-
import
|
|
862
|
-
import { jsx as
|
|
645
|
+
import React17 from "react";
|
|
646
|
+
import { jsx as jsx17, jsxs as jsxs12 } from "react/jsx-runtime";
|
|
863
647
|
var CheckboxInput = (props) => {
|
|
864
648
|
const textChangeHandler = (event) => {
|
|
865
649
|
let text = event.target.checked;
|
|
@@ -876,11 +660,11 @@ var CheckboxInput = (props) => {
|
|
|
876
660
|
if (props.value != void 0 && props.value != null && props.value != "" && (props.value == "true" || props.value.toString() == "true")) {
|
|
877
661
|
value = true;
|
|
878
662
|
}
|
|
879
|
-
return /* @__PURE__ */
|
|
880
|
-
/* @__PURE__ */
|
|
663
|
+
return /* @__PURE__ */ jsx17(React17.Fragment, { children: /* @__PURE__ */ jsxs12("label", { className: "inline-block mb-1", children: [
|
|
664
|
+
/* @__PURE__ */ jsx17("span", { className: "text-sm font-medium", children: props?.attributes?.label }),
|
|
881
665
|
" ",
|
|
882
|
-
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */
|
|
883
|
-
/* @__PURE__ */
|
|
666
|
+
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */ jsx17("span", { className: "bg-error-weak", children: "*" }),
|
|
667
|
+
/* @__PURE__ */ jsx17(
|
|
884
668
|
"input",
|
|
885
669
|
{
|
|
886
670
|
type: "checkbox",
|
|
@@ -897,14 +681,14 @@ var CheckboxInput = (props) => {
|
|
|
897
681
|
className: "peer mt-1 py-1.5 block rounded shadow-sm\n disabled:bg-slate-50 disabled:text-slate-500 disabled:border-slate-200 disabled:shadow-none\n "
|
|
898
682
|
}
|
|
899
683
|
),
|
|
900
|
-
/* @__PURE__ */
|
|
684
|
+
/* @__PURE__ */ jsx17("p", { className: "hidden group-[.validated]:peer-invalid:block mt-1 bg-error-weak text-sm", children: props?.attributes?.errorMessage ? props.attributes.errorMessage : "" })
|
|
901
685
|
] }) });
|
|
902
686
|
};
|
|
903
687
|
var CheckboxInput_default = CheckboxInput;
|
|
904
688
|
|
|
905
689
|
// src/components/controls/edit/OtpInput.tsx
|
|
906
|
-
import
|
|
907
|
-
import { jsx as
|
|
690
|
+
import React18 from "react";
|
|
691
|
+
import { jsx as jsx18, jsxs as jsxs13 } from "react/jsx-runtime";
|
|
908
692
|
var OtpInput = (props) => {
|
|
909
693
|
const textChangeHandler = (event) => {
|
|
910
694
|
const text = event.target.value;
|
|
@@ -926,11 +710,11 @@ var OtpInput = (props) => {
|
|
|
926
710
|
if (props.value !== void 0 && props.value !== null) {
|
|
927
711
|
value = props.value;
|
|
928
712
|
}
|
|
929
|
-
return /* @__PURE__ */
|
|
930
|
-
/* @__PURE__ */
|
|
713
|
+
return /* @__PURE__ */ jsx18(React18.Fragment, { children: /* @__PURE__ */ jsxs13("label", { htmlFor: props.name, className: "block mb-1 w-full", children: [
|
|
714
|
+
/* @__PURE__ */ jsx18("span", { className: "text-sm font-medium ", children: props?.attributes?.label }),
|
|
931
715
|
" ",
|
|
932
|
-
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */
|
|
933
|
-
/* @__PURE__ */
|
|
716
|
+
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */ jsx18("span", { className: "bg-error-weak", children: "*" }),
|
|
717
|
+
/* @__PURE__ */ jsx18(
|
|
934
718
|
"input",
|
|
935
719
|
{
|
|
936
720
|
type: "text",
|
|
@@ -950,14 +734,14 @@ var OtpInput = (props) => {
|
|
|
950
734
|
className: "peer mt-1 py-1.5 block w-full rounded shadow-sm tracking-[1.25em] text-center"
|
|
951
735
|
}
|
|
952
736
|
),
|
|
953
|
-
/* @__PURE__ */
|
|
737
|
+
/* @__PURE__ */ jsx18("p", { className: "hidden group-[.validated]:peer-invalid:block mt-1 bg-error-weak text-sm", children: props?.attributes?.errorMessage ? props.attributes.errorMessage : "" })
|
|
954
738
|
] }) });
|
|
955
739
|
};
|
|
956
740
|
var OtpInput_default = OtpInput;
|
|
957
741
|
|
|
958
742
|
// src/components/controls/edit/DateTimeInput.tsx
|
|
959
|
-
import
|
|
960
|
-
import { jsx as
|
|
743
|
+
import React19 from "react";
|
|
744
|
+
import { jsx as jsx19, jsxs as jsxs14 } from "react/jsx-runtime";
|
|
961
745
|
var DateTimeInput = (props) => {
|
|
962
746
|
const textChangeHandler = (event) => {
|
|
963
747
|
const localDate = new Date(event.target.value);
|
|
@@ -989,12 +773,12 @@ var DateTimeInput = (props) => {
|
|
|
989
773
|
e.preventDefault();
|
|
990
774
|
}
|
|
991
775
|
};
|
|
992
|
-
return /* @__PURE__ */
|
|
993
|
-
/* @__PURE__ */
|
|
776
|
+
return /* @__PURE__ */ jsx19(React19.Fragment, { children: /* @__PURE__ */ jsxs14("label", { className: "block mb-1", children: [
|
|
777
|
+
/* @__PURE__ */ jsx19("span", { className: "text-sm font-medium ", children: props?.attributes?.label }),
|
|
994
778
|
" ",
|
|
995
|
-
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */
|
|
996
|
-
/* @__PURE__ */
|
|
997
|
-
/* @__PURE__ */
|
|
779
|
+
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */ jsx19("span", { className: "bg-error-weak", children: "*" }),
|
|
780
|
+
/* @__PURE__ */ jsxs14("div", { className: "flex items-center gap-2", children: [
|
|
781
|
+
/* @__PURE__ */ jsx19(
|
|
998
782
|
"input",
|
|
999
783
|
{
|
|
1000
784
|
type: "datetime-local",
|
|
@@ -1012,18 +796,18 @@ var DateTimeInput = (props) => {
|
|
|
1012
796
|
className: "peer mt-1 py-1.5 block w-full rounded shadow-sm\n disabled:bg-slate-50 disabled:text-slate-500 disabled:border-slate-200 disabled:shadow-none\n "
|
|
1013
797
|
}
|
|
1014
798
|
),
|
|
1015
|
-
/* @__PURE__ */
|
|
799
|
+
/* @__PURE__ */ jsx19("span", { children: timeZoneAbbr })
|
|
1016
800
|
] }),
|
|
1017
|
-
/* @__PURE__ */
|
|
801
|
+
/* @__PURE__ */ jsx19("p", { className: "hidden group-[.validated]:peer-invalid:block mt-1 bg-error-weak text-sm", children: props?.attributes?.errorMessage ? props.attributes.errorMessage : "" })
|
|
1018
802
|
] }) });
|
|
1019
803
|
};
|
|
1020
804
|
var DateTimeInput_default = DateTimeInput;
|
|
1021
805
|
|
|
1022
806
|
// src/components/controls/edit/ColorInput.tsx
|
|
1023
|
-
import
|
|
1024
|
-
import { jsx as
|
|
807
|
+
import React20, { useEffect as useEffect2 } from "react";
|
|
808
|
+
import { jsx as jsx20, jsxs as jsxs15 } from "react/jsx-runtime";
|
|
1025
809
|
var ColorInput = (props) => {
|
|
1026
|
-
const [color, setColor] =
|
|
810
|
+
const [color, setColor] = React20.useState("#3b82f6");
|
|
1027
811
|
useEffect2(() => {
|
|
1028
812
|
if (props.value !== void 0 && props.value !== null) {
|
|
1029
813
|
if (typeof props.value === "string") {
|
|
@@ -1043,11 +827,11 @@ var ColorInput = (props) => {
|
|
|
1043
827
|
});
|
|
1044
828
|
}
|
|
1045
829
|
};
|
|
1046
|
-
return /* @__PURE__ */
|
|
1047
|
-
/* @__PURE__ */
|
|
830
|
+
return /* @__PURE__ */ jsxs15("label", { className: "block mb-1", children: [
|
|
831
|
+
/* @__PURE__ */ jsx20("span", { className: "text-sm font-medium", children: props?.attributes?.label }),
|
|
1048
832
|
" ",
|
|
1049
|
-
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */
|
|
1050
|
-
/* @__PURE__ */
|
|
833
|
+
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */ jsx20("span", { className: "bg-error-weak", children: "*" }),
|
|
834
|
+
/* @__PURE__ */ jsx20(
|
|
1051
835
|
"input",
|
|
1052
836
|
{
|
|
1053
837
|
type: "color",
|
|
@@ -1060,14 +844,14 @@ var ColorInput = (props) => {
|
|
|
1060
844
|
className: `w-[78px] h-12 block cursor-pointer`
|
|
1061
845
|
}
|
|
1062
846
|
),
|
|
1063
|
-
props?.attributes?.errorMessage && /* @__PURE__ */
|
|
847
|
+
props?.attributes?.errorMessage && /* @__PURE__ */ jsx20("p", { className: "mt-1 bg-error-weak text-sm", children: props.attributes.errorMessage })
|
|
1064
848
|
] });
|
|
1065
849
|
};
|
|
1066
850
|
var ColorInput_default = ColorInput;
|
|
1067
851
|
|
|
1068
852
|
// src/components/controls/edit/SelectWithSearchInput.tsx
|
|
1069
853
|
import { useEffect as useEffect3, useRef, useState as useState2 } from "react";
|
|
1070
|
-
import { jsx as
|
|
854
|
+
import { jsx as jsx21, jsxs as jsxs16 } from "react/jsx-runtime";
|
|
1071
855
|
var SelectWithSearchInput = (props) => {
|
|
1072
856
|
const [isOpen, setIsOpen] = useState2(false);
|
|
1073
857
|
const [searchTerm, setSearchTerm] = useState2("");
|
|
@@ -1138,15 +922,15 @@ var SelectWithSearchInput = (props) => {
|
|
|
1138
922
|
});
|
|
1139
923
|
}
|
|
1140
924
|
}, [highlightedIndex]);
|
|
1141
|
-
return /* @__PURE__ */
|
|
1142
|
-
/* @__PURE__ */
|
|
925
|
+
return /* @__PURE__ */ jsxs16("div", { className: "relative", children: [
|
|
926
|
+
/* @__PURE__ */ jsxs16("label", { children: [
|
|
1143
927
|
props.attributes?.label,
|
|
1144
928
|
" ",
|
|
1145
929
|
" ",
|
|
1146
|
-
props?.attributes?.required && /* @__PURE__ */
|
|
930
|
+
props?.attributes?.required && /* @__PURE__ */ jsx21("span", { className: "bg-error-weak", children: "*" })
|
|
1147
931
|
] }),
|
|
1148
|
-
/* @__PURE__ */
|
|
1149
|
-
/* @__PURE__ */
|
|
932
|
+
/* @__PURE__ */ jsxs16("div", { className: "relative", children: [
|
|
933
|
+
/* @__PURE__ */ jsx21(
|
|
1150
934
|
"input",
|
|
1151
935
|
{
|
|
1152
936
|
type: "text",
|
|
@@ -1162,13 +946,13 @@ var SelectWithSearchInput = (props) => {
|
|
|
1162
946
|
className: "peer py-1.5 select block w-full text-black rounded border-gray-300 shadow-sm\n focus:border-indigo-300 focus:ring focus:ring-indigo-200 focus:ring-opacity-50\n disabled:bg-slate-50 disabled:text-slate-500 disabled:border-slate-200 disabled:shadow-none\n "
|
|
1163
947
|
}
|
|
1164
948
|
),
|
|
1165
|
-
/* @__PURE__ */
|
|
949
|
+
/* @__PURE__ */ jsx21(
|
|
1166
950
|
"button",
|
|
1167
951
|
{
|
|
1168
952
|
type: "button",
|
|
1169
953
|
onClick: () => setIsOpen(!isOpen),
|
|
1170
954
|
className: "absolute right-2 top-3 h-5 w-5 text-gray-500 focus:outline-none",
|
|
1171
|
-
children: /* @__PURE__ */
|
|
955
|
+
children: /* @__PURE__ */ jsx21(
|
|
1172
956
|
"svg",
|
|
1173
957
|
{
|
|
1174
958
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -1177,7 +961,7 @@ var SelectWithSearchInput = (props) => {
|
|
|
1177
961
|
strokeWidth: 1.5,
|
|
1178
962
|
stroke: "currentColor",
|
|
1179
963
|
className: "w-full h-full",
|
|
1180
|
-
children: /* @__PURE__ */
|
|
964
|
+
children: /* @__PURE__ */ jsx21(
|
|
1181
965
|
"path",
|
|
1182
966
|
{
|
|
1183
967
|
strokeLinecap: "round",
|
|
@@ -1190,12 +974,12 @@ var SelectWithSearchInput = (props) => {
|
|
|
1190
974
|
}
|
|
1191
975
|
)
|
|
1192
976
|
] }),
|
|
1193
|
-
isOpen && /* @__PURE__ */
|
|
977
|
+
isOpen && /* @__PURE__ */ jsx21(
|
|
1194
978
|
"div",
|
|
1195
979
|
{
|
|
1196
980
|
ref: dropdownRef,
|
|
1197
981
|
className: "absolute z-10 mt-2 w-full bg-white border border-gray-200 rounded-md shadow-lg max-h-48 overflow-y-auto",
|
|
1198
|
-
children: filteredItems.length > 0 ? filteredItems.map((item, index) => /* @__PURE__ */
|
|
982
|
+
children: filteredItems.length > 0 ? filteredItems.map((item, index) => /* @__PURE__ */ jsx21(
|
|
1199
983
|
"button",
|
|
1200
984
|
{
|
|
1201
985
|
onClick: (e) => handleSelect(e, item),
|
|
@@ -1203,10 +987,10 @@ var SelectWithSearchInput = (props) => {
|
|
|
1203
987
|
role: "option",
|
|
1204
988
|
tabIndex: -1,
|
|
1205
989
|
onMouseEnter: () => setHighlightedIndex(index),
|
|
1206
|
-
children: /* @__PURE__ */
|
|
990
|
+
children: /* @__PURE__ */ jsx21("span", { children: item[props.dataTextFieldName] })
|
|
1207
991
|
},
|
|
1208
992
|
item[props.dataKeyFieldName]
|
|
1209
|
-
)) : /* @__PURE__ */
|
|
993
|
+
)) : /* @__PURE__ */ jsx21("div", { className: "px-4 py-2 text-gray-500", children: "No results found" })
|
|
1210
994
|
}
|
|
1211
995
|
)
|
|
1212
996
|
] });
|
|
@@ -1214,13 +998,13 @@ var SelectWithSearchInput = (props) => {
|
|
|
1214
998
|
var SelectWithSearchInput_default = SelectWithSearchInput;
|
|
1215
999
|
|
|
1216
1000
|
// src/components/controls/edit/SelectWithSearchPanel.tsx
|
|
1217
|
-
import
|
|
1001
|
+
import React22, {
|
|
1218
1002
|
useEffect as useEffect4,
|
|
1219
1003
|
useRef as useRef2,
|
|
1220
1004
|
useState as useState3,
|
|
1221
1005
|
useCallback
|
|
1222
1006
|
} from "react";
|
|
1223
|
-
import { jsx as
|
|
1007
|
+
import { jsx as jsx22, jsxs as jsxs17 } from "react/jsx-runtime";
|
|
1224
1008
|
var SelectWithSearchPanel = (props) => {
|
|
1225
1009
|
const [isOpen, setIsOpen] = useState3(false);
|
|
1226
1010
|
const [searchTerm, setSearchTerm] = useState3("");
|
|
@@ -1356,14 +1140,14 @@ var SelectWithSearchPanel = (props) => {
|
|
|
1356
1140
|
console.log("Form Data:", formData);
|
|
1357
1141
|
return formData;
|
|
1358
1142
|
}, []);
|
|
1359
|
-
return /* @__PURE__ */
|
|
1360
|
-
/* @__PURE__ */
|
|
1143
|
+
return /* @__PURE__ */ jsxs17("div", { className: "relative", children: [
|
|
1144
|
+
/* @__PURE__ */ jsxs17("label", { className: "text-sm mb-1 font-medium", children: [
|
|
1361
1145
|
props.attributes?.label,
|
|
1362
1146
|
" ",
|
|
1363
1147
|
" ",
|
|
1364
|
-
props?.attributes?.required && /* @__PURE__ */
|
|
1148
|
+
props?.attributes?.required && /* @__PURE__ */ jsx22("span", { className: "bg-error-weak", children: "*" })
|
|
1365
1149
|
] }),
|
|
1366
|
-
/* @__PURE__ */
|
|
1150
|
+
/* @__PURE__ */ jsx22("div", { children: /* @__PURE__ */ jsx22(
|
|
1367
1151
|
"input",
|
|
1368
1152
|
{
|
|
1369
1153
|
type: "text",
|
|
@@ -1377,14 +1161,14 @@ var SelectWithSearchPanel = (props) => {
|
|
|
1377
1161
|
disabled:bg-slate-50 disabled:text-slate-500 disabled:border-slate-200 disabled:shadow-none`
|
|
1378
1162
|
}
|
|
1379
1163
|
) }),
|
|
1380
|
-
/* @__PURE__ */
|
|
1381
|
-
/* @__PURE__ */
|
|
1382
|
-
/* @__PURE__ */
|
|
1164
|
+
/* @__PURE__ */ jsx22("div", { ref: containerRef, children: isOpen && /* @__PURE__ */ jsxs17(React22.Fragment, { children: [
|
|
1165
|
+
/* @__PURE__ */ jsxs17("div", { className: "fixed z-50 right-0 bg-white top-[62px] w-1/4 border-l border-gray-200", children: [
|
|
1166
|
+
/* @__PURE__ */ jsx22("div", { className: "flex flex-col p-2 bg-accent-950 text-white", children: /* @__PURE__ */ jsxs17("h5", { className: "text-md text-white font-medium", children: [
|
|
1383
1167
|
"Select a",
|
|
1384
1168
|
" ",
|
|
1385
1169
|
props.attributes?.label || props.attributes?.heading
|
|
1386
1170
|
] }) }),
|
|
1387
|
-
/* @__PURE__ */
|
|
1171
|
+
/* @__PURE__ */ jsx22("div", { className: "flex justify-end px-4 border-b py-2 border-gray-200 h-10", children: props.createFields && props.createFields.length > 0 && /* @__PURE__ */ jsx22(
|
|
1388
1172
|
"button",
|
|
1389
1173
|
{
|
|
1390
1174
|
type: "button",
|
|
@@ -1397,12 +1181,12 @@ var SelectWithSearchPanel = (props) => {
|
|
|
1397
1181
|
}
|
|
1398
1182
|
) })
|
|
1399
1183
|
] }),
|
|
1400
|
-
isCreateOpen && /* @__PURE__ */
|
|
1401
|
-
/* @__PURE__ */
|
|
1184
|
+
isCreateOpen && /* @__PURE__ */ jsxs17("div", { className: "fixed right-0 w-1/4 h-full top-[62px] bg-white shadow-lg border-l border-gray-200 z-50", children: [
|
|
1185
|
+
/* @__PURE__ */ jsx22("div", { className: "flex flex-col p-2 bg-accent-950", children: /* @__PURE__ */ jsxs17("h5", { className: "text-md font-medium text-white", children: [
|
|
1402
1186
|
"Create New ",
|
|
1403
1187
|
props.attributes?.label
|
|
1404
1188
|
] }) }),
|
|
1405
|
-
/* @__PURE__ */
|
|
1189
|
+
/* @__PURE__ */ jsx22("div", { className: "flex justify-end px-4 border-b py-2 border-gray-200", children: /* @__PURE__ */ jsx22(
|
|
1406
1190
|
"button",
|
|
1407
1191
|
{
|
|
1408
1192
|
type: "button",
|
|
@@ -1411,10 +1195,10 @@ var SelectWithSearchPanel = (props) => {
|
|
|
1411
1195
|
children: "Close"
|
|
1412
1196
|
}
|
|
1413
1197
|
) }),
|
|
1414
|
-
/* @__PURE__ */
|
|
1415
|
-
props.createFields?.map((field) => /* @__PURE__ */
|
|
1416
|
-
/* @__PURE__ */
|
|
1417
|
-
/* @__PURE__ */
|
|
1198
|
+
/* @__PURE__ */ jsxs17("div", { className: "p-4", children: [
|
|
1199
|
+
props.createFields?.map((field) => /* @__PURE__ */ jsxs17("div", { className: "mb-4", children: [
|
|
1200
|
+
/* @__PURE__ */ jsx22("label", { className: "text-sm mb-1 font-medium block", children: field.label }),
|
|
1201
|
+
/* @__PURE__ */ jsx22(
|
|
1418
1202
|
"input",
|
|
1419
1203
|
{
|
|
1420
1204
|
type: field.type,
|
|
@@ -1430,7 +1214,7 @@ var SelectWithSearchPanel = (props) => {
|
|
|
1430
1214
|
}
|
|
1431
1215
|
)
|
|
1432
1216
|
] }, field.name)),
|
|
1433
|
-
/* @__PURE__ */
|
|
1217
|
+
/* @__PURE__ */ jsxs17(Button_default, { onClick: async () => {
|
|
1434
1218
|
handleSaveModal();
|
|
1435
1219
|
return { isSuccessful: true };
|
|
1436
1220
|
}, className: "w-full", children: [
|
|
@@ -1439,13 +1223,13 @@ var SelectWithSearchPanel = (props) => {
|
|
|
1439
1223
|
] })
|
|
1440
1224
|
] })
|
|
1441
1225
|
] }),
|
|
1442
|
-
/* @__PURE__ */
|
|
1226
|
+
/* @__PURE__ */ jsx22(
|
|
1443
1227
|
"div",
|
|
1444
1228
|
{
|
|
1445
1229
|
ref: listRef,
|
|
1446
1230
|
className: "fixed z-10 right-0 mt-[130px] top-0 w-1/4 bg-white border-l border-gray-200 shadow-lg overflow-y-auto",
|
|
1447
1231
|
style: { height: "calc(100vh - 130px)" },
|
|
1448
|
-
children: filteredItems.length > 0 ? filteredItems.map((item, index) => /* @__PURE__ */
|
|
1232
|
+
children: filteredItems.length > 0 ? filteredItems.map((item, index) => /* @__PURE__ */ jsx22("div", { children: /* @__PURE__ */ jsx22(
|
|
1449
1233
|
"button",
|
|
1450
1234
|
{
|
|
1451
1235
|
onClick: (e) => {
|
|
@@ -1455,9 +1239,9 @@ var SelectWithSearchPanel = (props) => {
|
|
|
1455
1239
|
role: "option",
|
|
1456
1240
|
tabIndex: -1,
|
|
1457
1241
|
onMouseEnter: () => setHighlightedIndex(index),
|
|
1458
|
-
children: /* @__PURE__ */
|
|
1242
|
+
children: /* @__PURE__ */ jsx22("span", { children: getNestedValue3(item, props.dataTextFieldName) })
|
|
1459
1243
|
}
|
|
1460
|
-
) }, item[props.dataKeyFieldName])) : /* @__PURE__ */
|
|
1244
|
+
) }, item[props.dataKeyFieldName])) : /* @__PURE__ */ jsx22("div", { className: "px-4 py-2 text-gray-500", children: "No results found" })
|
|
1461
1245
|
}
|
|
1462
1246
|
)
|
|
1463
1247
|
] }) })
|
|
@@ -1466,11 +1250,11 @@ var SelectWithSearchPanel = (props) => {
|
|
|
1466
1250
|
var SelectWithSearchPanel_default = SelectWithSearchPanel;
|
|
1467
1251
|
|
|
1468
1252
|
// src/components/controls/edit/BooleanSelect.tsx
|
|
1469
|
-
import
|
|
1253
|
+
import React23, {
|
|
1470
1254
|
useState as useState4,
|
|
1471
1255
|
useEffect as useEffect5
|
|
1472
1256
|
} from "react";
|
|
1473
|
-
import { jsx as
|
|
1257
|
+
import { jsx as jsx23, jsxs as jsxs18 } from "react/jsx-runtime";
|
|
1474
1258
|
var BooleanSelect = (props) => {
|
|
1475
1259
|
const [list, setList] = useState4();
|
|
1476
1260
|
const textChangeHandler = (event) => {
|
|
@@ -1519,11 +1303,11 @@ var BooleanSelect = (props) => {
|
|
|
1519
1303
|
if (props.value !== void 0 && props.value !== null) {
|
|
1520
1304
|
value = props.value;
|
|
1521
1305
|
}
|
|
1522
|
-
return /* @__PURE__ */
|
|
1523
|
-
/* @__PURE__ */
|
|
1306
|
+
return /* @__PURE__ */ jsx23(React23.Fragment, { children: /* @__PURE__ */ jsxs18("label", { className: "block", children: [
|
|
1307
|
+
/* @__PURE__ */ jsx23("span", { className: "text-sm font-medium ", children: props?.attributes?.label }),
|
|
1524
1308
|
" ",
|
|
1525
|
-
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */
|
|
1526
|
-
/* @__PURE__ */
|
|
1309
|
+
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */ jsx23("span", { className: "bg-error-weak", children: "*" }),
|
|
1310
|
+
/* @__PURE__ */ jsxs18(
|
|
1527
1311
|
"select",
|
|
1528
1312
|
{
|
|
1529
1313
|
name: props.name,
|
|
@@ -1535,9 +1319,9 @@ var BooleanSelect = (props) => {
|
|
|
1535
1319
|
disabled: props?.attributes?.readOnly,
|
|
1536
1320
|
className: "peer mt-1 py-1.5 block w-full text-black rounded shadow-sm\n disabled:bg-slate-50 disabled:text-slate-500 disabled:border-slate-200 disabled:shadow-none\n ",
|
|
1537
1321
|
children: [
|
|
1538
|
-
/* @__PURE__ */
|
|
1322
|
+
/* @__PURE__ */ jsx23("option", { className: "", value: "", children: props.attributes?.placeholder || "Select" }),
|
|
1539
1323
|
list && list.map((item, i) => {
|
|
1540
|
-
return /* @__PURE__ */
|
|
1324
|
+
return /* @__PURE__ */ jsx23(
|
|
1541
1325
|
"option",
|
|
1542
1326
|
{
|
|
1543
1327
|
className: "fac-select-option",
|
|
@@ -1550,14 +1334,14 @@ var BooleanSelect = (props) => {
|
|
|
1550
1334
|
]
|
|
1551
1335
|
}
|
|
1552
1336
|
),
|
|
1553
|
-
/* @__PURE__ */
|
|
1337
|
+
/* @__PURE__ */ jsx23("p", { className: "hidden group-[.validated]:peer-invalid:block mt-1 bg-error-weak text-sm", children: props?.attributes?.errorMessage ? props.attributes.errorMessage : "" })
|
|
1554
1338
|
] }) });
|
|
1555
1339
|
};
|
|
1556
1340
|
var BooleanSelect_default = BooleanSelect;
|
|
1557
1341
|
|
|
1558
1342
|
// src/components/controls/edit/EmailInput.tsx
|
|
1559
|
-
import
|
|
1560
|
-
import { jsx as
|
|
1343
|
+
import React24 from "react";
|
|
1344
|
+
import { jsx as jsx24, jsxs as jsxs19 } from "react/jsx-runtime";
|
|
1561
1345
|
var EmailInput = (props) => {
|
|
1562
1346
|
const textChangeHandler = (event) => {
|
|
1563
1347
|
const text = event.target.value;
|
|
@@ -1582,11 +1366,11 @@ var EmailInput = (props) => {
|
|
|
1582
1366
|
if (props.value !== void 0 && props.value !== null) {
|
|
1583
1367
|
value = props.value;
|
|
1584
1368
|
}
|
|
1585
|
-
return /* @__PURE__ */
|
|
1586
|
-
/* @__PURE__ */
|
|
1369
|
+
return /* @__PURE__ */ jsx24(React24.Fragment, { children: /* @__PURE__ */ jsxs19("label", { className: "block mb-1", children: [
|
|
1370
|
+
/* @__PURE__ */ jsx24("span", { className: "text-sm font-medium text-slate-700", children: props?.attributes?.label }),
|
|
1587
1371
|
" ",
|
|
1588
|
-
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */
|
|
1589
|
-
/* @__PURE__ */
|
|
1372
|
+
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */ jsx24("span", { className: "bg-error-weak", children: "*" }),
|
|
1373
|
+
/* @__PURE__ */ jsx24(
|
|
1590
1374
|
"input",
|
|
1591
1375
|
{
|
|
1592
1376
|
type: "email",
|
|
@@ -1602,14 +1386,14 @@ var EmailInput = (props) => {
|
|
|
1602
1386
|
className: "peer mt-1 py-1.5 block w-full rounded shadow-sm\n transition-all duration-500 ease-in-out"
|
|
1603
1387
|
}
|
|
1604
1388
|
),
|
|
1605
|
-
/* @__PURE__ */
|
|
1389
|
+
/* @__PURE__ */ jsx24("p", { className: "hidden group-[.validated]:peer-invalid:block mt-1 mb-0 bg-error-weak text-sm", children: props?.attributes?.errorMessage ? props.attributes.errorMessage : "" })
|
|
1606
1390
|
] }) });
|
|
1607
1391
|
};
|
|
1608
1392
|
var EmailInput_default = EmailInput;
|
|
1609
1393
|
|
|
1610
1394
|
// src/components/controls/edit/TimeInput.tsx
|
|
1611
|
-
import
|
|
1612
|
-
import { jsx as
|
|
1395
|
+
import React25 from "react";
|
|
1396
|
+
import { jsx as jsx25, jsxs as jsxs20 } from "react/jsx-runtime";
|
|
1613
1397
|
var TimeInput = (props) => {
|
|
1614
1398
|
const timeChangeHandler = (event) => {
|
|
1615
1399
|
const timeValue = event.target.value;
|
|
@@ -1622,11 +1406,11 @@ var TimeInput = (props) => {
|
|
|
1622
1406
|
});
|
|
1623
1407
|
}
|
|
1624
1408
|
};
|
|
1625
|
-
return /* @__PURE__ */
|
|
1626
|
-
/* @__PURE__ */
|
|
1409
|
+
return /* @__PURE__ */ jsx25(React25.Fragment, { children: /* @__PURE__ */ jsxs20("label", { className: "block mb-1", children: [
|
|
1410
|
+
/* @__PURE__ */ jsx25("span", { className: "text-sm font-medium", children: props?.attributes?.label }),
|
|
1627
1411
|
" ",
|
|
1628
|
-
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */
|
|
1629
|
-
/* @__PURE__ */
|
|
1412
|
+
props?.attributes?.label && props?.attributes?.required && /* @__PURE__ */ jsx25("span", { className: "bg-error-weak", children: "*" }),
|
|
1413
|
+
/* @__PURE__ */ jsx25("div", { className: "flex items-center gap-2", children: /* @__PURE__ */ jsx25(
|
|
1630
1414
|
"input",
|
|
1631
1415
|
{
|
|
1632
1416
|
type: "time",
|
|
@@ -1639,13 +1423,13 @@ var TimeInput = (props) => {
|
|
|
1639
1423
|
className: "peer mt-1 py-1.5 block w-full rounded shadow-sm\n disabled:bg-slate-50 disabled:text-slate-500 disabled:border-slate-200 disabled:shadow-none"
|
|
1640
1424
|
}
|
|
1641
1425
|
) }),
|
|
1642
|
-
/* @__PURE__ */
|
|
1426
|
+
/* @__PURE__ */ jsx25("p", { className: "hidden group-[.validated]:peer-invalid:block mt-1 bg-error-weak text-sm", children: props?.attributes?.errorMessage ?? "" })
|
|
1643
1427
|
] }) });
|
|
1644
1428
|
};
|
|
1645
1429
|
var TimeInput_default = TimeInput;
|
|
1646
1430
|
|
|
1647
1431
|
// src/components/controls/edit/AssetUpload.tsx
|
|
1648
|
-
import
|
|
1432
|
+
import React26, { useEffect as useEffect6 } from "react";
|
|
1649
1433
|
|
|
1650
1434
|
// src/components/utilities/AssetUtility.tsx
|
|
1651
1435
|
var AssetUtility = class {
|
|
@@ -1670,7 +1454,7 @@ var AssetUtility_default = AssetUtility;
|
|
|
1670
1454
|
|
|
1671
1455
|
// src/components/dataForm/Hyperlink.tsx
|
|
1672
1456
|
import Link from "next/link";
|
|
1673
|
-
import { Fragment, jsx as
|
|
1457
|
+
import { Fragment, jsx as jsx26 } from "react/jsx-runtime";
|
|
1674
1458
|
function Hyperlink(props) {
|
|
1675
1459
|
let linkClass = props.linkType ? buttonClasses.get(props.linkType) : buttonClasses.get("Link" /* Link */);
|
|
1676
1460
|
const target = props?.href?.startsWith("http") ? "_blank" : "_self";
|
|
@@ -1678,7 +1462,7 @@ function Hyperlink(props) {
|
|
|
1678
1462
|
if (target == "_blank") {
|
|
1679
1463
|
additionalProps.rel = "noopener noreferrer";
|
|
1680
1464
|
}
|
|
1681
|
-
return /* @__PURE__ */
|
|
1465
|
+
return /* @__PURE__ */ jsx26(Fragment, { children: props.href ? /* @__PURE__ */ jsx26(
|
|
1682
1466
|
Link,
|
|
1683
1467
|
{
|
|
1684
1468
|
href: props.href,
|
|
@@ -1688,34 +1472,34 @@ function Hyperlink(props) {
|
|
|
1688
1472
|
target,
|
|
1689
1473
|
children: props.children
|
|
1690
1474
|
}
|
|
1691
|
-
) : props.isHeading ? /* @__PURE__ */
|
|
1475
|
+
) : props.isHeading ? /* @__PURE__ */ jsx26("h5", { className: props.className + "inline-block", children: props.children }) : /* @__PURE__ */ jsx26("span", { className: props.className, children: props.children }) });
|
|
1692
1476
|
}
|
|
1693
1477
|
|
|
1694
1478
|
// src/svg/chevron-updown.tsx
|
|
1695
|
-
import { jsx as
|
|
1479
|
+
import { jsx as jsx27 } from "react/jsx-runtime";
|
|
1696
1480
|
var ChevronUpDown = (props) => {
|
|
1697
|
-
return /* @__PURE__ */
|
|
1481
|
+
return /* @__PURE__ */ jsx27("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", strokeWidth: 1.5, stroke: "currentColor", className: props.className, children: /* @__PURE__ */ jsx27("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M8.25 15L12 18.75 15.75 15m-7.5-6L12 5.25 15.75 9" }) });
|
|
1698
1482
|
};
|
|
1699
1483
|
var chevron_updown_default = ChevronUpDown;
|
|
1700
1484
|
|
|
1701
1485
|
// src/svg/chevron-down.tsx
|
|
1702
|
-
import { jsx as
|
|
1486
|
+
import { jsx as jsx28 } from "react/jsx-runtime";
|
|
1703
1487
|
var ChevronDown = (props) => {
|
|
1704
|
-
return /* @__PURE__ */
|
|
1488
|
+
return /* @__PURE__ */ jsx28("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", strokeWidth: 1.5, stroke: "currentColor", className: props.className, children: /* @__PURE__ */ jsx28("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M19.5 8.25l-7.5 7.5-7.5-7.5" }) });
|
|
1705
1489
|
};
|
|
1706
1490
|
var chevron_down_default = ChevronDown;
|
|
1707
1491
|
|
|
1708
1492
|
// src/svg/chevron-up.tsx
|
|
1709
|
-
import { jsx as
|
|
1493
|
+
import { jsx as jsx29 } from "react/jsx-runtime";
|
|
1710
1494
|
var ChevronUp = (props) => {
|
|
1711
|
-
return /* @__PURE__ */
|
|
1495
|
+
return /* @__PURE__ */ jsx29("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", strokeWidth: 1.5, stroke: "currentColor", className: props.className, children: /* @__PURE__ */ jsx29("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M4.5 15.75l7.5-7.5 7.5 7.5" }) });
|
|
1712
1496
|
};
|
|
1713
1497
|
var chevron_up_default = ChevronUp;
|
|
1714
1498
|
|
|
1715
1499
|
// src/svg/plus.tsx
|
|
1716
|
-
import { jsx as
|
|
1500
|
+
import { jsx as jsx30 } from "react/jsx-runtime";
|
|
1717
1501
|
var Plus = (props) => {
|
|
1718
|
-
return /* @__PURE__ */
|
|
1502
|
+
return /* @__PURE__ */ jsx30("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", strokeWidth: 1.5, stroke: "currentColor", className: props.className, children: /* @__PURE__ */ jsx30("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M12 4.5v15m7.5-7.5h-15" }) });
|
|
1719
1503
|
};
|
|
1720
1504
|
var plus_default = Plus;
|
|
1721
1505
|
|
|
@@ -1729,19 +1513,19 @@ var Icons = {
|
|
|
1729
1513
|
var Icons_default = Icons;
|
|
1730
1514
|
|
|
1731
1515
|
// src/svg/Icon.tsx
|
|
1732
|
-
import { jsx as
|
|
1516
|
+
import { jsx as jsx31 } from "react/jsx-runtime";
|
|
1733
1517
|
var Icon = ({ name, className, ...props }) => {
|
|
1734
1518
|
const IconComponent = Icons_default[name];
|
|
1735
1519
|
if (!IconComponent) {
|
|
1736
1520
|
console.error(`Icon "${name}" not found.`);
|
|
1737
1521
|
return null;
|
|
1738
1522
|
}
|
|
1739
|
-
return /* @__PURE__ */
|
|
1523
|
+
return /* @__PURE__ */ jsx31(IconComponent, { ...props, className });
|
|
1740
1524
|
};
|
|
1741
1525
|
var Icon_default = Icon;
|
|
1742
1526
|
|
|
1743
1527
|
// src/components/controls/edit/AssetUpload.tsx
|
|
1744
|
-
import { jsx as
|
|
1528
|
+
import { jsx as jsx32, jsxs as jsxs21 } from "react/jsx-runtime";
|
|
1745
1529
|
var AssetUpload = (props) => {
|
|
1746
1530
|
const isDisabled = props.attributes?.disable ?? false;
|
|
1747
1531
|
let allValues = [];
|
|
@@ -1762,7 +1546,7 @@ var AssetUpload = (props) => {
|
|
|
1762
1546
|
}
|
|
1763
1547
|
return "image";
|
|
1764
1548
|
};
|
|
1765
|
-
const [assetType, setAssetType] =
|
|
1549
|
+
const [assetType, setAssetType] = React26.useState(getInitialTab);
|
|
1766
1550
|
useEffect6(() => {
|
|
1767
1551
|
setAssetType(getInitialTab());
|
|
1768
1552
|
}, [props.value]);
|
|
@@ -1838,10 +1622,10 @@ var AssetUpload = (props) => {
|
|
|
1838
1622
|
}
|
|
1839
1623
|
return false;
|
|
1840
1624
|
};
|
|
1841
|
-
return /* @__PURE__ */
|
|
1842
|
-
/* @__PURE__ */
|
|
1843
|
-
/* @__PURE__ */
|
|
1844
|
-
/* @__PURE__ */
|
|
1625
|
+
return /* @__PURE__ */ jsxs21(React26.Fragment, { children: [
|
|
1626
|
+
/* @__PURE__ */ jsx32("label", { className: "block mb-1", children: /* @__PURE__ */ jsx32("span", { className: "text-sm font-medium", children: props?.attributes?.label }) }),
|
|
1627
|
+
/* @__PURE__ */ jsxs21("div", { className: "flex gap-6 bg-neutral-100 rounded p-2", children: [
|
|
1628
|
+
/* @__PURE__ */ jsx32(
|
|
1845
1629
|
ClientButton_default,
|
|
1846
1630
|
{
|
|
1847
1631
|
className: assetType === "image" ? "px-2 py-1 rounded bg-body-200 scale-95" : "text-neutral-700",
|
|
@@ -1851,7 +1635,7 @@ var AssetUpload = (props) => {
|
|
|
1851
1635
|
children: "Image Upload"
|
|
1852
1636
|
}
|
|
1853
1637
|
),
|
|
1854
|
-
/* @__PURE__ */
|
|
1638
|
+
/* @__PURE__ */ jsx32(
|
|
1855
1639
|
ClientButton_default,
|
|
1856
1640
|
{
|
|
1857
1641
|
className: assetType === "video" ? "bg-body-200 px-2 py-1 rounded-md scale-95" : "text-neutral-700",
|
|
@@ -1862,13 +1646,13 @@ var AssetUpload = (props) => {
|
|
|
1862
1646
|
}
|
|
1863
1647
|
)
|
|
1864
1648
|
] }),
|
|
1865
|
-
shouldShowDetails() && /* @__PURE__ */
|
|
1866
|
-
/* @__PURE__ */
|
|
1867
|
-
/* @__PURE__ */
|
|
1868
|
-
/* @__PURE__ */
|
|
1869
|
-
/* @__PURE__ */
|
|
1870
|
-
/* @__PURE__ */
|
|
1871
|
-
/* @__PURE__ */
|
|
1649
|
+
shouldShowDetails() && /* @__PURE__ */ jsxs21("div", { className: "relative mt-4 rounded-md p-4 border-2 border-dotted border-gray-300 bg-gray-50", children: [
|
|
1650
|
+
/* @__PURE__ */ jsx32("span", { className: "absolute -top-2.5 left-3 bg-primary-600 text-white text-xs px-2 py-0.5 rounded-full", children: getAssetType(allValues[0]) === "video" ? "Video" : "Image" }),
|
|
1651
|
+
/* @__PURE__ */ jsx32("div", { className: "flex flex-col gap-3", children: allValues.map((digitalAsset, index) => /* @__PURE__ */ jsxs21("div", { className: "flex justify-between items-start gap-5", children: [
|
|
1652
|
+
/* @__PURE__ */ jsxs21("div", { className: "grid grid-cols-2 gap-x-8 gap-y-3 text-sm w-full", children: [
|
|
1653
|
+
/* @__PURE__ */ jsxs21("div", { children: [
|
|
1654
|
+
/* @__PURE__ */ jsx32("p", { className: "text-gray-500", children: "Title" }),
|
|
1655
|
+
/* @__PURE__ */ jsx32(
|
|
1872
1656
|
"input",
|
|
1873
1657
|
{
|
|
1874
1658
|
type: "text",
|
|
@@ -1880,18 +1664,18 @@ var AssetUpload = (props) => {
|
|
|
1880
1664
|
}
|
|
1881
1665
|
)
|
|
1882
1666
|
] }),
|
|
1883
|
-
digitalAsset.intrinsicWidth && digitalAsset.intrinsicHeight && /* @__PURE__ */
|
|
1884
|
-
/* @__PURE__ */
|
|
1885
|
-
/* @__PURE__ */
|
|
1667
|
+
digitalAsset.intrinsicWidth && digitalAsset.intrinsicHeight && /* @__PURE__ */ jsxs21("div", { children: [
|
|
1668
|
+
/* @__PURE__ */ jsx32("p", { className: "text-gray-500", children: "Resolution" }),
|
|
1669
|
+
/* @__PURE__ */ jsxs21("p", { className: "font-medium text-gray-900 mt-3", children: [
|
|
1886
1670
|
digitalAsset.intrinsicWidth,
|
|
1887
1671
|
"\xD7",
|
|
1888
1672
|
digitalAsset.intrinsicHeight
|
|
1889
1673
|
] })
|
|
1890
1674
|
] }),
|
|
1891
|
-
(digitalAsset.assetUrl || digitalAsset.posterUrl) && /* @__PURE__ */
|
|
1892
|
-
/* @__PURE__ */
|
|
1893
|
-
/* @__PURE__ */
|
|
1894
|
-
getAssetType(digitalAsset) === "video" && digitalAsset.posterUrl && /* @__PURE__ */
|
|
1675
|
+
(digitalAsset.assetUrl || digitalAsset.posterUrl) && /* @__PURE__ */ jsxs21("div", { children: [
|
|
1676
|
+
/* @__PURE__ */ jsx32("p", { className: "text-gray-500", children: "Image / Poster" }),
|
|
1677
|
+
/* @__PURE__ */ jsxs21("div", { className: "flex-shrink-0 flex flex-col gap-3 mt-1", children: [
|
|
1678
|
+
getAssetType(digitalAsset) === "video" && digitalAsset.posterUrl && /* @__PURE__ */ jsx32(
|
|
1895
1679
|
"img",
|
|
1896
1680
|
{
|
|
1897
1681
|
src: AssetUtility_default.resolveUrl(props.serviceClient?.baseUrl, digitalAsset.posterUrl),
|
|
@@ -1899,7 +1683,7 @@ var AssetUpload = (props) => {
|
|
|
1899
1683
|
className: "w-32 h-auto object-cover rounded border p-1"
|
|
1900
1684
|
}
|
|
1901
1685
|
),
|
|
1902
|
-
getAssetType(digitalAsset) === "image" && digitalAsset.assetUrl && /* @__PURE__ */
|
|
1686
|
+
getAssetType(digitalAsset) === "image" && digitalAsset.assetUrl && /* @__PURE__ */ jsx32(
|
|
1903
1687
|
"img",
|
|
1904
1688
|
{
|
|
1905
1689
|
src: AssetUtility_default.resolveUrl(props.serviceClient?.baseUrl, digitalAsset.assetUrl),
|
|
@@ -1909,9 +1693,9 @@ var AssetUpload = (props) => {
|
|
|
1909
1693
|
)
|
|
1910
1694
|
] })
|
|
1911
1695
|
] }),
|
|
1912
|
-
digitalAsset.assetUrl?.endsWith(".m3u8") && /* @__PURE__ */
|
|
1913
|
-
/* @__PURE__ */
|
|
1914
|
-
/* @__PURE__ */
|
|
1696
|
+
digitalAsset.assetUrl?.endsWith(".m3u8") && /* @__PURE__ */ jsxs21("div", { className: "col-span-2", children: [
|
|
1697
|
+
/* @__PURE__ */ jsx32("p", { className: "text-gray-500", children: "HLS Link" }),
|
|
1698
|
+
/* @__PURE__ */ jsx32(
|
|
1915
1699
|
Hyperlink,
|
|
1916
1700
|
{
|
|
1917
1701
|
href: digitalAsset.assetUrl,
|
|
@@ -1922,12 +1706,12 @@ var AssetUpload = (props) => {
|
|
|
1922
1706
|
)
|
|
1923
1707
|
] })
|
|
1924
1708
|
] }),
|
|
1925
|
-
/* @__PURE__ */
|
|
1709
|
+
/* @__PURE__ */ jsx32(
|
|
1926
1710
|
"span",
|
|
1927
1711
|
{
|
|
1928
1712
|
onClick: () => !isDisabled && deleteFile(index),
|
|
1929
1713
|
className: isDisabled ? "cursor-not-allowed opacity-50" : "cursor-pointer",
|
|
1930
|
-
children: /* @__PURE__ */
|
|
1714
|
+
children: /* @__PURE__ */ jsx32(Icon_default, { className: "w-4 h-4 text-primary", name: "delete" })
|
|
1931
1715
|
}
|
|
1932
1716
|
)
|
|
1933
1717
|
] }, index)) })
|
|
@@ -1937,8 +1721,8 @@ var AssetUpload = (props) => {
|
|
|
1937
1721
|
var AssetUpload_default = AssetUpload;
|
|
1938
1722
|
|
|
1939
1723
|
// src/components/controls/edit/InputControl.tsx
|
|
1940
|
-
import { jsx as
|
|
1941
|
-
var InputControl =
|
|
1724
|
+
import { jsx as jsx33 } from "react/jsx-runtime";
|
|
1725
|
+
var InputControl = React27.forwardRef(
|
|
1942
1726
|
(props, ref) => {
|
|
1943
1727
|
const ControlComponents = {
|
|
1944
1728
|
[InputControlType_default.lineTextInput]: LineTextInput_default,
|
|
@@ -1960,20 +1744,20 @@ var InputControl = React28.forwardRef(
|
|
|
1960
1744
|
[InputControlType_default.asset]: AssetUpload_default
|
|
1961
1745
|
};
|
|
1962
1746
|
const SelectedControlComponent = ControlComponents[props.controlType];
|
|
1963
|
-
return /* @__PURE__ */
|
|
1747
|
+
return /* @__PURE__ */ jsx33(React27.Fragment, { children: SelectedControlComponent ? /* @__PURE__ */ jsx33(SelectedControlComponent, { ...props }) : "Control not found" });
|
|
1964
1748
|
}
|
|
1965
1749
|
);
|
|
1966
1750
|
InputControl.displayName = "InputControl";
|
|
1967
1751
|
var InputControl_default = InputControl;
|
|
1968
1752
|
|
|
1969
1753
|
// src/components/pageRenderingEngine/PageBodyRenderer.tsx
|
|
1970
|
-
import
|
|
1754
|
+
import React41 from "react";
|
|
1971
1755
|
|
|
1972
1756
|
// src/components/pageRenderingEngine/nodes/ParagraphNode.tsx
|
|
1973
|
-
import
|
|
1757
|
+
import React30 from "react";
|
|
1974
1758
|
|
|
1975
1759
|
// src/components/pageRenderingEngine/nodes/TextNode.tsx
|
|
1976
|
-
import { jsx as
|
|
1760
|
+
import { jsx as jsx34, jsxs as jsxs22 } from "react/jsx-runtime";
|
|
1977
1761
|
var TextNode = (props) => {
|
|
1978
1762
|
function cssStringToJson(cssString) {
|
|
1979
1763
|
const styleObject = {};
|
|
@@ -2031,36 +1815,36 @@ var TextNode = (props) => {
|
|
|
2031
1815
|
});
|
|
2032
1816
|
}
|
|
2033
1817
|
function renderWithLineBreaks(text) {
|
|
2034
|
-
return text.split("\n").map((line, index, arr) => /* @__PURE__ */
|
|
1818
|
+
return text.split("\n").map((line, index, arr) => /* @__PURE__ */ jsxs22("span", { children: [
|
|
2035
1819
|
line,
|
|
2036
|
-
index < arr.length - 1 && /* @__PURE__ */
|
|
1820
|
+
index < arr.length - 1 && /* @__PURE__ */ jsx34("br", {})
|
|
2037
1821
|
] }, index));
|
|
2038
1822
|
}
|
|
2039
1823
|
const displayText = props.linkText ? props.linkText : props.node.text;
|
|
2040
1824
|
const finalText = props.dataitem && props.linkText ? displayText : props.dataitem ? replacePlaceholders(props.node.text, props.dataitem) : props.node.text;
|
|
2041
1825
|
return (
|
|
2042
1826
|
// @ts-expect-error custom code
|
|
2043
|
-
/* @__PURE__ */
|
|
1827
|
+
/* @__PURE__ */ jsx34("span", { style: { ...styles }, className: getFormatClass(props.node.format), children: typeof finalText === "string" ? renderWithLineBreaks(finalText) : finalText })
|
|
2044
1828
|
);
|
|
2045
1829
|
};
|
|
2046
1830
|
var TextNode_default = TextNode;
|
|
2047
1831
|
|
|
2048
1832
|
// src/components/pageRenderingEngine/nodes/LineBreakNode.tsx
|
|
2049
|
-
import { jsx as
|
|
1833
|
+
import { jsx as jsx35 } from "react/jsx-runtime";
|
|
2050
1834
|
var LineBreakNode = () => {
|
|
2051
|
-
return /* @__PURE__ */
|
|
1835
|
+
return /* @__PURE__ */ jsx35("div", { className: "py-0.5 lg:py-1.5" });
|
|
2052
1836
|
};
|
|
2053
1837
|
var LineBreakNode_default = LineBreakNode;
|
|
2054
1838
|
|
|
2055
1839
|
// src/components/pageRenderingEngine/nodes/LinkNode.tsx
|
|
2056
|
-
import
|
|
1840
|
+
import React29 from "react";
|
|
2057
1841
|
|
|
2058
1842
|
// src/components/pageRenderingEngine/nodes/ImageNode.tsx
|
|
2059
|
-
import
|
|
2060
|
-
import
|
|
1843
|
+
import React28 from "react";
|
|
1844
|
+
import dynamic2 from "next/dynamic";
|
|
2061
1845
|
|
|
2062
1846
|
// src/components/DeviceAssetSelector.tsx
|
|
2063
|
-
import { jsx as
|
|
1847
|
+
import { jsx as jsx36 } from "react/jsx-runtime";
|
|
2064
1848
|
var DeviceAssetSelector = ({
|
|
2065
1849
|
assets,
|
|
2066
1850
|
assetBaseUrl,
|
|
@@ -2135,7 +1919,7 @@ var DeviceAssetSelector = ({
|
|
|
2135
1919
|
const formatClasses = FormatClass[nodeProps?.format || ""] || "";
|
|
2136
1920
|
const renderMedia = () => {
|
|
2137
1921
|
if (isHls) {
|
|
2138
|
-
return /* @__PURE__ */
|
|
1922
|
+
return /* @__PURE__ */ jsx36(
|
|
2139
1923
|
HlsPlayer_default,
|
|
2140
1924
|
{
|
|
2141
1925
|
assetUrl: resolvedAssetUrl,
|
|
@@ -2152,7 +1936,7 @@ var DeviceAssetSelector = ({
|
|
|
2152
1936
|
} else {
|
|
2153
1937
|
return (
|
|
2154
1938
|
/* eslint-disable-next-line @next/next/no-img-element */
|
|
2155
|
-
/* @__PURE__ */
|
|
1939
|
+
/* @__PURE__ */ jsx36(
|
|
2156
1940
|
"img",
|
|
2157
1941
|
{
|
|
2158
1942
|
style: styles,
|
|
@@ -2168,18 +1952,18 @@ var DeviceAssetSelector = ({
|
|
|
2168
1952
|
}
|
|
2169
1953
|
};
|
|
2170
1954
|
if (width) {
|
|
2171
|
-
return /* @__PURE__ */
|
|
1955
|
+
return /* @__PURE__ */ jsx36("div", { style: { width }, children: renderMedia() });
|
|
2172
1956
|
}
|
|
2173
1957
|
if (nodeProps?.format) {
|
|
2174
|
-
return /* @__PURE__ */
|
|
1958
|
+
return /* @__PURE__ */ jsx36("div", { className: `flex ${formatClasses}`, children: renderMedia() });
|
|
2175
1959
|
}
|
|
2176
1960
|
return renderMedia();
|
|
2177
1961
|
};
|
|
2178
1962
|
var DeviceAssetSelector_default = DeviceAssetSelector;
|
|
2179
1963
|
|
|
2180
1964
|
// src/components/pageRenderingEngine/nodes/ImageNode.tsx
|
|
2181
|
-
import { Fragment as Fragment2, jsx as
|
|
2182
|
-
var HlsPlayer =
|
|
1965
|
+
import { Fragment as Fragment2, jsx as jsx37 } from "react/jsx-runtime";
|
|
1966
|
+
var HlsPlayer = dynamic2(() => import("./HlsPlayer-GV3FOPYT.mjs"), {
|
|
2183
1967
|
ssr: false
|
|
2184
1968
|
});
|
|
2185
1969
|
var getNestedValue = (obj, path) => {
|
|
@@ -2221,7 +2005,7 @@ var ImageNode = (props) => {
|
|
|
2221
2005
|
console.error("Error parsing assets in ImageNode:", error);
|
|
2222
2006
|
}
|
|
2223
2007
|
if (assets && assets.length > 0) {
|
|
2224
|
-
return /* @__PURE__ */
|
|
2008
|
+
return /* @__PURE__ */ jsx37(Fragment2, { children: /* @__PURE__ */ jsx37(
|
|
2225
2009
|
DeviceAssetSelector_default,
|
|
2226
2010
|
{
|
|
2227
2011
|
device: props.device,
|
|
@@ -2270,7 +2054,7 @@ var ImageNode = (props) => {
|
|
|
2270
2054
|
const isHls = imageUrl?.endsWith(".m3u8");
|
|
2271
2055
|
const renderMedia = () => {
|
|
2272
2056
|
if (isHls) {
|
|
2273
|
-
return /* @__PURE__ */
|
|
2057
|
+
return /* @__PURE__ */ jsx37(
|
|
2274
2058
|
HlsPlayer,
|
|
2275
2059
|
{
|
|
2276
2060
|
assetUrl: imageUrl,
|
|
@@ -2285,7 +2069,7 @@ var ImageNode = (props) => {
|
|
|
2285
2069
|
}
|
|
2286
2070
|
);
|
|
2287
2071
|
} else {
|
|
2288
|
-
return /* @__PURE__ */
|
|
2072
|
+
return /* @__PURE__ */ jsx37(React28.Fragment, { children: /* @__PURE__ */ jsx37(
|
|
2289
2073
|
"img",
|
|
2290
2074
|
{
|
|
2291
2075
|
style: styles,
|
|
@@ -2300,16 +2084,16 @@ var ImageNode = (props) => {
|
|
|
2300
2084
|
}
|
|
2301
2085
|
};
|
|
2302
2086
|
if (props.node.width) {
|
|
2303
|
-
return /* @__PURE__ */
|
|
2087
|
+
return /* @__PURE__ */ jsx37("div", { className: `flex ${formatClasses}`, children: renderMedia() });
|
|
2304
2088
|
}
|
|
2305
2089
|
return renderMedia();
|
|
2306
2090
|
};
|
|
2307
2091
|
var ImageNode_default = ImageNode;
|
|
2308
2092
|
|
|
2309
2093
|
// src/components/pageRenderingEngine/nodes/LinkNode.tsx
|
|
2310
|
-
import
|
|
2311
|
-
import { Fragment as Fragment3, jsx as
|
|
2312
|
-
var LinkNodeButton =
|
|
2094
|
+
import dynamic3 from "next/dynamic";
|
|
2095
|
+
import { Fragment as Fragment3, jsx as jsx38, jsxs as jsxs23 } from "react/jsx-runtime";
|
|
2096
|
+
var LinkNodeButton = dynamic3(() => import("./LinkNodeButton-SSV4NINC.mjs"), {
|
|
2313
2097
|
ssr: false
|
|
2314
2098
|
});
|
|
2315
2099
|
var LinkNode = (props) => {
|
|
@@ -2355,13 +2139,13 @@ var LinkNode = (props) => {
|
|
|
2355
2139
|
const isButton = node.isButton === true;
|
|
2356
2140
|
const renderChildren = () => {
|
|
2357
2141
|
if (!node.children || node.children.length === 0) return null;
|
|
2358
|
-
return /* @__PURE__ */
|
|
2142
|
+
return /* @__PURE__ */ jsx38(Fragment3, { children: node.children.map((childNode, index) => {
|
|
2359
2143
|
const SelectedNode = NodeTypes2[childNode.type];
|
|
2360
2144
|
if (!SelectedNode) {
|
|
2361
2145
|
console.warn("Unknown node type:", childNode.type);
|
|
2362
2146
|
return null;
|
|
2363
2147
|
}
|
|
2364
|
-
return /* @__PURE__ */
|
|
2148
|
+
return /* @__PURE__ */ jsx38(React29.Fragment, { children: /* @__PURE__ */ jsx38(
|
|
2365
2149
|
SelectedNode,
|
|
2366
2150
|
{
|
|
2367
2151
|
node: childNode,
|
|
@@ -2374,15 +2158,15 @@ var LinkNode = (props) => {
|
|
|
2374
2158
|
};
|
|
2375
2159
|
const renderFallback = () => {
|
|
2376
2160
|
if ((!node.children || node.children.length === 0) && linkText) {
|
|
2377
|
-
return /* @__PURE__ */
|
|
2161
|
+
return /* @__PURE__ */ jsx38("span", { children: linkText });
|
|
2378
2162
|
}
|
|
2379
2163
|
if ((!node.children || node.children.length === 0) && !linkText) {
|
|
2380
|
-
return /* @__PURE__ */
|
|
2164
|
+
return /* @__PURE__ */ jsx38("br", {});
|
|
2381
2165
|
}
|
|
2382
2166
|
return null;
|
|
2383
2167
|
};
|
|
2384
2168
|
if (isButton) {
|
|
2385
|
-
return /* @__PURE__ */
|
|
2169
|
+
return /* @__PURE__ */ jsxs23(
|
|
2386
2170
|
LinkNodeButton,
|
|
2387
2171
|
{
|
|
2388
2172
|
node,
|
|
@@ -2400,7 +2184,7 @@ var LinkNode = (props) => {
|
|
|
2400
2184
|
}
|
|
2401
2185
|
);
|
|
2402
2186
|
}
|
|
2403
|
-
return /* @__PURE__ */
|
|
2187
|
+
return /* @__PURE__ */ jsxs23(
|
|
2404
2188
|
Hyperlink,
|
|
2405
2189
|
{
|
|
2406
2190
|
href: linkUrl || "#",
|
|
@@ -2416,10 +2200,10 @@ var LinkNode = (props) => {
|
|
|
2416
2200
|
var LinkNode_default = LinkNode;
|
|
2417
2201
|
|
|
2418
2202
|
// src/components/pageRenderingEngine/nodes/SVGIconNode.tsx
|
|
2419
|
-
import { jsx as
|
|
2203
|
+
import { jsx as jsx39 } from "react/jsx-runtime";
|
|
2420
2204
|
var SVGIconNode = ({ node }) => {
|
|
2421
2205
|
if (!node?.svgCode) return null;
|
|
2422
|
-
return /* @__PURE__ */
|
|
2206
|
+
return /* @__PURE__ */ jsx39(
|
|
2423
2207
|
"span",
|
|
2424
2208
|
{
|
|
2425
2209
|
style: {
|
|
@@ -2436,7 +2220,7 @@ var SVGIconNode_default = SVGIconNode;
|
|
|
2436
2220
|
|
|
2437
2221
|
// src/components/pageRenderingEngine/nodes/EquationNode.tsx
|
|
2438
2222
|
import katex from "katex";
|
|
2439
|
-
import { jsx as
|
|
2223
|
+
import { jsx as jsx40 } from "react/jsx-runtime";
|
|
2440
2224
|
var EquationNode = ({ node }) => {
|
|
2441
2225
|
const { equation, inline } = node;
|
|
2442
2226
|
let html = "";
|
|
@@ -2451,7 +2235,7 @@ var EquationNode = ({ node }) => {
|
|
|
2451
2235
|
});
|
|
2452
2236
|
}
|
|
2453
2237
|
if (inline) {
|
|
2454
|
-
return /* @__PURE__ */
|
|
2238
|
+
return /* @__PURE__ */ jsx40(
|
|
2455
2239
|
"span",
|
|
2456
2240
|
{
|
|
2457
2241
|
className: "katex-inline",
|
|
@@ -2459,7 +2243,7 @@ var EquationNode = ({ node }) => {
|
|
|
2459
2243
|
}
|
|
2460
2244
|
);
|
|
2461
2245
|
}
|
|
2462
|
-
return /* @__PURE__ */
|
|
2246
|
+
return /* @__PURE__ */ jsx40(
|
|
2463
2247
|
"div",
|
|
2464
2248
|
{
|
|
2465
2249
|
className: "katex-block my-3 text-center",
|
|
@@ -2470,7 +2254,7 @@ var EquationNode = ({ node }) => {
|
|
|
2470
2254
|
var EquationNode_default = EquationNode;
|
|
2471
2255
|
|
|
2472
2256
|
// src/components/pageRenderingEngine/nodes/DatafieldNode.tsx
|
|
2473
|
-
import { jsx as
|
|
2257
|
+
import { jsx as jsx41 } from "react/jsx-runtime";
|
|
2474
2258
|
function getNestedProperty(obj, path) {
|
|
2475
2259
|
if (!obj || !path) return null;
|
|
2476
2260
|
if (path.includes(".")) {
|
|
@@ -2483,7 +2267,7 @@ function getNestedProperty(obj, path) {
|
|
|
2483
2267
|
}
|
|
2484
2268
|
const value = obj[path];
|
|
2485
2269
|
if (Array.isArray(value)) {
|
|
2486
|
-
return value.map((item, index) => /* @__PURE__ */
|
|
2270
|
+
return value.map((item, index) => /* @__PURE__ */ jsx41("div", { children: String(item) }, index));
|
|
2487
2271
|
}
|
|
2488
2272
|
return value;
|
|
2489
2273
|
}
|
|
@@ -2544,7 +2328,7 @@ var DatafieldNode = (props) => {
|
|
|
2544
2328
|
const dataType = props.node.dataType;
|
|
2545
2329
|
if (isEmptyValue) return null;
|
|
2546
2330
|
if (dataType === "rawContent") {
|
|
2547
|
-
return /* @__PURE__ */
|
|
2331
|
+
return /* @__PURE__ */ jsx41(
|
|
2548
2332
|
PageBodyRenderer_default,
|
|
2549
2333
|
{
|
|
2550
2334
|
rawBody: String(value ?? `@databound[${fieldName}]`),
|
|
@@ -2560,12 +2344,12 @@ var DatafieldNode = (props) => {
|
|
|
2560
2344
|
}
|
|
2561
2345
|
);
|
|
2562
2346
|
}
|
|
2563
|
-
return /* @__PURE__ */
|
|
2347
|
+
return /* @__PURE__ */ jsx41(
|
|
2564
2348
|
"span",
|
|
2565
2349
|
{
|
|
2566
2350
|
className: `datafield-node ${props.node.format < Formats.length ? Formats[props.node.format] : ""}`,
|
|
2567
2351
|
style: styles,
|
|
2568
|
-
children: /* @__PURE__ */
|
|
2352
|
+
children: /* @__PURE__ */ jsx41(
|
|
2569
2353
|
ViewControl_default,
|
|
2570
2354
|
{
|
|
2571
2355
|
controlType: dataType,
|
|
@@ -2578,7 +2362,7 @@ var DatafieldNode = (props) => {
|
|
|
2578
2362
|
var DatafieldNode_default = DatafieldNode;
|
|
2579
2363
|
|
|
2580
2364
|
// src/components/pageRenderingEngine/nodes/ParagraphNode.tsx
|
|
2581
|
-
import { Fragment as Fragment4, jsx as
|
|
2365
|
+
import { Fragment as Fragment4, jsx as jsx42, jsxs as jsxs24 } from "react/jsx-runtime";
|
|
2582
2366
|
var ParagraphNode = (props) => {
|
|
2583
2367
|
const NodeTypes2 = {
|
|
2584
2368
|
["text"]: TextNode_default,
|
|
@@ -2598,9 +2382,9 @@ var ParagraphNode = (props) => {
|
|
|
2598
2382
|
const isInlineOnlyParent = props.parentTag === "summary";
|
|
2599
2383
|
const hasChildren = props.node.children && props.node.children.length > 0;
|
|
2600
2384
|
if (isInlineOnlyParent) {
|
|
2601
|
-
return /* @__PURE__ */
|
|
2385
|
+
return /* @__PURE__ */ jsx42(Fragment4, { children: hasChildren && props.node.children.map((node, index) => {
|
|
2602
2386
|
const SelectedNode = NodeTypes2[node.type];
|
|
2603
|
-
return /* @__PURE__ */
|
|
2387
|
+
return /* @__PURE__ */ jsx42(React30.Fragment, { children: SelectedNode && /* @__PURE__ */ jsx42(
|
|
2604
2388
|
SelectedNode,
|
|
2605
2389
|
{
|
|
2606
2390
|
node,
|
|
@@ -2612,10 +2396,10 @@ var ParagraphNode = (props) => {
|
|
|
2612
2396
|
) }, index);
|
|
2613
2397
|
}) });
|
|
2614
2398
|
}
|
|
2615
|
-
return /* @__PURE__ */
|
|
2399
|
+
return /* @__PURE__ */ jsxs24("div", { className: " " + formatClasses, children: [
|
|
2616
2400
|
hasChildren && props.node.children.map((node, index) => {
|
|
2617
2401
|
const SelectedNode = NodeTypes2[node.type];
|
|
2618
|
-
return /* @__PURE__ */
|
|
2402
|
+
return /* @__PURE__ */ jsx42(React30.Fragment, { children: SelectedNode && /* @__PURE__ */ jsx42(
|
|
2619
2403
|
SelectedNode,
|
|
2620
2404
|
{
|
|
2621
2405
|
node,
|
|
@@ -2626,14 +2410,14 @@ var ParagraphNode = (props) => {
|
|
|
2626
2410
|
}
|
|
2627
2411
|
) }, index);
|
|
2628
2412
|
}),
|
|
2629
|
-
!hasChildren && /* @__PURE__ */
|
|
2413
|
+
!hasChildren && /* @__PURE__ */ jsx42("div", { className: "py-1.5 lg:py-2" })
|
|
2630
2414
|
] });
|
|
2631
2415
|
};
|
|
2632
2416
|
var ParagraphNode_default = ParagraphNode;
|
|
2633
2417
|
|
|
2634
2418
|
// src/components/pageRenderingEngine/nodes/HeadingNode.tsx
|
|
2635
|
-
import
|
|
2636
|
-
import { Fragment as Fragment5, jsx as
|
|
2419
|
+
import React31 from "react";
|
|
2420
|
+
import { Fragment as Fragment5, jsx as jsx43 } from "react/jsx-runtime";
|
|
2637
2421
|
var HeadingNode = (props) => {
|
|
2638
2422
|
const NodeTypes2 = {
|
|
2639
2423
|
["text"]: TextNode_default,
|
|
@@ -2649,23 +2433,23 @@ var HeadingNode = (props) => {
|
|
|
2649
2433
|
{
|
|
2650
2434
|
}
|
|
2651
2435
|
const formatClasses = FormatClass[props.node.format] || "";
|
|
2652
|
-
return /* @__PURE__ */
|
|
2436
|
+
return /* @__PURE__ */ jsx43(Fragment5, { children: React31.createElement(
|
|
2653
2437
|
HeadingTag,
|
|
2654
2438
|
{ className: formatClasses },
|
|
2655
2439
|
props.node.children && props.node.children.map((childNode, index) => {
|
|
2656
2440
|
const SelectedNode = NodeTypes2[childNode.type];
|
|
2657
|
-
return /* @__PURE__ */
|
|
2441
|
+
return /* @__PURE__ */ jsx43(React31.Fragment, { children: SelectedNode && /* @__PURE__ */ jsx43(SelectedNode, { node: childNode, dataitem: props.dataitem, session: props.session, apiBaseUrl: props.apiBaseUrl, routeParameters: props.routeParameters }) }, index);
|
|
2658
2442
|
})
|
|
2659
2443
|
) });
|
|
2660
2444
|
};
|
|
2661
2445
|
var HeadingNode_default = HeadingNode;
|
|
2662
2446
|
|
|
2663
2447
|
// src/components/pageRenderingEngine/nodes/ListNode.tsx
|
|
2664
|
-
import
|
|
2448
|
+
import React33 from "react";
|
|
2665
2449
|
|
|
2666
2450
|
// src/components/pageRenderingEngine/nodes/ListItemNode.tsx
|
|
2667
|
-
import
|
|
2668
|
-
import { jsx as
|
|
2451
|
+
import React32 from "react";
|
|
2452
|
+
import { jsx as jsx44 } from "react/jsx-runtime";
|
|
2669
2453
|
var ListItemNode = (props) => {
|
|
2670
2454
|
const NodeTypes2 = {
|
|
2671
2455
|
text: TextNode_default,
|
|
@@ -2682,66 +2466,66 @@ var ListItemNode = (props) => {
|
|
|
2682
2466
|
liStyle.fontSize = match[1].trim();
|
|
2683
2467
|
}
|
|
2684
2468
|
}
|
|
2685
|
-
return /* @__PURE__ */
|
|
2469
|
+
return /* @__PURE__ */ jsx44("li", { style: liStyle, children: props.node.children && props.node.children.map((node, index) => {
|
|
2686
2470
|
const SelectedNode = NodeTypes2[node.type];
|
|
2687
2471
|
if (node.type === "linebreak") {
|
|
2688
2472
|
if (!foundFirstBreak) {
|
|
2689
2473
|
foundFirstBreak = true;
|
|
2690
|
-
return /* @__PURE__ */
|
|
2474
|
+
return /* @__PURE__ */ jsx44("div", {}, index);
|
|
2691
2475
|
} else {
|
|
2692
|
-
return /* @__PURE__ */
|
|
2476
|
+
return /* @__PURE__ */ jsx44("div", { className: "py-1 lg:py-2" }, index);
|
|
2693
2477
|
}
|
|
2694
2478
|
} else {
|
|
2695
2479
|
foundFirstBreak = false;
|
|
2696
|
-
return /* @__PURE__ */
|
|
2480
|
+
return /* @__PURE__ */ jsx44(React32.Fragment, { children: SelectedNode && /* @__PURE__ */ jsx44(SelectedNode, { node, dataitem: props.dataitem, routeParameters: props.routeParameters }) }, index);
|
|
2697
2481
|
}
|
|
2698
2482
|
}) });
|
|
2699
2483
|
};
|
|
2700
2484
|
var ListItemNode_default = ListItemNode;
|
|
2701
2485
|
|
|
2702
2486
|
// src/components/pageRenderingEngine/nodes/ListNode.tsx
|
|
2703
|
-
import { jsx as
|
|
2487
|
+
import { jsx as jsx45, jsxs as jsxs25 } from "react/jsx-runtime";
|
|
2704
2488
|
var ListNode = (props) => {
|
|
2705
2489
|
const NodeTypes2 = {
|
|
2706
2490
|
listitem: ListItemNode_default
|
|
2707
2491
|
};
|
|
2708
|
-
return /* @__PURE__ */
|
|
2709
|
-
props.node.listType == "bullet" && /* @__PURE__ */
|
|
2492
|
+
return /* @__PURE__ */ jsxs25(React33.Fragment, { children: [
|
|
2493
|
+
props.node.listType == "bullet" && /* @__PURE__ */ jsx45("ul", { children: props.node.children && props.node.children.map((node, index) => {
|
|
2710
2494
|
const SelectedNode = NodeTypes2[node.type];
|
|
2711
|
-
return /* @__PURE__ */
|
|
2495
|
+
return /* @__PURE__ */ jsx45(React33.Fragment, { children: SelectedNode && /* @__PURE__ */ jsx45(SelectedNode, { node, dataitem: props.dataitem, routeParameters: props.routeParameters }) }, index);
|
|
2712
2496
|
}) }),
|
|
2713
|
-
props.node.listType == "number" && /* @__PURE__ */
|
|
2497
|
+
props.node.listType == "number" && /* @__PURE__ */ jsx45("ol", { children: props.node.children && props.node.children.map((node, index) => {
|
|
2714
2498
|
const SelectedNode = NodeTypes2[node.type];
|
|
2715
|
-
return /* @__PURE__ */
|
|
2499
|
+
return /* @__PURE__ */ jsx45(React33.Fragment, { children: SelectedNode && /* @__PURE__ */ jsx45(SelectedNode, { node, dataitem: props.dataitem, routeParameters: props.routeParameters }) }, index);
|
|
2716
2500
|
}) })
|
|
2717
2501
|
] });
|
|
2718
2502
|
};
|
|
2719
2503
|
var ListNode_default = ListNode;
|
|
2720
2504
|
|
|
2721
2505
|
// src/components/pageRenderingEngine/nodes/QuoteNode.tsx
|
|
2722
|
-
import
|
|
2723
|
-
import { jsx as
|
|
2506
|
+
import React34 from "react";
|
|
2507
|
+
import { jsx as jsx46 } from "react/jsx-runtime";
|
|
2724
2508
|
var QuoteNode = (props) => {
|
|
2725
2509
|
const NodeTypes2 = {
|
|
2726
2510
|
["text"]: TextNode_default,
|
|
2727
2511
|
["linebreak"]: LineBreakNode_default,
|
|
2728
2512
|
["link"]: LinkNode_default
|
|
2729
2513
|
};
|
|
2730
|
-
return /* @__PURE__ */
|
|
2514
|
+
return /* @__PURE__ */ jsx46("blockquote", { children: props.node.children && props.node.children.map((node, index) => {
|
|
2731
2515
|
const SelectedNode = NodeTypes2[node.type];
|
|
2732
|
-
return /* @__PURE__ */
|
|
2516
|
+
return /* @__PURE__ */ jsx46(React34.Fragment, { children: SelectedNode && /* @__PURE__ */ jsx46(SelectedNode, { node, session: props.session, apiBaseUrl: props.apiBaseUrl, routeParameters: props.routeParameters }) }, index);
|
|
2733
2517
|
}) });
|
|
2734
2518
|
};
|
|
2735
2519
|
var QuoteNode_default = QuoteNode;
|
|
2736
2520
|
|
|
2737
2521
|
// src/components/pageRenderingEngine/nodes/CodeNode.tsx
|
|
2738
|
-
import
|
|
2739
|
-
import
|
|
2740
|
-
import { jsx as
|
|
2741
|
-
var CopyButton =
|
|
2522
|
+
import React35 from "react";
|
|
2523
|
+
import dynamic4 from "next/dynamic";
|
|
2524
|
+
import { jsx as jsx47, jsxs as jsxs26 } from "react/jsx-runtime";
|
|
2525
|
+
var CopyButton = dynamic4(() => import("./CopyButton-XONTQQW7.mjs"), {
|
|
2742
2526
|
ssr: false,
|
|
2743
2527
|
// optional: fallback UI while loading
|
|
2744
|
-
loading: () => /* @__PURE__ */
|
|
2528
|
+
loading: () => /* @__PURE__ */ jsx47("span", { className: "text-gray-400 text-xs", children: "Copy" })
|
|
2745
2529
|
});
|
|
2746
2530
|
var CodeNode = (props) => {
|
|
2747
2531
|
const NodeTypes2 = {
|
|
@@ -2755,14 +2539,14 @@ var CodeNode = (props) => {
|
|
|
2755
2539
|
if (node.type === "link") return node.text || node.url || "";
|
|
2756
2540
|
return "";
|
|
2757
2541
|
}).join("") ?? "";
|
|
2758
|
-
return /* @__PURE__ */
|
|
2759
|
-
/* @__PURE__ */
|
|
2760
|
-
/* @__PURE__ */
|
|
2761
|
-
/* @__PURE__ */
|
|
2542
|
+
return /* @__PURE__ */ jsxs26("div", { children: [
|
|
2543
|
+
/* @__PURE__ */ jsxs26("div", { className: "flex items-center relative bg-neutral-strong px-4 py-3 text-xs font-sans justify-between rounded-t-md ", children: [
|
|
2544
|
+
/* @__PURE__ */ jsx47("span", { children: "Code Snippet" }),
|
|
2545
|
+
/* @__PURE__ */ jsx47(CopyButton, { text: textContent })
|
|
2762
2546
|
] }),
|
|
2763
|
-
/* @__PURE__ */
|
|
2547
|
+
/* @__PURE__ */ jsx47("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) => {
|
|
2764
2548
|
const SelectedNode = NodeTypes2[node.type];
|
|
2765
|
-
return /* @__PURE__ */
|
|
2549
|
+
return /* @__PURE__ */ jsx47(React35.Fragment, { children: SelectedNode && /* @__PURE__ */ jsx47(
|
|
2766
2550
|
SelectedNode,
|
|
2767
2551
|
{
|
|
2768
2552
|
node,
|
|
@@ -2777,15 +2561,15 @@ var CodeNode = (props) => {
|
|
|
2777
2561
|
var CodeNode_default = CodeNode;
|
|
2778
2562
|
|
|
2779
2563
|
// src/components/pageRenderingEngine/nodes/HorizontalRuleNode.tsx
|
|
2780
|
-
import { jsx as
|
|
2564
|
+
import { jsx as jsx48 } from "react/jsx-runtime";
|
|
2781
2565
|
var HorizontalRuleNode = () => {
|
|
2782
|
-
return /* @__PURE__ */
|
|
2566
|
+
return /* @__PURE__ */ jsx48("hr", {});
|
|
2783
2567
|
};
|
|
2784
2568
|
var HorizontalRuleNode_default = HorizontalRuleNode;
|
|
2785
2569
|
|
|
2786
2570
|
// src/components/pageRenderingEngine/nodes/WidgetNode.tsx
|
|
2787
|
-
import
|
|
2788
|
-
import { Fragment as Fragment6, jsx as
|
|
2571
|
+
import React36 from "react";
|
|
2572
|
+
import { Fragment as Fragment6, jsx as jsx49 } from "react/jsx-runtime";
|
|
2789
2573
|
var WidgetNode = (props) => {
|
|
2790
2574
|
const getWidgetParameters = () => {
|
|
2791
2575
|
const widgetInputParameters = {
|
|
@@ -2842,7 +2626,7 @@ var WidgetNode = (props) => {
|
|
|
2842
2626
|
};
|
|
2843
2627
|
const widgetCode = props.node?.widgetCode;
|
|
2844
2628
|
if (!widgetCode) {
|
|
2845
|
-
return /* @__PURE__ */
|
|
2629
|
+
return /* @__PURE__ */ jsx49(Fragment6, { children: "Invalid widget" });
|
|
2846
2630
|
}
|
|
2847
2631
|
const widgetParams = getWidgetParameters();
|
|
2848
2632
|
const WidgetRenderer = props.widgetRenderer;
|
|
@@ -2851,7 +2635,7 @@ var WidgetNode = (props) => {
|
|
|
2851
2635
|
}
|
|
2852
2636
|
return (
|
|
2853
2637
|
// eslint-disable-next-line react-hooks/static-components
|
|
2854
|
-
/* @__PURE__ */
|
|
2638
|
+
/* @__PURE__ */ jsx49(React36.Fragment, { children: /* @__PURE__ */ jsx49(
|
|
2855
2639
|
WidgetRenderer,
|
|
2856
2640
|
{
|
|
2857
2641
|
params: widgetParams,
|
|
@@ -2868,12 +2652,12 @@ var WidgetNode = (props) => {
|
|
|
2868
2652
|
var WidgetNode_default = WidgetNode;
|
|
2869
2653
|
|
|
2870
2654
|
// src/components/pageRenderingEngine/nodes/FormContainerNode.tsx
|
|
2871
|
-
import
|
|
2655
|
+
import React37, { useRef as useRef3, useReducer, useCallback as useCallback2, useEffect as useEffect7 } from "react";
|
|
2872
2656
|
|
|
2873
2657
|
// src/components/pageRenderingEngine/nodes/InputControlNode.tsx
|
|
2874
|
-
import { jsx as
|
|
2658
|
+
import { jsx as jsx50 } from "react/jsx-runtime";
|
|
2875
2659
|
var InputControlNode = (props) => {
|
|
2876
|
-
return /* @__PURE__ */
|
|
2660
|
+
return /* @__PURE__ */ jsx50("div", { children: /* @__PURE__ */ jsx50(
|
|
2877
2661
|
InputControl_default,
|
|
2878
2662
|
{
|
|
2879
2663
|
name: props.node.name,
|
|
@@ -2946,7 +2730,7 @@ function FormReducer(state, action) {
|
|
|
2946
2730
|
var FormReducer_default = FormReducer;
|
|
2947
2731
|
|
|
2948
2732
|
// src/components/pageRenderingEngine/nodes/FormContainerNode.tsx
|
|
2949
|
-
import { jsx as
|
|
2733
|
+
import { jsx as jsx51, jsxs as jsxs27 } from "react/jsx-runtime";
|
|
2950
2734
|
var FormContainerNode = (props) => {
|
|
2951
2735
|
const NodeTypes2 = {
|
|
2952
2736
|
["input-control"]: InputControlNode_default
|
|
@@ -2976,12 +2760,12 @@ var FormContainerNode = (props) => {
|
|
|
2976
2760
|
};
|
|
2977
2761
|
fetchInitialData();
|
|
2978
2762
|
}, [props.apiBaseUrl, props.node, props.session, props.routeParameters]);
|
|
2979
|
-
return /* @__PURE__ */
|
|
2763
|
+
return /* @__PURE__ */ jsxs27("form", { className: "group space-y-6 pb-6 overflow-y-auto", noValidate: true, ref: formRef, children: [
|
|
2980
2764
|
node.children && node.children.map((node2, index) => {
|
|
2981
2765
|
{
|
|
2982
2766
|
}
|
|
2983
2767
|
const SelectedNode = NodeTypes2[node2.type];
|
|
2984
|
-
return /* @__PURE__ */
|
|
2768
|
+
return /* @__PURE__ */ jsx51(React37.Fragment, { children: SelectedNode && node2.type == "input-control" && /* @__PURE__ */ jsx51(
|
|
2985
2769
|
InputControlNode_default,
|
|
2986
2770
|
{
|
|
2987
2771
|
value: formState.inputValues[node2.name],
|
|
@@ -2990,18 +2774,18 @@ var FormContainerNode = (props) => {
|
|
|
2990
2774
|
}
|
|
2991
2775
|
) }, index);
|
|
2992
2776
|
}),
|
|
2993
|
-
node.children.length == 0 && /* @__PURE__ */
|
|
2777
|
+
node.children.length == 0 && /* @__PURE__ */ jsx51("div", { className: "py-0.5 lg:py-1.5" })
|
|
2994
2778
|
] });
|
|
2995
2779
|
};
|
|
2996
2780
|
var FormContainerNode_default = FormContainerNode;
|
|
2997
2781
|
|
|
2998
2782
|
// src/components/pageRenderingEngine/nodes/DivContainer.tsx
|
|
2999
|
-
import
|
|
2783
|
+
import React40 from "react";
|
|
3000
2784
|
|
|
3001
2785
|
// src/components/pageRenderingEngine/nodes/EmbedNode.tsx
|
|
3002
|
-
import
|
|
3003
|
-
import { jsx as
|
|
3004
|
-
var IframeClient =
|
|
2786
|
+
import dynamic5 from "next/dynamic";
|
|
2787
|
+
import { jsx as jsx52 } from "react/jsx-runtime";
|
|
2788
|
+
var IframeClient = dynamic5(() => import("./IframeClient-J22NMEVY.mjs"), {
|
|
3005
2789
|
ssr: false
|
|
3006
2790
|
});
|
|
3007
2791
|
var EmbedNode = (props) => {
|
|
@@ -3013,13 +2797,13 @@ var EmbedNode = (props) => {
|
|
|
3013
2797
|
} else {
|
|
3014
2798
|
src = props.node.embedSrc;
|
|
3015
2799
|
}
|
|
3016
|
-
return /* @__PURE__ */
|
|
2800
|
+
return /* @__PURE__ */ jsx52("div", { className: "aspect-video", children: src && /* @__PURE__ */ jsx52(IframeClient, { src }) });
|
|
3017
2801
|
};
|
|
3018
2802
|
var EmbedNode_default = EmbedNode;
|
|
3019
2803
|
|
|
3020
2804
|
// src/components/Slider.tsx
|
|
3021
|
-
import
|
|
3022
|
-
import { Fragment as Fragment7, jsx as
|
|
2805
|
+
import React38, { useState as useState5, useEffect as useEffect8, Children, cloneElement } from "react";
|
|
2806
|
+
import { Fragment as Fragment7, jsx as jsx53, jsxs as jsxs28 } from "react/jsx-runtime";
|
|
3023
2807
|
var Slider = ({
|
|
3024
2808
|
children,
|
|
3025
2809
|
slidesToShow = 4,
|
|
@@ -3113,10 +2897,10 @@ var Slider = ({
|
|
|
3113
2897
|
};
|
|
3114
2898
|
const translateX = -currentSlide * (100 / slidesToShowState);
|
|
3115
2899
|
const slides = Children.map(children, (child, index) => {
|
|
3116
|
-
if (!
|
|
2900
|
+
if (!React38.isValidElement(child)) return null;
|
|
3117
2901
|
const childProps = child.props;
|
|
3118
2902
|
const mergedClassName = `${childProps.className ?? ""} w-full`.trim();
|
|
3119
|
-
return /* @__PURE__ */
|
|
2903
|
+
return /* @__PURE__ */ jsx53(
|
|
3120
2904
|
"div",
|
|
3121
2905
|
{
|
|
3122
2906
|
className: `flex-none ${scaleOnHover ? "group hover:z-50" : ""} relative`,
|
|
@@ -3139,14 +2923,14 @@ var Slider = ({
|
|
|
3139
2923
|
return "bottom-4";
|
|
3140
2924
|
}
|
|
3141
2925
|
};
|
|
3142
|
-
return /* @__PURE__ */
|
|
2926
|
+
return /* @__PURE__ */ jsxs28(
|
|
3143
2927
|
"div",
|
|
3144
2928
|
{
|
|
3145
2929
|
className: `relative w-full overflow-hidden ${className}`,
|
|
3146
2930
|
onMouseEnter: handleMouseEnter,
|
|
3147
2931
|
onMouseLeave: handleMouseLeave,
|
|
3148
2932
|
children: [
|
|
3149
|
-
/* @__PURE__ */
|
|
2933
|
+
/* @__PURE__ */ jsx53(
|
|
3150
2934
|
"div",
|
|
3151
2935
|
{
|
|
3152
2936
|
className: "flex h-full",
|
|
@@ -3157,18 +2941,18 @@ var Slider = ({
|
|
|
3157
2941
|
children: slides
|
|
3158
2942
|
}
|
|
3159
2943
|
),
|
|
3160
|
-
show_arrows && /* @__PURE__ */
|
|
3161
|
-
/* @__PURE__ */
|
|
2944
|
+
show_arrows && /* @__PURE__ */ jsxs28(Fragment7, { children: [
|
|
2945
|
+
/* @__PURE__ */ jsx53(
|
|
3162
2946
|
ArrowButton,
|
|
3163
2947
|
{
|
|
3164
2948
|
direction: "left",
|
|
3165
2949
|
onClick: prevSlide,
|
|
3166
2950
|
visible: infinite_scroll || currentSlide > 0,
|
|
3167
2951
|
className: arrowClassName,
|
|
3168
|
-
children: /* @__PURE__ */
|
|
2952
|
+
children: /* @__PURE__ */ jsx53("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__ */ jsx53("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M15.75 19.5 8.25 12l7.5-7.5" }) })
|
|
3169
2953
|
}
|
|
3170
2954
|
),
|
|
3171
|
-
/* @__PURE__ */
|
|
2955
|
+
/* @__PURE__ */ jsxs28(
|
|
3172
2956
|
ArrowButton,
|
|
3173
2957
|
{
|
|
3174
2958
|
direction: "right",
|
|
@@ -3176,13 +2960,13 @@ var Slider = ({
|
|
|
3176
2960
|
visible: infinite_scroll || currentSlide < maxSlide,
|
|
3177
2961
|
className: arrowClassName,
|
|
3178
2962
|
children: [
|
|
3179
|
-
/* @__PURE__ */
|
|
2963
|
+
/* @__PURE__ */ jsx53("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__ */ jsx53("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "m8.25 4.5 7.5 7.5-7.5 7.5" }) }),
|
|
3180
2964
|
" "
|
|
3181
2965
|
]
|
|
3182
2966
|
}
|
|
3183
2967
|
)
|
|
3184
2968
|
] }),
|
|
3185
|
-
show_dots && /* @__PURE__ */
|
|
2969
|
+
show_dots && /* @__PURE__ */ jsx53("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__ */ jsx53(
|
|
3186
2970
|
ProgressPill,
|
|
3187
2971
|
{
|
|
3188
2972
|
active: index === currentSlide,
|
|
@@ -3208,7 +2992,7 @@ var ArrowButton = ({
|
|
|
3208
2992
|
visible,
|
|
3209
2993
|
children,
|
|
3210
2994
|
className = ""
|
|
3211
|
-
}) => /* @__PURE__ */
|
|
2995
|
+
}) => /* @__PURE__ */ jsx53(
|
|
3212
2996
|
"button",
|
|
3213
2997
|
{
|
|
3214
2998
|
className: `
|
|
@@ -3295,7 +3079,7 @@ var ProgressPill = ({
|
|
|
3295
3079
|
const renderProgressBar = () => {
|
|
3296
3080
|
if (style === "modern" && isActive || style === "cumulative" && shouldShowProgress) {
|
|
3297
3081
|
const displayProgress = style === "cumulative" && isFilled ? 100 : progress;
|
|
3298
|
-
return /* @__PURE__ */
|
|
3082
|
+
return /* @__PURE__ */ jsx53(
|
|
3299
3083
|
"div",
|
|
3300
3084
|
{
|
|
3301
3085
|
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`,
|
|
@@ -3307,7 +3091,7 @@ var ProgressPill = ({
|
|
|
3307
3091
|
};
|
|
3308
3092
|
const renderCumulativeFill = () => {
|
|
3309
3093
|
if (style === "cumulative" && isFilled && !isActive) {
|
|
3310
|
-
return /* @__PURE__ */
|
|
3094
|
+
return /* @__PURE__ */ jsx53(
|
|
3311
3095
|
"div",
|
|
3312
3096
|
{
|
|
3313
3097
|
className: `absolute top-0 left-0 h-full rounded-full ${activeClassName || "bg-white"} transition-all duration-300`,
|
|
@@ -3317,7 +3101,7 @@ var ProgressPill = ({
|
|
|
3317
3101
|
}
|
|
3318
3102
|
return null;
|
|
3319
3103
|
};
|
|
3320
|
-
return /* @__PURE__ */
|
|
3104
|
+
return /* @__PURE__ */ jsxs28(
|
|
3321
3105
|
"button",
|
|
3322
3106
|
{
|
|
3323
3107
|
className: `${baseClasses} ${getStyleClasses()}`,
|
|
@@ -3655,10 +3439,10 @@ var PathUtility = class {
|
|
|
3655
3439
|
var PathUtility_default = new PathUtility();
|
|
3656
3440
|
|
|
3657
3441
|
// src/components/NoDataFound.tsx
|
|
3658
|
-
import { jsx as
|
|
3442
|
+
import { jsx as jsx54, jsxs as jsxs29 } from "react/jsx-runtime";
|
|
3659
3443
|
var NoDataFound = () => {
|
|
3660
|
-
return /* @__PURE__ */
|
|
3661
|
-
/* @__PURE__ */
|
|
3444
|
+
return /* @__PURE__ */ jsxs29("div", { className: "flex flex-col items-center justify-center py-12 px-4 text-center bg-neutral-weak", children: [
|
|
3445
|
+
/* @__PURE__ */ jsx54("div", { className: "mb-5", children: /* @__PURE__ */ jsx54("div", { className: "mx-auto w-20 h-20 rounded-full flex items-center justify-center bg-neutral-soft", children: /* @__PURE__ */ jsx54(
|
|
3662
3446
|
"svg",
|
|
3663
3447
|
{
|
|
3664
3448
|
className: "w-10 h-10",
|
|
@@ -3666,7 +3450,7 @@ var NoDataFound = () => {
|
|
|
3666
3450
|
stroke: "currentColor",
|
|
3667
3451
|
viewBox: "0 0 24 24",
|
|
3668
3452
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3669
|
-
children: /* @__PURE__ */
|
|
3453
|
+
children: /* @__PURE__ */ jsx54(
|
|
3670
3454
|
"path",
|
|
3671
3455
|
{
|
|
3672
3456
|
strokeLinecap: "round",
|
|
@@ -3677,15 +3461,15 @@ var NoDataFound = () => {
|
|
|
3677
3461
|
)
|
|
3678
3462
|
}
|
|
3679
3463
|
) }) }),
|
|
3680
|
-
/* @__PURE__ */
|
|
3681
|
-
/* @__PURE__ */
|
|
3464
|
+
/* @__PURE__ */ jsx54("h3", { className: "text-lg font-medium mb-2", children: "No data available" }),
|
|
3465
|
+
/* @__PURE__ */ jsx54("p", { className: " max-w-sm mb-0", children: "No records found. Data may be empty or not available at the moment." })
|
|
3682
3466
|
] });
|
|
3683
3467
|
};
|
|
3684
3468
|
var NoDataFound_default = NoDataFound;
|
|
3685
3469
|
|
|
3686
3470
|
// src/components/Pagination.tsx
|
|
3687
3471
|
import { useMemo } from "react";
|
|
3688
|
-
import { jsx as
|
|
3472
|
+
import { jsx as jsx55, jsxs as jsxs30 } from "react/jsx-runtime";
|
|
3689
3473
|
var Pagination = (props) => {
|
|
3690
3474
|
const { dataset, path, query, showPageSizeSelector = false, showJumpToPage = false } = props;
|
|
3691
3475
|
const builder = useMemo(() => {
|
|
@@ -3729,7 +3513,7 @@ var Pagination = (props) => {
|
|
|
3729
3513
|
return range;
|
|
3730
3514
|
};
|
|
3731
3515
|
const paginationRange = getPaginationRange();
|
|
3732
|
-
const PageButton = ({ page, children }) => /* @__PURE__ */
|
|
3516
|
+
const PageButton = ({ page, children }) => /* @__PURE__ */ jsx55(
|
|
3733
3517
|
Hyperlink,
|
|
3734
3518
|
{
|
|
3735
3519
|
linkType: "Link" /* Link */,
|
|
@@ -3744,9 +3528,9 @@ var Pagination = (props) => {
|
|
|
3744
3528
|
);
|
|
3745
3529
|
const NavigationButton = ({ page, disabled, children }) => {
|
|
3746
3530
|
if (disabled) {
|
|
3747
|
-
return /* @__PURE__ */
|
|
3531
|
+
return /* @__PURE__ */ jsx55("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 });
|
|
3748
3532
|
}
|
|
3749
|
-
return /* @__PURE__ */
|
|
3533
|
+
return /* @__PURE__ */ jsx55(
|
|
3750
3534
|
Hyperlink,
|
|
3751
3535
|
{
|
|
3752
3536
|
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",
|
|
@@ -3756,35 +3540,35 @@ var Pagination = (props) => {
|
|
|
3756
3540
|
);
|
|
3757
3541
|
};
|
|
3758
3542
|
if (totalPages <= 1 && totalItems === 0) return null;
|
|
3759
|
-
return /* @__PURE__ */
|
|
3760
|
-
/* @__PURE__ */
|
|
3761
|
-
/* @__PURE__ */
|
|
3543
|
+
return /* @__PURE__ */ jsxs30("div", { className: "py-6 border-t bg-default", children: [
|
|
3544
|
+
/* @__PURE__ */ jsxs30("div", { className: "flex flex-col sm:flex-row items-center justify-between gap-4", children: [
|
|
3545
|
+
/* @__PURE__ */ jsxs30("div", { className: "text-sm", children: [
|
|
3762
3546
|
"Showing ",
|
|
3763
|
-
/* @__PURE__ */
|
|
3547
|
+
/* @__PURE__ */ jsxs30("span", { className: "font-semibold", children: [
|
|
3764
3548
|
startItem,
|
|
3765
3549
|
"-",
|
|
3766
3550
|
endItem
|
|
3767
3551
|
] }),
|
|
3768
3552
|
" ",
|
|
3769
3553
|
"out of ",
|
|
3770
|
-
/* @__PURE__ */
|
|
3554
|
+
/* @__PURE__ */ jsx55("span", { className: "font-semibold", children: totalItems.toLocaleString() }),
|
|
3771
3555
|
" results"
|
|
3772
3556
|
] }),
|
|
3773
|
-
totalPages > 1 && /* @__PURE__ */
|
|
3774
|
-
/* @__PURE__ */
|
|
3557
|
+
totalPages > 1 && /* @__PURE__ */ jsxs30("div", { className: "flex items-center space-x-1", children: [
|
|
3558
|
+
/* @__PURE__ */ jsxs30(
|
|
3775
3559
|
NavigationButton,
|
|
3776
3560
|
{
|
|
3777
3561
|
page: activePageNumber - 1,
|
|
3778
3562
|
disabled: activePageNumber === 1,
|
|
3779
3563
|
children: [
|
|
3780
|
-
/* @__PURE__ */
|
|
3781
|
-
/* @__PURE__ */
|
|
3564
|
+
/* @__PURE__ */ jsx55("span", { children: /* @__PURE__ */ jsx55(Icon_default, { name: "chevronLeft", className: "w-4 h-4 mr-1" }) }),
|
|
3565
|
+
/* @__PURE__ */ jsx55("span", { className: "text-sm", children: "Prev" })
|
|
3782
3566
|
]
|
|
3783
3567
|
}
|
|
3784
3568
|
),
|
|
3785
3569
|
paginationRange.map((item, index) => {
|
|
3786
3570
|
if (item === "...") {
|
|
3787
|
-
return /* @__PURE__ */
|
|
3571
|
+
return /* @__PURE__ */ jsx55(
|
|
3788
3572
|
"span",
|
|
3789
3573
|
{
|
|
3790
3574
|
className: "min-w-[20px] md:min-w-[40px] h-10 flex items-center justify-center text-gray-500",
|
|
@@ -3794,23 +3578,23 @@ var Pagination = (props) => {
|
|
|
3794
3578
|
);
|
|
3795
3579
|
}
|
|
3796
3580
|
const page = item;
|
|
3797
|
-
return /* @__PURE__ */
|
|
3581
|
+
return /* @__PURE__ */ jsx55(PageButton, { page, children: page }, page);
|
|
3798
3582
|
}),
|
|
3799
|
-
/* @__PURE__ */
|
|
3583
|
+
/* @__PURE__ */ jsxs30(
|
|
3800
3584
|
NavigationButton,
|
|
3801
3585
|
{
|
|
3802
3586
|
page: activePageNumber + 1,
|
|
3803
3587
|
disabled: activePageNumber === totalPages,
|
|
3804
3588
|
children: [
|
|
3805
|
-
/* @__PURE__ */
|
|
3806
|
-
/* @__PURE__ */
|
|
3589
|
+
/* @__PURE__ */ jsx55("span", { className: "text-sm", children: "Next" }),
|
|
3590
|
+
/* @__PURE__ */ jsx55("span", { children: /* @__PURE__ */ jsx55(Icon_default, { name: "chevronRight", className: "w-4 h-4 ml-1" }) })
|
|
3807
3591
|
]
|
|
3808
3592
|
}
|
|
3809
3593
|
)
|
|
3810
3594
|
] }),
|
|
3811
|
-
showJumpToPage && totalPages > 5 && /* @__PURE__ */
|
|
3812
|
-
/* @__PURE__ */
|
|
3813
|
-
/* @__PURE__ */
|
|
3595
|
+
showJumpToPage && totalPages > 5 && /* @__PURE__ */ jsxs30("div", { className: "flex items-center space-x-2", children: [
|
|
3596
|
+
/* @__PURE__ */ jsx55("span", { className: "text-sm", children: "Go to:" }),
|
|
3597
|
+
/* @__PURE__ */ jsx55("div", { className: "relative", children: /* @__PURE__ */ jsx55(
|
|
3814
3598
|
"input",
|
|
3815
3599
|
{
|
|
3816
3600
|
type: "number",
|
|
@@ -3831,9 +3615,9 @@ var Pagination = (props) => {
|
|
|
3831
3615
|
) })
|
|
3832
3616
|
] })
|
|
3833
3617
|
] }),
|
|
3834
|
-
showPageSizeSelector && /* @__PURE__ */
|
|
3835
|
-
/* @__PURE__ */
|
|
3836
|
-
/* @__PURE__ */
|
|
3618
|
+
showPageSizeSelector && /* @__PURE__ */ jsx55("div", { className: "mt-4 pt-4 border-t bg-default", children: /* @__PURE__ */ jsxs30("div", { className: "flex items-center justify-center space-x-2", children: [
|
|
3619
|
+
/* @__PURE__ */ jsx55("span", { className: "text-sm", children: "Show:" }),
|
|
3620
|
+
/* @__PURE__ */ jsx55("div", { className: "flex space-x-1", children: [10, 25, 50, 100].map((size) => /* @__PURE__ */ jsx55(
|
|
3837
3621
|
Hyperlink,
|
|
3838
3622
|
{
|
|
3839
3623
|
className: `
|
|
@@ -3845,16 +3629,16 @@ var Pagination = (props) => {
|
|
|
3845
3629
|
},
|
|
3846
3630
|
size
|
|
3847
3631
|
)) }),
|
|
3848
|
-
/* @__PURE__ */
|
|
3632
|
+
/* @__PURE__ */ jsx55("span", { className: "text-sm", children: "per page" })
|
|
3849
3633
|
] }) })
|
|
3850
3634
|
] });
|
|
3851
3635
|
};
|
|
3852
3636
|
var Pagination_default = Pagination;
|
|
3853
3637
|
|
|
3854
3638
|
// src/components/pageRenderingEngine/nodes/ImageGalleryNode.tsx
|
|
3855
|
-
import
|
|
3856
|
-
import { Fragment as Fragment8, jsx as
|
|
3857
|
-
var HlsPlayer2 =
|
|
3639
|
+
import dynamic6 from "next/dynamic";
|
|
3640
|
+
import { Fragment as Fragment8, jsx as jsx56, jsxs as jsxs31 } from "react/jsx-runtime";
|
|
3641
|
+
var HlsPlayer2 = dynamic6(() => import("./HlsPlayer-GV3FOPYT.mjs"), { ssr: false });
|
|
3858
3642
|
var deviceToMediaQuery = (device) => {
|
|
3859
3643
|
switch (device) {
|
|
3860
3644
|
case "sm":
|
|
@@ -3922,8 +3706,8 @@ var ImageGalleryNode = (props) => {
|
|
|
3922
3706
|
right: "justify-end"
|
|
3923
3707
|
};
|
|
3924
3708
|
const formatClasses = FormatClass[props.node.format || ""] || "";
|
|
3925
|
-
return /* @__PURE__ */
|
|
3926
|
-
hlsSources.length > 0 && /* @__PURE__ */
|
|
3709
|
+
return /* @__PURE__ */ jsxs31(Fragment8, { children: [
|
|
3710
|
+
hlsSources.length > 0 && /* @__PURE__ */ jsx56(Fragment8, { children: /* @__PURE__ */ jsx56(
|
|
3927
3711
|
HlsPlayer2,
|
|
3928
3712
|
{
|
|
3929
3713
|
sources: hlsSources,
|
|
@@ -3937,14 +3721,14 @@ var ImageGalleryNode = (props) => {
|
|
|
3937
3721
|
session: props.session
|
|
3938
3722
|
}
|
|
3939
3723
|
) }),
|
|
3940
|
-
staticFallback && /* @__PURE__ */
|
|
3724
|
+
staticFallback && /* @__PURE__ */ jsx56(Fragment8, { children: /* @__PURE__ */ jsxs31("picture", { children: [
|
|
3941
3725
|
DEVICE_ORDER.map((deviceKey) => {
|
|
3942
3726
|
const match = staticSources.find((img) => img.device === deviceKey);
|
|
3943
3727
|
if (!match) return null;
|
|
3944
3728
|
const srcUrl = resolveImageUrl(match.imageUrl);
|
|
3945
3729
|
if (!srcUrl) return null;
|
|
3946
3730
|
const mediaQuery = deviceToMediaQuery(match.device);
|
|
3947
|
-
return /* @__PURE__ */
|
|
3731
|
+
return /* @__PURE__ */ jsx56(
|
|
3948
3732
|
"source",
|
|
3949
3733
|
{
|
|
3950
3734
|
media: mediaQuery,
|
|
@@ -3968,7 +3752,7 @@ var ImageGalleryNode = (props) => {
|
|
|
3968
3752
|
if (img.borderRadius) styles.borderRadius = img.borderRadius;
|
|
3969
3753
|
return (
|
|
3970
3754
|
// eslint-disable-next-line @next/next/no-img-element
|
|
3971
|
-
/* @__PURE__ */
|
|
3755
|
+
/* @__PURE__ */ jsx56(
|
|
3972
3756
|
"img",
|
|
3973
3757
|
{
|
|
3974
3758
|
loading: "lazy",
|
|
@@ -3989,7 +3773,7 @@ var ImageGalleryNode_default = ImageGalleryNode;
|
|
|
3989
3773
|
|
|
3990
3774
|
// src/components/pageRenderingEngine/nodes/DivContainer.tsx
|
|
3991
3775
|
import Link2 from "next/link";
|
|
3992
|
-
import { jsx as
|
|
3776
|
+
import { jsx as jsx57, jsxs as jsxs32 } from "react/jsx-runtime";
|
|
3993
3777
|
function toCamelCase(str) {
|
|
3994
3778
|
return str.replace(/-([a-z])/g, (_, letter) => letter.toUpperCase());
|
|
3995
3779
|
}
|
|
@@ -4196,7 +3980,7 @@ var DivContainer = async (props) => {
|
|
|
4196
3980
|
response = await serviceClient.get(endpoint);
|
|
4197
3981
|
result = response?.result;
|
|
4198
3982
|
if (dataBindingProperties.showNoResultsMessage && (result === void 0 || result.length == 0)) {
|
|
4199
|
-
return /* @__PURE__ */
|
|
3983
|
+
return /* @__PURE__ */ jsx57(NoDataFound_default, {});
|
|
4200
3984
|
}
|
|
4201
3985
|
if (dataBindingProperties.childCollectionName && props.dataitem) {
|
|
4202
3986
|
childCollectionData = getNestedValue2(props.dataitem, dataBindingProperties.childCollectionName);
|
|
@@ -4213,7 +3997,7 @@ var DivContainer = async (props) => {
|
|
|
4213
3997
|
}
|
|
4214
3998
|
const SelectedNode = NodeTypes2[node.type];
|
|
4215
3999
|
if (!SelectedNode) return null;
|
|
4216
|
-
return /* @__PURE__ */
|
|
4000
|
+
return /* @__PURE__ */ jsx57(React40.Fragment, { children: /* @__PURE__ */ jsx57(
|
|
4217
4001
|
SelectedNode,
|
|
4218
4002
|
{
|
|
4219
4003
|
node,
|
|
@@ -4315,9 +4099,9 @@ var DivContainer = async (props) => {
|
|
|
4315
4099
|
props.node.autoFormat && "auto-format",
|
|
4316
4100
|
props.node.bgClass
|
|
4317
4101
|
].filter(Boolean).join(" ");
|
|
4318
|
-
return /* @__PURE__ */
|
|
4319
|
-
/* @__PURE__ */
|
|
4320
|
-
/* @__PURE__ */
|
|
4102
|
+
return /* @__PURE__ */ jsxs32(React40.Fragment, { children: [
|
|
4103
|
+
/* @__PURE__ */ jsx57("style", { dangerouslySetInnerHTML: { __html: cssResult.css + animationCSS } }),
|
|
4104
|
+
/* @__PURE__ */ jsx57(React40.Fragment, { children: /* @__PURE__ */ jsx57(
|
|
4321
4105
|
Wrapper,
|
|
4322
4106
|
{
|
|
4323
4107
|
id: guid,
|
|
@@ -4326,18 +4110,18 @@ var DivContainer = async (props) => {
|
|
|
4326
4110
|
...wrapperProps,
|
|
4327
4111
|
children: dataToRender.map(
|
|
4328
4112
|
(item, idx) => item?.links?.view && renderLink ? renderChildren(props.node.children, props, item, idx, props.href ? void 0 : item?.links?.view)?.map(
|
|
4329
|
-
(child, i) => /* @__PURE__ */
|
|
4113
|
+
(child, i) => /* @__PURE__ */ jsx57(React40.Fragment, { children: child }, i)
|
|
4330
4114
|
) : renderChildren(props.node.children, props, item, idx)
|
|
4331
4115
|
)
|
|
4332
4116
|
}
|
|
4333
4117
|
) }),
|
|
4334
|
-
dataBindingProperties && props.node.dataBinding.enablePagination && /* @__PURE__ */
|
|
4118
|
+
dataBindingProperties && props.node.dataBinding.enablePagination && /* @__PURE__ */ jsx57("div", { children: /* @__PURE__ */ jsx57(Pagination_default, { path: props.path, query: props.query, dataset: response }) })
|
|
4335
4119
|
] });
|
|
4336
4120
|
};
|
|
4337
4121
|
var DivContainer_default = DivContainer;
|
|
4338
4122
|
|
|
4339
4123
|
// src/components/pageRenderingEngine/PageBodyRenderer.tsx
|
|
4340
|
-
import { jsx as
|
|
4124
|
+
import { jsx as jsx58 } from "react/jsx-runtime";
|
|
4341
4125
|
var NodeTypes = {
|
|
4342
4126
|
["paragraph"]: ParagraphNode_default,
|
|
4343
4127
|
["heading"]: HeadingNode_default,
|
|
@@ -4365,11 +4149,11 @@ var PageBodyRenderer = (props) => {
|
|
|
4365
4149
|
if (pageBodyTree && pageBodyTree.root) {
|
|
4366
4150
|
rootNode = pageBodyTree.root;
|
|
4367
4151
|
}
|
|
4368
|
-
return /* @__PURE__ */
|
|
4152
|
+
return /* @__PURE__ */ jsx58(React41.Fragment, { children: rootNode && rootNode?.children?.map((node, index) => {
|
|
4369
4153
|
{
|
|
4370
4154
|
}
|
|
4371
4155
|
const SelectedNode = NodeTypes[node.type];
|
|
4372
|
-
return /* @__PURE__ */
|
|
4156
|
+
return /* @__PURE__ */ jsx58(React41.Fragment, { children: SelectedNode && /* @__PURE__ */ jsx58(React41.Fragment, { children: node.type == "layout-container" ? /* @__PURE__ */ jsx58(React41.Fragment, { children: /* @__PURE__ */ jsx58(
|
|
4373
4157
|
SelectedNode,
|
|
4374
4158
|
{
|
|
4375
4159
|
node,
|
|
@@ -4385,7 +4169,7 @@ var PageBodyRenderer = (props) => {
|
|
|
4385
4169
|
device: props.device,
|
|
4386
4170
|
widgetRenderer: props.widgetRenderer
|
|
4387
4171
|
}
|
|
4388
|
-
) }) : /* @__PURE__ */
|
|
4172
|
+
) }) : /* @__PURE__ */ jsx58(React41.Fragment, { children: /* @__PURE__ */ jsx58(
|
|
4389
4173
|
SelectedNode,
|
|
4390
4174
|
{
|
|
4391
4175
|
node,
|
|
@@ -4407,7 +4191,7 @@ var PageBodyRenderer_default = PageBodyRenderer;
|
|
|
4407
4191
|
|
|
4408
4192
|
// src/components/Toast.tsx
|
|
4409
4193
|
import { useState as useState7 } from "react";
|
|
4410
|
-
import { Fragment as Fragment9, jsx as
|
|
4194
|
+
import { Fragment as Fragment9, jsx as jsx59, jsxs as jsxs33 } from "react/jsx-runtime";
|
|
4411
4195
|
var Toast = () => {
|
|
4412
4196
|
const [showToast, setShowToast] = useState7(false);
|
|
4413
4197
|
const [message, setMessage] = useState7("");
|
|
@@ -4450,8 +4234,8 @@ var Toast = () => {
|
|
|
4450
4234
|
const closeToast = () => {
|
|
4451
4235
|
setShowToast(false);
|
|
4452
4236
|
};
|
|
4453
|
-
return /* @__PURE__ */
|
|
4454
|
-
/* @__PURE__ */
|
|
4237
|
+
return /* @__PURE__ */ jsx59(Fragment9, { children: showToast && /* @__PURE__ */ jsx59("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__ */ jsxs33("div", { className: `w-full items-center flex justify-between p-3 rounded-md relative shadow border bg-${messageType}-soft`, children: [
|
|
4238
|
+
/* @__PURE__ */ jsx59(
|
|
4455
4239
|
"span",
|
|
4456
4240
|
{
|
|
4457
4241
|
className: "font-medium text-inherit text-sm",
|
|
@@ -4459,7 +4243,7 @@ var Toast = () => {
|
|
|
4459
4243
|
children: message
|
|
4460
4244
|
}
|
|
4461
4245
|
),
|
|
4462
|
-
/* @__PURE__ */
|
|
4246
|
+
/* @__PURE__ */ jsx59("button", { className: "absolute right-2 top-2 ml-2 focus:outline-none", onClick: closeToast, children: /* @__PURE__ */ jsx59(
|
|
4463
4247
|
"svg",
|
|
4464
4248
|
{
|
|
4465
4249
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -4467,7 +4251,7 @@ var Toast = () => {
|
|
|
4467
4251
|
fill: "none",
|
|
4468
4252
|
viewBox: "0 0 24 24",
|
|
4469
4253
|
stroke: "currentColor",
|
|
4470
|
-
children: /* @__PURE__ */
|
|
4254
|
+
children: /* @__PURE__ */ jsx59("path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: "2", d: "M6 18L18 6M6 6l12 12" })
|
|
4471
4255
|
}
|
|
4472
4256
|
) })
|
|
4473
4257
|
] }) }) });
|
|
@@ -4477,7 +4261,7 @@ var Toast_default = Toast;
|
|
|
4477
4261
|
// src/components/NavigationTabsV2.tsx
|
|
4478
4262
|
import Link3 from "next/link";
|
|
4479
4263
|
import { usePathname } from "next/navigation";
|
|
4480
|
-
import { jsx as
|
|
4264
|
+
import { jsx as jsx60 } from "react/jsx-runtime";
|
|
4481
4265
|
function resolveRoutePlaceholders(route, params) {
|
|
4482
4266
|
return route.replace(/\{([^}]+)\}/g, (match, key) => {
|
|
4483
4267
|
const value = params[key];
|
|
@@ -4502,8 +4286,8 @@ var NavigationTabsV2 = ({ tabs, params = {} }) => {
|
|
|
4502
4286
|
isActive: tab.isActive
|
|
4503
4287
|
})) || [];
|
|
4504
4288
|
if (mappedTabs.length === 0) return null;
|
|
4505
|
-
return /* @__PURE__ */
|
|
4506
|
-
return /* @__PURE__ */
|
|
4289
|
+
return /* @__PURE__ */ jsx60("div", { className: "flex border-b bg-white rounded-t mb-3", children: mappedTabs.map(({ tabTitle, landingPageUrl, isActive }) => {
|
|
4290
|
+
return /* @__PURE__ */ jsx60(Link3, { href: landingPageUrl, className: "-mb-px", children: /* @__PURE__ */ jsx60(
|
|
4507
4291
|
"div",
|
|
4508
4292
|
{
|
|
4509
4293
|
className: `text-sm font-medium border-b-2 px-6 py-2 transition
|
|
@@ -4516,51 +4300,51 @@ var NavigationTabsV2 = ({ tabs, params = {} }) => {
|
|
|
4516
4300
|
var NavigationTabsV2_default = NavigationTabsV2;
|
|
4517
4301
|
|
|
4518
4302
|
// src/components/dataForm/DataList.tsx
|
|
4519
|
-
import
|
|
4303
|
+
import React45, { useEffect as useEffect9, useState as useState8, useCallback as useCallback3, useReducer as useReducer2 } from "react";
|
|
4520
4304
|
import { useRouter } from "next/navigation";
|
|
4521
4305
|
|
|
4522
4306
|
// src/components/dataForm/NoContentView.tsx
|
|
4523
|
-
import
|
|
4524
|
-
import { jsx as
|
|
4307
|
+
import React43 from "react";
|
|
4308
|
+
import { jsx as jsx61 } from "react/jsx-runtime";
|
|
4525
4309
|
var NoContentView = (props) => {
|
|
4526
|
-
return /* @__PURE__ */
|
|
4310
|
+
return /* @__PURE__ */ jsx61(React43.Fragment, { children: props.isDataFound === false && props.children });
|
|
4527
4311
|
};
|
|
4528
4312
|
var NoContentView_default = NoContentView;
|
|
4529
4313
|
|
|
4530
4314
|
// src/components/dataForm/ContentView.tsx
|
|
4531
|
-
import
|
|
4532
|
-
import { jsx as
|
|
4315
|
+
import React44 from "react";
|
|
4316
|
+
import { jsx as jsx62, jsxs as jsxs34 } from "react/jsx-runtime";
|
|
4533
4317
|
var ContentView = (props) => {
|
|
4534
|
-
return /* @__PURE__ */
|
|
4535
|
-
props.isDataFound == null && /* @__PURE__ */
|
|
4536
|
-
/* @__PURE__ */
|
|
4537
|
-
/* @__PURE__ */
|
|
4538
|
-
/* @__PURE__ */
|
|
4539
|
-
/* @__PURE__ */
|
|
4540
|
-
/* @__PURE__ */
|
|
4318
|
+
return /* @__PURE__ */ jsxs34(React44.Fragment, { children: [
|
|
4319
|
+
props.isDataFound == null && /* @__PURE__ */ jsx62("div", { className: "", children: /* @__PURE__ */ jsxs34("div", { className: "bg-gray-200 rounded-md p-4 animate-pulse", children: [
|
|
4320
|
+
/* @__PURE__ */ jsxs34("div", { className: "flex items-center mb-4", children: [
|
|
4321
|
+
/* @__PURE__ */ jsx62("div", { className: "bg-gray-300 h-8 w-8 rounded-full animate-pulse" }),
|
|
4322
|
+
/* @__PURE__ */ jsxs34("div", { className: "ml-2", children: [
|
|
4323
|
+
/* @__PURE__ */ jsx62("div", { className: "bg-gray-300 h-3 w-16 animate-pulse" }),
|
|
4324
|
+
/* @__PURE__ */ jsx62("div", { className: "bg-gray-300 h-2 w-12 animate-pulse" })
|
|
4541
4325
|
] })
|
|
4542
4326
|
] }),
|
|
4543
|
-
/* @__PURE__ */
|
|
4544
|
-
/* @__PURE__ */
|
|
4545
|
-
/* @__PURE__ */
|
|
4546
|
-
/* @__PURE__ */
|
|
4547
|
-
/* @__PURE__ */
|
|
4548
|
-
/* @__PURE__ */
|
|
4549
|
-
/* @__PURE__ */
|
|
4327
|
+
/* @__PURE__ */ jsxs34("div", { className: "grid grid-cols-3 gap-4 mt-6", children: [
|
|
4328
|
+
/* @__PURE__ */ jsxs34("div", { className: "animate-pulse", children: [
|
|
4329
|
+
/* @__PURE__ */ jsx62("div", { className: "bg-gray-300 rounded-full h-3 w-12 mb-2" }),
|
|
4330
|
+
/* @__PURE__ */ jsx62("div", { className: "bg-gray-300 rounded-full h-3 w-24 mb-2" }),
|
|
4331
|
+
/* @__PURE__ */ jsx62("div", { className: "bg-gray-300 rounded-full h-3 w-32 mb-2" }),
|
|
4332
|
+
/* @__PURE__ */ jsx62("div", { className: "bg-gray-300 rounded-full h-3 w-16 mb-2" }),
|
|
4333
|
+
/* @__PURE__ */ jsx62("div", { className: "bg-gray-300 rounded-full h-3 w-28 mb-2" })
|
|
4550
4334
|
] }),
|
|
4551
|
-
/* @__PURE__ */
|
|
4552
|
-
/* @__PURE__ */
|
|
4553
|
-
/* @__PURE__ */
|
|
4554
|
-
/* @__PURE__ */
|
|
4555
|
-
/* @__PURE__ */
|
|
4556
|
-
/* @__PURE__ */
|
|
4335
|
+
/* @__PURE__ */ jsxs34("div", { className: "animate-pulse", children: [
|
|
4336
|
+
/* @__PURE__ */ jsx62("div", { className: "bg-gray-300 rounded-full h-3 w-12 mb-2" }),
|
|
4337
|
+
/* @__PURE__ */ jsx62("div", { className: "bg-gray-300 rounded-full h-3 w-24 mb-2" }),
|
|
4338
|
+
/* @__PURE__ */ jsx62("div", { className: "bg-gray-300 rounded-full h-3 w-32 mb-2" }),
|
|
4339
|
+
/* @__PURE__ */ jsx62("div", { className: "bg-gray-300 rounded-full h-3 w-16 mb-2" }),
|
|
4340
|
+
/* @__PURE__ */ jsx62("div", { className: "bg-gray-300 rounded-full h-3 w-28 mb-2" })
|
|
4557
4341
|
] }),
|
|
4558
|
-
/* @__PURE__ */
|
|
4559
|
-
/* @__PURE__ */
|
|
4560
|
-
/* @__PURE__ */
|
|
4561
|
-
/* @__PURE__ */
|
|
4562
|
-
/* @__PURE__ */
|
|
4563
|
-
/* @__PURE__ */
|
|
4342
|
+
/* @__PURE__ */ jsxs34("div", { className: "animate-pulse", children: [
|
|
4343
|
+
/* @__PURE__ */ jsx62("div", { className: "bg-gray-300 rounded-full h-3 w-12 mb-2" }),
|
|
4344
|
+
/* @__PURE__ */ jsx62("div", { className: "bg-gray-300 rounded-full h-3 w-24 mb-2" }),
|
|
4345
|
+
/* @__PURE__ */ jsx62("div", { className: "bg-gray-300 rounded-full h-3 w-32 mb-2" }),
|
|
4346
|
+
/* @__PURE__ */ jsx62("div", { className: "bg-gray-300 rounded-full h-3 w-16 mb-2" }),
|
|
4347
|
+
/* @__PURE__ */ jsx62("div", { className: "bg-gray-300 rounded-full h-3 w-28 mb-2" })
|
|
4564
4348
|
] })
|
|
4565
4349
|
] })
|
|
4566
4350
|
] }) }),
|
|
@@ -4570,7 +4354,7 @@ var ContentView = (props) => {
|
|
|
4570
4354
|
var ContentView_default = ContentView;
|
|
4571
4355
|
|
|
4572
4356
|
// src/components/dataForm/DataList.tsx
|
|
4573
|
-
import { Fragment as Fragment10, jsx as
|
|
4357
|
+
import { Fragment as Fragment10, jsx as jsx63, jsxs as jsxs35 } from "react/jsx-runtime";
|
|
4574
4358
|
var DataList = (props) => {
|
|
4575
4359
|
console.log(props.dataset, "datasetssssss");
|
|
4576
4360
|
const router = useRouter();
|
|
@@ -4593,7 +4377,7 @@ var DataList = (props) => {
|
|
|
4593
4377
|
if (path.includes(".")) {
|
|
4594
4378
|
return path.split(".").reduce((prev, curr) => prev ? prev[curr] : null, obj);
|
|
4595
4379
|
} else if (Array.isArray(obj[path])) {
|
|
4596
|
-
return obj[path].map((item, index) => /* @__PURE__ */
|
|
4380
|
+
return obj[path].map((item, index) => /* @__PURE__ */ jsx63("div", { children: item }, index));
|
|
4597
4381
|
} else {
|
|
4598
4382
|
return obj[path];
|
|
4599
4383
|
}
|
|
@@ -4649,30 +4433,30 @@ var DataList = (props) => {
|
|
|
4649
4433
|
const renderPageNumbers = () => {
|
|
4650
4434
|
if (pages <= 10) {
|
|
4651
4435
|
return Array.from({ length: pages }, (_, index) => index + 1).map(
|
|
4652
|
-
(page) => /* @__PURE__ */
|
|
4436
|
+
(page) => /* @__PURE__ */ jsx63(React45.Fragment, { children: activePageNumber !== page ? /* @__PURE__ */ jsx63(
|
|
4653
4437
|
Hyperlink,
|
|
4654
4438
|
{
|
|
4655
4439
|
className: "px-3 py-1 border-t border-b border-gray-300 bg-white text-gray-700 hover:bg-gray-100",
|
|
4656
4440
|
href: builder.getNewPageUrl(page),
|
|
4657
4441
|
children: page
|
|
4658
4442
|
}
|
|
4659
|
-
) : /* @__PURE__ */
|
|
4443
|
+
) : /* @__PURE__ */ jsx63("span", { className: "px-3 py-1 border-t border-b border-gray-300 bg-primary text-white", children: page }) }, page)
|
|
4660
4444
|
);
|
|
4661
4445
|
} else {
|
|
4662
4446
|
const showFirstPages = activePageNumber <= 5;
|
|
4663
4447
|
const showLastPages = activePageNumber > pages - 5;
|
|
4664
4448
|
if (showFirstPages) {
|
|
4665
|
-
return /* @__PURE__ */
|
|
4666
|
-
Array.from({ length: 8 }, (_, index) => index + 1).map((page) => /* @__PURE__ */
|
|
4449
|
+
return /* @__PURE__ */ jsxs35(Fragment10, { children: [
|
|
4450
|
+
Array.from({ length: 8 }, (_, index) => index + 1).map((page) => /* @__PURE__ */ jsx63(React45.Fragment, { children: activePageNumber !== page ? /* @__PURE__ */ jsx63(
|
|
4667
4451
|
Hyperlink,
|
|
4668
4452
|
{
|
|
4669
4453
|
className: "px-3 py-1 border-t border-b border-gray-300 bg-white text-gray-700 hover:bg-gray-100",
|
|
4670
4454
|
href: builder.getNewPageUrl(page),
|
|
4671
4455
|
children: page
|
|
4672
4456
|
}
|
|
4673
|
-
) : /* @__PURE__ */
|
|
4674
|
-
/* @__PURE__ */
|
|
4675
|
-
/* @__PURE__ */
|
|
4457
|
+
) : /* @__PURE__ */ jsx63("span", { className: "px-3 py-1 border-t border-b border-gray-300 bg-primary text-white", children: page }) }, page)),
|
|
4458
|
+
/* @__PURE__ */ jsx63("span", { className: "px-2 py-1", children: "..." }),
|
|
4459
|
+
/* @__PURE__ */ jsx63(
|
|
4676
4460
|
Hyperlink,
|
|
4677
4461
|
{
|
|
4678
4462
|
className: "px-3 py-1 border-t border-b border-gray-300 bg-white text-gray-700 hover:bg-gray-100",
|
|
@@ -4680,7 +4464,7 @@ var DataList = (props) => {
|
|
|
4680
4464
|
children: pages - 1
|
|
4681
4465
|
}
|
|
4682
4466
|
),
|
|
4683
|
-
/* @__PURE__ */
|
|
4467
|
+
/* @__PURE__ */ jsx63(
|
|
4684
4468
|
Hyperlink,
|
|
4685
4469
|
{
|
|
4686
4470
|
className: "px-3 py-1 border-t border-b border-gray-300 bg-white text-gray-700 hover:bg-gray-100",
|
|
@@ -4688,7 +4472,7 @@ var DataList = (props) => {
|
|
|
4688
4472
|
children: pages
|
|
4689
4473
|
}
|
|
4690
4474
|
),
|
|
4691
|
-
/* @__PURE__ */
|
|
4475
|
+
/* @__PURE__ */ jsx63("div", { className: "relative inline-block", children: /* @__PURE__ */ jsxs35(
|
|
4692
4476
|
"select",
|
|
4693
4477
|
{
|
|
4694
4478
|
className: " py-1 border border-gray-300 bg-white text-gray-700 appearance-none rounded-none",
|
|
@@ -4700,18 +4484,18 @@ var DataList = (props) => {
|
|
|
4700
4484
|
}
|
|
4701
4485
|
},
|
|
4702
4486
|
children: [
|
|
4703
|
-
/* @__PURE__ */
|
|
4487
|
+
/* @__PURE__ */ jsx63("option", { className: "", value: "", children: "Jump to" }),
|
|
4704
4488
|
Array.from(
|
|
4705
4489
|
{ length: Math.max(0, pages - 10) },
|
|
4706
4490
|
(_, index) => index + 9
|
|
4707
|
-
).map((page) => /* @__PURE__ */
|
|
4491
|
+
).map((page) => /* @__PURE__ */ jsx63("option", { value: page, children: page }, page))
|
|
4708
4492
|
]
|
|
4709
4493
|
}
|
|
4710
4494
|
) })
|
|
4711
4495
|
] });
|
|
4712
4496
|
} else if (showLastPages) {
|
|
4713
|
-
return /* @__PURE__ */
|
|
4714
|
-
/* @__PURE__ */
|
|
4497
|
+
return /* @__PURE__ */ jsxs35(Fragment10, { children: [
|
|
4498
|
+
/* @__PURE__ */ jsx63(
|
|
4715
4499
|
Hyperlink,
|
|
4716
4500
|
{
|
|
4717
4501
|
className: "px-3 py-1 border-t border-b border-gray-300 bg-white text-gray-700 hover:bg-gray-100",
|
|
@@ -4719,7 +4503,7 @@ var DataList = (props) => {
|
|
|
4719
4503
|
children: "1"
|
|
4720
4504
|
}
|
|
4721
4505
|
),
|
|
4722
|
-
/* @__PURE__ */
|
|
4506
|
+
/* @__PURE__ */ jsx63(
|
|
4723
4507
|
Hyperlink,
|
|
4724
4508
|
{
|
|
4725
4509
|
className: "px-3 py-1 border-t border-b border-gray-300 bg-white text-gray-700 hover:bg-gray-100",
|
|
@@ -4727,21 +4511,21 @@ var DataList = (props) => {
|
|
|
4727
4511
|
children: "2"
|
|
4728
4512
|
}
|
|
4729
4513
|
),
|
|
4730
|
-
/* @__PURE__ */
|
|
4514
|
+
/* @__PURE__ */ jsx63("span", { className: "px-2 py-1", children: "..." }),
|
|
4731
4515
|
Array.from({ length: 8 }, (_, index) => pages - 7 + index).map(
|
|
4732
|
-
(page) => /* @__PURE__ */
|
|
4516
|
+
(page) => /* @__PURE__ */ jsx63(React45.Fragment, { children: activePageNumber !== page ? /* @__PURE__ */ jsx63(
|
|
4733
4517
|
Hyperlink,
|
|
4734
4518
|
{
|
|
4735
4519
|
className: "px-3 py-1 border-t border-b border-gray-300 bg-white text-gray-700 hover:bg-gray-100",
|
|
4736
4520
|
href: builder.getNewPageUrl(page),
|
|
4737
4521
|
children: page
|
|
4738
4522
|
}
|
|
4739
|
-
) : /* @__PURE__ */
|
|
4523
|
+
) : /* @__PURE__ */ jsx63("span", { className: "px-3 py-1 border-t border-b border-gray-300 bg-primary text-white", children: page }) }, page)
|
|
4740
4524
|
)
|
|
4741
4525
|
] });
|
|
4742
4526
|
} else {
|
|
4743
|
-
return /* @__PURE__ */
|
|
4744
|
-
/* @__PURE__ */
|
|
4527
|
+
return /* @__PURE__ */ jsxs35(Fragment10, { children: [
|
|
4528
|
+
/* @__PURE__ */ jsx63(
|
|
4745
4529
|
Hyperlink,
|
|
4746
4530
|
{
|
|
4747
4531
|
className: "px-3 py-1 border-t border-b border-gray-300 bg-white text-gray-700 hover:bg-gray-100",
|
|
@@ -4749,7 +4533,7 @@ var DataList = (props) => {
|
|
|
4749
4533
|
children: "1"
|
|
4750
4534
|
}
|
|
4751
4535
|
),
|
|
4752
|
-
/* @__PURE__ */
|
|
4536
|
+
/* @__PURE__ */ jsx63(
|
|
4753
4537
|
Hyperlink,
|
|
4754
4538
|
{
|
|
4755
4539
|
className: "px-3 py-1 border-t border-b border-gray-300 bg-white text-gray-700 hover:bg-gray-100",
|
|
@@ -4757,20 +4541,20 @@ var DataList = (props) => {
|
|
|
4757
4541
|
children: "2"
|
|
4758
4542
|
}
|
|
4759
4543
|
),
|
|
4760
|
-
/* @__PURE__ */
|
|
4544
|
+
/* @__PURE__ */ jsx63("span", { className: "px-2 py-1", children: "..." }),
|
|
4761
4545
|
Array.from(
|
|
4762
4546
|
{ length: 5 },
|
|
4763
4547
|
(_, index) => activePageNumber - 2 + index
|
|
4764
|
-
).map((page) => /* @__PURE__ */
|
|
4548
|
+
).map((page) => /* @__PURE__ */ jsx63(React45.Fragment, { children: activePageNumber !== page ? /* @__PURE__ */ jsx63(
|
|
4765
4549
|
Hyperlink,
|
|
4766
4550
|
{
|
|
4767
4551
|
className: "px-3 py-1 border-t border-b border-gray-300 bg-white text-gray-700 hover:bg-gray-100",
|
|
4768
4552
|
href: builder.getNewPageUrl(page),
|
|
4769
4553
|
children: page
|
|
4770
4554
|
}
|
|
4771
|
-
) : /* @__PURE__ */
|
|
4772
|
-
/* @__PURE__ */
|
|
4773
|
-
/* @__PURE__ */
|
|
4555
|
+
) : /* @__PURE__ */ jsx63("span", { className: "px-3 py-1 border-t border-b border-gray-300 bg-primary text-white", children: page }) }, page)),
|
|
4556
|
+
/* @__PURE__ */ jsx63("span", { className: "px-2 py-1", children: "..." }),
|
|
4557
|
+
/* @__PURE__ */ jsx63(
|
|
4774
4558
|
Hyperlink,
|
|
4775
4559
|
{
|
|
4776
4560
|
className: "px-3 py-1 border-t border-b border-gray-300 bg-white text-gray-700 hover:bg-gray-100",
|
|
@@ -4778,7 +4562,7 @@ var DataList = (props) => {
|
|
|
4778
4562
|
children: pages - 1
|
|
4779
4563
|
}
|
|
4780
4564
|
),
|
|
4781
|
-
/* @__PURE__ */
|
|
4565
|
+
/* @__PURE__ */ jsx63(
|
|
4782
4566
|
Hyperlink,
|
|
4783
4567
|
{
|
|
4784
4568
|
className: "px-3 py-1 border-t border-b border-gray-300 bg-white text-gray-700 hover:bg-gray-100",
|
|
@@ -4786,7 +4570,7 @@ var DataList = (props) => {
|
|
|
4786
4570
|
children: pages
|
|
4787
4571
|
}
|
|
4788
4572
|
),
|
|
4789
|
-
/* @__PURE__ */
|
|
4573
|
+
/* @__PURE__ */ jsx63("div", { className: "relative inline-block", children: /* @__PURE__ */ jsxs35(
|
|
4790
4574
|
"select",
|
|
4791
4575
|
{
|
|
4792
4576
|
className: "px-2 py-1 border border-gray-300 bg-white text-gray-700 appearance-none rounded-none",
|
|
@@ -4798,8 +4582,8 @@ var DataList = (props) => {
|
|
|
4798
4582
|
}
|
|
4799
4583
|
},
|
|
4800
4584
|
children: [
|
|
4801
|
-
/* @__PURE__ */
|
|
4802
|
-
Array.from({ length: pages - 4 }, (_, index) => index + 3).filter((page) => page > 2 && page < pages - 1).map((page) => /* @__PURE__ */
|
|
4585
|
+
/* @__PURE__ */ jsx63("option", { value: "", children: "Jump to" }),
|
|
4586
|
+
Array.from({ length: pages - 4 }, (_, index) => index + 3).filter((page) => page > 2 && page < pages - 1).map((page) => /* @__PURE__ */ jsx63("option", { value: page, children: page }, page))
|
|
4803
4587
|
]
|
|
4804
4588
|
}
|
|
4805
4589
|
) })
|
|
@@ -4807,16 +4591,16 @@ var DataList = (props) => {
|
|
|
4807
4591
|
}
|
|
4808
4592
|
}
|
|
4809
4593
|
};
|
|
4810
|
-
return /* @__PURE__ */
|
|
4811
|
-
/* @__PURE__ */
|
|
4812
|
-
(props.title || props.filters || props.addLinkHref) && /* @__PURE__ */
|
|
4594
|
+
return /* @__PURE__ */ jsxs35(React45.Fragment, { children: [
|
|
4595
|
+
/* @__PURE__ */ jsxs35(ContentView_default, { isDataFound, children: [
|
|
4596
|
+
(props.title || props.filters || props.addLinkHref) && /* @__PURE__ */ jsxs35(
|
|
4813
4597
|
"div",
|
|
4814
4598
|
{
|
|
4815
4599
|
className: `flex justify-between items-center bg-white pl-6 pr-2 h-14 mb-3 shadow-sm rounded-md border-b border-neutral-200 sticky top-0`,
|
|
4816
4600
|
children: [
|
|
4817
|
-
props.title ? /* @__PURE__ */
|
|
4818
|
-
/* @__PURE__ */
|
|
4819
|
-
props.filters && props.filters.map((filter) => /* @__PURE__ */
|
|
4601
|
+
props.title ? /* @__PURE__ */ jsx63("div", { className: "inline-flex items-center gap-2", children: /* @__PURE__ */ jsx63("h2", { className: "text-lg font-semibold text-black-800", children: props.title }) }) : /* @__PURE__ */ jsx63("div", {}),
|
|
4602
|
+
/* @__PURE__ */ jsxs35("div", { className: "flex items-center gap-3", children: [
|
|
4603
|
+
props.filters && props.filters.map((filter) => /* @__PURE__ */ jsx63(
|
|
4820
4604
|
InputControl_default,
|
|
4821
4605
|
{
|
|
4822
4606
|
name: filter.name,
|
|
@@ -4831,15 +4615,15 @@ var DataList = (props) => {
|
|
|
4831
4615
|
},
|
|
4832
4616
|
filter.name
|
|
4833
4617
|
)),
|
|
4834
|
-
props.addLinkHref && /* @__PURE__ */
|
|
4618
|
+
props.addLinkHref && /* @__PURE__ */ jsxs35(
|
|
4835
4619
|
Hyperlink,
|
|
4836
4620
|
{
|
|
4837
4621
|
className: "gap-1",
|
|
4838
4622
|
linkType: "Primary" /* Solid */,
|
|
4839
4623
|
href: props.addLinkHref,
|
|
4840
4624
|
children: [
|
|
4841
|
-
/* @__PURE__ */
|
|
4842
|
-
/* @__PURE__ */
|
|
4625
|
+
/* @__PURE__ */ jsx63(Icon_default, { name: "plus", className: "w-4 h-4" }),
|
|
4626
|
+
/* @__PURE__ */ jsx63("span", { className: "text-sm font-medium", children: props.addLinkText || "Add New" })
|
|
4843
4627
|
]
|
|
4844
4628
|
}
|
|
4845
4629
|
)
|
|
@@ -4847,8 +4631,8 @@ var DataList = (props) => {
|
|
|
4847
4631
|
]
|
|
4848
4632
|
}
|
|
4849
4633
|
),
|
|
4850
|
-
/* @__PURE__ */
|
|
4851
|
-
/* @__PURE__ */
|
|
4634
|
+
/* @__PURE__ */ jsx63("div", { className: "flex-1 overflow-y-auto justify-end bg-white rounded shadow h-[calc(100vh-14rem)]", children: /* @__PURE__ */ jsxs35("table", { className: "w-full divide-y divide-gray-200", children: [
|
|
4635
|
+
/* @__PURE__ */ jsx63("thead", { className: "bg-gray-50 sticky top-0", children: /* @__PURE__ */ jsx63("tr", { children: props?.columns?.map((column) => {
|
|
4852
4636
|
let url = builder.getNewOrderByUrl(column.name);
|
|
4853
4637
|
let icon = "chevronUpDown";
|
|
4854
4638
|
if (orderBy.includes(`${column.name} desc`)) {
|
|
@@ -4858,36 +4642,36 @@ var DataList = (props) => {
|
|
|
4858
4642
|
icon = "chevronUp";
|
|
4859
4643
|
url = builder.getNewOrderByUrl(column.name + " desc");
|
|
4860
4644
|
}
|
|
4861
|
-
return /* @__PURE__ */
|
|
4645
|
+
return /* @__PURE__ */ jsx63(
|
|
4862
4646
|
"th",
|
|
4863
4647
|
{
|
|
4864
4648
|
className: "px-6 py-3 text-left font-medium cursor-pointer bg-neutral-soft " + column.width + (column.controlType == ViewControlTypes_default.money ? " text-right" : ""),
|
|
4865
|
-
children: /* @__PURE__ */
|
|
4866
|
-
/* @__PURE__ */
|
|
4867
|
-
column.enableSorting && /* @__PURE__ */
|
|
4649
|
+
children: /* @__PURE__ */ jsx63(Hyperlink, { href: url, className: "!text-neutral-contrast ", children: /* @__PURE__ */ jsxs35("span", { className: "flex items-center space-x-1", children: [
|
|
4650
|
+
/* @__PURE__ */ jsx63("span", { className: "text-black", children: column.label }),
|
|
4651
|
+
column.enableSorting && /* @__PURE__ */ jsx63(Icon_default, { className: "w-4 h-4", name: icon })
|
|
4868
4652
|
] }) })
|
|
4869
4653
|
},
|
|
4870
4654
|
column.name
|
|
4871
4655
|
);
|
|
4872
4656
|
}) }) }),
|
|
4873
|
-
/* @__PURE__ */
|
|
4657
|
+
/* @__PURE__ */ jsx63("tbody", { className: "divide-y divide-gray-200 ", children: props.dataset?.result?.map((dataitem, index) => {
|
|
4874
4658
|
let validityClass = "";
|
|
4875
4659
|
console.log("dataitem", dataitem);
|
|
4876
4660
|
if (props.recordValidityColumnName && getNestedProperty2(dataitem, props.recordValidityColumnName) == false) {
|
|
4877
4661
|
validityClass = "bg-alert-200";
|
|
4878
4662
|
}
|
|
4879
|
-
return /* @__PURE__ */
|
|
4663
|
+
return /* @__PURE__ */ jsx63("tr", { className: validityClass, children: props?.columns?.map((column, colindex) => {
|
|
4880
4664
|
console.log("column", column);
|
|
4881
|
-
return /* @__PURE__ */
|
|
4665
|
+
return /* @__PURE__ */ jsx63(React45.Fragment, { children: /* @__PURE__ */ jsx63(
|
|
4882
4666
|
"td",
|
|
4883
4667
|
{
|
|
4884
4668
|
className: "px-6 py-2 whitespace-normal " + (column.controlType == ViewControlTypes_default.money ? "" : ""),
|
|
4885
|
-
children: column.addhref === true ? /* @__PURE__ */
|
|
4669
|
+
children: column.addhref === true ? /* @__PURE__ */ jsx63(
|
|
4886
4670
|
Hyperlink,
|
|
4887
4671
|
{
|
|
4888
4672
|
className: "",
|
|
4889
4673
|
href: `https://${dataitem[column.name]}`,
|
|
4890
|
-
children: /* @__PURE__ */
|
|
4674
|
+
children: /* @__PURE__ */ jsx63(
|
|
4891
4675
|
ViewControl_default,
|
|
4892
4676
|
{
|
|
4893
4677
|
controlType: column.controlType,
|
|
@@ -4900,11 +4684,11 @@ var DataList = (props) => {
|
|
|
4900
4684
|
}
|
|
4901
4685
|
)
|
|
4902
4686
|
}
|
|
4903
|
-
) : column.showAsLink ? /* @__PURE__ */
|
|
4687
|
+
) : column.showAsLink ? /* @__PURE__ */ jsx63(
|
|
4904
4688
|
Hyperlink,
|
|
4905
4689
|
{
|
|
4906
4690
|
href: props.path + dataitem[props.columns[0].name] + "/" + (dataitem.linkUrlSegment ?? column.linkUrlSegment),
|
|
4907
|
-
children: /* @__PURE__ */
|
|
4691
|
+
children: /* @__PURE__ */ jsx63(
|
|
4908
4692
|
ViewControl_default,
|
|
4909
4693
|
{
|
|
4910
4694
|
controlType: column.controlType,
|
|
@@ -4914,7 +4698,7 @@ var DataList = (props) => {
|
|
|
4914
4698
|
}
|
|
4915
4699
|
)
|
|
4916
4700
|
}
|
|
4917
|
-
) : /* @__PURE__ */
|
|
4701
|
+
) : /* @__PURE__ */ jsx63(
|
|
4918
4702
|
ViewControl_default,
|
|
4919
4703
|
{
|
|
4920
4704
|
controlType: column.controlType,
|
|
@@ -4928,10 +4712,10 @@ var DataList = (props) => {
|
|
|
4928
4712
|
}) }, index);
|
|
4929
4713
|
}) })
|
|
4930
4714
|
] }) }),
|
|
4931
|
-
/* @__PURE__ */
|
|
4932
|
-
/* @__PURE__ */
|
|
4933
|
-
/* @__PURE__ */
|
|
4934
|
-
activePageNumber > 1 && /* @__PURE__ */
|
|
4715
|
+
/* @__PURE__ */ jsx63("div", { className: "pt-4 border-t border-t-gray-50 sticky bottom-0 h-11 mt-2 ", children: /* @__PURE__ */ jsxs35("div", { className: "flex items-center justify-between", children: [
|
|
4716
|
+
/* @__PURE__ */ jsx63("div", { className: "text-gray-700", children: label }),
|
|
4717
|
+
/* @__PURE__ */ jsxs35("div", { className: "flex space-x-2 items-center", children: [
|
|
4718
|
+
activePageNumber > 1 && /* @__PURE__ */ jsx63(
|
|
4935
4719
|
Hyperlink,
|
|
4936
4720
|
{
|
|
4937
4721
|
className: "px-3 py-1 rounded-l-md border border-gray-300 bg-white text-gray-500 hover:bg-gray-200",
|
|
@@ -4939,9 +4723,9 @@ var DataList = (props) => {
|
|
|
4939
4723
|
children: "Prev"
|
|
4940
4724
|
}
|
|
4941
4725
|
),
|
|
4942
|
-
activePageNumber <= 1 && /* @__PURE__ */
|
|
4726
|
+
activePageNumber <= 1 && /* @__PURE__ */ jsx63("div", { className: "px-3 py-1 rounded-l-md border border-gray-300 bg-gray-200 text-gray-500 hover:bg-gray-200", children: "Prev" }),
|
|
4943
4727
|
renderPageNumbers(),
|
|
4944
|
-
activePageNumber < pages && /* @__PURE__ */
|
|
4728
|
+
activePageNumber < pages && /* @__PURE__ */ jsx63(
|
|
4945
4729
|
Hyperlink,
|
|
4946
4730
|
{
|
|
4947
4731
|
className: "px-3 py-1 rounded-r-md border border-gray-300 bg-white text-gray-500 hover:bg-gray-200",
|
|
@@ -4949,19 +4733,19 @@ var DataList = (props) => {
|
|
|
4949
4733
|
children: "Next"
|
|
4950
4734
|
}
|
|
4951
4735
|
),
|
|
4952
|
-
activePageNumber >= pages && /* @__PURE__ */
|
|
4736
|
+
activePageNumber >= pages && /* @__PURE__ */ jsx63("div", { className: "px-3 py-1 rounded-r-md border border-gray-300 bg-gray-200 text-gray-500", children: "Next" })
|
|
4953
4737
|
] })
|
|
4954
4738
|
] }) })
|
|
4955
4739
|
] }),
|
|
4956
|
-
/* @__PURE__ */
|
|
4957
|
-
(props.title || props.filters || props.addLinkHref) && /* @__PURE__ */
|
|
4740
|
+
/* @__PURE__ */ jsxs35(NoContentView_default, { isDataFound, children: [
|
|
4741
|
+
(props.title || props.filters || props.addLinkHref) && /* @__PURE__ */ jsxs35(
|
|
4958
4742
|
"div",
|
|
4959
4743
|
{
|
|
4960
4744
|
className: `flex justify-between items-center bg-white pl-6 pr-2 h-14 mb-3 shadow-sm rounded-md border-b border-neutral-200`,
|
|
4961
4745
|
children: [
|
|
4962
|
-
props.title ? /* @__PURE__ */
|
|
4963
|
-
/* @__PURE__ */
|
|
4964
|
-
props.filters && props.filters.map((filter) => /* @__PURE__ */
|
|
4746
|
+
props.title ? /* @__PURE__ */ jsx63("div", { className: "inline-flex items-center gap-2", children: /* @__PURE__ */ jsx63("h2", { className: "text-lg font-semibold text-black", children: props.title }) }) : /* @__PURE__ */ jsx63("div", {}),
|
|
4747
|
+
/* @__PURE__ */ jsxs35("div", { className: "flex items-center gap-3", children: [
|
|
4748
|
+
props.filters && props.filters.map((filter) => /* @__PURE__ */ jsx63(
|
|
4965
4749
|
InputControl_default,
|
|
4966
4750
|
{
|
|
4967
4751
|
name: filter.name,
|
|
@@ -4976,15 +4760,15 @@ var DataList = (props) => {
|
|
|
4976
4760
|
},
|
|
4977
4761
|
filter.name
|
|
4978
4762
|
)),
|
|
4979
|
-
props.addLinkHref && /* @__PURE__ */
|
|
4763
|
+
props.addLinkHref && /* @__PURE__ */ jsxs35(
|
|
4980
4764
|
Hyperlink,
|
|
4981
4765
|
{
|
|
4982
4766
|
className: "gap-1",
|
|
4983
4767
|
linkType: "Primary" /* Solid */,
|
|
4984
4768
|
href: props.addLinkHref,
|
|
4985
4769
|
children: [
|
|
4986
|
-
/* @__PURE__ */
|
|
4987
|
-
/* @__PURE__ */
|
|
4770
|
+
/* @__PURE__ */ jsx63(Icon_default, { name: "plus", className: "w-4 h-4" }),
|
|
4771
|
+
/* @__PURE__ */ jsx63("span", { className: "text-sm font-medium", children: props.addLinkText || "Add New" })
|
|
4988
4772
|
]
|
|
4989
4773
|
}
|
|
4990
4774
|
)
|
|
@@ -4992,8 +4776,8 @@ var DataList = (props) => {
|
|
|
4992
4776
|
]
|
|
4993
4777
|
}
|
|
4994
4778
|
),
|
|
4995
|
-
/* @__PURE__ */
|
|
4996
|
-
/* @__PURE__ */
|
|
4779
|
+
/* @__PURE__ */ jsxs35("div", { className: "flex-grow overflow-y-auto justify-end bg-white rounded shadow h-[75vh]", children: [
|
|
4780
|
+
/* @__PURE__ */ jsx63("div", { children: /* @__PURE__ */ jsx63("table", { className: "w-full divide-y divide-gray-200", children: /* @__PURE__ */ jsx63("thead", { className: "bg-gray-50", children: /* @__PURE__ */ jsx63("tr", { children: props?.columns?.map((column) => {
|
|
4997
4781
|
let url = builder.getNewOrderByUrl(column.name);
|
|
4998
4782
|
let icon = "chevronUpDown";
|
|
4999
4783
|
if (orderBy.includes(`${column.name} desc`)) {
|
|
@@ -5003,19 +4787,19 @@ var DataList = (props) => {
|
|
|
5003
4787
|
icon = "chevronUp";
|
|
5004
4788
|
url = builder.getNewOrderByUrl(column.name + " desc");
|
|
5005
4789
|
}
|
|
5006
|
-
return /* @__PURE__ */
|
|
4790
|
+
return /* @__PURE__ */ jsx63(
|
|
5007
4791
|
"th",
|
|
5008
4792
|
{
|
|
5009
4793
|
className: "px-6 py-3 text-left font-medium cursor-pointer bg-neutral-soft " + column.width + (column.controlType == ViewControlTypes_default.money ? " text-right" : ""),
|
|
5010
|
-
children: /* @__PURE__ */
|
|
5011
|
-
/* @__PURE__ */
|
|
5012
|
-
column.enableSorting && /* @__PURE__ */
|
|
4794
|
+
children: /* @__PURE__ */ jsx63(Hyperlink, { href: url, className: "text-body-950", children: /* @__PURE__ */ jsxs35("span", { className: "flex items-center space-x-1", children: [
|
|
4795
|
+
/* @__PURE__ */ jsx63("span", { children: column.label }),
|
|
4796
|
+
column.enableSorting && /* @__PURE__ */ jsx63(Icon_default, { className: "w-4 h-4", name: icon })
|
|
5013
4797
|
] }) })
|
|
5014
4798
|
},
|
|
5015
4799
|
column.name
|
|
5016
4800
|
);
|
|
5017
4801
|
}) }) }) }) }),
|
|
5018
|
-
/* @__PURE__ */
|
|
4802
|
+
/* @__PURE__ */ jsx63("div", { className: "w-full text-center bg-transparent pt-5", children: "There are no entries in the table at the moment." })
|
|
5019
4803
|
] })
|
|
5020
4804
|
] })
|
|
5021
4805
|
] });
|
|
@@ -5023,9 +4807,9 @@ var DataList = (props) => {
|
|
|
5023
4807
|
var DataList_default = DataList;
|
|
5024
4808
|
|
|
5025
4809
|
// src/components/dataForm/DataListRenderer.tsx
|
|
5026
|
-
import
|
|
4810
|
+
import React46, { useState as useState9, useEffect as useEffect10 } from "react";
|
|
5027
4811
|
import { usePathname as usePathname2 } from "next/navigation";
|
|
5028
|
-
import { jsx as
|
|
4812
|
+
import { jsx as jsx64, jsxs as jsxs36 } from "react/jsx-runtime";
|
|
5029
4813
|
var viewControlMap = {
|
|
5030
4814
|
number: ViewControlTypes.number,
|
|
5031
4815
|
lineText: ViewControlTypes.lineText,
|
|
@@ -5114,9 +4898,9 @@ var DataListRenderer = ({
|
|
|
5114
4898
|
const [tabItem, setTabItem] = useState9();
|
|
5115
4899
|
const activeTab = tabItem?.find((tab) => tab.isActive);
|
|
5116
4900
|
const activeHref = activeTab ? resolveRoutePlaceholders2(activeTab.landingPageUrl, params) : pathname;
|
|
5117
|
-
return /* @__PURE__ */
|
|
5118
|
-
widgetProps && /* @__PURE__ */
|
|
5119
|
-
/* @__PURE__ */
|
|
4901
|
+
return /* @__PURE__ */ jsxs36(React46.Fragment, { children: [
|
|
4902
|
+
widgetProps && /* @__PURE__ */ jsx64(NavigationTabsV2_default, { tabs, params: widgetProps.params }),
|
|
4903
|
+
/* @__PURE__ */ jsx64(
|
|
5120
4904
|
DataList_default,
|
|
5121
4905
|
{
|
|
5122
4906
|
addLinkHref,
|
|
@@ -5135,10 +4919,10 @@ var DataListRenderer = ({
|
|
|
5135
4919
|
var DataListRenderer_default = DataListRenderer;
|
|
5136
4920
|
|
|
5137
4921
|
// src/components/dataForm/DataForm.tsx
|
|
5138
|
-
import
|
|
4922
|
+
import React48, { useCallback as useCallback5, useEffect as useEffect11, useReducer as useReducer3, useRef as useRef4 } from "react";
|
|
5139
4923
|
|
|
5140
4924
|
// src/components/dataForm/DataFormChildSection.tsx
|
|
5141
|
-
import
|
|
4925
|
+
import React47, { useCallback as useCallback4 } from "react";
|
|
5142
4926
|
|
|
5143
4927
|
// src/components/dataForm/StyleTypes.tsx
|
|
5144
4928
|
var StyleTypes2 = /* @__PURE__ */ ((StyleTypes3) => {
|
|
@@ -5161,7 +4945,7 @@ var FORM_CHILD_ONE_TO_ONE_UPDATE = "FORM_CHILD_ONE_TO_ONE_UPDATE";
|
|
|
5161
4945
|
var FORM_CHILD_ROW_ADD = "FORM_CHILD_ROW_ADD";
|
|
5162
4946
|
|
|
5163
4947
|
// src/components/dataForm/DataFormChildSection.tsx
|
|
5164
|
-
import { jsx as
|
|
4948
|
+
import { jsx as jsx65, jsxs as jsxs37 } from "react/jsx-runtime";
|
|
5165
4949
|
var DataFormChildSection = (props) => {
|
|
5166
4950
|
const { section } = props;
|
|
5167
4951
|
const isOneToOne = section.relationshipType === "one-to-one";
|
|
@@ -5229,14 +5013,14 @@ var DataFormChildSection = (props) => {
|
|
|
5229
5013
|
childItemsToRender,
|
|
5230
5014
|
allChildItems: childItems
|
|
5231
5015
|
});
|
|
5232
|
-
return /* @__PURE__ */
|
|
5233
|
-
section.sectionTitle && /* @__PURE__ */
|
|
5234
|
-
/* @__PURE__ */
|
|
5235
|
-
/* @__PURE__ */
|
|
5236
|
-
(!isOneToOne || childItemsToRender.length > 0) && /* @__PURE__ */
|
|
5237
|
-
return /* @__PURE__ */
|
|
5016
|
+
return /* @__PURE__ */ jsx65(React47.Fragment, { children: /* @__PURE__ */ jsxs37("div", { className: "rounded border-neutral-200 border px-6 py-4 mb-2", children: [
|
|
5017
|
+
section.sectionTitle && /* @__PURE__ */ jsx65("div", { className: "mb-4 text-lg font-medium text-body-950", children: section.sectionTitle }),
|
|
5018
|
+
/* @__PURE__ */ jsx65("div", { className: "flex-grow flex flex-col justify-between overflow-y-auto", children: /* @__PURE__ */ jsxs37("div", { className: "flex flex-col justify-between gap-2", children: [
|
|
5019
|
+
/* @__PURE__ */ jsx65("div", { children: /* @__PURE__ */ jsxs37("table", { className: "w-full border-separate divide-y divide-gray-200", children: [
|
|
5020
|
+
(!isOneToOne || childItemsToRender.length > 0) && /* @__PURE__ */ jsx65("thead", { className: "", children: section.sectionRows.map((sectionRow, sectionRowIndex) => {
|
|
5021
|
+
return /* @__PURE__ */ jsxs37("tr", { className: "", children: [
|
|
5238
5022
|
sectionRow.elements.map((field, index) => {
|
|
5239
|
-
return /* @__PURE__ */
|
|
5023
|
+
return /* @__PURE__ */ jsx65(
|
|
5240
5024
|
"th",
|
|
5241
5025
|
{
|
|
5242
5026
|
className: "py-3 font-normal text-left",
|
|
@@ -5245,21 +5029,21 @@ var DataFormChildSection = (props) => {
|
|
|
5245
5029
|
field.name
|
|
5246
5030
|
);
|
|
5247
5031
|
}),
|
|
5248
|
-
!section.readonly && !isOneToOne && /* @__PURE__ */
|
|
5032
|
+
!section.readonly && !isOneToOne && /* @__PURE__ */ jsx65("th", { className: "py-3 font-normal text-left", children: "Actions" })
|
|
5249
5033
|
] }, sectionRowIndex);
|
|
5250
5034
|
}) }),
|
|
5251
|
-
/* @__PURE__ */
|
|
5035
|
+
/* @__PURE__ */ jsx65("tbody", { className: "divide-y divide-gray-200", children: childItemsToRender.map((visibleItem, filteredIndex) => {
|
|
5252
5036
|
const { item, originalIndex } = visibleItem;
|
|
5253
5037
|
const rowKey = originalIndex;
|
|
5254
|
-
return /* @__PURE__ */
|
|
5038
|
+
return /* @__PURE__ */ jsx65(React47.Fragment, { children: section.sectionRows.map(
|
|
5255
5039
|
(sectionRow, sectionRowIndex) => {
|
|
5256
|
-
return /* @__PURE__ */
|
|
5040
|
+
return /* @__PURE__ */ jsxs37(
|
|
5257
5041
|
"tr",
|
|
5258
5042
|
{
|
|
5259
5043
|
className: "",
|
|
5260
5044
|
children: [
|
|
5261
5045
|
sectionRow.elements.map((field, index) => {
|
|
5262
|
-
return /* @__PURE__ */
|
|
5046
|
+
return /* @__PURE__ */ jsx65("td", { children: /* @__PURE__ */ jsx65("div", { className: "flex-1", children: /* @__PURE__ */ jsx65("div", { className: "w-11/12", children: /* @__PURE__ */ jsx65(
|
|
5263
5047
|
InputControl_default,
|
|
5264
5048
|
{
|
|
5265
5049
|
index: filteredIndex,
|
|
@@ -5279,7 +5063,7 @@ var DataFormChildSection = (props) => {
|
|
|
5279
5063
|
}
|
|
5280
5064
|
) }) }) }, field.name);
|
|
5281
5065
|
}),
|
|
5282
|
-
!section.readonly && !isOneToOne && /* @__PURE__ */
|
|
5066
|
+
!section.readonly && !isOneToOne && /* @__PURE__ */ jsx65("td", { children: /* @__PURE__ */ jsx65(
|
|
5283
5067
|
ClientButton_default,
|
|
5284
5068
|
{
|
|
5285
5069
|
ButtonType: StyleTypes2.Hollow,
|
|
@@ -5288,7 +5072,7 @@ var DataFormChildSection = (props) => {
|
|
|
5288
5072
|
},
|
|
5289
5073
|
dataRole: "delete",
|
|
5290
5074
|
tabIndex: -1,
|
|
5291
|
-
children: /* @__PURE__ */
|
|
5075
|
+
children: /* @__PURE__ */ jsx65(
|
|
5292
5076
|
Icon_default,
|
|
5293
5077
|
{
|
|
5294
5078
|
className: "w-4 h-4",
|
|
@@ -5305,7 +5089,7 @@ var DataFormChildSection = (props) => {
|
|
|
5305
5089
|
) }, rowKey);
|
|
5306
5090
|
}) })
|
|
5307
5091
|
] }) }),
|
|
5308
|
-
!section.readonly && !isOneToOne && /* @__PURE__ */
|
|
5092
|
+
!section.readonly && !isOneToOne && /* @__PURE__ */ jsx65("div", { className: "ml-1", children: /* @__PURE__ */ jsx65(
|
|
5309
5093
|
ClientButton_default,
|
|
5310
5094
|
{
|
|
5311
5095
|
ButtonType: "Link" /* Link */,
|
|
@@ -5320,7 +5104,7 @@ var DataFormChildSection = (props) => {
|
|
|
5320
5104
|
var DataFormChildSection_default = DataFormChildSection;
|
|
5321
5105
|
|
|
5322
5106
|
// src/components/dataForm/DataForm.tsx
|
|
5323
|
-
import { jsx as
|
|
5107
|
+
import { jsx as jsx66, jsxs as jsxs38 } from "react/jsx-runtime";
|
|
5324
5108
|
var DataForm = (props) => {
|
|
5325
5109
|
const formRef = useRef4(null);
|
|
5326
5110
|
console.log(props.dataItem, "dssads");
|
|
@@ -5540,19 +5324,19 @@ var DataForm = (props) => {
|
|
|
5540
5324
|
return false;
|
|
5541
5325
|
}
|
|
5542
5326
|
}
|
|
5543
|
-
return /* @__PURE__ */
|
|
5544
|
-
props.title && /* @__PURE__ */
|
|
5327
|
+
return /* @__PURE__ */ jsx66(React48.Fragment, { children: /* @__PURE__ */ jsxs38("div", { className: "flex-grow flex flex-col", children: [
|
|
5328
|
+
props.title && /* @__PURE__ */ jsx66("div", { className: "inline-flex items-center gap-2 px-6 py-3 border border-neutral-200 bg-white shadow-sm rounded-t-md", children: /* @__PURE__ */ jsxs38(
|
|
5545
5329
|
"div",
|
|
5546
5330
|
{
|
|
5547
5331
|
className: "inline-flex items-center gap-2 cursor-pointer",
|
|
5548
5332
|
onClick: () => window.history.back(),
|
|
5549
5333
|
children: [
|
|
5550
|
-
/* @__PURE__ */
|
|
5551
|
-
/* @__PURE__ */
|
|
5334
|
+
/* @__PURE__ */ jsx66(Icon_default, { name: "chevronLeft", className: "w-4 h-4 text-primary-800" }),
|
|
5335
|
+
/* @__PURE__ */ jsx66("h2", { className: "text-lg font-semibold text-primary-800", children: props.title })
|
|
5552
5336
|
]
|
|
5553
5337
|
}
|
|
5554
5338
|
) }),
|
|
5555
|
-
/* @__PURE__ */
|
|
5339
|
+
/* @__PURE__ */ jsx66(
|
|
5556
5340
|
"form",
|
|
5557
5341
|
{
|
|
5558
5342
|
className: "group space-y-6 pb-6 overflow-y-auto",
|
|
@@ -5573,8 +5357,8 @@ var DataForm = (props) => {
|
|
|
5573
5357
|
}
|
|
5574
5358
|
}
|
|
5575
5359
|
},
|
|
5576
|
-
children: /* @__PURE__ */
|
|
5577
|
-
return /* @__PURE__ */
|
|
5360
|
+
children: /* @__PURE__ */ jsx66("div", { className: "flex flex-col gap-6", children: props.sections?.map((section, sectionIndex) => {
|
|
5361
|
+
return /* @__PURE__ */ jsx66(React48.Fragment, { children: !section.isChildSection && /* @__PURE__ */ jsxs38("div", { className: " rounded-b-lg bg-white shadow border-neutral-200 border px-8 py-6 ", children: [
|
|
5578
5362
|
section.sectionRows?.map(
|
|
5579
5363
|
(sectionRow, sectionRowIndex) => {
|
|
5580
5364
|
const elementsCount = sectionRow.elements.length;
|
|
@@ -5585,14 +5369,14 @@ var DataForm = (props) => {
|
|
|
5585
5369
|
sectionRow.visible
|
|
5586
5370
|
);
|
|
5587
5371
|
}
|
|
5588
|
-
return /* @__PURE__ */
|
|
5589
|
-
return /* @__PURE__ */
|
|
5372
|
+
return /* @__PURE__ */ jsx66(React48.Fragment, { children: isVisible && /* @__PURE__ */ jsx66("div", { className: "lg:flex gap-14 flex-1 mb-4 ", children: sectionRow.elements.map((field, index) => {
|
|
5373
|
+
return /* @__PURE__ */ jsxs38(
|
|
5590
5374
|
"div",
|
|
5591
5375
|
{
|
|
5592
5376
|
className: sectionRow.grow ? "grow" : "",
|
|
5593
5377
|
children: [
|
|
5594
|
-
/* @__PURE__ */
|
|
5595
|
-
/* @__PURE__ */
|
|
5378
|
+
/* @__PURE__ */ jsx66("div", { children: field.controlType }),
|
|
5379
|
+
/* @__PURE__ */ jsx66(
|
|
5596
5380
|
InputControl_default,
|
|
5597
5381
|
{
|
|
5598
5382
|
name: field.name,
|
|
@@ -5622,12 +5406,12 @@ var DataForm = (props) => {
|
|
|
5622
5406
|
}) }) }, sectionRowIndex);
|
|
5623
5407
|
}
|
|
5624
5408
|
),
|
|
5625
|
-
/* @__PURE__ */
|
|
5409
|
+
/* @__PURE__ */ jsx66("div", { children: section.childSections?.map(
|
|
5626
5410
|
(childSection, childSectionIndex) => {
|
|
5627
|
-
return /* @__PURE__ */
|
|
5411
|
+
return /* @__PURE__ */ jsx66("div", { children: childSection.name && evalutateCondition(
|
|
5628
5412
|
formState.inputValues,
|
|
5629
5413
|
childSection.visible
|
|
5630
|
-
) && /* @__PURE__ */
|
|
5414
|
+
) && /* @__PURE__ */ jsx66(
|
|
5631
5415
|
DataFormChildSection_default,
|
|
5632
5416
|
{
|
|
5633
5417
|
section: childSection,
|
|
@@ -5642,8 +5426,8 @@ var DataForm = (props) => {
|
|
|
5642
5426
|
}) })
|
|
5643
5427
|
}
|
|
5644
5428
|
),
|
|
5645
|
-
/* @__PURE__ */
|
|
5646
|
-
/* @__PURE__ */
|
|
5429
|
+
/* @__PURE__ */ jsxs38("div", { className: "flex px-6 py-3 mt-2 mb-2 justify-end items-center gap-5", children: [
|
|
5430
|
+
/* @__PURE__ */ jsx66("div", { children: props.additionalActions && /* @__PURE__ */ jsx66(
|
|
5647
5431
|
Button_default,
|
|
5648
5432
|
{
|
|
5649
5433
|
ButtonType: "PrimaryHollow" /* Hollow */,
|
|
@@ -5651,7 +5435,7 @@ var DataForm = (props) => {
|
|
|
5651
5435
|
children: props.additionalActions.title
|
|
5652
5436
|
}
|
|
5653
5437
|
) }),
|
|
5654
|
-
/* @__PURE__ */
|
|
5438
|
+
/* @__PURE__ */ jsx66("div", { children: props.onDelete && /* @__PURE__ */ jsx66(
|
|
5655
5439
|
Button_default,
|
|
5656
5440
|
{
|
|
5657
5441
|
ButtonType: "PrimaryHollow" /* Hollow */,
|
|
@@ -5662,7 +5446,7 @@ var DataForm = (props) => {
|
|
|
5662
5446
|
children: "Delete"
|
|
5663
5447
|
}
|
|
5664
5448
|
) }),
|
|
5665
|
-
/* @__PURE__ */
|
|
5449
|
+
/* @__PURE__ */ jsx66("div", { children: props.onClick && /* @__PURE__ */ jsx66(
|
|
5666
5450
|
Button_default,
|
|
5667
5451
|
{
|
|
5668
5452
|
onValidate,
|
|
@@ -5679,7 +5463,7 @@ var DataForm = (props) => {
|
|
|
5679
5463
|
var DataForm_default = DataForm;
|
|
5680
5464
|
|
|
5681
5465
|
// src/components/dataForm/DataFormRenderer.tsx
|
|
5682
|
-
import { jsx as
|
|
5466
|
+
import { jsx as jsx67, jsxs as jsxs39 } from "react/jsx-runtime";
|
|
5683
5467
|
function getAction(actions, code) {
|
|
5684
5468
|
return actions?.find((a) => a.actionCode === code);
|
|
5685
5469
|
}
|
|
@@ -5705,9 +5489,9 @@ var DataFormRenderer = ({
|
|
|
5705
5489
|
"Delete"
|
|
5706
5490
|
);
|
|
5707
5491
|
const hasDataItem = dataItem && Object.keys(dataItem).length > 0;
|
|
5708
|
-
return /* @__PURE__ */
|
|
5709
|
-
widgetProps && /* @__PURE__ */
|
|
5710
|
-
/* @__PURE__ */
|
|
5492
|
+
return /* @__PURE__ */ jsxs39("div", { className: "flex-grow flex flex-col", children: [
|
|
5493
|
+
widgetProps && /* @__PURE__ */ jsx67(NavigationTabsV2_default, { tabs, params: widgetProps.params }),
|
|
5494
|
+
/* @__PURE__ */ jsx67(
|
|
5711
5495
|
DataForm_default,
|
|
5712
5496
|
{
|
|
5713
5497
|
title: !isAddPage ? "Edit " + formDefinition.formTitle + "- v2" : "Add " + formDefinition.formTitle + "- v2",
|