evelearn-theme 2.0.12 → 2.0.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +44 -22
- package/dist/index.mjs +45 -23
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -471,18 +471,23 @@ var StepsComponent = function(param) {
|
|
|
471
471
|
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", {
|
|
472
472
|
className: "flex justify-center items-center space-x-2 w-full",
|
|
473
473
|
children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", {
|
|
474
|
-
className: "flex flex-col items-center",
|
|
474
|
+
className: "flex flex-col items-center w-full",
|
|
475
475
|
children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("button", {
|
|
476
476
|
type: "button",
|
|
477
477
|
onClick: function() {
|
|
478
478
|
return onStepPress(index);
|
|
479
479
|
},
|
|
480
|
-
className: "flex items-center space-x-2 px-4 py-2 rounded-lg min-w-10 md:min-w-20 sm:min-w-40 font-header transition-all duration-150\n ".concat(activeStep === index ? "bg-primary text-white shadow-lg scale-110 border-2 border-primary" : "bg-gray-100 dark:bg-slate-800 text-gray-700 dark:text-gray-200 hover:bg-gray-200 dark:hover:bg-slate-700 border-2 border-transparent hover:border-primary/30"),
|
|
481
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("
|
|
480
|
+
className: "flex items-center space-x-2 px-4 py-2 rounded-lg w-full min-w-10 md:min-w-20 sm:min-w-40 font-header transition-all duration-150\n ".concat(activeStep === index ? "bg-primary text-white shadow-lg scale-110 border-2 border-primary" : "bg-gray-100 dark:bg-slate-800 text-gray-700 dark:text-gray-200 hover:bg-gray-200 dark:hover:bg-slate-700 border-2 border-transparent hover:border-primary/30"),
|
|
481
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("p", {
|
|
482
482
|
className: "font-medium truncate",
|
|
483
483
|
children: [
|
|
484
|
-
|
|
485
|
-
|
|
484
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("span", {
|
|
485
|
+
className: "text-gray-500 dark:text-gray-400",
|
|
486
|
+
children: [
|
|
487
|
+
index + 1,
|
|
488
|
+
". "
|
|
489
|
+
]
|
|
490
|
+
}),
|
|
486
491
|
step.label
|
|
487
492
|
]
|
|
488
493
|
})
|
|
@@ -1233,25 +1238,23 @@ var Modal = function(_param) {
|
|
|
1233
1238
|
children: /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)("div", {
|
|
1234
1239
|
className: (0, import_clsx7.default)("relative mx-1 w-full md:mx-auto md:w-3/4 lg:w-1/2", fullscreen && "md:w-5/6 lg:w-5/6"),
|
|
1235
1240
|
children: [
|
|
1236
|
-
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
1237
|
-
|
|
1238
|
-
|
|
1239
|
-
|
|
1240
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("div", {
|
|
1241
|
-
onClick: onDismissed,
|
|
1242
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(XIcon_default, {
|
|
1243
|
-
className: "absolute h-5 w-5 top-7 sm:top-20 right-4 transition-colors cursor-pointer duration-75 hover:text-blue-500 dark:text-gray-200 dark:hover:text-blue-500"
|
|
1244
|
-
})
|
|
1245
|
-
})
|
|
1246
|
-
}) : dismissable ? /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("button", {
|
|
1247
|
-
className: "absolute top-7 sm:top-20 right-4 transition-colors cursor-pointer duration-75 hover:text-blue-500 dark:text-gray-200 dark:hover:text-blue-500",
|
|
1248
|
-
type: "button",
|
|
1241
|
+
dismissLink ? /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_link.default, {
|
|
1242
|
+
href: dismissLink,
|
|
1243
|
+
scroll: false,
|
|
1244
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("div", {
|
|
1249
1245
|
onClick: onDismissed,
|
|
1250
1246
|
children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(XIcon_default, {
|
|
1251
|
-
className: "h-5 w-5"
|
|
1247
|
+
className: "absolute h-5 w-5 top-4 sm:top-8 right-4 transition-colors cursor-pointer duration-75 hover:text-blue-500 dark:text-gray-200 dark:hover:text-blue-500"
|
|
1252
1248
|
})
|
|
1253
|
-
})
|
|
1254
|
-
}),
|
|
1249
|
+
})
|
|
1250
|
+
}) : dismissable ? /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("button", {
|
|
1251
|
+
className: "absolute top-4 sm:top-8 right-4 transition-colors cursor-pointer duration-75 hover:text-blue-500 dark:text-gray-200 dark:hover:text-blue-500",
|
|
1252
|
+
type: "button",
|
|
1253
|
+
onClick: onDismissed,
|
|
1254
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(XIcon_default, {
|
|
1255
|
+
className: "h-5 w-5"
|
|
1256
|
+
})
|
|
1257
|
+
}) : null,
|
|
1255
1258
|
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)("div", {
|
|
1256
1259
|
className: "my-1 sm:mt-16 bg-white dark:bg-slate-900 shadow-lg border border-gray-100 dark:border-none rounded-xl overflow-x-visible overflow-y-visible no-scrollbar",
|
|
1257
1260
|
onClick: function(e) {
|
|
@@ -2075,11 +2078,30 @@ var import_react_dom3 = require("react-dom");
|
|
|
2075
2078
|
var import_jsx_runtime36 = require("react/jsx-runtime");
|
|
2076
2079
|
var OverlaySpinner = function(param) {
|
|
2077
2080
|
var visible = param.visible;
|
|
2078
|
-
var _ref = _sliced_to_array((0, import_react11.useState)(
|
|
2081
|
+
var _ref = _sliced_to_array((0, import_react11.useState)(null), 2), modalRoot = _ref[0], setModalRoot = _ref[1];
|
|
2082
|
+
var _ref1 = _sliced_to_array((0, import_react11.useState)(false), 2), mounted = _ref1[0], setMounted = _ref1[1];
|
|
2079
2083
|
(0, import_react11.useEffect)(function() {
|
|
2080
2084
|
return setMounted(true);
|
|
2081
2085
|
}, []);
|
|
2082
2086
|
if (!mounted) return null;
|
|
2087
|
+
(0, import_react11.useEffect)(function() {
|
|
2088
|
+
if (modalRoot || !visible) return;
|
|
2089
|
+
var root = document.getElementById("spinner-root");
|
|
2090
|
+
if (!root) {
|
|
2091
|
+
root = document.createElement("div");
|
|
2092
|
+
root.id = "spinner-root";
|
|
2093
|
+
document.body.appendChild(root);
|
|
2094
|
+
}
|
|
2095
|
+
setModalRoot(root);
|
|
2096
|
+
return function() {
|
|
2097
|
+
var root2 = document.getElementById("spinner-root");
|
|
2098
|
+
if (root2) {
|
|
2099
|
+
document.body.removeChild(root2);
|
|
2100
|
+
}
|
|
2101
|
+
};
|
|
2102
|
+
}, [
|
|
2103
|
+
visible
|
|
2104
|
+
]);
|
|
2083
2105
|
if (!visible) return null;
|
|
2084
2106
|
return (0, import_react_dom3.createPortal)(/* @__PURE__ */ (0, import_jsx_runtime36.jsx)("div", {
|
|
2085
2107
|
className: "animate-fade-in",
|
package/dist/index.mjs
CHANGED
|
@@ -283,18 +283,23 @@ var StepsComponent = function(param) {
|
|
|
283
283
|
return /* @__PURE__ */ jsx6("div", {
|
|
284
284
|
className: "flex justify-center items-center space-x-2 w-full",
|
|
285
285
|
children: /* @__PURE__ */ jsx6("div", {
|
|
286
|
-
className: "flex flex-col items-center",
|
|
286
|
+
className: "flex flex-col items-center w-full",
|
|
287
287
|
children: /* @__PURE__ */ jsx6("button", {
|
|
288
288
|
type: "button",
|
|
289
289
|
onClick: function() {
|
|
290
290
|
return onStepPress(index);
|
|
291
291
|
},
|
|
292
|
-
className: "flex items-center space-x-2 px-4 py-2 rounded-lg min-w-10 md:min-w-20 sm:min-w-40 font-header transition-all duration-150\n ".concat(activeStep === index ? "bg-primary text-white shadow-lg scale-110 border-2 border-primary" : "bg-gray-100 dark:bg-slate-800 text-gray-700 dark:text-gray-200 hover:bg-gray-200 dark:hover:bg-slate-700 border-2 border-transparent hover:border-primary/30"),
|
|
293
|
-
children: /* @__PURE__ */ jsxs3("
|
|
292
|
+
className: "flex items-center space-x-2 px-4 py-2 rounded-lg w-full min-w-10 md:min-w-20 sm:min-w-40 font-header transition-all duration-150\n ".concat(activeStep === index ? "bg-primary text-white shadow-lg scale-110 border-2 border-primary" : "bg-gray-100 dark:bg-slate-800 text-gray-700 dark:text-gray-200 hover:bg-gray-200 dark:hover:bg-slate-700 border-2 border-transparent hover:border-primary/30"),
|
|
293
|
+
children: /* @__PURE__ */ jsxs3("p", {
|
|
294
294
|
className: "font-medium truncate",
|
|
295
295
|
children: [
|
|
296
|
-
|
|
297
|
-
|
|
296
|
+
/* @__PURE__ */ jsxs3("span", {
|
|
297
|
+
className: "text-gray-500 dark:text-gray-400",
|
|
298
|
+
children: [
|
|
299
|
+
index + 1,
|
|
300
|
+
". "
|
|
301
|
+
]
|
|
302
|
+
}),
|
|
298
303
|
step.label
|
|
299
304
|
]
|
|
300
305
|
})
|
|
@@ -1016,7 +1021,7 @@ var XIcon = function(param) {
|
|
|
1016
1021
|
var XIcon_default = XIcon;
|
|
1017
1022
|
// src/Common/Modal.tsx
|
|
1018
1023
|
import clsx7 from "clsx";
|
|
1019
|
-
import {
|
|
1024
|
+
import { jsx as jsx20, jsxs as jsxs9 } from "react/jsx-runtime";
|
|
1020
1025
|
var Modal = function(_param) {
|
|
1021
1026
|
var visible = _param.visible, children = _param.children, fullscreen = _param.fullscreen, displayDark = _param.displayDark, dismissLink = _param.dismissLink, bgOpacity = _param.bgOpacity, onDismissed = _param.onDismissed, _param_dismissable = _param.dismissable, dismissable = _param_dismissable === void 0 ? true : _param_dismissable, _param_dismissOnBackdropClick = _param.dismissOnBackdropClick, dismissOnBackdropClick = _param_dismissOnBackdropClick === void 0 ? true : _param_dismissOnBackdropClick, style = _param.style, props = _object_without_properties(_param, [
|
|
1022
1027
|
"visible",
|
|
@@ -1045,25 +1050,23 @@ var Modal = function(_param) {
|
|
|
1045
1050
|
children: /* @__PURE__ */ jsxs9("div", {
|
|
1046
1051
|
className: clsx7("relative mx-1 w-full md:mx-auto md:w-3/4 lg:w-1/2", fullscreen && "md:w-5/6 lg:w-5/6"),
|
|
1047
1052
|
children: [
|
|
1048
|
-
/* @__PURE__ */ jsx20(
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
children: /* @__PURE__ */ jsx20("div", {
|
|
1053
|
-
onClick: onDismissed,
|
|
1054
|
-
children: /* @__PURE__ */ jsx20(XIcon_default, {
|
|
1055
|
-
className: "absolute h-5 w-5 top-7 sm:top-20 right-4 transition-colors cursor-pointer duration-75 hover:text-blue-500 dark:text-gray-200 dark:hover:text-blue-500"
|
|
1056
|
-
})
|
|
1057
|
-
})
|
|
1058
|
-
}) : dismissable ? /* @__PURE__ */ jsx20("button", {
|
|
1059
|
-
className: "absolute top-7 sm:top-20 right-4 transition-colors cursor-pointer duration-75 hover:text-blue-500 dark:text-gray-200 dark:hover:text-blue-500",
|
|
1060
|
-
type: "button",
|
|
1053
|
+
dismissLink ? /* @__PURE__ */ jsx20(Link, {
|
|
1054
|
+
href: dismissLink,
|
|
1055
|
+
scroll: false,
|
|
1056
|
+
children: /* @__PURE__ */ jsx20("div", {
|
|
1061
1057
|
onClick: onDismissed,
|
|
1062
1058
|
children: /* @__PURE__ */ jsx20(XIcon_default, {
|
|
1063
|
-
className: "h-5 w-5"
|
|
1059
|
+
className: "absolute h-5 w-5 top-4 sm:top-8 right-4 transition-colors cursor-pointer duration-75 hover:text-blue-500 dark:text-gray-200 dark:hover:text-blue-500"
|
|
1064
1060
|
})
|
|
1065
|
-
})
|
|
1066
|
-
}),
|
|
1061
|
+
})
|
|
1062
|
+
}) : dismissable ? /* @__PURE__ */ jsx20("button", {
|
|
1063
|
+
className: "absolute top-4 sm:top-8 right-4 transition-colors cursor-pointer duration-75 hover:text-blue-500 dark:text-gray-200 dark:hover:text-blue-500",
|
|
1064
|
+
type: "button",
|
|
1065
|
+
onClick: onDismissed,
|
|
1066
|
+
children: /* @__PURE__ */ jsx20(XIcon_default, {
|
|
1067
|
+
className: "h-5 w-5"
|
|
1068
|
+
})
|
|
1069
|
+
}) : null,
|
|
1067
1070
|
/* @__PURE__ */ jsx20("div", {
|
|
1068
1071
|
className: "my-1 sm:mt-16 bg-white dark:bg-slate-900 shadow-lg border border-gray-100 dark:border-none rounded-xl overflow-x-visible overflow-y-visible no-scrollbar",
|
|
1069
1072
|
onClick: function(e) {
|
|
@@ -1887,11 +1890,30 @@ import { createPortal } from "react-dom";
|
|
|
1887
1890
|
import { jsx as jsx36 } from "react/jsx-runtime";
|
|
1888
1891
|
var OverlaySpinner = function(param) {
|
|
1889
1892
|
var visible = param.visible;
|
|
1890
|
-
var _useState7 = _sliced_to_array(useState7(
|
|
1893
|
+
var _useState7 = _sliced_to_array(useState7(null), 2), modalRoot = _useState7[0], setModalRoot = _useState7[1];
|
|
1894
|
+
var _useState71 = _sliced_to_array(useState7(false), 2), mounted = _useState71[0], setMounted = _useState71[1];
|
|
1891
1895
|
useEffect6(function() {
|
|
1892
1896
|
return setMounted(true);
|
|
1893
1897
|
}, []);
|
|
1894
1898
|
if (!mounted) return null;
|
|
1899
|
+
useEffect6(function() {
|
|
1900
|
+
if (modalRoot || !visible) return;
|
|
1901
|
+
var root = document.getElementById("spinner-root");
|
|
1902
|
+
if (!root) {
|
|
1903
|
+
root = document.createElement("div");
|
|
1904
|
+
root.id = "spinner-root";
|
|
1905
|
+
document.body.appendChild(root);
|
|
1906
|
+
}
|
|
1907
|
+
setModalRoot(root);
|
|
1908
|
+
return function() {
|
|
1909
|
+
var root2 = document.getElementById("spinner-root");
|
|
1910
|
+
if (root2) {
|
|
1911
|
+
document.body.removeChild(root2);
|
|
1912
|
+
}
|
|
1913
|
+
};
|
|
1914
|
+
}, [
|
|
1915
|
+
visible
|
|
1916
|
+
]);
|
|
1895
1917
|
if (!visible) return null;
|
|
1896
1918
|
return createPortal(/* @__PURE__ */ jsx36("div", {
|
|
1897
1919
|
className: "animate-fade-in",
|