Skip to content

Commit fe7d9c7

Browse files
LadyBluenotestannerlinsleyautofix-ci[bot]
authored
chore: fix eslint errors (#594)
* fix: improve accessibility by adding htmlFor attributes to labels; fix: eslint errors and improve code * fix: add alt attribute to img component for improved accessibility * fix: enhance accessibility by adding dependencies to hooks and improving effect dependencies * blog post drafts, future date filtering, and ai blog posts * ci: apply automated fixes * ci: apply automated fixes * fix: standardize icon sizes by removing size attributes for consistency; fix: hover sidebar bg * ci: apply automated fixes * fix: enhance accessibility by adding aria-label to menu button and improving background color for better contrast * checkpoint # Conflicts: # src/auth/oauth.server.ts * fix: enhance accessibility by adding dependencies to hooks and improving effect dependencies * ci: apply automated fixes --------- Co-authored-by: Tanner Linsley <[email protected]> Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
1 parent 4daf0b3 commit fe7d9c7

File tree

81 files changed

+277
-340
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

81 files changed

+277
-340
lines changed

scripts/test-npm-cache.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,10 @@
33
* Tests that chunks are properly cached and retrieved
44
*/
55

6-
import { db } from '../src/db/client'
76
import {
87
getCachedNpmDownloadChunk,
98
setCachedNpmDownloadChunk,
10-
} from '../src/utils/stats-db.server'
9+
} from '~/utils/stats-db.server'
1110

