Anders Kaseorg
b953584d45
messages_overlay_ui: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:49 -07:00
Anders Kaseorg
eddf79fca2
message_viewport: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:49 -07:00
Anders Kaseorg
ad763ee7a7
message_list_data: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:49 -07:00
Anders Kaseorg
d8a7d65647
markdown: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:49 -07:00
Anders Kaseorg
74bfa62d78
left_sidebar_navigation_area: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:49 -07:00
Anders Kaseorg
f15c2c5dfd
inbox_ui: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:49 -07:00
Anders Kaseorg
6a429603ad
i18n: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:49 -07:00
Anders Kaseorg
eedde08f24
hash_util: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:49 -07:00
Anders Kaseorg
fc17821119
hash_parser: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:48 -07:00
Anders Kaseorg
da7d8b902b
filter: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:48 -07:00
Anders Kaseorg
beef5d259b
dropdown_widget: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:48 -07:00
Anders Kaseorg
7303851fd5
drafts: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:48 -07:00
Anders Kaseorg
ff23f79550
copy_and_paste: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:48 -07:00
Anders Kaseorg
e50a115d6f
composebox_typeahead: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:48 -07:00
Anders Kaseorg
a1ca665119
compose_ui: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:48 -07:00
Anders Kaseorg
6eec89ab96
compose_reply: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:48 -07:00
Anders Kaseorg
cbffc10e9e
compose_fade: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:48 -07:00
Anders Kaseorg
468da9ed23
compose_actions: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:48 -07:00
Anders Kaseorg
015e3917ac
common: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:48 -07:00
Anders Kaseorg
5a4b0420d1
buddy_list: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:48 -07:00
Anders Kaseorg
6cd8c9bb8c
bot_data: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:48 -07:00
Anders Kaseorg
8cec7dd917
bootstrap_typeahead: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:48 -07:00
Anders Kaseorg
9ad8ca4223
blueslip_stacktrace: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:48 -07:00
Anders Kaseorg
284beed889
billing/sponsorship: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:48 -07:00
Anders Kaseorg
c2c2e0b9ea
billing/remote_billing_auth: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:48 -07:00
Anders Kaseorg
01677db59e
attachments_ui: Fix TypeScript noUncheckedIndexedAccess errors.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:54:48 -07:00
Anders Kaseorg
9b711cda20
tippy: Use namespace import for tippy.js.
...
Names like “delegate”, “Instance”, “Placement”, “Props”, and
“ReferenceElement” are much too generic to make sense as named
imports.
The downside is that we now need to write tippy.default(…) instead of
tippy(…) (because ES module namespace objects cannot be callable), but
that cost is worthwhile.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 15:45:46 -07:00
Aman Agrawal
817bffe6b1
message_list: Rename `narrowed` property.
...
We rename it for clarity so that someone new to the codebase
knows instantly what it is checking.
2024-05-30 11:41:13 -07:00
Aman Agrawal
71341d282e
narrow: Remove last remains of was_narrowed_already.
...
This doesn't seem useful even for sentry logs since they
will already contain the full hash change history.
Rest of it was removed in 240f7b53b2
.
2024-05-30 11:41:13 -07:00
roanster007
7b1a5d84fc
refactor: Extract the methods called post narrow message list update.
...
This commit extracts various methods called post the current
message list is updated in "narrow.js" such as update_unread_banner,
handle_post_view_change, etc. into a separate method --
"handle_post_message_list_change".
This allows us to be able to call these methods independently
in case we need to update the filter and the corresponding
message lists.
This is a preparatory commit to #30114 .
2024-05-30 11:37:13 -07:00
Varun Singh
50e0f336f0
settings_streams: Fix error thrown when adding 'default-channels'.
...
The 'Select channel' dropdown in 'Add default channels' modal is
the LAST dropdown element on the modal and it does not contain
`data-stream-id` attribute.
.attr('data-stream-id') would return undefined for this element
and as a result the returned `Set` would have its last element a
`NaN` --- passing a `NaN` inside 'data' field of 'channel.post' threw
an error.
We tweaked the selector string to selectively map over the elements with
'data-stream-id' attribute.
Also we removed '.toString()' converting stream-id to a string (stream-id is a
'number' type).
2024-05-30 10:53:19 -07:00
Anders Kaseorg
4d8e5b5029
5xx: Fix development server preview of 500 error page.
...
This can be viewed at http://localhost:9991/webpack/5xx.html on the
development server.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 10:49:03 -07:00
Anders Kaseorg
27a993a504
stats: Make sent_data_schema specifically expect human and bot keys.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-30 10:01:59 -07:00
Aman Agrawal
e74dd93b52
5xx: Add a comment explaining how CSS is applied to this page.
2024-05-30 09:12:59 -07:00
Aman Agrawal
4811dd3ffd
Revert "5xx: Remove css classes and duplicate div tags."
...
This reverts commit eada57921e
.
This does have CSS applied to it via webpack.
See
```
new HtmlWebpackPlugin({
filename: "5xx.html",
template: "html/5xx.html",
chunks: ["error-styles"],
}),
```
2024-05-30 09:12:59 -07:00
Anders Kaseorg
7377d3fab9
topic_generator: Fix types of get_next_stream, get_prev_stream.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-29 23:33:27 -07:00
Anders Kaseorg
c20af83770
people: Fix get_custom_fields_by_type type.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-29 23:33:11 -07:00
Anders Kaseorg
a01d68e838
people: Rename ProfileData type to singular ProfileDatum.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-29 23:33:11 -07:00
Anders Kaseorg
ec199082fd
types: Move Submessage to submessage.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-05-29 17:47:09 -07:00
evykassirer
48fc0bc750
message_helper: Convert module to typescript.
2024-05-29 16:45:36 -07:00
evykassirer
7364c02ed6
message_helper: Set clean reactions when processing the raw message.
2024-05-29 16:45:36 -07:00
evykassirer
28107eb913
message_helper: Be more explicit about converting subject to topic.
2024-05-29 16:45:36 -07:00
evykassirer
297d393539
message_helper: Only convert subject to topic for stream messages.
...
There was a stale comment here saying we needed to do this for
private messages too, but `convert_message_topic` only modifies
`message` if its type is "stream".
2024-05-29 16:45:36 -07:00
evykassirer
50f5cf9ad8
message booleans: Return new message instead of mutating a raw message.
2024-05-29 16:45:36 -07:00
evykassirer
59a743de01
reify_message_id: Save id on most up-to-date message object.
...
Previously we relied on `echo.reify_message_id` to set the new
`id` and `locally_echoed` value, but it was setting this on
the message stored in `waiting_for_id`, which isn't guaranteed
to be the same as the message in the message store. Once
`process_new_message` stops mutating the message it gets and
returns a new message object, this would have caused a bug.
2024-05-29 16:45:36 -07:00
evykassirer
bab1dc5d9c
message tests: Don't assume process_new_message mutates the message.
...
We already changed callsites in the codebase to use the message
returned from `process_new_message` instead of assuming the raw
message passed in will be mutated. This fixes a few remaining tests.
2024-05-29 16:45:36 -07:00
evykassirer
61371868ad
message_store: Mark optional attributes as optional.
...
These aren't set when the Message object is first created
and only used within `message_list_view`, so they should be
optional.
2024-05-29 16:45:36 -07:00
evykassirer
26dbb953e0
people: Remove line for type of message that can't exist.
...
This will help us with a code coverage issue in an upcoming
commit.
2024-05-29 16:45:36 -07:00
evykassirer
854b3868ac
message: Remove unused star_status attribute.
...
Based on git log -S 'starred_status', it’s been unused since
4bf16ca9cc
(#22746 ).
2024-05-29 16:45:36 -07:00
Aman Agrawal
eada57921e
5xx: Remove css classes and duplicate div tags.
...
Since this file doesn't link any stylesheet, no CSS is applied to
these classes.
Tested change by pasting the content of it in `link_malformed`
and rendering that template using a malformed email confirmation link.
2024-05-29 09:37:25 -07:00