diff --git a/CliClient/locales/en_GB.po b/CliClient/locales/en_GB.po index b4a25edf88..304980bd41 100644 --- a/CliClient/locales/en_GB.po +++ b/CliClient/locales/en_GB.po @@ -469,6 +469,9 @@ msgstr "" msgid "Search:" msgstr "" +msgid "File" +msgstr "" + msgid "New note" msgstr "" @@ -556,6 +559,15 @@ msgstr "" msgid "Refresh" msgstr "" +msgid "OneDrive Login" +msgstr "" + +msgid "Import" +msgstr "" + +msgid "Configuration" +msgstr "" + msgid "Delete notebook?" msgstr "" @@ -773,9 +785,6 @@ msgstr "" msgid "Status" msgstr "" -msgid "Configuration" -msgstr "" - msgid "Cancel synchronisation" msgstr "" diff --git a/CliClient/locales/fr_FR.po b/CliClient/locales/fr_FR.po index 6b63ae18bd..d2b294a71a 100644 --- a/CliClient/locales/fr_FR.po +++ b/CliClient/locales/fr_FR.po @@ -520,6 +520,9 @@ msgstr "" msgid "Search:" msgstr "Chercher" +msgid "File" +msgstr "" + msgid "New note" msgstr "Nouvelle note" @@ -616,6 +619,17 @@ msgstr "Attacher un fichier" msgid "Refresh" msgstr "Rafraîchir" +#, fuzzy +msgid "OneDrive Login" +msgstr "OneDrive" + +#, fuzzy +msgid "Import" +msgstr "Importé - %s" + +msgid "Configuration" +msgstr "Configuration" + msgid "Delete notebook?" msgstr "Supprimer le carnet ?" @@ -846,9 +860,6 @@ msgstr "Journal" msgid "Status" msgstr "Etat" -msgid "Configuration" -msgstr "Configuration" - msgid "Cancel synchronisation" msgstr "Annuler synchronisation" @@ -1060,9 +1071,6 @@ msgstr "Bienvenue" #~ "Tous les ports sont en cours d'utilisation. Veuillez signaler ce problème " #~ "sur %s" -#~ msgid "Imported - %s" -#~ msgstr "Importé - %s" - #~ msgid "" #~ "There is currently no notebook. Create one by clicking on the (+) button." #~ msgstr "" diff --git a/CliClient/locales/joplin.pot b/CliClient/locales/joplin.pot index b4a25edf88..304980bd41 100644 --- a/CliClient/locales/joplin.pot +++ b/CliClient/locales/joplin.pot @@ -469,6 +469,9 @@ msgstr "" msgid "Search:" msgstr "" +msgid "File" +msgstr "" + msgid "New note" msgstr "" @@ -556,6 +559,15 @@ msgstr "" msgid "Refresh" msgstr "" +msgid "OneDrive Login" +msgstr "" + +msgid "Import" +msgstr "" + +msgid "Configuration" +msgstr "" + msgid "Delete notebook?" msgstr "" @@ -773,9 +785,6 @@ msgstr "" msgid "Status" msgstr "" -msgid "Configuration" -msgstr "" - msgid "Cancel synchronisation" msgstr "" diff --git a/ElectronClient/app/theme.js b/ElectronClient/app/theme.js index 358c7198fe..7b7e660ea7 100644 --- a/ElectronClient/app/theme.js +++ b/ElectronClient/app/theme.js @@ -1,7 +1,7 @@ const { Setting } = require('lib/models/setting.js'); const globalStyle = { - fontSize: 13, + fontSize: 12, fontFamily: 'sans-serif', margin: 15, // No text and no interactive component should be within this margin itemMarginTop: 10, diff --git a/ReactNativeClient/lib/BaseApplication.js b/ReactNativeClient/lib/BaseApplication.js index e264cc7b32..dc5eb050b4 100644 --- a/ReactNativeClient/lib/BaseApplication.js +++ b/ReactNativeClient/lib/BaseApplication.js @@ -136,10 +136,27 @@ class BaseApplication { process.exit(code); } - async refreshNotes(parentType, parentId) { - this.logger().debug('Refreshing notes:', parentType, parentId); + //async refreshNotes(parentType, parentId) { + //async refreshNotes(parentType, parentId) { + async refreshNotes(state) { + let parentType = state.notesParentType; + let parentId = null; + + if (parentType === 'Folder') { + parentId = state.selectedFolderId; + parentType = BaseModel.TYPE_FOLDER; + } else if (parentType === 'Note') { + parentId = state.selectedNoteId; + parentType = BaseModel.TYPE_NOTE; + } else if (parentType === 'Tag') { + parentId = state.selectedTagId; + parentType = BaseModel.TYPE_TAG; + } else if (parentType === 'Search') { + parentId = state.selectedSearchId; + parentType = BaseModel.TYPE_SEARCH; + } - const state = this.store().getState(); + this.logger().debug('Refreshing notes:', parentType, parentId); let options = { order: state.notesOrder, @@ -213,19 +230,19 @@ class BaseApplication { if (action.type == 'FOLDER_SELECT' || action.type === 'FOLDER_DELETE') { Setting.setValue('activeFolderId', newState.selectedFolderId); this.currentFolder_ = newState.selectedFolderId ? await Folder.load(newState.selectedFolderId) : null; - await this.refreshNotes(Folder.modelType(), newState.selectedFolderId); + await this.refreshNotes(newState); } if (this.hasGui() && action.type == 'SETTING_UPDATE_ONE' && action.key == 'uncompletedTodosOnTop' || action.type == 'SETTING_UPDATE_ALL') { - await this.refreshNotes(Folder.modelType(), newState.selectedFolderId); + await this.refreshNotes(newState); } - if (action.type == 'TAG_SELECT') { - await this.refreshNotes(Tag.modelType(), action.id); + if (action.type == 'TAG_SELECT' || action.type === 'TAG_DELETE') { + await this.refreshNotes(newState); } - if (action.type == 'SEARCH_SELECT') { - await this.refreshNotes(BaseModel.TYPE_SEARCH, action.id); + if (action.type == 'SEARCH_SELECT' || action.type === 'SEARCH_DELETE') { + await this.refreshNotes(newState); } if (this.hasGui() && action.type == 'SETTING_UPDATE_ONE' && action.key == 'sync.interval' || action.type == 'SETTING_UPDATE_ALL') { diff --git a/ReactNativeClient/lib/reducer.js b/ReactNativeClient/lib/reducer.js index 8e65aab37b..36d8813958 100644 --- a/ReactNativeClient/lib/reducer.js +++ b/ReactNativeClient/lib/reducer.js @@ -61,6 +61,10 @@ function handleItemDelete(state, action) { const newIndex = previousIndex >= 0 ? newItems[previousIndex].id : null; newState[selectedItemKey] = newIndex; + if (!newIndex && newState.notesParentType !== 'Folder') { + newState.notesParentType = 'Folder'; + } + return newState; }