HomePhabricator
Diffusion Comm 7b2032895388

[native] Add encrypted source support in <Multimedia>

Description

[native] Add encrypted source support in <Multimedia>

Summary:
Until now, the <Miltimedia> component operated on URIs but now encrypted media don't operate on URIs (although for keyserver uploads, the holder is a URI on which we rely here).
Replaced URIs with a Source objects which can be either a URI or encrypted media source.

The component uses the departing URI concept to indicate whether a temporary local file can be disposed. In theory, encrypted media don't have to be marked as departing, but I did it anyway for consistency (this should have no negative impact).

Added support for rendering encrypted source by using the <EncryptedImage> component added in D7225 is used.

Depends on D7225
Depends on D7168

Test Plan:

  • Added a fake mediaInfo prop containing encrypted image URL and ensured that the component displays it.
  • Dynamically replaced a source with and ensured state updates. Departing URI changes can be checked in input-state-container (inspecting the activeURIs variable).

Reviewers: ashoat, atul, marcin

Reviewed By: ashoat

Subscribers: tomek

Differential Revision: https://phab.comm.dev/D7227

Details

Provenance
bartekAuthored on Mar 28 2023, 10:40 AM
Reviewer
ashoat
Differential Revision
D7227: [native] Add encrypted source support in <Multimedia>
Parents
rCOMM46f28c3e9481: [native] VideoPlaybackModal support for encrypted video
Branches
Unknown
Tags
Unknown