@elevasis/ui 1.14.5 → 1.15.0

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.
@@ -1,5 +1,5 @@
1
- export { ActivityTrendChart, CombinedTrendChart, CostTrendChart, CyberAreaChart, CyberDonut, CyberDonutTooltip, CyberLegendItem, HeroStatsRow, getSeriesColor, useCyberColors } from '../chunk-HGUJ6SSM.js';
2
- import '../chunk-MYRCM7VD.js';
1
+ export { ActivityTrendChart, CombinedTrendChart, CostTrendChart, CyberAreaChart, CyberDonut, CyberDonutTooltip, CyberLegendItem, HeroStatsRow, getSeriesColor, useCyberColors } from '../chunk-PCC3PLDV.js';
2
+ import '../chunk-KBLGVZBD.js';
3
3
  import '../chunk-EQNXEBGZ.js';
4
4
  import '../chunk-LHQTTUL2.js';
5
5
  import '../chunk-ELJIFLCB.js';
@@ -0,0 +1,14 @@
1
+ import { PerspectiveGrid, RadiantGlow, FloatingOrbs, FilmGrain } from './chunk-GIQPDIG5.js';
2
+ import { jsxs, Fragment, jsx } from 'react/jsx-runtime';
3
+
4
+ function AppBackground({ children }) {
5
+ return /* @__PURE__ */ jsxs(Fragment, { children: [
6
+ /* @__PURE__ */ jsx(PerspectiveGrid, {}),
7
+ /* @__PURE__ */ jsx(RadiantGlow, {}),
8
+ /* @__PURE__ */ jsx(FloatingOrbs, {}),
9
+ /* @__PURE__ */ jsx(FilmGrain, {}),
10
+ children
11
+ ] });
12
+ }
13
+
14
+ export { AppBackground };
@@ -4,10 +4,11 @@ import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
4
4
  // src/components/layout/backgrounds/PerspectiveGrid.tsx
