Steve Howell
8cf6ef95b1
Extract reactions.view.insert_new_reaction().
2017-06-29 07:19:52 -04:00
Steve Howell
791e489938
Use a proper context in insert_new_reaction().
...
Before this change, we were piggybacking fields on to the event
object, which coupled us to any other function that relies on
the event.
2017-06-29 07:19:52 -04:00
Aditya Bansal
84b52661bb
compose.js: Remove small piece of dead code.
...
In this commit we remove a small piece of dead code from
check_stream_for_send() function and also rename it to
check_unsubscribed_stream_for_send() which makes more sense.
2017-06-28 07:45:21 -04:00
Aditya Bansal
89090cd3af
compose.js: Refactor validate_stream_message_address_info().
...
In this commit we just refactor validate_stream_message_address_info
function to early return in case of stream_data.is_subscribed()
returns true.
2017-06-28 07:45:21 -04:00
Aditya Bansal
eec9a9babb
compose.js: Export validate_stream_message_address_info().
2017-06-28 07:45:21 -04:00
Harshit Bansal
efa1cf6fb5
subs: Fix the traceback when an user subscribes/unsubscribes.
...
On receiving a `peer_add`/`peer_remove` event we were performing a
subscribers list re-rendering even when the stream settings form was
not open which was causing a traceback. This commit fixes this behavior
by first checking if the corresponding stream settings form is open and
performs a re-rendering only when it is open.
2017-06-27 16:23:00 -04:00
Joshua Pan
ac64ee355d
compose_actions.js: Allow compose to empty narrow.
...
This allows r/enter hotkeys to compose to
an empty narrow (no messages).
Fixes #4500 .
2017-06-27 14:06:59 -04:00
Joshua Pan
c4914eeec9
narrow.js: Create narrowed_by_stream_reply().
...
This function returns if you are narrowed
to a stream.
2017-06-27 14:06:59 -04:00
Yago González
9be3ff2b3f
composebox_typeahead: Remove unnecessary autocomplete_checks.
...
The validations that autocomplete_checks did were already managed by
tokenize_compose_str and the main "if" statements in
compose_content_begins_typeahead.
2017-06-26 19:33:25 -04:00
Yago González
c348b907e7
composebox_typeahead: Optimize token identification.
2017-06-26 19:33:25 -04:00
Yago González
67433691a9
templates: Fix typo in error message.
2017-06-26 19:33:25 -04:00
Aditya Bansal
411883365a
compose.js: Create initialize() function.
2017-06-26 15:55:10 -04:00
Yago González
5b0954c29d
node tests: Remove unreachable match case.
...
Since util.extract_pm_recipients() won't return a recipient if it's only
composed by whitespaces, considering such recipient in the matcher is
unnecessary.
2017-06-26 08:38:21 -04:00
Sampriti Panda
b2a1754f8a
drafts: Re-narrow on restoring draft.
...
Fixes #4587
2017-06-25 12:26:42 -04:00
Vishnu Ks
9fbd990d1a
tutorial.js: Narrow to PM with welcome-bot when user logins for first time.
2017-06-25 11:23:45 -04:00
Cory Lynch
090d7487cf
search_suggestion: Use person matching function from people.js.
...
Instead of having a custom (duplicate) matching function in
search suggestion, it was refactored to use the function in
people.js. This also gets the diacritic-ignoring feature
of the function in people.js.
Fixes #5315 .
2017-06-23 08:29:20 -04:00
Cory Lynch
46d224f021
people.js: Refactor to split out 'person_matches_query' function.
2017-06-23 08:29:20 -04:00
Harshit Bansal
6615f2f2e8
common.js: Migrate common.js module to use IIFE module style.
...
This module was exposing its functions as globals. This PR fixes
it use the IIFE module style that we use in our other modules.
2017-06-22 19:06:32 -04:00
digi0ps
f228700ef2
webpack: Migrate translations.js to use ES2015 syntax.
2017-06-22 16:43:33 -04:00
Harshit Bansal
0994726035
composebox_typeahead: Fix the behavior on inserting an emoji on new-line.
...
Autocompleting an emoji on a line was adding an extra space.
Fixes : #5516 .
2017-06-22 14:16:44 -04:00
Harshit Bansal
4912acf409
composebox_typeahead: Fix the autcomplete behavior while editing message.
...
On editing a multi-line message inserting an emoji or stream name,
the autocomplete was incorrectly sending the cursor to the the end
of the message.
Fixes : #5515 .
2017-06-22 14:16:44 -04:00
Abhijeet Kaur
534aa0b105
bots: Add a widget file to directly create bot from integration pages.
...
Add a widget file to create and subscribe bot to the stream user wishes
the incoming webhook services to send messages.
2017-06-22 11:07:30 -04:00
Vaida Plankyte
c52e964db3
frontend: Toggle aria-hidden for overlay container visibility.
2017-06-22 10:57:37 -04:00
Cory Lynch
df83cee86b
people.js: Ignore diacritics in search bar.
...
Fixes #5315
2017-06-21 19:13:44 -04:00
Yago González
e7bd18ec09
timerender: Make get_full_time produce a ISO 8601 date string.
...
Having get_full_time produce a date string non-compliant with RFC2822 or
ISO 8601 caused problems when showing edition timestamps on a message's
edit history.
Now it returns an ISO 8601 date string (1978-10-31T13:37:42Z).
2017-06-21 16:46:39 -04:00
Cynthia Lin
e832ebdc98
hotkeys: Add collapse/show message hotkey.
...
Fixes #4540
2017-06-21 15:54:09 -04:00
Cynthia Lin
a9afe43735
hotkeys: Add u hotkey for opening message sender profile.
...
Fixes #4873
2017-06-21 10:38:05 -04:00
Abhijeet Kaur
14fdc2aea6
bots: Add 'Bot type' column to bots list in organization settings.
2017-06-20 23:04:46 -04:00
Cory Lynch
c19be5e39e
Change conversation links to contain user's own email.
...
Fixes #2360 .
2017-06-20 21:22:45 -04:00
Cory Lynch
6d90d7ccbb
people.js: Ignore own email address in group PMs.
2017-06-20 21:22:45 -04:00
Cory Lynch
ff9498f85b
bookend: Hide re-subscribe button for private streams.
...
Fixes #5181
2017-06-20 20:56:26 -04:00
vaibhav
d9bc3932ec
settings: Move "download personal API key" from "your-bots" to "your account"
...
Fixes : #5355 .
2017-06-20 15:46:23 -04:00
Harshit Bansal
aee130bf06
subs: Fix the real-time sync when adding/removing the subscribers.
...
We were incorrectly amending the HTML directly whenever a subscriber
was added/removed. For updating any list which is being managed by
`list_rendering.js`, instead of modifying the HTML directly we should
just update the data in list render instance and perform a re-render.
Fixes : #4812 .
2017-06-20 15:44:20 -04:00
Harshit Bansal
e82a53117a
stream_edit.js: Add rerender_subscribers_list() function.
...
This function can be used for updating the subscribers list correctly
when a subscriber is added or removed.
2017-06-20 15:44:20 -04:00
Harshit Bansal
3f0ccd66c5
stream_edit.js: Extract get_email_for_subscribers() function.
...
This function can be used for mapping subscribers's id to their email.
2017-06-20 15:44:20 -04:00
vaibhav
9a6e326305
Add support for generating and downloading flaskbotrc.
...
Flaskbotrc is a file containing config of all active
outgoing webhook bots. It is used to provide configuration
of all active outgoing webhook bots to zulip-bot-server.
2017-06-20 09:43:45 -04:00
Cory Lynch
387f37c15e
popovers.js: Fix keyboard shortcuts with copying link.
...
Fixes #5374 .
2017-06-20 06:28:25 -04:00
Cory Lynch
d5bcfc415d
emoji_picker.js: Fix popover icon that persists after exit.
...
Another manifestation of #4329 , as this bug
also applied to the emoji popover.
2017-06-20 06:28:25 -04:00
Cory Lynch
801e4f6f6e
popovers.js: Fix chevron that persists when exiting.
...
Fixes #4329 .
2017-06-20 06:28:25 -04:00
Cory Lynch
55917b6761
message_store.js: Remove obsolete clear() function.
2017-06-20 06:24:27 -04:00
Vishnu Ks
9b16835c99
user_popover: Handle the case when user presence is unknown.
...
For bots and users who have not logged in for a long time the presence information is not known. For the these users make the presence indicator hidden.
2017-06-19 17:25:06 -04:00
vaibhav
33c0c00cd6
Outgoing webhook System: first Iteration of outgoing webhook UI.
2017-06-19 16:05:54 -04:00
Cory Lynch
6255636923
Support special characters for code block languages.
...
Fixes #5412
2017-06-19 06:53:25 -04:00
Cory Lynch
58a2ffbe1d
Add search suggestion support for is:unread.
2017-06-19 06:51:13 -04:00
Cory Lynch
86d3e00bd0
Add search support for is:unread.
...
Fixes #1423 .
2017-06-19 06:51:13 -04:00
Steve Howell
d7c0a7e1cb
Clean up settings_org.render_notifications_stream_ui.
...
The code now handles undefined stream_ids for realms that
don't have a notifications stream. It also removes unneeded
translation code on the stream name.
2017-06-16 08:47:42 -04:00
Steve Howell
081e0405dc
Avoid error in closest_id().
...
If we get a potential_idx that is not in items, we now just
warn about it instead of letting a type error happen.
2017-06-15 18:33:26 -04:00
Steve Howell
a9622b0e4f
Fix lint error from recent commit (error_data).
2017-06-15 17:47:44 -04:00
Steve Howell
1f34077fa1
minor: Add closest_id to blueslip error data.
2017-06-15 16:33:38 -04:00
Steve Howell
fe9020972a
Avoid type errors for bad PM narrows.
...
If somebody narrows to pm-with:bad_email@example.com , we no longer
generate a type error by trying to call addClass on undefined.
2017-06-15 15:52:42 -04:00