Merge branch 'develop' into feature/create-room-selector
This commit is contained in:
commit
539a0aa1cd
@ -30,6 +30,7 @@ import styled, { css } from "styled-components";
|
|||||||
import { useLocation } from "react-router-dom";
|
import { useLocation } from "react-router-dom";
|
||||||
|
|
||||||
import { mobile } from "@docspace/shared/utils";
|
import { mobile } from "@docspace/shared/utils";
|
||||||
|
import { isPublicPreview } from "@docspace/shared/utils/common";
|
||||||
import Bar from "./Bar";
|
import Bar from "./Bar";
|
||||||
|
|
||||||
const StyledContainer = styled.div`
|
const StyledContainer = styled.div`
|
||||||
@ -75,7 +76,8 @@ const MainBar = ({
|
|||||||
!isNotPaidPeriod &&
|
!isNotPaidPeriod &&
|
||||||
!pathname.includes("error") &&
|
!pathname.includes("error") &&
|
||||||
!pathname.includes("confirm") &&
|
!pathname.includes("confirm") &&
|
||||||
!pathname.includes("preparation-portal");
|
!pathname.includes("preparation-portal") &&
|
||||||
|
!isPublicPreview();
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<StyledContainer id={"main-bar"} className={"main-bar"}>
|
<StyledContainer id={"main-bar"} className={"main-bar"}>
|
||||||
|
@ -59,12 +59,12 @@ const MediaViewer = (props: MediaViewerProps): JSX.Element | undefined => {
|
|||||||
playlistPos,
|
playlistPos,
|
||||||
currentFileId,
|
currentFileId,
|
||||||
isPreviewFile,
|
isPreviewFile,
|
||||||
setBufferSelection,
|
|
||||||
extsImagePreviewed,
|
extsImagePreviewed,
|
||||||
deleteDialogVisible,
|
deleteDialogVisible,
|
||||||
pluginContextMenuItems,
|
pluginContextMenuItems,
|
||||||
currentDeviceType,
|
currentDeviceType,
|
||||||
isPublicFile,
|
isPublicFile = false,
|
||||||
|
|
||||||
t,
|
t,
|
||||||
getIcon,
|
getIcon,
|
||||||
onClose,
|
onClose,
|
||||||
@ -74,6 +74,7 @@ const MediaViewer = (props: MediaViewerProps): JSX.Element | undefined => {
|
|||||||
onDownload,
|
onDownload,
|
||||||
onChangeUrl,
|
onChangeUrl,
|
||||||
setActiveFiles,
|
setActiveFiles,
|
||||||
|
setBufferSelection,
|
||||||
onEmptyPlaylistError,
|
onEmptyPlaylistError,
|
||||||
|
|
||||||
...other
|
...other
|
||||||
@ -132,7 +133,7 @@ const MediaViewer = (props: MediaViewerProps): JSX.Element | undefined => {
|
|||||||
t,
|
t,
|
||||||
targetFile,
|
targetFile,
|
||||||
archiveRoom,
|
archiveRoom,
|
||||||
Boolean(isPublicFile),
|
isPublicFile,
|
||||||
{
|
{
|
||||||
onClickDownload,
|
onClickDownload,
|
||||||
onClickRename,
|
onClickRename,
|
||||||
@ -140,11 +141,7 @@ const MediaViewer = (props: MediaViewerProps): JSX.Element | undefined => {
|
|||||||
},
|
},
|
||||||
);
|
);
|
||||||
|
|
||||||
const model = getMobileMediaContextModel(
|
const model = getMobileMediaContextModel(t, targetFile, isPublicFile, {
|
||||||
t,
|
|
||||||
targetFile,
|
|
||||||
Boolean(isPublicFile),
|
|
||||||
{
|
|
||||||
onShowInfoPanel,
|
onShowInfoPanel,
|
||||||
onClickDownload,
|
onClickDownload,
|
||||||
onMoveAction,
|
onMoveAction,
|
||||||
@ -152,8 +149,7 @@ const MediaViewer = (props: MediaViewerProps): JSX.Element | undefined => {
|
|||||||
onDuplicate,
|
onDuplicate,
|
||||||
onClickRename,
|
onClickRename,
|
||||||
onClickDelete,
|
onClickDelete,
|
||||||
},
|
});
|
||||||
);
|
|
||||||
|
|
||||||
if (isPdf)
|
if (isPdf)
|
||||||
return getPDFContextModel(t, targetFile, {
|
return getPDFContextModel(t, targetFile, {
|
||||||
|
@ -251,7 +251,7 @@ export const Viewer = (props: ViewerProps) => {
|
|||||||
|
|
||||||
{isImage ? (
|
{isImage ? (
|
||||||
<ImageViewer
|
<ImageViewer
|
||||||
key={fileUrl}
|
key={targetFile?.viewUrl}
|
||||||
isTiff={isTiff}
|
isTiff={isTiff}
|
||||||
devices={devices}
|
devices={devices}
|
||||||
toolbar={toolbar}
|
toolbar={toolbar}
|
||||||
|
Loading…
Reference in New Issue
Block a user