Skip to content

Commit d1003b1

Browse files
Merge pull request #118 from rocky-linux/feature/update-depends
Upgrade Dependencies and Versions, and Remove Storybook
2 parents 486043f + d17f9c6 commit d1003b1

38 files changed

+8230
-21665
lines changed

.devcontainer/devcontainer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "RockyLinux.org",
3-
"image": "mcr.microsoft.com/devcontainers/typescript-node:0-20",
3+
"image": "mcr.microsoft.com/devcontainers/typescript-node:1-20",
44

55
// Use 'forwardPorts' to make a list of ports inside the container available locally.
66
// "forwardPorts": [],

.eslintignore

Lines changed: 0 additions & 3 deletions
This file was deleted.

.eslintrc.json

Lines changed: 0 additions & 34 deletions
This file was deleted.

.storybook/main.ts

Lines changed: 0 additions & 43 deletions
This file was deleted.

.storybook/preview.tsx

Lines changed: 0 additions & 69 deletions
This file was deleted.

app/[locale]/Hero.tsx

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import DpgLogo from "@/components/otherLogosIcons/DpgLogo";
44

55
import { Button } from "@/components/ui/button";
66
import React from "react";
7+
import Link from "next/link";
78

89
const Hero = () => {
910
const t = useTranslations("home.hero");
@@ -23,25 +24,25 @@ const Hero = () => {
2324
</h1>
2425
<p className="mt-6 text-lg leading-8">{t("description")}</p>
2526
<div className="mt-10 flex items-center justify-center gap-x-6">
26-
<a href="/download">
27+
<Link href="/download">
2728
<Button className="p-5">{tGlobal("download")}</Button>
28-
</a>
29-
<a href="https://docs.rockylinux.org/guides/migrate2rocky/">
29+
</Link>
30+
<Link href="https://docs.rockylinux.org/guides/migrate2rocky/">
3031
<Button
3132
variant="secondary"
3233
className="p-5"
3334
>
3435
{t("migrate")}
3536
</Button>
36-
</a>
37+
</Link>
3738
</div>
38-
<a
39+
<Link
3940
href="https://digitalpublicgoods.net/"
4041
target="_blank"
4142
>
4243
<DpgLogo />
4344
<p className="text-md font-display mt-2">{t("dpg")}</p>
44-
</a>
45+
</Link>
4546
</div>
4647
<div className="mt-16 flow-root sm:mt-24">
4748
<div className="-m-2 rounded-xl bg-slate-900/5 dark:bg-slate-100/5 p-2 ring-1 ring-inset ring-slate-900/10 dark:ring-slate-100/10 lg:-m-4 lg:rounded-2xl lg:p-4">

app/[locale]/about/[slug]/page.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ export type Params = {
66
};
77

88
export type Props = {
9-
params: Params;
9+
params: Promise<Params>;
1010
};
1111

1212
export type pageData = {
@@ -16,7 +16,7 @@ export type pageData = {
1616
};
1717

1818
export async function generateMetadata({ params }: Props) {
19-
const slug = params.slug;
19+
const { slug } = await params;
2020

2121
if (!(await checkIfSlugIsValid(slug))) {
2222
return {
@@ -32,7 +32,7 @@ export async function generateMetadata({ params }: Props) {
3232
}
3333

3434
export default async function Page({ params }: Props) {
35-
const slug = params.slug;
35+
const { slug } = await params;
3636

3737
if (!(await checkIfSlugIsValid(slug))) {
3838
notFound();
Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,40 +1,40 @@
1-
import { JSXElementConstructor, ReactElement, ReactNodeArray } from "react";
1+
import { JSXElementConstructor, ReactElement, ReactNode } from "react";
22

33
export interface QuizInterests {
44
chatting: string;
55
chattingDescription:
66
| string
77
| ReactElement<any, string | JSXElementConstructor<any>>
8-
| ReactNodeArray;
8+
| ReactNode;
99
bugs: string;
1010
bugsDescription:
1111
| string
1212
| ReactElement<any, string | JSXElementConstructor<any>>
13-
| ReactNodeArray;
13+
| ReactNode;
1414
webdev: string;
1515
webDevDescription:
1616
| string
1717
| ReactElement<any, string | JSXElementConstructor<any>>
18-
| ReactNodeArray;
18+
| ReactNode;
1919
graphics: string;
2020
graphicsDescription:
2121
| string
2222
| ReactElement<any, string | JSXElementConstructor<any>>
23-
| ReactNodeArray;
23+
| ReactNode;
2424
release: string;
2525
releaseDescription:
2626
| string
2727
| ReactElement<any, string | JSXElementConstructor<any>>
28-
| ReactNodeArray;
28+
| ReactNode;
2929
sig: string;
3030
sigDescription:
3131
| string
3232
| ReactElement<any, string | JSXElementConstructor<any>>
33-
| ReactNodeArray;
33+
| ReactNode;
3434
docs: string;
3535
docsDescription:
3636
| string
3737
| ReactElement<any, string | JSXElementConstructor<any>>
38-
| ReactNodeArray;
38+
| ReactNode;
3939
noSelection: string;
4040
}

app/[locale]/components/header/MobileNavigation.tsx

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ import NavListItem from "./nav/mobile/NavListItem";
1919
import { HamburgerMenuIcon } from "@radix-ui/react-icons";
2020

2121
import type { NavigationMenuItems } from "./NavigationTypes";
22+
import Link from "next/link";
2223

2324
export interface MobileNavigationProps {
2425
darkModeSRText: string;
@@ -55,10 +56,10 @@ const MobileNavigation = ({
5556
side="right"
5657
className="w-full"
5758
>
58-
<a href="/">
59+
<Link href="/">
5960
<Logo />
6061
<span className="sr-only">{rockyLinuxSRText}</span>
61-
</a>
62+
</Link>
6263
<Accordion
6364
type="single"
6465
collapsible
@@ -141,11 +142,11 @@ const MobileNavigation = ({
141142
</NavList>
142143
</Accordion>
143144
<div className="mt-auto">
144-
<a href="/download">
145+
<Link href="/download">
145146
<SheetClose asChild>
146147
<Button className="p-5 w-full mt-4">{downloadSRText}</Button>
147148
</SheetClose>
148-
</a>
149+
</Link>
149150
</div>
150151
</SheetContent>
151152
</Sheet>

app/[locale]/components/header/nav/desktop/NavListItem.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ const NavListItem = ({ title, href }: NavListItemProps) => {
1515
>
1616
<a
1717
className={cn(
18-
"block select-none space-y-1 rounded-md p-3 leading-none no-underline outline-none transition-colors hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground"
18+
"block select-none space-y-1 rounded-md p-3 leading-none no-underline outline-hidden transition-colors hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground"
1919
)}
2020
>
2121
<div className="text-sm font-medium leading-none">{title}</div>

0 commit comments

Comments
 (0)