Commit Graph

55816 Commits

Author SHA1 Message Date
Alya Abbott 2732da2bb2 settings: Update description text in Settings > Topics panel. 2024-01-02 15:54:48 -08:00
Lauryn Menard ea1da738d6 support: Update how remote server information is organized.
Changes the emoji that highlights when a remote realm or server has
an active discount.

Adds a remote server UUID field to the remote server information.

Moves the 'has remote realms' field to be after the Zulip version
information, and adds an extra break there to visually highlight
that field as well as the following 'max monthly messages' field.
2024-01-02 13:16:35 -08:00
Lauryn Menard b9ca60ab9e support: Add date created field to remove server information.
Removes the last updated field and replaces it with the date the
remote server was created based on the audit log data.
2024-01-02 13:16:35 -08:00
Prakhar Pratyush a03f9078e5 test_stripe: Add migrate customer from server to realms E2E test. 2024-01-02 11:20:56 -08:00
Mateusz Mandera 367d552052 billing: Improve make_end_of_cycle_... interactions with audit logs.
- Make `self.write_to_audit_log` support a `background_update:
  bool=False` parameter that can be passed when code that might have an
  acting user happens to trigger a background update.
- Make `make_end_of_cycle_updates_if_needed` pass that parameter for its
  direct audit log writes.
- Audit code that `make_end_of_cycle_updates_if_needed` calls and make
  sure those write audit logs this way too.
- Pass the user in the `billing_page` code that had to avoid it as a
  workaround:
