evelearn-theme 2.0.2 → 2.0.3

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 CHANGED
@@ -1,144 +1,333 @@
1
1
  "use strict";
2
+ function _array_like_to_array(arr, len) {
3
+ if (len == null || len > arr.length) len = arr.length;
4
+ for(var i = 0, arr2 = new Array(len); i < len; i++)arr2[i] = arr[i];
5
+ return arr2;
6
+ }
7
+ function _array_with_holes(arr) {
8
+ if (Array.isArray(arr)) return arr;
9
+ }
10
+ function _define_property(obj, key, value) {
11
+ if (key in obj) {
12
+ Object.defineProperty(obj, key, {
13
+ value: value,
14
+ enumerable: true,
15
+ configurable: true,
16
+ writable: true
17
+ });
18
+ } else {
19
+ obj[key] = value;
20
+ }
21
+ return obj;
22
+ }
23
+ function _iterable_to_array_limit(arr, i) {
24
+ var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
25
+ if (_i == null) return;
26
+ var _arr = [];
27
+ var _n = true;
28
+ var _d = false;
29
+ var _s, _e;
30
+ try {
31
+ for(_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true){
32
+ _arr.push(_s.value);
33
+ if (i && _arr.length === i) break;
34
+ }
35
+ } catch (err) {
36
+ _d = true;
37
+ _e = err;
38
+ } finally{
39
+ try {
40
+ if (!_n && _i["return"] != null) _i["return"]();
41
+ } finally{
42
+ if (_d) throw _e;
43
+ }
44
+ }
45
+ return _arr;
46
+ }
47
+ function _non_iterable_rest() {
48
+ throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
49
+ }
50
+ function _object_destructuring_empty(o) {
51
+ if (o === null || o === void 0) throw new TypeError("Cannot destructure " + o);
52
+ return o;
53
+ }
54
+ function _object_spread(target) {
55
+ for(var i = 1; i < arguments.length; i++){
56
+ var source = arguments[i] != null ? arguments[i] : {};
57
+ var ownKeys = Object.keys(source);
58
+ if (typeof Object.getOwnPropertySymbols === "function") {
59
+ ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function(sym) {
60
+ return Object.getOwnPropertyDescriptor(source, sym).enumerable;
61
+ }));
62
+ }
63
+ ownKeys.forEach(function(key) {
64
+ _define_property(target, key, source[key]);
65
+ });
66
+ }
67
+ return target;
68
+ }
69
+ function ownKeys(object, enumerableOnly) {
70
+ var keys = Object.keys(object);
71
+ if (Object.getOwnPropertySymbols) {
72
+ var symbols = Object.getOwnPropertySymbols(object);
73
+ if (enumerableOnly) {
74
+ symbols = symbols.filter(function(sym) {
75
+ return Object.getOwnPropertyDescriptor(object, sym).enumerable;
76
+ });
77
+ }
78
+ keys.push.apply(keys, symbols);
79
+ }
80
+ return keys;
81
+ }
82
+ function _object_spread_props(target, source) {
83
+ source = source != null ? source : {};
84
+ if (Object.getOwnPropertyDescriptors) {
85
+ Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
86
+ } else {
87
+ ownKeys(Object(source)).forEach(function(key) {
88
+ Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
89
+ });
90
+ }
91
+ return target;
92
+ }
93
+ function _object_without_properties(source, excluded) {
94
+ if (source == null) return {};
95
+ var target = _object_without_properties_loose(source, excluded);
96
+ var key, i;
97
+ if (Object.getOwnPropertySymbols) {
98
+ var sourceSymbolKeys = Object.getOwnPropertySymbols(source);
99
+ for(i = 0; i < sourceSymbolKeys.length; i++){
100
+ key = sourceSymbolKeys[i];
101
+ if (excluded.indexOf(key) >= 0) continue;
102
+ if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
103
+ target[key] = source[key];
104
+ }
105
+ }
106
+ return target;
107
+ }
108
+ function _object_without_properties_loose(source, excluded) {
109
+ if (source == null) return {};
110
+ var target = {};
111
+ var sourceKeys = Object.keys(source);
112
+ var key, i;
113
+ for(i = 0; i < sourceKeys.length; i++){
114
+ key = sourceKeys[i];
115
+ if (excluded.indexOf(key) >= 0) continue;
116
+ target[key] = source[key];
117
+ }
118
+ return target;
119
+ }
120
+ function _sliced_to_array(arr, i) {
121
+ return _array_with_holes(arr) || _iterable_to_array_limit(arr, i) || _unsupported_iterable_to_array(arr, i) || _non_iterable_rest();
122
+ }
123
+ function _type_of(obj) {
124
+ "@swc/helpers - typeof";
125
+ return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
126
+ }
127
+ function _unsupported_iterable_to_array(o, minLen) {
128
+ if (!o) return;
129
+ if (typeof o === "string") return _array_like_to_array(o, minLen);
130
+ var n = Object.prototype.toString.call(o).slice(8, -1);
131
+ if (n === "Object" && o.constructor) n = o.constructor.name;
132
+ if (n === "Map" || n === "Set") return Array.from(n);
133
+ if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array(o, minLen);
134
+ }
2
135
  var __create = Object.create;
3
136
  var __defProp = Object.defineProperty;
4
- var __defProps = Object.defineProperties;
5
137
  var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
6
- var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
7
138
  var __getOwnPropNames = Object.getOwnPropertyNames;
8
- var __getOwnPropSymbols = Object.getOwnPropertySymbols;
9
139
  var __getProtoOf = Object.getPrototypeOf;
10
140
  var __hasOwnProp = Object.prototype.hasOwnProperty;
11
- var __propIsEnum = Object.prototype.propertyIsEnumerable;
12
- var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
13
- var __spreadValues = (a, b) => {
14
- for (var prop in b || (b = {}))
15
- if (__hasOwnProp.call(b, prop))
16
- __defNormalProp(a, prop, b[prop]);
17
- if (__getOwnPropSymbols)
18
- for (var prop of __getOwnPropSymbols(b)) {
19
- if (__propIsEnum.call(b, prop))
20
- __defNormalProp(a, prop, b[prop]);
21
- }
22
- return a;
141
+ var __export = function(target, all) {
142
+ for(var name in all)__defProp(target, name, {
143
+ get: all[name],
144
+ enumerable: true
145
+ });
23
146
  };
24
- var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
25
- var __objRest = (source, exclude) => {
26
- var target = {};
27
- for (var prop in source)
28
- if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
29
- target[prop] = source[prop];
30
- if (source != null && __getOwnPropSymbols)
31
- for (var prop of __getOwnPropSymbols(source)) {
32
- if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
33
- target[prop] = source[prop];
147
+ var __copyProps = function(to, from, except, desc) {
148
+ if (from && (typeof from === "undefined" ? "undefined" : _type_of(from)) === "object" || typeof from === "function") {
149
+ var _iteratorNormalCompletion = true, _didIteratorError = false, _iteratorError = undefined;
150
+ try {
151
+ var _loop = function() {
152
+ var key = _step.value;
153
+ if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
154
+ get: function() {
155
+ return from[key];
156
+ },
157
+ enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
158
+ });
159
+ };
160
+ for(var _iterator = __getOwnPropNames(from)[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true)_loop();
161
+ } catch (err) {
162
+ _didIteratorError = true;
163
+ _iteratorError = err;
164
+ } finally{
165
+ try {
166
+ if (!_iteratorNormalCompletion && _iterator.return != null) {
167
+ _iterator.return();
168
+ }
169
+ } finally{
170
+ if (_didIteratorError) {
171
+ throw _iteratorError;
172
+ }
173
+ }
174
+ }
34
175
  }
35
- return target;
176
+ return to;
36
177
  };
37
- var __export = (target, all) => {
38
- for (var name in all)
39
- __defProp(target, name, { get: all[name], enumerable: true });
178
+ var __toESM = function(mod, isNodeMode, target) {
179
+ return target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(// If the importer is in node compatibility mode or this is not an ESM
180
+ // file that has been converted to a CommonJS file using a Babel-
181
+ // compatible transform (i.e. "__esModule" has not been set), then set
182
+ // "default" to the CommonJS "module.exports" for node compatibility.
183
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
184
+ value: mod,
185
+ enumerable: true
186
+ }) : target, mod);
40
187
  };
41
- var __copyProps = (to, from, except, desc) => {
42
- if (from && typeof from === "object" || typeof from === "function") {
43
- for (let key of __getOwnPropNames(from))
44
- if (!__hasOwnProp.call(to, key) && key !== except)
45
- __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
46
- }
47
- return to;
188
+ var __toCommonJS = function(mod) {
189
+ return __copyProps(__defProp({}, "__esModule", {
190
+ value: true
191
+ }), mod);
48
192
  };
49
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
50
- // If the importer is in node compatibility mode or this is not an ESM
51
- // file that has been converted to a CommonJS file using a Babel-
52
- // compatible transform (i.e. "__esModule" has not been set), then set
53
- // "default" to the CommonJS "module.exports" for node compatibility.
54
- isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
55
- mod
56
- ));
57
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
58
-
59
193
  // src/index.ts
60
194
  var index_exports = {};
61
195
  __export(index_exports, {
62
- AnimateLogo: () => AnimateLogo_default,
63
- Backdrop: () => Backdrop_default,
64
- BottomAlert: () => BottomAlert_default,
65
- Breakpoint: () => Breakpoint_default,
66
- Button: () => Button_default,
67
- Checkbox: () => Checkbox_default,
68
- CircleProgress: () => CircleProgress_default,
69
- Container: () => Container_default,
70
- CourseProgress: () => CourseProgress_default,
71
- ErrorText: () => ErrorText_default,
72
- Fade: () => Fade_default,
73
- FunButton: () => FunButton_default,
74
- FunRoundButton: () => FunRoundButton_default,
75
- IconInfo: () => IconInfo_default,
76
- Modal: () => Modal_default,
77
- NoResults: () => NoResults_default,
78
- NoticeBox: () => NoticeBox_default,
79
- Overlay: () => Overlay_default,
80
- OverlaySpinner: () => OverlaySpinner_default,
81
- PRIMARY_COLOR: () => PRIMARY_COLOR,
82
- Pill: () => Pill_default,
83
- ProgressBar: () => ProgressBar_default,
84
- ProgressBarSimple: () => ProgressBarSimple_default,
85
- RadioOption: () => RadioOption_default,
86
- RatingStars: () => RatingStars_default,
87
- ScrollProgress: () => ScrollProgress_default,
88
- Slider: () => Slider_default,
89
- Spinner: () => Spinner_default,
90
- StepsComponent: () => StepsComponent_default,
91
- Tippy: () => Tippy_default,
92
- ToggleSwitch: () => ToggleSwitch_default,
93
- UserContentSwitcher: () => UserContentSwitcher_default,
94
- baseFieldStyle: () => baseFieldStyle,
95
- createExerciseElementStyle: () => createExerciseElementStyle,
96
- exerciseDeleteButton: () => exerciseDeleteButton,
97
- exerciseEditButton: () => exerciseEditButton,
98
- headerButtonClass: () => headerButtonClass,
99
- headerTippyClass: () => headerTippyClass,
100
- tippyClassname: () => tippyClassname,
101
- toolbarExerciseButton: () => toolbarExerciseButton,
102
- xIconButton: () => xIconButton
196
+ AnimateLogo: function() {
197
+ return AnimateLogo_default;
198
+ },
199
+ Backdrop: function() {
200
+ return Backdrop_default;
201
+ },
202
+ BottomAlert: function() {
203
+ return BottomAlert_default;
204
+ },
205
+ Breakpoint: function() {
206
+ return Breakpoint_default;
207
+ },
208
+ Button: function() {
209
+ return Button_default;
210
+ },
211
+ Checkbox: function() {
212
+ return Checkbox_default;
213
+ },
214
+ CircleProgress: function() {
215
+ return CircleProgress_default;
216
+ },
217
+ CourseProgress: function() {
218
+ return CourseProgress_default;
219
+ },
220
+ ErrorText: function() {
221
+ return ErrorText_default;
222
+ },
223
+ Fade: function() {
224
+ return Fade_default;
225
+ },
226
+ FunButton: function() {
227
+ return FunButton_default;
228
+ },
229
+ FunRoundButton: function() {
230
+ return FunRoundButton_default;
231
+ },
232
+ IconInfo: function() {
233
+ return IconInfo_default;
234
+ },
235
+ Modal: function() {
236
+ return Modal_default;
237
+ },
238
+ NoResults: function() {
239
+ return NoResults_default;
240
+ },
241
+ NoticeBox: function() {
242
+ return NoticeBox_default;
243
+ },
244
+ Overlay: function() {
245
+ return Overlay_default;
246
+ },
247
+ OverlaySpinner: function() {
248
+ return OverlaySpinner_default;
249
+ },
250
+ PRIMARY_COLOR: function() {
251
+ return PRIMARY_COLOR;
252
+ },
253
+ Pill: function() {
254
+ return Pill_default;
255
+ },
256
+ ProgressBar: function() {
257
+ return ProgressBar_default;
258
+ },
259
+ ProgressBarSimple: function() {
260
+ return ProgressBarSimple_default;
261
+ },
262
+ RadioOption: function() {
263
+ return RadioOption_default;
264
+ },
265
+ RatingStars: function() {
266
+ return RatingStars_default;
267
+ },
268
+ ScrollProgress: function() {
269
+ return ScrollProgress_default;
270
+ },
271
+ Slider: function() {
272
+ return Slider_default;
273
+ },
274
+ Spinner: function() {
275
+ return Spinner_default;
276
+ },
277
+ StepsComponent: function() {
278
+ return StepsComponent_default;
279
+ },
280
+ Tippy: function() {
281
+ return Tippy_default;
282
+ },
283
+ ToggleSwitch: function() {
284
+ return ToggleSwitch_default;
285
+ },
286
+ UserContentSwitcher: function() {
287
+ return UserContentSwitcher_default;
288
+ },
289
+ baseFieldStyle: function() {
290
+ return baseFieldStyle;
291
+ },
292
+ createExerciseElementStyle: function() {
293
+ return createExerciseElementStyle;
294
+ },
295
+ exerciseDeleteButton: function() {
296
+ return exerciseDeleteButton;
297
+ },
298
+ exerciseEditButton: function() {
299
+ return exerciseEditButton;
300
+ },
301
+ headerButtonClass: function() {
302
+ return headerButtonClass;
303
+ },
304
+ headerTippyClass: function() {
305
+ return headerTippyClass;
306
+ },
307
+ tippyClassname: function() {
308
+ return tippyClassname;
309
+ },
310
+ toolbarExerciseButton: function() {
311
+ return toolbarExerciseButton;
312
+ },
313
+ xIconButton: function() {
314
+ return xIconButton;
315
+ }
103
316
  });
104
317
  module.exports = __toCommonJS(index_exports);
105
-
106
318
  // src/constants.tsx
107
319
  var PRIMARY_COLOR = "#00b4d8";
108
-
109
- // src/Common/Container.tsx
110
- var import_jsx_runtime = require("react/jsx-runtime");
111
- var Container = ({ backgroundImage, style, children, onClick }) => {
112
- return backgroundImage ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
113
- "div",
114
- {
115
- style: __spreadValues({
116
- backgroundImage,
117
- backgroundSize: "cover"
118
- }, style),
119
- className: "w-full md:min-h-screen dark:bg-slate-950 mx-auto overflow-y-auto overflow-x-clip px-0 md:px-2 sm:py-4 py-1 relative",
120
- onClick,
121
- children: children ? children : null
122
- }
123
- ) : /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
124
- "div",
125
- {
126
- className: `w-full dark:bg-slate-950 mx-auto overflow-y-auto overflow-x-clip px-0 sm:px-16 relative pt-20`,
127
- onClick,
128
- style: style || { minHeight: "100vh" },
129
- children: children ? children : null
130
- }
131
- );
132
- };
133
- var Container_default = Container;
134
-
135
320
  // src/Common/ErrorText.tsx
136
- var import_jsx_runtime2 = require("react/jsx-runtime");
137
- var ErrorText = ({ text, style, classNames }) => {
138
- return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("p", { className: classNames ? classNames : "text-red-500 font-semibold text-wrap py-auto", style, children: text });
321
+ var import_jsx_runtime = require("react/jsx-runtime");
322
+ var ErrorText = function(param) {
323
+ var text = param.text, style = param.style, classNames = param.classNames;
324
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", {
325
+ className: classNames ? classNames : "text-red-500 font-semibold text-wrap py-auto",
326
+ style: style,
327
+ children: text
328
+ });
139
329
  };
140
330
  var ErrorText_default = ErrorText;
141
-
142
331
  // src/Common/fieldStyle.ts
143
332
  var baseFieldStyle = "font-sans form-input h-11 w-full bg-white border-gray-200 dark:border-gray-500 dark:bg-slate-800 dark:text-gray-200 text-gray-700 dark:placeholder-gray-400 placeholder-gray-400 rounded-md px-2 py-1 focus:outline-none focus:border-blue-300 focus:ring focus:ring-blue-200 focus:ring-opacity-50";
144
333
  var createExerciseElementStyle = "flex flex-col justify-between space-y-2 w-full p-4 bg-white dark:bg-slate-800 rounded-xl text-gray-800 dark:text-gray-200 border-2 border-slate-200 dark:border-slate-400 overflow-hidden transition-all";
@@ -149,1446 +338,1753 @@ var tippyClassname = "p-2 bg-slate-600 dark:bg-slate-900 opacity-90 text-white f
149
338
  var headerTippyClass = "rounded-lg p-2 bg-slate-950 opacity-95 text-white font-medium";
150
339
  var headerButtonClass = "w-10 h-10 rounded-full dark:hover:bg-slate-600 hover:bg-slate-200 bg-transparent flex justify-center items-center flex justify-center items-center text-slate-600 dark:text-slate-100 hover:text-primary dark:hover:text-primary transition-colors duration-50";
151
340
  var toolbarExerciseButton = "flex bg-gray-50/90 items-center sm:justify-between p-4 shadow-sm w-full rounded-xl border-4 border-transparent hover:border-white text-gray-700 hover:text-white hover:bg-indigo-500 transition-colors duration-75";
152
-
153
341
  // src/Spinners/Spinner.tsx
