fix: Phase 6 - fix ImageVariant type export (37 -> 36 errors)

Fixed TypeScript error where ImageVariant type wasn't accessible in the
same file that re-exported it.

The issue: Re-exporting a type with `export type { X } from 'module'`
doesn't create a local binding that can be used in the same file.

The fix: Import the type first to create a local binding, then re-export it.

Changes:
- src/lib/features/database/detail/image.ts:
  - Added: import type { ResourceType, ImageVariant } from '$lib/utils/images'
  - Kept: export type { ResourceType as ResourceKind, ImageVariant }
  - This allows ImageVariant to be used in the ImageArgs interface below

Result: 37 → 36 errors (-1)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Justin Edmund 2025-11-28 19:52:02 -08:00
parent ebc0e48e92
commit aa87ccb7d7

View file

@ -7,7 +7,9 @@ export {
getImageUrl as getImageUrlBase
} from '$lib/utils/images'
export type { ResourceType as ResourceKind, ImageVariant } from '$lib/utils/images'
// Import types for local use and re-export
import type { ResourceType, ImageVariant } from '$lib/utils/images'
export type { ResourceType as ResourceKind, ImageVariant }
// Legacy compatibility wrapper
interface ImageArgs {