From fa11607a3b96727caa974ae1c332b8d22ac42100 Mon Sep 17 00:00:00 2001 From: Laurent Cozic Date: Thu, 5 Oct 2017 18:17:56 +0100 Subject: [PATCH] Started tkwidgets gui --- CliClient/app/app-gui.js | 172 +++++++++++++++++ CliClient/app/app.js | 77 ++++---- CliClient/locales/en_GB.po | 3 + CliClient/locales/fr_FR.po | 3 + CliClient/locales/joplin.pot | 3 + CliClient/package.json | 8 +- CliClient/yarn.lock | 346 ++++++++++++++++++++++++++++++++++- joplin.sublime-project | 39 ++-- 8 files changed, 593 insertions(+), 58 deletions(-) create mode 100644 CliClient/app/app-gui.js diff --git a/CliClient/app/app-gui.js b/CliClient/app/app-gui.js new file mode 100644 index 000000000..4ee764d92 --- /dev/null +++ b/CliClient/app/app-gui.js @@ -0,0 +1,172 @@ +import { Logger } from 'lib/logger.js'; +import { Folder } from 'lib/models/folder.js'; +import { Note } from 'lib/models/note.js'; + +const tk = require('terminal-kit'); +//const term = tk.terminal; +const termutils = require('tkwidgets/framework/termutils.js'); +const Renderer = require('tkwidgets/framework/Renderer.js'); + +const ListWidget = require('tkwidgets/ListWidget.js'); +const TextWidget = require('tkwidgets/TextWidget.js'); +const ConsoleWidget = require('tkwidgets/ConsoleWidget.js'); +const HLayoutWidget = require('tkwidgets/HLayoutWidget.js'); +const VLayoutWidget = require('tkwidgets/VLayoutWidget.js'); +const RootWidget = require('tkwidgets/RootWidget.js'); +const WindowWidget = require('tkwidgets/WindowWidget.js'); + +class AppGui { + + constructor(app) { + this.app_ = app; + this.term_ = tk.terminal; + this.renderer_ = null; + this.logger_ = new Logger(); + + this.rootWidget_ = new RootWidget(); + this.rootWidget_.setName('rootWidget'); + + const folderList = new ListWidget(); + folderList.setItems([]); + folderList.setItemRenderer((item) => { + return item.title; + }); + folderList.setStyle({ + //borderTopWidth: 1, + borderBottomWidth: 1, + //borderLeftWidth: 1, + //borderRightWidth: 1, + }); + folderList.setName('folderList'); + folderList.setVStretch(true); + folderList.on('currentItemChange', async () => { + const folder = folderList.currentItem(); + await this.updateNoteList(folder ? folder.id : null); + }); + + const noteList = new ListWidget(); + noteList.setItems([]); + noteList.setItemRenderer((item) => { + return item.title; + }); + noteList.setName('noteList'); + noteList.setVStretch(true); + noteList.setStyle({ + //borderTopWidth: 1, + borderBottomWidth: 1, + borderLeftWidth: 1, + borderRightWidth: 1, + }); + noteList.on('currentItemChange', async () => { + const note = noteList.currentItem(); + await this.updateNoteText(note); + }); + + const noteText = new TextWidget(); + noteText.setVStretch(true); + noteText.setName('noteText'); + noteText.setStyle({ + //borderTopWidth: 1, + borderBottomWidth: 1, + //borderLeftWidth: 1, + //borderRightWidth: 1, + }); + + const layout1 = new HLayoutWidget(); + //layout1.addChild(noteText, { type: 'fixed', factor: 20 }); + layout1.addChild(folderList, { type: 'stretch', factor: 1 }); + layout1.addChild(noteList, { type: 'stretch', factor: 1 }); + layout1.addChild(noteText, { type: 'stretch', factor: 1 }); + + // const layout2 = new VLayoutWidget(); + // layout2.addChild(layout1, { type: 'stretch', factor: 1 }); + // layout2.addChild(listWidget3, { type: 'fixed', factor: 5 }); + + const win1 = new WindowWidget(); + win1.addChild(layout1); + win1.setName('mainWindow'); + win1.setLocation(1,1); + + this.rootWidget_.addChild(win1); + + this.renderer_ = new Renderer(this.term(), this.rootWidget_); + } + + widget(name) { + return this.rootWidget_.childByName(name); + } + + app() { + return this.app_; + } + + setLogger(l) { + this.logger_ = l; + } + + logger() { + return this.logger_; + } + + term() { + return this.term_; + } + + async updateFolderList() { + const folders = await Folder.all(); + this.widget('folderList').setItems(folders); + } + + async updateNoteList(folderId) { + const notes = folderId ? await Note.previews(folderId) : []; + this.widget('noteList').setItems(notes); + } + + async updateNoteText(note) { + const text = note ? note.body : ''; + this.widget('noteText').setText(text); + } + + async start() { + const term = this.term(); + + term.fullscreen(); + termutils.hideCursor(term); + + try { + this.renderer_.start(); + + await this.updateFolderList(); + + term.grabInput(); + + term.on('key', function( name , matches , data ) { + if (name === 'CTRL_C' ) { + termutils.showCursor(term); + term.fullscreen(false); + process.exit(); + } + + if (name === 'CTRL_J') { + consoleWidget.focus(); + } + + if (name == 't') { + if (win1.isActiveWindow()) { + win2.activate(); + } else { + win1.activate(); + } + } + }); + } catch (error) { + this.logger().error(error); + term.fullscreen(false); + termutils.showCursor(term); + console.error(error); + } + } + +} + +module.exports = AppGui; \ No newline at end of file diff --git a/CliClient/app/app.js b/CliClient/app/app.js index 176aea69b..9e36614b7 100644 --- a/CliClient/app/app.js +++ b/CliClient/app/app.js @@ -29,6 +29,7 @@ class Application { this.activeCommand_ = null; this.allCommandsLoaded_ = false; this.showStackTraces_ = false; + this.gui_ = null; } currentFolder() { @@ -414,42 +415,48 @@ class Application { if (!this.currentFolder_) this.currentFolder_ = await Folder.defaultFolder(); Setting.setValue('activeFolderId', this.currentFolder_ ? this.currentFolder_.id : ''); - if (this.autocompletion_.active) { - if (this.autocompletion_.install) { - try { - await installAutocompletionFile(Setting.value('appName'), Setting.value('profileDir')); - } catch (error) { - if (error.code == 'shellNotSupported') { - console.info(error.message); - return; - } - throw error; - } - } else { - let items = await handleAutocompletion(this.autocompletion_); - if (!items.length) return; - for (let i = 0; i < items.length; i++) { - items[i] = items[i].replace(/ /g, '\\ '); - items[i] = items[i].replace(/'/g, "\\'"); - items[i] = items[i].replace(/:/g, "\\:"); - items[i] = items[i].replace(/\(/g, '\\('); - items[i] = items[i].replace(/\)/g, '\\)'); - } - console.info(items.join("\n")); - } - - return; - } + const AppGui = require('./app-gui.js'); + this.gui_ = new AppGui(this); + this.gui_.setLogger(this.logger_); + await this.gui_.start(); + + // if (this.autocompletion_.active) { + // if (this.autocompletion_.install) { + // try { + // await installAutocompletionFile(Setting.value('appName'), Setting.value('profileDir')); + // } catch (error) { + // if (error.code == 'shellNotSupported') { + // console.info(error.message); + // return; + // } + // throw error; + // } + // } else { + // let items = await handleAutocompletion(this.autocompletion_); + // if (!items.length) return; + // for (let i = 0; i < items.length; i++) { + // items[i] = items[i].replace(/ /g, '\\ '); + // items[i] = items[i].replace(/'/g, "\\'"); + // items[i] = items[i].replace(/:/g, "\\:"); + // items[i] = items[i].replace(/\(/g, '\\('); + // items[i] = items[i].replace(/\)/g, '\\)'); + // } + // console.info(items.join("\n")); + // } + + // return; + // } + + // try { + // await this.execCommand(argv); + // } catch (error) { + // if (this.showStackTraces_) { + // console.info(error); + // } else { + // console.info(error.message); + // } + // } - try { - await this.execCommand(argv); - } catch (error) { - if (this.showStackTraces_) { - console.info(error); - } else { - console.info(error.message); - } - } } } diff --git a/CliClient/locales/en_GB.po b/CliClient/locales/en_GB.po index 33ab18164..2097743f0 100644 --- a/CliClient/locales/en_GB.po +++ b/CliClient/locales/en_GB.po @@ -480,6 +480,9 @@ msgstr "" msgid "Show uncompleted todos on top of the lists" msgstr "" +msgid "Show advanced options" +msgstr "" + msgid "Save location with notes" msgstr "" diff --git a/CliClient/locales/fr_FR.po b/CliClient/locales/fr_FR.po index fe8ce6cd6..30dd805fd 100644 --- a/CliClient/locales/fr_FR.po +++ b/CliClient/locales/fr_FR.po @@ -529,6 +529,9 @@ msgstr "Tâches complétées seulement" msgid "Show uncompleted todos on top of the lists" msgstr "Tâches non-terminées en haut des listes" +msgid "Show advanced options" +msgstr "" + msgid "Save location with notes" msgstr "Enregistrer l'emplacement avec les notes" diff --git a/CliClient/locales/joplin.pot b/CliClient/locales/joplin.pot index 33ab18164..2097743f0 100644 --- a/CliClient/locales/joplin.pot +++ b/CliClient/locales/joplin.pot @@ -480,6 +480,9 @@ msgstr "" msgid "Show uncompleted todos on top of the lists" msgstr "" +msgid "Show advanced options" +msgstr "" + msgid "Save location with notes" msgstr "" diff --git a/CliClient/package.json b/CliClient/package.json index b10ac3e6a..bf77887d0 100644 --- a/CliClient/package.json +++ b/CliClient/package.json @@ -37,9 +37,10 @@ "string-padding": "^1.0.2", "string-to-stream": "^1.1.0", "tcp-port-used": "^0.1.2", + "tkwidgets": "^0.5.3", "uuid": "^3.0.1", - "yargs-parser": "^7.0.0", - "word-wrap": "^1.2.3" + "word-wrap": "^1.2.3", + "yargs-parser": "^7.0.0" }, "devDependencies": { "babel-changed": "^7.0.0", @@ -57,7 +58,6 @@ "babelbuild": "babel app -d build", "build": "babel-changed app -d build --source-maps && babel-changed app/lib/models -d build/lib/models --source-maps && babel-changed app/lib/services -d build/lib/services --source-maps", "clean": "babel-changed --reset", - "test": "babel-changed tests -d tests-build --source-maps && jasmine", - "postinstall": "joplin --autocompletion --ac-install" + "test": "babel-changed tests -d tests-build --source-maps && jasmine" } } diff --git a/CliClient/yarn.lock b/CliClient/yarn.lock index d29160c29..5e93f5423 100644 --- a/CliClient/yarn.lock +++ b/CliClient/yarn.lock @@ -13,6 +13,15 @@ ajv@^4.9.1: co "^4.6.0" json-stable-stringify "^1.0.1" +ajv@^5.1.0: + version "5.2.3" + resolved "https://registry.yarnpkg.com/ajv/-/ajv-5.2.3.tgz#c06f598778c44c6b161abafe3466b81ad1814ed2" + dependencies: + co "^4.6.0" + fast-deep-equal "^1.0.0" + json-schema-traverse "^0.3.0" + json-stable-stringify "^1.0.1" + ansi-regex@^2.0.0: version "2.1.1" resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-2.1.1.tgz#c3b33ab5ee360d86e0e628f0468ae7ef27d654df" @@ -21,6 +30,10 @@ ansi-styles@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-2.2.1.tgz#b432dd3358b634cf75e1e4664368240533c1ddbe" +ansicolors@~0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/ansicolors/-/ansicolors-0.2.1.tgz#be089599097b74a5c9c4a84a0cdbcdb62bd87aef" + anymatch@^1.3.0: version "1.3.2" resolved "https://registry.yarnpkg.com/anymatch/-/anymatch-1.3.2.tgz#553dcb8f91e3c889845dfdba34c77721b90b9d7a" @@ -91,6 +104,13 @@ async-each@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/async-each/-/async-each-1.0.1.tgz#19d386a1d9edc6e7c1c85d388aedbcc56d33602d" +async-kit@^2.2.3: + version "2.2.3" + resolved "https://registry.yarnpkg.com/async-kit/-/async-kit-2.2.3.tgz#264751a279ddc5f59b419638b805ae2c49858fb7" + dependencies: + nextgen-events "^0.9.0" + tree-kit "^0.5.26" + asynckit@^0.4.0: version "0.4.0" resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79" @@ -99,7 +119,11 @@ aws-sign2@~0.6.0: version "0.6.0" resolved "https://registry.yarnpkg.com/aws-sign2/-/aws-sign2-0.6.0.tgz#14342dd38dbcc94d0e5b87d763cd63612c0e794f" -aws4@^1.2.1: +aws-sign2@~0.7.0: + version "0.7.0" + resolved "https://registry.yarnpkg.com/aws-sign2/-/aws-sign2-0.7.0.tgz#b46e890934a9591f2d2f6f86d7e6a9f1b3fe76a8" + +aws4@^1.2.1, aws4@^1.6.0: version "1.6.0" resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.6.0.tgz#83ef5ca860b2b32e4a0deedee8c771b9db57471e" @@ -732,6 +756,18 @@ boom@2.x.x: dependencies: hoek "2.x.x" +boom@4.x.x: + version "4.3.1" + resolved "https://registry.yarnpkg.com/boom/-/boom-4.3.1.tgz#4f8a3005cb4a7e3889f749030fd25b96e01d2e31" + dependencies: + hoek "4.x.x" + +boom@5.x.x: + version "5.2.0" + resolved "https://registry.yarnpkg.com/boom/-/boom-5.2.0.tgz#5dd9da6ee3a5f302077436290cb717d3f4a54e02" + dependencies: + hoek "4.x.x" + brace-expansion@^1.1.7: version "1.1.8" resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.8.tgz#c07b211c7c952ec1f8efd51a77ef0d1d3990a292" @@ -766,11 +802,18 @@ caniuse-lite@^1.0.30000704: version "1.0.30000710" resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30000710.tgz#1c249bf7c6a61161c9b10906e3ad9fa5b6761af1" +cardinal@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/cardinal/-/cardinal-1.0.0.tgz#50e21c1b0aa37729f9377def196b5a9cec932ee9" + dependencies: + ansicolors "~0.2.1" + redeyed "~1.0.0" + caseless@~0.12.0: version "0.12.0" resolved "https://registry.yarnpkg.com/caseless/-/caseless-0.12.0.tgz#1b681c21ff84033c826543090689420d187151dc" -chalk@^1.1.0: +chalk@^1.1.0, chalk@^1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/chalk/-/chalk-1.1.3.tgz#a8115c55e4a702fe4d150abd3872822a7e09fc98" dependencies: @@ -803,6 +846,12 @@ circular-json@^0.3.1: version "0.3.3" resolved "https://registry.yarnpkg.com/circular-json/-/circular-json-0.3.3.tgz#815c99ea84f6809529d2f45791bdf82711352d66" +cli-table@^0.3.1: + version "0.3.1" + resolved "https://registry.yarnpkg.com/cli-table/-/cli-table-0.3.1.tgz#f53b05266a8b1a0b934b3d0821e6e2dc5914ae23" + dependencies: + colors "1.0.3" + co@^4.6.0: version "4.6.0" resolved "https://registry.yarnpkg.com/co/-/co-4.6.0.tgz#6ea6bdf3d853ae54ccb8e47bfa0bf3f9031fb184" @@ -811,6 +860,10 @@ code-point-at@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/code-point-at/-/code-point-at-1.1.0.tgz#0d070b4d043a5bea33a2f1a40e2edb3d9a4ccf77" +colors@1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/colors/-/colors-1.0.3.tgz#0433f44d809680fdeb60ed260f1b0c262e82a40b" + combined-stream@^1.0.5, combined-stream@~1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.5.tgz#938370a57b4a51dea2c77c15d5c5fdf895164009" @@ -851,12 +904,28 @@ cryptiles@2.x.x: dependencies: boom "2.x.x" +cryptiles@3.x.x: + version "3.1.2" + resolved "https://registry.yarnpkg.com/cryptiles/-/cryptiles-3.1.2.tgz#a89fbb220f5ce25ec56e8c4aa8a4fd7b5b0d29fe" + dependencies: + boom "5.x.x" + +cwise-compiler@^1.1.2: + version "1.1.3" + resolved "https://registry.yarnpkg.com/cwise-compiler/-/cwise-compiler-1.1.3.tgz#f4d667410e850d3a313a7d2db7b1e505bb034cc5" + dependencies: + uniq "^1.0.0" + dashdash@^1.12.0: version "1.14.1" resolved "https://registry.yarnpkg.com/dashdash/-/dashdash-1.14.1.tgz#853cfa0f7cbe2fed5de20326b8dd581035f6e2f0" dependencies: assert-plus "^1.0.0" +data-uri-to-buffer@0.0.3: + version "0.0.3" + resolved "https://registry.yarnpkg.com/data-uri-to-buffer/-/data-uri-to-buffer-0.0.3.tgz#18ae979a6a0ca994b0625853916d2662bbae0b1a" + debug@0.7.4: version "0.7.4" resolved "https://registry.yarnpkg.com/debug/-/debug-0.7.4.tgz#06e1ea8082c2cb14e39806e22e2f6f757f92af39" @@ -921,6 +990,10 @@ escape-string-regexp@^1.0.2: version "1.0.5" resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" +esprima@~3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/esprima/-/esprima-3.0.0.tgz#53cf247acda77313e551c3aa2e73342d3fb4f7d9" + esutils@^2.0.0, esutils@^2.0.2: version "2.0.2" resolved "https://registry.yarnpkg.com/esutils/-/esutils-2.0.2.tgz#0abf4f1caa5bcb1f7a9d8acc6dea4faaa04bac9b" @@ -945,7 +1018,7 @@ extend@~1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/extend/-/extend-1.2.1.tgz#a0f5fd6cfc83a5fe49ef698d60ec8a624dd4576c" -extend@~3.0.0: +extend@~3.0.0, extend@~3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.1.tgz#a755ea7bc1adfcc5a31ce7e762dbaadc5e636444" @@ -959,6 +1032,10 @@ extsprintf@1.3.0, extsprintf@^1.2.0: version "1.3.0" resolved "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.3.0.tgz#96918440e3041a7a414f8c52e3c574eb3c3e1e05" +fast-deep-equal@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-1.0.0.tgz#96256a3bc975595eb36d82e9929d060d893439ff" + file-entry-cache@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/file-entry-cache/-/file-entry-cache-2.0.0.tgz#c392990c3e684783d838b8c84a45d8a048458361" @@ -1025,6 +1102,14 @@ form-data@~2.1.1: combined-stream "^1.0.5" mime-types "^2.1.12" +form-data@~2.3.1: + version "2.3.1" + resolved "https://registry.yarnpkg.com/form-data/-/form-data-2.3.1.tgz#6fb94fbd71885306d73d15cc497fe4cc4ecd44bf" + dependencies: + asynckit "^0.4.0" + combined-stream "^1.0.5" + mime-types "^2.1.12" + fs-extra@^0.30.0: version "0.30.0" resolved "https://registry.yarnpkg.com/fs-extra/-/fs-extra-0.30.0.tgz#f233ffcc08d4da7d432daa449776989db1df93f0" @@ -1043,6 +1128,14 @@ fs-extra@^3.0.1: jsonfile "^3.0.0" universalify "^0.1.0" +fs-extra@^4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/fs-extra/-/fs-extra-4.0.2.tgz#f91704c53d1b461f893452b0c307d9997647ab6b" + dependencies: + graceful-fs "^4.1.2" + jsonfile "^4.0.0" + universalify "^0.1.0" + fs-readdir-recursive@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/fs-readdir-recursive/-/fs-readdir-recursive-1.0.0.tgz#8cd1745c8b4f8a29c8caec392476921ba195f560" @@ -1088,6 +1181,22 @@ gauge@~2.7.3: strip-ansi "^3.0.1" wide-align "^1.1.0" +get-pixels@^3.3.0: + version "3.3.0" + resolved "https://registry.yarnpkg.com/get-pixels/-/get-pixels-3.3.0.tgz#8d9795beae18850b840f749581badc05d3e36e41" + dependencies: + data-uri-to-buffer "0.0.3" + jpeg-js "^0.1.1" + mime-types "^2.0.1" + ndarray "^1.0.13" + ndarray-pack "^1.1.1" + node-bitmap "0.0.1" + omggif "^1.0.5" + parse-data-uri "^0.2.0" + pngjs "^2.0.0" + request "^2.44.0" + through "^2.3.4" + getpass@^0.1.1: version "0.1.7" resolved "https://registry.yarnpkg.com/getpass/-/getpass-0.1.7.tgz#5eff8e3e684d569ae4cb2b1282604e8ba62149fa" @@ -1148,6 +1257,10 @@ har-schema@^1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/har-schema/-/har-schema-1.0.5.tgz#d263135f43307c02c602afc8fe95970c0151369e" +har-schema@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/har-schema/-/har-schema-2.0.0.tgz#a94c2224ebcac04782a0d9035521f24735b7ec92" + har-validator@~4.2.1: version "4.2.1" resolved "https://registry.yarnpkg.com/har-validator/-/har-validator-4.2.1.tgz#33481d0f1bbff600dd203d75812a6a5fba002e2a" @@ -1155,6 +1268,13 @@ har-validator@~4.2.1: ajv "^4.9.1" har-schema "^1.0.5" +har-validator@~5.0.3: + version "5.0.3" + resolved "https://registry.yarnpkg.com/har-validator/-/har-validator-5.0.3.tgz#ba402c266194f15956ef15e0fcf242993f6a7dfd" + dependencies: + ajv "^5.1.0" + har-schema "^2.0.0" + has-ansi@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/has-ansi/-/has-ansi-2.0.0.tgz#34f5049ce1ecdf2b0649af3ef24e45ed35416d91" @@ -1178,10 +1298,23 @@ hawk@~3.1.3: hoek "2.x.x" sntp "1.x.x" +hawk@~6.0.2: + version "6.0.2" + resolved "https://registry.yarnpkg.com/hawk/-/hawk-6.0.2.tgz#af4d914eb065f9b5ce4d9d11c1cb2126eecc3038" + dependencies: + boom "4.x.x" + cryptiles "3.x.x" + hoek "4.x.x" + sntp "2.x.x" + hoek@2.x.x: version "2.16.3" resolved "https://registry.yarnpkg.com/hoek/-/hoek-2.16.3.tgz#20bb7403d3cea398e91dc4710a8ff1b8274a25ed" +hoek@4.x.x: + version "4.2.0" + resolved "https://registry.yarnpkg.com/hoek/-/hoek-4.2.0.tgz#72d9d0754f7fe25ca2d01ad8f8f9a9449a89526d" + home-or-tmp@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/home-or-tmp/-/home-or-tmp-2.0.0.tgz#e36c3f2d2cae7d746a857e38d18d5f32a7882db8" @@ -1197,6 +1330,14 @@ http-signature@~1.1.0: jsprim "^1.2.2" sshpk "^1.7.0" +http-signature@~1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/http-signature/-/http-signature-1.2.0.tgz#9aecd925114772f3d95b65a60abb8f7c18fbace1" + dependencies: + assert-plus "^1.0.0" + jsprim "^1.2.2" + sshpk "^1.7.0" + iconv-lite@~0.4.13: version "0.4.18" resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.18.tgz#23d8656b16aae6742ac29732ea8f0336a4789cf2" @@ -1222,6 +1363,10 @@ invariant@^2.2.0, invariant@^2.2.2: dependencies: loose-envify "^1.0.0" +iota-array@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/iota-array/-/iota-array-1.0.0.tgz#81ef57fe5d05814cd58c2483632a99c30a0e8087" + is-absolute@^0.2.6: version "0.2.6" resolved "https://registry.yarnpkg.com/is-absolute/-/is-absolute-0.2.6.tgz#20de69f3db942ef2d87b9c2da36f172235b1b5eb" @@ -1235,7 +1380,7 @@ is-binary-path@^1.0.0: dependencies: binary-extensions "^1.0.0" -is-buffer@^1.1.5, is-buffer@~1.1.1: +is-buffer@^1.0.2, is-buffer@^1.1.5, is-buffer@~1.1.1: version "1.1.5" resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-1.1.5.tgz#1f3b26ef613b214b88cbca23cc6c01d87961eecc" @@ -1367,6 +1512,10 @@ jasmine@^2.6.0: glob "^7.0.6" jasmine-core "~2.7.0" +jpeg-js@^0.1.1: + version "0.1.2" + resolved "https://registry.yarnpkg.com/jpeg-js/-/jpeg-js-0.1.2.tgz#135b992c0575c985cfa0f494a3227ed238583ece" + js-tokens@^3.0.0: version "3.0.2" resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-3.0.2.tgz#9866df395102130e38f7f996bceb65443209c25b" @@ -1383,6 +1532,10 @@ jsesc@~0.5.0: version "0.5.0" resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-0.5.0.tgz#e7dee66e35d6fc16f710fe91d5cf69f70f08911d" +json-schema-traverse@^0.3.0: + version "0.3.1" + resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.3.1.tgz#349a6d44c53a51de89b40805c5d5e59b417d3340" + json-schema@0.2.3: version "0.2.3" resolved "https://registry.yarnpkg.com/json-schema/-/json-schema-0.2.3.tgz#b480c892e59a2f05954ce727bd3f2a4e882f9e13" @@ -1413,6 +1566,12 @@ jsonfile@^3.0.0: optionalDependencies: graceful-fs "^4.1.6" +jsonfile@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/jsonfile/-/jsonfile-4.0.0.tgz#8771aae0799b64076b76640fca058f9c10e33ecb" + optionalDependencies: + graceful-fs "^4.1.6" + jsonify@~0.0.0: version "0.0.0" resolved "https://registry.yarnpkg.com/jsonify/-/jsonify-0.0.0.tgz#2c74b6ee41d93ca51b7b5aaee8f503631d252a73" @@ -1452,6 +1611,14 @@ levenshtein@^1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/levenshtein/-/levenshtein-1.0.5.tgz#3911737a9cb56da345d008f55782c6f138979ba3" +lodash.assign@^4.2.0: + version "4.2.0" + resolved "https://registry.yarnpkg.com/lodash.assign/-/lodash.assign-4.2.0.tgz#0d99f3ccd7a6d261d19bdaeb9245005d285808e7" + +lodash.toarray@^4.4.0: + version "4.4.0" + resolved "https://registry.yarnpkg.com/lodash.toarray/-/lodash.toarray-4.4.0.tgz#24c4bfcd6b2fba38bfd0594db1179d8e9b656561" + lodash.uniq@^4.5.0: version "4.5.0" resolved "https://registry.yarnpkg.com/lodash.uniq/-/lodash.uniq-4.5.0.tgz#d0225373aeb652adc1bc82e4945339a842754773" @@ -1466,6 +1633,20 @@ loose-envify@^1.0.0: dependencies: js-tokens "^3.0.0" +marked-terminal@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/marked-terminal/-/marked-terminal-2.0.0.tgz#5eaf568be66f686541afa52a558280310a31de2d" + dependencies: + cardinal "^1.0.0" + chalk "^1.1.3" + cli-table "^0.3.1" + lodash.assign "^4.2.0" + node-emoji "^1.4.1" + +marked@^0.3.6: + version "0.3.6" + resolved "https://registry.yarnpkg.com/marked/-/marked-0.3.6.tgz#b2c6c618fccece4ef86c4fc6cb8a7cbf5aeda8d7" + md5@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/md5/-/md5-2.2.1.tgz#53ab38d5fe3c8891ba465329ea23fac0540126f9" @@ -1496,6 +1677,16 @@ mime-db@~1.29.0: version "1.29.0" resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.29.0.tgz#48d26d235589651704ac5916ca06001914266878" +mime-db@~1.30.0: + version "1.30.0" + resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.30.0.tgz#74c643da2dd9d6a45399963465b26d5ca7d71f01" + +mime-types@^2.0.1, mime-types@~2.1.17: + version "2.1.17" + resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.17.tgz#09d7a393f03e995a79f8af857b70a9e0ab16557a" + dependencies: + mime-db "~1.30.0" + mime-types@^2.1.12, mime-types@~2.1.7: version "2.1.16" resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.16.tgz#2b858a52e5ecd516db897ac2be87487830698e23" @@ -1542,6 +1733,38 @@ nan@~2.4.0: version "2.4.0" resolved "https://registry.yarnpkg.com/nan/-/nan-2.4.0.tgz#fb3c59d45fe4effe215f0b890f8adf6eb32d2232" +ndarray-pack@^1.1.1: + version "1.2.1" + resolved "https://registry.yarnpkg.com/ndarray-pack/-/ndarray-pack-1.2.1.tgz#8caebeaaa24d5ecf70ff86020637977da8ee585a" + dependencies: + cwise-compiler "^1.1.2" + ndarray "^1.0.13" + +ndarray@^1.0.13, ndarray@^1.0.18: + version "1.0.18" + resolved "https://registry.yarnpkg.com/ndarray/-/ndarray-1.0.18.tgz#b60d3a73224ec555d0faa79711e502448fd3f793" + dependencies: + iota-array "^1.0.0" + is-buffer "^1.0.2" + +nextgen-events@^0.10.0: + version "0.10.2" + resolved "https://registry.yarnpkg.com/nextgen-events/-/nextgen-events-0.10.2.tgz#d0a3f4e620cae40061874d920afd0cc40c31cebe" + +nextgen-events@^0.9.0: + version "0.9.9" + resolved "https://registry.yarnpkg.com/nextgen-events/-/nextgen-events-0.9.9.tgz#39a8afc4a2b845388c57e2c6bb9716711986a3a0" + +node-bitmap@0.0.1: + version "0.0.1" + resolved "https://registry.yarnpkg.com/node-bitmap/-/node-bitmap-0.0.1.tgz#180eac7003e0c707618ef31368f62f84b2a69091" + +node-emoji@^1.4.1: + version "1.8.1" + resolved "https://registry.yarnpkg.com/node-emoji/-/node-emoji-1.8.1.tgz#6eec6bfb07421e2148c75c6bba72421f8530a826" + dependencies: + lodash.toarray "^4.4.0" + node-fetch@^1.7.1: version "1.7.1" resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-1.7.1.tgz#899cb3d0a3c92f952c47f1b876f4c8aeabd400d5" @@ -1597,7 +1820,7 @@ number-is-nan@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/number-is-nan/-/number-is-nan-1.0.1.tgz#097b602b53422a522c1afb8790318336941a011d" -oauth-sign@~0.8.1: +oauth-sign@~0.8.1, oauth-sign@~0.8.2: version "0.8.2" resolved "https://registry.yarnpkg.com/oauth-sign/-/oauth-sign-0.8.2.tgz#46a6ab7f0aead8deae9ec0565780b7d4efeb9d43" @@ -1612,6 +1835,10 @@ object.omit@^2.0.0: for-own "^0.1.4" is-extendable "^0.1.1" +omggif@^1.0.5: + version "1.0.8" + resolved "https://registry.yarnpkg.com/omggif/-/omggif-1.0.8.tgz#178f37b2ab0b3d7b46ed3a0e46bd0790b58d3530" + once@^1.3.0, once@^1.3.3: version "1.4.0" resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1" @@ -1641,6 +1868,12 @@ output-file-sync@^1.1.0: mkdirp "^0.5.1" object-assign "^4.1.0" +parse-data-uri@^0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/parse-data-uri/-/parse-data-uri-0.2.0.tgz#bf04d851dd5c87b0ab238e5d01ace494b604b4c9" + dependencies: + data-uri-to-buffer "0.0.3" + parse-glob@^3.0.4: version "3.0.4" resolved "https://registry.yarnpkg.com/parse-glob/-/parse-glob-3.0.4.tgz#b2c376cfb11f35513badd173ef0bb6e3a388391c" @@ -1666,6 +1899,10 @@ performance-now@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/performance-now/-/performance-now-0.2.0.tgz#33ef30c5c77d4ea21c5a53869d91b56d8f2555e5" +performance-now@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/performance-now/-/performance-now-2.1.0.tgz#6309f4e0e5fa913ec1c69307ae364b4b377c9e7b" + pify@^2.0.0: version "2.3.0" resolved "https://registry.yarnpkg.com/pify/-/pify-2.3.0.tgz#ed141a6ac043a849ea588498e7dca8b15330e90c" @@ -1680,6 +1917,10 @@ pinkie@^2.0.0: version "2.0.4" resolved "https://registry.yarnpkg.com/pinkie/-/pinkie-2.0.4.tgz#72556b80cfa0d48a974e80e77248e80ed4f7f870" +pngjs@^2.0.0: + version "2.3.1" + resolved "https://registry.yarnpkg.com/pngjs/-/pngjs-2.3.1.tgz#11d1e12b9cb64d63e30c143a330f4c1f567da85f" + preserve@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/preserve/-/preserve-0.2.0.tgz#815ed1f6ebc65926f865b310c0713bcb3315ce4b" @@ -1728,6 +1969,10 @@ qs@~6.4.0: version "6.4.0" resolved "https://registry.yarnpkg.com/qs/-/qs-6.4.0.tgz#13e26d28ad6b0ffaa91312cd3bf708ed351e7233" +qs@~6.5.1: + version "6.5.1" + resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.1.tgz#349cdf6eef89ec45c12d7d5eb3fc0c870343a6d8" + query-string@4.3.4: version "4.3.4" resolved "https://registry.yarnpkg.com/query-string/-/query-string-4.3.4.tgz#bbb693b9ca915c232515b228b1a02b609043dbeb" @@ -1772,6 +2017,12 @@ readdirp@^2.0.0: readable-stream "^2.0.2" set-immediate-shim "^1.0.1" +redeyed@~1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/redeyed/-/redeyed-1.0.1.tgz#e96c193b40c0816b00aec842698e61185e55498a" + dependencies: + esprima "~3.0.0" + regenerate@^1.2.1: version "1.3.2" resolved "https://registry.yarnpkg.com/regenerate/-/regenerate-1.3.2.tgz#d1941c67bad437e1be76433add5b385f95b19260" @@ -1831,6 +2082,33 @@ repeating@^2.0.0: dependencies: is-finite "^1.0.0" +request@^2.44.0: + version "2.83.0" + resolved "https://registry.yarnpkg.com/request/-/request-2.83.0.tgz#ca0b65da02ed62935887808e6f510381034e3356" + dependencies: + aws-sign2 "~0.7.0" + aws4 "^1.6.0" + caseless "~0.12.0" + combined-stream "~1.0.5" + extend "~3.0.1" + forever-agent "~0.6.1" + form-data "~2.3.1" + har-validator "~5.0.3" + hawk "~6.0.2" + http-signature "~1.2.0" + is-typedarray "~1.0.0" + isstream "~0.1.2" + json-stringify-safe "~5.0.1" + mime-types "~2.1.17" + oauth-sign "~0.8.2" + performance-now "^2.1.0" + qs "~6.5.1" + safe-buffer "^5.1.1" + stringstream "~0.0.5" + tough-cookie "~2.3.3" + tunnel-agent "^0.6.0" + uuid "^3.1.0" + request@^2.81.0: version "2.81.0" resolved "https://registry.yarnpkg.com/request/-/request-2.81.0.tgz#c6928946a0e06c5f8d6f8a9333469ffda46298a0" @@ -1906,6 +2184,12 @@ sntp@1.x.x: dependencies: hoek "2.x.x" +sntp@2.x.x: + version "2.0.2" + resolved "https://registry.yarnpkg.com/sntp/-/sntp-2.0.2.tgz#5064110f0af85f7cfdb7d6b67a40028ce52b4b2b" + dependencies: + hoek "4.x.x" + source-map-support@^0.4.15, source-map-support@^0.4.2: version "0.4.15" resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.4.15.tgz#03202df65c06d2bd8c7ec2362a193056fef8d3b1" @@ -1945,6 +2229,12 @@ strict-uri-encode@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/strict-uri-encode/-/strict-uri-encode-1.1.0.tgz#279b225df1d582b1f54e65addd4352e18faa0713" +string-kit@^0.6.1: + version "0.6.2" + resolved "https://registry.yarnpkg.com/string-kit/-/string-kit-0.6.2.tgz#605295e0a4fa084e9c47fdc3ea3ef8eb1ca85623" + dependencies: + xregexp "^3.2.0" + string-padding@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/string-padding/-/string-padding-1.0.2.tgz#3aaad855b3e9735c5e412dfe72198ccf99c7f48e" @@ -1970,7 +2260,7 @@ string_decoder@~1.0.3: dependencies: safe-buffer "~5.1.0" -stringstream@~0.0.4: +stringstream@~0.0.4, stringstream@~0.0.5: version "0.0.5" resolved "https://registry.yarnpkg.com/stringstream/-/stringstream-0.0.5.tgz#4e484cd4de5a0bbbee18e46307710a8a81621878" @@ -2017,6 +2307,30 @@ tcp-port-used@^0.1.2: is2 "0.0.9" q "0.9.7" +terminal-kit@^1.13.11: + version "1.13.12" + resolved "https://registry.yarnpkg.com/terminal-kit/-/terminal-kit-1.13.12.tgz#d4cfd6480adf0b3c43a062ac5de073b0b1cb9c4a" + dependencies: + async-kit "^2.2.3" + get-pixels "^3.3.0" + ndarray "^1.0.18" + nextgen-events "^0.10.0" + string-kit "^0.6.1" + tree-kit "^0.5.26" + +through@^2.3.4: + version "2.3.8" + resolved "https://registry.yarnpkg.com/through/-/through-2.3.8.tgz#0dd4c9ffaabc357960b1b724115d7e0e86a2e1f5" + +tkwidgets@^0.5.3: + version "0.5.3" + resolved "https://registry.yarnpkg.com/tkwidgets/-/tkwidgets-0.5.3.tgz#be7c326b9fdf2ffb2e29682ae2149baddcb0d7ac" + dependencies: + fs-extra "^4.0.2" + marked "^0.3.6" + marked-terminal "^2.0.0" + terminal-kit "^1.13.11" + to-fast-properties@^1.0.1: version "1.0.3" resolved "https://registry.yarnpkg.com/to-fast-properties/-/to-fast-properties-1.0.3.tgz#b83571fa4d8c25b82e231b06e3a3055de4ca1a47" @@ -2027,6 +2341,16 @@ tough-cookie@~2.3.0: dependencies: punycode "^1.4.1" +tough-cookie@~2.3.3: + version "2.3.3" + resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.3.3.tgz#0b618a5565b6dea90bf3425d04d55edc475a7561" + dependencies: + punycode "^1.4.1" + +tree-kit@^0.5.26: + version "0.5.26" + resolved "https://registry.yarnpkg.com/tree-kit/-/tree-kit-0.5.26.tgz#8571c86fa24d1db754e5b0cb3a7e09f41e74a8df" + trim-right@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/trim-right/-/trim-right-1.0.1.tgz#cb2e1203067e0c8de1f614094b9fe45704ea6003" @@ -2049,6 +2373,10 @@ unc-path-regex@^0.1.0: version "0.1.2" resolved "https://registry.yarnpkg.com/unc-path-regex/-/unc-path-regex-0.1.2.tgz#e73dd3d7b0d7c5ed86fbac6b0ae7d8c6a69d50fa" +uniq@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/uniq/-/uniq-1.0.1.tgz#b31c5ae8254844a3a8281541ce2b04b865a734ff" + universalify@^0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/universalify/-/universalify-0.1.1.tgz#fa71badd4437af4c148841e3b3b165f9e9e590b7" @@ -2061,7 +2389,7 @@ util-deprecate@~1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" -uuid@^3.0.0, uuid@^3.0.1: +uuid@^3.0.0, uuid@^3.0.1, uuid@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.1.0.tgz#3dd3d3e790abc24d7b0d3a034ffababe28ebbc04" @@ -2099,6 +2427,10 @@ write@^0.2.1: dependencies: mkdirp "^0.5.1" +xregexp@^3.2.0: + version "3.2.0" + resolved "https://registry.yarnpkg.com/xregexp/-/xregexp-3.2.0.tgz#cb3601987bfe2695b584000c18f1c4a8c322878e" + yargs-parser@^7.0.0: version "7.0.0" resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-7.0.0.tgz#8d0ac42f16ea55debd332caf4c4038b3e3f5dfd9" diff --git a/joplin.sublime-project b/joplin.sublime-project index 3fe01f1f3..20b053d5d 100755 --- a/joplin.sublime-project +++ b/joplin.sublime-project @@ -2,8 +2,20 @@ "folders": [ { - "path": ".", - "folder_exclude_patterns": [ + "file_exclude_patterns": + [ + "*.map", + "CliClient/app/src", + "CliClient/app/lib", + "*.jar", + "*.po", + "*.pot", + "locales/*.json", + "ReactNativeClient/locales/*", + "src/log.txt", + ], + "folder_exclude_patterns": + [ "CliClient/node_modules", "CliClient/build", "CliClient/tests-build", @@ -19,19 +31,22 @@ "ReactNativeClient/android/.gradle", "ReactNativeClient/android/local.properties", "ReactNativeClient/ios", + "src/node_modules", "_vieux", "tests/logs" ], - "file_exclude_patterns": [ - "*.map", - "CliClient/app/src", - "CliClient/app/lib", - "*.jar", - "*.po", - "*.pot", - "locales/*.json", - "ReactNativeClient/locales/*", - ] + "path": "." + }, + { + "file_exclude_patterns": + [ + "src/log.txt", + ], + "folder_exclude_patterns": + [ + "node_modules", + ], + "path": "D:\\Docs\\PROGS\\Node\\tkwidgets" } ] }