5
5
  function PerspectiveGrid({
6
6
  glowColor = "rgba(123, 123, 123, 0.1)",
7
+ lineColor: lineColorProp,
7
8
  className
8
9
  }) {
9
10
  const colorScheme = useComputedColorScheme();
10
- const lineColor = colorScheme === "dark" ? "rgba(90, 90, 90, 0.1)" : "rgba(120, 120, 120, 0.1)";
11
+ const lineColor = lineColorProp ?? (colorScheme === "dark" ? "rgba(90, 90, 90, 0.1)" : "rgba(120, 120, 120, 0.1)");
11
12
  return /* @__PURE__ */ jsxs(
12
13
  "div",
13
14
  {
@@ -270,14 +271,104 @@ function FilmGrain({ darkOpacity = 0.02, lightOpacity = 0.06, className }) {
270
271
  }
271
272
  );
272
273
  }
273
- function AppBackground({ children }) {
274
+ var randRange = (min, max) => min + Math.random() * (max - min);
275
+ var FLUX_SPARKS = Array.from({ length: 42 }, () => {
276
+ const duration = randRange(6, 15);
277
+ const pulse = randRange(0.8, 2.2);
278
+ return {
279
+ left: randRange(0, 100),
280
+ size: randRange(1.5, 4.2),
281
+ duration,
282
+ delay: -randRange(0, duration),
283
+ drift: randRange(-35, 35),
284
+ pulse,
285
+ pulseDelay: -randRange(0, pulse)
286
+ };
287
+ });
288
+ var KEYFRAMES4 = `
289
+ @keyframes elevasis-cyber-spark-rise {
290
+ 0% { transform: translate3d(0, 0, 0); opacity: 0; }
291
+ 10% { opacity: 1; }
292
+ 85% { opacity: 0.9; }
293
+ 100% { transform: translate3d(var(--cy-drift, 0px), -112vh, 0); opacity: 0; }
294
+ }
295
+ @keyframes elevasis-cyber-spark-pulse {
296
+ 0%, 100% { filter: brightness(0.55); transform: scale(0.8); }
297
+ 50% { filter: brightness(1.7); transform: scale(1.25); }
298
+ }
299
+ @media (prefers-reduced-motion: reduce) {
300
+ .elevasis-cyber-spark,
301
+ .elevasis-cyber-spark-inner {
302
+ animation: none !important;
303
+ }
304
+ .elevasis-cyber-spark {
305
+ opacity: 0 !important;
306
+ }
307
+ }
308
+ `;
309
+ function FluxSparks() {
310
+ return /* @__PURE__ */ jsx(Fragment, { children: FLUX_SPARKS.map((s, i) => /* @__PURE__ */ jsx(
311
+ "div",
312
+ {
313
+ className: "elevasis-cyber-spark",
314
+ style: {
315
+ position: "absolute",
316
+ bottom: "-2%",
317
+ left: `${s.left}%`,
318
+ width: `${s.size}px`,
319
+ height: `${s.size}px`,
320
+ animation: `elevasis-cyber-spark-rise ${s.duration}s linear infinite`,
321
+ animationDelay: `${s.delay}s`,
322
+ ["--cy-drift"]: `${s.drift}px`,
323
+ willChange: "transform, opacity"
324
+ },
325
+ children: /* @__PURE__ */ jsx(
326
+ "div",
327
+ {
328
+ className: "elevasis-cyber-spark-inner",
329
+ style: {
330
+ width: "100%",
331
+ height: "100%",
332
+ borderRadius: "50%",
333
+ background: "var(--color-primary)",
334
+ boxShadow: `0 0 ${s.size * 2.5}px var(--color-primary), 0 0 ${s.size * 5}px color-mix(in srgb, var(--color-primary) 50%, transparent)`,
335
+ animation: `elevasis-cyber-spark-pulse ${s.pulse}s ease-in-out infinite`,
336
+ animationDelay: `${s.pulseDelay}s`,
337
+ willChange: "transform, filter"
338
+ }
339
+ }
340
+ )
341
+ },
342
+ i
343
+ )) });
344
+ }
345
+ function CyberParticles({ variant: _variant, className }) {
346
+ return /* @__PURE__ */ jsxs(
347
+ "div",
348
+ {
349
+ className,
350
+ "aria-hidden": "true",
351
+ style: {
352
+ position: "absolute",
353
+ inset: 0,
354
+ pointerEvents: "none",
355
+ overflow: "hidden"
356
+ },
357
+ children: [
358
+ /* @__PURE__ */ jsx("style", { children: KEYFRAMES4 }),
359
+ /* @__PURE__ */ jsx(FluxSparks, {})
360
+ ]
361
+ }
362
+ );
363
+ }
364
+ function CyberBackground({ variant }) {
274
365
  return /* @__PURE__ */ jsxs(Fragment, { children: [
275
- /* @__PURE__ */ jsx(PerspectiveGrid, {}),
366
+ /* @__PURE__ */ jsx(PerspectiveGrid, { lineColor: "var(--color-border)" }),
276
367
  /* @__PURE__ */ jsx(RadiantGlow, {}),
277
368
  /* @__PURE__ */ jsx(FloatingOrbs, {}),
278
- /* @__PURE__ */ jsx(FilmGrain, {}),
279
- children
369
+ /* @__PURE__ */ jsx(CyberParticles, { variant }),
370
+ /* @__PURE__ */ jsx(FilmGrain, {})
280
371
  ] });
281
372
  }
282
373
 
283
- export { AppBackground, FilmGrain, FloatingOrbs, PerspectiveGrid, RadiantGlow };
374
+ export { CyberBackground, CyberParticles, FilmGrain, FloatingOrbs, PerspectiveGrid, RadiantGlow };
@@ -1,6 +1,6 @@
1
1
  import { ElevasisLoader } from './chunk-SZHARWKU.js';
2
- import { PRESETS, getPreset, generateShades, mantineThemeOverride, createCssVariablesResolver, PresetsProvider } from './chunk-6ZNKDPAO.js';
3
- import { AppBackground } from './chunk-TBRTRBJV.js';
2
+ import { PRESETS, getPreset, generateShades, mantineThemeOverride, createCssVariablesResolver, PresetsProvider } from './chunk-KUK3ZK4D.js';
3
+ import { AppBackground } from './chunk-GATPOCUD.js';
4
4
  import { ElevasisCoreProvider } from './chunk-YCOTIVEZ.js';
5
5
  import { AppearanceProvider } from './chunk-QJ2KCHKX.js';
6
6
  import { getErrorInfo, formatErrorMessage, getErrorTitle } from './chunk-FCFLBMVI.js';
@@ -39,11 +39,11 @@ var mantineAdapter = {
39
39
  function ElevasisUIProvider({ theme, children, ...coreProps }) {
40
40
  const resolvedColorScheme = theme?.colorScheme ?? "dark";
41
41
  const activePresets = theme?.presets ?? PRESETS;
42
+ const preset = useMemo(() => getPreset(theme?.preset ?? "default", theme?.presets), [theme?.preset, theme?.presets]);
42
43
  const resolvedAppearance = {
43
- background: theme?.background ?? /* @__PURE__ */ jsx(AppBackground, {}),
44
- loader: theme?.loader ?? /* @__PURE__ */ jsx(Loader, { size: "xl", loaders: { elevasis: ElevasisLoader }, type: "elevasis" })
44
+ background: theme?.background ?? preset.background ?? /* @__PURE__ */ jsx(AppBackground, {}),
45
+ loader: theme?.loader ?? preset.loader ?? /* @__PURE__ */ jsx(Loader, { size: "xl", loaders: { elevasis: ElevasisLoader }, type: "elevasis" })
45
46
  };
46
- const preset = useMemo(() => getPreset(theme?.preset ?? "default", theme?.presets), [theme?.preset, theme?.presets]);
47
47
  useEffect(() => {
48
48
  if (!preset.fontImports?.length) return;
49
49
  const links = [];
@@ -8,6 +8,8 @@ var sidebarCollapsedWidth = 72;
8
8
  var sidebarTransitionDuration = 200;
9
9
  var sidebarHoverDelay = 100;
10
10
  var topbarHeight = 54;
11
+ var sidebarBottomSectionHeight = 71;
12
+ var sidebarBottomSectionCollapsedHeight = 59;
11
13
  var sidebarItemHeight = 42;
12
14
  var sidebarItemPadding = 10;
13
15
  var sidebarItemGap = 4;
@@ -133,4 +135,4 @@ var NavigationButton = ({
133
135
  );
134
136
  };
135
137
 
136
- export { NavigationButton, sidebarCollapsedWidth, sidebarGroupChevronSize, sidebarHoverDelay, sidebarIconInnerSize, sidebarIconSize, sidebarIconStroke, sidebarItemGap, sidebarItemHeight, sidebarItemPadding, sidebarListItemIconSize, sidebarSectionPadding, sidebarSubLinkIndent, sidebarSubLinkPaddingX, sidebarSubLinkPaddingY, sidebarToggleIconSize, sidebarTransitionDuration, sidebarWidth, topbarHeight };
138
+ export { NavigationButton, sidebarBottomSectionCollapsedHeight, sidebarBottomSectionHeight, sidebarCollapsedWidth, sidebarGroupChevronSize, sidebarHoverDelay, sidebarIconInnerSize, sidebarIconSize, sidebarIconStroke, sidebarItemGap, sidebarItemHeight, sidebarItemPadding, sidebarListItemIconSize, sidebarSectionPadding, sidebarSubLinkIndent, sidebarSubLinkPaddingX, sidebarSubLinkPaddingY, sidebarToggleIconSize, sidebarTransitionDuration, sidebarWidth, topbarHeight };