Commit graph

1764 commits

Author SHA1 Message Date
Evan Morikawa e5ca74684d fix(onboarding): properly base64 encode string 2016-06-02 14:45:48 +01:00
Evan Morikawa 81c8cd6a8b fix(analytics): fix errors in onboarding flow 2016-06-02 11:16:41 +01:00
Evan Morikawa 7c870d7cd2 feat(analytics): update analytics libraries
Summary:
See
https://paper.dropbox.com/doc/Analytics-ID-Unification-oVDTkakFsiBBbk9aeuiA3

Test Plan: Manual

Reviewers: juan, bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D2998
2016-06-02 03:38:51 -04:00
Ben Gotow 2ac8987211 fix(tutorial): Incorrect strings 2016-06-01 17:25:08 -07:00
Juan Tejada ce968c0d3e update(sidebar): Moves accounts in sidebar state to FocusedPerspectiveStore
Summary:
- FocusedPerspectiveStore now holds the state of the accounts that are currently being displayed in the sidebar, i.e. unified inbox or not, which makes it globally accessible state. The SidebarStore just reads this state directly off of the FocusedPerspectiveStore to decide which sections and items to display in the sidebar.
- Updates `Actions.focusDefaultMailboxPerspectiveForAccounts` to take an optional array of `sidebarAccountIds` to set in the sidebar. The default behavior is to show the accounts of the perspective that will be focused. E.g. when selecting an account via the account switcher, it will just show the sidebar items for the single account that was selected, but when adding a new account, we are setting the sidebar accounts to all account although we are still focusing the perspective for a single account.
- Will now show unified inbox sidebar with correctly focused account when new account added.
- Cleans up the code a little bit, but this package still needs major refactor

Test Plan: Missing!

Reviewers: jackie, bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D3002
2016-06-01 17:13:46 -07:00
Jackie Luo 8de83d26d3 🎨(participant-profile): Use UI variables 2016-06-01 16:08:10 -07:00
Ben Gotow 7f09e72182 fix(account-store): Update fake data import for screenshots 2016-06-01 15:55:44 -07:00
Ben Gotow dd432e338b fix(undo): Improve messaging around label changes, modernize undo-redo-store
Summary: Just a small patch to address bad messaging

Test Plan: Run one new test!

Reviewers: jackie, juan

Reviewed By: jackie, juan

