Commit Graph

2427 Commits

Author SHA1 Message Date
xoldyckk 8b3f8d77b0 zform validation: Migrate validation logic to zod.
Migrated zform validation logic to make use of zod schema.
2023-10-27 16:14:51 -07:00
Aman Agrawal 2d033c94d9 recent_view: Fix user unable to focus change_visibility_policy icon.
`recent_view_focusable` class should be set on element whose
children can receive focus as per

`$topic_row.find(".recent_view_focusable").eq(col).children().trigger("focus")`
2023-10-27 13:26:36 -07:00
Lalit 151d51acfa input_pill: Remove over defensive if checks for `create` function.
We should remove this overly defensive code and remove the `undefined`
type from the return type of this function to avoid handling unexpected
`undefined` values in the downstream code.
2023-10-27 13:11:37 -07:00
Karl Stolley 01392a57dd left_sidebar: Resize scroll container when toggling condensed views. 2023-10-27 12:07:49 -07:00
evykassirer 0a33598f65 compose fade: Add test for want_normal_display. 2023-10-26 18:33:53 -07:00
evykassirer 6563e621fd buddy list: Simplify argument to get_data_from_keys. 2023-10-26 18:33:53 -07:00
Tim Abbott e560519dba portico: Fix new organization form focus scrolling.
Now that the "new organization" form is quite tall, we were seeing
this autofocus logic causing the browser to automatically scroll to
the middle of the form (to reach the first editable input), which felt
like a pretty bad user experience.
2023-10-26 16:27:35 -07:00
Tim Abbott a379fbe442 portico: Inline common.autofocus.
This was only called from a single code path.
2023-10-26 16:27:35 -07:00
Vector73 e442a9d11e user_profile: Sort arguments to "render_user_profile_modal". 2023-10-26 13:17:28 -07:00
Vector73 6dd7efae85 user_profile: Fix alignment and color of edit icon. 2023-10-26 13:17:28 -07:00
Vector73 4a4b8dff99 user_profile: Add deactivated user indicator in the profile header.
Fixes: #26861
2023-10-26 13:17:28 -07:00
Sahil Batra c9fccf476a settings: Rename default_view and escape_navigates_to_default_view.
This commit renames default_view and escape_navigates_to_default_view
settings to web_home_view and web_escape_navigates_to_home_view in
database and API to match with our recent renaming of user facing
strings related to this.

We also rename the variables, functions, comments in code and class
names and IDs for elements related to this.
2023-10-26 11:00:12 -07:00
Tim Abbott 67dbaaff91 input_pill: Fix backspace with selected text.
The logic added in b57ebe717e introduced
a different bug, namely that if you had selected text in the input,
Backspace would delete the input pill itself, not your selected text.

Fix this, without re-introducing the old bug, by checking explicitly
if there's a range selected before inspecting anchorOffset.

Also improve the comments.

Fixes #19544.
2023-10-26 10:41:45 -07:00
Karl Stolley 61aa55df79 navbar: Clean up unecessary userlist-toggle cruft. 2023-10-26 10:28:02 -07:00
Karl Stolley a9421f6ba0 navbar: Use new purple icon color with left-sidebar toggle.
This also implements the same hover and focus-visible styles
as icons on the righthand side of the navbar.
2023-10-26 10:28:02 -07:00
Karl Stolley 1f0e9b4587 sidebars: Correct display at small mobile sizes.
This fixes a state where the expanded left sidebar appears under
the navbar at the smallest mobile views.

It also provides a stop-gap fix for the right sidebar's USERS
heading, making it align better (but certainly not perfectly)
with the left sidebar's.
2023-10-26 10:28:02 -07:00
Karl Stolley 105729ce66 navbar: Simplify unread logic on left-sidebar toggle indicator.
This removes former animation logic as well as counts, as the
redesign calls only for showing an unread dot in the presence
of unreads.

