vyrplay 1.0.0 → 1.0.1
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 +25 -21
- package/README.md +21 -24
- package/dist/vyrplay.esm.js +30 -1754
- package/dist/vyrplay.umd.js +30 -1794
- package/package.json +14 -14
- package/src/VyrPlay.js +0 -1331
- package/src/engine/MediaEngine.js +0 -369
- package/src/index.js +0 -3
- package/src/ui/styles.css +0 -681
- package/src/ui/template.js +0 -220
- package/src/utils/events.js +0 -25
- package/src/utils/format.js +0 -20
package/src/ui/styles.css
DELETED
|
@@ -1,681 +0,0 @@
|
|
|
1
|
-
/* VyrPlay — core styles (mobile-first, responsive) */
|
|
2
|
-
.vyr-root {
|
|
3
|
-
--vyr-accent: #c026d3;
|
|
4
|
-
--vyr-accent-bright: #e879f9;
|
|
5
|
-
--vyr-text: #ffffff;
|
|
6
|
-
--vyr-font: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
|
|
7
|
-
position: relative;
|
|
8
|
-
display: block;
|
|
9
|
-
width: 100%;
|
|
10
|
-
height: 100%;
|
|
11
|
-
max-width: 100%;
|
|
12
|
-
min-height: 180px;
|
|
13
|
-
aspect-ratio: 16 / 9;
|
|
14
|
-
background: #000;
|
|
15
|
-
overflow: hidden;
|
|
16
|
-
font-family: var(--vyr-font);
|
|
17
|
-
color: #fff;
|
|
18
|
-
user-select: none;
|
|
19
|
-
touch-action: manipulation;
|
|
20
|
-
-webkit-tap-highlight-color: transparent;
|
|
21
|
-
-webkit-font-smoothing: antialiased;
|
|
22
|
-
transform: translateZ(0);
|
|
23
|
-
}
|
|
24
|
-
/* Jika parent sudah kasih height eksplisit (fullscreen page), biarkan isi penuh */
|
|
25
|
-
.vyr-root.is-fs,
|
|
26
|
-
.vyr-root.vyr-fill {
|
|
27
|
-
aspect-ratio: auto;
|
|
28
|
-
min-height: 0;
|
|
29
|
-
height: 100%;
|
|
30
|
-
}
|
|
31
|
-
/* Host opsional di luar root */
|
|
32
|
-
.vyr-host {
|
|
33
|
-
position: relative;
|
|
34
|
-
width: 100%;
|
|
35
|
-
aspect-ratio: 16 / 9;
|
|
36
|
-
background: #000;
|
|
37
|
-
overflow: hidden;
|
|
38
|
-
}
|
|
39
|
-
.vyr-host > .vyr-root {
|
|
40
|
-
position: absolute;
|
|
41
|
-
inset: 0;
|
|
42
|
-
aspect-ratio: auto;
|
|
43
|
-
min-height: 0;
|
|
44
|
-
height: 100%;
|
|
45
|
-
}
|
|
46
|
-
.vyr-root * { box-sizing: border-box; margin: 0; padding: 0; }
|
|
47
|
-
|
|
48
|
-
.vyr-root video {
|
|
49
|
-
position: absolute; inset: 0;
|
|
50
|
-
width: 100%; height: 100%;
|
|
51
|
-
object-fit: contain; background: #000; border: none;
|
|
52
|
-
transform: translateZ(0); will-change: contents;
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
/* Poster */
|
|
56
|
-
.vyr-poster {
|
|
57
|
-
position: absolute; inset: 0; z-index: 2;
|
|
58
|
-
background: #000 center center / cover no-repeat;
|
|
59
|
-
pointer-events: none;
|
|
60
|
-
transition: opacity .35s ease;
|
|
61
|
-
}
|
|
62
|
-
.vyr-poster.hide { opacity: 0; visibility: hidden; }
|
|
63
|
-
.vyr-poster::after {
|
|
64
|
-
content: ""; position: absolute; inset: 0;
|
|
65
|
-
background: linear-gradient(180deg, rgba(0,0,0,.35) 0%, rgba(0,0,0,.15) 40%, rgba(0,0,0,.55) 100%);
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
/* UI layer */
|
|
69
|
-
.vyr-ui {
|
|
70
|
-
position: absolute; inset: 0; z-index: 20;
|
|
71
|
-
opacity: 1; transition: opacity .25s ease;
|
|
72
|
-
pointer-events: none;
|
|
73
|
-
background: linear-gradient(to bottom,
|
|
74
|
-
rgba(0,0,0,.55) 0%, transparent 18%,
|
|
75
|
-
transparent 58%, rgba(0,0,0,.7) 100%);
|
|
76
|
-
}
|
|
77
|
-
.vyr-ui.hidden { opacity: 0; }
|
|
78
|
-
.vyr-ui.hidden .vyr-top,
|
|
79
|
-
.vyr-ui.hidden .vyr-center,
|
|
80
|
-
.vyr-ui.hidden .vyr-bottom,
|
|
81
|
-
.vyr-ui.hidden button,
|
|
82
|
-
.vyr-ui.hidden .vyr-chip,
|
|
83
|
-
.vyr-ui.hidden .vyr-progress {
|
|
84
|
-
pointer-events: none !important;
|
|
85
|
-
}
|
|
86
|
-
.vyr-ui.ui-locked .vyr-top-left,
|
|
87
|
-
.vyr-ui.ui-locked .vyr-btn-settings,
|
|
88
|
-
.vyr-ui.ui-locked .vyr-btn-pip,
|
|
89
|
-
.vyr-ui.ui-locked .vyr-center,
|
|
90
|
-
.vyr-ui.ui-locked .vyr-bottom { opacity: 0; pointer-events: none; }
|
|
91
|
-
.vyr-ui.ui-locked { background: transparent; }
|
|
92
|
-
.vyr-ui .vyr-top, .vyr-ui .vyr-center, .vyr-ui .vyr-bottom,
|
|
93
|
-
.vyr-ui button, .vyr-ui .vyr-chip, .vyr-ui .vyr-progress {
|
|
94
|
-
pointer-events: auto;
|
|
95
|
-
}
|
|
96
|
-
.vyr-btn-lock {
|
|
97
|
-
pointer-events: auto !important;
|
|
98
|
-
opacity: 1 !important;
|
|
99
|
-
z-index: 30;
|
|
100
|
-
}
|
|
101
|
-
.vyr-ui.hidden:not(.ui-locked) .vyr-btn-lock { pointer-events: none !important; }
|
|
102
|
-
.vyr-ui.ui-locked .vyr-btn-lock {
|
|
103
|
-
opacity: 1 !important;
|
|
104
|
-
background: rgba(0,0,0,.45);
|
|
105
|
-
border-radius: 50%;
|
|
106
|
-
}
|
|
107
|
-
|
|
108
|
-
/* Top bar */
|
|
109
|
-
.vyr-top {
|
|
110
|
-
position: absolute; top: 0; left: 0; right: 0;
|
|
111
|
-
display: flex; align-items: center; justify-content: space-between;
|
|
112
|
-
padding: calc(10px + env(safe-area-inset-top, 0px)) 12px 8px;
|
|
113
|
-
gap: 10px; z-index: 2;
|
|
114
|
-
}
|
|
115
|
-
.vyr-top-left { display: flex; align-items: center; gap: 8px; min-width: 0; flex: 1; }
|
|
116
|
-
.vyr-top-right { display: flex; align-items: center; gap: 2px; flex-shrink: 0; }
|
|
117
|
-
.vyr-title {
|
|
118
|
-
font-size: 14px; font-weight: 800;
|
|
119
|
-
white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
|
|
120
|
-
max-width: min(58vw, 380px);
|
|
121
|
-
text-shadow: 0 2px 10px rgba(0,0,0,.85);
|
|
122
|
-
}
|
|
123
|
-
|
|
124
|
-
.vyr-icon-btn {
|
|
125
|
-
width: 44px; height: 44px; border-radius: 50%;
|
|
126
|
-
background: transparent; border: none; color: #fff;
|
|
127
|
-
display: flex; align-items: center; justify-content: center;
|
|
128
|
-
cursor: pointer; flex-shrink: 0;
|
|
129
|
-
}
|
|
130
|
-
.vyr-icon-btn:active { transform: scale(.9); opacity: .7; }
|
|
131
|
-
.vyr-icon-btn svg { width: 24px; height: 24px; fill: currentColor; }
|
|
132
|
-
.vyr-icon-btn.active-lock { color: var(--vyr-accent-bright); }
|
|
133
|
-
@media (min-width: 480px) {
|
|
134
|
-
.vyr-icon-btn { width: 52px; height: 52px; }
|
|
135
|
-
.vyr-icon-btn svg { width: 28px; height: 28px; }
|
|
136
|
-
}
|
|
137
|
-
|
|
138
|
-
/* Center controls */
|
|
139
|
-
.vyr-center {
|
|
140
|
-
position: absolute; left: 0; right: 0;
|
|
141
|
-
top: 50%;
|
|
142
|
-
transform: translateY(-50%);
|
|
143
|
-
display: flex; align-items: center; justify-content: center;
|
|
144
|
-
gap: 14px;
|
|
145
|
-
padding: 0 max(8px, env(safe-area-inset-left, 0px)) 0 max(8px, env(safe-area-inset-right, 0px));
|
|
146
|
-
z-index: 2;
|
|
147
|
-
width: 100%;
|
|
148
|
-
max-width: 100%;
|
|
149
|
-
}
|
|
150
|
-
.vyr-c-btn {
|
|
151
|
-
flex: 0 0 auto;
|
|
152
|
-
width: 56px; height: 56px;
|
|
153
|
-
border-radius: 50%; padding: 0;
|
|
154
|
-
background: rgba(0,0,0,.52); border: none; color: #fff;
|
|
155
|
-
display: inline-flex; align-items: center; justify-content: center;
|
|
156
|
-
cursor: pointer; position: relative;
|
|
157
|
-
backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
|
|
158
|
-
box-shadow: 0 4px 18px rgba(0,0,0,.4);
|
|
159
|
-
-webkit-appearance: none; appearance: none;
|
|
160
|
-
}
|
|
161
|
-
.vyr-c-btn:active { transform: scale(.9); background: rgba(0,0,0,.65); }
|
|
162
|
-
.vyr-c-btn:disabled, .vyr-c-btn.is-disabled {
|
|
163
|
-
opacity: .3; pointer-events: none; cursor: default; box-shadow: none;
|
|
164
|
-
}
|
|
165
|
-
.vyr-c-btn svg { width: 26px; height: 26px; fill: #fff; pointer-events: none; }
|
|
166
|
-
.vyr-c-btn.play {
|
|
167
|
-
width: 72px; height: 72px;
|
|
168
|
-
background: rgba(0,0,0,.58);
|
|
169
|
-
backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
|
|
170
|
-
}
|
|
171
|
-
.vyr-c-btn.play svg { width: 34px; height: 34px; }
|
|
172
|
-
@media (min-width: 480px) {
|
|
173
|
-
.vyr-c-btn { width: 64px; height: 64px; }
|
|
174
|
-
.vyr-c-btn svg { width: 30px; height: 30px; }
|
|
175
|
-
.vyr-c-btn.play { width: 86px; height: 86px; }
|
|
176
|
-
.vyr-c-btn.play svg { width: 40px; height: 40px; }
|
|
177
|
-
}
|
|
178
|
-
.vyr-c-btn .ring {
|
|
179
|
-
position: absolute; inset: -5px; border-radius: 50%;
|
|
180
|
-
border: 3px solid transparent; border-top-color: var(--vyr-accent-bright);
|
|
181
|
-
animation: vyr-spin .8s linear infinite; display: none;
|
|
182
|
-
}
|
|
183
|
-
.vyr-c-btn.loading .ring { display: block; }
|
|
184
|
-
@keyframes vyr-spin { to { transform: rotate(360deg); } }
|
|
185
|
-
.vyr-c-btn .seek-badge {
|
|
186
|
-
position: absolute; right: 2px; bottom: 2px;
|
|
187
|
-
min-width: 16px; height: 14px; padding: 0 3px;
|
|
188
|
-
border-radius: 7px; background: rgba(168,85,247,.95);
|
|
189
|
-
color: #fff; font-size: 9px; font-weight: 800;
|
|
190
|
-
line-height: 14px; text-align: center; pointer-events: none;
|
|
191
|
-
}
|
|
192
|
-
|
|
193
|
-
/* Bottom */
|
|
194
|
-
.vyr-bottom {
|
|
195
|
-
position: absolute; left: 0; right: 0; bottom: 0;
|
|
196
|
-
padding: 12px 16px calc(20px + env(safe-area-inset-bottom, 0px));
|
|
197
|
-
z-index: 2;
|
|
198
|
-
}
|
|
199
|
-
@media (min-width: 480px) {
|
|
200
|
-
.vyr-bottom { padding: 14px 28px calc(28px + env(safe-area-inset-bottom, 0px)); }
|
|
201
|
-
}
|
|
202
|
-
.vyr-progress {
|
|
203
|
-
position: relative; height: 28px; display: flex; align-items: center;
|
|
204
|
-
margin-bottom: 10px; cursor: pointer;
|
|
205
|
-
}
|
|
206
|
-
.vyr-progress-track {
|
|
207
|
-
width: 100%; height: 5px;
|
|
208
|
-
background: rgba(255,255,255,.28); border-radius: 99px; position: relative;
|
|
209
|
-
}
|
|
210
|
-
.vyr-progress-fill {
|
|
211
|
-
height: 100%; background: var(--vyr-accent); border-radius: 99px; width: 0%;
|
|
212
|
-
pointer-events: none;
|
|
213
|
-
}
|
|
214
|
-
.vyr-progress-thumb {
|
|
215
|
-
position: absolute; top: 50%; width: 16px; height: 16px;
|
|
216
|
-
background: var(--vyr-accent-bright); border-radius: 50%;
|
|
217
|
-
transform: translate(-50%, -50%); left: 0%;
|
|
218
|
-
box-shadow: 0 0 0 4px rgba(192,38,211,.3); pointer-events: none;
|
|
219
|
-
}
|
|
220
|
-
.vyr-progress:active .vyr-progress-track,
|
|
221
|
-
.vyr-progress.scrubbing .vyr-progress-track { height: 7px; }
|
|
222
|
-
.vyr-progress:active .vyr-progress-thumb,
|
|
223
|
-
.vyr-progress.scrubbing .vyr-progress-thumb { width: 18px; height: 18px; }
|
|
224
|
-
.vyr-scrub-tip {
|
|
225
|
-
position: absolute; bottom: 100%; left: 0;
|
|
226
|
-
transform: translate(-50%, -8px);
|
|
227
|
-
background: rgba(0,0,0,.82); color: #fff;
|
|
228
|
-
font-size: 13px; font-weight: 800; font-variant-numeric: tabular-nums;
|
|
229
|
-
padding: 6px 10px; border-radius: 8px;
|
|
230
|
-
pointer-events: none; opacity: 0; white-space: nowrap;
|
|
231
|
-
transition: opacity .12s; z-index: 5;
|
|
232
|
-
}
|
|
233
|
-
.vyr-scrub-tip.show { opacity: 1; }
|
|
234
|
-
|
|
235
|
-
.vyr-meta {
|
|
236
|
-
display: flex; align-items: center; justify-content: space-between;
|
|
237
|
-
gap: 8px; flex-wrap: nowrap;
|
|
238
|
-
}
|
|
239
|
-
.vyr-time {
|
|
240
|
-
color: #fff; font-variant-numeric: tabular-nums;
|
|
241
|
-
font-family: var(--vyr-font) !important;
|
|
242
|
-
font-size: 15px; font-weight: 800;
|
|
243
|
-
text-shadow: 0 1px 6px rgba(0,0,0,.75);
|
|
244
|
-
white-space: nowrap; flex-shrink: 0;
|
|
245
|
-
}
|
|
246
|
-
.vyr-meta-right { display: flex; align-items: center; gap: 4px; flex-shrink: 0; }
|
|
247
|
-
.vyr-chip {
|
|
248
|
-
background: transparent; border: none; color: #fff;
|
|
249
|
-
padding: 6px 10px; border-radius: 10px;
|
|
250
|
-
font-family: var(--vyr-font) !important;
|
|
251
|
-
font-size: 15px; font-weight: 800;
|
|
252
|
-
letter-spacing: 0.02em;
|
|
253
|
-
cursor: pointer; display: flex; align-items: center; gap: 4px;
|
|
254
|
-
min-height: 40px; text-shadow: 0 1px 6px rgba(0,0,0,.7);
|
|
255
|
-
-webkit-font-smoothing: antialiased;
|
|
256
|
-
}
|
|
257
|
-
.vyr-chip:active { opacity: .7; transform: scale(.95); }
|
|
258
|
-
.vyr-chip svg { width: 20px; height: 20px; fill: #fff; }
|
|
259
|
-
|
|
260
|
-
/* Volume (fullscreen only for slider) */
|
|
261
|
-
.vyr-vol-wrap { display: flex; align-items: center; gap: 2px; flex-shrink: 0; }
|
|
262
|
-
.vyr-vol-btn {
|
|
263
|
-
background: transparent; border: none; color: #fff;
|
|
264
|
-
width: 32px; height: 32px; padding: 0; cursor: pointer;
|
|
265
|
-
display: flex; align-items: center; justify-content: center;
|
|
266
|
-
}
|
|
267
|
-
.vyr-vol-btn svg { width: 20px; height: 20px; fill: #fff; }
|
|
268
|
-
.vyr-vol-slider {
|
|
269
|
-
-webkit-appearance: none; appearance: none;
|
|
270
|
-
width: 0; height: 4px; opacity: 0;
|
|
271
|
-
background: rgba(255,255,255,.28); border-radius: 99px; outline: none;
|
|
272
|
-
transition: width .2s, opacity .2s;
|
|
273
|
-
}
|
|
274
|
-
.vyr-root.is-fs .vyr-vol-slider { width: 72px; opacity: 1; }
|
|
275
|
-
.vyr-vol-slider::-webkit-slider-thumb {
|
|
276
|
-
-webkit-appearance: none; width: 14px; height: 14px; border-radius: 50%;
|
|
277
|
-
background: var(--vyr-accent-bright); box-shadow: 0 0 0 3px rgba(192,38,211,.3);
|
|
278
|
-
}
|
|
279
|
-
|
|
280
|
-
/* Sheets (right panel) */
|
|
281
|
-
.vyr-backdrop {
|
|
282
|
-
position: absolute; inset: 0; z-index: 35;
|
|
283
|
-
background: rgba(0,0,0,.5);
|
|
284
|
-
opacity: 0; visibility: hidden; pointer-events: none;
|
|
285
|
-
transition: opacity .2s ease, visibility .2s;
|
|
286
|
-
cursor: pointer;
|
|
287
|
-
}
|
|
288
|
-
.vyr-backdrop.show { opacity: 1; visibility: visible; pointer-events: auto; }
|
|
289
|
-
/* Desktop: panel kanan, tidak full menutupi video */
|
|
290
|
-
.vyr-sheet {
|
|
291
|
-
position: absolute; top: 0; right: 0; bottom: 0;
|
|
292
|
-
z-index: 40; width: min(70%, 300px);
|
|
293
|
-
max-width: 320px;
|
|
294
|
-
background: linear-gradient(165deg, rgba(88,28,120,.98) 0%, rgba(30,12,45,.98) 45%, rgba(12,8,20,.98) 100%);
|
|
295
|
-
border-left: 1px solid rgba(232,121,249,.25);
|
|
296
|
-
box-shadow: -12px 0 40px rgba(0,0,0,.5);
|
|
297
|
-
padding: 10px 12px 12px;
|
|
298
|
-
transform: translateX(105%);
|
|
299
|
-
transition: transform .25s cubic-bezier(.22,1,.36,1), visibility .25s;
|
|
300
|
-
display: flex; flex-direction: column; overflow: hidden;
|
|
301
|
-
visibility: hidden; pointer-events: none;
|
|
302
|
-
}
|
|
303
|
-
.vyr-sheet.show {
|
|
304
|
-
transform: translateX(0);
|
|
305
|
-
visibility: visible;
|
|
306
|
-
pointer-events: auto;
|
|
307
|
-
}
|
|
308
|
-
.vyr-sheet-head {
|
|
309
|
-
display: flex; align-items: center; justify-content: space-between;
|
|
310
|
-
padding: 4px 4px 12px 8px; gap: 8px;
|
|
311
|
-
}
|
|
312
|
-
.vyr-sheet-title {
|
|
313
|
-
font-size: 13px; font-weight: 700; letter-spacing: .06em;
|
|
314
|
-
text-transform: uppercase; color: var(--vyr-accent-bright);
|
|
315
|
-
}
|
|
316
|
-
.vyr-sheet-close {
|
|
317
|
-
width: 36px; height: 36px; border: none; border-radius: 50%;
|
|
318
|
-
background: rgba(0,0,0,.35); color: #fff; font-size: 16px; cursor: pointer;
|
|
319
|
-
}
|
|
320
|
-
.vyr-sheet-body {
|
|
321
|
-
flex: 1; overflow-y: auto; padding: 0 4px 8px 8px;
|
|
322
|
-
-webkit-overflow-scrolling: touch;
|
|
323
|
-
}
|
|
324
|
-
.vyr-sheet-item {
|
|
325
|
-
padding: 12px 14px; margin-bottom: 6px; font-size: 15px;
|
|
326
|
-
cursor: pointer; border-radius: 12px;
|
|
327
|
-
display: flex; align-items: center; justify-content: space-between;
|
|
328
|
-
background: rgba(0,0,0,.28); border: 1px solid rgba(255,255,255,.06);
|
|
329
|
-
color: #fff; transition: background .15s;
|
|
330
|
-
}
|
|
331
|
-
.vyr-sheet-item:active, .vyr-sheet-item.active {
|
|
332
|
-
background: rgba(192,38,211,.55); border-color: rgba(232,121,249,.4);
|
|
333
|
-
}
|
|
334
|
-
.vyr-sheet-item .check { opacity: 0; font-weight: 700; }
|
|
335
|
-
.vyr-sheet-item.active .check { opacity: 1; }
|
|
336
|
-
|
|
337
|
-
/* Settings rows */
|
|
338
|
-
.vyr-set-row {
|
|
339
|
-
display: flex; align-items: center; gap: 12px;
|
|
340
|
-
padding: 14px 12px; border-radius: 12px; cursor: pointer;
|
|
341
|
-
}
|
|
342
|
-
.vyr-set-row:active { background: rgba(255,255,255,.08); }
|
|
343
|
-
.vyr-set-ic {
|
|
344
|
-
width: 40px; height: 40px; border-radius: 12px;
|
|
345
|
-
background: rgba(168,85,247,.25);
|
|
346
|
-
display: flex; align-items: center; justify-content: center; flex-shrink: 0;
|
|
347
|
-
}
|
|
348
|
-
.vyr-set-ic svg { width: 22px; height: 22px; fill: #e879f9; }
|
|
349
|
-
.vyr-set-txt { flex: 1; min-width: 0; }
|
|
350
|
-
.vyr-set-title { font-size: 15px; font-weight: 800; }
|
|
351
|
-
.vyr-set-desc { font-size: 12px; color: rgba(255,255,255,.55); margin-top: 2px; }
|
|
352
|
-
.vyr-set-val { font-size: 13px; font-weight: 800; color: #e879f9; flex-shrink: 0; }
|
|
353
|
-
.vyr-tog {
|
|
354
|
-
display: inline-block; width: 44px; height: 26px; border-radius: 13px;
|
|
355
|
-
background: rgba(255,255,255,.2); position: relative; transition: background .2s;
|
|
356
|
-
}
|
|
357
|
-
.vyr-tog::after {
|
|
358
|
-
content: ""; position: absolute; top: 3px; left: 3px;
|
|
359
|
-
width: 20px; height: 20px; border-radius: 50%; background: #fff;
|
|
360
|
-
transition: transform .2s; box-shadow: 0 1px 4px rgba(0,0,0,.35);
|
|
361
|
-
}
|
|
362
|
-
.vyr-tog.on { background: #a855f7; }
|
|
363
|
-
.vyr-tog.on::after { transform: translateX(18px); }
|
|
364
|
-
|
|
365
|
-
/* Loading / buffer — bat neon */
|
|
366
|
-
.vyr-loading, .vyr-buffer {
|
|
367
|
-
position: absolute; inset: 0; z-index: 50;
|
|
368
|
-
display: flex; flex-direction: column; align-items: center; justify-content: center;
|
|
369
|
-
background: transparent; pointer-events: none;
|
|
370
|
-
color: #eee; font-size: 11px; gap: 10px;
|
|
371
|
-
transition: opacity .22s ease;
|
|
372
|
-
}
|
|
373
|
-
.vyr-loading.hide { display: none; }
|
|
374
|
-
.vyr-buffer { z-index: 30; display: none; }
|
|
375
|
-
.vyr-buffer.show { display: flex; }
|
|
376
|
-
.vyr-bat-wrap { width: min(34vw, 140px); overflow: visible; animation: vyr-bat-float 4s ease-in-out infinite; }
|
|
377
|
-
.vyr-buffer .vyr-bat-wrap { width: min(26vw, 110px); }
|
|
378
|
-
.vyr-bat-wrap svg { width: 100%; height: auto; overflow: visible; }
|
|
379
|
-
.vyr-bat-base {
|
|
380
|
-
fill: rgba(12,6,22,.35); stroke: rgba(232,121,249,.55);
|
|
381
|
-
stroke-width: 4; stroke-linecap: round; stroke-linejoin: round;
|
|
382
|
-
}
|
|
383
|
-
.vyr-bat-line {
|
|
384
|
-
fill: none; stroke: #f8f0ff; stroke-width: 4;
|
|
385
|
-
stroke-linecap: round; stroke-linejoin: round;
|
|
386
|
-
stroke-dasharray: 140 580; animation: vyr-bat-trace 2.6s linear infinite;
|
|
387
|
-
filter: drop-shadow(0 0 3px #e879f9) drop-shadow(0 0 10px #a855f7) drop-shadow(0 0 18px #7c3aed);
|
|
388
|
-
}
|
|
389
|
-
.vyr-loading .label {
|
|
390
|
-
letter-spacing: 6px; text-transform: uppercase; color: rgba(255,255,255,.75);
|
|
391
|
-
font-size: 10px; font-weight: 600; animation: vyr-bat-pulse 1.5s ease-in-out infinite;
|
|
392
|
-
}
|
|
393
|
-
@keyframes vyr-bat-float { 0%,100%{ transform: translateY(0); } 50%{ transform: translateY(-5px); } }
|
|
394
|
-
@keyframes vyr-bat-trace { to { stroke-dashoffset: -720; } }
|
|
395
|
-
@keyframes vyr-bat-pulse { 0%,100%{ opacity: .35; } 50%{ opacity: 1; } }
|
|
396
|
-
|
|
397
|
-
/* Tap zones + seek toast */
|
|
398
|
-
.vyr-tap { position: absolute; top: 15%; bottom: 22%; width: 30%; z-index: 10; }
|
|
399
|
-
.vyr-tap-left { left: 0; }
|
|
400
|
-
.vyr-tap-right { right: 0; }
|
|
401
|
-
.vyr-seek-toast {
|
|
402
|
-
position: absolute; top: 42%; transform: translateY(-50%);
|
|
403
|
-
display: flex; flex-direction: column; align-items: center; gap: 8px;
|
|
404
|
-
pointer-events: none; opacity: 0; z-index: 26; transition: opacity .12s;
|
|
405
|
-
}
|
|
406
|
-
.vyr-seek-toast.show { opacity: 1; }
|
|
407
|
-
.vyr-seek-toast .sec {
|
|
408
|
-
font-size: 15px; font-weight: 800;
|
|
409
|
-
text-shadow: 0 2px 14px rgba(0,0,0,.65);
|
|
410
|
-
}
|
|
411
|
-
.vyr-seek-left { left: 10%; }
|
|
412
|
-
.vyr-seek-right { right: 10%; }
|
|
413
|
-
|
|
414
|
-
/* Speed / volume badge */
|
|
415
|
-
.vyr-speed-badge, .vyr-vol-toast {
|
|
416
|
-
position: absolute; left: 50%; top: 42%;
|
|
417
|
-
transform: translate(-50%, -50%);
|
|
418
|
-
z-index: 28; pointer-events: none;
|
|
419
|
-
background: rgba(0,0,0,.55); color: #fff;
|
|
420
|
-
font-size: 18px; font-weight: 800; padding: 8px 16px; border-radius: 20px;
|
|
421
|
-
opacity: 0; transition: opacity .15s;
|
|
422
|
-
}
|
|
423
|
-
.vyr-speed-badge.show, .vyr-vol-toast.show { opacity: 1; }
|
|
424
|
-
.vyr-vol-toast {
|
|
425
|
-
font-size: 22px; padding: 12px 20px; border-radius: 16px;
|
|
426
|
-
display: flex; align-items: center; gap: 8px;
|
|
427
|
-
transform: translate(-50%, -50%) scale(.92);
|
|
428
|
-
}
|
|
429
|
-
.vyr-vol-toast.show { transform: translate(-50%, -50%) scale(1); }
|
|
430
|
-
|
|
431
|
-
/* PiP overlay */
|
|
432
|
-
.vyr-pip-overlay {
|
|
433
|
-
position: absolute; inset: 0; z-index: 18;
|
|
434
|
-
display: none; align-items: center; justify-content: center;
|
|
435
|
-
background: rgba(0,0,0,.82); pointer-events: auto;
|
|
436
|
-
}
|
|
437
|
-
.vyr-pip-overlay.show { display: flex; }
|
|
438
|
-
.vyr-pip-box { text-align: center; padding: 24px; max-width: 280px; }
|
|
439
|
-
.vyr-pip-box button {
|
|
440
|
-
background: #a855f7; color: #fff; border: none; border-radius: 12px;
|
|
441
|
-
padding: 12px 18px; font-weight: 800; font-size: 14px; cursor: pointer; margin-top: 12px;
|
|
442
|
-
}
|
|
443
|
-
|
|
444
|
-
/* Error state */
|
|
445
|
-
.vyr-error {
|
|
446
|
-
text-align: center; padding: 20px; max-width: 320px;
|
|
447
|
-
}
|
|
448
|
-
.vyr-error-title { font-size: 18px; font-weight: 700; margin-bottom: 8px; }
|
|
449
|
-
.vyr-error-detail { font-size: 13px; opacity: .8; line-height: 1.45; }
|
|
450
|
-
|
|
451
|
-
/* ─── Subtitles (custom overlay) ─── */
|
|
452
|
-
.vyr-sub-layer {
|
|
453
|
-
position: absolute; left: 0; right: 0; z-index: 15;
|
|
454
|
-
pointer-events: none;
|
|
455
|
-
display: flex; justify-content: center; align-items: flex-end;
|
|
456
|
-
padding: 0 12px;
|
|
457
|
-
/* base di atas control bar + safe area + slider Y */
|
|
458
|
-
bottom: calc(56px + env(safe-area-inset-bottom, 0px) + (var(--vyr-sub-y, 8) * 1%));
|
|
459
|
-
top: auto;
|
|
460
|
-
height: auto;
|
|
461
|
-
max-width: 100%;
|
|
462
|
-
transition: bottom .15s ease;
|
|
463
|
-
}
|
|
464
|
-
.vyr-root.is-fs .vyr-sub-layer {
|
|
465
|
-
bottom: calc(64px + env(safe-area-inset-bottom, 0px) + (var(--vyr-sub-y, 8) * 1%));
|
|
466
|
-
}
|
|
467
|
-
/* saat UI hide, subtitle boleh lebih rendah */
|
|
468
|
-
.vyr-root:has(.vyr-ui.hidden) .vyr-sub-layer {
|
|
469
|
-
bottom: calc(16px + env(safe-area-inset-bottom, 0px) + (var(--vyr-sub-y, 8) * 1%));
|
|
470
|
-
}
|
|
471
|
-
.vyr-sub-text {
|
|
472
|
-
max-width: min(92%, 720px);
|
|
473
|
-
text-align: center;
|
|
474
|
-
font-weight: 700;
|
|
475
|
-
line-height: 1.35;
|
|
476
|
-
padding: 4px 10px;
|
|
477
|
-
border-radius: 6px;
|
|
478
|
-
white-space: pre-wrap;
|
|
479
|
-
word-break: break-word;
|
|
480
|
-
transition: font-size .15s, color .15s, background .15s;
|
|
481
|
-
}
|
|
482
|
-
.vyr-chip.vyr-btn-cc {
|
|
483
|
-
font-family: var(--vyr-font) !important;
|
|
484
|
-
font-size: 14px; font-weight: 800; letter-spacing: .06em;
|
|
485
|
-
min-width: 40px; justify-content: center;
|
|
486
|
-
}
|
|
487
|
-
.vyr-chip.vyr-btn-cc.active {
|
|
488
|
-
color: var(--vyr-accent-bright);
|
|
489
|
-
}
|
|
490
|
-
.vyr-sub-style-row {
|
|
491
|
-
display: flex; align-items: center; gap: 10px;
|
|
492
|
-
padding: 10px 8px; flex-wrap: wrap;
|
|
493
|
-
}
|
|
494
|
-
.vyr-sub-style-row label {
|
|
495
|
-
font-size: 12px; font-weight: 700; opacity: .7; min-width: 70px;
|
|
496
|
-
}
|
|
497
|
-
.vyr-sub-style-row input[type="color"] {
|
|
498
|
-
width: 36px; height: 28px; border: none; border-radius: 8px;
|
|
499
|
-
background: transparent; cursor: pointer; padding: 0;
|
|
500
|
-
}
|
|
501
|
-
.vyr-sub-style-row input[type="range"] {
|
|
502
|
-
flex: 1; min-width: 80px; accent-color: #a855f7;
|
|
503
|
-
}
|
|
504
|
-
.vyr-sub-pos-btns {
|
|
505
|
-
display: flex; gap: 6px;
|
|
506
|
-
}
|
|
507
|
-
.vyr-sub-pos-btns button {
|
|
508
|
-
flex: 1; padding: 8px; border-radius: 10px;
|
|
509
|
-
border: 1px solid rgba(255,255,255,.12);
|
|
510
|
-
background: rgba(0,0,0,.28); color: #fff;
|
|
511
|
-
font-weight: 700; font-size: 12px; cursor: pointer;
|
|
512
|
-
}
|
|
513
|
-
.vyr-sub-pos-btns button.active {
|
|
514
|
-
background: rgba(192,38,211,.55);
|
|
515
|
-
border-color: rgba(232,121,249,.4);
|
|
516
|
-
}
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
/* ========== MOBILE UI (bukan desktop diperkecil) ========== */
|
|
520
|
-
@media (max-width: 768px) {
|
|
521
|
-
.vyr-root {
|
|
522
|
-
min-height: 0;
|
|
523
|
-
/* isi parent; parent yang tentukan 16:9 */
|
|
524
|
-
aspect-ratio: auto;
|
|
525
|
-
height: 100%;
|
|
526
|
-
}
|
|
527
|
-
|
|
528
|
-
/* Top: compact app-bar style */
|
|
529
|
-
.vyr-top {
|
|
530
|
-
padding: calc(6px + env(safe-area-inset-top, 0px)) 8px 4px !important;
|
|
531
|
-
gap: 4px;
|
|
532
|
-
}
|
|
533
|
-
.vyr-title {
|
|
534
|
-
font-size: 13px !important;
|
|
535
|
-
font-weight: 700 !important;
|
|
536
|
-
line-height: 1.25;
|
|
537
|
-
}
|
|
538
|
-
.vyr-top-right .vyr-chip,
|
|
539
|
-
.vyr-top-right button {
|
|
540
|
-
width: 36px;
|
|
541
|
-
height: 36px;
|
|
542
|
-
min-width: 36px;
|
|
543
|
-
padding: 0 !important;
|
|
544
|
-
}
|
|
545
|
-
.vyr-top-right svg { width: 18px; height: 18px; }
|
|
546
|
-
|
|
547
|
-
/* Center: touch-first */
|
|
548
|
-
.vyr-center {
|
|
549
|
-
gap: 28px !important;
|
|
550
|
-
padding: 0 16px !important;
|
|
551
|
-
}
|
|
552
|
-
.vyr-btn-play {
|
|
553
|
-
width: 64px !important;
|
|
554
|
-
height: 64px !important;
|
|
555
|
-
border-radius: 50%;
|
|
556
|
-
background: rgba(0,0,0,.35) !important;
|
|
557
|
-
backdrop-filter: blur(8px);
|
|
558
|
-
}
|
|
559
|
-
.vyr-btn-play svg { width: 28px !important; height: 28px !important; }
|
|
560
|
-
.vyr-btn-seek {
|
|
561
|
-
width: 48px !important;
|
|
562
|
-
height: 48px !important;
|
|
563
|
-
background: rgba(0,0,0,.28) !important;
|
|
564
|
-
border-radius: 50%;
|
|
565
|
-
}
|
|
566
|
-
.vyr-btn-seek svg { width: 22px !important; height: 22px !important; }
|
|
567
|
-
|
|
568
|
-
/* Bottom: thick scrub + big chips (mirip player HP) */
|
|
569
|
-
.vyr-bottom {
|
|
570
|
-
padding: 4px 10px calc(10px + env(safe-area-inset-bottom, 0px)) !important;
|
|
571
|
-
}
|
|
572
|
-
.vyr-progress {
|
|
573
|
-
height: 36px !important;
|
|
574
|
-
margin-bottom: 2px !important;
|
|
575
|
-
}
|
|
576
|
-
.vyr-progress-track {
|
|
577
|
-
height: 4px !important;
|
|
578
|
-
border-radius: 4px;
|
|
579
|
-
}
|
|
580
|
-
.vyr-progress:active .vyr-progress-track,
|
|
581
|
-
.vyr-progress.scrubbing .vyr-progress-track {
|
|
582
|
-
height: 6px !important;
|
|
583
|
-
}
|
|
584
|
-
.vyr-progress-thumb {
|
|
585
|
-
width: 14px !important;
|
|
586
|
-
height: 14px !important;
|
|
587
|
-
}
|
|
588
|
-
.vyr-progress:active .vyr-progress-thumb,
|
|
589
|
-
.vyr-progress.scrubbing .vyr-progress-thumb {
|
|
590
|
-
width: 18px !important;
|
|
591
|
-
height: 18px !important;
|
|
592
|
-
}
|
|
593
|
-
|
|
594
|
-
.vyr-meta {
|
|
595
|
-
display: flex;
|
|
596
|
-
align-items: center;
|
|
597
|
-
gap: 4px;
|
|
598
|
-
min-height: 40px;
|
|
599
|
-
}
|
|
600
|
-
.vyr-time {
|
|
601
|
-
font-size: 11px !important;
|
|
602
|
-
font-weight: 700 !important;
|
|
603
|
-
letter-spacing: 0;
|
|
604
|
-
flex-shrink: 0;
|
|
605
|
-
}
|
|
606
|
-
.vyr-chip {
|
|
607
|
-
font-size: 12px !important;
|
|
608
|
-
font-weight: 700 !important;
|
|
609
|
-
min-height: 40px !important;
|
|
610
|
-
min-width: 40px;
|
|
611
|
-
padding: 0 8px !important;
|
|
612
|
-
border-radius: 10px !important;
|
|
613
|
-
}
|
|
614
|
-
.vyr-chip.vyr-btn-cc {
|
|
615
|
-
font-size: 12px !important;
|
|
616
|
-
letter-spacing: 0.04em;
|
|
617
|
-
}
|
|
618
|
-
.vyr-chip svg { width: 18px; height: 18px; }
|
|
619
|
-
|
|
620
|
-
/* Sheet = bottom drawer di DALAM player (bukan full page) */
|
|
621
|
-
.vyr-sheet {
|
|
622
|
-
left: 0 !important;
|
|
623
|
-
right: 0 !important;
|
|
624
|
-
top: auto !important;
|
|
625
|
-
bottom: 0 !important;
|
|
626
|
-
width: 100% !important;
|
|
627
|
-
max-width: 100% !important;
|
|
628
|
-
height: auto !important;
|
|
629
|
-
max-height: 70% !important; /* % dari tinggi player, bukan 72dvh layar */
|
|
630
|
-
border-radius: 14px 14px 0 0 !important;
|
|
631
|
-
border-left: none !important;
|
|
632
|
-
border-top: 1px solid rgba(232,121,249,.25);
|
|
633
|
-
padding: 8px 12px calc(10px + env(safe-area-inset-bottom, 0px)) !important;
|
|
634
|
-
transform: translateY(110%) !important;
|
|
635
|
-
box-shadow: 0 -8px 28px rgba(0,0,0,.45);
|
|
636
|
-
}
|
|
637
|
-
.vyr-sheet.show {
|
|
638
|
-
transform: translateY(0) !important;
|
|
639
|
-
}
|
|
640
|
-
.vyr-sheet-head {
|
|
641
|
-
padding: 8px 4px 10px !important;
|
|
642
|
-
flex-shrink: 0;
|
|
643
|
-
}
|
|
644
|
-
.vyr-sheet-title {
|
|
645
|
-
font-size: 14px !important;
|
|
646
|
-
}
|
|
647
|
-
.vyr-sheet-close {
|
|
648
|
-
width: 40px !important;
|
|
649
|
-
height: 40px !important;
|
|
650
|
-
font-size: 18px !important;
|
|
651
|
-
}
|
|
652
|
-
.vyr-sheet-item,
|
|
653
|
-
.vyr-set-row {
|
|
654
|
-
min-height: 44px;
|
|
655
|
-
padding-top: 10px !important;
|
|
656
|
-
padding-bottom: 10px !important;
|
|
657
|
-
}
|
|
658
|
-
|
|
659
|
-
/* Tap zones lebih lebar di mobile */
|
|
660
|
-
.vyr-tap { width: 36%; top: 12%; bottom: 28%; }
|
|
661
|
-
|
|
662
|
-
/* Subtitle di atas kontrol */
|
|
663
|
-
.vyr-sub-layer {
|
|
664
|
-
bottom: calc(52px + env(safe-area-inset-bottom, 0px) + (var(--vyr-sub-y, 6) * 1%)) !important;
|
|
665
|
-
}
|
|
666
|
-
.vyr-sub-text {
|
|
667
|
-
font-size: 15px !important;
|
|
668
|
-
line-height: 1.35 !important;
|
|
669
|
-
max-width: 92% !important;
|
|
670
|
-
}
|
|
671
|
-
|
|
672
|
-
.vyr-seek-toast {
|
|
673
|
-
font-size: 15px !important;
|
|
674
|
-
padding: 8px 14px !important;
|
|
675
|
-
}
|
|
676
|
-
}
|
|
677
|
-
|
|
678
|
-
@media (min-width: 769px) {
|
|
679
|
-
.vyr-btn-play { width: 68px; height: 68px; }
|
|
680
|
-
.vyr-btn-seek { width: 48px; height: 48px; }
|
|
681
|
-
}
|