154
- var import_jsx_runtime3 = require("react/jsx-runtime");
155
- var Spinner = ({ visible = true, size, white, isDark }) => {
156
- if (visible === false) return null;
157
- const isWhite = white || isDark;
158
- const color = isWhite ? "stroke-white/90" : "stroke-slate-600/80";
159
- const bgColor = isWhite ? "stroke-white/20" : "stroke-slate-500/20";
160
- const dimensions = size === "small" ? "w-5 h-5" : "w-8 h-8";
161
- const spinnerClasses = `
162
- absolute
163
- top-0
164
- animate-spin
165
- ${dimensions}
166
- `;
167
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("div", { className: "relative h-8 w-8 flex justify-center items-center", children: [
168
- /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
169
- "svg",
170
- {
171
- className: `absolute top-0 ${dimensions} ${bgColor}`,
172
- viewBox: "0 0 24 24",
173
- fill: "none",
174
- strokeWidth: "2.4",
175
- children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("circle", { cx: "12", cy: "12", r: "10" })
176
- }
177
- ),
178
- /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
179
- "svg",
180
- {
181
- className: spinnerClasses,
182
- viewBox: "0 0 24 24",
183
- fill: "none",
184
- strokeWidth: "2.4",
185
- strokeLinecap: "round",
186
- children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
187
- "path",
188
- {
189
- d: `
190
- M 12 2
191
- A 10 10 0 0 1 22 12
192
- A 10 10 0 0 1 12 22
193
- A 10 10 0 0 1 2 12
194
- A 10 10 0 0 1 12 2
195
- `,
196
- strokeDasharray: "13 18.4",
197
- stroke: "inherit",
198
- className: color
199
- }
200
- )
201
- }
202
- )
203
- ] });
342
+ var import_jsx_runtime2 = require("react/jsx-runtime");
343
+ var Spinner = function(param) {
344
+ var _param_visible = param.visible, visible = _param_visible === void 0 ? true : _param_visible, size = param.size, white = param.white, isDark = param.isDark;
345
+ if (visible === false) return null;
346
+ var isWhite = white || isDark;
347
+ var color = isWhite ? "stroke-white/90" : "stroke-slate-600/80";
348
+ var bgColor = isWhite ? "stroke-white/20" : "stroke-slate-500/20";
349
+ var dimensions = size === "small" ? "w-5 h-5" : "w-8 h-8";
350
+ var spinnerClasses = "\n absolute\n top-0\n animate-spin\n ".concat(dimensions, "\n ");
351
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("div", {
352
+ className: "relative h-8 w-8 flex justify-center items-center",
353
+ children: [
354
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("svg", {
355
+ className: "absolute top-0 ".concat(dimensions, " ").concat(bgColor),
356
+ viewBox: "0 0 24 24",
357
+ fill: "none",
358
+ strokeWidth: "2.4",
359
+ children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("circle", {
360
+ cx: "12",
361
+ cy: "12",
362
+ r: "10"
363
+ })
364
+ }),
365
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("svg", {
366
+ className: spinnerClasses,
367
+ viewBox: "0 0 24 24",
368
+ fill: "none",
369
+ strokeWidth: "2.4",
370
+ strokeLinecap: "round",
371
+ children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("path", {
372
+ d: "\n M 12 2 \n A 10 10 0 0 1 22 12 \n A 10 10 0 0 1 12 22 \n A 10 10 0 0 1 2 12 \n A 10 10 0 0 1 12 2\n ",
373
+ strokeDasharray: "13 18.4",
374
+ stroke: "inherit",
375
+ className: color
376
+ })
377
+ })
378
+ ]
379
+ });
204
380
  };
205
- var SpinnerCentered = (props) => {
206
- if (props.visible === false) return null;
207
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("div", { className: "w-full flex justify-center items-center", children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(Spinner, __spreadValues({}, props)) });
381
+ var SpinnerCentered = function(props) {
382
+ if (props.visible === false) return null;
383
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("div", {
384
+ className: "w-full flex justify-center items-center",
385
+ children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(Spinner, _object_spread({}, props))
386
+ });
208
387
  };
209
388
  Spinner.displayName = "Spinner";
210
389
  SpinnerCentered.displayName = "Spinner.Centered";
211
390
  Spinner.Centered = SpinnerCentered;
212
391
  var Spinner_default = Spinner;
213
-
214
392
  // src/Common/NoResults.tsx
215
- var import_jsx_runtime4 = require("react/jsx-runtime");
393
+ var import_jsx_runtime3 = require("react/jsx-runtime");
216
394
  var HEIGHT = 160;
217
395
  var WIDTH = HEIGHT * (16 / 9);
218
- var NoResults = ({ loading, message }) => {
219
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("div", { className: "relative w-full flex justify-center items-center", children: [
220
- /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("div", { className: "flex justify-start w-full space-x-2 py-3 p-4 bg-slate-100 dark:bg-slate-800 rounded-md", children: [
221
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("div", { style: { width: `calc(${WIDTH}px + 1rem)`, height: 320 }, className: "rounded-lg overflow-hidden cursor-pointer hover:shadow-md transition-shadow duration-150 px-2 pt-2 bg-slate-200 dark:bg-slate-700 animate-pulse" }),
222
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("div", { style: { width: `calc(${WIDTH}px + 1rem)`, height: 320 }, className: "rounded-lg overflow-hidden cursor-pointer hover:shadow-md transition-shadow duration-150 px-2 pt-2 bg-slate-200 dark:bg-slate-700 animate-pulse" })
223
- ] }),
224
- !loading && /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("div", { className: "absolute w-full h-full flex justify-center items-center m-auto", children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("div", { className: "p-4 rounded-lg bg-white dark:bg-slate-700 shadow-xl", children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("p", { className: "font-semibold text-lg text-gray-700 dark:text-gray-300", children: message || "No results" }) }) })
225
- ] });
396
+ var NoResults = function(param) {
397
+ var loading = param.loading, message = param.message;
398
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("div", {
399
+ className: "relative w-full flex justify-center items-center",
400
+ children: [
401
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("div", {
402
+ className: "flex justify-start w-full space-x-2 py-3 p-4 bg-slate-100 dark:bg-slate-800 rounded-md",
403
+ children: [
404
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("div", {
405
+ style: {
406
+ width: "calc(".concat(WIDTH, "px + 1rem)"),
407
+ height: 320
408
+ },
409
+ className: "rounded-lg overflow-hidden cursor-pointer hover:shadow-md transition-shadow duration-150 px-2 pt-2 bg-slate-200 dark:bg-slate-700 animate-pulse"
410
+ }),
411
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("div", {
412
+ style: {
413
+ width: "calc(".concat(WIDTH, "px + 1rem)"),
414
+ height: 320
415
+ },
416
+ className: "rounded-lg overflow-hidden cursor-pointer hover:shadow-md transition-shadow duration-150 px-2 pt-2 bg-slate-200 dark:bg-slate-700 animate-pulse"
417
+ })
418
+ ]
419
+ }),
420
+ !loading && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("div", {
421
+ className: "absolute w-full h-full flex justify-center items-center m-auto",
422
+ children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("div", {
423
+ className: "p-4 rounded-lg bg-white dark:bg-slate-700 shadow-xl",
424
+ children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("p", {
425
+ className: "font-semibold text-lg text-gray-700 dark:text-gray-300",
426
+ children: message || "No results"
427
+ })
428
+ })
429
+ })
430
+ ]
431
+ });
226
432
  };
227
433
  var NoResults_default = NoResults;
228
-
229
434
  // src/Common/Pill.tsx
230
- var import_jsx_runtime5 = require("react/jsx-runtime");
231
- var Pill = ({ text }) => {
232
- return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "rounded-full px-3 py-1 text-sm font-header font-medium bg-white dark:bg-slate-900 text-gray-700 dark:text-gray-300 mr-2 mb-2", children: text });
435
+ var import_jsx_runtime4 = require("react/jsx-runtime");
436
+ var Pill = function(param) {
437
+ var text = param.text;
438
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("span", {
439
+ className: "rounded-full px-3 py-1 text-sm font-header font-medium bg-white dark:bg-slate-900 text-gray-700 dark:text-gray-300 mr-2 mb-2",
440
+ children: text
441
+ });
233
442
  };
234
443
  var Pill_default = Pill;
235
-
236
444
  // src/Common/StepsComponent.tsx
237
- var import_jsx_runtime6 = require("react/jsx-runtime");
238
- var StepsComponent = ({ steps, activeStep, onStepPress }) => {
239
- return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className: "flex justify-between items-center w-full p-1 mb-2", children: steps.map((step, index) => {
240
- return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className: "flex justify-center items-center space-x-2 w-full", children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className: "flex flex-col items-center", children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
241
- "button",
242
- {
243
- type: "button",
244
- onClick: () => onStepPress(index),
245
- 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
246
- ${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"}`,
247
- children: /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("span", { className: "font-medium truncate", children: [
248
- index + 1,
249
- ". ",
250
- step.label
251
- ] })
252
- }
253
- ) }) }, `step_${index}_${step.label}`);
254
- }) });
445
+ var import_jsx_runtime5 = require("react/jsx-runtime");
446
+ var StepsComponent = function(param) {
447
+ var steps = param.steps, activeStep = param.activeStep, onStepPress = param.onStepPress;
448
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", {
449
+ className: "flex justify-between items-center w-full p-1 mb-2",
450
+ children: steps.map(function(step, index) {
451
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", {
452
+ className: "flex justify-center items-center space-x-2 w-full",
453
+ children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", {
454
+ className: "flex flex-col items-center",
455
+ children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", {
456
+ type: "button",
457
+ onClick: function() {
458
+ return onStepPress(index);
459
+ },
460
+ 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"),
461
+ children: /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("span", {
462
+ className: "font-medium truncate",
463
+ children: [
464
+ index + 1,
465
+ ". ",
466
+ step.label
467
+ ]
468
+ })
469
+ })
470
+ })
471
+ }, "step_".concat(index, "_").concat(step.label));
472
+ })
473
+ });
255
474
  };
256
475
  var StepsComponent_default = StepsComponent;
257
-
258
476
  // src/Fade/Fade.tsx
259
- var import_jsx_runtime7 = require("react/jsx-runtime");
260
- var Fade = ({ children, inProp }) => {
261
- return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("div", { className: "animate-fade-in", children });
477
+ var import_jsx_runtime6 = require("react/jsx-runtime");
478
+ var Fade = function(param) {
479
+ var children = param.children, inProp = param.inProp;
480
+ return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", {
481
+ className: "animate-fade-in",
482
+ children: children
483
+ });
262
484
  };
263
485
  var Fade_default = Fade;
264
-
265
486
  // src/Backdrop/Backdrop.tsx
266
- var import_jsx_runtime8 = require("react/jsx-runtime");
267
- var Backdrop = ({ visible, onClick, opacity }) => {
268
- if (!visible) return null;
269
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
270
- "div",
271
- {
272
- style: {
273
- opacity: opacity ? opacity : 90,
274
- zIndex: 21
275
- },
276
- className: `fixed top-0 left-0 w-full h-screen bg-gray-100 dark:bg-slate-900`,
277
- onClick
278
- }
279
- );
487
+ var import_jsx_runtime7 = require("react/jsx-runtime");
488
+ var Backdrop = function(param) {
489
+ var visible = param.visible, onClick = param.onClick, opacity = param.opacity;
490
+ if (!visible) return null;
491
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("div", {
492
+ style: {
493
+ opacity: opacity ? opacity : 90,
494
+ zIndex: 21
495
+ },
496
+ className: "fixed top-0 left-0 w-full h-screen bg-gray-100 dark:bg-slate-900",
497
+ onClick: onClick
498
+ });
280
499
  };
281
500
  var Backdrop_default = Backdrop;
282
-
283
501
  // src/Breakpoint/Breakpoint.tsx