Fixes: #27357
2023-10-26 10:28:02 -07:00
Karl Stolley 8ee764382b navbar: Show left-sidebar-style unread dot on streams toggle. 2023-10-26 10:28:02 -07:00
Karl Stolley 4409663e69 navbar: Handle streams-toggle alignment with dimensions, flexbox. 2023-10-26 10:28:02 -07:00
Anders Kaseorg 37f0a3b41b eslint: Forbid unchecked casts in TypeScript.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-26 09:54:30 -07:00
Anders Kaseorg 2f95c55df4 list_widget: Fix unsafe unchecked casts in generic comparators.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-26 09:54:30 -07:00
Anders Kaseorg a53231a1ae settings_muted_users: Fix sorting users by date muted.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-26 09:54:30 -07:00
evykassirer ba568adc2e recent_view_util: Rename is_rt_visible to is_view_visible.
This avoids the less readable abbreviation.
2023-10-25 17:35:00 -07:00
Sayam Samal bbf4792d81 right_sidebar: Drop keyboard shortcuts button from right sidebar.
Fixes: #27381.
2023-10-25 16:43:49 -07:00
Anders Kaseorg ba895b64ef stats: Remove unchecked casts of Plotly data.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-25 13:08:36 -07:00
Anders Kaseorg a145a6adfa realm_playground: Remove unchecked cast in sort_pygments_pretty_names_by_priority.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-25 13:08:36 -07:00
Anders Kaseorg 787ca02c6e messages_overlay_ui: Remove unchecked casts of HTMLElement objects.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-25 13:08:36 -07:00
Anders Kaseorg 31db313a46 list_widget: Add missing CSS escaping and remove unchecked cast.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-25 13:08:36 -07:00
Anders Kaseorg 043b43f044 typing_status: Remove unchecked casts in same_recipient.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-25 13:08:36 -07:00
Anders Kaseorg 9c9c453d5a web: Remove unchecked casts of event objects.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-25 13:08:36 -07:00
Anders Kaseorg 1da729e49f web: Remove unchecked casts of jQuery .val().
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-25 13:08:36 -07:00
Anders Kaseorg da80661592 e2e-tests: Remove unchecked casts of DOM objects.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-25 13:08:36 -07:00
Anders Kaseorg af8465b7fd billing: Replace unchecked keyof casts with Zod schemas.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-10-25 13:08:36 -07:00
Aman Agrawal 18a165fa97 personal_menu: Indicate no status text in italics.
If user has only set emoji as status, we show a placeholder
text to indicate no status text has been set.

Fixes #27362
2023-10-25 11:09:08 -07:00
Aman Agrawal 75aa91a39f user_card_popover: Fix clear link not working.
Incorrectly migrated in 87c87ed41f.
2023-10-25 11:09:08 -07:00
Karl Stolley 3385d5862b left_sidebar: Include right-hand padding on topic, nav labels. 2023-10-25 09:53:05 -07:00
Aman Agrawal af653572a1 recent_view_ui: Return if the list is empty.
Since we now have empty text message as a table row,
`$topic_rows.length === 0` no longer works to test if the
table is empty.
2023-10-25 09:52:23 -07:00
Karl Stolley 4fac53e35c left_sidebar: Restore and note positioning context for unread dots. 2023-10-25 08:17:11 -07:00
Tim Abbott db05d7ef0c css: Revert sidebar-menu-icon specificity change.
3ac0c3c401 incorrecly removed
specificity declarations needed to prevent that CSS from applying to
the right sidebar, which hasn't been properly prepared for this
change.
2023-10-24 16:23:30 -07:00
Aman Agrawal 464aff1f21 make_my_home_view: Show view name in bold. 2023-10-24 16:16:56 -07:00
Aman Agrawal 2f33fad5df left_sidebar: Add popover to make different views default.
Fixes #27324
2023-10-24 16:16:56 -07:00
Aman Agrawal 7f124500fa inbox_popover: Add option to make it the default view. 2023-10-24 16:16:56 -07:00
Aman Agrawal ce804fc37a navbar: Remove userlist unread count. 2023-10-24 13:57:27 -07:00
Aman Agrawal 6f6a53c909 help-menu: Center align keyboard shortcut hint. 2023-10-24 13:06:11 -07:00
Karl Stolley 1a18faaf02 left_sidebar: Increase size of condensed icons. 2023-10-24 12:29:45 -07:00
Karl Stolley 3ac0c3c401 left_sidebar: Correctly align vdots across all rows.
This brings modern alignment methods to all vdots instances,
including in views, streams, and topic rows.

This also aligns the vdots in the condensed view row with
all the others in the left sidebar.
2023-10-24 12:29:45 -07:00
Karl Stolley 21908b7a9e left_sidebar: Vertically align all vdots. 2023-10-24 12:29:45 -07:00
Karl Stolley 528f494d41 left_sidebar: Establish filter rows as grids. 2023-10-24 12:29:45 -07:00
Karl Stolley 56eaf9b153 left_sidebar: Place redesign icons in expanded views. 2023-10-24 12:29:45 -07:00
Animesh Biswas 7da9ca771f
settings: Change bot-type question to help center link.
In the "Add a new bot" modal, there was '?' next to the bot type field
that was confusingly showing a tooltip describing incoming webhooks,
regardless of the bot type have been selected.

The tooltip is removed from the '?' and it is linked to the help center
article explaining all the different bot types.

Fixes #27047.
2023-10-24 10:08:13 -07:00