11import React from 'react'
22import PropTypes from 'prop-types'
33import cx from 'classnames'
4- import flow from 'lodash/flow'
54
65import { useClient } from 'cozy-client'
76
@@ -12,15 +11,15 @@ import Icon from '../../Icon'
1211import Typography from '../../Typography'
1312import PreviousIcon from '../../Icons/Previous'
1413import DownloadIcon from '../../Icons/Download'
14+ import { useI18n } from '../../providers/I18n'
15+ import MidEllipsis from '../../MidEllipsis'
1516
16- import { withViewerLocales } from '../hoc/withViewerLocales'
1717import { downloadFile } from '../helpers'
1818import { useEncrypted } from '../providers/EncryptedProvider'
1919import { ToolbarFilePath } from './ToolbarFilePath'
2020import { extractChildrenCompByName } from '../Footer/helpers'
2121
2222import styles from './styles.styl'
23- import MidEllipsis from '../../MidEllipsis'
2423
2524const useClasses = makeStyles ( theme => ( {
2625 iconButton : {
@@ -36,14 +35,14 @@ const Toolbar = ({
3635 onMouseLeave,
3736 file,
3837 onClose,
39- t,
4038 toolbarRef,
4139 breakpoints : { isDesktop } ,
4240 children,
4341 showFilePath
4442} ) => {
4543 const client = useClient ( )
4644 const classes = useClasses ( )
45+ const { t } = useI18n ( )
4746
4847 const { url } = useEncrypted ( )
4948
@@ -109,7 +108,4 @@ Toolbar.propTypes = {
109108 showFilePath : PropTypes . bool
110109}
111110
112- export default flow (
113- withBreakpoints ( ) ,
114- withViewerLocales
115- ) ( Toolbar )
111+ export default withBreakpoints ( ) ( Toolbar )
0 commit comments