1211
async function testCache() {
1312
console.log('\n' + '='.repeat(80))

src/auth/context.server.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ import { OAuthService } from './oauth.server'
1111
import { SessionService } from './session.server'
1212
import { createAuthGuards } from './guards.server'
1313
import {
14-
createRepositories,
1514
DrizzleUserRepository,
1615
DrizzleOAuthAccountRepository,
1716
DrizzleCapabilitiesRepository,

src/components/AILibraryHero.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ const MESSAGES = [
9494
},
9595
]
9696

97-
export function AILibraryHero({ project, cta, actions }: AILibraryHeroProps) {
97+
export function AILibraryHero({}: AILibraryHeroProps) {
9898
const isDark = useIsDark()
9999
const strokeColor = isDark ? 'rgba(255, 255, 255, 0.8)' : 'rgba(0, 0, 0, 0.6)'
100100
const textColor = isDark ? '#ffffff' : '#000000'

src/components/BlockWithFeedback.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,6 @@ export function BlockWithFeedback({
4141
return feedback.userNotes.find((n) => n.blockSelector === blockSelector)
4242
}, [feedback.userNotes, blockSelector])
4343

44-
const isCollapsed = note ? feedback.collapsedNotes.has(note.id) : false
4544
const hasNote = !!note
4645

4746
const handleAddNote = React.useCallback(() => {

src/components/CookieConsent.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { Link } from '@tanstack/react-router'
2-
import { useCallback, useEffect, useState } from 'react'
2+
import { useEffect, useState } from 'react'
33

44
declare global {
55
interface Window {
@@ -134,6 +134,7 @@ export default function CookieConsent() {
134134
}
135135

136136
checkLocationAndSetConsent()
137+
// eslint-disable-next-line react-hooks/exhaustive-deps
137138
}, [])
138139

139140
const acceptAllCookies = () => {

src/components/Doc.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ function DocContent({
182182
href={`https://github.com/${repo}/edit/${branch}/${filePath}`}
183183
className="flex items-center gap-2"
184184
>
185-
<SquarePen size={16} /> Edit on GitHub
185+
<SquarePen /> Edit on GitHub
186186
</a>
187187
</div>
188188
<div className="h-24" />

src/components/DocFeedbackFloatingButton.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@ export function DocFeedbackFloatingButton({
5959
document.removeEventListener('mousedown', handleClickOutside)
6060
document.removeEventListener('keydown', handleEscape)
6161
}
62+
// eslint-disable-next-line react-hooks/exhaustive-deps
6263
}, [isMenuOpen])
6364

6465
const handleButtonClick = (e: React.MouseEvent) => {
@@ -86,6 +87,7 @@ export function DocFeedbackFloatingButton({
8687
}
8788

8889
return (
90+
// eslint-disable-next-line jsx-a11y/click-events-have-key-events,jsx-a11y/no-static-element-interactions
8991
<div
9092
ref={buttonRef}
9193
className="doc-feedback-floating-btn absolute top-0 right-0 -translate-y-full z-[100]"

src/components/DocFeedbackNote.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -298,6 +298,7 @@ export function DocFeedbackNote({
298298
}
299299

300300
return (
301+
// eslint-disable-next-line jsx-a11y/click-events-have-key-events,jsx-a11y/no-static-element-interactions
301302
<div
302303
className={twMerge(
303304
inline ? 'w-full' : 'fixed z-40 w-80 max-w-[calc(100vw-2rem)]',
@@ -334,6 +335,7 @@ export function DocFeedbackNote({
334335
)}
335336

336337
{/* Header - always visible */}
338+
{/* eslint-disable-next-line jsx-a11y/click-events-have-key-events,jsx-a11y/no-static-element-interactions */}
337339
<div
338340
className={twMerge(
339341
`flex flex-col gap-1 p-2 ${colors.header}`,

src/components/DocsLayout.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -288,8 +288,8 @@ export function DocsLayout({
288288
>
289289
<summary className="py-2 px-4 flex gap-2 items-center justify-between">
290290
<div className="flex-1 flex gap-4 items-center">
291-
<TextAlignStart className="icon-open cursor-pointer" size={16} />
292-
<X className="icon-close cursor-pointer" size={16} />
291+
<TextAlignStart className="icon-open cursor-pointer" />
292+
<X className="icon-close cursor-pointer" />
293293
Documentation
294294
</div>
295295
</summary>
@@ -359,7 +359,7 @@ export function DocsLayout({
359359
className="py-1 px-2 bg-white/70 text-black dark:bg-gray-500/40 dark:text-white shadow-lg shadow-black/20 flex items-center justify-center backdrop-blur-sm z-20 rounded-lg overflow-hidden"
360360
>
361361
<div className="flex gap-2 items-center font-bold">
362-
<ArrowLeft size={16} />
362+
<ArrowLeft />
363363
{prevItem.label}
364364
</div>
365365
</Link>
@@ -379,7 +379,7 @@ export function DocsLayout({
379379
>
380380
{nextItem.label}
381381
</span>{' '}
382-
<ArrowRight className={textColor} size={16} />
382+
<ArrowRight className={textColor} />
383383
</div>
384384
</Link>
385385
) : null}

src/components/FeedFilters.tsx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ export function FeedFilters({
136136
// Update filters when debounced search changes
137137
React.useEffect(() => {
138138
onFiltersChange({ search: debouncedSearch || undefined })
139-
}, [debouncedSearch])
139+
}, [debouncedSearch, onFiltersChange])
140140

141141
// Sync local state with prop when search prop changes externally
142142
React.useEffect(() => {
@@ -176,7 +176,7 @@ export function FeedFilters({
176176
featured !== undefined ||
177177
search ||
178178
(selectedReleaseLevels && selectedReleaseLevels.length > 0) ||
179-
(includePrerelease !== undefined && includePrerelease !== true),
179+
(includePrerelease !== undefined && !includePrerelease),
180180
)
181181

182182
// Render filter content (shared between mobile and desktop)
@@ -383,6 +383,7 @@ export function FeedFilters({
383383
compact
384384
/>
385385
)}
386+
{/* eslint-disable-next-line jsx-a11y/click-events-have-key-events,jsx-a11y/no-static-element-interactions */}
386387
<div onClick={(e) => e.stopPropagation()} className="flex-shrink-0">
387388
<FilterSearch
388389
value={searchInput}

0 commit comments

Comments
 (0)