Skip to content

Develop#38

Merged
Majorfi merged 46 commits into
mainfrom
develop
Mar 21, 2026
Merged

Develop#38
Majorfi merged 46 commits into
mainfrom
develop

Conversation

@Majorfi

@Majorfi Majorfi commented Mar 21, 2026

Copy link
Copy Markdown
Owner

Date Range Filtering (fix #32)

  • Backend: date range filtering on asset queries
  • Frontend: calendar picker UI in the filter bar, date range threaded through URL state, context providers, and fetch hooks
  • New dependencies: date picker + styling libraries
  • New UI components: calendar picker, popover

Coordinate Search

  • Parse direct coordinate input (e.g. 48.8566, 2.3522) in the place search bar
  • Utility for coordinate parsing

Dawarich Integration (GPX Import) (fix #31)

  • Backend: Dawarich location import API, match result builder, coordinate tolerance tuning
  • Auth: Dawarich API key storage with encryption, credentials management UI
  • Frontend: Dawarich API client hook, GPX import dialog redesigned with source tabs (file upload vs Dawarich), track
    selection/preview, status filters for imported locations
  • Map: marker click/drag handler extraction, reset position for imported locations
  • Various refactors: keyboard activation patterns, toggle pill extraction, settings panel extraction

Configurable Geocode Provider (PR #35 by @joshii-h, PR #37) (fix #25)

  • Added HERE Maps as a fallback geocoding provider
  • Fixed tests for migration version and syncAlbums signatures
  • Moved all forward geocoding from frontend to Go backend
  • Added /geocode/search endpoint with retry logic
  • Deleted frontend geocoding API route, HERE client, and geocoding constants
  • Improved error handling, rate limiting, and cancellation logic
  • Extracted day count data fetching, updated utils docs, lock file

Infrastructure (fix #34)

  • Consolidated Docker publishing into the release workflow
  • Remove comments, add date URL params
  • Various refactors cleaning up props, imports, types
  • Added library.read to README for External Library
  • Release tag fix

Upcoming:

Majorfi added 30 commits March 19, 2026 13:07
Add startDate and endDate parameters to asset and album filtering functions. Implements new countAssetsByDay() method to support calendar visualization with asset counts per day. Adds new /assets/day-counts endpoint to expose daily asset distributions within a date range.

Change-Type: feature
Scope: backend
Update all test calls to pass empty startDate and endDate parameters to accommodate new date filtering function signatures.

Change-Type: test
Scope: backend
Add reusable Button, Calendar, and Popover components from shadcn/ui patterns. Implement useScrollHeight hook for dynamic panel sizing. Add SettingsIcon for filter bar UI. Components provide foundation for date range selection UI.

Change-Type: feature
Scope: ui
Add @radix-ui/react-popover for dropdown positioning, date-fns for date manipulation, lucide-react for icons, and class-variance-authority + tailwind-merge for robust CSS class composition. These enable rich calendar UI and proper Tailwind class merging.

Change-Type: feature
Scope: dependencies
Implement DateRangeFilterGroup component with calendar picker, preset buttons (Last month, Last year, yearly), and day count visualization. Refactor FilterBar to support collapsible filter and settings panels. Add shadcn CSS variable aliases for consistent theming.

Change-Type: feature
Scope: filterBar
Add startDate and endDate to URL parameter synchronization. Implement setDateRangeAction to coordinate date updates across URL state. Ensure date range persists across page navigation and browser back/forward.

Change-Type: feature
Scope: state
Update useAssets and useAlbums to accept startDate and endDate parameters. Pass dates through to API calls. Treat date changes as filter invalidators that reset pagination and reload data.

Change-Type: feature
Scope: fetching
Add startDate, endDate, and setDateRangeAction to TViewContextValue. Thread date state through all provider layers (AppProviderState, ProviderValues) to make it available throughout the component tree.

Change-Type: feature
Scope: context
Add startDate and endDate parameters to fetchAssets and fetchAlbums. Implement fetchAssetDayCounts to retrieve asset counts grouped by day for calendar visualization.

Change-Type: feature
Scope: api
Update cn utility to use clsx + tailwind-merge for proper Tailwind CSS class deduplication. Add parseCoordinateInput utility to support coordinate entry in search box alongside location names.

Change-Type: refactor
Scope: utils
Allow users to enter coordinates directly (e.g., "40.7128,-74.0060") to set location without triggering a nominatim search. When valid coordinates are detected, immediately call onLocationSelectedAction instead of debouncing and searching. This provides immediate feedback for users who know their exact coordinates and avoids unnecessary API calls.

Change-Type: feature
Scope: search
Remove JSDoc comments from constants and functions that merely restate what the code already expresses clearly. Add URL parameter constants for date range filtering (URL_PARAM_START_DATE, URL_PARAM_END_DATE) to support the date range feature implemented in upstream commits. This reduces comment clutter and exposes the date parameters alongside other view-related URL keys.

Change-Type: refactor
Scope: view
Move Docker build and publish logic from standalone docker-publish.yml into the release workflow as a dependent job. This ensures Docker images are only published after successful release creation and links image semver tags to release outputs, reducing workflow maintenance overhead and creating a single source of truth for release automation.

Change-Type: refactor
Scope: ci
Add client for fetching tracks and points from Dawarich instance, type definitions for API responses, and HTTP handlers to support user-initiated track preview and import workflows. Extends API with endpoints for settings management, track listing, and location preview matching.

Scope: backend
Change-Type: feature
Add dawarichAPIKey column to users table with encryption support. Implement key decryption in database layer, update UserRow type, and refactor auth handlers to include Dawarich credentials in user state. Extract buildMeResponse to reduce handler duplication.

Change-Type: feature
Scope: auth
…olerance

Extract buildMatchResult to reduce code duplication in matchAssetsToTrack. Increase coordinate tolerance from 1e-6 to 4.5e-5 to improve matching precision for location detection.

Change-Type: refactor
Scope: backend
Implement Dawarich API calls for settings management, track fetching, and location preview. Add type guards for validation. Create useDawarich hook to manage workflow state transitions between setup, track loading, and preview generation.

Change-Type: feature
Scope: dawarich
Extend APIKeyDialog to handle both Immich and Dawarich API keys. Update AuthContext to track hasDawarichCredentials state and provide updateDawarichSettings and deleteDawarichSettings methods. Export isMeResponse validator and shared error handling utilities.

Change-Type: feature
Scope: auth
Restructure import dialog to support multiple track sources via tab interface. Extract GPX file dropzone into dedicated component. Move shared styling constants to constant.ts. Consolidate max gap settings into reusable input component.

Change-Type: refactor
Scope: gpxImport
Implement new tab component for importing tracks from Dawarich. Provides setup prompt, track list display, and preview workflow. Guides users to configure API key if not yet connected.

Change-Type: feature
Scope: gpxImport
Add TGPXStatusFilter type to distinguish between already-set, new, and edited locations from imports. Implement filter UI component and filtering logic in import panel. Update match result type to include existing location tracking. Provide helper functions to determine filter applicability.

Change-Type: feature
Scope: gpxImport
Extract settings panel contents into dedicated SettingsPanel component to improve FilterBar maintainability. Fix CountDayButton props ordering to place spread operator after className. Show GPX status filter when in GPX import mode.

Change-Type: refactor
Scope: filterBar
Extract marker interaction logic from overviewLayerMarkerSync into dedicated handlers module. Improve code organization by separating marker creation, event handling, and state management. Add support for resetting imported locations to original positions.

Scope: map
Change-Type: refactor
Add canResetPosition context menu option for markers with existing locations that were modified by imports. Implement reset handler that restores original coordinates. Filter GPX markers by status when displaying import results. Track original coordinates in pending locations.

Change-Type: feature
Scope: map
…tion

Introduce TGPXStatusFilter state to selection context. Extract location creation and pending location building into helpers to reduce duplication. Add matchesGPXStatusFilter and hasGPXPendingEntries utilities. Update LocationConfirm to respect active filter when calculating edited counts.

Change-Type: refactor
Scope: selection
Extract handleActivate keyboard event handler to constant.ts for reuse. Create togglePillClass utility for consistent toggle button styling across filter components. Reduces code duplication in suggestion pills.

Change-Type: refactor
Scope: ui
Add hasDawarichCredentials to TMeResponse. Introduce TGPXStatusFilter type. Extend TPendingLocation and TSetLocationOptions with original coordinate tracking. Update TMapContextMenuMarker with reset position fields. Export throwIfErrorResponse utility and update validation guards for new fields.

Change-Type: refactor
Scope: types
Remove unused health prop from PhotoList and derive missing count from view state. Update UserMenu labels and add Dawarich-aware props. Thread gpxStatusFilter through selection context. Fix cn.ts import ordering. Clean up unused variables and error message handling.

Change-Type: refactor
Scope: misc
Removed unused MAP_ICON_SHADOW and MAP_ICON_SHADOW_BASE_ALPHA constants that were not referenced in icon styling. Replaced redundant null check with optional chaining for clearer intent and safer null propagation in pendingLocation source validation.

Scope: map
Change-Type: refactor
s-martin and others added 16 commits March 20, 2026 20:09
Introduce a configurable geocoding provider system that uses Nominatim
as the primary provider and falls back to HERE Maps when Nominatim
returns no results. This improves search coverage for businesses and
POIs that are missing from OpenStreetMap.

Backend changes:
- Add GeocodeProvider interface with fallback geocoder pattern
- Implement HereClient for HERE Geocoding & Search API v1
- Export NominatimClient.ReverseGeocode to satisfy the interface
- Read GEOCODE_PROVIDER and GEOCODE_API_KEY from environment
- Use shutdown context for enrichment goroutine to prevent
  premature cancellation

Frontend changes:
- Add HERE forward-search client with Nominatim-compatible output
- Update search route to try Nominatim first, HERE on empty results
- Accept "here" as valid GEOCODE_PROVIDER value

Closes #25
- Update expected migration version from 13 to 14 (migration 014
  was added in develop but the test was not updated)
- Add missing forceRefresh bool argument to syncAlbums test calls
- Move maxGeocodeCacheSize and HERE API URL to geocoder.go constants
- Remove hardcoded lang=en-US from HERE reverse geocode requests
- Add configurable GEOCODE_TIMEOUT env var (default: 10s)
- Pass timeout through to Nominatim and HERE HTTP clients
- Standardize log.Println to log.Printf for consistent formatting
- Add .exe to .gitignore for Windows builds
The isAlreadyApplied and hasExistingLocation fields on pending
locations are optional, but matchesGPXStatusFilter requires boolean.
feat(geocoding): add HERE Maps as fallback provider
Move geocoding search logic from frontend to backend to centralize configuration management and simplify frontend logic. Implements forward search for both Nominatim and HERE providers with rate limiting and retry logic.

Change-Type: feature
Scope: backend
Replace silent fallback patterns with explicit error propagation. Implement rate limiter resets on Nominatim 429 responses and consistent error logging across providers. Add timeout validation in config.

Change-Type: refactor
Scope: geocoding
Remove Next.js API route and client-side provider implementations now handled by backend. Simplify frontend search to call backend endpoint with consistent response format.

Change-Type: refactor
Scope: frontend
Move geocoding provider and API key configuration from frontend environment to backend. Frontend now calls backend endpoint transparently regardless of provider.

Change-Type: refactor
Scope: config
Refactor buildMeResponse to return errors instead of silently logging failures. Add server connection status display in login form when auth service is unavailable.

Change-Type: refactor
Scope: auth
Extract useDayCounts hook from DateRangeFilterGroup component to reduce component complexity and enable reuse. Simplify component logic by inlining simple helper functions.

Change-Type: refactor
Scope: frontend
Fix SyncService cancellation flow to avoid early returns when cancel is nil. Improve Dawarich pagination error handling by separating parse error from missing total_pages cases.

Scope: sync
Change-Type: fix
Remove geocoding.ts from utils documentation after consolidating logic to backend. Reformat category descriptions for consistency.

Change-Type: docs
Scope: docs
Consolidate forward geocoding into Go backend
@Majorfi Majorfi merged commit 7d8e9a3 into main Mar 21, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Tag docker-images Filter by date Dawarich as a source Feature request: Configurable geocoding provider (e.g. HERE, LocationIQ)

3 participants