apex-ui-kit 2.0.6 → 2.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (35) hide show
  1. package/dist/ApexUI-Kit/templates/AccordionMarquee/AccordionMarquee.jsx +74 -53
  2. package/dist/ApexUI-Kit/templates/BeamBar/BeamBar.jsx +5 -3
  3. package/dist/ApexUI-Kit/templates/BluePrintBackground/BluePrintBackground.jsx +14 -2
  4. package/dist/ApexUI-Kit/templates/CardStack/CardStack.jsx +129 -0
  5. package/dist/ApexUI-Kit/templates/Cards/BasicCard.jsx +3 -3
  6. package/dist/ApexUI-Kit/templates/Carousel/ParallaxCarousel.jsx +0 -161
  7. package/dist/ApexUI-Kit/templates/DragCarousel/DragCarousel.jsx +39 -7
  8. package/dist/ApexUI-Kit/templates/EdgeGlowForm/EdgeGlowFrom.jsx +116 -98
  9. package/dist/ApexUI-Kit/templates/FlipProfile/FlipProfile.jsx +69 -37
  10. package/dist/ApexUI-Kit/templates/GlareCard/GlareCard.jsx +2 -2
  11. package/dist/ApexUI-Kit/templates/HoverText/HoverText.jsx +14 -13
  12. package/dist/ApexUI-Kit/templates/HyperCard/HyperCard.jsx +59 -42
  13. package/dist/ApexUI-Kit/templates/KineticThreadsBackground/KineticThreadBackground.jsx +17 -2
  14. package/dist/ApexUI-Kit/templates/LensFlareBackground/LensFlareBackground.jsx +18 -3
  15. package/dist/ApexUI-Kit/templates/LuminousParticleOcean/LuminousParticleOcean.jsx +15 -1
  16. package/dist/ApexUI-Kit/templates/MaskView/MaskView.jsx +345 -0
  17. package/dist/ApexUI-Kit/templates/MeteorCard/MeteorCard.jsx +34 -45
  18. package/dist/ApexUI-Kit/templates/NavDropDown/NavDropDown.jsx +272 -101
  19. package/dist/ApexUI-Kit/templates/NavMenu/NavMenu.jsx +8 -2
  20. package/dist/ApexUI-Kit/templates/ParallaxCard/ParallaxCard.jsx +13 -11
  21. package/dist/ApexUI-Kit/templates/ParallaxCarousel/ParallaxCarousel.jsx +60 -67
  22. package/dist/ApexUI-Kit/templates/ParallaxProfile/ParallaxProfile.jsx +69 -55
  23. package/dist/ApexUI-Kit/templates/PointerFollower/PointerFollower.jsx +34 -14
  24. package/dist/ApexUI-Kit/templates/ScrollMarquee/CardMarquee.jsx +0 -0
  25. package/dist/ApexUI-Kit/templates/SmartGridCard/SmartGridCard.jsx +4 -3
  26. package/dist/ApexUI-Kit/templates/SmokeBackground/SmokeBackground.jsx +35 -16
  27. package/dist/ApexUI-Kit/templates/Testimonials/Testimonials.jsx +11 -8
  28. package/dist/ApexUI-Kit/templates/ThemeToggle/ThemeAnimation.js +40 -69
  29. package/dist/ApexUI-Kit/templates/ThemeToggle/ThemeToggle.css +5 -1
  30. package/dist/ApexUI-Kit/templates/ThemeToggle/ThemeToggle.jsx +25 -7
  31. package/dist/ApexUI-Kit/templates/ToolTip/ToolTip.jsx +71 -52
  32. package/dist/cli/index.js +25 -14
  33. package/package.json +2 -2
  34. package/dist/ApexUI-Kit/templates/GlassCardStack/GlassCardStack.jsx +0 -111
  35. package/dist/ApexUI-Kit/templates/WaterDropReveal/WaterDropReveal.jsx +0 -151
