Commit Graph

56633 Commits

Author SHA1 Message Date
shashank-23002 d6219e93a8 popover: Rename user-card-status-text. 2024-02-20 18:10:38 -08:00
shashank-23002 6caacbcd07 tooltips: Fix status-emoji tooltip for user-card popover.
This tooltip seems to have been broken when #user_info_popover was
renamed to the user card popover.
2024-02-20 18:10:38 -08:00
shashank-23002 865f886f56 tooltips: Add a dedicated tooltip for status-emoji.
Fixes: #26772
2024-02-20 18:10:38 -08:00
Mateusz Mandera 8349437aff ldap: Clarify order of role processing by AUTH_LDAP_USER_FLAGS_BY_GROUP. 2024-02-20 16:18:43 -08:00
Mateusz Mandera 834dbd552b remote_billing: Make handle_customer_migration_... more robust.
The logic in the case where there's only one realm and the function
tries to migrate the server's plan to it, had two main unhandled edge
cases that would throw exceptions:
1.
```
        remote_realm = RemoteRealm.objects.get(
            uuid=realm_uuids[0], plan_type=RemoteRealm.PLAN_TYPE_SELF_MANAGED
        )
```

This could throw an exception if the RemoteRealm exists, but has an
active e.g. Legacy plan. Then there'd be no object matching the
plan_type in the query, raising RemoteRealm.DoesNotExist.

2. If the RemoteRealm had e.g. a Legacy plan in the past, that's now
   expired, then it'd have a Customer object. Meaning that the attempt
   to move the server's customer to the realm:
   `server_plan.customer = remote_realm_customer`
   would trigger an IntegrityError since a RemoteRealm can't have two
   Customer objects.

In simple cases the situation in (2) can still be easily migrated, by
moving the plan from the server's customer to the realm's customer.
2024-02-20 16:02:03 -08:00
Mateusz Mandera 5e6f4faad2 test_remote_billing: Rename server_on_active_plan_error helper arg.
This is kind of too specific, allowing testing for only one single error
when accessing signed_auth_url. Instead, this should use a general
pattern, which will allow other tests to use this to assert other kinds
of error responses that may be returned.
2024-02-20 16:02:03 -08:00
Mateusz Mandera 1c61bb2fad remote_billing: Fix two tests that shouldn't be asserting in a loop.
It doesn't make sense to run a loop over "all" query results, when those
results are just two, and each of them has its own distinct asserts.

That for loop is there probably due to copying the structure of the
earlier test_transfer_legacy_plan_from_server_to_all_realms test, for
which the loop does make sense.
2024-02-20 16:02:03 -08:00
Lauryn Menard 68f02da82e installation-activity: Fix ARR value in total row.
In commit ff8552269d, when we moved the links to the first column
of the activity charts, we missed updating the column for the ARR
total.
2024-02-20 15:57:06 -08:00
Tim Abbott 7d9c82cbea docs: Document restarts after changing zulip.conf. 2024-02-20 15:49:46 -08:00
David Rosa 2b95068406 docs: Split /production/deployment.html into multiple pages.
- Makes "Deployment options" easier to navigate by splitting the
  "Reverse proxies" and "System configuration" sections out into
  dedicated pages.

