1
0
mirror of https://github.com/laurent22/joplin.git synced 2025-08-30 20:39:46 +02:00

Compare commits

..

80 Commits

Author SHA1 Message Date
Laurent Cozic
f42786a840 Android release v1.3.8 2020-10-21 18:31:12 +01:00
Laurent Cozic
1c1f044966 Electron release v1.3.8 2020-10-21 18:19:33 +01:00
Laurent Cozic
ad7a80e260 Api: Allow preserving timestamps when updating a note 2020-10-21 18:12:36 +01:00
Laurent Cozic
5e040c062c Desktop: Fixes #3962: Certain commands no longer worked. 2020-10-21 17:22:29 +01:00
Laurent Cozic
0cede5f90a Desktop: Display more info while an ENEX file is being imported 2020-10-21 16:55:52 +01:00
Laurent Cozic
8dc0deb2a4 Desktop, Cli: Fixes #3958: Fixed freeze when importing ENEX as HTML, and fixed potential error when importing resources 2020-10-21 12:02:06 +01:00
Laurent Cozic
1ca44b8f44 Desktop: Made toolbar buttons bigger and swap order of bullet and number lists 2020-10-21 10:39:53 +01:00
Laurent Cozic
4ba9e60194 Merge branch 'dev' of github.com:laurent22/joplin into dev 2020-10-21 10:12:13 +01:00
Laurent Cozic
9d0bb4257f Desktop: Regression: Fixed format of copied version info 2020-10-21 10:10:18 +01:00
Alessandro Bernardello
1a273b9bca All: Translation: Update it_IT.po (#3956)
* Updated italian translation

* Updated translator name and email
2020-10-21 01:03:23 -04:00
Laurent Cozic
d9e93cd6c4 Doc: Update plugin doc 2020-10-21 01:46:53 +01:00
Laurent Cozic
5d39860707 Plugins: Allow custom commands to return a result 2020-10-21 01:43:06 +01:00
Laurent Cozic
60a6f714bc Update website 2020-10-21 00:56:03 +01:00
Laurent Cozic
6eebeca259 Tools: updated plugin types 2020-10-21 00:55:10 +01:00
Laurent Cozic
995034c53f Update plugin templates 2020-10-21 00:35:06 +01:00
Laurent Cozic
45a0981d05 Updated website 2020-10-21 00:27:11 +01:00
Laurent Cozic
3d8577a689 Plugins: Added support for content scripts
- For now, supports Markdown-it plugins
- Also fixed slow rendering of notes in some cases
- Simplified how Markdown-It plugins are created and cleaned MdToHtml code

commit 89576de289
Merge: c75aa21f 5292fc14
Author: Laurent Cozic <laurent@cozic.net>
Date:   Wed Oct 21 00:23:00 2020 +0100

    Merge branch 'release-1.3' into plugin_content_scripts

commit c75aa21ffd
Author: Laurent Cozic <laurent@cozic.net>
Date:   Wed Oct 21 00:19:52 2020 +0100

    Fixed tests

commit 075187729d
Author: Laurent Cozic <laurent@cozic.net>
Date:   Wed Oct 21 00:11:53 2020 +0100

    Fixed tests

commit 14696b8c65
Author: Laurent Cozic <laurent@cozic.net>
Date:   Tue Oct 20 23:27:58 2020 +0100

    Fixed slow rendering of note

commit 61c09f5bf8
Author: Laurent Cozic <laurent@cozic.net>
Date:   Tue Oct 20 22:35:21 2020 +0100

    Clean up

commit 9f7ea7d865
Author: Laurent Cozic <laurent@cozic.net>
Date:   Tue Oct 20 20:05:31 2020 +0100

    Updated doc

commit 98bf3bde8d
Author: Laurent Cozic <laurent@cozic.net>
Date:   Tue Oct 20 19:56:34 2020 +0100

    Finished converting plugins

commit fe90d92e01
Author: Laurent Cozic <laurent@cozic.net>
Date:   Tue Oct 20 17:52:02 2020 +0100

    Simplified how Markdown-It plugins are created

commit 47c7b864cb
Author: Laurent Cozic <laurent@cozic.net>
Date:   Mon Oct 19 16:40:11 2020 +0100

    Clean up rules

commit d927a238bb
Author: Laurent Cozic <laurent@cozic.net>
Date:   Mon Oct 19 14:29:40 2020 +0100

    Fixed tests

commit 388a56c5dd
Author: Laurent Cozic <laurent@cozic.net>
Date:   Mon Oct 19 14:00:47 2020 +0100

    Add support for content scripts
2020-10-21 00:23:55 +01:00
Laurent Cozic
5292fc1402 Tools: Escape HTML when generating changelog 2020-10-20 17:16:09 +01:00
Laurent Cozic
03063f1137 All: Fixed setting issue that would cause a password to be saved in plain text in the database, even when the keychain is working 2020-10-20 16:37:14 +01:00
Laurent Cozic
b125a768b8 Tools: Added test units for keychains on macOS and Windows 2020-10-20 16:16:18 +01:00
Laurent Cozic
a721f170e4 Doc: Added info about search filters 2020-10-20 12:12:00 +01:00
Laurent Cozic
76cd69ea16 Electron release v1.3.7 2020-10-20 12:01:12 +01:00
Laurent Cozic
45d4f277e2 Merge branch 'dev' into release-1.3 2020-10-20 12:00:39 +01:00
Naveen M V
fc2a52aa1a Desktop, Cli; Fix notebook search filter (#3946) 2020-10-20 11:54:46 +01:00
Roman Musin
b3e5a1e48d Android: do not show long press menu on press and drag (#3939) 2020-10-20 11:51:24 +01:00
Laurent Cozic
45eb902030 Fixed tests 2020-10-20 11:49:15 +01:00
Ian Slinger
456f7ac00c Desktop, Cli: Import <strike>,<s> tags (strikethrough) from Evernote (#3936) 2020-10-20 11:47:48 +01:00
Aaron
a93bda71fe All: Resolves #3691: Added support for a custom S3 URL (#3921) 2020-10-20 11:44:11 +01:00
Alkindi42
0f9d92dd3d Doc: add archlinux package for pre-release in docs (#3875) 2020-10-20 11:42:41 +01:00
Laurent Cozic
5543e9ef64 Merge branch 'release-1.3' of https://github.com/laurent22/joplin into release-1.3 2020-10-20 11:14:58 +01:00
Laurent Cozic
22dd613660 Revert "Plugins: Adding support for command boolean expressions"
This reverts commit f8f46db910.

Feature was implemented in 3a57cfea02
2020-10-20 11:13:56 +01:00
Laurent Cozic
f7502fe34b Electron release v1.3.6 2020-10-19 23:25:59 +01:00
Laurent Cozic
8254206f44 Desktop: Fixes #3893 (maybe): Trying to fix sidebar performance issue when there are many notebooks or tags 2020-10-19 23:24:40 +01:00
Laurent Cozic
3a57cfea02 Desktop: Simplified and improve command service, and added command palette
- Commands "enabled" state is now expressed using a "when-clause" like in VSCode
- A command palette has been added to the Tools menu
2020-10-18 21:52:10 +01:00
Helmut K. C. Tessarek
71bf0437c1 Desktop: Tray: Exit -> Quit (#3945) 2020-10-18 12:57:04 +01:00
Tomáš Bambas
eca4e24362 All: Translation: Update cs_CZ.po (#3940) 2020-10-17 14:01:32 -04:00
Andros Fenollosa
9a6efb7b37 All: Translation: Update es_ES.po (#3929)
* Update locale es

* Finish translate
2020-10-17 14:00:48 -04:00
jduar
4b666cbbd2 All: Translation: Update pt-PT.po (#3924)
* Updated the Portuguese (pt-PT) translation.

* Updated translator name and email.
2020-10-17 13:58:49 -04:00
Laurent Cozic
f8f46db910 Plugins: Adding support for command boolean expressions 2020-10-17 16:50:07 +01:00
Laurent Cozic
f529adac99 Electron release v1.3.5 2020-10-17 14:05:13 +01:00
Laurent Cozic
3a52b9764b Electron release v1.3.4 2020-10-17 14:03:16 +01:00
Laurent Cozic
7e78d7716b Desktop: Regression: Fixed opening links 2020-10-17 13:56:41 +01:00
Laurent Cozic
0488c5c4cb Android release v1.3.7 2020-10-17 12:07:51 +01:00
Laurent Cozic
921cc3b6c6 Electron release v1.3.3 2020-10-17 11:37:37 +01:00
Laurent Cozic
2a7aa28d4c Desktop, Cli: Fixes #3923 (Regression): Importing ENEX as HTML was importing as Markdown 2020-10-17 11:35:51 +01:00
Laurent Cozic
7b3440ac4c Desktop: Fixes #3915: Editor toolbar was disabled when importing note from MD file 2020-10-17 11:15:43 +01:00
Laurent Cozic
958e5a80b7 Desktop: Fixes #3903: Header links with special characters were no longer working 2020-10-16 22:55:48 +01:00
Laurent Cozic
3179117c62 Mobile: Fixed notebook expand icons 2020-10-16 21:52:27 +01:00
Laurent Cozic
d895463167 All: Removed OneDrive Dev sync target which was not really useful 2020-10-16 21:34:34 +01:00
Laurent Cozic
7e0e513051 Desktop: Regression: Fixed check for update 2020-10-16 21:14:57 +01:00
Laurent Cozic
4309c4f8e2 Desktop: Fixed Toggle Editor button toolip and icon 2020-10-16 18:52:17 +01:00
Laurent Cozic
20b1c90574 Android: Fixed signing config for production 2020-10-16 18:30:58 +01:00
Laurent Cozic
7ff6ceb585 Merge branch 'release-1.3' of https://github.com/laurent22/joplin into release-1.3 2020-10-16 17:45:29 +01:00
Laurent Cozic
3dc3f334ec Tools: Cleaned up ignored files as it was breaking VSCode search 2020-10-16 17:44:50 +01:00
Laurent Cozic
3476211f8b Desktop: Regression: Fixed move to notebook from context menu 2020-10-16 17:44:04 +01:00
Laurent Cozic
48e299916f Desktop: Make sidebar item font weight normal (not bold) 2020-10-16 17:07:43 +01:00
Laurent Cozic
35aebc9f52 Android release v1.3.3 2020-10-16 17:05:22 +01:00
Laurent Cozic
cb3e1cf1e9 Mobile: Upgraded React Native to v0.63
commit 2fb6cee901
Merge: 4e303be85f db509955f6
Author: Laurent Cozic <laurent@cozic.net>
Date:   Fri Oct 16 16:24:07 2020 +0100

    Merge branch 'dev' into rn_63

commit 4e303be85f
Author: Laurent Cozic <laurent@cozic.net>
Date:   Fri Oct 16 16:14:39 2020 +0100

    Clean up

commit e3a37ec2d6
Author: Laurent Cozic <laurent@cozic.net>
Date:   Fri Oct 16 15:57:55 2020 +0100

    Use different script for pre-commit and manual start

commit bd236648fc
Author: Laurent Cozic <laurent@cozic.net>
Date:   Fri Oct 16 15:56:45 2020 +0100

    Removed RN eslint config

commit e7feda41c9
Author: Laurent Cozic <laurent@cozic.net>
Date:   Fri Oct 16 15:27:08 2020 +0100

    Revert "Disable git hook for now"

    This reverts commit 89263ac742.

commit cfd63fe46f
Author: Laurent Cozic <laurent@cozic.net>
Date:   Fri Oct 16 13:02:32 2020 +0100

    Ask permission to use geo-location

commit 66059939a3
Author: Laurent Cozic <laurent@cozic.net>
Date:   Fri Oct 16 12:26:20 2020 +0100

    Fixed WebView race condition

commit 1e0d2b7b86
Author: Laurent Cozic <laurent@cozic.net>
Date:   Fri Oct 16 11:56:21 2020 +0100

    Fixed webview issues

commit f537d22d7f
Author: Laurent Cozic <laurent@cozic.net>
Date:   Fri Oct 16 11:08:29 2020 +0100

    Improve resource file watching

commit eec32cf70a
Author: Laurent Cozic <laurent@cozic.net>
Date:   Thu Oct 15 18:40:13 2020 +0100

    Removed cache package dependency and implemented one more suitable for React Native

commit efa346fea4
Author: Laurent Cozic <laurent@cozic.net>
Date:   Thu Oct 15 14:57:21 2020 +0100

    iOS: Added fonts to Info.plist although it was working without it

commit 572b647bc0
Author: Laurent Cozic <laurent@cozic.net>
Date:   Thu Oct 15 14:56:49 2020 +0100

    Specify content-type header for OneDrive to prevent network error

commit bcedf6c7f0
Author: Laurent Cozic <laurent@cozic.net>
Date:   Thu Oct 15 12:45:01 2020 +0100

    iOS: Disable long press menu since it is already built-in

commit 7359dd61d1
Author: Laurent Cozic <laurent@cozic.net>
Date:   Thu Oct 15 12:37:40 2020 +0100

    Removed unused react-native-device-info

commit 2d63ab36d3
Author: Laurent Cozic <laurent@cozic.net>
Date:   Thu Oct 15 12:35:54 2020 +0100

    iOS: Fixed taking a picture

commit 8e2875a91c
Author: Laurent Cozic <laurent@cozic.net>
Date:   Thu Oct 15 12:11:13 2020 +0100

    iOS: Restored camera roll functionality

commit 75f5edf2ad
Author: Laurent Cozic <laurent@cozic.net>
Date:   Thu Oct 15 11:40:13 2020 +0100

    iOS: Fixed build settings

commit b220c98419
Author: Laurent Cozic <laurent@cozic.net>
Date:   Thu Oct 15 11:40:03 2020 +0100

    iOS: Got images to work with WebKit

commit c34b43e841
Author: Laurent Cozic <laurent@cozic.net>
Date:   Thu Oct 15 10:24:52 2020 +0100

    iOS: Restore more settings

commit 32997611e6
Author: Laurent Cozic <laurent@cozic.net>
Date:   Thu Oct 15 10:15:14 2020 +0100

    iOS: Added back icons and other properties

commit b5811d7f7c
Author: Laurent Cozic <laurent@cozic.net>
Date:   Wed Oct 14 23:53:14 2020 +0100

    Got iOS build to work

commit dc6d7c00e0
Author: Laurent Cozic <laurent@cozic.net>
Date:   Wed Oct 14 18:40:06 2020 +0100

    Imported old settings in gradle build

commit dff59f5603
Author: Laurent Cozic <laurent@cozic.net>
Date:   Wed Oct 14 18:20:00 2020 +0100

    Restored sharing

commit 0bdb449e72
Author: Laurent Cozic <laurent@cozic.net>
Date:   Wed Oct 14 17:25:40 2020 +0100

    Updated NoteBodyViewer

commit 0c0d228815
Author: Laurent Cozic <laurent@cozic.net>
Date:   Wed Oct 14 16:54:42 2020 +0100

    Fixed networking

commit 6ff45ce485
Author: Laurent Cozic <laurent@cozic.net>
Date:   Wed Oct 14 13:11:00 2020 +0100

    Fixed document picker

commit cc889182b6
Author: Laurent Cozic <laurent@cozic.net>
Date:   Wed Oct 14 12:56:27 2020 +0100

    Added back support for alarms

commit 040261abfa
Author: Laurent Cozic <laurent@cozic.net>
Date:   Tue Oct 13 22:04:49 2020 +0100

    Fixed Clipboard and remove image-picker package

commit 1077ad8f16
Author: Laurent Cozic <laurent@cozic.net>
Date:   Tue Oct 13 21:54:52 2020 +0100

    Fixed Select Alarm dialog and PoorManIntervals class

commit 8296676fd5
Author: Laurent Cozic <laurent@cozic.net>
Date:   Tue Oct 13 21:32:52 2020 +0100

    Fixed icons and warnings

commit 3b0e3f6f43
Author: Laurent Cozic <laurent@cozic.net>
Date:   Tue Oct 13 17:02:59 2020 +0100

    Got app to build again

commit 89263ac742
Author: Laurent Cozic <laurent@cozic.net>
Date:   Tue Oct 13 15:41:17 2020 +0100

    Disable git hook for now

commit d6da162f67
Author: Laurent Cozic <laurent@cozic.net>
Date:   Tue Oct 13 15:39:12 2020 +0100

    Restored back all RN packages

commit 7f8ce3732c
Author: Laurent Cozic <laurent@cozic.net>
Date:   Tue Oct 13 15:13:12 2020 +0100

    Restored base packages

commit ea59726eb3
Author: Laurent Cozic <laurent@cozic.net>
Date:   Tue Oct 13 15:05:17 2020 +0100

    Started over from scratch
2020-10-16 16:26:19 +01:00
Andros Fenollosa
db509955f6 Cli: Updated installation script with BSD support (#3930) 2020-10-16 15:18:57 +01:00
Caleb John
fb39899f8e Desktop, Cli: Regression: Fix export of pluginAssets when exporting to html/pdf (#3927) 2020-10-16 15:18:19 +01:00
Laurent Cozic
f5d4bedc07 Doc: Fixed plugin API 2020-10-15 16:08:01 +01:00
Laurent Cozic
e710709c15 Fixed special space 2020-10-15 15:54:31 +01:00
Laurent Cozic
d74d6d9539 Update website 2020-10-15 15:35:43 +01:00
Laurent Cozic
435e8dfc3b Trying deployment again 2020-10-15 15:17:18 +01:00
Laurent Cozic
6c68459b34 Update website 2020-10-15 15:07:26 +01:00
Laurent Cozic
2e75a63b26 Updatee website 2020-10-13 13:02:35 +01:00
Laurent Cozic
c328996568 Desktop: Fixed toggleNoteList and toggleSidebar commands 2020-10-13 13:01:02 +01:00
Laurent Cozic
c648f19693 Desktop: Added support for Menu API for plugins 2020-10-13 12:57:03 +01:00
Laurent Cozic
2caaf8e8c1 Desktop: Added support for plugins packaged as JS bundles 2020-10-13 11:16:36 +01:00
Laurent Cozic
ceb7a7303d Desktop: Plugin API - added support for settings.globalValue method 2020-10-13 09:59:53 +01:00
Laurent Cozic
c01f533342 Desktop: Regression: Remove Hide Joplin menu item on Linux too 2020-10-13 09:45:40 +01:00
Laurent Cozic
ff50361e19 Merge branch 'dev' into release-1.3 2020-10-13 09:42:26 +01:00
Laurent Cozic
3539a452a3 Desktop: Remove Hide Joplin menu item on Linux and Windows 2020-10-12 10:45:00 +01:00
Laurent Cozic
9dfe084a02 Destkop: Create template directory on startup 2020-10-12 09:52:36 +01:00
Laurent Cozic
66204401c9 Desktop: Fixes #3899: Regression - Layout Button Sequence menu items were disabled 2020-10-11 22:22:04 +01:00
Laurent Cozic
0644e2897d Security: Updated packages to fix security vulnerabilities 2020-10-11 22:16:53 +01:00
Laurent Cozic
5761451def Merge branch 'dev' into release-1.3 2020-10-11 22:13:06 +01:00
Laurent Cozic
12db3d20ee Electron release v1.3.2 2020-10-11 19:37:57 +01:00
Laurent Cozic
80a70a6649 Desktop: Regression: Context menu in sidebar could point to wrong item 2020-10-11 19:37:12 +01:00
Laurent Cozic
02ed297529 tab 2020-10-11 19:27:33 +01:00
591 changed files with 26809 additions and 10141 deletions

View File

@@ -64,11 +64,16 @@ CliClient/build/
# AUTO-GENERATED - EXCLUDED TYPESCRIPT BUILD
CliClient/app/LinkSelector.js
CliClient/app/services/plugins/PluginRunner.js
CliClient/tests/fsDriver.js
CliClient/tests/InMemoryCache.js
CliClient/tests/MdToHtml.js
CliClient/tests/models_Setting.js
CliClient/tests/services_CommandService.js
CliClient/tests/services_InteropService.js
CliClient/tests/services_keychainService.js
CliClient/tests/services_PluginService.js
CliClient/tests/services_rest_Api.js
CliClient/tests/services/plugins/api/JoplinSetting.js
CliClient/tests/services/plugins/sandboxProxy.js
CliClient/tests/synchronizer_LockHandler.js
CliClient/tests/synchronizer_MigrationHandler.js
@@ -112,7 +117,7 @@ ElectronClient/gui/MainScreen/commands/showNoteProperties.js
ElectronClient/gui/MainScreen/commands/showShareNoteDialog.js
ElectronClient/gui/MainScreen/commands/toggleEditors.js
ElectronClient/gui/MainScreen/commands/toggleNoteList.js
ElectronClient/gui/MainScreen/commands/toggleSidebar.js
ElectronClient/gui/MainScreen/commands/toggleSideBar.js
ElectronClient/gui/MainScreen/commands/toggleVisiblePanes.js
ElectronClient/gui/MainScreen/MainScreen.js
ElectronClient/gui/MenuBar.js
@@ -178,6 +183,7 @@ ElectronClient/gui/SideBar/styles/index.js
ElectronClient/gui/StatusScreen/StatusScreen.js
ElectronClient/gui/style/StyledInput.js
ElectronClient/gui/style/StyledTextInput.js
ElectronClient/gui/TagList.js
ElectronClient/gui/ToggleEditorsButton/styles/index.js
ElectronClient/gui/ToggleEditorsButton/ToggleEditorsButton.js
ElectronClient/gui/ToolbarBase.js
@@ -185,7 +191,9 @@ ElectronClient/gui/ToolbarButton/styles/index.js
ElectronClient/gui/ToolbarButton/ToolbarButton.js
ElectronClient/gui/utils/NoteListUtils.js
ElectronClient/InteropServiceHelper.js
ElectronClient/plugins/GotoAnything.js
ElectronClient/services/bridge.js
ElectronClient/services/commands/types.js
ElectronClient/services/plugins/hooks/useThemeCss.js
ElectronClient/services/plugins/hooks/useViewIsReady.js
ElectronClient/services/plugins/PlatformImplementation.js
@@ -200,33 +208,57 @@ ReactNativeClient/lib/commands/historyBackward.js
ReactNativeClient/lib/commands/historyForward.js
ReactNativeClient/lib/commands/synchronize.js
ReactNativeClient/lib/components/BackButtonDialogBox.js
ReactNativeClient/lib/components/CameraView.js
ReactNativeClient/lib/components/NoteBodyViewer/hooks/useOnMessage.js
ReactNativeClient/lib/components/NoteBodyViewer/hooks/useOnResourceLongPress.js
ReactNativeClient/lib/components/NoteBodyViewer/hooks/useSource.js
ReactNativeClient/lib/components/NoteBodyViewer/NoteBodyViewer.js
ReactNativeClient/lib/components/screens/Note.js
ReactNativeClient/lib/components/screens/UpgradeSyncTargetScreen.js
ReactNativeClient/lib/components/SelectDateTimeDialog.js
ReactNativeClient/lib/errorUtils.js
ReactNativeClient/lib/eventManager.js
ReactNativeClient/lib/fs-driver-node.js
ReactNativeClient/lib/hooks/useEffectDebugger.js
ReactNativeClient/lib/hooks/useImperativeHandlerDebugger.js
ReactNativeClient/lib/hooks/usePrevious.js
ReactNativeClient/lib/hooks/usePropsDebugger.js
ReactNativeClient/lib/InMemoryCache.js
ReactNativeClient/lib/joplin-renderer/MarkupToHtml.js
ReactNativeClient/lib/joplin-renderer/MdToHtml.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/checkbox.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/code_inline.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/fence.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/fountain.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/highlight_keywords.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/html_image.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/image.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/katex.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/link_open.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/mermaid.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/sanitize_html.js
ReactNativeClient/lib/joplin-renderer/noteStyle.js
ReactNativeClient/lib/joplin-renderer/pathUtils.js
ReactNativeClient/lib/JoplinServerApi.js
ReactNativeClient/lib/locale.js
ReactNativeClient/lib/Logger.js
ReactNativeClient/lib/markdownUtils.js
ReactNativeClient/lib/markupLanguageUtils.js
ReactNativeClient/lib/models/Alarm.js
ReactNativeClient/lib/models/Setting.js
ReactNativeClient/lib/ntpDate.js
ReactNativeClient/lib/path-utils.js
ReactNativeClient/lib/PoorManIntervals.js
ReactNativeClient/lib/reducer.js
ReactNativeClient/lib/services/AlarmService.js
ReactNativeClient/lib/services/AlarmServiceDriver.android.js
ReactNativeClient/lib/services/AlarmServiceDriver.ios.js
ReactNativeClient/lib/services/AlarmServiceDriverNode.js
ReactNativeClient/lib/services/BaseService.js
ReactNativeClient/lib/services/BooleanExpression.js
ReactNativeClient/lib/services/commands/commandsToMarkdownTable.js
ReactNativeClient/lib/services/commands/MenuUtils.js
ReactNativeClient/lib/services/commands/propsHaveChanged.js
ReactNativeClient/lib/services/commands/stateToWhenClauseContext.js
ReactNativeClient/lib/services/commands/ToolbarButtonUtils.js
ReactNativeClient/lib/services/CommandService.js
ReactNativeClient/lib/services/contextkey/contextkey.js
@@ -263,17 +295,20 @@ ReactNativeClient/lib/services/plugins/api/JoplinSettings.js
ReactNativeClient/lib/services/plugins/api/JoplinViews.js
ReactNativeClient/lib/services/plugins/api/JoplinViewsDialogs.js
ReactNativeClient/lib/services/plugins/api/JoplinViewsMenuItems.js
ReactNativeClient/lib/services/plugins/api/JoplinViewsMenus.js
ReactNativeClient/lib/services/plugins/api/JoplinViewsPanels.js
ReactNativeClient/lib/services/plugins/api/JoplinViewsToolbarButtons.js
ReactNativeClient/lib/services/plugins/api/JoplinWorkspace.js
ReactNativeClient/lib/services/plugins/api/types.js
ReactNativeClient/lib/services/plugins/BasePluginRunner.js
ReactNativeClient/lib/services/plugins/MenuController.js
ReactNativeClient/lib/services/plugins/MenuItemController.js
ReactNativeClient/lib/services/plugins/Plugin.js
ReactNativeClient/lib/services/plugins/PluginService.js
ReactNativeClient/lib/services/plugins/reducer.js
ReactNativeClient/lib/services/plugins/sandboxProxy.js
ReactNativeClient/lib/services/plugins/ToolbarButtonController.js
ReactNativeClient/lib/services/plugins/utils/contentScriptsToRendererRules.js
ReactNativeClient/lib/services/plugins/utils/createViewHandle.js
ReactNativeClient/lib/services/plugins/utils/executeSandboxCall.js
ReactNativeClient/lib/services/plugins/utils/manifestFromObject.js
@@ -296,6 +331,7 @@ ReactNativeClient/lib/services/synchronizer/migrations/1.js
ReactNativeClient/lib/services/synchronizer/migrations/2.js
ReactNativeClient/lib/services/synchronizer/utils/types.js
ReactNativeClient/lib/services/UndoRedoService.js
ReactNativeClient/lib/services/WhenClause.js
ReactNativeClient/lib/ShareExtension.js
ReactNativeClient/lib/shareHandler.js
ReactNativeClient/lib/shim.js

40
.gitignore vendored
View File

@@ -58,11 +58,16 @@ plugin_types/
# AUTO-GENERATED - EXCLUDED TYPESCRIPT BUILD
CliClient/app/LinkSelector.js
CliClient/app/services/plugins/PluginRunner.js
CliClient/tests/fsDriver.js
CliClient/tests/InMemoryCache.js
CliClient/tests/MdToHtml.js
CliClient/tests/models_Setting.js
CliClient/tests/services_CommandService.js
CliClient/tests/services_InteropService.js
CliClient/tests/services_keychainService.js
CliClient/tests/services_PluginService.js
CliClient/tests/services_rest_Api.js
CliClient/tests/services/plugins/api/JoplinSetting.js
CliClient/tests/services/plugins/sandboxProxy.js
CliClient/tests/synchronizer_LockHandler.js
CliClient/tests/synchronizer_MigrationHandler.js
@@ -106,7 +111,7 @@ ElectronClient/gui/MainScreen/commands/showNoteProperties.js
ElectronClient/gui/MainScreen/commands/showShareNoteDialog.js
ElectronClient/gui/MainScreen/commands/toggleEditors.js
ElectronClient/gui/MainScreen/commands/toggleNoteList.js
ElectronClient/gui/MainScreen/commands/toggleSidebar.js
ElectronClient/gui/MainScreen/commands/toggleSideBar.js
ElectronClient/gui/MainScreen/commands/toggleVisiblePanes.js
ElectronClient/gui/MainScreen/MainScreen.js
ElectronClient/gui/MenuBar.js
@@ -172,6 +177,7 @@ ElectronClient/gui/SideBar/styles/index.js
ElectronClient/gui/StatusScreen/StatusScreen.js
ElectronClient/gui/style/StyledInput.js
ElectronClient/gui/style/StyledTextInput.js
ElectronClient/gui/TagList.js
ElectronClient/gui/ToggleEditorsButton/styles/index.js
ElectronClient/gui/ToggleEditorsButton/ToggleEditorsButton.js
ElectronClient/gui/ToolbarBase.js
@@ -179,7 +185,9 @@ ElectronClient/gui/ToolbarButton/styles/index.js
ElectronClient/gui/ToolbarButton/ToolbarButton.js
ElectronClient/gui/utils/NoteListUtils.js
ElectronClient/InteropServiceHelper.js
ElectronClient/plugins/GotoAnything.js
ElectronClient/services/bridge.js
ElectronClient/services/commands/types.js
ElectronClient/services/plugins/hooks/useThemeCss.js
ElectronClient/services/plugins/hooks/useViewIsReady.js
ElectronClient/services/plugins/PlatformImplementation.js
@@ -194,33 +202,57 @@ ReactNativeClient/lib/commands/historyBackward.js
ReactNativeClient/lib/commands/historyForward.js
ReactNativeClient/lib/commands/synchronize.js
ReactNativeClient/lib/components/BackButtonDialogBox.js
ReactNativeClient/lib/components/CameraView.js
ReactNativeClient/lib/components/NoteBodyViewer/hooks/useOnMessage.js
ReactNativeClient/lib/components/NoteBodyViewer/hooks/useOnResourceLongPress.js
ReactNativeClient/lib/components/NoteBodyViewer/hooks/useSource.js
ReactNativeClient/lib/components/NoteBodyViewer/NoteBodyViewer.js
ReactNativeClient/lib/components/screens/Note.js
ReactNativeClient/lib/components/screens/UpgradeSyncTargetScreen.js
ReactNativeClient/lib/components/SelectDateTimeDialog.js
ReactNativeClient/lib/errorUtils.js
ReactNativeClient/lib/eventManager.js
ReactNativeClient/lib/fs-driver-node.js
ReactNativeClient/lib/hooks/useEffectDebugger.js
ReactNativeClient/lib/hooks/useImperativeHandlerDebugger.js
ReactNativeClient/lib/hooks/usePrevious.js
ReactNativeClient/lib/hooks/usePropsDebugger.js
ReactNativeClient/lib/InMemoryCache.js
ReactNativeClient/lib/joplin-renderer/MarkupToHtml.js
ReactNativeClient/lib/joplin-renderer/MdToHtml.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/checkbox.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/code_inline.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/fence.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/fountain.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/highlight_keywords.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/html_image.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/image.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/katex.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/link_open.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/mermaid.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/sanitize_html.js
ReactNativeClient/lib/joplin-renderer/noteStyle.js
ReactNativeClient/lib/joplin-renderer/pathUtils.js
ReactNativeClient/lib/JoplinServerApi.js
ReactNativeClient/lib/locale.js
ReactNativeClient/lib/Logger.js
ReactNativeClient/lib/markdownUtils.js
ReactNativeClient/lib/markupLanguageUtils.js
ReactNativeClient/lib/models/Alarm.js
ReactNativeClient/lib/models/Setting.js
ReactNativeClient/lib/ntpDate.js
ReactNativeClient/lib/path-utils.js
ReactNativeClient/lib/PoorManIntervals.js
ReactNativeClient/lib/reducer.js
ReactNativeClient/lib/services/AlarmService.js
ReactNativeClient/lib/services/AlarmServiceDriver.android.js
ReactNativeClient/lib/services/AlarmServiceDriver.ios.js
ReactNativeClient/lib/services/AlarmServiceDriverNode.js
ReactNativeClient/lib/services/BaseService.js
ReactNativeClient/lib/services/BooleanExpression.js
ReactNativeClient/lib/services/commands/commandsToMarkdownTable.js
ReactNativeClient/lib/services/commands/MenuUtils.js
ReactNativeClient/lib/services/commands/propsHaveChanged.js
ReactNativeClient/lib/services/commands/stateToWhenClauseContext.js
ReactNativeClient/lib/services/commands/ToolbarButtonUtils.js
ReactNativeClient/lib/services/CommandService.js
ReactNativeClient/lib/services/contextkey/contextkey.js
@@ -257,17 +289,20 @@ ReactNativeClient/lib/services/plugins/api/JoplinSettings.js
ReactNativeClient/lib/services/plugins/api/JoplinViews.js
ReactNativeClient/lib/services/plugins/api/JoplinViewsDialogs.js
ReactNativeClient/lib/services/plugins/api/JoplinViewsMenuItems.js
ReactNativeClient/lib/services/plugins/api/JoplinViewsMenus.js
ReactNativeClient/lib/services/plugins/api/JoplinViewsPanels.js
ReactNativeClient/lib/services/plugins/api/JoplinViewsToolbarButtons.js
ReactNativeClient/lib/services/plugins/api/JoplinWorkspace.js
ReactNativeClient/lib/services/plugins/api/types.js
ReactNativeClient/lib/services/plugins/BasePluginRunner.js
ReactNativeClient/lib/services/plugins/MenuController.js
ReactNativeClient/lib/services/plugins/MenuItemController.js
ReactNativeClient/lib/services/plugins/Plugin.js
ReactNativeClient/lib/services/plugins/PluginService.js
ReactNativeClient/lib/services/plugins/reducer.js
ReactNativeClient/lib/services/plugins/sandboxProxy.js
ReactNativeClient/lib/services/plugins/ToolbarButtonController.js
ReactNativeClient/lib/services/plugins/utils/contentScriptsToRendererRules.js
ReactNativeClient/lib/services/plugins/utils/createViewHandle.js
ReactNativeClient/lib/services/plugins/utils/executeSandboxCall.js
ReactNativeClient/lib/services/plugins/utils/manifestFromObject.js
@@ -290,6 +325,7 @@ ReactNativeClient/lib/services/synchronizer/migrations/1.js
ReactNativeClient/lib/services/synchronizer/migrations/2.js
ReactNativeClient/lib/services/synchronizer/utils/types.js
ReactNativeClient/lib/services/UndoRedoService.js
ReactNativeClient/lib/services/WhenClause.js
ReactNativeClient/lib/ShareExtension.js
ReactNativeClient/lib/shareHandler.js
ReactNativeClient/lib/shim.js

296
.ignore Normal file
View File

@@ -0,0 +1,296 @@
# This is used by VSCode to ignore patterns during search.
# Before they were in joplin.code-workspace, under the `files.exclude` key
# but it eventually reached the limit with ENAMETOOLONG error.
#
# https://github.com/microsoft/vscode/issues/94718
# AUTO-GENERATED - EXCLUDED TYPESCRIPT BUILD
CliClient/app/LinkSelector.js
CliClient/app/services/plugins/PluginRunner.js
CliClient/tests/fsDriver.js
CliClient/tests/InMemoryCache.js
CliClient/tests/MdToHtml.js
CliClient/tests/models_Setting.js
CliClient/tests/services_CommandService.js
CliClient/tests/services_InteropService.js
CliClient/tests/services_keychainService.js
CliClient/tests/services_PluginService.js
CliClient/tests/services_rest_Api.js
CliClient/tests/services/plugins/api/JoplinSetting.js
CliClient/tests/services/plugins/sandboxProxy.js
CliClient/tests/synchronizer_LockHandler.js
CliClient/tests/synchronizer_MigrationHandler.js
ElectronClient/app.js
ElectronClient/bridge.js
ElectronClient/commands/copyDevCommand.js
ElectronClient/commands/focusElement.js
ElectronClient/commands/startExternalEditing.js
ElectronClient/commands/stopExternalEditing.js
ElectronClient/commands/toggleExternalEditing.js
ElectronClient/ElectronAppWrapper.js
ElectronClient/global.d.js
ElectronClient/gui/Button/Button.js
ElectronClient/gui/ConfigScreen/ButtonBar.js
ElectronClient/gui/ConfigScreen/ConfigScreen.js
ElectronClient/gui/ConfigScreen/SideBar.js
ElectronClient/gui/DropboxLoginScreen.js
ElectronClient/gui/ErrorBoundary.js
ElectronClient/gui/KeymapConfig/KeymapConfigScreen.js
ElectronClient/gui/KeymapConfig/ShortcutRecorder.js
ElectronClient/gui/KeymapConfig/styles/index.js
ElectronClient/gui/KeymapConfig/utils/getLabel.js
ElectronClient/gui/KeymapConfig/utils/useCommandStatus.js
ElectronClient/gui/KeymapConfig/utils/useKeymap.js
ElectronClient/gui/MainScreen/commands/editAlarm.js
ElectronClient/gui/MainScreen/commands/exportPdf.js
ElectronClient/gui/MainScreen/commands/hideModalMessage.js
ElectronClient/gui/MainScreen/commands/moveToFolder.js
ElectronClient/gui/MainScreen/commands/newFolder.js
ElectronClient/gui/MainScreen/commands/newNote.js
ElectronClient/gui/MainScreen/commands/newTodo.js
ElectronClient/gui/MainScreen/commands/print.js
ElectronClient/gui/MainScreen/commands/renameFolder.js
ElectronClient/gui/MainScreen/commands/renameTag.js
ElectronClient/gui/MainScreen/commands/search.js
ElectronClient/gui/MainScreen/commands/selectTemplate.js
ElectronClient/gui/MainScreen/commands/setTags.js
ElectronClient/gui/MainScreen/commands/showModalMessage.js
ElectronClient/gui/MainScreen/commands/showNoteContentProperties.js
ElectronClient/gui/MainScreen/commands/showNoteProperties.js
ElectronClient/gui/MainScreen/commands/showShareNoteDialog.js
ElectronClient/gui/MainScreen/commands/toggleEditors.js
ElectronClient/gui/MainScreen/commands/toggleNoteList.js
ElectronClient/gui/MainScreen/commands/toggleSideBar.js
ElectronClient/gui/MainScreen/commands/toggleVisiblePanes.js
ElectronClient/gui/MainScreen/MainScreen.js
ElectronClient/gui/MenuBar.js
ElectronClient/gui/MultiNoteActions.js
ElectronClient/gui/NoteContentPropertiesDialog.js
ElectronClient/gui/NoteEditor/commands/editorCommandDeclarations.js
ElectronClient/gui/NoteEditor/commands/focusElementNoteBody.js
ElectronClient/gui/NoteEditor/commands/focusElementNoteTitle.js
ElectronClient/gui/NoteEditor/commands/showLocalSearch.js
ElectronClient/gui/NoteEditor/commands/showRevisions.js
ElectronClient/gui/NoteEditor/NoteBody/CodeMirror/CodeMirror.js
ElectronClient/gui/NoteEditor/NoteBody/CodeMirror/Editor.js
ElectronClient/gui/NoteEditor/NoteBody/CodeMirror/styles/index.js
ElectronClient/gui/NoteEditor/NoteBody/CodeMirror/Toolbar.js
ElectronClient/gui/NoteEditor/NoteBody/CodeMirror/utils/index.js
ElectronClient/gui/NoteEditor/NoteBody/CodeMirror/utils/types.js
ElectronClient/gui/NoteEditor/NoteBody/CodeMirror/utils/useCursorUtils.js
ElectronClient/gui/NoteEditor/NoteBody/CodeMirror/utils/useEditorSearch.js
ElectronClient/gui/NoteEditor/NoteBody/CodeMirror/utils/useJoplinMode.js
ElectronClient/gui/NoteEditor/NoteBody/CodeMirror/utils/useKeymap.js
ElectronClient/gui/NoteEditor/NoteBody/CodeMirror/utils/useLineSorting.js
ElectronClient/gui/NoteEditor/NoteBody/CodeMirror/utils/useListIdent.js
ElectronClient/gui/NoteEditor/NoteBody/CodeMirror/utils/useScrollUtils.js
ElectronClient/gui/NoteEditor/NoteBody/TinyMCE/styles/index.js
ElectronClient/gui/NoteEditor/NoteBody/TinyMCE/TinyMCE.js
ElectronClient/gui/NoteEditor/NoteBody/TinyMCE/utils/useScroll.js
ElectronClient/gui/NoteEditor/NoteEditor.js
ElectronClient/gui/NoteEditor/styles/index.js
ElectronClient/gui/NoteEditor/utils/contextMenu.js
ElectronClient/gui/NoteEditor/utils/index.js
ElectronClient/gui/NoteEditor/utils/resourceHandling.js
ElectronClient/gui/NoteEditor/utils/types.js
ElectronClient/gui/NoteEditor/utils/useDropHandler.js
ElectronClient/gui/NoteEditor/utils/useFolder.js
ElectronClient/gui/NoteEditor/utils/useFormNote.js
ElectronClient/gui/NoteEditor/utils/useMarkupToHtml.js
ElectronClient/gui/NoteEditor/utils/useMessageHandler.js
ElectronClient/gui/NoteEditor/utils/useNoteSearchBar.js
ElectronClient/gui/NoteEditor/utils/usePluginServiceRegistration.js
ElectronClient/gui/NoteEditor/utils/useSearchMarkers.js
ElectronClient/gui/NoteEditor/utils/useWindowCommandHandler.js
ElectronClient/gui/NoteList/commands/focusElementNoteList.js
ElectronClient/gui/NoteList/NoteList.js
ElectronClient/gui/NoteListControls/commands/focusSearch.js
ElectronClient/gui/NoteListControls/NoteListControls.js
ElectronClient/gui/NoteListItem.js
ElectronClient/gui/NoteTextViewer.js
ElectronClient/gui/NoteToolbar/NoteToolbar.js
ElectronClient/gui/OneDriveLoginScreen.js
ElectronClient/gui/ResizableLayout/hooks/useLayoutItemSizes.js
ElectronClient/gui/ResizableLayout/hooks/useWindowResizeEvent.js
ElectronClient/gui/ResizableLayout/ResizableLayout.js
ElectronClient/gui/ResourceScreen.js
ElectronClient/gui/Root_UpgradeSyncTarget.js
ElectronClient/gui/Root.js
ElectronClient/gui/SearchBar/hooks/useSearch.js
ElectronClient/gui/SearchBar/SearchBar.js
ElectronClient/gui/SearchBar/styles/index.js
ElectronClient/gui/ShareNoteDialog.js
ElectronClient/gui/SideBar/commands/focusElementSideBar.js
ElectronClient/gui/SideBar/SideBar.js
ElectronClient/gui/SideBar/styles/index.js
ElectronClient/gui/StatusScreen/StatusScreen.js
ElectronClient/gui/style/StyledInput.js
ElectronClient/gui/style/StyledTextInput.js
ElectronClient/gui/TagList.js
ElectronClient/gui/ToggleEditorsButton/styles/index.js
ElectronClient/gui/ToggleEditorsButton/ToggleEditorsButton.js
ElectronClient/gui/ToolbarBase.js
ElectronClient/gui/ToolbarButton/styles/index.js
ElectronClient/gui/ToolbarButton/ToolbarButton.js
ElectronClient/gui/utils/NoteListUtils.js
ElectronClient/InteropServiceHelper.js
ElectronClient/plugins/GotoAnything.js
ElectronClient/services/bridge.js
ElectronClient/services/commands/types.js
ElectronClient/services/plugins/hooks/useThemeCss.js
ElectronClient/services/plugins/hooks/useViewIsReady.js
ElectronClient/services/plugins/PlatformImplementation.js
ElectronClient/services/plugins/PluginRunner.js
ElectronClient/services/plugins/UserWebview.js
ElectronClient/services/plugins/UserWebviewDialog.js
ElectronClient/services/plugins/UserWebviewDialogButtonBar.js
ReactNativeClient/lib/AsyncActionQueue.js
ReactNativeClient/lib/BaseApplication.js
ReactNativeClient/lib/checkPermissions.js
ReactNativeClient/lib/commands/historyBackward.js
ReactNativeClient/lib/commands/historyForward.js
ReactNativeClient/lib/commands/synchronize.js
ReactNativeClient/lib/components/BackButtonDialogBox.js
ReactNativeClient/lib/components/CameraView.js
ReactNativeClient/lib/components/NoteBodyViewer/hooks/useOnMessage.js
ReactNativeClient/lib/components/NoteBodyViewer/hooks/useOnResourceLongPress.js
ReactNativeClient/lib/components/NoteBodyViewer/hooks/useSource.js
ReactNativeClient/lib/components/NoteBodyViewer/NoteBodyViewer.js
ReactNativeClient/lib/components/screens/Note.js
ReactNativeClient/lib/components/screens/UpgradeSyncTargetScreen.js
ReactNativeClient/lib/components/SelectDateTimeDialog.js
ReactNativeClient/lib/errorUtils.js
ReactNativeClient/lib/eventManager.js
ReactNativeClient/lib/fs-driver-node.js
ReactNativeClient/lib/hooks/useEffectDebugger.js
ReactNativeClient/lib/hooks/useImperativeHandlerDebugger.js
ReactNativeClient/lib/hooks/usePrevious.js
ReactNativeClient/lib/hooks/usePropsDebugger.js
ReactNativeClient/lib/InMemoryCache.js
ReactNativeClient/lib/joplin-renderer/MarkupToHtml.js
ReactNativeClient/lib/joplin-renderer/MdToHtml.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/checkbox.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/code_inline.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/fence.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/fountain.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/highlight_keywords.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/html_image.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/image.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/katex.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/link_open.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/mermaid.js
ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/sanitize_html.js
ReactNativeClient/lib/joplin-renderer/noteStyle.js
ReactNativeClient/lib/joplin-renderer/pathUtils.js
ReactNativeClient/lib/JoplinServerApi.js
ReactNativeClient/lib/locale.js
ReactNativeClient/lib/Logger.js
ReactNativeClient/lib/markdownUtils.js
ReactNativeClient/lib/markupLanguageUtils.js
ReactNativeClient/lib/models/Alarm.js
ReactNativeClient/lib/models/Setting.js
ReactNativeClient/lib/ntpDate.js
ReactNativeClient/lib/path-utils.js
ReactNativeClient/lib/PoorManIntervals.js
ReactNativeClient/lib/reducer.js
ReactNativeClient/lib/services/AlarmService.js
ReactNativeClient/lib/services/AlarmServiceDriver.android.js
ReactNativeClient/lib/services/AlarmServiceDriver.ios.js
ReactNativeClient/lib/services/AlarmServiceDriverNode.js
ReactNativeClient/lib/services/BaseService.js
ReactNativeClient/lib/services/commands/commandsToMarkdownTable.js
ReactNativeClient/lib/services/commands/MenuUtils.js
ReactNativeClient/lib/services/commands/propsHaveChanged.js
ReactNativeClient/lib/services/commands/stateToWhenClauseContext.js
ReactNativeClient/lib/services/commands/ToolbarButtonUtils.js
ReactNativeClient/lib/services/CommandService.js
ReactNativeClient/lib/services/contextkey/contextkey.js
ReactNativeClient/lib/services/debug/populateDatabase.js
ReactNativeClient/lib/services/interop/InteropService_Exporter_Base.js
ReactNativeClient/lib/services/interop/InteropService_Exporter_Custom.js
ReactNativeClient/lib/services/interop/InteropService_Exporter_Html.js
ReactNativeClient/lib/services/interop/InteropService_Exporter_Jex.js
ReactNativeClient/lib/services/interop/InteropService_Exporter_Md.js
ReactNativeClient/lib/services/interop/InteropService_Exporter_Raw.js
ReactNativeClient/lib/services/interop/InteropService_Importer_Base.js
ReactNativeClient/lib/services/interop/InteropService_Importer_Custom.js
ReactNativeClient/lib/services/interop/InteropService_Importer_EnexToHtml.js
ReactNativeClient/lib/services/interop/InteropService_Importer_EnexToMd.js
ReactNativeClient/lib/services/interop/InteropService_Importer_Jex.js
ReactNativeClient/lib/services/interop/InteropService_Importer_Md.js
ReactNativeClient/lib/services/interop/InteropService_Importer_Raw.js
ReactNativeClient/lib/services/interop/InteropService.js
ReactNativeClient/lib/services/interop/types.js
ReactNativeClient/lib/services/keychain/KeychainService.js
ReactNativeClient/lib/services/keychain/KeychainServiceDriver.dummy.js
ReactNativeClient/lib/services/keychain/KeychainServiceDriver.mobile.js
ReactNativeClient/lib/services/keychain/KeychainServiceDriver.node.js
ReactNativeClient/lib/services/keychain/KeychainServiceDriverBase.js
ReactNativeClient/lib/services/KeymapService.js
ReactNativeClient/lib/services/plugins/api/Global.js
ReactNativeClient/lib/services/plugins/api/Joplin.js
ReactNativeClient/lib/services/plugins/api/JoplinCommands.js
ReactNativeClient/lib/services/plugins/api/JoplinData.js
ReactNativeClient/lib/services/plugins/api/JoplinFilters.js
ReactNativeClient/lib/services/plugins/api/JoplinInterop.js
ReactNativeClient/lib/services/plugins/api/JoplinPlugins.js
ReactNativeClient/lib/services/plugins/api/JoplinSettings.js
ReactNativeClient/lib/services/plugins/api/JoplinViews.js
ReactNativeClient/lib/services/plugins/api/JoplinViewsDialogs.js
ReactNativeClient/lib/services/plugins/api/JoplinViewsMenuItems.js
ReactNativeClient/lib/services/plugins/api/JoplinViewsMenus.js
ReactNativeClient/lib/services/plugins/api/JoplinViewsPanels.js
ReactNativeClient/lib/services/plugins/api/JoplinViewsToolbarButtons.js
ReactNativeClient/lib/services/plugins/api/JoplinWorkspace.js
ReactNativeClient/lib/services/plugins/api/types.js
ReactNativeClient/lib/services/plugins/BasePluginRunner.js
ReactNativeClient/lib/services/plugins/MenuController.js
ReactNativeClient/lib/services/plugins/MenuItemController.js
ReactNativeClient/lib/services/plugins/Plugin.js
ReactNativeClient/lib/services/plugins/PluginService.js
ReactNativeClient/lib/services/plugins/reducer.js
ReactNativeClient/lib/services/plugins/sandboxProxy.js
ReactNativeClient/lib/services/plugins/ToolbarButtonController.js
ReactNativeClient/lib/services/plugins/utils/contentScriptsToRendererRules.js
ReactNativeClient/lib/services/plugins/utils/createViewHandle.js
ReactNativeClient/lib/services/plugins/utils/executeSandboxCall.js
ReactNativeClient/lib/services/plugins/utils/manifestFromObject.js
ReactNativeClient/lib/services/plugins/utils/mapEventHandlersToIds.js
ReactNativeClient/lib/services/plugins/utils/types.js
ReactNativeClient/lib/services/plugins/ViewController.js
ReactNativeClient/lib/services/plugins/WebviewController.js
ReactNativeClient/lib/services/ResourceEditWatcher/index.js
ReactNativeClient/lib/services/ResourceEditWatcher/reducer.js
ReactNativeClient/lib/services/rest/actionApi.desktop.js
ReactNativeClient/lib/services/rest/Api.js
ReactNativeClient/lib/services/rest/errors.js
ReactNativeClient/lib/services/searchengine/filterParser.js
ReactNativeClient/lib/services/searchengine/queryBuilder.js
ReactNativeClient/lib/services/SettingUtils.js
ReactNativeClient/lib/services/synchronizer/gui/useSyncTargetUpgrade.js
ReactNativeClient/lib/services/synchronizer/LockHandler.js
ReactNativeClient/lib/services/synchronizer/MigrationHandler.js
ReactNativeClient/lib/services/synchronizer/migrations/1.js
ReactNativeClient/lib/services/synchronizer/migrations/2.js
ReactNativeClient/lib/services/synchronizer/utils/types.js
ReactNativeClient/lib/services/UndoRedoService.js
ReactNativeClient/lib/services/WhenClause.js
ReactNativeClient/lib/ShareExtension.js
ReactNativeClient/lib/shareHandler.js
ReactNativeClient/lib/shim.js
ReactNativeClient/lib/Synchronizer.js
ReactNativeClient/lib/theme.js
ReactNativeClient/lib/themes/aritimDark.js
ReactNativeClient/lib/themes/dark.js
ReactNativeClient/lib/themes/dracula.js
ReactNativeClient/lib/themes/light.js
ReactNativeClient/lib/themes/nord.js
ReactNativeClient/lib/themes/oledDark.js
ReactNativeClient/lib/themes/solarizedDark.js
ReactNativeClient/lib/themes/solarizedLight.js
ReactNativeClient/lib/themes/type.js
ReactNativeClient/lib/uuid.js
ReactNativeClient/lib/versionInfo.js
ReactNativeClient/PluginAssetsLoader.js
ReactNativeClient/setUpQuickActions.js
# AUTO-GENERATED - EXCLUDED TYPESCRIPT BUILD

View File

@@ -8,7 +8,7 @@ const Note = require('lib/models/Note.js');
const Tag = require('lib/models/Tag.js');
const Setting = require('lib/models/Setting').default;
const { reg } = require('lib/registry.js');
const { fileExtension } = require('lib/path-utils.js');
const { fileExtension } = require('lib/path-utils');
const { _ } = require('lib/locale');
const fs = require('fs-extra');
const { cliUtils } = require('./cli-utils.js');

View File

@@ -1,5 +1,5 @@
const fs = require('fs-extra');
const { fileExtension, dirname } = require('lib/path-utils.js');
const { fileExtension, dirname } = require('lib/path-utils');
const wrap_ = require('word-wrap');
const { languageCode } = require('lib/locale');

View File

@@ -2,7 +2,7 @@
const fs = require('fs-extra');
const Logger = require('lib/Logger').default;
const { dirname } = require('lib/path-utils.js');
const { dirname } = require('lib/path-utils');
const { DatabaseDriverNode } = require('lib/database-driver-node.js');
const { JoplinDatabase } = require('lib/joplin-database.js');
const BaseModel = require('lib/BaseModel.js');

View File

@@ -5,7 +5,7 @@ const DecryptionWorker = require('lib/services/DecryptionWorker');
const BaseItem = require('lib/models/BaseItem');
const Setting = require('lib/models/Setting').default;
const shim = require('lib/shim').default;
const pathUtils = require('lib/path-utils.js');
const pathUtils = require('lib/path-utils');
const imageType = require('image-type');
const readChunk = require('read-chunk');

View File

@@ -3,8 +3,8 @@
const { time } = require('lib/time-utils.js');
const Logger = require('lib/Logger').default;
const Resource = require('lib/models/Resource.js');
const { dirname } = require('lib/path-utils.js');
const { FsDriverNode } = require('./fs-driver-node.js');
const { dirname } = require('lib/path-utils');
const FsDriverNode = require('lib/fs-driver-node').default;
const lodash = require('lodash');
const exec = require('child_process').exec;
const fs = require('fs-extra');

View File

@@ -24,7 +24,7 @@ const MasterKey = require('lib/models/MasterKey');
const Setting = require('lib/models/Setting').default;
const Revision = require('lib/models/Revision.js');
const Logger = require('lib/Logger').default;
const { FsDriverNode } = require('lib/fs-driver-node.js');
const FsDriverNode = require('lib/fs-driver-node').default;
const { shimInit } = require('lib/shim-init-node.js');
const { _ } = require('lib/locale');
const { FileApiDriverLocal } = require('lib/file-api-driver-local.js');

File diff suppressed because it is too large Load Diff

View File

@@ -2,25 +2,29 @@
# Copyright (C) 2017 Lucas Vieites
# Copyright (C) 2019 Andros Fenollosa
# Copyright (C) 2019 Germán Martín
# Copyright (C) 2020 Andros Fenollosa
# This file is distributed under the same license as the Joplin-CLI package.
# Lucas Vieites <lucas.vieites@gmail.com>, 2017.
# Andros Fenollosa <andros@fenollosa.email>, 2019.
# Germán Martín <gmag11@gmail.com>, 2019.
# Fernando Pindado <fpindado@gmail.com>, 2020.
# Andros Fenollosa <andros@fenollosa.email>, 2020.
#
msgid ""
msgstr ""
"Project-Id-Version: Joplin-CLI 1.0.0\n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: Fernando Pindado <fpindado@gmail.com>\n"
"Last-Translator: Andros Fenollosa <andros@fenollosa.email>\n"
"Language-Team: Spanish <lucas.vieites@gmail.com>\n"
"Language: es_ES\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Generator: Poedit 2.3\n"
"X-Generator: Poedit 2.4.1\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"X-Poedit-SourceCharset: UTF-8\n"
"POT-Creation-Date: \n"
"PO-Revision-Date: \n"
#: ElectronClient/services/plugins/UserWebviewDialogButtonBar.js:20
#: ElectronClient/checkForUpdates.js:139
@@ -528,12 +532,14 @@ msgstr "Creando nuevo %s..."
#: ElectronClient/gui/NoteEditor/NoteEditor.js:373
msgid "The following attachments are being watched for changes:"
msgstr ""
"Los siguientes adjuntos están siendo vigilados para ver si hay cambios:"
#: ElectronClient/gui/NoteEditor/NoteEditor.js:376
msgid ""
"The attachments will no longer be watched when you switch to a different "
"note."
msgstr ""
"Los archivos adjuntos ya no se verán cuándo cambies a una nota diferente."
#: ElectronClient/gui/NoteEditor/NoteEditor.js:381
#, javascript-format
@@ -649,12 +655,15 @@ msgid ""
"may take a few minutes to complete and the app needs to be restarted. To "
"proceed please click on the link."
msgstr ""
"El objetivo de sincronización necesita ser actualizado antes de que Joplin "
"pueda sincronizarse. La operación puede tardar unos minutos en completarse y "
"la aplicación necesita ser reiniciada. Para proceder, por favor, haz clic en "
"el enlace."
#: ElectronClient/gui/MainScreen/MainScreen.js:416
#: ElectronClient/gui/MainScreen/MainScreen.min.js:306
#, fuzzy
msgid "Restart and upgrade"
msgstr "Claves maestras que necesitan actualización"
msgstr "Reiniciar y actualizar"
#: ElectronClient/gui/MainScreen/MainScreen.js:420
#: ElectronClient/gui/MainScreen/MainScreen.min.js:313
@@ -814,9 +823,8 @@ msgid "Toggle sidebar"
msgstr "Cambia la barra lateral"
#: ElectronClient/gui/MainScreen/commands/toggleEditors.js:17
#, fuzzy
msgid "Toggle editors"
msgstr "Cambia el diseño del editor"
msgstr "Intercambiar editores"
#: ElectronClient/gui/MainScreen/commands/selectTemplate.js:23
msgid "Template file:"
@@ -1321,9 +1329,8 @@ msgid "Import"
msgstr "Importar"
#: ElectronClient/gui/MenuBar.js:343
#, fuzzy
msgid "Export all"
msgstr "Exportar"
msgstr "Exportar todo"
#: ElectronClient/gui/MenuBar.js:356
#, javascript-format
@@ -1404,38 +1411,36 @@ msgstr "Adjuntos"
#: ElectronClient/gui/KeymapConfig/ShortcutRecorder.js:48
msgid "Press the shortcut"
msgstr ""
msgstr "Presiona el atajo"
#: ElectronClient/gui/KeymapConfig/ShortcutRecorder.js:48
msgid ""
"Press the shortcut and then press ENTER. Or, press BACKSPACE to clear the "
"shortcut."
msgstr ""
"Pulse el atajo y luego ENTER. O bien, pulse RETROCESO para borrar el atajo."
#: ElectronClient/gui/KeymapConfig/KeymapConfigScreen.js:62
#: ReactNativeClient/lib/services/KeymapService.js:142
#, fuzzy, javascript-format
#, javascript-format
msgid "Error: %s"
msgstr "Error"
msgstr "Error: %s"
#: ElectronClient/gui/KeymapConfig/KeymapConfigScreen.js:125
msgid "Command"
msgstr ""
msgstr "Comando"
#: ElectronClient/gui/KeymapConfig/KeymapConfigScreen.js:126
#, fuzzy
msgid "Keyboard Shortcut"
msgstr "Modo de teclado"
msgstr "Atajo de teclado"
#: ElectronClient/gui/KeymapConfig/utils/getLabel.js:24
#, fuzzy
msgid "Hide Joplin"
msgstr "Acerca de Joplin"
msgstr "Ocultar Joplin"
#: ElectronClient/gui/KeymapConfig/utils/getLabel.js:28
#, fuzzy
msgid "Preferences"
msgstr "Preferencias..."
msgstr "Preferencias"
#: ElectronClient/gui/NoteContentPropertiesDialog.js:77
msgid "Words"
@@ -1480,6 +1485,8 @@ msgstr "Estadísticas"
msgid ""
"The app is now going to close. Please relaunch it to complete the process."
msgstr ""
"La aplicación se va a cerrar. Por favor, vuelva a iniciarla para completar "
"el proceso."
#: ElectronClient/app.js:340
#, javascript-format
@@ -1491,9 +1498,8 @@ msgid "Exit"
msgstr "Salir"
#: ElectronClient/commands/copyDevCommand.js:17
#, fuzzy
msgid "Copy dev mode command to clipboard"
msgstr "Copiar la ruta en el portapapeles"
msgstr "Copiar el comando del modo de desarrollo al portapapeles"
#: ElectronClient/commands/startExternalEditing.js:18
msgid "Edit in external editor"
@@ -1505,13 +1511,12 @@ msgid "Error opening note in editor: %s"
msgstr "Error abriendo la nota en el editor: %s"
#: ElectronClient/commands/toggleExternalEditing.js:16
#, fuzzy
msgid "Toggle external editing"
msgstr "Detener la edición externa"
msgstr "Intercambiar la edición externa"
#: ElectronClient/commands/toggleExternalEditing.js:42
msgid "Stop"
msgstr ""
msgstr "Parar"
#: ElectronClient/commands/stopExternalEditing.js:16
msgid "Stop external editing"
@@ -1740,7 +1745,7 @@ msgstr ""
#: CliClient/app/command-sync.js:35
msgid "Upgrade the sync target to the latest version."
msgstr ""
msgstr "Actualiza el objetivo de sincronización a la última versión."
#: CliClient/app/command-sync.js:105
#, javascript-format
@@ -2247,10 +2252,10 @@ msgstr ""
"No se puede cargar el módulo «%s» para el formato «%s» y destino \"%s\""
#: ReactNativeClient/lib/services/interop/InteropService.js:152
#, fuzzy, javascript-format
#, javascript-format
msgid "Cannot load \"%s\" module for format \"%s\" and target \"%s\""
msgstr ""
"No se puede cargar el módulo «%s» para el formato «%s» y destino \"%s\""
"No se puede cargar el módulo %s para el formato %s y el objetivo “%s”"
#: ReactNativeClient/lib/services/interop/InteropService.js:187
#, javascript-format
@@ -2267,23 +2272,23 @@ msgstr "Notas restauradas"
#: ReactNativeClient/lib/services/KeymapService.js:236
msgid "command"
msgstr ""
msgstr "comando"
#: ReactNativeClient/lib/services/KeymapService.js:236
#: ReactNativeClient/lib/services/KeymapService.js:241
#, javascript-format
msgid "\"%s\" is missing the required \"%s\" property."
msgstr ""
msgstr "A “%s” le falta la propiedad requerida de “%s”."
#: ReactNativeClient/lib/services/KeymapService.js:241
#: ReactNativeClient/lib/services/KeymapService.js:248
msgid "accelerator"
msgstr ""
msgstr "acelerador"
#: ReactNativeClient/lib/services/KeymapService.js:248
#, fuzzy, javascript-format
#, javascript-format
msgid "Invalid %s: %s."
msgstr "Respuesta inválida: %s"
msgstr "Inválido %s: %s."
#: ReactNativeClient/lib/services/KeymapService.js:266
#, javascript-format
@@ -2291,11 +2296,13 @@ msgid ""
"Accelerator \"%s\" is used for \"%s\" and \"%s\" commands. This may lead to "
"unexpected behaviour."
msgstr ""
"El acelerador “%s” se usa para los comandos “%s” y “%s”. Esto puede llevar a "
"un comportamiento inesperado."
#: ReactNativeClient/lib/services/KeymapService.js:291
#, javascript-format
msgid "Accelerator \"%s\" is not valid."
msgstr ""
msgstr "El acelerador “%s” no es válido."
#: ReactNativeClient/lib/services/report.js:121
msgid "Items that cannot be synchronised"
@@ -2445,7 +2452,7 @@ msgstr "Versión del perfil: %s"
#: ReactNativeClient/lib/versionInfo.js:23
#, javascript-format
msgid "Keychain Supported: %s"
msgstr ""
msgstr "Llavero soportado: %s"
#: ReactNativeClient/lib/JoplinServerApi.js:71
#, javascript-format
@@ -2849,7 +2856,7 @@ msgstr "Añadir título"
#: ReactNativeClient/lib/components/screens/UpgradeSyncTargetScreen.js:42
msgid "Sync Target Upgrade"
msgstr ""
msgstr "Actualización del objetivo de sincronización"
#: ReactNativeClient/lib/components/screens/encryption-config.js:119
#, javascript-format
@@ -2941,6 +2948,8 @@ msgstr ""
#: ReactNativeClient/lib/components/screen-header.js:453
msgid "The sync target needs to be upgraded. Press this banner to proceed."
msgstr ""
"El objetivo de sincronización necesita ser mejorado. Presiona este banner "
"para proceder."
#: ReactNativeClient/lib/components/side-menu-content.js:126
#, javascript-format
@@ -3137,7 +3146,7 @@ msgstr "sí"
#: ReactNativeClient/lib/models/Setting.js:66
#, javascript-format
msgid "(wysiwyg: %s)"
msgstr ""
msgstr "(wysiwyg: %s)"
#: ReactNativeClient/lib/models/Setting.js:66
msgid "no"
@@ -3180,7 +3189,7 @@ msgstr "Nord"
#: ReactNativeClient/lib/models/Setting.js:80
msgid "Aritim Dark"
msgstr ""
msgstr "Aritim Oscuro"
#: ReactNativeClient/lib/models/Setting.js:81
msgid "OLED Dark"
@@ -3229,15 +3238,15 @@ msgstr "Contraseña de WebDAV"
#: ReactNativeClient/lib/models/Setting.js:214
msgid "AWS S3 bucket"
msgstr ""
msgstr "AWS S3 bucket"
#: ReactNativeClient/lib/models/Setting.js:225
msgid "AWS key"
msgstr ""
msgstr "AWS key"
#: ReactNativeClient/lib/models/Setting.js:235
msgid "AWS secret"
msgstr ""
msgstr "AWS secret"
#: ReactNativeClient/lib/models/Setting.js:247
msgid "Attachment download behaviour"
@@ -3695,9 +3704,8 @@ msgid "Web Clipper"
msgstr "Web Clipper"
#: ReactNativeClient/lib/models/Setting.js:1292
#, fuzzy
msgid "Keyboard Shortcuts"
msgstr "Modo de teclado"
msgstr "Atajos de teclado"
#: ReactNativeClient/lib/models/Setting.js:1299
msgid ""
@@ -3744,7 +3752,7 @@ msgstr "OneDrive"
#: ReactNativeClient/lib/SyncTargetAmazonS3.js:28
msgid "AWS S3"
msgstr ""
msgstr "AWS S3"
#: ReactNativeClient/lib/commands/historyForward.js:16
msgid "Forward"

View File

@@ -7,14 +7,16 @@ msgid ""
msgstr ""
"Project-Id-Version: Joplin-CLI 1.0.0\n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: StarFang208\n"
"Last-Translator: Alessandro Bernardello <mailfilledwithspam@gmail.com>\n"
"Language-Team: \n"
"Language: it\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Generator: Poedit 2.3\n"
"X-Generator: Poedit 2.4.1\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"POT-Creation-Date: \n"
"PO-Revision-Date: \n"
#: ElectronClient/services/plugins/UserWebviewDialogButtonBar.js:20
#: ElectronClient/checkForUpdates.js:139
@@ -117,9 +119,9 @@ msgid "Exporting to \"%s\" as \"%s\" format. Please wait..."
msgstr "Esportazione da \"%s\" come formato \"%s\". Si prega di attendere..."
#: ElectronClient/InteropServiceHelper.js:170
#, fuzzy, javascript-format
#, javascript-format
msgid "Could not export notes: %s"
msgstr "Non è possibile aggiornare la chiave master: %s"
msgstr "Non è possibile esportare le note: %s"
#: ElectronClient/plugins/GotoAnything.min.js:459
msgid ""
@@ -425,11 +427,11 @@ msgstr "Allega File"
#: ElectronClient/gui/NoteEditor/NoteBody/TinyMCE/TinyMCE.js:584
msgid "Code Block"
msgstr ""
msgstr "Blocco di codice"
#: ElectronClient/gui/NoteEditor/NoteBody/TinyMCE/TinyMCE.js:593
msgid "Inline Code"
msgstr ""
msgstr "Codice inline"
#: ElectronClient/gui/NoteEditor/NoteBody/TinyMCE/TinyMCE.js:608
#: ElectronClient/gui/NoteEditor/commands/editorCommandDeclarations.js:83
@@ -438,11 +440,10 @@ msgstr "Inserisci data e ora"
#: ElectronClient/gui/NoteEditor/NoteBody/TinyMCE/TinyMCE.js:1030
msgid "Drop notes or files here"
msgstr ""
msgstr "Trascina qui note o file"
#: ElectronClient/gui/NoteEditor/NoteBody/TinyMCE/TinyMCE.js:1030
#: ElectronClient/gui/MainScreen/MainScreen.min.js:419
#, fuzzy
msgid "Code View"
msgstr "Codice"
@@ -452,20 +453,20 @@ msgid ""
"Please wait for all attachments to be downloaded and decrypted. You may also "
"switch to %s to edit the note."
msgstr ""
"Attendi che tutti gli allegati vengano scaricati e decrittografati. Puoi "
"anche passare a %s per modificare la nota."
#: ElectronClient/gui/NoteEditor/NoteBody/TinyMCE/plugins/lists.js:2151
#, fuzzy
msgid "Checkbox list"
msgstr "Casella di controllo"
msgstr "Lista di caselle di spunta"
#: ElectronClient/gui/NoteEditor/NoteBody/CodeMirror/CodeMirror.js:165
msgid "strong text"
msgstr "testo grasseto"
msgstr "testo in grassetto"
#: ElectronClient/gui/NoteEditor/NoteBody/CodeMirror/CodeMirror.js:166
#, fuzzy
msgid "emphasised text"
msgstr "testo Sottolineato"
msgstr "testo sottolineato"
#: ElectronClient/gui/NoteEditor/NoteBody/CodeMirror/CodeMirror.js:168
msgid "Insert Hyperlink"
@@ -511,7 +512,7 @@ msgstr ""
#: ElectronClient/gui/NoteEditor/NoteEditor.js:292
msgid "to-do"
msgstr "\"Cose-da-fare\""
msgstr "attività"
#: ElectronClient/gui/NoteEditor/NoteEditor.js:292
msgid "note"
@@ -524,13 +525,15 @@ msgstr "Creare nuovo %s..."
#: ElectronClient/gui/NoteEditor/NoteEditor.js:373
msgid "The following attachments are being watched for changes:"
msgstr ""
msgstr "I seguenti allegati sono monitorati per eventuali modifiche:"
#: ElectronClient/gui/NoteEditor/NoteEditor.js:376
msgid ""
"The attachments will no longer be watched when you switch to a different "
"note."
msgstr ""
"Gli allegati non verranno più monitorati quando passerai ad una nota "
"differente."
#: ElectronClient/gui/NoteEditor/NoteEditor.js:381
#, javascript-format
@@ -547,7 +550,7 @@ msgstr "Salva come..."
#: ElectronClient/gui/NoteEditor/utils/contextMenu.js:65
msgid "Reveal file in folder"
msgstr ""
msgstr "Visualizza file nella cartella"
#: ElectronClient/gui/NoteEditor/utils/contextMenu.js:73
msgid "Copy path to clipboard"
@@ -590,7 +593,7 @@ msgstr "Seleziona tutto"
#: ElectronClient/gui/NoteEditor/commands/editorCommandDeclarations.js:33
msgid "Bold"
msgstr "Grasseto"
msgstr "Grassetto"
#: ElectronClient/gui/NoteEditor/commands/editorCommandDeclarations.js:38
msgid "Italic"
@@ -648,12 +651,14 @@ msgid ""
"may take a few minutes to complete and the app needs to be restarted. To "
"proceed please click on the link."
msgstr ""
"La destinazione di sincronizzazione deve essere aggiornata prima che Joplin "
"possa eseguire la sincronizzazione. L'operazione può richiedere alcuni "
"minuti ed è necessario riavviare l'app. Per procedere clicca sul link."
#: ElectronClient/gui/MainScreen/MainScreen.js:416
#: ElectronClient/gui/MainScreen/MainScreen.min.js:306
#, fuzzy
msgid "Restart and upgrade"
msgstr "Chiavi master che devono essere aggiornate"
msgstr "Aggiorna e riavvia"
#: ElectronClient/gui/MainScreen/MainScreen.js:420
#: ElectronClient/gui/MainScreen/MainScreen.min.js:313
@@ -790,7 +795,7 @@ msgstr "PDF File"
#: ElectronClient/gui/MainScreen/commands/toggleVisiblePanes.js:15
msgid "Toggle editor layout"
msgstr "Attiva / disattiva il layout dell'editor"
msgstr "Cambia il layout dell'editor"
#: ElectronClient/gui/MainScreen/commands/print.js:16
msgid "Print"
@@ -813,17 +818,16 @@ msgid "Toggle sidebar"
msgstr "Attiva / disattiva barra laterale"
#: ElectronClient/gui/MainScreen/commands/toggleEditors.js:17
#, fuzzy
msgid "Toggle editors"
msgstr "Attiva / disattiva il layout dell'editor"
msgstr "Attiva / disattiva editor"
#: ElectronClient/gui/MainScreen/commands/selectTemplate.js:23
msgid "Template file:"
msgstr "File del modello:"
msgstr "File modello:"
#: ElectronClient/gui/MainScreen/commands/showNoteContentProperties.js:16
msgid "Statistics..."
msgstr ""
msgstr "Statistiche..."
#: ElectronClient/gui/EncryptionConfigScreen.min.js:96
#: ElectronClient/gui/KeymapConfig/ShortcutRecorder.js:49
@@ -1144,13 +1148,12 @@ msgstr ""
#: ElectronClient/gui/NoteList/NoteList.min.js:151
#: ElectronClient/gui/NoteList/NoteList.js:160
msgid "Custom order"
msgstr ""
msgstr "Ordine personalizzato"
#: ElectronClient/gui/NoteList/NoteList.min.js:151
#: ElectronClient/gui/NoteList/NoteList.js:160
#, fuzzy
msgid "View"
msgstr "&Vista"
msgstr "Vedi"
#: ElectronClient/gui/NoteList/NoteList.min.js:151
#: ElectronClient/gui/NoteList/NoteList.js:160
@@ -1165,12 +1168,13 @@ msgid ""
"To manually sort the notes, the sort order must be changed to \"%s\" in the "
"menu \"%s\" > \"%s\""
msgstr ""
"Per ordinare le note con un ordine personalizzato il criterio di ordinamento "
"deve essere impostato in \"%s\" nel menù \"%s\" > \"%s\""
#: ElectronClient/gui/NoteList/NoteList.min.js:152
#: ElectronClient/gui/NoteList/NoteList.js:161
#, fuzzy
msgid "Do it now"
msgstr "Scaricalo subito:"
msgstr "Fallo subito"
#: ElectronClient/gui/NoteList/NoteList.min.js:423
#: ElectronClient/gui/NoteList/NoteList.js:412
@@ -1317,9 +1321,8 @@ msgid "Import"
msgstr "Importa"
#: ElectronClient/gui/MenuBar.js:343
#, fuzzy
msgid "Export all"
msgstr "Esporta"
msgstr "Esporta tutto"
#: ElectronClient/gui/MenuBar.js:356
#, javascript-format
@@ -1357,9 +1360,8 @@ msgid "Zoom Out"
msgstr "Diminuisci zoom"
#: ElectronClient/gui/MenuBar.js:516
#, fuzzy
msgid "&Note"
msgstr "Nota"
msgstr "&Note"
#: ElectronClient/gui/MenuBar.js:525
msgid "&Tools"
@@ -1401,38 +1403,37 @@ msgstr "Allegati"
#: ElectronClient/gui/KeymapConfig/ShortcutRecorder.js:48
msgid "Press the shortcut"
msgstr ""
msgstr "Premi il tasto da associare alla scorciatoia"
#: ElectronClient/gui/KeymapConfig/ShortcutRecorder.js:48
msgid ""
"Press the shortcut and then press ENTER. Or, press BACKSPACE to clear the "
"shortcut."
msgstr ""
"Premi il collegamento e poi premi INVIO oppure premi BACKSPACE per eliminare "
"il collegamento."
#: ElectronClient/gui/KeymapConfig/KeymapConfigScreen.js:62
#: ReactNativeClient/lib/services/KeymapService.js:142
#, fuzzy, javascript-format
#, javascript-format
msgid "Error: %s"
msgstr "Errore"
msgstr "Errore %s"
#: ElectronClient/gui/KeymapConfig/KeymapConfigScreen.js:125
msgid "Command"
msgstr ""
msgstr "Comando"
#: ElectronClient/gui/KeymapConfig/KeymapConfigScreen.js:126
#, fuzzy
msgid "Keyboard Shortcut"
msgstr "Modalità Tastiera"
msgstr "Scorciatoie da tastiera"
#: ElectronClient/gui/KeymapConfig/utils/getLabel.js:24
#, fuzzy
msgid "Hide Joplin"
msgstr "Informazione su Joplin"
msgstr "Nascondi Joplin"
#: ElectronClient/gui/KeymapConfig/utils/getLabel.js:28
#, fuzzy
msgid "Preferences"
msgstr "Preferenze..."
msgstr "Preferenze"
#: ElectronClient/gui/NoteContentPropertiesDialog.js:77
msgid "Words"
@@ -1467,17 +1468,17 @@ msgstr "Visualizzatore"
#: ElectronClient/gui/NoteContentPropertiesDialog.js:106
#, javascript-format
msgid "Read time: %s min"
msgstr ""
msgstr "Tempo di lettura: %s min"
#: ElectronClient/gui/NoteContentPropertiesDialog.js:109
#, fuzzy
msgid "Statistics"
msgstr "Stato"
msgstr "Statistiche"
#: ElectronClient/bridge.js:177
msgid ""
"The app is now going to close. Please relaunch it to complete the process."
msgstr ""
"Ora l'applicazione si chiuderà. Premi rilancia per completare il processo."
#: ElectronClient/app.js:340
#, javascript-format
@@ -1489,9 +1490,8 @@ msgid "Exit"
msgstr "Esci"
#: ElectronClient/commands/copyDevCommand.js:17
#, fuzzy
msgid "Copy dev mode command to clipboard"
msgstr "Copia il percorso negli appunti"
msgstr "Copia il comando della modalità sviluppatore negli appunti"
#: ElectronClient/commands/startExternalEditing.js:18
msgid "Edit in external editor"
@@ -1503,13 +1503,12 @@ msgid "Error opening note in editor: %s"
msgstr "Errore durante l'apertura della nota nell'editor: %s"
#: ElectronClient/commands/toggleExternalEditing.js:16
#, fuzzy
msgid "Toggle external editing"
msgstr "Interrompi modifiche esterne"
msgstr "Disattiva l'editing esterno"
#: ElectronClient/commands/toggleExternalEditing.js:42
msgid "Stop"
msgstr ""
msgstr "Stop"
#: ElectronClient/commands/stopExternalEditing.js:16
msgid "Stop external editing"
@@ -1738,7 +1737,7 @@ msgstr ""
#: CliClient/app/command-sync.js:35
msgid "Upgrade the sync target to the latest version."
msgstr ""
msgstr "Aggiorna la destinazione di sincronizzazione all'ultima versione."
#: CliClient/app/command-sync.js:105
#, javascript-format
@@ -1747,7 +1746,7 @@ msgstr "Non autenticato con %s. Si prega di fornire le credenziali mancanti."
#: CliClient/app/command-sync.js:128
msgid "Synchronisation is already in progress."
msgstr "La sincronizzazione è in corso."
msgstr "La sincronizzazione è già in corso."
#: CliClient/app/command-sync.js:133
#, javascript-format
@@ -1766,9 +1765,8 @@ msgid "Synchronisation target: %s (%s)"
msgstr "Posizione di sincronizzazione: %s (%s)"
#: CliClient/app/command-sync.js:177
#, fuzzy
msgid "Cannot initialise synchroniser."
msgstr "Non è possibile inizializzare il sincronizzatore."
msgstr "Non è possibile inizializzare la sincronizzazione."
#: CliClient/app/command-sync.js:207
msgid "Starting synchronisation..."
@@ -1802,9 +1800,9 @@ msgid ""
"convert the to-do back to a regular note."
msgstr ""
"<todo-command> può essere \"toggle\" or \"clear\". Usa \"toggle\" per "
"modifica lo stato di \"Cose-da-fare\" in completato/non completato (se "
"l'oggetto è una normale nota, questa verrà convertita in un \"Cose-da-fare"
"\"). Usa \"clear\" convertire i \"Cose-da-fare\" in normali note."
"modificare lo stato di un'attività in completato/non completato (se viene "
"utilizzato su una nota la nota verrà convertita in un'attività). Usa \"clear"
"\" convertire le attività in normali note."
#: CliClient/app/command-cat.js:14
msgid "Displays the given note."
@@ -1956,14 +1954,16 @@ msgstr ""
"per la decriptazione."
#: CliClient/app/command-e2ee.js:53
#, fuzzy, javascript-format
#, javascript-format
msgid "Decrypted items: %d"
msgstr "Elementi decriptati: %s / %s"
msgstr "Elementi decriptati: %d"
#: CliClient/app/command-e2ee.js:54
#, javascript-format
msgid "Skipped items: %d (use --retry-failed-items to retry decrypting them)"
msgstr ""
"Elementi saltati: %d (utilizza --retry-failed-items per riprovare a "
"decrittografarli)"
#: CliClient/app/command-e2ee.js:68
msgid "Completed decryption."
@@ -2012,9 +2012,9 @@ msgid "Do not ask for confirmation."
msgstr "Non chiedere conferma."
#: CliClient/app/command-import.js:27
#, fuzzy, javascript-format
#, javascript-format
msgid "Output format: %s"
msgstr "Formato sorgente: %s"
msgstr "Formato di esportazione: %s"
#: CliClient/app/command-import.js:65
msgid "Importing notes..."
@@ -2239,14 +2239,19 @@ msgid "HTML Directory"
msgstr "Cartella HTML"
#: ReactNativeClient/lib/services/interop/InteropService.js:127
#, fuzzy, javascript-format
#, javascript-format
msgid "Cannot load \"%s\" module for format \"%s\" and output \"%s\""
msgstr "Impossibile caricare il modulo \"%s\" per il formato \"%s\""
msgstr ""
"Impossibile caricare il modulo \"%s\" per il formato \"%s\" e per l'output "
"\"%s\""
# Target potrebbe significare destinazione
#: ReactNativeClient/lib/services/interop/InteropService.js:152
#, fuzzy, javascript-format
#, javascript-format
msgid "Cannot load \"%s\" module for format \"%s\" and target \"%s\""
msgstr "Impossibile caricare il modulo \"%s\" per il formato \"%s\""
msgstr ""
"Impossibile caricare il modulo \"%s\" per il formato \"%s\" e per il target "
"\"%s\""
#: ReactNativeClient/lib/services/interop/InteropService.js:187
#, javascript-format
@@ -2263,35 +2268,40 @@ msgstr "Ripristina note"
#: ReactNativeClient/lib/services/KeymapService.js:236
msgid "command"
msgstr ""
msgstr "comando"
#: ReactNativeClient/lib/services/KeymapService.js:236
#: ReactNativeClient/lib/services/KeymapService.js:241
#, javascript-format
msgid "\"%s\" is missing the required \"%s\" property."
msgstr ""
msgstr "A \"% s\" manca la proprietà \"% s\" richiesta."
# Non è chiaro cosa sia un accelerator senza contesto, non lo trovo nell'applicazione e non credo sia corretto tradurlo con acceleratore
#: ReactNativeClient/lib/services/KeymapService.js:241
#: ReactNativeClient/lib/services/KeymapService.js:248
#, fuzzy
msgid "accelerator"
msgstr ""
msgstr "accelerator"
#: ReactNativeClient/lib/services/KeymapService.js:248
#, fuzzy, javascript-format
msgid "Invalid %s: %s."
msgstr "Risposta non valida: %s"
#: ReactNativeClient/lib/services/KeymapService.js:266
#, javascript-format
msgid "Invalid %s: %s."
msgstr "%s non valido: %s."
# Non è chiaro cosa sia un accelerator senza contesto, non lo trovo nell'applicazione e non credo sia corretto tradurlo con acceleratore
#: ReactNativeClient/lib/services/KeymapService.js:266
#, fuzzy, javascript-format
msgid ""
"Accelerator \"%s\" is used for \"%s\" and \"%s\" commands. This may lead to "
"unexpected behaviour."
msgstr ""
"L'accelerator \"%s\" è utilizzato per i comandi \"%s\" e \"%s\". Questo "
"potrebbe portare a comportamenti inaspettati."
#: ReactNativeClient/lib/services/KeymapService.js:291
#, javascript-format
msgid "Accelerator \"%s\" is not valid."
msgstr ""
msgstr "L'accelerator \"%s\" non è valido."
#: ReactNativeClient/lib/services/report.js:121
msgid "Items that cannot be synchronised"
@@ -2441,7 +2451,7 @@ msgstr "Profilo versione: %s"
#: ReactNativeClient/lib/versionInfo.js:23
#, javascript-format
msgid "Keychain Supported: %s"
msgstr ""
msgstr "Portachiavi supportato: %s"
#: ReactNativeClient/lib/JoplinServerApi.js:71
#, javascript-format
@@ -2845,7 +2855,7 @@ msgstr "Aggiungi titolo"
#: ReactNativeClient/lib/components/screens/UpgradeSyncTargetScreen.js:42
msgid "Sync Target Upgrade"
msgstr ""
msgstr "Aggiorna la destinazione di sincronizzazione"
#: ReactNativeClient/lib/components/screens/encryption-config.js:119
#, javascript-format
@@ -2927,7 +2937,7 @@ msgstr "Spostare le note %d sul Taccuino \"%s\"?"
#: ReactNativeClient/lib/components/screen-header.js:451
msgid "Press to set the decryption password."
msgstr "Premere per impostare la password di decrittografia."
msgstr "Premi qui per impostare la password di decrittografia."
#: ReactNativeClient/lib/components/screen-header.js:452
msgid "Some items cannot be synchronised. Press for more info."
@@ -2938,6 +2948,8 @@ msgstr ""
#: ReactNativeClient/lib/components/screen-header.js:453
msgid "The sync target needs to be upgraded. Press this banner to proceed."
msgstr ""
"La destinazione di sincronizzazione deve essere aggiornata. Premi questo "
"banner per procedere."
#: ReactNativeClient/lib/components/side-menu-content.js:126
#, javascript-format
@@ -3082,17 +3094,20 @@ msgid "Downloaded"
msgstr "Scaricato"
#: ReactNativeClient/lib/models/Resource.js:371
#, fuzzy, javascript-format
#, javascript-format
msgid "Attachment conflict: \"%s\""
msgstr "Allegati"
msgstr "Conflitto tra gli allegati: \"%s\""
#: ReactNativeClient/lib/models/Resource.js:372
#, fuzzy, javascript-format
#, javascript-format
msgid ""
"There was a [conflict](%s) on the attachment below.\n"
"\n"
"%s"
msgstr "Errore nel scaricare questo allegato:"
msgstr ""
"Si è verificato un [conflitto](%s) nel seguente allegato.\n"
"\n"
"%s"
#: ReactNativeClient/lib/models/BaseItem.js:721
msgid "Encrypted"
@@ -3108,7 +3123,7 @@ msgstr "data di creazione"
#: ReactNativeClient/lib/models/Note.js:28
msgid "custom order"
msgstr ""
msgstr "ordine personalizzato"
#: ReactNativeClient/lib/models/Note.js:92
msgid "This note does not have geolocation information."
@@ -3223,15 +3238,15 @@ msgstr "Password WebDAV"
#: ReactNativeClient/lib/models/Setting.js:214
msgid "AWS S3 bucket"
msgstr ""
msgstr "Bucket AWS S3"
#: ReactNativeClient/lib/models/Setting.js:225
msgid "AWS key"
msgstr ""
msgstr "Chiave AWS"
#: ReactNativeClient/lib/models/Setting.js:235
msgid "AWS secret"
msgstr ""
msgstr "Secret AWS"
#: ReactNativeClient/lib/models/Setting.js:247
msgid "Attachment download behaviour"
@@ -3281,15 +3296,15 @@ msgstr "Tema"
#: ReactNativeClient/lib/models/Setting.js:337
msgid "Automatically switch theme to match system theme"
msgstr ""
msgstr "Usa il tema di sistema"
#: ReactNativeClient/lib/models/Setting.js:348
msgid "Preferred light theme"
msgstr ""
msgstr "Preferisci il tema chiaro"
#: ReactNativeClient/lib/models/Setting.js:361
msgid "Preferred dark theme"
msgstr ""
msgstr "Preferisci il tema scuro"
#: ReactNativeClient/lib/models/Setting.js:365
msgid "Show note counts"
@@ -3451,13 +3466,12 @@ msgid "Editor font family"
msgstr "Editor famiglia caratteri"
#: ReactNativeClient/lib/models/Setting.js:556
#, fuzzy
msgid ""
"This should be a *monospace* font or some elements will render incorrectly. "
"If the font is incorrect or empty, it will default to a generic monospace "
"font."
msgstr ""
"Questo carattere deve essere * monospace * o non funzionerà correttamente. "
"Questo carattere deve essere * monospazio* o non funzionerà correttamente. "
"Se il carattere è errato o vuoto, verrà impostato automaticamente su un "
"carattere generico monospace."
@@ -3629,7 +3643,7 @@ msgstr "Mantieni la cronologia note per"
#: ReactNativeClient/lib/models/Setting.js:735
msgid "Notebook list growth factor"
msgstr ""
msgstr "Fattore di crescita del taccuino"
#: ReactNativeClient/lib/models/Setting.js:736
#: ReactNativeClient/lib/models/Setting.js:748
@@ -3640,14 +3654,20 @@ msgid ""
"item with a factor of 2 will take twice as much space as an item with a "
"factor of 1.Restart app to see changes."
msgstr ""
"Il fattore di crescita indica la crescita o il restringersi di un oggetto "
"rispetto agli altri oggetti per adattarsi allo spazio disponibile nel "
"contenitore. Un oggetto con un fattore 2 occuperà il doppio dello spazio "
"rispetto ad un elemento con un fattore di 1. Riavvia il programma per vedere "
"le modifiche."
#: ReactNativeClient/lib/models/Setting.js:747
msgid "Note list growth factor"
msgstr ""
msgstr "Fattore di crescita delle note"
#: ReactNativeClient/lib/models/Setting.js:759
#, fuzzy
msgid "Note area growth factor"
msgstr ""
msgstr "Fattore di crescita dell'area delle note"
#: ReactNativeClient/lib/models/Setting.js:1272
msgid "General"
@@ -3682,9 +3702,8 @@ msgid "Web Clipper"
msgstr "Web Clipper"
#: ReactNativeClient/lib/models/Setting.js:1292
#, fuzzy
msgid "Keyboard Shortcuts"
msgstr "Modalità Tastiera"
msgstr "Scorciatoie da tastiera"
#: ReactNativeClient/lib/models/Setting.js:1299
msgid ""
@@ -3731,11 +3750,11 @@ msgstr "OneDrive"
#: ReactNativeClient/lib/SyncTargetAmazonS3.js:28
msgid "AWS S3"
msgstr ""
msgstr "AWS S3"
#: ReactNativeClient/lib/commands/historyForward.js:16
msgid "Forward"
msgstr ""
msgstr "Invia"
#: ReactNativeClient/lib/shim-init-node.js:158
#, javascript-format

View File

@@ -7,14 +7,16 @@ msgid ""
msgstr ""
"Project-Id-Version: Joplin-CLI 1.0.0\n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: Diogo Caveiro \n"
"Last-Translator: João Duarte <jduar@protonmail.com>\n"
"Language-Team: \n"
"Language: pt_PT\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"X-Generator: Poedit 2.2.4\n"
"X-Generator: Poedit 2.4.1\n"
"POT-Creation-Date: \n"
"PO-Revision-Date: \n"
#: ElectronClient/services/plugins/UserWebviewDialogButtonBar.js:20
#: ElectronClient/checkForUpdates.js:139
@@ -112,29 +114,28 @@ msgid "Full Release Notes"
msgstr "Notas de Lançamento Completas"
#: ElectronClient/InteropServiceHelper.js:153
#, fuzzy, javascript-format
#, javascript-format
msgid "Exporting to \"%s\" as \"%s\" format. Please wait..."
msgstr "A importar de \"%s\" com o formato \"%s\". Por favor, aguarde..."
msgstr "A exportar para \"%s\" com o formato \"%s\". Por favor, aguarde..."
#: ElectronClient/InteropServiceHelper.js:170
#, fuzzy, javascript-format
#, javascript-format
msgid "Could not export notes: %s"
msgstr "Não foi possível atualizar a chave mestra: %s"
msgstr "Não foi possível exportar as notas: %s"
#: ElectronClient/plugins/GotoAnything.min.js:459
#, fuzzy
msgid ""
"Type a note title or part of its content to jump to it. Or type # followed "
"by a tag name, or @ followed by a notebook name."
msgstr ""
"Digite um título de nota para avançar para o mesmo. Ou digite # seguido do "
"título de uma etiqueta, ou @ seguido do nome de um bloco de notas, ou / "
"seguido do conteúdo da nota."
"Escreva um título de uma nota ou parte do seu conteúdo para saltar para o "
"mesmo. Ou digite # seguido de um nome de etiqueta, ou @ seguido de um nome "
"de um caderno."
#: ElectronClient/plugins/GotoAnything.min.js:499
#: ElectronClient/gui/KeymapConfig/utils/getLabel.js:20
msgid "Goto Anything..."
msgstr "Ir até qualquer coisa..."
msgstr "Saltar para..."
#: ElectronClient/gui/NoteListControls/commands/focusSearch.js:15
msgid "Search in all the notes"
@@ -178,9 +179,9 @@ msgid "Delete"
msgstr "Eliminar"
#: ElectronClient/gui/ResourceScreen.js:94
#, fuzzy, javascript-format
#, javascript-format
msgid "Delete attachment \"%s\"?"
msgstr "Eliminar nota \"%s\"?"
msgstr "Eliminar anexo \"%s\"?"
#: ElectronClient/gui/ResourceScreen.js:140
msgid ""
@@ -188,6 +189,9 @@ msgid ""
"notes. Please be careful when deleting one of them as they cannot be "
"restored afterwards."
msgstr ""
"Esta é uma ferramenta avançada para ver os anexos que estão ligados às suas "
"notas. Por favor tenha cuidado ao apagar um deles já que não poderão ser "
"repostos de seguida."
#: ElectronClient/gui/ResourceScreen.js:141
msgid "Please wait..."
@@ -195,13 +199,13 @@ msgstr "Por favor, aguarde..."
#: ElectronClient/gui/ResourceScreen.js:143
msgid "No resources!"
msgstr "Sem fontes!"
msgstr "Sem recursos!"
#: ElectronClient/gui/ResourceScreen.js:145
#, javascript-format
msgid "Warning: not all resources shown for performance reasons (limit: %s)."
msgstr ""
"Aviso: nem todas as fontes apresentadas por razões de desempenho (limite: "
"Aviso: nem todos os recursos apresentadas por razões de desempenho (limite: "
"%s)."
#: ElectronClient/gui/PromptDialog.min.js:249
@@ -427,11 +431,11 @@ msgstr "Anexar ficheiro"
#: ElectronClient/gui/NoteEditor/NoteBody/TinyMCE/TinyMCE.js:584
msgid "Code Block"
msgstr ""
msgstr "Bloco de Código"
#: ElectronClient/gui/NoteEditor/NoteBody/TinyMCE/TinyMCE.js:593
msgid "Inline Code"
msgstr ""
msgstr "Código em Linha"
#: ElectronClient/gui/NoteEditor/NoteBody/TinyMCE/TinyMCE.js:608
#: ElectronClient/gui/NoteEditor/commands/editorCommandDeclarations.js:83
@@ -440,13 +444,12 @@ msgstr "Inserir Data e Hora"
#: ElectronClient/gui/NoteEditor/NoteBody/TinyMCE/TinyMCE.js:1030
msgid "Drop notes or files here"
msgstr ""
msgstr "Insira notas ou ficheiros aqui"
#: ElectronClient/gui/NoteEditor/NoteBody/TinyMCE/TinyMCE.js:1030
#: ElectronClient/gui/MainScreen/MainScreen.min.js:419
#, fuzzy
msgid "Code View"
msgstr "Código"
msgstr "Vista de Código"
#: ElectronClient/gui/NoteEditor/NoteBody/TinyMCE/TinyMCE.js:1030
#, javascript-format
@@ -454,18 +457,18 @@ msgid ""
"Please wait for all attachments to be downloaded and decrypted. You may also "
"switch to %s to edit the note."
msgstr ""
"Por favor espere que todos os anexados sejam transferidos e desencriptados. "
"Também pode mudar para %s para editar a nota."
#: ElectronClient/gui/NoteEditor/NoteBody/TinyMCE/plugins/lists.js:2151
#, fuzzy
msgid "Checkbox list"
msgstr "Campo de seleção"
msgstr "Lista de caixas de seleção"
#: ElectronClient/gui/NoteEditor/NoteBody/CodeMirror/CodeMirror.js:165
msgid "strong text"
msgstr "texto destacado"
#: ElectronClient/gui/NoteEditor/NoteBody/CodeMirror/CodeMirror.js:166
#, fuzzy
msgid "emphasised text"
msgstr "texto realçado"
@@ -526,13 +529,14 @@ msgstr "A criar novo/a %s..."
#: ElectronClient/gui/NoteEditor/NoteEditor.js:373
msgid "The following attachments are being watched for changes:"
msgstr ""
msgstr "Os anexos seguintes estão a ser monitorizados quanto a alterações:"
#: ElectronClient/gui/NoteEditor/NoteEditor.js:376
msgid ""
"The attachments will no longer be watched when you switch to a different "
"note."
msgstr ""
"Os anexos deixarão de ser monitorizados quando mudar para uma nota diferente."
#: ElectronClient/gui/NoteEditor/NoteEditor.js:381
#, javascript-format
@@ -549,7 +553,7 @@ msgstr "Guardar como..."
#: ElectronClient/gui/NoteEditor/utils/contextMenu.js:65
msgid "Reveal file in folder"
msgstr ""
msgstr "Revelar arquivo na pasta"
#: ElectronClient/gui/NoteEditor/utils/contextMenu.js:73
msgid "Copy path to clipboard"
@@ -649,12 +653,15 @@ msgid ""
"may take a few minutes to complete and the app needs to be restarted. To "
"proceed please click on the link."
msgstr ""
"O alvo de sincronização deve ser atualizado antes que o Joplin possa "
"sincronizar. A operação pode demorar alguns minutos a ser completa e a "
"aplicação precisará de ser reiniciada. Para proceder, por favor clique na "
"ligação."
#: ElectronClient/gui/MainScreen/MainScreen.js:416
#: ElectronClient/gui/MainScreen/MainScreen.min.js:306
#, fuzzy
msgid "Restart and upgrade"
msgstr "Chaves mestras que necessitam de atualização"
msgstr "Reiniciar e atualizar"
#: ElectronClient/gui/MainScreen/MainScreen.js:420
#: ElectronClient/gui/MainScreen/MainScreen.min.js:313
@@ -712,11 +719,11 @@ msgstr "Procurar..."
#: ElectronClient/gui/MainScreen/commands/moveToFolder.js:17
msgid "Move to notebook"
msgstr "Mudar para o bloco de notas"
msgstr "Mudar para o caderno"
#: ElectronClient/gui/MainScreen/commands/moveToFolder.js:36
msgid "Move to notebook:"
msgstr "Mudar para o bloco de notas:"
msgstr "Mudar para o caderno:"
#: ElectronClient/gui/MainScreen/commands/setTags.js:16
#: ElectronClient/gui/SideBar/SideBar.js:426
@@ -814,9 +821,8 @@ msgid "Toggle sidebar"
msgstr "Alternar a barra lateral"
#: ElectronClient/gui/MainScreen/commands/toggleEditors.js:17
#, fuzzy
msgid "Toggle editors"
msgstr "Alternar a estrutura do editor"
msgstr "Alternar editores"
#: ElectronClient/gui/MainScreen/commands/selectTemplate.js:23
msgid "Template file:"
@@ -824,7 +830,7 @@ msgstr "Ficheiro do modelo:"
#: ElectronClient/gui/MainScreen/commands/showNoteContentProperties.js:16
msgid "Statistics..."
msgstr ""
msgstr "Estatísticas..."
#: ElectronClient/gui/EncryptionConfigScreen.min.js:96
#: ElectronClient/gui/KeymapConfig/ShortcutRecorder.js:49
@@ -1148,13 +1154,12 @@ msgstr ""
#: ElectronClient/gui/NoteList/NoteList.min.js:151
#: ElectronClient/gui/NoteList/NoteList.js:160
msgid "Custom order"
msgstr ""
msgstr "Ordem personalizada"
#: ElectronClient/gui/NoteList/NoteList.min.js:151
#: ElectronClient/gui/NoteList/NoteList.js:160
#, fuzzy
msgid "View"
msgstr "&Ver"
msgstr "Ver"
#: ElectronClient/gui/NoteList/NoteList.min.js:151
#: ElectronClient/gui/NoteList/NoteList.js:160
@@ -1169,12 +1174,13 @@ msgid ""
"To manually sort the notes, the sort order must be changed to \"%s\" in the "
"menu \"%s\" > \"%s\""
msgstr ""
"Para ordenar as notas manualmente, a ordem deve ser alterada para \"%s\" no "
"menu \"%s\" > \"%s\""
#: ElectronClient/gui/NoteList/NoteList.min.js:152
#: ElectronClient/gui/NoteList/NoteList.js:161
#, fuzzy
msgid "Do it now"
msgstr "Obter agora:"
msgstr "Fazer agora"
#: ElectronClient/gui/NoteList/NoteList.min.js:423
#: ElectronClient/gui/NoteList/NoteList.js:412
@@ -1287,9 +1293,8 @@ msgid "Options"
msgstr "Opções"
#: ElectronClient/gui/MenuBar.js:266
#, fuzzy
msgid "Note attachments..."
msgstr "Anexos"
msgstr "Anexos das notas..."
#: ElectronClient/gui/MenuBar.js:296 ElectronClient/gui/MenuBar.js:366
#: ElectronClient/gui/MenuBar.js:659
@@ -1320,9 +1325,8 @@ msgid "Import"
msgstr "Importar"
#: ElectronClient/gui/MenuBar.js:343
#, fuzzy
msgid "Export all"
msgstr "Exportar"
msgstr "Exportar todos"
#: ElectronClient/gui/MenuBar.js:356
#, javascript-format
@@ -1360,9 +1364,8 @@ msgid "Zoom Out"
msgstr "Reduzir"
#: ElectronClient/gui/MenuBar.js:516
#, fuzzy
msgid "&Note"
msgstr "Nota"
msgstr "&Nota"
#: ElectronClient/gui/MenuBar.js:525
msgid "&Tools"
@@ -1399,44 +1402,42 @@ msgid "Dropbox Login"
msgstr "Acesso Dropbox"
#: ElectronClient/gui/Root.js:105 ElectronClient/gui/Root.min.js:105
#, fuzzy
msgid "Note attachments"
msgstr "Anexos"
msgstr "Anexos das notas"
#: ElectronClient/gui/KeymapConfig/ShortcutRecorder.js:48
msgid "Press the shortcut"
msgstr ""
msgstr "Prima o atalho"
#: ElectronClient/gui/KeymapConfig/ShortcutRecorder.js:48
msgid ""
"Press the shortcut and then press ENTER. Or, press BACKSPACE to clear the "
"shortcut."
msgstr ""
"Prima o atalho e de seguida prima ENTER. Ou então, prima BACKSPACE para "
"apagar o atalho."
#: ElectronClient/gui/KeymapConfig/KeymapConfigScreen.js:62
#: ReactNativeClient/lib/services/KeymapService.js:142
#, fuzzy, javascript-format
#, javascript-format
msgid "Error: %s"
msgstr "Erro"
msgstr "Erro: %s"
#: ElectronClient/gui/KeymapConfig/KeymapConfigScreen.js:125
msgid "Command"
msgstr ""
msgstr "Comando"
#: ElectronClient/gui/KeymapConfig/KeymapConfigScreen.js:126
#, fuzzy
msgid "Keyboard Shortcut"
msgstr "Modo de Teclado"
msgstr "Atalhos de Teclado"
#: ElectronClient/gui/KeymapConfig/utils/getLabel.js:24
#, fuzzy
msgid "Hide Joplin"
msgstr "Sobre o Joplin"
msgstr "Esconder o Joplin"
#: ElectronClient/gui/KeymapConfig/utils/getLabel.js:28
#, fuzzy
msgid "Preferences"
msgstr "Preferências..."
msgstr "Preferências"
#: ElectronClient/gui/NoteContentPropertiesDialog.js:77
msgid "Words"
@@ -1471,17 +1472,18 @@ msgstr "Visualizador"
#: ElectronClient/gui/NoteContentPropertiesDialog.js:106
#, javascript-format
msgid "Read time: %s min"
msgstr ""
msgstr "Tempo de leitura: %s min"
#: ElectronClient/gui/NoteContentPropertiesDialog.js:109
#, fuzzy
msgid "Statistics"
msgstr "Estado"
msgstr "Estatísticas"
#: ElectronClient/bridge.js:177
msgid ""
"The app is now going to close. Please relaunch it to complete the process."
msgstr ""
"A aplicação vai fechar. Por favor volte a executá-la para completar o "
"processo."
#: ElectronClient/app.js:340
#, javascript-format
@@ -1493,9 +1495,8 @@ msgid "Exit"
msgstr "Sair"
#: ElectronClient/commands/copyDevCommand.js:17
#, fuzzy
msgid "Copy dev mode command to clipboard"
msgstr "Copiar caminho para a área de transferência"
msgstr "Copiar comando de modo dev para a área de transferências"
#: ElectronClient/commands/startExternalEditing.js:18
msgid "Edit in external editor"
@@ -1507,13 +1508,12 @@ msgid "Error opening note in editor: %s"
msgstr "Erro a abrir a nota no editor: %s"
#: ElectronClient/commands/toggleExternalEditing.js:16
#, fuzzy
msgid "Toggle external editing"
msgstr "Parar a edição externa"
msgstr "Alternar edição externa"
#: ElectronClient/commands/toggleExternalEditing.js:42
msgid "Stop"
msgstr ""
msgstr "Parar"
#: ElectronClient/commands/stopExternalEditing.js:16
msgid "Stop external editing"
@@ -1649,8 +1649,8 @@ msgid ""
msgstr ""
"Em qualquer comando, uma nota ou caderno pode ser indicada pelo título ou "
"ID, ou através dos atalhos `$n` ou `$b` para, respetivamente, a nota ou "
"bloco de notas atualmente selecionado. O `$c` pode ser usado para indicar o "
"item atualmente selecionado."
"caderno atualmente selecionado. O `$c` pode ser usado para indicar o item "
"atualmente selecionado."
#: CliClient/app/command-help.js:79
msgid "To move from one pane to another, press Tab or Shift+Tab."
@@ -1743,7 +1743,7 @@ msgstr ""
#: CliClient/app/command-sync.js:35
msgid "Upgrade the sync target to the latest version."
msgstr ""
msgstr "Atualize o alvo de sincronização para a última versão."
#: CliClient/app/command-sync.js:105
#, javascript-format
@@ -1771,9 +1771,8 @@ msgid "Synchronisation target: %s (%s)"
msgstr "Destino de sincronização: %s (%s)"
#: CliClient/app/command-sync.js:177
#, fuzzy
msgid "Cannot initialise synchroniser."
msgstr "Não é possível alterar item encriptado."
msgstr "Não é possível inicializar o sincronizador."
#: CliClient/app/command-sync.js:207
msgid "Starting synchronisation..."
@@ -1916,9 +1915,8 @@ msgstr ""
"desencriptados em segundo plano e estarão disponíveis brevemente."
#: CliClient/app/gui/NoteWidget.js:50
#, fuzzy
msgid "You may also type `status` for more information."
msgstr "Não peça confirmação."
msgstr "Pode também escrever `status` para mais informação."
#: CliClient/app/gui/FolderListWidget.js:31
msgid "Search:"
@@ -1962,14 +1960,16 @@ msgstr ""
"vários minutos, dependendo de quanto há para desencriptar."
#: CliClient/app/command-e2ee.js:53
#, fuzzy, javascript-format
#, javascript-format
msgid "Decrypted items: %d"
msgstr "Itens desencriptados: %s / %s"
msgstr "Itens desencriptados: %d"
#: CliClient/app/command-e2ee.js:54
#, javascript-format
msgid "Skipped items: %d (use --retry-failed-items to retry decrypting them)"
msgstr ""
"Itens ignorados: %d (use --retry-failed-items para tentar desencriptá-los "
"novamente)"
#: CliClient/app/command-e2ee.js:68
msgid "Completed decryption."
@@ -2018,9 +2018,9 @@ msgid "Do not ask for confirmation."
msgstr "Não peça confirmação."
#: CliClient/app/command-import.js:27
#, fuzzy, javascript-format
#, javascript-format
msgid "Output format: %s"
msgstr "Formato da origem: %s"
msgstr "Formato da saída: %s"
#: CliClient/app/command-import.js:65
msgid "Importing notes..."
@@ -2051,6 +2051,8 @@ msgstr "Exibe um resumo sobre as notas e os cadernos."
msgid ""
"To retry decryption of these items. Run `e2ee decrypt --retry-failed-items`"
msgstr ""
"Para tentar desencriptar estes itens novamente. Execute `e2ee decrypt --"
"retry-failed-items`"
#: CliClient/app/command-undone.js:12
msgid "Marks a to-do as non-completed."
@@ -2244,14 +2246,17 @@ msgid "HTML Directory"
msgstr "Diretório HTML"
#: ReactNativeClient/lib/services/interop/InteropService.js:127
#, fuzzy, javascript-format
#, javascript-format
msgid "Cannot load \"%s\" module for format \"%s\" and output \"%s\""
msgstr "Não é possível carregar o módulo \"%s\" para o formato \"%s\"."
msgstr ""
"Não é possível carregar o módulo \"%s\" para o formato \"%s\" e saída \"%s\""
#: ReactNativeClient/lib/services/interop/InteropService.js:152
#, fuzzy, javascript-format
#, javascript-format
msgid "Cannot load \"%s\" module for format \"%s\" and target \"%s\""
msgstr "Não é possível carregar o módulo \"%s\" para o formato \"%s\"."
msgstr ""
"Não é possível carregar o módulo \"%s\" para o formato \"%s\" e o alvo \"%s"
"\"."
#: ReactNativeClient/lib/services/interop/InteropService.js:187
#, javascript-format
@@ -2269,35 +2274,37 @@ msgstr "Notas Recuperadas"
#: ReactNativeClient/lib/services/KeymapService.js:236
msgid "command"
msgstr ""
msgstr "comando"
#: ReactNativeClient/lib/services/KeymapService.js:236
#: ReactNativeClient/lib/services/KeymapService.js:241
#, javascript-format
msgid "\"%s\" is missing the required \"%s\" property."
msgstr ""
msgstr "Está em falta a propriedade \"%s\" de \"%s\"."
#: ReactNativeClient/lib/services/KeymapService.js:241
#: ReactNativeClient/lib/services/KeymapService.js:248
msgid "accelerator"
msgstr ""
msgstr "acelerador"
#: ReactNativeClient/lib/services/KeymapService.js:248
#, fuzzy, javascript-format
msgid "Invalid %s: %s."
msgstr "Resposta inválida: %s"
msgstr "\"%s\" inválida: %s"
#: ReactNativeClient/lib/services/KeymapService.js:266
#, javascript-format
#, fuzzy, javascript-format
msgid ""
"Accelerator \"%s\" is used for \"%s\" and \"%s\" commands. This may lead to "
"unexpected behaviour."
msgstr ""
"O acelerador \"%s\" é usado para comandos \"%s\" e \"%s\". Isto pode levar a "
"comportamentos inesperados."
#: ReactNativeClient/lib/services/KeymapService.js:291
#, javascript-format
#, fuzzy, javascript-format
msgid "Accelerator \"%s\" is not valid."
msgstr ""
msgstr "O acelerador \"%s\" não é válido."
#: ReactNativeClient/lib/services/report.js:121
msgid "Items that cannot be synchronised"
@@ -2309,9 +2316,9 @@ msgid ""
"target. In order to find these items, either search for the title or the ID "
"(which is displayed in brackets above)."
msgstr ""
"Esses itens permanecerão no dispositivo, mas não serão enviados para o "
"destino de sincronização. Para encontrar estes itens, procure o título ou o "
"ID (que é apresentado entre parênteses acima)."
"Esses itens permanecerão no dispositivo, mas não serão enviados para o alvo "
"de sincronização. Para encontrar estes itens, procure o título ou o ID (que "
"é apresentado entre parênteses acima)."
#: ReactNativeClient/lib/services/report.js:130
#, javascript-format
@@ -2447,7 +2454,7 @@ msgstr "Versão do Perfil: %s"
#: ReactNativeClient/lib/versionInfo.js:23
#, javascript-format
msgid "Keychain Supported: %s"
msgstr ""
msgstr "Porta-Chaves Suportado: %s"
#: ReactNativeClient/lib/JoplinServerApi.js:71
#, javascript-format
@@ -2849,7 +2856,7 @@ msgstr "Adicionar título"
#: ReactNativeClient/lib/components/screens/UpgradeSyncTargetScreen.js:42
msgid "Sync Target Upgrade"
msgstr ""
msgstr "Atualização do Alvo de Sincronização"
#: ReactNativeClient/lib/components/screens/encryption-config.js:119
#, javascript-format
@@ -2877,7 +2884,7 @@ msgid ""
"the data! To enable encryption, please enter your password below."
msgstr ""
"Ativar a encriptação significa que *todas* as suas notas e anexos serão "
"ressincronizados e enviados encriptados para o destino de sincronização. Não "
"ressincronizados e enviados encriptados para o alvo de sincronização. Não "
"perca a palavra-passe pois, por razões de segurança, esta será a única forma "
"de desencriptar os dados! Para ativar a encriptação, introduza a sua palavra-"
"passe abaixo."
@@ -2939,8 +2946,11 @@ msgstr ""
"Alguns itens não puderam ser sincronizados. Prima para mais informações."
#: ReactNativeClient/lib/components/screen-header.js:453
#, fuzzy
msgid "The sync target needs to be upgraded. Press this banner to proceed."
msgstr ""
"O alvo de sincronização precisa de ser atualizado. Clique neste banner para "
"proceder."
#: ReactNativeClient/lib/components/side-menu-content.js:126
#, javascript-format
@@ -3021,7 +3031,7 @@ msgid ""
"the sync target is accessible. The reported error was:"
msgstr ""
"Erro. Por favor verifique se o endereço, nome de utilizador, palavra-passe, "
"etc. estão corretos e se o destino de sincronização está acessível. O erro "
"etc. estão corretos e se o alvo de sincronização está acessível. O erro "
"reportado foi:"
#: ReactNativeClient/lib/components/note-list.js:97
@@ -3086,17 +3096,20 @@ msgid "Downloaded"
msgstr "Transferido"
#: ReactNativeClient/lib/models/Resource.js:371
#, fuzzy, javascript-format
#, javascript-format
msgid "Attachment conflict: \"%s\""
msgstr "Anexos"
msgstr "Anexos em conflito: \"%s\""
#: ReactNativeClient/lib/models/Resource.js:372
#, fuzzy, javascript-format
#, javascript-format
msgid ""
"There was a [conflict](%s) on the attachment below.\n"
"\n"
"%s"
msgstr "Ocorreu um erro ao transferir este anexo:"
msgstr ""
"Ocorreu um [conflito](%s) no anexo em baixo.\n"
"\n"
"%s"
#: ReactNativeClient/lib/models/BaseItem.js:721
msgid "Encrypted"
@@ -3104,7 +3117,7 @@ msgstr "Encriptado"
#: ReactNativeClient/lib/models/BaseItem.js:781
msgid "Encrypted items cannot be modified"
msgstr "Não é possível modificar tens encriptados"
msgstr "Não é possível modificar itens encriptados"
#: ReactNativeClient/lib/models/Note.js:27
msgid "created date"
@@ -3112,7 +3125,7 @@ msgstr "data criada"
#: ReactNativeClient/lib/models/Note.js:28
msgid "custom order"
msgstr ""
msgstr "ordem personalizada"
#: ReactNativeClient/lib/models/Note.js:92
msgid "This note does not have geolocation information."
@@ -3129,20 +3142,18 @@ msgid "Cannot move note to \"%s\" notebook"
msgstr "Não é possível mover a nota para o caderno \"%s\""
#: ReactNativeClient/lib/models/Setting.js:65
#, fuzzy
msgid "yes"
msgstr "Sim"
msgstr "sim"
#: ReactNativeClient/lib/models/Setting.js:65
#: ReactNativeClient/lib/models/Setting.js:66
#, javascript-format
msgid "(wysiwyg: %s)"
msgstr ""
msgstr "(wysiwyg: %s)"
#: ReactNativeClient/lib/models/Setting.js:66
#, fuzzy
msgid "no"
msgstr "n"
msgstr "não"
#: ReactNativeClient/lib/models/Setting.js:68
#, javascript-format
@@ -3181,7 +3192,7 @@ msgstr "Nórdico"
#: ReactNativeClient/lib/models/Setting.js:80
msgid "Aritim Dark"
msgstr ""
msgstr "Escuro Aritim"
#: ReactNativeClient/lib/models/Setting.js:81
msgid "OLED Dark"
@@ -3196,8 +3207,8 @@ msgid ""
"The target to synchonise to. Each sync target may have additional parameters "
"which are named as `sync.NUM.NAME` (all documented below)."
msgstr ""
"O destino para a sincronização. Cada destino de sincronização pode ter "
"parâmetros adicionais que são designados como `sync.NUM.NUM.NAME` (todos "
"O destino para a sincronização. Cada alvo de sincronização pode ter "
"parâmetros adicionais que são designados como `sync.NUM.NAME` (todos "
"documentados abaixo)."
#: ReactNativeClient/lib/models/Setting.js:131
@@ -3230,15 +3241,15 @@ msgstr "Palavra-passe WebDAV"
#: ReactNativeClient/lib/models/Setting.js:214
msgid "AWS S3 bucket"
msgstr ""
msgstr "Bucket AWS S3"
#: ReactNativeClient/lib/models/Setting.js:225
msgid "AWS key"
msgstr ""
msgstr "Chave AWS"
#: ReactNativeClient/lib/models/Setting.js:235
msgid "AWS secret"
msgstr ""
msgstr "Segredo AWS"
#: ReactNativeClient/lib/models/Setting.js:247
msgid "Attachment download behaviour"
@@ -3250,10 +3261,9 @@ msgid ""
"In \"Auto\", they are downloaded when you open the note. In \"Always\", all "
"the attachments are downloaded whether you open the note or not."
msgstr ""
"No modo \"Manual\", os anexos são transferidos apenas quando é dado um "
"clique neles. Em \"Automático\", eles são transferidos quando a nota é "
"aberta. Em \"Sempre\", todos os anexos são transferidos, quer a nota seja "
"aberta ou não."
"No modo \"Manual\", os anexos são transferidos apenas quando são clicados. "
"Em \"Automático\", eles são transferidos quando a nota é aberta. Em \"Sempre"
"\", todos os anexos são transferidos, quer a nota seja aberta ou não."
#: ReactNativeClient/lib/models/Setting.js:251
msgid "Always"
@@ -3289,15 +3299,15 @@ msgstr "Tema"
#: ReactNativeClient/lib/models/Setting.js:337
msgid "Automatically switch theme to match system theme"
msgstr ""
msgstr "Mudar automaticamente o tema para combinar com o tema do sistema"
#: ReactNativeClient/lib/models/Setting.js:348
msgid "Preferred light theme"
msgstr ""
msgstr "Tema claro preferido"
#: ReactNativeClient/lib/models/Setting.js:361
msgid "Preferred dark theme"
msgstr ""
msgstr "Tema escuro preferido"
#: ReactNativeClient/lib/models/Setting.js:365
msgid "Show note counts"
@@ -3460,15 +3470,14 @@ msgid "Editor font family"
msgstr "Família da letra do editor"
#: ReactNativeClient/lib/models/Setting.js:556
#, fuzzy
msgid ""
"This should be a *monospace* font or some elements will render incorrectly. "
"If the font is incorrect or empty, it will default to a generic monospace "
"font."
msgstr ""
"Este deverá ser um tipo de letra *mono-espaçado* ou não funcionará "
"corretamente. Se o tipo de letra estiver incorreto ou em branco, será pré-"
"definida para um tipo de letra mono-espaçado genérico."
"corretamente. Se o tipo de letra estiver incorreto ou em branco, reverterá "
"para um tipo de letra mono-espaçado genérico pré-definido."
#: ReactNativeClient/lib/models/Setting.js:595
msgid "Custom stylesheet for Joplin-wide app styles"
@@ -3482,7 +3491,7 @@ msgstr "Atualizar a aplicação automaticamente"
#: ReactNativeClient/lib/models/Setting.js:601
msgid "Get pre-releases when checking for updates"
msgstr "Obtenha versões de pré-lançamento ao verificar atualizações"
msgstr "Obtenha versões de pré-lançamento ao verificar se há atualizações"
#: ReactNativeClient/lib/models/Setting.js:601
#, javascript-format
@@ -3491,7 +3500,7 @@ msgstr "Consulte a página de pré-lançamento para obter mais detalhes: %s"
#: ReactNativeClient/lib/models/Setting.js:609
msgid "Synchronisation interval"
msgstr "Periodicidade de sincronização"
msgstr "Intervalo de sincronização"
#: ReactNativeClient/lib/models/Setting.js:613
#: ReactNativeClient/lib/models/Setting.js:614
@@ -3610,8 +3619,8 @@ msgid ""
"Fail-safe: Do not wipe out local data when sync target is empty (often the "
"result of a misconfiguration or bug)"
msgstr ""
"À prova de falhas: Não elimine os dados locais quando o destino de "
"sincronização está em brancp (muitas vezes o resultado de uma má "
"Segurança contra falhas: Não elimine os dados locais quando o alvo de "
"sincronização está em branco (muitas vezes o resultado de uma má "
"configuração ou erro)"
#: ReactNativeClient/lib/models/Setting.js:695
@@ -3641,7 +3650,7 @@ msgstr "Manter histórico de notas por"
#: ReactNativeClient/lib/models/Setting.js:735
msgid "Notebook list growth factor"
msgstr ""
msgstr "Fator de crescimento do caderno"
#: ReactNativeClient/lib/models/Setting.js:736
#: ReactNativeClient/lib/models/Setting.js:748
@@ -3652,14 +3661,18 @@ msgid ""
"item with a factor of 2 will take twice as much space as an item with a "
"factor of 1.Restart app to see changes."
msgstr ""
"A propriedade fator define como um item aumentará ou diminuirá para ocupar o "
"espaço disponível no seu contentor com respeito aos outros itens. Como tal, "
"um item com um fator de 2 ocupará o dobro do espaço de um item com um fator "
"de 1. Reinicie a aplicação para ver as alterações."
#: ReactNativeClient/lib/models/Setting.js:747
msgid "Note list growth factor"
msgstr ""
msgstr "Fator de crescimento da lista de notas"
#: ReactNativeClient/lib/models/Setting.js:759
msgid "Note area growth factor"
msgstr ""
msgstr "Fator de crescimento da área de notas"
#: ReactNativeClient/lib/models/Setting.js:1272
msgid "General"
@@ -3694,9 +3707,8 @@ msgid "Web Clipper"
msgstr "Recorte Web"
#: ReactNativeClient/lib/models/Setting.js:1292
#, fuzzy
msgid "Keyboard Shortcuts"
msgstr "Modo de Teclado"
msgstr "Atalhos do Teclado"
#: ReactNativeClient/lib/models/Setting.js:1299
msgid ""
@@ -3708,6 +3720,12 @@ msgid ""
"formatting. It is indicated below which plugins are compatible or not with "
"the WYSIWYG editor."
msgstr ""
"Estes plugins modificam o renderizador de Markdown com recursos adicionais. "
"Note que, enquanto estes recursos podem ser úteis, não são Markdown padrão "
"e, como tal, a maioria deles só funcionará no Joplin. Adicionalmente, alguns "
"deles são *incompatíveis* com o editor WYSIWYG. Se abrir uma nota que use um "
"destes plugins nesse editor, perderá a formatação do plugin. Está indicado "
"abaixo quais os plugins que são ou não compatíveis com o editor WYSIWYG."
#: ReactNativeClient/lib/models/Setting.js:1301
#, javascript-format
@@ -3736,11 +3754,11 @@ msgstr "OneDrive"
#: ReactNativeClient/lib/SyncTargetAmazonS3.js:28
msgid "AWS S3"
msgstr ""
msgstr "AWS S3"
#: ReactNativeClient/lib/commands/historyForward.js:16
msgid "Forward"
msgstr ""
msgstr "Avançar"
#: ReactNativeClient/lib/shim-init-node.js:158
#, javascript-format

View File

@@ -4199,11 +4199,6 @@
"resolved": "https://registry.npmjs.org/mdurl/-/mdurl-1.0.1.tgz",
"integrity": "sha1-/oWy7HWlkDfyrf7BAP1sYBdhFS4="
},
"memory-cache": {
"version": "0.2.0",
"resolved": "https://registry.npmjs.org/memory-cache/-/memory-cache-0.2.0.tgz",
"integrity": "sha1-eJCwHVLADI68nVM+H46xfjA0hxo="
},
"micromatch": {
"version": "3.1.10",
"resolved": "https://registry.npmjs.org/micromatch/-/micromatch-3.1.10.tgz",
@@ -5900,11 +5895,6 @@
"is-fullwidth-code-point": "^2.0.0"
}
},
"slug": {
"version": "3.5.0",
"resolved": "https://registry.npmjs.org/slug/-/slug-3.5.0.tgz",
"integrity": "sha512-+pZLDhMtmAc+ZcojQSMlUKDZBYmvhZiZmK8Ffx/D3Q/MIMHPDBAMbWvWN8vJb9xl2MfbDdRWxFzrdOhBiyVpow=="
},
"snapdragon": {
"version": "0.8.2",
"resolved": "https://registry.npmjs.org/snapdragon/-/snapdragon-0.8.2.tgz",
@@ -6767,6 +6757,11 @@
"resolved": "https://registry.npmjs.org/universalify/-/universalify-0.1.1.tgz",
"integrity": "sha1-+nG63UQ3r0wUiEHjs7Fl+enlkLc="
},
"unorm": {
"version": "1.6.0",
"resolved": "https://registry.npmjs.org/unorm/-/unorm-1.6.0.tgz",
"integrity": "sha512-b2/KCUlYZUeA7JFUuRJZPUtr4gZvBh7tavtv4fvk4+KV9pfGiR6CQAQAWl49ZpR3ts2dk4FYkP7EIgDJoiOLDA=="
},
"unpack-string": {
"version": "0.0.2",
"resolved": "https://registry.npmjs.org/unpack-string/-/unpack-string-0.0.2.tgz",
@@ -6869,6 +6864,24 @@
"resolved": "https://registry.npmjs.org/use/-/use-3.1.1.tgz",
"integrity": "sha512-cwESVXlO3url9YWlFW/TA9cshCEhtu7IKJ/p5soJ/gGpj7vbvFrAY/eIioQ6Dw23KjZhYgiIo8HOs1nQ2vr/oQ=="
},
"uslug": {
"version": "git+https://github.com/laurent22/uslug.git#ba2834d79beb0435318709958b2f5e817d96674d",
"from": "git+https://github.com/laurent22/uslug.git#emoji-support",
"requires": {
"node-emoji": "^1.10.0",
"unorm": ">= 1.0.0"
},
"dependencies": {
"node-emoji": {
"version": "1.10.0",
"resolved": "https://registry.npmjs.org/node-emoji/-/node-emoji-1.10.0.tgz",
"integrity": "sha512-Yt3384If5H6BYGVHiHwTL+99OzJKHhgp82S8/dktEK73T26BazdgZ4JZh92xSVtGNJvz9UbXdNAc5hcrXV42vw==",
"requires": {
"lodash.toarray": "^4.4.0"
}
}
}
},
"util-deprecate": {
"version": "1.0.2",
"resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz",

View File

@@ -6,7 +6,7 @@
"scripts": {
"test": "gulp buildTests -L && node node_modules/jasmine/bin/jasmine.js --fail-fast=true --config=tests/support/jasmine.json",
"test-ci": "gulp buildTests -L && node node_modules/jasmine/bin/jasmine.js --config=tests/support/jasmine.json",
"postinstall": "npm run build && patch-package --patch-dir ../patches",
"postinstall": "npm run build && patch-package --patch-dir ../patches/shared && patch-package --patch-dir ../patches/node",
"build": "gulp build",
"start": "gulp build -L && node 'build/main.js' --stack-trace-enabled --log-level debug --env dev"
},
@@ -80,7 +80,6 @@
"markdown-it-toc-done-right": "^4.1.0",
"md5": "^2.2.1",
"md5-file": "^4.0.0",
"memory-cache": "^0.2.0",
"mime": "^2.0.3",
"moment": "^2.24.0",
"multiparty": "^4.2.1",
@@ -102,7 +101,6 @@
"sax": "^1.2.4",
"server-destroy": "^1.0.1",
"sharp": "^0.23.2",
"slug": "^3.5.0",
"sprintf-js": "^1.1.1",
"sqlite3": "^4.1.1",
"string-padding": "^1.0.2",
@@ -114,6 +112,7 @@
"terminal-kit": "^1.30.0",
"tkwidgets": "^0.5.26",
"url-parse": "^1.4.7",
"uslug": "git+https://github.com/laurent22/uslug.git#emoji-support",
"uuid": "^3.0.1",
"valid-url": "^1.0.9",
"word-wrap": "^1.2.3",

View File

@@ -4,7 +4,7 @@ require('app-module-path').addPath(__dirname);
const os = require('os');
const { time } = require('lib/time-utils.js');
const { filename } = require('lib/path-utils.js');
const { filename } = require('lib/path-utils');
const { asyncTest, fileContentEqual, setupDatabase, setupDatabaseAndSynchronizer, db, synchronizer, fileApi, sleep, clearDatabase, switchClient, syncTargetId, objectsEqual, checkThrowAsync } = require('test-utils.js');
const Folder = require('lib/models/Folder.js');
const Note = require('lib/models/Note.js');

View File

@@ -4,7 +4,7 @@ require('app-module-path').addPath(__dirname);
const os = require('os');
const { time } = require('lib/time-utils.js');
const { filename } = require('lib/path-utils.js');
const { filename } = require('lib/path-utils');
const { asyncTest, fileContentEqual, setupDatabase, setupDatabaseAndSynchronizer, db, synchronizer, fileApi, sleep, clearDatabase, switchClient, syncTargetId, objectsEqual, checkThrowAsync } = require('test-utils.js');
const Folder = require('lib/models/Folder.js');
const Note = require('lib/models/Note.js');

View File

@@ -4,7 +4,7 @@ require('app-module-path').addPath(__dirname);
const os = require('os');
const { time } = require('lib/time-utils.js');
const { filename } = require('lib/path-utils.js');
const { filename } = require('lib/path-utils');
const { asyncTest, fileContentEqual, setupDatabase, setupDatabaseAndSynchronizer, db, synchronizer, fileApi, sleep, clearDatabase, switchClient, syncTargetId, objectsEqual, checkThrowAsync } = require('test-utils.js');
const Folder = require('lib/models/Folder.js');
const Note = require('lib/models/Note.js');

View File

@@ -0,0 +1,59 @@
import InMemoryCache from 'lib/InMemoryCache';
const { time } = require('lib/time-utils.js');
describe('InMemoryCache', function() {
it('should get and set values', () => {
const cache = new InMemoryCache();
expect(cache.value('test')).toBe(undefined);
expect(cache.value('test', 'default')).toBe('default');
cache.setValue('test', 'something');
expect(cache.value('test')).toBe('something');
// Check we get the exact same object back (cache should not copy)
const someObj = { abcd: '123' };
cache.setValue('someObj', someObj);
expect(cache.value('someObj')).toBe(someObj);
});
it('should expire values', async () => {
const cache = new InMemoryCache();
// Check that the value is udefined once the cache has expired
cache.setValue('test', 'something', 500);
expect(cache.value('test')).toBe('something');
await time.msleep(510);
expect(cache.value('test')).toBe(undefined);
// Check that the TTL is reset every time setValue is called
cache.setValue('test', 'something', 300);
await time.msleep(100);
cache.setValue('test', 'something', 300);
await time.msleep(100);
cache.setValue('test', 'something', 300);
await time.msleep(100);
cache.setValue('test', 'something', 300);
await time.msleep(100);
expect(cache.value('test')).toBe('something');
});
it('should delete old records', async () => {
const cache = new InMemoryCache(5);
cache.setValue('1', '1');
cache.setValue('2', '2');
cache.setValue('3', '3');
cache.setValue('4', '4');
cache.setValue('5', '5');
expect(cache.value('1')).toBe('1');
cache.setValue('6', '6');
expect(cache.value('1')).toBe(undefined);
});
});

View File

@@ -1,7 +1,7 @@
require('app-module-path').addPath(__dirname);
const { asyncTest } = require('test-utils.js');
const MarkupToHtml = require('lib/joplin-renderer/MarkupToHtml');
const MarkupToHtml = require('lib/joplin-renderer/MarkupToHtml').default;
describe('MarkupToHtml', function() {

View File

@@ -1,24 +1,11 @@
/* eslint-disable no-unused-vars */
require('app-module-path').addPath(__dirname);
const os = require('os');
const { time } = require('lib/time-utils.js');
const { filename } = require('lib/path-utils.js');
const { asyncTest, fileContentEqual, setupDatabase, setupDatabaseAndSynchronizer, db, synchronizer, fileApi, sleep, clearDatabase, switchClient, syncTargetId, objectsEqual, checkThrowAsync } = require('test-utils.js');
const Folder = require('lib/models/Folder.js');
const Note = require('lib/models/Note.js');
const BaseModel = require('lib/BaseModel.js');
const { filename } = require('lib/path-utils');
const { asyncTest, setupDatabaseAndSynchronizer, switchClient } = require('test-utils.js');
const shim = require('lib/shim').default;
const MdToHtml = require('lib/joplin-renderer/MdToHtml');
const { enexXmlToMd } = require('lib/import-enex-md-gen.js');
const MdToHtml = require('lib/joplin-renderer/MdToHtml').default;
const { themeStyle } = require('lib/theme');
process.on('unhandledRejection', (reason, p) => {
console.log('Unhandled Rejection at: Promise', p, 'reason:', reason);
});
function newTestMdToHtml(options = null) {
function newTestMdToHtml(options:any = null) {
options = {
ResourceModel: {
isResourceUrl: () => false,
@@ -32,7 +19,7 @@ function newTestMdToHtml(options = null) {
describe('MdToHtml', function() {
beforeEach(async (done) => {
beforeEach(async (done:Function) => {
await setupDatabaseAndSynchronizer(1);
await switchClient(1);
done();
@@ -52,14 +39,14 @@ describe('MdToHtml', function() {
// if (mdFilename !== 'sanitize_9.md') continue;
const mdToHtmlOptions = {
const mdToHtmlOptions:any = {
bodyOnly: true,
};
if (mdFilename === 'checkbox_alternative.md') {
mdToHtmlOptions.plugins = {
checkbox: {
renderingType: 2,
checkboxRenderingType: 2,
},
};
}
@@ -96,7 +83,7 @@ describe('MdToHtml', function() {
}));
it('should return enabled plugin assets', asyncTest(async () => {
const pluginOptions = {};
const pluginOptions:any = {};
const pluginNames = MdToHtml.pluginNames();
for (const n of pluginNames) pluginOptions[n] = { enabled: false };
@@ -126,7 +113,7 @@ describe('MdToHtml', function() {
// In this case, the HTML contains both the style and
// the rendered markdown wrapped in a DIV.
const result = await mdToHtml.render('just **testing**');
expect(result.cssStrings.length).toBe(0);
expect(result.cssStrings.length).toBeGreaterThan(0);
expect(result.html.indexOf('rendered-md') >= 0).toBe(true);
}));
@@ -137,7 +124,7 @@ describe('MdToHtml', function() {
// with no wrapper and no style.
// The style is instead in the cssStrings property.
const result = await mdToHtml.render('just **testing**', null, { bodyOnly: true });
expect(result.cssStrings.length).toBe(1);
expect(result.cssStrings.length).toBeGreaterThan(0);
expect(result.html.trim()).toBe('just <strong>testing</strong>');
}));
@@ -147,7 +134,7 @@ describe('MdToHtml', function() {
// It is similar to the bodyOnly option, excepts that
// the rendered Markdown is wrapped in a DIV
const result = await mdToHtml.render('just **testing**', null, { splitted: true });
expect(result.cssStrings.length).toBe(1);
expect(result.cssStrings.length).toBeGreaterThan(0);
expect(result.html.trim()).toBe('<div id="rendered-md"><p>just <strong>testing</strong></p>\n</div>');
}));

View File

@@ -0,0 +1,18 @@
import FsDriverNode from 'lib/fs-driver-node';
const { expectThrow } = require('test-utils.js');
describe('fsDriver', function() {
it('should resolveRelativePathWithinDir', () => {
const fsDriver = new FsDriverNode();
expect(fsDriver.resolveRelativePathWithinDir('/test/temp', './my/file.txt')).toBe('/test/temp/my/file.txt');
expect(fsDriver.resolveRelativePathWithinDir('/', './test')).toBe('/test');
expect(fsDriver.resolveRelativePathWithinDir('/test', 'myfile.txt')).toBe('/test/myfile.txt');
expect(fsDriver.resolveRelativePathWithinDir('/test/temp', './mydir/../test.txt')).toBe('/test/temp/test.txt');
expectThrow(() => fsDriver.resolveRelativePathWithinDir('/test/temp', '../myfile.txt'));
expectThrow(() => fsDriver.resolveRelativePathWithinDir('/test/temp', './mydir/../../test.txt'));
expectThrow(() => fsDriver.resolveRelativePathWithinDir('/test/temp', '/var/local/no.txt'));
});
});

View File

@@ -2,7 +2,7 @@
require('app-module-path').addPath(__dirname);
const { extractExecutablePath, quotePath, unquotePath, friendlySafeFilename, toFileProtocolPath } = require('lib/path-utils.js');
const { extractExecutablePath, quotePath, unquotePath, friendlySafeFilename, toFileProtocolPath } = require('lib/path-utils');
const { asyncTest, fileContentEqual, setupDatabase, setupDatabaseAndSynchronizer, db, synchronizer, fileApi, sleep, clearDatabase, switchClient, syncTargetId, objectsEqual, checkThrowAsync } = require('test-utils.js');
process.on('unhandledRejection', (reason, p) => {

View File

@@ -0,0 +1,16 @@
// import Setting from 'lib/models/Setting';
// const { asyncTest, setupDatabaseAndSynchronizer, switchClient, expectThrow, expectNotThrow } = require('../test-utils.js');
// describe('plugin_api_JoplinSetting', function() {
// beforeEach(async (done) => {
// await setupDatabaseAndSynchronizer(1);
// await switchClient(1);
// done();
// });
// it('should get and set plugin-specific values', asyncTest(async () => {
// await
// }));
// });

View File

@@ -2,7 +2,7 @@ import MenuUtils from 'lib/services/commands/MenuUtils';
import ToolbarButtonUtils from 'lib/services/commands/ToolbarButtonUtils';
import CommandService, { CommandDeclaration, CommandRuntime } from 'lib/services/CommandService';
const { asyncTest, setupDatabaseAndSynchronizer, switchClient } = require('test-utils.js');
const { asyncTest, setupDatabaseAndSynchronizer, switchClient, expectThrow, expectNotThrow } = require('test-utils.js');
interface TestCommand {
declaration: CommandDeclaration,
@@ -11,7 +11,12 @@ interface TestCommand {
function newService():CommandService {
const service = new CommandService();
service.initialize({});
const mockStore = {
getState: () => {
return {};
},
};
service.initialize(mockStore, true);
return service;
}
@@ -24,8 +29,7 @@ function createCommand(name:string, options:any):TestCommand {
execute: options.execute,
};
if (options.mapStateToProps) runtime.mapStateToProps = options.mapStateToProps;
if (options.isEnabled) runtime.isEnabled = options.isEnabled;
if (options.enabledCondition) runtime.enabledCondition = options.enabledCondition;
return { declaration, runtime };
}
@@ -61,7 +65,7 @@ describe('services_CommandService', function() {
},
}));
const toolbarInfos = toolbarButtonUtils.commandsToToolbarButtons({}, ['test1', 'test2']);
const toolbarInfos = toolbarButtonUtils.commandsToToolbarButtons(['test1', 'test2'], {});
await toolbarInfos[0].onClick();
await toolbarInfos[1].onClick();
@@ -77,98 +81,78 @@ describe('services_CommandService', function() {
registerCommand(service, createCommand('test1', {
execute: () => {},
mapStateToProps: (state:any) => {
return {
selectedNoteId: state.selectedNoteId,
selectedFolderId: state.selectedFolderId,
};
},
isEnabled: (props:any) => {
return props.selectedNoteId === 'abc';
},
enabledCondition: 'oneNoteSelected',
}));
registerCommand(service, createCommand('test2', {
execute: () => {},
mapStateToProps: (state:any) => {
return {
selectedNoteId: state.selectedNoteId,
selectedFolderId: state.selectedFolderId,
};
},
isEnabled: (props:any) => {
return props.selectedNoteId === '123';
},
enabledCondition: 'multipleNotesSelected',
}));
const toolbarInfos = toolbarButtonUtils.commandsToToolbarButtons({
selectedNoteId: '123',
selectedFolderId: 'aaa',
}, ['test1', 'test2']);
const toolbarInfos = toolbarButtonUtils.commandsToToolbarButtons(['test1', 'test2'], {
oneNoteSelected: false,
multipleNotesSelected: true,
});
expect(toolbarInfos[0].enabled).toBe(false);
expect(toolbarInfos[1].enabled).toBe(true);
}));
it('should enable commands by default', asyncTest(async () => {
const service = newService();
registerCommand(service, createCommand('test1', {
execute: () => {},
}));
expect(service.isEnabled('test1', {})).toBe(true);
}));
it('should return the same toolbarButtons array if nothing has changed', asyncTest(async () => {
const service = newService();
const toolbarButtonUtils = new ToolbarButtonUtils(service);
registerCommand(service, createCommand('test1', {
execute: () => {},
mapStateToProps: (state:any) => {
return {
selectedNoteId: state.selectedNoteId,
};
},
isEnabled: (props:any) => {
return props.selectedNoteId === 'ok';
},
enabledCondition: 'cond1',
}));
registerCommand(service, createCommand('test2', {
execute: () => {},
mapStateToProps: (state:any) => {
return {
selectedFolderId: state.selectedFolderId,
};
},
isEnabled: (props:any) => {
return props.selectedFolderId === 'ok';
},
enabledCondition: 'cond2',
}));
const toolbarInfos1 = toolbarButtonUtils.commandsToToolbarButtons({
selectedNoteId: 'ok',
selectedFolderId: 'notok',
}, ['test1', 'test2']);
const toolbarInfos1 = toolbarButtonUtils.commandsToToolbarButtons(['test1', 'test2'], {
cond1: true,
cond2: false,
});
const toolbarInfos2 = toolbarButtonUtils.commandsToToolbarButtons({
selectedNoteId: 'ok',
selectedFolderId: 'notok',
}, ['test1', 'test2']);
const toolbarInfos2 = toolbarButtonUtils.commandsToToolbarButtons(['test1', 'test2'], {
cond1: true,
cond2: false,
});
expect(toolbarInfos1).toBe(toolbarInfos2);
expect(toolbarInfos1[0] === toolbarInfos2[0]).toBe(true);
expect(toolbarInfos1[1] === toolbarInfos2[1]).toBe(true);
const toolbarInfos3 = toolbarButtonUtils.commandsToToolbarButtons({
selectedNoteId: 'ok',
selectedFolderId: 'ok',
}, ['test1', 'test2']);
const toolbarInfos3 = toolbarButtonUtils.commandsToToolbarButtons(['test1', 'test2'], {
cond1: true,
cond2: true,
});
expect(toolbarInfos2 === toolbarInfos3).toBe(false);
expect(toolbarInfos2[0] === toolbarInfos3[0]).toBe(true);
expect(toolbarInfos2[1] === toolbarInfos3[1]).toBe(false);
{
expect(toolbarButtonUtils.commandsToToolbarButtons({
selectedNoteId: 'ok',
selectedFolderId: 'notok',
}, ['test1', '-', 'test2'])).toBe(toolbarButtonUtils.commandsToToolbarButtons({
selectedNoteId: 'ok',
selectedFolderId: 'notok',
}, ['test1', '-', 'test2']));
expect(toolbarButtonUtils.commandsToToolbarButtons(['test1', '-', 'test2'], {
cond1: true,
cond2: false,
})).toBe(toolbarButtonUtils.commandsToToolbarButtons(['test1', '-', 'test2'], {
cond1: true,
cond2: false,
}));
}
}));
@@ -206,50 +190,37 @@ describe('services_CommandService', function() {
const utils = new MenuUtils(service);
registerCommand(service, createCommand('test1', {
mapStateToProps: (state:any) => {
return {
isOk: state.test1 === 'ok',
};
},
execute: () => {},
enabledCondition: 'cond1',
}));
registerCommand(service, createCommand('test2', {
mapStateToProps: (state:any) => {
return {
isOk: state.test2 === 'ok',
};
},
execute: () => {},
enabledCondition: 'cond2',
}));
{
const menuItemProps = utils.commandsToMenuItemProps({
test1: 'ok',
test2: 'notok',
}, ['test1', 'test2']);
const menuItemProps = utils.commandsToMenuItemProps(['test1', 'test2'], {
cond1: true,
cond2: false,
});
expect(menuItemProps.test1.isOk).toBe(true);
expect(menuItemProps.test2.isOk).toBe(false);
expect(menuItemProps.test1.enabled).toBe(true);
expect(menuItemProps.test2.enabled).toBe(false);
}
{
const menuItemProps = utils.commandsToMenuItemProps({
test1: 'ok',
test2: 'ok',
}, ['test1', 'test2']);
const menuItemProps = utils.commandsToMenuItemProps(['test1', 'test2'], {
cond1: true,
cond2: true,
});
expect(menuItemProps.test1.isOk).toBe(true);
expect(menuItemProps.test2.isOk).toBe(true);
expect(menuItemProps.test1.enabled).toBe(true);
expect(menuItemProps.test2.enabled).toBe(true);
}
expect(utils.commandsToMenuItemProps({
test1: 'ok',
test2: 'ok',
}, ['test1', 'test2'])).toBe(utils.commandsToMenuItemProps({
test1: 'ok',
test2: 'ok',
}, ['test1', 'test2']));
expect(utils.commandsToMenuItemProps(['test1', 'test2'], { cond1: true, cond2: true }))
.toBe(utils.commandsToMenuItemProps(['test1', 'test2'], { cond1: true, cond2: true }));
}));
it('should create stateful menu items', asyncTest(async () => {
@@ -259,20 +230,30 @@ describe('services_CommandService', function() {
let propValue = null;
registerCommand(service, createCommand('test1', {
mapStateToProps: (state:any) => {
return {
isOk: state.test1 === 'ok',
};
},
execute: (props:any) => {
propValue = props.isOk;
execute: (_context:any, greeting:string) => {
propValue = greeting;
},
}));
const menuItem = utils.commandToStatefulMenuItem('test1', { isOk: 'hello' });
const menuItem = utils.commandToStatefulMenuItem('test1', 'hello');
menuItem.click();
expect(propValue).toBe('hello');
}));
it('should throw an error for invalid when clause keys in dev mode', asyncTest(async () => {
const service = newService();
registerCommand(service, createCommand('test1', {
execute: () => {},
enabledCondition: 'cond1 && cond2',
}));
await expectThrow(async () => service.isEnabled('test1', {}));
await expectThrow(async () => service.isEnabled('test1', { cond1: true }));
await expectNotThrow(async () => service.isEnabled('test1', { cond1: true, cond2: true }));
await expectNotThrow(async () => service.isEnabled('test1', { cond1: true, cond2: false }));
}));
});

View File

@@ -299,7 +299,7 @@ describe('services_KeymapService', () => {
],
[
{ command: 'showLocalSearch', accelerator: 'Option+Cmd+S' },
{ command: 'print', accelerator: 'Cmd+G' /* Default of gotoAnything */ },
{ command: 'print', accelerator: 'Cmd+P' /* Default of gotoAnything */ },
{ command: 'focusElementNoteTitle', accelerator: 'Option+Shift+Cmd+J' },
],
];
@@ -317,7 +317,7 @@ describe('services_KeymapService', () => {
],
[
{ command: 'showLocalSearch', accelerator: 'Ctrl+Alt+S' },
{ command: 'print', accelerator: 'Ctrl+G' /* Default of gotoAnything */ },
{ command: 'print', accelerator: 'Ctrl+P' /* Default of gotoAnything */ },
{ command: 'focusElementNoteTitle', accelerator: 'Ctrl+Alt+Shift+J' },
],
];

View File

@@ -1,8 +1,13 @@
import PluginRunner from '../app/services/plugins/PluginRunner';
import PluginService from 'lib/services/plugins/PluginService';
import { ContentScriptType } from 'lib/services/plugins/api/types';
import MdToHtml from 'lib/joplin-renderer/MdToHtml';
import Setting from 'lib/models/Setting';
import shim from 'lib/shim';
import uuid from 'lib/uuid';
require('app-module-path').addPath(__dirname);
const { asyncTest, setupDatabaseAndSynchronizer, switchClient } = require('test-utils.js');
const { asyncTest, setupDatabaseAndSynchronizer, switchClient, expectThrow } = require('test-utils.js');
const Note = require('lib/models/Note');
const Folder = require('lib/models/Folder');
@@ -40,8 +45,7 @@ describe('services_PluginService', function() {
it('should load and run a simple plugin', asyncTest(async () => {
const service = newPluginService();
const plugin = await service.loadPlugin(`${testPluginDir}/simple`);
await service.runPlugin(plugin);
await service.loadAndRunPlugins([`${testPluginDir}/simple`]);
const allFolders = await Folder.all();
expect(allFolders.length).toBe(1);
@@ -55,9 +59,9 @@ describe('services_PluginService', function() {
it('should load and run a plugin that uses external packages', asyncTest(async () => {
const service = newPluginService();
const plugin = await service.loadPlugin(`${testPluginDir}/withExternalModules`);
await service.loadAndRunPlugins([`${testPluginDir}/withExternalModules`]);
const plugin = service.pluginById('withexternalmodules');
expect(plugin.id).toBe('withexternalmodules');
await service.runPlugin(plugin);
const allFolders = await Folder.all();
expect(allFolders.length).toBe(1);
@@ -78,4 +82,123 @@ describe('services_PluginService', function() {
expect(allFolders.map((f:any) => f.title).sort().join(', ')).toBe('multi - simple1, multi - simple2');
}));
it('should load plugins from JS bundles', asyncTest(async () => {
const service = newPluginService();
const plugin = await service.loadPluginFromString('example', '/tmp', `
/* joplin-manifest:
{
"manifest_version": 1,
"name": "JS Bundle test",
"description": "JS Bundle Test plugin",
"version": "1.0.0",
"author": "Laurent Cozic",
"homepage_url": "https://joplinapp.org"
}
*/
joplin.plugins.register({
onStart: async function() {
await joplin.data.post(['folders'], null, { title: "my plugin folder" });
},
});
`);
await service.runPlugin(plugin);
expect(plugin.manifest.manifest_version).toBe(1);
expect(plugin.manifest.name).toBe('JS Bundle test');
const allFolders = await Folder.all();
expect(allFolders.length).toBe(1);
}));
it('should load plugins from JS bundle files', asyncTest(async () => {
const service = newPluginService();
await service.loadAndRunPlugins(`${testPluginDir}/jsbundles`);
expect(!!service.pluginById('example')).toBe(true);
expect((await Folder.all()).length).toBe(1);
}));
it('should validate JS bundles', asyncTest(async () => {
const invalidJsBundles = [
`
/* joplin-manifest:
{
"not_a_valid_manifest_at_all": 1
}
*/
joplin.plugins.register({
onStart: async function() {},
});
`, `
/* joplin-manifest:
*/
joplin.plugins.register({
onStart: async function() {},
});
`, `
joplin.plugins.register({
onStart: async function() {},
});
`, '',
];
const service = newPluginService();
for (const jsBundle of invalidJsBundles) {
await expectThrow(async () => await service.loadPluginFromString('example', '/tmp', jsBundle));
}
}));
it('should register a Markdown-it plugin', asyncTest(async () => {
const contentScriptPath = `${Setting.value('tempDir')}/markdownItTestPlugin${uuid.createNano()}.js`;
await shim.fsDriver().copy(`${testPluginDir}/content_script/src/markdownItTestPlugin.js`, contentScriptPath);
const service = newPluginService();
const plugin = await service.loadPluginFromString('example', Setting.value('tempDir'), `
/* joplin-manifest:
{
"manifest_version": 1,
"name": "JS Bundle test",
"description": "JS Bundle Test plugin",
"version": "1.0.0",
"author": "Laurent Cozic",
"homepage_url": "https://joplinapp.org"
}
*/
joplin.plugins.register({
onStart: async function() {
await joplin.plugins.registerContentScript('markdownItPlugin', 'justtesting', '${contentScriptPath}');
},
});
`);
await service.runPlugin(plugin);
const contentScripts = plugin.contentScriptsByType(ContentScriptType.MarkdownItPlugin);
expect(contentScripts.length).toBe(1);
expect(!!contentScripts[0].path).toBe(true);
const contentScript = contentScripts[0];
const mdToHtml = new MdToHtml();
const module = require(contentScript.path).default;
mdToHtml.loadExtraRendererRule(contentScript.id, module({}));
const result = await mdToHtml.render([
'```justtesting',
'something',
'```',
].join('\n'));
expect(result.html.includes('JUST TESTING: something')).toBe(true);
await shim.fsDriver().remove(contentScriptPath);
}));
});

View File

@@ -1,60 +0,0 @@
/* eslint-disable no-unused-vars */
require('app-module-path').addPath(__dirname);
const { asyncTest, fileContentEqual, setupDatabase, setupDatabaseAndSynchronizer, db, synchronizer, fileApi, sleep, clearDatabase, switchClient, syncTargetId, objectsEqual, checkThrowAsync } = require('test-utils.js');
const shim = require('lib/shim').default;
const Setting = require('lib/models/Setting').default;
const KeychainService = require('lib/services/keychain/KeychainService').default;
process.on('unhandledRejection', (reason, p) => {
console.log('Unhandled Rejection at: Promise', p, 'reason:', reason);
});
function describeIfCompatible(name, fn) {
if (['win32', 'darwin'].includes(shim.platformName())) {
return describe(name, fn);
}
}
describeIfCompatible('services_KeychainService', function() {
beforeEach(async (done) => {
await setupDatabaseAndSynchronizer(1, { keychainEnabled: true });
await switchClient(1, { keychainEnabled: true });
await Setting.deleteKeychainPasswords();
done();
});
afterEach(async (done) => {
await Setting.deleteKeychainPasswords();
done();
});
it('should be enabled on macOS and Windows', asyncTest(async () => {
expect(Setting.value('keychain.supported')).toBe(1);
}));
it('should set, get and delete passwords', asyncTest(async () => {
const service = KeychainService.instance();
const isSet = await service.setPassword('zz_testunit', 'password');
expect(isSet).toBe(true);
const password = await service.password('zz_testunit');
expect(password).toBe('password');
await service.deletePassword('zz_testunit');
expect(await service.password('zz_testunit')).toBe(null);
}));
it('should save and load secure settings', asyncTest(async () => {
Setting.setObjectValue('encryption.passwordCache', 'testing', '123456');
await Setting.saveAll();
await Setting.load();
const passwords = Setting.value('encryption.passwordCache');
expect(passwords.testing).toBe('123456');
}));
});

View File

@@ -0,0 +1,94 @@
import KeychainService from 'lib/services/keychain/KeychainService';
import shim from 'lib/shim';
import Setting from 'lib/models/Setting';
const { db, asyncTest, setupDatabaseAndSynchronizer, switchClient } = require('test-utils.js');
function describeIfCompatible(name:string, fn:any) {
if (['win32', 'darwin'].includes(shim.platformName())) {
return describe(name, fn);
}
}
describeIfCompatible('services_KeychainService', function() {
beforeEach(async (done:Function) => {
await setupDatabaseAndSynchronizer(1, { keychainEnabled: true });
await switchClient(1, { keychainEnabled: true });
await Setting.deleteKeychainPasswords();
done();
});
afterEach(async (done:Function) => {
await Setting.deleteKeychainPasswords();
done();
});
it('should be enabled on macOS and Windows', asyncTest(async () => {
expect(Setting.value('keychain.supported')).toBe(1);
}));
it('should set, get and delete passwords', asyncTest(async () => {
const service = KeychainService.instance();
const isSet = await service.setPassword('zz_testunit', 'password');
expect(isSet).toBe(true);
const password = await service.password('zz_testunit');
expect(password).toBe('password');
await service.deletePassword('zz_testunit');
expect(await service.password('zz_testunit')).toBe(null);
}));
it('should save and load secure settings', asyncTest(async () => {
Setting.setObjectValue('encryption.passwordCache', 'testing', '123456');
await Setting.saveAll();
await Setting.load();
const passwords = Setting.value('encryption.passwordCache');
expect(passwords.testing).toBe('123456');
}));
it('should delete db settings if they have been saved in keychain', asyncTest(async () => {
// First save some secure settings and make sure it ends up in the databse
KeychainService.instance().enabled = false;
Setting.setValue('sync.5.password', 'password');
await Setting.saveAll();
{
// Check that it is in the database
const row = await db().selectOne('SELECT * FROM settings WHERE key = "sync.5.password"');
expect(row.value).toBe('password');
}
KeychainService.instance().enabled = true;
// Change any setting to make sure a save operation is triggered
Setting.setValue('sync.5.path', '/tmp');
// Save the settings - now db secure keys should have been cleared and moved to keychain
await Setting.saveAll();
{
// Check that it's been removed from the database
const row = await db().selectOne('SELECT * FROM settings WHERE key = "sync.5.password"');
expect(row).toBe(undefined);
}
// However we should still get it via the Setting class, since it will use the keychain
expect(Setting.value('sync.5.password')).toBe('password');
// Now do it again - because there was a bug that would cause the second attempt to save to the db instead
Setting.setValue('sync.5.username', 'john');
await Setting.saveAll();
{
// Check that it's been removed from the database
const row = await db().selectOne('SELECT * FROM settings WHERE key = "sync.5.password"');
expect(row).toBe(undefined);
}
}));
});

View File

@@ -146,7 +146,7 @@ describe('services_rest_Api', function() {
}));
const noteId = response.id;
{
const note = await Note.load(noteId);
expect(note.latitude).toBe('48.73207100');
@@ -154,7 +154,7 @@ describe('services_rest_Api', function() {
expect(note.altitude).toBe('21.0000');
}
await api.route('PUT', 'notes/' + noteId, null, JSON.stringify({
await api.route('PUT', `notes/${noteId}`, null, JSON.stringify({
latitude: '49',
longitude: '-3',
altitude: '22',
@@ -183,6 +183,59 @@ describe('services_rest_Api', function() {
expect(response.user_updated_time).toBe(updatedTime);
expect(response.user_created_time).toBe(createdTime);
const timeBefore = Date.now();
response = await api.route('POST', 'notes', null, JSON.stringify({
parent_id: f.id,
}));
const newNote = await Note.load(response.id);
expect(newNote.user_updated_time).toBeGreaterThanOrEqual(timeBefore);
expect(newNote.user_created_time).toBeGreaterThanOrEqual(timeBefore);
}));
it('should preserve user timestamps when updating notes', asyncTest(async () => {
const folder = await Folder.save({ title: 'mon carnet' });
const updatedTime = Date.now() - 1000;
const createdTime = Date.now() - 10000;
const response = await api.route('POST', 'notes', null, JSON.stringify({
parent_id: folder.id,
}));
const noteId = response.id;
{
// Check that if user timestamps are supplied, they are preserved by the API
await api.route('PUT', `notes/${noteId}`, null, JSON.stringify({
user_updated_time: updatedTime,
user_created_time: createdTime,
title: 'mod',
}));
const modNote = await Note.load(noteId);
expect(modNote.title).toBe('mod');
expect(modNote.user_updated_time).toBe(updatedTime);
expect(modNote.user_created_time).toBe(createdTime);
}
{
// Check if no user timestamps are supplied they are automatically updated.
const beforeTime = Date.now();
await api.route('PUT', `notes/${noteId}`, null, JSON.stringify({
title: 'mod2',
}));
const modNote = await Note.load(noteId);
expect(modNote.title).toBe('mod2');
expect(modNote.user_updated_time).toBeGreaterThanOrEqual(beforeTime);
expect(modNote.user_created_time).toBeGreaterThanOrEqual(createdTime);
}
}));
it('should create notes with supplied ID', asyncTest(async () => {

View File

@@ -3,6 +3,7 @@
"spec_files": [
"*.js",
"services/plugins/*.js",
"services/plugins/api/*.js",
"!test-utils.js"
],
"stopSpecOnExpectationFailure": false,

View File

@@ -0,0 +1,2 @@
dist/*
node_modules/

View File

@@ -0,0 +1,14 @@
# Joplin Plugin
This is a template to create a new Joplin plugin.
The main two files you will want to look at are:
- `/src/index.ts`, which contains the entry point for the plugin source code.
- `/src/manifest.json`, which is the plugin manifest. It contains information such as the plugin a name, version, etc.
The plugin is built using webpack, which create the compiled code in `/dist`. The project is setup to use TypeScript, although you can change the configuration to use plain JavaScript.
## Building the plugin
To build the plugin, simply run `npm run dist`.

View File

@@ -0,0 +1,15 @@
import Plugin from '../Plugin';
import Joplin from './Joplin';
import Logger from 'lib/Logger';
/**
* @ignore
*/
export default class Global {
private joplin_;
private requireWhiteList_;
constructor(logger: Logger, implementation: any, plugin: Plugin, store: any);
get joplin(): Joplin;
private requireWhiteList;
require(filePath: string): any;
get process(): any;
}

View File

@@ -0,0 +1,38 @@
import Plugin from '../Plugin';
import JoplinData from './JoplinData';
import JoplinPlugins from './JoplinPlugins';
import JoplinWorkspace from './JoplinWorkspace';
import JoplinFilters from './JoplinFilters';
import JoplinCommands from './JoplinCommands';
import JoplinViews from './JoplinViews';
import JoplinInterop from './JoplinInterop';
import JoplinSettings from './JoplinSettings';
import Logger from 'lib/Logger';
/**
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
*/
export default class Joplin {
private data_;
private plugins_;
private workspace_;
private filters_;
private commands_;
private views_;
private interop_;
private settings_;
constructor(logger: Logger, implementation: any, plugin: Plugin, store: any);
get data(): JoplinData;
get plugins(): JoplinPlugins;
get workspace(): JoplinWorkspace;
/**
* @ignore
*
* Not sure if it's the best way to hook into the app
* so for now disable filters.
*/
get filters(): JoplinFilters;
get commands(): JoplinCommands;
get views(): JoplinViews;
get interop(): JoplinInterop;
get settings(): JoplinSettings;
}

View File

@@ -0,0 +1,51 @@
import { Command } from './types';
/**
* This class allows executing or registering new Joplin commands. Commands can be executed or associated with
* {@link JoplinViewsToolbarButtons | toolbar buttons} or {@link JoplinViewsMenuItems | menu items}.
*
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/register_command)
*
* ## Executing Joplin's internal commands
*
* It is also possible to execute internal Joplin's commands which, as of now, are not well documented.
* You can find the list directly on GitHub though at the following locations:
*
* https://github.com/laurent22/joplin/tree/dev/ElectronClient/gui/MainScreen/commands
* https://github.com/laurent22/joplin/tree/dev/ElectronClient/commands
* https://github.com/laurent22/joplin/tree/dev/ElectronClient/gui/NoteEditor/commands/editorCommandDeclarations.ts
*
* To view what arguments are supported, you can open any of these files and look at the `execute()` command.
*/
export default class JoplinCommands {
/**
* <span class="platform-desktop">desktop</span> Executes the given command.
* The `props` are the arguments passed to the command, and they vary based on the command
*
* ```typescript
* // Create a new note in the current notebook:
* await joplin.commands.execute('newNote');
*
* // Create a new sub-notebook under the provided notebook
* // Note: internally, notebooks are called "folders".
* await joplin.commands.execute('newFolder', "SOME_FOLDER_ID");
* ```
*/
execute(commandName: string, ...args: any[]): Promise<any | void>;
/**
* <span class="platform-desktop">desktop</span> Registers a new command.
*
* ```typescript
* // Register a new commmand called "testCommand1"
*
* await joplin.commands.register({
* name: 'testCommand1',
* label: 'My Test Command 1',
* iconName: 'fas fa-music',
* execute: () => {
* alert('Testing plugin command 1');
* },
* });
* ```
*/
register(command: Command): Promise<void>;
}

View File

@@ -0,0 +1,47 @@
import { Path } from './types';
/**
* This module provides access to the Joplin data API: https://joplinapp.org/api/references/rest_api/
* This is the main way to retrieve data, such as notes, notebooks, tags, etc.
* or to update them or delete them.
*
* This is also what you would use to search notes, via the `search` endpoint.
*
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/simple)
*
* In general you would use the methods in this class as if you were using a REST API. There are four methods that map to GET, POST, PUT and DELETE calls.
* And each method takes these parameters:
*
* * `path`: This is an array that represents the path to the resource in the form `["resouceName", "resourceId", "resourceLink"]` (eg. ["tags", ":id", "notes"]). The "resources" segment is the name of the resources you want to access (eg. "notes", "folders", etc.). If not followed by anything, it will refer to all the resources in that collection. The optional "resourceId" points to a particular resources within the collection. Finally, an optional "link" can be present, which links the resource to a collection of resources. This can be used in the API for example to retrieve all the notes associated with a tag.
* * `query`: (Optional) The query parameters. In a URL, this is the part after the question mark "?". In this case, it should be an object with key/value pairs.
* * `data`: (Optional) Applies to PUT and POST calls only. The request body contains the data you want to create or modify, for example the content of a note or folder.
* * `files`: (Optional) Used to create new resources and associate them with files.
*
* Please refer to the [Joplin API documentation](https://joplinapp.org/api/references/rest_api/) for complete details about each call. As the plugin runs within the Joplin application **you do not need an authorisation token** to use this API.
*
* For example:
*
* ```typescript
* // Get a note ID, title and body
* const noteId = 'some_note_id';
* const note = await joplin.data.get(['notes', noteId], { fields: ['id', 'title', 'body'] });
*
* // Get all folders
* const folders = await joplin.data.get(['folders']);
*
* // Set the note body
* await joplin.data.put(['notes', noteId], null, { body: "New note body" });
*
* // Create a new note under one of the folders
* await joplin.data.post(['notes'], null, { body: "my new note", title: "some title", parent_id: folders[0].id });
* ```
*/
export default class JoplinData {
private api_;
private pathSegmentRegex_;
private serializeApiBody;
private pathToString;
get(path: Path, query?: any): Promise<any>;
post(path: Path, query?: any, body?: any, files?: any[]): Promise<any>;
put(path: Path, query?: any, body?: any, files?: any[]): Promise<any>;
delete(path: Path, query?: any): Promise<any>;
}

View File

@@ -0,0 +1,10 @@
/**
* @ignore
*
* Not sure if it's the best way to hook into the app
* so for now disable filters.
*/
export default class JoplinFilters {
on(name: string, callback: Function): Promise<void>;
off(name: string, callback: Function): Promise<void>;
}

View File

@@ -0,0 +1,17 @@
import { ExportModule, ImportModule } from './types';
/**
* Provides a way to create modules to import external data into Joplin or to export notes into any arbitrary format.
*
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/json_export)
*
* To implement an import or export module, you would simply define an object with various event handlers that are called
* by the application during the import/export process.
*
* See the documentation of the [[ExportModule]] and [[ImportModule]] for more information.
*
* You may also want to refer to the Joplin API documentation to see the list of properties for each item (note, notebook, etc.) - https://joplinapp.org/api/references/rest_api/
*/
export default class JoplinInterop {
registerExportModule(module: ExportModule): Promise<void>;
registerImportModule(module: ImportModule): Promise<void>;
}

View File

@@ -0,0 +1,38 @@
import Plugin from '../Plugin';
import Logger from 'lib/Logger';
import { ContentScriptType, Script } from './types';
/**
* This class provides access to plugin-related features.
*/
export default class JoplinPlugins {
private logger;
private plugin;
constructor(logger: Logger, plugin: Plugin);
/**
* Registers a new plugin. This is the entry point when creating a plugin. You should pass a simple object with an `onStart` method to it.
* That `onStart` method will be executed as soon as the plugin is loaded.
*
* ```typescript
* joplin.plugins.register({
* onStart: async function() {
* // Run your plugin code here
* }
* });
* ```
*/
register(script: Script): Promise<void>;
/**
* Registers a new content script. Unlike regular plugin code, which runs in a separate process, content scripts run within the main process code
* and thus allow improved performances and more customisations in specific cases. It can be used for example to load a Markdown or editor plugin.
*
* Note that registering a content script in itself will do nothing - it will only be loaded in specific cases by the relevant app modules
* (eg. the Markdown renderer or the code editor). So it is not a way to inject and run arbitrary code in the app, which for safety and performance reasons is not supported.
*
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/content_script)
*
* @param type Defines how the script will be used. See the type definition for more information about each supported type.
* @param id A unique ID for the content script.
* @param scriptPath Must be a path relative to the plugin main script. For example, if your file content_script.js is next to your index.ts file, you would set `scriptPath` to `"./content_script.js`.
*/
registerContentScript(type: ContentScriptType, id: string, scriptPath: string): Promise<void>;
}

View File

@@ -0,0 +1,43 @@
import Plugin from '../Plugin';
import { SettingItem, SettingSection } from './types';
/**
* This API allows registering new settings and setting sections, as well as getting and setting settings. Once a setting has been registered it will appear in the config screen and be editable by the user.
*
* Settings are essentially key/value pairs.
*
* Note: Currently this API does **not** provide access to Joplin's built-in settings. This is by design as plugins that modify user settings could give unexpected results
*
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/settings)
*/
export default class JoplinSettings {
private plugin_;
constructor(plugin: Plugin);
private namespacedKey;
/**
* Registers a new setting. Note that registering a setting item is dynamic and will be gone next time Joplin starts.
* What it means is that you need to register the setting every time the plugin starts (for example in the onStart event).
* The setting value however will be preserved from one launch to the next so there is no risk that it will be lost even if for some
* reason the plugin fails to start at some point.
*/
registerSetting(key: string, settingItem: SettingItem): Promise<void>;
/**
* Registers a new setting section. Like for registerSetting, it is dynamic and needs to be done every time the plugin starts.
*/
registerSection(name: string, section: SettingSection): Promise<void>;
/**
* Gets a setting value (only applies to setting you registered from your plugin)
*/
value(key: string): Promise<any>;
/**
* Sets a setting value (only applies to setting you registered from your plugin)
*/
setValue(key: string, value: any): Promise<void>;
/**
* Gets a global setting value, including app-specific settings and those set by other plugins.
*
* The list of available settings is not documented yet, but can be found by looking at the source code:
*
* https://github.com/laurent22/joplin/blob/3539a452a359162c461d2849829d2d42973eab50/ReactNativeClient/lib/models/Setting.ts#L142
*/
globalValue(key: string): Promise<any>;
}

View File

@@ -0,0 +1,28 @@
import Plugin from '../Plugin';
import JoplinViewsDialogs from './JoplinViewsDialogs';
import JoplinViewsMenuItems from './JoplinViewsMenuItems';
import JoplinViewsMenus from './JoplinViewsMenus';
import JoplinViewsToolbarButtons from './JoplinViewsToolbarButtons';
import JoplinViewsPanels from './JoplinViewsPanels';
/**
* This namespace provides access to view-related services.
*
* All view services provide a `create()` method which you would use to create the view object, whether it's a dialog, a toolbar button or a menu item.
* In some cases, the `create()` method will return a [[ViewHandle]], which you would use to act on the view, for example to set certain properties or call some methods.
*/
export default class JoplinViews {
private store;
private plugin;
private dialogs_;
private panels_;
private menuItems_;
private menus_;
private toolbarButtons_;
private implementation_;
constructor(implementation: any, plugin: Plugin, store: any);
get dialogs(): JoplinViewsDialogs;
get panels(): JoplinViewsPanels;
get menuItems(): JoplinViewsMenuItems;
get menus(): JoplinViewsMenus;
get toolbarButtons(): JoplinViewsToolbarButtons;
}

View File

@@ -0,0 +1,36 @@
import Plugin from '../Plugin';
import { ButtonSpec, ViewHandle, ButtonId } from './types';
/**
* Allows creating and managing dialogs. A dialog is modal window that contains a webview and a row of buttons. You can update the update the webview using the `setHtml` method.
* Dialogs are hidden by default and you need to call `open()` to open them. Once the user clicks on a button, the `open` call will return and provide the button ID that was
* clicked on. There is currently no "close" method since the dialog should be thought as a modal one and thus can only be closed by clicking on one of the buttons.
*
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/dialog)
*/
export default class JoplinViewsDialogs {
private store;
private plugin;
private implementation_;
constructor(implementation: any, plugin: Plugin, store: any);
private controller;
/**
* Creates a new dialog
*/
create(): Promise<ViewHandle>;
/**
* Displays a message box with OK/Cancel buttons. Returns the button index that was clicked - "0" for OK and "1" for "Cancel"
*/
showMessageBox(message: string): Promise<number>;
/**
* Sets the dialog HTML content
*/
setHtml(handle: ViewHandle, html: string): Promise<string>;
/**
* Sets the dialog buttons.
*/
setButtons(handle: ViewHandle, buttons: ButtonSpec[]): Promise<ButtonSpec[]>;
/**
* Opens the dialog
*/
open(handle: ViewHandle): Promise<ButtonId>;
}

View File

@@ -0,0 +1,16 @@
import { CreateMenuItemOptions, MenuItemLocation } from './types';
import Plugin from '../Plugin';
/**
* Allows creating and managing menu items.
*
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/register_command)
*/
export default class JoplinViewsMenuItems {
private store;
private plugin;
constructor(plugin: Plugin, store: any);
/**
* Creates a new menu item and associate it with the given command. You can specify under which menu the item should appear using the `location` parameter.
*/
create(commandName: string, location?: MenuItemLocation, options?: CreateMenuItemOptions): Promise<void>;
}

View File

@@ -0,0 +1,18 @@
import { MenuItem, MenuItemLocation } from './types';
import Plugin from '../Plugin';
/**
* Allows creating menus.
*
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/menu)
*/
export default class JoplinViewsMenus {
private store;
private plugin;
constructor(plugin: Plugin, store: any);
private registerCommandAccelerators;
/**
* Creates a new menu from the provided menu items and place it at the given location. As of now, it is only possible to place the
* menu as a sub-menu of the application build-in menus.
*/
create(label: string, menuItems: MenuItem[], location?: MenuItemLocation): Promise<void>;
}

View File

@@ -0,0 +1,30 @@
import Plugin from '../Plugin';
import { ViewHandle } from './types';
/**
* Allows creating and managing view panels. View panels currently are displayed at the right of the sidebar and allows displaying any HTML content (within a webview) and update it in real-time. For example
* it could be used to display a table of content for the active note, or display various metadata or graph.
*
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/toc)
*/
export default class JoplinViewsPanels {
private store;
private plugin;
constructor(plugin: Plugin, store: any);
private controller;
/**
* Creates a new panel
*/
create(): Promise<ViewHandle>;
/**
* Sets the panel webview HTML
*/
setHtml(handle: ViewHandle, html: string): Promise<string>;
/**
* Adds and loads a new JS or CSS files into the panel.
*/
addScript(handle: ViewHandle, scriptPath: string): Promise<void>;
/**
* Called when a message is sent from the webview (using postMessage).
*/
onMessage(handle: ViewHandle, callback: Function): Promise<void>;
}

View File

@@ -0,0 +1,16 @@
import { ToolbarButtonLocation } from './types';
import Plugin from '../Plugin';
/**
* Allows creating and managing toolbar buttons.
*
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/register_command)
*/
export default class JoplinViewsToolbarButtons {
private store;
private plugin;
constructor(plugin: Plugin, store: any);
/**
* Creates a new toolbar button and associate it with the given command.
*/
create(commandName: string, location: ToolbarButtonLocation): Promise<void>;
}

View File

@@ -0,0 +1,34 @@
/**
* The workspace service provides access to all the parts of Joplin that are being worked on - i.e. the currently selected notes or notebooks as well
* as various related events, such as when a new note is selected, or when the note content changes.
*
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins)
*/
export default class JoplinWorkspace {
private store;
constructor(_implementation: any, store: any);
/**
* Called when a new note or notes are selected.
*/
onNoteSelectionChange(callback: Function): Promise<void>;
/**
* Called when the content of a note changes.
*/
onNoteContentChange(callback: Function): Promise<void>;
/**
* Called when an alarm associated with a to-do is triggered.
*/
onNoteAlarmTrigger(callback: Function): Promise<void>;
/**
* Called when the synchronisation process has finished.
*/
onSyncComplete(callback: Function): Promise<void>;
/**
* Gets the currently selected note
*/
selectedNote(): Promise<any>;
/**
* Gets the IDs of the selected notes (can be zero, one, or many). Use the data API to retrieve information about these notes.
*/
selectedNoteIds(): Promise<string[]>;
}

View File

@@ -0,0 +1,5 @@
import type Joplin from './Joplin';
declare const joplin:Joplin;
export default joplin;

View File

@@ -0,0 +1,368 @@
// =================================================================
// Command API types
// =================================================================
export interface Command {
/**
* Name of command - must be globally unique
*/
name: string
/**
* Label to be displayed on menu items or keyboard shortcut editor for example.
* If it is missing, it's assumed it's a private command, to be called programmatically only.
* In that case the command will not appear in the shortcut editor or command panel, and logically
* should not be used as a menu item.
*/
label?: string
/**
* Icon to be used on toolbar buttons for example
*/
iconName?: string,
/**
* Code to be ran when the command is executed. It may return a result.
*/
execute(...args:any[]):Promise<any | void>
/**
* Defines whether the command should be enabled or disabled, which in turns affects
* the enabled state of any associated button or menu item.
*
* The condition should be expressed as a "when-clause" (as in Visual Studio Code). It's a simple boolean expression that evaluates to
* `true` or `false`. It supports the following operators:
*
* Operator | Symbol | Example
* -- | -- | --
* Equality | == | "editorType == markdown"
* Inequality | != | "currentScreen != config"
* Or | \|\| | "noteIsTodo \|\| noteTodoCompleted"
* And | && | "oneNoteSelected && !inConflictFolder"
*
* Currently the supported context variables aren't documented, but you can find the list there:
*
* https://github.com/laurent22/joplin/blob/dev/ReactNativeClient/lib/services/commands/stateToWhenClauseContext.ts
*
* Note: Commands are enabled by default unless you use this property.
*/
enabledCondition?: string
}
// =================================================================
// Interop API types
// =================================================================
export enum FileSystemItem {
File = 'file',
Directory = 'directory',
}
export enum ImportModuleOutputFormat {
Markdown = 'md',
Html = 'html',
}
/**
* Used to implement a module to export data from Joplin. [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/json_export) for an example.
*
* In general, all the event handlers you'll need to implement take a `context` object as a first argument. This object will contain the export or import path as well as various optional properties, such as which notes or notebooks need to be exported.
*
* To get a better sense of what it will contain it can be useful to print it using `console.info(context)`.
*/
export interface ExportModule {
/**
* The format to be exported, eg "enex", "jex", "json", etc.
*/
format: string,
/**
* The description that will appear in the UI, for example in the menu item.
*/
description: string,
/**
* Whether the module will export a single file or multiple files in a directory. It affects the open dialog that will be presented to the user when using your exporter.
*/
target: FileSystemItem,
/**
* Only applies to single file exporters or importers
* It tells whether the format can package multiple notes into one file.
* For example JEX or ENEX can, but HTML cannot.
*/
isNoteArchive: boolean,
/**
* The extensions of the files exported by your module. For example, it is `["htm", "html"]` for the HTML module, and just `["jex"]` for the JEX module.
*/
fileExtensions?: string[],
/**
* Called when the export process starts.
*/
onInit(context:ExportContext): Promise<void>;
/**
* Called when an item needs to be processed. An "item" can be any Joplin object, such as a note, a folder, a notebook, etc.
*/
onProcessItem(context:ExportContext, itemType:number, item:any):Promise<void>;
/**
* Called when a resource file needs to be exported.
*/
onProcessResource(context:ExportContext, resource:any, filePath:string):Promise<void>;
/**
* Called when the export process is done.
*/
onClose(context:ExportContext):Promise<void>;
}
export interface ImportModule {
/**
* The format to be exported, eg "enex", "jex", "json", etc.
*/
format: string,
/**
* The description that will appear in the UI, for example in the menu item.
*/
description: string,
/**
* Only applies to single file exporters or importers
* It tells whether the format can package multiple notes into one file.
* For example JEX or ENEX can, but HTML cannot.
*/
isNoteArchive: boolean,
/**
* The type of sources that are supported by the module. Tells whether the module can import files or directories or both.
*/
sources: FileSystemItem[],
/**
* Tells the file extensions of the exported files.
*/
fileExtensions?: string[],
/**
* Tells the type of notes that will be generated, either HTML or Markdown (default).
*/
outputFormat?: ImportModuleOutputFormat,
/**
* Called when the import process starts. There is only one event handler within which you should import the complete data.
*/
onExec(context:ImportContext): Promise<void>;
}
export interface ExportOptions {
format?: string,
path?:string,
sourceFolderIds?: string[],
sourceNoteIds?: string[],
modulePath?:string,
target?:FileSystemItem,
}
export interface ExportContext {
destPath: string,
options: ExportOptions,
/**
* You can attach your own custom data using this propery - it will then be passed to each event handler, allowing you to keep state from one event to the next.
*/
userData?: any,
}
export interface ImportContext {
sourcePath: string,
options: any,
warnings: string[],
}
// =================================================================
// Misc types
// =================================================================
export interface Script {
onStart?(event:any):Promise<void>,
}
// =================================================================
// Menu types
// =================================================================
export interface CreateMenuItemOptions {
accelerator: string,
}
export enum MenuItemLocation {
File = 'file',
Edit = 'edit',
View = 'view',
Note = 'note',
Tools = 'tools',
Help = 'help',
Context = 'context',
}
export interface MenuItem {
/**
* Command that should be associated with the menu item. All menu item should
* have a command associated with them unless they are a sub-menu.
*/
commandName?: string,
/**
* Accelerator associated with the menu item
*/
accelerator?: string,
/**
* Menu items that should appear below this menu item. Allows creating a menu tree.
*/
submenu?: MenuItem[],
/**
* Menu item label. If not specified, the command label will be used instead.
*/
label?: string,
}
// =================================================================
// View API types
// =================================================================
export interface ButtonSpec {
id: ButtonId,
title?: string,
onClick?():void,
}
export type ButtonId = string;
export enum ToolbarButtonLocation {
/**
* This toolbar in the top right corner of the application. It applies to the note as a whole, including its metadata.
*/
NoteToolbar = 'noteToolbar',
/**
* This toolbar is right above the text editor. It applies to the note body only.
*/
EditorToolbar = 'editorToolbar',
}
export type ViewHandle = string;
export interface EditorCommand {
name: string;
value?: any;
}
// =================================================================
// Settings types
// =================================================================
export enum SettingItemType {
Int = 1,
String = 2,
Bool = 3,
Array = 4,
Object = 5,
Button = 6,
}
// Redefine a simplified interface to mask internal details
// and to remove function calls as they would have to be async.
export interface SettingItem {
value: any,
type: SettingItemType,
public: boolean,
label:string,
description?:string,
isEnum?: boolean,
section?: string,
options?:any,
appTypes?:string[],
secure?: boolean,
advanced?: boolean,
minimum?: number,
maximum?: number,
step?: number,
}
export interface SettingSection {
label: string,
iconName?: string,
description?: string,
name?: string,
}
// =================================================================
// Data API types
// =================================================================
/**
* An array of at least one element and at most three elements.
*
* [0]: Resource name (eg. "notes", "folders", "tags", etc.)
* [1]: (Optional) Resource ID.
* [2]: (Optional) Resource link.
*/
export type Path = string[];
// =================================================================
// Plugins type
// =================================================================
export enum ContentScriptType {
/**
* Registers a new Markdown-It plugin, which should follow this template:
*
* ```javascript
* // The module should export an object as below:
*
* module.exports = {
*
* // The "context" variable is currently unused but could be used later on to provide
* // access to your own plugin so that the content script and plugin can communicate.
* default: function(context) {
* return {
*
* // This is the actual Markdown-It plugin - check the [official doc](https://github.com/markdown-it/markdown-it) for more information
* // The `options` parameter is of type [RuleOptions](https://github.com/laurent22/joplin/blob/dev/ReactNativeClient/lib/joplin-renderer/MdToHtml.ts), which
* // contains a number of options, mostly useful for Joplin's internal code.
* plugin: function(markdownIt, options) {
* // ...
* },
*
* // You may also specify additional assets such as JS or CSS that should be loaded in the rendered HTML document.
* // Check for example the Joplin [Mermaid plugin](https://github.com/laurent22/joplin/blob/dev/ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/mermaid.ts) to
* // see how the data should be structured.
* assets: {},
* }
* }
* }
* ```
*
* To include a regular Markdown-It plugin, that doesn't make use of any Joplin-specific feature, you
* would simply create a file such as this:
*
* ```javascript
* module.exports = {
* default: function(context) {
* return {
* plugin: require('markdown-it-toc-done-right');
* }
* }
* }
* ```
*/
MarkdownItPlugin = 'markdownItPlugin',
CodeMirrorPlugin = 'codeMirrorPlugin',
}

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,20 @@
{
"name": "joplin_plugin",
"version": "1.0.0",
"description": "",
"scripts": {
"dist": "webpack",
"postinstall": "npm run dist"
},
"keywords": [],
"author": "",
"license": "MIT",
"devDependencies": {
"@types/node": "^14.0.14",
"copy-webpack-plugin": "^6.1.0",
"ts-loader": "^7.0.5",
"typescript": "^3.9.3",
"webpack": "^4.43.0",
"webpack-cli": "^3.3.11"
}
}

View File

@@ -0,0 +1,7 @@
import joplin from 'api';
joplin.plugins.register({
onStart: async function() {
await joplin.plugins.registerContentScript('markdownItPlugin', 'justtesting', './markdownItTestPlugin.js');
},
});

View File

@@ -0,0 +1,8 @@
{
"manifest_version": 1,
"name": "Content Script Test",
"description": "",
"version": "1.0.0",
"author": "",
"homepage_url": ""
}

View File

@@ -0,0 +1,19 @@
function plugin(markdownIt, _options) {
const defaultRender = markdownIt.renderer.rules.fence || function(tokens, idx, options, env, self) {
return self.renderToken(tokens, idx, options, env, self);
};
markdownIt.renderer.rules.fence = function(tokens, idx, options, env, self) {
const token = tokens[idx];
if (token.info !== 'justtesting') return defaultRender(tokens, idx, options, env, self);
return `JUST TESTING: ${token.content}`;
};
}
module.exports = {
default: function(_context) {
return {
plugin: plugin,
}
},
}

View File

@@ -0,0 +1,10 @@
{
"compilerOptions": {
"outDir": "./dist/",
"module": "commonjs",
"target": "es2015",
"jsx": "react",
"allowJs": true,
"baseUrl": "."
}
}

View File

@@ -0,0 +1,44 @@
const path = require('path');
const CopyPlugin = require('copy-webpack-plugin');
module.exports = {
mode: 'production',
entry: './src/index.ts',
target: 'node',
module: {
rules: [
{
test: /\.tsx?$/,
use: 'ts-loader',
exclude: /node_modules/,
},
],
},
resolve: {
alias: {
api: path.resolve(__dirname, 'api')
},
extensions: [ '.tsx', '.ts', '.js' ],
},
output: {
filename: 'index.js',
path: path.resolve(__dirname, 'dist'),
},
plugins: [
new CopyPlugin({
patterns: [
{
from: "**/*",
context: path.resolve(__dirname, 'src'),
to: path.resolve(__dirname, 'dist'),
globOptions: {
ignore: [
'**/*.ts',
'**/*.tsx',
],
},
},
],
}),
],
};

View File

@@ -3,7 +3,7 @@ import { Command } from './types';
* This class allows executing or registering new Joplin commands. Commands can be executed or associated with
* {@link JoplinViewsToolbarButtons | toolbar buttons} or {@link JoplinViewsMenuItems | menu items}.
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/register_command)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/register_command)
*
* ## Executing Joplin's internal commands
*
@@ -27,10 +27,10 @@ export default class JoplinCommands {
*
* // Create a new sub-notebook under the provided notebook
* // Note: internally, notebooks are called "folders".
* await joplin.commands.execute('newFolder', { parent_id: "SOME_FOLDER_ID" });
* await joplin.commands.execute('newFolder', "SOME_FOLDER_ID");
* ```
*/
execute(commandName: string, props?: any): Promise<any>;
execute(commandName: string, ...args: any[]): Promise<any | void>;
/**
* <span class="platform-desktop">desktop</span> Registers a new command.
*

View File

@@ -1,12 +1,12 @@
import { Path } from './types';
/**
* This module provides access to the Joplin data API: https://joplinapp.org/api/
* This module provides access to the Joplin data API: https://joplinapp.org/api/references/rest_api/
* This is the main way to retrieve data, such as notes, notebooks, tags, etc.
* or to update them or delete them.
*
* This is also what you would use to search notes, via the `search` endpoint.
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/simple)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/simple)
*
* In general you would use the methods in this class as if you were using a REST API. There are four methods that map to GET, POST, PUT and DELETE calls.
* And each method takes these parameters:
@@ -16,7 +16,7 @@ import { Path } from './types';
* * `data`: (Optional) Applies to PUT and POST calls only. The request body contains the data you want to create or modify, for example the content of a note or folder.
* * `files`: (Optional) Used to create new resources and associate them with files.
*
* Please refer to the [Joplin API documentation](https://joplinapp.org/api/) for complete details about each call. As the plugin runs within the Joplin application **you do not need an authorisation token** to use this API.
* Please refer to the [Joplin API documentation](https://joplinapp.org/api/references/rest_api/) for complete details about each call. As the plugin runs within the Joplin application **you do not need an authorisation token** to use this API.
*
* For example:
*

View File

@@ -2,14 +2,14 @@ import { ExportModule, ImportModule } from './types';
/**
* Provides a way to create modules to import external data into Joplin or to export notes into any arbitrary format.
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/json_export)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/json_export)
*
* To implement an import or export module, you would simply define an object with various event handlers that are called
* by the application during the import/export process.
*
* See the documentation of the [[ExportModule]] and [[ImportModule]] for more information.
*
* You may also want to refer to the Joplin API documentation to see the list of properties for each item (note, notebook, etc.) - https://joplinapp.org/api/
* You may also want to refer to the Joplin API documentation to see the list of properties for each item (note, notebook, etc.) - https://joplinapp.org/api/references/rest_api/
*/
export default class JoplinInterop {
registerExportModule(module: ExportModule): Promise<void>;

View File

@@ -1,6 +1,6 @@
import Plugin from '../Plugin';
import Logger from 'lib/Logger';
import { Script } from './types';
import { ContentScriptType, Script } from './types';
/**
* This class provides access to plugin-related features.
*/
@@ -21,4 +21,18 @@ export default class JoplinPlugins {
* ```
*/
register(script: Script): Promise<void>;
/**
* Registers a new content script. Unlike regular plugin code, which runs in a separate process, content scripts run within the main process code
* and thus allow improved performances and more customisations in specific cases. It can be used for example to load a Markdown or editor plugin.
*
* Note that registering a content script in itself will do nothing - it will only be loaded in specific cases by the relevant app modules
* (eg. the Markdown renderer or the code editor). So it is not a way to inject and run arbitrary code in the app, which for safety and performance reasons is not supported.
*
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/content_script)
*
* @param type Defines how the script will be used. See the type definition for more information about each supported type.
* @param id A unique ID for the content script.
* @param scriptPath Must be a path relative to the plugin main script. For example, if your file content_script.js is next to your index.ts file, you would set `scriptPath` to `"./content_script.js`.
*/
registerContentScript(type: ContentScriptType, id: string, scriptPath: string): Promise<void>;
}

View File

@@ -7,7 +7,7 @@ import { SettingItem, SettingSection } from './types';
*
* Note: Currently this API does **not** provide access to Joplin's built-in settings. This is by design as plugins that modify user settings could give unexpected results
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/settings)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/settings)
*/
export default class JoplinSettings {
private plugin_;
@@ -32,4 +32,12 @@ export default class JoplinSettings {
* Sets a setting value (only applies to setting you registered from your plugin)
*/
setValue(key: string, value: any): Promise<void>;
/**
* Gets a global setting value, including app-specific settings and those set by other plugins.
*
* The list of available settings is not documented yet, but can be found by looking at the source code:
*
* https://github.com/laurent22/joplin/blob/3539a452a359162c461d2849829d2d42973eab50/ReactNativeClient/lib/models/Setting.ts#L142
*/
globalValue(key: string): Promise<any>;
}

View File

@@ -1,6 +1,7 @@
import Plugin from '../Plugin';
import JoplinViewsDialogs from './JoplinViewsDialogs';
import JoplinViewsMenuItems from './JoplinViewsMenuItems';
import JoplinViewsMenus from './JoplinViewsMenus';
import JoplinViewsToolbarButtons from './JoplinViewsToolbarButtons';
import JoplinViewsPanels from './JoplinViewsPanels';
/**
@@ -15,10 +16,13 @@ export default class JoplinViews {
private dialogs_;
private panels_;
private menuItems_;
private menus_;
private toolbarButtons_;
constructor(plugin: Plugin, store: any);
private implementation_;
constructor(implementation: any, plugin: Plugin, store: any);
get dialogs(): JoplinViewsDialogs;
get panels(): JoplinViewsPanels;
get menuItems(): JoplinViewsMenuItems;
get menus(): JoplinViewsMenus;
get toolbarButtons(): JoplinViewsToolbarButtons;
}

View File

@@ -5,17 +5,22 @@ import { ButtonSpec, ViewHandle, ButtonId } from './types';
* Dialogs are hidden by default and you need to call `open()` to open them. Once the user clicks on a button, the `open` call will return and provide the button ID that was
* clicked on. There is currently no "close" method since the dialog should be thought as a modal one and thus can only be closed by clicking on one of the buttons.
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/dialog)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/dialog)
*/
export default class JoplinViewsDialogs {
private store;
private plugin;
constructor(plugin: Plugin, store: any);
private implementation_;
constructor(implementation: any, plugin: Plugin, store: any);
private controller;
/**
* Creates a new dialog
*/
create(): Promise<ViewHandle>;
/**
* Displays a message box with OK/Cancel buttons. Returns the button index that was clicked - "0" for OK and "1" for "Cancel"
*/
showMessageBox(message: string): Promise<number>;
/**
* Sets the dialog HTML content
*/

View File

@@ -3,7 +3,7 @@ import Plugin from '../Plugin';
/**
* Allows creating and managing menu items.
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/register_command)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/register_command)
*/
export default class JoplinViewsMenuItems {
private store;

View File

@@ -0,0 +1,18 @@
import { MenuItem, MenuItemLocation } from './types';
import Plugin from '../Plugin';
/**
* Allows creating menus.
*
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/menu)
*/
export default class JoplinViewsMenus {
private store;
private plugin;
constructor(plugin: Plugin, store: any);
private registerCommandAccelerators;
/**
* Creates a new menu from the provided menu items and place it at the given location. As of now, it is only possible to place the
* menu as a sub-menu of the application build-in menus.
*/
create(label: string, menuItems: MenuItem[], location?: MenuItemLocation): Promise<void>;
}

View File

@@ -4,7 +4,7 @@ import { ViewHandle } from './types';
* Allows creating and managing view panels. View panels currently are displayed at the right of the sidebar and allows displaying any HTML content (within a webview) and update it in real-time. For example
* it could be used to display a table of content for the active note, or display various metadata or graph.
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/toc)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/toc)
*/
export default class JoplinViewsPanels {
private store;

View File

@@ -3,7 +3,7 @@ import Plugin from '../Plugin';
/**
* Allows creating and managing toolbar buttons.
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/register_command)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/register_command)
*/
export default class JoplinViewsToolbarButtons {
private store;

View File

@@ -2,7 +2,7 @@
* The workspace service provides access to all the parts of Joplin that are being worked on - i.e. the currently selected notes or notebooks as well
* as various related events, such as when a new note is selected, or when the note content changes.
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins)
*/
export default class JoplinWorkspace {
private store;

View File

@@ -3,12 +3,50 @@
// =================================================================
export interface Command {
/**
* Name of command - must be globally unique
*/
name: string
label: string
/**
* Label to be displayed on menu items or keyboard shortcut editor for example.
* If it is missing, it's assumed it's a private command, to be called programmatically only.
* In that case the command will not appear in the shortcut editor or command panel, and logically
* should not be used as a menu item.
*/
label?: string
/**
* Icon to be used on toolbar buttons for example
*/
iconName?: string,
execute(props:any):Promise<any>
isEnabled?(props:any):boolean
mapStateToProps?(state:any):any
/**
* Code to be ran when the command is executed. It may return a result.
*/
execute(...args:any[]):Promise<any | void>
/**
* Defines whether the command should be enabled or disabled, which in turns affects
* the enabled state of any associated button or menu item.
*
* The condition should be expressed as a "when-clause" (as in Visual Studio Code). It's a simple boolean expression that evaluates to
* `true` or `false`. It supports the following operators:
*
* Operator | Symbol | Example
* -- | -- | --
* Equality | == | "editorType == markdown"
* Inequality | != | "currentScreen != config"
* Or | \|\| | "noteIsTodo \|\| noteTodoCompleted"
* And | && | "oneNoteSelected && !inConflictFolder"
*
* Currently the supported context variables aren't documented, but you can find the list there:
*
* https://github.com/laurent22/joplin/blob/dev/ReactNativeClient/lib/services/commands/stateToWhenClauseContext.ts
*
* Note: Commands are enabled by default unless you use this property.
*/
enabledCondition?: string
}
// =================================================================
@@ -26,7 +64,7 @@ export enum ImportModuleOutputFormat {
}
/**
* Used to implement a module to export data from Joplin. [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/json_export) for an example.
* Used to implement a module to export data from Joplin. [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/json_export) for an example.
*
* In general, all the event handlers you'll need to implement take a `context` object as a first argument. This object will contain the export or import path as well as various optional properties, such as which notes or notebooks need to be exported.
*
@@ -154,17 +192,9 @@ export interface Script {
}
// =================================================================
// View API types
// Menu types
// =================================================================
export type ButtonId = string;
export interface ButtonSpec {
id: ButtonId,
title?: string,
onClick?():void,
}
export interface CreateMenuItemOptions {
accelerator: string,
}
@@ -179,6 +209,41 @@ export enum MenuItemLocation {
Context = 'context',
}
export interface MenuItem {
/**
* Command that should be associated with the menu item. All menu item should
* have a command associated with them unless they are a sub-menu.
*/
commandName?: string,
/**
* Accelerator associated with the menu item
*/
accelerator?: string,
/**
* Menu items that should appear below this menu item. Allows creating a menu tree.
*/
submenu?: MenuItem[],
/**
* Menu item label. If not specified, the command label will be used instead.
*/
label?: string,
}
// =================================================================
// View API types
// =================================================================
export interface ButtonSpec {
id: ButtonId,
title?: string,
onClick?():void,
}
export type ButtonId = string;
export enum ToolbarButtonLocation {
/**
* This toolbar in the top right corner of the application. It applies to the note as a whole, including its metadata.
@@ -250,3 +315,54 @@ export interface SettingSection {
* [2]: (Optional) Resource link.
*/
export type Path = string[];
// =================================================================
// Plugins type
// =================================================================
export enum ContentScriptType {
/**
* Registers a new Markdown-It plugin, which should follow this template:
*
* ```javascript
* // The module should export an object as below:
*
* module.exports = {
*
* // The "context" variable is currently unused but could be used later on to provide
* // access to your own plugin so that the content script and plugin can communicate.
* default: function(context) {
* return {
*
* // This is the actual Markdown-It plugin - check the [official doc](https://github.com/markdown-it/markdown-it) for more information
* // The `options` parameter is of type [RuleOptions](https://github.com/laurent22/joplin/blob/dev/ReactNativeClient/lib/joplin-renderer/MdToHtml.ts), which
* // contains a number of options, mostly useful for Joplin's internal code.
* plugin: function(markdownIt, options) {
* // ...
* },
*
* // You may also specify additional assets such as JS or CSS that should be loaded in the rendered HTML document.
* // Check for example the Joplin [Mermaid plugin](https://github.com/laurent22/joplin/blob/dev/ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/mermaid.ts) to
* // see how the data should be structured.
* assets: {},
* }
* }
* }
* ```
*
* To include a regular Markdown-It plugin, that doesn't make use of any Joplin-specific feature, you
* would simply create a file such as this:
*
* ```javascript
* module.exports = {
* default: function(context) {
* return {
* plugin: require('markdown-it-toc-done-right');
* }
* }
* }
* ```
*/
MarkdownItPlugin = 'markdownItPlugin',
CodeMirrorPlugin = 'codeMirrorPlugin',
}

View File

@@ -3,7 +3,7 @@ import { Command } from './types';
* This class allows executing or registering new Joplin commands. Commands can be executed or associated with
* {@link JoplinViewsToolbarButtons | toolbar buttons} or {@link JoplinViewsMenuItems | menu items}.
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/register_command)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/register_command)
*
* ## Executing Joplin's internal commands
*
@@ -27,10 +27,10 @@ export default class JoplinCommands {
*
* // Create a new sub-notebook under the provided notebook
* // Note: internally, notebooks are called "folders".
* await joplin.commands.execute('newFolder', { parent_id: "SOME_FOLDER_ID" });
* await joplin.commands.execute('newFolder', "SOME_FOLDER_ID");
* ```
*/
execute(commandName: string, props?: any): Promise<any>;
execute(commandName: string, ...args: any[]): Promise<any | void>;
/**
* <span class="platform-desktop">desktop</span> Registers a new command.
*

View File

@@ -1,12 +1,12 @@
import { Path } from './types';
/**
* This module provides access to the Joplin data API: https://joplinapp.org/api/
* This module provides access to the Joplin data API: https://joplinapp.org/api/references/rest_api/
* This is the main way to retrieve data, such as notes, notebooks, tags, etc.
* or to update them or delete them.
*
* This is also what you would use to search notes, via the `search` endpoint.
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/simple)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/simple)
*
* In general you would use the methods in this class as if you were using a REST API. There are four methods that map to GET, POST, PUT and DELETE calls.
* And each method takes these parameters:
@@ -16,7 +16,7 @@ import { Path } from './types';
* * `data`: (Optional) Applies to PUT and POST calls only. The request body contains the data you want to create or modify, for example the content of a note or folder.
* * `files`: (Optional) Used to create new resources and associate them with files.
*
* Please refer to the [Joplin API documentation](https://joplinapp.org/api/) for complete details about each call. As the plugin runs within the Joplin application **you do not need an authorisation token** to use this API.
* Please refer to the [Joplin API documentation](https://joplinapp.org/api/references/rest_api/) for complete details about each call. As the plugin runs within the Joplin application **you do not need an authorisation token** to use this API.
*
* For example:
*

View File

@@ -2,14 +2,14 @@ import { ExportModule, ImportModule } from './types';
/**
* Provides a way to create modules to import external data into Joplin or to export notes into any arbitrary format.
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/json_export)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/json_export)
*
* To implement an import or export module, you would simply define an object with various event handlers that are called
* by the application during the import/export process.
*
* See the documentation of the [[ExportModule]] and [[ImportModule]] for more information.
*
* You may also want to refer to the Joplin API documentation to see the list of properties for each item (note, notebook, etc.) - https://joplinapp.org/api/
* You may also want to refer to the Joplin API documentation to see the list of properties for each item (note, notebook, etc.) - https://joplinapp.org/api/references/rest_api/
*/
export default class JoplinInterop {
registerExportModule(module: ExportModule): Promise<void>;

View File

@@ -1,6 +1,6 @@
import Plugin from '../Plugin';
import Logger from 'lib/Logger';
import { Script } from './types';
import { ContentScriptType, Script } from './types';
/**
* This class provides access to plugin-related features.
*/
@@ -21,4 +21,18 @@ export default class JoplinPlugins {
* ```
*/
register(script: Script): Promise<void>;
/**
* Registers a new content script. Unlike regular plugin code, which runs in a separate process, content scripts run within the main process code
* and thus allow improved performances and more customisations in specific cases. It can be used for example to load a Markdown or editor plugin.
*
* Note that registering a content script in itself will do nothing - it will only be loaded in specific cases by the relevant app modules
* (eg. the Markdown renderer or the code editor). So it is not a way to inject and run arbitrary code in the app, which for safety and performance reasons is not supported.
*
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/content_script)
*
* @param type Defines how the script will be used. See the type definition for more information about each supported type.
* @param id A unique ID for the content script.
* @param scriptPath Must be a path relative to the plugin main script. For example, if your file content_script.js is next to your index.ts file, you would set `scriptPath` to `"./content_script.js`.
*/
registerContentScript(type: ContentScriptType, id: string, scriptPath: string): Promise<void>;
}

View File

@@ -7,7 +7,7 @@ import { SettingItem, SettingSection } from './types';
*
* Note: Currently this API does **not** provide access to Joplin's built-in settings. This is by design as plugins that modify user settings could give unexpected results
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/settings)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/settings)
*/
export default class JoplinSettings {
private plugin_;
@@ -32,4 +32,12 @@ export default class JoplinSettings {
* Sets a setting value (only applies to setting you registered from your plugin)
*/
setValue(key: string, value: any): Promise<void>;
/**
* Gets a global setting value, including app-specific settings and those set by other plugins.
*
* The list of available settings is not documented yet, but can be found by looking at the source code:
*
* https://github.com/laurent22/joplin/blob/3539a452a359162c461d2849829d2d42973eab50/ReactNativeClient/lib/models/Setting.ts#L142
*/
globalValue(key: string): Promise<any>;
}

View File

@@ -1,6 +1,7 @@
import Plugin from '../Plugin';
import JoplinViewsDialogs from './JoplinViewsDialogs';
import JoplinViewsMenuItems from './JoplinViewsMenuItems';
import JoplinViewsMenus from './JoplinViewsMenus';
import JoplinViewsToolbarButtons from './JoplinViewsToolbarButtons';
import JoplinViewsPanels from './JoplinViewsPanels';
/**
@@ -15,10 +16,13 @@ export default class JoplinViews {
private dialogs_;
private panels_;
private menuItems_;
private menus_;
private toolbarButtons_;
constructor(plugin: Plugin, store: any);
private implementation_;
constructor(implementation: any, plugin: Plugin, store: any);
get dialogs(): JoplinViewsDialogs;
get panels(): JoplinViewsPanels;
get menuItems(): JoplinViewsMenuItems;
get menus(): JoplinViewsMenus;
get toolbarButtons(): JoplinViewsToolbarButtons;
}

View File

@@ -5,17 +5,22 @@ import { ButtonSpec, ViewHandle, ButtonId } from './types';
* Dialogs are hidden by default and you need to call `open()` to open them. Once the user clicks on a button, the `open` call will return and provide the button ID that was
* clicked on. There is currently no "close" method since the dialog should be thought as a modal one and thus can only be closed by clicking on one of the buttons.
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/dialog)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/dialog)
*/
export default class JoplinViewsDialogs {
private store;
private plugin;
constructor(plugin: Plugin, store: any);
private implementation_;
constructor(implementation: any, plugin: Plugin, store: any);
private controller;
/**
* Creates a new dialog
*/
create(): Promise<ViewHandle>;
/**
* Displays a message box with OK/Cancel buttons. Returns the button index that was clicked - "0" for OK and "1" for "Cancel"
*/
showMessageBox(message: string): Promise<number>;
/**
* Sets the dialog HTML content
*/

View File

@@ -3,7 +3,7 @@ import Plugin from '../Plugin';
/**
* Allows creating and managing menu items.
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/register_command)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/register_command)
*/
export default class JoplinViewsMenuItems {
private store;

View File

@@ -0,0 +1,18 @@
import { MenuItem, MenuItemLocation } from './types';
import Plugin from '../Plugin';
/**
* Allows creating menus.
*
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/menu)
*/
export default class JoplinViewsMenus {
private store;
private plugin;
constructor(plugin: Plugin, store: any);
private registerCommandAccelerators;
/**
* Creates a new menu from the provided menu items and place it at the given location. As of now, it is only possible to place the
* menu as a sub-menu of the application build-in menus.
*/
create(label: string, menuItems: MenuItem[], location?: MenuItemLocation): Promise<void>;
}

View File

@@ -4,7 +4,7 @@ import { ViewHandle } from './types';
* Allows creating and managing view panels. View panels currently are displayed at the right of the sidebar and allows displaying any HTML content (within a webview) and update it in real-time. For example
* it could be used to display a table of content for the active note, or display various metadata or graph.
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/toc)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/toc)
*/
export default class JoplinViewsPanels {
private store;

View File

@@ -3,7 +3,7 @@ import Plugin from '../Plugin';
/**
* Allows creating and managing toolbar buttons.
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/register_command)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/register_command)
*/
export default class JoplinViewsToolbarButtons {
private store;

View File

@@ -2,7 +2,7 @@
* The workspace service provides access to all the parts of Joplin that are being worked on - i.e. the currently selected notes or notebooks as well
* as various related events, such as when a new note is selected, or when the note content changes.
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins)
*/
export default class JoplinWorkspace {
private store;

View File

@@ -3,12 +3,50 @@
// =================================================================
export interface Command {
/**
* Name of command - must be globally unique
*/
name: string
label: string
/**
* Label to be displayed on menu items or keyboard shortcut editor for example.
* If it is missing, it's assumed it's a private command, to be called programmatically only.
* In that case the command will not appear in the shortcut editor or command panel, and logically
* should not be used as a menu item.
*/
label?: string
/**
* Icon to be used on toolbar buttons for example
*/
iconName?: string,
execute(props:any):Promise<any>
isEnabled?(props:any):boolean
mapStateToProps?(state:any):any
/**
* Code to be ran when the command is executed. It may return a result.
*/
execute(...args:any[]):Promise<any | void>
/**
* Defines whether the command should be enabled or disabled, which in turns affects
* the enabled state of any associated button or menu item.
*
* The condition should be expressed as a "when-clause" (as in Visual Studio Code). It's a simple boolean expression that evaluates to
* `true` or `false`. It supports the following operators:
*
* Operator | Symbol | Example
* -- | -- | --
* Equality | == | "editorType == markdown"
* Inequality | != | "currentScreen != config"
* Or | \|\| | "noteIsTodo \|\| noteTodoCompleted"
* And | && | "oneNoteSelected && !inConflictFolder"
*
* Currently the supported context variables aren't documented, but you can find the list there:
*
* https://github.com/laurent22/joplin/blob/dev/ReactNativeClient/lib/services/commands/stateToWhenClauseContext.ts
*
* Note: Commands are enabled by default unless you use this property.
*/
enabledCondition?: string
}
// =================================================================
@@ -26,7 +64,7 @@ export enum ImportModuleOutputFormat {
}
/**
* Used to implement a module to export data from Joplin. [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/json_export) for an example.
* Used to implement a module to export data from Joplin. [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/json_export) for an example.
*
* In general, all the event handlers you'll need to implement take a `context` object as a first argument. This object will contain the export or import path as well as various optional properties, such as which notes or notebooks need to be exported.
*
@@ -154,17 +192,9 @@ export interface Script {
}
// =================================================================
// View API types
// Menu types
// =================================================================
export type ButtonId = string;
export interface ButtonSpec {
id: ButtonId,
title?: string,
onClick?():void,
}
export interface CreateMenuItemOptions {
accelerator: string,
}
@@ -179,6 +209,41 @@ export enum MenuItemLocation {
Context = 'context',
}
export interface MenuItem {
/**
* Command that should be associated with the menu item. All menu item should
* have a command associated with them unless they are a sub-menu.
*/
commandName?: string,
/**
* Accelerator associated with the menu item
*/
accelerator?: string,
/**
* Menu items that should appear below this menu item. Allows creating a menu tree.
*/
submenu?: MenuItem[],
/**
* Menu item label. If not specified, the command label will be used instead.
*/
label?: string,
}
// =================================================================
// View API types
// =================================================================
export interface ButtonSpec {
id: ButtonId,
title?: string,
onClick?():void,
}
export type ButtonId = string;
export enum ToolbarButtonLocation {
/**
* This toolbar in the top right corner of the application. It applies to the note as a whole, including its metadata.
@@ -250,3 +315,54 @@ export interface SettingSection {
* [2]: (Optional) Resource link.
*/
export type Path = string[];
// =================================================================
// Plugins type
// =================================================================
export enum ContentScriptType {
/**
* Registers a new Markdown-It plugin, which should follow this template:
*
* ```javascript
* // The module should export an object as below:
*
* module.exports = {
*
* // The "context" variable is currently unused but could be used later on to provide
* // access to your own plugin so that the content script and plugin can communicate.
* default: function(context) {
* return {
*
* // This is the actual Markdown-It plugin - check the [official doc](https://github.com/markdown-it/markdown-it) for more information
* // The `options` parameter is of type [RuleOptions](https://github.com/laurent22/joplin/blob/dev/ReactNativeClient/lib/joplin-renderer/MdToHtml.ts), which
* // contains a number of options, mostly useful for Joplin's internal code.
* plugin: function(markdownIt, options) {
* // ...
* },
*
* // You may also specify additional assets such as JS or CSS that should be loaded in the rendered HTML document.
* // Check for example the Joplin [Mermaid plugin](https://github.com/laurent22/joplin/blob/dev/ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/mermaid.ts) to
* // see how the data should be structured.
* assets: {},
* }
* }
* }
* ```
*
* To include a regular Markdown-It plugin, that doesn't make use of any Joplin-specific feature, you
* would simply create a file such as this:
*
* ```javascript
* module.exports = {
* default: function(context) {
* return {
* plugin: require('markdown-it-toc-done-right');
* }
* }
* }
* ```
*/
MarkdownItPlugin = 'markdownItPlugin',
CodeMirrorPlugin = 'codeMirrorPlugin',
}

View File

@@ -0,0 +1,16 @@
/* joplin-manifest:
{
"manifest_version": 1,
"name": "JS Bundle test",
"description": "JS Bundle Test plugin",
"version": "1.0.0",
"author": "Laurent Cozic",
"homepage_url": "https://joplinapp.org"
}
*/
joplin.plugins.register({
onStart: async function() {
await joplin.data.post(['folders'], null, { title: "my plugin folder" });
},
});

View File

@@ -3,7 +3,7 @@ import { Command } from './types';
* This class allows executing or registering new Joplin commands. Commands can be executed or associated with
* {@link JoplinViewsToolbarButtons | toolbar buttons} or {@link JoplinViewsMenuItems | menu items}.
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/register_command)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/register_command)
*
* ## Executing Joplin's internal commands
*
@@ -27,10 +27,10 @@ export default class JoplinCommands {
*
* // Create a new sub-notebook under the provided notebook
* // Note: internally, notebooks are called "folders".
* await joplin.commands.execute('newFolder', { parent_id: "SOME_FOLDER_ID" });
* await joplin.commands.execute('newFolder', "SOME_FOLDER_ID");
* ```
*/
execute(commandName: string, props?: any): Promise<any>;
execute(commandName: string, ...args: any[]): Promise<any | void>;
/**
* <span class="platform-desktop">desktop</span> Registers a new command.
*

View File

@@ -1,12 +1,12 @@
import { Path } from './types';
/**
* This module provides access to the Joplin data API: https://joplinapp.org/api/
* This module provides access to the Joplin data API: https://joplinapp.org/api/references/rest_api/
* This is the main way to retrieve data, such as notes, notebooks, tags, etc.
* or to update them or delete them.
*
* This is also what you would use to search notes, via the `search` endpoint.
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/simple)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/simple)
*
* In general you would use the methods in this class as if you were using a REST API. There are four methods that map to GET, POST, PUT and DELETE calls.
* And each method takes these parameters:
@@ -16,7 +16,7 @@ import { Path } from './types';
* * `data`: (Optional) Applies to PUT and POST calls only. The request body contains the data you want to create or modify, for example the content of a note or folder.
* * `files`: (Optional) Used to create new resources and associate them with files.
*
* Please refer to the [Joplin API documentation](https://joplinapp.org/api/) for complete details about each call. As the plugin runs within the Joplin application **you do not need an authorisation token** to use this API.
* Please refer to the [Joplin API documentation](https://joplinapp.org/api/references/rest_api/) for complete details about each call. As the plugin runs within the Joplin application **you do not need an authorisation token** to use this API.
*
* For example:
*

View File

@@ -2,14 +2,14 @@ import { ExportModule, ImportModule } from './types';
/**
* Provides a way to create modules to import external data into Joplin or to export notes into any arbitrary format.
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/json_export)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/json_export)
*
* To implement an import or export module, you would simply define an object with various event handlers that are called
* by the application during the import/export process.
*
* See the documentation of the [[ExportModule]] and [[ImportModule]] for more information.
*
* You may also want to refer to the Joplin API documentation to see the list of properties for each item (note, notebook, etc.) - https://joplinapp.org/api/
* You may also want to refer to the Joplin API documentation to see the list of properties for each item (note, notebook, etc.) - https://joplinapp.org/api/references/rest_api/
*/
export default class JoplinInterop {
registerExportModule(module: ExportModule): Promise<void>;

View File

@@ -1,6 +1,6 @@
import Plugin from '../Plugin';
import Logger from 'lib/Logger';
import { Script } from './types';
import { ContentScriptType, Script } from './types';
/**
* This class provides access to plugin-related features.
*/
@@ -21,4 +21,18 @@ export default class JoplinPlugins {
* ```
*/
register(script: Script): Promise<void>;
/**
* Registers a new content script. Unlike regular plugin code, which runs in a separate process, content scripts run within the main process code
* and thus allow improved performances and more customisations in specific cases. It can be used for example to load a Markdown or editor plugin.
*
* Note that registering a content script in itself will do nothing - it will only be loaded in specific cases by the relevant app modules
* (eg. the Markdown renderer or the code editor). So it is not a way to inject and run arbitrary code in the app, which for safety and performance reasons is not supported.
*
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/content_script)
*
* @param type Defines how the script will be used. See the type definition for more information about each supported type.
* @param id A unique ID for the content script.
* @param scriptPath Must be a path relative to the plugin main script. For example, if your file content_script.js is next to your index.ts file, you would set `scriptPath` to `"./content_script.js`.
*/
registerContentScript(type: ContentScriptType, id: string, scriptPath: string): Promise<void>;
}

View File

@@ -7,7 +7,7 @@ import { SettingItem, SettingSection } from './types';
*
* Note: Currently this API does **not** provide access to Joplin's built-in settings. This is by design as plugins that modify user settings could give unexpected results
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/settings)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/settings)
*/
export default class JoplinSettings {
private plugin_;
@@ -32,4 +32,12 @@ export default class JoplinSettings {
* Sets a setting value (only applies to setting you registered from your plugin)
*/
setValue(key: string, value: any): Promise<void>;
/**
* Gets a global setting value, including app-specific settings and those set by other plugins.
*
* The list of available settings is not documented yet, but can be found by looking at the source code:
*
* https://github.com/laurent22/joplin/blob/3539a452a359162c461d2849829d2d42973eab50/ReactNativeClient/lib/models/Setting.ts#L142
*/
globalValue(key: string): Promise<any>;
}

View File

@@ -1,6 +1,7 @@
import Plugin from '../Plugin';
import JoplinViewsDialogs from './JoplinViewsDialogs';
import JoplinViewsMenuItems from './JoplinViewsMenuItems';
import JoplinViewsMenus from './JoplinViewsMenus';
import JoplinViewsToolbarButtons from './JoplinViewsToolbarButtons';
import JoplinViewsPanels from './JoplinViewsPanels';
/**
@@ -15,10 +16,13 @@ export default class JoplinViews {
private dialogs_;
private panels_;
private menuItems_;
private menus_;
private toolbarButtons_;
constructor(plugin: Plugin, store: any);
private implementation_;
constructor(implementation: any, plugin: Plugin, store: any);
get dialogs(): JoplinViewsDialogs;
get panels(): JoplinViewsPanels;
get menuItems(): JoplinViewsMenuItems;
get menus(): JoplinViewsMenus;
get toolbarButtons(): JoplinViewsToolbarButtons;
}

View File

@@ -5,17 +5,22 @@ import { ButtonSpec, ViewHandle, ButtonId } from './types';
* Dialogs are hidden by default and you need to call `open()` to open them. Once the user clicks on a button, the `open` call will return and provide the button ID that was
* clicked on. There is currently no "close" method since the dialog should be thought as a modal one and thus can only be closed by clicking on one of the buttons.
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/dialog)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/dialog)
*/
export default class JoplinViewsDialogs {
private store;
private plugin;
constructor(plugin: Plugin, store: any);
private implementation_;
constructor(implementation: any, plugin: Plugin, store: any);
private controller;
/**
* Creates a new dialog
*/
create(): Promise<ViewHandle>;
/**
* Displays a message box with OK/Cancel buttons. Returns the button index that was clicked - "0" for OK and "1" for "Cancel"
*/
showMessageBox(message: string): Promise<number>;
/**
* Sets the dialog HTML content
*/

View File

@@ -3,7 +3,7 @@ import Plugin from '../Plugin';
/**
* Allows creating and managing menu items.
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/register_command)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/register_command)
*/
export default class JoplinViewsMenuItems {
private store;

View File

@@ -0,0 +1,18 @@
import { MenuItem, MenuItemLocation } from './types';
import Plugin from '../Plugin';
/**
* Allows creating menus.
*
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/menu)
*/
export default class JoplinViewsMenus {
private store;
private plugin;
constructor(plugin: Plugin, store: any);
private registerCommandAccelerators;
/**
* Creates a new menu from the provided menu items and place it at the given location. As of now, it is only possible to place the
* menu as a sub-menu of the application build-in menus.
*/
create(label: string, menuItems: MenuItem[], location?: MenuItemLocation): Promise<void>;
}

View File

@@ -4,7 +4,7 @@ import { ViewHandle } from './types';
* Allows creating and managing view panels. View panels currently are displayed at the right of the sidebar and allows displaying any HTML content (within a webview) and update it in real-time. For example
* it could be used to display a table of content for the active note, or display various metadata or graph.
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/toc)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/toc)
*/
export default class JoplinViewsPanels {
private store;

View File

@@ -3,7 +3,7 @@ import Plugin from '../Plugin';
/**
* Allows creating and managing toolbar buttons.
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/register_command)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/register_command)
*/
export default class JoplinViewsToolbarButtons {
private store;

View File

@@ -2,7 +2,7 @@
* The workspace service provides access to all the parts of Joplin that are being worked on - i.e. the currently selected notes or notebooks as well
* as various related events, such as when a new note is selected, or when the note content changes.
*
* [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins)
* [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins)
*/
export default class JoplinWorkspace {
private store;

View File

@@ -3,12 +3,50 @@
// =================================================================
export interface Command {
/**
* Name of command - must be globally unique
*/
name: string
label: string
/**
* Label to be displayed on menu items or keyboard shortcut editor for example.
* If it is missing, it's assumed it's a private command, to be called programmatically only.
* In that case the command will not appear in the shortcut editor or command panel, and logically
* should not be used as a menu item.
*/
label?: string
/**
* Icon to be used on toolbar buttons for example
*/
iconName?: string,
execute(props:any):Promise<any>
isEnabled?(props:any):boolean
mapStateToProps?(state:any):any
/**
* Code to be ran when the command is executed. It may return a result.
*/
execute(...args:any[]):Promise<any | void>
/**
* Defines whether the command should be enabled or disabled, which in turns affects
* the enabled state of any associated button or menu item.
*
* The condition should be expressed as a "when-clause" (as in Visual Studio Code). It's a simple boolean expression that evaluates to
* `true` or `false`. It supports the following operators:
*
* Operator | Symbol | Example
* -- | -- | --
* Equality | == | "editorType == markdown"
* Inequality | != | "currentScreen != config"
* Or | \|\| | "noteIsTodo \|\| noteTodoCompleted"
* And | && | "oneNoteSelected && !inConflictFolder"
*
* Currently the supported context variables aren't documented, but you can find the list there:
*
* https://github.com/laurent22/joplin/blob/dev/ReactNativeClient/lib/services/commands/stateToWhenClauseContext.ts
*
* Note: Commands are enabled by default unless you use this property.
*/
enabledCondition?: string
}
// =================================================================
@@ -26,7 +64,7 @@ export enum ImportModuleOutputFormat {
}
/**
* Used to implement a module to export data from Joplin. [View the demo plugin](https://github.com/laurent22/joplin/CliClient/tests/support/plugins/json_export) for an example.
* Used to implement a module to export data from Joplin. [View the demo plugin](https://github.com/laurent22/joplin/tree/dev/CliClient/tests/support/plugins/json_export) for an example.
*
* In general, all the event handlers you'll need to implement take a `context` object as a first argument. This object will contain the export or import path as well as various optional properties, such as which notes or notebooks need to be exported.
*
@@ -154,17 +192,9 @@ export interface Script {
}
// =================================================================
// View API types
// Menu types
// =================================================================
export type ButtonId = string;
export interface ButtonSpec {
id: ButtonId,
title?: string,
onClick?():void,
}
export interface CreateMenuItemOptions {
accelerator: string,
}
@@ -179,6 +209,41 @@ export enum MenuItemLocation {
Context = 'context',
}
export interface MenuItem {
/**
* Command that should be associated with the menu item. All menu item should
* have a command associated with them unless they are a sub-menu.
*/
commandName?: string,
/**
* Accelerator associated with the menu item
*/
accelerator?: string,
/**
* Menu items that should appear below this menu item. Allows creating a menu tree.
*/
submenu?: MenuItem[],
/**
* Menu item label. If not specified, the command label will be used instead.
*/
label?: string,
}
// =================================================================
// View API types
// =================================================================
export interface ButtonSpec {
id: ButtonId,
title?: string,
onClick?():void,
}
export type ButtonId = string;
export enum ToolbarButtonLocation {
/**
* This toolbar in the top right corner of the application. It applies to the note as a whole, including its metadata.
@@ -250,3 +315,54 @@ export interface SettingSection {
* [2]: (Optional) Resource link.
*/
export type Path = string[];
// =================================================================
// Plugins type
// =================================================================
export enum ContentScriptType {
/**
* Registers a new Markdown-It plugin, which should follow this template:
*
* ```javascript
* // The module should export an object as below:
*
* module.exports = {
*
* // The "context" variable is currently unused but could be used later on to provide
* // access to your own plugin so that the content script and plugin can communicate.
* default: function(context) {
* return {
*
* // This is the actual Markdown-It plugin - check the [official doc](https://github.com/markdown-it/markdown-it) for more information
* // The `options` parameter is of type [RuleOptions](https://github.com/laurent22/joplin/blob/dev/ReactNativeClient/lib/joplin-renderer/MdToHtml.ts), which
* // contains a number of options, mostly useful for Joplin's internal code.
* plugin: function(markdownIt, options) {
* // ...
* },
*
* // You may also specify additional assets such as JS or CSS that should be loaded in the rendered HTML document.
* // Check for example the Joplin [Mermaid plugin](https://github.com/laurent22/joplin/blob/dev/ReactNativeClient/lib/joplin-renderer/MdToHtml/rules/mermaid.ts) to
* // see how the data should be structured.
* assets: {},
* }
* }
* }
* ```
*
* To include a regular Markdown-It plugin, that doesn't make use of any Joplin-specific feature, you
* would simply create a file such as this:
*
* ```javascript
* module.exports = {
* default: function(context) {
* return {
* plugin: require('markdown-it-toc-done-right');
* }
* }
* }
* ```
*/
MarkdownItPlugin = 'markdownItPlugin',
CodeMirrorPlugin = 'codeMirrorPlugin',
}

View File

@@ -0,0 +1,2 @@
dist/*
node_modules/

View File

@@ -0,0 +1,14 @@
# Joplin Plugin
This is a template to create a new Joplin plugin.
The main two files you will want to look at are:
- `/src/index.ts`, which contains the entry point for the plugin source code.
- `/src/manifest.json`, which is the plugin manifest. It contains information such as the plugin a name, version, etc.
The plugin is built using webpack, which create the compiled code in `/dist`. The project is setup to use TypeScript, although you can change the configuration to use plain JavaScript.
## Building the plugin
To build the plugin, simply run `npm run dist`.

View File

@@ -0,0 +1,15 @@
import Plugin from '../Plugin';
import Joplin from './Joplin';
import Logger from 'lib/Logger';
/**
* @ignore
*/
export default class Global {
private joplin_;
private requireWhiteList_;
constructor(logger: Logger, implementation: any, plugin: Plugin, store: any);
get joplin(): Joplin;
private requireWhiteList;
require(filePath: string): any;
get process(): any;
}

Some files were not shown because too many files have changed in this diff Show More