Commit Graph

17511 Commits

Author SHA1 Message Date
Steve Howell 37254c9031 Simplify ESC handling for modals.
Rather than checking every modal individually in hotkey.js for
handing the escape key, we now use the modals API:

    is_active: says whether any modal is open
    close_active: closes the active modal
2017-05-09 18:44:08 -07:00
Steve Howell 23b7be90c2 Fix console errors with closing settings.
We were mapping the escape key to fake-click a redundant
click handler when the settings pages were open.  This fix
lets the actual click handling work via modals.js, and it
lets keyboard handling directly calls modals.close_settings().
2017-05-09 18:44:08 -07:00
Tim Abbott bd3e338c35 templates: Fix URL coverage for new files. 2017-05-09 18:42:24 -07:00
Tim Abbott fc24a56fc5 test_docs: Fix expected text in /hello page. 2017-05-09 17:23:38 -07:00
Tim Abbott df6dba9673 test_home: Fix expected text in /hello page. 2017-05-09 16:59:33 -07:00
Brock Whittaker 3fd3ae4199 Restyle /hello/ page.
This restyles the /hello/ page to be the new portico branding.
2017-05-09 16:31:57 -07:00
Brock Whittaker a82a0d16d5 Add landing page assets.
This adds the required logos and other assets for the /hello/ page.
2017-05-09 15:26:45 -07:00
Tim Abbott 484adf1461 about: Update words of developer documentation. 2017-05-09 15:04:17 -07:00
Tim Abbott 6dd85a78ce about: Update to have slightly more current numbers. 2017-05-09 15:03:30 -07:00
Tim Abbott 937dcdde59 docs: Update which projects are marked complete in roadmap.
We need to do a more significant update soon, but this will at least
make things passable for now.
2017-05-09 14:34:53 -07:00
Tim Abbott 68be0edc67 Update changelog since the Zulip 1.5 release.
It's amazing how much we've done in the last few months.
2017-05-09 14:02:24 -07:00
Tim Abbott 2d97db3518 streams: Add endpoint for modifying properties of a single stream.
This is likely to be the more common endpoint for API clients like the
mobile apps to interact with when modifying streams.
2017-05-09 13:42:34 -07:00
kunall17 e087bc24f8 streams: Migrate stream property changes to new REST endpoint.
This is one of the last major endpoints that were still done in the
pre-REST style.

While we're at it, we change the endpoint to expect a stream ID, not a
stream name.
2017-05-09 13:39:23 -07:00
Rishi Gupta a75af36039 stats: Change sort order of client labels to match default view. 2017-05-09 11:32:35 -07:00
Rishi Gupta ee16abaf3b analytics: Fix sort function in views.sort_client_labels.
sort_client_labels sorts first by total, and then to ensure deterministic
outcomes, sorts (reverse) alphabetically by label.

Fixes regression introduced in 0c0e539.
2017-05-09 11:32:35 -07:00
Rohitt Vashishtha 0414ac6df5 bugdown: Convert GitHub image-preview urls to image urls.
This makes inline image previews work for links to image files' pages
on GitHub.

Fixes #4658.
2017-05-09 11:22:37 -07:00
Rohitt Vashishtha 5be7494ddf Remove duplicate connection-error message.
There's really no need for a separate user-visible error message for
get_messages vs. get_events.

Fixes #4703.
2017-05-09 11:13:27 -07:00
Steve Howell 94b7058743 Make local_echo an official feature.
This commit removes all references to feature_flags.local_echo.
It's been a core feature for about four years, so I think we
can safely say the experiment was successful.:)
2017-05-09 11:06:10 -07:00
Steve Howell 0a0f567aeb Split out markdown.js from echo.js.
The new module handles markdown rendering.

The code left behind in echo.js does local-echo kind of things
like reifying message ids.
2017-05-09 11:06:10 -07:00
Tomasz Kolek 61d5d41067 Add Slack importer bot. 2017-05-09 10:48:08 -07:00
Mahim Goyal 49fec57768 Add hotkey for narrowing to next unread topic.
Fixes: #4199.
2017-05-09 10:02:54 -07:00
Tim Abbott 40e43d8cba narrow: Remove unused by_conversation_and_time and by_id helpers.
Now that we just copy links to the clipboard, neither of these are
used.  (Actually, the narrow.by_id helper has been dead code for
years).
2017-05-09 09:59:37 -07:00
Mahim Goyal a2adcfd7fc popovers: Add direct copy to clipboard link feature.
Change the onClick function of copy link of
conversation to actually copy the link to clipboard.