284
- var import_jsx_runtime9 = require("react/jsx-runtime");
285
- var Breakpoint = ({ children, fromSize, toSize }) => {
286
- let className = "";
287
- if (fromSize && toSize) {
288
- className = `hidden ${fromSize}:block ${toSize}:hidden`;
289
- } else if (fromSize) {
290
- className = `hidden ${fromSize}:block`;
291
- } else if (toSize) {
292
- className = `block ${toSize}:hidden`;
293
- }
294
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("div", { className, children });
502
+ var import_jsx_runtime8 = require("react/jsx-runtime");
503
+ var Breakpoint = function(param) {
504
+ var children = param.children, fromSize = param.fromSize, toSize = param.toSize;
505
+ var className = "";
506
+ if (fromSize && toSize) {
507
+ className = "hidden ".concat(fromSize, ":block ").concat(toSize, ":hidden");
508
+ } else if (fromSize) {
509
+ className = "hidden ".concat(fromSize, ":block");
510
+ } else if (toSize) {
511
+ className = "block ".concat(toSize, ":hidden");
512
+ }
513
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("div", {
514
+ className: className,
515
+ children: children
516
+ });
295
517
  };
296
518
  var Breakpoint_default = Breakpoint;
297
-
298
519
  // src/Backdrop/Overlay.tsx
299
520
  var import_react = require("react");
300
521
  var import_react_dom = __toESM(require("react-dom"));
301
- var import_jsx_runtime10 = require("react/jsx-runtime");
302
- var Overlay = ({ visible, onDismissed, onClick, zIndex, isDark, children, opacity, withContainer = true }) => {
303
- const [modalRoot, setModalRoot] = (0, import_react.useState)(null);
304
- (0, import_react.useEffect)(() => {
305
- let root = document.getElementById("modal-root");
306
- if (!root) {
307
- root = document.createElement("div");
308
- root.id = "modal-root";
309
- document.body.appendChild(root);
310
- }
311
- setModalRoot(root);
312
- return () => {
313
- const root2 = document.getElementById("modal-root");
314
- if (root2) {
315
- document.body.removeChild(root2);
316
- }
317
- };
318
- }, [visible]);
319
- if (!visible || !modalRoot) return null;
320
- return import_react_dom.default.createPortal(
321
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("div", { className: "animate-fade-in", children: withContainer ? /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
322
- "div",
323
- {
324
- onClick: onDismissed || onClick,
325
- className: `top-0 left-0 fixed w-full h-screen flex items-center justify-center`,
326
- style: {
327
- background: isDark ? `rgba(0, 0, 0, ${opacity || "0.7"})` : `rgba(255, 255, 255, ${opacity || "0.6"})`,
328
- zIndex: zIndex || 9999
329
- },
330
- children
331
- }
332
- ) : children }),
333
- modalRoot
334
- );
522
+ var import_jsx_runtime9 = require("react/jsx-runtime");
523
+ var Overlay = function(param) {
524
+ var visible = param.visible, onDismissed = param.onDismissed, onClick = param.onClick, zIndex = param.zIndex, isDark = param.isDark, children = param.children, opacity = param.opacity, _param_withContainer = param.withContainer, withContainer = _param_withContainer === void 0 ? true : _param_withContainer;
525
+ var _ref = _sliced_to_array((0, import_react.useState)(null), 2), modalRoot = _ref[0], setModalRoot = _ref[1];
526
+ (0, import_react.useEffect)(function() {
527
+ var root = document.getElementById("modal-root");
528
+ if (!root) {
529
+ root = document.createElement("div");
530
+ root.id = "modal-root";
531
+ document.body.appendChild(root);
532
+ }
533
+ setModalRoot(root);
534
+ return function() {
535
+ var root2 = document.getElementById("modal-root");
536
+ if (root2) {
537
+ document.body.removeChild(root2);
538
+ }
539
+ };
540
+ }, [
541
+ visible
542
+ ]);
543
+ if (!visible || !modalRoot) return null;
544
+ return import_react_dom.default.createPortal(/* @__PURE__ */ (0, import_jsx_runtime9.jsx)("div", {
545
+ className: "animate-fade-in",
546
+ children: withContainer ? /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("div", {
547
+ onClick: onDismissed || onClick,
548
+ className: "top-0 left-0 fixed w-full h-screen flex items-center justify-center",
549
+ style: {
550
+ background: isDark ? "rgba(0, 0, 0, ".concat(opacity || "0.7", ")") : "rgba(255, 255, 255, ".concat(opacity || "0.6", ")"),
551
+ zIndex: zIndex || 9999
552
+ },
553
+ children: children
554
+ }) : children
555
+ }), modalRoot);
335
556
  };
336
557
  var Overlay_default = Overlay;
337
-
338
558
  // src/Button/Button.tsx
339
- var import_jsx_runtime11 = require("react/jsx-runtime");
340
- var Button = ({ disabled = false, loading, onClick, kind = "primary", size = "small", type = "button", children }) => {
341
- const styled = () => {
342
- switch (kind) {
343
- case "primary":
344
- return `bg-primary font-header text-white font-medium transition-all duration-75 ${disabled ? "bg-white/50" : "hover:bg-black/10"}`;
345
- case "indigo":
346
- return `bg-indigo-500 font-header text-white font-medium transition-all duration-75 ${disabled ? "bg-white/50" : "hover:bg-black/10"}`;
347
- case "green":
348
- return `bg-green-500 font-header text-white font-medium transition-all duration-75 ${disabled ? "bg-white/50" : "hover:bg-black/10"}`;
349
- case "teal":
350
- return `bg-teal-500 font-header text-white font-medium transition-all duration-75 ${disabled ? "bg-white/50" : "hover:bg-black/10"}`;
351
- case "secondary":
352
- return "bg-secondary text-white font-header font-medium hover:bg-black/10 transition-all duration-75";
353
- case "base":
354
- return "bg-white border-1 font-header border-gray-200 dark:bg-slate-600 dark:text-gray-100 dark:hover:bg-slate-400 hover:bg-slate-100 transition-all duration-75";
355
- case "gray":
356
- return "bg-slate-400 dark:bg-slate-700 font-header text-white border-1 font-medium hover:bg-black/10 transition-opacity duration-75";
357
- case "alert":
358
- return "bg-amber-500 font-header text-white transition-all hover:bg-black/10 duration-75";
359
- case "warning":
360
- return "bg-red-500 font-header text-white font-medium hover:bg-black/10 transition-opacity duration-100";
361
- default:
362
- break;
363
- }
364
- };
365
- const sized = () => {
366
- switch (size) {
367
- case "small":
368
- return "p-1";
369
- case "fixed":
370
- return "box-border w-32 h-11";
371
- case "large":
372
- return "px-2 h-11";
373
- default:
374
- return "px-2 py-1";
375
- }
376
- };
377
- return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("button", { type: type || "button", disabled, className: `rounded-lg focus:outline-none transition duration-100 ${styled()} ${sized()}`, onClick, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("div", { className: "w-full max-h-11", children: loading ? /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("div", { className: "flex w-full justify-center items-center", children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Spinner_default, { white: true }) }) : children }) });
559
+ var import_jsx_runtime10 = require("react/jsx-runtime");
560
+ var Button = function(param) {
561
+ var _param_disabled = param.disabled, disabled = _param_disabled === void 0 ? false : _param_disabled, loading = param.loading, onClick = param.onClick, _param_kind = param.kind, kind = _param_kind === void 0 ? "primary" : _param_kind, _param_size = param.size, size = _param_size === void 0 ? "small" : _param_size, _param_type = param.type, type = _param_type === void 0 ? "button" : _param_type, children = param.children;
562
+ var styled = function() {
563
+ switch(kind){
564
+ case "primary":
565
+ return "bg-primary font-header text-white font-medium transition-all duration-75 ".concat(disabled ? "bg-white/50" : "hover:bg-black/10");
566
+ case "indigo":
567
+ return "bg-indigo-500 font-header text-white font-medium transition-all duration-75 ".concat(disabled ? "bg-white/50" : "hover:bg-black/10");
568
+ case "green":
569
+ return "bg-green-500 font-header text-white font-medium transition-all duration-75 ".concat(disabled ? "bg-white/50" : "hover:bg-black/10");
570
+ case "teal":
571
+ return "bg-teal-500 font-header text-white font-medium transition-all duration-75 ".concat(disabled ? "bg-white/50" : "hover:bg-black/10");
572
+ case "secondary":
573
+ return "bg-secondary text-white font-header font-medium hover:bg-black/10 transition-all duration-75";
574
+ case "base":
575
+ return "bg-white border-1 font-header border-gray-200 dark:bg-slate-600 dark:text-gray-100 dark:hover:bg-slate-400 hover:bg-slate-100 transition-all duration-75";
576
+ case "gray":
577
+ return "bg-slate-400 dark:bg-slate-700 font-header text-white border-1 font-medium hover:bg-black/10 transition-opacity duration-75";
578
+ case "alert":
579
+ return "bg-amber-500 font-header text-white transition-all hover:bg-black/10 duration-75";
580
+ case "warning":
581
+ return "bg-red-500 font-header text-white font-medium hover:bg-black/10 transition-opacity duration-100";
582
+ default:
583
+ break;
584
+ }
585
+ };
586
+ var sized = function() {
587
+ switch(size){
588
+ case "small":
589
+ return "p-1";
590
+ case "fixed":
591
+ return "box-border w-32 h-11";
592
+ case "large":
593
+ return "px-2 h-11";
594
+ default:
595
+ return "px-2 py-1";
596
+ }
597
+ };
598
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("button", {
599
+ type: type || "button",
600
+ disabled: disabled,
601
+ className: "rounded-lg focus:outline-none transition duration-100 ".concat(styled(), " ").concat(sized()),
602
+ onClick: onClick,
603
+ children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("div", {
604
+ className: "w-full max-h-11",
605
+ children: loading ? /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("div", {
606
+ className: "flex w-full justify-center items-center",
607
+ children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(Spinner_default, {
608
+ white: true
609
+ })
610
+ }) : children
611
+ })
612
+ });
378
613
  };
379
614
  var Button_default = Button;
380
-
381
615
  // src/Button/FunButton.tsx
382
616
  var import_react2 = require("react");
383
617
  var import_framer_motion = require("framer-motion");
384
- var import_jsx_runtime12 = require("react/jsx-runtime");
385
- var FunButton = ({
386
- onClick,
387
- disabled,
388
- type,
389
- children,
390
- color = "primary",
391
- loading,
392
- active,
393
- className,
394
- size = "base"
395
- }) => {
396
- const { front, bottom } = (0, import_react2.useMemo)(() => {
397
- switch (color) {
398
- case "primary":
399
- return { bottom: "#00b4d8", front: "#0284c7" };
400
- case "red":
401
- return { bottom: "#f00f0f", front: "#b91c1c" };
402
- case "green":
403
- return { bottom: "#22c55e", front: "#16a34a" };
404
- case "purple":
405
- return { bottom: "#6366f1", front: "#4f46e5" };
406
- case "teal":
407
- return { bottom: "#14b8a6", front: "#0d9488" };
408
- case "cyan":
409
- return { bottom: "#06b6d4", front: "#0891b2" };
410
- case "yellow":
411
- return { bottom: "#eab308", front: "#ca8a04" };
412
- default:
413
- return { bottom: "#00b4d8", front: "#0369a1" };
414
- }
415
- }, [color]);
416
- const classStyle = (0, import_react2.useMemo)(() => {
417
- switch (size) {
418
- case "base":
419
- return "relative block px-8 py-3 rounded-lg text-lg text-white font-medium font-header hover:bg-slate-900/20";
420
- case "big":
421
- return "relative block px-12 py-4 rounded-lg text-lg text-white font-medium font-header hover:bg-slate-900/20";
422
- case "small":
423
- return "relative block px-6 py-1 rounded-lg text-lg text-white font-medium font-header hover:bg-slate-900/20";
424
- case "square":
425
- return "relative block h-12 w-12 rounded text-lg flex items-center justify-center text-white font-medium font-header hover:bg-slate-900/20";
426
- default:
427
- return "relative block px-8 py-3 rounded-lg text-lg text-white font-medium font-header hover:bg-slate-900/20";
428
- }
429
- }, [size]);
430
- const computedClassName = (0, import_react2.useMemo)(() => {
431
- const cName = className + " rounded-lg border-none p-0 cursor-pointer opacity-90 hover:bg-black/30 transition-opacity";
432
- return cName + (disabled ? " opacity-70 cursor-default" : "");
433
- }, [className, disabled]);
434
- const computedClassStyle = (0, import_react2.useMemo)(() => {
435
- const cName = classStyle;
436
- return cName + (disabled ? " opacity-70 cursor-default hover:bg-black/70" : "");
437
- }, [classStyle, disabled]);
438
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
439
- import_framer_motion.motion.button,
440
- {
441
- className: `${computedClassName}`,
442
- style: { background: front, outlineOffset: "4px" },
443
- type,
444
- onMouseDown: onClick,
445
- whileTap: { y: disabled ? 0 : 2 },
446
- transition: { duration: 0.1, ease: "easeInOut" },
447
- children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
448
- import_framer_motion.motion.span,
449
- {
450
- className: computedClassStyle,
451
- style: {
452
- background: bottom,
453
- opacity: 1
454
- },
455
- initial: { y: active ? 0 : -6 },
456
- animate: { y: active ? 0 : -6 },
457
- whileTap: { y: disabled ? -6 : 0 },
458
- transition: { duration: 0.1, ease: "easeInOut" },
459
- children: loading ? /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("div", { className: size === "small" ? "min-h-6" : "min-h-10", children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Spinner_default.Centered, { visible: true, size: size === "small" ? "small" : "base", white: true }) }) : children
618
+ var import_jsx_runtime11 = require("react/jsx-runtime");
619
+ var FunButton = function(param) {
620
+ var onClick = param.onClick, disabled = param.disabled, type = param.type, children = param.children, _param_color = param.color, color = _param_color === void 0 ? "primary" : _param_color, loading = param.loading, active = param.active, className = param.className, _param_size = param.size, size = _param_size === void 0 ? "base" : _param_size;
621
+ var _ref = (0, import_react2.useMemo)(function() {
622
+ switch(color){
623
+ case "primary":
624
+ return {
625
+ bottom: "#00b4d8",
626
+ front: "#0284c7"
627
+ };
628
+ case "red":
629
+ return {
630
+ bottom: "#f00f0f",
631
+ front: "#b91c1c"
632
+ };
633
+ case "green":
634
+ return {
635
+ bottom: "#22c55e",
636
+ front: "#16a34a"
637
+ };
638
+ case "purple":
639
+ return {
640
+ bottom: "#6366f1",
641
+ front: "#4f46e5"
642
+ };
643
+ case "teal":
644
+ return {
645
+ bottom: "#14b8a6",
646
+ front: "#0d9488"
647
+ };
648
+ case "cyan":
649
+ return {
650
+ bottom: "#06b6d4",
651
+ front: "#0891b2"
652
+ };
653
+ case "yellow":
654
+ return {
655
+ bottom: "#eab308",
656
+ front: "#ca8a04"
657
+ };
658
+ default:
659
+ return {
660
+ bottom: "#00b4d8",
661
+ front: "#0369a1"
662
+ };
460
663
  }
461
- )
462
- }
463
- );
664
+ }, [
665
+ color
666
+ ]), front = _ref.front, bottom = _ref.bottom;
667
+ var classStyle = (0, import_react2.useMemo)(function() {
668
+ switch(size){
669
+ case "base":
670
+ return "relative block px-8 py-3 rounded-lg text-lg text-white font-medium font-header hover:bg-slate-900/20";
671
+ case "big":
672
+ return "relative block px-12 py-4 rounded-lg text-lg text-white font-medium font-header hover:bg-slate-900/20";
673
+ case "small":
674
+ return "relative block px-6 py-1 rounded-lg text-lg text-white font-medium font-header hover:bg-slate-900/20";
675
+ case "square":
676
+ return "relative block h-12 w-12 rounded text-lg flex items-center justify-center text-white font-medium font-header hover:bg-slate-900/20";
677
+ default:
678
+ return "relative block px-8 py-3 rounded-lg text-lg text-white font-medium font-header hover:bg-slate-900/20";
679
+ }
680
+ }, [
681
+ size
682
+ ]);
683
+ var computedClassName = (0, import_react2.useMemo)(function() {
684
+ var cName = className + " rounded-lg border-none p-0 cursor-pointer opacity-90 hover:bg-black/30 transition-opacity";
685
+ return cName + (disabled ? " opacity-70 cursor-default" : "");
686
+ }, [
687
+ className,
688
+ disabled
689
+ ]);
690
+ var computedClassStyle = (0, import_react2.useMemo)(function() {
691
+ var cName = classStyle;
692
+ return cName + (disabled ? " opacity-70 cursor-default hover:bg-black/70" : "");
693
+ }, [
694
+ classStyle,
695
+ disabled
696
+ ]);
697
+ return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_framer_motion.motion.button, {
698
+ className: "".concat(computedClassName),
699
+ style: {
700
+ background: front,
701
+ outlineOffset: "4px"
702
+ },
703
+ type: type,
704
+ onMouseDown: onClick,
705
+ whileTap: {
706
+ y: disabled ? 0 : 2
707
+ },
708
+ transition: {
709
+ duration: 0.1,
710
+ ease: "easeInOut"
711
+ },
712
+ children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_framer_motion.motion.span, {
713
+ className: computedClassStyle,
714
+ style: {
715
+ background: bottom,
716
+ opacity: 1
717
+ },
718
+ initial: {
719
+ y: active ? 0 : -6
720
+ },
721
+ animate: {
722
+ y: active ? 0 : -6
723
+ },
724
+ whileTap: {
725
+ y: disabled ? -6 : 0
726
+ },
727
+ transition: {
728
+ duration: 0.1,
729
+ ease: "easeInOut"
730
+ },
731
+ children: loading ? /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("div", {
732
+ className: size === "small" ? "min-h-6" : "min-h-10",
733
+ children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Spinner_default.Centered, {
734
+ visible: true,
735
+ size: size === "small" ? "small" : "base",
736
+ white: true
737
+ })
738
+ }) : children
739
+ })
740
+ });
464
741
  };
465
742
  var FunButton_default = FunButton;
466
-
467
743
  // src/Button/FunRoundButton.tsx
468
744
  var import_react3 = require("react");
469
745
  var import_framer_motion2 = require("framer-motion");
470
- var import_jsx_runtime13 = require("react/jsx-runtime");
471
- var FunRoundButton = ({ onClick, disabled, type, children, color, active, className, size = 44 }) => {
472
- const { front, bottom } = (0, import_react3.useMemo)(() => {
473
- switch (color) {
474
- case "primary":
475
- return { bottom: "#00b4d8", front: "#0284c7" };
476
- case "red":
477
- return { bottom: disabled ? "hsl(340deg 100% 42%)" : "hsl(345deg 100% 47%)", front: disabled ? "hsl(340deg 100% 52%)" : "hsl(340deg 100% 32%)" };
478
- case "green":
479
- return { bottom: disabled ? "#86efac" : "#22c55e", front: disabled ? "#4ade80" : "#16a34a" };
480
- case "purple":
481
- return { bottom: disabled ? "#a5b4fc" : "#6366f1", front: disabled ? "#818cf8" : "#4f46e5" };
482
- case "teal":
483
- return { bottom: disabled ? "#5eead4" : "#14b8a6", front: disabled ? "#2dd4bf" : "#0d9488" };
484
- case "yellow":
485
- return { bottom: disabled ? "#fde047" : "#eab308", front: disabled ? "#facc15" : "#ca8a04" };
486
- default:
487
- return { bottom: disabled ? "#d1d5db" : "#00b4d8", front: disabled ? "#38bdf8" : "#0369a1" };
488
- }
489
- }, [color, disabled]);
490
- return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
491
- import_framer_motion2.motion.button,
492
- {
493
- className: `${className || "border-none p-0 flex justify-center items-center cursor-pointer z-10"} ${disabled ? "opacity-70 cursor-default" : "hover:opacity-95"}`,
494
- style: {
495
- background: front,
496
- height: size,
497
- width: size + 2,
498
- borderRadius: (size + 2) / 2,
499
- outlineOffset: 0
500
- },
501
- type,
502
- disabled,
503
- onClick,
504
- whileHover: { opacity: 0.95 },
505
- whileTap: { y: disabled ? 0 : 2 },
506
- children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
507
- import_framer_motion2.motion.span,
508
- {
509
- className: "flex justify-center items-center z-10",
510
- style: {
511
- background: bottom,
746
+ var import_jsx_runtime12 = require("react/jsx-runtime");
747
+ var FunRoundButton = function(param) {
748
+ var onClick = param.onClick, disabled = param.disabled, type = param.type, children = param.children, color = param.color, active = param.active, className = param.className, _param_size = param.size, size = _param_size === void 0 ? 44 : _param_size;
749
+ var _ref = (0, import_react3.useMemo)(function() {
750
+ switch(color){
751
+ case "primary":
752
+ return {
753
+ bottom: "#00b4d8",
754
+ front: "#0284c7"
755
+ };
756
+ case "red":
757
+ return {
758
+ bottom: disabled ? "hsl(340deg 100% 42%)" : "hsl(345deg 100% 47%)",
759
+ front: disabled ? "hsl(340deg 100% 52%)" : "hsl(340deg 100% 32%)"
760
+ };
761
+ case "green":
762
+ return {
763
+ bottom: disabled ? "#86efac" : "#22c55e",
764
+ front: disabled ? "#4ade80" : "#16a34a"
765
+ };
766
+ case "purple":
767
+ return {
768
+ bottom: disabled ? "#a5b4fc" : "#6366f1",
769
+ front: disabled ? "#818cf8" : "#4f46e5"
770
+ };
771
+ case "teal":
772
+ return {
773
+ bottom: disabled ? "#5eead4" : "#14b8a6",
774
+ front: disabled ? "#2dd4bf" : "#0d9488"
775
+ };
776
+ case "yellow":
777
+ return {
778
+ bottom: disabled ? "#fde047" : "#eab308",
779
+ front: disabled ? "#facc15" : "#ca8a04"
780
+ };
781
+ default:
782
+ return {
783
+ bottom: disabled ? "#d1d5db" : "#00b4d8",
784
+ front: disabled ? "#38bdf8" : "#0369a1"
785
+ };
786
+ }
787
+ }, [
788
+ color,
789
+ disabled
790
+ ]), front = _ref.front, bottom = _ref.bottom;
791
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_framer_motion2.motion.button, {
792
+ className: "".concat(className || "border-none p-0 flex justify-center items-center cursor-pointer z-10", " ").concat(disabled ? "opacity-70 cursor-default" : "hover:opacity-95"),
793
+ style: {
794
+ background: front,
512
795
  height: size,
513
796
  width: size + 2,
514
- borderRadius: (size + 2) / 2
515
- },
516
- initial: { y: active ? 0 : -6 },
517
- animate: { y: active ? 0 : -6 },
518
- transition: { duration: 0.1, ease: "easeInOut" },
519
- whileHover: { opacity: 0.95 },
520
- whileTap: { y: disabled ? active ? 0 : -6 : 0 },
521
- children
522
- }
523
- )
524
- }
525
- );
797
+ borderRadius: (size + 2) / 2,
798
+ outlineOffset: 0
799
+ },
800
+ type: type,
801
+ disabled: disabled,
802
+ onClick: onClick,
803
+ whileHover: {
804
+ opacity: 0.95
805
+ },
806
+ whileTap: {
807
+ y: disabled ? 0 : 2
808
+ },
809
+ children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_framer_motion2.motion.span, {
810
+ className: "flex justify-center items-center z-10",
811
+ style: {
812
+ background: bottom,
813
+ height: size,
814
+ width: size + 2,
815
+ borderRadius: (size + 2) / 2
816
+ },
817
+ initial: {
818
+ y: active ? 0 : -6
819
+ },
820
+ animate: {
821
+ y: active ? 0 : -6
822
+ },
823
+ transition: {
824
+ duration: 0.1,
825
+ ease: "easeInOut"
826
+ },
827
+ whileHover: {
828
+ opacity: 0.95
829
+ },
830
+ whileTap: {
831
+ y: disabled ? active ? 0 : -6 : 0
832
+ },
833
+ children: children
834
+ })
835
+ });
526
836
  };
527
837
  var FunRoundButton_default = FunRoundButton;
528
-
529
838
  // src/Checkbox/Checkbox.tsx
530
839
  var import_react4 = require("react");
531
840
  var import_formik = require("formik");
532
- var import_jsx_runtime14 = require("react/jsx-runtime");
533
- var Checkbox = ({ name, labelText, isLarge, onChange, isDisabled }) => {
534
- const [{ value }, { error }, { setValue, setTouched }] = (0, import_formik.useField)(name);
535
- const onCheck = (e) => {
536
- setTouched(true);
537
- setValue(!value, true);
538
- };
539
- const rand = (0, import_react4.useMemo)(() => {
540
- return Math.random();
541
- }, []);
542
- return /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)("div", { className: "relative flex flex-col justify-center items-center", children: [
543
- /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)("div", { className: "flex items-center", children: [
544
- /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
545
- "input",
546
- {
547
- disabled: !!isDisabled,
548
- onChange: (e) => {
549
- onCheck(e);
550
- onChange == null ? void 0 : onChange(Boolean(e.target.value));
551
- },
552
- value: value ? "true" : "false",
553
- id: `${name}${rand}`,
554
- name,
555
- type: "checkbox",
556
- checked: !!value,
557
- className: `form-checkbox text-blue-600 focus:ring-blue-500 border-gray-300 rounded ${isLarge ? "h-5 w-5" : "h-4 w-4"}`
558
- }
559
- ),
560
- typeof labelText === "string" ? /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("label", { htmlFor: `${name}${rand}`, className: "ml-2 block text-sm text-gray-800 dark:text-gray-200", children: labelText }) : /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("label", { htmlFor: `${name}${rand}`, children: labelText })
561
- ] }),
562
- error && /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(ErrorText_default, { classNames: "absolute w-64 left-6 top-4 text-xs text-red-500", text: error })
563
- ] });
841
+ var import_jsx_runtime13 = require("react/jsx-runtime");
842
+ var Checkbox = function(param) {
843
+ var name = param.name, labelText = param.labelText, isLarge = param.isLarge, onChange = param.onChange, isDisabled = param.isDisabled;
844
+ var _ref = _sliced_to_array((0, import_formik.useField)(name), 3), value = _ref[0].value, error = _ref[1].error, _ref_ = _ref[2], setValue = _ref_.setValue, setTouched = _ref_.setTouched;
845
+ var onCheck = function(e) {
846
+ setTouched(true);
847
+ setValue(!value, true);
848
+ };
849
+ var rand = (0, import_react4.useMemo)(function() {
850
+ return Math.random();
851
+ }, []);
852
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)("div", {
853
+ className: "relative flex flex-col justify-center items-center",
854
+ children: [
855
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)("div", {
856
+ className: "flex items-center",
857
+ children: [
858
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("input", {
859
+ disabled: !!isDisabled,
860
+ onChange: function(e) {
861
+ onCheck(e);
862
+ onChange === null || onChange === void 0 ? void 0 : onChange(Boolean(e.target.value));
863
+ },
864
+ value: value ? "true" : "false",
865
+ id: "".concat(name).concat(rand),
866
+ name: name,
867
+ type: "checkbox",
868
+ checked: !!value,
869
+ className: "form-checkbox text-blue-600 focus:ring-blue-500 border-gray-300 rounded ".concat(isLarge ? "h-5 w-5" : "h-4 w-4")
870
+ }),
871
+ typeof labelText === "string" ? /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("label", {
872
+ htmlFor: "".concat(name).concat(rand),
873
+ className: "ml-2 block text-sm text-gray-800 dark:text-gray-200",
874
+ children: labelText
875
+ }) : /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("label", {
876
+ htmlFor: "".concat(name).concat(rand),
877
+ children: labelText
878
+ })
879
+ ]
880
+ }),
881
+ error && /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(ErrorText_default, {
882
+ classNames: "absolute w-64 left-6 top-4 text-xs text-red-500",
883
+ text: error
884
+ })
885
+ ]
886
+ });
564
887
  };
