lint: remove remaining unused imports and variables (20 fixes)

Co-Authored-By: Justin Edmund <justin@jedmund.com>
This commit is contained in:
Devin AI 2025-11-24 05:31:03 +00:00
parent 2df4819fef
commit f3bd552eca
4 changed files with 3 additions and 44 deletions

View file

@ -1,11 +1,6 @@
<script lang="ts">
import type { Editor } from '@tiptap/core'
import type { Media } from '@prisma/client'
import Image from 'lucide-svelte/icons/image'
import Video from 'lucide-svelte/icons/video'
import AudioLines from 'lucide-svelte/icons/audio-lines'
import Grid3x3 from 'lucide-svelte/icons/grid-3x3'
import MapPin from 'lucide-svelte/icons/map-pin'
import MediaIcon from '$icons/media.svg?component'
import Upload from 'lucide-svelte/icons/upload'
import Link from 'lucide-svelte/icons/link'
@ -38,7 +33,6 @@
let selectedAction = $state<ActionType>(defaultAction())
let embedUrl = $state('')
let searchQuery = $state('')
let isUploading = $state(false)
let fileInput: HTMLInputElement
let isOpen = $state(true)
@ -291,12 +285,6 @@
return null
}
function handleLocationSearch() {
// This would integrate with a geocoding API
// For now, just show a message
alert('Location search coming soon! For now, paste a Google Maps link.')
}
function handleLocationInsert() {
const lat = parseFloat(locationLat)
const lng = parseFloat(locationLng)
@ -336,23 +324,6 @@
isOpen = false
onClose()
}
function getContentTitle() {
switch (contentType) {
case 'image':
return 'Insert Image'
case 'video':
return 'Insert Video'
case 'audio':
return 'Insert Audio'
case 'gallery':
return 'Create Gallery'
case 'location':
return 'Add Location'
default:
return 'Insert Content'
}
}
</script>
<Pane

View file

@ -1,6 +1,4 @@
<script lang="ts">
import Album from '$components/Album.svelte'
import Game from '$components/Game.svelte'
import MentionList from '$components/MentionList.svelte'
import Page from '$components/Page.svelte'
import RecentAlbums from '$components/RecentAlbums.svelte'
@ -13,8 +11,6 @@
let { data } = $props<{ data: PageData }>()
let albums = $derived(data.albums)
let games = $derived(data.games)
let error = $derived(data.error)
const pageUrl = $derived($page.url.href)

View file

@ -4,8 +4,7 @@ import redis from '../redis-client'
import type {
AuthTokensResponse,
GetUserPlayedTimeResponse,
RecentlyPlayedGamesResponse
GetUserPlayedTimeResponse
} from 'psn-api'
import type { RequestHandler } from './$types'
@ -13,7 +12,6 @@ const require = Module.createRequire(import.meta.url)
const {
exchangeNpssoForCode,
exchangeCodeForAccessToken,
getRecentlyPlayedGames,
getUserPlayedTime
} = require('psn-api')
@ -21,7 +19,7 @@ const CACHE_TTL = 60 * 60 // 1 hour
const PSN_NPSSO_TOKEN = process.env.PSN_NPSSO_TOKEN
const PSN_ID = '1275018559140296533'
export const GET: RequestHandler = async ({ url }) => {
export const GET: RequestHandler = async () => {
// Check if data is in cache
const cachedData = await redis.get(`psn:${PSN_ID}`)
if (cachedData) {
@ -45,7 +43,7 @@ async function authorize(npsso: string): Promise<AuthTokensResponse> {
return authorization
}
async function getSerializedGames(psnId: string): Promise<SerializableGameInfo[]> {
async function getSerializedGames(_psnId: string): Promise<SerializableGameInfo[]> {
// Authorize with PSN and get games sorted by last played time
const authorization = await authorize(PSN_NPSSO_TOKEN || '')
const response = await getUserPlayedTime(authorization, PSN_ID, {

View file

@ -5,7 +5,6 @@
import { generateMetaTags } from '$lib/utils/metadata'
import { page } from '$app/stores'
import { goto } from '$app/navigation'
import { onMount } from 'svelte'
import { spring } from 'svelte/motion'
import { getCurrentMousePosition } from '$lib/stores/mouse'
import type { PageData } from './$types'
@ -46,7 +45,6 @@
let defaultRightX = 0
const pageUrl = $derived($page.url.href)
const fromAlbum = $derived($page.url.searchParams.get('from'))
// Generate metadata
const metaTags = $derived(
@ -218,10 +216,6 @@
}
}
// Track last known mouse position for scroll updates
let lastMouseX = 0
let lastMouseY = 0
// Store last mouse client position for scroll updates
let lastClientX = 0
let lastClientY = 0