Commit Graph

1282 Commits

Author SHA1 Message Date
Steve Howell 8d81ea33da Have pick_empty_narrow_banner() use operator/operand.
This is part of phasing out the internal tuple representation.

(imported from commit aa8788efbdc0f8d08d99bae154f68a3b60272c65)
2014-02-10 13:23:26 -05:00
Leo Franchi 1c332f5d6a Standardize on 'subscription' as event type name for subscription changes
Our overall guideline is the type names for events are singular, and the list of
events of that type are plural. 'subscriptions' was not following this guideline
and (potentially as a result) had a bug where it was impossible for clients to explicitly
subscribe to subscription change events properly.

(imported from commit 7b3162141fd673746e0489199966c29ea32ee876)
2014-02-06 17:07:38 -05:00
Jason Michalski f1e110c177 Empty large collections and remove event listeners before reload
Chrome was showing a memory leak after many auto-reloads. Emptying the
the collections and removing the event listeners reduces the severity.
Before this change 40 reloads would would grow to about 140MB, now it
stays around 50MB.

(imported from commit 55fbeff9bdd0363bb95929f2981a2de238ff35d8)
2014-02-06 16:42:38 -05:00
Steve Howell fc78a2cc66 Stop using tuples in search_suggestions.js and Filter.unparse().
This is yet another change related to phasing out the
[operator, operand] tuple data structure for representing
terms in a narrow.

(imported from commit 508e58fc4eebae8a24a8ae59919ba5d94fc66850)
2014-02-06 16:42:38 -05:00
Steve Howell 90f6eb0661 Keep track of subs by stream_id inside of stream_data.js.
The JS code can now call stream_data.get_sub_by_id() to get
a sub from a stream_id.  Subs have stream_id due to a prior commit,
and we keep track of the mapping in stream_data's subs_by_stream_id
variable.

(imported from commit 409e13d6d2e79d909441a66c85ee651529d15cd2)
2014-02-06 12:09:52 -05:00
Steve Howell 3a96686cbc Add stream_id to page_params.{subscriptions,unsubscribed}
This isn't used by the client yet, but it should be harmless.

(imported from commit e09ac65ca802f5cf16375b8a93d34e0dfbcb76b4)
2014-02-06 12:09:52 -05:00
Steve Howell 07e337ff8a Simplify calling mark_(un)subscribed in server_events.js
(imported from commit a5faae42642c5d2c2410021bb33917827577d9a2)
2014-02-06 12:09:52 -05:00
Steve Howell 583dae72a3 Change how the tutorial overrides the default stream color.
The tutorial introduces "engineering" messages that might not
be in the user's normal subscription, and they would get a gray
border if we did not override the stream color.  Before this change,
we accomplished this by overriding the core data structure in
stream_data.js.  Now we are a bit more future-proof; we only
override stream_color.default_color.

(imported from commit 0d0845b72f766912679f5aa7641ae9a60fdbb4ce)
2014-02-06 12:09:51 -05:00
Steve Howell dbcc406272 Fix blueslip warning for stream email_address updates.
(imported from commit 6cc105113072eadff3781bdbf9e08e43974ade4c)
2014-02-06 12:09:51 -05:00
Tim Abbott 02d69f18ac Clean up codepath for selecting a message on unnarrowing.
This does have a small functional change of using use_closest even for
the current_msg_list.last().id case, but that's harmless; and it does
reduce a lot of code duplication and confusing logic here.

(imported from commit 7c4ecaa197120cc6d5c05ce4887f33c7d94a9c59)
2014-02-06 10:25:35 -05:00
Tim Abbott 1bd9e5809c Restore the browser's scroll position on server-initiated reload.
(imported from commit 934659c0f1a2c014cfd2811fe49ea31abad262b2)
2014-02-06 10:25:35 -05:00
Leo Franchi d961829355 Tell the desktop app the source of a desktop notification
(imported from commit ed697d50e35589a61746ad66bff5ae50becead77)
2014-02-05 12:02:27 -05:00
Jason Michalski 515e64175f Add extra logging when the selected row can not be found in the cache
The leading theories this will test are:

1) MessageList._items becomes unsorted and the binary search starts
returning the wrong index from selected_idx.

2) MessageListView.render is not rendering the message or it is not
being inserted into the cache.

(imported from commit 926b7d7bf9df338320a8cba6241038176ce4b47d)
2014-02-05 10:27:33 -05:00
Jason Michalski 0dd61e9222 Blueslip has a warn not warning function
(imported from commit 1f18331cac451c62a089f042b316278030c41965)
2014-02-04 23:08:19 -05:00
Jessica McKellar a32b326ff2 Make tutorial respond to window resize events.
(imported from commit 4d7af1df04db8e2ef344e4c8e572d1a702309f73)
2014-02-04 15:51:53 -05:00
Steve Howell 9c48ba43fb Do not return terms as tuples in hashchange.parse_narrow.
(imported from commit ffc4acacdd220de57e0179c9dc8272e6b5c33457)
2014-02-04 13:16:34 -05:00
Steve Howell 7fb7950f70 Support non-tuple operators in hashchange.operators_to_hash().
(imported from commit e002293c586d4ef754612feee2b7f33215cf305f)
2014-02-04 13:16:28 -05:00
Steve Howell 89ea079dce Allow Filter to accept non-tuple-based terms.
We make this happen inside of canonicalize_term.

(imported from commit 0571f6cac8ffdc806af56423cc98134c7493139e)
2014-02-04 13:16:25 -05:00
Steve Howell 112bc5ceda Rename canonicalize_tuple to canonicalize_term.
(imported from commit 07e0c4a6802b0d4b4fbb8ffd3965cab6457d4aeb)
2014-02-04 13:16:25 -05:00
Steve Howell 889adfa0e0 Have filter_term accept an object, not a tuple.
This is more phasing out of tuples for narrowing.

(imported from commit 7c8b801e807053f60bee5086df6acb70b852a79c)
2014-02-04 13:16:24 -05:00
Steve Howell eea8c0d1d5 Allow admins to change the realm's name in the UI.
(imported from commit 2873f872069a41c91beb87728f64fa526dd8a326)
2014-02-04 11:33:19 -05:00
Steve Howell 8266ac3cf9 Extract notifications.redraw_title().
This sets us up to redraw the window title without having to
pass in the unread count, which will be useful for realm name
changes.  The redraw_title() function is only responsible for
rendering stuff, whereas update_title_count() handles
the details of caching the count.

