Mailspring/spec/stores
Ben Gotow 8b3f7f0578 feat(outbox): Sending status now appears beside drafts
Summary:
This diff adds an "OutboxStore" which reflects the TaskQueue and
adds a progress bar / cancel button to drafts which are currently sending.

- Sending state is different from things like Send later because drafts
  which are sending shouldn't be editable. You should have to stop them
  from sending before editing. I think we can implement "Send Later"
  indicators, etc. with a simple InjectedComponentSet on the draft list
  rows, but the OutboxStore is woven into the DraftList query subscription
  so every draft has a `uploadTaskId`.

- The TaskQueue now saves periodically (every one second) when there are
  "Processing" tasks. This is not really necessary, but makes it super
  easy for tasks to expose "progress", because they're essentially
  serialized and propagated to all windows every one second with the
  current progress value. Kind of questionable, but super convenient.

- I also cleaned up ListTabular and MultiselectList a bit because they
  applied the className prop to an inner element and not the top one.

- If a DestroyDraft task is created for a draft without a server id, it
  ends with Task.Status.Continue and not Failed.

- The SendDraftTask doesn't delete uploads until the send actually goes
  through, in case the app crashes and it forgets the file IDs it created.

Test Plan: Tests coming soon

Reviewers: juan, evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D2524
2016-02-04 14:14:24 -08:00
..
account-store-spec.coffee Add account switcher back to sidebar: 2016-01-19 23:42:50 -08:00
contact-store-spec.coffee fix(contact-search): Keep only ranked contacts, query for others. Massive perf boost. 2016-01-28 14:56:15 -08:00
database-setup-query-builder-spec.coffee DatabaseTransaction / QueryBuilder spec fixes 2016-01-25 11:11:57 -08:00
database-store-spec.coffee feat(tasks): add Create, Update, Destroy tasks plus spec & lint fixes 2016-01-15 15:16:21 -05:00
database-transaction-spec.coffee DatabaseTransaction / QueryBuilder spec fixes 2016-01-25 11:11:57 -08:00
draft-store-proxy-spec.coffee feat(tasks): add Create, Update, Destroy tasks plus spec & lint fixes 2016-01-15 15:16:21 -05:00
draft-store-spec.coffee feat(outbox): Sending status now appears beside drafts 2016-02-04 14:14:24 -08:00
file-download-store-spec.coffee Merge branch 'master' into unified-inbox 2016-01-13 17:20:34 -08:00
file-upload-store-spec.coffee fix(uploads): Consolidate logic, use Promisify, path.join 2016-01-29 14:45:53 -08:00
focused-contacts-store-spec.coffee
focused-content-store-spec.coffee Merge branch 'master' into unified-inbox 2016-01-25 17:28:29 -08:00
focused-perspective-store-spec.coffee Fix drafts 2016-01-25 16:37:34 -08:00
message-store-spec.coffee fix(message-list): Spec fixes, all stubs need accountId 2016-01-28 11:14:04 -08:00
task-queue-spec.coffee feat(outbox): Sending status now appears beside drafts 2016-02-04 14:14:24 -08:00
thread-counts-store-spec.coffee Merge branch 'master' into unified-inbox 2016-01-25 17:28:29 -08:00
unread-badge-store-spec.coffee fix(badge): Badge respects option in prefs 2015-11-30 19:17:35 -08:00