Commit graph

422 commits

Author SHA1 Message Date
Evan Morikawa d5fc102f8a feat(attachment): improved downloading and draggable images
Summary:
Fixes T1975
Fixes T1900
Fixes T1899
Fixes T1979

Attachments downloading update progress

downloads will restart if the file on disk isn't complete

can drag images onto drive

Test Plan: edgehill --test

Reviewers: bengotow

Reviewed By: bengotow

Maniphest Tasks: T1900, T1899, T1975, T1979

Differential Revision: https://phab.nylas.com/D1638
2015-06-15 18:48:17 -07:00
Evan Morikawa 304c34f918 fix(specs): silence noisy specs and fix warnings
Summary:
Silence buffered process spec

Clean up error reporter and spec bootup

fix errors in draft store spec

package manager spec and theme spec fixes

Fix memory leak in draft store

Test Plan: mmmmmm tests. Run all those green passing tests :)

Reviewers: bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D1628
2015-06-15 18:29:59 -07:00
Ben Gotow f6b5b7ea30 fix(T1251) When a returnsModel request returns a 404, unpersist the object
Summary:
Give DatabaseStore trigger payload a 'type' so that you can handle the deletion of objects (clear focus if the object is focused, know to remove it from database view)

Fix specs and add one for new DatabaseView => unpersist handler

Test Plan: Run new test case

Reviewers: evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D1639
2015-06-15 18:23:58 -07:00
Ben Gotow e090dd428a feat(subject-search): Use basic LIKE query and date ordering to find likely emails
Summary: Begins to fix T1866, but for now only doing a LIKE instead of FTS4, because there are many, many other things to think about there.

Test Plan: No new tests. I still want to rewrite the whole search bar.

Reviewers: evan

Reviewed By: evan

Maniphest Tasks: T1866

Differential Revision: https://phab.nylas.com/D1634
2015-06-15 18:22:41 -07:00
Ben Gotow 646e159a69 fix(T1886): When sending, strip off fields if they result in specific, known errors on the API
Summary: Fixes T1886

Test Plan: Run 2 new tests

Reviewers: evan

Reviewed By: evan

Maniphest Tasks: T1886

Differential Revision: https://phab.nylas.com/D1633
2015-06-15 18:19:52 -07:00
Ben Gotow 6f16659a30 fix(T1758): Handle initial focus properly if draft is not yet ready 2015-06-15 14:48:54 -07:00
Ben Gotow 42819e4d71 upgrade(electron): 0.28.1. Improvements to webview, clipboard on linux 2015-06-15 11:22:42 -07:00
Evan Morikawa 7b9f89bc5d fix(keymap): add ctrl-enter to send email 2015-06-12 17:47:59 -07:00
Evan Morikawa 3e30e18236 fix(thread-list): narrow mode isn't hidden 2015-06-12 13:31:30 -07:00
Evan Morikawa fed1076d04 Fixes T1928: don't lose focus on cc and bcc fields
Summary: Fixes T1928

Test Plan: edgehill --test

Reviewers: bengotow

Reviewed By: bengotow

Maniphest Tasks: T1928

Differential Revision: https://phab.nylas.com/D1622
2015-06-11 18:48:55 -07:00
Ben Gotow f887e4e55a fix(style): Minor styling adjustments (floating toolbar, token carats) 2015-06-11 18:46:30 -07:00
Evan Morikawa 6f4f0c0ad0 Fixes T1868: tokenizing inputs resize properly
Summary:
Fixes T1868
The hidden sizing window was not getting whitespace properly and the width
was different because of different paddings

Test Plan: edgehill --test

Reviewers: bengotow

Reviewed By: bengotow

Maniphest Tasks: T1868

Differential Revision: https://phab.nylas.com/D1623
2015-06-11 18:39:55 -07:00
Ben Gotow f7f1ab3605 feat(thread-actions): Hover actions on thread list, improved drawing performance
Summary: Adds hover actions to threads in the thread list, uses overflow:hidden to improve thread list render times

Test Plan: Run tests

Reviewers: evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D1621
2015-06-11 18:38:57 -07:00
Ben Gotow aa10ddfd1c fix(thread-list): Narrow mode, and new selection rules for three-pane
Summary:
Fix bug in apm_wrapper

Refactor model selection so that it's easier to understand the logic for split vs list mode

