TagSpaces is an offline, open source, document manager with tagging support
Tsn366 refactor grid perspective (#1056)
mladensapdb5f94d943cf
diff --git a/.vscode/settings.json b/.vscode/settings.jsonindex a92e99c13..11fa51a1c 100644--- a/.vscode/settings.json+++ b/.vscode/settings.json@@ -2,7 +2,7 @@"flow.pathToFlow": "node_modules/.bin/flow","javascript.validate.enable": false,"git.autofetch": true,- "editor.minimap.enabled": false,+ "editor.minimap.enabled": true,"git.confirmSync": false,"cSpell.userWords": ["customizability", "mapique", "tagspaces", "treeviz"],"typescript.format.enable": false,diff --git a/app/perspectives/grid-perspective/components/CellContent.js b/app/perspectives/grid-perspective/components/CellContent.jsindex 8cdac8f9a..8c7b8b756 100644--- a/app/perspectives/grid-perspective/components/CellContent.js+++ b/app/perspectives/grid-perspective/components/CellContent.js@@ -18,7 +18,6 @@*/import React from 'react';-import uuidv1 from 'uuid';import formatDistance from 'date-fns/formatDistance';import removeMd from 'remove-markdown';import classNames from 'classnames';@@ -36,7 +35,6 @@ import {} from '../../../services/utils-io';import TagContainerDnd from '../../../components/TagContainerDnd';import TagContainer from '../../../components/TagContainer';-import AppConfig from '../../../config';import i18n from '../../../services/i18n';import { type Tag } from '../../../reducers/taglibrary';@@ -57,9 +55,9 @@ type Props = {showTags: boolean,handleTagMenu: (event: Object, tag: Tag, entryPath: string) => void,layoutType: string,- handleGridContextMenu: () => void,- handleGridCellDblClick: () => void,- handleGridCellClick: () => void+ handleGridContextMenu: (event: Object, fsEntry: FileSystemEntry) => void,+ handleGridCellDblClick: (event: Object, fsEntry: FileSystemEntry) => void,+ handleGridCellClick: (event: Object, fsEntry: FileSystemEntry) => void};const CellContent = (props: Props) => {diff --git a/app/perspectives/grid-perspective/components/GridOptionsMenu.js b/app/perspectives/grid-perspective/components/GridOptionsMenu.jsnew file mode 100644index 000000000..9c839b826--- /dev/null+++ b/app/perspectives/grid-perspective/components/GridOptionsMenu.js@@ -0,0 +1,214 @@+/**+ * TagSpaces - universal file and folder organizer+ * Copyright (C) 2017-present TagSpaces UG (haftungsbeschraenkt)+ *+ * This program is free software: you can redistribute it and/or modify+ * it under the terms of the GNU Affero General Public License (version 3) as+ * published by the Free Software Foundation.+ *+ * This program is distributed in the hope that it will be useful,+ * but WITHOUT ANY WARRANTY; without even the implied warranty of+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the+ * GNU Affero General Public License for more details.+ *+ * You should have received a copy of the GNU Affero General Public License+ * along with this program. If not, see <https://www.gnu.org/licenses/>.+ *+ * @flow+ */++import React from 'react';+import ListItemText from '@material-ui/core/ListItemText';+import ListItemIcon from '@material-ui/core/ListItemIcon';+import Menu from '@material-ui/core/Menu';+import MenuItem from '@material-ui/core/MenuItem';+import CheckBoxIcon from '@material-ui/icons/CheckBox';+import CheckBoxEmptyIcon from '@material-ui/icons/CheckBoxOutlineBlank';+import Divider from '@material-ui/core/Divider';+import ThumbnailCoverIcon from '@material-ui/icons/PhotoSizeSelectActual';+import ThumbnailContainIcon from '@material-ui/icons/PhotoSizeSelectLarge';+import RadioCheckedIcon from '@material-ui/icons/RadioButtonChecked';+import RadioUncheckedIcon from '@material-ui/icons/RadioButtonUnchecked';+import HelpIcon from '@material-ui/icons/Help';+import i18n from '../../../services/i18n';++type Props = {+ open: boolean,+ onClose: () => void,+ anchorEl: Object | null,+ toggleShowDirectories: boolean,+ toggleShowTags: boolean,+ showDirectories: boolean,+ showTags: boolean,+ toggleThumbnailsMode: boolean,+ thumbnailMode: string,+ singleClickAction: string,+ entrySize: string,+ changeEntrySize: (entrySize: string) => void,+ changeSingleClickAction: (actionType: string) => void,+ openHelpWebPage: () => void+};++const GridOptionsMenu = (props: Props) => {+ const {+ open,+ onClose,+ anchorEl,+ changeEntrySize,+ toggleShowDirectories,+ showDirectories,+ toggleShowTags,+ showTags,+ toggleThumbnailsMode,+ thumbnailMode,+ changeSingleClickAction,+ entrySize,+ singleClickAction,+ openHelpWebPage+ } = props;++ return (+ <Menu anchorEl={anchorEl} open={open} onClose={onClose}>+ <MenuItem+ data-tid="gridPerspectiveToggleShowDirectories"+ title={i18n.t('core:showHideDirectories')}+ aria-label={i18n.t('core:showHideDirectories')}+ onClick={toggleShowDirectories}+ >+ <ListItemIcon>+ {showDirectories ? <CheckBoxIcon /> : <CheckBoxEmptyIcon />}+ </ListItemIcon>+ <ListItemText primary={i18n.t('core:showHideDirectories')} />+ </MenuItem>+ <MenuItem+ data-tid="gridPerspectiveToggleShowTags"+ title={i18n.t('core:showTags')}+ aria-label={i18n.t('core:showTags')}+ onClick={toggleShowTags}+ >+ <ListItemIcon>+ {showTags ? <CheckBoxIcon /> : <CheckBoxEmptyIcon />}+ </ListItemIcon>+ <ListItemText primary={i18n.t('core:showTags')} />+ </MenuItem>+ <Divider />+ <MenuItem+ data-tid="gridPerspectiveToggleThumbnailsMode"+ title={i18n.t('core:toggleThumbnailModeTitle')}+ aria-label={i18n.t('core:toggleThumbnailMode')}+ onClick={toggleThumbnailsMode}+ >+ <ListItemIcon>+ {thumbnailMode === 'cover' ? (+ <ThumbnailCoverIcon />+ ) : (+ <ThumbnailContainIcon />+ )}+ </ListItemIcon>+ <ListItemText primary={i18n.t('core:toggleThumbnailMode')} />+ </MenuItem>+ <Divider />+ <MenuItem+ data-tid="gridPerspectiveEntrySizeSmall"+ title={i18n.t('core:entrySizeSmall')}+ aria-label={i18n.t('core:entrySizeSmall')}+ onClick={() => changeEntrySize('small')}+ >+ <ListItemIcon>+ {entrySize === 'small' ? (+ <RadioCheckedIcon />+ ) : (+ <RadioUncheckedIcon />+ )}+ </ListItemIcon>+ <ListItemText primary={i18n.t('core:entrySizeSmall')} />+ </MenuItem>+ <MenuItem+ data-tid="gridPerspectiveEntrySizeNormal"+ title={i18n.t('core:entrySizeNormal')}+ aria-label={i18n.t('core:entrySizeNormal')}+ onClick={() => changeEntrySize('normal')}+ >+ <ListItemIcon>+ {entrySize === 'normal' ? (+ <RadioCheckedIcon />+ ) : (+ <RadioUncheckedIcon />+ )}+ </ListItemIcon>+ <ListItemText primary={i18n.t('core:entrySizeNormal')} />+ </MenuItem>+ <MenuItem+ data-tid="gridPerspectiveEntrySizeBig"+ title={i18n.t('core:entrySizeBig')}+ aria-label={i18n.t('core:entrySizeBig')}+ onClick={() => changeEntrySize('big')}+ >+ <ListItemIcon>+ {entrySize === 'big' ? <RadioCheckedIcon /> : <RadioUncheckedIcon />}+ </ListItemIcon>+ <ListItemText primary={i18n.t('core:entrySizeBig')} />+ </MenuItem>+ <Divider />+ <MenuItem+ data-tid="gridPerspectiveSingleClickOpenInternally"+ title={i18n.t('core:singleClickOpenInternally')}+ aria-label={i18n.t('core:singleClickOpenInternally')}+ onClick={() => changeSingleClickAction('openInternal')}+ >+ <ListItemIcon>+ {singleClickAction === 'openInternal' ? (+ <RadioCheckedIcon />+ ) : (+ <RadioUncheckedIcon />+ )}+ </ListItemIcon>+ <ListItemText primary={i18n.t('core:singleClickOpenInternally')} />+ </MenuItem>+ <MenuItem+ data-tid="gridPerspectiveSingleClickOpenExternally"+ title={i18n.t('core:singleClickOpenExternally')}+ aria-label={i18n.t('core:singleClickOpenExternally')}+ onClick={() => changeSingleClickAction('openExternal')}+ >+ <ListItemIcon>+ {singleClickAction === 'openExternal' ? (+ <RadioCheckedIcon />+ ) : (+ <RadioUncheckedIcon />+ )}+ </ListItemIcon>+ <ListItemText primary={i18n.t('core:singleClickOpenExternally')} />+ </MenuItem>+ <MenuItem+ data-tid="gridPerspectiveSingleClickSelects"+ title={i18n.t('core:singleClickSelects')}+ aria-label={i18n.t('core:singleClickSelects')}+ onClick={() => changeSingleClickAction('selects')}+ >+ <ListItemIcon>+ {singleClickAction === 'selects' ? (+ <RadioCheckedIcon />+ ) : (+ <RadioUncheckedIcon />+ )}+ </ListItemIcon>+ <ListItemText primary={i18n.t('core:singleClickSelects')} />+ </MenuItem>+ <Divider />+ <MenuItem+ data-tid="gridPerspectiveHelp"+ title={i18n.t('core:help')}+ aria-label={i18n.t('core:perspectiveHelp')}+ onClick={openHelpWebPage}+ >+ <ListItemIcon>+ <HelpIcon />+ </ListItemIcon>+ <ListItemText primary={i18n.t('core:help')} />+ </MenuItem>+ </Menu>+ );+};++export default GridOptionsMenu;diff --git a/app/perspectives/grid-perspective/components/MainContainer.js b/app/perspectives/grid-perspective/components/MainContainer.jsindex 3d2f096a2..e10547318 100644--- a/app/perspectives/grid-perspective/components/MainContainer.js+++ b/app/perspectives/grid-perspective/components/MainContainer.js@@ -25,33 +25,8 @@ import memoize from 'memoize-one';import { GlobalHotKeys } from 'react-hotkeys';import { withStyles } from '@material-ui/core/styles';import Typography from '@material-ui/core/Typography';-import Toolbar from '@material-ui/core/Toolbar';-import MoreVertIcon from '@material-ui/icons/MoreVert';-import RadioCheckedIcon from '@material-ui/icons/RadioButtonChecked';-import RadioUncheckedIcon from '@material-ui/icons/RadioButtonUnchecked';-import ListItemIcon from '@material-ui/core/ListItemIcon';-import ListItemText from '@material-ui/core/ListItemText';-import ViewListIcon from '@material-ui/icons/ViewList';-import SwapVertIcon from '@material-ui/icons/SwapVert';-import ViewGridIcon from '@material-ui/icons/ViewModule';-import ArrowUpIcon from '@material-ui/icons/KeyboardArrowUp';-import ArrowDownIcon from '@material-ui/icons/KeyboardArrowDown';-import IconButton from '@material-ui/core/IconButton';-import Menu from '@material-ui/core/Menu';-import MenuItem from '@material-ui/core/MenuItem';-import Divider from '@material-ui/core/Divider';-import ThumbnailCoverIcon from '@material-ui/icons/PhotoSizeSelectActual';-import ThumbnailContainIcon from '@material-ui/icons/PhotoSizeSelectLarge';import FolderIcon from '@material-ui/icons/FolderOpen';import FolderHiddenIcon from '@material-ui/icons/Folder';-import TagIcon from '@material-ui/icons/LocalOffer';-import CheckBoxIcon from '@material-ui/icons/CheckBox';-import CheckBoxEmptyIcon from '@material-ui/icons/CheckBoxOutlineBlank';-import CopyIcon from '@material-ui/icons/FileCopy';-import DeleteIcon from '@material-ui/icons/Delete';-import SelectAllIcon from '@material-ui/icons/CheckBox';-import DeSelectAllIcon from '@material-ui/icons/CheckBoxOutlineBlank';-import HelpIcon from '@material-ui/icons/Help';import { type FileSystemEntry } from '../../../services/utils-io';import { type Tag } from '../../../reducers/taglibrary';import {@@ -85,6 +60,9 @@ import {} from '../../../reducers/app';import TaggingActions from '../../../reducers/tagging-actions';import CellContent from './CellContent';+import MainToolbar from './MainToolbar';+import SortingMenu from './SortingMenu';+import GridOptionsMenu from './GridOptionsMenu';const settings = JSON.parse(localStorage.getItem('tsPerspectiveGrid')); // loading settings@@ -754,6 +732,16 @@ class GridPerspective extends React.Component<Props, State> {directoryContent,currentDirectoryColor,selectedEntries,+ loadParentDirectoryContent,+ toggleSelectAllFiles,+ allFilesSelected,+ handleLayoutSwitch,+ openAddRemoveTagsDialog,+ fileOperationsEnabled,+ openMoveCopyFilesDialog,+ openDeleteFileDialog,+ handleSortingMenu,+ handleOptionsMenu,theme,desktopMode} = this.props;@@ -781,107 +769,22 @@ class GridPerspective extends React.Component<Props, State> {}`}</style>- <Toolbar- className={classes.topToolbar}- data-tid="perspectiveGridToolbar"- >- <IconButton- title={i18n.t('core:toggleSelectAllFiles')}- data-tid="gridPerspectiveSelectAllFiles"- onClick={this.toggleSelectAllFiles}- >- {this.state.allFilesSelected ? (- <SelectAllIcon />- ) : (- <DeSelectAllIcon />- )}- </IconButton>- {/* { desktopMode && (- <IconButton- title={i18n.t('core:navigateToParentDirectory')}- aria-label={i18n.t('core:navigateToParentDirectory')}- data-tid="gridPerspectiveOnBackButton"- onClick={this.props.loadParentDirectoryContent}- >- <ParentDirIcon />- </IconButton>- )} */}- {this.state.layoutType === 'row' ? (- <IconButton- title={i18n.t('core:switchToGridView')}- aria-label={i18n.t('core:switchToGridView')}- data-tid="gridPerspectiveSwitchLayoutToGrid"- onClick={() => {- this.handleLayoutSwitch('grid');- }}- >- <ViewGridIcon />- </IconButton>- ) : (- <IconButton- title={i18n.t('core:switchToListView')}- aria-label={i18n.t('core:switchToListView')}- data-tid="gridPerspectiveSwitchLayoutToRow"- onClick={() => {- this.handleLayoutSwitch('row');- }}- >- <ViewListIcon />- </IconButton>- )}- {!this.props.isReadOnlyMode && (- <IconButton- title={i18n.t('core:tagSelectedEntries')}- aria-label={i18n.t('core:tagSelectedEntries')}- data-tid="gridPerspectiveAddRemoveTags"- disabled={selectedEntries.length < 1}- onClick={this.openAddRemoveTagsDialog}- >- <TagIcon />- </IconButton>- )}- {!this.props.isReadOnlyMode && (- <IconButton- title={i18n.t('core:copyMoveSelectedEntries')}- aria-label={i18n.t('core:copyMoveSelectedEntries')}- data-tid="gridPerspectiveCopySelectedFiles"- disabled={!this.state.fileOperationsEnabled}- onClick={this.openMoveCopyFilesDialog}- >- <CopyIcon />- </IconButton>- )}- {!this.props.isReadOnlyMode && (- <IconButton- title={i18n.t('core:deleteSelectedEntries')}- aria-label={i18n.t('core:deleteSelectedEntries')}- data-tid="gridPerspectiveDeleteMultipleFiles"- disabled={!this.state.fileOperationsEnabled}- onClick={this.openDeleteFileDialog}- >- <DeleteIcon />- </IconButton>- )}- <IconButton- title={i18n.t('core:sort')}- aria-label={i18n.t('core:sort')}- data-tid="gridPerspectiveSortMenu"- onClick={e => {- this.handleSortingMenu(e);- }}- >- <SwapVertIcon />- </IconButton>- <IconButton- title={i18n.t('core:options')}- data-tid="gridPerspectiveOptionsMenu"- onClick={e => {- this.handleOptionsMenu(e);- }}- >- <MoreVertIcon />- </IconButton>- </Toolbar>+ <MainToolbar+ classes={classes}+ layoutType={this.state.layoutType}+ isReadOnlyMode={this.props.isReadOnlyMode}+ selectedEntries={this.props.selectedEntries}+ loadParentDirectoryContent={this.props.loadParentDirectoryContent}+ toggleSelectAllFiles={this.toggleSelectAllFiles}+ allFilesSelected={this.state.allFilesSelected}+ handleLayoutSwitch={this.handleLayoutSwitch}+ openAddRemoveTagsDialog={this.openAddRemoveTagsDialog}+ fileOperationsEnabled={this.state.fileOperationsEnabled}+ openMoveCopyFilesDialog={this.openMoveCopyFilesDialog}+ openDeleteFileDialog={this.openDeleteFileDialog}+ handleSortingMenu={this.handleSortingMenu}+ handleOptionsMenu={this.handleOptionsMenu}+ /><GlobalHotKeys keyMap={this.keyMap} handlers={this.keyBindingHandlers}><divstyle={{@@ -1016,236 +919,30 @@ class GridPerspective extends React.Component<Props, State> {editTagForEntry={this.props.editTagForEntry}isReadOnlyMode={this.props.isReadOnlyMode}/>- <Menu+ <SortingMenuopen={this.state.sortingContextMenuOpened}onClose={this.closeSortingMenu}anchorEl={this.state.sortingContextMenuAnchorEl}- >- {/* <ListSubHeader>Sort by</ListSubHeader> */}- <MenuItem- data-tid="gridPerspectiveSortByName"- onClick={() => {- this.handleSortBy('byName');- }}- >- <ListItemIcon style={{ minWidth: 25 }}>- {this.state.sortBy === 'byName' &&- (this.state.orderBy ? <ArrowUpIcon /> : <ArrowDownIcon />)}- </ListItemIcon>- <ListItemText primary={i18n.t('core:fileTitle')} />- </MenuItem>- <MenuItem- data-tid="gridPerspectiveSortBySize"- onClick={() => {- this.handleSortBy('byFileSize');- }}- >- <ListItemIcon style={{ minWidth: 25 }}>- {this.state.sortBy === 'byFileSize' &&- (this.state.orderBy ? <ArrowUpIcon /> : <ArrowDownIcon />)}- </ListItemIcon>- <ListItemText primary={i18n.t('core:fileSize')} />- </MenuItem>- <MenuItem- data-tid="gridPerspectiveSortByDate"- onClick={() => {- this.handleSortBy('byDateModified');- }}- >- <ListItemIcon style={{ minWidth: 25 }}>- {this.state.sortBy === 'byDateModified' &&- (this.state.orderBy ? <ArrowUpIcon /> : <ArrowDownIcon />)}- </ListItemIcon>- <ListItemText primary={i18n.t('core:fileLDTM')} />- </MenuItem>- <MenuItem- data-tid="gridPerspectiveSortByFirstTag"- onClick={() => {- this.handleSortBy('byFirstTag');- }}- >- <ListItemIcon style={{ minWidth: 25 }}>- {this.state.sortBy === 'byFirstTag' &&- (this.state.orderBy ? <ArrowUpIcon /> : <ArrowDownIcon />)}- </ListItemIcon>- <ListItemText primary={i18n.t('core:fileFirstTag')} />- </MenuItem>- <MenuItem- data-tid="gridPerspectiveSortByExt"- onClick={() => {- this.handleSortBy('byExtension');- }}- >- <ListItemIcon style={{ minWidth: 25 }}>- {this.state.sortBy === 'byExtension' &&- (this.state.orderBy ? <ArrowUpIcon /> : <ArrowDownIcon />)}- </ListItemIcon>- <ListItemText primary={i18n.t('core:fileExtension')} />- </MenuItem>- <MenuItem- data-tid="gridPerspectiveSortRandom"- onClick={() => {- this.handleSortBy('random');- }}- >- <ListItemIcon style={{ minWidth: 25 }}>- {this.state.sortBy === 'random' && <ArrowDownIcon />}- </ListItemIcon>- <ListItemText primary={i18n.t('core:random')} />- </MenuItem>- </Menu>- <Menu+ sortBy={this.state.sortBy}+ orderBy={this.state.orderBy}+ handleSortBy={this.handleSortBy}+ />+ <GridOptionsMenuopen={this.state.optionsContextMenuOpened}onClose={this.closeOptionsMenu}anchorEl={this.state.optionsContextMenuAnchorEl}- >- <MenuItem- data-tid="gridPerspectiveToggleShowDirectories"- title={i18n.t('core:showHideDirectories')}- aria-label={i18n.t('core:showHideDirectories')}- onClick={this.toggleShowDirectories}- >- <ListItemIcon>- {this.state.showDirectories ? (- <CheckBoxIcon />- ) : (- <CheckBoxEmptyIcon />- )}- </ListItemIcon>- <ListItemText primary={i18n.t('core:showHideDirectories')} />- </MenuItem>- <MenuItem- data-tid="gridPerspectiveToggleShowTags"- title={i18n.t('core:showTags')}- aria-label={i18n.t('core:showTags')}- onClick={this.toggleShowTags}- >- <ListItemIcon>- {this.state.showTags ? <CheckBoxIcon /> : <CheckBoxEmptyIcon />}- </ListItemIcon>- <ListItemText primary={i18n.t('core:showTags')} />- </MenuItem>- <Divider />- <MenuItem- data-tid="gridPerspectiveToggleThumbnailsMode"- title={i18n.t('core:toggleThumbnailModeTitle')}- aria-label={i18n.t('core:toggleThumbnailMode')}- onClick={this.toggleThumbnailsMode}- >- <ListItemIcon>- {this.state.thumbnailMode === 'cover' ? (- <ThumbnailCoverIcon />- ) : (- <ThumbnailContainIcon />- )}- </ListItemIcon>- <ListItemText primary={i18n.t('core:toggleThumbnailMode')} />- </MenuItem>- <Divider />- <MenuItem- data-tid="gridPerspectiveEntrySizeSmall"- title={i18n.t('core:entrySizeSmall')}- aria-label={i18n.t('core:entrySizeSmall')}- onClick={() => this.changeEntrySize('small')}- >- <ListItemIcon>- {this.state.entrySize === 'small' ? (- <RadioCheckedIcon />- ) : (- <RadioUncheckedIcon />- )}- </ListItemIcon>- <ListItemText primary={i18n.t('core:entrySizeSmall')} />- </MenuItem>- <MenuItem- data-tid="gridPerspectiveEntrySizeNormal"- title={i18n.t('core:entrySizeNormal')}- aria-label={i18n.t('core:entrySizeNormal')}- onClick={() => this.changeEntrySize('normal')}- >- <ListItemIcon>- {this.state.entrySize === 'normal' ? (- <RadioCheckedIcon />- ) : (- <RadioUncheckedIcon />- )}- </ListItemIcon>- <ListItemText primary={i18n.t('core:entrySizeNormal')} />- </MenuItem>- <MenuItem- data-tid="gridPerspectiveEntrySizeBig"- title={i18n.t('core:entrySizeBig')}- aria-label={i18n.t('core:entrySizeBig')}- onClick={() => this.changeEntrySize('big')}- >- <ListItemIcon>- {this.state.entrySize === 'big' ? (- <RadioCheckedIcon />- ) : (- <RadioUncheckedIcon />- )}- </ListItemIcon>- <ListItemText primary={i18n.t('core:entrySizeBig')} />- </MenuItem>- <Divider />- <MenuItem- data-tid="gridPerspectiveSingleClickOpenInternally"- title={i18n.t('core:singleClickOpenInternally')}- aria-label={i18n.t('core:singleClickOpenInternally')}- onClick={() => this.changeSingleClickAction('openInternal')}- >- <ListItemIcon>- {this.state.singleClickAction === 'openInternal' ? (- <RadioCheckedIcon />- ) : (- <RadioUncheckedIcon />- )}- </ListItemIcon>- <ListItemText primary={i18n.t('core:singleClickOpenInternally')} />- </MenuItem>- <MenuItem- data-tid="gridPerspectiveSingleClickOpenExternally"- title={i18n.t('core:singleClickOpenExternally')}- aria-label={i18n.t('core:singleClickOpenExternally')}- onClick={() => this.changeSingleClickAction('openExternal')}- >- <ListItemIcon>- {this.state.singleClickAction === 'openExternal' ? (- <RadioCheckedIcon />- ) : (- <RadioUncheckedIcon />- )}- </ListItemIcon>- <ListItemText primary={i18n.t('core:singleClickOpenExternally')} />- </MenuItem>- <MenuItem- data-tid="gridPerspectiveSingleClickSelects"- title={i18n.t('core:singleClickSelects')}- aria-label={i18n.t('core:singleClickSelects')}- onClick={() => this.changeSingleClickAction('selects')}- >- <ListItemIcon>- {this.state.singleClickAction === 'selects' ? (- <RadioCheckedIcon />- ) : (- <RadioUncheckedIcon />- )}- </ListItemIcon>- <ListItemText primary={i18n.t('core:singleClickSelects')} />- </MenuItem>- <Divider />- <MenuItem- data-tid="gridPerspectiveHelp"- title={i18n.t('core:help')}- aria-label={i18n.t('core:perspectiveHelp')}- onClick={this.openHelpWebPage}- >- <ListItemIcon>- <HelpIcon />- </ListItemIcon>- <ListItemText primary={i18n.t('core:help')} />- </MenuItem>- </Menu>+ toggleShowDirectories={this.toggleShowDirectories}+ showDirectories={this.state.showDirectories}+ toggleShowTags={this.toggleShowTags}+ showTags={this.state.showTags}+ toggleThumbnailsMode={this.toggleThumbnailsMode}+ thumbnailMode={this.state.thumbnailMode}+ entrySize={this.state.entrySize}+ changeSingleClickAction={this.changeSingleClickAction}+ singleClickAction={this.state.singleClickAction}+ changeEntrySize={this.changeEntrySize}+ openHelpWebPage={this.openHelpWebPage}+ /></div>);}diff --git a/app/perspectives/grid-perspective/components/MainToolbar.js b/app/perspectives/grid-perspective/components/MainToolbar.jsnew file mode 100644index 000000000..0f872b6ec--- /dev/null+++ b/app/perspectives/grid-perspective/components/MainToolbar.js@@ -0,0 +1,166 @@+/**+ * TagSpaces - universal file and folder organizer+ * Copyright (C) 2017-present TagSpaces UG (haftungsbeschraenkt)+ *+ * This program is free software: you can redistribute it and/or modify+ * it under the terms of the GNU Affero General Public License (version 3) as+ * published by the Free Software Foundation.+ *+ * This program is distributed in the hope that it will be useful,+ * but WITHOUT ANY WARRANTY; without even the implied warranty of+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the+ * GNU Affero General Public License for more details.+ *+ * You should have received a copy of the GNU Affero General Public License+ * along with this program. If not, see <https://www.gnu.org/licenses/>.+ *+ * @flow+ */++import React from 'react';+import Toolbar from '@material-ui/core/Toolbar';+import MoreVertIcon from '@material-ui/icons/MoreVert';+import IconButton from '@material-ui/core/IconButton';+import ParentDirIcon from '@material-ui/icons/SubdirectoryArrowLeft';+import ViewGridIcon from '@material-ui/icons/ViewModule';+import SwapVertIcon from '@material-ui/icons/SwapVert';+import ViewListIcon from '@material-ui/icons/ViewList';+import TagIcon from '@material-ui/icons/LocalOffer';+import SelectAllIcon from '@material-ui/icons/CheckBox';+import DeSelectAllIcon from '@material-ui/icons/CheckBoxOutlineBlank';+import CopyIcon from '@material-ui/icons/FileCopy';+import DeleteIcon from '@material-ui/icons/Delete';+import i18n from '../../../services/i18n';++type Props = {+ classes: Object,+ isReadOnlyMode: boolean,+ selectedEntries: Array<Object>,+ loadParentDirectoryContent: () => void,+ toggleSelectAllFiles: boolean,+ allFilesSelected: boolean,+ handleLayoutSwitch: (event: Object) => void,+ openAddRemoveTagsDialog: () => void,+ fileOperationsEnabled: boolean,+ openMoveCopyFilesDialog: () => void,+ openDeleteFileDialog: () => void,+ handleSortingMenu: (event: Object) => void,+ handleOptionsMenu: (event: Object) => void,+ layoutType: string+};++const MainToolbar = (props: Props) => {+ const {+ classes,+ selectedEntries,+ toggleSelectAllFiles,+ allFilesSelected,+ loadParentDirectoryContent,+ layoutType,+ handleLayoutSwitch,+ isReadOnlyMode,+ openAddRemoveTagsDialog,+ openMoveCopyFilesDialog,+ openDeleteFileDialog,+ fileOperationsEnabled,+ handleSortingMenu,+ handleOptionsMenu+ } = props;++ return (+ <Toolbar className={classes.topToolbar} data-tid="perspectiveGridToolbar">+ <IconButton+ title={i18n.t('core:toggleSelectAllFiles')}+ data-tid="gridPerspectiveSelectAllFiles"+ onClick={toggleSelectAllFiles}+ >+ {allFilesSelected ? <SelectAllIcon /> : <DeSelectAllIcon />}+ </IconButton>+ <IconButton+ title={i18n.t('core:navigateToParentDirectory')}+ aria-label={i18n.t('core:navigateToParentDirectory')}+ data-tid="gridPerspectiveOnBackButton"+ onClick={loadParentDirectoryContent}+ >+ <ParentDirIcon />+ </IconButton>+ {layoutType === 'row' ? (+ <IconButton+ title={i18n.t('core:switchToGridView')}+ aria-label={i18n.t('core:switchToGridView')}+ data-tid="gridPerspectiveSwitchLayoutToGrid"+ onClick={() => {+ handleLayoutSwitch('grid');+ }}+ >+ <ViewGridIcon />+ </IconButton>+ ) : (+ <IconButton+ title={i18n.t('core:switchToListView')}+ aria-label={i18n.t('core:switchToListView')}+ data-tid="gridPerspectiveSwitchLayoutToRow"+ onClick={() => {+ handleLayoutSwitch('row');+ }}+ >+ <ViewListIcon />+ </IconButton>+ )}+ {!isReadOnlyMode && (+ <IconButton+ title={i18n.t('core:tagSelectedEntries')}+ aria-label={i18n.t('core:tagSelectedEntries')}+ data-tid="gridPerspectiveAddRemoveTags"+ disabled={selectedEntries.length < 1}+ onClick={openAddRemoveTagsDialog}+ >+ <TagIcon />+ </IconButton>+ )}+ {!isReadOnlyMode && (+ <IconButton+ title={i18n.t('core:copyMoveSelectedEntries')}+ aria-label={i18n.t('core:copyMoveSelectedEntries')}+ data-tid="gridPerspectiveCopySelectedFiles"+ disabled={!fileOperationsEnabled}+ onClick={openMoveCopyFilesDialog}+ >+ <CopyIcon />+ </IconButton>+ )}+ {!isReadOnlyMode && (+ <IconButton+ title={i18n.t('core:deleteSelectedEntries')}+ aria-label={i18n.t('core:deleteSelectedEntries')}+ data-tid="gridPerspectiveDeleteMultipleFiles"+ disabled={!fileOperationsEnabled}+ onClick={openDeleteFileDialog}+ >+ <DeleteIcon />+ </IconButton>+ )}+ <IconButton+ title={i18n.t('core:sort')}+ aria-label={i18n.t('core:sort')}+ data-tid="gridPerspectiveSortMenu"+ onClick={e => {+ handleSortingMenu(e);+ }}+ >+ <SwapVertIcon />+ </IconButton>+ <IconButton+ title={i18n.t('core:options')}+ data-tid="gridPerspectiveOptionsMenu"+ onClick={e => {+ handleOptionsMenu(e);+ }}+ >+ <MoreVertIcon />+ </IconButton>+ </Toolbar>+ );+};++export default MainToolbar;diff --git a/app/perspectives/grid-perspective/components/SortingMenu.js b/app/perspectives/grid-perspective/components/SortingMenu.jsnew file mode 100644index 000000000..f70fb4932--- /dev/null+++ b/app/perspectives/grid-perspective/components/SortingMenu.js@@ -0,0 +1,119 @@+/**+ * TagSpaces - universal file and folder organizer+ * Copyright (C) 2017-present TagSpaces UG (haftungsbeschraenkt)+ *+ * This program is free software: you can redistribute it and/or modify+ * it under the terms of the GNU Affero General Public License (version 3) as+ * published by the Free Software Foundation.+ *+ * This program is distributed in the hope that it will be useful,+ * but WITHOUT ANY WARRANTY; without even the implied warranty of+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the+ * GNU Affero General Public License for more details.+ *+ * You should have received a copy of the GNU Affero General Public License+ * along with this program. If not, see <https://www.gnu.org/licenses/>.+ *+ * @flow+ */++import React from 'react';+import ListItemText from '@material-ui/core/ListItemText';+import ListItemIcon from '@material-ui/core/ListItemIcon';+import Menu from '@material-ui/core/Menu';+import MenuItem from '@material-ui/core/MenuItem';+import ArrowUpIcon from '@material-ui/icons/KeyboardArrowUp';+import ArrowDownIcon from '@material-ui/icons/KeyboardArrowDown';+import i18n from '../../../services/i18n';++type Props = {+ open: boolean,+ onClose: () => void,+ anchorEl: Object | null,+ handleSortBy: (sortType: string) => void,+ sortBy: string,+ orderBy: null | boolean+};++const SortingMenu = (props: Props) => {+ const { open, onClose, sortBy, orderBy, handleSortBy, anchorEl } = props;++ return (+ <Menu anchorEl={anchorEl} open={open} onClose={onClose}>+ {/* <ListSubHeader>Sort by</ListSubHeader> */}+ <MenuItem+ data-tid="gridPerspectiveSortByName"+ onClick={() => {+ handleSortBy('byName');+ }}+ >+ <ListItemIcon style={{ minWidth: 25 }}>+ {sortBy === 'byName' &&+ (orderBy ? <ArrowUpIcon /> : <ArrowDownIcon />)}+ </ListItemIcon>+ <ListItemText primary={i18n.t('core:fileTitle')} />+ </MenuItem>+ <MenuItem+ data-tid="gridPerspectiveSortBySize"+ onClick={() => {+ handleSortBy('byFileSize');+ }}+ >+ <ListItemIcon style={{ minWidth: 25 }}>+ {sortBy === 'byFileSize' &&+ (orderBy ? <ArrowUpIcon /> : <ArrowDownIcon />)}+ </ListItemIcon>+ <ListItemText primary={i18n.t('core:fileSize')} />+ </MenuItem>+ <MenuItem+ data-tid="gridPerspectiveSortByDate"+ onClick={() => {+ handleSortBy('byDateModified');+ }}+ >+ <ListItemIcon style={{ minWidth: 25 }}>+ {sortBy === 'byDateModified' &&+ (orderBy ? <ArrowUpIcon /> : <ArrowDownIcon />)}+ </ListItemIcon>+ <ListItemText primary={i18n.t('core:fileLDTM')} />+ </MenuItem>+ <MenuItem+ data-tid="gridPerspectiveSortByFirstTag"+ onClick={() => {+ handleSortBy('byFirstTag');+ }}+ >+ <ListItemIcon style={{ minWidth: 25 }}>+ {sortBy === 'byFirstTag' &&+ (orderBy ? <ArrowUpIcon /> : <ArrowDownIcon />)}+ </ListItemIcon>+ <ListItemText primary={i18n.t('core:fileFirstTag')} />+ </MenuItem>+ <MenuItem+ data-tid="gridPerspectiveSortByExt"+ onClick={() => {+ handleSortBy('byExtension');+ }}+ >+ <ListItemIcon style={{ minWidth: 25 }}>+ {sortBy === 'byExtension' &&+ (orderBy ? <ArrowUpIcon /> : <ArrowDownIcon />)}+ </ListItemIcon>+ <ListItemText primary={i18n.t('core:fileExtension')} />+ </MenuItem>+ <MenuItem+ data-tid="gridPerspectiveSortRandom"+ onClick={() => {+ handleSortBy('random');+ }}+ >+ <ListItemIcon style={{ minWidth: 25 }}>+ {sortBy === 'random' && <ArrowDownIcon />}+ </ListItemIcon>+ <ListItemText primary={i18n.t('core:random')} />+ </MenuItem>+ </Menu>+ );+};++export default SortingMenu;diff --git a/app/perspectives/grid-perspective/components/styles.css.js b/app/perspectives/grid-perspective/components/styles.css.jsindex 0a3c6e9a5..b096109b1 100644--- a/app/perspectives/grid-perspective/components/styles.css.js+++ b/app/perspectives/grid-perspective/components/styles.css.js@@ -18,7 +18,7 @@*/import AppConfig from '../../../config';-export default theme => ({+export default (theme: Object) => ({gridContainer: {display: 'grid',gridGap: '2px 2px',diff --git a/package.json b/package.jsonindex ba7c627ac..309f98755 100644--- a/package.json+++ b/package.json@@ -149,8 +149,8 @@"eslint-formatter-pretty": "^1.1.0","eslint-import-resolver-webpack": "^0.8.1","eslint-plugin-compat": "^1.0.3",- "eslint-plugin-flowtype": "^2.33.0",- "eslint-plugin-flowtype-errors": "^3.3.0",+ "eslint-plugin-flowtype": "^4.5.2",+ "eslint-plugin-flowtype-errors": "^4.1.0","eslint-plugin-import": "^2.3.0","eslint-plugin-jest": "^20.0.3","eslint-plugin-jsx-a11y": "^5.0.3",@@ -160,9 +160,9 @@"extract-text-webpack-plugin": "^v4.0.0-beta.0","fbjs-scripts": "^1.2.0","file-loader": "^3.0.1",- "flow-bin": "^0.109.0",+ "flow-bin": "^0.114.0","flow-runtime": "^0.17.0",- "flow-typed": "^2.6.1",+ "flow-typed": "^2.6.2","husky": "^1.3.1","identity-obj-proxy": "^3.0.0","jest": "^24.9.0",diff --git a/yarn.lock b/yarn.lockindex 2b3d34221..223c2fe0f 100644--- a/yarn.lock+++ b/yarn.lock@@ -1694,6 +1694,15 @@universal-user-agent "^3.0.0"url-template "^2.0.8"+"@octokit/endpoint@^5.5.0":+ version "5.5.1"+ resolved "https://registry.yarnpkg.com/@octokit/endpoint/-/endpoint-5.5.1.tgz#2eea81e110ca754ff2de11c79154ccab4ae16b3f"+ integrity sha512-nBFhRUb5YzVTCX/iAK1MgQ4uWo89Gu0TH00qQHoYRCsE12dWcG1OiLd7v2EIo2+tpUKPMOQ62QFy9hy9Vg2ULg==+ dependencies:+ "@octokit/types" "^2.0.0"+ is-plain-object "^3.0.0"+ universal-user-agent "^4.0.0"+"@octokit/plugin-enterprise-rest@^3.6.1":version "3.6.2"resolved "https://registry.yarnpkg.com/@octokit/plugin-enterprise-rest/-/plugin-enterprise-rest-3.6.2.tgz#74de25bef21e0182b4fa03a8678cd00a4e67e561"@@ -1720,20 +1729,19 @@once "^1.4.0"universal-user-agent "^3.0.0"-"@octokit/rest@^15.12.1":- version "15.18.2"- resolved "https://registry.yarnpkg.com/@octokit/rest/-/rest-15.18.2.tgz#3e4d448ce4630c8ac926e14819874175bc271669"- integrity sha512-cXP/hzh21PoZe0HJ74Co33HS3ITayWujXXeb1P8oR9kXt3hEmGsm2FQ4A8PrqV18C26uYkIb4KjjlVBzX1aHjw==+"@octokit/request@^5.2.0":+ version "5.3.1"+ resolved "https://registry.yarnpkg.com/@octokit/request/-/request-5.3.1.tgz#3a1ace45e6f88b1be4749c5da963b3a3b4a2f120"+ integrity sha512-5/X0AL1ZgoU32fAepTfEoggFinO3rxsMLtzhlUX+RctLrusn/CApJuGFCd0v7GMFhF+8UiCsTTfsu7Fh1HnEJg==dependencies:- before-after-hook "^1.1.0"- btoa-lite "^1.0.0"- debug "^3.1.0"- http-proxy-agent "^2.1.0"- https-proxy-agent "^2.2.0"- lodash "^4.17.4"- node-fetch "^2.1.1"- universal-user-agent "^2.0.0"- url-template "^2.0.8"+ "@octokit/endpoint" "^5.5.0"+ "@octokit/request-error" "^1.0.1"+ "@octokit/types" "^2.0.0"+ deprecation "^2.0.0"+ is-plain-object "^3.0.0"+ node-fetch "^2.3.0"+ once "^1.4.0"+ universal-user-agent "^4.0.0""@octokit/rest@^16.28.4":version "16.28.7"@@ -1754,6 +1762,31 @@universal-user-agent "^3.0.0"url-template "^2.0.8"+"@octokit/rest@^16.33.1":+ version "16.35.2"+ resolved "https://registry.yarnpkg.com/@octokit/rest/-/rest-16.35.2.tgz#0098c9e2a895d4afb0fa6578479283553543143c"+ integrity sha512-iijaNZpn9hBpUdh8YdXqNiWazmq4R1vCUsmxpBB0kCQ0asHZpCx+HNs22eiHuwYKRhO31ZSAGBJLi0c+3XHaKQ==+ dependencies:+ "@octokit/request" "^5.2.0"+ "@octokit/request-error" "^1.0.2"+ atob-lite "^2.0.0"+ before-after-hook "^2.0.0"+ btoa-lite "^1.0.0"+ deprecation "^2.0.0"+ lodash.get "^4.4.2"+ lodash.set "^4.3.2"+ lodash.uniq "^4.5.0"+ octokit-pagination-methods "^1.1.0"+ once "^1.4.0"+ universal-user-agent "^4.0.0"++"@octokit/types@^2.0.0":+ version "2.0.2"+ resolved "https://registry.yarnpkg.com/@octokit/types/-/types-2.0.2.tgz#0888497f5a664e28b0449731d5e88e19b2a74f90"+ integrity sha512-StASIL2lgT3TRjxv17z9pAqbnI7HGu9DrJlg3sEBFfCLaMEqp+O3IQPUF6EZtQ4xkAu2ml6kMBBCtGxjvmtmuQ==+ dependencies:+ "@types/node" ">= 8"+"@sindresorhus/is@^0.14.0":version "0.14.0"resolved "https://registry.yarnpkg.com/@sindresorhus/is/-/is-0.14.0.tgz#9fb3a3cf3132328151f353de4632e01e52102bea"@@ -1861,6 +1894,11 @@resolved "https://registry.yarnpkg.com/@types/node/-/node-12.7.2.tgz#c4e63af5e8823ce9cc3f0b34f7b998c2171f0c44"integrity sha512-dyYO+f6ihZEtNPDcWNR1fkoTDf3zAK3lAABDze3mz6POyIercH0lEUawUFXlG8xaQZmm1yEBON/4TsYv/laDYg==+"@types/node@>= 8":+ version "12.12.21"+ resolved "https://registry.yarnpkg.com/@types/node/-/node-12.12.21.tgz#aa44a6363291c7037111c47e4661ad210aded23f"+ integrity sha512-8sRGhbpU+ck1n0PGAUgVrWrWdjSW2aqNeyC15W88GRsMpSwzv6RJGlLhE7s2RhVSOdyDmxbqlWSeThq4/7xqlA==+"@types/node@^10.12.18":version "10.14.15"resolved "https://registry.yarnpkg.com/@types/node/-/node-10.14.15.tgz#e8f7729b631be1b02ae130ff0b61f3e018000640"@@ -4002,11 +4040,6 @@ bcrypt-pbkdf@^1.0.0:dependencies:tweetnacl "^0.14.3"-before-after-hook@^1.1.0:- version "1.4.0"- resolved "https://registry.yarnpkg.com/before-after-hook/-/before-after-hook-1.4.0.tgz#2b6bf23dca4f32e628fd2747c10a37c74a4b484d"- integrity sha512-l5r9ir56nda3qu14nAXIlyq1MmUSs0meCIaFAh8HwkFwP1F8eToOuS3ah2VAHHcY04jaYD7FpJC5JTXHYRbkzg==-before-after-hook@^2.0.0:version "2.1.0"resolved "https://registry.yarnpkg.com/before-after-hook/-/before-after-hook-2.1.0.tgz#b6c03487f44e24200dd30ca5e6a1979c5d2fb635"@@ -6819,20 +6852,21 @@ eslint-plugin-compat@^1.0.3:caniuse-db "1.0.30000671"requireindex "^1.1.0"-eslint-plugin-flowtype-errors@^3.3.0:- version "3.6.0"- resolved "https://registry.yarnpkg.com/eslint-plugin-flowtype-errors/-/eslint-plugin-flowtype-errors-3.6.0.tgz#5782994261e925aed1320630146636e88e4ad553"- integrity sha1-V4KZQmHpJa7RMgYwFGY26I5K1VM=+eslint-plugin-flowtype-errors@^4.1.0:+ version "4.1.0"+ resolved "https://registry.yarnpkg.com/eslint-plugin-flowtype-errors/-/eslint-plugin-flowtype-errors-4.1.0.tgz#6edb0837001f70001ceeb33f0541bd2b8eb8e6c8"+ integrity sha512-79Hy4ITWwXF7J8/N7jZG6PN6O+kL8oUCZgQaPf4eT8UvSI0x10WACEDzfxJgG1qW3/FN/lT6U1e7K/7fpIWPKw==dependencies:- babel-runtime "^6.26.0"+ "@babel/runtime" "^7.4.2"+ find-up "^3.0.0"slash "^2.0.0"-eslint-plugin-flowtype@^2.33.0:- version "2.50.3"- resolved "https://registry.yarnpkg.com/eslint-plugin-flowtype/-/eslint-plugin-flowtype-2.50.3.tgz#61379d6dce1d010370acd6681740fd913d68175f"- integrity sha512-X+AoKVOr7Re0ko/yEXyM5SSZ0tazc6ffdIOocp2fFUlWoDt7DV0Bz99mngOkAFLOAWjqRA5jPwqUCbrx13XoxQ==+eslint-plugin-flowtype@^4.5.2:+ version "4.5.2"+ resolved "https://registry.yarnpkg.com/eslint-plugin-flowtype/-/eslint-plugin-flowtype-4.5.2.tgz#5353449692663ef70e8fc8c2386cebdecac7e86b"+ integrity sha512-ByV0EtEQOqiCl6bsrtXtTGnXlIXoyvDrvUq3Nz28huODAhnRDuMotyTrwP+TjAKZMPWbtaNGFHMoUxW3DktGOw==dependencies:- lodash "^4.17.10"+ lodash "^4.17.15"eslint-plugin-import@^2.3.0:version "2.18.2"@@ -7540,10 +7574,10 @@ flatten@^1.0.2:resolved "https://registry.yarnpkg.com/flatten/-/flatten-1.0.2.tgz#dae46a9d78fbe25292258cc1e780a41d95c03782"integrity sha1-2uRqnXj74lKSJYzB54CkHZXAN4I=-flow-bin@^0.109.0:- version "0.109.0"- resolved "https://registry.yarnpkg.com/flow-bin/-/flow-bin-0.109.0.tgz#dcdcb7402dd85b58200392d8716ccf14e5a8c24c"- integrity sha512-tpcMTpAGIRivYhFV3KJq+zHI2HzcXo8MoGe9pXS4G/UZuey2Faq/e8/gdph2WF0erRlML5hmwfwiq7v9c25c7w==+flow-bin@^0.114.0:+ version "0.114.0"+ resolved "https://registry.yarnpkg.com/flow-bin/-/flow-bin-0.114.0.tgz#9079c5fcdf08fab4db91616f38994e9b7d035842"+ integrity sha512-hewufX0nbnhemQn5XtJ97nEFNqoBclPBAZ54aY3jKuZJnLpwqB7Doaplet3M26TOh2NchBsU0+lUkM8oVna2VA==flow-config-parser@^0.3.0:version "0.3.0"@@ -7555,13 +7589,13 @@ flow-runtime@^0.17.0:resolved "https://registry.yarnpkg.com/flow-runtime/-/flow-runtime-0.17.0.tgz#ff57dd22bd7b0682c7beff20c3590f6a4a8286e3"integrity sha512-x621HugMPrtU68ddiRX0TkNRif9PS6ml3oeP6oo0k+Kv2issqCmifC4ZX59XnLUh9dfmBcj4GoZJXu4oe8L28Q==-flow-typed@^2.6.1:- version "2.6.1"- resolved "https://registry.yarnpkg.com/flow-typed/-/flow-typed-2.6.1.tgz#e991f53840ad121d9e1f61bd8f8b844cfae57ab1"- integrity sha512-UXhkAHcv4t+sSsuGud35zkV5CVXkEfIbGee545/1WnajM0+na1IKhmccuawg/PVu1Jtc3i127JcuKV/CLhF0oQ==+flow-typed@^2.6.2:+ version "2.6.2"+ resolved "https://registry.yarnpkg.com/flow-typed/-/flow-typed-2.6.2.tgz#6d324a96c4df300e0f823c13ca879c824bef40ce"+ integrity sha512-brTh8SukLidVpR1u8hSR3OcZSvLtptpwLEGgEhK/qBhWCB7zxPZmnmChYi40JQH6vB448ck380+qbkDo3fJ6qA==dependencies:"@babel/polyfill" "^7.0.0"- "@octokit/rest" "^15.12.1"+ "@octokit/rest" "^16.33.1"colors "^1.3.2"flowgen "^1.9.0"fs-extra "^7.0.0"@@ -8652,7 +8686,7 @@ https-browserify@^1.0.0:resolved "https://registry.yarnpkg.com/https-browserify/-/https-browserify-1.0.0.tgz#ec06c10e0a34c0f2faf199f7fd7fc78fffd03c73"integrity sha1-7AbBDgo0wPL68Zn3/X/Hj//QPHM=-https-proxy-agent@^2.1.0, https-proxy-agent@^2.2.0, https-proxy-agent@^2.2.1:+https-proxy-agent@^2.1.0, https-proxy-agent@^2.2.1:version "2.2.2"resolved "https://registry.yarnpkg.com/https-proxy-agent/-/https-proxy-agent-2.2.2.tgz#271ea8e90f836ac9f119daccd39c19ff7dfb0793"integrity sha512-c8Ndjc9Bkpfx/vCJueCPy0jlP4ccCCSNDp8xwCZzPjKJUm+B+u9WX2x98Qx4n1PiMNTWo3D7KK5ifNV/yJyRzg==@@ -10784,7 +10818,7 @@ lodash.without@~4.4.0:resolved "https://registry.yarnpkg.com/lodash.without/-/lodash.without-4.4.0.tgz#3cd4574a00b67bae373a94b748772640507b7aac"integrity sha1-PNRXSgC2e643OpS3SHcmQFB7eqw=-lodash@^4.0.0, lodash@^4.0.1, lodash@^4.1.0, lodash@^4.17.10, lodash@^4.17.11, lodash@^4.17.13, lodash@^4.17.14, lodash@^4.17.15, lodash@^4.17.4, lodash@^4.17.5, lodash@^4.2.0, lodash@^4.2.1, lodash@^4.3.0, lodash@^4.8.0, lodash@~4.17.10:+lodash@^4.0.0, lodash@^4.0.1, lodash@^4.1.0, lodash@^4.17.11, lodash@^4.17.13, lodash@^4.17.14, lodash@^4.17.15, lodash@^4.17.4, lodash@^4.17.5, lodash@^4.2.0, lodash@^4.2.1, lodash@^4.3.0, lodash@^4.8.0, lodash@~4.17.10:version "4.17.15"resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.15.tgz#b447f6670a0455bbfeedd11392eff330ea097548"integrity sha512-8xOcRHvCjnocdS5cpwXQXVzmmh5e5+saE2QGoeQmbKmRS6J3VQppPOIt0MnmE+4xlZoumy0GPG0D0MVIQbNA1A==@@ -11530,7 +11564,7 @@ node-fetch@^1.0.1:encoding "^0.1.11"is-stream "^1.0.1"-node-fetch@^2.1.1, node-fetch@^2.3.0, node-fetch@^2.5.0:+node-fetch@^2.3.0, node-fetch@^2.5.0:version "2.6.0"resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.6.0.tgz#e633456386d4aa55863f676a7ab0daa8fdecb0fd"integrity sha512-8dG4H5ujfvFiqDmVu9fQ5bOHUC15JMjMY/Zumv26oOvvVJjM67KF8koCWIabKQ1GJIa9r2mMZscBq/TbdOcmNA==@@ -12298,7 +12332,7 @@ os-locale@^3.0.0, os-locale@^3.1.0:lcid "^2.0.0"mem "^4.0.0"-os-name@^3.0.0:+os-name@^3.0.0, os-name@^3.1.0:version "3.1.0"resolved "https://registry.yarnpkg.com/os-name/-/os-name-3.1.0.tgz#dec19d966296e1cd62d701a5a66ee1ddeae70801"integrity sha512-h8L+8aNjNcMpo/mAIBPn5PXCM16iyPGjHNWo6U1YO8sJTMHtEtyczI6QJnLoplswm6goopQkqc7OAnjhWcugVg==@@ -16604,13 +16638,6 @@ unique-string@^1.0.0:dependencies:crypto-random-string "^1.0.0"-universal-user-agent@^2.0.0:- version "2.1.0"- resolved "https://registry.yarnpkg.com/universal-user-agent/-/universal-user-agent-2.1.0.tgz#5abfbcc036a1ba490cb941f8fd68c46d3669e8e4"- integrity sha512-8itiX7G05Tu3mGDTdNY2fB4KJ8MgZLS54RdG6PkkfwMAavrXu1mV/lls/GABx9O3Rw4PnTtasxrvbMQoBYY92Q==- dependencies:- os-name "^3.0.0"-universal-user-agent@^3.0.0:version "3.0.0"resolved "https://registry.yarnpkg.com/universal-user-agent/-/universal-user-agent-3.0.0.tgz#4cc88d68097bffd7ac42e3b7c903e7481424b4b9"@@ -16618,6 +16645,13 @@ universal-user-agent@^3.0.0:dependencies:os-name "^3.0.0"+universal-user-agent@^4.0.0:+ version "4.0.0"+ resolved "https://registry.yarnpkg.com/universal-user-agent/-/universal-user-agent-4.0.0.tgz#27da2ec87e32769619f68a14996465ea1cb9df16"+ integrity sha512-eM8knLpev67iBDizr/YtqkJsF3GK8gzDc6st/WKzrTuPtcsOKW/0IdL4cnMBsU69pOx0otavLWBDGTwg+dB0aA==+ dependencies:+ os-name "^3.1.0"+universalify@^0.1.0:version "0.1.2"resolved "https://registry.yarnpkg.com/universalify/-/universalify-0.1.2.tgz#b646f69be3942dabcecc9d6639c80dc105efaa66"