@moontra/moonui-pro 2.17.3 → 2.17.5

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.mjs CHANGED
@@ -3,11 +3,11 @@ import { twMerge } from 'tailwind-merge';
3
3
  import * as t from 'react';
4
4
  import t__default, { useState, useRef, useCallback, useMemo, forwardRef, createContext, useEffect, useContext, useLayoutEffect, useDebugValue, Component } from 'react';
5
5
  import * as AccordionPrimitive from '@radix-ui/react-accordion';
6
- import { ChevronDown, Info, AlertCircle, AlertTriangle, Check, X, MoreHorizontal, Loader2, Minus, Search, ChevronRight, Circle, ChevronUp, Lock, Sparkles, Plus, PanelLeft, PanelRight, ChevronLeft, Download, FileText, FileSpreadsheet, FileCode, Printer, Share2, Settings, Upload, Play, Eye, CheckCircle2, Pause, RotateCcw, Copy, Share, Trash2, CreditCard, Globe, XCircle, Clock, HelpCircle, Calendar as Calendar$1, Repeat, Edit, MapPin, Users, User, Briefcase, ClipboardList, Bell, Cake, Tag, Filter, Move, Archive, EyeOff, Timer, Palette, ArrowUpDown, Star, Square, CheckSquare, Bold, Italic, Underline, Strikethrough, Code, Type, Heading1, Heading2, Heading3, AlignLeft, AlignCenter, AlignRight, AlignJustify, List, ListOrdered, Quote, Highlighter, Link2, Image as Image$1, Table as Table$1, Undo, Redo, RefreshCw, Wand2, Maximize, MessageSquare, Heart, GraduationCap, Zap, Languages, Lightbulb, Target, GitBranch, ArrowRight, MoreVertical, Trash, ExternalLink, TrendingUp, MessageCircle, Paperclip, TrendingDown, ZoomOut, ZoomIn, FileJson, Maximize2, Menu, CheckCheck, CheckCircle, Settings2, LogOut, Edit3, LayoutGrid, Save, Video, Music, File, FileDown, ArrowUp, ArrowDown, ChevronsLeft, ChevronsRight, Pin, Sun, Moon, Monitor, Activity, Send, Flag, CalendarIcon, DollarSign, Github, GitFork, Server, RotateCw, Cpu, MemoryStick, HardDrive, Network, BarChart3, Columns, Grip, Unlock, Minimize2, Map as Map$1, BellOff, ArrowDownRight, ArrowUpRight } from 'lucide-react';
6
+ import { ChevronDown, Info, AlertCircle, AlertTriangle, Check, X, MoreHorizontal, Loader2, Minus, Search, ChevronRight, Circle, ChevronUp, Lock, Sparkles, Plus, PanelLeft, PanelRight, ChevronLeft, Download, FileText, FileSpreadsheet, FileCode, Printer, Share2, Settings, Upload, Play, Eye, CheckCircle2, Pause, RotateCcw, Copy, Share, Trash2, CreditCard, Globe, XCircle, Clock, HelpCircle, Calendar as Calendar$1, Repeat, Edit, MapPin, Users, User, Briefcase, ClipboardList, Bell, Cake, Tag, Filter, Move, Archive, EyeOff, Timer, Palette, ArrowUpDown, Star, Square, CheckSquare, Bold, Italic, Underline, Strikethrough, Code, Type, Heading1, Heading2, Heading3, AlignLeft, AlignCenter, AlignRight, AlignJustify, List, ListOrdered, Quote, Highlighter, Link2, Image as Image$1, Table as Table$1, Undo, Redo, RefreshCw, Wand2, Maximize, MessageSquare, Heart, GraduationCap, Zap, Languages, Lightbulb, Cpu, BarChart3, Target, GitBranch, ArrowRight, MoreVertical, Trash, ExternalLink, TrendingUp, MessageCircle, Paperclip, TrendingDown, ZoomOut, ZoomIn, FileJson, Maximize2, Menu, CheckCheck, CheckCircle, Settings2, LogOut, Edit3, LayoutGrid, Save, Video, Music, File, FileDown, ArrowUp, ArrowDown, ChevronsLeft, ChevronsRight, Pin, Sun, Moon, Monitor, Activity, Send, Flag, CalendarIcon, DollarSign, Github, GitFork, Server, RotateCw, MemoryStick, HardDrive, Network, Columns, Grip, Unlock, Minimize2, Map as Map$1, BellOff, ArrowDownRight, ArrowUpRight } from 'lucide-react';
7
7
  import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
8
8
  import { cva } from 'class-variance-authority';
9
9
  import * as AvatarPrimitive from '@radix-ui/react-avatar';
10
- import { startOfDay, endOfDay, addDays, startOfYear, endOfYear, startOfMonth, endOfMonth, startOfWeek, endOfWeek, isWithinInterval, isBefore, isAfter, subYears, addYears, subMonths, addMonths, subWeeks, addWeeks, subDays, addHours, differenceInMinutes, addMinutes, format, isSameDay, setHours, setMinutes, isToday, eachDayOfInterval, isSameMonth, eachMonthOfInterval, getDay, getDaysInMonth, formatDistanceToNow } from 'date-fns';
10
+ import { startOfDay, endOfDay, addDays, startOfYear, endOfYear, startOfMonth, endOfMonth, startOfWeek, endOfWeek, isWithinInterval, isBefore, isAfter, subYears, addYears, subMonths, addMonths, subWeeks, addWeeks, subDays, addHours, setHours, setMinutes, differenceInMinutes, addMinutes, format, isSameDay, isToday, eachDayOfInterval, isSameMonth, eachMonthOfInterval, getDay, getDaysInMonth, formatDistanceToNow } from 'date-fns';
11
11
  import { motion, AnimatePresence, useMotionValue, useSpring, useTransform, animate, LayoutGroup, Reorder, useDragControls } from 'framer-motion';
12
12
  import * as CheckboxPrimitive from '@radix-ui/react-checkbox';
13
13
  import * as ReactDOM from 'react-dom';