Test Plan: Run new specs (WIP)

Reviewers: evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D1619
2015-06-11 18:00:40 -07:00
Evan Morikawa d7f12873b3 feat(update): autoupdater adds an updateLevel param
Summary:
There's now an `updateLevel` that can be set in the config file.

It has the valid values of "major", "minor", "patch", and "commit". By
default it upgrades on the "patch" level.

If you want to be on the bleeding edge, manually change the config file to
add `updateLevel: 'commit'`

Test Plan: A new `auto-update-manager-spec` :)

Reviewers: bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D1567
2015-06-11 12:23:31 -07:00
Evan Morikawa 4f62a7c9e1 feat(salesforce): can convert a Lead to a Contact
Summary:
In order to create a Contact from a Lead you need to:

1. Create an Account
2. Create an Opportunity and link it to the newly created Account
3. Create a Contact and link it to the Account
4. Create an OpportunityContactRole and link it to both a Contact and an
Opportunity

Working on passing pending object ids around

add in window openers

create lead and check if lead got deleted

Saving form

conversion workflow syncs with opportunities now

Test Plan: manual

Reviewers: bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D1599
2015-06-11 12:05:12 -07:00
Evan Morikawa 6fcd5f2ced feat(attachments): new attachments & uploads UI with img support
Summary:
Initial styles on attachments ui

More file uploading UI

fix race condition in draft saving

attachments and uploads interweaved

Test Plan: edgehill --test

Reviewers: bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D1610
2015-06-11 12:04:52 -07:00
Ben Gotow 7a62f5ce7d fix(icon-type): Star / unread status should work even when we can't compute "forwarded / replied" icons 2015-06-09 10:35:21 -07:00
Ben Gotow 6221bf1311 fix(fakt): Rename fakt, never try to use the locally installed version (with potentially incorrect baseline) 2015-06-08 17:48:59 -07:00
Ben Gotow 336b9f2c76 fix(composer): Border appearing in inline composer 2015-06-08 17:27:09 -07:00
Ben Gotow a903bbea7c fix(build): CSS lint error breaking mac build 2015-06-08 17:24:55 -07:00
Ben Gotow 256813208f feat(starring): Star and unstar threads in the thread list
Summary:
When two or more buttons are grouped together, cut the padding off one interior edge so they're spaced more appropriately

Remove source list graphics for active states we aren't using

Starred in the sidebar

Small fix to the feature that keeps the selected item visible as you scroll

Test Plan: No new tests yet

Reviewers: evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D1607
2015-06-08 17:02:50 -07:00
Ben Gotow 43924e2918 feat(paste): Add files by pasting them into the composer
Summary: You can now add file attachments by pasting them.

Test Plan: Run 3 new specs! We only had specs for sanitization so I added some for the paste event handler as well.

Reviewers: evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D1604
2015-06-08 12:41:31 -07:00
Ben Gotow 92e366653e punt(files): Temporarily disable the files package 2015-06-08 11:22:37 -07:00
Ben Gotow b6730864be fix(test): function execution order seems different on CI server? 2015-06-05 19:25:42 -07:00
Ben Gotow 87dc291327 fix(css): Invalid padding value separated by commas 2015-06-05 18:33:17 -07:00
Ben Gotow 54b9f2bfb6 fix(RetinaImg): shoudn't throw an exception if you forget to provide an image name 2015-06-05 18:28:06 -07:00
Ben Gotow 5904381338 fix(mac-build): CSS Linter warnings treated as errors 2015-06-05 18:22:11 -07:00
Ben Gotow 1bd8767a77 fix(iframes): Contextual menus for email contents
Summary: Fixes T1191

Test Plan: No new tests to see here.

Reviewers: evan

Reviewed By: evan

Maniphest Tasks: T1191

Differential Revision: https://phab.nylas.com/D1603
2015-06-05 16:47:30 -07:00
Ben Gotow fb3f7fc410 feat(scrollbars): Custom scrollbars via ScrollRegion
Summary:
ScrollRegion with support for tooltips shown as you scroll, custom tooltips for thread list and message list.

fix(specs): all other scrollbars hidden to prevent incompatibility

fix scrollbar sizing when used in conjunction with resizableregion

Test Plan: Need to write tests and docs for ScrollRegion - no tests yet

