TagSpaces is an offline, open source, document manager with tagging support
chore: improving the settings
Ilian Sapundshiev5688988be9d3
diff --git a/src/renderer/components/dialogs/settings/SettingsDialog.tsx b/src/renderer/components/dialogs/settings/SettingsDialog.tsxindex e732dfdc3..a6439840a 100644--- a/src/renderer/components/dialogs/settings/SettingsDialog.tsx+++ b/src/renderer/components/dialogs/settings/SettingsDialog.tsx@@ -88,12 +88,13 @@ function SettingsDialog(props: Props) {variant={fullScreen ? 'scrollable' : 'standard'}orientation={fullScreen ? 'horizontal' : 'vertical'}style={{- width: fullScreen ? '100%' : '150px',+ width: fullScreen ? '100%' : '170px',}}><Tabstyle={{- // textTransform: 'unset',+ textTransform: 'unset',+ fontSize: 16,alignItems: 'baseline',paddingLeft: 0,}}@@ -102,7 +103,8 @@ function SettingsDialog(props: Props) {/><Tabstyle={{- // textTransform: 'unset',+ textTransform: 'unset',+ fontSize: 16,alignItems: 'baseline',paddingLeft: 0,}}@@ -111,7 +113,8 @@ function SettingsDialog(props: Props) {/><Tabstyle={{- // textTransform: 'unset',+ textTransform: 'unset',+ fontSize: 16,alignItems: 'baseline',paddingLeft: 0,}}@@ -120,7 +123,8 @@ function SettingsDialog(props: Props) {/><Tabstyle={{- // textTransform: 'unset',+ textTransform: 'unset',+ fontSize: 16,alignItems: 'baseline',paddingLeft: 0,}}@@ -129,7 +133,8 @@ function SettingsDialog(props: Props) {/><Tabstyle={{- // textTransform: 'unset',+ textTransform: 'unset',+ fontSize: 16,alignItems: 'baseline',paddingLeft: 0,}}diff --git a/src/renderer/components/dialogs/settings/SettingsFileTypes.tsx b/src/renderer/components/dialogs/settings/SettingsFileTypes.tsxindex f591ea36d..504e5244e 100644--- a/src/renderer/components/dialogs/settings/SettingsFileTypes.tsx+++ b/src/renderer/components/dialogs/settings/SettingsFileTypes.tsx@@ -472,79 +472,79 @@ function SettingsFileTypes() {}return (- <Root>- <Paper+ <Paper+ style={{+ height: 500,+ width: '100%',+ minWidth: 550,+ overflow: 'hidden',+ background: 'transparent',+ paddingLeft: 10,+ }}+ >+ <TsButton+ data-tid="addNewFileTypeTID"+ onClick={onAddFileType}+ color="secondary"style={{- height: 500,- width: '100%',- minWidth: 550,- overflow: 'hidden',- background: 'transparent',+ width: 300,+ marginBottom: AppConfig.defaultSpaceBetweenButtons,}}>+ {t('core:addNewFileType')}+ </TsButton>+ {devMode && (<TsButton- data-tid="addNewFileTypeTID"- onClick={onAddFileType}+ data-tid="resetFileTypesTID"+ onClick={() => {+ selectedItem.current = undefined;+ items.current = defaultSupportedFileTypes;+ dispatch(SettingsActions.setSupportedFileTypes(supportedFileTypes));+ }}color="secondary"style={{ width: '50%' }}>- {t('core:addNewFileType')}+ {t('core:resetFileType')}</TsButton>- {devMode && (- <TsButton- data-tid="resetFileTypesTID"- onClick={() => {- selectedItem.current = undefined;- items.current = defaultSupportedFileTypes;- dispatch(- SettingsActions.setSupportedFileTypes(supportedFileTypes),- );- }}- color="secondary"- style={{ width: '50%' }}- >- {t('core:resetFileType')}- </TsButton>- )}- {isConfirmDialogOpened && (- <ConfirmDialog- open={isConfirmDialogOpened}- onClose={() => {- setIsConfirmDialogOpened(false);- }}- title="Confirm"- content={t('core:confirmFileTypeDeletion')}- confirmCallback={(result) => {- if (result) {- removeItem(selectedItem.current);- }- }}- cancelDialogTID="cancelDeleteFileTypeDialog"- confirmDialogTID="confirmDeleteFileTypeDialog"- confirmDialogContentTID="confirmDeleteFileTypeDialogContent"- />- )}- <TableVirtuoso- style={{- overflowX: 'hidden',- height: 'calc(100% - 30px)',- overflowY: 'auto',- background: 'transparent',+ )}+ {isConfirmDialogOpened && (+ <ConfirmDialog+ open={isConfirmDialogOpened}+ onClose={() => {+ setIsConfirmDialogOpened(false);}}- data={items.current}- components={VirtuosoTableComponents}- fixedHeaderContent={fixedHeaderContent}- itemContent={rowContent}- ref={settingsFileTypeRef}+ title="Confirm"+ content={t('core:confirmFileTypeDeletion')}+ confirmCallback={(result) => {+ if (result) {+ removeItem(selectedItem.current);+ }+ }}+ cancelDialogTID="cancelDeleteFileTypeDialog"+ confirmDialogTID="confirmDeleteFileTypeDialog"+ confirmDialogContentTID="confirmDeleteFileTypeDialogContent"/>- </Paper>+ )}+ <TableVirtuoso+ style={{+ overflowX: 'hidden',+ height: 'calc(100% - 30px)',+ overflowY: 'auto',+ background: 'transparent',+ }}+ data={items.current}+ components={VirtuosoTableComponents}+ fixedHeaderContent={fixedHeaderContent}+ itemContent={rowContent}+ ref={settingsFileTypeRef}+ /><ColorPickerDialogopen={isColorPickerVisible}setColor={handleChangeColor}onClose={closeColorPicker}color={selectedItem.current && selectedItem.current.color}/>- </Root>+ </Paper>);}