Commit graph

1926 commits

Author SHA1 Message Date
Juan Tejada 52f928c991 fix(sidebar): Properly update sidebarAcctIds when all accts removed
- Prevents app from crashing when all accounts are removed
2016-06-06 15:08:10 -07:00
Ben Gotow 36ee588d12 fix(merge): Settings: add 24-hour clock support 2016-06-06 14:33:51 -07:00
Friedrich von Never 32efb09825 Settings: add 24-hour clock support 2016-06-06 14:31:57 -07:00
Ben Gotow f7492b8250 fix(css): Fix CSS regression, remove unused assets 2016-06-03 17:01:48 -07:00
Ben Gotow 74cb7ac94f fix(onboarding): Message for 400+ server error codes 2016-06-03 16:38:59 -07:00
Ben Gotow 668d32705f fix(onboarding): Only show the welcome page if not already seen 2016-06-03 16:09:25 -07:00
Juan Tejada f484117b00 fix(sidebar): Correctly update sidebar when focusing perspective
- When focusing a perspective:
  - If sidebar is unified inbox then don't the sidebar layout
  - If sidebar is for a single account, then update to the appropriate
  single account
- Renames some variables
2016-06-03 15:10:08 -07:00
Ben Gotow c0c543c9c8 fix(identity): deprecate updaterId, provide safe access to identity.id 2016-06-02 18:56:09 -07:00
Ben Gotow 508c92f599 fix(sync): Always restart where left off after initial sync interrupted 2016-06-02 18:56:09 -07:00
Juan Tejada 5c8b68b4e1 fix(build): Don't lint files inside node_modules, fix lint error 2016-06-02 14:45:51 -07:00
Evan Morikawa 680b219662 fix(analyitcs): make sure to flush events before they close 2016-06-02 16:24:32 +01:00
Evan Morikawa 077472af55 fix(onboarding): use proper env 2016-06-02 15:00:02 +01:00
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
Evan Morikawa d24f653e26 fix(scheduler): minor style tweaks to scheduler popover 2016-04-11 19:33:27 -04:00
Evan Morikawa ceee33eb10 fix(scheduler): fix jumping calendar and add popover
fix(scheduler): fix jumping calendar and add popover

Summary: feat(scheduler): improved calendar picker

Test Plan: manual

Reviewers: bengotow, juan

Differential Revision: https://phab.nylas.com/D2873
2016-04-11 18:23:06 -04:00
Ben Gotow 586d099c23 fix(schedule): Move z-indexes to prevent dropdown layering issue 2016-04-11 14:58:58 -07:00
Ben Gotow db90db3131 fix(schedule): Use draft session to udpate metadata, always save in syncback 2016-04-11 14:32:54 -07:00
Ben Gotow 5220b471e3 fix(db): Counts no longer require Thread table join 2016-04-11 13:51:31 -07:00
Ben Gotow c00190c492 fix(auth): Fix missing var. This is why we should go ES6! 2016-04-11 10:48:16 -07:00
Ben Gotow b4b67c65c9 fix(initial-sync): Fix sync sidebar showing all the time 2016-04-11 00:43:06 -07:00
Juan Tejada 3716706833 feat(thread-search): Add spinner to indicate search in progress
Summary:
- This diff also restructures the search package in a few ways:
  - Rename package to `thread-search` instead of `search-bar`
  - Move SearchQuerySubscription and SearchMailboxPerspective inside
  package. This allows SearchQuerySubscription to have access to
  SearchActions in a clean way and keeps all of the search related code
  in 1 package
  - Remove SearchMailboxPerspetcive from mailbox-perspective.coffee
- Adds temporary spinner while we get a new design for it

Test Plan: - TODO

Reviewers: evan, bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D2868
2016-04-10 16:20:26 -07:00
Evan Morikawa e2e9a72233 fix(scheduler): use proper start and end time formats for when block 2016-04-10 11:44:24 -04:00
Evan Morikawa 42d7aa47b4 fix(scheduler): properly formatting when objects for post 2016-04-09 21:47:52 -04:00
Evan Morikawa 8960009643 fix(scheduler): properly set proposals 2016-04-09 21:25:01 -04:00
Evan Morikawa 8f7b99ee4f refactor(scheduler): move all event data into metadata
Summary: Moved events into metadata. Removed a lot of code