@@ -1,111 +0,0 @@
1
- /* eslint-disable no-unused-vars */
2
- import React, { useState, useEffect, useRef } from "react";
3
- import { motion, AnimatePresence } from "framer-motion";
4
- import { FaExternalLinkAlt, FaGithub, FaRegImage } from "react-icons/fa";
5
- const CARD_STACK_OFFSET = 32;
6
- const CARD_SCALE_STEP = 0.08;
7
- const AUTO_CYCLE_INTERVAL = 5000;
8
- export default function GlassCardStack({
9
- cards = [],
10
- autoCycle = true,
11
- cycleInterval = AUTO_CYCLE_INTERVAL,
12
- }) {
13
- const [active, setActive] = useState(0);
14
- const [paused, setPaused] = useState(false);
15
- const timeoutRef = useRef();
16
-
17
- useEffect(() => {
18
- if (!autoCycle || paused) return;
19
- timeoutRef.current = setTimeout(() => {
20
- setActive((prev) => (prev + 1) % cards.length);
21
- }, cycleInterval);
22
- return () => clearTimeout(timeoutRef.current);
23
- }, [active, paused, autoCycle, cycleInterval, cards.length]);
24
-
25
- // For cycling animation
26
- const getCardIndex = (i) => (active + i) % cards.length;
27
-
28
- return (
29
- <div
30
- className="relative flex justify-center items-center h-[340px] md:h-[400px] w-full max-w-lg mx-auto select-none"
31
- onMouseEnter={() => setPaused(true)}
32
- onMouseLeave={() => setPaused(false)}
33
- >
34
- {cards.map((_, i) => {
35
- // Stack order: 0 is top, 1 is next, etc.
36
- const idx = getCardIndex(i);
37
- const isTop = i === 0;
38
- const z = cards.length - i;
39
- const offset = i * CARD_STACK_OFFSET;
40
- const scale = 1 - i * CARD_SCALE_STEP;
41
- const card = cards[idx];
42
- return (
43
- <AnimatePresence key={idx}>
44
- <motion.div
45
- key={idx}
46
- initial={{
47
- y: 60,
48
- opacity: 0,
49
- scale: scale * 0.95,
50
- }}
51
- animate={{
52
- y: -offset,
53
- opacity: 1,
54
- scale,
55
- zIndex: z,
56
- filter: isTop ? "none" : "blur(2px)",
57
- }}
58
- exit={{
59
- y: -100,
60
- opacity: 0,
61
- scale: scale * 0.95,
62
- }}
63
- transition={{ type: "spring", stiffness: 300, damping: 30 }}
64
- className={`absolute left-0 right-0 mx-auto w-11/12 md:w-96 h-48 md:h-60 rounded-3xl shadow-xl bg-gradient-to-br ${card.color} backdrop-blur-lg border border-white/20 flex flex-row items-center px-3 md:px-6 py-4 cursor-pointer select-none ${isTop ? "" : "pointer-events-none"}`}
65
- style={{ zIndex: z }}
66
- >
67
- {/* Left: Responsive Image */}
68
- <div className="flex-shrink-0 flex items-center justify-center w-16 h-16 md:w-24 md:h-24 lg:w-28 lg:h-28 rounded-xl overflow-hidden bg-white/10 border border-white/20 mr-3 md:mr-6">
69
- {card.image ? (
70
- <img
71
- src={card.image}
72
- alt={card.title}
73
- className="object-cover w-full h-full"
74
- />
75
- ) : (
76
- <FaRegImage className="text-3xl text-white/40" />
77
- )}
78
- </div>
79
- {/* Right: Info */}
80
- <div className="flex-1 flex flex-col justify-center gap-1 md:gap-2">
81
- <div className="flex items-center gap-2">
82
- <h2 className="text-base md:text-xl font-bold text-white drop-shadow">
83
- {card.title}
84
- </h2>
85
- {card.github && (
86
- <a href={card.github} target="_blank" rel="noopener noreferrer" className="text-white/70 hover:text-white ml-1">
87
- <FaGithub className="inline-block align-middle text-lg md:text-xl" />
88
- </a>
89
- )}
90
- </div>
91
- <p className="text-xs md:text-sm text-white/60 mb-1">{card.subtitle}</p>
92
- <p className="text-xs md:text-base text-white/80 mb-1 line-clamp-2">{card.desc}</p>
93
- {card.link && (
94
- <a
95
- href={card.link}
96
- target="_blank"
97
- rel="noopener noreferrer"
98
- className="inline-flex items-center gap-1 text-xs md:text-sm px-2 py-1 rounded bg-blue-500/80 hover:bg-blue-600/90 text-white font-semibold shadow transition w-fit mt-1"
99
- >
100
- <FaExternalLinkAlt className="inline-block mr-1 text-xs md:text-sm" />
101
- Visit
102
- </a>
103
- )}
104
- </div>
105
- </motion.div>
106
- </AnimatePresence>
107
- );
108
- })}
109
- </div>
110
- );
111
- }
@@ -1,151 +0,0 @@
1
- import React, { useState, useRef, useEffect } from "react";
2
- import gsap from "gsap";
3
-
4
- const WaterDropReveal = ({
5
- text = "Discover the Water Drop Reveal Effect!\nMake your UI interactive, modern, and magical.\nHover to experience the reveal.",
6
- dropCount = 3,
7
- dropColor = "#a855f7",
8
- animationSpeed = 0.4,
9
- }) => {
10
- // Limit dropCount to max 10
11
- const safeDropCount = Math.min(Math.max(1, dropCount), 10);
12
- const [hovered, setHovered] = useState(false);
13
- const [mouse, setMouse] = useState({ x: 0.5, y: 0.5 });
14
- const dropRef = useRef(null);
15
- const textRef = useRef(null);
16
- const mouseAnim = useRef({ x: 0.5, y: 0.5 });
17
-
18
- useEffect(() => {
19
- if (!hovered) return;
20
- gsap.to(mouseAnim.current, {
21
- x: mouse.x,
22
- y: mouse.y,
23
- duration: animationSpeed,
24
- ease: "power2.out",
25
- onUpdate: () => {
26
- if (dropRef.current) {
27
- dropRef.current.setAttribute("data-x", mouseAnim.current.x);
28
- dropRef.current.setAttribute("data-y", mouseAnim.current.y);
29
- }
30
- if (textRef.current) {
31
- const xShift = (mouseAnim.current.x - 0.5) * 20;
32
- const yShift = (mouseAnim.current.y - 0.5) * 10;
33
- const rotateX = -(mouseAnim.current.y - 0.5) * 10;
34
- const rotateY = (mouseAnim.current.x - 0.5) * 15;
35
- gsap.to(textRef.current, {
36
- x: xShift,
37
- y: yShift,
38
- rotateX,
39
- rotateY,
40
- scale: 1.08,
41
- transformPerspective: 600,
42
- transformOrigin: "center",
43
- duration: animationSpeed,
44
- ease: "power3.out",
45
- });
46
- }
47
- },
48
- });
49
- }, [mouse, hovered, animationSpeed]);
50
-
51
- const handleMouseMove = (e) => {
52
- const rect = e.currentTarget.getBoundingClientRect();
53
- const x = (e.clientX - rect.left) / rect.width;
54
- const y = (e.clientY - rect.top) / rect.height;
55
- setMouse({ x, y });
56
- };
57
-
58
- const animX = hovered ? mouseAnim.current.x : 0.5;
59
- const animY = hovered ? mouseAnim.current.y : 0.5;
60
- const cx = 200 + (animX - 0.5) * 40;
61
- const cy = 80 + (animY - 0.5) * 20;
62
-
63
- return (
64
- <div
65
- className="relative w-full h-full rounded-2xl shadow-2xl flex items-center justify-center cursor-pointer overflow-hidden group border border-gray-800 transition-all duration-300"
66
- onMouseEnter={() => setHovered(true)}
67
- onMouseLeave={() => {
68
- setHovered(false);
69
- gsap.to(textRef.current, {
70
- x: 0,
71
- y: 0,
72
- rotateX: 0,
73
- rotateY: 0,
74
- scale: 1,
75
- duration: 0.6,
76
- ease: "power2.out",
77
- });
78
- }}
79
- onMouseMove={handleMouseMove}
80
- style={{ minHeight: 260 }}
81
- >
82
- {/* Water Drop Layer */}
83
- <div
84
- ref={dropRef}
85
- className={`pointer-events-none absolute left-1/2 top-1/2 z-10 -translate-x-1/2 -translate-y-1/2 transition-opacity duration-700 ${hovered ? "opacity-100" : "opacity-0"}`}
86
- style={{ width: "100%", height: "100%" }}
87
- >
88
- <svg width="100%" height="100%" viewBox="0 0 400 160" preserveAspectRatio="xMidYMid slice">
89
- <defs>
90
- <filter id="drop-shadow" x="-30%" y="-30%" width="160%" height="160%">
91
- <feDropShadow dx="0" dy="6" stdDeviation="18" flood-color="black" flood-opacity="60" />
92
- </filter>
93
- </defs>
94
- {(() => {
95
- // Dynamic radii and opacities for unique drops
96
- const maxRadius = 160;
97
- const minRadius = 36;
98
- const maxOpacity = 0.7;
99
- const minOpacity = 0.18;
100
- const step = safeDropCount > 1 ? (maxRadius - minRadius) / (safeDropCount - 1) : 0;
101
- const opacityStep = safeDropCount > 1 ? (maxOpacity - minOpacity) / (safeDropCount - 1) : 0;
102
- return [...Array(safeDropCount)].map((_, i) => {
103
- const r = Math.round(maxRadius - i * step);
104
- const opacity = +(maxOpacity - i * opacityStep).toFixed(2);
105
- return (
106
- <circle
107
- key={i}
108
- cx={cx}
109
- cy={cy}
110
- r={hovered ? r : 0}
111
- fill={dropColor}
112
- fillOpacity={hovered ? opacity : 0}
113
- style={{ transition: `r 0.7s, fill-opacity 0.7s` }}
114
- filter="url(#drop-shadow)"
115
- />
116
- );
117
- });
118
- })()}
119
- </svg>
120
- </div>
121
-
122
- {/* Text Reveal with 3D */}
123
- <span
124
- ref={textRef}
125
- className={`absolute whitespace-break-spaces z-20 max-sm:text-xl text-4xl font-semibold tracking-wide select-none transition-opacity duration-700 text-center w-full px-4 ${hovered ? "blur-0 opacity-100" : "text-gray-400 blur-sm opacity-60"}`}
126
- style={{
127
- left: 0,
128
- letterSpacing: 0,
129
- willChange: "transform",
130
- background: hovered ? "linear-gradient(90deg, #fff, #38bdf8, #fff)" : undefined,
131
- WebkitBackgroundClip: hovered ? "text" : undefined,
132
- WebkitTextFillColor: hovered ? "transparent" : undefined,
133
- backgroundClip: hovered ? "text" : undefined,
134
- color: hovered ? undefined : undefined,
135
- fontFamily: "Bitcount Prop Double, system-ui",
136
- }}
137
- >
138
- {text}
139
- </span>
140
-
141
- {/* Hover Hint */}
142
- {!hovered && (
143
- <span className="absolute bottom-4 left-1/2 -translate-x-1/2 z-30 text-xs sm:text-sm text-white bg-black/40 px-3 py-1 rounded-full shadow-md animate-pulse pointer-events-none select-none">
144
- Hover to reveal
145
- </span>
146
- )}
147
- </div>
148
- );
149
- };
150
-
151
- export default WaterDropReveal;