(imported from commit 67cfb7a273e2a61720ce2bd8d91d73fe1089c813)
2014-02-04 11:33:18 -05:00
Leo Franchi 9f8e57a1cd Catch exceptions when saving to local storage, as disk may be full or quota may be up
(imported from commit 5707228b89badd766527a4fdf77d4b7a7552447b)
2014-02-03 17:50:30 -05:00
Leo Franchi e8d4723d44 Enable local echo for hacker school realms
(imported from commit cd34b326f94be5fdf5ec93a0e5302b880f16e78c)
2014-02-03 16:57:36 -05:00
Jason Michalski 0e1909f489 Prevent errors in get_updates_success from stopping the event loop
Add try/catch blocks to get_updates_success and send a blueslip error on
errors we catch. This will let get_updates_success return successfully
so that the next call to get_updates will start immediately.

(imported from commit 44d8b85d9d8e930a5552a5fbf4af1d0e5e8c07e8)
2014-02-03 15:28:27 -05:00
Jason Michalski a4ff866571 Add support to blueslip.error to report an existing stack
(imported from commit 864b6b066a7870d2a435f50c6154f4bf3e3c5a12)
2014-02-02 00:47:50 -05:00
Tim Abbott 84e2c2b9da Use stored.messages[id] rather than exports.get inside message_store module.
(imported from commit 83ae3f364083da4d5d26f26a941440c1925d4b62)
2014-02-03 13:32:02 -05:00
Tim Abbott 9107c67d88 Rename msg_metadata_cache to stored_messages.
(imported from commit 3b32fb8b4f46eb6f09232e8b251feb2874a0e01e)
2014-02-03 13:32:02 -05:00
Tim Abbott 8c733fde8f Use message_store rather than all_msg_list to get messages by id.
There are 2 uses of all_msg_list previous to this commit:

(1) The contiguous block of messages to be used for constructing the
initial state of narrows.

(2) A way to look up an arbitrary message by ID that may or may not be
in the home view to check if we have it locally.

We eliminate all applications of use case (2), replacing them with
queries on message_store, since they are in fact wrong -- any messages
that are outside the contiguous time period of all_msg_list would not
appear in all_msg_list and thus would incorrectly not be returned.

(imported from commit e2e2efe919242331bbc44abc6c50b16e3ab1336e)
2014-02-03 13:32:02 -05:00
Tim Abbott 30056197a6 Move report_as_received to compose.js.
(imported from commit 29a309aa0597f17d82277901bcf5d38c680c9b94)
2014-02-03 13:32:02 -05:00
Tim Abbott 7e6bb801e2 Move message_range to a function on the message list.
(imported from commit c78710a3ccddb15352086b450fb6986e1251f364)
2014-02-03 13:32:02 -05:00
Tim Abbott 0b12681558 Export message_store.get() for getting message objects.
(imported from commit d7d20bf3aab62a1b407709b1c0bf947b3ad8bee8)
2014-02-03 13:32:02 -05:00
Tim Abbott f26af47fb6 Center on-page-load narrows on first unread message.
This implementation is somewhat hackish in large part because I think
we're going to be wanting to redo the get_old_messages API somewhat
soon, and this may naturally become a lot cleaner as a result, but
this isn't a lot of code and fixes #2235 part (A) and substantially
mitigates #1510.

(imported from commit 47a2160a44befa9d83190c5cc95b90e92cc5b4cc)
2014-02-03 13:32:02 -05:00
Steve Howell 259f6123e6 Move "Customize avatar" button below "Save changes" on settings page.
The old layout was misleading, because users would make the perfectly
reasonable assumption that their avatar change wouldn't be made until
they hit the Save button.  Moving the avatar stuff below the Save button
makes the UI clear and also unclutters the form for updating name and
password.

(imported from commit 9154ba69a2d61844701c88c2afdf399532ccddd9)
2014-02-03 13:29:28 -05:00
Leo Franchi be115a2914 [localecho] Properly account for an empty message list and empty db
(imported from commit faac1644cb81bc53f43de8c6f830a0145c8c7ca5)
2014-02-03 13:15:42 -05:00
Leo Franchi 0a9f54369a Disable desktop-app emoji handler. It breaks copying of formatted text
(imported from commit 14c9ee7ba61d4913da2d2e8c677739b573252525)
2014-02-03 13:07:43 -05:00
Leo Franchi f8a9f36dfa Don't use our copy handler when editing a message
(imported from commit 49e7001d8aa9af4f482b62332da03faad784074f)
2014-02-03 13:07:42 -05:00
Leo Franchi bb21400732 [localecho] Properly escape HTML in code blocks
(imported from commit 11f7e4f440cdd3a2ef6debb10c3d5a07f4fd1a1a)
2014-02-03 12:57:54 -05:00
Leo Franchi c8f134370b Provide a valid local id when a fresh database with no messages is used
(imported from commit dafff9d4800a643693b57e92b7a02171c466333b)
2014-02-03 10:35:25 -05:00
Jason Michalski bb0784d9aa Remove tags from selectors to conform to the style guide
(imported from commit 14233e3ec8ca72cae6baa5fcb4e4068bd1524823)
2014-02-01 20:29:15 -05:00
Jason Michalski 80d2ecdd1e Enable custom copy handler when selection starts on a stream header
When users select messages starting with stream header we should format
the text as using the custom copy handler.

(imported from commit 4f9851939484d046619c3e53c71c47ad64797670)
2014-02-01 20:29:15 -05:00
Steve Howell 20cfb9fe84 Remove unused in_realm var in people.add()
(imported from commit af827e29b03492c671c1f05df9bb3280fde0ad4e)
2014-02-03 10:16:17 -05:00
Tim Abbott 4b30afbb27 Fix display of unread counts.
I apparently screwed up when backing up the process_loaded_for_unread
move in a way that just lost the function.

(imported from commit 91dfcf1abc85d439274cb8b0be380e9230942ebb)
2014-01-31 17:53:11 -05:00
Jessica McKellar 1c5110dbad Send you a registration email if you try to sign up for an existing realm.
(imported from commit 9104096b424f31a22ee7c8b72378f05309bb978b)
2014-01-31 16:40:19 -05:00
Jessica McKellar 7c788c1a17 signup: point to /register at the top too.
The message to use /register if your group is already signed up is
below the fold on my laptop -- this probably contributes to people
trying to sign up their group when they are just trying to register.

