From 06b161d0d47066dfddf4889e9eb08c84b4b50790 Mon Sep 17 00:00:00 2001 From: Pedro Gonzalez Gomez Date: Thu, 27 Mar 2025 11:46:04 +0100 Subject: [PATCH] mgr/dashboard: carbonize smb tabs also removes share tab as was the only one in favour of title and description Fixes: https://tracker.ceph.com/issues/70695 Signed-off-by: Pedro Gonzalez Gomez --- .../smb-cluster-list.component.html | 2 ++ .../smb-cluster-tabs.component.html | 16 ++-------- .../smb-cluster-tabs.component.spec.ts | 27 ----------------- .../smb-join-auth-list.component.html | 2 ++ .../smb-share-list.component.html | 2 ++ .../ceph/smb/smb-tabs/smb-tabs.component.html | 30 ------------------- .../smb-usersgroups-list.component.html | 2 ++ .../datatable/table/table.component.html | 11 +++++++ .../shared/datatable/table/table.component.ts | 4 +++ .../frontend/src/styles/_carbon-defaults.scss | 8 +++++ 10 files changed, 34 insertions(+), 70 deletions(-) diff --git a/src/pybind/mgr/dashboard/frontend/src/app/ceph/smb/smb-cluster-list/smb-cluster-list.component.html b/src/pybind/mgr/dashboard/frontend/src/app/ceph/smb/smb-cluster-list/smb-cluster-list.component.html index 269152a257ee6..3417d30adb62b 100644 --- a/src/pybind/mgr/dashboard/frontend/src/app/ceph/smb/smb-cluster-list/smb-cluster-list.component.html +++ b/src/pybind/mgr/dashboard/frontend/src/app/ceph/smb/smb-cluster-list/smb-cluster-list.component.html @@ -1,5 +1,7 @@ - - - - - + diff --git a/src/pybind/mgr/dashboard/frontend/src/app/ceph/smb/smb-cluster-tabs/smb-cluster-tabs.component.spec.ts b/src/pybind/mgr/dashboard/frontend/src/app/ceph/smb/smb-cluster-tabs/smb-cluster-tabs.component.spec.ts index c9c8bb9c52423..0f1dc6cc8529d 100644 --- a/src/pybind/mgr/dashboard/frontend/src/app/ceph/smb/smb-cluster-tabs/smb-cluster-tabs.component.spec.ts +++ b/src/pybind/mgr/dashboard/frontend/src/app/ceph/smb/smb-cluster-tabs/smb-cluster-tabs.component.spec.ts @@ -1,8 +1,6 @@ import { ComponentFixture, TestBed } from '@angular/core/testing'; import { SmbClusterTabsComponent } from './smb-cluster-tabs.component'; -import { CLUSTER_RESOURCE, SMBCluster } from '../smb.model'; -import { By } from '@angular/platform-browser'; describe('SmbClusterTabsComponent', () => { let component: SmbClusterTabsComponent; @@ -21,29 +19,4 @@ describe('SmbClusterTabsComponent', () => { it('should create', () => { expect(component).toBeTruthy(); }); - - it('should not render anything if selection is falsy', () => { - component.selection = null; - fixture.detectChanges(); - - const tabsElement = fixture.debugElement.query(By.css('cds-tabs')); - expect(tabsElement).toBeNull(); - }); - - const selectedSmbCluster = (clusterId: string) => { - const smbCluster: SMBCluster = { - resource_type: CLUSTER_RESOURCE, - cluster_id: clusterId, - auth_mode: 'user' - }; - return smbCluster; - }; - - it('should render cds-tabs if selection is truthy', () => { - component.selection = selectedSmbCluster('fooBar'); - fixture.detectChanges(); - - const tabsElement = fixture.debugElement.query(By.css('cds-tabs')); - expect(tabsElement).toBeTruthy(); - }); }); diff --git a/src/pybind/mgr/dashboard/frontend/src/app/ceph/smb/smb-join-auth-list/smb-join-auth-list.component.html b/src/pybind/mgr/dashboard/frontend/src/app/ceph/smb/smb-join-auth-list/smb-join-auth-list.component.html index 56ee93b88da74..3f3da5e1e09ee 100644 --- a/src/pybind/mgr/dashboard/frontend/src/app/ceph/smb/smb-join-auth-list/smb-join-auth-list.component.html +++ b/src/pybind/mgr/dashboard/frontend/src/app/ceph/smb/smb-join-auth-list/smb-join-auth-list.component.html @@ -1,4 +1,6 @@ - Clusters - - Logical management units that may map to one or more managed Samba service - - - - - Active directory access resources - - Logical management units for authorization on active directory (AD) servers - - - - - Standalone access resources - - Logical management units for authorization on Standalone servers - - - + +

+ {{headerTitle}} +

+

+ {{headerDescription}} +

+