Skip to content

Commit

Permalink
feat: Use MoreMenu in the standard Viewer
Browse files Browse the repository at this point in the history
  • Loading branch information
JF-Cozy committed Jan 27, 2025
1 parent b519e7f commit 9b65bdf
Showing 1 changed file with 5 additions and 7 deletions.
12 changes: 5 additions & 7 deletions src/modules/viewer/FilesViewer.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ import {
} from 'lib/encryption'
import logger from 'lib/logger'
import Fallback from 'modules/viewer/Fallback'
import MoreMenu from 'modules/viewer/MoreMenu'
import {
isOfficeEnabled,
makeOnlyOfficeFileRoute
Expand All @@ -36,12 +37,11 @@ import {
* fetchMore() on the query
*/
const FilesViewer = ({ filesQuery, files, onClose, onChange }) => {
const { isDesktop } = useBreakpoints()
const fileId = useCurrentFileId()
const [currentFile, setCurrentFile] = useState(null)
const [currentDecryptedFileURL, setCurrentDecryptedFileURL] = useState(null)
const [fetchingMore, setFetchingMore] = useState(false)

const { isDesktop } = useBreakpoints()
const fileId = useCurrentFileId()
const client = useClient()
const { t } = useI18n()
const vaultClient = useVaultClient()
Expand Down Expand Up @@ -178,13 +178,11 @@ const FilesViewer = ({ filesQuery, files, onClose, onChange }) => {
isEnabled: isOfficeEnabled(isDesktop),
opener: file => navigate(makeOnlyOfficeFileRoute(file.id))
},
toolbarProps: {
showFilePath: true
}
toolbarProps: { showFilePath: true }
}}
>
<ToolbarButtons>
<SharingButton variant="iconButton" />
<MoreMenu />
</ToolbarButtons>
<FooterActionButtons>
<SharingButton />
Expand Down

0 comments on commit 9b65bdf

Please sign in to comment.