565
- var MultiChoiceCheckBox = ({ name, hasMultipleAnswers, index, isLarge, allOptionsName }) => {
566
- const [{ value }, {}, { setValue, setTouched }] = (0, import_formik.useField)(name);
567
- const [{ value: optionsValue }, , { setValue: setOptionsValue }] = (0, import_formik.useField)(allOptionsName);
568
- const onCheck = (e) => {
569
- setTouched(true);
570
- if (hasMultipleAnswers) {
571
- setValue(!value);
572
- return;
573
- }
574
- setOptionsValue(optionsValue == null ? void 0 : optionsValue.map((el, idx) => ({ option: el.option, id: el.id, isCorrectAnswer: index === idx ? !el.isCorrectAnswer : false })));
575
- };
576
- return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("div", { className: "flex flex-col justify-center items-center", children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("div", { className: "flex items-center", children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
577
- "input",
578
- {
579
- onChange: (e) => onCheck(e),
580
- value: index,
581
- checked: !!value,
582
- id: name,
583
- name,
584
- type: "checkbox",
585
- className: `form-checkbox text-blue-600 focus:ring-blue-500 border-gray-300 rounded ${isLarge ? "h-5 w-5" : "h-4 w-4"}`
586
- }
587
- ) }) });
888
+ var MultiChoiceCheckBox = function(param) {
889
+ var name = param.name, hasMultipleAnswers = param.hasMultipleAnswers, index = param.index, isLarge = param.isLarge, allOptionsName = param.allOptionsName;
890
+ var _ref = _sliced_to_array((0, import_formik.useField)(name), 3), value = _ref[0].value, ref = _object_destructuring_empty(_ref[1]), _ref_ = _ref[2], setValue = _ref_.setValue, setTouched = _ref_.setTouched;
891
+ var _ref1 = _sliced_to_array((0, import_formik.useField)(allOptionsName), 3), _ref_1 = _ref1[0], optionsValue = _ref_1.value, _ref_2 = _ref1[2], setOptionsValue = _ref_2.setValue;
892
+ var onCheck = function(e) {
893
+ setTouched(true);
894
+ if (hasMultipleAnswers) {
895
+ setValue(!value);
896
+ return;
897
+ }
898
+ setOptionsValue(optionsValue === null || optionsValue === void 0 ? void 0 : optionsValue.map(function(el, idx) {
899
+ return {
900
+ option: el.option,
901
+ id: el.id,
902
+ isCorrectAnswer: index === idx ? !el.isCorrectAnswer : false
903
+ };
904
+ }));
905
+ };
906
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("div", {
907
+ className: "flex flex-col justify-center items-center",
908
+ children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("div", {
909
+ className: "flex items-center",
910
+ children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("input", {
911
+ onChange: function(e) {
912
+ return onCheck(e);
913
+ },
914
+ value: index,
915
+ checked: !!value,
916
+ id: name,
917
+ name: name,
918
+ type: "checkbox",
919
+ className: "form-checkbox text-blue-600 focus:ring-blue-500 border-gray-300 rounded ".concat(isLarge ? "h-5 w-5" : "h-4 w-4")
920
+ })
921
+ })
922
+ });
588
923
  };
589
924
  Checkbox.Multi = MultiChoiceCheckBox;
590
925
  var Checkbox_default = Checkbox;
591
-
592
926
  // src/Checkbox/RadioOption.tsx
593
927
  var import_formik2 = require("formik");
594
- var import_jsx_runtime15 = require("react/jsx-runtime");
595
- var RadioOption = ({ name, isLarge, labelText, option, onSelect }) => {
596
- const [{ value }, {}, { setValue }] = (0, import_formik2.useField)(name);
597
- return /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("div", { className: "flex items-center", children: [
598
- /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
599
- "input",
600
- {
601
- onChange: () => {
602
- setValue(option);
603
- onSelect == null ? void 0 : onSelect();
604
- },
605
- value: option,
606
- id: option,
607
- name,
608
- type: "checkbox",
609
- checked: value === option,
610
- className: `form-checkbox text-blue-600 focus:ring-blue-500 border-gray-300 rounded ${isLarge ? "h-5 w-5" : "h-4 w-4"}`
611
- }
612
- ),
613
- typeof labelText === "string" ? /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("label", { htmlFor: option, className: "ml-2 block text-sm text-gray-900", children: labelText }) : /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("label", { htmlFor: option, children: labelText })
614
- ] });
928
+ var import_jsx_runtime14 = require("react/jsx-runtime");
929
+ var RadioOption = function(param) {
930
+ var name = param.name, isLarge = param.isLarge, labelText = param.labelText, option = param.option, onSelect = param.onSelect;
931
+ var _ref = _sliced_to_array((0, import_formik2.useField)(name), 3), value = _ref[0].value, ref = _object_destructuring_empty(_ref[1]), setValue = _ref[2].setValue;
932
+ return /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)("div", {
933
+ className: "flex items-center",
934
+ children: [
935
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("input", {
936
+ onChange: function() {
937
+ setValue(option);
938
+ onSelect === null || onSelect === void 0 ? void 0 : onSelect();
939
+ },
940
+ value: option,
941
+ id: option,
942
+ name: name,
943
+ type: "checkbox",
944
+ checked: value === option,
945
+ className: "form-checkbox text-blue-600 focus:ring-blue-500 border-gray-300 rounded ".concat(isLarge ? "h-5 w-5" : "h-4 w-4")
946
+ }),
947
+ typeof labelText === "string" ? /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("label", {
948
+ htmlFor: option,
949
+ className: "ml-2 block text-sm text-gray-900",
950
+ children: labelText
951
+ }) : /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("label", {
952
+ htmlFor: option,
953
+ children: labelText
954
+ })
955
+ ]
956
+ });
615
957
  };
616
958
  var RadioOption_default = RadioOption;
617
-
618
959
  // src/Common/BottomAlert.tsx
619
960
  var import_react_dom2 = __toESM(require("react-dom"));
620
- var import_jsx_runtime16 = require("react/jsx-runtime");
621
- var BottomAlert = ({ isDark, setDontShowAgain, dontShowAgain, title, borderColor, onDismissed, cancelText, confirmText, onConfirm, onCancel, isSingleAction, children, buttonColor }) => {
622
- const dismiss = () => {
623
- onDismissed == null ? void 0 : onDismissed();
624
- };
625
- return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
626
- "div",
627
- {
628
- className: "top-0 left-0 fixed w-full h-screen flex justify-center",
629
- style: {
630
- background: isDark ? "rgba(0, 0, 0, 0.1)" : "rgba(255, 255, 255, 0.1)",
631
- zIndex: 9999
632
- },
633
- children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("div", { className: "absolute top-0 w-full h-screen flex justify-center bg-gray-200/90 dark:bg-slate-800/50", children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("div", { className: "absolute sm:w-1/2 w-full mx-auto shadow-xl rounded-md p-6 flex z-50 flex-col top-24 bg-white dark:bg-slate-900 overflow-clip rounded-bl-lg rounded-br-lg border-b-8 border-b-blue-500", children: /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("div", { style: { borderColor: borderColor || "#0ea5e9" }, children: [
634
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("h3", { className: "font-semibold font-header text-gray-700 dark:text-gray-300 text-xl", children: title }),
635
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("div", { className: "mt-2 text-lg", children }),
636
- setDontShowAgain ? /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("div", { className: "flex items-center space-x-1", children: [
637
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
638
- "input",
639
- {
640
- onChange: () => {
641
- setDontShowAgain((s) => !s);
642
- },
643
- id: `show_again_check`,
644
- checked: !!dontShowAgain,
645
- type: "checkbox",
646
- className: `form-checkbox text-blue-600 focus:ring-blue-500 border-gray-300 rounded h-4 w-4`
647
- }
648
- ),
649
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("label", { htmlFor: "show_again_check", className: "dark:text-gray-200 text-gray-700", children: "Don't show again" })
650
- ] }) : null,
651
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("div", { className: "mt-4 flex items-center justify-end space-x-4 z-10", children: isSingleAction ? /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
652
- Button_default,
653
- {
654
- type: "button",
655
- kind: buttonColor,
656
- onClick: () => {
657
- onConfirm(true);
658
- dismiss();
659
- },
660
- children: confirmText || "Okay"
661
- }
662
- ) : /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("div", { className: "w-1/3 flex justify-end space-x-4", children: [
663
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("div", { className: "w-full flex flex-col", children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
664
- Button_default,
665
- {
666
- type: "button",
667
- kind: "secondary",
668
- onClick: () => {
669
- onCancel == null ? void 0 : onCancel();
670
- dismiss();
671
- },
672
- children: cancelText || "Cancel"
673
- }
674
- ) }),
675
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("div", { className: "w-full flex flex-col", children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
676
- Button_default,
677
- {
678
- type: "button",
679
- kind: buttonColor,
680
- onClick: () => {
681
- onConfirm(true);
682
- dismiss();
683
- },
684
- children: confirmText || "Confirm"
685
- }
686
- ) })
687
- ] }) })
688
- ] }) }) })
689
- }
690
- );
961
+ var import_jsx_runtime15 = require("react/jsx-runtime");
962
+ var BottomAlert = function(param) {
963
+ var isDark = param.isDark, setDontShowAgain = param.setDontShowAgain, dontShowAgain = param.dontShowAgain, title = param.title, borderColor = param.borderColor, onDismissed = param.onDismissed, cancelText = param.cancelText, confirmText = param.confirmText, onConfirm = param.onConfirm, onCancel = param.onCancel, isSingleAction = param.isSingleAction, children = param.children, buttonColor = param.buttonColor;
964
+ var dismiss = function() {
965
+ onDismissed === null || onDismissed === void 0 ? void 0 : onDismissed();
966
+ };
967
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", {
968
+ className: "top-0 left-0 fixed w-full h-screen flex justify-center",
969
+ style: {
970
+ background: isDark ? "rgba(0, 0, 0, 0.1)" : "rgba(255, 255, 255, 0.1)",
971
+ zIndex: 9999
972
+ },
973
+ children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", {
974
+ className: "absolute top-0 w-full h-screen flex justify-center bg-gray-200/90 dark:bg-slate-800/50",
975
+ children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", {
976
+ className: "absolute sm:w-1/2 w-full mx-auto shadow-xl rounded-md p-6 flex z-50 flex-col top-24 bg-white dark:bg-slate-900 overflow-clip rounded-bl-lg rounded-br-lg border-b-8 border-b-blue-500",
977
+ children: /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("div", {
978
+ style: {
979
+ borderColor: borderColor || "#0ea5e9"
980
+ },
981
+ children: [
982
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("h3", {
983
+ className: "font-semibold font-header text-gray-700 dark:text-gray-300 text-xl",
984
+ children: title
985
+ }),
986
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", {
987
+ className: "mt-2 text-lg",
988
+ children: children
989
+ }),
990
+ setDontShowAgain ? /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("div", {
991
+ className: "flex items-center space-x-1",
992
+ children: [
993
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("input", {
994
+ onChange: function() {
995
+ setDontShowAgain(function(s) {
996
+ return !s;
997
+ });
998
+ },
999
+ id: "show_again_check",
1000
+ checked: !!dontShowAgain,
1001
+ type: "checkbox",
1002
+ className: "form-checkbox text-blue-600 focus:ring-blue-500 border-gray-300 rounded h-4 w-4"
1003
+ }),
1004
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("label", {
1005
+ htmlFor: "show_again_check",
1006
+ className: "dark:text-gray-200 text-gray-700",
1007
+ children: "Don't show again"
1008
+ })
1009
+ ]
1010
+ }) : null,
1011
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", {
1012
+ className: "mt-4 flex items-center justify-end space-x-4 z-10",
1013
+ children: isSingleAction ? /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(Button_default, {
1014
+ type: "button",
1015
+ kind: buttonColor,
1016
+ onClick: function() {
1017
+ onConfirm(true);
1018
+ dismiss();
1019
+ },
1020
+ children: confirmText || "Okay"
1021
+ }) : /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("div", {
1022
+ className: "w-1/3 flex justify-end space-x-4",
1023
+ children: [
1024
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", {
1025
+ className: "w-full flex flex-col",
1026
+ children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(Button_default, {
1027
+ type: "button",
1028
+ kind: "secondary",
1029
+ onClick: function() {
1030
+ onCancel === null || onCancel === void 0 ? void 0 : onCancel();
1031
+ dismiss();
1032
+ },
1033
+ children: cancelText || "Cancel"
1034
+ })
1035
+ }),
1036
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", {
1037
+ className: "w-full flex flex-col",
1038
+ children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(Button_default, {
1039
+ type: "button",
1040
+ kind: buttonColor,
1041
+ onClick: function() {
1042
+ onConfirm(true);
1043
+ dismiss();
1044
+ },
1045
+ children: confirmText || "Confirm"
1046
+ })
1047
+ })
1048
+ ]
1049
+ })
1050
+ })
1051
+ ]
1052
+ })
1053
+ })
1054
+ })
1055
+ });
691
1056
  };
692
- var BAWrapper = (props) => {
693
- if (!props.isVisible) return null;
694
- return import_react_dom2.default.createPortal(
695
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(BottomAlert, __spreadValues({}, props)),
696
- document.body
697
- );
1057
+ var BAWrapper = function(props) {
1058
+ if (!props.isVisible) return null;
1059
+ return import_react_dom2.default.createPortal(/* @__PURE__ */ (0, import_jsx_runtime15.jsx)(BottomAlert, _object_spread({}, props)), document.body);
698
1060
  };
699
1061
  var BottomAlert_default = BAWrapper;
700
-
701
1062
  // src/Common/Tippy.tsx
702
1063
  var import_react5 = require("react");
703
1064
  var import_react6 = require("@floating-ui/react");
704
- var import_jsx_runtime17 = require("react/jsx-runtime");
705
- var Tippy = ({ children, content, placement = "top", className = "", wrapperClassname = "", disabled = false, arrow: useArrow = false, visible }) => {
706
- const [isOpen, setIsOpen] = (0, import_react5.useState)(false);
707
- const arrowRef = (0, import_react5.useRef)(null);
708
- (0, import_react5.useEffect)(() => {
709
- if (visible) {
710
- setIsOpen(true);
711
- }
712
- }, [visible]);
713
- const {
714
- x,
715
- y,
716
- strategy,
717
- refs,
718
- context
719
- } = (0, import_react6.useFloating)({
720
- placement,
721
- open: isOpen,
722
- onOpenChange: setIsOpen,
723
- middleware: [
724
- (0, import_react6.offset)(8),
725
- (0, import_react6.flip)(),
726
- (0, import_react6.shift)(),
727
- (0, import_react6.arrow)({ element: arrowRef })
728
- ]
729
- });
730
- const hover = (0, import_react6.useHover)(context, {
731
- enabled: !disabled
732
- });
733
- const dismiss = (0, import_react6.useDismiss)(context);
734
- const role = (0, import_react6.useRole)(context);
735
- const { getReferenceProps, getFloatingProps } = (0, import_react6.useInteractions)([
736
- hover,
737
- dismiss,
738
- role
739
- ]);
740
- return /* @__PURE__ */ (0, import_jsx_runtime17.jsxs)(import_jsx_runtime17.Fragment, { children: [
741
- isOpen && /* @__PURE__ */ (0, import_jsx_runtime17.jsxs)(import_react6.FloatingPortal, { children: [
742
- /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
743
- "div",
744
- __spreadProps(__spreadValues({
745
- ref: refs.setFloating,
746
- className: `z-[9999] ${className || tippyClassname}`
747
- }, getFloatingProps()), {
748
- style: {
749
- position: strategy,
750
- top: y != null ? y : 0,
751
- left: x != null ? x : 0,
752
- width: "max-content"
753
- },
754
- children: content
755
- })
756
- ),
757
- useArrow && /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
758
- import_react6.FloatingArrow,
759
- {
760
- ref: arrowRef,
761
- context,
762
- className: "fill-gray-900",
763
- tipRadius: 2
1065
+ var import_jsx_runtime16 = require("react/jsx-runtime");
1066
+ var Tippy = function(param) {
1067
+ var children = param.children, content = param.content, _param_placement = param.placement, placement = _param_placement === void 0 ? "top" : _param_placement, _param_className = param.className, className = _param_className === void 0 ? "" : _param_className, _param_wrapperClassname = param.wrapperClassname, wrapperClassname = _param_wrapperClassname === void 0 ? "" : _param_wrapperClassname, _param_disabled = param.disabled, disabled = _param_disabled === void 0 ? false : _param_disabled, tmp = param.arrow, useArrow = tmp === void 0 ? false : tmp, visible = param.visible;
1068
+ var _ref = _sliced_to_array((0, import_react5.useState)(false), 2), isOpen = _ref[0], setIsOpen = _ref[1];
1069
+ var arrowRef = (0, import_react5.useRef)(null);
1070
+ (0, import_react5.useEffect)(function() {
1071
+ if (visible) {
1072
+ setIsOpen(true);
764
1073
  }
765
- )
766
- ] }),
767
- /* @__PURE__ */ (0, import_jsx_runtime17.jsx)("div", __spreadProps(__spreadValues({ ref: refs.setReference }, getReferenceProps()), { className: wrapperClassname, children }))
768
- ] });
1074
+ }, [
1075
+ visible
1076
+ ]);
1077
+ var _ref1 = (0, import_react6.useFloating)({
1078
+ placement: placement,
1079
+ open: isOpen,
1080
+ onOpenChange: setIsOpen,
1081
+ middleware: [
1082
+ (0, import_react6.offset)(8),
1083
+ (0, import_react6.flip)(),
1084
+ (0, import_react6.shift)(),
1085
+ (0, import_react6.arrow)({
1086
+ element: arrowRef
1087
+ })
1088
+ ]
1089
+ }), x = _ref1.x, y = _ref1.y, strategy = _ref1.strategy, refs = _ref1.refs, context = _ref1.context;
1090
+ var hover = (0, import_react6.useHover)(context, {
1091
+ enabled: !disabled
1092
+ });
1093
+ var dismiss = (0, import_react6.useDismiss)(context);
1094
+ var role = (0, import_react6.useRole)(context);
1095
+ var _ref2 = (0, import_react6.useInteractions)([
1096
+ hover,
1097
+ dismiss,
1098
+ role
1099
+ ]), getReferenceProps = _ref2.getReferenceProps, getFloatingProps = _ref2.getFloatingProps;
1100
+ return /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(import_jsx_runtime16.Fragment, {
1101
+ children: [
1102
+ isOpen && /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(import_react6.FloatingPortal, {
1103
+ children: [
1104
+ /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("div", _object_spread_props(_object_spread({
1105
+ ref: refs.setFloating,
1106
+ className: "z-[9999] ".concat(className || tippyClassname)
1107
+ }, getFloatingProps()), {
1108
+ style: {
1109
+ position: strategy,
1110
+ top: y !== null && y !== void 0 ? y : 0,
1111
+ left: x !== null && x !== void 0 ? x : 0,
1112
+ width: "max-content"
1113
+ },
1114
+ children: content
1115
+ })),
1116
+ useArrow && /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react6.FloatingArrow, {
1117
+ ref: arrowRef,
1118
+ context: context,
1119
+ className: "fill-gray-900",
1120
+ tipRadius: 2
1121
+ })
1122
+ ]
1123
+ }),
1124
+ /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("div", _object_spread_props(_object_spread({
1125
+ ref: refs.setReference
1126
+ }, getReferenceProps()), {
1127
+ className: wrapperClassname,
1128
+ children: children
1129
+ }))
1130
+ ]
1131
+ });
769
1132
  };