```
    # BUG: This should pass the acting_user; this is just working
    # around that make_end_of_cycle_updates_if_needed doesn't do audit
    # logging not using the session user properly.
    billing_session = RealmBillingSession(user=None, realm=user.realm)
```
2024-01-02 10:59:05 -08:00
evykassirer c0719e0285 pm_list_data: Convert module to typescript. 2024-01-02 10:27:02 -08:00
Lauryn Menard 481828e556 support: Exclude deactivated servers from search results. 2024-01-02 07:51:50 -08:00
Anders Kaseorg 06d439e0b2 typing_events: Fix early read of page_params.
For spectators,
page_params.server_typing_started_expiry_period_milliseconds has not
been initialized yet at module load time.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-01-01 17:39:10 -08:00
Anders Kaseorg 45c8dcc9c3 typing: Fix early read of page_params.
For spectators,
page_params.server_typing_started_wait_period_milliseconds and
page_params.server_typing_stopped_wait_period_milliseconds have not
been initialized yet at module load time.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-01-01 17:39:10 -08:00
Anders Kaseorg 80432c8c06 stream_create: Fix early read of page_params.
For spectators, page_params.realm_create_public_stream_policy,
page_params.server_web_public_streams_enabled,
page_params.realm_enable_spectator_access have not been initialized
yet at module load time.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-01-01 17:39:10 -08:00
Anders Kaseorg 8f069ac1d8 settings_profile_fields: Fix early read of page_params.
For spectators, page_params.custom_profile_field_types has not been
initialized yet at module load time.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-01-01 17:39:10 -08:00
Anders Kaseorg 88f0d6e710 docs: Fix reference to page_params.mandatory_topics.
Commit 64041e0da1 (#4628) renamed this.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-01-01 17:37:50 -08:00
Anders Kaseorg 8066405d9b tests: Fix incorrect reference to page_params.sent_by_me.
Commit 24a1f7b792 (#23056) introduced
this mistake; it has never existed.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-01-01 17:37:50 -08:00
Anders Kaseorg 2a69545bec page_params: Move initial_pointer and friends to message_fetch.
These aren’t sent by the server; they’re client-side global variables.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-01-01 17:37:50 -08:00
Anders Kaseorg e8e7142ed1 page_params: Move events_queue_expired to server_events.
This isn’t sent by the server; it’s a client-side global variable.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-01-01 17:37:50 -08:00
Mateusz Mandera bc8167db2a docs: Fix typo in mypy doc. 2024-01-01 17:36:13 -08:00
Lauryn Menard 9f009a2e63 support: Reformat percentages in attach discount success message. 2023-12-30 11:22:30 -08:00
Lauryn Menard ffd708ecaf support: Display next plan data on remote support view.
Currently, this will only be the case for legacy self-managed plans
that have scheduled a switch to either the Basic or Business plan.
2023-12-30 11:22:02 -08:00
Sahil Batra 8f795e22e8 settings: Fix discard button in groups UI in dark theme. 2023-12-30 11:15:30 -08:00
Prakhar Pratyush 1472aac750 docs: Update the URL for Stripe docs to install Stripe CLI locally. 2023-12-30 11:15:06 -08:00
Prakhar Pratyush 3dd9ba4e94 docs: Update 'set private key' step in billing (development) docs.
Earlier, the URL directed to live API keys. Updated the URL
to direct to 'test API keys'.

Also explicitly mentioned is to double check that the keys are
'test keys', in case Stripe changes the URL as it did before.
2023-12-30 11:15:06 -08:00
Anders Kaseorg 8514c8d739 page_params: Fix types of narrow, server_sentry_dsn, user_id.
page_params.narrow may be undefined, page_params.server_sentry_dsn may
be null but not undefined, and page_params.user_id may be 0 (for
spectators) but not undefined.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-12-29 14:16:19 -08:00
Anders Kaseorg 089c8f61c5 test_remote_billing: Use unordered comparison for deactivation test.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-12-29 14:12:43 -08:00
Anders Kaseorg a5d51a0895 people: Don’t reference nonexistent page_params.is_bot.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-12-29 13:05:30 -08:00
Anders Kaseorg 9703b4d70b login: Remove external_authentication_methods from page_params.
This was used by a work-in-progress social login implementation in
zulip-desktop that was reverted for security reasons and never
released.

https://github.com/zulip/zulip/pull/13782
https://github.com/zulip/zulip-desktop/pull/863

We replaced it by a secure implementation with a maintainable API.

https://github.com/zulip/zulip-desktop/pull/943

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-12-29 13:02:12 -08:00
Anders Kaseorg 711f6433cb docs: Correct certutil invocation for importing self-signed certificate.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-12-29 12:48:08 -08:00
sayyedarib b430ba2bd5 navbar_help_menu: Migrate module to typescript.
Signed-off-by: sayyedarib <sayyedaribhussain4321@gmail.com>
2023-12-29 12:15:08 -08:00
Anders Kaseorg 2cf8f1c063 page_params: Move page_load_time to zulip_test.
This isn’t sent by the server; it’s a client-side global variable.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-12-29 11:58:58 -08:00
evykassirer baf6c68ab8 starred_messages: Migrate module to typescript. 2023-12-28 18:24:40 -08:00
evykassirer baba72df91 compose_banner: Restrict banner to only JQuery, never htmlString.
Co-authored-by: Anders Kaseorg <anders@zulip.com>
2023-12-28 16:53:46 -08:00
evykassirer 1f21510dd4 compose_notifications: Convert module to typescript. 2023-12-28 16:53:46 -08:00
Varun Singh 62a636068e subscriber_api: Convert module to TypeScript. 2023-12-28 15:05:16 -08:00
evykassirer 6157d83d3a unread_ui: Convert module to typescript. 2023-12-28 11:26:37 -08:00
evykassirer 8d685d5b5a page params: Add furthest_read_time attribute. 2023-12-28 11:26:37 -08:00
evykassirer 5f5e77afd5 local_message: Convert module to typescript. 2023-12-27 23:23:36 -08:00
evykassirer b20694aa07 narrow_history: Convert module to typescript. 2023-12-27 23:12:09 -08:00
evykassirer e0a10c2d94 all_messages_data: Convert module to typescript. 2023-12-27 22:55:47 -08:00
evykassirer ccd5b4a813 narrow_state: Convert module to typescript. 2023-12-27 22:16:21 -08:00
evykassirer b7a28f1630 page params: Add narrow attribute. 2023-12-27 22:16:21 -08:00
evykassirer 0f1fa8e159 message_list_data: Potentially return undefined in first_unread_message_id. 2023-12-27 21:48:54 -08:00
evykassirer 0cf1d49fee message_list_data: Convert module to typescript. 2023-12-27 21:48:54 -08:00
evykassirer dc8d0ed861 message_lists: Convert module to typescript. 2023-12-27 20:44:58 -08:00
evykassirer e0fef6fdff narrow_title: Migrate module to typescript. 2023-12-27 20:39:53 -08:00
evykassirer 01abd96127 buddy_data: Convert module to typescript. 2023-12-27 15:53:39 -08:00
evykassirer 68f2535ebc recent senders: Convert module to typescript. 2023-12-27 14:05:35 -08:00
evykassirer 1f2ea95b9f recent senders: Use for loop instead of filter/if combination. 2023-12-27 14:05:35 -08:00
Anders Kaseorg 6e220f4dc1 eslint: Enable @typescript-eslint/method-signature-style.
For historical reasons, TypeScript ignores variance errors for method
shorthand type declarations even in strict mode.  Prefer the correctly
checked style.

https://typescript-eslint.io/rules/method-signature-style

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-12-26 17:30:33 -08:00
Anders Kaseorg b44daf080c list_widget: Remove unknown generic defaults.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-12-26 17:30:33 -08:00
Anders Kaseorg d7803db5c7 list_widget: Remove get.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-12-26 17:30:33 -08:00
Anders Kaseorg c1636ffc6f list_widget: Add missing generic parameters to handle_sort.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-12-26 17:30:33 -08:00