Fixes #28928.
2024-02-20 15:49:46 -08:00
Lauryn Menard b9c4a8a811 support: Add CSS formatting for form areas on support views. 2024-02-20 15:46:55 -08:00
Lauryn Menard b6d50c158d support: Add CSS grid for confirmation objects in query results. 2024-02-20 15:46:55 -08:00
Lauryn Menard b74a8a5ff5 support: Add CSS grid for user and user realm. 2024-02-20 15:46:55 -08:00
Lauryn Menard 8c5325fc2c remote-support: Add CSS grid for remote server and remote realms. 2024-02-20 15:46:55 -08:00
Lauryn Menard 439e88e251 support: Remove relative positioning for form elements.
Prep commit for adding a grid layout for some query response data.
2024-02-20 15:46:55 -08:00
Aman Agrawal e6718369d6 css: Apply fa-chevron-down CSS to zulip-icon-chevron-down.
This was missed as part of #27577 migration.
2024-02-20 15:16:56 -08:00
N-Shar-ma 8002f0db8f compose: Fix bug where sometimes message draft remained post sending it.
Now whenever we initiate sending a message, we save / update its draft,
which is deleted on a successful send. Earlier, we did this only for
locally echoed messages. Hence a non locally echoed message's draft
would remain, if created in the timeframe between initiating send and
receiving the same message from the server, which can be significant
for slow connections.
2024-02-20 11:59:46 -08:00
Aman Agrawal 90e67f7d75 upgrade: Fix spacing issue for fixed plan upgrade page. 2024-02-20 11:51:32 -08:00
Aman Agrawal 949379581e billing: Add separate entry point for billing login pages.
We just exclude upgrade.ts from the imports to avoid page_params
being imported which results in an error.

s
2024-02-20 11:51:32 -08:00
shashank-23002 5803d4afec clipboard: Align click to copy button inside spoiler tag.
Fixes: #20712
2024-02-20 10:18:43 -08:00
Aman Agrawal 0c6dfd1e5e message_actions_popover: Select message being moved.
This helps keep the content of this message in the move messages
modal relevant.
2024-02-20 09:29:26 -08:00
Aman Agrawal 4d1bb762be css: Add 25px to content width on right for chevron-down icon.
This fixes chevron-down icon overlapping with content when content
occupies full width of the select element.
2024-02-20 09:29:26 -08:00
Varun Singh c91ca3eca8 message_live_update: Convert module to TypeScript. 2024-02-20 08:30:04 -08:00
Varun Singh 5fd6a819d4 message_lists: Add 'rerender_messages' function to type. 2024-02-20 08:30:04 -08:00
Varun Singh d432b5e36a message_lists: Add 'rerender_view' function to type. 2024-02-20 08:30:04 -08:00
Prakhar Pratyush a20ce627d9 stripe: Add a check to create invoices only for paid plans.
In 'invoice_plan()', the primary way to not create
an invoice for a plan is to not have any new ledger entry.

This commit adds a 'self.on_paid_plan()' check which is
an extra layer of defense to avoid creating any invoices
for customers not on paid plan. It saves a DB query too.
2024-02-20 08:25:49 -08:00
evykassirer 23795ca153 message_edit_history: Convert module to typescript. 2024-02-19 21:39:40 -08:00
evykassirer a8be874f70 state_data: Add realm_allow_edit_history. 2024-02-19 21:39:40 -08:00
Mateusz Mandera 616527e73e zilencer: Exclude realm_locally_deleted in get_human_user_realm_uuids.
Just like deactivated realms should be excluded, so should locally
deleted realms.

In particular, failure to exclude locally deleted realms breaks
handle_customer_migration_from_server_to_realms.
2024-02-19 20:27:24 -08:00
Mateusz Mandera be03dabf76 zilencer: Implement do_reactivate_remote_server utility function.
The inverse of do_deactivate_remote_server. It's just flipping the
.deactivated flag, but we also should have an AuditLog for these events.
2024-02-19 20:26:47 -08:00
Anders Kaseorg cc8a4636ba namespace: Prevent direct mutation of ES modules in tests.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-02-19 21:20:35 -05:00
Anders Kaseorg 10892f1d60 tests: Fix direct mutation of ES modules again, again.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-02-19 21:20:35 -05:00
Karl Stolley 29dd61c20c bootstrap: Remove pre styles.
Happily, every last CSS property in these styles is already
described for the places <pre> appears in the Zulip UI:

1. In rendered message markdown
2. In the compose preview
3. In the information overlay (Message formatting)
2024-02-19 18:15:26 -08:00
Tim Abbott 2e1ed4431a corporate: Fix plan precedence issues with expired plans.
RemoteRealm customer takes precedence over RemoteServer
in general. But if an inactive plan is associated with
RemoteRealm and an active plan with RemoteServer, the
ACTIVE plan takes precendence.

