{
const colorConfig = Object.entries(config).filter(
- ([_, config]) => config.theme || config.color,
+ ([, config]) => config.theme || config.color,
);
if (!colorConfig.length) {
diff --git a/components/ui/input.tsx b/components/ui/input.tsx
index 5b0bce3..6e58d5e 100644
--- a/components/ui/input.tsx
+++ b/components/ui/input.tsx
@@ -1,8 +1,7 @@
import { cn } from "@/lib/utils";
import * as React from "react";
-export interface InputProps
- extends React.InputHTMLAttributes
{}
+export type InputProps = React.InputHTMLAttributes;
const Input = React.forwardRef(
({ className, type, ...props }, ref) => {
diff --git a/i18n/locale.ts b/i18n/locale.ts
index 04fbcce..26fddc0 100644
--- a/i18n/locale.ts
+++ b/i18n/locale.ts
@@ -6,9 +6,12 @@ import { cookies } from "next/headers";
const COOKIE_NAME = "NEXT_LOCALE";
export async function getUserLocale() {
- return cookies().get(COOKIE_NAME)?.value || (getEnv("DefaultLocale") ?? "en");
+ return (
+ (await cookies()).get(COOKIE_NAME)?.value ||
+ (getEnv("DefaultLocale") ?? "en")
+ );
}
export async function setUserLocale(locale: string) {
- cookies().set(COOKIE_NAME, locale);
+ (await cookies()).set(COOKIE_NAME, locale);
}
diff --git a/lib/utils.ts b/lib/utils.ts
index 024faf3..17d4186 100644
--- a/lib/utils.ts
+++ b/lib/utils.ts
@@ -76,9 +76,9 @@ export const nezhaFetcher = async (url: string) => {
if (!res.ok) {
const error = new Error("An error occurred while fetching the data.");
- // @ts-ignore
+ // @ts-expect-error - res.json() returns a Promise
error.info = await res.json();
- // @ts-ignore
+ // @ts-expect-error - res.status is a number
error.status = res.status;
throw error;
}
diff --git a/package.json b/package.json
index b1d8f9e..9f775aa 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
{
"name": "nezha-dash",
- "version": "1.0.0",
+ "version": "1.1.0",
"private": true,
"scripts": {
"dev": "next dev -p 3020",
@@ -22,46 +22,53 @@
"@radix-ui/react-tooltip": "^1.1.3",
"@trivago/prettier-plugin-sort-imports": "^4.3.0",
"@types/luxon": "^3.4.2",
- "@typescript-eslint/eslint-plugin": "^8.10.0",
- "caniuse-lite": "^1.0.30001669",
+ "@typescript-eslint/eslint-plugin": "^8.12.2",
+ "caniuse-lite": "^1.0.30001674",
"class-variance-authority": "^0.7.0",
"clsx": "^2.1.1",
"country-flag-icons": "^1.5.13",
"eslint-plugin-simple-import-sort": "^12.1.1",
"flag-icons": "^7.2.3",
- "framer-motion": "^11.11.9",
+ "framer-motion": "^12.0.0-alpha.1",
"lucide-react": "^0.451.0",
"luxon": "^3.5.0",
- "next": "^14.2.15",
+ "next": "15.0.2",
"next-auth": "^5.0.0-beta.25",
- "next-intl": "^3.21.1",
+ "next-intl": "^3.23.5",
"next-runtime-env": "^3.2.2",
"next-themes": "^0.3.0",
- "react": "^18.3.1",
+ "react": "19.0.0-rc-02c0e824-20241028",
"react-device-detect": "^2.2.3",
- "react-dom": "^18.3.1",
+ "react-dom": "19.0.0-rc-02c0e824-20241028",
"react-intersection-observer": "^9.13.1",
"react-wrap-balancer": "^1.1.1",
- "recharts": "2.12.7",
+ "recharts": "2.13.1",
"sharp": "^0.33.5",
"swr": "^2.2.6-beta.4",
"tailwind-merge": "^2.5.4",
- "tailwindcss-animate": "^1.0.7"
+ "tailwindcss-animate": "^1.0.7",
+ "typescript-eslint": "^8.12.2"
},
"devDependencies": {
- "eslint-plugin-turbo": "^2.2.1",
+ "eslint-plugin-turbo": "^2.2.3",
"eslint-plugin-unused-imports": "^4.1.4",
- "@next/bundle-analyzer": "^14.2.15",
- "@types/node": "^22.7.7",
- "@types/react": "^18.3.11",
- "@types/react-dom": "^18.3.1",
+ "@next/bundle-analyzer": "15.0.2",
+ "@types/node": "^22.8.4",
+ "@types/react": "npm:types-react@19.0.0-rc.1",
+ "@types/react-dom": "npm:types-react-dom@19.0.0-rc.1",
"autoprefixer": "^10.4.20",
"eslint": "^9.13.0",
- "eslint-config-next": "^14.2.15",
+ "eslint-config-next": "15.0.2",
"postcss": "^8.4.47",
"prettier": "^3.3.3",
"prettier-plugin-tailwindcss": "^0.6.8",
"tailwindcss": "^3.4.14",
"typescript": "^5.6.3"
- }
+ },
+ "overrides": {
+ "@types/react": "npm:types-react@19.0.0-rc.1",
+ "@types/react-dom": "npm:types-react-dom@19.0.0-rc.1",
+ "react-is": "^19.0.0-rc-69d4b800-20241021"
+ },
+ "packageManager": "yarn@1.22.22+sha512.a6b2f7906b721bba3d67d4aff083df04dad64c399707841b7acf00f6b133b7ac24255f2652fa22ae3534329dc6180534e98d17432037ff6fd140556e2bb3137e"
}
diff --git a/public/manifest.json b/public/manifest.json
index e00a07d..7d0dadc 100644
--- a/public/manifest.json
+++ b/public/manifest.json
@@ -1,6 +1,6 @@
{
- "name": "HomeDash",
- "short_name": "HomeDash PWA App",
+ "name": "NezhaDash PWA App",
+ "short_name": "NezhaDash",
"icons": [
{
"src": "/android-chrome-192x192.png",