Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve Issue Templates and Add Lighthouse CI Integration #16

Closed
wants to merge 13 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 12 additions & 1 deletion .github/ISSUE_TEMPLATE/bug_report.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: Bug Report
description: Submit a report to help improve our project. Please write in English.
title: "{ BUG } Provide a short title for your bug"
title: "[BUG] Provide a short title for your bug"
labels: ["bug"]
body:
- type: markdown
Expand Down Expand Up @@ -43,3 +43,14 @@ body:
description: Which operating system are you using (e.g., Windows 11/Linux Distro/Steam Deck)?
validations:
required: true
- type: dropdown
id: browsers
attributes:
label: What browsers are you seeing the problem on?
multiple: true
options:
- Chrome (including Arc, Brave, Opera, Vivaldi)
- Microsoft Edge
- Firefox
- Safari
- Other (please specify)
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/feature_request.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: Feature Request
description: Request a new feature.
title: "{ REQUEST} "
title: "[REQUEST] "
labels: ["enhancement"]
body:
- type: markdown
Expand Down
12 changes: 9 additions & 3 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,19 +8,25 @@ on:

jobs:
build:
runs-on: ubuntu-latest
runs-on: ubuntu-24.04

steps:
- name: Check out Git repository
uses: actions/checkout@v4

- name: Install Bun
uses: oven-sh/setup-bun@v2
with:
node-version: 20.18.0

- name: Install dependencies
run: bun install

- name: Build Next.js App
run: bun run build
uses: actions/cache@v4
with:
path: |
~/.bun/install/cache
${{ github.workspace }}/.next/cache
key: ${{ runner.os }}-nextjs-${{ hashFiles('**/bun.lockb') }}-${{ hashFiles('**/*.js', '**/*.jsx', '**/*.ts', '**/*.tsx') }}
restore-keys: |
${{ runner.os }}-nextjs-${{ hashFiles('**/bun.lockb') }}-
38 changes: 38 additions & 0 deletions .github/workflows/lighthouse.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Lighthouse CI

on:
push:
branches: [master]
pull_request:
branches: [master]

jobs:
lighthouse:
runs-on: ubuntu-24.04

steps:
- uses: actions/checkout@v4
- uses: oven-sh/setup-bun@v2
- name: Install dependencies
run: bun install
- name: Build Next.js app
run: bun run build
uses: actions/cache@v4
with:
path: |
~/.bun/install/cache
${{ github.workspace }}/.next/cache
key: ${{ runner.os }}-nextjs-${{ hashFiles('**/bun.lockb') }}-${{ hashFiles('**/*.js', '**/*.jsx', '**/*.ts', '**/*.tsx') }}
restore-keys: |
${{ runner.os }}-nextjs-${{ hashFiles('**/bun.lockb') }}-
- name: Run Lighthouse CI
run: |
npm install -g @lhci/cli
lhci autorun
env:
LHCI_GITHUB_APP_TOKEN: ${{ secrets.LHCI_GITHUB_APP_TOKEN }}
- name: Upload Lighthouse reports as artifacts
uses: actions/upload-artifact@v4
with:
name: lighthouse-reports
path: ./lighthouserc.cjs
4 changes: 1 addition & 3 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,14 @@ on: pull_request

jobs:
lint:
runs-on: ubuntu-latest
runs-on: ubuntu-24.04

steps:
- name: Check out Git repository
uses: actions/checkout@v4

- name: Install Bun
uses: oven-sh/setup-bun@v2
with:
node-version: 20.18.0

- name: Install dependencies
run: bun install
Expand Down
24 changes: 0 additions & 24 deletions app/(root)/download/[platform]/page.tsx

This file was deleted.

39 changes: 0 additions & 39 deletions app/(root)/download/page.tsx

This file was deleted.

55 changes: 0 additions & 55 deletions app/api/mirrorlists/[mirrorlist]/route.ts

This file was deleted.

Binary file modified bun.lockb
Binary file not shown.
8 changes: 1 addition & 7 deletions components/footer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ import { links } from "@/constants/links";
import { footer } from "@/constants/footer";
import { useTranslations } from "next-intl";
import LanguageSwitcher from "@/components/language-switcher";
import { IconArrowUpRight } from "@tabler/icons-react";

export const Footer = () => {
const t = useTranslations("footer");
Expand Down Expand Up @@ -53,14 +52,9 @@ export const Footer = () => {
<li key={idx}>
<Link
href={item.href || "#"}
className="flex items-center text-white/60 transition duration-300 hover:text-white"
target={item.newTab ? "_blank" : "_self"}
rel={item.newTab ? "noopener noreferrer" : undefined}
className="text-white/60 transition duration-300 hover:text-white"
>
{t(item.title)}
{item.newTab && (
<IconArrowUpRight className="ml-2 h-4 w-4" />
)}
</Link>
</li>
))}
Expand Down
12 changes: 4 additions & 8 deletions components/header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ import { header } from "@/constants/header";
import { Button } from "@/components/ui/button";
import { MobileSidebar } from "@/components/mobile-navbar";
import { useTranslations } from "next-intl";
import { IconArrowUpRight } from "@tabler/icons-react";

export const Header = () => {
const t = useTranslations("header");
Expand All @@ -32,19 +31,16 @@ export const Header = () => {
/>
</Link>
<div className="hidden md:block">
<nav className="flex items-center gap-4 md:gap-8">
<nav className="flex items-center gap-3 md:gap-6">
{header.map((link) => (
<Link
key={link.label}
className="flex items-center text-base font-medium text-black/60 transition-colors duration-300 hover:text-black"
className="text-base font-medium text-black/60 transition-colors duration-300 hover:text-black"
href={link.href}
target={link.newTab ? "_blank" : "_self"}
rel={link.newTab ? "noopener noreferrer" : undefined}
target="_blank"
rel="noopener noreferrer"
>
{t(link.label)}
{link.newTab && (
<IconArrowUpRight className="ml-2 h-4 w-4" />
)}
</Link>
))}
<Button asChild>
Expand Down
25 changes: 3 additions & 22 deletions components/mobile-navbar.tsx
Original file line number Diff line number Diff line change
@@ -1,38 +1,19 @@
import {
Sheet,
SheetContent,
SheetTitle,
SheetTrigger,
} from "@/components/ui/sheet";
import { Sheet, SheetContent, SheetTrigger } from "@/components/ui/sheet";
import Link from "next/link";
import { header } from "@/constants/header";
import { IconMenu } from "@tabler/icons-react";
import { useTranslations } from "next-intl";
import Image from "next/image";

export const MobileSidebar = () => {
const t = useTranslations("header");

return (
<Sheet>
<SheetTrigger aria-label="Open Menu">
<IconMenu />
</SheetTrigger>
<SheetContent side="left">
<SheetTitle className="mb-4 flex flex-col gap-2 text-xl font-medium">
<Image
src="/logo.webp"
alt="Redot Engine Logo"
width={30}
height={30}
style={{ filter: "invert(100%)" }}
/>
Redot Engine
</SheetTitle>
<div className="flex flex-col items-start justify-start gap-1">
<div className="flex flex-col items-start justify-start gap-2">
{header.map((link) => (
<Link key={link.label} href={link.href}>
<span className="block text-lg">{t(link.label)}</span>
<span className="block text-xl font-medium">{link.label}</span>
</Link>
))}
</div>
Expand Down
Loading