Test Plan: todo

Reviewers: juan, bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D2866
2016-04-09 21:19:01 -04:00
Ben Gotow d884eccb36 fix(specs): * 2016-04-08 16:03:21 -07:00
Juan Tejada 172ac4fc0a update(search): Add search usage reporting + other fixes
Summary:
- Converts SearchQuerySubscription to ES6 to fix method overriding for
  `removeCallback`
- Reports different usage metrics for search
- Removes unecessary data source listener iniside ThreadListStore:
  - This listener focused the first thread on the list, which is
  actually unwanted (#1461)
  - It prevented QuerySubscriptions from being disposed promptly because
  of the remaining listener. They qould only be disposed until the
  subscription triggered once, which is not actually desired behavior
  (e.g. for SearchQuerySubscription)

Test Plan: - Manual

Reviewers: evan, bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D2864
2016-04-08 14:11:32 -07:00
Ben Gotow 227bc81736 fix(sync-errors): Improve display of sync errors and offline status
- Make the retry interval go 2 sec, 3.4s, 6 sec...
- Only show the connection status bar if the interval is > 5 seconds, in case the error was temporary.
- Do not show sync errors in the sidebar. The only available action is "Try Again", and we try again on our own. The error is frustrating and the user can't do anything about it anyway.
2016-04-08 13:52:26 -07:00
Drew Regitsky 3918f1a181 feat(auth): Provide reauth param to handle changed server endpoints
Summary:
Notify the backend when auth is a reauth of an existing account by
providing the `accountId`. This lets the backend differentiate between
a new auth (where a new account will be created if the server endpoints
don't match) and a re-auth (where the auth will fail on server endpoint
mismatch, prompting the user).

Test Plan: manual

Reviewers: juan, evan, bengotow

Reviewed By: bengotow

Subscribers: mg, spang, kav-ya

Differential Revision: https://phab.nylas.com/D2833
2016-04-08 12:00:03 -07:00
Ben Gotow 0b4527bb03 fix(autoscale): Apply vw when width and height are not present 2016-04-07 18:02:04 -07:00
Evan Morikawa 6a70584ffa feat(scheduler): better time picker
fix(scheduler): time picker fixed
2016-04-07 15:14:33 -07:00
Jackie Luo c78401c566 🎨(preferences): Change spacing and button sizes 2016-04-07 14:32:51 -07:00
Ben Gotow b6f539ac7b 💄(prefs): Shrink top tabs better, add min-widths 2016-04-07 14:14:20 -07:00
Jackie Luo 5fc110c1dc 🎨(preferences): Adjust textbox styles for signatures and templates 2016-04-07 14:12:35 -07:00
Evan Morikawa be7a196eeb fix(tracking): uid uses draftClientId 2016-04-07 12:18:37 -07:00
Juan Tejada cb46f8a9d8 fix(contact-sidebar): Don't render <select> when no contacts available 2016-04-07 09:57:53 -07:00
Juan Tejada 317f9be93d feat(thread-search): Make thread search indexing smarter
Summary:
- When accounts change, make sure sync has completed, and only add or
remove threads from the index based on accounts that were added or
removed instead of rebuilding the entire index from scratch

- When thread is updated, make sure to only update the index for threads
that belong to accounts that are not currently in the sync process

- Add more logging and docs

Test Plan: TODO

Reviewers: evan, bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D2852
2016-04-07 09:57:29 -07:00
Ben Gotow b16b465fd9 lint(*): Fix linter errors from QA fixes 2016-04-06 16:15:46 -07:00
Ben Gotow 0bd7480338 fix(autolinker): Additional test case from #1863 2016-04-06 14:29:28 -07:00
Ben Gotow a05daeb0f0 fix(autolinker): Add test cases, .ly, url hash chars 2016-04-06 14:17:10 -07:00
Evan Morikawa d4de652dab fix(scheduler): can scheduler on 30 min intervals 2016-04-06 14:09:51 -07:00
Evan Morikawa 544eacd87e fix(scheduler): removes proposals from metadata when removing event
Also add <tbody> tags
2016-04-06 13:59:24 -07:00
Evan Morikawa f1a8b6929f fix(scheduler): can remove proposed times 2016-04-06 13:59:24 -07:00
Evan Morikawa dc5210275e fix(scheduler): fix top banner 2016-04-06 13:59:24 -07:00
Ben Gotow 3cd94e8957 fix(cc/bcc): Make targets bigger, wait longer before declaring focus left 2016-04-06 13:54:39 -07:00
Jackie Luo 748e6ed55e 🎨(preferences): Update styling 2016-04-06 13:08:44 -07:00
Ben Gotow 965884fa95 fix(*): Minor CSS fixes, open tracking fix when only message is draft 2016-04-06 12:35:30 -07:00
Ben Gotow 5989fa7e52 fix(error): Show actual API domain in connection error bar 2016-04-06 12:35:30 -07:00
Jackie Luo 8479fdd0ce fix(composer-emoji): Fix tabs to scroll correctly 2016-04-06 12:06:27 -07:00
Evan Morikawa f97aa855a4 fix(schedule): extracted to own SyncbackDraftEventsTask 2016-04-06 11:50:21 -07:00
Ben Gotow 7210e2f42d fix(mail-rules): Only process inbox, never skip threads
Summary:
- Disable processing button while already processing
- Only process mail in the inbox in bulk reprocess task
- Advance through mail using "after X" rather than "offset X", avoiding the issue where mail can be deleted as you're advancing.

Test Plan: Run existing tests

Reviewers: evan, juan

Reviewed By: juan

Differential Revision: https://phab.nylas.com/D2847
2016-04-05 19:16:58 -07:00
Evan Morikawa bb318bf69c feat(scheduler): add new date & time picker
Summary: Adds a date and time picker to the new event creator

Test Plan: todo

Reviewers: bengotow, juan

Reviewed By: bengotow, juan

Differential Revision: https://phab.nylas.com/D2842
2016-04-05 18:42:19 -07:00
Juan Tejada cf6f577a68 fix(scheduler): Fix moment-timezone require 2016-04-05 15:19:53 -07:00
Evan Morikawa 3d80e03421 fix(scheduler): import from moment-timezone 2016-04-05 14:57:51 -07:00
Juan Tejada 4c250640fe fix(react): Fix several warnings in missing imports 2016-04-05 14:53:37 -07:00
Ben Gotow d1b1c5bea2 fix(quoted-text): Correctly update container height 2016-04-05 14:27:54 -07:00
Ben Gotow 34201ff644 fix(collapsed-participants): Resize in correct scenarios 2016-04-05 14:16:24 -07:00
Jackie Luo 4f11201ff7 fix(theme-picker): Reformat invalid class names 2016-04-05 13:43:43 -07:00
Juan Tejada 9f4b9693ac fix(sync-status): Fix logic for checking sync status:
- Only check sync status keys that belong to actual models being synced
- Return false if state object is empty
2016-04-05 13:29:25 -07:00
Juan Tejada 18aa0f2bb8 fix(thread-search): Correct typo 2016-04-05 13:29:25 -07:00
Ben Gotow e08c7fe9d4 fix(notifs): _.reject does not support dict, Sentry 26699 2016-04-05 13:10:39 -07:00
Juan Tejada 4e326edfce fix(warning): Add key to react component 2016-04-05 12:16:32 -07:00
Juan Tejada 5a8f8b9877 fix(thread-search): Only rebuild index when # of accounts has changed 2016-04-05 12:16:32 -07:00
Ben Gotow 698af87912 fix(mail-rules): all "on" handlers need to be bound functions 2016-04-05 12:01:53 -07:00
Juan Tejada c17c1ffaa6 fix(prefs): Fix this binding in mail rules prefs page 2016-04-05 11:28:08 -07:00
Ben Gotow 646ac9589c fix(composer): Show when rendered, send draft JSON to composer windows 2016-04-04 18:30:50 -07:00
Juan Tejada fc489e5db3 feat(thread-search): Add client side search
Summary:
This diff includes several updates:
- Update sqlite version to use FTS5
- Adds new methods to DatabaseStore to create and update Search Indexes
- Currently indexing subject, participants, and thread message bodies or snippets if the body is not available
- Update initial sync to fetch 5000 message bodies per account
- Adds a new SearchMatcher
- Add new thread-search-index package to run in the worker window to
  init and keep thread search index up to date
- Converts Thread to ES6

TODO:
- Remove/Update suggestions dropdown
- Add tests

Test Plan: - TODO

Reviewers: evan, bengotow

Reviewed By: evan, bengotow

Differential Revision: https://phab.nylas.com/D2826
2016-04-04 17:15:19 -07:00
Ben Gotow 2688881ff3 fix(lint): Missing const breaking build 2016-04-04 17:12:59 -07:00
Ben Gotow 26fe05153c feat(offline-status): Show a bar when not connected to the API
Summary:
The TaskQueue does it's own throttling and has it's own processQueue retry timeout, no need for longPollConnected

Remove dead code (OfflineError)

Rename long connection state to status so we don't ask for `state.state`

Remove long poll actions related to online/offline in favor of exposing connection state through NylasSyncStatusStore

Consoliate notifications and account-error-heaer into a single package and organize files into sidebar vs. header.

Update the DeveloperBarStore to query the sync status store for long poll statuses

Test Plan: All existing tests pass

Reviewers: juan, evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D2835
2016-04-04 17:11:09 -07:00
Evan Morikawa db1f651a3e fix(scheduler): add timezone & fix tabbing 2016-04-04 16:06:48 -07:00
Ben Gotow b4434f6617 fix(focus): Remove focusedField in favor of imperative focus, break apart ComposerView
Summary:
- Removes controlled focus in the composer!
  - No React components ever perfom focus in lifecycle methods. Never again.
  - A new `Utils.schedule({action, after, timeout})` helper makes it easy to say "setState or load draft, etc. and then focus"
  - The DraftStore issues a focusDraft action after creating a draft, which causes the MessageList to focus and scroll to the desired composer, which itself decides which field to focus.
  - The MessageList never focuses anything automatically.
- Refactors ComposerView apart — ComposerHeader handles all top fields, DraftSessionContainer handles draft session initialization and exposes props to ComposerView
  - ComposerHeader now uses a KeyCommandRegion (with focusIn and focusOut) to do the expanding and collapsing of the participants fields. May rename that container very soon.
- Removes all CommandRegistry handling of tab and shift-tab. Unless you preventDefault, the browser does it's thing.
- Removes all tabIndexes greater than 1. This is an anti-pattern—assigning everything a tabIndex of 0 tells the browser to move between them based on their order in the DOM, and is almost always what you want.
- Adds "TabGroupRegion" which allows you to create a tab/shift-tabbing group, (so tabbing does not leave the active composer). Can't believe this isn't a browser feature.

Todos:
- Occasionally, clicking out of the composer contenteditable requires two clicks. This is because atomicEdit is restoring selection within the contenteditable and breaking blur.
- Because the ComposerView does not render until it has a draft, we're back to it being white in popout composers for a brief moment. We will fix this another way - all the "return unless draft" statements were untenable.
- Clicking a row in the thread list no longer shifts focus to the message list and focuses the last draft. This will be restored soon.

Test Plan: Broken

Reviewers: juan, evan

Reviewed By: juan, evan

Differential Revision: https://phab.nylas.com/D2814
2016-04-04 15:22:01 -07:00
Evan Morikawa 4986049bd6 fix(console): remove log 2016-04-04 15:20:25 -07:00
Evan Morikawa fd76568f15 fix(react): replace with ReactDOM 2016-04-04 15:17:50 -07:00
Evan Morikawa 15ff969e73 feat(calendar): add week view for quick scheduler
Summary: New Calendar

Test Plan: TODO

Reviewers: drew, juan, bengotow

Reviewed By: bengotow

Subscribers: jackie

Differential Revision: https://phab.nylas.com/D2767
2016-04-04 15:05:48 -07:00
Jackie Luo 73bf32c477 fix(composer-emoji): Replace images with Unicode characters properly 2016-04-04 11:03:52 -07:00
Jackie Luo d786fb85da Merge pull request #1861 from jamiewilson/darkside
(darkside) correcting window buttons, adding input focus
2016-04-02 13:40:24 -07:00
Jamie Wilson 8164d75b02 correcting size of window contol buttons
This addresses issue #1687 on nylas/n1
2016-04-02 15:02:26 -05:00
Jackie Luo f7e0acc4dd 🎨(preferences): Darken tab icons during click 2016-04-01 14:50:56 -07:00
Ben Gotow 209debf797 fix(thread-list): Constrain details width to ensure attachment icon visible. #1858 2016-04-01 14:49:15 -07:00
Jackie Luo e2480c1e36 fix(templates): Convert to ES6 and allow creation of new templates 2016-04-01 14:30:43 -07:00
Jackie Luo 6e07dce03c 🎨(preferences): Updates preferences to look prettier
Summary:
Adds new redesigned preferences with horizontal tab bar and refactored code.

Converts Preferences, Plugins, and a few components to ES6.

Test Plan: Tested locally.

Reviewers: evan, bengotow

Reviewed By: bengotow

Subscribers: juan

Differential Revision: https://phab.nylas.com/D2818
2016-04-01 14:01:26 -07:00
Jackie Luo 603a3dfb4b spec(composer-emoji): Fix specs for popover 2016-03-31 18:14:11 -07:00
Ben Gotow 9a588dbda6 fix(autolinker): Update regexp to handle reported failure cases 2016-03-31 16:36:23 -07:00
Juan Tejada bec4a86629 fix(build): FIx linting and react errors and popover spec 2016-03-31 16:10:09 -07:00
Ben Gotow 3d8133ff8d fix(inline): Use vw for max-width, use DOM rather than regex 2016-03-31 15:16:22 -07:00
Ben Gotow 78681f6ed1 fix(inline): radial progress, merge body with download data on render 2016-03-31 15:16:21 -07:00
Jackie Luo 6faa7d5e12 spec(composer-emoji): Add tests for emoji popover
Summary: Adds tests to check that emoji popover is inserting emoji correctly and adding PNGs as expected.

Test Plan: Tested locally.

Reviewers: evan, bengotow, juan

Reviewed By: juan

Subscribers: juan

Differential Revision: https://phab.nylas.com/D2810
2016-03-31 14:54:46 -07:00
Jackie Luo dc1ff47bb0 🎨(theme-picker): Fix oval close button 2016-03-31 12:04:41 -07:00
Jackie Luo 49a321124f 🎨(scroll): Fix UI issues in theme picker/emoji picker 2016-03-30 15:52:51 -07:00
Ben Gotow 39768fd9d4 bump(react): 0.13.2 => 0.14.7
Great breakdown of React changes here:
https://github.com/facebook/react/blob/master/CHANGELOG.md#0140-october-7-2015

Due to deprecation warnings, I don't think this will break third-party extensions unless they were doing really bad things.
2016-03-29 01:43:12 -07:00
Jackie Luo 62b06121f6 fix(composer-emoji): Render emoji characters on Windows/Linux 2016-03-28 16:18:41 -07:00
Jamie Wilson c5d41eaf6a applying accent color to focused inputs 2016-03-28 12:49:47 -05:00
Jackie Luo ec3ac5f58d 🎨(themes): Tweak Taiga to feel more native 2016-03-27 15:51:27 -07:00
Jackie Luo 9a923c7c88 fix(thread-list): Show emoji in bolded subject lines 2016-03-27 15:51:27 -07:00
Juan Tejada f7a4523604 update(open-tracking): Only display icon when last message has metadata 2016-03-25 14:00:55 -07:00
Juan Tejada 0e360b061b Revert "fix(open-tracking): Make sure icon only shows in sent perspective"
This reverts commit 872aae1bcd.
2016-03-25 14:00:55 -07:00
Jackie Luo cbf9627029 fix(composer-emoji): Only show replacement PNGs for OS X 2016-03-25 13:35:32 -07:00
Juan Tejada 872aae1bcd fix(open-tracking): Make sure icon only shows in sent perspective 2016-03-25 12:37:42 -07:00
Juan Tejada 8a3c2730cb fix(tray): Re add old icon assets for tray icon for win32 and linux 2016-03-25 10:05:17 -07:00
Ben Gotow 3fa93c2730 fix(composer): Sentry 9688 2016-03-24 17:18:50 -07:00
Jackie Luo 3e36e10f07 lint(themes): Add import to ui-variables 2016-03-24 16:56:49 -07:00
Ben Gotow c1b3f87d71 fix(autolinker): Don't include trailing ? or . in URLs 2016-03-24 16:35:11 -07:00
Jackie Luo 2fedf7f091 fix(themes): Re-add disclosure triangles to Taiga 2016-03-24 16:19:41 -07:00
Juan Tejada 5d90cb40b0 🎨(selected-stack): Update text color for clear selection btn 2016-03-24 15:47:49 -07:00
Ben Gotow cbce8fb79b fix(search): Display search API errors in transient notiication bar 2016-03-24 15:42:05 -07:00
Ben Gotow fc33e97bf8 perf(*): Replace _.omit, refresh scrollbar height less often 2016-03-24 15:14:41 -07:00
Juan Tejada 4bfb4fe916 patch(thread-list): Limit number of injected icons in narrow mode to 1
- Update InjectedComponentSet to take a limit for the amount of matching
  components to render
2016-03-24 12:32:01 -07:00
Juan Tejada d3ca6e592d feat(list): Add ThreadIcon injected region to narrow thread-list 2016-03-24 12:00:49 -07:00
Jackie Luo d6bc6e7bc5 fix(composer-emoji): Return if no search results are found 2016-03-24 11:57:49 -07:00
Ben Gotow 1d97b6811a fix(selection): Make the clear selection button a button 2016-03-24 10:57:12 -07:00
Jackie Luo d0b001012e feat(composer-emoji): Add emoji button to composer
Summary: The emoji picker allows users to insert emoji to their messages on click. A few emoji that don't render properly in Chromium are replaced with PNGs, both in the composer view and the message list view, but only the Unicode characters are sent in the message bodies.

Test Plan: TODO

Reviewers: bengotow, evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D2787
2016-03-24 10:45:48 -07:00
Ben Gotow ac70ed3064 fix(undo-redo): Remove initial state check 2016-03-24 10:42:15 -07:00
Ben Gotow 27000e1965 fix(autolinker): Only match top ten tld's when schme not present 2016-03-24 10:14:47 -07:00
Ben Gotow 75ff8282a8 perf(autolinker): Use requestIdleCallback to fix hanging on large bodies 2016-03-23 19:03:21 -07:00
Juan Tejada 95cd1945de fix(snooze): Correctly display snoozed until label 2016-03-23 18:00:46 -07:00
Juan Tejada 4a6d9d1085 fix(send-later): Close popover in inline composer when msg scheduled 2016-03-23 17:46:24 -07:00
Juan Tejada 9413459311 fix(styles): Fix styles for attachment and upload items 2016-03-23 17:16:25 -07:00
Jackie Luo f059e65acc fix(composer-emoji): Return null if no matching node is found 2016-03-23 17:01:14 -07:00
Jackie Luo e574c2ecf7 fix(composer-emoji): Fix setBaseAndExtent bug 2016-03-23 16:48:35 -07:00
Juan Tejada 0056773769 fix(signatures): Fix signature switching between accounts in composer 2016-03-23 15:23:13 -07:00
Dakota Nelson f3250e5395 Add extensibility in composer recipient chips
Summary:
Allow for injection into the composer's list of recipients to indicate
something about each recipient (i.e. for the PGP plugin, allow an
indicator as to whether or not each recipient has a PGP key
available)

Test Plan: Tested locally

Reviewers: juan

Reviewed By: juan

Subscribers: bengotow

Differential Revision: https://phab.nylas.com/D2761
2016-03-22 17:08:54 -07:00
Ben Gotow 92bff6ca5a fix(drafts): Formalize draft factory, add reply "behaviors" #1722
Summary:
This diff implements a behavior change described in https://github.com/nylas/N1/issues/1722.

Reply buttons should prefer to focus an existing draft in reply to the same message, if one is pristine, altering it as necessary to switch between reply / reply-all. If no pristine reply is already there, it creates one.

Reply keyboard shortcuts should do the same, but more strictly - the shortcuts should switch between reply / reply-all for an existing draft regardless of whether it's pristine.

This diff also cleans up the DraftStore and moves all the draft creation itself to a new DraftFactory object. This makes it much easier to see what's going on in the DraftStore, and I also refactored away the "newMessageWithContext" method, which was breaking the logic for Reply vs Forward between a bunch of different helper methods and was hard to follow.

Test Plan: They're all wrecked. Will fix after concept is greenlighted

Reviewers: evan, juan

Reviewed By: juan

Differential Revision: https://phab.nylas.com/D2776
2016-03-22 15:47:51 -07:00
Juan Tejada c07bead684 🎨(composer): Reduce contenteditable min height 2016-03-22 14:51:38 -07:00
Juan Tejada a6f9e84c9a fix(tasks): Properly handle DraftNotFoundError in DestroyDraftTask
- Fix reference to actual DestroyDraftTask class inside
  syncback-draft-task
2016-03-22 14:34:09 -07:00
Juan Tejada 419eace7e8 feat(popover): Add subtle ease-in animation when opening popover
- Closes popover on window resize:
  - Re rendering popover on window resize will be a bit more tricky because
    the FixedPopover only receives an origin rect. The one who
    dispatches the action has the responsability of re dispatching when
    the window resizes
- Fixes tiny behavior in send later popover
2016-03-22 13:45:07 -07:00
Juan Tejada dfd051339d fix(message-list-toolbar): Fix observable for selection & focused thread 2016-03-22 11:28:55 -07:00
Juan Tejada 9bbaf3b90d fix(attachments): Update fn name in ImageAttachmentComponent 2016-03-22 11:28:55 -07:00
Jackie Luo b1d49e8477 🎨(theme-picker): Fix styling for non-Retina displays 2016-03-21 19:35:47 -07:00
Ben Gotow 5dcb3a1bce fix(template): Rewrite in ES6, add missing windowTypes 2016-03-21 18:25:50 -07:00
Juan Tejada 96846d4052 feat(download-all): Adds download-all button + style updates, more ES6
Summary:
- Adds initial version of download all button
- Converts attachments plugin to ES6 and adds updated styling
- Updates quoted text button
- #905, #1712

Test Plan: - Unit + manual

Reviewers: evan, bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D2769
2016-03-21 18:23:26 -07:00
Ben Gotow a791ae76e0 fix(tray): Use total count, not unread count, for tray icon 2016-03-21 17:36:18 -07:00
Juan Tejada e83bf2bbec feat(selection): Add new display for selection count + update toolbar
Summary:
- New behavior is that the in split mode, you will perform actions on
  the selection via the MessageListToolbar (the toolbar positioned above
  the message list)
- Refactored and moved around a bunch of code to achieve this:
  - Mostly renaming stuff and moving stuff around and removing some
    duplication
  - Update naming of toolbar role to a single role, and update relevant code
  - Converted and refactored a bunch of code into ES6, specifically to reuse the code for the ThreadActionsToolbar at the 2 locations
  - Deprecated MultiselectActionBar in favor of MultiselectToolbar
  - Deprecated old roles
- Punted the animation for the stackable cards in the selection display for now.
- #370

Test Plan: - Manual and unit tests

Reviewers: evan, drew, bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D2756
2016-03-21 12:20:11 -07:00
Ben Gotow b5fe01e5d0 fix(composer): Refactor header actions, clean up layout
Summary:
WIP

Remove the mode prop from everywhere, use NylasEnv.isComposerWindow() instead

Test Plan: Run updated tests

Reviewers: drew, evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D2766
2016-03-21 11:32:48 -07:00
Jackie Luo 400ccb1cdb fix(theme-picker): Add tabIndex to click to dismiss 2016-03-18 18:12:55 -07:00
Ben Gotow 04faa0769f log(sync-state): Send Account State Delta to mixpanel 2016-03-18 15:09:00 -07:00
Ben Gotow 2d279eeb05 fix(onboarding): Focus first field when showing settings #1696 2016-03-18 14:03:37 -07:00
Jackie Luo 7ee762a202 fix(ui-taiga): Remove border-bottom in two-pane mode 2016-03-18 13:48:14 -07:00
Jackie Luo e0fa3d5707 fix(ui-taiga): Show active list item in single-pane mode (#1751) 2016-03-18 13:42:32 -07:00
Ben Gotow 073924ff00 fix(build): Fix failing linter and account tests 2016-03-18 13:26:03 -07:00
Ben Gotow 301cc4ad8b fix(quick-schedule): Update to use new APIs, remove leftover docs 2016-03-18 10:43:43 -07:00
Drew Regitsky 3af91d22b6 fix(sync-state): ignore Account.syncState=="stopped" for now
Valid accounts that are syncing properly can reviece a delta for
Account.syncState==stopped currently, due to some quirks in the backend.
Ignore "stopped" until it unabiguously represents an error state.
2016-03-18 10:41:08 -07:00
Jackie Luo e0db484276 bump(node-emoji): Use 1.2.1 with merged PR 2016-03-18 10:07:56 -07:00
Ben Gotow 9099542643 fix(quoted-text): div vs blockquote, signature cleanup #1746
Summary:
Previously we always created <blockquote class="gmail_quote"> to wrap quoted text. This is not correct.
Gmail uses blockquotes only when it wants visual indentation, and <div>s to wrap other quoted text, like forwarded
messages which are not displayed indented.

This diff updates N1 to match Gmail exactly. Note that for replies, Gmail actually nests a blockquote.gmail_quote
inside a div.gmail_quote.

I also updated signature handling because it turns out the regexp that was removing existing signatures would blow
away any and all divs until it reached a <blockquote> tag.

Test Plan: See updated specs. Manually tested by creating a thread in Google Inbox and then performing fwd and reply in both N1 and Inbox. Results match.

Reviewers: juan, evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D2750
2016-03-17 13:11:00 -07:00
Ben Gotow 9794817fb0 fix(lint): Actions is defined but never used 2016-03-16 20:04:01 -07:00
Ben Gotow 466bca813b fix(syncback): Bidirectional transforms, ready-to-send saved state
Summary:
This diff replaces "finalizeSessionBeforeSending" with a
plugin hook that is bidirectional and allows us to put the draft in
the "ready to send" state every time we save it, and restore it to
the "ready to edit" state every time a draft session is created to
edit it.

This diff also significantly restructures the draft tasks:

1. SyncbackDraftUploadsTask:
   - ensures that `uploads` are converted to `files` and that any
     existing files on the draft are part of the correct account.

1. SyncbackDraftTask:
   - saves the draft, nothing else.

3. SendDraftTask
   - sends the draft, nothing else.
   - deletes the entire uploads directory for the draft

Test Plan: WIP

Reviewers: juan, evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D2753
2016-03-16 19:27:12 -07:00
Jackie Luo e5e474569b sp(composer-emoji): Correct emojis to emoji 2016-03-15 13:37:54 -07:00
Juan Tejada b47c707845 fix(focus): Show drafts in unfocused state when window is blurred
- See #1695
- Update key commands region to clear focus when window blurs
- Dispatch broswer-window-focus/blur as a window event into the renderer
  window
- Update tray icon to listen to window instead of ipc event
2016-03-15 12:12:30 -07:00
Juan Tejada d324a33d4b feat(view-mode): Add option in menu to select view mode
Summary:
Also add minor refactoring
#1710

Test Plan: Manual

Reviewers: bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D2745
2016-03-15 11:20:55 -07:00
Jackie Luo c49d523e8f refactor(ui-variables): Clean UI variables for consistency/usage
Summary: Shortens and simplifies UI variables so that unused variables are no longer present.

Test Plan: Tested locally.

Reviewers: evan, bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D2738
2016-03-15 11:18:50 -07:00
Ben Gotow da47fd4bdb fix(autolinker): Additional phone number parsing specs 2016-03-15 11:04:00 -07:00
Ben Gotow 73afdbb482 fix(autolinker): Add more test cases, improv URL regex 2016-03-15 10:47:14 -07:00