(imported from commit 517df29d10182c05780017c15225c9f95b844225)
2014-01-31 16:40:19 -05:00
Tim Abbott 88fbd5d16a Split out new module message_store.js.
(imported from commit 57cf3f2b8e74d7c56e3baf75859d5b3646282225)
2014-01-31 15:57:28 -05:00
Tim Abbott f5d3a6ddc7 Move suppress_unread_counts to unread.js.
(imported from commit fb64edc27b661d036c9f24715aeb3b4dbdf9463a)
2014-01-31 15:57:28 -05:00
Tim Abbott 004fd0eab8 Move unread-related functions from zulip.js to unread.js.
(imported from commit efc0dd84c2cd30b0203b906af6991475d8a63985)
2014-01-31 14:59:03 -05:00
Tim Abbott c8d57fcafb Split out message_flags.js.
(imported from commit 52afa76fa71141630e325e558cb9c6955d8c03d5)
2014-01-31 14:59:03 -05:00
Tim Abbott 55a88f049c Remove unused within_viewport.
(imported from commit d528e022a0d088052bb0bac5c29864688dae59ca)
2014-01-31 14:59:03 -05:00
Jessica McKellar ec88b3abaf Give admins the ability to unsubscribe people from streams.
(imported from commit 7ec130a233a2976ad0be6f8a7b59c33ce0e0cf3f)
2014-01-31 11:23:14 -05:00
Jessica McKellar c4c5ac210e Convert stream member list to a handlebars template.
We had been concatenating strings.

(imported from commit 2d50d3f750a450029d39553ea9cd99ef824a149b)
2014-01-31 11:23:13 -05:00
Tim Abbott 6e5e5596fd Remove deferred installation of scroll handler.
This is no longer required, now that we're no longer scrolling the
main body of the page.

(imported from commit c2aa0d403c8fd0679b3110fe8e7684d46a7557fa)
2014-01-31 11:15:14 -05:00
Leo Franchi 2fac412119 Get next local id correctly when all message list is empty
(imported from commit 07208222ea682251927ef13c684e9e89277233bf)
2014-01-30 18:08:48 -05:00
Leo Franchi 01e948ac97 Allow unnarrowing to an empty message list in unread-messages-read case
(imported from commit f377dbce61fe2fc2051bc286f7215e8112f92736)
2014-01-30 18:08:48 -05:00
Leo Franchi 1056078415 Truncate local ids when loading older messages if messages could be local only
(imported from commit b32ae8f3554632aa84ed2dd039a612bb0fa644e2)
2014-01-30 18:08:48 -05:00
Tim Abbott e505583f52 Split out new module people.js for tracking people.
(imported from commit fb9b769819ade25d1d3d6e452e68c7ee8651cfdd)
2014-01-30 17:32:58 -05:00
Tim Abbott d0ae8795c3 Clean up obsolete fields in get_events_params.
Both pointer and last are fields that were removed when we changed the
protocol to use events like a year ago.

This conveniently allows us to stop exporting get_updates_params to
other modules.

(imported from commit 13651ee240ce6e1bafb241b185e5ef653c348cdf)
2014-01-30 17:23:53 -05:00
Tim Abbott 2fb9baafb4 Start running get_events immediately on page load.
Previously, we waited until we'd fully loaded the home view to start
calling get_events, which:
(A) didn't make sense non-message related events
(B) resulted in our throwing "get_updates not started" errors when
users sent a message before the home view was fully loaded.

This commit only fixes problem (B); to fix problem (A) we will need to
change the event capture code to only capture some events.

(imported from commit 2aacd6bdfd1e7d7707e3a724f1fde7da4a556538)
2014-01-30 17:23:53 -05:00
Tim Abbott f27edcd50a Move initial call to get_events to server_events.home_view_loaded.
Note that this makes the event fire after the home view has messages
loaded all the way to current; previously it only waited for the first
batch of messages to load.

(imported from commit a5c408ea0136c761f4cc77e8be4977b13acc6d77)
2014-01-30 17:23:52 -05:00
Tim Abbott 1eb294ed11 Rename get_updates to get_events in the frontend.
We did this rename on the backend ages ago.

(imported from commit 11bdf6aa08d932fe2586de282f6174e3dba7267a)
2014-01-30 17:23:52 -05:00
Steve Howell e60f148a3e Clean up double negatives in message_matches_search_term
(imported from commit 677bb3a76d3404f9899498777e7f1169947422c7)
2014-01-30 17:19:50 -05:00
Steve Howell 189743e813 Extract message_matches_search_term in filter.js.
This diff really just moves code; it's a trivial function extraction.

(imported from commit 8ff82b089e49645a6c6034152a9fc9cd83da0737)
2014-01-30 16:46:51 -05:00
Steve Howell 3a412b35e1 Use _.all() in Filter._build_predicate.
By using _.all() instead of a for loop, we avoid a tiny bit of
confusing between "break" being for a switch statement and being for
the loop.

(imported from commit cd6e7ff788b50f4dadce93e7f0efcb381bc59270)
2014-01-30 16:45:47 -05:00
Steve Howell 15b0f9dcc7 Use operator/operand in narrow.collect_single().
(This is part of converting away from tuples.)

(imported from commit ba3083f8b3242fee1d532d7666aee68af89d8ddc)
2014-01-30 16:15:16 -05:00
Steve Howell 796ebfd007 Do not return raw operators from narrow.operators().
Even in the case where we are running embedded narrows,
we want narrow.operators() to return new-style operators
that you get with Filter objects, so that callees do
not need to support the legacy tuple format.

(imported from commit a6649881a926a2304e9f7cc8ca53b406e2c8828e)
2014-01-30 16:15:14 -05:00
Steve Howell de7708ed6e Handle id:<msg id> searches with multiple terms.
If you do a search like id:5 topic:foo and message #5
does not have the topic "foo", we now return zero results.

(imported from commit 8121fac1dbd79024c51af1f310d831dab9242e36)
2014-01-30 15:57:32 -05:00
Zev Benjamin a2d989b318 Fix typo
(imported from commit dc7ef302a70291063c3ef339f72b6a91e8129dc1)
2014-01-30 15:57:32 -05:00
Zev Benjamin 50e1cb7ab3 socket: Specify reasons everywhere we close the SockJS object
(imported from commit 7314fa975b9408caba2c5f1374c8259d67784ad0)
2014-01-30 15:57:32 -05:00
Zev Benjamin 3df1097c95 socket: Wrap module in an anonymous function call
This is so we can have some class variables.