770
1133
  var Tippy_default = Tippy;
771
-
772
1134
  // src/Common/IconInfo.tsx
773
- var import_jsx_runtime18 = require("react/jsx-runtime");
774
- var IconInfo = ({ content, icon, number, color }) => {
775
- return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("div", { className: "flex flex-shrink-0 items-center justify-center w-8 h-8 rounded-full bg-slate-400 dark:bg-slate-600 dark:border dark:border-white", children: /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
776
- Tippy_default,
777
- {
778
- className: tippyClassname,
779
- content,
780
- children: /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("div", { className: "relative", children: [
781
- icon,
782
- /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("p", { className: `absolute -bottom-1 ${number > 9 ? number > 99 ? number > 999 ? "w-8 h-8 -right-6 -bottom-3" : "w-6 h-6 -right-5 -bottom-2" : "w-5 h-5 -right-3" : "w-4 -right-3"} flex justify-center items-center text-xs font-sans rounded-full text-white ${color || "bg-secondary"}`, children: number })
783
- ] })
784
- }
785
- ) });
1135
+ var import_jsx_runtime17 = require("react/jsx-runtime");
1136
+ var IconInfo = function(param) {
1137
+ var content = param.content, icon = param.icon, number = param.number, color = param.color;
1138
+ return /* @__PURE__ */ (0, import_jsx_runtime17.jsx)("div", {
1139
+ className: "flex flex-shrink-0 items-center justify-center w-8 h-8 rounded-full bg-slate-400 dark:bg-slate-600 dark:border dark:border-white",
1140
+ children: /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(Tippy_default, {
1141
+ className: tippyClassname,
1142
+ content: content,
1143
+ children: /* @__PURE__ */ (0, import_jsx_runtime17.jsxs)("div", {
1144
+ className: "relative",
1145
+ children: [
1146
+ icon,
1147
+ /* @__PURE__ */ (0, import_jsx_runtime17.jsx)("p", {
1148
+ className: "absolute -bottom-1 ".concat(number > 9 ? number > 99 ? number > 999 ? "w-8 h-8 -right-6 -bottom-3" : "w-6 h-6 -right-5 -bottom-2" : "w-5 h-5 -right-3" : "w-4 -right-3", " flex justify-center items-center text-xs font-sans rounded-full text-white ").concat(color || "bg-secondary"),
1149
+ children: number
1150
+ })
1151
+ ]
1152
+ })
1153
+ })
1154
+ });
786
1155
  };
787
1156
  var IconInfo_default = IconInfo;
788
-
789
1157
  // src/Common/Modal.tsx
790
1158
  var import_link = __toESM(require("next/link"));
791
-
792
1159
  // src/Icons/XIcon.tsx
793
- var import_jsx_runtime19 = require("react/jsx-runtime");
794
- var XIcon = ({ className }) => {
795
- return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", className: className || "h-5 w-5", viewBox: "0 0 20 20", fill: "currentColor", children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("path", { fillRule: "evenodd", d: "M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z", clipRule: "evenodd" }) });
1160
+ var import_jsx_runtime18 = require("react/jsx-runtime");
1161
+ var XIcon = function(param) {
1162
+ var className = param.className;
1163
+ return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("svg", {
1164
+ xmlns: "http://www.w3.org/2000/svg",
1165
+ className: className || "h-5 w-5",
1166
+ viewBox: "0 0 20 20",
1167
+ fill: "currentColor",
1168
+ children: /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("path", {
1169
+ fillRule: "evenodd",
1170
+ d: "M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z",
1171
+ clipRule: "evenodd"
1172
+ })
1173
+ });
796
1174
  };
797
1175
  var XIcon_default = XIcon;
798
-
799
1176
  // src/Common/Modal.tsx
800
- var import_jsx_runtime20 = require("react/jsx-runtime");
801
- var Modal = (_a) => {
802
- var _b = _a, { visible, children, fullscreen, displayDark, dismissLink, bgOpacity, onDismissed, dismissable = true, dismissOnBackdropClick = true, style } = _b, props = __objRest(_b, ["visible", "children", "fullscreen", "displayDark", "dismissLink", "bgOpacity", "onDismissed", "dismissable", "dismissOnBackdropClick", "style"]);
803
- if (!visible) return null;
804
- return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(Overlay_default, __spreadProps(__spreadValues({ visible, onClick: dismissOnBackdropClick ? onDismissed : void 0, isDark: displayDark, withContainer: true }, props), { children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
805
- "div",
806
- {
807
- className: `${displayDark && "dark"} bg-slate-900/20 fixed inset-0 flex items-center justify-center`,
808
- style: { zIndex: 1e4 },
809
- children: /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)("div", { className: ["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`].join(" "), children: [
810
- /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_jsx_runtime20.Fragment, { children: dismissLink ? /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
811
- import_link.default,
812
- {
813
- href: dismissLink,
814
- scroll: false,
815
- children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("div", { onClick: onDismissed, children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(XIcon_default, { className: "absolute h-5 w-5 top-5 sm:top-20 right-4 transition-colors cursor-pointer duration-75 hover:text-blue-500 dark:text-gray-200 dark:hover:text-blue-500" }) })
816
- }
817
- ) : dismissable ? /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
818
- "button",
819
- {
820
- className: "absolute top-5 sm:top-20 right-4 transition-colors cursor-pointer duration-75 hover:text-blue-500 dark:text-gray-200 dark:hover:text-blue-500",
821
- type: "button",
822
- onClick: onDismissed,
823
- children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
824
- XIcon_default,
825
- {
826
- className: "h-5 w-5"
827
- }
828
- )
829
- }
830
- ) : null }),
831
- /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
832
- "div",
833
- {
834
- 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",
835
- onClick: (e) => e.stopPropagation(),
836
- style: __spreadValues({ maxHeight: "calc(100vh - 6rem)" }, style),
837
- children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("div", { className: "p-4 sm:p-10", children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("div", { className: "mt-8 sm:mt-0", children }) })
838
- }
839
- )
840
- ] })
841
- }
842
- ) }));
1177
+ var import_jsx_runtime19 = require("react/jsx-runtime");
1178
+ var Modal = function(_param) {
1179
+ 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, [
1180
+ "visible",
1181
+ "children",
1182
+ "fullscreen",
1183
+ "displayDark",
1184
+ "dismissLink",
1185
+ "bgOpacity",
1186
+ "onDismissed",
1187
+ "dismissable",
1188
+ "dismissOnBackdropClick",
1189
+ "style"
1190
+ ]);
1191
+ if (!visible) return null;
1192
+ return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(Overlay_default, _object_spread_props(_object_spread({
1193
+ visible: visible,
1194
+ onClick: dismissOnBackdropClick ? onDismissed : void 0,
1195
+ isDark: displayDark,
1196
+ withContainer: true
1197
+ }, props), {
1198
+ children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("div", {
1199
+ className: "".concat(displayDark && "dark", " bg-slate-900/20 fixed inset-0 flex items-center justify-center"),
1200
+ style: {
1201
+ zIndex: 1e4
1202
+ },
1203
+ children: /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)("div", {
1204
+ className: [
1205
+ "relative mx-1 w-full md:mx-auto md:w-3/4 lg:w-1/2",
1206
+ fullscreen && "md:w-5/6 lg:w-5/6"
1207
+ ].join(" "),
1208
+ children: [
1209
+ /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_jsx_runtime19.Fragment, {
1210
+ children: dismissLink ? /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_link.default, {
1211
+ href: dismissLink,
1212
+ scroll: false,
1213
+ children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("div", {
1214
+ onClick: onDismissed,
1215
+ children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(XIcon_default, {
1216
+ className: "absolute h-5 w-5 top-5 sm:top-20 right-4 transition-colors cursor-pointer duration-75 hover:text-blue-500 dark:text-gray-200 dark:hover:text-blue-500"
1217
+ })
1218
+ })
1219
+ }) : dismissable ? /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("button", {
1220
+ className: "absolute top-5 sm:top-20 right-4 transition-colors cursor-pointer duration-75 hover:text-blue-500 dark:text-gray-200 dark:hover:text-blue-500",
1221
+ type: "button",
1222
+ onClick: onDismissed,
1223
+ children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(XIcon_default, {
1224
+ className: "h-5 w-5"
1225
+ })
1226
+ }) : null
1227
+ }),
1228
+ /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("div", {
1229
+ 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",
1230
+ onClick: function(e) {
1231
+ return e.stopPropagation();
1232
+ },
1233
+ style: _object_spread({
1234
+ maxHeight: "calc(100vh - 6rem)"
1235
+ }, style),
1236
+ children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("div", {
1237
+ className: "p-4 sm:p-10",
1238
+ children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("div", {
1239
+ className: "mt-8 sm:mt-0",
1240
+ children: children
1241
+ })
1242
+ })
1243
+ })
1244
+ ]
1245
+ })
1246
+ })
1247
+ }));
843
1248
  };
844
1249
  var Modal_default = Modal;
845
-
846
1250
  // src/Common/NoticeBox.tsx
847
1251
  var import_react7 = require("react");
848
- var import_jsx_runtime21 = require("react/jsx-runtime");
849
- var NoticeBox = ({ children, type, isDismissible, isVisible, onDismiss }) => {
850
- const [visible, setVisible] = (0, import_react7.useState)(true);
851
- const styles = (0, import_react7.useMemo)(() => {
852
- const base = "relative text-base rounded-md p-2 ";
853
- if (!visible) return "hidden";
854
- switch (type) {
855
- case "error":
856
- return base.concat("w-full absolute top-50 text-red-500 border-red-400 border-2");
857
- case "info":
858
- return base.concat("text-green-800 border-green-400 bg-green-100");
859
- case "warning":
860
- return base.concat("text-orange-500 border border-orange-400 bg-white");
861
- default:
862
- return base.concat("w-full absolute top-0 text-red-500 border-red-500 bg-white p-3 border-2");
863
- }
864
- }, [type, visible]);
865
- (0, import_react7.useEffect)(() => {
866
- setVisible(isVisible);
867
- }, [isVisible]);
868
- if (!isVisible) return null;
869
- return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
870
- "div",
871
- {
872
- style: {
873
- zIndex: 100
874
- },
875
- className: styles,
876
- children: /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("div", { className: "relative", children: [
877
- isDismissible && /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
878
- "button",
879
- {
880
- type: "button",
881
- onClick: () => {
882
- setVisible((s) => !s);
883
- onDismiss == null ? void 0 : onDismiss();
884
- },
885
- className: "absolute bottom-1 right-1 transition-colors cursor-pointer duration-75 hover:text-blue-500",
886
- children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(XIcon_default, { className: "h-5 w-5" })
887
- }
888
- ),
889
- children
890
- ] })
891
- }
892
- );
1252
+ var import_jsx_runtime20 = require("react/jsx-runtime");
1253
+ var NoticeBox = function(param) {
1254
+ var children = param.children, type = param.type, isDismissible = param.isDismissible, isVisible = param.isVisible, onDismiss = param.onDismiss;
1255
+ var _ref = _sliced_to_array((0, import_react7.useState)(true), 2), visible = _ref[0], setVisible = _ref[1];
1256
+ var styles = (0, import_react7.useMemo)(function() {
1257
+ var base = "relative text-base rounded-md p-2 ";
1258
+ if (!visible) return "hidden";
1259
+ switch(type){
1260
+ case "error":
1261
+ return base.concat("w-full absolute top-50 text-red-500 border-red-400 border-2");
1262
+ case "info":
1263
+ return base.concat("text-green-800 border-green-400 bg-green-100");
1264
+ case "warning":
1265
+ return base.concat("text-orange-500 border border-orange-400 bg-white");
1266
+ default:
1267
+ return base.concat("w-full absolute top-0 text-red-500 border-red-500 bg-white p-3 border-2");
1268
+ }
1269
+ }, [
1270
+ type,
1271
+ visible
1272
+ ]);
1273
+ (0, import_react7.useEffect)(function() {
1274
+ setVisible(isVisible);
1275
+ }, [
1276
+ isVisible
1277
+ ]);
1278
+ if (!isVisible) return null;
1279
+ return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("div", {
1280
+ style: {
1281
+ zIndex: 100
1282
+ },
1283
+ className: styles,
1284
+ children: /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)("div", {
1285
+ className: "relative",
1286
+ children: [
1287
+ isDismissible && /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("button", {
1288
+ type: "button",
1289
+ onClick: function() {
1290
+ setVisible(function(s) {
1291
+ return !s;
1292
+ });
1293
+ onDismiss === null || onDismiss === void 0 ? void 0 : onDismiss();
1294
+ },
1295
+ className: "absolute bottom-1 right-1 transition-colors cursor-pointer duration-75 hover:text-blue-500",
1296
+ children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(XIcon_default, {
1297
+ className: "h-5 w-5"
1298
+ })
1299
+ }),
1300
+ children
1301
+ ]
1302
+ })
1303
+ });
893
1304
  };
894
1305
  var NoticeBox_default = NoticeBox;
895
-
896
1306
  // src/Icons/StarIcon.tsx
