@clyrex-digital/clyrex-controls-dev 0.8.1-dev.20260722112436 → 0.8.1-dev.20260723122345
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/{LinkNodeButton-U7T2NP22.mjs → LinkNodeButton-KZRNRJRI.mjs} +139 -46
- package/dist/index.js +2 -0
- package/dist/index.mjs +19 -17
- package/dist/server.js +242 -119
- package/dist/server.mjs +76 -51
- package/package.json +6 -5
- package/dist/DateTimeViewClient-22GW4AD7.mjs +0 -14
- package/dist/DateTimeViewClient-R3M6ISVK.mjs +0 -16
- package/dist/DateViewClient-ELEHLGWS.mjs +0 -7
- package/dist/DateViewClient-VLTRN47D.mjs +0 -9
- package/dist/EnterAnimationClient-4OKXLKSA.mjs +0 -45
- package/dist/EnterAnimationClient-ZN3NLFNO.mjs +0 -47
- package/dist/InputControlClient-AZRPSTUZ.mjs +0 -677
- package/dist/InputControlClient-BUOYZNWQ.mjs +0 -675
- package/dist/InputControlClient-HIZOJLKW.mjs +0 -677
- package/dist/LinkNodeButton-BIZA2NPE.mjs +0 -225
- package/dist/LinkNodeButton-LX3KKGZY.mjs +0 -173
- package/dist/Pagination-NCJCOYHF.mjs +0 -181
- package/dist/Pagination-OQT7Q2XO.mjs +0 -183
- package/dist/chunk-3R4VVVNK.mjs +0 -903
- package/dist/chunk-DBHUCH4B.mjs +0 -109
- package/dist/chunk-FI2KJBK2.mjs +0 -110
- package/dist/chunk-JKP4XOZB.mjs +0 -214
- package/dist/chunk-OGGIS4AN.mjs +0 -201
- package/dist/chunk-RHVNJMS4.mjs +0 -251
- package/dist/chunk-SPRVN5IM.mjs +0 -118
- package/dist/chunk-UFKPTMM7.mjs +0 -199
- package/dist/chunk-XG6SXZWP.mjs +0 -115
- package/dist/chunk-YG6FKKQJ.mjs +0 -900
package/dist/server.js
CHANGED
|
@@ -852,7 +852,9 @@ var init_Button = __esm({
|
|
|
852
852
|
event.preventDefault();
|
|
853
853
|
event.stopPropagation();
|
|
854
854
|
if (props.confirm) {
|
|
855
|
-
const confirmed = await showConfirmation(
|
|
855
|
+
const confirmed = await showConfirmation(
|
|
856
|
+
"Are you sure you want to delete this item?"
|
|
857
|
+
);
|
|
856
858
|
setShowModal(null);
|
|
857
859
|
if (!confirmed) {
|
|
858
860
|
return;
|
|
@@ -867,7 +869,9 @@ var init_Button = __esm({
|
|
|
867
869
|
isValid = await props.onValidate();
|
|
868
870
|
if (!isValid) {
|
|
869
871
|
setInProgress(false);
|
|
870
|
-
ToastService_default.showError(
|
|
872
|
+
ToastService_default.showError(
|
|
873
|
+
"There are errors in the form. Please fix them before proceeding."
|
|
874
|
+
);
|
|
871
875
|
return;
|
|
872
876
|
}
|
|
873
877
|
}
|
|
@@ -891,7 +895,16 @@ var init_Button = __esm({
|
|
|
891
895
|
return new Promise((resolve) => {
|
|
892
896
|
const onConfirm = () => resolve(true);
|
|
893
897
|
const onCancel = () => resolve(false);
|
|
894
|
-
setShowModal(
|
|
898
|
+
setShowModal(
|
|
899
|
+
/* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
|
|
900
|
+
Confirm_default,
|
|
901
|
+
{
|
|
902
|
+
message: props.confirmationMessage,
|
|
903
|
+
onConfirm,
|
|
904
|
+
onCancel
|
|
905
|
+
}
|
|
906
|
+
)
|
|
907
|
+
);
|
|
895
908
|
});
|
|
896
909
|
};
|
|
897
910
|
let buttonClass = props.ButtonType ? buttonClasses.get(props.ButtonType) : buttonClasses.get("Primary" /* Solid */);
|
|
@@ -905,13 +918,39 @@ var init_Button = __esm({
|
|
|
905
918
|
onClick: execute,
|
|
906
919
|
disabled: props.disabled,
|
|
907
920
|
title: isDisabled ? "The button is disabled to prevent any action" : "",
|
|
908
|
-
className: buttonClass
|
|
921
|
+
className: `${buttonClass} relative inline-flex items-center justify-center gap-2 ${props.className ?? ""}`,
|
|
909
922
|
children: [
|
|
910
923
|
isActionPerformed && props.oneTimeAction && responseMessage ? responseMessage : props.children,
|
|
911
|
-
inProgress && /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
|
|
924
|
+
inProgress && /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_jsx_runtime9.Fragment, { children: props.hideProgressIndicator ? /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("div", { className: "absolute bottom-0 left-0 h-0.5 bg-gray-400 rounded animate-progress" }) : /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(
|
|
925
|
+
"svg",
|
|
926
|
+
{
|
|
927
|
+
className: `animate-spin h-5 w-5 flex-shrink-0 ${progressClass}`,
|
|
928
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
929
|
+
fill: "none",
|
|
930
|
+
viewBox: "0 0 24 24",
|
|
931
|
+
children: [
|
|
932
|
+
/* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
|
|
933
|
+
"circle",
|
|
934
|
+
{
|
|
935
|
+
className: "opacity-25",
|
|
936
|
+
cx: "12",
|
|
937
|
+
cy: "12",
|
|
938
|
+
r: "10",
|
|
939
|
+
stroke: "currentColor",
|
|
940
|
+
strokeWidth: "4"
|
|
941
|
+
}
|
|
942
|
+
),
|
|
943
|
+
/* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
|
|
944
|
+
"path",
|
|
945
|
+
{
|
|
946
|
+
className: "opacity-75",
|
|
947
|
+
fill: "currentColor",
|
|
948
|
+
d: "M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"
|
|
949
|
+
}
|
|
950
|
+
)
|
|
951
|
+
]
|
|
952
|
+
}
|
|
953
|
+
) })
|
|
915
954
|
]
|
|
916
955
|
}
|
|
917
956
|
),
|
|
@@ -1154,6 +1193,8 @@ var init_LinkNodeButton = __esm({
|
|
|
1154
1193
|
LinkNodeButton = (props) => {
|
|
1155
1194
|
const { node, dataitem, children, linkText, linkType, linkUrl } = props;
|
|
1156
1195
|
const [isLoading, setIsLoading] = (0, import_react5.useState)(false);
|
|
1196
|
+
const [successMessage, setSuccessMessage] = (0, import_react5.useState)(null);
|
|
1197
|
+
console.log("LinkNodeButton props:", props);
|
|
1157
1198
|
const extractFieldNames = (0, import_react5.useCallback)((template) => {
|
|
1158
1199
|
if (!template) return [];
|
|
1159
1200
|
const regex = /\{(\{\})?([a-zA-Z_$][a-zA-Z0-9_$]*)(?:\}\})?\}/g;
|
|
@@ -1161,35 +1202,38 @@ var init_LinkNodeButton = __esm({
|
|
|
1161
1202
|
const fieldNames = matches.map((match) => match[2] || match[1]).filter((name, index, self) => self.indexOf(name) === index);
|
|
1162
1203
|
return fieldNames;
|
|
1163
1204
|
}, []);
|
|
1164
|
-
const replaceTemplateVariables = (0, import_react5.useCallback)(
|
|
1165
|
-
|
|
1166
|
-
|
|
1167
|
-
|
|
1168
|
-
|
|
1169
|
-
|
|
1170
|
-
|
|
1171
|
-
|
|
1172
|
-
|
|
1173
|
-
|
|
1174
|
-
|
|
1175
|
-
|
|
1176
|
-
|
|
1177
|
-
|
|
1178
|
-
|
|
1179
|
-
|
|
1180
|
-
|
|
1181
|
-
|
|
1182
|
-
|
|
1183
|
-
|
|
1184
|
-
|
|
1185
|
-
|
|
1186
|
-
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1205
|
+
const replaceTemplateVariables = (0, import_react5.useCallback)(
|
|
1206
|
+
(template, responseData) => {
|
|
1207
|
+
if (!template) return template;
|
|
1208
|
+
let result = template;
|
|
1209
|
+
const fieldNames = extractFieldNames(template);
|
|
1210
|
+
if (responseData) {
|
|
1211
|
+
fieldNames.forEach((fieldName) => {
|
|
1212
|
+
const value = getNestedValue7(responseData, fieldName);
|
|
1213
|
+
if (value !== void 0) {
|
|
1214
|
+
const regex1 = new RegExp(`\\{${fieldName}\\}`, "g");
|
|
1215
|
+
const regex2 = new RegExp(`\\{\\{${fieldName}\\}\\}`, "g");
|
|
1216
|
+
result = result.replace(regex1, String(value));
|
|
1217
|
+
result = result.replace(regex2, String(value));
|
|
1218
|
+
}
|
|
1219
|
+
});
|
|
1220
|
+
}
|
|
1221
|
+
if (props.routeParameters) {
|
|
1222
|
+
Object.entries(props.routeParameters).forEach(([key, value]) => {
|
|
1223
|
+
const regex = new RegExp(`\\{\\{${key}\\}\\}`, "g");
|
|
1224
|
+
result = result.replace(regex, String(value));
|
|
1225
|
+
});
|
|
1226
|
+
}
|
|
1227
|
+
if (dataitem) {
|
|
1228
|
+
Object.entries(dataitem).forEach(([key, value]) => {
|
|
1229
|
+
const regex = new RegExp(`\\{\\{${key}\\}\\}`, "g");
|
|
1230
|
+
result = result.replace(regex, String(value));
|
|
1231
|
+
});
|
|
1232
|
+
}
|
|
1233
|
+
return result;
|
|
1234
|
+
},
|
|
1235
|
+
[props.routeParameters, dataitem, extractFieldNames]
|
|
1236
|
+
);
|
|
1193
1237
|
const getNestedValue7 = (0, import_react5.useCallback)((obj, path) => {
|
|
1194
1238
|
if (!obj || !path) return void 0;
|
|
1195
1239
|
if (obj[path] !== void 0) {
|
|
@@ -1207,7 +1251,10 @@ var init_LinkNodeButton = __esm({
|
|
|
1207
1251
|
}, []);
|
|
1208
1252
|
const onClick = (0, import_react5.useCallback)(async () => {
|
|
1209
1253
|
if (!node.postUrl) {
|
|
1210
|
-
return {
|
|
1254
|
+
return {
|
|
1255
|
+
isSuccessful: false,
|
|
1256
|
+
message: "No POST URL configured for this button"
|
|
1257
|
+
};
|
|
1211
1258
|
}
|
|
1212
1259
|
setIsLoading(true);
|
|
1213
1260
|
try {
|
|
@@ -1233,6 +1280,7 @@ var init_LinkNodeButton = __esm({
|
|
|
1233
1280
|
}
|
|
1234
1281
|
if (response?.message) {
|
|
1235
1282
|
ToastService_default.showSuccess(response.message);
|
|
1283
|
+
setSuccessMessage(response.message);
|
|
1236
1284
|
}
|
|
1237
1285
|
if (response && node.redirectUrl) {
|
|
1238
1286
|
const fieldNames = extractFieldNames(node.redirectUrl);
|
|
@@ -1255,7 +1303,9 @@ var init_LinkNodeButton = __esm({
|
|
|
1255
1303
|
}
|
|
1256
1304
|
});
|
|
1257
1305
|
console.log("Field value map:", fieldValueMap);
|
|
1258
|
-
const missingFields = fieldNames.filter(
|
|
1306
|
+
const missingFields = fieldNames.filter(
|
|
1307
|
+
(fieldName) => !fieldValueMap[fieldName]
|
|
1308
|
+
);
|
|
1259
1309
|
if (missingFields.length > 0) {
|
|
1260
1310
|
console.warn(`Missing field values for: ${missingFields.join(", ")}`);
|
|
1261
1311
|
}
|
|
@@ -1266,7 +1316,10 @@ var init_LinkNodeButton = __esm({
|
|
|
1266
1316
|
resolvedRedirectUrl = resolvedRedirectUrl.replace(regex1, value);
|
|
1267
1317
|
resolvedRedirectUrl = resolvedRedirectUrl.replace(regex2, value);
|
|
1268
1318
|
});
|
|
1269
|
-
resolvedRedirectUrl = replaceTemplateVariables(
|
|
1319
|
+
resolvedRedirectUrl = replaceTemplateVariables(
|
|
1320
|
+
resolvedRedirectUrl,
|
|
1321
|
+
response
|
|
1322
|
+
);
|
|
1270
1323
|
console.log("Final redirect URL:", resolvedRedirectUrl);
|
|
1271
1324
|
if (resolvedRedirectUrl && !resolvedRedirectUrl.includes("{")) {
|
|
1272
1325
|
window.location.href = resolvedRedirectUrl;
|
|
@@ -1277,14 +1330,27 @@ var init_LinkNodeButton = __esm({
|
|
|
1277
1330
|
return { isSuccessful: false, message: errorMessage };
|
|
1278
1331
|
}
|
|
1279
1332
|
setIsLoading(false);
|
|
1280
|
-
return {
|
|
1333
|
+
return {
|
|
1334
|
+
isSuccessful: true,
|
|
1335
|
+
message: response?.message,
|
|
1336
|
+
result: response
|
|
1337
|
+
};
|
|
1281
1338
|
} catch (err) {
|
|
1282
1339
|
console.error("Button API call failed:", err);
|
|
1283
1340
|
const errorMessage = err.message || "An unexpected error occurred";
|
|
1284
1341
|
setIsLoading(false);
|
|
1285
1342
|
return { isSuccessful: false, message: errorMessage };
|
|
1286
1343
|
}
|
|
1287
|
-
}, [
|
|
1344
|
+
}, [
|
|
1345
|
+
node.postUrl,
|
|
1346
|
+
node.payload,
|
|
1347
|
+
node.redirectUrl,
|
|
1348
|
+
replaceTemplateVariables,
|
|
1349
|
+
extractFieldNames,
|
|
1350
|
+
getNestedValue7,
|
|
1351
|
+
props.apiBaseUrl,
|
|
1352
|
+
props.session
|
|
1353
|
+
]);
|
|
1288
1354
|
const renderButtonContent = () => {
|
|
1289
1355
|
if (children) {
|
|
1290
1356
|
return children;
|
|
@@ -1294,14 +1360,41 @@ var init_LinkNodeButton = __esm({
|
|
|
1294
1360
|
}
|
|
1295
1361
|
return node.title || "Button";
|
|
1296
1362
|
};
|
|
1363
|
+
const fontSize = node.children?.[0]?.style?.match(/font-size:\s*([^;]+)/)?.[1];
|
|
1297
1364
|
return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("div", { className: "link-button-wrapper", children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
|
|
1298
1365
|
Button_default,
|
|
1299
1366
|
{
|
|
1300
1367
|
ButtonType: linkType,
|
|
1301
1368
|
onClick,
|
|
1302
|
-
disabled: isLoading,
|
|
1369
|
+
disabled: isLoading || !!successMessage,
|
|
1303
1370
|
className: "w-full",
|
|
1304
|
-
children:
|
|
1371
|
+
children: successMessage ? /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(
|
|
1372
|
+
"span",
|
|
1373
|
+
{
|
|
1374
|
+
style: fontSize ? { fontSize } : void 0,
|
|
1375
|
+
className: "inline-flex items-center gap-2",
|
|
1376
|
+
children: [
|
|
1377
|
+
/* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
|
|
1378
|
+
"svg",
|
|
1379
|
+
{
|
|
1380
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
1381
|
+
viewBox: "0 0 20 20",
|
|
1382
|
+
fill: "currentColor",
|
|
1383
|
+
className: "w-5 h-5",
|
|
1384
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
|
|
1385
|
+
"path",
|
|
1386
|
+
{
|
|
1387
|
+
fillRule: "evenodd",
|
|
1388
|
+
d: "M16.704 5.29a1 1 0 010 1.42l-7.25 7.25a1 1 0 01-1.415 0L3.29 9.21a1 1 0 111.415-1.414l4.042 4.042 6.543-6.543a1 1 0 011.414 0z",
|
|
1389
|
+
clipRule: "evenodd"
|
|
1390
|
+
}
|
|
1391
|
+
)
|
|
1392
|
+
}
|
|
1393
|
+
),
|
|
1394
|
+
/* @__PURE__ */ (0, import_jsx_runtime10.jsx)("span", { children: successMessage })
|
|
1395
|
+
]
|
|
1396
|
+
}
|
|
1397
|
+
) : renderButtonContent()
|
|
1305
1398
|
}
|
|
1306
1399
|
) });
|
|
1307
1400
|
};
|
|
@@ -1314,13 +1407,42 @@ var DateViewClient_exports = {};
|
|
|
1314
1407
|
__export(DateViewClient_exports, {
|
|
1315
1408
|
default: () => DateViewClient_default
|
|
1316
1409
|
});
|
|
1317
|
-
var import_react8, import_jsx_runtime15, DateViewClient, DateViewClient_default;
|
|
1410
|
+
var import_react8, import_jsx_runtime15, dateFormatter, timeFormatterNoSeconds, timeFormatterWithSeconds, dateTimeFormatterNoSeconds, dateTimeFormatterWithSeconds, DateViewClient, DateViewClient_default;
|
|
1318
1411
|
var init_DateViewClient = __esm({
|
|
1319
1412
|
"src/components/controls/view/DateViewClient.tsx"() {
|
|
1320
1413
|
"use strict";
|
|
1321
1414
|
"use client";
|
|
1322
1415
|
import_react8 = require("react");
|
|
1323
1416
|
import_jsx_runtime15 = require("react/jsx-runtime");
|
|
1417
|
+
dateFormatter = new Intl.DateTimeFormat("en", {
|
|
1418
|
+
day: "2-digit",
|
|
1419
|
+
month: "short",
|
|
1420
|
+
year: "numeric"
|
|
1421
|
+
});
|
|
1422
|
+
timeFormatterNoSeconds = new Intl.DateTimeFormat("en", {
|
|
1423
|
+
hour: "2-digit",
|
|
1424
|
+
minute: "2-digit"
|
|
1425
|
+
});
|
|
1426
|
+
timeFormatterWithSeconds = new Intl.DateTimeFormat("en", {
|
|
1427
|
+
hour: "2-digit",
|
|
1428
|
+
minute: "2-digit",
|
|
1429
|
+
second: "2-digit"
|
|
1430
|
+
});
|
|
1431
|
+
dateTimeFormatterNoSeconds = new Intl.DateTimeFormat("en", {
|
|
1432
|
+
day: "2-digit",
|
|
1433
|
+
month: "short",
|
|
1434
|
+
year: "numeric",
|
|
1435
|
+
hour: "2-digit",
|
|
1436
|
+
minute: "2-digit"
|
|
1437
|
+
});
|
|
1438
|
+
dateTimeFormatterWithSeconds = new Intl.DateTimeFormat("en", {
|
|
1439
|
+
day: "2-digit",
|
|
1440
|
+
month: "short",
|
|
1441
|
+
year: "numeric",
|
|
1442
|
+
hour: "2-digit",
|
|
1443
|
+
minute: "2-digit",
|
|
1444
|
+
second: "2-digit"
|
|
1445
|
+
});
|
|
1324
1446
|
DateViewClient = (props) => {
|
|
1325
1447
|
const [timeZoneAbbr, setTimeZoneAbbr] = (0, import_react8.useState)("");
|
|
1326
1448
|
(0, import_react8.useEffect)(() => {
|
|
@@ -1345,37 +1467,13 @@ var init_DateViewClient = __esm({
|
|
|
1345
1467
|
return date;
|
|
1346
1468
|
};
|
|
1347
1469
|
const formatDate = (date) => {
|
|
1348
|
-
return
|
|
1349
|
-
day: "2-digit",
|
|
1350
|
-
month: "short",
|
|
1351
|
-
year: "numeric"
|
|
1352
|
-
}).format(date);
|
|
1470
|
+
return dateFormatter.format(date);
|
|
1353
1471
|
};
|
|
1354
1472
|
const formatTime = (date) => {
|
|
1355
|
-
return date.getSeconds() === 0 ?
|
|
1356
|
-
hour: "2-digit",
|
|
1357
|
-
minute: "2-digit"
|
|
1358
|
-
}).format(date) : new Intl.DateTimeFormat("en", {
|
|
1359
|
-
hour: "2-digit",
|
|
1360
|
-
minute: "2-digit",
|
|
1361
|
-
second: "2-digit"
|
|
1362
|
-
}).format(date);
|
|
1473
|
+
return date.getSeconds() === 0 ? timeFormatterNoSeconds.format(date) : timeFormatterWithSeconds.format(date);
|
|
1363
1474
|
};
|
|
1364
1475
|
const formatDateTime = (date) => {
|
|
1365
|
-
return date.getSeconds() === 0 ?
|
|
1366
|
-
day: "2-digit",
|
|
1367
|
-
month: "short",
|
|
1368
|
-
year: "numeric",
|
|
1369
|
-
hour: "2-digit",
|
|
1370
|
-
minute: "2-digit"
|
|
1371
|
-
}).format(date) : new Intl.DateTimeFormat("en", {
|
|
1372
|
-
day: "2-digit",
|
|
1373
|
-
month: "short",
|
|
1374
|
-
year: "numeric",
|
|
1375
|
-
hour: "2-digit",
|
|
1376
|
-
minute: "2-digit",
|
|
1377
|
-
second: "2-digit"
|
|
1378
|
-
}).format(date);
|
|
1476
|
+
return date.getSeconds() === 0 ? dateTimeFormatterNoSeconds.format(date) : dateTimeFormatterWithSeconds.format(date);
|
|
1379
1477
|
};
|
|
1380
1478
|
const getTimePeriod = (date) => {
|
|
1381
1479
|
const hours = date.getHours();
|
|
@@ -3632,6 +3730,17 @@ var EmbedNode_default = EmbedNode;
|
|
|
3632
3730
|
init_ServiceClient();
|
|
3633
3731
|
|
|
3634
3732
|
// src/components/utilities/AnimationUtility.tsx
|
|
3733
|
+
var normalizeSelector = (guid) => {
|
|
3734
|
+
const trimmedGuid = guid?.trim();
|
|
3735
|
+
if (!trimmedGuid) {
|
|
3736
|
+
return ".animation-fallback";
|
|
3737
|
+
}
|
|
3738
|
+
const baseValue = trimmedGuid.replace(/^#/, "").replace(/^\./, "");
|
|
3739
|
+
if (typeof CSS !== "undefined" && typeof CSS.escape === "function") {
|
|
3740
|
+
return `#${CSS.escape(baseValue)}`;
|
|
3741
|
+
}
|
|
3742
|
+
return `#${baseValue}`;
|
|
3743
|
+
};
|
|
3635
3744
|
var AnimationUtility = class {
|
|
3636
3745
|
static generateAnimationCSS(config, guid) {
|
|
3637
3746
|
const {
|
|
@@ -3646,10 +3755,12 @@ var AnimationUtility = class {
|
|
|
3646
3755
|
speedPerChar = 100,
|
|
3647
3756
|
cursor = true,
|
|
3648
3757
|
mode = "enter",
|
|
3649
|
-
direction = "left"
|
|
3650
|
-
|
|
3758
|
+
direction = "left",
|
|
3759
|
+
backgroundColor,
|
|
3760
|
+
borderColor
|
|
3651
3761
|
} = config;
|
|
3652
3762
|
let base = "", visible = "", keyframes = "";
|
|
3763
|
+
const selector = normalizeSelector(guid);
|
|
3653
3764
|
switch (config.animation) {
|
|
3654
3765
|
case "Fade":
|
|
3655
3766
|
base = `opacity:0; transition:opacity ${duration}ms ${easing} ${delay}ms;`;
|
|
@@ -3683,12 +3794,20 @@ var AnimationUtility = class {
|
|
|
3683
3794
|
`;
|
|
3684
3795
|
if (mode === "enter") {
|
|
3685
3796
|
base = `opacity:0;`;
|
|
3686
|
-
visible = `opacity:1; animation:bounce ${duration}ms ${easing} ${delay}ms ${repeat};`;
|
|
3797
|
+
visible = `opacity:1; animation: bounce ${duration}ms ${easing} ${delay}ms ${repeat};`;
|
|
3687
3798
|
} else {
|
|
3688
3799
|
base = ``;
|
|
3689
|
-
visible = `animation:bounce ${duration / 1e3}s ${easing} ${delay / 1e3}s ${repeat};`;
|
|
3800
|
+
visible = `animation: bounce ${duration / 1e3}s ${easing} ${delay / 1e3}s ${repeat};`;
|
|
3690
3801
|
}
|
|
3691
3802
|
break;
|
|
3803
|
+
case "Background":
|
|
3804
|
+
base = `transition: background-color ${duration}ms ${easing} ${delay}ms;`;
|
|
3805
|
+
visible = `background-color: ${backgroundColor};`;
|
|
3806
|
+
break;
|
|
3807
|
+
case "Border":
|
|
3808
|
+
base = `transition: border-color ${duration}ms ${easing} ${delay}ms;`;
|
|
3809
|
+
visible = `border-color: ${borderColor};`;
|
|
3810
|
+
break;
|
|
3692
3811
|
case "Typewriter":
|
|
3693
3812
|
keyframes = `
|
|
3694
3813
|
@keyframes typewriter { from { width: 0 } to { width: 100% } }
|
|
@@ -3710,14 +3829,14 @@ var AnimationUtility = class {
|
|
|
3710
3829
|
if (mode === "hover") {
|
|
3711
3830
|
return `
|
|
3712
3831
|
${keyframes}
|
|
3713
|
-
${
|
|
3714
|
-
${
|
|
3832
|
+
${selector} { ${base} }
|
|
3833
|
+
${selector}:hover { ${visible} }
|
|
3715
3834
|
`;
|
|
3716
3835
|
} else {
|
|
3717
3836
|
return `
|
|
3718
3837
|
${keyframes}
|
|
3719
|
-
${
|
|
3720
|
-
${
|
|
3838
|
+
${selector} { ${base} }
|
|
3839
|
+
${selector}.visible { ${visible} }
|
|
3721
3840
|
`;
|
|
3722
3841
|
}
|
|
3723
3842
|
}
|
|
@@ -4847,6 +4966,7 @@ var DivContainer = async (props) => {
|
|
|
4847
4966
|
}
|
|
4848
4967
|
const updatedStyle = { ...updatedStyles };
|
|
4849
4968
|
const guid = "css" + crypto.randomUUID().toLocaleLowerCase();
|
|
4969
|
+
const animationSelector = `#${guid}`;
|
|
4850
4970
|
const { enterAnimation, exitAnimation, hoverAnimation } = props.node;
|
|
4851
4971
|
let animationCSS = "";
|
|
4852
4972
|
if (enterAnimation?.name) {
|
|
@@ -4856,7 +4976,7 @@ var DivContainer = async (props) => {
|
|
|
4856
4976
|
mode: "enter",
|
|
4857
4977
|
...enterAnimation.properties
|
|
4858
4978
|
},
|
|
4859
|
-
|
|
4979
|
+
animationSelector
|
|
4860
4980
|
);
|
|
4861
4981
|
}
|
|
4862
4982
|
if (hoverAnimation?.name) {
|
|
@@ -4866,7 +4986,7 @@ var DivContainer = async (props) => {
|
|
|
4866
4986
|
mode: "hover",
|
|
4867
4987
|
...hoverAnimation.properties
|
|
4868
4988
|
},
|
|
4869
|
-
|
|
4989
|
+
animationSelector
|
|
4870
4990
|
);
|
|
4871
4991
|
}
|
|
4872
4992
|
const isHidden = !shouldRenderContainer(
|
|
@@ -5129,46 +5249,49 @@ var PageBodyRenderer = (props) => {
|
|
|
5129
5249
|
}
|
|
5130
5250
|
return true;
|
|
5131
5251
|
};
|
|
5132
|
-
return /* @__PURE__ */ (0, import_jsx_runtime54.
|
|
5133
|
-
{
|
|
5134
|
-
|
|
5135
|
-
const SelectedNode = NodeTypes[node.type];
|
|
5136
|
-
if (!shouldRenderNode(node)) {
|
|
5137
|
-
return null;
|
|
5138
|
-
}
|
|
5139
|
-
return /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_react34.default.Fragment, { children: SelectedNode && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_react34.default.Fragment, { children: node.type == "layout-container" ? /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_react34.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
|
|
5140
|
-
SelectedNode,
|
|
5252
|
+
return /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(import_react34.default.Fragment, { children: [
|
|
5253
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsx)("div", { children: "Thuis isadiasdia testaststtstst" }),
|
|
5254
|
+
rootNode && rootNode?.children?.map((node, index) => {
|
|
5141
5255
|
{
|
|
5142
|
-
node,
|
|
5143
|
-
firstNode: true,
|
|
5144
|
-
routeParameters: props.routeParameters,
|
|
5145
|
-
query: props.query,
|
|
5146
|
-
session: props.session,
|
|
5147
|
-
host: props.host,
|
|
5148
|
-
path: props.path,
|
|
5149
|
-
apiBaseUrl: props.apiBaseUrl,
|
|
5150
|
-
serviceClient: props.serviceClient,
|
|
5151
|
-
assetBaseUrl: props.assetBaseUrl,
|
|
5152
|
-
device: props.device,
|
|
5153
|
-
widgetRenderer: props.widgetRenderer
|
|
5154
5256
|
}
|
|
5155
|
-
|
|
5156
|
-
|
|
5157
|
-
|
|
5158
|
-
node,
|
|
5159
|
-
routeParameters: props.routeParameters,
|
|
5160
|
-
query: props.query,
|
|
5161
|
-
session: props.session,
|
|
5162
|
-
host: props.host,
|
|
5163
|
-
path: props.path,
|
|
5164
|
-
apiBaseUrl: props.apiBaseUrl,
|
|
5165
|
-
serviceClient: props.serviceClient,
|
|
5166
|
-
assetBaseUrl: props.assetBaseUrl,
|
|
5167
|
-
device: props.device,
|
|
5168
|
-
widgetRenderer: props.widgetRenderer
|
|
5257
|
+
const SelectedNode = NodeTypes[node.type];
|
|
5258
|
+
if (!shouldRenderNode(node)) {
|
|
5259
|
+
return null;
|
|
5169
5260
|
}
|
|
5170
|
-
|
|
5171
|
-
|
|
5261
|
+
return /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_react34.default.Fragment, { children: SelectedNode && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_react34.default.Fragment, { children: node.type == "layout-container" ? /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_react34.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
|
|
5262
|
+
SelectedNode,
|
|
5263
|
+
{
|
|
5264
|
+
node,
|
|
5265
|
+
firstNode: true,
|
|
5266
|
+
routeParameters: props.routeParameters,
|
|
5267
|
+
query: props.query,
|
|
5268
|
+
session: props.session,
|
|
5269
|
+
host: props.host,
|
|
5270
|
+
path: props.path,
|
|
5271
|
+
apiBaseUrl: props.apiBaseUrl,
|
|
5272
|
+
serviceClient: props.serviceClient,
|
|
5273
|
+
assetBaseUrl: props.assetBaseUrl,
|
|
5274
|
+
device: props.device,
|
|
5275
|
+
widgetRenderer: props.widgetRenderer
|
|
5276
|
+
}
|
|
5277
|
+
) }) : /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_react34.default.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
|
|
5278
|
+
SelectedNode,
|
|
5279
|
+
{
|
|
5280
|
+
node,
|
|
5281
|
+
routeParameters: props.routeParameters,
|
|
5282
|
+
query: props.query,
|
|
5283
|
+
session: props.session,
|
|
5284
|
+
host: props.host,
|
|
5285
|
+
path: props.path,
|
|
5286
|
+
apiBaseUrl: props.apiBaseUrl,
|
|
5287
|
+
serviceClient: props.serviceClient,
|
|
5288
|
+
assetBaseUrl: props.assetBaseUrl,
|
|
5289
|
+
device: props.device,
|
|
5290
|
+
widgetRenderer: props.widgetRenderer
|
|
5291
|
+
}
|
|
5292
|
+
) }) }) }, index);
|
|
5293
|
+
})
|
|
5294
|
+
] });
|
|
5172
5295
|
};
|
|
5173
5296
|
var PageBodyRenderer_default = PageBodyRenderer;
|
|
5174
5297
|
// Annotate the CommonJS export names for ESM import in node:
|