From 618638ecedafc7a8df1446e3449b469f107fcfb7 Mon Sep 17 00:00:00 2001 From: eveeify Date: Thu, 28 Mar 2024 23:10:16 +1100 Subject: [PATCH 01/15] feat: types --- src/env.d.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/env.d.ts b/src/env.d.ts index f964fe0..acef35f 100644 --- a/src/env.d.ts +++ b/src/env.d.ts @@ -1 +1,2 @@ +/// /// From 05ecf03d195828b7c77449d881f779004d568bc8 Mon Sep 17 00:00:00 2001 From: eveeify Date: Thu, 28 Mar 2024 23:10:26 +1100 Subject: [PATCH 02/15] feat: droops redirect --- astro.config.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/astro.config.ts b/astro.config.ts index a828571..c937113 100644 --- a/astro.config.ts +++ b/astro.config.ts @@ -18,10 +18,16 @@ export default defineConfig({ tailwind({ nesting: true, applyBaseStyles: true }), ], redirects: { + // Resources "/discord": "https://discord.gg/ejFTe4Hfnc", - "/klaas": "https://klaas.tiiny.site/", "/github": "https://github.com/TeaClientMC", "/roadmap": "https://github.com/orgs/TeaClientMC/projects/3", + + // Partner Networks + "/dropps": "https://discord.gg/qFarXHT32J", + + // Easter-Eggs + "/klaas": "https://klaas.tiiny.site/", }, vite: { resolve: { From 2ac5480e86f360c4d3716517d2cd6cf81e66a081 Mon Sep 17 00:00:00 2001 From: eveeify Date: Thu, 28 Mar 2024 23:13:25 +1100 Subject: [PATCH 03/15] fix: biome formating issue --- biome.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/biome.json b/biome.json index 791289f..8925862 100644 --- a/biome.json +++ b/biome.json @@ -7,7 +7,8 @@ "enabled": true, "rules": { "recommended": true - } + }, + "ignore": [".astro/**/*"] }, "formatter": { "enabled": true, From 900a33d921fca79b37c29654568b9433bc48cf50 Mon Sep 17 00:00:00 2001 From: eveeify Date: Thu, 28 Mar 2024 23:22:18 +1100 Subject: [PATCH 04/15] feat: updated deps --- package.json | 120 +++++++++++++++++++++++++-------------------------- 1 file changed, 60 insertions(+), 60 deletions(-) diff --git a/package.json b/package.json index 6072562..46eb62e 100644 --- a/package.json +++ b/package.json @@ -1,62 +1,62 @@ { - "name": "teaclient-website", - "type": "module", - "version": "0.0.1", - "scripts": { - "dev": "astro dev", - "preview": "astro preview", - "build": "astro build", - "astro": "astro", - "lint": "biome check --apply . && bun lint:css --fix", - "lint:css": "stylelint 'src/styles/**/*.css'", - "fmt": "biome format . --write", - "biome": "bunx @biomejs/biome", - "check": "biome check . && bun lint:css && bun astro check", - "postinstall": "husky install" - }, - "trustedDependencies": ["sharp"], - "stylelint": { - "extends": "stylelint-config-standard", - "plugins": ["stylelint-scss"], - "customSyntax": "postcss-scss", - "rules": { - "at-rule-no-unknown": null, - "selector-class-pattern": null, - "scss/at-rule-no-unknown": true, - "custom-property-pattern": null - } - }, - "commitlint": { - "extends": ["@commitlint/config-conventional"] - }, - "dependencies": { - "@astrojs/mdx": "^2.0.2", - "@astrojs/rss": "^3.0.0", - "@astrojs/sitemap": "^3.1.1", - "@astrojs/tailwind": "^5.1.0", - "@astrojs/ts-plugin": "^1.3.1", - "astro-meta-tags": "^0.2.1", - "astro-seo": "^0.8.0", - "axios": "^1.6.5", - "sass": "^1.71.1", - "sharp": "^0.33.2", - "tailwind-merge": "^2.2.1", - "tailwindcss": "^3.4.1", - "web-vitals": "^3.5.0" - }, - "devDependencies": { - "@astrojs/check": "^0.2.0", - "@biomejs/biome": "^1.5.3", - "@commitlint/cli": "^18.4.3", - "@commitlint/config-conventional": "^18.4.3", - "@types/node": "^20.8.3", - "astro": "^4.2.3", - "husky": "^8.0.3", - "postcss-scss": "^4.0.9", - "stylelint": "^15.11.0", - "stylelint-config-standard": "^34.0.0", - "stylelint-scss": "^6.2.1", - "typescript": "^5.2.2" - }, - "packageManager": "bun@1.0.25" + "name": "teaclient-website", + "type": "module", + "version": "0.0.1", + "scripts": { + "dev": "astro dev", + "preview": "astro preview", + "build": "astro build", + "astro": "astro", + "lint": "biome check --apply . && bun lint:css --fix", + "lint:css": "stylelint 'src/styles/**/*.css'", + "fmt": "biome format . --write", + "biome": "bunx @biomejs/biome", + "check": "biome check . && bun lint:css && bun astro check", + "postinstall": "husky install" + }, + "trustedDependencies": ["sharp"], + "stylelint": { + "extends": "stylelint-config-standard", + "plugins": ["stylelint-scss"], + "customSyntax": "postcss-scss", + "rules": { + "at-rule-no-unknown": null, + "selector-class-pattern": null, + "scss/at-rule-no-unknown": true, + "custom-property-pattern": null + } + }, + "commitlint": { + "extends": ["@commitlint/config-conventional"] + }, + "dependencies": { + "@astrojs/mdx": "^2.0.2", + "@astrojs/rss": "^4.0.5", + "@astrojs/sitemap": "^3.1.1", + "@astrojs/tailwind": "^5.1.0", + "@astrojs/ts-plugin": "^1.3.1", + "astro-meta-tags": "^0.2.1", + "astro-seo": "^0.8.0", + "axios": "^1.6.5", + "sass": "^1.71.1", + "sharp": "^0.33.2", + "tailwind-merge": "^2.2.1", + "tailwindcss": "^3.4.1", + "web-vitals": "^3.5.0" + }, + "devDependencies": { + "@astrojs/check": "^0.5.10", + "@biomejs/biome": "^1.5.3", + "@commitlint/cli": "^18.4.3", + "@commitlint/config-conventional": "^18.4.3", + "@types/node": "^20.8.3", + "astro": "^4.2.3", + "husky": "^9.0.11", + "postcss-scss": "^4.0.9", + "stylelint": "^16.3.1", + "stylelint-config-standard": "^36.0.0", + "stylelint-scss": "^6.2.1", + "typescript": "^5.2.2" + }, + "packageManager": "bun@1.0.25" } From ea0a1b5feb0449b641aa67c3bab5ef167c853d7c Mon Sep 17 00:00:00 2001 From: eveeify Date: Thu, 28 Mar 2024 23:23:01 +1100 Subject: [PATCH 05/15] fix: formating and linting --- package.json | 120 +++++++++++++++++++++++++-------------------------- 1 file changed, 60 insertions(+), 60 deletions(-) diff --git a/package.json b/package.json index 46eb62e..f6def7e 100644 --- a/package.json +++ b/package.json @@ -1,62 +1,62 @@ { - "name": "teaclient-website", - "type": "module", - "version": "0.0.1", - "scripts": { - "dev": "astro dev", - "preview": "astro preview", - "build": "astro build", - "astro": "astro", - "lint": "biome check --apply . && bun lint:css --fix", - "lint:css": "stylelint 'src/styles/**/*.css'", - "fmt": "biome format . --write", - "biome": "bunx @biomejs/biome", - "check": "biome check . && bun lint:css && bun astro check", - "postinstall": "husky install" - }, - "trustedDependencies": ["sharp"], - "stylelint": { - "extends": "stylelint-config-standard", - "plugins": ["stylelint-scss"], - "customSyntax": "postcss-scss", - "rules": { - "at-rule-no-unknown": null, - "selector-class-pattern": null, - "scss/at-rule-no-unknown": true, - "custom-property-pattern": null - } - }, - "commitlint": { - "extends": ["@commitlint/config-conventional"] - }, - "dependencies": { - "@astrojs/mdx": "^2.0.2", - "@astrojs/rss": "^4.0.5", - "@astrojs/sitemap": "^3.1.1", - "@astrojs/tailwind": "^5.1.0", - "@astrojs/ts-plugin": "^1.3.1", - "astro-meta-tags": "^0.2.1", - "astro-seo": "^0.8.0", - "axios": "^1.6.5", - "sass": "^1.71.1", - "sharp": "^0.33.2", - "tailwind-merge": "^2.2.1", - "tailwindcss": "^3.4.1", - "web-vitals": "^3.5.0" - }, - "devDependencies": { - "@astrojs/check": "^0.5.10", - "@biomejs/biome": "^1.5.3", - "@commitlint/cli": "^18.4.3", - "@commitlint/config-conventional": "^18.4.3", - "@types/node": "^20.8.3", - "astro": "^4.2.3", - "husky": "^9.0.11", - "postcss-scss": "^4.0.9", - "stylelint": "^16.3.1", - "stylelint-config-standard": "^36.0.0", - "stylelint-scss": "^6.2.1", - "typescript": "^5.2.2" - }, - "packageManager": "bun@1.0.25" + "name": "teaclient-website", + "type": "module", + "version": "0.0.1", + "scripts": { + "dev": "astro dev", + "preview": "astro preview", + "build": "astro build", + "astro": "astro", + "lint": "biome check --apply . && bun lint:css --fix", + "lint:css": "stylelint 'src/styles/**/*.css'", + "fmt": "biome format . --write", + "biome": "bunx @biomejs/biome", + "check": "biome check . && bun lint:css && bun astro check", + "postinstall": "husky install" + }, + "trustedDependencies": ["sharp"], + "stylelint": { + "extends": "stylelint-config-standard", + "plugins": ["stylelint-scss"], + "customSyntax": "postcss-scss", + "rules": { + "at-rule-no-unknown": null, + "selector-class-pattern": null, + "scss/at-rule-no-unknown": true, + "custom-property-pattern": null + } + }, + "commitlint": { + "extends": ["@commitlint/config-conventional"] + }, + "dependencies": { + "@astrojs/mdx": "^2.0.2", + "@astrojs/rss": "^4.0.5", + "@astrojs/sitemap": "^3.1.1", + "@astrojs/tailwind": "^5.1.0", + "@astrojs/ts-plugin": "^1.3.1", + "astro-meta-tags": "^0.2.1", + "astro-seo": "^0.8.0", + "axios": "^1.6.5", + "sass": "^1.71.1", + "sharp": "^0.33.2", + "tailwind-merge": "^2.2.1", + "tailwindcss": "^3.4.1", + "web-vitals": "^3.5.0" + }, + "devDependencies": { + "@astrojs/check": "^0.5.10", + "@biomejs/biome": "^1.5.3", + "@commitlint/cli": "^18.4.3", + "@commitlint/config-conventional": "^18.4.3", + "@types/node": "^20.8.3", + "astro": "^4.2.3", + "husky": "^9.0.11", + "postcss-scss": "^4.0.9", + "stylelint": "^16.3.1", + "stylelint-config-standard": "^36.0.0", + "stylelint-scss": "^6.2.1", + "typescript": "^5.2.2" + }, + "packageManager": "bun@1.0.25" } From 4f88c6e7621d05a708d58d846e13625d9d5def32 Mon Sep 17 00:00:00 2001 From: eveeify Date: Thu, 28 Mar 2024 23:28:23 +1100 Subject: [PATCH 06/15] chore: removed an unnesserary lines and fix somethings --- biome.json | 5 +++-- package.json | 5 ++--- src/layouts/layout.astro | 2 +- src/pages/apply/[apply].astro | 5 ++--- 4 files changed, 8 insertions(+), 9 deletions(-) diff --git a/biome.json b/biome.json index 8925862..6dfa839 100644 --- a/biome.json +++ b/biome.json @@ -8,13 +8,14 @@ "rules": { "recommended": true }, - "ignore": [".astro/**/*"] + "ignore": ["./.astro/*"] }, "formatter": { "enabled": true, "formatWithErrors": false, "indentWidth": 2, - "lineWidth": 80 + "lineWidth": 80, + "ignore": ["./.astro/*"] }, "css": { "formatter": { diff --git a/package.json b/package.json index f6def7e..8ba70d5 100644 --- a/package.json +++ b/package.json @@ -7,11 +7,10 @@ "preview": "astro preview", "build": "astro build", "astro": "astro", - "lint": "biome check --apply . && bun lint:css --fix", - "lint:css": "stylelint 'src/styles/**/*.css'", + "lint": "biome check --apply . && stylelint 'src/styles/**/*.css' --fix", "fmt": "biome format . --write", "biome": "bunx @biomejs/biome", - "check": "biome check . && bun lint:css && bun astro check", + "check": "biome check . && stylelint 'src/styles/**/*.css'&& bun astro check", "postinstall": "husky install" }, "trustedDependencies": ["sharp"], diff --git a/src/layouts/layout.astro b/src/layouts/layout.astro index d6b831b..dfbdc81 100644 --- a/src/layouts/layout.astro +++ b/src/layouts/layout.astro @@ -15,7 +15,7 @@ export interface Props { const { title, className, desc, banner } = Astro.props; --- - +
diff --git a/src/pages/apply/[apply].astro b/src/pages/apply/[apply].astro index 77c419f..5431221 100644 --- a/src/pages/apply/[apply].astro +++ b/src/pages/apply/[apply].astro @@ -1,5 +1,4 @@ --- -import AppError from "@layout/error.astro"; import Layout from "@layout/layout.astro"; const { apply } = Astro.params; @@ -21,13 +20,13 @@ if (apply === "staff") { {apply === 'staff' ? (
- +
Go Back
) : apply === 'team' ? (
- +
Go Back
From a35d0f9a7340c785cdda32b5f79d17bf4bd8d725 Mon Sep 17 00:00:00 2001 From: eveeify Date: Thu, 28 Mar 2024 23:28:57 +1100 Subject: [PATCH 07/15] chore: removed undclared --- src/components/shared/header.astro | 1 - 1 file changed, 1 deletion(-) diff --git a/src/components/shared/header.astro b/src/components/shared/header.astro index 0daf76a..19a1af8 100644 --- a/src/components/shared/header.astro +++ b/src/components/shared/header.astro @@ -1,6 +1,5 @@ --- import { Image } from "astro:assets"; -import { twMerge } from "tailwind-merge"; ---
Date: Thu, 28 Mar 2024 23:32:57 +1100 Subject: [PATCH 08/15] fix: type issues --- src/pages/news/index.xml.ts | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/src/pages/news/index.xml.ts b/src/pages/news/index.xml.ts index f2f099c..8563224 100644 --- a/src/pages/news/index.xml.ts +++ b/src/pages/news/index.xml.ts @@ -1,11 +1,17 @@ -import rss, { pagesGlobToRssItems } from "@astrojs/rss"; +import rss, { + pagesGlobToRssItems, + type RSSFeedItem, + type RSSOptions, +} from "@astrojs/rss"; -export async function GET(context) { +export async function GET(context: RSSOptions) { return rss({ title: "TeaClient News/Updates", description: "Update your self on the latest news.", site: context.site, - items: await pagesGlobToRssItems(import.meta.glob("./*/*.{md,mdx}")), + items: (await pagesGlobToRssItems( + import.meta.glob("./*/*.{md,mdx}"), + )) as RSSFeedItem[], customData: "en-us", trailingSlash: false, stylesheet: "./feed.xsl", From 51da76e14534f0918d91d3706ec7231c892c2945 Mon Sep 17 00:00:00 2001 From: eveeify Date: Thu, 28 Mar 2024 23:38:05 +1100 Subject: [PATCH 09/15] chore: removed the need of stylint script --- .github/workflows/PrQuality.yml | 2 +- .github/workflows/Quality.yml | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/PrQuality.yml b/.github/workflows/PrQuality.yml index c517e17..3b8c00b 100644 --- a/.github/workflows/PrQuality.yml +++ b/.github/workflows/PrQuality.yml @@ -24,7 +24,7 @@ jobs: run: bun install - name: Check stylelint - run: bun stylelint + run: bunx stylelint src/styles/**/*.css CommitQuality: runs-on: ubuntu-22.04 diff --git a/.github/workflows/Quality.yml b/.github/workflows/Quality.yml index 7debbc4..e423fdd 100644 --- a/.github/workflows/Quality.yml +++ b/.github/workflows/Quality.yml @@ -4,6 +4,7 @@ on: push: branches-ignore: - main + jobs: Quality: @@ -26,7 +27,7 @@ jobs: run: bun install - name: Check stylelint - run: bun stylelint + run: bunx stylelint src/styles/**/*.css CommitQuality: runs-on: ubuntu-22.04 From 5387b93809ec5cfff66ba92ec6a6bf11f2dfbdad Mon Sep 17 00:00:00 2001 From: eveeify Date: Thu, 28 Mar 2024 23:40:59 +1100 Subject: [PATCH 10/15] fix: quality script --- .github/workflows/Quality.yml | 16 ++++------------ 1 file changed, 4 insertions(+), 12 deletions(-) diff --git a/.github/workflows/Quality.yml b/.github/workflows/Quality.yml index e423fdd..7c213c8 100644 --- a/.github/workflows/Quality.yml +++ b/.github/workflows/Quality.yml @@ -1,13 +1,12 @@ name: Quality on: - push: + push: branches-ignore: - main - jobs: - Quality: + Quality: runs-on: ubuntu-latest steps: - name: Checkout @@ -18,18 +17,15 @@ jobs: version: latest - name: Run Biome run: biome ci . - - uses: oven-sh/setup-bun@v1 with: bun-version: latest - - name: Install Deps run: bun install - - name: Check stylelint run: bunx stylelint src/styles/**/*.css - CommitQuality: + CommitQuality: runs-on: ubuntu-22.04 steps: - uses: actions/checkout@v4 @@ -38,11 +34,9 @@ jobs: - uses: oven-sh/setup-bun@v1 with: bun-version: latest - - name: Install packages run: | bun install - - name: Print versions run: | bun --version @@ -51,11 +45,9 @@ jobs: run: | bun install conventional-changelog-conventionalcommits bun install commitlint@latest - - name: Validate current commit (last commit) with commitlint if: github.event_name == 'push' run: bunx commitlint --from HEAD~1 --to HEAD --verbose - - name: Validate PR commits with commitlint if: github.event_name == 'pull_request' - run: bunx commitlint --from ${{ github.event.pull_request.head.sha }}~${{ github.event.pull_request.commits }} --to ${{ github.event.pull_request.head.sha }} --verbose + run: bunx commitlint --from ${{ github.event.pull_request.head.sha }}~${{ github.event.pull_request.commits }} --to ${{ github.event.pull_request.head.sha }} --verbose \ No newline at end of file From 3a895180ca6e813c233ded8960d871838aba11e4 Mon Sep 17 00:00:00 2001 From: eveeify Date: Thu, 28 Mar 2024 23:43:09 +1100 Subject: [PATCH 11/15] fix(ci): node install fix --- .github/workflows/Quality.yml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.github/workflows/Quality.yml b/.github/workflows/Quality.yml index 7c213c8..a8915bd 100644 --- a/.github/workflows/Quality.yml +++ b/.github/workflows/Quality.yml @@ -31,9 +31,16 @@ jobs: - uses: actions/checkout@v4 with: fetch-depth: 0 + - uses: oven-sh/setup-bun@v1 with: bun-version: latest + + # Needed to fix some issues with commitlint. + - name: Setup Node.js + uses: actions/setup-node@v2 + with: + node-version: '16' - name: Install packages run: | bun install From 3b825ffa5c5fbf86e57d818fa313f001af4018c6 Mon Sep 17 00:00:00 2001 From: eveeify Date: Thu, 28 Mar 2024 23:45:18 +1100 Subject: [PATCH 12/15] fix: ubuntu --- .github/workflows/Quality.yml | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/.github/workflows/Quality.yml b/.github/workflows/Quality.yml index a8915bd..7ac7492 100644 --- a/.github/workflows/Quality.yml +++ b/.github/workflows/Quality.yml @@ -26,7 +26,7 @@ jobs: run: bunx stylelint src/styles/**/*.css CommitQuality: - runs-on: ubuntu-22.04 + runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 with: @@ -35,12 +35,6 @@ jobs: - uses: oven-sh/setup-bun@v1 with: bun-version: latest - - # Needed to fix some issues with commitlint. - - name: Setup Node.js - uses: actions/setup-node@v2 - with: - node-version: '16' - name: Install packages run: | bun install From e24bed73590c98a5cea1169853412fb586fea7a4 Mon Sep 17 00:00:00 2001 From: eveeify Date: Thu, 28 Mar 2024 23:45:47 +1100 Subject: [PATCH 13/15] fix: ubuntu latest for prquality --- .github/workflows/PrQuality.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/PrQuality.yml b/.github/workflows/PrQuality.yml index 3b8c00b..563a52d 100644 --- a/.github/workflows/PrQuality.yml +++ b/.github/workflows/PrQuality.yml @@ -27,7 +27,7 @@ jobs: run: bunx stylelint src/styles/**/*.css CommitQuality: - runs-on: ubuntu-22.04 + runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 with: From 90f1c1c404cf971687bb008d5579713a27698581 Mon Sep 17 00:00:00 2001 From: eveeify Date: Thu, 28 Mar 2024 23:46:14 +1100 Subject: [PATCH 14/15] fix: ubuntu latest for deploy --- .github/workflows/deploy.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 0c54108..0a6d57c 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -40,7 +40,7 @@ jobs: run: bun stylelint commitquality: - runs-on: ubuntu-22.04 + runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 with: From bec1de6bc642e411d8892bb67eb6158b66bda955 Mon Sep 17 00:00:00 2001 From: eveeify Date: Thu, 28 Mar 2024 23:48:03 +1100 Subject: [PATCH 15/15] chore: removed the extra install step --- .github/workflows/Quality.yml | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/.github/workflows/Quality.yml b/.github/workflows/Quality.yml index 7ac7492..87a0c43 100644 --- a/.github/workflows/Quality.yml +++ b/.github/workflows/Quality.yml @@ -36,16 +36,12 @@ jobs: with: bun-version: latest - name: Install packages - run: | - bun install + run: bun install + - name: Print versions run: | bun --version bunx commitlint --version - - name: Install commitlint - run: | - bun install conventional-changelog-conventionalcommits - bun install commitlint@latest - name: Validate current commit (last commit) with commitlint if: github.event_name == 'push' run: bunx commitlint --from HEAD~1 --to HEAD --verbose