897
- var import_jsx_runtime22 = require("react/jsx-runtime");
898
- var StarIcon = ({ className, percentage, color }) => {
899
- return /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("svg", { xmlns: "http://www.w3.org/2000/svg", className: className || "h-5 w-5", viewBox: "0 0 20 20", fill: "currentColor", children: [
900
- /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("defs", { children: /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("linearGradient", { id: "grad", children: [
901
- /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("stop", { offset: `${(percentage || 0.5) * 100}%`, "stop-color": color ? color : "#4b5563" }),
902
- /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("stop", { offset: `${100 - (percentage || 0.5) * 100}%`, "stop-color": "white" })
903
- ] }) }),
904
- /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("path", { fill: "url(#grad)", d: "M9.049 2.927c.3-.921 1.603-.921 1.902 0l1.07 3.292a1 1 0 00.95.69h3.462c.969 0 1.371 1.24.588 1.81l-2.8 2.034a1 1 0 00-.364 1.118l1.07 3.292c.3.921-.755 1.688-1.54 1.118l-2.8-2.034a1 1 0 00-1.175 0l-2.8 2.034c-.784.57-1.838-.197-1.539-1.118l1.07-3.292a1 1 0 00-.364-1.118L2.98 8.72c-.783-.57-.38-1.81.588-1.81h3.461a1 1 0 00.951-.69l1.07-3.292z" })
905
- ] });
1307
+ var import_jsx_runtime21 = require("react/jsx-runtime");
1308
+ var StarIcon = function(param) {
1309
+ var className = param.className, percentage = param.percentage, color = param.color;
1310
+ return /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("svg", {
1311
+ xmlns: "http://www.w3.org/2000/svg",
1312
+ className: className || "h-5 w-5",
1313
+ viewBox: "0 0 20 20",
1314
+ fill: "currentColor",
1315
+ children: [
1316
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("defs", {
1317
+ children: /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("linearGradient", {
1318
+ id: "grad",
1319
+ children: [
1320
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("stop", {
1321
+ offset: "".concat((percentage || 0.5) * 100, "%"),
1322
+ "stop-color": color ? color : "#4b5563"
1323
+ }),
1324
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("stop", {
1325
+ offset: "".concat(100 - (percentage || 0.5) * 100, "%"),
1326
+ "stop-color": "white"
1327
+ })
1328
+ ]
1329
+ })
1330
+ }),
1331
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("path", {
1332
+ fill: "url(#grad)",
1333
+ d: "M9.049 2.927c.3-.921 1.603-.921 1.902 0l1.07 3.292a1 1 0 00.95.69h3.462c.969 0 1.371 1.24.588 1.81l-2.8 2.034a1 1 0 00-.364 1.118l1.07 3.292c.3.921-.755 1.688-1.54 1.118l-2.8-2.034a1 1 0 00-1.175 0l-2.8 2.034c-.784.57-1.838-.197-1.539-1.118l1.07-3.292a1 1 0 00-.364-1.118L2.98 8.72c-.783-.57-.38-1.81.588-1.81h3.461a1 1 0 00.951-.69l1.07-3.292z"
1334
+ })
1335
+ ]
1336
+ });
906
1337
  };
907
1338
  var StarIcon_default = StarIcon;
908
-
909
1339
  // src/Icons/StarIconSolid.tsx
910
- var import_jsx_runtime23 = require("react/jsx-runtime");
911
- var StartIconSolid = ({ className }) => {
912
- return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", className: className || "h-5 w-5", viewBox: "0 0 20 20", fill: "currentColor", children: /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("path", { d: "M9.049 2.927c.3-.921 1.603-.921 1.902 0l1.07 3.292a1 1 0 00.95.69h3.462c.969 0 1.371 1.24.588 1.81l-2.8 2.034a1 1 0 00-.364 1.118l1.07 3.292c.3.921-.755 1.688-1.54 1.118l-2.8-2.034a1 1 0 00-1.175 0l-2.8 2.034c-.784.57-1.838-.197-1.539-1.118l1.07-3.292a1 1 0 00-.364-1.118L2.98 8.72c-.783-.57-.38-1.81.588-1.81h3.461a1 1 0 00.951-.69l1.07-3.292z" }) });
1340
+ var import_jsx_runtime22 = require("react/jsx-runtime");
1341
+ var StartIconSolid = function(param) {
1342
+ var className = param.className;
1343
+ return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("svg", {
1344
+ xmlns: "http://www.w3.org/2000/svg",
1345
+ className: className || "h-5 w-5",
1346
+ viewBox: "0 0 20 20",
1347
+ fill: "currentColor",
1348
+ children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("path", {
1349
+ d: "M9.049 2.927c.3-.921 1.603-.921 1.902 0l1.07 3.292a1 1 0 00.95.69h3.462c.969 0 1.371 1.24.588 1.81l-2.8 2.034a1 1 0 00-.364 1.118l1.07 3.292c.3.921-.755 1.688-1.54 1.118l-2.8-2.034a1 1 0 00-1.175 0l-2.8 2.034c-.784.57-1.838-.197-1.539-1.118l1.07-3.292a1 1 0 00-.364-1.118L2.98 8.72c-.783-.57-.38-1.81.588-1.81h3.461a1 1 0 00.951-.69l1.07-3.292z"
1350
+ })
1351
+ });
913
1352
  };
914
1353
  var StarIconSolid_default = StartIconSolid;
915
-
916
1354
  // src/Common/RatingStars.tsx
917
- var import_jsx_runtime24 = require("react/jsx-runtime");
918
- var RatingStars = ({ avgRating, large }) => {
919
- const icons = [1, 2, 3, 4, 5].map((el) => {
920
- if (avgRating === 0) {
921
- return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(StarIconSolid_default, { className: `${large ? "h-5 w-5" : "h-3 w-3"} text-gray-200 dark:text-gray-400` }, `rating_star_${el}`);
922
- }
923
- if (Number.isInteger(avgRating)) {
924
- if (el <= avgRating) {
925
- return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(StarIconSolid_default, { className: `${large ? "h-5 w-5" : "h-3 w-3"} text-blue-500` }, `rating_star_${el}`);
926
- }
927
- return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(StarIconSolid_default, { className: `${large ? "h-5 w-5" : "h-3 w-3"} text-gray-200 dark:text-gray-400` }, `rating_star_${el}`);
928
- }
929
- const whole = Math.floor(avgRating);
930
- if (el <= whole) {
931
- return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(StarIconSolid_default, { className: `${large ? "h-5 w-5" : "h-3 w-3"} text-blue-500` }, `rating_star_${el}`);
932
- }
933
- return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(StarIcon_default, { percentage: avgRating - whole, color: "#00b4d8", className: `${large ? "h-5 w-5" : "h-3 w-3"}` }, `rating_star_${el}`);
934
- });
935
- return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
936
- Tippy_default,
937
- {
938
- content: avgRating === 0 ? "No ratings" : "Average Rating " + avgRating,
939
- className: "bg-gray-800 opacity-90 text-white rounded-md px-2 py-1 cursor-pointer h-fit",
940
- children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { className: "flex items-center space-x-0 justify-start", children: icons })
941
- }
942
- );
1355
+ var import_jsx_runtime23 = require("react/jsx-runtime");
1356
+ var RatingStars = function(param) {
1357
+ var avgRating = param.avgRating, large = param.large;
1358
+ var icons = [
1359
+ 1,
1360
+ 2,
1361
+ 3,
1362
+ 4,
1363
+ 5
1364
+ ].map(function(el) {
1365
+ if (avgRating === 0) {
1366
+ return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(StarIconSolid_default, {
1367
+ className: "".concat(large ? "h-5 w-5" : "h-3 w-3", " text-gray-200 dark:text-gray-400")
1368
+ }, "rating_star_".concat(el));
1369
+ }
1370
+ if (Number.isInteger(avgRating)) {
1371
+ if (el <= avgRating) {
1372
+ return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(StarIconSolid_default, {
1373
+ className: "".concat(large ? "h-5 w-5" : "h-3 w-3", " text-blue-500")
1374
+ }, "rating_star_".concat(el));
1375
+ }
1376
+ return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(StarIconSolid_default, {
1377
+ className: "".concat(large ? "h-5 w-5" : "h-3 w-3", " text-gray-200 dark:text-gray-400")
1378
+ }, "rating_star_".concat(el));
1379
+ }
1380
+ var whole = Math.floor(avgRating);
1381
+ if (el <= whole) {
1382
+ return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(StarIconSolid_default, {
1383
+ className: "".concat(large ? "h-5 w-5" : "h-3 w-3", " text-blue-500")
1384
+ }, "rating_star_".concat(el));
1385
+ }
1386
+ return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(StarIcon_default, {
1387
+ percentage: avgRating - whole,
1388
+ color: "#00b4d8",
1389
+ className: "".concat(large ? "h-5 w-5" : "h-3 w-3")
1390
+ }, "rating_star_".concat(el));
1391
+ });
1392
+ return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(Tippy_default, {
1393
+ content: avgRating === 0 ? "No ratings" : "Average Rating " + avgRating,
1394
+ className: "bg-gray-800 opacity-90 text-white rounded-md px-2 py-1 cursor-pointer h-fit",
1395
+ children: /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("div", {
1396
+ className: "flex items-center space-x-0 justify-start",
1397
+ children: icons
1398
+ })
1399
+ });
943
1400
  };
944
1401
  var RatingStars_default = RatingStars;
945
-
946
1402
  // src/Common/Slider.tsx
947
1403
  var import_react8 = require("react");
948
1404
  var import_use_debounce = require("use-debounce");
949
- var import_jsx_runtime25 = require("react/jsx-runtime");
950
- var Slider = ({ min, max, step, value, onChange }) => {
951
- const handleChange = (event) => {
952
- onChange(parseFloat(event.target.value));
953
- };
954
- return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
955
- "input",
956
- {
957
- type: "range",
958
- min,
959
- max,
960
- step,
961
- value,
962
- onChange: handleChange,
963
- className: `w-full h-2 rounded-lg range-input`
964
- }
965
- );
1405
+ var import_jsx_runtime24 = require("react/jsx-runtime");
1406
+ var Slider = function(param) {
1407
+ var min = param.min, max = param.max, step = param.step, value = param.value, onChange = param.onChange;
1408
+ var handleChange = function(event) {
1409
+ onChange(parseFloat(event.target.value));
1410
+ };
1411
+ return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("input", {
1412
+ type: "range",
1413
+ min: min,
1414
+ max: max,
1415
+ step: step,
1416
+ value: value,
1417
+ onChange: handleChange,
1418
+ className: "w-full h-2 rounded-lg range-input"
1419
+ });
966
1420
  };
967
- var DebouncedSlider = ({ min, max, handleUpdate, initialValue }) => {
968
- const [value, setValue] = (0, import_react8.useState)(initialValue);
969
- const debouncedUpdate = (0, import_use_debounce.useDebouncedCallback)((v) => {
970
- handleUpdate(v);
971
- }, 120, { trailing: true, leading: false });
972
- return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
973
- Slider,
974
- {
975
- min,
976
- max,
977
- step: 1,
978
- value,
979
- onChange: (v) => {
980
- setValue(v);
981
- debouncedUpdate(v);
982
- }
983
- }
984
- );
1421
+ var DebouncedSlider = function(param) {
1422
+ var min = param.min, max = param.max, handleUpdate = param.handleUpdate, initialValue = param.initialValue;
1423
+ var _ref = _sliced_to_array((0, import_react8.useState)(initialValue), 2), value = _ref[0], setValue = _ref[1];
1424
+ var debouncedUpdate = (0, import_use_debounce.useDebouncedCallback)(function(v) {
1425
+ handleUpdate(v);
1426
+ }, 120, {
1427
+ trailing: true,
1428
+ leading: false
1429
+ });
1430
+ return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(Slider, {
1431
+ min: min,
1432
+ max: max,
1433
+ step: 1,
1434
+ value: value,
1435
+ onChange: function(v) {
1436
+ setValue(v);
1437
+ debouncedUpdate(v);
1438
+ }
1439
+ });
985
1440
  };
986
1441
  Slider.Debounced = DebouncedSlider;
987
1442
  var Slider_default = Slider;
988
-
989
1443
  // src/Common/ToggleSwitch.tsx
990
1444
  var import_formik3 = require("formik");
991
1445
  var import_framer_motion3 = require("framer-motion");
992
- var import_jsx_runtime26 = require("react/jsx-runtime");
993
- var Formik = ({ label, name }) => {
994
- const [{ value }, , { setValue }] = (0, import_formik3.useField)(name);
995
- const handleChange = (e) => {
996
- setValue(e.target.checked);
997
- };
998
- return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("label", { className: "flex items-center space-x-2 cursor-pointer", children: [
999
- /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "relative", children: [
1000
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
1001
- "input",
1002
- {
1003
- type: "checkbox",
1004
- className: "opacity-0 absolute",
1005
- checked: value,
1006
- onChange: handleChange
1007
- }
1008
- ),
1009
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { className: `w-10 h-6 rounded-full p-[4px] transition-colors duration-300 ${value ? "bg-[#00b4d8]" : "bg-[#64748b]"}`, children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
1010
- import_framer_motion3.motion.div,
1011
- {
1012
- className: "w-4 h-4 bg-white rounded-full absolute top-1",
1013
- initial: false,
1014
- animate: {
1015
- x: value ? 16 : 0
1016
- },
1017
- transition: { type: "spring", stiffness: 500, damping: 30 }
1018
- }
1019
- ) })
1020
- ] }),
1021
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("span", { className: "text-sm font-medium text-gray-800 dark:text-gray-200", children: label })
1022
- ] });
1446
+ var import_jsx_runtime25 = require("react/jsx-runtime");
1447
+ var Formik = function(param) {
1448
+ var label = param.label, name = param.name;
1449
+ var _ref = _sliced_to_array((0, import_formik3.useField)(name), 3), value = _ref[0].value, setValue = _ref[2].setValue;
1450
+ var handleChange = function(e) {
1451
+ setValue(e.target.checked);
1452
+ };
1453
+ return /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("label", {
1454
+ className: "flex items-center space-x-2 cursor-pointer",
1455
+ children: [
1456
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("div", {
1457
+ className: "relative",
1458
+ children: [
1459
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("input", {
1460
+ type: "checkbox",
1461
+ className: "opacity-0 absolute",
1462
+ checked: value,
1463
+ onChange: handleChange
1464
+ }),
1465
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("div", {
1466
+ className: "w-10 h-6 rounded-full p-[4px] transition-colors duration-300 ".concat(value ? "bg-[#00b4d8]" : "bg-[#64748b]"),
1467
+ children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(import_framer_motion3.motion.div, {
1468
+ className: "w-4 h-4 bg-white rounded-full absolute top-1",
1469
+ initial: false,
1470
+ animate: {
1471
+ x: value ? 16 : 0
1472
+ },
1473
+ transition: {
1474
+ type: "spring",
1475
+ stiffness: 500,
1476
+ damping: 30
1477
+ }
1478
+ })
1479
+ })
1480
+ ]
1481
+ }),
1482
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("span", {
1483
+ className: "text-sm font-medium text-gray-800 dark:text-gray-200",
1484
+ children: label
1485
+ })
1486
+ ]
1487
+ });
1023
1488
  };
1024
- var ToggleSwitch = ({ label, onChange, value }) => {
1025
- const handleChange = (e) => {
1026
- onChange(e.target.checked);
1027
- };
1028
- return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("label", { className: "flex items-center space-x-2 cursor-pointer", children: [
1029
- /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "relative", children: [
1030
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
1031
- "input",
1032
- {
1033
- type: "checkbox",
1034
- className: "opacity-0 absolute",
1035
- checked: value,
1036
- onChange: handleChange
1037
- }
1038
- ),
1039
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { className: `w-10 h-6 rounded-full p-[4px] transition-colors duration-300 ${value ? "bg-[#00b4d8]" : "bg-[#64748b]"}`, children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
1040
- import_framer_motion3.motion.div,
1041
- {
1042
- className: "w-4 h-4 bg-white rounded-full absolute top-1",
1043
- initial: false,
1044
- animate: {
1045
- x: value ? 16 : 0
1046
- },
1047
- transition: { type: "spring", stiffness: 500, damping: 30 }
1048
- }
1049
- ) })
1050
- ] }),
1051
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("span", { className: "text-sm font-medium text-gray-800 dark:text-gray-200", children: label })
1052
- ] });
1489
+ var ToggleSwitch = function(param) {
1490
+ var label = param.label, onChange = param.onChange, value = param.value;
1491
+ var handleChange = function(e) {
1492
+ onChange(e.target.checked);
1493
+ };
1494
+ return /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("label", {
1495
+ className: "flex items-center space-x-2 cursor-pointer",
1496
+ children: [
1497
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("div", {
1498
+ className: "relative",
1499
+ children: [
1500
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("input", {
1501
+ type: "checkbox",
1502
+ className: "opacity-0 absolute",
1503
+ checked: value,
1504
+ onChange: handleChange
1505
+ }),
1506
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("div", {
1507
+ className: "w-10 h-6 rounded-full p-[4px] transition-colors duration-300 ".concat(value ? "bg-[#00b4d8]" : "bg-[#64748b]"),
1508
+ children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(import_framer_motion3.motion.div, {
1509
+ className: "w-4 h-4 bg-white rounded-full absolute top-1",
1510
+ initial: false,
1511
+ animate: {
1512
+ x: value ? 16 : 0
1513
+ },
1514
+ transition: {
1515
+ type: "spring",
1516
+ stiffness: 500,
1517
+ damping: 30
1518
+ }
1519
+ })
1520
+ })
1521
+ ]
1522
+ }),
1523
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("span", {
1524
+ className: "text-sm font-medium text-gray-800 dark:text-gray-200",
1525
+ children: label
1526
+ })
1527
+ ]
1528
+ });
1053
1529
  };
1054
1530
  ToggleSwitch.Formik = Formik;
1055
1531
  var ToggleSwitch_default = ToggleSwitch;
1056
-
1057
1532
  // src/Common/UserContentSwitcher.tsx
1058
1533
  var import_framer_motion4 = require("framer-motion");
1059
-
1060
1534
  // src/Icons/PlusCircleIcon.tsx
1061
- var import_jsx_runtime27 = require("react/jsx-runtime");
1062
- var PlusCircleIcon = ({ className }) => {
1063
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", className: className || "h-5 w-5", fill: "none", viewBox: "0 0 24 24", stroke: "currentColor", strokeWidth: 2, children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M12 9v3m0 0v3m0-3h3m-3 0H9m12 0a9 9 0 11-18 0 9 9 0 0118 0z" }) });
1535
+ var import_jsx_runtime26 = require("react/jsx-runtime");
1536
+ var PlusCircleIcon = function(param) {
1537
+ var className = param.className;
1538
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("svg", {
1539
+ xmlns: "http://www.w3.org/2000/svg",
1540
+ className: className || "h-5 w-5",
1541
+ fill: "none",
1542
+ viewBox: "0 0 24 24",
1543
+ stroke: "currentColor",
1544
+ strokeWidth: 2,
1545
+ children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("path", {
1546
+ strokeLinecap: "round",
1547
+ strokeLinejoin: "round",
1548
+ d: "M12 9v3m0 0v3m0-3h3m-3 0H9m12 0a9 9 0 11-18 0 9 9 0 0118 0z"
1549
+ })
1550
+ });
1064
1551
  };
1065
1552
  var PlusCircleIcon_default = PlusCircleIcon;
1066
-
1067
1553
  // src/Icons/ArrowCircleRight.tsx
1068
- var import_jsx_runtime28 = require("react/jsx-runtime");
1069
- var StartIconSolid2 = ({ className }) => {
1070
- return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", className: className || "h-5 w-5", fill: "none", viewBox: "0 0 24 24", stroke: "currentColor", strokeWidth: 2, children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M13 9l3 3m0 0l-3 3m3-3H8m13 0a9 9 0 11-18 0 9 9 0 0118 0z" }) });
1554
+ var import_jsx_runtime27 = require("react/jsx-runtime");
1555
+ var StartIconSolid2 = function(param) {
1556
+ var className = param.className;
1557
+ return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("svg", {
1558
+ xmlns: "http://www.w3.org/2000/svg",
1559
+ className: className || "h-5 w-5",
1560
+ fill: "none",
1561
+ viewBox: "0 0 24 24",
1562
+ stroke: "currentColor",
1563
+ strokeWidth: 2,
1564
+ children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("path", {
1565
+ strokeLinecap: "round",
1566
+ strokeLinejoin: "round",
1567
+ d: "M13 9l3 3m0 0l-3 3m3-3H8m13 0a9 9 0 11-18 0 9 9 0 0118 0z"
1568
+ })
1569
+ });
1071
1570
  };
1072
1571
  var ArrowCircleRight_default = StartIconSolid2;
1073
-
1074
1572
  // src/Common/UserContentSwitcher.tsx
1075
- var import_jsx_runtime29 = require("react/jsx-runtime");
1076
- var UserContentSwitcher = ({ icon1: Icon1, icon2: Icon2, setGalleryMode, galleryMode, title1, title2 }) => {
1077
- return /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)("div", { className: "relative flex flex-row items-center my-2 bg-slate-100 dark:bg-slate-900 w-full h-14 rounded-lg", children: [
1078
- /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
1079
- import_framer_motion4.motion.div,
1080
- {
1081
- className: "absolute w-1/2 h-11 rounded-md bg-white dark:bg-slate-600",
1082
- animate: {
1083
- x: galleryMode === title1.toLowerCase() ? "1%" : "99%"
1084
- },
1085
- transition: {
1086
- type: "spring",
1087
- damping: 20,
1088
- stiffness: 200
1089
- }
1090
- }
1091
- ),
1092
- /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(
1093
- "button",
1094
- {
1095
- onClick: () => setGalleryMode(title1.toLowerCase()),
1096
- className: "py-2 flex flex-row w-1/2 justify-center items-center gap-1 z-10",
1097
- children: [
1098
- /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
1099
- "span",
1100
- {
1101
- className: `truncate ${galleryMode === title1.toLowerCase() ? "text-primary dark:text-blue-400" : "text-slate-500 dark:text-slate-400 opacity-90"}`,
1102
- children: title1.toLocaleUpperCase()
1103
- }
1104
- ),
1105
- Icon1 ? /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
1106
- Icon1,
1107
- {
1108
- className: `h-5 w-5 ${galleryMode === title1.toLowerCase() ? "text-primary dark:text-blue-400" : "text-slate-500 dark:text-slate-400 opacity-90"}`
1109
- }
1110
- ) : /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
1111
- PlusCircleIcon_default,
1112
- {
1113
- className: `h-5 w-5 ${galleryMode === title1.toLowerCase() ? "text-primary dark:text-blue-400" : "text-slate-500 dark:text-slate-400 opacity-90"}`
1114
- }
1115
- )
1116
- ]
1117
- }
1118
- ),
1119
- /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(
1120
- "button",
1121
- {
1122
- onClick: () => setGalleryMode(title2.toLowerCase()),
1123
- className: "py-2 flex flex-row w-1/2 justify-center items-center gap-1 z-10",
1573
+ var import_jsx_runtime28 = require("react/jsx-runtime");
1574
+ var UserContentSwitcher = function(param) {
1575
+ var Icon1 = param.icon1, Icon2 = param.icon2, setGalleryMode = param.setGalleryMode, galleryMode = param.galleryMode, title1 = param.title1, title2 = param.title2;
1576
+ return /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("div", {
1577
+ className: "relative flex flex-row items-center my-2 bg-slate-100 dark:bg-slate-900 w-full h-14 rounded-lg",
1124
1578
  children: [
1125
- /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
1126
- "span",
1127
- {
1128
- className: `truncate ${galleryMode === title2.toLowerCase() ? "text-primary dark:text-blue-400" : "text-slate-500 dark:text-slate-400 opacity-90"}`,
1129
- children: title2.toLocaleUpperCase()
1130
- }
1131
- ),
1132
- Icon2 ? /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
1133
- Icon2,
1134
- {
1135
- className: `h-5 w-5 ${galleryMode === title2.toLowerCase() ? "text-primary dark:text-blue-400" : "text-slate-500 dark:text-slate-400 opacity-90"}`
1136
- }
1137
- ) : /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
1138
- ArrowCircleRight_default,
1139
- {
1140
- className: `h-5 w-5 ${galleryMode === title2.toLowerCase() ? "text-primary dark:text-blue-400" : "text-slate-500 dark:text-slate-400 opacity-90"}`
1141
- }
1142
- )
1579
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(import_framer_motion4.motion.div, {
1580
+ className: "absolute w-1/2 h-11 rounded-md bg-white dark:bg-slate-600",
1581
+ animate: {
1582
+ x: galleryMode === title1.toLowerCase() ? "1%" : "99%"
1583
+ },
1584
+ transition: {
1585
+ type: "spring",
1586
+ damping: 20,
1587
+ stiffness: 200
1588
+ }
1589
+ }),
1590
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("button", {
1591
+ onClick: function() {
1592
+ return setGalleryMode(title1.toLowerCase());
1593
+ },
1594
+ className: "py-2 flex flex-row w-1/2 justify-center items-center gap-1 z-10",
1595
+ children: [
1596
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("span", {
1597
+ className: "truncate ".concat(galleryMode === title1.toLowerCase() ? "text-primary dark:text-blue-400" : "text-slate-500 dark:text-slate-400 opacity-90"),
1598
+ children: title1.toLocaleUpperCase()
1599
+ }),
1600
+ Icon1 ? /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(Icon1, {
1601
+ className: "h-5 w-5 ".concat(galleryMode === title1.toLowerCase() ? "text-primary dark:text-blue-400" : "text-slate-500 dark:text-slate-400 opacity-90")
1602
+ }) : /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(PlusCircleIcon_default, {
1603
+ className: "h-5 w-5 ".concat(galleryMode === title1.toLowerCase() ? "text-primary dark:text-blue-400" : "text-slate-500 dark:text-slate-400 opacity-90")
1604
+ })
1605
+ ]
1606
+ }),
1607
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("button", {
1608
+ onClick: function() {
1609
+ return setGalleryMode(title2.toLowerCase());
1610
+ },
1611
+ className: "py-2 flex flex-row w-1/2 justify-center items-center gap-1 z-10",
1612
+ children: [
1613
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("span", {
1614
+ className: "truncate ".concat(galleryMode === title2.toLowerCase() ? "text-primary dark:text-blue-400" : "text-slate-500 dark:text-slate-400 opacity-90"),
1615
+ children: title2.toLocaleUpperCase()
1616
+ }),
1617
+ Icon2 ? /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(Icon2, {
1618
+ className: "h-5 w-5 ".concat(galleryMode === title2.toLowerCase() ? "text-primary dark:text-blue-400" : "text-slate-500 dark:text-slate-400 opacity-90")
1619
+ }) : /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(ArrowCircleRight_default, {
1620
+ className: "h-5 w-5 ".concat(galleryMode === title2.toLowerCase() ? "text-primary dark:text-blue-400" : "text-slate-500 dark:text-slate-400 opacity-90")
1621
+ })
1622
+ ]
1623
+ })
1143
1624
  ]
1144
- }
1145
- )
1146
- ] });
1625
+ });
1147
1626
  };
