zopassport 0.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.
- package/LICENSE +22 -0
- package/README.md +407 -0
- package/app/.env.example +15 -0
- package/app/README.md +28 -0
- package/app/package.json +24 -0
- package/app/reanimated-mock.js +102 -0
- package/app/reanimated-mock.jsx +97 -0
- package/app/src/App.tsx +331 -0
- package/app/src/components/FounderBadge.tsx +26 -0
- package/app/src/components/OTPInput.tsx +149 -0
- package/app/src/components/PhoneInput.tsx +109 -0
- package/app/src/components/ZoAuth.tsx +320 -0
- package/app/src/components/ZoAvatar.tsx +87 -0
- package/app/src/components/ZoLanding.tsx +231 -0
- package/app/src/components/ZoOnboarding.tsx +524 -0
- package/app/src/components/ZoPassportCard.tsx +183 -0
- package/app/src/components/ZoProgressRing.tsx +57 -0
- package/app/src/components/index.ts +16 -0
- package/app/src/components/wallet/MovingShine.tsx +43 -0
- package/app/src/components/wallet/TransactionItem.tsx +84 -0
- package/app/src/components/wallet/TransactionList.tsx +65 -0
- package/app/src/components/wallet/WalletCard.tsx +152 -0
- package/app/src/components/wallet/WalletScreen.tsx +190 -0
- package/app/src/components/wallet/ZoToken.tsx +69 -0
- package/app/src/components/wallet/index.ts +8 -0
- package/app/src/components/wallet/styles/index.ts +4 -0
- package/app/src/components/wallet/styles/walletStyles.ts +210 -0
- package/app/src/sdk/ZoPassportSDK.ts +277 -0
- package/app/src/sdk/lib/api/auth.ts +223 -0
- package/app/src/sdk/lib/api/avatar.ts +155 -0
- package/app/src/sdk/lib/api/client.ts +135 -0
- package/app/src/sdk/lib/api/index.ts +8 -0
- package/app/src/sdk/lib/api/profile.ts +80 -0
- package/app/src/sdk/lib/api/wallet.ts +59 -0
- package/app/src/sdk/lib/types/auth.ts +78 -0
- package/app/src/sdk/lib/types/avatar.ts +22 -0
- package/app/src/sdk/lib/types/index.ts +8 -0
- package/app/src/sdk/lib/types/profile.ts +18 -0
- package/app/src/sdk/lib/types/wallet.ts +103 -0
- package/app/src/sdk/lib/types.ts +205 -0
- package/app/src/sdk/lib/utils/index.ts +6 -0
- package/app/src/sdk/lib/utils/phone.ts +71 -0
- package/app/src/sdk/lib/utils/storage.ts +116 -0
- package/app/src/sdk/lib/utils/wallet.ts +73 -0
- package/app/src/sdk/types.ts +205 -0
- package/app/src/styles.css +154 -0
- package/app/svg-mock.js +125 -0
- package/app/svg-mock.jsx +120 -0
- package/app/vite.config.ts +70 -0
- package/assets/ASSETS_MANIFEST.md +124 -0
- package/assets/bae.png +0 -0
- package/assets/bro.png +0 -0
- package/assets/cultural-stickers/Business.png +0 -0
- package/assets/cultural-stickers/Default (2).jpg +0 -0
- package/assets/cultural-stickers/Design.png +0 -0
- package/assets/cultural-stickers/FollowYourHeart.png +0 -0
- package/assets/cultural-stickers/Food.png +0 -0
- package/assets/cultural-stickers/Game.png +0 -0
- package/assets/cultural-stickers/Health&Fitness.png +0 -0
- package/assets/cultural-stickers/Home&Lifestyle.png +0 -0
- package/assets/cultural-stickers/Law.png +0 -0
- package/assets/cultural-stickers/Literature&Stories.png +0 -0
- package/assets/cultural-stickers/Music&Entertainment.png +0 -0
- package/assets/cultural-stickers/Nature&Wildlife.png +0 -0
- package/assets/cultural-stickers/Photography.png +0 -0
- package/assets/cultural-stickers/Science&Technology.png +0 -0
- package/assets/cultural-stickers/Spiritual.png +0 -0
- package/assets/cultural-stickers/Sport.png +0 -0
- package/assets/cultural-stickers/Stories&Journal.png +0 -0
- package/assets/cultural-stickers/Television&Cinema.png +0 -0
- package/assets/cultural-stickers/Travel&Adventure.png +0 -0
- package/assets/cultural-stickers/z.jpg (1).jpg +0 -0
- package/assets/figma-assets/landing-zo-logo.png +0 -0
- package/assets/images/rank1.jpeg +0 -0
- package/assets/index.ts +76 -0
- package/assets/lotties/loader.json +1216 -0
- package/assets/lotties/spinner.json +1 -0
- package/assets/videos/loading-screen-background.mp4 +0 -0
- package/assets/videos/opening-disks.mp4 +0 -0
- package/assets/wallet/constants.ts +38 -0
- package/assets/zo-coin.gif +0 -0
- package/assets/zo-fallback.png +0 -0
- package/dist/assets/index.d.mts +136 -0
- package/dist/assets/index.d.ts +136 -0
- package/dist/assets/index.js +133 -0
- package/dist/assets/index.js.map +1 -0
- package/dist/assets/index.mjs +100 -0
- package/dist/assets/index.mjs.map +1 -0
- package/dist/index.d.mts +789 -0
- package/dist/index.d.ts +789 -0
- package/dist/index.js +1118 -0
- package/dist/index.js.map +1 -0
- package/dist/index.mjs +1060 -0
- package/dist/index.mjs.map +1 -0
- package/dist/react-native.d.mts +537 -0
- package/dist/react-native.d.ts +537 -0
- package/dist/react-native.js +1617 -0
- package/dist/react-native.js.map +1 -0
- package/dist/react-native.mjs +1588 -0
- package/dist/react-native.mjs.map +1 -0
- package/dist/react.d.mts +824 -0
- package/dist/react.d.ts +824 -0
- package/dist/react.js +3856 -0
- package/dist/react.js.map +1 -0
- package/dist/react.mjs +3801 -0
- package/dist/react.mjs.map +1 -0
- package/package.json +112 -0
- package/scripts/init.js +196 -0
- package/scripts/postinstall.js +174 -0
- package/scripts/verify-build.js +121 -0
|
@@ -0,0 +1,154 @@
|
|
|
1
|
+
/* Zo Passport Global Styles */
|
|
2
|
+
|
|
3
|
+
/* Reset and base styles for mobile scrolling */
|
|
4
|
+
*, *::before, *::after {
|
|
5
|
+
box-sizing: border-box;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
html {
|
|
9
|
+
height: 100%;
|
|
10
|
+
overflow-x: hidden;
|
|
11
|
+
overflow-y: auto;
|
|
12
|
+
-webkit-overflow-scrolling: touch;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
body {
|
|
16
|
+
margin: 0;
|
|
17
|
+
padding: 0;
|
|
18
|
+
min-height: 100%;
|
|
19
|
+
height: auto;
|
|
20
|
+
overflow-x: hidden;
|
|
21
|
+
overflow-y: auto;
|
|
22
|
+
background: #000;
|
|
23
|
+
color: #fff;
|
|
24
|
+
font-family: 'Rubik', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
|
|
25
|
+
-webkit-font-smoothing: antialiased;
|
|
26
|
+
-moz-osx-font-smoothing: grayscale;
|
|
27
|
+
-webkit-overflow-scrolling: touch;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
#root {
|
|
31
|
+
min-height: 100%;
|
|
32
|
+
height: auto;
|
|
33
|
+
overflow-x: hidden;
|
|
34
|
+
overflow-y: visible;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
@keyframes spin {
|
|
38
|
+
to {
|
|
39
|
+
transform: rotate(360deg);
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
@keyframes fadeIn {
|
|
44
|
+
from {
|
|
45
|
+
opacity: 0;
|
|
46
|
+
transform: translateY(10px);
|
|
47
|
+
}
|
|
48
|
+
to {
|
|
49
|
+
opacity: 1;
|
|
50
|
+
transform: translateY(0);
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
@keyframes pulse {
|
|
55
|
+
0%, 100% {
|
|
56
|
+
opacity: 1;
|
|
57
|
+
}
|
|
58
|
+
50% {
|
|
59
|
+
opacity: 0.5;
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
@keyframes shimmer {
|
|
64
|
+
0% {
|
|
65
|
+
background-position: -200% 0;
|
|
66
|
+
}
|
|
67
|
+
100% {
|
|
68
|
+
background-position: 200% 0;
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
/* Smooth transitions */
|
|
73
|
+
* {
|
|
74
|
+
transition-property: background-color, border-color, color, fill, stroke, opacity, box-shadow, transform;
|
|
75
|
+
transition-duration: 200ms;
|
|
76
|
+
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
/* Scrollbar styling */
|
|
80
|
+
::-webkit-scrollbar {
|
|
81
|
+
width: 8px;
|
|
82
|
+
height: 8px;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
::-webkit-scrollbar-track {
|
|
86
|
+
background: rgba(255, 255, 255, 0.05);
|
|
87
|
+
border-radius: 4px;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
::-webkit-scrollbar-thumb {
|
|
91
|
+
background: rgba(255, 255, 255, 0.2);
|
|
92
|
+
border-radius: 4px;
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
::-webkit-scrollbar-thumb:hover {
|
|
96
|
+
background: rgba(255, 255, 255, 0.3);
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
/* Button hover effects */
|
|
100
|
+
button:hover:not(:disabled) {
|
|
101
|
+
transform: translateY(-1px);
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
button:active:not(:disabled) {
|
|
105
|
+
transform: translateY(0);
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
/* Link hover */
|
|
109
|
+
a:hover {
|
|
110
|
+
transform: translateY(-2px);
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
/* Focus styles for accessibility */
|
|
114
|
+
button:focus-visible,
|
|
115
|
+
input:focus-visible,
|
|
116
|
+
a:focus-visible {
|
|
117
|
+
outline: 2px solid rgba(255, 255, 255, 0.5);
|
|
118
|
+
outline-offset: 2px;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
/* Selection color */
|
|
122
|
+
::selection {
|
|
123
|
+
background: rgba(255, 255, 255, 0.2);
|
|
124
|
+
color: #fff;
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
/* Disable text selection on UI elements */
|
|
128
|
+
button,
|
|
129
|
+
.no-select {
|
|
130
|
+
user-select: none;
|
|
131
|
+
-webkit-user-select: none;
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
/* Placeholder text */
|
|
135
|
+
::placeholder {
|
|
136
|
+
color: rgba(255, 255, 255, 0.3);
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
/* Input autofill styling */
|
|
140
|
+
input:-webkit-autofill,
|
|
141
|
+
input:-webkit-autofill:hover,
|
|
142
|
+
input:-webkit-autofill:focus {
|
|
143
|
+
-webkit-text-fill-color: #fff;
|
|
144
|
+
-webkit-box-shadow: 0 0 0px 1000px #1a1a2e inset;
|
|
145
|
+
transition: background-color 5000s ease-in-out 0s;
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
|
|
149
|
+
|
|
150
|
+
|
|
151
|
+
|
|
152
|
+
|
|
153
|
+
|
|
154
|
+
|
package/app/svg-mock.js
ADDED
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
// Mock for react-native-svg on web
|
|
2
|
+
// Uses standard SVG elements
|
|
3
|
+
|
|
4
|
+
import React from 'react';
|
|
5
|
+
|
|
6
|
+
export const Svg = ({ children, width, height, viewBox, style, ...props }) => (
|
|
7
|
+
<svg
|
|
8
|
+
width={width}
|
|
9
|
+
height={height}
|
|
10
|
+
viewBox={viewBox}
|
|
11
|
+
style={style}
|
|
12
|
+
{...props}
|
|
13
|
+
>
|
|
14
|
+
{children}
|
|
15
|
+
</svg>
|
|
16
|
+
);
|
|
17
|
+
|
|
18
|
+
export const Circle = ({ cx, cy, r, fill, stroke, strokeWidth, ...props }) => (
|
|
19
|
+
<circle
|
|
20
|
+
cx={cx}
|
|
21
|
+
cy={cy}
|
|
22
|
+
r={r}
|
|
23
|
+
fill={fill}
|
|
24
|
+
stroke={stroke}
|
|
25
|
+
strokeWidth={strokeWidth}
|
|
26
|
+
{...props}
|
|
27
|
+
/>
|
|
28
|
+
);
|
|
29
|
+
|
|
30
|
+
export const Rect = ({ x, y, width, height, fill, stroke, rx, ry, ...props }) => (
|
|
31
|
+
<rect
|
|
32
|
+
x={x}
|
|
33
|
+
y={y}
|
|
34
|
+
width={width}
|
|
35
|
+
height={height}
|
|
36
|
+
fill={fill}
|
|
37
|
+
stroke={stroke}
|
|
38
|
+
rx={rx}
|
|
39
|
+
ry={ry}
|
|
40
|
+
{...props}
|
|
41
|
+
/>
|
|
42
|
+
);
|
|
43
|
+
|
|
44
|
+
export const Path = ({ d, fill, stroke, strokeWidth, ...props }) => (
|
|
45
|
+
<path
|
|
46
|
+
d={d}
|
|
47
|
+
fill={fill}
|
|
48
|
+
stroke={stroke}
|
|
49
|
+
strokeWidth={strokeWidth}
|
|
50
|
+
{...props}
|
|
51
|
+
/>
|
|
52
|
+
);
|
|
53
|
+
|
|
54
|
+
export const Line = ({ x1, y1, x2, y2, stroke, strokeWidth, ...props }) => (
|
|
55
|
+
<line
|
|
56
|
+
x1={x1}
|
|
57
|
+
y1={y1}
|
|
58
|
+
x2={x2}
|
|
59
|
+
y2={y2}
|
|
60
|
+
stroke={stroke}
|
|
61
|
+
strokeWidth={strokeWidth}
|
|
62
|
+
{...props}
|
|
63
|
+
/>
|
|
64
|
+
);
|
|
65
|
+
|
|
66
|
+
export const Text = ({ x, y, fill, fontSize, fontFamily, textAnchor, children, ...props }) => (
|
|
67
|
+
<text
|
|
68
|
+
x={x}
|
|
69
|
+
y={y}
|
|
70
|
+
fill={fill}
|
|
71
|
+
fontSize={fontSize}
|
|
72
|
+
fontFamily={fontFamily}
|
|
73
|
+
textAnchor={textAnchor}
|
|
74
|
+
{...props}
|
|
75
|
+
>
|
|
76
|
+
{children}
|
|
77
|
+
</text>
|
|
78
|
+
);
|
|
79
|
+
|
|
80
|
+
export const G = ({ children, transform, ...props }) => (
|
|
81
|
+
<g transform={transform} {...props}>
|
|
82
|
+
{children}
|
|
83
|
+
</g>
|
|
84
|
+
);
|
|
85
|
+
|
|
86
|
+
export const Defs = ({ children }) => <defs>{children}</defs>;
|
|
87
|
+
|
|
88
|
+
export const LinearGradient = ({ id, x1, y1, x2, y2, children, ...props }) => (
|
|
89
|
+
<linearGradient id={id} x1={x1} y1={y1} x2={x2} y2={y2} {...props}>
|
|
90
|
+
{children}
|
|
91
|
+
</linearGradient>
|
|
92
|
+
);
|
|
93
|
+
|
|
94
|
+
export const RadialGradient = ({ id, cx, cy, r, fx, fy, children, ...props }) => (
|
|
95
|
+
<radialGradient id={id} cx={cx} cy={cy} r={r} fx={fx} fy={fy} {...props}>
|
|
96
|
+
{children}
|
|
97
|
+
</radialGradient>
|
|
98
|
+
);
|
|
99
|
+
|
|
100
|
+
export const Stop = ({ offset, stopColor, stopOpacity, ...props }) => (
|
|
101
|
+
<stop
|
|
102
|
+
offset={offset}
|
|
103
|
+
stopColor={stopColor}
|
|
104
|
+
stopOpacity={stopOpacity}
|
|
105
|
+
{...props}
|
|
106
|
+
/>
|
|
107
|
+
);
|
|
108
|
+
|
|
109
|
+
export const ClipPath = ({ id, children }) => (
|
|
110
|
+
<clipPath id={id}>{children}</clipPath>
|
|
111
|
+
);
|
|
112
|
+
|
|
113
|
+
export const Mask = ({ id, children }) => (
|
|
114
|
+
<mask id={id}>{children}</mask>
|
|
115
|
+
);
|
|
116
|
+
|
|
117
|
+
export const Use = ({ href, ...props }) => <use href={href} {...props} />;
|
|
118
|
+
|
|
119
|
+
export default Svg;
|
|
120
|
+
|
|
121
|
+
|
|
122
|
+
|
|
123
|
+
|
|
124
|
+
|
|
125
|
+
|
package/app/svg-mock.jsx
ADDED
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
// Mock for react-native-svg on web
|
|
2
|
+
// Uses standard SVG elements
|
|
3
|
+
|
|
4
|
+
import React from 'react';
|
|
5
|
+
|
|
6
|
+
export const Svg = ({ children, width, height, viewBox, style, ...props }) => (
|
|
7
|
+
<svg
|
|
8
|
+
width={width}
|
|
9
|
+
height={height}
|
|
10
|
+
viewBox={viewBox}
|
|
11
|
+
style={style}
|
|
12
|
+
{...props}
|
|
13
|
+
>
|
|
14
|
+
{children}
|
|
15
|
+
</svg>
|
|
16
|
+
);
|
|
17
|
+
|
|
18
|
+
export const Circle = ({ cx, cy, r, fill, stroke, strokeWidth, ...props }) => (
|
|
19
|
+
<circle
|
|
20
|
+
cx={cx}
|
|
21
|
+
cy={cy}
|
|
22
|
+
r={r}
|
|
23
|
+
fill={fill}
|
|
24
|
+
stroke={stroke}
|
|
25
|
+
strokeWidth={strokeWidth}
|
|
26
|
+
{...props}
|
|
27
|
+
/>
|
|
28
|
+
);
|
|
29
|
+
|
|
30
|
+
export const Rect = ({ x, y, width, height, fill, stroke, rx, ry, ...props }) => (
|
|
31
|
+
<rect
|
|
32
|
+
x={x}
|
|
33
|
+
y={y}
|
|
34
|
+
width={width}
|
|
35
|
+
height={height}
|
|
36
|
+
fill={fill}
|
|
37
|
+
stroke={stroke}
|
|
38
|
+
rx={rx}
|
|
39
|
+
ry={ry}
|
|
40
|
+
{...props}
|
|
41
|
+
/>
|
|
42
|
+
);
|
|
43
|
+
|
|
44
|
+
export const Path = ({ d, fill, stroke, strokeWidth, ...props }) => (
|
|
45
|
+
<path
|
|
46
|
+
d={d}
|
|
47
|
+
fill={fill}
|
|
48
|
+
stroke={stroke}
|
|
49
|
+
strokeWidth={strokeWidth}
|
|
50
|
+
{...props}
|
|
51
|
+
/>
|
|
52
|
+
);
|
|
53
|
+
|
|
54
|
+
export const Line = ({ x1, y1, x2, y2, stroke, strokeWidth, ...props }) => (
|
|
55
|
+
<line
|
|
56
|
+
x1={x1}
|
|
57
|
+
y1={y1}
|
|
58
|
+
x2={x2}
|
|
59
|
+
y2={y2}
|
|
60
|
+
stroke={stroke}
|
|
61
|
+
strokeWidth={strokeWidth}
|
|
62
|
+
{...props}
|
|
63
|
+
/>
|
|
64
|
+
);
|
|
65
|
+
|
|
66
|
+
export const Text = ({ x, y, fill, fontSize, fontFamily, textAnchor, children, ...props }) => (
|
|
67
|
+
<text
|
|
68
|
+
x={x}
|
|
69
|
+
y={y}
|
|
70
|
+
fill={fill}
|
|
71
|
+
fontSize={fontSize}
|
|
72
|
+
fontFamily={fontFamily}
|
|
73
|
+
textAnchor={textAnchor}
|
|
74
|
+
{...props}
|
|
75
|
+
>
|
|
76
|
+
{children}
|
|
77
|
+
</text>
|
|
78
|
+
);
|
|
79
|
+
|
|
80
|
+
export const G = ({ children, transform, ...props }) => (
|
|
81
|
+
<g transform={transform} {...props}>
|
|
82
|
+
{children}
|
|
83
|
+
</g>
|
|
84
|
+
);
|
|
85
|
+
|
|
86
|
+
export const Defs = ({ children }) => <defs>{children}</defs>;
|
|
87
|
+
|
|
88
|
+
export const LinearGradient = ({ id, x1, y1, x2, y2, children, ...props }) => (
|
|
89
|
+
<linearGradient id={id} x1={x1} y1={y1} x2={x2} y2={y2} {...props}>
|
|
90
|
+
{children}
|
|
91
|
+
</linearGradient>
|
|
92
|
+
);
|
|
93
|
+
|
|
94
|
+
export const RadialGradient = ({ id, cx, cy, r, fx, fy, children, ...props }) => (
|
|
95
|
+
<radialGradient id={id} cx={cx} cy={cy} r={r} fx={fx} fy={fy} {...props}>
|
|
96
|
+
{children}
|
|
97
|
+
</radialGradient>
|
|
98
|
+
);
|
|
99
|
+
|
|
100
|
+
export const Stop = ({ offset, stopColor, stopOpacity, ...props }) => (
|
|
101
|
+
<stop
|
|
102
|
+
offset={offset}
|
|
103
|
+
stopColor={stopColor}
|
|
104
|
+
stopOpacity={stopOpacity}
|
|
105
|
+
{...props}
|
|
106
|
+
/>
|
|
107
|
+
);
|
|
108
|
+
|
|
109
|
+
export const ClipPath = ({ id, children }) => (
|
|
110
|
+
<clipPath id={id}>{children}</clipPath>
|
|
111
|
+
);
|
|
112
|
+
|
|
113
|
+
export const Mask = ({ id, children }) => (
|
|
114
|
+
<mask id={id}>{children}</mask>
|
|
115
|
+
);
|
|
116
|
+
|
|
117
|
+
export const Use = ({ href, ...props }) => <use href={href} {...props} />;
|
|
118
|
+
|
|
119
|
+
export default Svg;
|
|
120
|
+
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import { defineConfig } from 'vite';
|
|
2
|
+
import react from '@vitejs/plugin-react';
|
|
3
|
+
import path from 'path';
|
|
4
|
+
|
|
5
|
+
// Check if we're running in development (inside the SDK repo)
|
|
6
|
+
const isDev = process.cwd().includes('zopassport-sdk');
|
|
7
|
+
|
|
8
|
+
export default defineConfig({
|
|
9
|
+
plugins: [react()],
|
|
10
|
+
resolve: {
|
|
11
|
+
alias: [
|
|
12
|
+
// Mock native-only libraries FIRST (order matters!)
|
|
13
|
+
{
|
|
14
|
+
find: /^react-native-reanimated$/,
|
|
15
|
+
replacement: path.resolve(__dirname, 'reanimated-mock.jsx'),
|
|
16
|
+
},
|
|
17
|
+
{
|
|
18
|
+
find: /^react-native-svg$/,
|
|
19
|
+
replacement: path.resolve(__dirname, 'svg-mock.jsx'),
|
|
20
|
+
},
|
|
21
|
+
// React Native Web (must use absolute path)
|
|
22
|
+
{
|
|
23
|
+
find: /^react-native$/,
|
|
24
|
+
replacement: path.resolve(__dirname, 'node_modules/react-native-web'),
|
|
25
|
+
},
|
|
26
|
+
// In development, resolve zopassport to the local source
|
|
27
|
+
...(isDev ? [
|
|
28
|
+
{
|
|
29
|
+
find: /^zopassport\/react$/,
|
|
30
|
+
replacement: path.resolve(__dirname, '../src/react.tsx'),
|
|
31
|
+
},
|
|
32
|
+
{
|
|
33
|
+
find: /^zopassport$/,
|
|
34
|
+
replacement: path.resolve(__dirname, '../src/index.ts'),
|
|
35
|
+
},
|
|
36
|
+
] : []),
|
|
37
|
+
],
|
|
38
|
+
extensions: ['.web.tsx', '.web.ts', '.web.js', '.tsx', '.ts', '.js'],
|
|
39
|
+
},
|
|
40
|
+
define: {
|
|
41
|
+
global: 'window',
|
|
42
|
+
__DEV__: JSON.stringify(true),
|
|
43
|
+
},
|
|
44
|
+
optimizeDeps: {
|
|
45
|
+
// Force Vite to pre-bundle these
|
|
46
|
+
include: ['react', 'react-dom', 'axios', 'moment'],
|
|
47
|
+
// Exclude native libraries from optimization
|
|
48
|
+
exclude: ['react-native-reanimated', 'react-native-svg'],
|
|
49
|
+
},
|
|
50
|
+
server: {
|
|
51
|
+
port: 3000,
|
|
52
|
+
open: true,
|
|
53
|
+
fs: {
|
|
54
|
+
// Allow serving files from the parent assets folder
|
|
55
|
+
allow: ['..'],
|
|
56
|
+
},
|
|
57
|
+
},
|
|
58
|
+
// In dev, serve assets from parent SDK folder
|
|
59
|
+
publicDir: isDev ? path.resolve(__dirname, '../assets') : 'public',
|
|
60
|
+
build: {
|
|
61
|
+
outDir: 'dist',
|
|
62
|
+
sourcemap: true,
|
|
63
|
+
rollupOptions: {
|
|
64
|
+
external: ['react-native-worklets'],
|
|
65
|
+
},
|
|
66
|
+
},
|
|
67
|
+
});
|
|
68
|
+
|
|
69
|
+
|
|
70
|
+
|
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
# Zo Passport SDK - Assets Manifest
|
|
2
|
+
|
|
3
|
+
All required assets for the complete phone → avatar → passport flow.
|
|
4
|
+
|
|
5
|
+
## 📂 Directory Structure
|
|
6
|
+
|
|
7
|
+
```
|
|
8
|
+
assets/
|
|
9
|
+
├── bro.png # Male avatar preview (256x256)
|
|
10
|
+
├── bae.png # Female avatar preview (256x256)
|
|
11
|
+
├── zo-fallback.png # Default fallback avatar
|
|
12
|
+
├── zo-coin.gif # Animated $Zo coin
|
|
13
|
+
│
|
|
14
|
+
├── figma-assets/
|
|
15
|
+
│ └── landing-zo-logo.png # Zo logo (60x60)
|
|
16
|
+
│
|
|
17
|
+
├── videos/
|
|
18
|
+
│ ├── loading-screen-background.mp4 # Landing/onboarding bg video
|
|
19
|
+
│ └── opening-disks.mp4 # Portal animation
|
|
20
|
+
│
|
|
21
|
+
├── images/
|
|
22
|
+
│ └── rank1.jpeg # Fallback avatar
|
|
23
|
+
│
|
|
24
|
+
├── cultural-stickers/ # 17 culture icons
|
|
25
|
+
│ ├── Business.png
|
|
26
|
+
│ ├── Design.png
|
|
27
|
+
│ ├── Food.png
|
|
28
|
+
│ ├── Game.png
|
|
29
|
+
│ ├── Health&Fitness.png
|
|
30
|
+
│ ├── Home&Lifestyle.png
|
|
31
|
+
│ ├── Law.png
|
|
32
|
+
│ ├── Literature&Stories.png
|
|
33
|
+
│ ├── Music&Entertainment.png
|
|
34
|
+
│ ├── Nature&Wildlife.png
|
|
35
|
+
│ ├── Photography.png
|
|
36
|
+
│ ├── Science&Technology.png
|
|
37
|
+
│ ├── Spiritual.png
|
|
38
|
+
│ ├── Sport.png
|
|
39
|
+
│ ├── Stories&Journal.png
|
|
40
|
+
│ ├── Television&Cinema.png
|
|
41
|
+
│ └── Travel&Adventure.png
|
|
42
|
+
│
|
|
43
|
+
└── lotties/
|
|
44
|
+
├── loader.json # Loading animation
|
|
45
|
+
└── spinner.json # Button spinner
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
## 🌐 CDN Assets (Not Bundled)
|
|
49
|
+
|
|
50
|
+
These are loaded from Zo CDN and don't need to be bundled:
|
|
51
|
+
|
|
52
|
+
| Asset | URL |
|
|
53
|
+
|-------|-----|
|
|
54
|
+
| Founder Passport BG | `https://proxy.cdn.zo.xyz/gallery/media/images/a1659b07-94f0-4490-9b3c-3366715d9717_20250515053726.png` |
|
|
55
|
+
| Citizen Passport BG | `https://proxy.cdn.zo.xyz/gallery/media/images/bda9da5a-eefe-411d-8d90-667c80024463_20250515053805.png` |
|
|
56
|
+
|
|
57
|
+
## 📦 Usage
|
|
58
|
+
|
|
59
|
+
### Copy to Public Folder
|
|
60
|
+
|
|
61
|
+
```bash
|
|
62
|
+
# Copy all assets to your public folder
|
|
63
|
+
cp -r packages/zopassport/assets/* public/
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
### Import Paths (After copying to public/)
|
|
67
|
+
|
|
68
|
+
```tsx
|
|
69
|
+
// In your components
|
|
70
|
+
const videoUrl = '/videos/loading-screen-background.mp4';
|
|
71
|
+
const logoUrl = '/figma-assets/landing-zo-logo.png';
|
|
72
|
+
const broAvatarUrl = '/bro.png';
|
|
73
|
+
const baeAvatarUrl = '/bae.png';
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
### Or Reference from SDK
|
|
77
|
+
|
|
78
|
+
```tsx
|
|
79
|
+
import { ZoLanding } from '@zo/passport/react';
|
|
80
|
+
|
|
81
|
+
<ZoLanding
|
|
82
|
+
videoUrl="/assets/videos/loading-screen-background.mp4"
|
|
83
|
+
logoUrl="/assets/figma-assets/landing-zo-logo.png"
|
|
84
|
+
/>
|
|
85
|
+
```
|
|
86
|
+
|
|
87
|
+
## 📊 File Sizes
|
|
88
|
+
|
|
89
|
+
| Asset | Size (approx) |
|
|
90
|
+
|-------|---------------|
|
|
91
|
+
| loading-screen-background.mp4 | ~2 MB |
|
|
92
|
+
| opening-disks.mp4 | ~500 KB |
|
|
93
|
+
| Cultural stickers (all) | ~200 KB |
|
|
94
|
+
| Avatar previews | ~50 KB each |
|
|
95
|
+
| Lotties | ~10 KB each |
|
|
96
|
+
|
|
97
|
+
**Total Bundle**: ~3 MB
|
|
98
|
+
|
|
99
|
+
## 🎨 Culture Sticker Mapping
|
|
100
|
+
|
|
101
|
+
| ID | Name | File |
|
|
102
|
+
|----|------|------|
|
|
103
|
+
| `travel` | Travel & Adventure | `Travel&Adventure.png` |
|
|
104
|
+
| `design` | Design | `Design.png` |
|
|
105
|
+
| `tech` | Science & Technology | `Science&Technology.png` |
|
|
106
|
+
| `food` | Food | `Food.png` |
|
|
107
|
+
| `music` | Music & Entertainment | `Music&Entertainment.png` |
|
|
108
|
+
| `photography` | Photography | `Photography.png` |
|
|
109
|
+
| `fitness` | Health & Fitness | `Health&Fitness.png` |
|
|
110
|
+
| `sports` | Sport | `Sport.png` |
|
|
111
|
+
| `literature` | Literature & Stories | `Literature&Stories.png` |
|
|
112
|
+
| `cinema` | Television & Cinema | `Television&Cinema.png` |
|
|
113
|
+
| `spiritual` | Spiritual | `Spiritual.png` |
|
|
114
|
+
| `nature` | Nature & Wildlife | `Nature&Wildlife.png` |
|
|
115
|
+
| `business` | Business | `Business.png` |
|
|
116
|
+
| `law` | Law | `Law.png` |
|
|
117
|
+
| `lifestyle` | Home & Lifestyle | `Home&Lifestyle.png` |
|
|
118
|
+
| `gaming` | Game | `Game.png` |
|
|
119
|
+
| `stories` | Stories & Journal | `Stories&Journal.png` |
|
|
120
|
+
|
|
121
|
+
---
|
|
122
|
+
|
|
123
|
+
*Generated: December 2025*
|
|
124
|
+
|
package/assets/bae.png
ADDED
|
Binary file
|
package/assets/bro.png
ADDED
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|