Skip to content

Commit b30fc42

Browse files
authored
Merge pull request #1522 from dxc-technology/gomezivann-links-fixed
Update links to Halstack Provider in the Themes page
2 parents f94eadd + 20a93c5 commit b30fc42

File tree

5 files changed

+28
-21
lines changed

5 files changed

+28
-21
lines changed

website/pages/_app.tsx

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,16 @@ const MyApp = ({ Component, pageProps }: AppPropsWithLayout) => {
6363
setFilter(value);
6464
};
6565

66+
const matchPaths = (linkPath: string) => {
67+
const pathToBeMatched = currentPath.split("#")[0].slice(0, -1);
68+
const desiredPaths = [
69+
linkPath,
70+
`${linkPath}/specifications`,
71+
`${linkPath}/usage`,
72+
];
73+
return desiredPaths.includes(pathToBeMatched);
74+
};
75+
6676
return (
6777
<>
6878
<Head>
@@ -98,12 +108,7 @@ const MyApp = ({ Component, pageProps }: AppPropsWithLayout) => {
98108
{links.map(({ label, path }) => (
99109
<Link key={`${label}-${path}`} href={path} passHref>
100110
<DxcApplicationLayout.SideNav.Link
101-
selected={
102-
currentPath.slice(0, -1) === path ||
103-
currentPath.slice(0, -1) ===
104-
path + "/specifications" ||
105-
currentPath.slice(0, -1) === path + "/usage"
106-
}
111+
selected={matchPaths(path)}
107112
>
108113
{label}
109114
</DxcApplicationLayout.SideNav.Link>

website/screens/common/TabsPageLayout.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ const TabsPageLayout = ({ tabs }: TabsPageLayoutProps) => {
2222
</Link>
2323
))}
2424
</DxcNavTabs>
25-
<Space></Space>
25+
<Space />
2626
</TabsContainer>
2727
);
2828
};
@@ -34,7 +34,7 @@ const TabsContainer = styled.div`
3434
`;
3535

3636
const Space = styled.div`
37-
border-bottom: 2px solid #0000001a;
37+
border-bottom: 2px solid #bfbfbf;
3838
width: 100%;
3939
`;
4040

website/screens/principles/localization/LocalizationPage.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ const sections = [
5454
content: (
5555
<>
5656
<DxcParagraph>
57-
FormFields labels are common to several components of the design
57+
These labels are common to several components of the design
5858
system.
5959
</DxcParagraph>
6060
<DxcTable>

website/screens/principles/themes/ThemesPage.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1427,7 +1427,7 @@ const sections = [
14271427
<DxcParagraph>
14281428
More examples can be found in the{" "}
14291429
<Link
1430-
href="/utilities/halstackProvider/#opinionated-theme"
1430+
href="/utilities/halstack-provider/#opinionated-theme"
14311431
passHref
14321432
>
14331433
<DxcLink>Halstack Provider section</DxcLink>
@@ -1472,7 +1472,7 @@ const sections = [
14721472
</JsonContainer>
14731473
<DxcParagraph>
14741474
More examples can be found in the{" "}
1475-
<Link href="/utilities/halstackProvider/#advanced-theme" passHref>
1475+
<Link href="/utilities/halstack-provider/#advanced-theme" passHref>
14761476
<DxcLink>Halstack Provider section</DxcLink>
14771477
</Link>
14781478
.

website/screens/utilities/halstack-provider/HalstackProviderPage.tsx

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -61,14 +61,14 @@ const sections = [
6161
content: (
6262
<>
6363
<DxcParagraph>
64-
As explained in the{" "}
64+
As explained on the{" "}
6565
<Link
66-
href="/principles/themes/#opinionated-theme-inputs-list"
66+
href="/principles/themes/#different-theming-strategies-opinionated-theme"
6767
passHref
6868
>
69-
<DxcLink>Themes section</DxcLink>
70-
</Link>
71-
, you can apply the opinionated theme strategy to customize the
69+
<DxcLink>Themes</DxcLink>
70+
</Link>{" "}
71+
page, you can apply the opinionated theming strategy to customize the
7272
components.
7373
</DxcParagraph>
7474

@@ -98,14 +98,16 @@ const sections = [
9898
content: (
9999
<>
100100
<DxcParagraph>
101-
The advanced strategy is the option to choose when further
102-
customization is required, as explained in the{" "}
101+
Advanced theming is the option to choose when further customization is
102+
required. To find out which use cases are valid for this strategy, you
103+
can refer to the{" "}
103104
<Link
104-
href="/principles/themes/#opinionated-theme-inputs-list"
105+
href="/principles/themes/#different-theming-strategies-advanced-theme"
105106
passHref
106107
>
107-
<DxcLink>Themes section.</DxcLink>
108-
</Link>
108+
<DxcLink>Themes</DxcLink>
109+
</Link>{" "}
110+
page.
109111
</DxcParagraph>
110112
<DxcAlert type="info" size="fillParent">
111113
Remember that you can use the{" "}

0 commit comments

Comments
 (0)