1148
1627
  var UserContentSwitcher_default = UserContentSwitcher;
1149
-
1150
1628
  // src/ProgressBar/ProgressBarSimple.tsx
1151
- var import_jsx_runtime30 = require("react/jsx-runtime");
1152
- var ProgressBarSimple = ({ progress, color, height = 10, backgroundColor = "#ccc" }) => {
1153
- return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("div", { className: "w-full", children: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
1154
- "div",
1155
- {
1156
- className: "w-full overflow-hidden transition-all duration-150 ease-in-out",
1157
- style: {
1158
- backgroundColor,
1159
- height: `${height}px`,
1160
- borderRadius: `${height / 2}px`
1161
- },
1162
- children: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
1163
- "div",
1164
- {
1165
- className: "transition-all duration-150 ease-in-out",
1166
- style: {
1167
- width: `${progress}%`,
1168
- backgroundColor: color,
1169
- height: `${height}px`,
1170
- borderRadius: `${height / 2}px`
1171
- }
1172
- }
1173
- )
1174
- }
1175
- ) });
1629
+ var import_jsx_runtime29 = require("react/jsx-runtime");
1630
+ var ProgressBarSimple = function(param) {
1631
+ var progress = param.progress, color = param.color, _param_height = param.height, height = _param_height === void 0 ? 10 : _param_height, _param_backgroundColor = param.backgroundColor, backgroundColor = _param_backgroundColor === void 0 ? "#ccc" : _param_backgroundColor;
1632
+ return /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("div", {
1633
+ className: "w-full",
1634
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("div", {
1635
+ className: "w-full overflow-hidden transition-all duration-150 ease-in-out",
1636
+ style: {
1637
+ backgroundColor: backgroundColor,
1638
+ height: "".concat(height, "px"),
1639
+ borderRadius: "".concat(height / 2, "px")
1640
+ },
1641
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("div", {
1642
+ className: "transition-all duration-150 ease-in-out",
1643
+ style: {
1644
+ width: "".concat(progress, "%"),
1645
+ backgroundColor: color,
1646
+ height: "".concat(height, "px"),
1647
+ borderRadius: "".concat(height / 2, "px")
1648
+ }
1649
+ })
1650
+ })
1651
+ });
1176
1652
  };
1177
1653
  var ProgressBarSimple_default = ProgressBarSimple;
1178
-
1179
1654
  // src/ProgressBar/ProgressBar.tsx
1180
- var import_jsx_runtime31 = require("react/jsx-runtime");
1181
- var ProgressBar = ({ progress }) => /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("div", { className: "-mt-2 mb-6", children: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("div", { className: "bg-gray-100 rounded-full h-2", children: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
1182
- "div",
1183
- {
1184
- className: `rounded-full h-2 ${progress === 100 ? "bg-green-400" : "bg-gray-100"}`,
1185
- style: {
1186
- width: `${progress}%`,
1187
- minWidth: "100%",
1188
- position: "absolute"
1189
- }
1190
- }
1191
- ) }) }) });
1192
- var ProgressStepBar = ({ steps, stepIndex, onStepClick, color }) => {
1193
- return /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("div", { className: "flex w-full items-center space-x-0.5 -mt-1 overflow-hidden", children: steps.map((el, i) => {
1194
- return /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("div", { className: "flex-1 relative", children: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
1195
- Tippy_default,
1196
- {
1197
- content: el.label,
1198
- className: tippyClassname,
1199
- children: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("div", { className: "mb-4", children: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
1200
- "div",
1201
- {
1202
- onClick: () => onStepClick == null ? void 0 : onStepClick(i),
1203
- className: "cursor-pointer bg-gray-100 rounded-full h-2 overflow-hidden",
1204
- children: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
1205
- "div",
1206
- {
1207
- className: `cursor-pointer rounded-full h-2 ${stepIndex >= i ? "bg-green-400" : "bg-gray-100"}`,
1208
- style: {
1209
- width: `${stepIndex >= i ? 100 : 0}%`,
1210
- transition: "width 0.3s ease"
1211
- }
1212
- }
1213
- )
1214
- }
1215
- ) })
1216
- }
1217
- ) }, `index_progress_${el.label}`);
1218
- }) });
1655
+ var import_jsx_runtime30 = require("react/jsx-runtime");
1656
+ var ProgressBar = function(param) {
1657
+ var progress = param.progress;
1658
+ return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("div", {
1659
+ children: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("div", {
1660
+ className: "-mt-2 mb-6",
1661
+ children: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("div", {
1662
+ className: "bg-gray-100 rounded-full h-2",
1663
+ children: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("div", {
1664
+ className: "rounded-full h-2 ".concat(progress === 100 ? "bg-green-400" : "bg-gray-100"),
1665
+ style: {
1666
+ width: "".concat(progress, "%"),
1667
+ minWidth: "100%",
1668
+ position: "absolute"
1669
+ }
1670
+ })
1671
+ })
1672
+ })
1673
+ });
1674
+ };
1675
+ var ProgressStepBar = function(param) {
1676
+ var steps = param.steps, stepIndex = param.stepIndex, onStepClick = param.onStepClick, color = param.color;
1677
+ return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("div", {
1678
+ className: "flex w-full items-center space-x-0.5 -mt-1 overflow-hidden",
1679
+ children: steps.map(function(el, i) {
1680
+ return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("div", {
1681
+ className: "flex-1 relative",
1682
+ children: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(Tippy_default, {
1683
+ content: el.label,
1684
+ className: tippyClassname,
1685
+ children: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("div", {
1686
+ className: "mb-4",
1687
+ children: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("div", {
1688
+ onClick: function() {
1689
+ return onStepClick === null || onStepClick === void 0 ? void 0 : onStepClick(i);
1690
+ },
1691
+ className: "cursor-pointer bg-gray-100 rounded-full h-2 overflow-hidden",
1692
+ children: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("div", {
1693
+ className: "cursor-pointer rounded-full h-2 ".concat(stepIndex >= i ? "bg-green-400" : "bg-gray-100"),
1694
+ style: {
1695
+ width: "".concat(stepIndex >= i ? 100 : 0, "%"),
1696
+ transition: "width 0.3s ease"
1697
+ }
1698
+ })
1699
+ })
1700
+ })
1701
+ })
1702
+ }, "index_progress_".concat(el.label));
1703
+ })
1704
+ });
1219
1705
  };
1220
1706
  ProgressBar.Step = ProgressStepBar;
1221
1707
  var ProgressBar_default = ProgressBar;
1222
-
1223
1708
  // src/ProgressBar/CircleProgress.tsx
1224
- var import_jsx_runtime32 = require("react/jsx-runtime");
1225
- var CircleProgress = ({ twColor, percentage, radius, fill, strokeWidth }) => {
1226
- const r = radius;
1227
- const cx = "50%";
1228
- const cy = "50%";
1229
- const w = Math.round(radius / 16);
1230
- const strokeWidthCalc = strokeWidth ? strokeWidth : w < 8 ? 8 : w;
1231
- const size = radius * 2 + strokeWidthCalc;
1232
- return /* @__PURE__ */ (0, import_jsx_runtime32.jsx)("div", { style: { height: size, width: size }, children: /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)("svg", { viewBox: `0 0 ${size} ${size}`, className: "-rotate-90", children: [
1233
- /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
1234
- "circle",
1235
- {
1236
- className: "text-white/50 dark:text-slate-200/50",
1237
- strokeWidth: strokeWidthCalc - 0.5,
1238
- stroke: "currentColor",
1239
- fill: fill || "transparent",
1240
- r,
1241
- cx,
1242
- cy
1243
- }
1244
- ),
1245
- /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
1246
- "circle",
1247
- {
1248
- strokeDasharray: 2 * Math.PI * r,
1249
- strokeDashoffset: 2 * Math.PI * r - percentage / 100 * 2 * Math.PI * r,
1250
- stroke: twColor || "white/50",
1251
- strokeWidth: strokeWidthCalc,
1252
- strokeLinecap: "round",
1253
- fill: "transparent",
1254
- r,
1255
- cx,
1256
- cy
1257
- }
1258
- )
1259
- ] }) });
1709
+ var import_jsx_runtime31 = require("react/jsx-runtime");
1710
+ var CircleProgress = function(param) {
1711
+ var twColor = param.twColor, percentage = param.percentage, radius = param.radius, fill = param.fill, strokeWidth = param.strokeWidth;
1712
+ var r = radius;
1713
+ var cx = "50%";
1714
+ var cy = "50%";
1715
+ var w = Math.round(radius / 16);
1716
+ var strokeWidthCalc = strokeWidth ? strokeWidth : w < 8 ? 8 : w;
1717
+ var size = radius * 2 + strokeWidthCalc;
1718
+ return /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("div", {
1719
+ style: {
1720
+ height: size,
1721
+ width: size
1722
+ },
1723
+ children: /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)("svg", {
1724
+ viewBox: "0 0 ".concat(size, " ").concat(size),
1725
+ className: "-rotate-90",
1726
+ children: [
1727
+ /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("circle", {
1728
+ className: "text-white/50 dark:text-slate-200/50",
1729
+ strokeWidth: strokeWidthCalc - 0.5,
1730
+ stroke: "currentColor",
1731
+ fill: fill || "transparent",
1732
+ r: r,
1733
+ cx: cx,
1734
+ cy: cy
1735
+ }),
1736
+ /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("circle", {
1737
+ strokeDasharray: 2 * Math.PI * r,
1738
+ strokeDashoffset: 2 * Math.PI * r - percentage / 100 * 2 * Math.PI * r,
1739
+ stroke: twColor || "white/50",
1740
+ strokeWidth: strokeWidthCalc,
1741
+ strokeLinecap: "round",
1742
+ fill: "transparent",
1743
+ r: r,
1744
+ cx: cx,
1745
+ cy: cy
1746
+ })
1747
+ ]
1748
+ })
1749
+ });
1260
1750
  };
1261
1751
  var CircleProgress_default = CircleProgress;
1262
-
1263
1752
  // src/ProgressBar/CourseProgress.tsx
1264
- var import_jsx_runtime33 = require("react/jsx-runtime");
1753
+ var import_jsx_runtime32 = require("react/jsx-runtime");
1265
1754
  var PRIMARY_COLOR2 = "#00b4d8";
1266
- var CourseProgress = ({ twColor, percentage, label }) => {
1267
- const cx = "50%";
1268
- const cy = "50%";
1269
- const r = 50;
1270
- const strokeWidth = 10;
1271
- const fullLength = 2 * Math.PI * r;
1272
- const length = fullLength * (percentage < 1 ? 1 - percentage : 0.01);
1273
- const strokeDashoffset = 2 * Math.PI * r - percentage / 100 * 2 * Math.PI * r;
1274
- return /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)("div", { className: "flex items-center flex-col justify-center space-y-0 dark:bg-inherit dark:text-gray-300", children: [
1275
- /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)("div", { className: `relative flex items-center justify-center -my-2 -mt-1 overflow-hidden rounded-full`, children: [
1276
- /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)("svg", { className: `-rotate-90`, children: [
1277
- /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
1278
- "circle",
1279
- {
1280
- className: "text-gray-300",
1281
- strokeWidth,
1282
- stroke: "currentColor",
1283
- fill: "transparent",
1284
- r,
1285
- cx,
1286
- cy
1287
- }
1288
- ),
1289
- /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
1290
- "circle",
1291
- {
1292
- style: { strokeDashoffset },
1293
- color: twColor || PRIMARY_COLOR2,
1294
- ref: (ref) => {
1295
- if (ref) {
1296
- }
1297
- },
1298
- strokeWidth,
1299
- strokeLinecap: "round",
1300
- stroke: "currentColor",
1301
- fill: "transparent",
1302
- r,
1303
- cx,
1304
- cy,
1305
- strokeDasharray: fullLength,
1306
- strokeDashoffset: length
1307
- }
1308
- )
1309
- ] }),
1310
- /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("span", { className: `absolute top-[${50 / 2}] text-xl leading-none font-medium font-header hidden sm:block`, children: percentage.toString() + "%" })
1311
- ] }),
1312
- /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("p", { className: "font-medium sm:text-xl font-header text-center w-full", children: label })
1313
- ] });
1755
+ var CourseProgress = function(param) {
1756
+ var twColor = param.twColor, percentage = param.percentage, label = param.label;
1757
+ var cx = "50%";
1758
+ var cy = "50%";
1759
+ var r = 50;
1760
+ var strokeWidth = 10;
1761
+ var fullLength = 2 * Math.PI * r;
1762
+ var length = fullLength * (percentage < 1 ? 1 - percentage : 0.01);
1763
+ var strokeDashoffset = 2 * Math.PI * r - percentage / 100 * 2 * Math.PI * r;
1764
+ return /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)("div", {
1765
+ className: "flex items-center flex-col justify-center space-y-0 dark:bg-inherit dark:text-gray-300",
1766
+ children: [
1767
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)("div", {
1768
+ className: "relative flex items-center justify-center -my-2 -mt-1 overflow-hidden rounded-full",
1769
+ children: [
1770
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)("svg", {
1771
+ className: "-rotate-90",
1772
+ children: [
1773
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)("circle", {
1774
+ className: "text-gray-300",
1775
+ strokeWidth: strokeWidth,
1776
+ stroke: "currentColor",
1777
+ fill: "transparent",
1778
+ r: r,
1779
+ cx: cx,
1780
+ cy: cy
1781
+ }),
1782
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)("circle", {
1783
+ style: {
1784
+ strokeDashoffset: strokeDashoffset
1785
+ },
1786
+ color: twColor || PRIMARY_COLOR2,
1787
+ ref: function(ref) {
1788
+ if (ref) {}
1789
+ },
1790
+ strokeWidth: strokeWidth,
1791
+ strokeLinecap: "round",
1792
+ stroke: "currentColor",
1793
+ fill: "transparent",
1794
+ r: r,
1795
+ cx: cx,
1796
+ cy: cy,
1797
+ strokeDasharray: fullLength,
1798
+ strokeDashoffset: length
1799
+ })
1800
+ ]
1801
+ }),
1802
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)("span", {
1803
+ className: "absolute top-[".concat(50 / 2, "] text-xl leading-none font-medium font-header hidden sm:block"),
1804
+ children: percentage.toString() + "%"
1805
+ })
1806
+ ]
1807
+ }),
1808
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)("p", {
1809
+ className: "font-medium sm:text-xl font-header text-center w-full",
1810
+ children: label
1811
+ })
1812
+ ]
1813
+ });
1314
1814
  };
1315
- var Small = ({ twColor, percentage, label }) => {
1316
- const cx = 18;
1317
- const cy = 18;
1318
- const r = 14;
1319
- const strokeWidth = 4;
1320
- const strokeDashoffset = 2 * Math.PI * r - percentage / 100 * 2 * Math.PI * r;
1321
- return /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)("div", { className: "flex items-center space-x-2 rounded-full bg-transparent border-2 border-slate-100 w-full", children: [
1322
- /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("div", { className: `flex items-center justify-center overflow-hidden`, children: /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)("svg", { className: `w-10 h-11 transform translate-x-1 translate-y-1`, children: [
1323
- /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
1324
- "circle",
1325
- {
1326
- className: "text-gray-300",
1327
- strokeWidth,
1328
- stroke: "currentColor",
1329
- fill: "transparent",
1330
- r,
1331
- cx,
1332
- cy
1333
- }
1334
- ),
1335
- /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
1336
- "circle",
1337
- {
1338
- style: { strokeDashoffset },
1339
- className: twColor || "text-blue-500",
1340
- ref: (ref) => {
1341
- if (ref) {
1342
- }
1343
- },
1344
- strokeWidth,
1345
- strokeLinecap: "round",
1346
- stroke: "currentColor",
1347
- fill: "transparent",
1348
- r,
1349
- cx,
1350
- cy
1351
- }
1352
- )
1353
- ] }) }),
1354
- /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)("p", { className: "font-medium dark:text-gray-300 text-gray-600 text-sm font-header mt-1", children: [
1355
- label,
1356
- " ",
1357
- percentage.toString() + "%"
1358
- ] })
1359
- ] });
1815
+ var Small = function(param) {
1816
+ var twColor = param.twColor, percentage = param.percentage, label = param.label;
1817
+ var cx = 18;
1818
+ var cy = 18;
1819
+ var r = 14;
1820
+ var strokeWidth = 4;
1821
+ var strokeDashoffset = 2 * Math.PI * r - percentage / 100 * 2 * Math.PI * r;
1822
+ return /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)("div", {
1823
+ className: "flex items-center space-x-2 rounded-full bg-transparent border-2 border-slate-100 w-full",
1824
+ children: [
1825
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)("div", {
1826
+ className: "flex items-center justify-center overflow-hidden",
1827
+ children: /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)("svg", {
1828
+ className: "w-10 h-11 transform translate-x-1 translate-y-1",
1829
+ children: [
1830
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)("circle", {
1831
+ className: "text-gray-300",
1832
+ strokeWidth: strokeWidth,
1833
+ stroke: "currentColor",
1834
+ fill: "transparent",
1835
+ r: r,
1836
+ cx: cx,
1837
+ cy: cy
1838
+ }),
1839
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)("circle", {
1840
+ style: {
1841
+ strokeDashoffset: strokeDashoffset
1842
+ },
1843
+ className: twColor || "text-blue-500",
1844
+ ref: function(ref) {
1845
+ if (ref) {}
1846
+ },
1847
+ strokeWidth: strokeWidth,
1848
+ strokeLinecap: "round",
1849
+ stroke: "currentColor",
1850
+ fill: "transparent",
1851
+ r: r,
1852
+ cx: cx,
1853
+ cy: cy
1854
+ })
1855
+ ]
1856
+ })
1857
+ }),
1858
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)("p", {
1859
+ className: "font-medium dark:text-gray-300 text-gray-600 text-sm font-header mt-1",
1860
+ children: [
1861
+ label,
1862
+ " ",
1863
+ percentage.toString() + "%"
1864
+ ]
1865
+ })
1866
+ ]
1867
+ });
1360
1868
  };
