Commit graph

421 commits

Author SHA1 Message Date
Ben Gotow 48574ddffa fix(multiselect-list): Only show loading dots when list source is empty
Fixes T1118
2015-08-10 15:09:53 -07:00
Ben Gotow a5f05f52fd fix(composer): Remove unnecessary zIndex rules, fix wrapping around Cc/Bcc/Subject icons
Previously, we were adding 160px of padding to the entire To field. Now the buttons in the top right are floating inside the container and only impact the first line of participants.

I also stripped out a lot of zIndex rules on the participant fields, subject, body that I think were only necessary because "once you've started adding zindexes you need them everywhere".

Also changed the hover state of the buttons to be consistent.
2015-08-10 14:47:47 -07:00
dillon f5172bd1b2 fix(composer): default warning is now 'Send Anyway' instead of 'Cancel'
Summary: Fixes T2433

Test Plan: Updated composer specs

Reviewers: bengotow

Reviewed By: bengotow

Maniphest Tasks: T2433

Differential Revision: https://phab.nylas.com/D1861
2015-08-10 12:19:40 -07:00
dillon 0dc3f6f883 fix(message-list): side-bar button shouldn't be selectable
Summary: fixes T2852

Test Plan: tested manually

Reviewers: bengotow

Reviewed By: bengotow

Maniphest Tasks: T2852

Differential Revision: https://phab.nylas.com/D1859
2015-08-10 11:40:19 -07:00
Ben Gotow b2d80d12b5 fix(participant-fragments): Fragment based on name as well as email
Fixes T2880, with a new test
2015-08-06 13:12:24 -07:00
Ben Gotow 58a9d60ce1 fix(specs/keys): Fix broken specs, clean up CJSX 2015-08-06 12:22:06 -07:00
Ben Gotow 574c32438a fix(reply-area): Remove animated height from message list reply-area - looks strange since the removal of a draft is not otherwise animated 2015-08-05 17:41:15 -07:00
Ben Gotow e17c7812a8 fix(drafts): Fix rapid draft creation and deletion issues 2015-08-05 17:40:33 -07:00
Ben Gotow be4af0671b feat(composer): Show blue focus ring around the composer 2015-08-05 17:38:44 -07:00
Ben Gotow 1e6e857f28 perf(*): Add indexes, optimize "shouldAcceptModel", optimize Tasks
Summary:
Consolidate the smarts from ChangeFolderTask into a generic ChangeMailTask

ChangeMailTask:
   - only makes requests for threads / messages that actually changed
   - handles incrementing / decrementing locks
   - writes changes to the database in a single pass, and only writes modified models
   - encapsulates the undo state that was built into ChangeFolderTask

This change means that ChangeLabelsTask enjoys the same "smarts" as ChangeFolderTask. Label changes resulting in no-ops do not create web requests, you can undo label changes and they go back to the correct previous state.

Replace "UpdateThreadsTask" and "UpdateNylasObjectsTask" with subclasses based on the same code used for folder/labels

This means that the naming and parameter sets are consistent for all thread/message changing tasks. It also means that starring/marking as use the same (tested) business logic and starring 999 already-starred threads doesn't create 999 requests.
Go away DraftCountStore - nobody wants you in secondary windows

Add "Debug query plans" option which prints out the steps the database is taking. Look for "SCAN" to now you're having a bad time.

Make "version" field queryable, when we receive deltas/API response, find all versions of existing models in a single query without loading or parsing the objects

Contact: Add index for lookup by email

Label: add index for lookup by name

Message: Add index for message body join table

Test Plan: Run tests

Reviewers: evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D1840
2015-08-05 15:53:08 -07:00
Evan Morikawa aeced745f3 fix(spec): Make specs work with new animated pending message 2015-08-05 09:34:56 -07:00
Evan Morikawa a125e79799 fix(message-list): get rid of flicker and add transitions
Test Plan: edgehill --test

Reviewers: bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D1841
2015-08-04 19:35:56 -07:00
Ben Gotow 7f84917675 fix(lint): Address linter errors 2015-08-03 19:09:08 -07:00
Ben Gotow 0b9b72dce5 fix(draft-scroll): Ignore composer scroll requests while moving to new draft 2015-08-03 18:39:11 -07:00
Ben Gotow 0f76577a15 fix(message-scroll): Remove double overflow:auto to prevent scroll weirdness
Fixes T2357
2015-08-03 18:37:06 -07:00
Evan Morikawa c001cb0be8 fix(spec): fix rename issue 2015-08-03 17:41:18 -07:00
Evan Morikawa 763e42d974 fix(message-list): fix type and change variable name 2015-08-03 17:28:56 -07:00
Evan Morikawa ada9f722f5 feat(message-list): better sending state
Summary:
We now have a `MessageItemContainer` class that handles the logic of
deciding what kind of message to show. We introduce a new `PendingMessage`
(which is just a sublcass of `MessageItem`) that has the spinner and
stuff.

