Skip to content

Commit 0145e69

Browse files
fix: [UIE-9933], [UIE-9935] - IAM: UX copy updates, breadcrumbs fix (linode#13259)
* fix: [UIE-9933], [UIE-9935] - IAM: UX copy updates, breadcrumbs fix * Added changeset: IAM Delegation: UX copy update, wrong breadcrumb fix
1 parent 25a4879 commit 0145e69

File tree

9 files changed

+37
-9
lines changed

9 files changed

+37
-9
lines changed
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@linode/manager": Fixed
3+
---
4+
5+
IAM Delegation: UX copy update, wrong breadcrumb fix ([#13259](https://github.com/linode/manager/pull/13259))

packages/manager/src/features/IAM/Delegations/AccountDelegations.test.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ describe('AccountDelegations', () => {
8282
});
8383

8484
await waitFor(() => {
85-
const emptyElement = screen.getByText(/No delegate users found/);
85+
const emptyElement = screen.getByText(/No users added/);
8686
expect(emptyElement).toBeInTheDocument();
8787
});
8888
});

packages/manager/src/features/IAM/Delegations/AccountDelegationsTable.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ export const AccountDelegationsTable = ({
5959
style={{ width: '59%' }}
6060
sx={{ display: { sm: 'table-cell', xs: 'none' } }}
6161
>
62-
Delegate Users
62+
Users
6363
</TableCell>
6464
<TableCell style={{ width: '14%' }} />
6565
</TableRow>

packages/manager/src/features/IAM/Delegations/UpdateDelegationsDrawer.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -127,9 +127,9 @@ export const UpdateDelegationsDrawer = ({
127127
<form onSubmit={handleSubmit(onSubmit)}>
128128
<Typography sx={{ marginBottom: theme.tokens.spacing.S16 }}>
129129
Add or remove users who should have access to the child account.
130-
Delegate users removed from this list will lose the role assignment
131-
on the child account and they won’t be visible in the user list on
132-
the child account.
130+
Users removed from this list will lose the role assignment on the
131+
child account and they won’t be visible in the user list on the
132+
child account.
133133
</Typography>
134134

135135
{delegation && (

packages/manager/src/features/IAM/Roles/Defaults/DefaultRolesPanel.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ export const DefaultRolesPanel = () => {
1616
<Box>
1717
<Typography variant="h2">Default Roles for Delegate Users</Typography>
1818
<Typography marginTop={2}>
19-
View and manage roles to be assigned to new delegated users by
19+
View and manage roles to be assigned to new delegate users by
2020
default.
2121
</Typography>
2222
</Box>

packages/manager/src/features/IAM/Roles/Defaults/DefaultsLanding.tsx

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import { NewFeatureChip } from '@linode/ui';
12
import { TabPanels } from '@reach/tabs';
23
import { Outlet, useLocation, useNavigate } from '@tanstack/react-router';
34
import * as React from 'react';
@@ -6,11 +7,19 @@ import { LandingHeader } from 'src/components/LandingHeader';
67
import { SuspenseLoader } from 'src/components/SuspenseLoader';
78
import { Tabs } from 'src/components/Tabs/Tabs';
89
import { TanStackTabLinkList } from 'src/components/Tabs/TanStackTabLinkList';
10+
import { useFlags } from 'src/hooks/useFlags';
911
import { useTabs } from 'src/hooks/useTabs';
1012

13+
import { useIsIAMEnabled } from '../../hooks/useIsIAMEnabled';
14+
import { IAM_LABEL } from '../../Shared/constants';
15+
1116
export const DefaultsLanding = () => {
1217
const location = useLocation();
1318
const navigate = useNavigate();
19+
const flags = useFlags();
20+
const { isIAMBeta, isIAMEnabled } = useIsIAMEnabled();
21+
const showLimitedAvailabilityBadges =
22+
flags.iamLimitedAvailabilityBadges && isIAMEnabled && !isIAMBeta;
1423

1524
const { tabs, tabIndex, handleTabChange } = useTabs([
1625
{
@@ -32,6 +41,20 @@ export const DefaultsLanding = () => {
3241
<LandingHeader
3342
breadcrumbProps={{
3443
pathname: '/iam/roles/defaults',
44+
crumbOverrides: [
45+
{
46+
label: (
47+
<>
48+
{IAM_LABEL}
49+
{showLimitedAvailabilityBadges ? (
50+
<NewFeatureChip sx={{ position: 'relative', top: -1 }} />
51+
) : null}
52+
</>
53+
),
54+
linkTo: '/iam',
55+
position: 1,
56+
},
57+
],
3558
}}
3659
spacingBottom={4}
3760
title="Default Roles for Delegate Users"

packages/manager/src/features/IAM/Shared/RemoveAssignmentConfirmationDialog/RemoveAssignmentConfirmationDialog.test.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ describe('RemoveAssignmentConfirmationDialog', () => {
139139
);
140140
expect(headerText).toBeVisible();
141141

142-
const paragraph = screen.getByText(/Delegated users wont get the/i);
142+
const paragraph = screen.getByText(/Delegate users wont get the/i);
143143

144144
expect(paragraph).toBeVisible();
145145
expect(paragraph).toHaveTextContent(mockRole.entity_name);

packages/manager/src/features/IAM/Shared/RemoveAssignmentConfirmationDialog/RemoveAssignmentConfirmationDialog.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ export const RemoveAssignmentConfirmationDialog = (props: Props) => {
116116
<Notice variant="warning">
117117
{isDefaultDelegationRolesForChildAccount ? (
118118
<Typography>
119-
Delegated users won’t get the {role?.role_name} access on the{' '}
119+
Delegate users won’t get the {role?.role_name} access on the{' '}
120120
{role?.entity_name} entity by default.
121121
</Typography>
122122
) : (

packages/manager/src/features/IAM/Shared/constants.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ export const ERROR_STATE_TEXT =
2020
'An unexpected error occurred. Refresh the page or try again later.';
2121

2222
// Delegation error messages
23-
export const NO_DELEGATIONS_TEXT = 'No delegate users found.';
23+
export const NO_DELEGATIONS_TEXT = 'No users added.';
2424
export const DELEGATION_VALIDATION_ERROR =
2525
'At least one user must be selected as a delegate.';
2626

0 commit comments

Comments
 (0)