ogplayer 1.2.2 → 1.3.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.
@@ -1,6 +1,6 @@
1
1
  /**
2
- * Control glyphs — the EXACT vector paths from the Android SDK's
3
- * `og_ic_*.xml` drawables (24×24 viewport, stroked, round caps/joins), so
2
+ * Control glyphs — the SDK's vector paths (24×24 viewport, stroked, round
3
+ * caps/joins), so
4
4
  * the three platforms render identical iconography. `filled` paths use fill
5
5
  * instead of stroke (play/pause/volume body).
6
6
  */
@@ -3,14 +3,14 @@ import type { OGPlayerError } from "../core/types.js";
3
3
  import { type OGControlColors, type OGControlDimens } from "./tokens.js";
4
4
  import { type OGKeymap } from "./keymap.js";
5
5
  /** A host-supplied icon button rendered left of the (future) cast position —
6
- * icon-only, max 8, part of the chrome (mirrors Android/iOS `CustomAction`). */
6
+ * icon-only, max 8, part of the chrome (. */
7
7
  export interface CustomAction {
8
8
  /** Inline SVG markup (24×24 recommended); rendered with the chrome tint. */
9
9
  svg: string;
10
10
  accessibilityLabel?: string;
11
11
  onClick: () => void;
12
12
  }
13
- /** Per-control visibility + behavior — Android's `OGUiConfig` counterpart. */
13
+ /** Per-control visibility + behavior. */
14
14
  export interface OGUIConfig {
15
15
  showProgressBar: boolean;
16
16
  showTimeLabels: boolean;
@@ -117,13 +117,13 @@ export interface OGUIConfig {
117
117
  }
118
118
  export declare const defaultUIConfig: OGUIConfig;
119
119
  /** Every control flag off — headless chrome in one call (mobile parity:
120
- * `hideAllControls()`). Title/ratings stay, exactly like Android/iOS. */
120
+ * `hideAllControls()`). Title/ratings stay,. */
121
121
  export declare function hidingAllControls(overrides?: Partial<OGUIConfig>): Partial<OGUIConfig>;
122
122
  /**
123
123
  * `<og-player>` — the OGPlayer UI as a framework-agnostic custom element
124
124
  * (works in plain HTML, React, Vue, Angular alike). Attach an `OGPlayer`
125
125
  * engine via the `player` property; overlays (watermarks, logos) go into the
126
- * nine named slots (`slot="top-end"` …), mirroring the Android/iOS
126
+ * nine named slots (`slot="top-end"` …),
127
127
  * `OverlaySlot` system including the clearance choreography.
128
128
  */
129
129
  export declare class OGPlayerElement extends HTMLElement {
@@ -132,6 +132,8 @@ export declare class OGPlayerElement extends HTMLElement {
132
132
  private root;
133
133
  private controlsVisible;
134
134
  private hideTimer;
135
+ /** Whether the current ad's provider draws its own layer over the video (IMA). */
136
+ private currentAdRendersUi;
135
137
  /** Where the last deliberate tap-to-hide happened; gates hover-raise. */
136
138
  private hidePoint;
137
139
  /** Pointer type of the most recent pointerdown on the stage; "" until one lands. */
@@ -186,7 +188,7 @@ export declare class OGPlayerElement extends HTMLElement {
186
188
  private maybeShowOnceOverlays;
187
189
  private ratingNode;
188
190
  /** While the rating row is shown, the top-end button row drops below it
189
- * and top-row overlays clear both — the Android/iOS choreography. */
191
+ * and top-row overlays clear both. */
190
192
  private setRatingRow;
191
193
  private applyOverlayInsets;
192
194
  private showControls;
@@ -203,8 +205,9 @@ export declare class OGPlayerElement extends HTMLElement {
203
205
  private paintAdCues;
204
206
  private syncPeriodic;
205
207
  /** Break-mode UI: the SDK yields the chrome to the ad layer and draws its
206
- * own yellow bar + AD chip + centered transport (mobile parity — IMA
207
- * renders its own skip/clickthrough on top of its layer). */
208
+ * own yellow bar + play/pause + AD chip (mobile parity — IMA renders its own
209
+ * skip/clickthrough on top of its layer). Nothing sits over a playing ad:
210
+ * the bar button is the transport for the whole break. */
208
211
  private syncAdUi;
209
212
  private syncWatermark;
210
213
  /** Same markup as the template's `.watermark` — used when the node was removed from the open shadow root. */
@@ -2,8 +2,7 @@ import { type OGVerticalFeedConfig, type OGVerticalFeedItem } from "../core/vert
2
2
  import type { OGPlayerError } from "../core/types.js";
3
3
  /**
4
4
  * `<og-vertical-feed>` — a swipeable, full-screen vertical video feed built
5
- * on the OGPlayer engine; the web counterpart of the Android/iOS
6
- * `OGVerticalFeedView`, with the same names and semantics. A separate
5
+ * on the OGPlayer engine. A separate
7
6
  * surface from `<og-player>` on purpose: portrait-only, no fullscreen or
8
7
  * rotation API, its own minimal chrome.
9
8
  *
@@ -1,7 +1,5 @@
1
1
  /**
2
- * Design tokens — Android's `OGControlColors` / `OGControlDimens`,
3
- * token-for-token (dp → px at CSS-pixel scale, which is the same unit
4
- * philosophy the Android/iOS SDKs use).
2
+ * Design tokens — colours and dimensions in CSS pixels.
5
3
  */
6
4
  export interface OGControlColors {
7
5
  foreground: string;
@@ -47,5 +45,5 @@ export interface OGControlDimens {
47
45
  adCueMarkerSize: number;
48
46
  }
49
47
  export declare const embeddedDimens: OGControlDimens;
50
- /** Fullscreen step-up (Android `forFullscreen()`). */
48
+ /** Fullscreen step-up. */
51
49
  export declare const fullscreenDimens: OGControlDimens;
@@ -8,8 +8,7 @@
8
8
  * throw on the missing node and take every other overlay down with it, and
9
9
  * (2) while the player is unlicensed the mark is re-created on the next sync,
10
10
  * so a removal lasts only until the next player event — the same standing as
11
- * Android/iOS, where the mark is a composable / SwiftUI view with no
12
- * addressable instance to remove. Tampering with the mark is a terms-of-use
11
+ * native views, where the mark has no addressable instance to remove. Tampering with the mark is a terms-of-use
13
12
  * matter either way (terms §3); this keeps the SDK's own behaviour consistent.
14
13
  */
15
14
  export interface WatermarkHost {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ogplayer",
3
- "version": "1.2.2",
3
+ "version": "1.3.1",
4
4
  "description": "OGPlayer video player for the browser — an <og-player> web component with HLS, DRM (Widevine, PlayReady, FairPlay), Google IMA ads, playlists and themeable controls.",
5
5
  "type": "module",
6
6
  "main": "./dist/ogplayer.js",