@digilogiclabs/create-saas-app 2.8.0 → 2.9.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/.tsbuildinfo +1 -1
- package/dist/generators/template-generator.js +8 -8
- package/dist/generators/template-generator.js.map +1 -1
- package/dist/templates/shared/quality/web/src/__tests__/accessibility.test.tsx +3 -3
- package/dist/templates/web/ai-platform/template/src/app/page.tsx +207 -207
- package/dist/templates/web/base/template/package.json +1 -3
- package/dist/templates/web/base/template/src/app/auth/callback/route.ts +32 -18
- package/dist/templates/web/base/template/src/app/dashboard/page.tsx +6 -43
- package/dist/templates/web/base/template/src/app/globals.css +158 -157
- package/dist/templates/web/base/template/src/app/page.tsx +2 -2
- package/dist/templates/web/ui-auth/template/src/app/dev-setup/page.tsx +800 -800
- package/dist/templates/web/ui-auth/template/src/app/globals.css +96 -95
- package/dist/templates/web/ui-auth/template/src/app/login/page.tsx +109 -109
- package/dist/templates/web/ui-auth/template/src/app/page.tsx +4 -3
- package/dist/templates/web/ui-auth/template/src/app/signup/page.tsx +128 -128
- package/dist/templates/web/ui-auth-ai/template/src/app/globals.css +35 -40
- package/dist/templates/web/ui-auth-ai/template/src/app/layout.tsx +1 -0
- package/dist/templates/web/ui-auth-payments/template/src/app/checkout/page.tsx +3 -3
- package/dist/templates/web/ui-auth-payments/template/src/app/dashboard/page.tsx +10 -49
- package/dist/templates/web/ui-auth-payments/template/src/app/dev-setup/page.tsx +800 -800
- package/dist/templates/web/ui-auth-payments/template/src/app/globals.css +212 -211
- package/dist/templates/web/ui-auth-payments/template/src/app/login/page.tsx +109 -109
- package/dist/templates/web/ui-auth-payments/template/src/app/page.tsx +350 -350
- package/dist/templates/web/ui-auth-payments/template/src/app/setup/page.tsx +506 -506
- package/dist/templates/web/ui-auth-payments/template/src/app/signup/page.tsx +128 -128
- package/dist/templates/web/ui-auth-payments/template/src/components/client/login-form.tsx +143 -143
- package/dist/templates/web/ui-auth-payments/template/src/components/client/signup-form.tsx +184 -184
- package/dist/templates/web/ui-auth-payments-ai/template/src/app/billing/page.tsx +143 -233
- package/dist/templates/web/ui-auth-payments-ai/template/src/app/dashboard/page.tsx +10 -50
- package/dist/templates/web/ui-auth-payments-ai/template/src/app/dev-setup/page.tsx +800 -800
- package/dist/templates/web/ui-auth-payments-ai/template/src/app/globals.css +97 -96
- package/dist/templates/web/ui-auth-payments-ai/template/src/app/onboarding/page.tsx +325 -364
- package/dist/templates/web/ui-auth-payments-ai/template/src/app/page.tsx +1 -1
- package/dist/templates/web/ui-auth-payments-ai/template/src/app/settings/page.tsx +389 -532
- package/dist/templates/web/ui-auth-payments-ai/template/src/app/setup/page.tsx +644 -644
- package/dist/templates/web/ui-auth-payments-ai/template/src/components/client/login-form.tsx +119 -163
- package/dist/templates/web/ui-auth-payments-ai/template/src/components/client/signup-form.tsx +158 -201
- package/dist/templates/web/ui-auth-payments-ai-rag/template/package.json +1 -2
- package/dist/templates/web/ui-auth-payments-audio/template/src/app/dashboard/page.tsx +10 -51
- package/dist/templates/web/ui-auth-payments-audio/template/src/app/globals.css +97 -96
- package/dist/templates/web/ui-auth-payments-audio/template/src/app/page.tsx +402 -403
- package/dist/templates/web/ui-auth-payments-audio/template/src/components/client/login-form.tsx +143 -143
- package/dist/templates/web/ui-auth-payments-audio/template/src/components/client/signup-form.tsx +184 -184
- package/dist/templates/web/ui-auth-payments-video/template/src/app/globals.css +229 -228
- package/dist/templates/web/ui-auth-payments-video/template/src/app/login/page.tsx +1 -1
- package/dist/templates/web/ui-auth-payments-video/template/src/app/page.tsx +4 -7
- package/dist/templates/web/ui-auth-payments-video/template/src/app/signup/page.tsx +1 -1
- package/dist/templates/web/ui-only/template/src/app/globals.css +43 -42
- package/package.json +1 -1
- package/src/templates/shared/quality/web/src/__tests__/accessibility.test.tsx +3 -3
- package/src/templates/web/ai-platform/template/src/app/page.tsx +207 -207
- package/src/templates/web/base/template/package.json +1 -3
- package/src/templates/web/base/template/src/app/auth/callback/route.ts +32 -18
- package/src/templates/web/base/template/src/app/dashboard/page.tsx +6 -43
- package/src/templates/web/base/template/src/app/globals.css +158 -157
- package/src/templates/web/base/template/src/app/page.tsx +2 -2
- package/src/templates/web/ui-auth/template/src/app/dev-setup/page.tsx +800 -800
- package/src/templates/web/ui-auth/template/src/app/globals.css +96 -95
- package/src/templates/web/ui-auth/template/src/app/login/page.tsx +109 -109
- package/src/templates/web/ui-auth/template/src/app/page.tsx +4 -3
- package/src/templates/web/ui-auth/template/src/app/signup/page.tsx +128 -128
- package/src/templates/web/ui-auth-ai/template/src/app/globals.css +35 -40
- package/src/templates/web/ui-auth-ai/template/src/app/layout.tsx +1 -0
- package/src/templates/web/ui-auth-payments/template/src/app/checkout/page.tsx +3 -3
- package/src/templates/web/ui-auth-payments/template/src/app/dashboard/page.tsx +10 -49
- package/src/templates/web/ui-auth-payments/template/src/app/dev-setup/page.tsx +800 -800
- package/src/templates/web/ui-auth-payments/template/src/app/globals.css +212 -211
- package/src/templates/web/ui-auth-payments/template/src/app/login/page.tsx +109 -109
- package/src/templates/web/ui-auth-payments/template/src/app/page.tsx +350 -350
- package/src/templates/web/ui-auth-payments/template/src/app/setup/page.tsx +506 -506
- package/src/templates/web/ui-auth-payments/template/src/app/signup/page.tsx +128 -128
- package/src/templates/web/ui-auth-payments/template/src/components/client/login-form.tsx +143 -143
- package/src/templates/web/ui-auth-payments/template/src/components/client/signup-form.tsx +184 -184
- package/src/templates/web/ui-auth-payments-ai/template/src/app/billing/page.tsx +143 -233
- package/src/templates/web/ui-auth-payments-ai/template/src/app/dashboard/page.tsx +10 -50
- package/src/templates/web/ui-auth-payments-ai/template/src/app/dev-setup/page.tsx +800 -800
- package/src/templates/web/ui-auth-payments-ai/template/src/app/globals.css +97 -96
- package/src/templates/web/ui-auth-payments-ai/template/src/app/onboarding/page.tsx +325 -364
- package/src/templates/web/ui-auth-payments-ai/template/src/app/page.tsx +1 -1
- package/src/templates/web/ui-auth-payments-ai/template/src/app/settings/page.tsx +389 -532
- package/src/templates/web/ui-auth-payments-ai/template/src/app/setup/page.tsx +644 -644
- package/src/templates/web/ui-auth-payments-ai/template/src/components/client/login-form.tsx +119 -163
- package/src/templates/web/ui-auth-payments-ai/template/src/components/client/signup-form.tsx +158 -201
- package/src/templates/web/ui-auth-payments-ai-rag/template/package.json +1 -2
- package/src/templates/web/ui-auth-payments-audio/template/src/app/dashboard/page.tsx +10 -51
- package/src/templates/web/ui-auth-payments-audio/template/src/app/globals.css +97 -96
- package/src/templates/web/ui-auth-payments-audio/template/src/app/page.tsx +402 -403
- package/src/templates/web/ui-auth-payments-audio/template/src/components/client/login-form.tsx +143 -143
- package/src/templates/web/ui-auth-payments-audio/template/src/components/client/signup-form.tsx +184 -184
- package/src/templates/web/ui-auth-payments-video/template/src/app/globals.css +229 -228
- package/src/templates/web/ui-auth-payments-video/template/src/app/login/page.tsx +1 -1
- package/src/templates/web/ui-auth-payments-video/template/src/app/page.tsx +4 -7
- package/src/templates/web/ui-auth-payments-video/template/src/app/signup/page.tsx +1 -1
- package/src/templates/web/ui-only/template/src/app/globals.css +43 -42
|
@@ -1,403 +1,402 @@
|
|
|
1
|
-
'use client'
|
|
2
|
-
|
|
3
|
-
import {
|
|
4
|
-
Button,
|
|
5
|
-
Card,
|
|
6
|
-
AudioPlayer,
|
|
7
|
-
PageTransition,
|
|
8
|
-
MobileContainer,
|
|
9
|
-
MobileHero,
|
|
10
|
-
ResponsiveGrid,
|
|
11
|
-
NetworkAwareContent,
|
|
12
|
-
OfflineWrapper,
|
|
13
|
-
SwipeableCard,
|
|
14
|
-
PullToRefresh,
|
|
15
|
-
useNetworkInfo,
|
|
16
|
-
useOfflineState,
|
|
17
|
-
FixedAudioBar,
|
|
18
|
-
PlaylistCard,
|
|
19
|
-
TrackList,
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
} from '
|
|
34
|
-
import {
|
|
35
|
-
import
|
|
36
|
-
import
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
const
|
|
41
|
-
const
|
|
42
|
-
const
|
|
43
|
-
const [
|
|
44
|
-
const [
|
|
45
|
-
const [
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
const
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
const
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
const
|
|
57
|
-
const
|
|
58
|
-
const
|
|
59
|
-
const
|
|
60
|
-
const
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
<div className="absolute inset-0 bg-gradient-to-
|
|
165
|
-
<div className="absolute inset-0 bg-gradient-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
<div className="absolute top-
|
|
170
|
-
<div className="absolute top-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
<div className="
|
|
175
|
-
<
|
|
176
|
-
|
|
177
|
-
{
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
{
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
{
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
}
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
{ id: '
|
|
313
|
-
{ id: '
|
|
314
|
-
{ id: '
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
{
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
</
|
|
331
|
-
<
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
</
|
|
341
|
-
<
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
</
|
|
351
|
-
<
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
</
|
|
363
|
-
<
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
</
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
{
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
const
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
const
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
}
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
}
|
|
1
|
+
'use client'
|
|
2
|
+
|
|
3
|
+
import {
|
|
4
|
+
Button,
|
|
5
|
+
Card,
|
|
6
|
+
AudioPlayer,
|
|
7
|
+
PageTransition,
|
|
8
|
+
MobileContainer,
|
|
9
|
+
MobileHero,
|
|
10
|
+
ResponsiveGrid,
|
|
11
|
+
NetworkAwareContent,
|
|
12
|
+
OfflineWrapper,
|
|
13
|
+
SwipeableCard,
|
|
14
|
+
PullToRefresh,
|
|
15
|
+
useNetworkInfo,
|
|
16
|
+
useOfflineState,
|
|
17
|
+
FixedAudioBar,
|
|
18
|
+
PlaylistCard,
|
|
19
|
+
TrackList,
|
|
20
|
+
WaveformPlayer,
|
|
21
|
+
VolumeSlider,
|
|
22
|
+
ProgressBar,
|
|
23
|
+
ShuffleButton,
|
|
24
|
+
RepeatButton,
|
|
25
|
+
LikeButton,
|
|
26
|
+
ShareButton,
|
|
27
|
+
PlaylistSidebar,
|
|
28
|
+
AudioSearch,
|
|
29
|
+
NowPlayingCard,
|
|
30
|
+
useAnimationTokens,
|
|
31
|
+
useGlassmorphism
|
|
32
|
+
} from '@digilogiclabs/saas-factory-ui'
|
|
33
|
+
import { ArrowRight, Zap, Shield, Rocket, CheckCircle, LogOut, User, Music, Wifi, WifiOff } from 'lucide-react'
|
|
34
|
+
import { useAuth } from '@digilogiclabs/app-sdk'
|
|
35
|
+
import Link from 'next/link'
|
|
36
|
+
import { useState } from 'react'
|
|
37
|
+
|
|
38
|
+
export default function Home() {
|
|
39
|
+
const { user, signOut, loading } = useAuth()
|
|
40
|
+
const networkInfo = useNetworkInfo()
|
|
41
|
+
const isOnline = useOfflineState()
|
|
42
|
+
const [isRefreshing, setIsRefreshing] = useState(false)
|
|
43
|
+
const [currentTrack, setCurrentTrack] = useState(null)
|
|
44
|
+
const [isPlaying, setIsPlaying] = useState(false)
|
|
45
|
+
const [showPlaylistSidebar, setShowPlaylistSidebar] = useState(false)
|
|
46
|
+
|
|
47
|
+
// Modern design tokens
|
|
48
|
+
const animations = useAnimationTokens()
|
|
49
|
+
const glass = useGlassmorphism()
|
|
50
|
+
|
|
51
|
+
const projectName = "{{projectName}}"
|
|
52
|
+
const projectDescription = "{{description}}"
|
|
53
|
+
|
|
54
|
+
// Static glassmorphism classes to avoid template literal corruption
|
|
55
|
+
const glassCard = "bg-white/10 backdrop-blur-lg border border-white/20"
|
|
56
|
+
const glassCardRounded = "bg-white/10 backdrop-blur-lg border border-white/20 rounded-2xl"
|
|
57
|
+
const glassCardWithHover = "bg-white/10 backdrop-blur-lg border border-white/20 rounded-2xl hover:scale-105 transition-all duration-300"
|
|
58
|
+
const glassAccentIcon = "bg-white/10 backdrop-blur-lg border border-white/20 rounded-xl flex items-center justify-center hover:shadow-lg hover:shadow-purple-500/25 transition-all duration-300"
|
|
59
|
+
const glassBackground = "bg-gradient-to-br from-purple-900/20 via-blue-900/20 to-teal-900/20"
|
|
60
|
+
const glassBackgroundAccent = "bg-gradient-to-br from-purple-500/10 via-blue-500/10 to-teal-500/10"
|
|
61
|
+
|
|
62
|
+
const gridConfig = {
|
|
63
|
+
columns_1_2: { base: 1, md: 2 },
|
|
64
|
+
columns_1_3: { base: 1, md: 3 },
|
|
65
|
+
columns_1_sm2: { base: 1, sm: 2 },
|
|
66
|
+
columns_1_sm2_md3: { base: 1, sm: 2, md: 3 },
|
|
67
|
+
columns_1_sm2_md4: { base: 1, sm: 2, md: 4 },
|
|
68
|
+
columns_2: { base: 2 },
|
|
69
|
+
columns_2_md3: { base: 2, md: 3 },
|
|
70
|
+
columns_2_2: { base: 2 },
|
|
71
|
+
columns_2_md4: { base: 2, md: 4 }
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
// Demo playlist data
|
|
75
|
+
const demoPlaylist = [
|
|
76
|
+
{
|
|
77
|
+
id: '1',
|
|
78
|
+
title: 'Midnight Echoes',
|
|
79
|
+
artist: 'Luna Rivers',
|
|
80
|
+
album: 'Digital Dreams',
|
|
81
|
+
duration: 180,
|
|
82
|
+
url: 'https://www.soundjay.com/misc/sounds/bell-ringing-05.mp3',
|
|
83
|
+
coverArt: 'data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzAwIiBoZWlnaHQ9IjMwMCIgdmlld0JveD0iMCAwIDMwMCAzMDAiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHJlY3Qgd2lkdGg9IjMwMCIgaGVpZ2h0PSIzMDAiIGZpbGw9IiM4QjVDRjYiLz48Y2lyY2xlIGN4PSIxNTAiIGN5PSIxNTAiIHI9IjYwIiBmaWxsPSJ3aGl0ZSIgZmlsbC1vcGFjaXR5PSIwLjIiLz48cGF0aCBkPSJNMTMwIDEyMFYxODBMMTcwIDE1MEwxMzAgMTIwWiIgZmlsbD0id2hpdGUiLz48L3N2Zz4=',
|
|
84
|
+
liked: false
|
|
85
|
+
},
|
|
86
|
+
{
|
|
87
|
+
id: '2',
|
|
88
|
+
title: 'Neon Nights',
|
|
89
|
+
artist: 'The Frequency',
|
|
90
|
+
album: 'Electric Pulse',
|
|
91
|
+
duration: 210,
|
|
92
|
+
url: 'https://www.soundjay.com/misc/sounds/bell-ringing-05.mp3',
|
|
93
|
+
coverArt: 'data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzAwIiBoZWlnaHQ9IjMwMCIgdmlld0JveD0iMCAwIDMwMCAzMDAiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHJlY3Qgd2lkdGg9IjMwMCIgaGVpZ2h0PSIzMDAiIGZpbGw9IiNFRjQ0NDQiLz48Y2lyY2xlIGN4PSIxNTAiIGN5PSIxNTAiIHI9IjYwIiBmaWxsPSJ3aGl0ZSIgZmlsbC1vcGFjaXR5PSIwLjIiLz48cGF0aCBkPSJNMTMwIDEyMFYxODBMMTcwIDE1MEwxMzAgMTIwWiIgZmlsbD0id2hpdGUiLz48L3N2Zz4=',
|
|
94
|
+
liked: true
|
|
95
|
+
},
|
|
96
|
+
{
|
|
97
|
+
id: '3',
|
|
98
|
+
title: 'Ocean Waves',
|
|
99
|
+
artist: 'Ambient Flow',
|
|
100
|
+
album: 'Nature Sounds',
|
|
101
|
+
duration: 195,
|
|
102
|
+
url: 'https://www.soundjay.com/misc/sounds/bell-ringing-05.mp3',
|
|
103
|
+
coverArt: 'data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzAwIiBoZWlnaHQ9IjMwMCIgdmlld0JveD0iMCAwIDMwMCAzMDAiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHJlY3Qgd2lkdGg9IjMwMCIgaGVpZ2h0PSIzMDAiIGZpbGw9IiMwNjkyQzUiLz48Y2lyY2xlIGN4PSIxNTAiIGN5PSIxNTAiIHI9IjYwIiBmaWxsPSJ3aGl0ZSIgZmlsbC1vcGFjaXR5PSIwLjIiLz48cGF0aCBkPSJNMTMwIDEyMFYxODBMMTcwIDE1MEwxMzAgMTIwWiIgZmlsbD0id2hpdGUiLz48L3N2Zz4=',
|
|
104
|
+
liked: false
|
|
105
|
+
},
|
|
106
|
+
{
|
|
107
|
+
id: '4',
|
|
108
|
+
title: 'City Lights',
|
|
109
|
+
artist: 'Urban Echo',
|
|
110
|
+
album: 'Metropolitan',
|
|
111
|
+
duration: 225,
|
|
112
|
+
url: 'https://www.soundjay.com/misc/sounds/bell-ringing-05.mp3',
|
|
113
|
+
coverArt: 'data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzAwIiBoZWlnaHQ9IjMwMCIgdmlld0JveD0iMCAwIDMwMCAzMDAiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHJlY3Qgd2lkdGg9IjMwMCIgaGVpZ2h0PSIzMDAiIGZpbGw9IiNGNTk3MDAiLz48Y2lyY2xlIGN4PSIxNTAiIGN5PSIxNTAiIHI9IjYwIiBmaWxsPSJ3aGl0ZSIgZmlsbC1vcGFjaXR5PSIwLjIiLz48cGF0aCBkPSJNMTMwIDEyMFYxODBMMTcwIDE1MEwxMzAgMTIwWiIgZmlsbD0id2hpdGUiLz48L3N2Zz4=',
|
|
114
|
+
liked: true
|
|
115
|
+
}
|
|
116
|
+
]
|
|
117
|
+
|
|
118
|
+
const heroConfig = {
|
|
119
|
+
badge: {
|
|
120
|
+
text: "🎵 Premium Audio Experience",
|
|
121
|
+
variant: "secondary" as const,
|
|
122
|
+
icon: <CheckCircle className="w-4 h-4" />
|
|
123
|
+
},
|
|
124
|
+
title: {
|
|
125
|
+
text: "Welcome to " + projectName,
|
|
126
|
+
highlight: projectName,
|
|
127
|
+
size: "xl" as const
|
|
128
|
+
},
|
|
129
|
+
description: projectDescription + ". Stream your favorite music with crystal-clear quality, offline downloads, and seamless playback across all your devices."
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
const handleSignOut = async () => {
|
|
133
|
+
try {
|
|
134
|
+
await signOut()
|
|
135
|
+
} catch (err) {
|
|
136
|
+
console.error('Sign out error:', err)
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
const handleRefresh = async () => {
|
|
141
|
+
setIsRefreshing(true)
|
|
142
|
+
// Simulate refresh
|
|
143
|
+
await new Promise(resolve => setTimeout(resolve, 1500))
|
|
144
|
+
setIsRefreshing(false)
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
return (
|
|
148
|
+
<PageTransition type="fade" duration={300}>
|
|
149
|
+
<OfflineWrapper
|
|
150
|
+
cacheStrategy="stale-while-revalidate"
|
|
151
|
+
showOfflineIndicator={true}
|
|
152
|
+
backgroundSync={true}
|
|
153
|
+
>
|
|
154
|
+
<PullToRefresh
|
|
155
|
+
onRefresh={handleRefresh}
|
|
156
|
+
threshold={80}
|
|
157
|
+
loadingIndicator="spinner"
|
|
158
|
+
hapticOnTrigger={true}
|
|
159
|
+
networkAware={true}
|
|
160
|
+
>
|
|
161
|
+
<main className="min-h-screen relative overflow-hidden bg-background">
|
|
162
|
+
{/* Theme-aware gradient background for audio streaming */}
|
|
163
|
+
<div className="absolute inset-0 bg-gradient-to-br from-primary/15 via-background to-accent/15 dark:from-primary/25 dark:via-background dark:to-accent/25" />
|
|
164
|
+
<div className="absolute inset-0 bg-gradient-to-tr from-secondary/10 via-transparent to-primary/10 dark:from-secondary/15 dark:via-transparent dark:to-primary/15" />
|
|
165
|
+
<div className="absolute inset-0 bg-[radial-gradient(ellipse_at_bottom_left,_var(--tw-gradient-stops))] from-accent/20 via-transparent to-transparent dark:from-accent/30 dark:via-transparent dark:to-transparent" />
|
|
166
|
+
{/* Animated music-themed particles */}
|
|
167
|
+
<div className="absolute inset-0 opacity-25 dark:opacity-15">
|
|
168
|
+
<div className="absolute top-1/3 left-1/6 w-64 h-64 bg-primary/50 rounded-full mix-blend-multiply filter blur-3xl animate-pulse dark:bg-primary/70"></div>
|
|
169
|
+
<div className="absolute top-2/3 right-1/5 w-80 h-80 bg-accent/50 rounded-full mix-blend-multiply filter blur-3xl animate-pulse animation-delay-2000 dark:bg-accent/70"></div>
|
|
170
|
+
<div className="absolute top-1/5 right-1/3 w-56 h-56 bg-secondary/50 rounded-full mix-blend-multiply filter blur-3xl animate-pulse animation-delay-4000 dark:bg-secondary/70"></div>
|
|
171
|
+
</div>
|
|
172
|
+
{/* Audio wave overlay */}
|
|
173
|
+
<div className="absolute inset-0 bg-gradient-to-t from-transparent via-primary/5 to-transparent opacity-60" />
|
|
174
|
+
<div className="relative z-10">
|
|
175
|
+
<MobileContainer className="py-8">
|
|
176
|
+
{/* Simple Auth Status */}
|
|
177
|
+
{user && (
|
|
178
|
+
<div className="flex justify-end mb-8">
|
|
179
|
+
<div className="flex items-center gap-4">
|
|
180
|
+
<span className="text-sm text-gray-600 dark:text-gray-300">
|
|
181
|
+
Welcome, {user.email?.split('@')[0]}
|
|
182
|
+
</span>
|
|
183
|
+
<Button variant="outline" size="sm" onClick={handleSignOut}>
|
|
184
|
+
<LogOut className="w-4 h-4 mr-2" />
|
|
185
|
+
Sign Out
|
|
186
|
+
</Button>
|
|
187
|
+
</div>
|
|
188
|
+
</div>
|
|
189
|
+
)}
|
|
190
|
+
|
|
191
|
+
{!user && !loading && (
|
|
192
|
+
<div className="flex justify-end mb-8">
|
|
193
|
+
<div className="flex gap-2">
|
|
194
|
+
<Link href="/login">
|
|
195
|
+
<Button variant="outline" size="sm">Sign In</Button>
|
|
196
|
+
</Link>
|
|
197
|
+
<Link href="/signup">
|
|
198
|
+
<Button size="sm">Sign Up</Button>
|
|
199
|
+
</Link>
|
|
200
|
+
</div>
|
|
201
|
+
</div>
|
|
202
|
+
)}
|
|
203
|
+
|
|
204
|
+
{/* Hero Section with Search */}
|
|
205
|
+
<MobileHero
|
|
206
|
+
badge={heroConfig.badge}
|
|
207
|
+
title={heroConfig.title}
|
|
208
|
+
description={heroConfig.description}
|
|
209
|
+
actions={[
|
|
210
|
+
{
|
|
211
|
+
label: "View Pricing",
|
|
212
|
+
href: "/checkout",
|
|
213
|
+
icon: ArrowRight,
|
|
214
|
+
variant: "default",
|
|
215
|
+
size: "lg"
|
|
216
|
+
},
|
|
217
|
+
{
|
|
218
|
+
label: "Learn More",
|
|
219
|
+
variant: "outline",
|
|
220
|
+
size: "lg"
|
|
221
|
+
}
|
|
222
|
+
]}
|
|
223
|
+
className="text-center mb-8"
|
|
224
|
+
/>
|
|
225
|
+
|
|
226
|
+
{/* Search Bar with Glassmorphism */}
|
|
227
|
+
<div className="max-w-2xl mx-auto mb-12">
|
|
228
|
+
<div className={glass.card + " " + glass.border + " p-1 rounded-2xl " + animations.hover.lift}>
|
|
229
|
+
<AudioSearch
|
|
230
|
+
placeholder="Search for tracks, artists, or albums..."
|
|
231
|
+
onSearch={(query) => console.log('Searching:', query)}
|
|
232
|
+
showTrending={true}
|
|
233
|
+
recentSearches={['Luna Rivers', 'Ambient Flow', 'Electronic']}
|
|
234
|
+
className="w-full bg-transparent border-none"
|
|
235
|
+
/>
|
|
236
|
+
</div>
|
|
237
|
+
</div>
|
|
238
|
+
|
|
239
|
+
{/* Main Content Area */}
|
|
240
|
+
<div className="grid grid-cols-1 lg:grid-cols-4 gap-8 mb-20">
|
|
241
|
+
{/* Main Content */}
|
|
242
|
+
<div className="lg:col-span-3 space-y-8">
|
|
243
|
+
{/* Now Playing Card with Enhanced Glassmorphism */}
|
|
244
|
+
<div className={glass.card + " " + glass.border + " rounded-3xl p-6 mb-8 " + animations.hover.lift + " " + animations.transition.smooth}>
|
|
245
|
+
<NowPlayingCard
|
|
246
|
+
track={currentTrack || demoPlaylist[0]}
|
|
247
|
+
isPlaying={isPlaying}
|
|
248
|
+
onPlayPause={() => setIsPlaying(!isPlaying)}
|
|
249
|
+
showWaveform={true}
|
|
250
|
+
className="bg-transparent"
|
|
251
|
+
/>
|
|
252
|
+
</div>
|
|
253
|
+
|
|
254
|
+
{/* Featured Playlists with Staggered Animation */}
|
|
255
|
+
<div className="grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 gap-6 mb-8">
|
|
256
|
+
<div className={glass.card + " " + glass.border + " rounded-2xl overflow-hidden " + animations.hover.scale + " " + animations.transition.smooth + " " + animations.delay.short}>
|
|
257
|
+
<PlaylistCard
|
|
258
|
+
title="Today's Top Hits"
|
|
259
|
+
description="The most played songs today"
|
|
260
|
+
trackCount={50}
|
|
261
|
+
coverImage="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzAwIiBoZWlnaHQ9IjMwMCIgdmlld0JveD0iMCAwIDMwMCAzMDAiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHJlY3Qgd2lkdGg9IjMwMCIgaGVpZ2h0PSIzMDAiIGZpbGw9IiNGRjc4NzgiLz48Y2lyY2xlIGN4PSIxNTAiIGN5PSIxNTAiIHI9IjYwIiBmaWxsPSJ3aGl0ZSIgZmlsbC1vcGFjaXR5PSIwLjMiLz48cGF0aCBkPSJNMTMwIDEyMFYxODBMMTcwIDE1MEwxMzAgMTIwWiIgZmlsbD0id2hpdGUiLz48L3N2Zz4="
|
|
262
|
+
onClick={() => console.log('Opening Top Hits playlist')}
|
|
263
|
+
className="bg-transparent border-none"
|
|
264
|
+
/>
|
|
265
|
+
</div>
|
|
266
|
+
<div className={glass.card + " " + glass.border + " rounded-2xl overflow-hidden " + animations.hover.scale + " " + animations.transition.smooth + " " + animations.delay.medium}>
|
|
267
|
+
<PlaylistCard
|
|
268
|
+
title="Chill Vibes"
|
|
269
|
+
description="Relaxing music for focus and creativity"
|
|
270
|
+
trackCount={32}
|
|
271
|
+
coverImage="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzAwIiBoZWlnaHQ9IjMwMCIgdmlld0JveD0iMCAwIDMwMCAzMDAiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHJlY3Qgd2lkdGg9IjMwMCIgaGVpZ2h0PSIzMDAiIGZpbGw9IiM2MEE1RkEiLz48Y2lyY2xlIGN4PSIxNTAiIGN5PSIxNTAiIHI9IjYwIiBmaWxsPSJ3aGl0ZSIgZmlsbC1vcGFjaXR5PSIwLjMiLz48cGF0aCBkPSJNMTMwIDEyMFYxODBMMTcwIDE1MEwxMzAgMTIwWiIgZmlsbD0id2hpdGUiLz48L3N2Zz4="
|
|
272
|
+
onClick={() => console.log('Opening Chill Vibes playlist')}
|
|
273
|
+
className="bg-transparent border-none"
|
|
274
|
+
/>
|
|
275
|
+
</div>
|
|
276
|
+
<div className={glass.card + " " + glass.border + " rounded-2xl overflow-hidden " + animations.hover.scale + " " + animations.transition.smooth + " " + animations.delay.long}>
|
|
277
|
+
<PlaylistCard
|
|
278
|
+
title="Electronic Pulse"
|
|
279
|
+
description="High-energy electronic and dance music"
|
|
280
|
+
trackCount={28}
|
|
281
|
+
coverImage="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzAwIiBoZWlnaHQ9IjMwMCIgdmlld0JveD0iMCAwIDMwMCAzMDAiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHJlY3Qgd2lkdGg9IjMwMCIgaGVpZ2h0PSIzMDAiIGZpbGw9IiM5QzI3QjAiLz48Y2lyY2xlIGN4PSIxNTAiIGN5PSIxNTAiIHI9IjYwIiBmaWxsPSJ3aGl0ZSIgZmlsbC1vcGFjaXR5PSIwLjMiLz48cGF0aCBkPSJNMTMwIDEyMFYxODBMMTcwIDE1MEwxMzAgMTIwWiIgZmlsbD0id2hpdGUiLz48L3N2Zz4="
|
|
282
|
+
onClick={() => console.log('Opening Electronic Pulse playlist')}
|
|
283
|
+
className="bg-transparent border-none"
|
|
284
|
+
/>
|
|
285
|
+
</div>
|
|
286
|
+
</div>
|
|
287
|
+
|
|
288
|
+
{/* Track List with Glassmorphism */}
|
|
289
|
+
<div className={glass.card + " " + glass.border + " rounded-2xl overflow-hidden " + animations.transition.smooth}>
|
|
290
|
+
<TrackList
|
|
291
|
+
tracks={demoPlaylist}
|
|
292
|
+
currentTrackId={currentTrack?.id}
|
|
293
|
+
onTrackSelect={(track) => setCurrentTrack(track)}
|
|
294
|
+
onTrackPlay={(track) => {
|
|
295
|
+
setCurrentTrack(track)
|
|
296
|
+
setIsPlaying(true)
|
|
297
|
+
}}
|
|
298
|
+
showArtwork={true}
|
|
299
|
+
showDuration={true}
|
|
300
|
+
showLikeButton={true}
|
|
301
|
+
className="mb-8 bg-transparent"
|
|
302
|
+
/>
|
|
303
|
+
</div>
|
|
304
|
+
</div>
|
|
305
|
+
|
|
306
|
+
{/* Sidebar with Glassmorphism */}
|
|
307
|
+
<div className="lg:col-span-1">
|
|
308
|
+
<div className={glass.card + " " + glass.border + " rounded-2xl overflow-hidden " + animations.hover.lift + " " + animations.transition.smooth}>
|
|
309
|
+
<PlaylistSidebar
|
|
310
|
+
playlists={[
|
|
311
|
+
{ id: '1', name: 'Liked Songs', trackCount: 47 },
|
|
312
|
+
{ id: '2', name: 'Recently Played', trackCount: 23 },
|
|
313
|
+
{ id: '3', name: 'My Playlist #1', trackCount: 15 },
|
|
314
|
+
{ id: '4', name: 'Favorites', trackCount: 32 }
|
|
315
|
+
]}
|
|
316
|
+
onPlaylistSelect={(playlist) => console.log('Selected playlist:', playlist)}
|
|
317
|
+
currentPlaylistId="1"
|
|
318
|
+
className="sticky top-4 bg-transparent"
|
|
319
|
+
/>
|
|
320
|
+
</div>
|
|
321
|
+
</div>
|
|
322
|
+
</div>
|
|
323
|
+
|
|
324
|
+
{/* Features Overview with Enhanced Glassmorphism */}
|
|
325
|
+
<ResponsiveGrid columns={gridConfig.columns_1_sm2_md4} gap={6} className="mb-16">
|
|
326
|
+
<div className={glass.card + " " + glass.border + " text-center p-6 rounded-2xl " + animations.hover.scale + " " + animations.transition.smooth + " " + animations.delay.short}>
|
|
327
|
+
<div className={"mx-auto w-12 h-12" + " " + glass.accent + " " + "rounded-xl flex items-center justify-center mb-4" + " " + animations.hover.glow}>
|
|
328
|
+
<Zap className="h-6 w-6 text-blue-400" />
|
|
329
|
+
</div>
|
|
330
|
+
<h3 className="text-lg font-semibold mb-2">High-Quality Streaming</h3>
|
|
331
|
+
<p className="text-sm text-gray-600 dark:text-gray-300">
|
|
332
|
+
Lossless audio with adaptive bitrate for the best experience
|
|
333
|
+
</p>
|
|
334
|
+
</div>
|
|
335
|
+
|
|
336
|
+
<div className={glass.card + " " + glass.border + " text-center p-6 rounded-2xl " + animations.hover.scale + " " + animations.transition.smooth + " " + animations.delay.medium}>
|
|
337
|
+
<div className={"mx-auto w-12 h-12" + " " + glass.accent + " " + "rounded-xl flex items-center justify-center mb-4" + " " + animations.hover.glow}>
|
|
338
|
+
<Shield className="h-6 w-6 text-green-400" />
|
|
339
|
+
</div>
|
|
340
|
+
<h3 className="text-lg font-semibold mb-2">Secure & Private</h3>
|
|
341
|
+
<p className="text-sm text-gray-600 dark:text-gray-300">
|
|
342
|
+
Your listening habits and data are always protected
|
|
343
|
+
</p>
|
|
344
|
+
</div>
|
|
345
|
+
|
|
346
|
+
<div className={glass.card + " " + glass.border + " text-center p-6 rounded-2xl " + animations.hover.scale + " " + animations.transition.smooth + " " + animations.delay.long}>
|
|
347
|
+
<div className={"mx-auto w-12 h-12" + " " + glass.accent + " " + "rounded-xl flex items-center justify-center mb-4" + " " + animations.hover.glow}>
|
|
348
|
+
<Rocket className="h-6 w-6 text-purple-400" />
|
|
349
|
+
</div>
|
|
350
|
+
<h3 className="text-lg font-semibold mb-2">Offline Support</h3>
|
|
351
|
+
<p className="text-sm text-gray-600 dark:text-gray-300">
|
|
352
|
+
Download your favorites for offline listening anywhere
|
|
353
|
+
</p>
|
|
354
|
+
</div>
|
|
355
|
+
|
|
356
|
+
<div className={glass.card + " " + glass.border + " text-center p-6 rounded-2xl " + animations.hover.scale + " " + animations.transition.smooth + " " + animations.delay.extra}>
|
|
357
|
+
<div className={"mx-auto w-12 h-12" + " " + glass.accent + " " + "rounded-xl flex items-center justify-center mb-4" + " " + animations.hover.glow}>
|
|
358
|
+
<svg className="h-6 w-6 text-orange-400" fill="none" stroke="currentColor" viewBox="0 0 24 24">
|
|
359
|
+
<path strokeLinecap="round" strokeLinejoin="round" strokeWidth={2} d="M3 10h18M7 15h1m4 0h1m-7 4h12a3 3 0 003-3V8a3 3 0 00-3-3H6a3 3 0 00-3 3v8a3 3 0 003 3z" />
|
|
360
|
+
</svg>
|
|
361
|
+
</div>
|
|
362
|
+
<h3 className="text-lg font-semibold mb-2">Premium Plans</h3>
|
|
363
|
+
<p className="text-sm text-gray-600 dark:text-gray-300">
|
|
364
|
+
Flexible subscription options for every music lover
|
|
365
|
+
</p>
|
|
366
|
+
</div>
|
|
367
|
+
</ResponsiveGrid>
|
|
368
|
+
</MobileContainer>
|
|
369
|
+
</div>
|
|
370
|
+
</main>
|
|
371
|
+
</PullToRefresh>
|
|
372
|
+
</OfflineWrapper>
|
|
373
|
+
|
|
374
|
+
{/* Fixed Audio Player Bar with Enhanced Glassmorphism */}
|
|
375
|
+
<div className={"fixed bottom-0 left-0 right-0 z-50" + " " + glass.card + " " + glass.border + " " + "border-t backdrop-blur-xl"}>
|
|
376
|
+
<FixedAudioBar
|
|
377
|
+
track={currentTrack || demoPlaylist[0]}
|
|
378
|
+
isPlaying={isPlaying}
|
|
379
|
+
onPlayPause={() => setIsPlaying(!isPlaying)}
|
|
380
|
+
onNext={() => {
|
|
381
|
+
const currentIndex = demoPlaylist.findIndex(track => track.id === (currentTrack?.id || demoPlaylist[0].id))
|
|
382
|
+
const nextIndex = (currentIndex + 1) % demoPlaylist.length
|
|
383
|
+
setCurrentTrack(demoPlaylist[nextIndex])
|
|
384
|
+
}}
|
|
385
|
+
onPrevious={() => {
|
|
386
|
+
const currentIndex = demoPlaylist.findIndex(track => track.id === (currentTrack?.id || demoPlaylist[0].id))
|
|
387
|
+
const prevIndex = (currentIndex - 1 + demoPlaylist.length) % demoPlaylist.length
|
|
388
|
+
setCurrentTrack(demoPlaylist[prevIndex])
|
|
389
|
+
}}
|
|
390
|
+
showWaveform={true}
|
|
391
|
+
showVolumeControl={true}
|
|
392
|
+
showTimeProgress={true}
|
|
393
|
+
showLikeButton={true}
|
|
394
|
+
showShareButton={true}
|
|
395
|
+
showShuffleRepeat={true}
|
|
396
|
+
allowMinimize={true}
|
|
397
|
+
className="bg-transparent"
|
|
398
|
+
/>
|
|
399
|
+
</div>
|
|
400
|
+
</PageTransition>
|
|
401
|
+
)
|
|
402
|
+
}
|