Adds a new Map sidebar entry that plots photos by their EXIF GPS coordinates on a clustered Leaflet map. While wiring this up, the metadata extractor was reading unprefixed GPS keys that never exist in `exiftool -G -j` output AND assumed coordinates were already floats — every photo silently lost its GPS. The new extract_gps helper handles Composite/EXIF group prefixes and parses DMS strings, and lat/lon are stored as first-class indexed columns so the map can query them without parsing exif_json on every request. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
28 lines
871 B
TypeScript
28 lines
871 B
TypeScript
import React from 'react'
|
||
import ReactDOM from 'react-dom/client'
|
||
import { QueryClient, QueryClientProvider } from '@tanstack/react-query'
|
||
import { ReactQueryDevtools } from '@tanstack/react-query-devtools'
|
||
import App from './App'
|
||
import './index.css'
|
||
// Leaflet ships its base styles separately; without these the map tiles
|
||
// render at 0×0 and marker icons go missing. Imported once globally so
|
||
// any lazy MapView render picks them up.
|
||
import 'leaflet/dist/leaflet.css'
|
||
|
||
const queryClient = new QueryClient({
|
||
defaultOptions: {
|
||
queries: {
|
||
staleTime: 5 * 60 * 1000, // 5 minutes
|
||
retry: 2,
|
||
},
|
||
},
|
||
})
|
||
|
||
ReactDOM.createRoot(document.getElementById('root')!).render(
|
||
<React.StrictMode>
|
||
<QueryClientProvider client={queryClient}>
|
||
<App />
|
||
<ReactQueryDevtools initialIsOpen={false} />
|
||
</QueryClientProvider>
|
||
</React.StrictMode>,
|
||
) |