@@ -3597,7 +3597,7 @@ var CollapsibleContentImpl = t.forwardRef((props, forwardedRef) => {
3597
3597
  const heightRef = t.useRef(0);
3598
3598
  const height = heightRef.current;
3599
3599
  const widthRef = t.useRef(0);
3600
- const width = widthRef.current;
3600
+ const width2 = widthRef.current;
3601
3601
  const isOpen = context.open || isPresent;
3602
3602
  const isMountAnimationPreventedRef = t.useRef(isOpen);
3603
3603
  const originalStylesRef = t.useRef(void 0);
@@ -3635,7 +3635,7 @@ var CollapsibleContentImpl = t.forwardRef((props, forwardedRef) => {
3635
3635
  ref: composedRefs,
3636
3636
  style: {
3637
3637
  [`--radix-collapsible-content-height`]: height ? `${height}px` : void 0,
3638
- [`--radix-collapsible-content-width`]: width ? `${width}px` : void 0,
3638
+ [`--radix-collapsible-content-width`]: width2 ? `${width2}px` : void 0,
3639
3639
  ...props.style
3640
3640
  },
3641
3641
  children: isOpen && children
@@ -6897,9 +6897,9 @@ function getSideList(side, isStart, rtl) {
6897
6897
  return [];
6898
6898
  }
6899
6899
  }
6900
- function getOppositeAxisPlacements(placement, flipAlignment, direction, rtl) {
6900
+ function getOppositeAxisPlacements(placement, flipAlignment, direction2, rtl) {
6901
6901
  const alignment = getAlignment(placement);
6902
- let list = getSideList(getSide(placement), direction === "start", rtl);
6902
+ let list = getSideList(getSide(placement), direction2 === "start", rtl);
6903
6903
  if (alignment) {
6904
6904
  list = list.map((side) => side + "-" + alignment);
6905
6905
  if (flipAlignment) {
@@ -6932,15 +6932,15 @@ function rectToClientRect(rect) {
6932
6932
  const {
6933
6933
  x,
6934
6934
  y,
6935
- width,
6935
+ width: width2,
6936
6936
  height
6937
6937
  } = rect;
6938
6938
  return {
6939
- width,
6939
+ width: width2,
6940
6940
  height,
6941
6941
  top: y,
6942
6942
  left: x,
6943
- right: x + width,
6943
+ right: x + width2,
6944
6944
  bottom: y + height,
6945
6945
  x,
6946
6946
  y
@@ -7603,7 +7603,7 @@ var size = function(options) {
7603
7603
  const alignment = getAlignment(placement);
7604
7604
  const isYAxis = getSideAxis(placement) === "y";
7605
7605
  const {
7606
- width,
7606
+ width: width2,
7607
7607
  height
7608
7608
  } = rects.floating;
7609
7609
  let heightSide;
@@ -7616,9 +7616,9 @@ var size = function(options) {
7616
7616
  heightSide = alignment === "end" ? "top" : "bottom";
7617
7617
  }
7618
7618
  const maximumClippingHeight = height - overflow.top - overflow.bottom;
7619
- const maximumClippingWidth = width - overflow.left - overflow.right;
7619
+ const maximumClippingWidth = width2 - overflow.left - overflow.right;
7620
7620
  const overflowAvailableHeight = min(height - overflow[heightSide], maximumClippingHeight);
7621
- const overflowAvailableWidth = min(width - overflow[widthSide], maximumClippingWidth);
7621
+ const overflowAvailableWidth = min(width2 - overflow[widthSide], maximumClippingWidth);
7622
7622
  const noShift = !state.middlewareData.shift;
7623
7623
  let availableHeight = overflowAvailableHeight;
7624
7624
  let availableWidth = overflowAvailableWidth;
@@ -7634,7 +7634,7 @@ var size = function(options) {
7634
7634
  const yMin = max(overflow.top, 0);
7635
7635
  const yMax = max(overflow.bottom, 0);
7636
7636
  if (isYAxis) {
7637
- availableWidth = width - 2 * (xMin !== 0 || xMax !== 0 ? xMin + xMax : max(overflow.left, overflow.right));
7637
+ availableWidth = width2 - 2 * (xMin !== 0 || xMax !== 0 ? xMin + xMax : max(overflow.left, overflow.right));
7638
7638
  } else {
7639
7639
  availableHeight = height - 2 * (yMin !== 0 || yMax !== 0 ? yMin + yMax : max(overflow.top, overflow.bottom));
7640
7640
  }
@@ -7645,7 +7645,7 @@ var size = function(options) {
7645
7645
  availableHeight
7646
7646
  });
7647
7647
  const nextDimensions = await platform2.getDimensions(elements.floating);
7648
- if (width !== nextDimensions.width || height !== nextDimensions.height) {
7648
+ if (width2 !== nextDimensions.width || height !== nextDimensions.height) {
7649
7649
  return {
7650
7650
  reset: {
7651
7651
  rects: true
@@ -7814,18 +7814,18 @@ function getFrameElement(win) {
7814
7814
  // node_modules/@floating-ui/dom/dist/floating-ui.dom.mjs
7815
7815
  function getCssDimensions(element) {
7816
7816
  const css2 = getComputedStyle2(element);
7817
- let width = parseFloat(css2.width) || 0;
7817
+ let width2 = parseFloat(css2.width) || 0;
7818
7818
  let height = parseFloat(css2.height) || 0;
7819
7819
  const hasOffset = isHTMLElement(element);
7820
- const offsetWidth = hasOffset ? element.offsetWidth : width;
7820
+ const offsetWidth = hasOffset ? element.offsetWidth : width2;
7821
7821
  const offsetHeight = hasOffset ? element.offsetHeight : height;
7822
- const shouldFallback = round(width) !== offsetWidth || round(height) !== offsetHeight;
7822
+ const shouldFallback = round(width2) !== offsetWidth || round(height) !== offsetHeight;
7823
7823
  if (shouldFallback) {
7824
- width = offsetWidth;
7824
+ width2 = offsetWidth;
7825
7825
  height = offsetHeight;
7826
7826
  }
7827
7827
  return {
7828
- width,
7828
+ width: width2,
7829
7829
  height,
7830
7830
  $: shouldFallback
7831
7831
  };
@@ -7840,11 +7840,11 @@ function getScale(element) {
7840
7840
  }
7841
7841
  const rect = domElement.getBoundingClientRect();
7842
7842
  const {
7843
- width,
7843
+ width: width2,
7844
7844
  height,
7845
7845
  $: $2
7846
7846
  } = getCssDimensions(domElement);
7847
- let x = ($2 ? round(rect.width) : rect.width) / width;
7847
+ let x = ($2 ? round(rect.width) : rect.width) / width2;
7848
7848
  let y = ($2 ? round(rect.height) : rect.height) / height;
7849
7849
  if (!x || !Number.isFinite(x)) {
7850
7850
  x = 1;
@@ -7899,7 +7899,7 @@ function getBoundingClientRect(element, includeScale, isFixedStrategy, offsetPar
7899
7899
  const visualOffsets = shouldAddVisualOffsets(domElement, isFixedStrategy, offsetParent) ? getVisualOffsets(domElement) : createCoords(0);
7900
7900
  let x = (clientRect2.left + visualOffsets.x) / scale.x;
7901
7901
  let y = (clientRect2.top + visualOffsets.y) / scale.y;
7902
- let width = clientRect2.width / scale.x;
7902
+ let width2 = clientRect2.width / scale.x;
7903
7903
  let height = clientRect2.height / scale.y;
7904
7904
  if (domElement) {
7905
7905
  const win = getWindow(domElement);
@@ -7914,7 +7914,7 @@ function getBoundingClientRect(element, includeScale, isFixedStrategy, offsetPar
7914
7914
  const top = iframeRect.top + (currentIFrame.clientTop + parseFloat(css2.paddingTop)) * iframeScale.y;
7915
7915
  x *= iframeScale.x;
7916
7916
  y *= iframeScale.y;
7917
- width *= iframeScale.x;
7917
+ width2 *= iframeScale.x;
7918
7918
  height *= iframeScale.y;
7919
7919
  x += left;
7920
7920
  y += top;
@@ -7923,7 +7923,7 @@ function getBoundingClientRect(element, includeScale, isFixedStrategy, offsetPar
7923
7923
  }
7924
7924
  }
7925
7925
  return rectToClientRect({
7926
- width,
7926
+ width: width2,
7927
7927
  height,
7928
7928
  x,
7929
7929
  y
@@ -7997,15 +7997,15 @@ function getDocumentRect(element) {
7997
7997
  const html = getDocumentElement(element);
7998
7998
  const scroll = getNodeScroll(element);
7999
7999
  const body = element.ownerDocument.body;
8000
- const width = max(html.scrollWidth, html.clientWidth, body.scrollWidth, body.clientWidth);
8000
+ const width2 = max(html.scrollWidth, html.clientWidth, body.scrollWidth, body.clientWidth);
8001
8001
  const height = max(html.scrollHeight, html.clientHeight, body.scrollHeight, body.clientHeight);
8002
8002
  let x = -scroll.scrollLeft + getWindowScrollBarX(element);
8003
8003
  const y = -scroll.scrollTop;
8004
8004
  if (getComputedStyle2(body).direction === "rtl") {
8005
- x += max(html.clientWidth, body.clientWidth) - width;
8005
+ x += max(html.clientWidth, body.clientWidth) - width2;
8006
8006
  }
8007
8007
  return {
8008
- width,
8008
+ width: width2,
8009
8009
  height,
8010
8010
  x,
8011
8011
  y
@@ -8015,12 +8015,12 @@ function getViewportRect(element, strategy) {
8015
8015
  const win = getWindow(element);
8016
8016
  const html = getDocumentElement(element);
8017
8017
  const visualViewport = win.visualViewport;
8018
- let width = html.clientWidth;
8018
+ let width2 = html.clientWidth;
8019
8019
  let height = html.clientHeight;
8020
8020
  let x = 0;
8021
8021
  let y = 0;
8022
8022
  if (visualViewport) {
8023
- width = visualViewport.width;
8023
+ width2 = visualViewport.width;
8024
8024
  height = visualViewport.height;
8025
8025
  const visualViewportBased = isWebKit();
8026
8026
  if (!visualViewportBased || visualViewportBased && strategy === "fixed") {
@@ -8029,7 +8029,7 @@ function getViewportRect(element, strategy) {
8029
8029
  }
8030
8030
  }
8031
8031
  return {
8032
- width,
8032
+ width: width2,
8033
8033
  height,
8034
8034
  x,
8035
8035
  y
@@ -8041,12 +8041,12 @@ function getInnerBoundingClientRect(element, strategy) {
8041
8041
  const top = clientRect2.top + element.clientTop;
8042
8042
  const left = clientRect2.left + element.clientLeft;
8043
8043
  const scale = isHTMLElement(element) ? getScale(element) : createCoords(1);
8044
- const width = element.clientWidth * scale.x;
8044
+ const width2 = element.clientWidth * scale.x;
8045
8045
  const height = element.clientHeight * scale.y;
8046
8046
  const x = left * scale.x;
8047
8047
  const y = top * scale.y;
8048
8048
  return {
8049
- width,
8049
+ width: width2,
8050
8050
  height,
8051
8051
  x,
8052
8052
  y
@@ -8131,11 +8131,11 @@ function getClippingRect(_ref) {
8131
8131
  }
8132
8132
  function getDimensions(element) {
8133
8133
  const {
8134
- width,
8134
+ width: width2,
8135
8135
  height
8136
8136
  } = getCssDimensions(element);
8137
8137
  return {
8138
- width,
8138
+ width: width2,
8139
8139
  height
8140
8140
  };
8141
8141
  }
@@ -8271,17 +8271,17 @@ function observeMove(element, onMove) {
8271
8271
  const {
8272
8272
  left,
8273
8273
  top,
8274
- width,
8274
+ width: width2,
8275
8275
  height
8276
8276
  } = elementRectForRootMargin;
8277
8277
  if (!skip) {
8278
8278
  onMove();
8279
8279
  }
8280
- if (!width || !height) {
8280
+ if (!width2 || !height) {
8281
8281
  return;
8282
8282
  }
8283
8283
  const insetTop = floor(top);
8284
- const insetRight = floor(root.clientWidth - (left + width));
8284
+ const insetRight = floor(root.clientWidth - (left + width2));
8285
8285
  const insetBottom = floor(root.clientHeight - (top + height));
8286
8286
  const insetLeft = floor(left);
8287
8287
  const rootMargin = -insetTop + "px " + -insetRight + "px " + -insetBottom + "px " + -insetLeft + "px";
@@ -8697,13 +8697,13 @@ var arrow3 = (options, deps) => ({
8697
8697
  });
8698
8698
  var NAME2 = "Arrow";
8699
8699
  var Arrow2 = t.forwardRef((props, forwardedRef) => {
8700
- const { children, width = 10, height = 5, ...arrowProps } = props;
8700
+ const { children, width: width2 = 10, height = 5, ...arrowProps } = props;
8701
8701
  return /* @__PURE__ */ jsx(
8702
8702
  Primitive.svg,
8703
8703
  {
8704
8704
  ...arrowProps,
8705
8705
  ref: forwardedRef,
8706
- width,
8706
+ width: width2,
8707
8707
  height,
8708
8708
  viewBox: "0 0 30 10",
8709
8709
  preserveAspectRatio: "none",
@@ -8733,18 +8733,18 @@ function useSize(element) {
8733
8733
  return;
8734
8734
  }
8735
8735
  const entry = entries[0];
8736
- let width;
8736
+ let width2;
8737
8737
  let height;
8738
8738
  if ("borderBoxSize" in entry) {
8739
8739
  const borderSizeEntry = entry["borderBoxSize"];
8740
8740
  const borderSize = Array.isArray(borderSizeEntry) ? borderSizeEntry[0] : borderSizeEntry;
8741
- width = borderSize["inlineSize"];
8741
+ width2 = borderSize["inlineSize"];
8742
8742
  height = borderSize["blockSize"];
8743
8743
  } else {
8744
- width = element.offsetWidth;
8744
+ width2 = element.offsetWidth;
8745
8745
  height = element.offsetHeight;
8746
8746
  }
8747
- setSize({ width, height });
8747
+ setSize({ width: width2, height });
8748
8748
  });
8749
8749
  resizeObserver.observe(element, { box: "border-box" });
8750
8750
  return () => resizeObserver.unobserve(element);
@@ -10908,9 +10908,9 @@ function Calendar3({
10908
10908
  return true;
10909
10909
  return false;
10910
10910
  };
10911
- const navigateMonth = (direction) => {
10911
+ const navigateMonth = (direction2) => {
10912
10912
  const newDate = new Date(currentDate);
10913
- if (direction === "prev") {
10913
+ if (direction2 === "prev") {
10914
10914
  newDate.setMonth(currentMonth - 1);
10915
10915
  } else {
10916
10916
  newDate.setMonth(currentMonth + 1);
@@ -11518,6 +11518,8 @@ var CalendarPro = t.forwardRef(({
11518
11518
  theme = "system",
11519
11519
  ...props
11520
11520
  }, ref) => {
11521
+ const [draggedEventId, setDraggedEventId] = useState(null);
11522
+ const [dragOverInfo, setDragOverInfo] = useState(null);
11521
11523
  const [internalSidebarCollapsed, setInternalSidebarCollapsed] = useState(false);
11522
11524
  const sidebarCollapsed = controlledSidebarCollapsed ?? internalSidebarCollapsed;
11523
11525
  const setSidebarCollapsed = useCallback((collapsed) => {
@@ -11542,8 +11544,8 @@ var CalendarPro = t.forwardRef(({
11542
11544
  const [selectedCategories, setSelectedCategories] = useState([]);
11543
11545
  const [editingEvent, setEditingEvent] = useState({});
11544
11546
  const [isDragging, setIsDragging] = useState(false);
11545
- const [draggedEvent, setDraggedEvent] = useState(null);
11546
- const [dropTarget, setDropTarget] = useState(null);
11547
+ useState(null);
11548
+ useState(null);
11547
11549
  useRef(null);
11548
11550
  const currentViewConfig = useMemo(() => {
11549
11551
  return views.find((v) => v.id === currentView) || views[0];
@@ -11594,21 +11596,21 @@ var CalendarPro = t.forwardRef(({
11594
11596
  setCurrentView(viewId);
11595
11597
  onViewChange?.(viewId);
11596
11598
  }, [onViewChange]);
11597
- const navigateDate = useCallback((direction) => {
11599
+ const navigateDate = useCallback((direction2) => {
11598
11600
  const viewType = currentViewConfig.type;
11599
11601
  let newDate;
11600
11602
  switch (viewType) {
11601
11603
  case "day":
11602
- newDate = direction === "prev" ? subDays(currentDate, 1) : addDays(currentDate, 1);
11604
+ newDate = direction2 === "prev" ? subDays(currentDate, 1) : addDays(currentDate, 1);
11603
11605
  break;
11604
11606
  case "week":
11605
- newDate = direction === "prev" ? subWeeks(currentDate, 1) : addWeeks(currentDate, 1);
11607
+ newDate = direction2 === "prev" ? subWeeks(currentDate, 1) : addWeeks(currentDate, 1);
11606
11608
  break;
11607
11609
  case "month":
11608
- newDate = direction === "prev" ? subMonths(currentDate, 1) : addMonths(currentDate, 1);
11610
+ newDate = direction2 === "prev" ? subMonths(currentDate, 1) : addMonths(currentDate, 1);
11609
11611
  break;
11610
11612
  case "year":
11611
- newDate = direction === "prev" ? subYears(currentDate, 1) : addYears(currentDate, 1);
11613
+ newDate = direction2 === "prev" ? subYears(currentDate, 1) : addYears(currentDate, 1);
11612
11614
  break;
11613
11615
  default:
11614
11616
  newDate = currentDate;
@@ -11655,23 +11657,65 @@ var CalendarPro = t.forwardRef(({
11655
11657
  setEditingEvent({});
11656
11658
  }
11657
11659
  }, [selectedEvent, onEventDelete]);
11658
- useCallback((event) => {
11660
+ const handleDragStart = useCallback((e, event) => {
11659
11661
  if (!allowEventDragging)
11660
11662
  return;
11663
+ setDraggedEventId(event.id);
11661
11664
  setIsDragging(true);
11662
- setDraggedEvent(event);
11665
+ e.dataTransfer.effectAllowed = "move";
11666
+ e.dataTransfer.setData("text/plain", event.id);
11667
+ const dragImage = e.currentTarget.cloneNode(true);
11668
+ const originalRect = e.currentTarget.getBoundingClientRect();
11669
+ dragImage.style.opacity = "0.8";
11670
+ dragImage.style.position = "absolute";
11671
+ dragImage.style.top = "-1000px";
11672
+ dragImage.style.width = `${originalRect.width}px`;
11673
+ dragImage.style.height = `${originalRect.height}px`;
11674
+ dragImage.style.boxSizing = "border-box";
11675
+ document.body.appendChild(dragImage);
11676
+ e.dataTransfer.setDragImage(dragImage, e.nativeEvent.offsetX, e.nativeEvent.offsetY);
11677
+ setTimeout(() => document.body.removeChild(dragImage), 0);
11663
11678
  }, [allowEventDragging]);
11664
- useCallback((result) => {
11665
- setIsDragging(false);
11666
- setDraggedEvent(null);
11667
- setDropTarget(null);
11668
- if (!result.destination || !draggedEvent || !onEventDrop)
11679
+ const handleDragOver = useCallback((e, date, hour) => {
11680
+ e.preventDefault();
11681
+ e.dataTransfer.dropEffect = "move";
11682
+ setDragOverInfo({ date, hour });
11683
+ }, []);
11684
+ const handleDragLeave = useCallback((e) => {
11685
+ const rect = e.currentTarget.getBoundingClientRect();
11686
+ const x = e.clientX;
11687
+ const y = e.clientY;
11688
+ if (x < rect.left || x >= rect.right || y < rect.top || y >= rect.bottom) {
11689
+ setDragOverInfo(null);
11690
+ }
11691
+ }, []);
11692
+ const handleDrop = useCallback((e, date, hour) => {
11693
+ e.preventDefault();
11694
+ const eventId = e.dataTransfer.getData("text/plain");
11695
+ const draggedEvent2 = events.find((ev) => ev.id === eventId);
11696
+ if (!draggedEvent2 || !onEventDrop)
11669
11697
  return;
11670
- const newStart = new Date(result.destination.droppableId);
11671
- const duration = differenceInMinutes(draggedEvent.end, draggedEvent.start);
11672
- const newEnd = addMinutes(newStart, duration);
11673
- onEventDrop(draggedEvent.id, newStart, newEnd);
11674
- }, [draggedEvent, onEventDrop]);
11698
+ let newStart;
11699
+ let newEnd;
11700
+ if (hour !== void 0) {
11701
+ newStart = setHours(setMinutes(date, 0), hour);
11702
+ } else {
11703
+ const originalHours = draggedEvent2.start.getHours();
11704
+ const originalMinutes = draggedEvent2.start.getMinutes();
11705
+ newStart = setHours(setMinutes(date, originalMinutes), originalHours);
11706
+ }
11707
+ const duration = differenceInMinutes(draggedEvent2.end, draggedEvent2.start);
11708
+ newEnd = addMinutes(newStart, duration);
11709
+ onEventDrop(draggedEvent2.id, newStart, newEnd);
11710
+ setDraggedEventId(null);
11711
+ setDragOverInfo(null);
11712
+ setIsDragging(false);
11713
+ }, [events, onEventDrop]);
11714
+ const handleDragEnd = useCallback(() => {
11715
+ setDraggedEventId(null);
11716
+ setDragOverInfo(null);
11717
+ setIsDragging(false);
11718
+ }, []);
11675
11719
  const exportCalendar = useCallback((format7) => {
11676
11720
  if (onExport) {
11677
11721
  onExport(format7, eventsInView);
@@ -11738,28 +11782,50 @@ END:VCALENDAR`;
11738
11782
  (event) => isSameDay(new Date(event.start), currentDate)
11739
11783
  );
11740
11784
  return /* @__PURE__ */ jsx("div", { className: "flex flex-1 overflow-hidden", children: /* @__PURE__ */ jsx("div", { className: "flex-1 overflow-auto", children: /* @__PURE__ */ jsxs("div", { className: "min-h-full", children: [
11741
- /* @__PURE__ */ jsxs("div", { className: "border-b p-2", children: [
11742
- /* @__PURE__ */ jsx("div", { className: "text-xs text-muted-foreground mb-1", children: "All Day" }),
11743
- /* @__PURE__ */ jsx("div", { className: "space-y-1", children: dayEvents.filter((event) => event.allDay).map((event) => /* @__PURE__ */ jsx(
11744
- "div",
11745
- {
11746
- className: "p-2 rounded text-xs cursor-pointer hover:opacity-80",
11747
- style: {
11748
- backgroundColor: event.color || eventColors[event.category || ""] || "#3b82f6",
11749
- color: "#ffffff"
11750
- },
11751
- onClick: (e) => handleEventClick(event, e),
11752
- children: event.title
11753
- },
11754
- event.id
11755
- )) })
11756
- ] }),
11785
+ /* @__PURE__ */ jsxs(
11786
+ "div",
11787
+ {
11788
+ className: cn(
11789
+ "border-b p-2",
11790
+ dragOverInfo?.date && !dragOverInfo?.hour && isSameDay(dragOverInfo.date, currentDate) && "bg-primary/10"
11791
+ ),
11792
+ onDragOver: (e) => handleDragOver(e, currentDate),
11793
+ onDragLeave: handleDragLeave,
11794
+ onDrop: (e) => handleDrop(e, currentDate),
11795
+ children: [
11796
+ /* @__PURE__ */ jsx("div", { className: "text-xs text-muted-foreground mb-1", children: "All Day" }),
11797
+ /* @__PURE__ */ jsx("div", { className: "space-y-1", children: dayEvents.filter((event) => event.allDay).map((event) => /* @__PURE__ */ jsx(
11798
+ "div",
11799
+ {
11800
+ draggable: allowEventDragging,
11801
+ onDragStart: (e) => handleDragStart(e, event),
11802
+ onDragEnd: handleDragEnd,
11803
+ className: "p-2 rounded text-xs cursor-pointer hover:opacity-80",
11804
+ style: {
11805
+ backgroundColor: event.color || eventColors[event.category || ""] || "#3b82f6",
11806
+ color: "#ffffff",
11807
+ opacity: draggedEventId === event.id ? 0.5 : 1
11808
+ },
11809
+ onClick: (e) => handleEventClick(event, e),
11810
+ children: event.title
11811
+ },
11812
+ event.id
11813
+ )) })
11814
+ ]
11815
+ }
11816
+ ),
11757
11817
  /* @__PURE__ */ jsx("div", { className: "relative", children: hours.map((hour) => /* @__PURE__ */ jsxs("div", { className: "flex border-b", style: { height: "60px" }, children: [
11758
11818
  /* @__PURE__ */ jsx("div", { className: "w-16 p-2 text-xs text-muted-foreground text-right", children: format(setHours(/* @__PURE__ */ new Date(), hour), timeFormat === "12h" ? "h a" : "HH:00") }),
11759
11819
  /* @__PURE__ */ jsx(
11760
11820
  "div",
11761
11821
  {
11762
- className: "flex-1 relative border-l cursor-pointer hover:bg-muted/20",
11822
+ className: cn(
11823
+ "flex-1 relative border-l cursor-pointer hover:bg-muted/20",
11824
+ dragOverInfo?.date && dragOverInfo?.hour === hour && isSameDay(dragOverInfo.date, currentDate) && "bg-primary/10"
11825
+ ),
11826
+ onDragOver: (e) => handleDragOver(e, currentDate, hour),
11827
+ onDragLeave: handleDragLeave,
11828
+ onDrop: (e) => handleDrop(e, currentDate, hour),
11763
11829
  onClick: () => {
11764
11830
  if (allowEventCreation) {
11765
11831
  const clickedTime = setHours(setMinutes(currentDate, 0), hour);
@@ -11788,13 +11854,18 @@ END:VCALENDAR`;
11788
11854
  return /* @__PURE__ */ jsxs(
11789
11855
  "div",
11790
11856
  {
11857
+ draggable: allowEventDragging,
11858
+ onDragStart: (e) => handleDragStart(e, event),
11859
+ onDragEnd: handleDragEnd,
11791
11860
  className: "absolute left-0 right-0 mx-1 p-1 rounded text-xs cursor-pointer hover:opacity-80 overflow-hidden",
11792
11861
  style: {
11793
11862
  top: `${top}px`,
11794
11863
  height: `${height2}px`,
11795
11864
  backgroundColor: event.color || eventColors[event.category || ""] || "#3b82f6",
11796
11865
  color: "#ffffff",
11797
- zIndex: 10
11866
+ zIndex: 10,
11867
+ opacity: draggedEventId === event.id ? 0.5 : 1,
11868
+ cursor: allowEventDragging ? "move" : "pointer"
11798
11869
  },
11799
11870
  onClick: (e) => {
11800
11871
  e.stopPropagation();
@@ -11853,8 +11924,12 @@ END:VCALENDAR`;
11853
11924
  {
11854
11925
  className: cn(
11855
11926
  "flex-1 relative border-l border-b cursor-pointer hover:bg-muted/20",
11856
- isToday(day) && "bg-primary/5"
11927
+ isToday(day) && "bg-primary/5",
11928
+ dragOverInfo?.date && dragOverInfo?.hour === hour && isSameDay(dragOverInfo.date, day) && "bg-primary/10"
11857
11929
  ),
11930
+ onDragOver: (e) => handleDragOver(e, day, hour),
11931
+ onDragLeave: handleDragLeave,
11932
+ onDrop: (e) => handleDrop(e, day, hour),
11858
11933
  onClick: () => {
11859
11934
  if (allowEventCreation) {
11860
11935
  const clickedTime = setHours(setMinutes(day, 0), hour);
@@ -11881,13 +11956,18 @@ END:VCALENDAR`;
11881
11956
  return /* @__PURE__ */ jsx(
11882
11957
  "div",
11883
11958
  {
11959
+ draggable: allowEventDragging,
11960
+ onDragStart: (e) => handleDragStart(e, event),
11961
+ onDragEnd: handleDragEnd,
11884
11962
  className: "absolute left-0 right-0 mx-1 p-1 rounded text-xs cursor-pointer hover:opacity-80 overflow-hidden",
11885
11963
  style: {
11886
11964
  top: `${top}px`,
11887
11965
  height: `${height2}px`,
11888
11966
  backgroundColor: event.color || eventColors[event.category || ""] || "#3b82f6",
11889
11967
  color: "#ffffff",
11890
- zIndex: 10
11968
+ zIndex: 10,
11969
+ opacity: draggedEventId === event.id ? 0.5 : 1,
11970
+ cursor: allowEventDragging ? "move" : "pointer"
11891
11971
  },
11892
11972
  onClick: (e) => {
11893
11973
  e.stopPropagation();
@@ -11936,8 +12016,12 @@ END:VCALENDAR`;
11936
12016
  "min-h-[100px] p-2 border rounded-lg cursor-pointer transition-colors",
11937
12017
  !isCurrentMonth && "opacity-50",
11938
12018
  isToday(day) && "bg-primary/10 border-primary",
11939
- "hover:bg-muted/50"
12019
+ "hover:bg-muted/50",
12020
+ dragOverInfo?.date && !dragOverInfo?.hour && isSameDay(dragOverInfo.date, day) && "bg-primary/20 border-primary"
11940
12021
  ),
12022
+ onDragOver: (e) => handleDragOver(e, day),
12023
+ onDragLeave: handleDragLeave,
12024
+ onDrop: (e) => handleDrop(e, day),
11941
12025
  onClick: () => handleDateSelect(day),
11942
12026
  children: [
11943
12027
  /* @__PURE__ */ jsx("div", { className: cn(
@@ -11949,10 +12033,15 @@ END:VCALENDAR`;
11949
12033
  return /* @__PURE__ */ jsx(
11950
12034
  motion.div,
11951
12035
  {
12036
+ draggable: allowEventDragging,
12037
+ onDragStart: (e) => handleDragStart(e, event),
12038
+ onDragEnd: handleDragEnd,
11952
12039
  className: "text-xs p-1 rounded cursor-pointer truncate",
11953
12040
  style: {
11954
12041
  backgroundColor: event.color || eventColors[event.category || ""] || "#3b82f6",
11955
- color: "#ffffff"
12042
+ color: "#ffffff",
12043
+ opacity: draggedEventId === event.id ? 0.5 : 1,
12044
+ cursor: allowEventDragging ? "move" : "pointer"
11956
12045
  },
11957
12046
  whileHover: { scale: 1.02 },
11958
12047
  whileTap: { scale: 0.98 },
@@ -12008,7 +12097,7 @@ END:VCALENDAR`;
12008
12097
  ] })
12009
12098
  ] }),
12010
12099
  /* @__PURE__ */ jsx(MoonUICardContentPro, { children: /* @__PURE__ */ jsxs("div", { className: "grid grid-cols-7 gap-1 text-xs", children: [
12011
- ["S", "M", "T", "W", "T", "F", "S"].map((day) => /* @__PURE__ */ jsx("div", { className: "text-center text-muted-foreground p-1", children: day }, day)),
12100
+ ["S", "M", "T", "W", "T", "F", "S"].map((day, index2) => /* @__PURE__ */ jsx("div", { className: "text-center text-muted-foreground p-1", children: day }, `${day}-${index2}`)),
12012
12101
  Array.from({ length: getDay(startOfMonth(month)) }, (_, i) => /* @__PURE__ */ jsx("div", {}, `empty-${i}`)),
12013
12102
  Array.from({ length: getDaysInMonth(month) }, (_, i) => {
12014
12103
  const day = new Date(month.getFullYear(), month.getMonth(), i + 1);
@@ -13507,12 +13596,12 @@ var getInitials3 = (name) => {
13507
13596
  var useAutoScroll = () => {
13508
13597
  const scrollRef = useRef(null);
13509
13598
  const scrollIntervalRef = useRef(null);
13510
- const startAutoScroll = useCallback((direction) => {
13599
+ const startAutoScroll = useCallback((direction2) => {
13511
13600
  if (scrollIntervalRef.current)
13512
13601
  return;
13513
13602
  scrollIntervalRef.current = setInterval(() => {
13514
13603
  if (scrollRef.current) {
13515
- const scrollAmount = direction === "left" ? -10 : 10;
13604
+ const scrollAmount = direction2 === "left" ? -10 : 10;
13516
13605
  scrollRef.current.scrollLeft += scrollAmount;
13517
13606
  }
13518
13607
  }, 20);
@@ -36283,8 +36372,8 @@ if (typeof WeakMap != "undefined") {
36283
36372
  };
36284
36373
  }
36285
36374
  var TableMap = class {
36286
- constructor(width, height, map2, problems) {
36287
- this.width = width;
36375
+ constructor(width2, height, map2, problems) {
36376
+ this.width = width2;
36288
36377
  this.height = height;
36289
36378
  this.map = map2;
36290
36379
  this.problems = problems;
@@ -36396,12 +36485,12 @@ var TableMap = class {
36396
36485
  function computeMap(table) {
36397
36486
  if (table.type.spec.tableRole != "table")
36398
36487
  throw new RangeError("Not a table node: " + table.type.name);
36399
- const width = findWidth(table), height = table.childCount;
36488
+ const width2 = findWidth(table), height = table.childCount;
36400
36489
  const map2 = [];
36401
36490
  let mapPos = 0;
36402
36491
  let problems = null;
36403
36492
  const colWidths = [];
36404
- for (let i = 0, e = width * height; i < e; i++)
36493
+ for (let i = 0, e = width2 * height; i < e; i++)
36405
36494
  map2[i] = 0;
36406
36495
  for (let row = 0, pos = 0; row < height; row++) {
36407
36496
  const rowNode = table.child(row);
@@ -36422,7 +36511,7 @@ function computeMap(table) {
36422
36511
  });
36423
36512
  break;
36424
36513
  }
36425
- const start = mapPos + h2 * width;
36514
+ const start = mapPos + h2 * width2;
36426
36515
  for (let w2 = 0; w2 < colspan; w2++) {
36427
36516
  if (map2[start + w2] == 0)
36428
36517
  map2[start + w2] = pos;
@@ -36435,7 +36524,7 @@ function computeMap(table) {
36435
36524
  });
36436
36525
  const colW = colwidth && colwidth[w2];
36437
36526
  if (colW) {
36438
- const widthIndex = (start + w2) % width * 2, prev = colWidths[widthIndex];
36527
+ const widthIndex = (start + w2) % width2 * 2, prev = colWidths[widthIndex];
36439
36528
  if (prev == null || prev != colW && colWidths[widthIndex + 1] == 1) {
36440
36529
  colWidths[widthIndex] = colW;
36441
36530
  colWidths[widthIndex + 1] = 1;
@@ -36448,7 +36537,7 @@ function computeMap(table) {
36448
36537
  mapPos += colspan;
36449
36538
  pos += cellNode.nodeSize;
36450
36539
  }
36451
- const expectedPos = (row + 1) * width;
36540
+ const expectedPos = (row + 1) * width2;
36452
36541
  let missing = 0;
36453
36542
  while (mapPos < expectedPos)
36454
36543
  if (map2[mapPos++] == 0)
@@ -36457,9 +36546,9 @@ function computeMap(table) {
36457
36546
  (problems || (problems = [])).push({ type: "missing", row, n: missing });
36458
36547
  pos++;
36459
36548
  }
36460
- if (width === 0 || height === 0)
36549
+ if (width2 === 0 || height === 0)
36461
36550
  (problems || (problems = [])).push({ type: "zero_sized" });
36462
- const tableMap = new TableMap(width, height, map2, problems);
36551
+ const tableMap = new TableMap(width2, height, map2, problems);
36463
36552
  let badWidths = false;
36464
36553
  for (let i = 0; !badWidths && i < colWidths.length; i += 2)
36465
36554
  if (colWidths[i] != null && colWidths[i + 1] < height)
@@ -36469,7 +36558,7 @@ function computeMap(table) {
36469
36558
  return tableMap;
36470
36559
  }
36471
36560
  function findWidth(table) {
36472
- let width = -1;
36561
+ let width2 = -1;
36473
36562
  let hasRowSpan = false;
36474
36563
  for (let row = 0; row < table.childCount; row++) {
36475
36564
  const rowNode = table.child(row);
@@ -36489,12 +36578,12 @@ function findWidth(table) {
36489
36578
  if (cell.attrs.rowspan > 1)
36490
36579
  hasRowSpan = true;
36491
36580
  }
36492
- if (width == -1)
36493
- width = rowWidth;
36494
- else if (width != rowWidth)
36495
- width = Math.max(width, rowWidth);
36581
+ if (width2 == -1)
36582
+ width2 = rowWidth;
36583
+ else if (width2 != rowWidth)
36584
+ width2 = Math.max(width2, rowWidth);
36496
36585
  }
36497
- return width;
36586
+ return width2;
36498
36587
  }
36499
36588
  function findBadColWidths(map2, colWidths, table) {
36500
36589
  if (!map2.problems)
@@ -37285,17 +37374,17 @@ function isEmpty(cell) {
37285
37374
  const c2 = cell.content;
37286
37375
  return c2.childCount == 1 && c2.child(0).isTextblock && c2.child(0).childCount == 0;
37287
37376
  }
37288
- function cellsOverlapRectangle({ width, height, map: map2 }, rect) {
37289
- let indexTop = rect.top * width + rect.left, indexLeft = indexTop;
37290
- let indexBottom = (rect.bottom - 1) * width + rect.left, indexRight = indexTop + (rect.right - rect.left - 1);
37377
+ function cellsOverlapRectangle({ width: width2, height, map: map2 }, rect) {
37378
+ let indexTop = rect.top * width2 + rect.left, indexLeft = indexTop;
37379
+ let indexBottom = (rect.bottom - 1) * width2 + rect.left, indexRight = indexTop + (rect.right - rect.left - 1);
37291
37380
  for (let i = rect.top; i < rect.bottom; i++) {
37292
- if (rect.left > 0 && map2[indexLeft] == map2[indexLeft - 1] || rect.right < width && map2[indexRight] == map2[indexRight + 1])
37381
+ if (rect.left > 0 && map2[indexLeft] == map2[indexLeft - 1] || rect.right < width2 && map2[indexRight] == map2[indexRight + 1])
37293
37382
  return true;
37294
- indexLeft += width;
37295
- indexRight += width;
37383
+ indexLeft += width2;
37384
+ indexRight += width2;
37296
37385
  }
37297
37386
  for (let i = rect.left; i < rect.right; i++) {
37298
- if (rect.top > 0 && map2[indexTop] == map2[indexTop - width] || rect.bottom < height && map2[indexBottom] == map2[indexBottom + width])
37387
+ if (rect.top > 0 && map2[indexTop] == map2[indexTop - width2] || rect.bottom < height && map2[indexBottom] == map2[indexBottom + width2])
37299
37388
  return true;
37300
37389
  indexTop++;
37301
37390
  indexBottom++;
@@ -37592,11 +37681,11 @@ function findNextCell($cell, dir) {
37592
37681
  }
37593
37682
  return null;
37594
37683
  }
37595
- function goToNextCell(direction) {
37684
+ function goToNextCell(direction2) {
37596
37685
  return function(state, dispatch2) {
37597
37686
  if (!isInTable(state))
37598
37687
  return false;
37599
- const cell = findNextCell(selectionCell(state), direction);
37688
+ const cell = findNextCell(selectionCell(state), direction2);
37600
37689
  if (cell == null)
37601
37690
  return false;
37602
37691
  if (dispatch2) {
@@ -37688,30 +37777,30 @@ function ensureRectangular(schema, rows) {
37688
37777
  widths[r2] = (widths[r2] || 0) + colspan;
37689
37778
  }
37690
37779
  }
37691
- let width = 0;
37780
+ let width2 = 0;
37692
37781
  for (let r2 = 0; r2 < widths.length; r2++)
37693
- width = Math.max(width, widths[r2]);
37782
+ width2 = Math.max(width2, widths[r2]);
37694
37783
  for (let r2 = 0; r2 < widths.length; r2++) {
37695
37784
  if (r2 >= rows.length)
37696
37785
  rows.push(Fragment8.empty);
37697
- if (widths[r2] < width) {
37786
+ if (widths[r2] < width2) {
37698
37787
  const empty2 = tableNodeTypes(schema).cell.createAndFill();
37699
37788
  const cells = [];
37700
- for (let i = widths[r2]; i < width; i++) {
37789
+ for (let i = widths[r2]; i < width2; i++) {
37701
37790
  cells.push(empty2);
37702
37791
  }
37703
37792
  rows[r2] = rows[r2].append(Fragment8.from(cells));
37704
37793
  }
37705
37794
  }
37706
- return { height: rows.length, width, rows };
37795
+ return { height: rows.length, width: width2, rows };
37707
37796
  }
37708
37797
  function fitSlice(nodeType, slice2) {
37709
37798
  const node = nodeType.createAndFill();
37710
37799
  const tr2 = new Transform(node).replace(0, node.content.size, slice2);
37711
37800
  return tr2.doc;
37712
37801
  }
37713
- function clipCells({ width, height, rows }, newWidth, newHeight) {
37714
- if (width != newWidth) {
37802
+ function clipCells({ width: width2, height, rows }, newWidth, newHeight) {
37803
+ if (width2 != newWidth) {
37715
37804
  const added = [];
37716
37805
  const newRows = [];
37717
37806
  for (let row = 0; row < rows.length; row++) {
@@ -37735,7 +37824,7 @@ function clipCells({ width, height, rows }, newWidth, newHeight) {
37735
37824
  newRows.push(Fragment8.from(cells));
37736
37825
  }
37737
37826
  rows = newRows;
37738
- width = newWidth;
37827
+ width2 = newWidth;
37739
37828
  }
37740
37829
  if (height != newHeight) {
37741
37830
  const newRows = [];
@@ -37758,14 +37847,14 @@ function clipCells({ width, height, rows }, newWidth, newHeight) {
37758
37847
  rows = newRows;
37759
37848
  height = newHeight;
37760
37849
  }
37761
- return { width, height, rows };
37850
+ return { width: width2, height, rows };
37762
37851
  }
37763
- function growTable(tr2, map2, table, start, width, height, mapFrom) {
37852
+ function growTable(tr2, map2, table, start, width2, height, mapFrom) {
37764
37853
  const schema = tr2.doc.type.schema;
37765
37854
  const types = tableNodeTypes(schema);
37766
37855
  let empty2;
37767
37856
  let emptyHead;
37768
- if (width > map2.width) {
37857
+ if (width2 > map2.width) {
37769
37858
  for (let row = 0, rowEnd = 0; row < map2.height; row++) {
37770
37859
  const rowNode = table.child(row);
37771
37860
  rowEnd += rowNode.nodeSize;
@@ -37775,14 +37864,14 @@ function growTable(tr2, map2, table, start, width, height, mapFrom) {
37775
37864
  add = empty2 || (empty2 = types.cell.createAndFill());
37776
37865
  else
37777
37866
  add = emptyHead || (emptyHead = types.header_cell.createAndFill());
37778
- for (let i = map2.width; i < width; i++)
37867
+ for (let i = map2.width; i < width2; i++)
37779
37868
  cells.push(add);
37780
37869
  tr2.insert(tr2.mapping.slice(mapFrom).map(rowEnd - 1 + start), cells);
37781
37870
  }
37782
37871
  }
37783
37872
  if (height > map2.height) {
37784
37873
  const cells = [];
37785
- for (let i = 0, start2 = (map2.height - 1) * map2.width; i < Math.max(map2.width, width); i++) {
37874
+ for (let i = 0, start2 = (map2.height - 1) * map2.width; i < Math.max(map2.width, width2); i++) {
37786
37875
  const header = i >= map2.width ? false : table.nodeAt(map2.map[start2 + i]).type == types.header_cell;
37787
37876
  cells.push(
37788
37877
  header ? emptyHead || (emptyHead = types.header_cell.createAndFill()) : empty2 || (empty2 = types.cell.createAndFill())
@@ -38312,10 +38401,10 @@ function handleMouseDown2(view, event, cellMinWidth, defaultCellMinWidth) {
38312
38401
  if (!pluginState || pluginState.activeHandle == -1 || pluginState.dragging)
38313
38402
  return false;
38314
38403
  const cell = view.state.doc.nodeAt(pluginState.activeHandle);
38315
- const width = currentColWidth(view, pluginState.activeHandle, cell.attrs);
38404
+ const width2 = currentColWidth(view, pluginState.activeHandle, cell.attrs);
38316
38405
  view.dispatch(
38317
38406
  view.state.tr.setMeta(columnResizingPluginKey, {
38318
- setDragging: { startX: event.clientX, startWidth: width }
38407
+ setDragging: { startX: event.clientX, startWidth: width2 }
38319
38408
  })
38320
38409
  );
38321
38410
  function finish(event2) {
@@ -38352,7 +38441,7 @@ function handleMouseDown2(view, event, cellMinWidth, defaultCellMinWidth) {
38352
38441
  displayColumnWidth(
38353
38442
  view,
38354
38443
  pluginState.activeHandle,
38355
- width,
38444
+ width2,
38356
38445
  defaultCellMinWidth
38357
38446
  );
38358
38447
  win.addEventListener("mouseup", finish);
@@ -38361,9 +38450,9 @@ function handleMouseDown2(view, event, cellMinWidth, defaultCellMinWidth) {
38361
38450
  return true;
38362
38451
  }
38363
38452
  function currentColWidth(view, cellPos, { colspan, colwidth }) {
38364
- const width = colwidth && colwidth[colwidth.length - 1];
38365
- if (width)
38366
- return width;
38453
+ const width2 = colwidth && colwidth[colwidth.length - 1];
38454
+ if (width2)
38455
+ return width2;
38367
38456
  const dom = view.domAtPos(cellPos);
38368
38457
  const node = dom.node.childNodes[dom.offset];
38369
38458
  let domWidth = node.offsetWidth, parts = colspan;
@@ -38408,7 +38497,7 @@ function updateHandle(view, value) {
38408
38497
  view.state.tr.setMeta(columnResizingPluginKey, { setHandle: value })
38409
38498
  );
38410
38499
  }
38411
- function updateColumnWidth(view, cell, width) {
38500
+ function updateColumnWidth(view, cell, width2) {
38412
38501
  const $cell = view.state.doc.resolve(cell);
38413
38502
  const table = $cell.node(-1), map2 = TableMap.get(table), start = $cell.start(-1);
38414
38503
  const col = map2.colCount($cell.pos - start) + $cell.nodeAfter.attrs.colspan - 1;
@@ -38420,16 +38509,16 @@ function updateColumnWidth(view, cell, width) {
38420
38509
  const pos = map2.map[mapIndex];
38421
38510
  const attrs = table.nodeAt(pos).attrs;
38422
38511
  const index2 = attrs.colspan == 1 ? 0 : col - map2.colCount(pos);
38423
- if (attrs.colwidth && attrs.colwidth[index2] == width)
38512
+ if (attrs.colwidth && attrs.colwidth[index2] == width2)
38424
38513
  continue;
38425
38514
  const colwidth = attrs.colwidth ? attrs.colwidth.slice() : zeroes(attrs.colspan);
38426
- colwidth[index2] = width;
38515
+ colwidth[index2] = width2;
38427
38516
  tr2.setNodeMarkup(start + pos, null, { ...attrs, colwidth });
38428
38517
  }
38429
38518
  if (tr2.docChanged)
38430
38519
  view.dispatch(tr2);
38431
38520
  }
38432
- function displayColumnWidth(view, cell, width, defaultCellMinWidth) {
38521
+ function displayColumnWidth(view, cell, width2, defaultCellMinWidth) {
38433
38522
  const $cell = view.state.doc.resolve(cell);
38434
38523
  const table = $cell.node(-1), start = $cell.start(-1);
38435
38524
  const col = TableMap.get(table).colCount($cell.pos - start) + $cell.nodeAfter.attrs.colspan - 1;
@@ -38445,7 +38534,7 @@ function displayColumnWidth(view, cell, width, defaultCellMinWidth) {
38445
38534
  dom,
38446
38535
  defaultCellMinWidth,
38447
38536
  col,
38448
- width
38537
+ width2
38449
38538
  );
38450
38539
  }
38451
38540
  function zeroes(n) {
@@ -38550,7 +38639,7 @@ var TableCell = Node3.create({
38550
38639
  default: null,
38551
38640
  parseHTML: (element) => {
38552
38641
  const colwidth = element.getAttribute("colwidth");
38553
- const value = colwidth ? colwidth.split(",").map((width) => parseInt(width, 10)) : null;
38642
+ const value = colwidth ? colwidth.split(",").map((width2) => parseInt(width2, 10)) : null;
38554
38643
  return value;
38555
38644
  }
38556
38645
  }
@@ -38585,7 +38674,7 @@ var TableHeader = Node3.create({
38585
38674
  default: null,
38586
38675
  parseHTML: (element) => {
38587
38676
  const colwidth = element.getAttribute("colwidth");
38588
- const value = colwidth ? colwidth.split(",").map((width) => parseInt(width, 10)) : null;
38677
+ const value = colwidth ? colwidth.split(",").map((width2) => parseInt(width2, 10)) : null;
38589
38678
  return value;
38590
38679
  }
38591
38680
  }
@@ -38616,9 +38705,9 @@ var TableRow = Node3.create({
38616
38705
  return ["tr", mergeAttributes(this.options.HTMLAttributes, HTMLAttributes), 0];
38617
38706
  }
38618
38707
  });
38619
- function getColStyleDeclaration(minWidth, width) {
38620
- if (width) {
38621
- return ["width", `${Math.max(width, minWidth)}px`];
38708
+ function getColStyleDeclaration(minWidth, width2) {
38709
+ if (width2) {
38710
+ return ["width", `${Math.max(width2, minWidth)}px`];
38622
38711
  }
38623
38712
  return ["min-width", `${minWidth}px`];
38624
38713
  }
@@ -54340,10 +54429,10 @@ function RichTextEditor({
54340
54429
  setIsTableDialogOpen(false);
54341
54430
  }
54342
54431
  };
54343
- const applyTableBorders = (width, color, style2) => {
54432
+ const applyTableBorders = (width2, color, style2) => {
54344
54433
  if (!editor)
54345
54434
  return;
54346
- const borderStyle = `${width}px ${style2} ${color}`;
54435
+ const borderStyle = `${width2}px ${style2} ${color}`;
54347
54436
  editor.view.dom.querySelectorAll(".ProseMirror table").forEach((table) => {
54348
54437
  if (table instanceof HTMLElement) {
54349
54438
  table.style.borderCollapse = "collapse";
@@ -55560,6 +55649,8 @@ function RichTextEditor({
55560
55649
  var MemoryCache = class {
55561
55650
  constructor(maxSize, strategy = "lru") {
55562
55651
  this.cache = /* @__PURE__ */ new Map();
55652
+ this.hitCount = 0;
55653
+ this.missCount = 0;
55563
55654
  this.maxSize = maxSize;
55564
55655
  this.strategy = strategy;
55565
55656
  }
@@ -55574,14 +55665,6 @@ var MemoryCache = class {
55574
55665
  compressed
55575
55666
  });
55576
55667
  }
55577
- get(key) {
55578
- const node = this.cache.get(key);
55579
- if (!node)
55580
- return null;
55581
- node.accessCount++;
55582
- node.timestamp = Date.now();
55583
- return node.data;
55584
- }
55585
55668
  evict() {
55586
55669
  if (this.cache.size === 0)
55587
55670
  return;
@@ -55617,12 +55700,131 @@ var MemoryCache = class {
55617
55700
  this.cache.clear();
55618
55701
  }
55619
55702
  getStats() {
55703
+ let totalMemory = 0;
55704
+ for (const [, node] of this.cache) {
55705
+ totalMemory += JSON.stringify(node.data).length * 2;
55706
+ }
55620
55707
  return {
55621
55708
  size: this.cache.size,
55622
- hitRate: 0.95
55623
- // Basit bir mock değer
55709
+ hitRate: this.calculateHitRate(),
55710
+ memoryUsage: totalMemory
55624
55711
  };
55625
55712
  }
55713
+ calculateHitRate() {
55714
+ const total = this.hitCount + this.missCount;
55715
+ return total === 0 ? 0 : this.hitCount / total;
55716
+ }
55717
+ // Hit/miss tracking için güncelle
55718
+ get(key) {
55719
+ const node = this.cache.get(key);
55720
+ if (!node) {
55721
+ this.missCount++;
55722
+ return null;
55723
+ }
55724
+ this.hitCount++;
55725
+ node.accessCount++;
55726
+ node.timestamp = Date.now();
55727
+ return node.data;
55728
+ }
55729
+ };
55730
+ var PerformanceTracker = class {
55731
+ constructor() {
55732
+ this.frames = [];
55733
+ this.renderTimes = [];
55734
+ this.startTime = 0;
55735
+ this.lastFrameTime = 0;
55736
+ }
55737
+ startRender() {
55738
+ this.startTime = performance.now();
55739
+ }
55740
+ endRender() {
55741
+ const renderTime = performance.now() - this.startTime;
55742
+ this.renderTimes.push(renderTime);
55743
+ if (this.renderTimes.length > 60) {
55744
+ this.renderTimes.shift();
55745
+ }
55746
+ }
55747
+ recordFrame() {
55748
+ const now = performance.now();
55749
+ if (this.lastFrameTime > 0) {
55750
+ const fps = 1e3 / (now - this.lastFrameTime);
55751
+ this.frames.push(fps);
55752
+ if (this.frames.length > 60) {
55753
+ this.frames.shift();
55754
+ }
55755
+ }
55756
+ this.lastFrameTime = now;
55757
+ }
55758
+ getMetrics() {
55759
+ const avgFPS = this.frames.length > 0 ? this.frames.reduce((a, b) => a + b, 0) / this.frames.length : 0;
55760
+ const avgRenderTime = this.renderTimes.length > 0 ? this.renderTimes.reduce((a, b) => a + b, 0) / this.renderTimes.length : 0;
55761
+ return {
55762
+ fps: Math.round(avgFPS),
55763
+ renderTime: Math.round(avgRenderTime * 100) / 100,
55764
+ memoryLeaks: this.detectMemoryLeaks(),
55765
+ scrollPerformance: this.calculateScrollPerformance(),
55766
+ lastUpdate: Date.now()
55767
+ };
55768
+ }
55769
+ detectMemoryLeaks() {
55770
+ return this.renderTimes.filter((time) => time > 16).length;
55771
+ }
55772
+ calculateScrollPerformance() {
55773
+ const avgFPS = this.frames.length > 0 ? this.frames.reduce((a, b) => a + b, 0) / this.frames.length : 60;
55774
+ return Math.min(100, Math.max(0, avgFPS / 60 * 100));
55775
+ }
55776
+ };
55777
+ var VariableHeightManager = class {
55778
+ constructor(defaultHeight = 60) {
55779
+ this.heights = /* @__PURE__ */ new Map();
55780
+ this.totalHeight = 0;
55781
+ this.measuredCount = 0;
55782
+ this.defaultHeight = defaultHeight;
55783
+ }
55784
+ setItemHeight(index2, height) {
55785
+ const oldHeight = this.heights.get(index2) || this.defaultHeight;
55786
+ this.heights.set(index2, height);
55787
+ if (!this.heights.has(index2)) {
55788
+ this.measuredCount++;
55789
+ }
55790
+ this.totalHeight += height - oldHeight;
55791
+ }
55792
+ getItemHeight(index2) {
55793
+ return this.heights.get(index2) || this.defaultHeight;
55794
+ }
55795
+ getOffsetForIndex(index2) {
55796
+ let offset4 = 0;
55797
+ for (let i = 0; i < index2; i++) {
55798
+ offset4 += this.getItemHeight(i);
55799
+ }
55800
+ return offset4;
55801
+ }
55802
+ getTotalHeight(itemCount) {
55803
+ if (this.measuredCount === 0) {
55804
+ return itemCount * this.defaultHeight;
55805
+ }
55806
+ const measuredHeight = Array.from(this.heights.values()).reduce((sum, height) => sum + height, 0);
55807
+ const averageHeight = measuredHeight / this.measuredCount;
55808
+ const unmeasuredCount = itemCount - this.measuredCount;
55809
+ return measuredHeight + unmeasuredCount * averageHeight;
55810
+ }
55811
+ getVisibleRange(scrollTop, containerHeight, itemCount) {
55812
+ let start = 0;
55813
+ let currentOffset = 0;
55814
+ while (start < itemCount && currentOffset < scrollTop) {
55815
+ currentOffset += this.getItemHeight(start);
55816
+ start++;
55817
+ }
55818
+ start = Math.max(0, start - 1);
55819
+ let end = start;
55820
+ const targetOffset = scrollTop + containerHeight;
55821
+ currentOffset = this.getOffsetForIndex(start);
55822
+ while (end < itemCount && currentOffset < targetOffset) {
55823
+ currentOffset += this.getItemHeight(end);
55824
+ end++;
55825
+ }
55826
+ return { start, end: Math.min(itemCount, end + 1) };
55827
+ }
55626
55828
  };
55627
55829
  function MemoryEfficientData({
55628
55830
  data,
@@ -55630,7 +55832,17 @@ function MemoryEfficientData({
55630
55832
  renderItem,
55631
55833
  height = 400,
55632
55834
  onMemoryUpdate,
55633
- className
55835
+ className,
55836
+ // Yeni props
55837
+ itemHeight = 60,
55838
+ onSearch,
55839
+ onSort,
55840
+ onFilter,
55841
+ onExport,
55842
+ searchPlaceholder = "Ara...",
55843
+ emptyStateMessage = "Veri bulunamad\u0131",
55844
+ loadingComponent,
55845
+ errorComponent
55634
55846
  }) {
55635
55847
  const {
55636
55848
  chunkSize = 1e3,
@@ -55641,7 +55853,16 @@ function MemoryEfficientData({
55641
55853
  cleanupThreshold = 0.8,
55642
55854
  streamingMode = false,
55643
55855
  enableAnalytics = false,
55644
- analyticsCallback
55856
+ analyticsCallback,
55857
+ // Yeni konfigürasyonlar
55858
+ variableHeight = false,
55859
+ preloadStrategy = "smart",
55860
+ performanceTracking = false,
55861
+ enableSearch = false,
55862
+ enableSort = false,
55863
+ enableFilter = false,
55864
+ enableExport = false,
55865
+ animations: animations2 = true
55645
55866
  } = config;
55646
55867
  const [visibleRange, setVisibleRange] = useState({ start: 0, end: Math.min(chunkSize, data.length) });
55647
55868
  const [memoryStats, setMemoryStats] = useState({
@@ -55649,46 +55870,145 @@ function MemoryEfficientData({
55649
55870
  itemCount: 0,
55650
55871
  cacheHitRate: 0.95
55651
55872
  });
55873
+ const [tableFeatures, setTableFeatures] = useState({
55874
+ searchTerm: "",
55875
+ sortConfig: void 0,
55876
+ filters: []
55877
+ });
55878
+ const [isLoading, setIsLoading] = useState(false);
55879
+ const [error, setError] = useState(null);
55652
55880
  const containerRef = useRef(null);
55653
55881
  const cacheRef = useRef(new MemoryCache(Math.floor(maxMemoryItems / chunkSize), cacheStrategy));
55654
55882
  const scrollTimeoutRef = useRef(void 0);
55883
+ const performanceTrackerRef = useRef(new PerformanceTracker());
55884
+ const heightManagerRef = useRef(new VariableHeightManager(typeof itemHeight === "number" ? itemHeight : 60));
55885
+ const itemRefs = useRef(/* @__PURE__ */ new Map());
55886
+ const processedData = useMemo(() => {
55887
+ let result = [...data];
55888
+ try {
55889
+ setIsLoading(true);
55890
+ if (enableSearch && tableFeatures.searchTerm && onSearch) {
55891
+ result = onSearch(tableFeatures.searchTerm);
55892
+ }
55893
+ if (enableFilter && tableFeatures.filters && tableFeatures.filters.length > 0 && onFilter) {
55894
+ result = onFilter(result, tableFeatures.filters);
55895
+ }
55896
+ if (enableSort && tableFeatures.sortConfig && onSort) {
55897
+ result = onSort(result, tableFeatures.sortConfig.key, tableFeatures.sortConfig.direction);
55898
+ }
55899
+ setError(null);
55900
+ return result;
55901
+ } catch (err) {
55902
+ setError(err instanceof Error ? err.message : "Veri i\u015Flenirken hata olu\u015Ftu");
55903
+ return data;
55904
+ } finally {
55905
+ setIsLoading(false);
55906
+ }
55907
+ }, [data, tableFeatures, enableSearch, enableFilter, enableSort, onSearch, onFilter, onSort]);
55655
55908
  const visibleData = useMemo(() => {
55909
+ if (performanceTracking) {
55910
+ performanceTrackerRef.current.startRender();
55911
+ }
55656
55912
  const start = visibleRange.start;
55657
- const end = Math.min(visibleRange.end, data.length);
55658
- const cacheKey = `${start}-${end}`;
55913
+ const end = Math.min(visibleRange.end, processedData.length);
55914
+ const cacheKey = `${start}-${end}-${JSON.stringify(tableFeatures)}`;
55659
55915
  const cachedData = cacheRef.current.get(cacheKey);
55660
55916
  if (cachedData && cachedData.length === end - start) {
55917
+ if (performanceTracking) {
55918
+ performanceTrackerRef.current.endRender();
55919
+ }
55661
55920
  return cachedData;
55662
55921
  }
55663
- const newData = data.slice(start, end);
55922
+ const newData = processedData.slice(start, end);
55664
55923
  cacheRef.current.set(cacheKey, newData, compression);
55924
+ if (performanceTracking) {
55925
+ performanceTrackerRef.current.endRender();
55926
+ }
55665
55927
  return newData;
55666
- }, [data, visibleRange, compression]);
55928
+ }, [processedData, visibleRange, compression, tableFeatures, performanceTracking]);
55929
+ const measureItemHeight = useCallback((index2, element) => {
55930
+ if (!variableHeight)
55931
+ return;
55932
+ const height2 = element.getBoundingClientRect().height;
55933
+ heightManagerRef.current.setItemHeight(index2, height2);
55934
+ const oldHeight = heightManagerRef.current.getItemHeight(index2);
55935
+ if (Math.abs(height2 - oldHeight) > 5) {
55936
+ const container = containerRef.current;
55937
+ if (container) {
55938
+ handleScroll({ currentTarget: container });
55939
+ }
55940
+ }
55941
+ }, [variableHeight]);
55667
55942
  const handleScroll = useCallback((e) => {
55943
+ if (performanceTracking) {
55944
+ performanceTrackerRef.current.recordFrame();
55945
+ }
55668
55946
  const scrollTop = e.currentTarget.scrollTop;
55669
55947
  const containerHeight = e.currentTarget.clientHeight;
55670
- const estimatedItemHeight = 60;
55671
- const startIndex = Math.floor(scrollTop / estimatedItemHeight);
55672
- const visibleCount = Math.ceil(containerHeight / estimatedItemHeight);
55673
- const bufferSize = Math.floor(visibleCount * 0.5);
55674
- const newStart = Math.max(0, startIndex - bufferSize);
55675
- const newEnd = Math.min(data.length, startIndex + visibleCount + bufferSize);
55948
+ let newStart, newEnd;
55949
+ if (variableHeight) {
55950
+ const range = heightManagerRef.current.getVisibleRange(scrollTop, containerHeight, processedData.length);
55951
+ newStart = range.start;
55952
+ newEnd = range.end;
55953
+ } else {
55954
+ const itemHeightValue = typeof itemHeight === "number" ? itemHeight : 60;
55955
+ const startIndex = Math.floor(scrollTop / itemHeightValue);
55956
+ const visibleCount = Math.ceil(containerHeight / itemHeightValue);
55957
+ const bufferSize = Math.floor(visibleCount * 0.5);
55958
+ newStart = Math.max(0, startIndex - bufferSize);
55959
+ newEnd = Math.min(processedData.length, startIndex + visibleCount + bufferSize);
55960
+ }
55961
+ if (preloadStrategy === "aggressive") {
55962
+ const extraBuffer = Math.floor((newEnd - newStart) * 0.5);
55963
+ newStart = Math.max(0, newStart - extraBuffer);
55964
+ newEnd = Math.min(processedData.length, newEnd + extraBuffer);
55965
+ } else if (preloadStrategy === "smart") {
55966
+ const currentScroll = scrollTop;
55967
+ const lastScroll = scrollTimeoutRef.current ? parseInt(scrollTimeoutRef.current) : 0;
55968
+ const isScrollingDown = currentScroll > lastScroll;
55969
+ if (isScrollingDown) {
55970
+ newEnd = Math.min(processedData.length, newEnd + Math.floor((newEnd - newStart) * 0.2));
55971
+ } else {
55972
+ newStart = Math.max(0, newStart - Math.floor((newEnd - newStart) * 0.2));
55973
+ }
55974
+ }
55676
55975
  if (scrollTimeoutRef.current) {
55677
55976
  clearTimeout(scrollTimeoutRef.current);
55678
55977
  }
55679
55978
  scrollTimeoutRef.current = setTimeout(() => {
55680
55979
  setVisibleRange({ start: newStart, end: newEnd });
55681
55980
  }, 16);
55682
- }, [data.length]);
55981
+ }, [processedData.length, variableHeight, itemHeight, preloadStrategy, performanceTracking]);
55982
+ const handleSearch = useCallback((searchTerm) => {
55983
+ setTableFeatures((prev) => ({ ...prev, searchTerm }));
55984
+ }, []);
55985
+ useCallback((key) => {
55986
+ setTableFeatures((prev) => {
55987
+ const currentDirection = prev.sortConfig?.key === key && prev.sortConfig?.direction === "asc" ? "desc" : "asc";
55988
+ return {
55989
+ ...prev,
55990
+ sortConfig: { key, direction: currentDirection }
55991
+ };
55992
+ });
55993
+ }, []);
55994
+ useCallback((filters) => {
55995
+ setTableFeatures((prev) => ({ ...prev, filters }));
55996
+ }, []);
55997
+ const handleExport = useCallback((format7) => {
55998
+ if (onExport) {
55999
+ onExport(processedData, format7);
56000
+ }
56001
+ }, [processedData, onExport]);
55683
56002
  useEffect(() => {
55684
56003
  const cacheStats = cacheRef.current.getStats();
56004
+ const performanceMetrics = performanceTracking ? performanceTrackerRef.current.getMetrics() : void 0;
55685
56005
  const newStats = {
55686
- memoryUsage: visibleData.length * 1024,
55687
- // Rough estimation
56006
+ memoryUsage: cacheStats.memoryUsage,
55688
56007
  itemCount: visibleData.length,
55689
56008
  cacheHitRate: cacheStats.hitRate,
55690
56009
  compressionRatio: compression ? 0.7 : 1,
55691
- lastCleanup: Date.now()
56010
+ lastCleanup: Date.now(),
56011
+ performance: performanceMetrics
55692
56012
  };
55693
56013
  setMemoryStats(newStats);
55694
56014
  if (enableAnalytics && analyticsCallback) {
@@ -55697,7 +56017,7 @@ function MemoryEfficientData({
55697
56017
  if (onMemoryUpdate) {
55698
56018
  onMemoryUpdate(newStats);
55699
56019
  }
55700
- }, [visibleData, enableAnalytics, analyticsCallback, onMemoryUpdate, compression]);
56020
+ }, [visibleData, enableAnalytics, analyticsCallback, onMemoryUpdate, compression, performanceTracking]);
55701
56021
  useEffect(() => {
55702
56022
  if (!autoCleanup)
55703
56023
  return;
@@ -55709,27 +56029,281 @@ function MemoryEfficientData({
55709
56029
  }, 5e3);
55710
56030
  return () => clearInterval(cleanupInterval);
55711
56031
  }, [autoCleanup, cleanupThreshold, maxMemoryItems, visibleData.length]);
55712
- return /* @__PURE__ */ jsx(
55713
- "div",
56032
+ if (error && errorComponent) {
56033
+ return errorComponent;
56034
+ }
56035
+ if (isLoading && loadingComponent) {
56036
+ return loadingComponent;
56037
+ }
56038
+ const totalHeight = variableHeight ? heightManagerRef.current.getTotalHeight(processedData.length) : processedData.length * (typeof itemHeight === "number" ? itemHeight : 60);
56039
+ const offsetY = variableHeight ? heightManagerRef.current.getOffsetForIndex(visibleRange.start) : visibleRange.start * (typeof itemHeight === "number" ? itemHeight : 60);
56040
+ return /* @__PURE__ */ jsxs("div", { className: cn("flex flex-col", className), children: [
56041
+ (enableSearch || enableSort || enableFilter || enableExport) && /* @__PURE__ */ jsxs(
56042
+ motion.div,
56043
+ {
56044
+ className: "flex items-center gap-2 p-3 border-b bg-muted/5",
56045
+ initial: animations2 ? { opacity: 0, y: -10 } : {},
56046
+ animate: animations2 ? { opacity: 1, y: 0 } : {},
56047
+ transition: { duration: 0.2 },
56048
+ children: [
56049
+ enableSearch && /* @__PURE__ */ jsxs("div", { className: "relative flex-1 max-w-sm", children: [
56050
+ /* @__PURE__ */ jsx(Search, { className: "absolute left-3 top-1/2 transform -translate-y-1/2 h-4 w-4 text-muted-foreground" }),
56051
+ /* @__PURE__ */ jsx(
56052
+ "input",
56053
+ {
56054
+ type: "text",
56055
+ placeholder: searchPlaceholder,
56056
+ value: tableFeatures.searchTerm,
56057
+ onChange: (e) => handleSearch(e.target.value),
56058
+ className: "w-full pl-10 pr-4 py-2 border rounded-md bg-background text-sm focus:outline-none focus:ring-2 focus:ring-primary/20 focus:border-primary"
56059
+ }
56060
+ )
56061
+ ] }),
56062
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-1", children: [
56063
+ enableFilter && /* @__PURE__ */ jsx(
56064
+ "button",
56065
+ {
56066
+ onClick: () => {
56067
+ },
56068
+ className: "p-2 hover:bg-muted rounded-md transition-colors",
56069
+ title: "Filtrele",
56070
+ children: /* @__PURE__ */ jsx(Filter, { className: "h-4 w-4" })
56071
+ }
56072
+ ),
56073
+ enableExport && /* @__PURE__ */ jsx("div", { className: "relative", children: /* @__PURE__ */ jsx(
56074
+ "button",
56075
+ {
56076
+ onClick: () => handleExport("csv"),
56077
+ className: "p-2 hover:bg-muted rounded-md transition-colors",
56078
+ title: "D\u0131\u015Fa Aktar",
56079
+ children: /* @__PURE__ */ jsx(Download, { className: "h-4 w-4" })
56080
+ }
56081
+ ) })
56082
+ ] })
56083
+ ]
56084
+ }
56085
+ ),
56086
+ /* @__PURE__ */ jsx(
56087
+ "div",
56088
+ {
56089
+ ref: containerRef,
56090
+ className: "overflow-auto border rounded-lg bg-background",
56091
+ style: { height: typeof height === "number" ? height - (enableSearch || enableSort || enableFilter || enableExport ? 60 : 0) : height },
56092
+ onScroll: handleScroll,
56093
+ children: processedData.length === 0 ? /* @__PURE__ */ jsx(
56094
+ motion.div,
56095
+ {
56096
+ className: "flex items-center justify-center h-full text-muted-foreground",
56097
+ initial: animations2 ? { opacity: 0 } : {},
56098
+ animate: animations2 ? { opacity: 1 } : {},
56099
+ children: emptyStateMessage
56100
+ }
56101
+ ) : /* @__PURE__ */ jsx("div", { style: { height: totalHeight, position: "relative" }, children: /* @__PURE__ */ jsx(
56102
+ motion.div,
56103
+ {
56104
+ style: {
56105
+ transform: `translateY(${offsetY}px)`,
56106
+ position: "absolute",
56107
+ width: "100%"
56108
+ },
56109
+ animate: animations2 ? { y: offsetY } : {},
56110
+ transition: animations2 ? { duration: 0.1, ease: "linear" } : {},
56111
+ children: /* @__PURE__ */ jsx(AnimatePresence, { mode: "popLayout", children: visibleData.map((item, index2) => {
56112
+ const globalIndex = visibleRange.start + index2;
56113
+ const itemHeightValue = typeof itemHeight === "function" ? itemHeight(item, globalIndex) : typeof itemHeight === "number" ? itemHeight : 60;
56114
+ return /* @__PURE__ */ jsx(
56115
+ motion.div,
56116
+ {
56117
+ ref: (el) => {
56118
+ if (el && variableHeight) {
56119
+ itemRefs.current.set(globalIndex, el);
56120
+ measureItemHeight(globalIndex, el);
56121
+ }
56122
+ },
56123
+ style: variableHeight ? {} : { height: itemHeightValue },
56124
+ initial: animations2 ? { opacity: 0, y: 20 } : {},
56125
+ animate: animations2 ? { opacity: 1, y: 0 } : {},
56126
+ exit: animations2 ? { opacity: 0, y: -20 } : {},
56127
+ transition: animations2 ? { duration: 0.2 } : {},
56128
+ layout: animations2,
56129
+ children: renderItem(item, globalIndex)
56130
+ },
56131
+ globalIndex
56132
+ );
56133
+ }) })
56134
+ }
56135
+ ) })
56136
+ }
56137
+ ),
56138
+ performanceTracking && memoryStats.performance && /* @__PURE__ */ jsxs("div", { className: "p-2 border-t bg-muted/5 text-xs text-muted-foreground flex items-center gap-4", children: [
56139
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-1", children: [
56140
+ /* @__PURE__ */ jsx(Zap, { className: "h-3 w-3" }),
56141
+ /* @__PURE__ */ jsxs("span", { children: [
56142
+ "FPS: ",
56143
+ memoryStats.performance.fps
56144
+ ] })
56145
+ ] }),
56146
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-1", children: [
56147
+ /* @__PURE__ */ jsx(Clock, { className: "h-3 w-3" }),
56148
+ /* @__PURE__ */ jsxs("span", { children: [
56149
+ "Render: ",
56150
+ memoryStats.performance.renderTime,
56151
+ "ms"
56152
+ ] })
56153
+ ] }),
56154
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-1", children: [
56155
+ /* @__PURE__ */ jsx(Cpu, { className: "h-3 w-3" }),
56156
+ /* @__PURE__ */ jsxs("span", { children: [
56157
+ "Scroll: ",
56158
+ memoryStats.performance.scrollPerformance,
56159
+ "%"
56160
+ ] })
56161
+ ] }),
56162
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-1", children: [
56163
+ /* @__PURE__ */ jsx(BarChart3, { className: "h-3 w-3" }),
56164
+ /* @__PURE__ */ jsxs("span", { children: [
56165
+ "Cache: ",
56166
+ Math.round(memoryStats.cacheHitRate * 100),
56167
+ "%"
56168
+ ] })
56169
+ ] })
56170
+ ] })
56171
+ ] });
56172
+ }
56173
+ function RealTimePerformanceMonitor({
56174
+ memoryStats,
56175
+ className,
56176
+ showChart = false,
56177
+ updateInterval = 1e3
56178
+ }) {
56179
+ const [history2, setHistory] = useState([]);
56180
+ const [isActive2, setIsActive] = useState(true);
56181
+ useEffect(() => {
56182
+ if (!memoryStats || !isActive2)
56183
+ return;
56184
+ setHistory((prev) => {
56185
+ const newHistory = [...prev, memoryStats];
56186
+ return newHistory.length > 60 ? newHistory.slice(-60) : newHistory;
56187
+ });
56188
+ }, [memoryStats, isActive2]);
56189
+ const formatBytes = (bytes) => {
56190
+ if (bytes === 0)
56191
+ return "0 Bytes";
56192
+ const k3 = 1024;
56193
+ const sizes = ["Bytes", "KB", "MB", "GB"];
56194
+ const i = Math.floor(Math.log(bytes) / Math.log(k3));
56195
+ return parseFloat((bytes / Math.pow(k3, i)).toFixed(2)) + " " + sizes[i];
56196
+ };
56197
+ const getPerformanceColor = (value, threshold) => {
56198
+ if (value >= threshold.good)
56199
+ return "text-green-500";
56200
+ if (value >= threshold.warning)
56201
+ return "text-yellow-500";
56202
+ return "text-red-500";
56203
+ };
56204
+ if (!memoryStats) {
56205
+ return /* @__PURE__ */ jsx("div", { className: cn("p-4 border rounded-lg bg-muted/5", className), children: /* @__PURE__ */ jsx("div", { className: "text-center text-muted-foreground", children: "Performance monitoring devre d\u0131\u015F\u0131" }) });
56206
+ }
56207
+ return /* @__PURE__ */ jsxs(
56208
+ motion.div,
55714
56209
  {
55715
- ref: containerRef,
55716
- className: cn(
55717
- "overflow-auto border rounded-lg bg-background",
55718
- className
55719
- ),
55720
- style: { height },
55721
- onScroll: handleScroll,
55722
- children: /* @__PURE__ */ jsx("div", { style: { height: data.length * 60, position: "relative" }, children: /* @__PURE__ */ jsx(
55723
- "div",
55724
- {
55725
- style: {
55726
- transform: `translateY(${visibleRange.start * 60}px)`,
55727
- position: "absolute",
55728
- width: "100%"
55729
- },
55730
- children: visibleData.map((item, index2) => /* @__PURE__ */ jsx(t__default.Fragment, { children: renderItem(item, visibleRange.start + index2) }, visibleRange.start + index2))
55731
- }
55732
- ) })
56210
+ className: cn("p-4 border rounded-lg bg-background space-y-4", className),
56211
+ initial: { opacity: 0, y: 20 },
56212
+ animate: { opacity: 1, y: 0 },
56213
+ transition: { duration: 0.3 },
56214
+ children: [
56215
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center justify-between", children: [
56216
+ /* @__PURE__ */ jsxs("h3", { className: "font-semibold flex items-center gap-2", children: [
56217
+ /* @__PURE__ */ jsx(BarChart3, { className: "h-4 w-4" }),
56218
+ "Ger\xE7ek Zamanl\u0131 Performans"
56219
+ ] }),
56220
+ /* @__PURE__ */ jsx(
56221
+ "button",
56222
+ {
56223
+ onClick: () => setIsActive(!isActive2),
56224
+ className: cn(
56225
+ "px-3 py-1 text-xs rounded-md transition-colors",
56226
+ isActive2 ? "bg-green-500/10 text-green-500 hover:bg-green-500/20" : "bg-gray-500/10 text-gray-500 hover:bg-gray-500/20"
56227
+ ),
56228
+ children: isActive2 ? "Aktif" : "Durduruldu"
56229
+ }
56230
+ )
56231
+ ] }),
56232
+ /* @__PURE__ */ jsxs("div", { className: "grid grid-cols-2 md:grid-cols-4 gap-4", children: [
56233
+ /* @__PURE__ */ jsxs("div", { className: "space-y-1", children: [
56234
+ /* @__PURE__ */ jsx("div", { className: "text-xs text-muted-foreground", children: "FPS" }),
56235
+ /* @__PURE__ */ jsx("div", { className: cn(
56236
+ "text-lg font-mono font-bold",
56237
+ memoryStats.performance ? getPerformanceColor(memoryStats.performance.fps, { good: 55, warning: 30 }) : ""
56238
+ ), children: memoryStats.performance?.fps || 0 })
56239
+ ] }),
56240
+ /* @__PURE__ */ jsxs("div", { className: "space-y-1", children: [
56241
+ /* @__PURE__ */ jsx("div", { className: "text-xs text-muted-foreground", children: "Render S\xFCresi" }),
56242
+ /* @__PURE__ */ jsxs("div", { className: cn(
56243
+ "text-lg font-mono font-bold",
56244
+ memoryStats.performance ? getPerformanceColor(100 - memoryStats.performance.renderTime, { good: 84, warning: 70 }) : ""
56245
+ ), children: [
56246
+ memoryStats.performance?.renderTime.toFixed(2) || 0,
56247
+ "ms"
56248
+ ] })
56249
+ ] }),
56250
+ /* @__PURE__ */ jsxs("div", { className: "space-y-1", children: [
56251
+ /* @__PURE__ */ jsx("div", { className: "text-xs text-muted-foreground", children: "Bellek Kullan\u0131m\u0131" }),
56252
+ /* @__PURE__ */ jsx("div", { className: "text-lg font-mono font-bold", children: formatBytes(memoryStats.memoryUsage) })
56253
+ ] }),
56254
+ /* @__PURE__ */ jsxs("div", { className: "space-y-1", children: [
56255
+ /* @__PURE__ */ jsx("div", { className: "text-xs text-muted-foreground", children: "Cache Hit Rate" }),
56256
+ /* @__PURE__ */ jsxs("div", { className: cn(
56257
+ "text-lg font-mono font-bold",
56258
+ getPerformanceColor(memoryStats.cacheHitRate * 100, { good: 85, warning: 70 })
56259
+ ), children: [
56260
+ Math.round(memoryStats.cacheHitRate * 100),
56261
+ "%"
56262
+ ] })
56263
+ ] })
56264
+ ] }),
56265
+ memoryStats.performance && /* @__PURE__ */ jsxs("div", { className: "grid grid-cols-2 gap-4 pt-2 border-t", children: [
56266
+ /* @__PURE__ */ jsxs("div", { className: "space-y-1", children: [
56267
+ /* @__PURE__ */ jsx("div", { className: "text-xs text-muted-foreground", children: "Memory Leaks" }),
56268
+ /* @__PURE__ */ jsxs("div", { className: cn(
56269
+ "text-sm font-mono",
56270
+ memoryStats.performance.memoryLeaks > 5 ? "text-red-500" : "text-green-500"
56271
+ ), children: [
56272
+ memoryStats.performance.memoryLeaks,
56273
+ " detection"
56274
+ ] })
56275
+ ] }),
56276
+ /* @__PURE__ */ jsxs("div", { className: "space-y-1", children: [
56277
+ /* @__PURE__ */ jsx("div", { className: "text-xs text-muted-foreground", children: "Scroll Performance" }),
56278
+ /* @__PURE__ */ jsxs("div", { className: cn(
56279
+ "text-sm font-mono",
56280
+ getPerformanceColor(memoryStats.performance.scrollPerformance, { good: 85, warning: 70 })
56281
+ ), children: [
56282
+ memoryStats.performance.scrollPerformance,
56283
+ "%"
56284
+ ] })
56285
+ ] })
56286
+ ] }),
56287
+ showChart && history2.length > 1 && /* @__PURE__ */ jsxs("div", { className: "pt-2 border-t", children: [
56288
+ /* @__PURE__ */ jsx("div", { className: "text-xs text-muted-foreground mb-2", children: "FPS Ge\xE7mi\u015Fi (Son 60 g\xFCncelleme)" }),
56289
+ /* @__PURE__ */ jsx("div", { className: "h-16 flex items-end gap-1", children: history2.slice(-30).map((stat, index2) => {
56290
+ const fps = stat.performance?.fps || 0;
56291
+ const height = Math.max(4, fps / 60 * 100);
56292
+ const color = fps >= 55 ? "bg-green-500" : fps >= 30 ? "bg-yellow-500" : "bg-red-500";
56293
+ return /* @__PURE__ */ jsx(
56294
+ motion.div,
56295
+ {
56296
+ className: cn("w-1 rounded-t-sm", color),
56297
+ style: { height: `${height}%` },
56298
+ initial: { height: 0 },
56299
+ animate: { height: `${height}%` },
56300
+ transition: { duration: 0.2 }
56301
+ },
56302
+ index2
56303
+ );
56304
+ }) })
56305
+ ] })
56306
+ ]
55733
56307
  }
55734
56308
  );
55735
56309
  }
@@ -55749,11 +56323,16 @@ function MemoryAnalytics({
55749
56323
  const interval = setInterval(() => {
55750
56324
  const newStats = {
55751
56325
  memoryUsage: Math.random() * 50 * 1024 * 1024,
55752
- // 0-50MB
55753
56326
  itemCount: Math.floor(Math.random() * 5e4),
55754
56327
  cacheHitRate: 0.9 + Math.random() * 0.1,
55755
- // 90-100%
55756
- lastCleanup: Date.now()
56328
+ lastCleanup: Date.now(),
56329
+ performance: {
56330
+ fps: Math.floor(30 + Math.random() * 30),
56331
+ renderTime: Math.random() * 16,
56332
+ memoryLeaks: Math.floor(Math.random() * 3),
56333
+ scrollPerformance: 70 + Math.random() * 30,
56334
+ lastUpdate: Date.now()
56335
+ }
55757
56336
  };
55758
56337
  setStats(newStats);
55759
56338
  if (onStatsUpdate) {
@@ -55762,10 +56341,7 @@ function MemoryAnalytics({
55762
56341
  }, 1e3);
55763
56342
  return () => clearInterval(interval);
55764
56343
  }, [showRealTime, onStatsUpdate]);
55765
- if (!showRealTime) {
55766
- return null;
55767
- }
55768
- return /* @__PURE__ */ jsx("div", { className: cn("text-xs text-muted-foreground", className), children: "Memory Analytics Active - Updates every second" });
56344
+ return /* @__PURE__ */ jsx(RealTimePerformanceMonitor, { memoryStats: stats, className, showChart: showRealTime });
55769
56345
  }
55770
56346
  function useStreamingData(initialData = [], streamingConfig) {
55771
56347
  const [data, setData] = useState(initialData);
@@ -55790,7 +56366,28 @@ function VirtualList({
55790
56366
  overscan = 5,
55791
56367
  renderItem,
55792
56368
  onScroll,
55793
- className
56369
+ className,
56370
+ // Infinite scrolling props
56371
+ hasNextPage = false,
56372
+ isLoadingNextPage = false,
56373
+ onLoadMore,
56374
+ loadMoreThreshold = 500,
56375
+ renderLoader,
56376
+ renderEndMessage,
56377
+ // Animation props
56378
+ enableAnimations = false,
56379
+ itemEnterAnimation = {
56380
+ initial: { opacity: 0, y: 20 },
56381
+ animate: { opacity: 1, y: 0 },
56382
+ exit: { opacity: 0, y: -20 },
56383
+ transition: { duration: 0.2 }
56384
+ },
56385
+ listAnimation = {
56386
+ initial: { opacity: 0 },
56387
+ animate: { opacity: 1 },
56388
+ transition: { duration: 0.3 }
56389
+ },
56390
+ staggerDelay = 0.05
55794
56391
  }) {
55795
56392
  const [scrollTop, setScrollTop] = useState(0);
55796
56393
  const [isScrolling, setIsScrolling] = useState(false);
@@ -55799,23 +56396,76 @@ function VirtualList({
55799
56396
  const scrollElementRef = useRef(null);
55800
56397
  const scrollTimeoutRef = useRef(void 0);
55801
56398
  const isScrollingTimeoutRef = useRef(void 0);
56399
+ useEffect(() => {
56400
+ if (!containerRef.current)
56401
+ return;
56402
+ const resizeObserver = new ResizeObserver((entries) => {
56403
+ const entry = entries[0];
56404
+ if (entry) {
56405
+ setContainerDimensions({
56406
+ width: entry.contentRect.width,
56407
+ height: entry.contentRect.height
56408
+ });
56409
+ }
56410
+ });
56411
+ resizeObserver.observe(containerRef.current);
56412
+ return () => resizeObserver.disconnect();
56413
+ }, []);
56414
+ const gridPositions = useGridLayout(
56415
+ items,
56416
+ gridConfig,
56417
+ direction,
56418
+ containerDimensions.width || (typeof width === "number" ? width : 800),
56419
+ itemHeight,
56420
+ itemWidth
56421
+ );
55802
56422
  const itemPositions = useMemo(() => {
56423
+ if (direction === "grid") {
56424
+ return gridPositions;
56425
+ }
55803
56426
  const positions = [];
55804
56427
  let currentTop = 0;
56428
+ let currentLeft = 0;
55805
56429
  for (let i = 0; i < items.length; i++) {
55806
56430
  const currentHeight = variableHeight ? itemHeights.get(i) || estimatedItemHeight : itemHeight;
56431
+ const currentWidth = variableWidth ? itemWidths.get(i) || estimatedItemWidth : direction === "horizontal" ? itemWidth : containerDimensions.width || 0;
55807
56432
  positions.push({
55808
56433
  index: i,
55809
56434
  height: currentHeight,
55810
- top: currentTop
56435
+ width: currentWidth,
56436
+ top: direction === "horizontal" ? 0 : currentTop,
56437
+ left: direction === "horizontal" ? currentLeft : 0
55811
56438
  });
55812
- currentTop += currentHeight;
56439
+ if (direction === "horizontal") {
56440
+ currentLeft += currentWidth;
56441
+ } else {
56442
+ currentTop += currentHeight;
56443
+ }
55813
56444
  }
55814
56445
  return positions;
55815
- }, [items.length, itemHeight, estimatedItemHeight, variableHeight, itemHeights]);
56446
+ }, [
56447
+ items.length,
56448
+ itemHeight,
56449
+ itemWidth,
56450
+ estimatedItemHeight,
56451
+ estimatedItemWidth,
56452
+ variableHeight,
56453
+ variableWidth,
56454
+ itemHeights,
56455
+ itemWidths,
56456
+ direction,
56457
+ containerDimensions.width,
56458
+ gridPositions
56459
+ ]);
55816
56460
  const totalHeight = useMemo(() => {
55817
- return itemPositions.length > 0 ? itemPositions[itemPositions.length - 1].top + itemPositions[itemPositions.length - 1].height : 0;
55818
- }, [itemPositions]);
56461
+ let baseHeight = itemPositions.length > 0 ? itemPositions[itemPositions.length - 1].top + itemPositions[itemPositions.length - 1].height : 0;
56462
+ if (hasNextPage && isLoadingNextPage) {
56463
+ baseHeight += 50;
56464
+ } else if (!hasNextPage && items.length > 0) {
56465
+ baseHeight += 40;
56466
+ }
56467
+ return baseHeight;
56468
+ }, [itemPositions, hasNextPage, isLoadingNextPage, items.length]);
55819
56469
  const visibleRange = useMemo(() => {
55820
56470
  const start = itemPositions.findIndex((item) => item.top + item.height >= scrollTop);
55821
56471
  const end = itemPositions.findIndex((item) => item.top > scrollTop + height);
@@ -55826,6 +56476,13 @@ function VirtualList({
55826
56476
  end: actualEnd
55827
56477
  };
55828
56478
  }, [scrollTop, height, itemPositions, overscan, items.length, itemHeight]);
56479
+ const {
56480
+ metrics,
56481
+ memoryCache,
56482
+ updateScrollDistance,
56483
+ optimizeGC,
56484
+ trackRenderPerformance
56485
+ } = useMemoryManagement(memoryManagement, visibleRange, items.length);
55829
56486
  const visibleItems = useMemo(() => {
55830
56487
  const result = [];
55831
56488
  for (let i = visibleRange.start; i <= visibleRange.end; i++) {
@@ -55849,11 +56506,18 @@ function VirtualList({
55849
56506
  }, [items, visibleRange, itemPositions, variableHeight]);
55850
56507
  const handleScroll = useCallback((e) => {
55851
56508
  const scrollTop2 = e.currentTarget.scrollTop;
56509
+ const scrollHeight = e.currentTarget.scrollHeight;
56510
+ const clientHeight = e.currentTarget.clientHeight;
55852
56511
  setScrollTop(scrollTop2);
55853
56512
  setIsScrolling(true);
56513
+ updateScrollDistance(scrollTop2);
56514
+ optimizeGC();
55854
56515
  if (onScroll) {
55855
56516
  onScroll(scrollTop2);
55856
56517
  }
56518
+ if (hasNextPage && !isLoadingNextPage && onLoadMore && scrollHeight - (scrollTop2 + clientHeight) <= loadMoreThreshold) {
56519
+ onLoadMore();
56520
+ }
55857
56521
  if (scrollTimeoutRef.current) {
55858
56522
  clearTimeout(scrollTimeoutRef.current);
55859
56523
  }
@@ -55863,7 +56527,7 @@ function VirtualList({
55863
56527
  isScrollingTimeoutRef.current = setTimeout(() => {
55864
56528
  setIsScrolling(false);
55865
56529
  }, 150);
55866
- }, [onScroll]);
56530
+ }, [onScroll, hasNextPage, isLoadingNextPage, onLoadMore, loadMoreThreshold, updateScrollDistance, optimizeGC]);
55867
56531
  useEffect(() => {
55868
56532
  if (!variableHeight || !containerRef.current)
55869
56533
  return;
@@ -55927,8 +56591,11 @@ function VirtualList({
55927
56591
  return () => container.removeEventListener("keydown", handleKeyDown3);
55928
56592
  }
55929
56593
  }, [itemHeight, height, totalHeight]);
56594
+ const ContainerComponent = enableAnimations ? motion.div : "div";
56595
+ const ContentComponent = enableAnimations ? motion.div : "div";
56596
+ const ItemComponent = enableAnimations ? motion.div : "div";
55930
56597
  return /* @__PURE__ */ jsxs(
55931
- "div",
56598
+ ContainerComponent,
55932
56599
  {
55933
56600
  ref: containerRef,
55934
56601
  className: cn(
@@ -55939,6 +56606,7 @@ function VirtualList({
55939
56606
  tabIndex: 0,
55940
56607
  role: "listbox",
55941
56608
  "aria-label": `Virtual list with ${items.length} items`,
56609
+ ...enableAnimations && listAnimation,
55942
56610
  children: [
55943
56611
  /* @__PURE__ */ jsx(
55944
56612
  "div",
@@ -55946,41 +56614,168 @@ function VirtualList({
55946
56614
  ref: scrollElementRef,
55947
56615
  className: "h-full overflow-auto scrollbar-thin scrollbar-thumb-muted scrollbar-track-transparent",
55948
56616
  onScroll: handleScroll,
55949
- children: /* @__PURE__ */ jsx(
55950
- "div",
56617
+ children: /* @__PURE__ */ jsxs(
56618
+ ContentComponent,
55951
56619
  {
55952
56620
  style: {
55953
56621
  height: totalHeight,
55954
56622
  position: "relative"
55955
56623
  },
55956
- children: visibleItems.map(({ item, index: index2, style: style2 }) => /* @__PURE__ */ jsx(
55957
- "div",
55958
- {
55959
- "data-index": index2,
55960
- style: style2,
55961
- role: "option",
55962
- "aria-selected": "false",
55963
- className: "outline-none",
55964
- children: renderItem(item, index2)
55965
- },
55966
- index2
55967
- ))
56624
+ ...enableAnimations && {
56625
+ initial: { opacity: 0 },
56626
+ animate: { opacity: 1 },
56627
+ transition: { duration: 0.2 }
56628
+ },
56629
+ children: [
56630
+ /* @__PURE__ */ jsx(AnimatePresence, { mode: "popLayout", children: visibleItems.map(({ item, index: index2, style: style2 }, itemIndex) => /* @__PURE__ */ jsx(
56631
+ ItemComponent,
56632
+ {
56633
+ "data-index": index2,
56634
+ style: style2,
56635
+ role: "option",
56636
+ "aria-selected": "false",
56637
+ className: "outline-none",
56638
+ ...enableAnimations && {
56639
+ ...itemEnterAnimation,
56640
+ transition: {
56641
+ ...itemEnterAnimation.transition,
56642
+ delay: itemIndex * staggerDelay
56643
+ }
56644
+ },
56645
+ children: renderItem(item, index2)
56646
+ },
56647
+ `${index2}-${JSON.stringify(item)}`
56648
+ )) }),
56649
+ hasNextPage && isLoadingNextPage && /* @__PURE__ */ jsx(
56650
+ motion.div,
56651
+ {
56652
+ style: {
56653
+ position: "absolute",
56654
+ top: totalHeight,
56655
+ left: 0,
56656
+ right: 0,
56657
+ minHeight: 50
56658
+ },
56659
+ className: "flex items-center justify-center py-4",
56660
+ initial: { opacity: 0, y: 20 },
56661
+ animate: { opacity: 1, y: 0 },
56662
+ exit: { opacity: 0, y: -20 },
56663
+ transition: { duration: 0.3 },
56664
+ children: renderLoader ? renderLoader() : /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2 text-muted-foreground", children: [
56665
+ /* @__PURE__ */ jsx(
56666
+ motion.div,
56667
+ {
56668
+ className: "rounded-full h-4 w-4 border-2 border-primary border-t-transparent",
56669
+ animate: { rotate: 360 },
56670
+ transition: { duration: 1, repeat: Infinity, ease: "linear" }
56671
+ }
56672
+ ),
56673
+ /* @__PURE__ */ jsx("span", { className: "text-sm", children: "Loading more..." })
56674
+ ] })
56675
+ }
56676
+ ),
56677
+ !hasNextPage && items.length > 0 && /* @__PURE__ */ jsx(
56678
+ motion.div,
56679
+ {
56680
+ style: {
56681
+ position: "absolute",
56682
+ top: totalHeight,
56683
+ left: 0,
56684
+ right: 0,
56685
+ minHeight: 40
56686
+ },
56687
+ className: "flex items-center justify-center py-3",
56688
+ initial: { opacity: 0, scale: 0.9 },
56689
+ animate: { opacity: 1, scale: 1 },
56690
+ transition: { duration: 0.2 },
56691
+ children: renderEndMessage ? renderEndMessage() : /* @__PURE__ */ jsx("div", { className: "text-sm text-muted-foreground", children: "No more items to load" })
56692
+ }
56693
+ )
56694
+ ]
55968
56695
  }
55969
56696
  )
55970
56697
  }
55971
56698
  ),
55972
- isScrolling && /* @__PURE__ */ jsx("div", { className: "absolute top-2 right-2 bg-muted/80 text-muted-foreground px-2 py-1 rounded text-xs", children: "Scrolling..." }),
55973
- items.length > 100 && /* @__PURE__ */ jsxs("div", { className: "absolute bottom-2 right-2 bg-muted/80 text-muted-foreground px-2 py-1 rounded text-xs", children: [
55974
- Math.round(scrollTop / Math.max(totalHeight - height, 1) * 100),
55975
- "%"
55976
- ] })
56699
+ /* @__PURE__ */ jsx(AnimatePresence, { children: isScrolling && /* @__PURE__ */ jsx(
56700
+ motion.div,
56701
+ {
56702
+ className: "absolute top-2 right-2 bg-muted/80 text-muted-foreground px-2 py-1 rounded text-xs",
56703
+ initial: { opacity: 0, scale: 0.8 },
56704
+ animate: { opacity: 1, scale: 1 },
56705
+ exit: { opacity: 0, scale: 0.8 },
56706
+ transition: { duration: 0.15 },
56707
+ children: "Scrolling..."
56708
+ }
56709
+ ) }),
56710
+ items.length > 100 && /* @__PURE__ */ jsxs(
56711
+ motion.div,
56712
+ {
56713
+ className: "absolute bottom-2 right-2 bg-muted/80 text-muted-foreground px-2 py-1 rounded text-xs",
56714
+ initial: { opacity: 0, y: 10 },
56715
+ animate: { opacity: 1, y: 0 },
56716
+ transition: { duration: 0.2, delay: 0.5 },
56717
+ children: [
56718
+ Math.round(scrollTop / Math.max(totalHeight - height, 1) * 100),
56719
+ "%"
56720
+ ]
56721
+ }
56722
+ ),
56723
+ enablePerformanceMonitoring && memoryManagement.enableDebugMode && /* @__PURE__ */ jsx(PerformanceMonitor, { metrics })
55977
56724
  ]
55978
56725
  }
55979
56726
  );
55980
56727
  }
56728
+ function PerformanceMonitor({ metrics }) {
56729
+ const formatMemory = (bytes) => {
56730
+ const kb = bytes / 1024;
56731
+ const mb = kb / 1024;
56732
+ if (mb >= 1)
56733
+ return `${mb.toFixed(2)} MB`;
56734
+ if (kb >= 1)
56735
+ return `${kb.toFixed(2)} KB`;
56736
+ return `${bytes} B`;
56737
+ };
56738
+ return /* @__PURE__ */ jsx(
56739
+ motion.div,
56740
+ {
56741
+ className: "absolute top-2 left-2 bg-black/90 text-white p-3 rounded-lg text-xs font-mono shadow-lg",
56742
+ initial: { opacity: 0, x: -20 },
56743
+ animate: { opacity: 1, x: 0 },
56744
+ transition: { duration: 0.3 },
56745
+ children: /* @__PURE__ */ jsxs("div", { className: "space-y-1", children: [
56746
+ /* @__PURE__ */ jsx("div", { className: "text-green-400 font-semibold", children: "\u{1F680} Performance Monitor" }),
56747
+ /* @__PURE__ */ jsxs("div", { className: "grid grid-cols-2 gap-x-4 gap-y-1", children: [
56748
+ /* @__PURE__ */ jsx("span", { children: "Renders:" }),
56749
+ /* @__PURE__ */ jsx("span", { className: "text-blue-300", children: metrics.renderCount }),
56750
+ /* @__PURE__ */ jsx("span", { children: "Avg Render:" }),
56751
+ /* @__PURE__ */ jsxs("span", { className: "text-blue-300", children: [
56752
+ metrics.averageRenderTime.toFixed(2),
56753
+ "ms"
56754
+ ] }),
56755
+ /* @__PURE__ */ jsx("span", { children: "Memory:" }),
56756
+ /* @__PURE__ */ jsx("span", { className: `${metrics.memoryUsage > 5 * 1024 * 1024 ? "text-red-400" : "text-green-400"}`, children: formatMemory(metrics.memoryUsage) }),
56757
+ /* @__PURE__ */ jsx("span", { children: "Visible Items:" }),
56758
+ /* @__PURE__ */ jsx("span", { className: "text-yellow-300", children: metrics.visibleItemsCount }),
56759
+ /* @__PURE__ */ jsx("span", { children: "Scroll FPS:" }),
56760
+ /* @__PURE__ */ jsx("span", { className: `${metrics.scrollFPS < 50 ? "text-red-400" : "text-green-400"}`, children: metrics.scrollFPS }),
56761
+ /* @__PURE__ */ jsx("span", { children: "Distance:" }),
56762
+ /* @__PURE__ */ jsxs("span", { className: "text-purple-300", children: [
56763
+ Math.round(metrics.totalScrollDistance),
56764
+ "px"
56765
+ ] })
56766
+ ] }),
56767
+ metrics.lastGCTime && /* @__PURE__ */ jsxs("div", { className: "text-orange-400 text-xs mt-2", children: [
56768
+ "Last GC: ",
56769
+ new Date(metrics.lastGCTime).toLocaleTimeString()
56770
+ ] })
56771
+ ] })
56772
+ }
56773
+ );
56774
+ }
55981
56775
  function useVirtualList(items, initialConfig = {}) {
55982
56776
  const [config, setConfig] = useState(initialConfig);
55983
56777
  const [selectedItems, setSelectedItems] = useState(/* @__PURE__ */ new Set());
56778
+ const [focusedIndex, setFocusedIndex] = useState(-1);
55984
56779
  const updateConfig = useCallback((newConfig) => {
55985
56780
  setConfig((prev) => ({ ...prev, ...newConfig }));
55986
56781
  }, []);
@@ -55994,16 +56789,58 @@ function useVirtualList(items, initialConfig = {}) {
55994
56789
  return newSet;
55995
56790
  });
55996
56791
  }, []);
56792
+ const toggleItem = useCallback((index2) => {
56793
+ setSelectedItems((prev) => {
56794
+ const newSet = new Set(prev);
56795
+ if (newSet.has(index2)) {
56796
+ newSet.delete(index2);
56797
+ } else {
56798
+ newSet.add(index2);
56799
+ }
56800
+ return newSet;
56801
+ });
56802
+ }, []);
56803
+ const selectRange = useCallback((startIndex, endIndex) => {
56804
+ setSelectedItems((prev) => {
56805
+ const newSet = new Set(prev);
56806
+ const start = Math.min(startIndex, endIndex);
56807
+ const end = Math.max(startIndex, endIndex);
56808
+ for (let i = start; i <= end; i++) {
56809
+ newSet.add(i);
56810
+ }
56811
+ return newSet;
56812
+ });
56813
+ }, []);
56814
+ const selectAll3 = useCallback(() => {
56815
+ setSelectedItems(new Set(Array.from({ length: items.length }, (_, i) => i)));
56816
+ }, [items.length]);
55997
56817
  const clearSelection = useCallback(() => {
55998
56818
  setSelectedItems(/* @__PURE__ */ new Set());
55999
56819
  }, []);
56820
+ const isSelected = useCallback((index2) => {
56821
+ return selectedItems.has(index2);
56822
+ }, [selectedItems]);
56823
+ const getSelectedItems = useCallback(() => {
56824
+ return Array.from(selectedItems).map((index2) => items[index2]).filter(Boolean);
56825
+ }, [selectedItems, items]);
56826
+ const getSelectedCount = useCallback(() => {
56827
+ return selectedItems.size;
56828
+ }, [selectedItems]);
56000
56829
  return {
56001
56830
  config,
56002
56831
  updateConfig,
56003
56832
  selectedItems,
56833
+ focusedIndex,
56834
+ setFocusedIndex,
56004
56835
  selectItem,
56005
56836
  deselectItem,
56006
- clearSelection
56837
+ toggleItem,
56838
+ selectRange,
56839
+ selectAll: selectAll3,
56840
+ clearSelection,
56841
+ isSelected,
56842
+ getSelectedItems,
56843
+ getSelectedCount
56007
56844
  };
56008
56845
  }
56009
56846
  function SelectableVirtualList({
@@ -56011,14 +56848,33 @@ function SelectableVirtualList({
56011
56848
  multiSelect = false,
56012
56849
  selectedItems = /* @__PURE__ */ new Set(),
56013
56850
  onSelectionChange,
56851
+ focusedIndex = -1,
56852
+ onFocusChange,
56853
+ selectAllEnabled = false,
56854
+ onSelectAll,
56855
+ onDeselectAll,
56856
+ getItemId,
56014
56857
  renderItem: originalRenderItem,
56015
56858
  ...props
56016
56859
  }) {
56017
- const handleItemClick = useCallback((index2) => {
56860
+ const [lastSelectedIndex, setLastSelectedIndex] = useState(-1);
56861
+ const handleItemClick = useCallback((index2, event) => {
56018
56862
  if (!selectable || !onSelectionChange)
56019
56863
  return;
56020
56864
  const newSelection = new Set(selectedItems);
56021
- if (multiSelect) {
56865
+ if (multiSelect && event?.shiftKey && lastSelectedIndex !== -1) {
56866
+ const start = Math.min(lastSelectedIndex, index2);
56867
+ const end = Math.max(lastSelectedIndex, index2);
56868
+ for (let i = start; i <= end; i++) {
56869
+ newSelection.add(i);
56870
+ }
56871
+ } else if (multiSelect && (event?.ctrlKey || event?.metaKey)) {
56872
+ if (newSelection.has(index2)) {
56873
+ newSelection.delete(index2);
56874
+ } else {
56875
+ newSelection.add(index2);
56876
+ }
56877
+ } else if (multiSelect) {
56022
56878
  if (newSelection.has(index2)) {
56023
56879
  newSelection.delete(index2);
56024
56880
  } else {
@@ -56028,23 +56884,61 @@ function SelectableVirtualList({
56028
56884
  newSelection.clear();
56029
56885
  newSelection.add(index2);
56030
56886
  }
56887
+ setLastSelectedIndex(index2);
56031
56888
  onSelectionChange(newSelection);
56032
- }, [selectable, multiSelect, selectedItems, onSelectionChange]);
56889
+ onFocusChange?.(index2);
56890
+ }, [selectable, multiSelect, selectedItems, onSelectionChange, lastSelectedIndex, onFocusChange]);
56891
+ const handleKeyDown3 = useCallback((event) => {
56892
+ if (!selectable)
56893
+ return;
56894
+ switch (event.key) {
56895
+ case "Enter":
56896
+ case " ":
56897
+ event.preventDefault();
56898
+ if (focusedIndex >= 0 && focusedIndex < props.items.length) {
56899
+ handleItemClick(focusedIndex);
56900
+ }
56901
+ break;
56902
+ case "a":
56903
+ if ((event.ctrlKey || event.metaKey) && multiSelect && selectAllEnabled) {
56904
+ event.preventDefault();
56905
+ if (onSelectAll) {
56906
+ onSelectAll();
56907
+ }
56908
+ }
56909
+ break;
56910
+ case "Escape":
56911
+ if (multiSelect && onDeselectAll) {
56912
+ event.preventDefault();
56913
+ onDeselectAll();
56914
+ }
56915
+ break;
56916
+ }
56917
+ }, [selectable, focusedIndex, props.items.length, handleItemClick, multiSelect, selectAllEnabled, onSelectAll, onDeselectAll]);
56033
56918
  const renderItem = useCallback((item, index2) => {
56034
56919
  const isSelected = selectedItems.has(index2);
56920
+ const isFocused = focusedIndex === index2;
56921
+ const itemId = getItemId ? getItemId(item, index2) : index2;
56035
56922
  return /* @__PURE__ */ jsx(
56036
56923
  "div",
56037
56924
  {
56038
56925
  className: cn(
56039
- "transition-colors",
56926
+ "transition-colors outline-none",
56040
56927
  selectable && "cursor-pointer hover:bg-muted/50",
56041
- isSelected && "bg-primary/10 border-l-4 border-primary"
56928
+ isSelected && "bg-primary/10 border-l-4 border-primary",
56929
+ isFocused && "ring-2 ring-ring ring-offset-2"
56042
56930
  ),
56043
- onClick: () => selectable && handleItemClick(index2),
56931
+ onClick: (e) => selectable && handleItemClick(index2, e),
56932
+ onKeyDown: handleKeyDown3,
56933
+ tabIndex: selectable ? 0 : void 0,
56934
+ role: selectable ? "option" : void 0,
56935
+ "aria-selected": selectable ? isSelected : void 0,
56936
+ "aria-label": selectable ? `Item ${index2 + 1}${isSelected ? ", selected" : ""}` : void 0,
56044
56937
  children: originalRenderItem(item, index2)
56045
- }
56938
+ },
56939
+ itemId
56046
56940
  );
56047
- }, [originalRenderItem, selectable, selectedItems, handleItemClick]);
56941
+ }, [originalRenderItem, selectable, selectedItems, focusedIndex, handleItemClick, handleKeyDown3, getItemId]);
56048
56942
  return /* @__PURE__ */ jsx(VirtualList, { ...props, renderItem });
56049
56943
  }
56050
56944
  var SwipeableCard = t__default.forwardRef(
@@ -56074,12 +56968,12 @@ var SwipeableCard = t__default.forwardRef(
56074
56968
  return;
56075
56969
  onSwipeEnd?.();
56076
56970
  if (Math.abs(info.offset.x) > threshold) {
56077
- const direction = info.offset.x > 0 ? "right" : "left";
56971
+ const direction2 = info.offset.x > 0 ? "right" : "left";
56078
56972
  const exitX = info.offset.x > 0 ? 400 : -400;
56079
56973
  animate(x, exitX, { duration: 0.3 });
56080
- if (direction === "right" && onSwipeRight) {
56974
+ if (direction2 === "right" && onSwipeRight) {
56081
56975
  onSwipeRight();
56082
- } else if (direction === "left" && onSwipeLeft) {
56976
+ } else if (direction2 === "left" && onSwipeLeft) {
56083
56977
  onSwipeLeft();
56084
56978
  }
56085
56979
  } else {
@@ -57054,7 +57948,7 @@ function AdvancedChart({
57054
57948
  title,
57055
57949
  subtitle,
57056
57950
  height = 400,
57057
- width = "100%",
57951
+ width: width2 = "100%",
57058
57952
  xAxisKey = "name",
57059
57953
  yAxisKey,
57060
57954
  showGrid = true,
@@ -57139,9 +58033,9 @@ function AdvancedChart({
57139
58033
  onExport(format7);
57140
58034
  }
57141
58035
  };
57142
- const handleZoom = (direction) => {
58036
+ const handleZoom = (direction2) => {
57143
58037
  setZoomLevel((prev) => {
57144
- if (direction === "in")
58038
+ if (direction2 === "in")
57145
58039
  return Math.min(prev + 10, 200);
57146
58040
  return Math.max(prev - 10, 50);
57147
58041
  });
@@ -57170,7 +58064,7 @@ function AdvancedChart({
57170
58064
  }
57171
58065
  const commonProps = {
57172
58066
  data,
57173
- width: typeof width === "string" ? void 0 : width,
58067
+ width: typeof width2 === "string" ? void 0 : width2,
57174
58068
  height: sparklineMode ? 60 : height,
57175
58069
  margin: sparklineMode ? { top: 5, right: 5, left: 5, bottom: 5 } : { top: 20, right: 30, left: 20, bottom: showBrush ? 60 : 20 }
57176
58070
  };
@@ -57466,7 +58360,7 @@ function AdvancedChart({
57466
58360
  cx: "50%",
57467
58361
  cy: "50%",
57468
58362
  innerRadius: type === "pie" ? 0 : "40%",
57469
- outerRadius: Math.min(height, typeof width === "number" ? width : 400) / 3,
58363
+ outerRadius: Math.min(height, typeof width2 === "number" ? width2 : 400) / 3,
57470
58364
  animationDuration: animated ? animationDuration : 0,
57471
58365
  animationBegin: 0,
57472
58366
  label: showDataLabels ? {
@@ -58800,15 +59694,15 @@ function DashboardGrid({
58800
59694
  t__default.useEffect(() => {
58801
59695
  const updateWidth = () => {
58802
59696
  if (containerRef.current) {
58803
- const width = containerRef.current.offsetWidth;
58804
- setContainerWidth(width);
58805
- if (width < 480) {
59697
+ const width2 = containerRef.current.offsetWidth;
59698
+ setContainerWidth(width2);
59699
+ if (width2 < 480) {
58806
59700
  setCurrentBreakpoint("xxs");
58807
- } else if (width < 768) {
59701
+ } else if (width2 < 768) {
58808
59702
  setCurrentBreakpoint("xs");
58809
- } else if (width < 996) {
59703
+ } else if (width2 < 996) {
58810
59704
  setCurrentBreakpoint("sm");
58811
- } else if (width < 1200) {
59705
+ } else if (width2 < 1200) {
58812
59706
  setCurrentBreakpoint("md");
58813
59707
  } else {
58814
59708
  setCurrentBreakpoint("lg");
@@ -60166,7 +61060,7 @@ function DraggableList({
60166
61060
  onReorder,
60167
61061
  renderItem,
60168
61062
  keyExtractor,
60169
- direction = "vertical",
61063
+ direction: direction2 = "vertical",
60170
61064
  className,
60171
61065
  droppableId = "draggable-list",
60172
61066
  disabled = false
@@ -60189,7 +61083,7 @@ function DraggableList({
60189
61083
  Droppable,
60190
61084
  {
60191
61085
  droppableId,
60192
- direction,
61086
+ direction: direction2,
60193
61087
  isDropDisabled: disabled,
60194
61088
  children: (provided, snapshot) => /* @__PURE__ */ jsxs(
60195
61089
  "div",
@@ -60198,7 +61092,7 @@ function DraggableList({
60198
61092
  ref: provided.innerRef,
60199
61093
  className: cn(
60200
61094
  "space-y-2",
60201
- direction === "horizontal" && "flex space-y-0 space-x-2",
61095
+ direction2 === "horizontal" && "flex space-y-0 space-x-2",
60202
61096
  snapshot.isDraggingOver && "bg-muted/50 rounded-lg",
60203
61097
  className
60204
61098
  ),
@@ -61329,7 +62223,7 @@ var LazyComponent = ({ className, ...props }) => {
61329
62223
  var OptimizedImageInternal = ({
61330
62224
  src,
61331
62225
  alt,
61332
- width,
62226
+ width: width2,
61333
62227
  height,
61334
62228
  quality = 75,
61335
62229
  format: format7 = "auto",
@@ -61371,7 +62265,7 @@ var OptimizedImageInternal = ({
61371
62265
  params.set("f", options.format);
61372
62266
  return optimizedUrl;
61373
62267
  };
61374
- const optimizedSrc = getOptimizedSrc(src, { width, height, quality, format: format7 });
62268
+ const optimizedSrc = getOptimizedSrc(src, { width: width2, height, quality, format: format7 });
61375
62269
  const handleImageLoad = () => {
61376
62270
  setIsLoaded(true);
61377
62271
  setIsLoading(false);
@@ -61421,9 +62315,9 @@ var OptimizedImageInternal = ({
61421
62315
  const generateSrcSet = () => {
61422
62316
  if (srcSet)
61423
62317
  return srcSet;
61424
- if (!width)
62318
+ if (!width2)
61425
62319
  return void 0;
61426
- const widths = [width * 0.5, width, width * 1.5, width * 2];
62320
+ const widths = [width2 * 0.5, width2, width2 * 1.5, width2 * 2];
61427
62321
  return widths.map((w2) => `${getOptimizedSrc(src, { width: Math.round(w2), quality })} ${Math.round(w2)}w`).join(", ");
61428
62322
  };
61429
62323
  return /* @__PURE__ */ jsxs(Fragment, { children: [
@@ -61458,7 +62352,7 @@ var OptimizedImageInternal = ({
61458
62352
  ref: imgRef,
61459
62353
  src: optimizedSrc,
61460
62354
  alt,
61461
- width,
62355
+ width: width2,
61462
62356
  height,
61463
62357
  sizes,
61464
62358
  srcSet: generateSrcSet(),
@@ -62648,7 +63542,7 @@ var PerformanceMonitorInternal = ({
62648
63542
  ] }) })
62649
63543
  ] });
62650
63544
  };
62651
- var PerformanceMonitor = ({ className, ...props }) => {
63545
+ var PerformanceMonitor2 = ({ className, ...props }) => {
62652
63546
  const { hasProAccess, isLoading } = useSubscription();
62653
63547
  if (!isLoading && !hasProAccess) {
62654
63548
  return /* @__PURE__ */ jsx(MoonUICardPro, { className: cn("w-fit", className), children: /* @__PURE__ */ jsx(MoonUICardContentPro, { className: "py-6 text-center", children: /* @__PURE__ */ jsxs("div", { className: "space-y-4", children: [
@@ -63054,21 +63948,21 @@ var MoonUIFileUploadPro = t__default.forwardRef(
63054
63948
  img.onload = () => {
63055
63949
  const canvas = document.createElement("canvas");
63056
63950
  const ctx = canvas.getContext("2d");
63057
- let width = img.width;
63951
+ let width2 = img.width;
63058
63952
  let height = img.height;
63059
- if (width > maxWidth || height > maxHeight) {
63060
- const aspectRatio = width / height;
63061
- if (width > height) {
63062
- width = maxWidth;
63953
+ if (width2 > maxWidth || height > maxHeight) {
63954
+ const aspectRatio = width2 / height;
63955
+ if (width2 > height) {
63956
+ width2 = maxWidth;
63063
63957
  height = maxWidth / aspectRatio;
63064
63958
  } else {
63065
63959
  height = maxHeight;
63066
- width = maxHeight * aspectRatio;
63960
+ width2 = maxHeight * aspectRatio;
63067
63961
  }
63068
63962
  }
63069
- canvas.width = width;
63963
+ canvas.width = width2;
63070
63964
  canvas.height = height;
63071
- ctx.drawImage(img, 0, 0, width, height);
63965
+ ctx.drawImage(img, 0, 0, width2, height);
63072
63966
  canvas.toBlob(
63073
63967
  (blob) => {
63074
63968
  if (blob) {
@@ -64480,7 +65374,7 @@ function DataTableFilterDrawer({
64480
65374
  open,
64481
65375
  onOpenChange,
64482
65376
  position = "right",
64483
- width = "400px",
65377
+ width: width2 = "400px",
64484
65378
  filters: externalFilters,
64485
65379
  onFiltersChange,
64486
65380
  customFilters,
@@ -64560,7 +65454,7 @@ function DataTableFilterDrawer({
64560
65454
  "fixed top-0 bottom-0 z-50 bg-background border-l shadow-xl",
64561
65455
  position === "right" ? "right-0" : "left-0"
64562
65456
  ),
64563
- style: { width },
65457
+ style: { width: width2 },
64564
65458
  children: /* @__PURE__ */ jsxs("div", { className: "flex flex-col h-full", children: [
64565
65459
  /* @__PURE__ */ jsxs("div", { className: "flex items-center justify-between p-4 border-b", children: [
64566
65460
  /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2", children: [
@@ -66301,16 +67195,16 @@ var FormWizardProgress = ({
66301
67195
  };
66302
67196
  var animations = {
66303
67197
  slide: {
66304
- initial: (direction) => ({
66305
- x: direction > 0 ? 1e3 : -1e3,
67198
+ initial: (direction2) => ({
67199
+ x: direction2 > 0 ? 1e3 : -1e3,
66306
67200
  opacity: 0
66307
67201
  }),
66308
67202
  animate: {
66309
67203
  x: 0,
66310
67204
  opacity: 1
66311
67205
  },
66312
- exit: (direction) => ({
66313
- x: direction < 0 ? 1e3 : -1e3,
67206
+ exit: (direction2) => ({
67207
+ x: direction2 < 0 ? 1e3 : -1e3,
66314
67208
  opacity: 0
66315
67209
  })
66316
67210
  },
@@ -66336,7 +67230,7 @@ var FormWizardStep = ({
66336
67230
  animationDuration = 0.3
66337
67231
  }) => {
66338
67232
  const { steps, currentStep, goToNext, goToPrevious, goToStep, updateStepData, stepData, error } = useFormWizard();
66339
- const [direction, setDirection] = t__default.useState(0);
67233
+ const [direction2, setDirection] = t__default.useState(0);
66340
67234
  const previousStep = t__default.useRef(currentStep);
66341
67235
  t__default.useEffect(() => {
66342
67236
  setDirection(currentStep > previousStep.current ? 1 : -1);
@@ -66357,10 +67251,10 @@ var FormWizardStep = ({
66357
67251
  updateStepData: (data) => updateStepData(currentStepObj.id, data)
66358
67252
  };
66359
67253
  const content = typeof currentStepObj.content === "function" ? currentStepObj.content(stepContentProps) : currentStepObj.content;
66360
- return /* @__PURE__ */ jsx(AnimatePresence, { mode: "wait", custom: direction, children: /* @__PURE__ */ jsx(
67254
+ return /* @__PURE__ */ jsx(AnimatePresence, { mode: "wait", custom: direction2, children: /* @__PURE__ */ jsx(
66361
67255
  motion.div,
66362
67256
  {
66363
- custom: direction,
67257
+ custom: direction2,
66364
67258
  variants: animations[animationType],
66365
67259
  initial: "initial",
66366
67260
  animate: "animate",
@@ -68592,4 +69486,4 @@ var BadgePro = t__default.forwardRef(({
68592
69486
  });
68593
69487
  BadgePro.displayName = "BadgePro";
68594
69488
 
68595
- export { MoonUIAccordionPro as Accordion, MoonUIAccordionContentPro as AccordionContent, MoonUIAccordionItemPro as AccordionItem, MoonUIAccordionTriggerPro as AccordionTrigger, Calendar3 as AdvancedCalendar, AdvancedChart, AdvancedForms, MoonUIAlertPro as Alert, MoonUIAlertDescriptionPro as AlertDescription, MoonUIAlertTitlePro as AlertTitle, AnimatedButton, MoonUIAspectRatioPro as AspectRatio, MoonUIAvatarPro as Avatar, MoonUIAvatarFallbackPro as AvatarFallback, MoonUIAvatarImagePro as AvatarImage, MoonUIBadgePro as Badge, MoonUIBreadcrumbPro as Breadcrumb, MoonUIBreadcrumbEllipsisPro as BreadcrumbEllipsis, MoonUIBreadcrumbItemPro as BreadcrumbItem, MoonUIBreadcrumbLinkPro as BreadcrumbLink, MoonUIBreadcrumbListPro as BreadcrumbList, MoonUIBreadcrumbPagePro as BreadcrumbPage, MoonUIBreadcrumbSeparatorPro as BreadcrumbSeparator, MoonUIButtonPro as Button, Calendar, CalendarPro, MoonUICardPro as Card, MoonUICardContentPro as CardContent, MoonUICardDescriptionPro as CardDescription, MoonUICardFooterPro as CardFooter, MoonUICardHeaderPro as CardHeader, MoonUICardTitlePro as CardTitle, MoonUICheckboxPro as Checkbox, MoonUICollapsiblePro as Collapsible, MoonUICollapsibleContentPro as CollapsibleContent, MoonUICollapsibleTriggerPro as CollapsibleTrigger, MoonUIColorPickerPro as ColorPicker, MoonUICommandPro as Command, MoonUICommandDialogPro as CommandDialog, MoonUICommandEmptyPro as CommandEmpty, MoonUICommandGroupPro as CommandGroup, MoonUICommandInputPro as CommandInput, MoonUICommandItemPro as CommandItem, MoonUICommandListPro as CommandList, MoonUICommandSeparatorPro as CommandSeparator, MoonUICommandShortcutPro as CommandShortcut, Dashboard, DataTable, MoonUIDialogPro as Dialog, MoonUIDialogClosePro as DialogClose, MoonUIDialogContentPro as DialogContent, MoonUIDialogDescriptionPro as DialogDescription, MoonUIDialogFooterPro as DialogFooter, MoonUIDialogHeaderPro as DialogHeader, MoonUIDialogTitlePro as DialogTitle, MoonUIDialogTriggerPro as DialogTrigger, DraggableList, MoonUIDropdownMenuPro as DropdownMenu, MoonUIDropdownMenuCheckboxItemPro as DropdownMenuCheckboxItem, MoonUIDropdownMenuContentPro as DropdownMenuContent, MoonUIDropdownMenuGroupPro as DropdownMenuGroup, MoonUIDropdownMenuItemPro as DropdownMenuItem, MoonUIDropdownMenuLabelPro as DropdownMenuLabel, MoonUIDropdownMenuPortalPro as DropdownMenuPortal, MoonUIDropdownMenuRadioGroupPro as DropdownMenuRadioGroup, MoonUIDropdownMenuRadioItemPro as DropdownMenuRadioItem, MoonUIDropdownMenuSeparatorPro as DropdownMenuSeparator, MoonUIDropdownMenuShortcutPro as DropdownMenuShortcut, MoonUIDropdownMenuSubPro as DropdownMenuSub, MoonUIDropdownMenuSubContentPro as DropdownMenuSubContent, MoonUIDropdownMenuSubTriggerPro as DropdownMenuSubTrigger, MoonUIDropdownMenuTriggerPro as DropdownMenuTrigger, enhanced_exports as Enhanced, ErrorBoundary, FloatingActionButton, FormWizardNavigation, FormWizardProgress, FormWizardStep, GitHubStars, HealthCheck, HoverCard2 as HoverCard, HoverCard3D, HoverCardContent2 as HoverCardContent, HoverCardTrigger2 as HoverCardTrigger, MoonUIInputPro as Input, Kanban, MoonUILabelPro as Label, LazyComponent, LazyImage, LazyList, MagneticButton, MemoryAnalytics, MemoryEfficientData, MoonUIAccordionContentPro, MoonUIAccordionItemPro, MoonUIAccordionPro, MoonUIAccordionTriggerPro, MoonUIAlertDescriptionPro, MoonUIAlertPro, MoonUIAlertTitlePro, MoonUIAspectRatioPro, MoonUIAvatarFallbackPro, MoonUIAvatarImagePro, MoonUIAvatarPro, MoonUIBadgePro, MoonUIBreadcrumbEllipsisPro, MoonUIBreadcrumbItemPro, MoonUIBreadcrumbLinkPro, MoonUIBreadcrumbListPro, MoonUIBreadcrumbPagePro, MoonUIBreadcrumbPro, MoonUIBreadcrumbSeparatorPro, MoonUIButtonPro, MoonUICardContentPro, MoonUICardDescriptionPro, MoonUICardFooterPro, MoonUICardHeaderPro, MoonUICardPro, MoonUICardTitlePro, MoonUICheckboxPro, MoonUICollapsibleContentPro, MoonUICollapsiblePro, MoonUICollapsibleTriggerPro, MoonUIColorPickerPro, MoonUICommandDialogPro, MoonUICommandEmptyPro, MoonUICommandGroupPro, MoonUICommandInputPro, MoonUICommandItemPro, MoonUICommandListPro, MoonUICommandPro, MoonUICommandSeparatorPro, MoonUICommandShortcutPro, MoonUICreditCardInputPro, MoonUIDialogClosePro, MoonUIDialogContentPro, MoonUIDialogDescriptionPro, MoonUIDialogFooterPro, MoonUIDialogHeaderPro, MoonUIDialogPro, MoonUIDialogTitlePro, MoonUIDialogTriggerPro, MoonUIDropdownMenuCheckboxItemPro, MoonUIDropdownMenuContentPro, MoonUIDropdownMenuGroupPro, MoonUIDropdownMenuItemPro, MoonUIDropdownMenuLabelPro, MoonUIDropdownMenuPortalPro, MoonUIDropdownMenuPro, MoonUIDropdownMenuRadioGroupPro, MoonUIDropdownMenuRadioItemPro, MoonUIDropdownMenuSeparatorPro, MoonUIDropdownMenuShortcutPro, MoonUIDropdownMenuSubContentPro, MoonUIDropdownMenuSubPro, MoonUIDropdownMenuSubTriggerPro, MoonUIDropdownMenuTriggerPro, MoonUIFileUploadPro, MoonUIFormWizardPro, MoonUIInputPro, MoonUILabelPro, MoonUIPaginationContentPro, MoonUIPaginationEllipsisPro, MoonUIPaginationItemPro, MoonUIPaginationLinkPro, MoonUIPaginationNextPro, MoonUIPaginationPreviousPro, MoonUIPaginationPro, MoonUIPhoneNumberInputPro, MoonUIPopoverContentPro, MoonUIPopoverPro, MoonUIPopoverTriggerPro, MoonUIProgressPro, MoonUIQuizFormPro, MoonUIRadioGroupContextPro, MoonUIRadioGroupItemPro, MoonUIRadioGroupPro, MoonUIRadioItemWithLabelPro, MoonUIRadioLabelPro, MoonUISelectContentPro, MoonUISelectGroupPro, MoonUISelectItemPro, MoonUISelectLabelPro, MoonUISelectPro, MoonUISelectSeparatorPro, MoonUISelectTriggerPro, MoonUISelectValuePro, MoonUISeparatorPro, MoonUISkeletonPro, MoonUISliderPro, MoonUISwitchPro, MoonUITableBodyPro, MoonUITableCaptionPro, MoonUITableCellPro, MoonUITableFooterPro, MoonUITableHeadPro, MoonUITableHeaderPro, MoonUITablePro, MoonUITableRowPro, MoonUITabsContentPro, MoonUITabsListPro, MoonUITabsPro, MoonUITabsTriggerPro, MoonUITextareaPro, MoonUIToastPro, MoonUITogglePro, MoonUITooltipContentPro, MoonUITooltipPro, MoonUITooltipProviderPro, MoonUITooltipTriggerPro, MoonUIalertVariantsPro, MoonUIaspectRatioVariantsPro, MoonUIbreadcrumbVariantsPro, MoonUIcollapsibleContentVariantsPro, MoonUIcollapsibleTriggerVariantsPro, MoonUIcommandVariantsPro, MoonUIradioGroupItemVariantsPro, MoonUItableVariantsPro, MoonUItoggleVariantsPro, OptimizedImage, MoonUIPaginationPro as Pagination, MoonUIPaginationContentPro as PaginationContent, MoonUIPaginationEllipsisPro as PaginationEllipsis, MoonUIPaginationItemPro as PaginationItem, MoonUIPaginationLinkPro as PaginationLink, MoonUIPaginationNextPro as PaginationNext, MoonUIPaginationPreviousPro as PaginationPrevious, PerformanceDebugger, PerformanceMonitor, PinchZoom, MoonUIPopoverPro as Popover, MoonUIPopoverContentPro as PopoverContent, MoonUIPopoverTriggerPro as PopoverTrigger, MoonUIProgressPro as Progress, MoonUIRadioGroupPro as RadioGroup, MoonUIRadioGroupContextPro as RadioGroupContext, MoonUIRadioGroupItemPro as RadioGroupItem, MoonUIRadioItemWithLabelPro as RadioItemWithLabel, MoonUIRadioLabelPro as RadioLabel, RichTextEditor, ScrollArea, ScrollBar, MoonUISelectPro as Select, MoonUISelectContentPro as SelectContent, MoonUISelectGroupPro as SelectGroup, MoonUISelectItemPro as SelectItem, MoonUISelectLabelPro as SelectLabel, MoonUISelectSeparatorPro as SelectSeparator, MoonUISelectTriggerPro as SelectTrigger, MoonUISelectValuePro as SelectValue, SelectableVirtualList, MoonUISeparatorPro as Separator, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetOverlay, SheetPortal, SheetTitle, SheetTrigger, Sidebar2 as Sidebar, MoonUISkeletonPro as Skeleton, MoonUISliderPro as Slider, SpotlightCard, SwipeableCard, MoonUISwitchPro as Switch, MoonUITablePro as Table, MoonUITableBodyPro as TableBody, MoonUITableCaptionPro as TableCaption, MoonUITableCellPro as TableCell, MoonUITableFooterPro as TableFooter, MoonUITableHeadPro as TableHead, MoonUITableHeaderPro as TableHeader, MoonUITableRowPro as TableRow, MoonUITabsPro as Tabs, MoonUITabsContentPro as TabsContent, MoonUITabsListPro as TabsList, MoonUITabsTriggerPro as TabsTrigger, MoonUITextareaPro as Textarea, Timeline, MoonUIToastPro as Toast, MoonUITogglePro as Toggle, MoonUITooltipPro as Tooltip, MoonUITooltipContentPro as TooltipContent, MoonUITooltipProviderPro as TooltipProvider, MoonUITooltipTriggerPro as TooltipTrigger, VirtualList, MoonUIalertVariantsPro as alertVariants, animatedButtonVariants, MoonUIaspectRatioVariantsPro as aspectRatioVariants, moonUIBadgeVariantsPro as badgeVariants, MoonUIbreadcrumbVariantsPro as breadcrumbVariants, moonUIButtonProVariants as buttonVariants, cn, MoonUIcollapsibleContentVariantsPro as collapsibleContentVariants, MoonUIcollapsibleTriggerVariantsPro as collapsibleTriggerVariants, MoonUIcommandVariantsPro as commandVariants, getExpandableColumn, moonUIBadgeVariantsPro, moonUIButtonProVariants, moonUISeparatorVariantsPro, countries as phoneCountries, MoonUIradioGroupItemVariantsPro as radioGroupItemVariants, moonUISeparatorVariantsPro as separatorVariants, MoonUItableVariantsPro as tableVariants, MoonUItoggleVariantsPro as toggleVariants, useExpandableRows, useFormWizard, useStreamingData, useVirtualList };
69489
+ export { MoonUIAccordionPro as Accordion, MoonUIAccordionContentPro as AccordionContent, MoonUIAccordionItemPro as AccordionItem, MoonUIAccordionTriggerPro as AccordionTrigger, Calendar3 as AdvancedCalendar, AdvancedChart, AdvancedForms, MoonUIAlertPro as Alert, MoonUIAlertDescriptionPro as AlertDescription, MoonUIAlertTitlePro as AlertTitle, AnimatedButton, MoonUIAspectRatioPro as AspectRatio, MoonUIAvatarPro as Avatar, MoonUIAvatarFallbackPro as AvatarFallback, MoonUIAvatarImagePro as AvatarImage, MoonUIBadgePro as Badge, MoonUIBreadcrumbPro as Breadcrumb, MoonUIBreadcrumbEllipsisPro as BreadcrumbEllipsis, MoonUIBreadcrumbItemPro as BreadcrumbItem, MoonUIBreadcrumbLinkPro as BreadcrumbLink, MoonUIBreadcrumbListPro as BreadcrumbList, MoonUIBreadcrumbPagePro as BreadcrumbPage, MoonUIBreadcrumbSeparatorPro as BreadcrumbSeparator, MoonUIButtonPro as Button, Calendar, CalendarPro, MoonUICardPro as Card, MoonUICardContentPro as CardContent, MoonUICardDescriptionPro as CardDescription, MoonUICardFooterPro as CardFooter, MoonUICardHeaderPro as CardHeader, MoonUICardTitlePro as CardTitle, MoonUICheckboxPro as Checkbox, MoonUICollapsiblePro as Collapsible, MoonUICollapsibleContentPro as CollapsibleContent, MoonUICollapsibleTriggerPro as CollapsibleTrigger, MoonUIColorPickerPro as ColorPicker, MoonUICommandPro as Command, MoonUICommandDialogPro as CommandDialog, MoonUICommandEmptyPro as CommandEmpty, MoonUICommandGroupPro as CommandGroup, MoonUICommandInputPro as CommandInput, MoonUICommandItemPro as CommandItem, MoonUICommandListPro as CommandList, MoonUICommandSeparatorPro as CommandSeparator, MoonUICommandShortcutPro as CommandShortcut, Dashboard, DataTable, MoonUIDialogPro as Dialog, MoonUIDialogClosePro as DialogClose, MoonUIDialogContentPro as DialogContent, MoonUIDialogDescriptionPro as DialogDescription, MoonUIDialogFooterPro as DialogFooter, MoonUIDialogHeaderPro as DialogHeader, MoonUIDialogTitlePro as DialogTitle, MoonUIDialogTriggerPro as DialogTrigger, DraggableList, MoonUIDropdownMenuPro as DropdownMenu, MoonUIDropdownMenuCheckboxItemPro as DropdownMenuCheckboxItem, MoonUIDropdownMenuContentPro as DropdownMenuContent, MoonUIDropdownMenuGroupPro as DropdownMenuGroup, MoonUIDropdownMenuItemPro as DropdownMenuItem, MoonUIDropdownMenuLabelPro as DropdownMenuLabel, MoonUIDropdownMenuPortalPro as DropdownMenuPortal, MoonUIDropdownMenuRadioGroupPro as DropdownMenuRadioGroup, MoonUIDropdownMenuRadioItemPro as DropdownMenuRadioItem, MoonUIDropdownMenuSeparatorPro as DropdownMenuSeparator, MoonUIDropdownMenuShortcutPro as DropdownMenuShortcut, MoonUIDropdownMenuSubPro as DropdownMenuSub, MoonUIDropdownMenuSubContentPro as DropdownMenuSubContent, MoonUIDropdownMenuSubTriggerPro as DropdownMenuSubTrigger, MoonUIDropdownMenuTriggerPro as DropdownMenuTrigger, enhanced_exports as Enhanced, ErrorBoundary, FloatingActionButton, FormWizardNavigation, FormWizardProgress, FormWizardStep, GitHubStars, HealthCheck, HoverCard2 as HoverCard, HoverCard3D, HoverCardContent2 as HoverCardContent, HoverCardTrigger2 as HoverCardTrigger, MoonUIInputPro as Input, Kanban, MoonUILabelPro as Label, LazyComponent, LazyImage, LazyList, MagneticButton, MemoryAnalytics, MemoryEfficientData, MoonUIAccordionContentPro, MoonUIAccordionItemPro, MoonUIAccordionPro, MoonUIAccordionTriggerPro, MoonUIAlertDescriptionPro, MoonUIAlertPro, MoonUIAlertTitlePro, MoonUIAspectRatioPro, MoonUIAvatarFallbackPro, MoonUIAvatarImagePro, MoonUIAvatarPro, MoonUIBadgePro, MoonUIBreadcrumbEllipsisPro, MoonUIBreadcrumbItemPro, MoonUIBreadcrumbLinkPro, MoonUIBreadcrumbListPro, MoonUIBreadcrumbPagePro, MoonUIBreadcrumbPro, MoonUIBreadcrumbSeparatorPro, MoonUIButtonPro, MoonUICardContentPro, MoonUICardDescriptionPro, MoonUICardFooterPro, MoonUICardHeaderPro, MoonUICardPro, MoonUICardTitlePro, MoonUICheckboxPro, MoonUICollapsibleContentPro, MoonUICollapsiblePro, MoonUICollapsibleTriggerPro, MoonUIColorPickerPro, MoonUICommandDialogPro, MoonUICommandEmptyPro, MoonUICommandGroupPro, MoonUICommandInputPro, MoonUICommandItemPro, MoonUICommandListPro, MoonUICommandPro, MoonUICommandSeparatorPro, MoonUICommandShortcutPro, MoonUICreditCardInputPro, MoonUIDialogClosePro, MoonUIDialogContentPro, MoonUIDialogDescriptionPro, MoonUIDialogFooterPro, MoonUIDialogHeaderPro, MoonUIDialogPro, MoonUIDialogTitlePro, MoonUIDialogTriggerPro, MoonUIDropdownMenuCheckboxItemPro, MoonUIDropdownMenuContentPro, MoonUIDropdownMenuGroupPro, MoonUIDropdownMenuItemPro, MoonUIDropdownMenuLabelPro, MoonUIDropdownMenuPortalPro, MoonUIDropdownMenuPro, MoonUIDropdownMenuRadioGroupPro, MoonUIDropdownMenuRadioItemPro, MoonUIDropdownMenuSeparatorPro, MoonUIDropdownMenuShortcutPro, MoonUIDropdownMenuSubContentPro, MoonUIDropdownMenuSubPro, MoonUIDropdownMenuSubTriggerPro, MoonUIDropdownMenuTriggerPro, MoonUIFileUploadPro, MoonUIFormWizardPro, MoonUIInputPro, MoonUILabelPro, MoonUIPaginationContentPro, MoonUIPaginationEllipsisPro, MoonUIPaginationItemPro, MoonUIPaginationLinkPro, MoonUIPaginationNextPro, MoonUIPaginationPreviousPro, MoonUIPaginationPro, MoonUIPhoneNumberInputPro, MoonUIPopoverContentPro, MoonUIPopoverPro, MoonUIPopoverTriggerPro, MoonUIProgressPro, MoonUIQuizFormPro, MoonUIRadioGroupContextPro, MoonUIRadioGroupItemPro, MoonUIRadioGroupPro, MoonUIRadioItemWithLabelPro, MoonUIRadioLabelPro, MoonUISelectContentPro, MoonUISelectGroupPro, MoonUISelectItemPro, MoonUISelectLabelPro, MoonUISelectPro, MoonUISelectSeparatorPro, MoonUISelectTriggerPro, MoonUISelectValuePro, MoonUISeparatorPro, MoonUISkeletonPro, MoonUISliderPro, MoonUISwitchPro, MoonUITableBodyPro, MoonUITableCaptionPro, MoonUITableCellPro, MoonUITableFooterPro, MoonUITableHeadPro, MoonUITableHeaderPro, MoonUITablePro, MoonUITableRowPro, MoonUITabsContentPro, MoonUITabsListPro, MoonUITabsPro, MoonUITabsTriggerPro, MoonUITextareaPro, MoonUIToastPro, MoonUITogglePro, MoonUITooltipContentPro, MoonUITooltipPro, MoonUITooltipProviderPro, MoonUITooltipTriggerPro, MoonUIalertVariantsPro, MoonUIaspectRatioVariantsPro, MoonUIbreadcrumbVariantsPro, MoonUIcollapsibleContentVariantsPro, MoonUIcollapsibleTriggerVariantsPro, MoonUIcommandVariantsPro, MoonUIradioGroupItemVariantsPro, MoonUItableVariantsPro, MoonUItoggleVariantsPro, OptimizedImage, MoonUIPaginationPro as Pagination, MoonUIPaginationContentPro as PaginationContent, MoonUIPaginationEllipsisPro as PaginationEllipsis, MoonUIPaginationItemPro as PaginationItem, MoonUIPaginationLinkPro as PaginationLink, MoonUIPaginationNextPro as PaginationNext, MoonUIPaginationPreviousPro as PaginationPrevious, PerformanceDebugger, PerformanceMonitor2 as PerformanceMonitor, PinchZoom, MoonUIPopoverPro as Popover, MoonUIPopoverContentPro as PopoverContent, MoonUIPopoverTriggerPro as PopoverTrigger, MoonUIProgressPro as Progress, MoonUIRadioGroupPro as RadioGroup, MoonUIRadioGroupContextPro as RadioGroupContext, MoonUIRadioGroupItemPro as RadioGroupItem, MoonUIRadioItemWithLabelPro as RadioItemWithLabel, MoonUIRadioLabelPro as RadioLabel, RealTimePerformanceMonitor, RichTextEditor, ScrollArea, ScrollBar, MoonUISelectPro as Select, MoonUISelectContentPro as SelectContent, MoonUISelectGroupPro as SelectGroup, MoonUISelectItemPro as SelectItem, MoonUISelectLabelPro as SelectLabel, MoonUISelectSeparatorPro as SelectSeparator, MoonUISelectTriggerPro as SelectTrigger, MoonUISelectValuePro as SelectValue, SelectableVirtualList, MoonUISeparatorPro as Separator, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetOverlay, SheetPortal, SheetTitle, SheetTrigger, Sidebar2 as Sidebar, MoonUISkeletonPro as Skeleton, MoonUISliderPro as Slider, SpotlightCard, SwipeableCard, MoonUISwitchPro as Switch, MoonUITablePro as Table, MoonUITableBodyPro as TableBody, MoonUITableCaptionPro as TableCaption, MoonUITableCellPro as TableCell, MoonUITableFooterPro as TableFooter, MoonUITableHeadPro as TableHead, MoonUITableHeaderPro as TableHeader, MoonUITableRowPro as TableRow, MoonUITabsPro as Tabs, MoonUITabsContentPro as TabsContent, MoonUITabsListPro as TabsList, MoonUITabsTriggerPro as TabsTrigger, MoonUITextareaPro as Textarea, Timeline, MoonUIToastPro as Toast, MoonUITogglePro as Toggle, MoonUITooltipPro as Tooltip, MoonUITooltipContentPro as TooltipContent, MoonUITooltipProviderPro as TooltipProvider, MoonUITooltipTriggerPro as TooltipTrigger, VirtualList, MoonUIalertVariantsPro as alertVariants, animatedButtonVariants, MoonUIaspectRatioVariantsPro as aspectRatioVariants, moonUIBadgeVariantsPro as badgeVariants, MoonUIbreadcrumbVariantsPro as breadcrumbVariants, moonUIButtonProVariants as buttonVariants, cn, MoonUIcollapsibleContentVariantsPro as collapsibleContentVariants, MoonUIcollapsibleTriggerVariantsPro as collapsibleTriggerVariants, MoonUIcommandVariantsPro as commandVariants, getExpandableColumn, moonUIBadgeVariantsPro, moonUIButtonProVariants, moonUISeparatorVariantsPro, countries as phoneCountries, MoonUIradioGroupItemVariantsPro as radioGroupItemVariants, moonUISeparatorVariantsPro as separatorVariants, MoonUItableVariantsPro as tableVariants, MoonUItoggleVariantsPro as toggleVariants, useExpandableRows, useFormWizard, useStreamingData, useVirtualList };