(imported from commit 6311444bb2739daebc6c5da2b7ea7eabdd88689d)
2014-01-30 15:57:31 -05:00
Zev Benjamin 9020f37141 socket: Add comment about the close() call in _try_to_reconnect()
(imported from commit 87e32adcb9eeb066b6f3ecd85550d00263e0a4e9)
2014-01-30 15:57:30 -05:00
Zev Benjamin b8444daddd socket: Pass wait_time as an option to _try_to_reconnect
(imported from commit 15a88c6da084f4834258868bc08b2cd983899820)
2014-01-30 15:57:29 -05:00
Zev Benjamin 1ed176b5ef socket: Log the reason the SockJS connection was lost
(imported from commit 069067f9f979e7255f97f4943d6513076b2706bd)
2014-01-30 15:57:29 -05:00
Steve Howell b3a551f402 Stop using raw operators in narrow.activate().
Have narrow.activate() user filter.operators() to produce
operators that have operand/operator fields, so that its callees
don't need to be backward compatible with the tuple format.

(imported from commit e408e33074d1be2d112bb3cdc081ec3616c908ee)
2014-01-30 15:57:28 -05:00
Tim Abbott a7b1b29bf0 Move get_updates into a module.
(imported from commit 9a6c0ab1e76dd96abad8626bc5b1fdbd234b2645)
2014-01-30 15:57:28 -05:00
Tim Abbott 33690d1dc6 Clean up argument to get_updates_success.
(imported from commit 2583c79f83e1e3e540a00ba8afae5a07dff70845)
2014-01-30 15:57:28 -05:00
Jason Michalski 90995889fc Fix scroll when muting and unmuting streams
(imported from commit 9bd22cd12dfa50cf8fd9d87eb659a4543c5c78c4)
2014-01-30 01:48:15 -05:00
Jason Michalski bf57839e85 Remove scrollTop workaround for hash changes
Now that we are not scrolling the document we can remove the workaround
to prevent browsers from scrolling on hash changes.

(imported from commit 67fdaa4980d4d54d80ca9c259bbee567b8eeb917)
2014-01-30 01:48:15 -05:00
Jason Michalski 21c2aea755 Fix scroll position on narrow and unnarrow
Change the offset to hold of the selected message as an offset from the
top of the screen. Then use the current offset and scrollTop to compute
the new scrollTop.

(imported from commit 718e95d3435c0f84cbb7663a9bb2bc2789314203)
2014-01-30 01:48:15 -05:00
Jason Michalski b0c5e2dbd0 Fix scroll on opening subscriptions details
Move the animated scroll from body to the app div.

(imported from commit 2d2062d7a917616a60f414a633dd2f827ae840a0)
2014-01-30 01:48:15 -05:00
Jason Michalski 9cc1dc242c Move the mouse handlers from window to app
(imported from commit 0331496a578c47f73b6c9e81d8a79e26e8d7a9a3)
2014-01-30 01:48:15 -05:00
Jason Michalski 198648447f Change viewport to use the app div not the document for size
Now that we are scrolling the app we should have viewport respect this
CSS change.

(imported from commit dec5450563a6f5ac23499819ec382030e3a910dc)
2014-01-30 01:48:15 -05:00
Allen Rabinovich dedd3cf03c Overflow scroll on app instead of body
(imported from commit 2be63b16afe212e95e983745eaa0bc5dc8e1397e)
2014-01-30 01:48:15 -05:00
Steve Howell 967d3c9c65 Use .operator to get operator for mixpanel.
(imported from commit 7c70a592b2efd769acab9b178c08a345785b889b)
2014-01-30 13:24:43 -05:00
Steve Howell 53027b71a4 Use operator/operand inside the Filter instance methods.
Avoid tuples in the methods inside Filter.prototype.

(imported from commit beed799e767d9645735a2bd4eefb5d431c04f17f)
2014-01-30 12:53:08 -05:00
Steve Howell b18307b667 Start using operator/operands internally in Filter class.
By having Filter.canonicalize_tuple() call filter_term(),
we make it so that Filter objects get operator/operand
fields in their terms when we initialize this.

This mostly caused test breakage for tests that were doing
assert.deepEqual; now we just check to make sure that the
field we need are there.

(imported from commit 63b2516dc72edeb11e76a1fa4442570b9c605baa)
2014-01-30 12:53:08 -05:00
Steve Howell 12626ead66 Populate terms with named fields in filter_term().
Consumers of Filter.parse() can now reference
search term parts like so: term.operand, term.operator

(Legacy code can still use term[0] and term[1].)

(imported from commit 06d0da65f13f1eb7e3ba8eac0e69448aab2735ab)
2014-01-30 12:53:08 -05:00
Steve Howell fdd57f5abe Extract filter_term() in filter.js
(imported from commit 142464bb02817108726f9c118459c38e55b96bbf)
2014-01-30 12:53:07 -05:00
Tim Abbott abbe0f781f Don't wait 1 second before syncing updates manually controlled flags.
(imported from commit 8526f5d77aee078b5bc282da093009e19f016a44)
2014-01-30 12:48:36 -05:00
Tim Abbott 20457d695d Fix starring/unstarring of messages.
This got broken in the local echo refactoring -- we accidentally
switched the update_starred function to be a toggle, which meant that
the message would be marked as starred and then unmarked as starred
moments later, due to the two update_starred calls for the initiating
browser (one from when the click happens, the second from when the
event returns from the server).

