Commit graph

3580 commits

Author SHA1 Message Date
Ben Gotow
c5ff2f640b fix(onboarding): Fire event when user selects account type 2016-10-07 10:16:20 -07:00
Luke Schlangen
a8865eb2a2 Fixing broken screenshot link (#2911)
Replacing with new screenshot
2016-10-06 18:48:12 -07:00
Ben Gotow
0eef80e5d4 fix(db): Switch to better-sqlite3, resolves offline issue
Summary:
Better-SQLite3 is a fork of node-sqlite3 which includes a re-written JavaScript interface. It’s more synchronous, but better reflects what is actually sync vs. async in sqlite’s C++ API. (Not much is really async under the hood.) This diff uses a branch of better-sqlite3 I’ve edited to support Node 6.

In my tests, this branch spends 3.24x less time executing queries than `master`. (Measured time spent in calls to `this._db[run|all|get]` over the first 5000 queries of initial sync. It also increased the performance of starring a thread in the thread list by 28%.

This library also allows us to use a prepared statement cache, which is great because we often make the same queries repeatedly as query subscriptions refresh the UI and deltas are dumped into the app. The old interface didn’t expose statements (cached query plans) to JS.

better-sqlite3 advertises that it uses the JS garbage collector instead of lower level C++ memory management. I tested syncing my entire mailbox to verify that memory usage is not significantly different on this branch after a lot of queries have been made.

Finally, it looks like we can finally stop building sqlite3 from scratch in `script/bootstrap`. This library builds properly with `apm install`. 🎉

We might want to change the DatabaseStore and DatabaseTransaction classes more, now that it’s possible to execute queries synchronously. It could make things cleaner and get us out of promise-hell in a few places. In this diff I tried to change as little as possible.

Test Plan: Run tests, everything still works

Reviewers: juan, jackie

Reviewed By: juan, jackie

Differential Revision: https://phab.nylas.com/D3315
2016-10-06 17:01:22 -07:00
Evan Morikawa
f2c1ac3289 refator(notification): move base notification to nylas-component-kit 2016-10-06 10:53:22 -07:00
Ben Gotow
0bb26bce79 fix(perspectives): Restore when only account cannot be found (Sentry 59061)
https://sentry.nylas.com/sentry/edgehill/group/59061/
2016-10-04 14:15:52 -07:00
Ben Gotow
a232f6fc17 fix(templates): Handle error when scanning dir (Sentry 44351)
https://sentry.nylas.com/sentry/edgehill/group/44351/
2016-10-04 14:15:52 -07:00
Ben Gotow
8a3efdd6f7 fix(phising): Handle scenarios where input is malformed (Sentry 51642)
https://sentry.nylas.com/sentry/edgehill/group/51642/
2016-10-04 14:15:52 -07:00
Juan Tejada
aaca39f9c7 fix(lint) 2016-10-04 12:06:43 -07:00
Juan Tejada
b1c6a9996f bump(submodule) 2016-10-04 11:17:57 -07:00
Halla Moore
dcb84db3e3 feat(sidebar-notifs) Create sidebar notifications to replace old bars
Summary:
Move the old bar notifications to the sidebar, and only display one notification
at a time using a priority-rating system. Remove all of the old notification
infrastructure.

Test Plan: Added specs, also reproduced notifications locally

Reviewers: bengotow

Reviewed By: bengotow

Subscribers: juan

Differential Revision: https://phab.nylas.com/D3310
2016-10-04 08:08:23 -07:00
Ben Gotow
dda7c50adf fix(files): When download mode is “manual” prompt about inline attachments
Summary:
When you have your "Download attachments for new mail" setting set
to "manually", inline images always appear broken with no explanation.

This patch listens for the image load to fail and displays a button which
queues the fetchFile task on click. This seemed like the best approach because
it doesn't slow down the loading of the message with more fstats / lookups.
(Seeing if the file has already been downloaded is an async operation)

Test Plan: No specs atm

Reviewers: evan, juan

Reviewed By: juan

Differential Revision: https://phab.nylas.com/D3313
2016-10-03 11:22:44 -07:00
Juan Tejada
b1dddd1541 fix(tools): Make arc lint great again
Add proper arc config for linting ES6 files with eslint
2016-10-02 10:56:11 -07:00
Juan Tejada
dafffa87d5 🔪 Last remaining traces of coffeescript in submodule! 2016-10-02 10:55:41 -07:00
Evan Morikawa
8fd6fe27ca fix(composer): tokenizing text field trigger logic moved to composer 2016-10-02 12:05:31 -04:00
Evan Morikawa
f7c2703683 fix(composer): fix margin when editing contact chip 2016-10-02 12:05:25 -04:00
Evan Morikawa
5ea9d110cb fix(composer): can shift-tab more places
Allow shift-tab to go back to subject from anywhere except in front of a
tab character
2016-10-02 12:05:14 -04:00
Evan Morikawa
376158c9b9 fix(composer): enable click regions on margins of composer
Change padding, margins, and borders to allow you to click on the left
margin of to, cc, bcc, from, subject fields as well as the composer
margins both above, left, and to the right of the composer.

Ensured attachments and other assets show up in correct spots

Ensure subject looks correct for mail merge
2016-10-02 12:04:55 -04:00
Juan Tejada
a47eb50705 fix(specs): Activity List 2016-10-01 00:25:20 -07:00
Juan Tejada
c1396c877a fix+🎨(notifs): Cleanup, handle nonexistent thread when opening notification
Notifications now check to see the thread they are supposed to open
exists.

Also, clean up FocusedContentStore._onFocus so that it doesn't have the side
effect of dispatching another action and messay logic.
Instead, added Actions.ensureCategoryFocused, to focus any category, and which
should be used separately from focusing content (notifications now use
this action for "opening" the thread)
Also, convert FocusedPerspectiveStore to ES6
2016-10-01 00:08:19 -07:00
Juan Tejada
93281f859f 💄(outline-view): Add title attr for tooltips 2016-09-30 21:01:30 -07:00
Ben Gotow
1b8c41d057 es6(db): Move DatabaseStore to ES6 2016-09-30 15:24:34 -07:00
Ben Gotow
a2b9e22157 fix(dev-mode): Don’t save to config.json, use flag instead
Turns out even the built, packaged version of the app can be restarted into dev mode by adding `—dev` to argv and using the new relaunch API.
2016-09-30 14:37:03 -07:00
Juan Tejada
7d7700edb7 fix(share-thread): Closed when blurred when blurred or new thread selected 2016-09-30 13:48:12 -07:00
Juan Tejada
7acc8dc995 fix(tutorial-tips): Recompute pos when theme changes 2016-09-30 13:46:17 -07:00
Ben Gotow
2e66cf9ef6 fix(specs): Minor spec fixes 2016-09-30 11:58:57 -07:00
Ben Gotow
31bf2e2ce7 fix(spellcheck): Do not spellcheck <code>, <a>, <pre> tags
This fixes #2877. The templates feature becomes broken when variable names contain misspellings.
2016-09-30 11:53:52 -07:00
Ben Gotow
325ce1b12e fix(participants): When copying, include space #2871 2016-09-30 10:48:34 -07:00
Juan Tejada
805e665b6e fix(tutorial-tips): Don't display when component is not visible 2016-09-29 20:31:52 -07:00
Juan Tejada
796e7e1a14 💄(share-thread): Fix positioning of share thread button 2016-09-29 20:30:03 -07:00
Ben Gotow
c222fa0c39 fix(data-source): Wait until the next cycle to cleanup
Fixes a crash when switching to the thread list from the draft list, where there are very briefly zero observers.
2016-09-29 13:42:52 -07:00
Ben Gotow
1e9d1dff07 bump(verison): 0.4.56, more items in changelog 2016-09-29 12:24:15 -07:00
Halla Moore
02eaf34c6c feat(self-hosting) Add onboarding page about self-hosting plugin restrictions 2016-09-29 12:12:05 -07:00
Halla Moore
c2b9b3070a fix(self-hosting) Don't load packages that don't support self-hosting 2016-09-29 12:12:05 -07:00
Juan Tejada
4e3332386a fix(composer): When pasting links that are tracked, extract actual link 2016-09-29 11:30:19 -07:00
Ben Gotow
7997e70a84 feat(bios): Linkify twitter hashtags and mentions in bios 2016-09-29 11:25:08 -07:00
Ben Gotow
af278e0765 rm(ship-logs): Remove unused log shipping, prevents many-processes bug on win32 2016-09-29 10:38:29 -07:00
Evan Morikawa
787781b3a9 fix(linter): fix linter error 2016-09-29 10:05:11 -05:00
Evan Morikawa
ec51730e24 fix(spec): remove unnecessary messages & prevent extra hot window 2016-09-29 09:52:51 -05:00
Ben Gotow
6fad7a9ceb fix(composer): Wrap composer instead of allowing overflow-x 2016-09-28 17:39:44 -07:00
Ben Gotow
3940a0abbd fix(window-state): Per electron#7278, save state in beforeunload
Related:
https://github.com/electron/electron/issues/7278
https://github.com/atom/atom/pull/3223/files

As of Chromium 36, unload is async and @zcbenz does not think it happens reliabily in Electron. Move saving of window state to beforeunload, following suit with Atom.
2016-09-28 17:39:44 -07:00
Juan Tejada
7391dd782b 🎨(activity-list): punctuation 2016-09-28 17:22:50 -07:00
Juan Tejada
878dc293bc fix(dev): Pretty print deltas 2016-09-28 16:51:50 -07:00
Juan Tejada
7c871a8618 fix(draft-list): Don't render html string in draft subject 2016-09-28 16:02:47 -07:00
Juan Tejada
302aca5a4e fix(lint): Fix coffeelint errors 2016-09-28 15:58:16 -07:00
Juan Tejada
a3497956ba 🎨(thread-sharing): Fix icon 2016-09-28 15:56:37 -07:00
Juan Tejada
4e1f8c9b53 fix(specs): Fix mail merge specs 2016-09-28 15:02:36 -07:00
Ben Gotow
dc15c3e243 fix(perspectives): More robust validation of saved perspectives, never open to blank screen 2016-09-28 14:46:08 -07:00
Ben Gotow
96ab35cb8e fix(composer): Add additional isMounted checks
Resolves this exception: https://gist.github.com/jstejada/a26dc6a7a2896dcef9be3cec60eaecdb
2016-09-28 14:46:08 -07:00
Juan Tejada
0e6b4a0c96 fix(mail-merge): Reduce limit to 150 messages, improve error handling 2016-09-28 13:27:59 -07:00
Ben Gotow
6815c36065 fix(calendar): CSS layout fix for Chromium 53 2016-09-28 12:14:50 -07:00