Reviewers: evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D1597
2015-06-05 11:50:55 -07:00
Ben Gotow bc916a2530 feat(theming): Definitely not hacker mode. I don't know what you're talking about.
Summary: Add docs for new RetinaImg modes

Test Plan: Not much to test, except that it looks good!

Reviewers: evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D1595
2015-06-05 11:40:44 -07:00
Ben Gotow ded4da1505 fix(draft-speed): Optimize draft creation and reduce scroll / focus delays
Summary:
This diff attempts to improve the responsiveness of the app when you hit "Reply". This is achieved by being smarter about creating the draft and loading it into the draft store, and also by allowing the compose* actions to take objects instead of just IDs (resulting in a fetch of the object).

Allow Actions.composeReply,etc. to optionally be called with thread and message objects instead of IDs. This prevents a database lookup and the data is "right there."

Create DraftStoreProxy for new drafts optimistically—this allows us to hand it the draft model we just created and it doesn't have to go query for it

When we create a new Draft, immediately bind it to a LocalId. This means that when the MessageStore receives the trigger() event from the Database, it doesn't have to wait while a localId is created

When MessageStore sees a new Message come in which is on the current thread, a draft, and not in the localIds map, assume it's a new draft and shortcut fetchFromCaceh to manually add it to the items array and display. This means the user sees the...

...draft instantly.

Remove delays from focusing draft, scrolling to draft after content is ready. I actually removed these thinking it would break something, and it didn't break anything.... Maybe new Chromium handles better?

Fix specs

Test Plan: Run specs - more in progress right now

Reviewers: evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D1598
2015-06-05 11:38:30 -07:00
Ben Gotow 503631e685 fix(*): Resolve a variety of small and simple bugs
Summary:
Fix T1822 - saving templates not working, not showing template

Fix T1800 - give composers a minimum size

Fix the bottom bar of the composer so the gray bar goes all the way across in popout mode.

Fix T1825 - switch to a more attractive "June 4, 2015 at 3:10 PM" styling for expanded dates

Remove, rather than hide, react components for text fields in composer. Fixes T1147

Fix specs

Switch to 999+ instead of infinity. Fixes T1768

Fix broken TemplateStore specs

Test Plan: Run tests

Reviewers: evan

Reviewed By: evan

Maniphest Tasks: T1147, T1768, T1822, T1800, T1825

Differential Revision: https://phab.nylas.com/D1601
2015-06-05 11:02:44 -07:00
Ben Gotow 3201a9e82e fix(sentry): Switch to private sentry 2015-06-03 18:00:17 -07:00
Ben Gotow 89e9cdef8d feat(*): draft icon, misc fixes, and WorkspaceStore / custom toolbar in secondary windows
Summary:
Features:
- ThreadListParticipants ignores drafts when computing participants, renders "Draft" label, pending design

- Put the WorkspaceStore in every window—means they all get toolbars and custom gumdrop icons on Mac OS X

Bug Fixes:

- Never display notifications for email the user just sent

- Fix obscure issue with DatabaseView trying to update metadata on items it froze. This resolves issue with names remaining bold after marking as read, drafts not appearing in message list immediately.

- When you pop out a draft, save it first and *wait* for the commit() promise to succeed.

- If you scroll very fast, you node.contentWindow can be null in eventedIframe

Other:

Make it OK to re-register the same component

Make it possible to unregister a hot window

Break the Sheet Toolbar out into it's own file to make things manageable

Replace `package.windowPropsReceived` with a store-style model where anyone can listen for changes to `windowProps`

When I put the WorkspaceStore in every window, I ran into a problem because the package was no longer rendering an instance of the Composer, it was declaring a root sheet with a composer in it. This meant that it was actually a React component that needed to listen to window props, not the package itself.

`atom` is already an event emitter, so I added a `onWindowPropsReceived` hook so that components can listen to window props as if they were listening to a store. I think this might be more flexible than only broadcasting the props change event to packages.

Test Plan: Run tests