Differential Revision: https://phab.nylas.com/D3000
2016-06-01 14:36:57 -07:00
Jackie Luo c6e28d3ebb fix(emoji): Remove special casing for Outlook emoji 2016-06-01 11:11:51 -07:00
Ben Gotow 66613470fd fix(specs): Empty parameter list 2016-05-31 19:10:11 -07:00
Ben Gotow e3a08c8e7a fix(category-picker): Update specs for sorting 2016-05-31 17:05:17 -07:00
Ben Gotow 9d0db18dc9 fix(category-picker): Sort categories displayed in picker 2016-05-31 17:01:02 -07:00
Ben Gotow 52cc1a6e33 fix(mail-rules): Fix re-ordering of mail rules 2016-05-31 16:42:03 -07:00
Jackie Luo b5ad43a686 fix(themes): Add Less is More to list ordering 2016-05-31 14:35:49 -07:00
Ben Gotow 9c54677753 fix(auth): Wait 150s for Exchange autodiscovery to complete 2016-05-31 14:04:22 -07:00
Ben Gotow 14dce13276 fix(unified-inbox): If a Gmail account is present, show Important 2016-05-31 12:24:38 -07:00
Ben Gotow 8a71c23bb4 fix(pro): Upgrade buttons go to /payment 2016-05-31 12:24:38 -07:00
Ollie Ford 3df2b1e3be warns suspicious message only on differing domain (#2343)
For example, the following is *not* suspicious:
```
From: foo@example.org
Reply-To: bar@example.org
```

While the following remains suspicious:
```
From: foo@example.org
Reply-To: foo@example.com
``` 

This commit fixes #2342.
2016-05-31 12:08:18 -07:00
Ben Gotow 8385097341 fix(pro): Don't refresh identity unless one is present 2016-05-27 15:37:49 -07:00
Jackie Luo 6713827e65 fix(email-frame): Allow events to bubble correctly and pass iframe 2016-05-27 15:18:12 -07:00
Ben Gotow c6354feb41 feat(pro): New Nylas identity provider, onboarding and auth
commit 50d0cfb87c
Author: Ben Gotow <bengotow@gmail.com>
Date:   Fri May 27 14:01:49 2016 -0700

    IdentityStore conveniene methods for subscription state

commit 80c3c7b956
Author: Ben Gotow <bengotow@gmail.com>
Date:   Fri May 27 12:03:53 2016 -0700

    Periodically refresh identity, show expired notice in top bar

commit 5dc39efe98
Merge: 4c4f463 906ea74
Author: Juan Tejada <juans.tejada@gmail.com>
Date:   Thu May 26 15:17:46 2016 -0700

    Merge branch 'bengotow/n1-pro' of github.com:nylas/N1 into bengotow/n1-pro

commit 4c4f463f4b
Author: Juan Tejada <juans.tejada@gmail.com>
Date:   Thu May 26 15:16:48 2016 -0700

    Hijack links inside email that go to billing site and add SSO to them

commit 906ea74807
Author: Ben Gotow <bengotow@gmail.com>
Date:   Thu May 26 12:02:29 2016 -0700

    Add custom welcome page for upgrading users

commit 2ba9aedfe9
Author: Juan Tejada <juans.tejada@gmail.com>
Date:   Wed May 25 17:27:12 2016 -0700

    Add styling to Subscription tab in prefs

commit 384433a338
Author: Ben Gotow <bengotow@gmail.com>
Date:   Wed May 25 16:21:18 2016 -0700

    Add better style reset, more IdentityStore changes

commit c4f9dfb4e4
Author: Ben Gotow <bengotow@gmail.com>
Date:   Wed May 25 15:29:41 2016 -0700

    Add subscription tab

commit bd4c25405a
Author: Ben Gotow <bengotow@gmail.com>
Date:   Wed May 25 14:18:40 2016 -0700

    Point to billing-staging for now

commit 578e808bfc
Author: Ben Gotow <bengotow@gmail.com>
Date:   Wed May 25 13:30:13 2016 -0700

    Rename account helpers > onboarding helpers

commit dfea0a9861
Author: Ben Gotow <bengotow@gmail.com>
Date:   Wed May 25 13:26:46 2016 -0700

    A few minor fixes

commit 7110217fd4
Author: Ben Gotow <bengotow@gmail.com>
Date:   Wed May 25 12:58:21 2016 -0700

    feat(onboarding): Nylas Pro onboarding overhaul

    Summary:
    Rip out all invite-related code

    Enable Templates and Translate by default

    Scrub packages page, unused code in onboarding pkg

    Remove resizing

    New onboarding screens

    IMAP provider list, validation

    Call success with response object as well

    Renaming and tweaks

    Test Plan: No tests yet

    Reviewers: evan, juan, jackie

    Differential Revision: https://phab.nylas.com/D2985

commit dc9ea45ca9
Author: Ben Gotow <bengotow@gmail.com>
Date:   Wed May 25 12:52:39 2016 -0700

    Renaming and tweaks

commit 5ca4cd31ce
Author: Ben Gotow <bengotow@gmail.com>
Date:   Wed May 25 11:03:57 2016 -0700

    Call success with response object as well

commit 45f14f9b00
Author: Ben Gotow <bengotow@gmail.com>
Date:   Tue May 24 18:26:38 2016 -0700

    IMAP provider list, validation

commit c6ca124e6e
Author: Ben Gotow <bengotow@gmail.com>
Date:   Sat May 21 11:14:44 2016 -0700

    New onboarding screens

commit dad918d926
Author: Ben Gotow <bengotow@gmail.com>
Date:   Thu May 19 16:37:31 2016 -0700

    Remove resizing

commit ecb1a569e2
Author: Ben Gotow <bengotow@gmail.com>
Date:   Thu May 19 16:36:04 2016 -0700

    Scrub packages page, unused code in onboarding pkg

commit 3e0a44156c
Author: Ben Gotow <bengotow@gmail.com>
Date:   Thu May 19 16:33:12 2016 -0700

    Enable Templates and Translate by default

commit 0d218bc86f
Author: Ben Gotow <bengotow@gmail.com>
Date:   Thu May 19 16:30:47 2016 -0700

    Rip out all invite-related code
2016-05-27 14:21:19 -07:00
Juan Tejada e103809b34 fix(mail-merge): Switch to using new overlaid components api
Summary:
- Fixes several selection and focus issues along the way
- Can now preview what tokens will look like when not editing
- Adds decorator to listen to mail merge session changes and removes a bunch of duplicated code
- Gets rid of all imperative code (and specs) that had to imperatively
reach into the dom to update the tokens

Test Plan: - Unit tests

Reviewers: bengotow, evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D2989
2016-05-27 11:02:44 -07:00
Jackie Luo d9b6529df7 Revert "🎨(ui-dark): Remove iframe inversion" 2016-05-25 23:46:36 -07:00
Ben Gotow 2eb331aae3 fix(packages): Show version numbr of 3rd party plugins 2016-05-25 14:13:42 -07:00
Ben Gotow 7e3ddba016 fix(ubuntu): Update theme, fix a few strange glitches 2016-05-25 14:03:09 -07:00
Ben Gotow 0c77f61838 fix(config): removeAtKeyPath => undo, guard with assertions 2016-05-25 14:03:09 -07:00
Juan Tejada 6e57cbaee4 fix(build): Fix remaining specs (composer-view, send-draft-task) 2016-05-25 10:25:36 -07:00
Juan Tejada 39611f8962 fix(specs): Fix merge conflicts and some specs 2016-05-24 19:04:20 -07:00
Juan Tejada db868740c8 fix(build): Fix lint error 2016-05-24 17:53:15 -07:00
Juan Tejada a4ee61eadc fix(mail-merge): Refactor mass sending procedure
Summary:
This diff introduces several updates to mail merge to improve the procedure for sending a list of drafts.
Specifically, sending mass email will now:

- Clear mail merge metadata on the drafts that will actually be sent
- Upload attached files only /once/, and reuse those files on the drafts that will actually be sent
- Minimize database writes for new drafts being created
- Will queue a SendManyDraftsTask that will subsequently queue the necessary SendDraftTasks and keep track of them, and notify of any failed tasks

TODO:
- Add state to MailMerge plugin for failed sends and ability to attempt to re send them

Test Plan: - TODO

Reviewers: evan, bengotow, jackie

Reviewed By: bengotow, jackie

Subscribers: jackie

Differential Revision: https://phab.nylas.com/D2973
2016-05-24 17:22:09 -07:00
Evan Morikawa c9ea5b6483 feat(scheduler): Add Overlaid Components
Summary:
SEE ASSOCIATED SUBMODULE DIFF

This enables rich React components (like the Scheduler's `NewEventCard`)
to be used in contenteditables.

We introduce the concept of an "Overlaid Component". These are rendered
React components that are absolutely positioned on top of an equivalent
"Anchor" in a contenteditable.

Inside the contenteditable are special `<img />` tags that have an
id corresponding to a particular rich overlaid component. This way, even
if those img tags are cut and pasted or moved, they'll have a mapping to a
  particular component stored in the `OverlaidComponentStore`. Img tags
  are fairly well handled natively by contenteditable and allow you to
  maniuplate these overlaid components as normal text elements.

The `OverlaidComponentStore` is responsible for listening to and managing
the state of the Anchors and their equivalent OverlaidComponents.

We use a decorator called `ListenToChanges` that allows us to wrap
components to update their corresponding anchor. Since we need to know
about ALL changes that could affect rendered height and width, we need to
use a `MuatationListener` instead of the React render cycle.

This is only the initial diff. There are several TODOs here:
https://paper.dropbox.com/doc/Composer-Overlaid-Components-FoZrF0cFggzSUZirZ9MNo

Test Plan: TODO. Manual

Reviewers: juan, bengotow

Reviewed By: juan

Differential Revision: https://phab.nylas.com/D2946
2016-05-24 15:47:49 -07:00
Ben Gotow 77733253eb fix(undo): Move undo/redo to session, properly undo all changes
Summary:
- Simplify undoManager to just maintain the undo/redo history items
- DraftEditingSession manages snapshotting state of draft, hack allows it to also save selection (still hoping to eventually put selection in body HTML as markers)
- Switch from `debounce` to `throttle` style behavior so typing for along time followed by undo doesn't undo away your entire block.

This resolves two issues:
+ Changes to participant fields are no longer undoable because they go straight to the session.
+ Changes to metadata weren't undoable.

Test Plan: Tests WIP

Reviewers: evan, juan

Reviewed By: juan

Differential Revision: https://phab.nylas.com/D2956
2016-05-24 11:48:33 -07:00
Ben Gotow c2e9ac6fab fix(dialogs): Use new buttonLabel as needed 2016-05-23 10:34:44 -07:00
Ben Gotow 52f050c5f5 fix(pli): Always indent where indicators are, even if blank 2016-05-19 14:58:12 -07:00
Juan Tejada 072490ebcc fix(send-later): Check if draft is valid before scheduling send later 2016-05-19 13:28:28 -07:00
Juan Tejada 11799c8ce8 fix(accts): Display perspective for a newly added acct correctly
- Will wait for categories to be ready before attempting to focus the
inbox for the new account, preventing a blank screen when a new account
is added
- Add temprary action to set the collapsed state of a sidebar action
after adding a new account
2016-05-19 12:12:22 -07:00
Juan Tejada 04e3a5a3a1 fix(sidebar): Add state to determine wether to show unified sidebar
- Adds a piece of global state that will be persisted to
`NylasEnv.savedState` indicating wether the accounts for the sidebar
should be reset whenever the FocusedPerspective changes
- #2257
2016-05-19 11:30:31 -07:00
Juan Tejada 7f735e9f41 fix(aliases): Properly set selected state on account update 2016-05-18 17:35:07 -07:00
Jackie Luo 29b448989c fix(plugins): Update plugins list on install 2016-05-18 16:02:57 -07:00
Jackie Luo fdc7b0aa5d 🎨(templates): Change language and remove gray box in demo template 2016-05-18 15:30:16 -07:00
Ben Gotow 5b5320997f fix(pkg-install): Use the package.json name, not the folder name 2016-05-18 15:25:18 -07:00
Ben Gotow 564d77421f perf(spellcheck): Limit misspellings to 15, recycle nodes 2016-05-17 18:48:01 -07:00
Evan Morikawa 0db70868a8 fix(composer): reduction in composer bootup time 2016-05-17 15:03:49 -07:00
Evan Morikawa 517a9cdd47 feat(perf): add perf monitoring to composer open time
Summary:
Add basic globally accessible performance monitoring.

Allows us to measure load times for composer windows (or whatever else we
want) and view the data as a Histogram on Mixpanel

Test Plan: manual

Reviewers: bengotow, juan

Reviewed By: juan

Differential Revision: https://phab.nylas.com/D2965
2016-05-17 14:23:14 -07:00
Evan Morikawa 6f355093e0 feat(composer): speed up composer loading & fix deactivate error 2016-05-17 12:37:46 -07:00
Juan Tejada 907ee68aa7 fix(snooze): Fix path to main file in package.json 2016-05-16 17:53:42 -07:00
Juan Tejada 417b09f2ff fix(snooze): Sentry error: "Can't create Snooze Category"
- This error was still being thrown for a large number of accounts,
despite the fact that the N1-Snoozed category was being created
- This error was happening when adding a new account which did not already have a
snooze category in the backend:
  - When the account is added the AccountStore triggers more than once,
  causing the SnoozeStore to send more than one request to create the
  same category. Any request after the first one will fail because the
  category already exists
- The fix is not try to create a category unless the accounts have
actually changed
2016-05-16 16:21:27 -07:00
Ben Gotow bb40df97fe fix(config): Move all reads / writes to the main process
Summary:
Moves all reading / writing of config file to the main process,
to avoid needing to write code to lock across processes. This should also
be more efficient than re-loading the file in all processes when it's
saved.

Test Plan: Run tests

Reviewers: evan, jackie

Reviewed By: evan, jackie

Differential Revision: https://phab.nylas.com/D2963
2016-05-16 16:38:46 -05:00
Ben Gotow 345d006533 fix(connection): account.id => accountId 2016-05-16 03:26:23 -05:00
Ben Gotow b3b6276f4e Revert "refactor(deltas): Update sync-worker to use NylasAPI.longConnection"
This reverts commit 1a78a758f4.

# Conflicts:
#	internal_packages/worker-sync/lib/delta-streaming-connection.es6
#	internal_packages/worker-sync/lib/nylas-sync-worker.coffee
#	internal_packages/worker-sync/spec/nylas-sync-worker-spec.coffee
#	src/flux/nylas-long-connection.es6
2016-05-16 01:25:30 -05:00
Ben Gotow e23d597493 fix(keymaps): Handle empty keymap.json, recover when saving 2016-05-15 12:19:03 -05:00
Ben Gotow f865b48f4e fix(auth): Revert imap => custom, bump package.json 0.4.37 2016-05-15 11:14:16 -05:00
Ben Gotow 288023639b fix(linux): Add libappindicator1 note, improved View menu 2016-05-15 00:05:25 -05:00
Jackie Luo 9a569c41ae 🎨(ui-dark): Remove iframe inversion 2016-05-13 23:03:33 -07:00
Ben Gotow f6a90d12c5 fix(imports): Don't use relative paths with ASAR 2016-05-13 18:05:24 -07:00
Ben Gotow ef328fe451 fix(templates): QA pass on templates, resolve #2216 2016-05-13 17:14:04 -07:00
Ben Gotow 3135e2b339 fix(err): InspectorFrontendAPI => DevToolsAPI 2016-05-13 16:25:23 -07:00
Juan Tejada 99f8a81e96 fix(mail-merge): Pass session to injected subject 2016-05-13 16:01:12 -07:00
Ben Gotow 17ed847240 fix(401/403): Unify error bars, query /account, improve reconnect flow
Summary: See https://paper.dropbox.com/doc/Sync-disabling-for-N1-URZmjVpSSxWFvjC62TiFI

Test Plan: Tests incoming

Reviewers: juan, evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D2959
2016-05-13 14:16:54 -07:00
Ben Gotow 4145a60130 fix(category-picker): Don't wrap folder names early 2016-05-12 16:14:30 -07:00
Juan Tejada eb10d46992 fix(build): Fix linter errors 2016-05-12 14:28:11 -07:00
Ben Gotow 26d4361bfb bump(electron): Fix remaining deprecated requires, move to 1.0.1 2016-05-12 13:59:23 -07:00
Jackie Luo 589f77d7e1 refactor(focus): Move code for focusing threads to FocusedContentStore 2016-05-12 13:29:41 -07:00
Juan Tejada 51d51fb47e feat(mail-merge): Add ability to drop tokens in subject
Summary:
Adds ability to drop tokens in subject via a custom rendered subject field which
renders a contenteditable instead of an input.
Decided to completely replace the subject field via injected components for a
few resons:
  - That's the way we are currently extending the functionality of the participant fields, so it keeps the plugin code consistent (at the cost of potentially more code)
  - Completely replacing the subject for a contenteditable means we hace to do extra work to clean up the html before sending.
  - Reusing our Contenteditable.cjsx class for the subject is overkill, but using a vanilla contenteditable meant duplicating a bunch of the code in that class if we want to add

Test Plan: Unit tests

Reviewers: bengotow, evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D2949
2016-05-12 10:47:41 -07:00
Jackie Luo ce0bf93cdc 🎨(dark): Update theme colors 2016-05-12 01:05:26 -07:00
Ben Gotow 57ac866021 fix(pli): Design PLI indicators #2148 2016-05-11 17:09:23 -07:00
Juan Tejada ab55bc68ea fix(build): Fix lint issues and specs 2016-05-11 15:33:52 -07:00
Juan Tejada eb79ce9d44 specs(table): Add specs for table components
Summary:
- Add some docs to Table components
- Updates Table components to use a TableDataSource instead of accessing arrays, cleans up code a bit
- Add enzyme lib to have a cleaner and simpler api to write tests for React Components
- Updates decorators to extend from the BaseComponent instead of vanilla Component, this way instance methods are still available on composed components

Test Plan: - Unit tests

Reviewers: evan, bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D2941
2016-05-11 14:36:59 -07:00
Juan Tejada 3e21a89a88 fixt(print): Update print header logo 2016-05-11 11:33:12 -07:00
Juan Tejada c564b2c0f7 fix(delta-streaming): Fix stale cursor key in config file 2016-05-11 10:34:29 -07:00
Juan Tejada 48abc9dd9e Revert "fix(print): Update logo"
This reverts commit bff232e892.
2016-05-09 23:43:36 -07:00
Juan Tejada bff232e892 fix(print): Update logo 2016-05-09 20:13:32 -07:00
Ben Gotow c4b5b4b779 fix(prefs): ? shortcut for "Show Keybindings" #1144 2016-05-09 17:28:52 -07:00
Ben Gotow c441913f0e fix(drafts): Support additional deletion shortcuts #939 2016-05-09 17:28:52 -07:00
Ben Gotow da07fe21ab feat(not-spam): Unmark items as junk / spam #2112 2016-05-09 17:28:52 -07:00
Ben Gotow 35d5f29b82 fix(thread-list): Add missing displayName, ES6 2016-05-09 13:18:07 -07:00
Ben Gotow a5e3bf86c2 fix(notifs): Don't play notification sounds over and over #1910, #2179 2016-05-09 13:09:10 -07:00
Evan Morikawa 6910520dc5 fix(lint): fix minor linter issue 2016-05-09 13:42:18 -04:00
Alexander Adkins 92a54f8013 Added Less Is More (#2168)
* Added Less Is More Theme to internal-packages and README.md

* fixed Less Is More title in README.md

* removed units for values of zero

* updated readme, package title fix, theme topbar fix, message list adjustments
2016-05-09 09:46:50 -07:00
Robert Stanfield be48fc4305 The horizontal scrollbar was not showing up when viewing an email (#2028) 2016-05-06 16:44:30 -07:00
Evan Morikawa 1498bcfac6 fix(lint): final linter fixes
fix(lint): final set of linter fixes
2016-05-06 16:32:34 -07:00
Ben Gotow 41ae914b9d fix(lint): Various linter fixes 2016-05-06 16:23:48 -07:00
Ben Gotow 42ef0e98a4 fix(lint): Various linter issues 2016-05-06 16:06:16 -07:00
Evan Morikawa 2bcfedf7a4 fix(lint): fix various linter issues 2016-05-06 14:36:11 -07:00
Evan Morikawa 4fed2b452e fix(lint): various linter fixes 2016-05-06 14:11:05 -07:00
Evan Morikawa bb861d494f fix(lint): fixing various linter errors.
746 left
2016-05-06 13:42:09 -07:00
Evan Morikawa 805221dfa3 fix(linter): object-shorthand, quote-props
object-shorthand got turned off. We think it's fine to say {foo: foo} if
you want

quote-props is error consistent as neeeded.

Use custom file-by-file rules for global-require
2016-05-06 12:41:52 -07:00
Evan Morikawa 9355a2635d feat(babel6): fix es6 importing from coffee 2016-05-06 12:00:45 -07:00
Evan Morikawa b812a93850 feat(babel6): Fix emoji data 2016-05-06 11:55:48 -07:00
Evan Morikawa 837627aa39 feat(babel6): 1,774 linter errors 2016-05-06 11:55:46 -07:00
Evan Morikawa f72e28a22f feat(babel6): 2,743 lint errors 2016-05-06 11:55:41 -07:00
Evan Morikawa 1a0dfeaf78 feat(babel6): Yay all the tests pass 2016-05-06 11:55:36 -07:00
Evan Morikawa cc1f6e46dd feat(babel6): Don't use _.clone on Model objects 2016-05-06 11:55:34 -07:00
Evan Morikawa f2d153c87b feat(babel6): Fix autlinker spec 2016-05-06 11:55:32 -07:00
Evan Morikawa e717a44581 feat(babel6): Fix spread operator 2016-05-06 11:55:29 -07:00
Evan Morikawa 8f4e30329c feat(babel6): Convert message.coffee to message.es6 2016-05-06 11:55:27 -07:00
Evan Morikawa 50f301e845 feat(babel6): fix es6 describe function syntax 2016-05-06 11:55:20 -07:00
Evan Morikawa 47c064617d feat(babel6): Fix destructuring default from exports and update linter 2016-05-06 11:55:14 -07:00
Evan Morikawa 87b1d5075b feat(babel6): Fix syntax errors and add regenerator runtime 2016-05-06 11:55:08 -07:00
Evan Morikawa fb32bdfa67 feat(babel6): Fix linter problems in new es6 files 2016-05-06 11:55:06 -07:00
Evan Morikawa 9230078ffe feat(babel6): Rename to js to es6 2016-05-06 11:55:02 -07:00
Evan Morikawa 7f50074c0d feat(babel6): Convert to use new es6 require syntax 2016-05-06 11:54:55 -07:00
Evan Morikawa e2f9104766 feat(babel6): Initial babel conversion 2016-05-06 11:54:38 -07:00
Ben Gotow 8d9d979abc feat(keymaps): Edit your keymaps from preferences 2016-05-05 17:05:51 -07:00
Ben Gotow f0be73cdc4 fix(focus): Always set selection range into editor on focus 2016-05-05 11:53:58 -07:00
Jackie Luo bd063fd9c6 🎨(darkside): Hide search bar in list mode when items are selected 2016-05-05 10:35:37 -07:00
Ben Gotow 5d9cf73c3c es6(*): AutoUpdateManager, ProtocolHandler, more. 2016-05-04 19:34:41 -07:00
Ben Gotow 5150dccaf1 fix(file-drop): Wait for attachments before popping composer 2016-05-04 19:09:28 -07:00
Juan Tejada 2c986f2cd0 fix(composer): Properly setup editing action listeners on update
- This prevented emoji selection via the popover from working on a new
window because the plugin is loaded after the contenteditable sets up
the action listeners, so we need to re set them on update
2016-05-04 16:25:42 -07:00
Juan Tejada 6e0e70ddf7 fix(composer-editor): Remove dead code 2016-05-04 15:02:38 -07:00
Ben Gotow 0448dd1070 rm(fullcontact): Deprecated in favor of new contact sidebar 2016-05-04 14:41:13 -07:00
Ben Gotow aee07a80b8 rm(*): deprecated/unused Atom code, user stylesheet support 2016-05-04 14:27:46 -07:00
Ben Gotow 0992acf4c8 fix(read-receipts): Always remove own read receipt images 2016-05-04 13:44:35 -07:00
Juan Tejada 1a78a758f4 refactor(deltas): Update sync-worker to use NylasAPI.longConnection
Summary:
- Remove nylas-long-connection.coffee duplicate code from sync worker package
  and replace with delta-streaming-connection which uses NylasAPI.longConnection
- Replacement for XHR will come in another diff -- still need to clean up and
  fix some edge cases

Test Plan:
- TODO! Will add test coverage for NylasLongConnection and
  DeltaStreamingConnection

Reviewers: evan, bengotow

Reviewed By: evan, bengotow

Differential Revision: https://phab.nylas.com/D2875
2016-05-04 13:03:47 -07:00
Ben Gotow 2bd2965acf fix(keymaps): "Delete" => "Del" to fix keycode 46 2016-05-04 09:29:42 -07:00
Ben Gotow 85c1b030b7 Revert "feat(mailto): Allow N1 to be default client on windows"
This reverts commit fad7c1ae86.
2016-05-03 19:04:04 -07:00
Ben Gotow fad7c1ae86 feat(mailto): Allow N1 to be default client on windows 2016-05-03 14:47:21 -07:00
Ben Gotow dc30187d30 fix(db): When replacing obj in a set, keep old body if new body not provided 2016-05-03 14:01:06 -07:00
Evan Morikawa c89413e98d fix(window): fix error when adding account and serializing bad API data 2016-05-03 11:30:41 -07:00
Ben Gotow c1a296acf9 fix(sheets): Always change sheet when changing perspective (#2094) 2016-05-02 19:14:12 -07:00
Ben Gotow 74232d5b7e fix(tracking): Use colors for link/read receipts, fix parsing 2016-05-02 15:59:17 -07:00
Ben Gotow 4c537cbf8e fix(emoji): Replace message emoji in DOM, not in html string 2016-05-02 12:33:08 -07:00
Ben Gotow e9a898c869 fix(undo): Don't create separate commands, since they bubble separately 2016-04-29 17:10:17 -07:00
Evan Morikawa 444101a74b fix(specs): fix composer-header specs 2016-04-29 16:54:37 -07:00
Ben Gotow 871383d0b1 fix(lint): Errors in ActionBarPlugins 2016-04-29 16:19:52 -07:00
Evan Morikawa 909226fcf4 feat(composer): better composer plugin loading 2016-04-29 15:58:17 -07:00
Evan Morikawa 99a8143a9d fix(composer): fix flashing and focus losing in the composer 2016-04-29 15:58:17 -07:00
Ben Gotow 55bd04b3a2 feat(mail-merge): Import CSV button 2016-04-29 13:55:11 -07:00
Ben Gotow 105e33c9c4 fix(mail-merge): Fix drag and drop for files vs. chips 2016-04-29 11:57:43 -07:00
Evan Morikawa db899491ea fix(onboarding): pass along accountId too 2016-04-29 10:20:59 -07:00
Karim Hamidou cba6ccc220 [N1] Changes to allow running edgehill-server locally
Summary: This is mostly config changes.

Test Plan: Tested the Google OAuth flow.

Reviewers: bengotow, drew

Reviewed By: bengotow, drew

Differential Revision: https://phab.nylas.com/D2907
2016-04-29 10:18:51 -07:00
Ben Gotow b0d332c2c1 fix(read-receipts): Fix another issue caused by ES6 subclassing Coffeescript 2016-04-28 17:20:39 -07:00
Ben Gotow 05be74ec04 fix(read-receipts): Remove tracking pixels when composing drafts 2016-04-28 17:08:54 -07:00
Evan Morikawa 7907b8fdd1 fix(onboarding): encode welcome page info 2016-04-28 17:06:47 -07:00
Ben Gotow 040c3bc45a fix(build): linter errors 2016-04-28 16:40:48 -07:00
Ben Gotow c2cf89026e fix(thread-list): Don't rely on zip since it can become off-by-one forever 2016-04-28 15:53:51 -07:00
Evan Morikawa 78c453a616 feat(onboardin): fix win closing & nav to welcome page 2016-04-28 15:29:13 -07:00
Evan Morikawa b226dfb5b1 perf(composer): tweak tooltip animation timing & composer loading 2016-04-28 13:42:30 -07:00
Evan Morikawa f45c497810 fix(sidebar): fix account name styles 2016-04-28 11:45:44 -07:00
Juan Tejada 8ff5f4f8b5 fix(cursor): Remove stale cursor from config.cson when cursor error
- #2049
2016-04-28 10:16:40 -07:00
Juan Tejada ea9538f444 feat(mail-merge): Add CSV imports, styling, and several fixes
Summary: Adds CSV imports, proper styles to mail merge plugin and fixes a handful of bugs

Test Plan: TODO

Reviewers: bengotow, evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D2925
2016-04-27 18:22:32 -07:00
Ben Gotow 5bda8993f0 fix(thread-list): Remove unnecessary extra trigger 2016-04-27 15:20:25 -07:00
Ben Gotow a270234f6d fix(keymaps): Restore missing bindings, handle single keys inside of email frames 2016-04-27 15:20:06 -07:00
John McNair dccf4f3ad3 Parse Office 365 names (#2016)
Office 365 likes to format email addresses as follows:
Last Name, First Name (Some Description) <email@address.org>

This causes Contact.firstName() (and hence sometimes displayName()) to return
"Last Name," which looks a bit odd in the message/thread views.

The intent of the commit is to correctly parse these names so that (using the
above example):
- firstName = "First Name"
- lastName = "Last Name (Some Description)"
- fullName = "First Name Last Name (Some Description)"

These behavioral changes only impact names containing a ','.

I don't know that this really provides exhaustive coverage of Office 365, and
keeping the description as part of the last name is not completely guilt free,
but it's not any worse than the previous state of affairs which also has
the description in the same field but combined instead with (misplaced)
first name data.
2016-04-27 10:26:23 -07:00
Selwyn cbded86bd4 Linux launch on start (#2019)
* feat(workspace-section): Add Linux-only warning to launch on start

* feat(system-start-service): Add Linux launch on system start option
2016-04-27 09:22:23 -07:00
Ben Gotow 8944e10ae9 fix(autolinker): Don't match emails that are also URLs #2071 2016-04-26 19:03:43 -07:00
Ben Gotow c5a77fa854 fix(autolinker): Use getAttribute('href') because href is magic 2016-04-26 17:01:15 -07:00
Ben Gotow aa42040813 fix(autolinker): Always override title attribute #2056 2016-04-26 16:49:33 -07:00
Ben Gotow e4a0c94482 fix(sidebar): Fix overflow of account name 2016-04-26 15:53:51 -07:00
Ben Gotow 1fcef30b6b fix(attachments): Make presentError display underlying error, file optional. Sentry 27089 2016-04-26 14:03:08 -07:00
Ben Gotow 2bae0d5885 fix(composer): Wait frames not msec on focus out #2033 2016-04-26 13:14:06 -07:00
Evan Morikawa 3ac94a4402 fix(win): draft popout windows always send draftJSON 2016-04-26 13:02:05 -07:00
Evan Morikawa 60d2c24693 feat(package): fix build-resources-task and move submodule 2016-04-25 16:01:56 -07:00
Evan Morikawa 2472e0556b feat(package): require 'engines': {'nylas': '*'} in package.json 2016-04-25 15:06:37 -07:00
Ben Gotow 43b65ca36c cson(cleanup): Remove imports, only used for config.cson now 2016-04-24 20:33:34 -05:00
Jackie Luo cbda623fec 🎨(plugins): Fix line breaks 2016-04-24 18:32:53 -07:00
Ben Gotow 16dd26c29e fix(build): CSON => JSON no longer necessary for /keymaps, /menus 2016-04-24 20:27:29 -05:00
Ben Gotow ddba5415ad mv(packages): move plugins that are incompatible with open source sync engine 2016-04-24 14:53:12 -05:00
Ben Gotow a48ddd51f8 refactor(menus): Major prune of keymaps/commands, real conditional menus
Summary:
Keymaps & menus CSON => JSON, remove AtomKeymaps, CommandRegistry use of CSS selectors, use Mousetrap instead

Important Notes:

- The `application:` prefix is reserved for commands which are handled in the application process. Don't use it for other things. You will not receive the events in the window.

- Maintaining dynamic menus seems to come with quite an overhead, because Electron updates the entire menu every time. In the future, we'll need https://github.com/electron/electron/issues/528 to really make things nice. I will be tracking this upstream.

- The format for keyboard shortcuts has changed. `cmd-X` is now `command+shift+x`

Test Plan: Run tests

Reviewers: juan, evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D2917
2016-04-24 12:16:25 -05:00
Juan Tejada 2dccde2e58 feat(mail-merge): Add mail merge plugin
Summary:
Adds Mail Merge Plugin
- Adds new table components to component kit
- Adds new extension points to allow dragging and dropping into composer contenteditable and participant fields and customizing participant fields
- Adds new decorators and other misc updates
- #1608

Test Plan: TODO

Reviewers: bengotow, evan

Reviewed By: bengotow, evan

Differential Revision: https://phab.nylas.com/D2895
2016-04-22 18:29:07 -07:00
Evan Morikawa 1920d5db8a fix(win): speed up composer launching 2016-04-22 17:41:22 -07:00
Jackie Luo 777ef33622 fix(draft-list): Revert regression for sheet selection 2016-04-22 17:30:14 -07:00
Jackie Luo 6a1bed23c1 feat(activity-list): View message opens and link clicks
Summary:
Adds an activity list view that shows message opens and link clicks in a
chronological feed.

TODO: Add badge for unread notifications and different styling for read/unread
notifications. Click item to jump to corresponding thread.

Test Plan: TODO.

Reviewers: evan, bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D2915
2016-04-22 17:27:30 -07:00
Evan Morikawa 78112563a6 feat(win): faster popout windows
Summary:
This diff is designed to dramatically speed up new window load time for
all window types and reduce memory consumption of our hot windows.

Before this diff, windows loaded in ~3 seconds. They now boot in a couple
hundred milliseconds without requiring to keep hot windows around for
each and every type of popout window we want to load quickly.

One of the largest bottlenecks was the `require`ing and initializing of
everything in `NylasExports`.

I changed `NylasExports` to be entirely lazily-loaded. Drafts and tasks
now register their constructors with a `StoreRegistry` and the
`TaskRegistry`. This lets us explicitly choose a time to activate these
stores in the window initalization instead of whenever nylas-exports
happens to be required first.

Before, NylasExports was required first when components were first
rendering. This made initial render extremely slow and made the proposed
time picker popout slow.

By moving require into the very initial window boot, we can create a new
scheme of hot windows that are "half loaded". All of the expensive
require-ing and store initialization is done. All we need to do is
activate the packages for just the one window.

This means that the hot window scheme needs to fundamentally change from
have fully pre-loaded windows, to having half-loaded empty hot windows
that can get their window props overridden again.

This led to a major refactor of the WindowManager to support this new
window scheme.

Along the way the API of WindowManager was significantly simplifed.
Instead of a bunch of special-cased windows, there are now consistent
interfaces to get and `ensure` windows are created and displayed. This
DRYed up a lot of repeated logic around showing or creating core windows.

This also allowed the consolidation of the core window configurations into
one place for much easier reasoning about what's getting booted up.

When a hot window goes "live" and gets populated, we simply change the
`windowType`. This now re-triggers the loading of all of the packages for
the window. All of the loading time is now just for the packages that
window requires since core Nylas is there thanks to the hot window
mechanism.

Unfortunately loading all of the packages for the composer was still
unnaceptably slow. The major issue was that all of the composer plugins
were taking a long time to process and initialize. The solution was to
have the main composer load first, then trigger another window load
settings change to change the `windowType` that loads in all of the
plugins.

Another major bottleneck was the `RetinaImg` name lookup on disk. This
requires traversing the entire static folder synchronously on boot. This
is now done once when the main window loads and saved in a cache in the
browser process. Any secondary windows simply ask the backend for this
cache and save the filesystem access time.

The Paper Doc below is the current set of manual tests I'm doing to make
sure no window interactions (there are a lot of them!) regressed.

Test Plan: https://paper.dropbox.com/doc/Window-Refactor-UYsgvjgdXgVlTw8nXTr9h

Reviewers: juan, bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D2916
2016-04-22 13:30:42 -07:00
Jackie Luo 79b5e34211 fix(draft-list): Select proper sheet when launching in drafts perspective 2016-04-21 16:00:06 -07:00
Evan Morikawa 8fb062f765 fix(spec): fix to run in utc travis 2016-04-20 14:39:15 -07:00
Ben Gotow bb71529322 fix(attachments): Don't show the paperclip for inline attachments < 3k (signatures, etc.) 2016-04-20 10:44:32 -07:00
Kevin Jose Martin 78ea5c0c64 Doing write on a GET is invalid. (#2004)
* Doing write on a GET is invalid

* Doing write on a GET is invalid
2016-04-20 10:07:12 -07:00
Ben Gotow 658e1a5d0d perf(db): Use partial indexes added in sqlite 3.8 2016-04-19 17:42:02 -07:00
Jackie Luo 8803b01d2f lint(github-card): Change duplicated variable name 2016-04-19 17:34:19 -07:00
Jackie Luo 1bfc8e74b1 feat(preferences): Add theme picker button to Appearances 2016-04-19 17:14:25 -07:00
Tim Hitchins 24fb3ee952 Added link to all plugins section (#2002)
* Added link to all plugins section

* Added correct link - to the nylas repro ;-)
2016-04-19 16:14:06 -07:00
Max Stoiber fe453b02da Fix Github Sidebar Plugin (#2003)
Hopefully fixes #1991

I don't have N1 setup locally, so this is a blind shot–would appreciate somebody who has it set up to pull this and verify this fixes the issue, but as far as I can tell it should.

The gist is:

> Looking at the code, what you do is use the `search/users` endpoint to find users by email and taking the repos from there. You then load the repositories of the username, but we can't sort those by most-starred: "sort string Can be one of `created`, `updated`, `pushed`, `full_name`. Default: `full_name`" *([src](https://developer.github.com/v3/repos/#list-user-repositories))*
> What we could instead do is use the search API, which **allows us to search for repositories by a specific user and sort by most starred**. This is a tiny bit hacky, but works perfectly fine. E.g. this is the URL for my most starred repos: `https://api.github.com/search/repositories?q=user:mxstbr&sort=stars&order=desc`
2016-04-19 16:13:30 -07:00
Ben Gotow 33225f56b0 rename(drafts) DraftStoreProxy => DraftEditingSession 2016-04-19 16:08:58 -07:00
Ben Gotow 7452705c31 refactor(composer): Make session, draft available everywhere
Summary:
Up until now, we've been requiring that every plugin control in the composer take the draftClientId, retreive the session, listen to it, build state from the draft, etc. This is a huge pain and is hard to explain to newcomers becaus it frankly makes no sense.

In 0.3.45 we made it so that the ComposerView always has a non-null draft and session. (It isn't rendered until they're available). In this diff, I just pass those through to all the plugins and remove all the session retrieval cruft.

Almost none of the buttons have state of their own, which I think is appropriate.

They do render on every keystroke, but they were already running code (to recompute their state) on each keystroke and profiling suggests this has no impact.

Prepare for immutable

In preparation for Immutable models, make the draft store proxy returns a !== draft if any changes have been made. This means you can safely know that a draft has changed if `props.draft !== nextProps.draft`

Test Plan: Run tests

Reviewers: juan, evan

Reviewed By: juan, evan

Differential Revision: https://phab.nylas.com/D2902
2016-04-19 16:05:15 -07:00
Evan Morikawa b29d5ac75b tests(calendar): adding calendar and scheduler tests
Summary: Adding tests

Test Plan: Tests

Reviewers: juan, bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D2892
2016-04-19 11:54:15 -07:00
Ben Gotow 36ab9d593b feat(unread/spam): New items in the sidebar for unread and spam
Summary:
Adds a new unified "Spam" folder and a unified "Unread" view,
which shows all the messages in your inbox which are unread.

Test Plan: Run tests

Reviewers: evan, juan

Reviewed By: juan

Differential Revision: https://phab.nylas.com/D2901
2016-04-19 11:32:33 -07:00
Dakota Nelson ccaa03e944 Expose ParticipantsTextField through component kit (#1994) 2016-04-18 16:39:08 -07:00
Ben Gotow 0de50b476c fix(default-alias): Show primary email instead of "None", clarify only for new messages currently 2016-04-15 19:05:54 -04:00
Ben Gotow e70fdd4dcd fix(default-client): Set initial state to fix React warning 2016-04-15 14:30:13 -04:00
Ben Gotow cd4b1c7016 fix(related-threads): Show snippet in addition to subject #1683 2016-04-14 17:33:43 -04:00
Ben Gotow 59b0c1c556 fix(view-on-github): Add readme and fix bug 2016-04-14 17:03:57 -04:00
Ben Gotow b521cf7f03 fix(star): Change action from Star All => Star #1927 2016-04-14 16:34:46 -04:00
Ben Gotow c96a5a4d22 💄(scheduler): Would you like => I'd like 2016-04-13 17:48:27 -07:00
Drew Regitsky 8ea78417a8 fix(onboarding): Add missing return statement when changing endpoints 2016-04-13 17:41:31 -07:00
Drew Regitsky 19a4281bb4 fix(onboarding): Change error notification for endpoint changes 2016-04-13 16:13:25 -07:00
Ben Gotow 1b6525910c fix(search-bar): Apparently we were not providing keys 2016-04-13 16:08:24 -07:00
Ben Gotow f85f447141 fix(require): Move more requires to new electron format 2016-04-13 15:35:01 -07:00
Ben Gotow b64719d09f fix(search): Cannot remove items from search (Sentry 30318) 2016-04-13 14:22:43 -07:00
Ben Gotow d1211ab7de bump(electron): 0.36.7 => 0.37.5 2016-04-12 18:42:57 -07:00
Matt Bilker 5fd8faa82c fix(imports): switch to Electron's require('electron') (#1907)
* fix(imports): switch to Electron's require('electron')

Electron in 0.37.5 phases out the usage of `require('built-in-module')`
in favor of `require('electron').builtInModule`. This commit corrects usage in
some cases that cause N1 to not start under Electron 0.37.5.

* fix(specs): use new Electron remote import
2016-04-12 18:09:13 -07:00
Jackie Luo cf926b0346 fix(composer-emoji): Fix calculation for category positioning 2016-04-12 14:51:56 -07:00
Ben Gotow d5fb58a029 fix(emoji): Improve variable names / diff feedback 2016-04-12 14:46:03 -07:00
Ben Gotow 370edc40e9 fix(emoji): Re-use img tag to avoid running out of file descriptors
Summary:
On my machine the new emoji picker was causing "too many open file descriptor"
errors. I think that this was because it was creating 1300 image tags in 50msec.

I refactored this code so that it uses a single image tag and only loads one image
at a time. This could make it slower on some people's machines, but eliminates the
possibility of it breaking the app!

Test Plan: Run tests

Reviewers: jackie

Differential Revision: https://phab.nylas.com/D2878
2016-04-12 14:29:59 -07:00
Jackie Luo 2a431fcec7 fix(composer-emoji): Switch to characters to PNGs (#1898)
* Add PNGs and JSON file

* Add Apple and Twitter emoji

* Fix linter issues and tests

* Get correct path from EmojiStore

* Add emoji regex and update extensions

* Remove the scary regex
2016-04-12 10:27:24 -07:00
Evan Morikawa c5f4c7305d feat(scheduler): add an event preview when sending a meeting request
Summary: add event preview

Test Plan: manual

Reviewers: bengotow, juan

Differential Revision: https://phab.nylas.com/D2874
2016-04-11 22:45:36 -04:00
Ben Gotow 793b9efae0 fix(scheduler): Don't cast durations to integers, fix 1.5, 2.5 hour blocks 2016-04-11 18:52:49 -07:00
Ben Gotow 24d9157ee5 fix(scheduler): End should work even if the mouse isn't over a time 2016-04-11 18:42:17 -07:00
Ben Gotow c3fad8cca7 fix(scheduler): Make popover width even so it's not blurry 2016-04-11 18:33:53 -07:00
Ben Gotow 046c8b3122 fix(sync): Handle "Invalid cursor" scenario by 💣🔥 away the cache 2016-04-11 17:34:52 -07:00