Commit Graph

26 Commits

Author SHA1 Message Date
joakim aa2ca9aec3 feat: add TaskDetail, bidirectional swipe, and active indicator
- SwipeAction: bidirectional with onSwipeRight/onSwipeLeft, dual backgrounds
- TaskItem: onTap for bottom sheet, onStartStop, active border + pill
- TaskDetail: full field layout with inline editing, action buttons
- TaskList: passes onTap and onStartStop through to TaskItem

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-19 15:47:39 +01:00
joakim b53e77a8ec feat: add foundational Tier 1 components and store methods
Add generic BottomSheet, Toast, and ConfirmDialog components.
Add startTask/stopTask optimistic methods to tasks store.
Add --color-active-bg/text theme tokens for all three themes.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-19 15:44:30 +01:00
joakim a551f50cef ui updates 2026-02-18 23:16:00 +01:00
joakim f05d6e154e gradient gutters 2026-02-17 21:57:34 +01:00
joakim 4dfef88f19 refactor: use Vite built-in DEV flag instead of VITE_OAUTH_ENABLED
import.meta.env.DEV is already true during `bun run dev` and false in
production builds, so a separate env var is unnecessary.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-17 21:19:34 +01:00
joakim d51c6da18d feat: replace mock mode with real backend dev mode
Add --dev flag to `opal server start` that disables auth (injects
userID=1 for all requests) and exposes a /auth/dev-session endpoint,
so the frontend can develop against a real backend without OAuth
config. Remove VITE_MOCK_MODE and all mock data/branches from the
frontend stores. Add scripts/dev.sh to start both services locally.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-17 17:07:34 +01:00
joakim b3c30738bd fix(web): minor UI refinements across header, pills, swipe, and settings
- Remove ThemeSwitcher from header (already accessible via settings)
- Increase pill padding and font size for better tap targets
- Guard non-cancelable touchmove preventDefault in SwipeAction
- Restyle settings page with grid-area layout and inline sign-out button

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-15 14:59:58 +01:00
joakim 3bb2ef2759 feat: add JSON serialization, urgency field, and snake_case API contract
Fix latent API bug where multi-word fields (RecurrenceDuration, ParentUUID,
CreatedAt) serialized as PascalCase, breaking the frontend. Add explicit
snake_case json tags and custom MarshalJSON/UnmarshalJSON on Task, Status,
and APIKey to emit unix timestamps and string status codes.

Add Urgency float64 as a derived field on Task, populated via
PopulateUrgency helper in all handlers before serialization. The report
engine's sortByUrgency now also retains the computed score.

Frontend updated with urgency type, color-coded badge in TaskItem, and
mock data values.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-15 14:58:34 +01:00
joakim d86501e4e6 feat(web): use CSS grid-areas layout with anchor-positioned report picker
Replace flexbox layout with CSS grid using named grid-areas for responsive
content containment. Gutters collapse naturally on small screens via
min(--content-max-width, 100%). Anchor ReportPicker to its trigger button
using CSS anchor positioning instead of fixed viewport offsets.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-15 14:08:41 +01:00
joakim 78881e1b07 feat: add parse endpoint, refactor recurring tasks, and improve web task completion
Extract CreateRecurringTask into engine package for reuse by both CLI
and API. Add POST /tasks/parse endpoint for CLI-style input parsing.
Remove FK constraint on change_log to preserve history after task
deletion. Update web frontend to filter completed tasks from view and
add mock mode support for development.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-14 23:49:20 +01:00
joakim 0352c22b4f feat(web): add theme system with Obsidian, Paper, and Midnight themes
Three holistic design directions with CSS custom properties, a theme
store persisted to localStorage, and a live switcher in both the header
(cycle button) and settings page (card selector). Also fixes checkbox
checkmark alignment and adds back navigation from settings.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-14 22:36:07 +01:00
joakim 6c2fc6960a feat(web): add fade-out animation for checkbox task completion
When a task is completed via checkbox tap, it fades out and collapses
before being removed from the list, matching the swipe-to-complete
animation behavior.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-14 17:41:28 +01:00
joakim 5e829320cf feat(web): rewrite home page as single-screen CLI-passthrough orchestrator
Replace multi-page task management with single-screen layout: Header
with report picker at top, scrollable TaskList in the middle, and
InputBar with property pills fixed at the bottom. Owns state for
active report, task loading, input parsing, and task completion.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-14 17:35:07 +01:00
joakim a6cd0ea41d feat(web): update TaskItem and TaskList for single-screen design
TaskItem: remove onClick navigation, wrap in SwipeAction for
swipe-to-complete, update priority colors (H=red, M=amber, L=gray,
default=hidden), add due-today amber color.

