Skip to content

Commit eabc060

Browse files
committed
Fix ESLint errors
1 parent d5882af commit eabc060

File tree

8 files changed

+11
-17
lines changed

8 files changed

+11
-17
lines changed

resources/js/app.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import { route as routeFn } from 'ziggy-js';
77
import { initializeTheme } from './hooks/use-appearance';
88

99
declare global {
10-
var route: typeof routeFn;
10+
const route: typeof routeFn;
1111
}
1212

1313
const appName = import.meta.env.VITE_APP_NAME || 'Laravel';

resources/js/components/app-logo.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
1-
import { SVGAttributes } from 'react';
21
import AppLogoIcon from './app-logo-icon';
32

4-
export default function AppLogo(props: SVGAttributes<SVGElement>) {
3+
export default function AppLogo() {
54
return (
65
<>
76
<div className="flex aspect-square size-8 items-center justify-center rounded-md bg-sidebar-primary text-sidebar-primary-foreground">

resources/js/components/appearance-dropdown.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,7 @@ import { useAppearance } from '@/hooks/use-appearance';
44
import { Monitor, Moon, Sun } from 'lucide-react';
55
import { HTMLAttributes } from 'react';
66

7-
interface AppearanceToggleDropdownProps extends HTMLAttributes<HTMLDivElement> {}
8-
9-
export default function AppearanceToggleDropdown({ className = '', ...props }: AppearanceToggleDropdownProps) {
7+
export default function AppearanceToggleDropdown({ className = '', ...props }: HTMLAttributes<HTMLDivElement>) {
108
const { appearance, updateAppearance } = useAppearance();
119

1210
const getCurrentIcon = () => {

resources/js/components/appearance-tabs.tsx

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,11 @@
1-
import { useAppearance } from '@/hooks/use-appearance';
2-
import { Monitor, Moon, Sun } from 'lucide-react';
1+
import { Appearance, useAppearance } from '@/hooks/use-appearance';
2+
import { LucideIcon, Monitor, Moon, Sun } from 'lucide-react';
33
import { HTMLAttributes } from 'react';
44

5-
interface AppearanceToggleTabProps extends HTMLAttributes<HTMLDivElement> {}
6-
7-
export default function AppearanceToggleTab({ className = '', ...props }: AppearanceToggleTabProps) {
5+
export default function AppearanceToggleTab({ className = '', ...props }: HTMLAttributes<HTMLDivElement>) {
86
const { appearance, updateAppearance } = useAppearance();
97

10-
const tabs = [
8+
const tabs: { value: Appearance; icon: LucideIcon; label: string }[] = [
119
{ value: 'light', icon: Sun, label: 'Light' },
1210
{ value: 'dark', icon: Moon, label: 'Dark' },
1311
{ value: 'system', icon: Monitor, label: 'System' },

resources/js/layouts/settings/layout.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ const sidebarNavItems: NavItem[] = [
2525

2626
export default function SettingsLayout({ children }: { children: React.ReactNode }) {
2727
const currentPath = window.location.pathname;
28-
const currentItem = sidebarNavItems.find((item) => currentPath === item.url);
2928

3029
return (
3130
<div className="px-4 py-6">

resources/js/pages/auth/reset-password.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ interface ResetPasswordForm {
2121
}
2222

2323
export default function ResetPassword({ token, email }: ResetPasswordProps) {
24-
const { data, setData, post, processing, errors, reset } = useForm({
24+
const { data, setData, post, processing, errors, reset } = useForm<ResetPasswordForm>({
2525
token: token,
2626
email: email,
2727
password: '',

resources/js/pages/settings/password.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ const breadcrumbs: BreadcrumbItem[] = [
1818
},
1919
];
2020

21-
export default function Password({ className = '' }: { className?: string }) {
21+
export default function Password() {
2222
const passwordInput = useRef<HTMLInputElement>(null);
2323
const currentPasswordInput = useRef<HTMLInputElement>(null);
2424

resources/js/types/index.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ export interface SharedData {
2525
auth: Auth;
2626
name: string;
2727
quote: { message: string; author: string };
28-
[key: string]: any;
28+
[key: string]: unknown;
2929
}
3030

3131
export interface User {
@@ -36,5 +36,5 @@ export interface User {
3636
email_verified_at: string | null;
3737
created_at: string;
3838
updated_at: string;
39-
[key: string]: any; // This allows for additional properties
39+
[key: string]: unknown; // This allows for additional properties
4040
}

0 commit comments

Comments
 (0)