@katajere/recap 1.0.14 → 2.0.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.
- package/dist/App.css +22 -2
- package/dist/LoginScreen.css +22 -21
- package/dist/OtpScreen.css +20 -17
- package/dist/RecapStory.css +148 -0
- package/dist/RecapStory.d.ts.map +1 -1
- package/dist/RecapStory.js +61 -28
- package/dist/StoryProgress.css +3 -3
- package/dist/assets/huxxle-login-blue-logo.svg +14 -0
- package/dist/assets/noisy-background.png +0 -0
- package/dist/assets/noisy-background.svg +23 -0
- package/dist/assets/search-icon.svg +4 -0
- package/dist/assets/share-button.svg +5 -0
- package/dist/assets/web-icon.png +0 -0
- package/dist/assets/web-icon.svg +14 -0
- package/dist/components/Header.css +12 -1
- package/dist/components/Header.js +2 -2
- package/dist/data/mock.d.ts.map +1 -1
- package/dist/data/mock.js +19 -7
- package/dist/index.d.ts +0 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +0 -1
- package/dist/slides/Slide10Final.css +73 -35
- package/dist/slides/Slide1Intro.css +204 -56
- package/dist/slides/Slide1Intro.d.ts +2 -1
- package/dist/slides/Slide1Intro.d.ts.map +1 -1
- package/dist/slides/Slide1Intro.js +41 -47
- package/dist/slides/Slide2Days.css +121 -34
- package/dist/slides/Slide2Days.d.ts +2 -1
- package/dist/slides/Slide2Days.d.ts.map +1 -1
- package/dist/slides/Slide2Days.js +45 -4
- package/dist/slides/Slide3Revenue.css +80 -38
- package/dist/slides/Slide3Revenue.d.ts.map +1 -1
- package/dist/slides/Slide3Revenue.js +31 -3
- package/dist/slides/Slide4Orders.css +93 -34
- package/dist/slides/Slide4Orders.d.ts +2 -1
- package/dist/slides/Slide4Orders.d.ts.map +1 -1
- package/dist/slides/Slide4Orders.js +45 -3
- package/dist/slides/Slide5Buyers.css +124 -67
- package/dist/slides/Slide5Buyers.d.ts +2 -1
- package/dist/slides/Slide5Buyers.d.ts.map +1 -1
- package/dist/slides/Slide5Buyers.js +43 -3
- package/dist/slides/Slide6Customer.css +294 -52
- package/dist/slides/Slide6Customer.d.ts +6 -3
- package/dist/slides/Slide6Customer.d.ts.map +1 -1
- package/dist/slides/Slide6Customer.js +25 -4
- package/dist/slides/Slide7Products.css +8 -7
- package/dist/slides/Slide7Products.js +3 -3
- package/dist/slides/Slide8Months.css +6 -6
- package/dist/slides/Slide9Year.css +4 -2
- package/dist/slides/Slide9Year.d.ts +2 -1
- package/dist/slides/Slide9Year.d.ts.map +1 -1
- package/dist/slides/Slide9Year.js +23 -2
- package/dist/types.d.ts +5 -0
- package/dist/types.d.ts.map +1 -1
- package/dist/utils/slideScreenshot.d.ts +27 -0
- package/dist/utils/slideScreenshot.d.ts.map +1 -0
- package/dist/utils/slideScreenshot.js +274 -0
- package/package.json +2 -1
- package/src/App.css +22 -2
- package/src/LoginScreen.css +22 -21
- package/src/LoginScreen.tsx +1 -1
- package/src/OtpScreen.css +20 -17
- package/src/OtpScreen.tsx +1 -1
- package/src/RecapStory.css +148 -0
- package/src/RecapStory.tsx +131 -57
- package/src/StoryProgress.css +3 -3
- package/src/components/Header.css +12 -1
- package/src/components/Header.tsx +2 -2
- package/src/data/mock.ts +19 -7
- package/src/index.ts +0 -1
- package/src/slides/Slide10Final.css +73 -35
- package/src/slides/Slide1Intro.css +204 -56
- package/src/slides/Slide1Intro.tsx +89 -81
- package/src/slides/Slide2Days.css +121 -34
- package/src/slides/Slide2Days.tsx +67 -19
- package/src/slides/Slide3Revenue.css +80 -38
- package/src/slides/Slide3Revenue.tsx +43 -6
- package/src/slides/Slide4Orders.css +93 -34
- package/src/slides/Slide4Orders.tsx +71 -10
- package/src/slides/Slide5Buyers.css +124 -67
- package/src/slides/Slide5Buyers.tsx +97 -38
- package/src/slides/Slide6Customer.css +294 -52
- package/src/slides/Slide6Customer.tsx +68 -10
- package/src/slides/Slide7Products.css +8 -7
- package/src/slides/Slide7Products.tsx +3 -3
- package/src/slides/Slide8Months.css +6 -6
- package/src/slides/Slide9Year.css +4 -2
- package/src/slides/Slide9Year.tsx +35 -7
- package/src/types.ts +5 -0
- package/src/utils/slideScreenshot.ts +324 -0
- package/dist/FloatingFrames.css +0 -55
- package/dist/FloatingFrames.d.ts +0 -11
- package/dist/FloatingFrames.d.ts.map +0 -1
- package/dist/FloatingFrames.js +0 -12
- package/src/FloatingFrames.css +0 -55
- package/src/FloatingFrames.tsx +0 -27
|
@@ -1,52 +1,48 @@
|
|
|
1
|
+
/* Slide5Buyers - Figma exact specifications with blue/purple scheme */
|
|
2
|
+
|
|
1
3
|
.slide5-buyers {
|
|
2
4
|
position: relative;
|
|
3
5
|
width: 100%;
|
|
4
|
-
|
|
6
|
+
height: 100%;
|
|
5
7
|
display: flex;
|
|
6
8
|
align-items: center;
|
|
7
9
|
justify-content: center;
|
|
8
|
-
padding: 9.48% 6.15% 7.11%;
|
|
9
10
|
overflow: hidden;
|
|
10
11
|
}
|
|
11
12
|
|
|
12
|
-
@media (max-height: 720px), (orientation: landscape) {
|
|
13
|
-
.slide5-buyers {
|
|
14
|
-
padding: clamp(24px, 5vh, 40px) 6.15% clamp(24px, 4vh, 32px);
|
|
15
|
-
}
|
|
16
|
-
}
|
|
17
|
-
|
|
18
13
|
.slide5-buyers__grid {
|
|
19
14
|
position: absolute;
|
|
20
15
|
inset: 0;
|
|
21
|
-
/* width: 650px; */
|
|
22
|
-
height: 100%;
|
|
23
|
-
margin: 0 auto;
|
|
24
16
|
pointer-events: none;
|
|
25
17
|
z-index: 0;
|
|
26
18
|
}
|
|
27
19
|
|
|
28
20
|
.column {
|
|
29
21
|
position: absolute;
|
|
30
|
-
width:
|
|
31
|
-
height: 100%;
|
|
22
|
+
width: 180px;
|
|
32
23
|
display: flex;
|
|
24
|
+
flex-direction: column;
|
|
33
25
|
justify-content: center;
|
|
26
|
+
align-items: center;
|
|
27
|
+
gap: 12px;
|
|
28
|
+
height: 996px;
|
|
34
29
|
}
|
|
35
30
|
|
|
36
31
|
.column-left {
|
|
37
|
-
left: -
|
|
32
|
+
left: -130px;
|
|
33
|
+
top: -80.98px;
|
|
38
34
|
}
|
|
39
35
|
|
|
40
36
|
.column-right {
|
|
41
|
-
right: -
|
|
37
|
+
right: -130px;
|
|
38
|
+
top: calc(50% - 996px/2 - 0.5px);
|
|
42
39
|
}
|
|
43
40
|
|
|
44
41
|
.column-inner {
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
width:
|
|
49
|
-
height: 1300px;
|
|
42
|
+
display: flex;
|
|
43
|
+
flex-direction: column;
|
|
44
|
+
gap: 12px;
|
|
45
|
+
width: 180px;
|
|
50
46
|
}
|
|
51
47
|
|
|
52
48
|
.column-left .column-inner {
|
|
@@ -58,27 +54,13 @@
|
|
|
58
54
|
}
|
|
59
55
|
|
|
60
56
|
.rect {
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
height: 239px;
|
|
57
|
+
width: 180px;
|
|
58
|
+
height: 240px;
|
|
64
59
|
box-sizing: border-box;
|
|
65
|
-
border: 1px solid #
|
|
60
|
+
border: 1px solid #817FE3;
|
|
61
|
+
flex: none;
|
|
66
62
|
}
|
|
67
63
|
|
|
68
|
-
.rect.l1 { top: -251.5px; }
|
|
69
|
-
.rect.l2 { top: 0.5px; }
|
|
70
|
-
.rect.l3 { top: 252.5px; }
|
|
71
|
-
.rect.l4 { top: 504.5px; }
|
|
72
|
-
.rect.l5 { top: 756.5px; }
|
|
73
|
-
.rect.l6 { top: 1008.5px; }
|
|
74
|
-
|
|
75
|
-
.rect.r1 { top: -247.022px; }
|
|
76
|
-
.rect.r2 { top: 4.978px; }
|
|
77
|
-
.rect.r3 { top: 256.978px; }
|
|
78
|
-
.rect.r4 { top: 508.978px; }
|
|
79
|
-
.rect.r5 { top: 760.978px; }
|
|
80
|
-
.rect.r6 { top: 1012.978px; }
|
|
81
|
-
|
|
82
64
|
@keyframes moveUp {
|
|
83
65
|
from { transform: translateY(0); }
|
|
84
66
|
to { transform: translateY(-29.86%); }
|
|
@@ -90,51 +72,126 @@
|
|
|
90
72
|
}
|
|
91
73
|
|
|
92
74
|
.slide5-buyers__content {
|
|
93
|
-
position:
|
|
75
|
+
position: absolute;
|
|
94
76
|
z-index: 1;
|
|
95
|
-
|
|
96
|
-
|
|
77
|
+
width: calc(100% - 32px - env(safe-area-inset-left) - env(safe-area-inset-right));
|
|
78
|
+
max-width: 358px;
|
|
97
79
|
display: flex;
|
|
98
80
|
flex-direction: column;
|
|
99
81
|
align-items: center;
|
|
100
|
-
|
|
101
|
-
|
|
82
|
+
gap: 64px;
|
|
83
|
+
left: 50%;
|
|
84
|
+
top: 50%;
|
|
85
|
+
transform: translate(-50%, -50%);
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
.slide5-buyers__section {
|
|
89
|
+
display: flex;
|
|
90
|
+
flex-direction: column;
|
|
91
|
+
align-items: center;
|
|
92
|
+
width: 100%;
|
|
93
|
+
gap: 16px;
|
|
102
94
|
}
|
|
103
95
|
|
|
104
96
|
.slide5-buyers__number {
|
|
105
|
-
|
|
106
|
-
font-
|
|
97
|
+
width: 100%;
|
|
98
|
+
font-family: 'Lora', serif;
|
|
99
|
+
font-style: normal;
|
|
107
100
|
font-weight: 700;
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
color: transparent;
|
|
114
|
-
padding-top: 4.74%;
|
|
101
|
+
font-size: 10vh;
|
|
102
|
+
line-height: 1;
|
|
103
|
+
text-align: center;
|
|
104
|
+
color: var(--primary-blue);
|
|
105
|
+
margin: 0;
|
|
115
106
|
}
|
|
116
107
|
|
|
117
|
-
.slide5-buyers__number
|
|
118
|
-
font-size:
|
|
108
|
+
.slide5-buyers__number--secondary {
|
|
109
|
+
font-size: 8vh;
|
|
110
|
+
color: #FFFFFF;
|
|
111
|
+
-webkit-text-stroke: 1.5px var(--primary-blue);
|
|
112
|
+
paint-order: stroke fill;
|
|
119
113
|
}
|
|
120
114
|
|
|
121
115
|
.slide5-buyers__label {
|
|
122
|
-
|
|
123
|
-
font-
|
|
116
|
+
width: 100%;
|
|
117
|
+
font-family: 'Lora', serif;
|
|
118
|
+
font-style: normal;
|
|
124
119
|
font-weight: 400;
|
|
125
|
-
|
|
126
|
-
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
120
|
+
font-size: clamp(14px, 4.1vw, 16px);
|
|
121
|
+
line-height: 1.5;
|
|
122
|
+
text-align: center;
|
|
123
|
+
color: #3734D3;
|
|
124
|
+
margin: 0;
|
|
130
125
|
}
|
|
131
126
|
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
127
|
+
/* Media queries for landscape and short screens */
|
|
128
|
+
@media (max-height: 720px), (orientation: landscape) {
|
|
129
|
+
.slide5-buyers__content {
|
|
130
|
+
gap: 48px;
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
.slide5-buyers__number {
|
|
134
|
+
font-size: 9dvh;
|
|
135
135
|
}
|
|
136
|
+
|
|
137
|
+
.slide5-buyers__number--secondary {
|
|
138
|
+
font-size: 7dvh;
|
|
139
|
+
}
|
|
140
|
+
}
|
|
136
141
|
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
142
|
+
/* Small/Short screens - handles browser chrome taking space */
|
|
143
|
+
@media (max-height: 700px) {
|
|
144
|
+
.slide5-buyers__content {
|
|
145
|
+
gap: 40px;
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
.slide5-buyers__section {
|
|
149
|
+
gap: 12px;
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
.slide5-buyers__number {
|
|
153
|
+
font-size: 8dvh;
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
.slide5-buyers__number--secondary {
|
|
157
|
+
font-size: 6dvh;
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
.slide5-buyers__label {
|
|
161
|
+
font-size: clamp(12px, 3.5vw, 14px);
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
/* Extra short screens (under 600px) - more aggressive adjustments */
|
|
166
|
+
@media (max-height: 600px) {
|
|
167
|
+
.slide5-buyers__content {
|
|
168
|
+
gap: 32px;
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
.slide5-buyers__section {
|
|
172
|
+
gap: 8px;
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
.slide5-buyers__number {
|
|
176
|
+
font-size: 7dvh;
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
.slide5-buyers__number--secondary {
|
|
180
|
+
font-size: 5dvh;
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
.slide5-buyers__label {
|
|
184
|
+
font-size: clamp(11px, 3vw, 13px);
|
|
185
|
+
}
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
/* Large screens - ensure columns are visible */
|
|
189
|
+
@media (min-width: 768px) {
|
|
190
|
+
.column-left {
|
|
191
|
+
left: -80px;
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
.column-right {
|
|
195
|
+
right: -80px;
|
|
196
|
+
}
|
|
140
197
|
}
|
|
@@ -1,71 +1,130 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { motion } from 'framer-motion';
|
|
2
|
+
import { motion, useMotionValue, useTransform, animate } from 'framer-motion';
|
|
3
3
|
import './Slide5Buyers.css';
|
|
4
4
|
|
|
5
5
|
interface Slide5BuyersProps {
|
|
6
6
|
firstTimeBuyers: number;
|
|
7
7
|
repeatBuyers: number;
|
|
8
|
+
frameImages?: string[];
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
/**
|
|
12
|
+
* Custom hook for number counter animation
|
|
13
|
+
*/
|
|
14
|
+
function useCountAnimation(target: number, duration: number = 2, delay: number = 0) {
|
|
15
|
+
const count = useMotionValue(0);
|
|
16
|
+
const rounded = useTransform(count, (latest) => Math.round(latest));
|
|
17
|
+
|
|
18
|
+
React.useEffect(() => {
|
|
19
|
+
const controls = animate(count, target, {
|
|
20
|
+
duration,
|
|
21
|
+
delay,
|
|
22
|
+
ease: 'easeOut',
|
|
23
|
+
});
|
|
24
|
+
|
|
25
|
+
return controls.stop;
|
|
26
|
+
}, [count, target, duration, delay]);
|
|
27
|
+
|
|
28
|
+
return rounded;
|
|
8
29
|
}
|
|
9
30
|
|
|
10
31
|
/**
|
|
11
32
|
* Slide5Buyers - Displays first-time and returning buyer counts with vertical animated columns
|
|
12
33
|
*/
|
|
13
|
-
function Slide5Buyers({ firstTimeBuyers, repeatBuyers }: Slide5BuyersProps) {
|
|
34
|
+
function Slide5Buyers({ firstTimeBuyers, repeatBuyers, frameImages }: Slide5BuyersProps) {
|
|
35
|
+
const firstTimeBuyersCount = useCountAnimation(firstTimeBuyers, 1.7, 0.3); // 1.7s + 0.3s delay = 2s total
|
|
36
|
+
const repeatBuyersCount = useCountAnimation(repeatBuyers, 1.2, 0.8); // 1.2s + 0.8s delay = 2s total
|
|
14
37
|
const leftRects = ['l1', 'l2', 'l3', 'l4', 'l5', 'l6'];
|
|
15
38
|
const rightRects = ['r1', 'r2', 'r3', 'r4', 'r5', 'r6'];
|
|
16
39
|
|
|
40
|
+
const frameImagePool = React.useMemo(() => {
|
|
41
|
+
return frameImages && frameImages.length > 0 ? frameImages : [];
|
|
42
|
+
}, [frameImages]);
|
|
43
|
+
|
|
44
|
+
const totalRects = leftRects.length + rightRects.length;
|
|
45
|
+
const rectSources = React.useMemo(() => {
|
|
46
|
+
if (!frameImagePool.length) {
|
|
47
|
+
return [];
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
return Array.from({ length: totalRects }, () =>
|
|
51
|
+
frameImagePool[Math.floor(Math.random() * frameImagePool.length)]
|
|
52
|
+
);
|
|
53
|
+
}, [frameImagePool, totalRects]);
|
|
54
|
+
|
|
55
|
+
const getRectStyle = (index: number) => {
|
|
56
|
+
const image = rectSources[index];
|
|
57
|
+
if (!image) {
|
|
58
|
+
return undefined;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
return {
|
|
62
|
+
backgroundImage: `url('${image}')`,
|
|
63
|
+
backgroundSize: 'cover',
|
|
64
|
+
backgroundPosition: 'center',
|
|
65
|
+
};
|
|
66
|
+
};
|
|
67
|
+
|
|
17
68
|
return (
|
|
18
69
|
<div className="slide5-buyers">
|
|
19
70
|
<div className="slide5-buyers__grid" aria-hidden="true">
|
|
20
71
|
<div className="column column-left">
|
|
21
72
|
<div className="column-inner">
|
|
22
|
-
{leftRects.map(rect => (
|
|
23
|
-
<span key={rect} className={`rect ${rect}`} />
|
|
73
|
+
{leftRects.map((rect, index) => (
|
|
74
|
+
<span key={rect} className={`rect ${rect}`} style={getRectStyle(index)} />
|
|
24
75
|
))}
|
|
25
76
|
</div>
|
|
26
77
|
</div>
|
|
27
78
|
<div className="column column-right">
|
|
28
79
|
<div className="column-inner">
|
|
29
|
-
{rightRects.map(rect => (
|
|
30
|
-
<span
|
|
80
|
+
{rightRects.map((rect, index) => (
|
|
81
|
+
<span
|
|
82
|
+
key={rect}
|
|
83
|
+
className={`rect ${rect}`}
|
|
84
|
+
style={getRectStyle(leftRects.length + index)}
|
|
85
|
+
/>
|
|
31
86
|
))}
|
|
32
87
|
</div>
|
|
33
88
|
</div>
|
|
34
89
|
</div>
|
|
35
90
|
|
|
36
91
|
<div className="slide5-buyers__content">
|
|
37
|
-
<
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
92
|
+
<div className="slide5-buyers__section">
|
|
93
|
+
<motion.div
|
|
94
|
+
className="slide5-buyers__number"
|
|
95
|
+
initial={{ opacity: 0, y: 20 }}
|
|
96
|
+
animate={{ opacity: 1, y: 0 }}
|
|
97
|
+
transition={{ duration: 0.6 }}
|
|
98
|
+
>
|
|
99
|
+
<motion.span>{firstTimeBuyersCount}</motion.span>
|
|
100
|
+
</motion.div>
|
|
101
|
+
<motion.p
|
|
102
|
+
className="slide5-buyers__label"
|
|
103
|
+
initial={{ opacity: 0, y: 20 }}
|
|
104
|
+
animate={{ opacity: 1, y: 0 }}
|
|
105
|
+
transition={{ duration: 0.6, delay: 0.2 }}
|
|
106
|
+
>
|
|
107
|
+
people don buy from you
|
|
108
|
+
</motion.p>
|
|
109
|
+
</div>
|
|
110
|
+
<div className="slide5-buyers__section">
|
|
111
|
+
<motion.div
|
|
112
|
+
className="slide5-buyers__number slide5-buyers__number--secondary"
|
|
113
|
+
initial={{ opacity: 0, y: 20 }}
|
|
114
|
+
animate={{ opacity: 1, y: 0 }}
|
|
115
|
+
transition={{ duration: 0.6, delay: 0.4 }}
|
|
116
|
+
>
|
|
117
|
+
<motion.span>{repeatBuyersCount}</motion.span>
|
|
118
|
+
</motion.div>
|
|
119
|
+
<motion.p
|
|
120
|
+
className="slide5-buyers__label"
|
|
121
|
+
initial={{ opacity: 0, y: 20 }}
|
|
122
|
+
animate={{ opacity: 1, y: 0 }}
|
|
123
|
+
transition={{ duration: 0.6, delay: 0.6 }}
|
|
124
|
+
>
|
|
125
|
+
people come buy again
|
|
126
|
+
</motion.p>
|
|
127
|
+
</div>
|
|
69
128
|
</div>
|
|
70
129
|
</div>
|
|
71
130
|
);
|