From 44845805cae4134fa4e485b2a8d846de0841d5fc Mon Sep 17 00:00:00 2001 From: Eduardo Date: Thu, 9 Nov 2023 15:20:12 -0800 Subject: [PATCH 1/2] PSP-7103 : Change main menu "Management" to "Leases & Licenses" (#3586) Co-authored-by: Eduardo Herrera --- .../layout/SideNavBar/LeaseAndLicenses.tsx | 4 ++-- .../src/components/layout/SideNavBar/NavIcon.tsx | 5 ++++- .../layout/SideNavBar/SideNavbar.test.tsx | 14 +++++++------- .../components/layout/SideNavBar/SideNavbar.tsx | 2 +- .../__snapshots__/SideNavbar.test.tsx.snap | 4 ++-- 5 files changed, 16 insertions(+), 13 deletions(-) diff --git a/source/frontend/src/components/layout/SideNavBar/LeaseAndLicenses.tsx b/source/frontend/src/components/layout/SideNavBar/LeaseAndLicenses.tsx index 297d9465e8..94d871dc97 100644 --- a/source/frontend/src/components/layout/SideNavBar/LeaseAndLicenses.tsx +++ b/source/frontend/src/components/layout/SideNavBar/LeaseAndLicenses.tsx @@ -19,7 +19,7 @@ export const LeaseAndLicenses = ({ onLinkClick }: ISideTrayPageProps) => { return ( <> - Management + Leases & Licenses {hasClaim(Claims.LEASE_VIEW) && ( Manage Lease/License Files @@ -38,7 +38,7 @@ export const LeaseAndLicenses = ({ onLinkClick }: ISideTrayPageProps) => {

Aggregated Lease & License Payments

-

Lease and License Payments by Fiscal Year

+

Lease & License Payments by Fiscal Year

)} diff --git a/source/frontend/src/components/layout/SideNavBar/NavIcon.tsx b/source/frontend/src/components/layout/SideNavBar/NavIcon.tsx index c120ff439f..236a1b8df6 100644 --- a/source/frontend/src/components/layout/SideNavBar/NavIcon.tsx +++ b/source/frontend/src/components/layout/SideNavBar/NavIcon.tsx @@ -27,7 +27,10 @@ export const NavIcon = ({ icon, text, showText, onClick, roles, claims }: INavIc _.find(claims, (claim: Claims) => hasClaim(claim)); return (!roles?.length && !claims?.length) || displayIcon ? ( - + {icon} diff --git a/source/frontend/src/components/layout/SideNavBar/SideNavbar.test.tsx b/source/frontend/src/components/layout/SideNavBar/SideNavbar.test.tsx index 26c3beffe7..948458bd06 100644 --- a/source/frontend/src/components/layout/SideNavBar/SideNavbar.test.tsx +++ b/source/frontend/src/components/layout/SideNavBar/SideNavbar.test.tsx @@ -50,8 +50,8 @@ describe('SideNavbar display and logic', () => { const { getByTitle, queryByText, getByTestId } = renderComponent(); await waitFor(async () => { expect(getByTitle('expand')).toBeInTheDocument(); - expect(queryByText('Management')?.clientWidth).toBe(0); - expect(getByTestId('nav-tooltip-management')).toContainHTML('svg'); + expect(queryByText('Leases & Licenses')?.clientWidth).toBe(0); + expect(getByTestId('nav-tooltip-leases&licenses')).toContainHTML('svg'); }); }); @@ -73,8 +73,8 @@ describe('SideNavbar display and logic', () => { userEvent.click(expandButton); }); await waitFor(async () => { - expect(getByTestId('nav-tooltip-management')).toContainHTML('svg'); - expect(getByText('Management')).toBeInTheDocument(); + expect(getByTestId('nav-tooltip-leases&licenses')).toContainHTML('svg'); + expect(getByText('Leases & Licenses')).toBeInTheDocument(); }); }); @@ -118,7 +118,7 @@ describe('SideNavbar display and logic', () => { const { getByText, getByTestId } = renderComponent({ roles: [Roles.SYSTEM_ADMINISTRATOR], }); - const managementButton = getByTestId('nav-tooltip-management'); + const managementButton = getByTestId('nav-tooltip-leases&licenses'); await act(async () => { userEvent.click(managementButton); }); @@ -131,7 +131,7 @@ describe('SideNavbar display and logic', () => { const { getByTestId, getByTitle } = renderComponent({ roles: [Roles.SYSTEM_ADMINISTRATOR], }); - const managementButton = getByTestId('nav-tooltip-management'); + const managementButton = getByTestId('nav-tooltip-leases&licenses'); await act(async () => { userEvent.click(managementButton); }); @@ -148,7 +148,7 @@ describe('SideNavbar display and logic', () => { const { getByTestId, getByTitle } = renderComponent({ roles: [Roles.SYSTEM_ADMINISTRATOR], }); - const managementButton = getByTestId('nav-tooltip-management'); + const managementButton = getByTestId('nav-tooltip-leases&licenses'); await act(async () => { userEvent.click(managementButton); }); diff --git a/source/frontend/src/components/layout/SideNavBar/SideNavbar.tsx b/source/frontend/src/components/layout/SideNavBar/SideNavbar.tsx index 595953f5d7..8836974577 100644 --- a/source/frontend/src/components/layout/SideNavBar/SideNavbar.tsx +++ b/source/frontend/src/components/layout/SideNavBar/SideNavbar.tsx @@ -54,7 +54,7 @@ export const SideNavBar = () => { setTrayPage(SidebarContextType.LEASE)} icon={} - text="Management" + text="Leases & Licenses" showText={expanded} /> From fbfd7046bd9622f3ff04b334cc5d35b64a5976d5 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Thu, 9 Nov 2023 23:20:39 +0000 Subject: [PATCH 2/2] CI: Bump version to v4.0.0-67.2 --- source/backend/api/Pims.Api.csproj | 4 ++-- source/frontend/package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/source/backend/api/Pims.Api.csproj b/source/backend/api/Pims.Api.csproj index ff36fd3e57..e4a04ba4e4 100644 --- a/source/backend/api/Pims.Api.csproj +++ b/source/backend/api/Pims.Api.csproj @@ -2,8 +2,8 @@ 0ef6255f-9ea0-49ec-8c65-c172304b4926 - 4.0.0-67.1 - 4.0.0-67.1 + 4.0.0-67.2 + 4.0.0-67.2 4.0.0.67 true 16BC0468-78F6-4C91-87DA-7403C919E646 diff --git a/source/frontend/package.json b/source/frontend/package.json index e84197567b..c57595a9be 100644 --- a/source/frontend/package.json +++ b/source/frontend/package.json @@ -1,6 +1,6 @@ { "name": "frontend", - "version": "4.0.0-67.1", + "version": "4.0.0-67.2", "private": true, "dependencies": { "@bcgov/bc-sans": "1.0.1",