This commit is a part of the efforts to rename btn-related classes
and variables to align with Zulip's no-abbreviations policy and
streamline the search results.
This commit is a part of the efforts to rename btn-related classes
and variables to align with Zulip's no-abbreviations policy and
streamline the search results.
This commit is a part of the efforts to rename btn-related classes
and variables to align with Zulip's no-abbreviations policy and
streamline the search results.
This commit is a part of the efforts to rename btn-related classes
and variables to align with Zulip's no-abbreviations policy and
streamline the search results.
This commit is a part of the efforts to rename btn-related classes
and variables to align with Zulip's no-abbreviations policy and
streamline the search results.
This commit is a part of the efforts to rename btn-related classes
and variables to align with Zulip's no-abbreviations policy and
streamline the search results.
This commit is a part of the efforts to rename btn-related classes
and variables to align with Zulip's no-abbreviations policy and
streamline the search results.
This commit is a part of the efforts to rename btn-related classes
and variables to align with Zulip's no-abbreviations policy and
streamline the search results.
This commit is a part of the efforts to rename btn-related classes
and variables to align with Zulip's no-abbreviations policy and
streamline the search results.
This commit is a part of the efforts to rename btn-related classes
and variables to align with Zulip's no-abbreviations policy and
streamline the search results.
This commit is a part of the efforts to rename btn-related classes
and variables to align with Zulip's no-abbreviations policy and
streamline the search results.
This commit is a part of the efforts to rename btn-related classes
and variables to align with Zulip's no-abbreviations policy and
streamline the search results.
This commit is a part of the efforts to rename btn-related classes
and variables to align with Zulip's no-abbreviations policy and
streamline the search results.
This commit is a part of the efforts to rename btn-related classes
and variables to align with Zulip's no-abbreviations policy and
streamline the search results.
This commit is a part of the efforts to rename btn-related classes
and variables to align with Zulip's no-abbreviations policy and
streamline the search results.
This commit is a part of the efforts to rename btn-related classes
and variables to align with Zulip's no-abbreviations policy and
streamline the search results.
This commit is a part of the efforts to rename btn-related classes
and variables to align with Zulip's no-abbreviations policy and
streamline the search results.
This commit is a part of the efforts to rename btn-related classes
and variables to align with Zulip's no-abbreviations policy and
streamline the search results.
This commit is a part of the efforts to rename btn-related classes
and variables to align with Zulip's no-abbreviations policy and
streamline the search results.
This commit is a part of the efforts to rename btn-related classes
and variables to align with Zulip's no-abbreviations policy and
streamline the search results.
This commit is a part of the efforts to rename btn-related classes
and variables to align with Zulip's no-abbreviations policy and
streamline the search results.
This commit is a part of the efforts to rename btn-related classes
and variables to align with Zulip's no-abbreviations policy and
streamline the search results.
This commit is a part of the efforts to rename btn-related classes
and variables to align with Zulip's no-abbreviations policy and
streamline the search results.
This commit is a part of the efforts to rename btn-related classes
and variables to align with Zulip's no-abbreviations policy and
streamline the search results.
This commit is a part of the efforts to rename btn-related classes
and variables to align with Zulip's no-abbreviations policy and
streamline the search results.
The setting value for message move limit seconds was not being
converted to seconds before checking if the value was allowed or
not and that resulted in requests being made for values greater
than the allowed values.
Commit db24df488c (#29286) made this a
normal function rather than a jQuery plugin, so it doesn’t need to be
imported for side effects.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
Removes "last active" time from deactivated user tooltip and instead adds
"This user has been deactivated." Also, in the deactivated bot tooltip,
"This bot has been deactivated." has been added.
Fixes#32136.
This bug was introduced in 174a458928 as `this` parameter
passed to role_selected_handler was DropdownWidget instance
and not the Jquery element for the selected role option.
Created a custom type declaration file `ga-gtag.d.ts` for
`ga-gtag` npm module.
`@types/gtag.js` is installed as a devDependency so that the type
for `gtag` function can be provided.
This was due to `box-shadow` used to hide the content was incorrectly
overridden in `.sticky_header` from the `.message_header` just above.
The bug is highly reproducible since it happens due to minor pixel
differences when rendering.
This fixes backfill data not being inserted in recent view if
recent view was open when it received the backfill data.
Fixed by inserted rows in the sorted order instead of inserting
them randomly which caused rows to not be inserted if there were
no rows around the row being inserted.
In 245357c868 we added a redirect
after stream creation, to go to the stream feed. This means
the stream settings modal was closed partway through the tests.
This caused a flake where when the modal was reopened it was
not always open by the time we fetched the stream name.
The main fix in this commit is changing the classname for
the stream in the modal to be more specific (`stream-name`
can also be found in the left sidebar in many places) and
waiting for it to be visible again before getting text from
it.
More discussion here:
https://chat.zulip.org/#narrow/channel/43-automated-testing/topic/stream.20create.20puppeteer.20failure/near/1976724
Co-authored-by: Anders Kaseorg <anders@zulip.com>
Fixes#31823
When home view changes, CSS just puts the selected home view
at the top of the left_sidebar navigation list (expanded)
or to the left (collapsed), but the rendered <li> elements
stay in the same order in DOM, so regarldess of current home view,
keyboard navigation always follows the order in which the <li>
elements appear in DOM.
Changes:
- Reorder <li> navigation elements in DOM based on current home view.
- Remove tabindex=0 from <a> elements, because they are now ordered
correctly in DOM.
- Add (tabindex="0" role="button") to the <i> collapsable VIEWS, to be
keyboard accessibile.
I saw some profiling traces where it appears multiple copies of this
click handler got processed when clicking on a topic in the left
sidebar.
I suspect that was a profiling artifact, but the intent is for
on_topic_click to fully process clicks on topics in the sidebar, and
we should write the code to say that.
This commit adds more space between rows, increases the line height
so that the status message doesn't touch the status emoji, and makes
the status circle a little bigger.
c39ae45d95 was incorrect, and should
only have been applied to the circles in the buddy list avatars.
In other places in the app, the transparency was over other colors
of background.
Users are fetched from `people_by_user_id_dict`.
`bot_info` is only called from:
* `bots_create_table`, with ids from `get_bot_ids` which are
from this `people_by_user_id_dict`.
* `update_bot_data`, which is called in two places that check
`is_valid_bot_user` on the bot id first.
So we should always get a `bot_user` back, and we're already relying
on the bot users being defined in several methods of the
`bot_list_widget`.
These were all manually checked to still work.
`e.currentTarget` is equivalent to `this`, and
all instance of `e.target` were either the same
as `this` or used with a `closest` function that
still got the same value.
It seems like this was working fine, thanks to some internal
workings of Handlebars, but when we convert this file to
typescript, it will want a string for `html_body`.
`sub.email_address` can be `undefined`, `$foo.text(undefined)` has
no effect (it doesn't clear the text), and `text()` doesn't formally
accept `undefined`, so here we only call `text()` if the new value
isn't undefined.
None of these have showed up in Sentry in the last 90 days, and
it will be easier to type this file if we can assume we always
get a valid stream id and a valid sub for that stream id.
This had been getting undefined `sub` already, in the modal to create
a new channel, but managed to not cause errors because
`properties_elements` was empty and `button_state` didn't equal
`"unsaved"`, leaving areas that treated `sub` as defined not accessible.
This commit fixes the type and handles the `undefined` case more directly.
These tests have been broken since long ago, we don't see any
errors since they are wrapped in `Sentry`. Also, We have a great
puppeteer test suite for the verification of loading current narrow.
Since we cannot cheaply live update `is-followed` narrow, we
discard any message list or data with that narrow if we
received a message event that changes topic visibility
from or to `FOLLOWED`.
Not added to `Filter` library since this function is a bit
localized to message_events us case in the sense that it
checks for existence of `not-` prefix of the term type too.
Since stream / topic change involves change in topic name, it could
involve new messages being included and some being discarded. Also,
messages could have been moved from an inaccessible stream to now
accessible stream for the user.
Since we only pass non echo messages to
message_events.insert_new_messages, where message lists get
updated, it is important to update locally echoed messages here.
Instead of having information about streams and groups below the
create button, we show that in a banner at the top irrespective
of whether user has permission to create them or not.
Fixes part of #32212.
This commit updates the right panel for groups to be same as we
have it for stream settings when the user does not have permission
to create groups.
Fixes part of #32212.
This commit also moves styles from user-presence-link
onto selectable_sidebar_block, since the link is no
longer wrapping the whole block contents.
The `data-name` was also moved to the top level `<li>`
because it's used in pupeteer tests.
Previously, the event handler was targeting the `event.target` element
instead of the `event.currentTarget` element. Due to event bubbling,
this lead to incorrect element being used to extract the `data-user-id`,
resulting in an error whenever a user mention was clicked in the
unsaved message in the message box or the drafts view.
There are two inputs for the add email modal in demo organizations,
one to add the email address of the owner and one to update their
full name. We want the email input to be selected when the modal
is opened.
In HTML, option elements do not use/have the "name" attribute, so
the custom time choice select options do not need it to be set.
The "custom_time_choice" class is not referenced anywhere else in
the codebase, so it can be removed to make this template more
readable.
Similar to #29302, we transform zulip message links to
a pretty syntax and in case there are some problematic
characters (#30071), we generate a fallback markdown link.
Fixes#31920
Previously, when there were no messages in the topic being moved, the
banner in the move topic modal only showed a "Failed" error banner which
did not convey the actual error to the user. Also, a server call was
being made even when there were no messages in the topic being moved.
This commit explicitly handles the non-existent topic, prevents a call
to the server when the message_id is undefined, and displays a more
informative error banner to the user.
Move the redundant code for hiding spinners and re-enabling buttons into
a common `hide_spinner` function inside `loading.ts`. This reduces
duplication between `hide_button_spinner` and `hide_dialog_spinner`.
Fixes#26691.