Web:Common:Сhanged history.pushState method to history.push.

This commit is contained in:
Vlada Gazizova 2022-01-19 12:27:41 +03:00
parent fde1f1c015
commit 5dbe35f4d1

View File

@ -14,6 +14,7 @@ import Hammer from "hammerjs";
import IconButton from "@appserver/components/icon-button";
import commonIconsStyles from "@appserver/components/utils/common-icons-style";
import { isDesktop } from "react-device-detect";
import history from "@appserver/common/history";
const StyledVideoViewer = styled(VideoViewer)`
z-index: 301;
@ -310,9 +311,10 @@ class MediaViewer extends React.Component {
});
const id = playlist[currentPlaylistPos].fileId;
const url = "#preview/" + id;
const url = "/products/files/#preview/" + id;
window.history.pushState(null, null, url);
//window.history.pushState(null, null, url);
history.push(url);
};
nextMedia = () => {
@ -326,9 +328,10 @@ class MediaViewer extends React.Component {
});
const id = playlist[currentPlaylistPos].fileId;
const url = "#preview/" + id;
const url = "/products/files/#preview/" + id;
window.history.pushState(null, null, url);
history.push(url);
//window.history.pushState(null, null, url);
};
getOffset = () => {