@underverse-ui/underverse 1.0.84 → 1.0.85

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,6 +1,6 @@
1
1
  {
2
2
  "package": "@underverse-ui/underverse",
3
- "version": "1.0.84",
3
+ "version": "1.0.85",
4
4
  "sourceEntry": "src/index.ts",
5
5
  "totalExports": 225,
6
6
  "exports": [
package/dist/index.cjs CHANGED
@@ -5493,9 +5493,10 @@ var ToastComponent = ({ toast, onRemove }) => {
5493
5493
  "div",
5494
5494
  {
5495
5495
  className: cn(
5496
- "relative w-80 rounded-xl border backdrop-blur-md transition-all duration-300 pointer-events-auto overflow-hidden",
5496
+ "relative w-80 rounded-xl border backdrop-blur-md transition-all duration-300 pointer-events-auto",
5497
5497
  "bg-card shadow-xl",
5498
5498
  "animate-in slide-in-from-right-full",
5499
+ toast.overflowHidden !== false && "overflow-hidden",
5499
5500
  config.containerClassName,
5500
5501
  isVisible ? "opacity-100 translate-x-0" : "opacity-0 translate-x-full"
5501
5502
  ),
@@ -6341,7 +6342,18 @@ var variantConfig = {
6341
6342
  accentBarClassName: "bg-destructive"
6342
6343
  }
6343
6344
  };
6344
- var Alert = ({ title, description, variant = "default", className, icon, dismissible = false, onClose, actions, closeAriaLabel }) => {
6345
+ var Alert = ({
6346
+ title,
6347
+ description,
6348
+ variant = "default",
6349
+ className,
6350
+ icon,
6351
+ dismissible = false,
6352
+ onClose,
6353
+ actions,
6354
+ closeAriaLabel,
6355
+ overflowHidden = true
6356
+ }) => {
6345
6357
  const [open, setOpen] = (0, import_react12.useState)(true);
6346
6358
  const t = useSmartTranslations("Common");
6347
6359
  if (!open) return null;
@@ -6355,9 +6367,10 @@ var Alert = ({ title, description, variant = "default", className, icon, dismiss
6355
6367
  "div",
6356
6368
  {
6357
6369
  className: cn(
6358
- "relative w-full rounded-r-xl border border-l-0 overflow-hidden",
6370
+ "relative w-full rounded-r-xl border border-l-0",
6359
6371
  "flex items-start gap-3 p-4 pl-5",
6360
6372
  "backdrop-blur-md",
6373
+ overflowHidden && "overflow-hidden",
6361
6374
  config.containerClassName,
6362
6375
  className
6363
6376
  ),
@@ -13737,6 +13750,7 @@ function CalendarTimeline({
13737
13750
  dayEventMaxWidth,
13738
13751
  monthEventStyle = "span",
13739
13752
  monthEventMaxWidth,
13753
+ overflowHidden = true,
13740
13754
  dayTimeStepMinutes = 60,
13741
13755
  enableEventTooltips = true,
13742
13756
  dayHeaderMode = "full",
@@ -14799,9 +14813,10 @@ function CalendarTimeline({
14799
14813
  "div",
14800
14814
  {
14801
14815
  className: cn(
14802
- "rounded-2xl md:rounded-3xl overflow-hidden bg-card text-card-foreground backdrop-blur-sm",
14816
+ "rounded-2xl md:rounded-3xl bg-card text-card-foreground backdrop-blur-sm",
14803
14817
  "border border-border/50 shadow-sm md:hover:shadow-md",
14804
14818
  "transition-[transform,box-shadow,border-color,background-color] duration-300 ease-soft",
14819
+ overflowHidden && "overflow-hidden",
14805
14820
  densityClass,
14806
14821
  className
14807
14822
  ),
@@ -20349,7 +20364,8 @@ var MusicPlayer = ({
20349
20364
  playlist = DEFAULT_PLAYLIST,
20350
20365
  autoPlay = false,
20351
20366
  showPlaylist: initialShowPlaylist = true,
20352
- className = ""
20367
+ className = "",
20368
+ overflowHidden = true
20353
20369
  }) => {
20354
20370
  const [currentSongIndex, setCurrentSongIndex] = (0, import_react26.useState)(0);
20355
20371
  const [isPlaying, setIsPlaying] = (0, import_react26.useState)(false);
@@ -20451,108 +20467,116 @@ var MusicPlayer = ({
20451
20467
  }
20452
20468
  }
20453
20469
  }, [currentSongIndex, currentSong.startTime, isPlaying]);
20454
- return /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: `underverse-music-player bg-card dark:bg-card border border-border/50 rounded-2xl shadow-2xl overflow-hidden ${className}`, children: [
20455
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("audio", { ref: audioRef, src: currentSong.audioUrl, onTimeUpdate: handleTimeUpdate, onLoadedMetadata: handleLoadedMetadata, onEnded: playNext }),
20456
- /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "p-6", children: [
20457
- /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "text-center mb-6", children: [
20458
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { className: "w-48 h-48 mx-auto mb-4 bg-primary/10 dark:bg-primary/20 border border-primary/30 rounded-2xl shadow-lg flex items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { className: "text-6xl", children: "\u{1F3B5}" }) }),
20459
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("h2", { className: "text-2xl font-bold text-foreground mb-1", children: currentSong.title }),
20460
- currentSong.artist && /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("p", { className: "text-muted-foreground", children: currentSong.artist })
20461
- ] }),
20462
- /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "mb-4", children: [
20463
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
20464
- "input",
20465
- {
20466
- type: "range",
20467
- min: "0",
20468
- max: duration || 0,
20469
- value: currentTime,
20470
- onChange: handleSeek,
20471
- className: "w-full h-2 bg-muted rounded-lg appearance-none cursor-pointer slider"
20472
- }
20473
- ),
20474
- /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "flex justify-between text-sm text-muted-foreground mt-1", children: [
20475
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("span", { children: formatTime3(currentTime) }),
20476
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("span", { children: formatTime3(duration) })
20477
- ] })
20478
- ] }),
20479
- /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "flex items-center justify-center gap-4 mb-6", children: [
20480
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
20481
- "button",
20482
- {
20483
- onClick: playPrevious,
20484
- className: "w-12 h-12 flex items-center justify-center rounded-full bg-secondary hover:bg-secondary/80 transition-colors text-secondary-foreground",
20485
- children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_lucide_react33.SkipBack, { size: 24 })
20486
- }
20487
- ),
20488
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
20489
- "button",
20490
- {
20491
- onClick: togglePlay,
20492
- className: "w-16 h-16 flex items-center justify-center rounded-full bg-primary hover:bg-primary/90 transition-colors text-primary-foreground shadow-lg",
20493
- children: isPlaying ? /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_lucide_react33.Pause, { size: 32 }) : /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_lucide_react33.Play, { size: 32, className: "ml-1" })
20494
- }
20495
- ),
20496
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
20497
- "button",
20498
- {
20499
- onClick: playNext,
20500
- className: "w-12 h-12 flex items-center justify-center rounded-full bg-secondary hover:bg-secondary/80 transition-colors text-secondary-foreground",
20501
- children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_lucide_react33.SkipForward, { size: 24 })
20502
- }
20503
- )
20504
- ] }),
20505
- /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "flex items-center gap-3 mb-4", children: [
20506
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("button", { onClick: toggleMute, className: "text-foreground hover:text-primary transition-colors", children: isMuted || volume === 0 ? /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_lucide_react33.VolumeX, { size: 20 }) : /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_lucide_react33.Volume2, { size: 20 }) }),
20507
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
20508
- "input",
20509
- {
20510
- type: "range",
20511
- min: "0",
20512
- max: "1",
20513
- step: "0.01",
20514
- value: volume,
20515
- onChange: handleVolumeChange,
20516
- className: "flex-1 h-2 bg-muted rounded-lg appearance-none cursor-pointer"
20517
- }
20518
- )
20519
- ] }),
20520
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { className: "flex justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(
20521
- "button",
20522
- {
20523
- onClick: () => setShowPlaylist(!showPlaylist),
20524
- className: "flex items-center gap-2 px-4 py-2 bg-secondary hover:bg-secondary/80 rounded-lg text-secondary-foreground transition-colors",
20525
- children: [
20526
- showPlaylist ? /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_lucide_react33.X, { size: 20 }) : /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_lucide_react33.List, { size: 20 }),
20527
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("span", { children: showPlaylist ? "Hide Playlist" : "Show Playlist" })
20528
- ]
20529
- }
20530
- ) })
20531
- ] }),
20532
- showPlaylist && /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { className: "bg-muted/50 backdrop-blur-sm max-h-96 overflow-y-auto border-t border-border/50", children: /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "p-4", children: [
20533
- /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("h3", { className: "text-lg font-semibold text-foreground mb-3", children: [
20534
- "Playlist (",
20535
- playlist.length,
20536
- " songs)"
20537
- ] }),
20538
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { className: "space-y-2", children: playlist.map((song, index) => /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(
20539
- "div",
20540
- {
20541
- onClick: () => playSong(index),
20542
- className: `flex items-center gap-3 p-3 rounded-lg cursor-pointer transition-all ${index === currentSongIndex ? "bg-primary/20 border border-primary shadow-lg" : "bg-secondary/30 hover:bg-secondary/50"}`,
20543
- children: [
20544
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { className: "shrink-0 w-8 h-8 flex items-center justify-center rounded-full bg-primary text-primary-foreground text-sm font-semibold", children: index === currentSongIndex && isPlaying ? "\u25B6" : index + 1 }),
20545
- /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "flex-1 min-w-0", children: [
20546
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("p", { className: "text-foreground font-medium truncate", children: song.title }),
20547
- song.artist && /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("p", { className: "text-muted-foreground text-sm truncate", children: song.artist })
20548
- ] }),
20549
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { className: "text-muted-foreground text-sm shrink-0", children: song.duration })
20550
- ]
20551
- },
20552
- song.id
20553
- )) })
20554
- ] }) }),
20555
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("style", { children: `
20470
+ return /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(
20471
+ "div",
20472
+ {
20473
+ className: [
20474
+ "underverse-music-player bg-card dark:bg-card border border-border/50 rounded-2xl shadow-2xl",
20475
+ overflowHidden ? "overflow-hidden" : "",
20476
+ className
20477
+ ].filter(Boolean).join(" "),
20478
+ children: [
20479
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("audio", { ref: audioRef, src: currentSong.audioUrl, onTimeUpdate: handleTimeUpdate, onLoadedMetadata: handleLoadedMetadata, onEnded: playNext }),
20480
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "p-6", children: [
20481
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "text-center mb-6", children: [
20482
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { className: "w-48 h-48 mx-auto mb-4 bg-primary/10 dark:bg-primary/20 border border-primary/30 rounded-2xl shadow-lg flex items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { className: "text-6xl", children: "\u{1F3B5}" }) }),
20483
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("h2", { className: "text-2xl font-bold text-foreground mb-1", children: currentSong.title }),
20484
+ currentSong.artist && /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("p", { className: "text-muted-foreground", children: currentSong.artist })
20485
+ ] }),
20486
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "mb-4", children: [
20487
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
20488
+ "input",
20489
+ {
20490
+ type: "range",
20491
+ min: "0",
20492
+ max: duration || 0,
20493
+ value: currentTime,
20494
+ onChange: handleSeek,
20495
+ className: "w-full h-2 bg-muted rounded-lg appearance-none cursor-pointer slider"
20496
+ }
20497
+ ),
20498
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "flex justify-between text-sm text-muted-foreground mt-1", children: [
20499
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("span", { children: formatTime3(currentTime) }),
20500
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("span", { children: formatTime3(duration) })
20501
+ ] })
20502
+ ] }),
20503
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "flex items-center justify-center gap-4 mb-6", children: [
20504
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
20505
+ "button",
20506
+ {
20507
+ onClick: playPrevious,
20508
+ className: "w-12 h-12 flex items-center justify-center rounded-full bg-secondary hover:bg-secondary/80 transition-colors text-secondary-foreground",
20509
+ children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_lucide_react33.SkipBack, { size: 24 })
20510
+ }
20511
+ ),
20512
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
20513
+ "button",
20514
+ {
20515
+ onClick: togglePlay,
20516
+ className: "w-16 h-16 flex items-center justify-center rounded-full bg-primary hover:bg-primary/90 transition-colors text-primary-foreground shadow-lg",
20517
+ children: isPlaying ? /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_lucide_react33.Pause, { size: 32 }) : /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_lucide_react33.Play, { size: 32, className: "ml-1" })
20518
+ }
20519
+ ),
20520
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
20521
+ "button",
20522
+ {
20523
+ onClick: playNext,
20524
+ className: "w-12 h-12 flex items-center justify-center rounded-full bg-secondary hover:bg-secondary/80 transition-colors text-secondary-foreground",
20525
+ children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_lucide_react33.SkipForward, { size: 24 })
20526
+ }
20527
+ )
20528
+ ] }),
20529
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "flex items-center gap-3 mb-4", children: [
20530
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("button", { onClick: toggleMute, className: "text-foreground hover:text-primary transition-colors", children: isMuted || volume === 0 ? /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_lucide_react33.VolumeX, { size: 20 }) : /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_lucide_react33.Volume2, { size: 20 }) }),
20531
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
20532
+ "input",
20533
+ {
20534
+ type: "range",
20535
+ min: "0",
20536
+ max: "1",
20537
+ step: "0.01",
20538
+ value: volume,
20539
+ onChange: handleVolumeChange,
20540
+ className: "flex-1 h-2 bg-muted rounded-lg appearance-none cursor-pointer"
20541
+ }
20542
+ )
20543
+ ] }),
20544
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { className: "flex justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(
20545
+ "button",
20546
+ {
20547
+ onClick: () => setShowPlaylist(!showPlaylist),
20548
+ className: "flex items-center gap-2 px-4 py-2 bg-secondary hover:bg-secondary/80 rounded-lg text-secondary-foreground transition-colors",
20549
+ children: [
20550
+ showPlaylist ? /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_lucide_react33.X, { size: 20 }) : /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_lucide_react33.List, { size: 20 }),
20551
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("span", { children: showPlaylist ? "Hide Playlist" : "Show Playlist" })
20552
+ ]
20553
+ }
20554
+ ) })
20555
+ ] }),
20556
+ showPlaylist && /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { className: "bg-muted/50 backdrop-blur-sm max-h-96 overflow-y-auto border-t border-border/50", children: /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "p-4", children: [
20557
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("h3", { className: "text-lg font-semibold text-foreground mb-3", children: [
20558
+ "Playlist (",
20559
+ playlist.length,
20560
+ " songs)"
20561
+ ] }),
20562
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { className: "space-y-2", children: playlist.map((song, index) => /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(
20563
+ "div",
20564
+ {
20565
+ onClick: () => playSong(index),
20566
+ className: `flex items-center gap-3 p-3 rounded-lg cursor-pointer transition-all ${index === currentSongIndex ? "bg-primary/20 border border-primary shadow-lg" : "bg-secondary/30 hover:bg-secondary/50"}`,
20567
+ children: [
20568
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { className: "shrink-0 w-8 h-8 flex items-center justify-center rounded-full bg-primary text-primary-foreground text-sm font-semibold", children: index === currentSongIndex && isPlaying ? "\u25B6" : index + 1 }),
20569
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "flex-1 min-w-0", children: [
20570
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("p", { className: "text-foreground font-medium truncate", children: song.title }),
20571
+ song.artist && /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("p", { className: "text-muted-foreground text-sm truncate", children: song.artist })
20572
+ ] }),
20573
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { className: "text-muted-foreground text-sm shrink-0", children: song.duration })
20574
+ ]
20575
+ },
20576
+ song.id
20577
+ )) })
20578
+ ] }) }),
20579
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("style", { children: `
20556
20580
  .underverse-music-player input[type="range"]::-webkit-slider-thumb {
20557
20581
  -webkit-appearance: none;
20558
20582
  appearance: none;
@@ -20578,7 +20602,9 @@ var MusicPlayer = ({
20578
20602
  background: linear-gradient(to right, hsl(var(--primary)) var(--progress, 0%), hsl(var(--muted)) var(--progress, 0%));
20579
20603
  }
20580
20604
  ` })
20581
- ] });
20605
+ ]
20606
+ }
20607
+ );
20582
20608
  };
20583
20609
  var MusicPlayer_default = MusicPlayer;
20584
20610