Also tests

Test Plan: edgehill --test

Reviewers: bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D1833
2015-08-03 17:19:07 -07:00
Ben Gotow 9b2f830348 fix(*): Minor performance tweaks and fixes to category picker
Summary:
fix(undo-redo): UndoRedoComponent does not take props

fix(category-picker):

- Use Actions.queueTask like the rest of the app so UndoRedoStore can see it. Can change this in the future but it's currently the only place in the app we directly queue tasks.

- Stop subscribing to the FocusedContentStore / FocusedCategoryStore (which are not used in setState?) since we receive threads as props

- Rename categoryDatum to item because it's not a category. (Was super confused that categories were becoming JSON in `_extendCategoryWithDisplayData`) Give item a category property so that tasks can specify items and not IDs (allows for better descriptions like "Moved one thread to Archive"

Add simple shouldComponentUpdate to retina-img

Test Plan: Run tests

Reviewers: evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D1832
2015-08-03 17:05:31 -07:00
Ben Gotow 8884435da0 fix(undo-redo): Minor tweaks to undo/redo based on testing - see description
Summary:
Give UpdateThreadsTask a description method for strings like "Marked as read"

Give ChangeLabelsTask a better description method that returns shorter strings and is specific when possible

Give ChangeFolderTask a more specific description and don't assume folderOrId will always be a folder

Make it so that passive "mark as read" from the message store isn't undoable

Give the base class a description method that names the object

Change UndoRedo component CSS a bit:

- Use "inline-flexbox" with a max-width so that we can define shrinking rules on the label and Undo button (label gets ellipsis, button does not shrink at all)

- Avoid left:39%, since it assumed that the undo-redo element would be 22% of the width of the thread list, which wasn't always true. Instead, make the `undo-redo-manager` container "text-align:center", so the `undo-redo` div is always centered within it.

- Add `cursor:default` so that the user sees the pointer, not the text insertion cursor when hovering over "Undo"

- Add overflow / text-overflow so that if the message is ever too long, the user sees `...` ellipsis properly.

Test Plan: Run a few new tests

Reviewers: evan, ethanb

Reviewed By: ethanb

Differential Revision: https://phab.nylas.com/D1830
2015-08-03 14:46:19 -07:00
Ben Gotow 00bab73fbe fix(thread-list): Add more shouldComponentUpdate to prevent threadlist re-rendering as you move keyboard cursor 2015-08-03 14:09:29 -07:00
Ben Gotow 1dc7c03ebd fix(contact-chips): Contact chips are editable and have much better style
Summary:
The TokenizingTextField has several new optional props, including onEdit, which enables
editing of the tokens and tokenIsInvalid, which allows you to make tokens red, while still
accepting them as tokens.

When you go to send a message with invalid recipients it won't let you until you remove/
edit them.

Hotloading

Edit chips, keymappings not through command registry, 7 new tests for editing chips

Test Plan: Run 7 new tests

Reviewers: evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D1825
2015-08-03 13:06:28 -07:00
Ben Gotow b2602222bc fix(invariant): Remove event listener with "capture: true"
Fixes https://sentry.nylas.com/sentry/edgehill/group/1831/
2015-08-03 11:38:57 -07:00
Evan Morikawa 9d17b90b93 fix(tooltip): doesn't show on archive either 2015-08-03 10:57:56 -07:00
Ben Gotow 99da4a112a fix(undo-redo): Clear timeout when component unmounts to avoid React errors 2015-08-03 10:21:04 -07:00
EthanBlackburn 11b20f326d Removed old code from thread-list 2015-07-31 14:02:13 -07:00
EthanBlackburn 76b83f5faf Merge branch 'master' of github.com:nylas/edgehill into receivedrecentdate-sent-folder-fix 2015-07-31 13:59:05 -07:00
EthanBlackburn 17bcb88ae3 UndoRedoButton now shows
Summary: A notification now appears at the bottom of the window when the user performs an action that can be undone

Test Plan: Tested manually

Reviewers: bengotow

Reviewed By: bengotow

Subscribers: mg

Differential Revision: https://phab.nylas.com/D1820
2015-07-31 13:12:47 -07:00
EthanBlackburn 631098f4f0 Merge branch 'master' of github.com:nylas/edgehill into receivedrecentdate-sent-folder-fix 2015-07-31 12:38:53 -07:00
Ben Gotow 73ae6ea6f3 fix(T2387): Use better file icons from SDW
Summary:
fix misc spec failure by making event store fetch immediately on setup

add specs for displayExtension, displayName

Test Plan: Run new tests

