feat: Improve manual license management

Merged
DO
4mo ago
+1083-40

Proposed changes (including videos or screenshots)

Adds a Manage License flow to the Subscription page so admins can preview a license before applying it, and moves license management out of the Enterprise settings page.

What's new:

  • ManageLicenseModal — paste, upload (.txt), or drag-and-drop a license key. The key is validated in real time (debounced) so the admin can confirm it's valid before applying. Supports applying a new license and removing the current one (with a confirmation step).
  • Specific validation messages — rejected licenses map to actionable copy (expired, URL mismatch, limits exceeded, out of date range, undecodable) instead of a generic error.
  • License controls on the Plan card — shows Site URL, Hashed Site URL, and the license key with a manage/add action.
  • Enterprise settings page now redirects to the Subscription page, where license management lives.

How to test

  • Go to Admin → Subscription.
  • On the Plan card, use Add license / the manage (cog) action.
  • Paste, upload, or drop a license — confirm the status updates (valid / specific error) and that Apply is only enabled for a valid, non-current license.
  • Remove the current license and confirm the community-license flow.

Issue(s)

Steps to test or reproduce

Further comments

CORE-2104

Summary by CodeRabbit

  • New Features

    • Added a new license management flow in Subscription settings, including upload, validation, apply, and remove actions.
    • Added license file support with drag-and-drop, text input, and file preview.
    • Workspace details now show site URLs and license information with copy-to-clipboard actions.
    • The Enterprise settings area now directs users to manage licenses from Subscription settings.
  • Bug Fixes

    • Improved license validation feedback with clearer messages for invalid, expired, and unsupported licenses.