TaskList: accept activeReport prop for context-aware empty states,
replace onToggle/onTaskClick with onComplete, make scrollable with
flex:1 and overflow-y:auto.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-14 17:30:02 +01:00
joakim ac0fd6c72f feat(web): add SwipeAction touch gesture component
Implements right-swipe-to-complete with angle-based lock-in (horizontal
must exceed 2x vertical), 100px threshold, green checkmark background
reveal, and CSS transition for snap-back and completion animation.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-14 17:29:14 +01:00
joakim 2f83e8fe2f feat(web): add InputBar and PropertyPills components
InputBar provides fixed-to-bottom text input with Enter to submit,
blur-delay (150ms) for pill interaction, and cursor-aware text
insertion. PropertyPills shows 8 modifier pills (Due, Pri, Project,
Tag, Recur, Scheduled, Wait, Until) on input focus.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-14 17:28:48 +01:00
joakim 5ff75453bc feat(web): add Header and ReportPicker components
Header shows active report name (left) with dropdown chevron and gear
icon linking to /settings (right). ReportPicker uses native Popover API
with 11 reports grouped into Common, Time-based, Recurring, and Archive.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-14 17:28:06 +01:00
joakim 40b1f51f64 refactor(web): remove old routes and BottomNav for single-screen redesign
Delete /tasks/new, /tasks/[uuid], /projects, /tags routes and BottomNav
component. Simplify layout to slot-only with 100dvh flexbox. Remove
nav-height CSS variable and .page padding rules.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-14 17:27:23 +01:00
joakim 83a9689e47 feat(web): add parse and report API endpoints with store methods
Add tasks.parse() and tasks.listByReport() to the API layer, and
loadReport() and parseAndCreate() to the tasks store with mock mode
support for the CLI-passthrough redesign.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-14 17:25:17 +01:00
joakim 7ea78d3b54 docs: add comprehensive deployment guide and Caddy configuration
- Create detailed deployment documentation
- Add Caddyfile.example with security headers and API proxy
- Document SystemD service setup for Go API
- Include database backup strategy
- Add troubleshooting guide
- Document OAuth configuration steps
- Add build and deployment commands
- Test production build successfully (340KB static site)
2026-01-06 16:19:34 +01:00
joakim 8145645252 feat(pwa): complete PWA configuration
- Generate PWA icons in multiple sizes (72-512px)
- Create favicon.svg with app branding
- Add offline.html fallback page
- Update app.html with PWA meta tags
- Add theme-color and apple-touch-icon
- Configure viewport-fit for mobile notches
- PWA manifest already configured in vite.config.js
- Service worker caching already configured
2026-01-06 16:17:57 +01:00
joakim e8c6dd3930 feat(frontend): implement task CRUD functionality
- Create TaskItem component with checkbox, meta info, tags
- Create TaskList component with loading/empty states
- Update home page with task list and filter toggle (pending/completed)
- Add new task form with description, project, priority, due date, tags
- Add task detail placeholder page
- Implement task toggle (complete/uncomplete)
- Add filter bar to switch between pending and completed tasks
- Support for optimistic UI updates and offline queueing
- Visual indicators for priority, due dates, overdue tasks
- Mobile-optimized list items with proper touch targets
2026-01-06 16:16:44 +01:00
joakim 6b146c16a8 feat(frontend): add core UI components and pages
- Add global CSS with mobile-first styling and CSS custom properties
- Create base UI components: Button, Input, Checkbox, Select
- Add BottomNav component with icons for Tasks, Projects, Tags, Settings
- Update app layout to include BottomNav and auth handling
- Create Settings page with API key input and sync controls
- Create auth pages: /auth/login (OAuth) and /auth/callback
- Add placeholder pages for Projects and Tags
- Implement manual API key authentication for MVP testing
- Add logout functionality and user info display
- Support for safe-area-inset (mobile notches)
2026-01-06 16:14:24 +01:00
joakim d99e158a8c feat(frontend): add API client and Svelte stores
- Create API client with auto-retry and token refresh support
- Add comprehensive API endpoints for tasks, tags, projects, sync, and auth
- Implement authStore for authentication state management
- Implement tasksStore with optimistic updates and offline queue
- Add derived stores for filtered task views (pending, completed, by project)
- Implement syncStore for managing sync state and queue
- Add client ID generation and persistence for sync tracking
2026-01-06 15:45:13 +01:00
joakim 41795d1827 feat(frontend): setup frontend foundation
- Install dependencies: date-fns, @vite-pwa/sveltekit, workbox-window
- Configure Vite with PWA support and manifest
- Update SvelteKit config for static adapter with fallback
- Create environment files (.env, .env.example, .env.production)
- Create directory structure for lib, components, routes
- Add JSDoc type definitions for Task, User, AuthTokens, etc.
- Add utility functions: storage (localStorage wrapper), uuid, dates, sync-queue
- Configure PWA with icons, theme colors, and caching strategies
2026-01-06 15:43:39 +01:00
joakim 4eb18388db feat(backend): add OAuth2/JWT authentication support
- Add OAuth2 client for Authentik integration
- Implement JWT token generation and validation
- Add refresh token support with database storage
- Update database schema with oauth_subject, oauth_provider, and refresh_tokens table
- Create auth package with config, jwt, oauth, and token management
- Add OAuth endpoints: /auth/login, /auth/callback, /auth/refresh, /auth/logout
- Update AuthMiddleware to support both JWT and API key authentication
- Add user helper functions for OAuth user creation and retrieval
- Add .env.example with OAuth configuration template

API keys still work for CLI compatibility while JWT tokens support web/mobile clients.
2026-01-06 15:42:03 +01:00