Reviewers: evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D1592
2015-06-03 16:02:19 -07:00
Ben Gotow 9236a2289b fix(build): Temporarily disable 'Task' tests Jenkins can't run, and avoid empty ui-variables files 2015-06-03 12:04:43 -07:00
Ben Gotow e246ec3204 fix(mac-build): Lint error breaking jenkins 2015-06-03 11:10:42 -07:00
Ben Gotow 2cac5e1edf fix(fakt): Switch to otf fonts with correct baseline, remove hacky styles 2015-06-03 11:07:59 -07:00
Ben Gotow 7ea8b0ea06 add(specs): Empty folders and node_modules in spec fixture to fix specs 2015-06-03 10:23:54 -07:00
Ben Gotow f0f4df6714 add(specs): +101 specs and 403 assertions from Atom 2015-06-02 19:51:00 -07:00
Ben Gotow 2b324c4533 feature(package-management): Package management interface, APM integration
Summary:
Update a few more packages to deactivate properly

Miscelaneous fixes

Initial commit of new settings package

WIP

WIP - can load and unload and install / uninstall

Click to create new boilerplate package, package updating

Test Plan: Run tests

Reviewers: evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D1582
2015-06-02 19:04:21 -07:00
Michael Grinich bdc6a93887 Move guides from Edgehill repo to Redwood and only generate docs from classes 2015-06-02 16:24:56 -07:00
Ben Gotow b9ab0fa234 fix(commands): Broken event dispatch after 0.27.2 push 2015-06-01 18:31:42 -07:00
Ben Gotow 33606e27e0 fix(database-view): Double-query when creating DatabaseView objects
Summary: Remove debounce on initial view creation that was causing `retrievePage` to be called twice

Test Plan: Run tests

Reviewers: evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D1587
2015-06-01 18:29:54 -07:00
Ben Gotow eac4029ded fix(selection): Fix issue where selecting offscreen thread (null) could break selection
Summary:
- ModelViewSelection shouldn't break if you accidentally call it with null

- ModelViewSelection methods should throw if you pass non-items, need to do this to narrow down other Sentry errors

Test Plan: Run new specs

Reviewers: evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D1589
2015-06-01 18:29:39 -07:00
Ben Gotow 72fdfcd4a1 fix(T1167): When focusing an iFrame, remove selection from the parent document
Summary: Fixes T1167 (MG's additional scenario)

Test Plan: Run tests

Reviewers: evan

Reviewed By: evan

Maniphest Tasks: T1167

Differential Revision: https://phab.nylas.com/D1585
2015-06-01 16:01:13 -07:00
Ben Gotow d35dcd32e3 fix(app): When there is no focused window, dispatch events to the mainWindow
Summary: This fixes T1766 and probably others as well, ensuring that commands not handled by the browser-side are still delivered to the main window even when it's hidden.

Test Plan: Run tests

Reviewers: evan

Reviewed By: evan

Maniphest Tasks: T1766

Differential Revision: https://phab.nylas.com/D1586
2015-06-01 16:00:57 -07:00
Ben Gotow dad36aad2f bump(electron): Electron 0.27.1, Chromium 43
Summary:
0.27.1? Nope webview still broken

Update atom-keymap

As of Chromium 42, you cannot subclass CustomEvent or Event using Object.create(event). This caused the CommandRegistry to break. Creating a new object with the properties of the event seems to work fine.

Resolves "Deprecated attempt to access property 'target' on a non-Event object.
dispatchEvent
fireCustomEventevent-test.html:8
global codeevent-test.html:21
event-test.html:8" in Safari and "TypeError: Illegal Invocation" in Chromium

Test Plan: Tests still pass

Reviewers: evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D1584
2015-06-01 15:21:40 -07:00
Ben Gotow 8e8eaf0f7d fix(focus): When composing a forward, focus on the To field.
Summary:
fix specs

This functionality used to work but `component` isn't defined and focus: was failing. Added specs to make sure this doesn't happen again.

Test Plan: Run new specs

Reviewers: evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D1583
2015-06-01 15:12:18 -07:00
Evan Morikawa 00fe3692e8 Fixes T1751: Make sure composer can't send twice
Summary:
Fixes T1751
Since there's time between clicking "send" and the draft appearing on the
TaskQueue (which is what we use to determine sending state declaratively)
it's possible for it to send twice.

I opted to use `setState` at the Composer View level since I don't think
we should debouce the Action or the Store. It's totally fine for a script
to queue a bunch of messages to send via the queue. We really just want to
stop it at the user intaction level.

Test Plan: There's a test for this now in the composer-spec

Reviewers: bengotow

Reviewed By: bengotow

Maniphest Tasks: T1751

Differential Revision: https://phab.nylas.com/D1576
2015-06-01 11:24:32 -04:00