myetv-player 1.0.8 → 1.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/scss/_base.scss CHANGED
@@ -101,21 +101,6 @@ body {
101
101
  opacity: 0;
102
102
  }
103
103
 
104
- .video-wrapper:not(.has-controls) .video-watermark.watermark-bottomleft:not(.hide-on-autohide),
105
- .video-wrapper:not(.has-controls) .video-watermark.watermark-bottomright:not(.hide-on-autohide) {
106
- bottom: 15px;
107
- }
108
-
109
- .video-wrapper.has-controls .video-watermark {
110
- visibility: visible;
111
- opacity: 0.7;
112
- }
113
-
114
- .video-wrapper.has-controls .video-watermark.watermark-bottomleft,
115
- .video-wrapper.has-controls .video-watermark.watermark-bottomright {
116
- bottom: 90px;
117
- }
118
-
119
104
  .hidden {
120
105
  display: none !important;
121
106
  }
@@ -5,6 +5,24 @@
5
5
  @use 'mixins' as *;
6
6
  @use 'variables' as *;
7
7
 
8
+ // ===================================
9
+ // PREVENT TEXT SELECTION DURING DRAG
10
+ // ===================================
11
+
12
+ // Disable text selection on all controls when dragging
13
+ .controls,
14
+ .progress-container,
15
+ .progress-bar,
16
+ .controls-main,
17
+ .controls-left,
18
+ .controls-right,
19
+ .time-display {
20
+ user-select: none; // Prevent text selection
21
+ -webkit-user-select: none; // Safari
22
+ -moz-user-select: none; // Firefox
23
+ -ms-user-select: none; // IE/Edge
24
+ }
25
+
8
26
  // ===================================
9
27
  // PROGRESS BAR SYSTEM
10
28
  // ===================================
@@ -66,7 +84,7 @@
66
84
  height: 14px;
67
85
  background: var(--player-accent, #ff0000);
68
86
  cursor: grab; // Indicates draggable
69
- transition: opacity 0.2s ease;
87
+ transition: all 0.2s ease; // Smooth transition for size changes
70
88
  z-index: 10; // Above everything (buffer and filled)
71
89
  pointer-events: auto; // Ensure it's clickable
72
90
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3); // Subtle shadow for depth
@@ -154,6 +172,103 @@
154
172
  opacity: 1 !important; // Always visible with higher specificity
155
173
  }
156
174
 