(imported from commit 8f83729fe5477cf052124c1c56ed9189b85b885c)
2014-01-30 12:48:36 -05:00
Jessica McKellar 7085dca1ce Fix the Admin page not working for newly-knighted users.
Previously, while you'd get the event saying you'd been knighted,
which would make the Administration tab visible, clicking on the tab
would error out because the admin page HTML was never sent over on
page load (since you weren't an admin at that point).

(imported from commit 90ad351533515bebece630d67baf4b142d320754)
2014-01-29 12:41:22 -05:00
Jessica McKellar 3d234e1b84 Update admin page language on deleting streams.
(imported from commit 3670c65e3fe9e79855b1c0ffaa08f48368de9856)
2014-01-29 12:41:21 -05:00
Jessica McKellar 20f2baa614 admin: Show a lock icon next to private streams.
(imported from commit 26829016cf219b55aef0ef45187667b0a9bd86fd)
2014-01-29 12:41:21 -05:00
Leo Franchi e716a75d22 Properly render at-all and at-everyone mentions locally
(imported from commit 9533b83dba6a61f6c09da755fca54e8a24ad61e6)
2014-01-28 17:37:10 -05:00
Leo Franchi 1666403850 Find message objects in any lists when updating, as update might come from server
(imported from commit fa70180c9a228bff39efd846d465d0f1fa9bb4e7)
2014-01-28 17:31:02 -05:00
Jason Michalski c573efd437 Ignore stream description update events for unknown streams
Clients can receive description updates for streams which are not in
stream_data. We should ignore the updates and warn that this has
occurred.

(imported from commit 3cd5a98a133012ae27ea0f43b03cc9d8e459e49c)
2014-01-28 17:12:15 -05:00
Leo Franchi 91fb4f6b8c Fix clicking on link to message when sending outside this narrow
(imported from commit 6eeeb3b4c06021be21f48c8c5f2869904cd13b09)
2014-01-28 16:03:11 -05:00
Leo Franchi ffb816391c Use our own fenced code preprocessor, fixing output mismatches
(imported from commit 3d4abb1043349e30adf265342ee7c946a99b3ce2)
2014-01-28 15:35:32 -05:00
Leo Franchi 420a7cab7a [marked] Add preprocessors in marked and allow them to insert arbitrary HTML
(imported from commit 367418266f4fbe2d723212845f49f0d4356fab52)
2014-01-28 15:35:32 -05:00
Leo Franchi daecc7993a Add a fenced code parser in javascript
(imported from commit 42b1dc18ca34cbbdf3cda6e833adde631a9d88f5)
2014-01-28 15:35:32 -05:00
Leo Franchi dd7d31c7a6 Allow an empty home view when unnarrowing
(imported from commit 69f1a84b23ae8942db58851a1a1c6723c26df560)
2014-01-28 15:35:31 -05:00
Leo Franchi dc3c6f34fc Convert python-regex inline flag style to JS regex flags
(imported from commit 16c58fa54c0b87931d873290b175461ceb176d62)
2014-01-27 12:30:42 -05:00
Leo Franchi b83be2cd32 Properly avoid realm filter work in non-local-echo case
(imported from commit 9c01109e6900509690841306fb4a23464321de61)
2014-01-27 12:30:42 -05:00
Leo Franchi 1fdb586c13 Make sure then_select_id is a number to call .toFixed()
(imported from commit 58635110c737ccb38e74cce8b4feb5d93dfbf5cc)
2014-01-27 12:30:42 -05:00
Leo Franchi a82bc689e8 Render /me message on the frontend
(imported from commit ce4a44624b7084464d5c6ce8e04eef03ee23c9e3)
2014-01-27 12:30:42 -05:00
Leo Franchi 883157893c Use a UserMessage flag to indicate /me messages
(imported from commit ea503b0d3eb6e90230c0859be96ede60faf5c2bd)
2014-01-27 12:07:48 -05:00
Leo Franchi b119bf74ca [third] Update marked.js to HEAD to pull in javascript escape fixes
(imported from commit f673746c7f2d424c56b3e0b5d028952f97fb2a57)
2014-01-27 12:07:48 -05:00
Leo Franchi 5441409044 Consolidate emoji tests and test on frontend as well
(imported from commit 3244a93209b56b655b80633713a3f58ae46d06ff)
2014-01-27 12:07:48 -05:00
Leo Franchi 78f0cc1c4d Don't set realm filters unless we have local echo
(imported from commit bbb7d87a869d6f1bd99a45581f8f557a97f30cce)
2014-01-27 11:56:25 -05:00
Leo Franchi 6d9edcf06f Re-enable local echo for staging
(imported from commit e8b579e2289271732d3998cbe16854e39e55d5d6)
2014-01-24 16:09:44 -05:00
Leo Franchi 3b07c164fb Fix realm filters with multiple groups
(imported from commit 9652cf8acbe51e25bcf053980b6caa9565b57e45)
2014-01-24 16:09:44 -05:00
Leo Franchi 97fb3e74af Support subject links in local echo
(imported from commit 916fecccc834053ea0354936119c6591af273938)
2014-01-24 16:09:44 -05:00
Jason Michalski 62435e167f Add frontend stream description event handling
Update the stream page when receiving stream description change events.

(imported from commit 84f6f3846a3197f14a24611cdc06350fae90f9dd)
2014-01-24 14:47:44 -05:00
Jason Michalski 1f98c4f4ce Add support for updating the stream description
The stream description can now be updated, but the UI is not yet updated
on success.

(imported from commit f45e0a9d5138d828ae98d6d49645ab3ddc966704)
2014-01-24 14:47:44 -05:00
Jason Michalski 4104f00229 [schema] Add description to streams and display it
A description was added to the streams and it is now displayed on the
subscriptions page. It can not be set in the UI yet.

(imported from commit 81d08b65eee42dba87cd99dd5bd30106c4eb6c6a)
2014-01-24 14:47:44 -05:00
Jason Michalski 0c9271212d Added a admin settings div to the subscription template
(imported from commit 8aaa55d90a78ab1c4b182efeb4cac5b7d0677822)
2014-01-24 14:47:44 -05:00
Leo Franchi ea04d027cf Don't allow editing of local-only messages
(imported from commit 4fcac6b4b7a5f917944934d06eae757d7cca8170)
2014-01-24 14:01:19 -05:00
Leo Franchi 9ec5cde8b0 Disable local echo for staging temporarily
(imported from commit dd4dcf1382f8511f49fc223223fa3dbba1634ef8)
2014-01-24 14:01:18 -05:00
Leo Franchi f528ac659d Only attempt to reorder a message if we had it in the message list originally
(imported from commit 0b2802c1f1b6b17cd9f52dd9cecdf84f6f1cf5b0)
2014-01-24 14:01:18 -05:00
Leo Franchi b1ac754448 Don't local echo messages that we can't apply locally to the narrow filter
(imported from commit 372063352f17caa4990195ace4757bb68c53523a)
2014-01-24 14:01:18 -05:00
Leo Franchi 063484a917 Only clear the compose box if a message was locally echoed
(imported from commit a90a566f61e939e34eab9666743848e47c122400)
2014-01-24 14:01:18 -05:00
Steve Howell e63d9d32e2 Remove an unneeded call to build_stream_list().
We were calling build_stream_list() twice in succession for
no good reason.  The call to build_stream_list() inside
populate_subscriptions was pulled out to happen right after
its two callers.

(imported from commit 816ae2fd34224d8baf4e4bcccdb670143795bb42)
2014-01-24 12:23:41 -05:00
Steve Howell 4015189094 Release page_params.{un,}subbed_info during initialization.
(imported from commit 410eeb7978281ae9b9e2a28fe26dcae10a65518d)
2014-01-24 12:23:41 -05:00
Steve Howell b82ed52e7b Rename page_params.stream_list to page_params.subbed_info.
This matches page_params.unsubbed_info, plus it sets up to
add something like page_params.stream_dict without being confusing.

(imported from commit 2d40deb779e5c7a488d6952560b4119094bbc0d8)
2014-01-24 12:23:41 -05:00
Jessica McKellar ee7a1f0953 tutorial: add helpful in-app links and be consistent with realm welcome message.
(imported from commit 2057dbe2606d32721192021ed2046ed9f412d8a7)
2014-01-23 17:06:29 -05:00
Jessica McKellar 6aaa11027f Fix the Desktop App banner covering top links in the left sidebar.
Before this commit, while the banner is open you can't click on the
Home link.

(imported from commit 4d41bacc50d8115b4868fbda537c9bd64250040a)
2014-01-23 17:06:28 -05:00
Jessica McKellar 993a20bdee tutorial: be flexible about the work-focused warm-up message recipient.
(imported from commit 190f0cb27dda8cb89c2682affe1daee4248fe846)
2014-01-23 17:06:28 -05:00
Jessica McKellar 117c98796e Send some messages to warm up the first user in a realm.
(imported from commit b4d92d474b27c9a0eabf99576a0f441a7d919106)
2014-01-23 17:06:28 -05:00
Jessica McKellar fcd89d5861 tutorial: show content as if in a stream narrow.
(imported from commit 716640dd5d0abeafdd8fd2f1b033a6203486a405)
2014-01-23 17:06:27 -05:00
Jessica McKellar ebd6408ec7 Make the tutorial shorter, and visually highlight important concepts.
(imported from commit 543d0ff838edbc2148df4b8d08331c793c7af4f6)
2014-01-23 17:06:27 -05:00
Jessica McKellar a677db4672 Start users in a narrow to the notifications stream after the tutorial.
They'll see the welcome messages they need without being overwhelmed
by the home view.

(imported from commit 195cb4defa1dc0aa5ba8870226036e4dfd111c0f)
2014-01-23 17:06:27 -05:00
Jessica McKellar 7702461700 Unconditionally subscribe new users to the notification stream if it is public.
(imported from commit 7d7f14eb6fee43ca6f18adddda741665ce22d24a)
2014-01-23 17:06:26 -05:00
Jessica McKellar e5a24c2d21 tutorial: tweak Desktop app banner language.
(imported from commit 727dd269314092a28b39e43300ee322416e3e18e)
2014-01-23 17:06:26 -05:00
Leo Franchi 1c9a59fd3f Add newlines outside code blocks in marked.js to match bugdown
(imported from commit 7618260dbfa11209b3cc45d007407476897c2a20)
2014-01-23 16:50:29 -05:00
Leo Franchi 07dae5fcb9 Locally echo messages that are loaded from storage and resent
(imported from commit 474a0994d82bdbff9c98b453d3e1e4dc7732f5bd)
2014-01-23 16:28:59 -05:00
Leo Franchi 4ac59a71bd [socket] Persist queued requests across restarts in localStorage
(imported from commit a3a7b0c8292c53807d179b343d371eebc11ef10b)
2014-01-23 16:28:59 -05:00
Leo Franchi fd4b68aa72 [socket] Save pending and queued requests together
(imported from commit aecf59b26938c831da03a6a31545f2522387e67f)
2014-01-23 16:28:59 -05:00
Leo Franchi 56d9446c41 [socket] Use socket req ids that contain queue ids
(imported from commit 781eafe60bf117d79ce3a30deea02ec1e875060a)
2014-01-23 16:28:58 -05:00
Leo Franchi 24cb5fb079 Add a localstorage.js module
(imported from commit 9f3ab248ce84ce296bb1fb918de3b2dd8cde1ded)
2014-01-23 16:28:58 -05:00
Leo Franchi e24dcb3952 Report proper displayed/receive time and local echo data
(imported from commit 63aba6ef05b1a55d61e975831ebbaa074f8ea74f)
2014-01-23 16:28:58 -05:00
Leo Franchi 439633fd03 More markdown compatibility fixes
* Escape " as &quot;
* Enable GFM newlines
* Output a linebreak after <br> in the generated markup

(imported from commit c007ec422054f9fc66a810b66aac70f70a2a1952)
2014-01-23 16:28:58 -05:00
Leo Franchi c1442f386f Local echo messages that mention the sender should be highlighted
(imported from commit 58184f00e63fd50ed4a68d12afe0779ae3745749)
2014-01-23 16:28:57 -05:00
Leo Franchi 86cb451dcb Render <a> with title and target attributes
(imported from commit 0e195db0a3ff1ebe3d567a1ab6408c4a1bfe1e2d)
2014-01-23 16:28:57 -05:00
Leo Franchi 97a69cbc12 Convert realm filters in client-side markdown parser
(imported from commit ef12b9ed28cf0176881d33caa1973fe4d9b90d0b)
2014-01-23 16:28:57 -05:00
Leo Franchi b1a6fdf5e2 Add support for realm filters to marked.js
(imported from commit cea1720b6535a23469185f0ad2677edd373e7cfb)
2014-01-23 16:28:57 -05:00
Leo Franchi c0d56c822f Use the batched_flag_updater in ui.js as well as zulip.js
(imported from commit 6dea64d068d013471baf4022a8041f54da5c111e)
2014-01-23 16:28:57 -05:00
Leo Franchi b7b322d8cd Parse user mentions client side
(imported from commit b2919912792b8a02afad45f48e1c8df4783b93a9)
2014-01-23 16:28:56 -05:00
Leo Franchi 0f8cb25d89 Parse emoji client-side
(imported from commit 3bf150d866689b301ee31218cb3d570119b766cf)
2014-01-23 16:28:56 -05:00
Leo Franchi 0de824f73e Add a zulip module to marked, which supports emoji and user mentions
This is partially inspired by https://github.com/chjj/marked/pull/238

(imported from commit 03b84cde88fc8c2fe31c1003a5ce852cc364733e)
2014-01-23 16:28:56 -05:00
Leo Franchi 87ce2bd0be More standardization of client-side markdown parsing
(imported from commit bc010d69ee92758481d3645f84f2a68dcafacf7a)
2014-01-23 16:28:56 -05:00
Leo Franchi 53739622fd Animate/rotate the retry spinner while retrying local send after failure
(imported from commit 13daa2b956baecb8e30fbc5807bcd969eb46a653)
2014-01-23 16:28:56 -05:00
Leo Franchi 03ceef0c40 Trigger a JS event on the inital load of messages completing
(imported from commit 9f1dc0c2f631bdd0a0b020b4b9565ee910e07c98)
2014-01-23 16:28:55 -05:00
Leo Franchi 34722de1da Don't allow editing of in-flight locally delivered messages
(imported from commit 771ba4910a8f8e50803baa5f7ec75208077ed2dd)
2014-01-23 16:28:55 -05:00
Leo Franchi 883122b129 Allow editing of locally echoed messages that failed to be sent
(imported from commit eff8d55af7a1ff123ed2a2e45e58ff74de96beac)
2014-01-23 16:28:55 -05:00
Leo Franchi c3f798297e Show message failure message on hover of error
(imported from commit 8379c3c35c612d3609d2ab378eb6ca2f7ec120b1)
2014-01-23 16:28:55 -05:00
Leo Franchi 00f64113e9 Support locally echoing messages when sending
(imported from commit 00b5c5f9b933d119553c32cadff0f17b9f7c2879)
2014-01-23 16:28:55 -05:00
Leo Franchi 5b8e46f971 Allow emails in display recipient until local PMs are reified from server
(imported from commit 73f87449206c3789a4d74b8f776588d588ef88e1)
2014-01-23 16:28:55 -05:00
Leo Franchi 835e385b75 [third] Add marked.js, a javascript markdown parser
(imported from commit e85d9b50328ce7d31882464fcc283478f7a9f753)
2014-01-23 16:28:54 -05:00
Leo Franchi 0b2ba855f9 Add helper for rough determination of markdown client-side
(imported from commit 3b6439f54e55fbca0f586392d1a0add4d7f694b8)
2014-01-23 16:28:54 -05:00
Leo Franchi f5af245c09 Clear compose box immediately after message is sent
(imported from commit 07cf0ca34dea1a64c37261e153730a9564281b3b)
2014-01-23 16:28:54 -05:00
Leo Franchi 9b42cdd826 Add a feature flag for local echo
(imported from commit 8aad03929333c77da62160aeb58013a0844c6eab)
2014-01-23 16:28:54 -05:00
Zev Benjamin d5c6408efe Handle a Firefox error relating to websockets.
We've only gotten one error report for this error, and it didn't have a stack
trace, so it's hard to know whether this will actually fix the issue or not.

(imported from commit 7bff052347a33f67d8479b1cb23f6e5e24defc75)
2014-01-23 13:32:40 -05:00
Leo Franchi 49c4ad61a1 Delay render on narrowing to end, to ensure only one render happens
(imported from commit c38574417e339275a90b235ecabc96e0deab95f8)
2014-01-23 13:29:18 -05:00
Steve Howell 2283aa52cb Use "stream" as our type for updates to Stream.name.
(imported from commit 2eedbff5fac77b9e654ba88900167048573e4056)
2014-01-23 13:27:11 -05:00
Tim Abbott 09dbaabcb6 Update unread flags between multiple browser windows.
(imported from commit 1c5e2bc0233c28c72ce4c8253fa0717ae4793f84)
2014-01-23 13:21:59 -05:00
Tim Abbott 8fa49388c0 Sync the starred message flag to browsers without reload.
(imported from commit e685104275f471d1cd9b94e1803c26f714628f36)
2014-01-23 13:21:59 -05:00
Tim Abbott 59cd1663df Rename confusing update_message_* functions in ui.js.
(imported from commit eeb2b1f92deb807676a75f1263d994a8c606b249)
2014-01-23 13:21:59 -05:00
Tim Abbott 59b0af835e Use clearer variable name for toggle_star argument.
(imported from commit 6cc604b0cbe8a3a16ff4772e811af1fb4b41aa1e)
2014-01-23 13:21:59 -05:00
acrefoot c93d0abfb0 Add circle Z logo to static images; do not rename without changing github-services
github.com/github/github-services/lib/services/humbug.rb:4
log_url = 'https://zulip.com/static/images/logo/zulip-icon-512x512.png'

(imported from commit 0fd4b54d18128a2edcb16b09168d948109679825)
2014-01-22 16:44:09 -05:00
Steve Howell 1746af4df6 Reflect is_admin changes on the client.
The client's update_person() method will look for an is_admin
change and update the gear menu as needed, as well as the underlying
data structures that help draw the admin page user list.

(imported from commit af8c173886d63dd102c63336bbca176f49e1036d)
2014-01-22 14:43:29 -05:00
Steve Howell 887c2059b1 Make the Administration menu item be show/hide-driven.
Always render the Administration menu item from the back end, but
make it be hidden by default until the page is loaded.  Then, the
client can un-hide it as needed.

(imported from commit 66e607eec430d7179b4d5ac3f5416f5be8ac26c9)
2014-01-22 14:43:29 -05:00
Steve Howell 81d975c5ff Account for update_user not having a full_name field.
Going forward, the back end may supply fields other than
full_name, like is_admin, so we should make sure the field
is in the hash first.

(imported from commit be94b9698bae0866444739e2846ff65a3ab27eb6)
2014-01-22 14:43:28 -05:00
Steve Howell 93deefec8d Remove defensive code in update_person().
The code to keep page_params.people_list and realm_people_dict
values in sync with people_dict was unnecessary, as they are
the same underlying object.

(imported from commit 0a901213977ed21a0587ed1590ab5434be756f51)
2014-01-22 14:43:27 -05:00
Leo Franchi 9160fb3ed5 Remove debug that slipped in to previous commit
(imported from commit 1aeb04b0e8fc0b37da4a8aa123b567d2f96cc32a)
2014-01-22 14:04:25 -05:00
Leo Franchi c0fdbf81cf Use the feedback connection for getting APNS feedback
(imported from commit d371188e0437606b3ff435ee9c005cee2849f6ae)
2014-01-22 13:50:15 -05:00
Jason Michalski d4aece75a5 Add JS to for the inline subscribe button
Add javascript to handle the button clicks and update the status based
on the subscribe and unsubscribe events from the server.

(imported from commit 6b9c0b40d9084e3d8b64bed701ebc786bef6d432)
2014-01-22 11:28:31 -05:00
Jason Michalski d8a6ec3507 Add a message_rendered.zulip event
The message_rendered.zulip event fires after a new messages was rendered
but before it is added to the DOM. This allows javascript components to
change the display of a message before it is added to the DOM.

(imported from commit 69448a250863853a6d0a6e428dcfa12db50f2f71)
2014-01-22 11:28:31 -05:00
Steve Howell 8f9d29189c Fix undefined operator in search suggestions.
There was a bug where you would type "is:private je" into the search
suggestion and see undefined:jesstess@zulip.com.  Now we use
the "pm-with" operator.  The search suggestions for people are kind
of complicated now, because there is some overlap between
get_private_suggestions and get_person_suggestions.

(imported from commit 7d330f34f4a433995420de6eb90cb41229b70272)
2014-01-21 17:07:50 -05:00
Steve Howell 816fce50f7 Allow reactivating 2+ users on admin page.
There was a bug where you could not reactivate a user after
doing another user-based action on the page, because we weren't
clearing the active_user_row class on the previous row, and
then $(".active_user_row").find('.email').text() would be a
concatenation of two user emails and cause a "No such user!"
error.

(imported from commit c867d3bc0855e02b17b9553e1924926c2dd50e56)
2014-01-17 17:34:32 -05:00
Steve Howell ecd288f144 Rename inactive_user_row CSS class to deactivated_user.
It was confusing, because it has different meaning that being
the opposite of active_user_row.

(imported from commit df190afb2d9bccf9790c7373802b16ff6da2f2cb)
2014-01-17 17:34:32 -05:00
Steve Howell 5a3d338937 Hide "Make admin"/"Remove admin" button when deactivating a user.
(imported from commit 0d925d68c1beecf3fee7dd5de47930a4ad9ce3cf)
2014-01-17 17:34:31 -05:00
Steve Howell 59ac5cce72 Reformat admin_user_list.handlebars template.
(imported from commit 0e6f92d2cd4ab7c4d9c94f6827fda9231c9d42fe)
2014-01-17 17:34:31 -05:00
Steve Howell 004d84f6e2 Redraw sidebar lock icon for stream privacy changes.
If you make a stream private/public from the Streams page
(which admins can do now), then we now correctly redraw
the swatch to have/not have the lock icon.

(imported from commit 35eb4ba12ad152e43b40f1bcf2c5db784a965dee)
2014-01-17 16:39:27 -05:00
Steve Howell bca0311b53 Created stream_list.redraw_stream_privacy().
This function can redraws the lock icon (or lack of lock icon)
for a stream in the stream sidebar.  It can be called when
admins change the stream privacy.

(imported from commit 880133d02525137094c48ecad8cf2dfff59f3307)
2014-01-17 16:38:06 -05:00
Steve Howell a9e621fff4 Extract stream_privacy.handlebars partial template.
(imported from commit 77d614a549f5a337442936a002d422db1913e298)
2014-01-17 16:37:47 -05:00
Steve Howell 137a1b7799 Rename stream_list.build_narrow_filter() to build_stream_sidebar_row.
The new name is more descriptive of what the function does, and it
also has the side benefit of cleaning up greps for the backend
function called build_narrow_filter().

(imported from commit 4b88fa863d7c1751946c78977f2ffaf19dd3ae5e)
2014-01-17 16:37:46 -05:00
Steve Howell 84ea28ae25 Remove type parameter from build_narrow_filter().
The type parameter was always passed in as "stream", and we
only render the stream_sidebar_row template, so let's not
pretend like we support arbitrary message types here.

(imported from commit 8a852a68ddda336024793f6fdafa648883bb815e)
2014-01-17 16:37:46 -05:00
Steve Howell c7bf349e70 Deprecate stream_list.add_narrow_filter().
We now call add_stream_to_sidebar() instead.  The old function was
only ever called for streams, so the newly named function is more
descriptive of what it does.

(imported from commit 7ae373279ea9987d3637cdbdc427680ac989fe86)
2014-01-17 16:37:45 -05:00
Steve Howell 56dc4e0b8e Add test_add_stream_to_sidebar().
This is a node test that verifies that
stream_list.add_stream_to_sidebar() creates the right
DOM when it renders the stream_sidebar_row template.
The test also makes sure that the DOM gets put in the
correct place to be retrieved by stream_list.get_stream_li()
calls.

(imported from commit ed4c0148da2261870e3db5a9b553913788b4eccd)
2014-01-17 16:37:43 -05:00
Jason Michalski 4c90392261 [schema] Add an per-user option to disable notification on new streams
Added a default_desktop_notifications boolean to userprofile with a UI
in Zulip Labs. This flag is used to default the notification flag on new
subscriptions.

(imported from commit a25223cc5ecf09980cf877991e25034bb3fd4046)
2014-01-16 20:13:34 -05:00
Tim Abbott 1edcbfb8b0 Fix tab bar for embedded topic narrows.
(imported from commit 4c63478b1899c22f3d0be5651e2eb82aecdaaa4a)
2014-01-16 18:18:21 -05:00
Tim Abbott bc22b1eb16 Add support for topic narrows in our embedded narrow widget.
(imported from commit d3ef2db8e0903e445d9ecc2c28d9f249a0042bd9)
2014-01-16 18:05:35 -05:00
Steve Howell 4d03fd984f [notify customer] Add 24hr support for Steve Pomeroy.
We hard coded his feature flag as a response to Z438.

(imported from commit f2637b5610bf69a0d79347586a788b3bb67b19de)
2014-01-16 15:04:54 -05:00
Steve Howell ec91ece6ed Remove "Create new stream" UI for restricted users.
If a user is not allowed to create new streams, then do not
show the "Create new stream" UI at the top of the settings page.

(imported from commit b97626938d8b612317c2189f7eca0d4bd27fc274)
2014-01-16 14:43:57 -05:00
Steve Howell 447c99aa66 Add UI for admins to add/remove admin power from other users.
(imported from commit b7e81316f1f1e3c7b7f7dd5dac5db8e70f1ee209)
2014-01-16 13:41:54 -05:00
Steve Howell 6d963c4a85 Always set data.method=PATCH in channel.patch()
(imported from commit 242503c1caa670fa219acbfe811a1b5e5d54f2b6)
2014-01-16 13:41:53 -05:00
Steve Howell 81de08f067 Improve selectors for user activate buttons on admin screens.
(imported from commit 094e81a1a337aeed7cfd39ce61daf6ac50e905cd)
2014-01-16 13:41:53 -05:00
Steve Howell 07b2eed389 Add README.zulip.md for handlebars.
(imported from commit a1e214d4bfbd1c0e6dc3918ad649c20e921399db)
2014-01-15 16:45:22 -05:00
Tim Abbott 6443aead67 Fix scrolling when unnarrowing after reading new messages.
Our logic for unnarrowing when messages were read during the narrow
did not properly use the then_scroll option and thus actually set the
scroll position when they selected a new message.  This was
accidentally prevented from being a big problem by the incorrect
scrolling logic that was fixed by:

    Only preserve_pre_narrowing_screen_position when preserving pointer.

which caused the browser to scroll _back_ to close to the correct
scroll position (but not the intended scroll position -- it would
usually be a little bit off).

(imported from commit d779de8f89590d242f62d32b22a297bdc096c594)
2014-01-15 16:07:20 -05:00
Zev Benjamin fa097a1201 Remove jquery.highlight
The one call we were making to it was actually unnecessary since highlighting is
no longer done client-side.

(imported from commit 7644a5961ca48cd57f4b65c6f698083677e0a130)
2014-01-15 16:07:20 -05:00