Skip to content
This repository was archived by the owner on May 16, 2024. It is now read-only.

upstream merge#12

Open
hannojg wants to merge 1437 commits intocuvent:masterfrom
TheWidlarzGroup:master
Open

upstream merge#12
hannojg wants to merge 1437 commits intocuvent:masterfrom
TheWidlarzGroup:master

Conversation

@hannojg
Copy link

@hannojg hannojg commented May 24, 2021

No description provided.

KrzysztofMoch and others added 30 commits December 22, 2025 12:32
* docs: add twg theme

* docs: import theme css
* docs: add eslint

* chore: remove @eslint/css

* feat(docs): add custom eslint rule for css variables

* ci: check lint on css changes in docs

* ci: update lefthook configuration
* fix: external subtitle asset composition

* fix: filter for supported subtitles before adding them
* fix(ios): prevent KVO crash in HybridVideoPlayer.release()

Fix a crash that occurs when rapidly creating/destroying video players
(e.g., fast swiping through a FlatList of videos). The crash message is:
"Cannot remove an observer for the key path 'currentItem.status'"

Root cause:
When release() was called, it would set playerItem = nil and then
playerObserver = nil, which triggered the observer's deinit. However,
the KVO observers were still registered on the playerItem, causing
a crash when the system tried to remove them.

Solution:
1. Explicitly invalidate all KVO observers BEFORE changing any state
2. Change invalidatePlayerItemObservers() from private to internal
   so it can be called from HybridVideoPlayer.release()
3. Skip self.player.replaceCurrentItem(with: nil) which was also
   triggering the crash by changing currentItem while observers
   were still active

This ensures clean KVO removal before any state changes that could
interfere with the observer lifecycle.

* refactor: address review feedback - clean up comments and reorganize release()

- Remove verbose KVO CRASH FIX comments
- Move observer invalidation calls to "Clear player observer" section
- Restore replaceCurrentItem(with: nil) after observer cleanup

* refactor: reorder cleaners

---------

Co-authored-by: Eran Kaufman <eran@sefirot.io>
Co-authored-by: Kamil Moskała <91079590+moskalakamil@users.noreply.github.com>
* docs: refactor tabs

* docs: update video-view docs

* docs: lowercase tabs

* feat(docs): add downloading section

* chore: add chapters example video

* docs: update sidebar type

* docs: update tab heading

* docs: add title to fundaments

* docs: lowercase plugin

* docs(sidebar): remove link to offline sdk

* docs: add `ads` tab

* chore: add `build` to eslint ignore

* docs: remove theme mermaid

* refactor: update deploy values

* chore: upper case tabs

* refactor: update configuration tabs name

* feat: add `ask for plugin` tab

* refactor: update analytics tab

* docs: update player class tip

* docs: make chapters paid

* docs: update utm's

* docs(downloading): update intro

* chore: bump `docusaurus-ui` package to 0.1.2

* fix: update paths

* docs: update dashes

* docs: update downloading events example imports

* docs: update readme

* docs: update case

* refactor: update intro & offer
* fix: update observer thread

* fix(ios): fix showNotificationControls not working when set during initialization

* fix(ios): set custom metadata on AVPlayerItem for now playing info

* refactor: warn when wront artwork url

* docs: update file header

* chore: warn when failed to load artwork image
…4852)

* fix(ios): restore inline UI after PIP stop to prevent black screen

* fix: restore pip when view is attached
* fix: fixed audio focus change on ios

* Fix formatting for audio session category options

---------

Co-authored-by: Kamil Moskała <91079590+moskalakamil@users.noreply.github.com>
* fix(ios): load artwork asynchronously to unblock notification controls

* fix(ios): remove playback observer on player removal and guard artwork callback

* fix: cleaning up player

* refactor: `if` syntax

* fix: add missing cleaner

* fix: remove `rounded` from current time

* chore: update pod versions

* refactor(ios): use targeted update functions at each call site

* refactor(ios): use async/await to load artwork metadata

* fix(ios): update static now playing info after setting external metadata

* fix: find new player before updating playback state

* fix(ios): take over notification controls when registering an already-playing player

* fix(ios): clear stale artwork and guard against item change in async artwork load

* fix: guard notification controls updates against stale player item

* fix: update playback duration periodically to handle streams with initially unknown duration
* fix(ios): stabilize NowPlaying controls

* fix(ios): dispatch NowPlaying update to main thread (#4862)

* docs: remove comment (#4863)

* rename player with `_`
* fix: video in fullscreen freezing after swiping

* fix(ios): use optional chainin
* chore: Upgrade to Nitro 0.35.0

* Replace `bigint` with `UInt64`

* chore: Regenerate specs now for Nitro 0.35.0

* fix: Use Int64 as it can be -1

* Remove unnecessary patches

* fix: change duration type to number

* fix: avoid mutating VideoInformation fields after init

* chore: regenerate specs with new duration type

* fix: use Double for duration in VideoInformation

* docs: react-native-nitro-modules version

* chore: update react-native-nitro-modules version (rnv & drm)

---------

Co-authored-by: fnwk <filip.wnek200@gmail.com>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.