1361
1869
  CourseProgress.Small = Small;
1362
1870
  var CourseProgress_default = CourseProgress;
1363
-
1364
1871
  // src/ProgressBar/ScrollProgress.tsx
1365
1872
  var import_react9 = require("react");
1366
- var import_jsx_runtime34 = require("react/jsx-runtime");
1873
+ var import_jsx_runtime33 = require("react/jsx-runtime");
1367
1874
  var PRIMARY_COLOR3 = "#00b4d8";
1368
- var ScrollProgress = () => {
1369
- const [scrollPercentage, setScrollPercentage] = (0, import_react9.useState)(0);
1370
- (0, import_react9.useEffect)(() => {
1371
- const handleScroll = () => {
1372
- const windowHeight = window.innerHeight;
1373
- const documentHeight = document.documentElement.scrollHeight;
1374
- const scrollY = window.scrollY;
1375
- const scrollPercent = scrollY / (documentHeight - windowHeight) * 100;
1376
- setScrollPercentage(scrollPercent);
1377
- };
1378
- window.addEventListener("scroll", handleScroll);
1379
- return () => {
1380
- window.removeEventListener("scroll", handleScroll);
1381
- };
1382
- }, []);
1383
- return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
1384
- "div",
1385
- {
1386
- style: {
1387
- height: "4px",
1388
- borderRadius: 2,
1389
- width: "100%",
1390
- // backgroundColor: '#d1dced',
1391
- position: "fixed",
1392
- top: "62px",
1393
- left: "0px",
1394
- right: "0px"
1395
- },
1396
- children: /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
1397
- "div",
1398
- {
1399
- style: {
1400
- height: "100%",
1401
- backgroundColor: PRIMARY_COLOR3,
1875
+ var ScrollProgress = function() {
1876
+ var _ref = _sliced_to_array((0, import_react9.useState)(0), 2), scrollPercentage = _ref[0], setScrollPercentage = _ref[1];
1877
+ (0, import_react9.useEffect)(function() {
1878
+ var handleScroll = function() {
1879
+ var windowHeight = window.innerHeight;
1880
+ var documentHeight = document.documentElement.scrollHeight;
1881
+ var scrollY = window.scrollY;
1882
+ var scrollPercent = scrollY / (documentHeight - windowHeight) * 100;
1883
+ setScrollPercentage(scrollPercent);
1884
+ };
1885
+ window.addEventListener("scroll", handleScroll);
1886
+ return function() {
1887
+ window.removeEventListener("scroll", handleScroll);
1888
+ };
1889
+ }, []);
1890
+ return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("div", {
1891
+ style: {
1892
+ height: "4px",
1402
1893
  borderRadius: 2,
1403
- width: `${scrollPercentage}%`
1404
- }
1405
- }
1406
- )
1407
- }
1408
- );
1894
+ width: "100%",
1895
+ // backgroundColor: '#d1dced',
1896
+ position: "fixed",
1897
+ top: "62px",
1898
+ left: "0px",
1899
+ right: "0px"
1900
+ },
1901
+ children: /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("div", {
1902
+ style: {
1903
+ height: "100%",
1904
+ backgroundColor: PRIMARY_COLOR3,
1905
+ borderRadius: 2,
1906
+ width: "".concat(scrollPercentage, "%")
1907
+ }
1908
+ })
1909
+ });
1409
1910
  };
1410
1911
  var ScrollProgress_default = ScrollProgress;
1411
-
1412
1912
  // src/Icons/AnimateLogo.tsx
1413
1913
  var import_react10 = require("react");
1414
- var import_jsx_runtime35 = require("react/jsx-runtime");
1415
- var AnimateLogo = () => {
1416
- const [isFirefox, setIsFirefox] = (0, import_react10.useState)(false);
1417
- (0, import_react10.useEffect)(() => {
1418
- const userAgent = window.navigator.userAgent;
1419
- setIsFirefox(userAgent.indexOf("Firefox") > -1);
1420
- }, []);
1421
- if (isFirefox) {
1422
- return /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", className: "animate-pulse", viewBox: "0 0 600 600", children: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("g", { children: /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(
1423
- "path",
1424
- {
1425
- className: "stroke-black dark:stroke-white text-gray-900 dark:text-gray-50",
1426
- stroke: "currentColor",
1427
- fill: "none",
1428
- strokeLinecap: "round",
1429
- strokeMiterlimit: "10",
1430
- strokeWidth: "82",
1431
- strokeDasharray: "1600",
1432
- d: "M466.49 164.79c17.79 34.76 25.48 75.66 19.08 118.96-11.28 76.36-67.11 139.06-141.89 158.25-127.11 32.61-243.49-61.27-245.86-184.81C95.79 150.86 182.9 60.52 289.23 58.56c33.95-.63 66.08 7.48 94.22 22.29 0 0 15.68 6.34 10.14 23.19 0 0-68.52 219.82-352.61 268.06",
1433
- children: [
1434
- /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
1435
- "animate",
1436
- {
1437
- attributeName: "stroke-dashoffset",
1438
- to: "0",
1439
- from: "1600",
1440
- dur: "4s",
1441
- fill: "freeze",
1442
- repeatCount: "indefinite",
1443
- calcMode: "cubic",
1444
- keyTimes: "0;0.375;0.5;0.875;1",
1445
- keySplines: "0 0.26 0 1;0 0.26 0 1;0 0.26 0 1;0 0.26 0 1",
1446
- values: "1600;0;0;1600;1600"
1447
- }
1448
- ),
1449
- /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
1450
- "animateTransform",
1451
- {
1452
- attributeName: "transform",
1453
- type: "rotate",
1454
- from: "0 300 300",
1455
- to: "360 300 300",
1456
- dur: "2s",
1457
- fill: "freeze",
1458
- repeatCount: "indefinite",
1459
- calcMode: "cubic",
1460
- keyTimes: "0;0.75;1",
1461
- keySplines: "0 0.26 0 1",
1462
- values: "0 300 300;360 300 300;360 300 300;"
1463
- }
1464
- )
1465
- ]
1466
- }
1467
- ) }) });
1468
- }
1469
- return /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 600 600", children: /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(
1470
- "g",
1471
- {
1472
- style: {
1473
- transformOrigin: "center"
1474
- },
1475
- transform: "translate(300 300) rotate(0)",
1476
- height: 176,
1477
- width: 176,
1478
- children: [
1479
- /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
1480
- "path",
1481
- {
1482
- className: "stroke-black dark:stroke-white text-gray-900 dark:text-gray-50",
1483
- stroke: "currentColor",
1484
- id: "motionPath",
1485
- fill: "none",
1486
- strokeLinecap: "round",
1487
- height: 600,
1488
- width: 600,
1914
+ var import_jsx_runtime34 = require("react/jsx-runtime");
1915
+ var AnimateLogo = function() {
1916
+ var _ref = _sliced_to_array((0, import_react10.useState)(false), 2), isFirefox = _ref[0], setIsFirefox = _ref[1];
1917
+ (0, import_react10.useEffect)(function() {
1918
+ var userAgent = window.navigator.userAgent;
1919
+ setIsFirefox(userAgent.indexOf("Firefox") > -1);
1920
+ }, []);
1921
+ if (isFirefox) {
1922
+ return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("svg", {
1923
+ xmlns: "http://www.w3.org/2000/svg",
1924
+ className: "animate-pulse",
1925
+ viewBox: "0 0 600 600",
1926
+ children: /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("g", {
1927
+ children: /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)("path", {
1928
+ className: "stroke-black dark:stroke-white text-gray-900 dark:text-gray-50",
1929
+ stroke: "currentColor",
1930
+ fill: "none",
1931
+ strokeLinecap: "round",
1932
+ strokeMiterlimit: "10",
1933
+ strokeWidth: "82",
1934
+ strokeDasharray: "1600",
1935
+ d: "M466.49 164.79c17.79 34.76 25.48 75.66 19.08 118.96-11.28 76.36-67.11 139.06-141.89 158.25-127.11 32.61-243.49-61.27-245.86-184.81C95.79 150.86 182.9 60.52 289.23 58.56c33.95-.63 66.08 7.48 94.22 22.29 0 0 15.68 6.34 10.14 23.19 0 0-68.52 219.82-352.61 268.06",
1936
+ children: [
1937
+ /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("animate", {
1938
+ attributeName: "stroke-dashoffset",
1939
+ to: "0",
1940
+ from: "1600",
1941
+ dur: "4s",
1942
+ fill: "freeze",
1943
+ repeatCount: "indefinite",
1944
+ calcMode: "cubic",
1945
+ keyTimes: "0;0.375;0.5;0.875;1",
1946
+ keySplines: "0 0.26 0 1;0 0.26 0 1;0 0.26 0 1;0 0.26 0 1",
1947
+ values: "1600;0;0;1600;1600"
1948
+ }),
1949
+ /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("animateTransform", {
1950
+ attributeName: "transform",
1951
+ type: "rotate",
1952
+ from: "0 300 300",
1953
+ to: "360 300 300",
1954
+ dur: "2s",
1955
+ fill: "freeze",
1956
+ repeatCount: "indefinite",
1957
+ calcMode: "cubic",
1958
+ keyTimes: "0;0.75;1",
1959
+ keySplines: "0 0.26 0 1",
1960
+ values: "0 300 300;360 300 300;360 300 300;"
1961
+ })
1962
+ ]
1963
+ })
1964
+ })
1965
+ });
1966
+ }
1967
+ return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("svg", {
1968
+ xmlns: "http://www.w3.org/2000/svg",
1969
+ viewBox: "0 0 600 600",
1970
+ children: /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)("g", {
1489
1971
  style: {
1490
- transformOrigin: "center"
1972
+ transformOrigin: "center"
1491
1973
  },
1492
- strokeMiterlimit: "10",
1493
- strokeWidth: "82",
1494
- strokeDasharray: "1600",
1495
- d: "M466.49 164.79c17.79 34.76 25.48 75.66 19.08 118.96-11.28 76.36-67.11 139.06-141.89 158.25-127.11 32.61-243.49-61.27-245.86-184.81C95.79 150.86 182.9 60.52 289.23 58.56c33.95-.63 66.08 7.48 94.22 22.29 0 0 15.68 6.34 10.14 23.19 0 0-68.52 219.82-352.61 268.06",
1496
- children: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
1497
- "animate",
1498
- {
1499
- attributeName: "stroke-dashoffset",
1500
- to: "0",
1501
- from: "1600",
1502
- dur: "4s",
1503
- fill: "freeze",
1504
- repeatCount: "indefinite",
1505
- calcMode: "cubic",
1506
- keyTimes: "0;0.375;0.5;0.875;1",
1507
- keySplines: "0 0.26 0 1;0 0.26 0 1;0 0.26 0 1;0 0.26 0 1",
1508
- values: "1600;0;0;1600;1600"
1509
- }
1510
- )
1511
- }
1512
- ),
1513
- /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
1514
- "animateTransform",
1515
- {
1516
- attributeName: "transform",
1517
- type: "rotate",
1518
- from: "0",
1519
- to: "360",
1520
- dur: "2s",
1521
- fill: "freeze",
1522
- repeatCount: "indefinite",
1523
- calcMode: "cubic",
1524
- keyTimes: "0;0.75;1",
1525
- keySplines: "0 0.26 0 1",
1526
- values: "0;360;360;"
1527
- }
1528
- )
1529
- ]
1530
- }
1531
- ) });
1974
+ transform: "translate(300 300) rotate(0)",
1975
+ height: 176,
1976
+ width: 176,
1977
+ children: [
1978
+ /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("path", {
1979
+ className: "stroke-black dark:stroke-white text-gray-900 dark:text-gray-50",
1980
+ stroke: "currentColor",
1981
+ id: "motionPath",
1982
+ fill: "none",
1983
+ strokeLinecap: "round",
1984
+ height: 600,
1985
+ width: 600,
1986
+ style: {
1987
+ transformOrigin: "center"
1988
+ },
1989
+ strokeMiterlimit: "10",
1990
+ strokeWidth: "82",
1991
+ strokeDasharray: "1600",
1992
+ d: "M466.49 164.79c17.79 34.76 25.48 75.66 19.08 118.96-11.28 76.36-67.11 139.06-141.89 158.25-127.11 32.61-243.49-61.27-245.86-184.81C95.79 150.86 182.9 60.52 289.23 58.56c33.95-.63 66.08 7.48 94.22 22.29 0 0 15.68 6.34 10.14 23.19 0 0-68.52 219.82-352.61 268.06",
1993
+ children: /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("animate", {
1994
+ attributeName: "stroke-dashoffset",
1995
+ to: "0",
1996
+ from: "1600",
1997
+ dur: "4s",
1998
+ fill: "freeze",
1999
+ repeatCount: "indefinite",
2000
+ calcMode: "cubic",
2001
+ keyTimes: "0;0.375;0.5;0.875;1",
2002
+ keySplines: "0 0.26 0 1;0 0.26 0 1;0 0.26 0 1;0 0.26 0 1",
2003
+ values: "1600;0;0;1600;1600"
2004
+ })
2005
+ }),
2006
+ /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("animateTransform", {
2007
+ attributeName: "transform",
2008
+ type: "rotate",
2009
+ from: "0",
2010
+ to: "360",
2011
+ dur: "2s",
2012
+ fill: "freeze",
2013
+ repeatCount: "indefinite",
2014
+ calcMode: "cubic",
2015
+ keyTimes: "0;0.75;1",
2016
+ keySplines: "0 0.26 0 1",
2017
+ values: "0;360;360;"
2018
+ })
2019
+ ]
2020
+ })
2021
+ });
1532
2022
  };
1533
2023
  var AnimateLogo_default = AnimateLogo;
1534
-
1535
2024
  // src/Spinners/OverlaySpinner.tsx
1536
2025
  var import_react11 = require("react");
1537
2026
  var import_react_dom3 = require("react-dom");
1538
- var import_jsx_runtime36 = require("react/jsx-runtime");
1539
- var OverlaySpinner = ({ visible }) => {
1540
- const [mounted, setMounted] = (0, import_react11.useState)(false);
1541
- (0, import_react11.useEffect)(() => setMounted(true), []);
1542
- if (!mounted) return null;
1543
- if (!visible) return null;
1544
- return (0, import_react_dom3.createPortal)(
1545
- /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("div", { className: "animate-fade-in", children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("div", { className: "fixed top-0 left-0 w-full h-screen flex items-center justify-center z-50 dark:bg-black/70 bg-white/60", children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("div", { className: "h-44 w-44 overflow-visible", children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(AnimateLogo_default, {}) }) }) }),
1546
- typeof window !== "undefined" ? document.body : {},
1547
- "spinner"
1548
- );
2027
+ var import_jsx_runtime35 = require("react/jsx-runtime");
2028
+ var OverlaySpinner = function(param) {
2029
+ var visible = param.visible;
2030
+ var _ref = _sliced_to_array((0, import_react11.useState)(false), 2), mounted = _ref[0], setMounted = _ref[1];
2031
+ (0, import_react11.useEffect)(function() {
2032
+ return setMounted(true);
2033
+ }, []);
2034
+ if (!mounted) return null;
2035
+ if (!visible) return null;
2036
+ return (0, import_react_dom3.createPortal)(/* @__PURE__ */ (0, import_jsx_runtime35.jsx)("div", {
2037
+ className: "animate-fade-in",
2038
+ children: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("div", {
2039
+ className: "fixed top-0 left-0 w-full h-screen flex items-center justify-center z-50 dark:bg-black/70 bg-white/60",
2040
+ children: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("div", {
2041
+ className: "h-44 w-44 overflow-visible",
2042
+ children: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(AnimateLogo_default, {})
2043
+ })
2044
+ })
2045
+ }), typeof window !== "undefined" ? document.body : {}, "spinner");
1549
2046
  };
1550
2047
  var OverlaySpinner_default = OverlaySpinner;
1551
2048
  // Annotate the CommonJS export names for ESM import in node:
1552
2049
  0 && (module.exports = {
1553
- AnimateLogo,
1554
- Backdrop,
1555
- BottomAlert,
1556
- Breakpoint,
1557
- Button,
1558
- Checkbox,
1559
- CircleProgress,
1560
- Container,
1561
- CourseProgress,
1562
- ErrorText,
1563
- Fade,
1564
- FunButton,
1565
- FunRoundButton,
1566
- IconInfo,
1567
- Modal,
1568
- NoResults,
1569
- NoticeBox,
1570
- Overlay,
1571
- OverlaySpinner,
1572
- PRIMARY_COLOR,
1573
- Pill,
1574
- ProgressBar,
1575
- ProgressBarSimple,
1576
- RadioOption,
1577
- RatingStars,
1578
- ScrollProgress,
1579
- Slider,
1580
- Spinner,
1581
- StepsComponent,
1582
- Tippy,
1583
- ToggleSwitch,
1584
- UserContentSwitcher,
1585
- baseFieldStyle,
1586
- createExerciseElementStyle,
1587
- exerciseDeleteButton,
1588
- exerciseEditButton,
1589
- headerButtonClass,
1590
- headerTippyClass,
1591
- tippyClassname,
1592
- toolbarExerciseButton,
1593
- xIconButton
2050
+ AnimateLogo: AnimateLogo,
2051
+ Backdrop: Backdrop,
2052
+ BottomAlert: BottomAlert,
2053
+ Breakpoint: Breakpoint,
2054
+ Button: Button,
2055
+ Checkbox: Checkbox,
2056
+ CircleProgress: CircleProgress,
2057
+ CourseProgress: CourseProgress,
2058
+ ErrorText: ErrorText,
2059
+ Fade: Fade,
2060
+ FunButton: FunButton,
2061
+ FunRoundButton: FunRoundButton,
2062
+ IconInfo: IconInfo,
2063
+ Modal: Modal,
2064
+ NoResults: NoResults,
2065
+ NoticeBox: NoticeBox,
2066
+ Overlay: Overlay,
2067
+ OverlaySpinner: OverlaySpinner,
2068
+ PRIMARY_COLOR: PRIMARY_COLOR,
2069
+ Pill: Pill,
2070
+ ProgressBar: ProgressBar,
2071
+ ProgressBarSimple: ProgressBarSimple,
2072
+ RadioOption: RadioOption,
2073
+ RatingStars: RatingStars,
2074
+ ScrollProgress: ScrollProgress,
2075
+ Slider: Slider,
2076
+ Spinner: Spinner,
2077
+ StepsComponent: StepsComponent,
2078
+ Tippy: Tippy,
2079
+ ToggleSwitch: ToggleSwitch,
2080
+ UserContentSwitcher: UserContentSwitcher,
2081
+ baseFieldStyle: baseFieldStyle,
2082
+ createExerciseElementStyle: createExerciseElementStyle,
2083
+ exerciseDeleteButton: exerciseDeleteButton,
2084
+ exerciseEditButton: exerciseEditButton,
2085
+ headerButtonClass: headerButtonClass,
2086
+ headerTippyClass: headerTippyClass,
2087
+ tippyClassname: tippyClassname,
2088
+ toolbarExerciseButton: toolbarExerciseButton,
2089
+ xIconButton: xIconButton
1594
2090
  });