Fix extraneous shadow at bottom of link preview
in stream messages in dark theme, in private
messages for both themes and in mentions, group
mentions and direct mentions.
This is done by applying the same color, used
in the background, to the shadow. There are CSS
variables that hold the values of the background
color.
Fixes#28853.
Adds an option to the generate bot URL modal to filter for events
that will trigger notifications. This option is conditionally
displayed when only `all_event_types` is defined for the selected
integration.
If selected, the URL will display all events by default. There
are "check all" and "uncheck all" buttons to easily include or
remove all the events from the URL.
Fixes#27628.
Previously, the stream dropdown remained active regardless of whether
an integration type was selected.
This commit addresses the issue by disabling
the stream dropdown widget when no integration type is selected
Previously, when a topic name was included in the URL
and the user unchecked the button for including a
topic, the URL was not being updated accordingly.
Expands the check for setting the topic parameter for
the topic not being an empty string and having the
include topic option checked.
The padding on the sides of the Drafts button is reduced from 5 to 3px
at smaller width, so that it's not right up against the textareas when
hovered.
The text is also aligned to the Send button's edge, like at larger
widths.
Fixes#25964
We can fail to load emojiset if browser is unable to connect to
internet or fetch failed midway due to a network error. We simply
wait for browser to come back online and retry.
This contains two more complex changes:
- The default versions of sorter and matcher assume that ItemType is a
string. But the Typeahead class works on a generic ItemType and I'm
not aware of a way to assert that this function is only called for
typeaheads with string items. For `matcher`, we can assert that the
items are strings. `sorter` is now a required option instead of an
optional one that could fall back to the default.
- `element` can be either an `input` element or a `contenteditable`
`div`. We distinguish between them using `.is("[contenteditable]"))`
but TypeScript doesn't understand that. So we replaced `this.$element`
with `this.input_element` where `input_element` is an object with the
`$element` and also a `type` specifying which type of element it is
(input or contenteditable).
`final_items` is a list of `ItemType` so it doesn't
make sense to wrap it in `$()`. Intead of creating a
"jquery list of objects", we generate a list of JQuery
objects. I also removed the unused `_index` in the
`map` call.
`this.source` will always be of type `function`,
so we can remove the ternary statement. And `source`
always takes one argument, so we can remove the
second argument.
Previously, "This profile field is required." tooltip was visible on
all custom profile fields, including those that were not required.
This commit fixes that by targeting only the required fields.
Earlier, DM row remained highlighted when narrowed to different
part of left sidebar other than recent and inbox since on narrow
event, `handle_narrow_activate` wasn't properly handling unnarrow
events. It wasn't calling `update_private_messages` to update the
state of the DM list.
This commit fixes the behaviour by updating the state on narrowing
away from DM rows.
Fixes: zulip#27698.
Co-authored-by: Rinwaoluwa <peterodejobi9@gmail.com>
Earlier when users narrowed to recents or inbox, message_list.current
was updating to last dm row selected for first few filter checks in
'narrow_state' which in turn would set active_user_ids to last dm
row selected. This resulted in DM highlight lingering.
The narrow_state.filter is supposed to return undefined when narrowed
to recents or inbox.
This commit fixes the behaviour by setting 'current' undefined before
filter checks on narrow.
Fixes part of #27698.
The test data was not the correct representation of submessage's
content field. This caused the zod schema to throw error.
This is a temporary solution and eventually we have to move to an
efficient approach making the test data more representative and
accurate.
Discussion:
https://chat.zulip.org/#narrow/stream/6-frontend/topic/TypeScript.20migration/near/1766122