@gravity-ui/page-constructor 5.14.1 → 5.14.2

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.
@@ -130,6 +130,7 @@ exports.ReactPlayerBlock = react_1.default.forwardRef((props, originRef) => {
130
130
  const changeMute = (0, react_1.useCallback)((isMuted) => {
131
131
  if (isMuted &&
132
132
  playerRef &&
133
+ controls === models_1.MediaVideoControlsType.Custom &&
133
134
  customControlsType === models_1.CustomControlsType.WithMuteButton) {
134
135
  playerRef.seekTo(0);
135
136
  setPlayedPercent(0);
@@ -141,7 +142,15 @@ exports.ReactPlayerBlock = react_1.default.forwardRef((props, originRef) => {
141
142
  }
142
143
  // In order to the progress bar to update (equals 0) before displaying
143
144
  setTimeout(() => setMuted(!isMuted), 0);
144
- }, [playerRef, customControlsType, playEvents, stopEvents, handleAnalytics, setProps]);
145
+ }, [
146
+ playerRef,
147
+ customControlsType,
148
+ playEvents,
149
+ stopEvents,
150
+ handleAnalytics,
151
+ setProps,
152
+ controls,
153
+ ]);
145
154
  const handleClickPreview = (0, react_1.useCallback)(() => {
146
155
  setIsPlaying(true);
147
156
  onClickPreview === null || onClickPreview === void 0 ? void 0 : onClickPreview();
@@ -127,6 +127,7 @@ export const ReactPlayerBlock = React.forwardRef((props, originRef) => {
127
127
  const changeMute = useCallback((isMuted) => {
128
128
  if (isMuted &&
129
129
  playerRef &&
130
+ controls === MediaVideoControlsType.Custom &&
130
131
  customControlsType === CustomControlsType.WithMuteButton) {
131
132
  playerRef.seekTo(0);
132
133
  setPlayedPercent(0);
@@ -138,7 +139,15 @@ export const ReactPlayerBlock = React.forwardRef((props, originRef) => {
138
139
  }
139
140
  // In order to the progress bar to update (equals 0) before displaying
140
141
  setTimeout(() => setMuted(!isMuted), 0);
141
- }, [playerRef, customControlsType, playEvents, stopEvents, handleAnalytics, setProps]);
142
+ }, [
143
+ playerRef,
144
+ customControlsType,
145
+ playEvents,
146
+ stopEvents,
147
+ handleAnalytics,
148
+ setProps,
149
+ controls,
150
+ ]);
142
151
  const handleClickPreview = useCallback(() => {
143
152
  setIsPlaying(true);
144
153
  onClickPreview === null || onClickPreview === void 0 ? void 0 : onClickPreview();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gravity-ui/page-constructor",
3
- "version": "5.14.1",
3
+ "version": "5.14.2",
4
4
  "description": "Gravity UI Page Constructor",
5
5
  "license": "MIT",
6
6
  "repository": {