- EmptyState should only be displayed when the thread-list is actually
empty, not while it is being loaded
- Update ObservableListDataSource to have a state of loaded only when
the requested range is > 0, i.e. when we are actually requesting threads
The FocusedPerspectiveStore wants to restore a saved current perspective from disk. It needs to wait for the categories to be ready, but it doesn't necessarily need to wait for them to be synced, because it's unlikely unsynced categories are in the saved perspective and it just falls back to unified inbox.
I think there was some dead code in `_onCategoryStoreChanged` that initialized the perspective also, so I merged the two
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
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
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
- 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.
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
Summary:
- This diff includes code to connect to the new search stremaming API. It converts the old NylasLongConnection into ES6 without any of the cursor management and includes it as part of NylasAPI
- Removes current search error handling because of the new error semantics of the api. If no results are returned a message will be displayed to the user indicating that
- WIP TODO:
- Replace old NylasLongConnection class with new one and add test coverage.
I did not replace our current streaming code with the new ES6 code yet because
the old code doesn't have test coverage and I don't want to introduce any
(subtle) regressions to a vital piece of the app.
- Potentially replace with JSONStreaming library or new http library
(e.g. fetch)
- Note that Streaming API is not in production yet and only works for Gmail and IMAP (no EAS)
Test Plan: -TODO, manual
Reviewers: bengotow, evan
Reviewed By: evan
Differential Revision: https://phab.nylas.com/D2859
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
This is to fix a bug where changing the "from" address to an address with a different signature caused the composer to become focused, hiding the from field.
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