Due to differences between the codepoints of flag emojis in
`emoji_map.json` and iamcal's dataset, we need to patch the
css classes for the flag emojis temporarily until the migration
to iamcal's dataset is complete inorder to render them properly.
There is a difference between the images of flag emojis in our
old emoji farm and iamcal's spritesheets and since we have not
yet switched to using spritesheets for displaying emojis in
messages, there is a difference between the flag emojis as
rendered in messages and in emoji pickers.
This reverts commit c7f710b8d4.
Because the back end still stores muted topics fundamentally using
stream name as a key, trying to cut over the client to use stream
id was just making things more brittle. Mutes would work after
renaming the stream, which was progress in the change that we
revert here, but only until page load. The other problem, which
is more severe, is that the order of page loading functions would
cause no mutes to happen at page load time. This could be fixed
to some degree, but we should do a deeper fix on the back end.
Previously, the sum (capital sigma) operator would become
misaligned so that the lower and upper bounds are placed in
the wrong location. Changing the line height fixes this alignment.
Also, previously, wrapping long lines of TeX did not work, as often,
the different lines of math would overlap with each other.
Fixes#4657.
We should be able to eventually further clean this up to do nothing,
since we now don't have tabs over than the home tab. But I'm leaving
that for a future issue.
These date from long before the settings UI was restructured as an
overlay. Now, instead of ensuring that error messages are visible,
they just scroll the message feed incorrectly.
Fixes#4810.
There's no advantage to doing a small batch size towards current here,
since latency isn't an issue at this point, and performance on the
server side generally favors larger batch sizes.
This also will make it significantly harder to start getting 429 rate
limiting errors when loading when far behind current.
A formal date string will be assigned to the title attribute of the
recipient_row_date and date_row elements.
e.g. Wednesday, April 5, 2017.
Fixes#4663.
This is system unfortunately has a rather complicated calculation to
compute the offsets correctly, but the net effect here is that the top
section of the Zulip window is much more space-efficient.
Shrinking the tab bar underpadding, part of this change, fixes#4444.
We only need the underpadding to be as tall as the space above the
floating recipient bar, which is definitely less than 10px, so I don't
anticipate regressions caused by this.
When you create a stream, there was always an "Announce stream"
option that would be enabled for public streams.
We are about to make it so that we never send PMs to announce
new streams to folks, so the only mechanism will be sending a message
to the realm's notification stream. If a realm has no notifications
stream, the decision is moot, so we hide the option.
The regex we were using didn't cover all the unicode blocks
to which our emojis belong. This commit fixes the regex to
include all the unicode blocks and also updates the
corresponding JS regex in marked.js.
Fixes: #3460.
If you were narrowed to an unpinned stream, and then pinned it,
we were mostly redrawing the sidebar correctly, but we weren't
setting the active-filter class. Now we accomplish this by
calling maybe_activate_stream_item(), which also reduces some
code duplication. (The new code introduces a bit of extra logic
to do `stream_li.addClass('active-filter')`.
This commit changes the key for recent_topics to be a
stream id. For streams that have been renamed, we will now
get accurate data on recent topics and active streams as
long as stream_data.get_stream_id(stream_name) returns a
valid value.
This commit changes stream_data.in_home_view() to
take a stream_id parameter, which will make it more
robust to stream name changes.
This fixes a bug. Now when an admin renames a stream
you are looking at, it will correctly show itself to
be un-muted. (Even with this fix, though, the stream
appears to be inactive.)
Some callers still do lookups by name, and they will
call name_in_home_view() for now, which we can
hopefully deprecate over time.
Rather than having get_stream_li() look up stream id using
stream name, we force the callers to pass in the stream id.
This adds an extra line to most of the callers for now, but
this will eventually change as we fix some of the callers to
have their callers pass in stream_id.
In places where we now call stream_data.get_stream_id() to
get the stream id, we will be more resilient toward stream
renamings, at least until the next reload, since
stream_data.get_stream_id() can resolve old names that
are stored when we process stream-rename events.
We no longer have get_stream_li() delegate to get_filter_li(),
which simplifies the logic in get_filter_li() and makes
get_stream_li() more direct.
We also move the two functions closer to each other in the file.
There's no correct contact that we can list here unconditionally;
previously, we had people emailing zulip-devel@ because their server
was misconfigured.
Addresses #696 enough that it's no longer a priority issue.
Using get_name() is more robust for stream name changes. This
fixes, for example, the situation where you narrow to a stream,
edit it via the sidebar, and then close the modal, and the message
redraw logic thinks you have unsubscribed.
Fixes#4686.
This change fixes a few small things related to stream
renames, such as what happens if you hit the back button
to go to a narrow where the stream had been renamed. You
will now get the correct behavior in terms of filtering
and searching. Unfortunately, this will only last until
you reload.
We now use stream ids to filter messages in narrowing
situations, instead of doing stream name comparisons.
This partially fixes certain stream-renaming scenarios, since
we will be able to match the stream id for an out-of-date
stream operand, but it doesn't fix some other stuff, such
as the query that the server gets.
This is not a user-facing change, but it starts us down the
path to having the JS client be able to look up old stream
names for situations like people clicking old external links
or for live-update scenarios.
This commit addresses to issues with the left sidebar:
The cursor flickering when hovering over topics, and
the cursor not becoming a pointer when resting just right
of a topic's name (in a clickable area).
This is a follow-up to #4675.
Can be added to the landing pages via:
+ {% include 'zerver/compare.html' %}
+
I'm avoiding adding that include into the landing pages until we have
time to do a bit of tweaking of the styling to integrate better into
/hello/ (primarily color-wise).
Most of the work for this was done by Brock, huge thanks to him!
The search bar for picking message reactions now is case-insensitive,
since that's a better user experience, and there isn't a clear use
case for capital letters in emoji names.
Fixes#4666.
This is a much less annoying behavior than the Chrome browser default.
Explanatory comment added by tabbott, thanks to Steve Howell for the
research.
Fixes#4604.
This enforces a max-width of 1024px on the #settings overlay.
This commit also cleans up the "Your Account" tab to display
correctly without the avatar bleeding over to the next line.
Both callers to get_user_list_for_message_reactions() already
had a message object, so there was no need to pass in an id
just to fetch it from message_store again, so now the first
parameter is message, not message_id.
This adds the current_user_has_reacted_to_emoji() helper.
This new helper is easier to use and slightly more efficient
than calling get_user_list_for_message_reaction() and then
indexOf().
This also replaces one call to get_user_list_for_message_reaction()
with a list of user_ids that we already had locally.
The node tests were improved a bit here, including a minor
whitespace fixup.
We used to render the subscriptions_settings template for every
stream when you loaded "Manage Streams," which can be very slow
for a big realm. Now we only render the right pane on demand.
The function stream_data.add_admin_options() got removed as
part of a somewhat recent fix. This caused a console error, and
the modal would not go away.
We now call the new stream_data.update_calculated_fields().
This commit only addresses the recent regression. We still have
the known issue that public/private changes do not get
live-updated for other users.
This changes the styling of the user profile popup to be responsive
to mobile devices. In this case it is converted to a modal form using
flex to center it on devices with screen sizes under 768px in width.
Fixes#4669.
This is a follow-up to merging the compose and reactions emoji
pickers. The logic for what happens when the user picks an emoji via
the hotkeys (i.e. hits `enter`) was still attempting to add a reaction
to the currently selected message unconditionally.
This commit adds a check in the two `enter` key code paths, and does
the correct thing in each case.
Fixes#4736.
The click target was still for #hamburger even though it has since
been changed to .hamburger. This fixes the selectors to make it work
with the new className declaration over ID.
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
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().
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.