175
+ // ===================================
176
+ // MOBILE TOUCH ENHANCEMENTS
177
+ // ===================================
178
+
179
+ // Media query for tablets and mobile devices (max width 768px)
180
+ @media (max-width: 768px) {
181
+
182
+ // Progress bar stays thin (4px)
183
+ .progress-bar {
184
+ height: 4px; // Keep thin
185
+ }
186
+
187
+ // Handle with large invisible touch area
188
+ .progress-handle {
189
+ touch-action: none; // Critical for mobile drag
190
+ -webkit-touch-callout: none; // Disable iOS callout
191
+ // Add large invisible touch area using pseudo-element
192
+ &::before {
193
+ content: '';
194
+ position: absolute;
195
+ top: 50%;
196
+ left: 50%;
197
+ transform: translate(-50%, -50%);
198
+ width: 50px; // Large touch target (50x50px)
199
+ height: 50px;
200
+ border-radius: 50%;
201
+ background: transparent; // Invisible but touchable
202
+ z-index: -1; // Behind the visible handle
203
+ }
204
+ // Scale up when touched/active
205
+ &:active {
206
+ width: 24px !important; // Grow: 14px -> 24px
207
+ height: 24px !important;
208
+ box-shadow: 0 3px 8px rgba(0, 0, 0, 0.4); // Stronger shadow when active
209
+ }
210
+ }
211
+
212
+ // Adjust shapes when active (touched)
213
+ .progress-handle-circle:active {
214
+ border-radius: 50%;
215
+ }
216
+
217
+ .progress-handle-square:active {
218
+ border-radius: 5px;
219
+ }
220
+
221
+ .progress-handle-diamond:active {
222
+ border-radius: 4px;
223
+ transform: translate(-50%, -50%) rotate(45deg);
224
+ }
225
+
226
+ .progress-handle-arrow:active {
227
+ border-left: 12px solid transparent;
228
+ border-right: 12px solid transparent;
229
+ border-bottom: 24px solid var(--player-accent, #ff0000);
230
+ }
231
+
232
+ .progress-handle-triangle:active {
233
+ border-left: 13px solid transparent;
234
+ border-right: 13px solid transparent;
235
+ border-bottom: 24px solid var(--player-accent, #ff0000);
236
+ }
237
+
238
+ .progress-handle-heart:active,
239
+ .progress-handle-star:active {
240
+ width: 26px !important;
241
+ height: 26px !important;
242
+ }
243
+ }
244
+
245
+ // Enhanced touch targets for very small screens (phones)
246
+ @media (max-width: 480px) {
247
+
248
+ // Progress bar stays thin on phones too
249
+ .progress-bar {
250
+ height: 4px; // Keep thin
251
+ }
252
+
253
+ .progress-handle {
254
+ &::before {
255
+ width: 60px; // Extra large touch target on phones
256
+ height: 60px;
257
+ }
258
+ // Even bigger when touched on phones
259
+ &:active {
260
+ width: 28px !important;
261
+ height: 28px !important;
262
+ }
263
+ }
264
+
265
+ .progress-handle-heart:active,
266
+ .progress-handle-star:active {
267
+ width: 30px !important;
268
+ height: 30px !important;
269
+ }
270
+ }
271
+
157
272
  // ===================================
158
273
  // CONTROLS CONTAINER
159
274
  // ===================================
@@ -181,4 +296,69 @@
181
296
  position: absolute !important;
182
297
  bottom: 0 !important;
183
298
  z-index: 20 !important; // Above other elements
184
- }
299
+ }
300
+
301
+ // ===================================
302
+ // TOUCH EVENT FIXES FOR MOBILE
303
+ // ===================================
304
+
305
+ // Prevent default touch behavior on progress bar
306
+ .progress-container,
307
+ .progress-bar,
308
+ .progress-handle {
309
+ touch-action: none; // Disable browser's default touch gestures
310
+ -webkit-touch-callout: none; // Disable callout on iOS
311
+ }
312
+
313
+ // ===================================
314
+ // ENCODING BADGE - Video in encoding
315
+ // ===================================
316
+
317
+ /* Badge for video in encoding (duration Infinity/NaN) */
318
+ .encoding-badge {
319
+ display: inline-block;
320
+ background: rgba(128, 128, 128, 0.8); // Grigio semi-trasparente
321
+ color: white;
322
+ padding: 2px 8px;
323
+ border-radius: 4px;
324
+ font-size: 11px;
325
+ font-weight: 500;
326
+ text-transform: uppercase;
327
+ letter-spacing: 0.5px;
328
+ white-space: nowrap;
329
+ backdrop-filter: blur(4px);
330
+ border: 1px solid rgba(255, 255, 255, 0.2);
331
+ animation: encoding-pulse 2s ease-in-out infinite;
332
+ }
333
+
334
+ /* Class for the container when shows the badge */
335
+ .time-display .encoding-state {
336
+ display: flex;
337
+ align-items: center;
338
+ }
339
+
340
+ /* animation for the badge */
341
+ @keyframes encoding-pulse {
342
+ 0%, 100% {
343
+ opacity: 0.8;
344
+ }
345
+
346
+ 50% {
347
+ opacity: 1;
348
+ }
349
+ }
350
+
351
+ // Responsive for badge encoding
352
+ @media (max-width: 480px) {
353
+ .encoding-badge {
354
+ font-size: 9px;
355
+ padding: 1px 6px;
356
+ }
357
+ }
358
+
359
+ @media (max-width: 350px) {
360
+ .encoding-badge {
361
+ font-size: 8px;
362
+ padding: 1px 4px;
363
+ }
364
+ }
package/scss/_menus.scss CHANGED
@@ -4235,4 +4235,55 @@ video::-webkit-media-text-track-display {
4235
4235
  /* Clickable watermark cursor */
4236
4236
  .video-watermark[style*="cursor: pointer"] {
4237
4237
  cursor: pointer !important;
4238
+ }
4239
+ /* ===================================
4240
+ FIX SUBMENU CLIPPING ON SMALL SCREENS
4241
+ =================================== */
4242
+
4243
+ /* Change positioning from bottom-aligned to top-aligned when menu would be clipped */
4244
+ /* ONLY affects submenus inside settings menu (small screen mode) */
4245
+ @media (max-height: 600px) {
4246
+ .settings-menu .settings-submenu,
4247
+ .settings-option .settings-submenu,
4248
+ .settings-option .quality-submenu,
4249
+ .settings-option .speed-submenu {
4250
+ /* Remove bottom positioning */
4251
+ bottom: auto !important;
4252
+ /* Align to top of parent option */
4253
+ top: 0 !important;
4254
+ /* Reduce max-height on very small screens */
4255
+ max-height: 150px !important;
4256
+ }
4257
+ }
4258
+
4259
+ /* Even smaller screens - ultra compact */
4260
+ @media (max-height: 400px) {
4261
+ .settings-menu .settings-submenu,
4262
+ .settings-option .settings-submenu,
4263
+ .settings-option .quality-submenu,
4264
+ .settings-option .speed-submenu {
4265
+ max-height: 120px !important;
4266
+ }
4267
+ }
4268
+
4269
+ /* For very small players (width < 400px) - only inside settings menu */
4270
+ @media (max-width: 400px) {
4271
+ .settings-menu .settings-submenu,
4272
+ .settings-option .settings-submenu,
4273
+ .settings-option .quality-submenu,
4274
+ .settings-option .speed-submenu {
4275
+ /* Switch to top alignment */
4276
+ bottom: auto !important;
4277
+ top: 0 !important;
4278
+ max-height: 180px !important;
4279
+ }
4280
+ }
4281
+
4282
+ /* EXCLUDE standalone subtitles menu (the one that appears when player is large) */
4283
+ /* Keep original bottom positioning for standalone menus */
4284
+ .subtitles-button .subtitles-menu,
4285
+ .yt-subtitles-submenu:not(.settings-option *),
4286
+ .yt-quality-submenu:not(.settings-option *) {
4287
+ bottom: 0 !important;
4288
+ top: auto !important;
4238
4289
  }