@cinecrew/cinecrew-player 0.1.2 → 0.1.4

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.
@@ -30,7 +30,7 @@
30
30
 
31
31
  .cinecrew-player__video,
32
32
  .cinecrew-player__youtube {
33
- transition: width 180ms ease, height 180ms ease, top 180ms ease;
33
+ transition: width 180ms ease, height 180ms ease, top 180ms ease, left 180ms ease, transform 180ms ease;
34
34
  }
35
35
 
36
36
  .cinecrew-player__shade {
@@ -40,10 +40,9 @@
40
40
  }
41
41
 
42
42
  .cinecrew-player__title {
43
- position: absolute;
44
- top: 62px;
45
- left: 20px;
46
- right: 20px;
43
+ flex: 1 1 auto;
44
+ min-width: 0;
45
+ text-align: center;
47
46
  z-index: 2;
48
47
  overflow: hidden;
49
48
  font-weight: 700;
@@ -70,6 +69,14 @@
70
69
  opacity: 1;
71
70
  }
72
71
 
72
+ .cinecrew-player__controls.is-recording { opacity: 1; }
73
+ .cinecrew-player__controls.is-recording > .cinecrew-player__top-controls,
74
+ .cinecrew-player__controls.is-recording > .cinecrew-player__center-controls,
75
+ .cinecrew-player__controls.is-recording > .cinecrew-player__bottom-controls {
76
+ visibility: hidden;
77
+ pointer-events: none;
78
+ }
79
+
73
80
  .cinecrew-player__top-controls,
74
81
  .cinecrew-player__bottom-controls,
75
82
  .cinecrew-player__center-controls,
@@ -103,8 +110,11 @@
103
110
 
104
111
  .cinecrew-player__top-right-actions {
105
112
  justify-content: flex-end;
113
+ flex: 0 0 auto;
106
114
  }
107
115
 
116
+ .cinecrew-player__top-left-actions { flex: 0 0 auto; }
117
+
108
118
  .cinecrew-player__bottom-controls {
109
119
  width: 100%;
110
120
  flex-direction: column;
@@ -128,18 +138,76 @@
128
138
  justify-content: center;
129
139
  }
130
140
 
