TagSpaces is an offline, open source, document manager with tagging support
minor changes
stanimir6070994bfd61
diff --git a/app/components/EntryContainer.tsx b/app/components/EntryContainer.tsxindex 1d77a7f4b..6d8261789 100644--- a/app/components/EntryContainer.tsx+++ b/app/components/EntryContainer.tsx@@ -973,33 +973,6 @@ const EntryContainer = (props: Props) => {return defaultSplitSize;}- const renderEntryProperties = memoize(openEntry => (- <div className={classes.entryProperties}>- {currentEntry.isFile ? renderFileToolbar(classes) : renderFolderToolbar()}- <EntryProperties- key={uuidv1()}- // resetState={this.resetState}- // setPropertiesEditMode={this.setPropertiesEditMode}- // entryPath={currentEntry.path}- // entryURL={currentEntry.url}- openedEntry={openEntry}- // shouldReload={reload}- renameFile={props.renameFile}- renameDirectory={props.renameDirectory}- editTagForEntry={props.editTagForEntry}- // shouldCopyFile={shouldCopyFile}- // normalizeShouldCopyFile={() => setShouldCopyFile(false)}- addTags={props.addTags}- removeTags={props.removeTags}- removeAllTags={props.removeAllTags}- reflectUpdateSidecarMeta={props.reflectUpdateSidecarMeta}- updateThumbnailUrl={props.updateThumbnailUrl}- showNotification={props.showNotification}- isReadOnlyMode={props.isReadOnlyMode}- />- </div>- ));-return (<GlobalHotKeyshandlers={{@@ -1242,7 +1215,32 @@ const EntryContainer = (props: Props) => {</div>)}</div>- {renderEntryProperties(currentEntry)}+ <div className={classes.entryProperties}>+ {currentEntry.isFile+ ? renderFileToolbar(classes)+ : renderFolderToolbar()}+ <EntryProperties+ key={uuidv1()}+ // resetState={this.resetState}+ // setPropertiesEditMode={this.setPropertiesEditMode}+ entryPath={currentEntry.path}+ // entryURL={currentEntry.url}+ // openedEntry={openEntry}+ // shouldReload={reload}+ renameFile={props.renameFile}+ renameDirectory={props.renameDirectory}+ editTagForEntry={props.editTagForEntry}+ // shouldCopyFile={shouldCopyFile}+ // normalizeShouldCopyFile={() => setShouldCopyFile(false)}+ addTags={props.addTags}+ removeTags={props.removeTags}+ removeAllTags={props.removeAllTags}+ reflectUpdateSidecarMeta={props.reflectUpdateSidecarMeta}+ updateThumbnailUrl={props.updateThumbnailUrl}+ showNotification={props.showNotification}+ isReadOnlyMode={props.isReadOnlyMode}+ />+ </div></div>) : (<div>{i18n.t('core:noEntrySelected')}</div>diff --git a/app/components/EntryProperties.tsx b/app/components/EntryProperties.tsxindex b9dc07bc1..63fcb5830 100644--- a/app/components/EntryProperties.tsx+++ b/app/components/EntryProperties.tsx@@ -154,8 +154,8 @@ marked.setOptions({interface Props {classes: any;theme: any;- openedEntry: OpenedEntry;- // entryPath: string;+ // openedEntry: OpenedEntry;+ entryPath: string;// entryURL: string;// shouldReload: boolean | null;// shouldCopyFile: boolean;@@ -205,10 +205,10 @@ const EntryProperties = (props: Props) => {// const [thumbPath, setThumbPath] = useState<string>('');useEffect(() => {- if (props.openedEntry) {- loadEntryProperties(props.openedEntry.path);+ if (props.entryPath) {+ loadEntryProperties(props.entryPath);}- }, [props.openedEntry]);+ }, [props.entryPath]);/* useEffect(() => { // Rethink and move this Dialog in EntryContainerif (props.shouldCopyFile) {diff --git a/app/containers/MainPage.tsx b/app/containers/MainPage.tsxindex d950febcb..26c06fc19 100644--- a/app/containers/MainPage.tsx+++ b/app/containers/MainPage.tsx@@ -183,7 +183,7 @@ interface Props {toggleAboutDialog: () => void; // needed by electron-menustoggleOnboardingDialog: () => void; // needed by electron-menussetLastSelectedEntry: (path: string) => void; // needed by electron-menus- openFile: (path: string) => void; // needed by electron-menus+ // openFile: (path: string) => void; // needed by electron-menusopenFileNatively: (url: string) => void; // needed by electron-menusopenURLExternally: (url: string) => void;getNextFile: () => void; // needed by electron-menus@@ -990,7 +990,7 @@ function mapDispatchToProps(dispatch) {toggleOnboardingDialog: AppActions.toggleOnboardingDialog,setLastSelectedEntry: AppActions.setLastSelectedEntry,setGeneratingThumbnails: AppActions.setGeneratingThumbnails,- openFile: AppActions.openFile,+ // openFile: AppActions.openFile,openFileNatively: AppActions.openFileNatively,openURLExternally: AppActions.openURLExternally,setEntryFullWidth: AppActions.setEntryFullWidth,