Co-authored-by: Prakhar Pratyush <prakhar@zulip.com>
2024-02-19 17:58:49 -08:00
Anders Kaseorg 2c799125ea bundles: Remove unnecessary imports of effect-free modules.
Some of these may have once been necessary to enforce an ordering on
cyclic imports, but we’ve fixed all of those now.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-02-19 17:55:40 -08:00
Karl Stolley 384e28c8e2 bootstrap: Remove li style.
The `line-height` value is set to `inherit` in zulip.css, rendering
this line moot. `inherit` will always force list items to take
their line height from the nearest ancestor that sets one.
2024-02-19 17:53:50 -08:00
Karl Stolley 6073507230 bootstrap: Remove q styles.
There is no evidence of the <q> (quote) element in use in the
Zulip UI, nor that any of the Python-Markdown syntax generates them
either.
2024-02-19 17:51:10 -08:00
Anders Kaseorg 976987f9a3 webpack: Remove extraneous inclusions of page_params.
Commit a4938d3760 (#28971) fixed the
order-sensitivity of these modules, so it suffices to just import them
where they are used.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-02-19 15:10:02 -05:00
Aman Agrawal f6b1fe9f36 billing: Remove unused page_params on event_status page.
a4938d3760 introduced assertions
for page_params for which they were used. This caused the
assertion to fail on event_status page making the page not work.
Removed the page_params from running on event_status page to fix it.
2024-02-19 08:41:34 -08:00
Anders Kaseorg e568064f4e page_params: Set and expect state_data = null for spectators.
Fix a ZodError when spectators load the app, introduced by commit
a4938d3760 (#28971).

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-02-19 03:03:58 -05:00
Anders Kaseorg a5c055ae82 state_data: Rename Term type to NarrowTerm.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-02-17 00:02:38 -08:00
Anders Kaseorg a4938d3760 page_params: Parse page_params and state_data with Zod.
This establishes a runtime check that their types continue to reflect
reality going forward.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-02-17 00:02:38 -08:00
Alya Abbott 4f1659fe8f billing: Make push notifications error message more clear. 2024-02-16 16:01:53 -08:00
Anders Kaseorg 273453d285 lint: Remove .lock extension from frontend group.
Commit 3a27b12a7d (#24731) migrated
yarn.lock to pnpm-lock.yaml.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-02-16 18:50:17 -05:00
Sayyed Arib Hussain 8e39123839 message_view_header: Manage no description in message_view_header.
This commit modifies the behavior of the message view header
when a stream's description is empty. Previously, it displayed
"(no description)". With this change, if the user is an admin
or owner (i.e., has permission to update the description), it
will now display a "Add description" link to the settings. If
the user does not have these permissions, it will display nothing.

Fixes #28851

Signed-off-by: Sayyed Arib Hussain <sayyedaribhussain4321@gmail.com>
2024-02-16 15:41:27 -08:00
Tim Abbott 2a59edda53 version: Update version and changelog following 8.2 release. 2024-02-16 15:31:54 -08:00
Anders Kaseorg ac68996ac3 sentry: Avoid early reads from state data.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2024-02-16 15:12:42 -08:00
Aman Agrawal 176c15f74b billing: Redirect user to login page if session expires.
If user makes an AJAX request but their session is expired, we
redirect user to the login page.
2024-02-16 14:56:26 -08:00
Aman Agrawal 98868b7f4a billing: Take user to default page if next_page is invalid.
Here invalid is more or less uncommon since there are a lot of
next_page that are valid for a logged in user.
2024-02-16 14:56:26 -08:00
Lauryn Menard 0c17b90fc5 remote-support: Fix last push notification sent field.
Instead of displaying the end of the day interval for the latest
count stat update for push notifications forwarded on the bouncer,
we display the start of the day interval and format it as a date
instead of a date and time.
2024-02-16 14:49:34 -08:00