Reviewers: evan

Maniphest Tasks: T2387

Differential Revision: https://phab.nylas.com/D1821
2015-07-31 12:34:24 -07:00
Ben Gotow 31512e8d9a fix(specs): Resolve merge issues in specs 2015-07-31 12:06:34 -07:00
EthanBlackburn c9ef090fa0 Fixed bug where items in sent folder have "invalid date" 2015-07-31 08:23:03 -07:00
Ben Gotow 43f9b0b8c3 fix(message-list-scrolling): Move scroll logic to ScrollRegion
Summary: This is still a work in progress and needs more specs

Test Plan: Run tests

Reviewers: evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D1808
2015-07-30 18:29:38 -07:00
Ben Gotow 266e50607e fix(T2347): Alignment of attachment icon is now consistent row-to-row
Fixes https://phab.nylas.com/T2347. Note that it could still appear indented a bit if a thread has a particularly long timestamp, but should account for all cases.
2015-07-30 16:43:44 -07:00
Ben Gotow 07322b3b6c fix(T2418): Make buttons in the composer footer 4px taller
Fixes https://phab.nylas.com/T2418 ("Fixes")
2015-07-30 14:51:36 -07:00
EthanBlackburn 88a45dfd13 RSVP tile for events on messages
Summary: RSVP tile now appears for messages with attached events.

Test Plan: Tested manually. Will add unit tests

Reviewers: evan, bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D1797
2015-07-28 18:21:30 -07:00
EthanBlackburn c622e2dbeb Threads now sorted by receivedrecetndate
Summary: Threads are now sorted using the thread's receivedrecentdate instead of recentdate

Test Plan: Tested Manually

Reviewers: bengotow

Reviewed By: bengotow

Subscribers: mg

Differential Revision: https://phab.nylas.com/D1812
2015-07-28 14:03:55 -07:00
Ben Gotow 73a2f7c5c7 fix(composer): Remove post-install script 2015-07-24 19:30:34 -07:00
Ben Gotow 1f748cc2fa fix(T2117): Make draft body font size 15px instead of 15.9px
Fixes T2117 as much as possible. Still *slightly* kerned differently but there's not much we can do. DirectWrite font rendering just sucks on Windwos.
2015-07-24 19:25:49 -07:00
Ben Gotow 8b751f2520 fix(build): Actually install package dependencies 2015-07-24 19:12:25 -07:00
Ben Gotow d2833cfefa feat(hotloading): CJSX hotloading when running in dev mode
Summary:
# Conflicts:
#	static/components/tokenizing-text-field.less

Wat no

Test Plan: Tested with ci build

Reviewers: evan

Reviewed By: evan

Maniphest Tasks: T1216

Differential Revision: https://phab.nylas.com/D1804
2015-07-24 14:10:48 -07:00
Evan Morikawa 5b7ca072cd fix(popover): don't let popover overflow
Summary:
The popover class now will adjust itself until it fits within the window
frame. You don't see the intermediate state in the double render.

Test Plan: edgehill --test

Reviewers: bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D1795
2015-07-23 19:42:16 -07:00
Ben Gotow add780f28e fix(message): Show folder in expanded headers 2015-07-23 15:18:08 -07:00
Ben Gotow 45fd754fd3 fix(thread-list): Cache MailLabel component instances to prevent needless rendering 2015-07-23 14:30:32 -07:00
Evan Morikawa 344d938c24 fix(message-store): fix scoping issue in message store 2015-07-23 12:42:42 -07:00
Evan Morikawa f1d9ba6233 feat(labels): replace account sidebar icon with proper image 2015-07-23 12:33:21 -07:00
Evan Morikawa 0b3dcd3e35 fix(styles): fix button padding and styles 2015-07-23 12:22:27 -07:00
Evan Morikawa f22d154486 feat(picker): new folder and label picker
Summary:
The new, styled folder and label picker!

Some highlights:
- Folder picker has custom icons and a divider
- Label picker has checkboxes with off, checked, and intermediate state
- Extracted LabelColorizer out of mail-label
- Search will bold the results it found
- Fixes to Tooltip to prevent it displaying at invalid moments
- Keyboard UX improvements to Menu

Test Plan: coming soon

Reviewers: bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D1790
2015-07-23 11:47:46 -07:00
Ben Gotow 0aea79f0ba Fix specs 2015-07-23 11:32:13 -07:00
Ben Gotow 5acbdb0955 fix(workspace): Support for hidden locations / columns
Summary:
- New control will likely be shortlived - SDW mocking up replacement for when settings UI lands
- New action for toggling location hidden
- New rule for mail labels: can't remove "Sent"

Test Plan: Run tests - none new atm

Reviewers: evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D1782
2015-07-23 11:18:42 -07:00