-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Show tags as completion list #1966
Conversation
605342a
to
c5f61e6
Compare
Fixed linting problems, forced push. |
There is a code duplication, but my knowledge is not enough to refactor in to one method: getting tag list in completion menu and in sidenav. |
Please wait before merging, I will rebase on |
When editing a note, it is possible to select an already exist tag from a completion menu. It needs the latest Electron because of an `input` `datalist` bug. See: electron/electron#9860 NOTE: Clicking on tag does note selects it; needs pressing Enter or `blur` event, because I cannot find the proper event to detect mouse click: `onChange` and `onInput` is fired when selecting tag by keyboard and by mouse too.
1665702
to
4c40df5
Compare
Rebased to master, I'm done. |
Run |
I ran |
Here's the output of # yarn info v1.5.1
{ name: 'boost',
description: 'Robust pipeline for creating build tools that separate logic into routines and tasks.',
'dist-tags':
{ latest: '0.60.0' },
versions:
[ '0.0.0',
'0.0.1',
'0.0.2',
'0.0.3',
'0.0.4',
'0.0.5',
'0.0.6',
'0.0.8',
'0.0.9',
'0.0.10',
'0.0.11',
'0.0.12',
'0.1.0',
'0.2.0',
'0.3.0',
'0.4.0',
'0.6.0',
'0.7.0',
'0.8.0',
'0.9.0',
'0.10.0',
'0.11.0',
'0.12.0',
'0.12.1',
'0.13.0',
'0.13.1',
'0.14.0',
'0.15.0',
'0.15.1',
'0.16.0',
'0.16.1',
'0.17.0',
'0.18.0',
'0.19.0',
'0.19.1',
'0.20.1',
'0.21.0',
'0.21.1',
'0.21.2',
'0.22.0',
'0.23.0',
'0.24.0',
'0.25.0',
'0.26.0',
'0.27.0',
'0.28.0',
'0.29.0',
'0.29.1',
'0.30.0',
'0.31.0',
'0.32.0',
'0.32.1',
'0.34.0',
'0.34.1',
'0.35.0',
'0.35.1',
'0.36.0',
'0.38.0',
'0.38.1',
'0.40.0',
'0.41.0',
'0.42.0',
'0.43.0',
'0.45.0',
'0.46.0',
'0.47.0',
'0.48.0',
'0.48.1',
'0.48.2',
'0.49.0',
'0.49.1',
'0.50.0',
'0.51.0',
'0.51.1',
'0.52.0',
'0.52.1',
'0.53.0',
'0.53.1',
'0.54.0',
'0.54.1',
'0.55.0',
'0.56.0',
'0.56.1',
'0.57.0',
'0.58.0',
'0.59.0',
'0.59.1',
'0.59.2',
'0.60.0' ],
maintainers:
[ { name: 'milesj',
email: 'mileswjohnson@gmail.com' } ],
time:
{ modified: '2018-06-06T05:11:26.789Z',
created: '2013-01-15T03:08:07.241Z',
'0.0.0': '2013-01-15T03:08:08.867Z',
'0.0.1': '2013-01-15T03:43:54.068Z',
'0.0.2': '2013-01-15T07:31:28.377Z',
'0.0.3': '2013-02-07T22:12:13.424Z',
'0.0.4': '2016-12-20T02:43:37.995Z',
'0.0.5': '2016-12-20T07:27:32.481Z',
'0.0.6': '2017-04-02T00:17:41.810Z',
'0.0.8': '2017-04-02T02:33:04.912Z',
'0.0.9': '2017-04-02T03:32:39.859Z',
'0.0.10': '2017-04-02T05:26:26.120Z',
'0.0.11': '2017-04-06T01:52:32.528Z',
'0.0.12': '2017-04-08T02:53:42.646Z',
'0.1.0': '2017-05-19T02:05:50.351Z',
'0.2.0': '2017-10-29T05:52:14.723Z',
'0.3.0': '2017-10-31T06:06:36.880Z',
'0.4.0': '2017-11-03T05:51:41.091Z',
'0.6.0': '2017-11-06T06:44:46.216Z',
'0.7.0': '2017-11-07T03:46:48.592Z',
'0.8.0': '2017-11-11T08:56:18.375Z',
'0.9.0': '2017-11-11T09:39:02.480Z',
'0.10.0': '2017-11-13T07:13:20.896Z',
'0.11.0': '2017-11-15T08:02:22.371Z',
'0.12.0': '2017-11-16T07:45:52.992Z',
'0.12.1': '2017-11-16T08:00:05.742Z',
'0.13.0': '2017-11-17T03:31:08.906Z',
'0.13.1': '2017-11-17T08:08:03.273Z',
'0.14.0': '2017-11-22T06:35:08.297Z',
'0.15.0': '2017-11-22T06:46:12.503Z',
'0.15.1': '2017-11-23T05:11:06.678Z',
'0.16.0': '2017-11-23T06:12:20.775Z',
'0.16.1': '2017-11-23T06:47:17.799Z',
'0.17.0': '2017-11-26T22:00:01.617Z',
'0.18.0': '2017-11-30T06:51:19.403Z',
'0.19.0': '2017-12-01T02:29:38.904Z',
'0.19.1': '2017-12-01T02:44:36.525Z',
'0.20.1': '2017-12-01T03:13:18.607Z',
'0.21.0': '2017-12-01T06:29:05.967Z',
'0.21.1': '2017-12-01T07:35:37.937Z',
'0.21.2': '2018-01-21T05:10:45.862Z',
'0.22.0': '2018-01-23T05:27:15.136Z',
'0.23.0': '2018-01-26T02:04:06.937Z',
'0.24.0': '2018-01-27T08:36:02.453Z',
'0.25.0': '2018-01-28T07:25:48.745Z',
'0.26.0': '2018-01-29T07:06:56.792Z',
'0.27.0': '2018-01-30T07:29:34.735Z',
'0.28.0': '2018-02-03T06:20:07.827Z',
'0.29.0': '2018-02-03T06:53:56.911Z',
'0.29.1': '2018-02-03T07:45:48.321Z',
'0.30.0': '2018-02-04T18:58:54.442Z',
'0.31.0': '2018-02-06T06:45:44.372Z',
'0.32.0': '2018-02-16T07:49:27.091Z',
'0.32.1': '2018-02-16T07:55:54.172Z',
'0.34.0': '2018-03-08T04:42:23.520Z',
'0.34.1': '2018-03-08T04:56:05.156Z',
'0.35.0': '2018-03-15T01:49:36.892Z',
'0.35.1': '2018-03-16T00:32:15.017Z',
'0.36.0': '2018-03-25T06:47:29.605Z',
'0.38.0': '2018-03-25T06:47:54.990Z',
'0.38.1': '2018-03-26T01:11:52.128Z',
'0.40.0': '2018-04-10T05:48:39.231Z',
'0.41.0': '2018-04-11T01:51:16.053Z',
'0.42.0': '2018-04-11T02:42:57.949Z',
'0.43.0': '2018-04-13T01:44:06.306Z',
'0.45.0': '2018-04-28T08:00:04.551Z',
'0.46.0': '2018-04-28T08:08:08.901Z',
'0.47.0': '2018-04-28T22:42:57.756Z',
'0.48.0': '2018-04-29T20:41:18.155Z',
'0.48.1': '2018-05-01T00:59:59.478Z',
'0.48.2': '2018-05-01T01:03:12.091Z',
'0.49.0': '2018-05-01T01:28:28.654Z',
'0.49.1': '2018-05-01T02:37:39.892Z',
'0.50.0': '2018-05-02T02:38:03.810Z',
'0.51.0': '2018-05-05T01:26:35.382Z',
'0.51.1': '2018-05-05T01:52:37.217Z',
'0.52.0': '2018-05-05T04:09:36.642Z',
'0.52.1': '2018-05-05T06:59:08.873Z',
'0.53.0': '2018-05-06T04:01:11.828Z',
'0.53.1': '2018-05-07T02:09:53.219Z',
'0.54.0': '2018-05-09T04:57:49.106Z',
'0.54.1': '2018-05-09T05:05:33.504Z',
'0.55.0': '2018-05-11T03:33:04.952Z',
'0.56.0': '2018-05-18T06:47:13.344Z',
'0.56.1': '2018-05-20T05:35:46.926Z',
'0.57.0': '2018-05-25T07:13:36.531Z',
'0.58.0': '2018-06-01T01:13:33.099Z',
'0.59.0': '2018-06-03T20:32:27.787Z',
'0.59.1': '2018-06-03T20:49:25.130Z',
'0.59.2': '2018-06-03T20:50:42.277Z',
'0.60.0': '2018-06-06T05:11:23.999Z' },
author:
{ name: 'Miles Johnson',
url: 'http://milesj.me' },
repository:
{ type: 'git',
url: 'git+https://github.com/milesj/boost.git' },
keywords: [],
license: 'MIT',
readmeFilename: 'README.md',
homepage: 'https://github.com/milesj/boost#readme',
bugs:
{ url: 'https://github.com/milesj/boost/issues' },
version: '0.60.0',
main: './lib/index.js',
types: './lib/index.d.ts',
scripts:
{ babel: 'beemo typescript --node',
build: 'yarn run babel',
clean: 'rimraf ./{lib,esm}/',
coverage: 'yarn run jest --coverage',
eslint: 'beemo eslint',
jest: 'beemo jest',
package: 'yarn run clean && yarn run build && yarn test',
prettier: 'beemo prettier',
pretest: 'yarn run type',
test: 'yarn run jest',
posttest: 'yarn run eslint',
type: 'beemo typescript --noEmit',
prerelease: 'yarn run package',
release: 'np --yolo --no-yarn' },
engines:
{ node: '>=6.5.0' },
dependencies:
{ '@types/chalk': '^2.2.0',
'@types/debug': '^0.0.30',
'@types/execa': '^0.9.0',
'@types/glob': '^5.0.35',
'@types/json5': '^0.0.29',
'@types/lodash': '^4.14.109',
'@types/pluralize': '^0.0.28',
'@types/split': '^0.3.28',
chalk: '^2.4.1',
'cli-truncate': '^1.1.0',
debug: '^3.1.0',
execa: '^0.10.0',
glob: '^7.1.2',
json5: '^1.0.1',
lodash: '^4.17.10',
optimal: '^0.19.0',
pluralize: '^7.0.0',
split: '^1.0.1' },
peerDependencies:
{ optimal: '^0.19.0' },
devDependencies:
{ '@milesj/build-tool-config': '0.100.1',
'fs-extra': '^6.0.1' },
beemo:
{ module: '@milesj/build-tool-config',
drivers:
[ 'babel',
'eslint',
{ driver: 'jest',
env:
{ NODE_ENV: 'test' } },
'prettier',
'typescript' ] },
gitHead: '6dbf5f8d48074b28a5431ec97e5b0b3f36511f38',
dist:
{ integrity: 'sha512-ojd/+EWCiBGB2bMMZHW5+VJRD4nN2dDq5LBRfBrlOdAYI2hzshvb/Y8iLtTtzmfVsuGP2FAFrD1VNUbDV45uDA==',
shasum: 'd72ab5392127ccab86e7f5d15afa927dc6a96f4d',
tarball: 'https://registry.npmjs.org/boost/-/boost-0.60.0.tgz',
fileCount: 63,
unpackedSize: 409964,
'npm-signature': '-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbF2z8CRA9TVsSAnZWagAA/XwP/3cPKrFAdLxOUN8cFKhm\n/9AC+kbLZYRcCLMff0SuKVpPYbxJZQuXyfHOvhUTBptzjUsI54npqy/Z4vG7\ni0d4Ni6cu/u4vd/zt1sml6kCuGmvNl22dCIT4ELSpCOTSpKr7WHhgLJvl+j5\nAn0/UIBRKrE/z5AqIIvctpWex60Bp/dbtIvEJjHItzeIRGQ377RQjCrv+cI7\nY/DL4FN2t16YuhGd6AQPrpQdbAVXgDfi9hVnHT15lgORoCuUvs//NkLrlJTW\nCt6mR8v87t89GtBd9X4Nr+Cbs1fsPyLec/9YGtHD63Hs4vly3CJRarEhZfZB\noo2Cc/TMl8nwtgX89oBJWhnwkb+mRwBL1im7IwLI9Z1ANA31t345jLkXdW8D\npp4cUsHQxvu8JRNBRcupBGj/Fub7iDn9bVydZf5NSjCmqlH/o223653EJTal\nG0ePB2ESJ1KCeUhi+6OkON6ezJQrGemMq8UWT1Fse6OPEjQiSaW77126S0bo\n3FupO1IArkeXZLfzIjhbpl1XvWGwfj2vER4hOGMPXmHo0lB3Ap7MWOpaAh6Z\nbdgp8nP+oIq4+zLHCsl080tDW8jeE4jdg7Ik0RfQLn//7bPKj3qoOb2dArx2\n13llDqPkEKB4K5DRYnDiodDO5CDfR58oNKmRaWGbBpi7JzejcZ3CwH3uMHo6\nOa4a\r\n=a5bn\r\n-----END PGP SIGNATURE-----\r\n' },
directories: {} } |
Maybe try Just found an interesting thing: why Electron is not listed in devDependencies:
{ '@milesj/build-tool-config': '0.100.1',
'fs-extra': '^6.0.1' }, |
:D Bahh, sorry, it's just an info about Yarn, I misunderstood. So this is what I wanted:
|
Umm...
installed electron version is 1.8.7. But, my local environment can't execution your feature... |
I've tested on v1.8.7 and confirmed it still doesn't work. Let's wait for the next version of electron. |
Just to note that the latest Electron is now v2.0.2. Is this merge stalled due to the potential complexity of updating the major version of the Electron dependency? |
Just realised Electron v2.0.2 is now the version depended on in master: https://github.com/BoostIO/Boostnote/blob/c42e1a0ab403d7d10b8181250c5340e85c6ca076/package.json#L123 So potentially this can be re-tested and maybe merged? (I'm excited to have this feature 😄) |
Just tried out on Linux, it works. |
@sosukesuzuki Can you please check it on Mac? |
@bimlas Sorry for delay. Just tried out on MacOS, doesn't work... |
@Rokt33r tested it, does not works. |
Closing, because #2320 solved the issue. |
When editing a note, it is possible to select an already exist tag from
a completion menu.
It needs the latest Electron because of an
input
datalist
bug. See:electron/electron#9860
Because of this, it needs #1955 to be merged first.
NOTE:
Clicking on tag does note selects it; needs pressing Enter or
blur
event, because I cannot find the proper event to detect mouse click:
onChange
andonInput
is fired when selecting tag by keyboard and bymouse too.
Before:
After: