mirror of
https://github.com/pacnpal/thrillwiki_django_no_react.git
synced 2025-12-20 09:31:09 -05:00
989 B
989 B
Active Context - Park View Modularization
Objective: Refactor parks view to use reusable card component and implement grid/list view toggle
Current Implementation Analysis:
- Park cards rendered via
park_list_item.htmlpartial - Existing layout uses flex-based list structure
- Search functionality uses HTMX for dynamic updates
Planned Changes:
-
Create
park_card.htmlPartial- Extract card markup from
park_list_item.html - Add responsive grid/list view classes
- Include view mode toggle state
- Extract card markup from
-
View Toggle Implementation
- Add grid/list toggle UI with HTMX
- Store view preference in cookie/localStorage
- Update CSS for grid (grid-cols) vs list (flex) layouts
-
Backend Updates
- Add view_mode parameter to park list view
- Modify context processor to handle layout preference
Next Steps:
- Implement card partial with responsive classes
- Create view toggle component
- Update HTMX handlers to preserve view mode