141
+ .cinecrew-player__recording-overlay {
142
+ position: absolute;
143
+ top: 10px;
144
+ left: 50%;
145
+ z-index: 5;
146
+ display: flex;
147
+ min-width: 0;
148
+ max-width: calc(100% - 24px);
149
+ box-sizing: border-box;
150
+ align-items: center;
151
+ justify-content: center;
152
+ gap: 8px;
153
+ flex-wrap: wrap;
154
+ padding: 7px 10px;
155
+ border: 1px solid rgba(255,255,255,.22);
156
+ border-radius: 12px;
157
+ background: rgba(0, 0, 0, .68);
158
+ box-shadow: 0 6px 18px rgba(0,0,0,.28);
159
+ transform: translateX(-50%);
160
+ backdrop-filter: blur(8px);
161
+ font-size: .88em;
162
+ }
163
+
164
+ .cinecrew-player__recording-overlay.is-error { border-color: var(--cinecrew-accent); }
165
+ .cinecrew-player__recording-indicator { color: #ff4b63; font-size: .78em; font-weight: 800; letter-spacing: .08em; }
166
+ .cinecrew-player__recording-timer { font-variant-numeric: tabular-nums; font-size: 1.05em; }
167
+ .cinecrew-player__recording-actions { display: flex; gap: 6px; }
168
+ .cinecrew-player__recording-actions button,
169
+ .cinecrew-player__recording-overlay > button {
170
+ border: 1px solid rgba(255,255,255,.2);
171
+ border-radius: 999px;
172
+ padding: 6px 9px;
173
+ color: inherit;
174
+ background: rgba(255,255,255,.1);
175
+ cursor: pointer;
176
+ font: inherit;
177
+ }
178
+ .cinecrew-player__recording-download {
179
+ display: inline-flex;
180
+ align-items: center;
181
+ border: 1px solid rgba(255,255,255,.2);
182
+ border-radius: 999px;
183
+ padding: 6px 9px;
184
+ color: inherit;
185
+ background: rgba(255,255,255,.1);
186
+ text-decoration: none;
187
+ font: inherit;
188
+ }
189
+ .cinecrew-player__recording-actions button:last-child { border-color: #ff4b63; background: rgba(255,75,99,.2); }
190
+ .cinecrew-player__recording-ready { color: #70e3b1; }
191
+
131
192
  .cinecrew-player__seek {
132
193
  flex: 0 0 auto;
133
194
  width: 100%;
195
+ align-items: center;
134
196
  font-variant-numeric: tabular-nums;
135
197
  text-shadow: 0 1px 3px #000;
136
198
  }
137
199
 
200
+ .cinecrew-player__seek > span {
201
+ min-width: 3.4em;
202
+ }
203
+
204
+ .cinecrew-player__seek > span:last-child { text-align: right; }
205
+
138
206
  .cinecrew-player__seek input {
139
207
  flex: 1;
140
208
  min-width: 50px;
141
209
  min-height: 24px;
142
- touch-action: auto;
210
+ touch-action: pan-y;
143
211
  cursor: ew-resize;
144
212
  }
145
213
 
@@ -193,8 +261,9 @@
193
261
 
194
262
  .cinecrew-player__audio-card {
195
263
  position: absolute;
196
- inset: 10%;
264
+ inset: 0;
197
265
  z-index: 5;
266
+ box-sizing: border-box;
198
267
  display: flex;
199
268
  flex-direction: column;
200
269
  align-items: center;
@@ -202,7 +271,7 @@
202
271
  gap: 18px;
203
272
  padding: 24px;
204
273
  border: 1px solid;
205
- border-radius: 20px;
274
+ border-radius: inherit;
206
275
  text-align: center;
207
276
  box-shadow: 0 18px 60px rgba(0, 0, 0, .32);
208
277
  }
@@ -214,6 +283,23 @@
214
283
  border-radius: 50%;
215
284
  }
216
285
 
286
+ .cinecrew-player__audio-placeholder {
287
+ display: grid;
288
+ width: min(30vw, 160px);
289
+ aspect-ratio: 1;
290
+ place-items: center;
291
+ border: 2px solid var(--cinecrew-accent, #00d4ff);
292
+ border-radius: 50%;
293
+ background: radial-gradient(circle at 35% 30%, rgba(0, 212, 255, .28), transparent 58%), linear-gradient(145deg, #142b49, #081321 72%);
294
+ box-shadow: 0 0 28px rgba(0, 212, 255, .2), inset 0 0 22px rgba(0, 212, 255, .12);
295
+ }
296
+
297
+ .cinecrew-player__audio-placeholder .cinecrew-player__icon {
298
+ width: 42px;
299
+ height: 42px;
300
+ font-size: 42px;
301
+ }
302
+
217
303
  .cinecrew-player__audio-wave {
218
304
  letter-spacing: .28em;
219
305
  font-size: 1.25rem;
@@ -302,36 +388,121 @@
302
388
  font: inherit;
303
389
  }
304
390
 
391
+ .cinecrew-player__menu-empty {
392
+ padding: 10px 13px;
393
+ color: var(--cinecrew-text, #fff);
394
+ white-space: nowrap;
395
+ }
396
+
305
397
  .cinecrew-player__menu-wrap--aspect .cinecrew-player__menu button {
306
398
  padding-block: 6px;
307
399
  }
308
400
 
309
401
  .cinecrew-player__diagnostics {
310
402
  display: flex;
403
+ box-sizing: border-box;
404
+ height: 100%;
311
405
  flex-direction: column;
312
- gap: 10px;
313
- min-width: 220px;
406
+ gap: 14px;
407
+ min-width: 0;
408
+ overflow: auto;
314
409
  }
315
410
 
316
- .cinecrew-player__diagnostics > strong {
317
- padding-bottom: 8px;
411
+ .cinecrew-player__diagnostics-heading {
412
+ display: flex;
413
+ align-items: flex-start;
414
+ justify-content: space-between;
415
+ gap: 12px;
416
+ padding-bottom: 12px;
318
417
  border-bottom: 1px solid rgba(255, 255, 255, .14);
319
418
  }
320
419
 
321
- .cinecrew-player__diagnostic-row {
420
+ .cinecrew-player__diagnostics-heading > div {
322
421
  display: flex;
323
- justify-content: space-between;
324
- gap: 16px;
422
+ min-width: 0;
423
+ flex-direction: column;
424
+ gap: 3px;
425
+ }
426
+
427
+ .cinecrew-player__diagnostics-heading strong { font-size: 1.05rem; }
428
+ .cinecrew-player__diagnostics-heading > div > span { opacity: .7; overflow-wrap: anywhere; }
429
+
430
+ .cinecrew-player__diagnostics-close {
431
+ display: grid;
432
+ flex: 0 0 36px;
433
+ width: 36px;
434
+ height: 36px;
435
+ place-items: center;
436
+ border: 1px solid rgba(255,255,255,.2);
437
+ border-radius: 50%;
438
+ color: inherit;
439
+ background: rgba(255,255,255,.1);
440
+ cursor: pointer;
441
+ }
442
+
443
+ .cinecrew-player__diagnostics-status {
444
+ display: flex;
445
+ align-items: center;
446
+ gap: 8px;
447
+ align-self: flex-start;
448
+ padding: 6px 10px;
449
+ border: 1px solid rgba(255,255,255,.15);
450
+ border-radius: 999px;
451
+ background: rgba(255,255,255,.07);
452
+ font-size: .86em;
453
+ }
454
+
455
+ .cinecrew-player__status-dot {
456
+ width: 8px;
457
+ height: 8px;
458
+ border-radius: 50%;
459
+ background: #9ba9bb;
460
+ box-shadow: 0 0 10px currentColor;
461
+ }
462
+
463
+ .cinecrew-player__status-dot.is-playing { color: #42d392; background: currentColor; }
464
+ .cinecrew-player__status-dot.is-buffering { color: #ffca58; background: currentColor; }
465
+ .cinecrew-player__status-dot.is-error { color: #ff647c; background: currentColor; }
466
+
467
+ .cinecrew-player__diagnostic-grid {
468
+ display: grid;
469
+ grid-template-columns: repeat(2, minmax(0, 1fr));
470
+ gap: 9px;
471
+ }
472
+
473
+ .cinecrew-player__diagnostic-card {
474
+ display: grid;
475
+ min-width: 0;
476
+ grid-template-columns: 32px minmax(0, 1fr);
477
+ grid-template-rows: auto auto;
478
+ align-items: center;
479
+ column-gap: 9px;
480
+ row-gap: 3px;
481
+ padding: 10px;
482
+ border: 1px solid rgba(255,255,255,.14);
483
+ border-radius: 12px;
484
+ background: rgba(255,255,255,.08);
325
485
  font-variant-numeric: tabular-nums;
326
486
  }
327
487
 
328
- .cinecrew-player__diagnostic-row span:first-child {
329
- opacity: .72;
488
+ .cinecrew-player__diagnostic-icon {
489
+ display: grid;
490
+ width: 30px;
491
+ height: 30px;
492
+ grid-row: span 2;
493
+ place-items: center;
494
+ border-radius: 9px;
495
+ border: 1px solid color-mix(in srgb, var(--diagnostic-accent, #fff) 32%, transparent);
496
+ background: color-mix(in srgb, var(--diagnostic-accent, #fff) 14%, transparent);
330
497
  }
331
498
 
332
- .cinecrew-player__diagnostic-row span:last-child {
333
- text-align: right;
334
- overflow-wrap: anywhere;
499
+ .cinecrew-player__diagnostic-icon .cinecrew-player__icon { width: 18px; height: 18px; }
500
+ .cinecrew-player__diagnostic-label { overflow: hidden; opacity: .7; font-size: .76em; text-overflow: ellipsis; white-space: nowrap; }
501
+ .cinecrew-player__diagnostic-card strong { overflow-wrap: anywhere; font-size: .9em; }
502
+ .cinecrew-player__diagnostics-note { opacity: .65; line-height: 1.35; }
503
+
504
+ @media (max-width: 420px) {
505
+ .cinecrew-player__diagnostic-grid { grid-template-columns: minmax(0, 1fr); }
335
506
  }
336
507
 
337
508
  .cinecrew-player__panel-content {
@@ -370,6 +541,16 @@
370
541
  gap: 8px;
371
542
  min-height: 0;
372
543
  overflow: auto;
544
+ overscroll-behavior: contain;
545
+ scrollbar-width: thin;
546
+ }
547
+
548
+ .cinecrew-player__older-loading {
549
+ flex: 0 0 auto;
550
+ align-self: center;
551
+ padding: 6px 10px;
552
+ color: var(--cinecrew-accent);
553
+ font-size: .86em;
373
554
  }
374
555
 
375
556
  .cinecrew-player__chat-message,
@@ -418,19 +599,21 @@
418
599
 
419
600
  .cinecrew-player__chat-composer {
420
601
  position: relative;
602
+ container-type: inline-size;
421
603
  display: flex;
422
604
  align-items: center;
423
- gap: 8px;
424
- padding: 6px;
425
- border: 1px solid rgba(255, 255, 255, .2);
426
- border-radius: 999px;
427
- background: rgba(0, 0, 0, .2);
605
+ gap: 7px;
606
+ padding: 5px 6px 5px 10px;
607
+ border: 1px solid rgba(255, 255, 255, .22);
608
+ border-radius: 14px;
609
+ background: rgba(12, 20, 32, .72);
610
+ box-shadow: 0 3px 12px rgba(0,0,0,.12);
428
611
  transition: border-color .16s ease, box-shadow .16s ease, background-color .16s ease;
429
612
  }
430
613
 
431
614
  .cinecrew-player__chat-composer:focus-within {
432
615
  border-color: var(--cinecrew-accent);
433
- background: rgba(0, 0, 0, .28);
616
+ background: rgba(12, 20, 32, .88);
434
617
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--cinecrew-accent) 18%, transparent);
435
618
  }
436
619
 
@@ -439,7 +622,7 @@
439
622
  min-width: 0;
440
623
  border: 0;
441
624
  outline: 0;
442
- padding: 8px 10px;
625
+ padding: 10px 4px;
443
626
  color: inherit;
444
627
  background: transparent;
445
628
  font: inherit;
@@ -468,15 +651,19 @@
468
651
  }
469
652
 
470
653
  .cinecrew-player__chat-composer button[type="submit"] {
471
- min-width: auto;
472
- padding: 0 14px;
473
- border-radius: 999px;
654
+ width: 40px;
655
+ min-width: 40px;
656
+ height: 40px;
657
+ min-height: 40px;
658
+ padding: 0;
659
+ border-radius: 12px;
474
660
  color: #07111e;
475
661
  background: var(--cinecrew-accent);
476
- font-weight: 700;
477
662
  box-shadow: 0 2px 8px color-mix(in srgb, var(--cinecrew-accent) 24%, transparent);
478
663
  }
479
664
 
665
+ .cinecrew-player__chat-composer button[type="submit"] .cinecrew-player__icon { width: 19px; height: 19px; }
666
+
480
667
  .cinecrew-player__chat-composer button[type="submit"]:hover:not(:disabled) {
481
668
  filter: brightness(1.08);
482
669
  }
@@ -488,8 +675,9 @@
488
675
 
489
676
  .cinecrew-player__emoji-picker {
490
677
  position: absolute;
491
- right: 0;
492
- bottom: calc(100% + 12px);
678
+ left: 0;
679
+ right: auto;
680
+ bottom: 100%;
493
681
  z-index: 2;
494
682
  display: flex;
495
683
  flex-direction: column;
@@ -503,7 +691,31 @@
503
691
  box-shadow: 0 10px 30px rgba(0, 0, 0, .42);
504
692
  }
505
693
 
506
- .cinecrew-player__chat-composer .cinecrew-player__emoji-search {
694
+ @supports (width: 1cqw) {
695
+ .cinecrew-player__emoji-picker { width: min(340px, 100cqw); }
696
+ }
697
+
698
+ .cinecrew-player__emoji-anchor {
699
+ position: relative;
700
+ display: inline-flex;
701
+ flex: 0 0 34px;
702
+ width: 34px;
703
+ height: 34px;
704
+ align-self: center;
705
+ align-items: center;
706
+ }
707
+
708
+ .cinecrew-player__emoji-anchor > .cinecrew-player__emoji-toggle {
709
+ box-sizing: border-box;
710
+ width: 34px;
711
+ min-width: 34px;
712
+ height: 34px;
713
+ min-height: 34px;
714
+ padding: 0;
715
+ line-height: 1;
716
+ }
717
+
718
+ .cinecrew-player__emoji-picker .cinecrew-player__emoji-search {
507
719
  flex: 0 0 auto;
508
720
  width: 100%;
509
721
  box-sizing: border-box;
@@ -517,7 +729,7 @@
517
729
  font-size: 13px;
518
730
  }
519
731
 
520
- .cinecrew-player__chat-composer .cinecrew-player__emoji-search:focus {
732
+ .cinecrew-player__emoji-picker .cinecrew-player__emoji-search:focus {
521
733
  border-color: var(--cinecrew-accent);
522
734
  }
523
735
 
@@ -538,7 +750,7 @@
538
750
  font: inherit;
539
751
  }
540
752
 
541
- .cinecrew-player__chat-composer .cinecrew-player__emoji-categories button {
753
+ .cinecrew-player__emoji-picker .cinecrew-player__emoji-categories button {
542
754
  display: grid;
543
755
  min-width: 0;
544
756
  min-height: 34px;
@@ -550,8 +762,8 @@
550
762
  font-size: 19px;
551
763
  }
552
764
 
553
- .cinecrew-player__chat-composer .cinecrew-player__emoji-categories button:hover,
554
- .cinecrew-player__chat-composer .cinecrew-player__emoji-categories button.is-active {
765
+ .cinecrew-player__emoji-picker .cinecrew-player__emoji-categories button:hover,
766
+ .cinecrew-player__emoji-picker .cinecrew-player__emoji-categories button.is-active {
555
767
  border-color: var(--cinecrew-accent);
556
768
  background: color-mix(in srgb, var(--cinecrew-accent) 14%, transparent);
557
769
  }
@@ -568,24 +780,27 @@
568
780
  scrollbar-width: thin;
569
781
  }
570
782
 
571
- .cinecrew-player__chat-composer .cinecrew-player__emoji-grid button {
783
+ .cinecrew-player__emoji-picker .cinecrew-player__emoji-grid button {
572
784
  display: grid;
573
785
  width: 100%;
574
786
  min-width: 0;
575
- min-height: 34px;
787
+ min-height: 38px;
576
788
  place-items: center;
577
789
  border: 0;
578
- border-radius: 8px;
790
+ border-radius: 50%;
579
791
  padding: 0;
580
792
  background: transparent;
581
- font-size: 19px;
793
+ font-size: 23px;
794
+ line-height: 1;
795
+ transition: background-color .12s ease, transform .12s ease;
582
796
  }
583
797
 
584
- .cinecrew-player__chat-composer .cinecrew-player__emoji-grid button:hover {
798
+ .cinecrew-player__emoji-picker .cinecrew-player__emoji-grid button:hover {
585
799
  background: rgba(255, 255, 255, .12);
800
+ transform: scale(1.12);
586
801
  }
587
802
 
588
- .cinecrew-player__chat-composer .cinecrew-player__emoji-grid .cinecrew-player__emoji-load-more {
803
+ .cinecrew-player__emoji-picker .cinecrew-player__emoji-grid .cinecrew-player__emoji-load-more {
589
804
  grid-column: 1 / -1;
590
805
  min-height: 34px;
591
806
  border: 1px solid rgba(255, 255, 255, .14);
@@ -638,6 +853,12 @@
638
853
  background: rgba(255,255,255,.1);
639
854
  }
640
855
 
856
+ .cinecrew-player__menu .cinecrew-player__menu-option.is-selected {
857
+ color: var(--cinecrew-accent);
858
+ background: color-mix(in srgb, var(--cinecrew-accent) 18%, transparent);
859
+ font-weight: 700;
860
+ }
861
+
641
862
  .cinecrew-player__panel {
642
863
  position: absolute;
643
864
  inset: 0 0 0 auto;
@@ -649,15 +870,31 @@
649
870
  padding: 16px;
650
871
  border-left: 1px solid rgba(255,255,255,.2);
651
872
  border-radius: 0;
652
- background: rgba(13, 26, 44, .78);
653
- backdrop-filter: blur(18px);
873
+ background: rgba(13, 26, 44, .58);
874
+ backdrop-filter: blur(10px);
654
875
  box-shadow: -12px 0 34px rgba(0,0,0,.34);
655
876
  animation: cinecrew-drawer-in 180ms ease-out both;
656
877
  }
657
878
 
658
- .cinecrew-player--drawer-resize .cinecrew-player__panel { width: min(420px, 36%); }
879
+ .cinecrew-player--drawer-resize .cinecrew-player__panel {
880
+ width: calc(100% - var(--cinecrew-media-width, 64%));
881
+ max-width: none;
882
+ padding: 14px;
883
+ }
884
+
885
+ .cinecrew-player__panel.is-resizing { background: rgba(13, 26, 44, .82); }
659
886
 
660
- .cinecrew-player__panel.is-resizing { background: rgba(13, 26, 44, .88); }
887
+ .cinecrew-player--drawer-resize .cinecrew-player__shade,
888
+ .cinecrew-player--drawer-resize .cinecrew-player__controls,
889
+ .cinecrew-player--drawer-resize .cinecrew-player__status,
890
+ .cinecrew-player--drawer-resize .cinecrew-player__error {
891
+ right: auto;
892
+ width: var(--cinecrew-media-width, 64%);
893
+ }
894
+
895
+ .cinecrew-player--drawer-resize .cinecrew-player__title {
896
+ right: calc(100% - var(--cinecrew-media-width, 64%));
897
+ }
661
898
 
662
899
  .cinecrew-player__panel-close {
663
900
  position: absolute;
@@ -681,9 +918,11 @@
681
918
 
682
919
  @media (max-width: 640px) {
683
920
  .cinecrew-player__controls { padding: 10px; }
684
- .cinecrew-player__top-controls { align-items: flex-start; gap: 6px; }
685
- .cinecrew-player__top-left-actions { gap: 4px; }
921
+ .cinecrew-player__top-controls { align-items: center; gap: 6px; flex-wrap: wrap; }
922
+ .cinecrew-player__title { order: 3; flex: 0 0 100%; box-sizing: border-box; padding: 0 4px; text-align: center; }
923
+ .cinecrew-player__top-left-actions { order: 1; gap: 4px; }
686
924
  .cinecrew-player__top-right-actions {
925
+ order: 2;
687
926
  max-width: calc(100% - 128px);
688
927
  flex-wrap: wrap;
689
928
  gap: 4px;
@@ -695,8 +934,9 @@
695
934
  min-height: 34px;
696
935
  padding: 6px 8px;
697
936
  }
698
- .cinecrew-player__title { top: 96px; left: 12px; right: 12px; }
699
937
  .cinecrew-player__bottom-actions { align-items: flex-end; gap: 6px; }
700
938
  .cinecrew-player__bottom-right-actions { max-width: 100%; flex-wrap: wrap; justify-content: flex-end; gap: 4px; }
701
939
  .cinecrew-player__panel { width: min(380px, 92%); }
940
+ .cinecrew-player--drawer-resize { --cinecrew-media-width: 52% !important; }
941
+ .cinecrew-player--drawer-resize .cinecrew-player__panel { width: calc(100% - var(--cinecrew-media-width)); padding: 10px; }
702
942
  }
package/types/index.d.ts CHANGED
@@ -1,6 +1,7 @@
1
1
  import type * as React from 'react';
2
2
 
3
3
  export type AspectRatio = 'FIT' | 'FILL' | 'STRETCH' | 'FILL_SCREEN' | string;
4
+ export interface AspectRatioOption { value: AspectRatio; label?: string }
4
5
  export type PlayerMediaType = 'live' | 'channel' | 'movie' | 'series' | string;
5
6
 
6
7
  export interface PlayerSource {
@@ -57,6 +58,8 @@ export interface PlayerApi {
57
58
  seekBy(seconds: number): void;
58
59
  back(): void;
59
60
  setPlaybackRate(rate: number): void;
61
+ setPanel(panel: 'chat' | 'epg' | 'diagnostics' | null): void;
62
+ closePanel(): void;
60
63
  getVideoElement(): unknown | null;
61
64
  getAudioTracks(): AudioTrack[];
62
65
  enterFullscreen?(): void | Promise<void>;
@@ -77,6 +80,7 @@ export interface PlayerActionContext {
77
80
  video?: unknown | null;
78
81
  }
79
82
 
83
+ /** Notification invoked after the player's built-in action has executed. */
80
84
  export type PlayerAction = (payload?: Record<string, unknown>, context?: PlayerActionContext) => unknown;
81
85
 
82
86
  export interface PlayerActions {
@@ -209,9 +213,14 @@ export interface CineCrewPlayerProps {
209
213
  drawerMode?: PlayerDrawerMode;
210
214
  /** Web CSS or React Native view-style overrides for the chat, EPG, and diagnostics drawer. */
211
215
  drawerStyle?: React.CSSProperties | import('react-native').ViewStyle;
212
- /** Number of chat messages fetched per page; older pages load from the drawer's See more button. Defaults to 50. */
216
+ /** Number of chat messages fetched per page. Older pages load automatically when scrolling to the top. Defaults to 50. */
213
217
  messagePageSize?: number;
218
+ /** Available aspect-ratio choices. Items may be values or labeled { value, label } options. */
219
+ aspectRatios?: Array<AspectRatio | AspectRatioOption>;
220
+ /** Initial aspect-ratio choice. Defaults to FIT. */
221
+ defaultAspectRatio?: AspectRatio;
214
222
  features?: { diagnostics?: boolean; [key: string]: boolean | undefined };
223
+ /** App callbacks invoked after each corresponding built-in action. */
215
224
  actions?: PlayerActions;
216
225
  integrations?: PlayerIntegrations;
217
226
  theme?: PlayerTheme;
@@ -236,6 +245,8 @@ export interface CineCrewPlayerProps {
236
245
  onClose?: () => void;
237
246
  onBack?: () => void;
238
247
  onFullscreen?: (state: { isFullscreen: boolean }) => void;
248
+ /** Invoked after the player applies an aspect ratio selection; actions.onAspectRatioChange takes precedence when both are supplied. */
249
+ onAspectRatioChange?: PlayerAction;
239
250
  onPlayerHostRef?: (node: unknown | null) => void;
240
251
  onInlinePreviewWheel?: (deltaY: number) => void;
241
252
  inlinePreview?: boolean;
@@ -245,6 +256,8 @@ export interface CineCrewPlayerProps {
245
256
  liveChatNonce?: number;
246
257
  onReady?: (playerOrEvent: unknown) => void;
247
258
  onProgress?: (event: unknown) => void;
259
+ /** Called once for each elapsed playback second and after a completed seek/restart with a zero-padded HH:MM:SS position. */
260
+ onProgressBarChange?: (time: string) => void;
248
261
  onPlaying?: (event: unknown) => void;
249
262
  onBuffering?: (buffering: boolean) => void;
250
263
  onError?: (error: Error | Record<string, unknown>) => void;