@moontra/moonui-pro 3.4.14 → 3.4.16

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.d.ts CHANGED
@@ -2080,6 +2080,14 @@ interface FloatingDockProps extends Omit<React__default.HTMLAttributes<HTMLDivEl
2080
2080
  * Toggle button ikonu
2081
2081
  */
2082
2082
  toggleIcon?: React__default.ReactNode;
2083
+ /**
2084
+ * Toggle button arkaplan rengi (default: "bg-background/95")
2085
+ */
2086
+ toggleButtonBg?: string;
2087
+ /**
2088
+ * Toggle button border rengi (default: "border-border")
2089
+ */
2090
+ toggleButtonBorder?: string;
2083
2091
  }
2084
2092
  declare const FloatingDock: React__default.ForwardRefExoticComponent<FloatingDockProps & React__default.RefAttributes<HTMLDivElement>>;
2085
2093
 
package/dist/index.mjs CHANGED
@@ -17344,6 +17344,8 @@ var FloatingDockInternal = React71__default.forwardRef(
17344
17344
  mobileBreakpoint = "lg",
17345
17345
  autoHideDelay = 5e3,
17346
17346
  toggleIcon,
17347
+ toggleButtonBg = "bg-background/95",
17348
+ toggleButtonBorder = "border-border",
17347
17349
  ...props
17348
17350
  }, ref) => {
17349
17351
  const [isMobileOpen, setIsMobileOpen] = useState(false);
@@ -17499,7 +17501,9 @@ var FloatingDockInternal = React71__default.forwardRef(
17499
17501
  motion.button,
17500
17502
  {
17501
17503
  className: cn(
17502
- "absolute p-2.5 rounded-full bg-background/95 backdrop-blur-md border border-border shadow-lg hover:shadow-xl transition-shadow",
17504
+ "absolute p-2.5 rounded-full backdrop-blur-md border shadow-lg hover:shadow-xl transition-shadow",
17505
+ toggleButtonBg,
17506
+ toggleButtonBorder,
17503
17507
  position === "right" && "-left-14 top-1/2 -translate-y-1/2",
17504
17508
  position === "left" && "-right-14 top-1/2 -translate-y-1/2",
17505
17509
  position === "bottom" && "left-1/2 -translate-x-1/2 -top-14",
@@ -95538,6 +95542,7 @@ var NumberTickerInternal = ({
95538
95542
  const [currentValue, setCurrentValue] = useState(startValue);
95539
95543
  const [isAnimating, setIsAnimating] = useState(false);
95540
95544
  const [hasAnimated, setHasAnimated] = useState(false);
95545
+ const [isInViewport, setIsInViewport] = useState(false);
95541
95546
  const elementRef = useRef(null);
95542
95547
  const animationRef = useRef(null);
95543
95548
  const getEasingFunction = (t2) => {
@@ -95611,8 +95616,12 @@ var NumberTickerInternal = ({
95611
95616
  return;
95612
95617
  const observer = new IntersectionObserver(
95613
95618
  ([entry]) => {
95614
- if (entry.isIntersecting) {
95619
+ setIsInViewport(entry.isIntersecting);
95620
+ if (entry.isIntersecting && (!hasAnimated || repeat)) {
95615
95621
  startAnimation();
95622
+ } else if (!entry.isIntersecting && isAnimating && animationRef.current) {
95623
+ cancelAnimationFrame(animationRef.current);
95624
+ setIsAnimating(false);
95616
95625
  }
95617
95626
  },
95618
95627
  { threshold }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@moontra/moonui-pro",
3
- "version": "3.4.14",
3
+ "version": "3.4.16",
4
4
  "description": "Premium React components for MoonUI - Advanced UI library with 50+ pro components including performance, interactive, and gesture components",
5
5
  "type": "module",
6
6
  "main": "dist/index.mjs",