@vyonio/player 0.2.0 → 0.2.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/CHANGELOG.md ADDED
@@ -0,0 +1,38 @@
1
+ # Changelog
2
+
3
+ ## 0.2.1 — 2026-10-15
4
+
5
+ ### Fixed
6
+
7
+ - Prefer standard or WebKit element fullscreen when available, then native video
8
+ fullscreen on supported iOS video elements, retaining Plyr's CSS fallback.
9
+ - Request fullscreen synchronously from an explicit user action. Opening,
10
+ metadata, playing and autoplay do not enter fullscreen automatically.
11
+ - Recover from unsupported or rejected fullscreen entry; restore inline controls
12
+ on exit and clean up listeners and fullscreen state on destroy/remount.
13
+ Delayed WebKit exit and element entry completing after teardown are covered.
14
+ - Respect disabled or omitted fullscreen controls, including keyboard and
15
+ double-click actions.
16
+ - Remove the unconditional 192px mount minimum. Preserve explicit host sizing
17
+ even when SDK CSS loads last, intrinsic sizing for width-only hosts, source
18
+ aspect ratios, letterboxing, and responsive controls without remounting.
19
+
20
+ ### Validation and limitations
21
+
22
+ - 196 unit/release-script tests and 36 offline browser regression tests passed.
23
+ Browser tests use real Plyr and the built SDK stylesheet in headless Chrome;
24
+ fullscreen capability APIs are simulated. All five requested viewport widths
25
+ (320, 375, 390, 844 and 1400px), rotation, and lifecycle races are covered.
26
+ - Build and independent tarball consumer installation/type-check/build passed.
27
+ - Physical iPhone fullscreen with a supported protected video is **not verified**.
28
+ Apple iPhone Simulator was not used. This release does not claim FairPlay/DRM
29
+ device certification. Native fullscreen uses system controls and cannot render
30
+ HTML badges, the popularity histogram or custom HTML overlays.
31
+
32
+ ### Consumer migration
33
+
34
+ Upgrade the locked `@vyonio/player` dependency to `0.2.1`. Remove the Rails
35
+ `nativeVideoFullscreen()` click-interception helper and its lifecycle wiring.
36
+ After verifying sizing with the released package, remove the SDK-specific
37
+ `min-height: 0` workaround. Keep application container sizing, modal scrolling
38
+ and course-navigation fixes.
package/README.md CHANGED
@@ -66,6 +66,79 @@ as plain text inside Plyr's fullscreen container and is limited to 64
66
66
  characters; positions are the four corners and styles are `dark`, `light`, or
67
67
  `accent`.
68
68
 
69
+ ### Fullscreen and responsive hosts
70
+
71
+ Fullscreen uses element fullscreen when the mounted video's document supports
72
+ it, then native video fullscreen (`fullscreen.iosNative`) when available, and
73
+ Plyr's full-window CSS fallback otherwise. Entry happens only on an explicit
74
+ fullscreen action; mounting, metadata, playing and autoplay do not request it.
75
+ If native entry fails, the existing CSS fallback remains usable. Exiting keeps
76
+ inline playback and controls available. `controls: false` or a `controlItems`
77
+ list without `fullscreen` also disables keyboard and double-click entry.
78
+ Consumers do not need a click interceptor on Plyr's private DOM selectors.
79
+
80
+ Native iPhone fullscreen uses system video controls. HTML badges, the popularity
81
+ histogram and other HTML overlays are not rendered in that system view; custom
82
+ quality/settings UI is available again after returning inline. Do not depend on
83
+ HTML badges for mandatory watermarking. See [Plyr's fullscreen options](https://github.com/sampotts/plyr#options)
84
+ and [Apple's native video API](https://developer.apple.com/documentation/webkitjs/htmlvideoelement/1633500-webkitenterfullscreen).
85
+
86
+ The mount fills a sized host, including heights below 192px, with no minimum
87
+ height override required. Host rules win over SDK size defaults even when the
88
+ SDK stylesheet is loaded last. A width-only host uses the video's intrinsic
89
+ aspect ratio once metadata is available (16:9 before that). Media uses
90
+ `object-fit: contain`, so differing host/media ratios produce intentional
91
+ letterboxing. Resizing and orientation changes do not require a remount.
92
+
93
+ ```css
94
+ /* Choose a host size appropriate to your layout. */
95
+ .video-slot {
96
+ width: 100%;
97
+ aspect-ratio: 16 / 9;
98
+ border-radius: 0.75rem;
99
+ overflow: hidden;
100
+ }
101
+ ```
102
+
103
+ ### Verify fullscreen and sizing changes
104
+
105
+ ```sh
106
+ # From packages/player, with Node 22.12+ and installed dependencies:
107
+ npm test
108
+ # Uses installed Google Chrome. To provision it when absent:
109
+ # npx playwright install chrome
110
+ npm run test:browser
111
+ npm run verify:package
112
+ ```
113
+
114
+ Browser regressions build and load the shipped `dist/style.css` after host CSS
115
+ with real Plyr markup. They cover direct/nested 16:9 hosts at viewport widths
116
+ 320, 375, 390, 844 and 1400px, explicit 120px height, width-only hosts, metadata
117
+ aspect-ratio changes, portrait/landscape resizing, visible usable controls,
118
+ capability selection, synchronous entry, fallback, exit and teardown races.
119
+ They block non-local requests and need no live token/media/DRM/analytics/payment
120
+ services. Browser fullscreen APIs are simulated; desktop mobile emulation does
121
+ not establish that native iPhone fullscreen or protected playback works.
122
+
123
+ Device acceptance remains outstanding: verify on a **physical iPhone** using a supported
124
+ protected video: open/play stays inline; tapping fullscreen opens system video
125
+ fullscreen; exit restores inline video and working controls; repeat entry,
126
+ rotation, closing while fullscreen, source switching and remounting work.
127
+ Record device/iOS/Safari versions and the protected asset/DRM mode without
128
+ recording secrets. Physical iPhone verification has **not** been completed in
129
+ this change.
130
+
131
+ See the shipped [changelog](./CHANGELOG.md) for the 0.2.1 fixes and known
132
+ verification limits. The 0.2.1 patch follows the [repository release procedure](https://gitlab.com/buildio/playground/vyonio.com/-/blob/main/docs/player-release.md);
133
+ 0.2.0 remains immutable. Package version files and the `player-v0.2.1` tag are
134
+ recorded by that procedure only after publication and registry verification.
135
+
136
+ After upgrading the Rails consumer's locked dependency to 0.2.1, remove
137
+ `nativeVideoFullscreen()` and its lifecycle wiring, then remove its SDK-specific
138
+ `min-height: 0` workaround after sizing is verified against the released package.
139
+ Keep normal container sizing, modal scrolling and course-navigation fixes in
140
+ the application.
141
+
69
142
  ### Popularity histogram
70
143
 
71
144
  Pass equal-duration popularity buckets to render a YouTube-like engagement