@julseb-lib/react 0.1.33 → 0.1.35

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.cjs CHANGED
@@ -94,7 +94,6 @@ __export(index_exports, {
94
94
  ButtonGroup: () => ButtonGroup,
95
95
  ButtonIcon: () => ButtonIcon,
96
96
  COLORS: () => COLORS,
97
- CodeContainer: () => CodeContainer,
98
97
  Cover: () => Cover,
99
98
  DROP_SHADOWS: () => DROP_SHADOWS,
100
99
  DragList: () => DragList,
@@ -177,27 +176,27 @@ __export(index_exports, {
177
176
  Tooltip: () => Tooltip,
178
177
  URL_REGEX: () => URL_REGEX,
179
178
  Wrapper: () => Wrapper,
180
- addDay: () => import_utils151.addDay,
181
- addMonth: () => import_utils151.addMonth,
182
- addYear: () => import_utils151.addYear,
183
- calculateAverage: () => import_utils151.calculateAverage,
184
- calculateTotalSum: () => import_utils151.calculateTotalSum,
185
- capitalize: () => import_utils151.capitalize,
179
+ addDay: () => import_utils150.addDay,
180
+ addMonth: () => import_utils150.addMonth,
181
+ addYear: () => import_utils150.addYear,
182
+ calculateAverage: () => import_utils150.calculateAverage,
183
+ calculateTotalSum: () => import_utils150.calculateTotalSum,
184
+ capitalize: () => import_utils150.capitalize,
186
185
  clsx: () => clsx,
187
- convertDate: () => import_utils151.convertDate,
188
- convertDateShort: () => import_utils151.convertDateShort,
189
- convertPrice: () => import_utils151.convertPrice,
190
- convertToEmail: () => import_utils151.convertToEmail,
191
- convertYoutube: () => import_utils151.convertYoutube,
192
- deleteDuplicates: () => import_utils151.deleteDuplicates,
186
+ convertDate: () => import_utils150.convertDate,
187
+ convertDateShort: () => import_utils150.convertDateShort,
188
+ convertPrice: () => import_utils150.convertPrice,
189
+ convertToEmail: () => import_utils150.convertToEmail,
190
+ convertYoutube: () => import_utils150.convertYoutube,
191
+ deleteDuplicates: () => import_utils150.deleteDuplicates,
193
192
  designTokens: () => designTokens,
194
- detectLanguage: () => import_utils151.detectLanguage,
195
- disableScroll: () => import_utils151.disableScroll,
196
- emailRegex: () => import_utils151.emailRegex,
197
- enableScroll: () => import_utils151.enableScroll,
198
- filterObject: () => import_utils151.filterObject,
199
- formatDate: () => import_utils151.formatDate,
200
- formatHour: () => import_utils151.formatHour,
193
+ detectLanguage: () => import_utils150.detectLanguage,
194
+ disableScroll: () => import_utils150.disableScroll,
195
+ emailRegex: () => import_utils150.emailRegex,
196
+ enableScroll: () => import_utils150.enableScroll,
197
+ filterObject: () => import_utils150.filterObject,
198
+ formatDate: () => import_utils150.formatDate,
199
+ formatHour: () => import_utils150.formatHour,
201
200
  genAlignContent: () => genAlignContent,
202
201
  genAlignItems: () => genAlignItems,
203
202
  genBgAllColors: () => genBgAllColors,
@@ -232,43 +231,43 @@ __export(index_exports, {
232
231
  genTextColorHover: () => genTextColorHover,
233
232
  genTextColorShort: () => genTextColorShort,
234
233
  genVAlign: () => genVAlign,
235
- generateNumbers: () => import_utils151.generateNumbers,
236
- getFirstName: () => import_utils151.getFirstName,
237
- getInitials: () => import_utils151.getInitials,
238
- getLastName: () => import_utils151.getLastName,
239
- getNextDay: () => import_utils151.getNextDay,
240
- getPercentage: () => import_utils151.getPercentage,
241
- getRandom: () => import_utils151.getRandom,
242
- getRandomAvatar: () => import_utils151.getRandomAvatar,
243
- getRandomDate: () => import_utils151.getRandomDate,
244
- getRandomNumber: () => import_utils151.getRandomNumber,
245
- getRandomString: () => import_utils151.getRandomString,
246
- getRandomTime: () => import_utils151.getRandomTime,
247
- getTimeNow: () => import_utils151.getTimeNow,
248
- getToday: () => import_utils151.getToday,
249
- getTomorrow: () => import_utils151.getTomorrow,
250
- getYesterday: () => import_utils151.getYesterday,
251
- hexToRgb: () => import_utils151.hexToRgb,
234
+ generateNumbers: () => import_utils150.generateNumbers,
235
+ getFirstName: () => import_utils150.getFirstName,
236
+ getInitials: () => import_utils150.getInitials,
237
+ getLastName: () => import_utils150.getLastName,
238
+ getNextDay: () => import_utils150.getNextDay,
239
+ getPercentage: () => import_utils150.getPercentage,
240
+ getRandom: () => import_utils150.getRandom,
241
+ getRandomAvatar: () => import_utils150.getRandomAvatar,
242
+ getRandomDate: () => import_utils150.getRandomDate,
243
+ getRandomNumber: () => import_utils150.getRandomNumber,
244
+ getRandomString: () => import_utils150.getRandomString,
245
+ getRandomTime: () => import_utils150.getRandomTime,
246
+ getTimeNow: () => import_utils150.getTimeNow,
247
+ getToday: () => import_utils150.getToday,
248
+ getTomorrow: () => import_utils150.getTomorrow,
249
+ getYesterday: () => import_utils150.getYesterday,
250
+ hexToRgb: () => import_utils150.hexToRgb,
252
251
  libMarkdownEditorOptions: () => libMarkdownEditorOptions,
253
252
  libOptionsMarkdown: () => libOptionsMarkdown,
254
253
  linkifyText: () => linkifyText,
255
- passwordRegex: () => import_utils151.passwordRegex,
256
- rgbToHex: () => import_utils151.rgbToHex,
257
- scrollToTop: () => import_utils151.scrollToTop,
258
- slugify: () => import_utils151.slugify,
259
- sortByFrequency: () => import_utils151.sortByFrequency,
260
- stringifyPx: () => import_utils151.stringifyPx,
261
- toCamelCase: () => import_utils151.toCamelCase,
262
- toConstantCase: () => import_utils151.toConstantCase,
263
- toDotCase: () => import_utils151.toDotCase,
264
- toKebabCase: () => import_utils151.toKebabCase,
265
- toPascalCase: () => import_utils151.toPascalCase,
266
- toPathCase: () => import_utils151.toPathCase,
267
- toSentenceCase: () => import_utils151.toSentenceCase,
268
- toSnakeCase: () => import_utils151.toSnakeCase,
269
- toTitleCase: () => import_utils151.toTitleCase,
254
+ passwordRegex: () => import_utils150.passwordRegex,
255
+ rgbToHex: () => import_utils150.rgbToHex,
256
+ scrollToTop: () => import_utils150.scrollToTop,
257
+ slugify: () => import_utils150.slugify,
258
+ sortByFrequency: () => import_utils150.sortByFrequency,
259
+ stringifyPx: () => import_utils150.stringifyPx,
260
+ toCamelCase: () => import_utils150.toCamelCase,
261
+ toConstantCase: () => import_utils150.toConstantCase,
262
+ toDotCase: () => import_utils150.toDotCase,
263
+ toKebabCase: () => import_utils150.toKebabCase,
264
+ toPascalCase: () => import_utils150.toPascalCase,
265
+ toPathCase: () => import_utils150.toPathCase,
266
+ toSentenceCase: () => import_utils150.toSentenceCase,
267
+ toSnakeCase: () => import_utils150.toSnakeCase,
268
+ toTitleCase: () => import_utils150.toTitleCase,
270
269
  toast: () => toast,
271
- unslugify: () => import_utils151.unslugify,
270
+ unslugify: () => import_utils150.unslugify,
272
271
  useClickOutside: () => useClickOutside,
273
272
  useCopyToClipboard: () => useCopyToClipboard,
274
273
  useDebounce: () => useDebounce,
@@ -285,7 +284,7 @@ __export(index_exports, {
285
284
  usePagination: () => usePagination,
286
285
  useTouchScreen: () => useTouchScreen,
287
286
  useTranslation: () => useTranslation,
288
- uuid: () => import_utils151.uuid
287
+ uuid: () => import_utils150.uuid
289
288
  });
290
289
  module.exports = __toCommonJS(index_exports);
291
290
 
@@ -2319,7 +2318,7 @@ var genRingColorChildren = {
2319
2318
  };
2320
2319
 
2321
2320
  // src/lib/index.ts
2322
- var import_utils151 = require("@julseb-lib/utils");
2321
+ var import_utils150 = require("@julseb-lib/utils");
2323
2322
 
2324
2323
  // src/lib/hooks/useClickOutside.tsx
2325
2324
  var import_react2 = require("react");
@@ -2843,31 +2842,37 @@ var import_react14 = require("react");
2843
2842
  var import_jsx_runtime18 = require("react/jsx-runtime");
2844
2843
  var ThemeContext = (0, import_react14.createContext)(null);
2845
2844
  var ThemeProviderWrapper = ({ children }) => {
2846
- const storedTheme = localStorage.getItem("theme");
2847
- const [theme, setTheme] = (0, import_react14.useState)(storedTheme != null ? storedTheme : "light");
2845
+ const [theme, setTheme] = (0, import_react14.useState)("light");
2848
2846
  const docEl = document.documentElement;
2849
2847
  const switchToLight = () => {
2850
- docEl.classList.add("light");
2851
- docEl.classList.remove("dark");
2852
- setTheme("light");
2853
- localStorage.setItem("theme", "light");
2848
+ if (typeof window !== "undefined") {
2849
+ docEl.classList.add("light");
2850
+ docEl.classList.remove("dark");
2851
+ setTheme("light");
2852
+ localStorage.setItem("theme", "light");
2853
+ }
2854
2854
  };
2855
2855
  const switchToDark = () => {
2856
- docEl.classList.remove("light");
2857
- docEl.classList.add("dark");
2858
- setTheme("dark");
2859
- localStorage.setItem("theme", "dark");
2856
+ if (typeof window !== "undefined") {
2857
+ docEl.classList.remove("light");
2858
+ docEl.classList.add("dark");
2859
+ setTheme("dark");
2860
+ localStorage.setItem("theme", "dark");
2861
+ }
2860
2862
  };
2861
2863
  (0, import_react14.useEffect)(() => {
2862
- if (storedTheme) {
2863
- if (theme === "light") switchToLight();
2864
- else switchToDark();
2865
- } else {
2866
- if (window.matchMedia("(prefers-color-scheme: dark)").matches)
2867
- switchToDark();
2868
- else switchToLight();
2864
+ if (typeof window !== "undefined") {
2865
+ const storedTheme = localStorage.getItem("theme");
2866
+ if (storedTheme) {
2867
+ if (theme === "light") switchToLight();
2868
+ else switchToDark();
2869
+ } else {
2870
+ if (window.matchMedia("(prefers-color-scheme: dark)").matches)
2871
+ switchToDark();
2872
+ else switchToLight();
2873
+ }
2869
2874
  }
2870
- }, [theme, localStorage.getItem("theme"), docEl]);
2875
+ }, [theme, docEl]);
2871
2876
  const switchTheme = () => {
2872
2877
  if (theme === "light") switchToDark();
2873
2878
  else switchToLight();
@@ -11002,86 +11007,9 @@ var MarkdownContainer = (_a) => {
11002
11007
  );
11003
11008
  };
11004
11009
 
11005
- // src/lib/components/CodeContainer/CodeContainer.tsx
11010
+ // src/lib/components/Fade/Fade.tsx
11006
11011
  var import_react51 = require("react");
11007
- var import_react_syntax_highlighter = __toESM(require("react-syntax-highlighter"), 1);
11008
- var import_atom_one_dark = __toESM(require("react-syntax-highlighter/dist/esm/styles/hljs/atom-one-dark.js"), 1);
11009
- var import_bi25 = require("react-icons/bi");
11010
11012
  var import_jsx_runtime121 = require("react/jsx-runtime");
11011
- var CodeContainer = (_a) => {
11012
- var _b = _a, {
11013
- className,
11014
- element,
11015
- ref,
11016
- children,
11017
- highlighterProps,
11018
- textColor,
11019
- backgroundColor,
11020
- style = import_atom_one_dark.default,
11021
- hideCopyButton,
11022
- tooltipTexts,
11023
- icons
11024
- } = _b, rest = __objRest(_b, [
11025
- "className",
11026
- "element",
11027
- "ref",
11028
- "children",
11029
- "highlighterProps",
11030
- "textColor",
11031
- "backgroundColor",
11032
- "style",
11033
- "hideCopyButton",
11034
- "tooltipTexts",
11035
- "icons"
11036
- ]);
11037
- var _a2, _b2, _c, _d;
11038
- const Element = element != null ? element : textColor || backgroundColor ? "pre" : "div";
11039
- const [hasCopied, setHasCopied] = (0, import_react51.useState)(false);
11040
- const copyToClipboard = () => {
11041
- if (children) {
11042
- let copyString = children.toString();
11043
- if (copyString[0] === "$") {
11044
- copyString = copyString.replace("$ ", "");
11045
- }
11046
- navigator.clipboard.writeText(copyString);
11047
- setHasCopied(true);
11048
- }
11049
- setTimeout(() => setHasCopied(false), 1e3);
11050
- };
11051
- return /* @__PURE__ */ (0, import_jsx_runtime121.jsxs)(
11052
- Element,
11053
- __spreadProps(__spreadValues({
11054
- ref,
11055
- className: clsx(
11056
- "relative outline-none",
11057
- "code-container-wrapper",
11058
- "[&>pre]:bg-gray-800! [&>pre]:p-4!",
11059
- textColor && genTextAllColor[textColor],
11060
- genRingColor["primary"],
11061
- className
11062
- )
11063
- }, rest), {
11064
- children: [
11065
- /* @__PURE__ */ (0, import_jsx_runtime121.jsx)(import_react_syntax_highlighter.default, { style, children }),
11066
- !hideCopyButton && /* @__PURE__ */ (0, import_jsx_runtime121.jsx)(
11067
- ButtonIcon,
11068
- {
11069
- className: clsx("size-8", "copy-button"),
11070
- onClick: copyToClipboard,
11071
- icon: hasCopied ? (_a2 = icons == null ? void 0 : icons.copied) != null ? _a2 : /* @__PURE__ */ (0, import_jsx_runtime121.jsx)(import_bi25.BiCheck, { size: 16 }) : (_b2 = icons == null ? void 0 : icons.copy) != null ? _b2 : /* @__PURE__ */ (0, import_jsx_runtime121.jsx)(import_bi25.BiClipboard, { size: 16 }),
11072
- tooltip: hasCopied ? (_c = tooltipTexts == null ? void 0 : tooltipTexts.copied) != null ? _c : "Copied!" : (_d = tooltipTexts == null ? void 0 : tooltipTexts.copy) != null ? _d : "Copy",
11073
- color: hasCopied ? "success" : "primary",
11074
- showTooltip: { className: "absolute top-4 right-4" }
11075
- }
11076
- )
11077
- ]
11078
- })
11079
- );
11080
- };
11081
-
11082
- // src/lib/components/Fade/Fade.tsx
11083
- var import_react52 = require("react");
11084
- var import_jsx_runtime122 = require("react/jsx-runtime");
11085
11013
  var Fade = (_a) => {
11086
11014
  var _b = _a, {
11087
11015
  className,
@@ -11095,15 +11023,15 @@ var Fade = (_a) => {
11095
11023
  "children"
11096
11024
  ]);
11097
11025
  const Element = element;
11098
- const [isVisible, setIsVisible] = (0, import_react52.useState)(true);
11099
- const fadeRef = (0, import_react52.useRef)(null);
11100
- (0, import_react52.useEffect)(() => {
11026
+ const [isVisible, setIsVisible] = (0, import_react51.useState)(true);
11027
+ const fadeRef = (0, import_react51.useRef)(null);
11028
+ (0, import_react51.useEffect)(() => {
11101
11029
  const observer = new IntersectionObserver((entries) => {
11102
11030
  entries.forEach((entry) => setIsVisible(entry.isIntersecting));
11103
11031
  });
11104
11032
  observer.observe(fadeRef.current);
11105
11033
  }, []);
11106
- return /* @__PURE__ */ (0, import_jsx_runtime122.jsx)(
11034
+ return /* @__PURE__ */ (0, import_jsx_runtime121.jsx)(
11107
11035
  Element,
11108
11036
  __spreadProps(__spreadValues({
11109
11037
  ref: useMergeRefs([ref, fadeRef]),
@@ -11121,15 +11049,15 @@ var Fade = (_a) => {
11121
11049
  };
11122
11050
 
11123
11051
  // src/lib/components/BackToTop/BackToTop.tsx
11124
- var import_react53 = require("react");
11125
- var import_bi26 = require("react-icons/bi");
11126
- var import_utils140 = require("@julseb-lib/utils");
11127
- var import_jsx_runtime123 = require("react/jsx-runtime");
11052
+ var import_react52 = require("react");
11053
+ var import_bi25 = require("react-icons/bi");
11054
+ var import_utils139 = require("@julseb-lib/utils");
11055
+ var import_jsx_runtime122 = require("react/jsx-runtime");
11128
11056
  var BackToTop = (_a) => {
11129
11057
  var _b = _a, {
11130
11058
  className,
11131
11059
  ref,
11132
- icon = /* @__PURE__ */ (0, import_jsx_runtime123.jsx)(import_bi26.BiUpArrowAlt, {}),
11060
+ icon = /* @__PURE__ */ (0, import_jsx_runtime122.jsx)(import_bi25.BiUpArrowAlt, {}),
11133
11061
  color = "primary",
11134
11062
  tooltip = "Back to top",
11135
11063
  showTooltip
@@ -11141,8 +11069,8 @@ var BackToTop = (_a) => {
11141
11069
  "tooltip",
11142
11070
  "showTooltip"
11143
11071
  ]);
11144
- const [isVisible, setIsVisible] = (0, import_react53.useState)(false);
11145
- (0, import_react53.useEffect)(() => {
11072
+ const [isVisible, setIsVisible] = (0, import_react52.useState)(false);
11073
+ (0, import_react52.useEffect)(() => {
11146
11074
  const scrollFn = () => {
11147
11075
  if (window.scrollY >= 200) {
11148
11076
  setIsVisible(true);
@@ -11156,13 +11084,13 @@ var BackToTop = (_a) => {
11156
11084
  const smoothScroll = () => {
11157
11085
  document.body.classList.add("smooth");
11158
11086
  document.documentElement.classList.add("smooth");
11159
- setTimeout(() => (0, import_utils140.scrollToTop)(), 100);
11087
+ setTimeout(() => (0, import_utils139.scrollToTop)(), 100);
11160
11088
  setTimeout(() => {
11161
11089
  document.body.classList.remove("smooth");
11162
11090
  document.documentElement.classList.remove("smooth");
11163
11091
  }, 1e3);
11164
11092
  };
11165
- return /* @__PURE__ */ (0, import_jsx_runtime123.jsx)(
11093
+ return /* @__PURE__ */ (0, import_jsx_runtime122.jsx)(
11166
11094
  ButtonIcon,
11167
11095
  __spreadValues({
11168
11096
  ref,
@@ -11188,10 +11116,10 @@ var BackToTop = (_a) => {
11188
11116
  };
11189
11117
 
11190
11118
  // src/lib/components/Drawer/Drawer.tsx
11191
- var import_react54 = require("react");
11192
- var import_bi27 = require("react-icons/bi");
11193
- var import_utils142 = require("@julseb-lib/utils");
11194
- var import_jsx_runtime124 = require("react/jsx-runtime");
11119
+ var import_react53 = require("react");
11120
+ var import_bi26 = require("react-icons/bi");
11121
+ var import_utils141 = require("@julseb-lib/utils");
11122
+ var import_jsx_runtime123 = require("react/jsx-runtime");
11195
11123
  var Drawer = (_a) => {
11196
11124
  var _b = _a, {
11197
11125
  className,
@@ -11229,16 +11157,16 @@ var Drawer = (_a) => {
11229
11157
  "hideCloseButton"
11230
11158
  ]);
11231
11159
  const Element = element;
11232
- const el = (0, import_react54.useRef)(null);
11160
+ const el = (0, import_react53.useRef)(null);
11233
11161
  useClickOutside(el, () => isOpen && setIsOpen(false));
11234
11162
  useKeyPress("Escape", () => {
11235
11163
  if (!disableEsc && isOpen) setIsOpen(false);
11236
11164
  });
11237
- (0, import_react54.useEffect)(() => {
11238
- if (!enableScrollingOpen && isOpen) (0, import_utils142.disableScroll)();
11239
- else (0, import_utils142.enableScroll)();
11165
+ (0, import_react53.useEffect)(() => {
11166
+ if (!enableScrollingOpen && isOpen) (0, import_utils141.disableScroll)();
11167
+ else (0, import_utils141.enableScroll)();
11240
11168
  }, [enableScrollingOpen, isOpen]);
11241
- return /* @__PURE__ */ (0, import_jsx_runtime124.jsxs)(
11169
+ return /* @__PURE__ */ (0, import_jsx_runtime123.jsxs)(
11242
11170
  Element,
11243
11171
  __spreadProps(__spreadValues({
11244
11172
  ref,
@@ -11251,7 +11179,7 @@ var Drawer = (_a) => {
11251
11179
  )
11252
11180
  }, rest), {
11253
11181
  children: [
11254
- /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(
11182
+ /* @__PURE__ */ (0, import_jsx_runtime123.jsx)(
11255
11183
  "div",
11256
11184
  {
11257
11185
  className: clsx(
@@ -11264,7 +11192,7 @@ var Drawer = (_a) => {
11264
11192
  onClick: () => setIsOpen(false)
11265
11193
  }
11266
11194
  ),
11267
- /* @__PURE__ */ (0, import_jsx_runtime124.jsxs)(
11195
+ /* @__PURE__ */ (0, import_jsx_runtime123.jsxs)(
11268
11196
  "div",
11269
11197
  {
11270
11198
  className: clsx(
@@ -11278,14 +11206,14 @@ var Drawer = (_a) => {
11278
11206
  position === "left" ? "left-[calc(var(--drawer-max-width)*-1)] [&.open]:left-0" : "right-[calc(var(--drawer-max-width)*-1)] [&.open]:right-0",
11279
11207
  "drawer-content"
11280
11208
  ),
11281
- style: { ["--drawer-max-width"]: (0, import_utils142.stringifyPx)(maxWidth2) },
11209
+ style: { ["--drawer-max-width"]: (0, import_utils141.stringifyPx)(maxWidth2) },
11282
11210
  ref: el,
11283
11211
  children: [
11284
11212
  children,
11285
- !hideCloseButton && /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(
11213
+ !hideCloseButton && /* @__PURE__ */ (0, import_jsx_runtime123.jsx)(
11286
11214
  ButtonIcon,
11287
11215
  {
11288
- icon: /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(import_bi27.BiX, { size: 24 }),
11216
+ icon: /* @__PURE__ */ (0, import_jsx_runtime123.jsx)(import_bi26.BiX, { size: 24 }),
11289
11217
  color: "white",
11290
11218
  variant: "transparent",
11291
11219
  className: "top-2 right-2 absolute size-12",
@@ -11301,12 +11229,12 @@ var Drawer = (_a) => {
11301
11229
  };
11302
11230
 
11303
11231
  // src/lib/components/Header/Header.tsx
11304
- var import_react55 = require("react");
11305
- var import_utils146 = require("@julseb-lib/utils");
11232
+ var import_react54 = require("react");
11233
+ var import_utils145 = require("@julseb-lib/utils");
11306
11234
 
11307
11235
  // src/lib/components/Header/HeaderSearch.tsx
11308
- var import_utils144 = require("@julseb-lib/utils");
11309
- var import_jsx_runtime125 = require("react/jsx-runtime");
11236
+ var import_utils143 = require("@julseb-lib/utils");
11237
+ var import_jsx_runtime124 = require("react/jsx-runtime");
11310
11238
  var HeaderSearch = ({ search, handleClose }) => {
11311
11239
  if (!search) return null;
11312
11240
  const {
@@ -11323,7 +11251,7 @@ var HeaderSearch = ({ search, handleClose }) => {
11323
11251
  maxWidth: maxWidth2 = 400,
11324
11252
  clearSearch
11325
11253
  } = search;
11326
- return /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(
11254
+ return /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(
11327
11255
  "form",
11328
11256
  {
11329
11257
  onSubmit: (e) => {
@@ -11331,8 +11259,8 @@ var HeaderSearch = ({ search, handleClose }) => {
11331
11259
  handleClose();
11332
11260
  },
11333
11261
  className: clsx("w-full max-w-(--form-max-width)", "search-form"),
11334
- style: { ["--form-max-width"]: (0, import_utils144.stringifyPx)(maxWidth2) },
11335
- children: /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(
11262
+ style: { ["--form-max-width"]: (0, import_utils143.stringifyPx)(maxWidth2) },
11263
+ children: /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(
11336
11264
  Input,
11337
11265
  {
11338
11266
  type: "search",
@@ -11354,7 +11282,7 @@ var HeaderSearch = ({ search, handleClose }) => {
11354
11282
  };
11355
11283
 
11356
11284
  // src/lib/components/Header/Header.tsx
11357
- var import_jsx_runtime126 = require("react/jsx-runtime");
11285
+ var import_jsx_runtime125 = require("react/jsx-runtime");
11358
11286
  var Header = (_a) => {
11359
11287
  var _b = _a, {
11360
11288
  className,
@@ -11397,18 +11325,18 @@ var Header = (_a) => {
11397
11325
  ]);
11398
11326
  const Element = element;
11399
11327
  const isMobile = useMaxWidth(16 * 48);
11400
- const el = (0, import_react55.useRef)(null);
11401
- const [isOpen, setIsOpen] = (0, import_react55.useState)(false);
11402
- const [isHidden, setIsHidden] = (0, import_react55.useState)(false);
11328
+ const el = (0, import_react54.useRef)(null);
11329
+ const [isOpen, setIsOpen] = (0, import_react54.useState)(false);
11330
+ const [isHidden, setIsHidden] = (0, import_react54.useState)(false);
11403
11331
  const handleOpen = () => {
11404
- if (!enableScrollingOpen) (0, import_utils146.disableScroll)();
11332
+ if (!enableScrollingOpen) (0, import_utils145.disableScroll)();
11405
11333
  setIsOpen(true);
11406
11334
  };
11407
11335
  const handleClose = () => {
11408
- if (!enableScrollingOpen) (0, import_utils146.enableScroll)();
11336
+ if (!enableScrollingOpen) (0, import_utils145.enableScroll)();
11409
11337
  setTimeout(() => setIsOpen(false), 10);
11410
11338
  };
11411
- (0, import_react55.useEffect)(() => {
11339
+ (0, import_react54.useEffect)(() => {
11412
11340
  const handleHideScroll = () => {
11413
11341
  const hidePosition = typeof hideOnScroll === "number" ? hideOnScroll : 400;
11414
11342
  if (window.pageYOffset >= hidePosition) {
@@ -11433,9 +11361,9 @@ var Header = (_a) => {
11433
11361
  };
11434
11362
  const searchProps = { search, handleClose };
11435
11363
  const navProps = {
11436
- children: /* @__PURE__ */ (0, import_jsx_runtime126.jsxs)(import_jsx_runtime126.Fragment, { children: [
11364
+ children: /* @__PURE__ */ (0, import_jsx_runtime125.jsxs)(import_jsx_runtime125.Fragment, { children: [
11437
11365
  links ? links.map((link) => link) : nav ? nav : children,
11438
- isMobile && /* @__PURE__ */ (0, import_jsx_runtime126.jsx)(HeaderSearch, __spreadValues({}, searchProps))
11366
+ isMobile && /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(HeaderSearch, __spreadValues({}, searchProps))
11439
11367
  ] }),
11440
11368
  className: clsx(
11441
11369
  "z-999 flex gap-2 [&>a]:outline-none transition-all duration-200 ease-in-out",
@@ -11464,7 +11392,7 @@ var Header = (_a) => {
11464
11392
  useClickOutside(el, () => {
11465
11393
  if (isOpen) handleClose();
11466
11394
  });
11467
- return /* @__PURE__ */ (0, import_jsx_runtime126.jsxs)(
11395
+ return /* @__PURE__ */ (0, import_jsx_runtime125.jsxs)(
11468
11396
  Element,
11469
11397
  __spreadProps(__spreadValues({
11470
11398
  ref,
@@ -11482,8 +11410,8 @@ var Header = (_a) => {
11482
11410
  )
11483
11411
  }, rest), {
11484
11412
  children: [
11485
- burgerPosition === "left" && /* @__PURE__ */ (0, import_jsx_runtime126.jsx)(Burger, __spreadValues({}, burgerProps)),
11486
- /* @__PURE__ */ (0, import_jsx_runtime126.jsx)(
11413
+ burgerPosition === "left" && /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(Burger, __spreadValues({}, burgerProps)),
11414
+ /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(
11487
11415
  "span",
11488
11416
  {
11489
11417
  className: clsx(
@@ -11493,10 +11421,10 @@ var Header = (_a) => {
11493
11421
  children: logo
11494
11422
  }
11495
11423
  ),
11496
- navDesktopPosition === "left" && /* @__PURE__ */ (0, import_jsx_runtime126.jsx)("nav", __spreadValues({}, navProps)),
11497
- !isMobile && navDesktopPosition === "right" && /* @__PURE__ */ (0, import_jsx_runtime126.jsx)(HeaderSearch, __spreadValues({}, searchProps)),
11498
- burgerPosition === "right" && /* @__PURE__ */ (0, import_jsx_runtime126.jsx)(Burger, __spreadValues({}, burgerProps)),
11499
- isMobile && navMobileVariant === "drawer" && /* @__PURE__ */ (0, import_jsx_runtime126.jsx)(
11424
+ navDesktopPosition === "left" && /* @__PURE__ */ (0, import_jsx_runtime125.jsx)("nav", __spreadValues({}, navProps)),
11425
+ !isMobile && navDesktopPosition === "right" && /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(HeaderSearch, __spreadValues({}, searchProps)),
11426
+ burgerPosition === "right" && /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(Burger, __spreadValues({}, burgerProps)),
11427
+ isMobile && navMobileVariant === "drawer" && /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(
11500
11428
  "div",
11501
11429
  {
11502
11430
  className: clsx(
@@ -11508,17 +11436,17 @@ var Header = (_a) => {
11508
11436
  onClick: handleClose
11509
11437
  }
11510
11438
  ),
11511
- navDesktopPosition === "right" && /* @__PURE__ */ (0, import_jsx_runtime126.jsx)("nav", __spreadValues({}, navProps)),
11512
- !isMobile && navDesktopPosition === "left" && /* @__PURE__ */ (0, import_jsx_runtime126.jsx)(HeaderSearch, __spreadValues({}, searchProps))
11439
+ navDesktopPosition === "right" && /* @__PURE__ */ (0, import_jsx_runtime125.jsx)("nav", __spreadValues({}, navProps)),
11440
+ !isMobile && navDesktopPosition === "left" && /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(HeaderSearch, __spreadValues({}, searchProps))
11513
11441
  ]
11514
11442
  })
11515
11443
  );
11516
11444
  };
11517
11445
 
11518
11446
  // src/lib/components/Footer/Footer.tsx
11519
- var import_react56 = require("react");
11520
- var import_utils148 = require("@julseb-lib/utils");
11521
- var import_jsx_runtime127 = require("react/jsx-runtime");
11447
+ var import_react55 = require("react");
11448
+ var import_utils147 = require("@julseb-lib/utils");
11449
+ var import_jsx_runtime126 = require("react/jsx-runtime");
11522
11450
  var Footer = (_a) => {
11523
11451
  var _b = _a, {
11524
11452
  className,
@@ -11547,8 +11475,8 @@ var Footer = (_a) => {
11547
11475
  ]);
11548
11476
  var _a2;
11549
11477
  const Element = element;
11550
- const childrenArray = import_react56.Children.toArray(children);
11551
- return /* @__PURE__ */ (0, import_jsx_runtime127.jsxs)(
11478
+ const childrenArray = import_react55.Children.toArray(children);
11479
+ return /* @__PURE__ */ (0, import_jsx_runtime126.jsxs)(
11552
11480
  Element,
11553
11481
  __spreadProps(__spreadValues({
11554
11482
  ref,
@@ -11562,9 +11490,9 @@ var Footer = (_a) => {
11562
11490
  }, rest), {
11563
11491
  children: [
11564
11492
  logo,
11565
- /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("div", { className: "flex items-container gap-2", children: (_a2 = items == null ? void 0 : items.map((item, i) => /* @__PURE__ */ (0, import_jsx_runtime127.jsxs)(import_react56.Fragment, { children: [
11493
+ /* @__PURE__ */ (0, import_jsx_runtime126.jsx)("div", { className: "flex items-container gap-2", children: (_a2 = items == null ? void 0 : items.map((item, i) => /* @__PURE__ */ (0, import_jsx_runtime126.jsxs)(import_react55.Fragment, { children: [
11566
11494
  item,
11567
- i !== items.length - 1 && !hideLinksSeparator && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)(
11495
+ i !== items.length - 1 && !hideLinksSeparator && /* @__PURE__ */ (0, import_jsx_runtime126.jsx)(
11568
11496
  "span",
11569
11497
  {
11570
11498
  className: clsx(
@@ -11573,17 +11501,17 @@ var Footer = (_a) => {
11573
11501
  children: linksSeparator === "dot" ? "\u2022" : "-"
11574
11502
  }
11575
11503
  )
11576
- ] }, (0, import_utils148.uuid)()))) != null ? _a2 : childrenArray.map((child, i) => /* @__PURE__ */ (0, import_jsx_runtime127.jsxs)(import_react56.Fragment, { children: [
11504
+ ] }, (0, import_utils147.uuid)()))) != null ? _a2 : childrenArray.map((child, i) => /* @__PURE__ */ (0, import_jsx_runtime126.jsxs)(import_react55.Fragment, { children: [
11577
11505
  child,
11578
11506
  i !== childrenArray.length - 1 && !hideLinksSeparator && (linksSeparator === "dot" ? "\u2022" : "-")
11579
- ] }, (0, import_utils148.uuid)())) })
11507
+ ] }, (0, import_utils147.uuid)())) })
11580
11508
  ]
11581
11509
  })
11582
11510
  );
11583
11511
  };
11584
11512
 
11585
11513
  // src/lib/components/Meta/Meta.tsx
11586
- var import_jsx_runtime128 = require("react/jsx-runtime");
11514
+ var import_jsx_runtime127 = require("react/jsx-runtime");
11587
11515
  var Meta = ({
11588
11516
  children,
11589
11517
  title,
@@ -11605,59 +11533,59 @@ var Meta = ({
11605
11533
  category,
11606
11534
  twitterCard = "summary"
11607
11535
  }) => {
11608
- return /* @__PURE__ */ (0, import_jsx_runtime128.jsxs)(import_jsx_runtime128.Fragment, { children: [
11609
- /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("meta", { charSet: "utf-8" }),
11610
- /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(
11536
+ return /* @__PURE__ */ (0, import_jsx_runtime127.jsxs)(import_jsx_runtime127.Fragment, { children: [
11537
+ /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("meta", { charSet: "utf-8" }),
11538
+ /* @__PURE__ */ (0, import_jsx_runtime127.jsx)(
11611
11539
  "meta",
11612
11540
  {
11613
11541
  name: "viewport",
11614
11542
  content: "width=device-width, initial-scale=1"
11615
11543
  }
11616
11544
  ),
11617
- title && /* @__PURE__ */ (0, import_jsx_runtime128.jsxs)(import_jsx_runtime128.Fragment, { children: [
11618
- /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("title", { children: title }),
11619
- /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("meta", { property: "og:title", content: title }),
11620
- /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("meta", { name: "twitter:title", content: title })
11545
+ title && /* @__PURE__ */ (0, import_jsx_runtime127.jsxs)(import_jsx_runtime127.Fragment, { children: [
11546
+ /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("title", { children: title }),
11547
+ /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("meta", { property: "og:title", content: title }),
11548
+ /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("meta", { name: "twitter:title", content: title })
11621
11549
  ] }),
11622
- description && /* @__PURE__ */ (0, import_jsx_runtime128.jsxs)(import_jsx_runtime128.Fragment, { children: [
11623
- /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("meta", { name: "description", content: description }),
11624
- /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("meta", { property: "og:description", content: description }),
11625
- /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("meta", { name: "twitter:description", content: description })
11550
+ description && /* @__PURE__ */ (0, import_jsx_runtime127.jsxs)(import_jsx_runtime127.Fragment, { children: [
11551
+ /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("meta", { name: "description", content: description }),
11552
+ /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("meta", { property: "og:description", content: description }),
11553
+ /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("meta", { name: "twitter:description", content: description })
11626
11554
  ] }),
11627
- siteName && /* @__PURE__ */ (0, import_jsx_runtime128.jsxs)(import_jsx_runtime128.Fragment, { children: [
11628
- /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("meta", { name: "application-name", content: siteName }),
11629
- /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("meta", { property: "og:site_name", content: siteName })
11555
+ siteName && /* @__PURE__ */ (0, import_jsx_runtime127.jsxs)(import_jsx_runtime127.Fragment, { children: [
11556
+ /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("meta", { name: "application-name", content: siteName }),
11557
+ /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("meta", { property: "og:site_name", content: siteName })
11630
11558
  ] }),
11631
- author && /* @__PURE__ */ (0, import_jsx_runtime128.jsxs)(import_jsx_runtime128.Fragment, { children: [
11632
- /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("meta", { name: "author", content: author }),
11633
- /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("meta", { name: "twitter:creator", content: author })
11559
+ author && /* @__PURE__ */ (0, import_jsx_runtime127.jsxs)(import_jsx_runtime127.Fragment, { children: [
11560
+ /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("meta", { name: "author", content: author }),
11561
+ /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("meta", { name: "twitter:creator", content: author })
11634
11562
  ] }),
11635
- url && /* @__PURE__ */ (0, import_jsx_runtime128.jsxs)(import_jsx_runtime128.Fragment, { children: [
11636
- /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("meta", { property: "og:url", content: url }),
11637
- /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("meta", { name: "twitter:site", content: url })
11563
+ url && /* @__PURE__ */ (0, import_jsx_runtime127.jsxs)(import_jsx_runtime127.Fragment, { children: [
11564
+ /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("meta", { property: "og:url", content: url }),
11565
+ /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("meta", { name: "twitter:site", content: url })
11638
11566
  ] }),
11639
- cover && /* @__PURE__ */ (0, import_jsx_runtime128.jsxs)(import_jsx_runtime128.Fragment, { children: [
11640
- /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("meta", { property: "og:image", content: cover }),
11641
- /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("meta", { name: "twitter:image", content: cover })
11567
+ cover && /* @__PURE__ */ (0, import_jsx_runtime127.jsxs)(import_jsx_runtime127.Fragment, { children: [
11568
+ /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("meta", { property: "og:image", content: cover }),
11569
+ /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("meta", { name: "twitter:image", content: cover })
11642
11570
  ] }),
11643
- authorUrl && /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("link", { rel: "author", href: authorUrl }),
11644
- manifest && /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("link", { rel: "manifest", href: manifest }),
11645
- generator && /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("meta", { name: "generator", content: generator }),
11646
- keywords && /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("meta", { name: "keywords", content: keywords == null ? void 0 : keywords.join(",") }),
11647
- creator && /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("meta", { name: "creator", content: creator }),
11648
- publisher && /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("meta", { name: "publisher", content: publisher }),
11649
- category && /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("meta", { name: "category", content: category }),
11650
- language && /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("meta", { property: "og:locale", content: language }),
11651
- email && /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("meta", { property: "og:email", content: email }),
11652
- type && /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("meta", { property: "og:type", content: type }),
11653
- twitterCard && /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("meta", { name: "twitter:card", content: twitterCard }),
11654
- favicon && /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("link", { rel: "icon", href: favicon }),
11571
+ authorUrl && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("link", { rel: "author", href: authorUrl }),
11572
+ manifest && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("link", { rel: "manifest", href: manifest }),
11573
+ generator && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("meta", { name: "generator", content: generator }),
11574
+ keywords && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("meta", { name: "keywords", content: keywords == null ? void 0 : keywords.join(",") }),
11575
+ creator && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("meta", { name: "creator", content: creator }),
11576
+ publisher && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("meta", { name: "publisher", content: publisher }),
11577
+ category && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("meta", { name: "category", content: category }),
11578
+ language && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("meta", { property: "og:locale", content: language }),
11579
+ email && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("meta", { property: "og:email", content: email }),
11580
+ type && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("meta", { property: "og:type", content: type }),
11581
+ twitterCard && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("meta", { name: "twitter:card", content: twitterCard }),
11582
+ favicon && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("link", { rel: "icon", href: favicon }),
11655
11583
  children
11656
11584
  ] });
11657
11585
  };
11658
11586
 
11659
11587
  // src/lib/components/PageLayout/PageLayout.tsx
11660
- var import_jsx_runtime129 = require("react/jsx-runtime");
11588
+ var import_jsx_runtime128 = require("react/jsx-runtime");
11661
11589
  var PageLayout = ({
11662
11590
  children,
11663
11591
  meta,
@@ -11668,19 +11596,19 @@ var PageLayout = ({
11668
11596
  noWrapper,
11669
11597
  noMain
11670
11598
  }) => {
11671
- return /* @__PURE__ */ (0, import_jsx_runtime129.jsxs)(import_jsx_runtime129.Fragment, { children: [
11672
- meta && /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(Meta, __spreadValues({}, meta)),
11673
- header && /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(Header, __spreadValues({}, header)),
11674
- !noWrapper && /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(Wrapper, __spreadProps(__spreadValues({}, wrapperProps), { children: !noMain ? /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(Main, __spreadProps(__spreadValues({}, mainProps), { children })) : children })),
11675
- footer && /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(Footer, __spreadValues({}, footer))
11599
+ return /* @__PURE__ */ (0, import_jsx_runtime128.jsxs)(import_jsx_runtime128.Fragment, { children: [
11600
+ meta && /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(Meta, __spreadValues({}, meta)),
11601
+ header && /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(Header, __spreadValues({}, header)),
11602
+ !noWrapper && /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(Wrapper, __spreadProps(__spreadValues({}, wrapperProps), { children: !noMain ? /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(Main, __spreadProps(__spreadValues({}, mainProps), { children })) : children })),
11603
+ footer && /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(Footer, __spreadValues({}, footer))
11676
11604
  ] });
11677
11605
  };
11678
11606
 
11679
11607
  // src/lib/components/SrOnly/SrOnly.tsx
11680
- var import_jsx_runtime130 = require("react/jsx-runtime");
11608
+ var import_jsx_runtime129 = require("react/jsx-runtime");
11681
11609
  var SrOnly = ({ element = "div", ref, children }) => {
11682
11610
  const Element = element;
11683
- return /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(Element, { ref, className: clsx("sr-only"), children });
11611
+ return /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(Element, { ref, className: clsx("sr-only"), children });
11684
11612
  };
11685
11613
  // Annotate the CommonJS export names for ESM import in node:
11686
11614
  0 && (module.exports = {
@@ -11698,7 +11626,6 @@ var SrOnly = ({ element = "div", ref, children }) => {
11698
11626
  ButtonGroup,
11699
11627
  ButtonIcon,
11700
11628
  COLORS,
11701
- CodeContainer,
11702
11629
  Cover,
11703
11630
  DROP_SHADOWS,
11704
11631
  DragList,