From: Sagar Gopale Date: Thu, 25 Jun 2026 07:07:25 +0000 (+0530) Subject: mgr/dashboard: Align RGW Account Role forms with updated UX design X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=5f5e4093ad3dbe306593999a6b1ee0410f079af3;p=ceph.git mgr/dashboard: Align RGW Account Role forms with updated UX design Signed-off-by: Sagar Gopale --- diff --git a/src/pybind/mgr/dashboard/frontend/cypress/e2e/rgw/accounts.po.ts b/src/pybind/mgr/dashboard/frontend/cypress/e2e/rgw/accounts.po.ts index f58932982fd..f172c6265cd 100644 --- a/src/pybind/mgr/dashboard/frontend/cypress/e2e/rgw/accounts.po.ts +++ b/src/pybind/mgr/dashboard/frontend/cypress/e2e/rgw/accounts.po.ts @@ -32,6 +32,8 @@ export class AccountsPageHelper extends PageHelper { // Enter email cy.get('#email').type(account.email); + cy.contains('button', 'Show advanced settings').click(); + // Enter max buckets cy.get('input#max_buckets').should('exist').should('have.value', '1000'); @@ -49,7 +51,7 @@ export class AccountsPageHelper extends PageHelper { cy.get('input#account_checkbox_input').check({ force: true }); // Click the create button and wait for account to be made - cy.contains('button', 'Create Account').click(); + cy.contains('button', 'Create account').click(); this.getFirstTableCell(account.name).should('have.text', account.name); this.getTableRow(account.name).within(() => { @@ -106,6 +108,8 @@ export class AccountsPageHelper extends PageHelper { // Enter email cy.get('#email').clear().type(account.email); + cy.contains('button', 'Show advanced settings').click(); + // Enter max buckets this.selectOption('max_buckets_mode', 'Custom'); cy.get('input#max_buckets').click().clear().type(account.max_buckets); @@ -129,7 +133,7 @@ export class AccountsPageHelper extends PageHelper { cy.get('input#account_quota_max_objects').clear().type('200'); // Click the create button and wait for account to be made - cy.contains('button', 'Edit Account').click(); + cy.contains('button', 'Edit account').click(); this.getTableRow(account.name).within(() => { cy.get('td').eq(this.columnIndex.tenant).should('have.text', account.tenant); @@ -215,6 +219,8 @@ export class AccountsPageHelper extends PageHelper { .find('.cds--form-requirement') .should('have.text', ' Please enter a valid email '); + cy.contains('button', 'Show advanced settings').click(); + cy.get('input#max_buckets').click().clear().type('0').blur(); cy.get('label[for=max_buckets]') @@ -252,6 +258,8 @@ export class AccountsPageHelper extends PageHelper { .find('.cds--form-requirement') .should('have.text', ' Please enter a valid email '); + cy.contains('button', 'Show advanced settings').click(); + cy.get('input#max_buckets').click().clear().type('0').blur(); cy.get('label[for=max_buckets]') diff --git a/src/pybind/mgr/dashboard/frontend/cypress/e2e/rgw/roles.po.ts b/src/pybind/mgr/dashboard/frontend/cypress/e2e/rgw/roles.po.ts index 611a060236e..4ec20aa1105 100644 --- a/src/pybind/mgr/dashboard/frontend/cypress/e2e/rgw/roles.po.ts +++ b/src/pybind/mgr/dashboard/frontend/cypress/e2e/rgw/roles.po.ts @@ -38,7 +38,7 @@ export class RolesPageHelper extends PageHelper { cy.get('cds-number[formControlName="max_session_duration"] input') .clear() .type(maxSessionDuration.toString()); - cy.get('cds-modal').contains('button', 'Edit').click(); + cy.get('cds-modal').contains('button', 'Save').click(); cy.get('cds-modal').should('not.exist'); this.getRolesTableCell(this.columnIndex.roleName, name) diff --git a/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-account-role-form/rgw-account-role-form.component.html b/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-account-role-form/rgw-account-role-form.component.html index 11fff876688..641b3c9c94e 100644 --- a/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-account-role-form/rgw-account-role-form.component.html +++ b/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-account-role-form/rgw-account-role-form.component.html @@ -1,19 +1,38 @@ -

{{ accountName }}

-

{{ mode }} role

+ @if (isEdit) { +

Role

+

Edit session duration

+

+ Update the maximum session duration for this role. +

+ } @else { +

User account

+

Create role

+

+ Role grants temporary permissions to trusted users, applications, or services. +

+ }
+ @if (!isEdit) { + +
+ +

{{ accountName }}

+
+
Role name
+ + } @else { +
+ +

+ + {{ form.getValue('role_name') }} + +

+ +
+ User account:
+ {{ accountName }} +
+
+
+ } + @if (!isEdit) {
Path + helperText='Specifies the hierarchy or namespace for the role. Use "/" for the root path.' + i18n-helperText + >Role path @@ -72,7 +118,8 @@ labelInputID="role_assume_policy_doc" [invalid]="policyDoc.isInvalid" [invalidText]="policyError" - cdRequiredField="Trust Policy" + helperText="Defines which principals can assume this role. Enter a valid JSON policy document." + i18n-helperText >Trust policy