Fixes: #4621.
2017-05-09 09:59:23 -07:00
Mahim Goyal 6fe0728afa Return absolute URL from narrow.by_conversation_and_time_uri 2017-05-09 09:55:38 -07:00
Umair Khan 4971b7ff9f testing: Add errored tests to failed tests list.
Fixes: #4716.
2017-05-09 09:36:59 -07:00
Steve Howell 70d4ac93ce Add modals.info_overlay_open().
This also removes ui_state.js, since its last function
is now replaced by modals.info_overlay_open().
2017-05-09 09:19:27 -07:00
rht 00e057bf44 install-node: bypass nvm wrapper for faster node startup.
This fixes a significant performance issue with LaTeX rendering (and
other things that invoked node) where starting up node took a few
hundred milliseconds due to nvm initialization.

Tweaked by tabbott to avoid copying the node binary itself, instead
using a tiny wrapper script.

This is important primarily because it's possible a future version of
node will expect to find libraries/dependencies/etc. installed via NVM
at some path related to the path of the node binary itself, and that's
more guaranteed with this new model.

Fixes #4618.
2017-05-09 09:17:54 -07:00
Steve Howell 86a9283471 Update JS dependency configuration. 2017-05-08 22:04:56 -07:00
Steve Howell 742c55f514 Speed up key handling by adding modals.is_active().
The function modals.is_active() can see if modals are open
without having to look at the DOM.  This should make it snappier
to type in the compose box.  Even if the speedup is pretty minor,
not having to worry about jQuery slowness should make it easier
to diagnose future compose box issues.

The new function gets used in other places, too, where performance
isn't so much an issue.
2017-05-08 22:04:56 -07:00
Steve Howell 3c0ef6295f Enforce that only one modal can be open at any time. 2017-05-08 22:04:56 -07:00
Steve Howell ddded59a6d Remove modals.set_close_handler(). 2017-05-08 22:04:56 -07:00
Steve Howell 07248ee7bd Use modal.open_overlay() for info overlays. 2017-05-08 22:04:56 -07:00
Steve Howell 4bcb4d6c15 Use modal.open_overlay() in subs.js. 2017-05-08 22:04:56 -07:00
Steve Howell 0965fc5a05 Use modal.open_overlay() in settings/admin. 2017-05-08 22:04:56 -07:00
Steve Howell b82a802c22 Use modal.open_overlay() in lightbox.js. 2017-05-08 22:04:56 -07:00
Steve Howell 02c743853c Use modal.open_overlay() in invite.js. 2017-05-08 22:04:56 -07:00
Steve Howell 6d1a6934b8 Use modal.open_overlay() in drafts.js. 2017-05-08 22:04:56 -07:00
Steve Howell 09a37ec179 Add modals.open_overlay(). 2017-05-08 22:04:56 -07:00
Steve Howell 2f6edf47bc Fix code format of modals.js.
Our de facto coding standard for JS modules is not indent
within the boilerplate, and we assign functions to `exports`
in single JS statements.
2017-05-08 22:04:56 -07:00
Tim Abbott 9da63bc087 ui: Initialize settings_sections before hashchange.
This is important, since settings_sections must be initialized in
order to load the page with a hash in the settings UI.
2017-05-08 22:02:56 -07:00
Mahim Goyal 6464514ca9 Break compose.js and drafts.js dependency. 2017-05-08 14:43:49 -07:00
Steve Howell b609911656 Remove unused get_user_profile_by_email() imports. 2017-05-08 11:57:38 -07:00
Steve Howell 3b2a3601c1 tests: Add ZulipTestCase.notification_bot(). 2017-05-08 11:57:38 -07:00
Steve Howell 3a031f6814 test: Use example_user() in more places.
This commit replaces calls to get_user_profile_by_email() with
calls to self.example_user() by introducing a local variable.
2017-05-08 11:57:38 -07:00
Steve Howell 7f9057ba99 tests: Use example_user() in more places. 2017-05-08 11:57:38 -07:00
Steve Howell 6bc8424c71 Use self.example_user() in more places.
This fixes most cases where we were assigning a user to
the var email and then calling get_user_profile_by_email with
that var.

(This was fixed mostly with a script.)
2017-05-08 11:57:38 -07:00
Steve Howell 942db9b6c5 tests: Added ZulipTestCase.example_user() function.
The example_user() function is specifically designed for
AARON, hamlet, cordelia, and friends, and it allows a concise
way of using their built-in user profiles. Eventually, the
widespread use of example_user() should help us with refactorings
such as moving the tests users out of the "zulip.com" realm
and deprecating get_user_profile_by_email.
2017-05-08 11:57:38 -07:00
Mahim Goyal a44a291cdf Don't open compose when clicking links containing search terms.
Link that is a search term opens compose box, add this exception to
the is_clickable_message_element.

Fixes: #4651.
2017-05-08 11:39:00 -07:00
Tim Abbott abd09cebb2 git tools: Make error messages more clear. 2017-05-08 10:51:59 -07:00
derAnfaenger d63fdf5bc6 Fix Twitter bot breaking layout with long words/links.
Long words and links now get automatically broken down in the
'twitter-tweet' div; prevents a message box overflow.

Fixes #4659.
2017-05-08 09:56:35 -07:00