@applicaster/zapp-react-native-ui-components 16.0.0-alpha.3534530222 → 16.0.0-alpha.4115436491
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.
|
@@ -295,7 +295,7 @@ export class LiveImageManager implements PlayerLifecycleListener {
|
|
|
295
295
|
|
|
296
296
|
setUserCellPlayerMutedPreference(true);
|
|
297
297
|
|
|
298
|
-
this.items.forEach((liveImage) => liveImage.
|
|
298
|
+
this.items.forEach((liveImage) => liveImage.mute());
|
|
299
299
|
};
|
|
300
300
|
|
|
301
301
|
public unmuteAll = () => {
|
|
@@ -303,7 +303,7 @@ export class LiveImageManager implements PlayerLifecycleListener {
|
|
|
303
303
|
|
|
304
304
|
setUserCellPlayerMutedPreference(false);
|
|
305
305
|
|
|
306
|
-
this.items.forEach((liveImage) => liveImage.
|
|
306
|
+
this.items.forEach((liveImage) => liveImage.unmute());
|
|
307
307
|
};
|
|
308
308
|
|
|
309
309
|
public onViewPositionChanged = (item: LiveImage) => {
|
|
@@ -573,6 +573,20 @@ export class LiveImage implements QuickBrickPlayer.SharedPlayerCallBacks {
|
|
|
573
573
|
left: 0,
|
|
574
574
|
};
|
|
575
575
|
|
|
576
|
+
// Keeps muted state in sync: updates the initial value for deferred
|
|
577
|
+
// player creation and forwards to the player if it already exists.
|
|
578
|
+
public initiallyMuted: boolean = true;
|
|
579
|
+
|
|
580
|
+
mute = () => {
|
|
581
|
+
this.initiallyMuted = true;
|
|
582
|
+
this.player?.mute();
|
|
583
|
+
};
|
|
584
|
+
|
|
585
|
+
unmute = () => {
|
|
586
|
+
this.initiallyMuted = false;
|
|
587
|
+
this.player?.unmute();
|
|
588
|
+
};
|
|
589
|
+
|
|
576
590
|
positionToString() {
|
|
577
591
|
if (!this.position) {
|
|
578
592
|
return "position not set";
|
|
@@ -634,6 +648,7 @@ export class LiveImage implements QuickBrickPlayer.SharedPlayerCallBacks {
|
|
|
634
648
|
playerId: this.factoryConfig.playerId,
|
|
635
649
|
autoplay: false,
|
|
636
650
|
entry,
|
|
651
|
+
muted: this.initiallyMuted,
|
|
637
652
|
playerPluginId: this.factoryConfig.playerPluginId,
|
|
638
653
|
screenConfig: this.factoryConfig.screenConfig,
|
|
639
654
|
playerRole: PlayerRole.Cell,
|
|
@@ -134,6 +134,9 @@ const PlayerLiveImageComponent = (props: Props) => {
|
|
|
134
134
|
});
|
|
135
135
|
}, [playerId, preloadHooks, playerPluginId, screenConfig, item]);
|
|
136
136
|
|
|
137
|
+
// Keep the muted state in sync with user preference and player state
|
|
138
|
+
liveImageItem.initiallyMuted = muted;
|
|
139
|
+
|
|
137
140
|
React.useEffect(() => {
|
|
138
141
|
liveImageItem.setMode = setModeDebounced;
|
|
139
142
|
}, [setModeDebounced, liveImageItem]);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@applicaster/zapp-react-native-ui-components",
|
|
3
|
-
"version": "16.0.0-alpha.
|
|
3
|
+
"version": "16.0.0-alpha.4115436491",
|
|
4
4
|
"description": "Applicaster Zapp React Native ui components for the Quick Brick App",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"types": "index.d.ts",
|
|
@@ -28,10 +28,10 @@
|
|
|
28
28
|
},
|
|
29
29
|
"homepage": "https://github.com/applicaster/quickbrick#readme",
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@applicaster/applicaster-types": "16.0.0-alpha.
|
|
32
|
-
"@applicaster/zapp-react-native-bridge": "16.0.0-alpha.
|
|
33
|
-
"@applicaster/zapp-react-native-redux": "16.0.0-alpha.
|
|
34
|
-
"@applicaster/zapp-react-native-utils": "16.0.0-alpha.
|
|
31
|
+
"@applicaster/applicaster-types": "16.0.0-alpha.4115436491",
|
|
32
|
+
"@applicaster/zapp-react-native-bridge": "16.0.0-alpha.4115436491",
|
|
33
|
+
"@applicaster/zapp-react-native-redux": "16.0.0-alpha.4115436491",
|
|
34
|
+
"@applicaster/zapp-react-native-utils": "16.0.0-alpha.4115436491",
|
|
35
35
|
"fast-json-stable-stringify": "^2.1.0",
|
|
36
36
|
"promise": "^8.3.0",
|
|
37
37
|
"url": "^0.11.0",
|