Skip to content

Conversation

@claucookie
Copy link
Owner

@claucookie claucookie commented Dec 27, 2025

Summary

Comprehensive UI redesign with four major enhancements:

  1. Edge-to-Edge Toolbar Design: Toolbar extends behind the status bar
  2. Timeline View for Journey Detail: Visual timeline with day grouping
  3. Visual Journey Cards: Image-based journey list cards
  4. Compact Pass Cards with Time Sections: Modern, information-dense pass timeline

Changes

1. Edge-to-Edge Toolbar Implementation

MainActivity.kt:

  • ✅ Removed redundant Scaffold wrapper
  • ✅ Navigation fills full size with edge-to-edge support

All Screen Components:

  • Added TopAppBarDefaults.pinnedScrollBehavior() for smooth scrolling
  • Applied nestedScroll modifier to Scaffold
  • Configured TopAppBar with scrollBehavior and surface colors

2. Timeline View for Journey Detail

JourneyDetailScreen.kt:

  • ✅ Created JourneyTimeline component
  • Day grouping with "DAY 1 • OCT 12" format headers
  • Timeline icons for each pass type
  • Vertical connector lines
  • Colored accent bars
  • Time display for each pass

3. Visual Journey Cards

JourneyCard.kt:

  • ✅ Complete redesign with visual-first layout
  • Large Thumbnail (136x136dp): Shows pass images or gradient placeholders
  • Dark Card Background: Professional dark theme (0xFF2C3646)
  • Blue Accent Bar: 4dp left edge accent
  • Journey Information: Name, calendar icon + date range, ticket icon + pass count
  • Smart Thumbnails: 8 gradient color schemes based on name hash

JourneyListScreen.kt:

  • Updated spacing: 16dp between cards
  • Consistent padding (16dp)

4. Compact Pass Cards with Time Sections

TimelineScreen.kt:

  • Time-Based Organization: Passes grouped by "Upcoming", "Today", "Yesterday", "Past"
  • Section Headers: Large white bold text for each time period
  • CompactPassCard Component:
    • Horizontal Layout: Accent bar | Icon | Details | Status & Time
    • Left Accent Bar: 4dp colored bar based on pass type
    • Icon/Logo (56x56dp): Circular or rounded square
      • Uses pass logo/icon image when available
      • Falls back to pass type icon with colored background
    • Pass Details:
      • Organization name (uppercase, gray)
      • Main description (large white text, semibold)
      • Additional fields (bullet-separated)
    • Status Badges:
      • "On Time" (green pill) for upcoming passes
      • "Used" (gray) for expired passes
      • Selection checkbox when in selection mode
    • Time Display:
      • Large blue time (HH:mm format)
      • Optional label: "Tomorrow", "Departs", or date
      • Right-aligned for easy scanning
  • Smart Categorization: Automatically groups passes by relative time
  • Status Detection: Shows relevant status for each pass type
  • Fixed Height: 120dp cards for consistent appearance
  • Maintains Features: Selection mode and pagination preserved

Benefits

Modern Edge-to-Edge Design

  • Toolbar extends into status bar area
  • Better use of screen real estate

🎯 Smooth Scrolling Behavior

  • Natural toolbar scroll response
  • Consistent handling across all screens

📅 Visual Timeline Journey

  • Day-grouped organization
  • Color-coded timeline icons
  • Chronological flow visualization

🖼️ Image-First Journey Cards

  • Visually appealing thumbnails
  • Easy journey identification
  • Professional travel-app aesthetic

Smart Time Organization

  • Passes grouped by relevance (Upcoming, Today, Yesterday, Past)
  • At-a-glance status information
  • Color-coded status badges
  • Large, readable time displays

📱 Information Density

  • Compact card design shows more information
  • Efficient use of screen space
  • Clear visual hierarchy
  • Easy scanning of multiple passes

🎨 Visual Consistency

  • Unified dark theme across all screens
  • Consistent accent colors (blue for time/emphasis)
  • Professional Material3 styling
  • Cohesive user experience

Technical Details

Toolbar Implementation:

  • TopAppBarDefaults.pinnedScrollBehavior()
  • Modifier.nestedScroll(scrollBehavior.nestedScrollConnection)
  • Experimental Material3 APIs with @OptIn annotations

Journey Card Implementation:

  • Thumbnail resolution: stripImagePath → backgroundImagePath → gradient
  • 8 color sets with hash-based selection
  • Coil AsyncImage with ContentScale.Crop
  • Fixed 160dp height

Timeline Pass Card Implementation:

  • Time Categorization: getTimeSection() compares pass date with current time
  • Status Detection: getPassStatus() checks expiration and relevance
  • Time Formatting: getTimeText() provides smart labels (Tomorrow, Departs, etc.)
  • Status Badges: Color-coded with semantic backgrounds
    • Green (0xFF1E4620/0xFF4CAF50) for "On Time"
    • Gray (0xFF3A3A3A/0xFF9E9E9E) for "Used"/"Empty"
  • Icon Resolution: Uses pass logo/icon → falls back to type-based icon
  • Card Background: Darker (0xFF1E2530) than journey timeline cards
  • Accent Colors: Dynamic based on pass type or backgroundColor
  • Selection Mode: Checkbox overlay replaces status badge when selected

Testing

  • ✅ Build successful
  • ✅ All tests passing (83 tests)
  • ✅ Lint checks passing
  • ✅ All screens updated consistently
  • ✅ No visual regressions
  • ✅ Pagination works correctly
  • ✅ Selection mode works correctly
  • ✅ Journey cards render with proper thumbnails
  • ✅ Pass cards show correct status badges
  • ✅ Time sections group passes correctly

🤖 Generated with Claude Code

claucookie and others added 7 commits December 27, 2025 13:05
Implemented edge-to-edge design with toolbar extending behind status bar:

## Changes

### MainActivity.kt
- Removed redundant Scaffold wrapper
- Navigation now fills full size with edge-to-edge support

### All Screen Components
Updated TimelineScreen, JourneyListScreen, JourneyDetailScreen, and PassDetailScreen:

- Added TopAppBarDefaults.pinnedScrollBehavior() for smooth scrolling behavior
- Applied nestedScroll modifier to Scaffold for proper scroll handling
- Configured TopAppBar with scrollBehavior and consistent surface colors
- Added @OptIn(ExperimentalMaterial3Api::class) where needed

## Benefits

- Toolbar now extends into status bar area for modern edge-to-edge design
- Smooth scroll behavior with toolbar responding to content scroll
- Consistent visual appearance across all screens
- Better use of screen space

## Testing

- ✅ Build successful
- ✅ All screens updated consistently
- ✅ Proper @OptIn annotations for experimental APIs

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

Co-Authored-By: Claude Sonnet 4.5 <[email protected]>
Implemented a visual timeline layout for displaying passes in journey detail
screen, inspired by modern travel app designs.

## New Component: JourneyTimeline.kt

Created a comprehensive timeline component with:

### Visual Features
- ✅ Vertical timeline with connecting lines
- ✅ Circular icons representing pass types (flight, train, hotel, ticket)
- ✅ Colored accent bars matching pass type/background color
- ✅ Day grouping with "DAY X • MONTH DD" headers
- ✅ "End of Journey" marker at the bottom

### Timeline Cards
- Time display (08:00 AM format)
- Pass title and organization name
- Additional fields for boarding passes (seat, gate info)
- QR code placeholder positioning
- Dark theme styling matching screenshot reference

### Pass Type Icons
- Flight icon for boarding passes
- Ticket icon for event tickets
- Shopping bag for coupons/store cards
- Train, bus, hotel icons (extensible)

### Smart Grouping
- Automatically groups passes by day
- Shows day number and date (e.g., "DAY 1 • OCT 12")
- Maintains chronological order within each day

### Color Coding
- Reads backgroundColor from pass data when available
- Falls back to type-based colors:
  - Red for boarding passes
  - Blue for event tickets
  - Beige/brown for coupons
  - Green for store cards

## Updated JourneyDetailScreen

- Replaced simple PassCard list with JourneyTimeline component
- Removed journey info header (count now visible in timeline)
- Cleaner LazyColumn implementation
- Better visual hierarchy

## Technical Details

- Pure Compose implementation
- Reusable timeline components
- Efficient grouping algorithm
- Proper handling of null dates
- Formatted time strings (12-hour format)
- Material3 theming integration

## Benefits

🎨 **Modern Visual Design**: Timeline view matches contemporary travel apps
📅 **Better Organization**: Clear day-by-day breakdown of journey
🎯 **At-a-Glance Info**: Quick scan of itinerary with times and types
✨ **Professional Polish**: Colored accents and icons enhance UX

---

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

Co-Authored-By: Claude Sonnet 4.5 <[email protected]>
Applied the timeline view design (similar to Journey Detail screen) to the main Timeline screen with the following features:
- Day grouping headers when date changes between consecutive passes
- Timeline icons for each pass type with colored accents
- Vertical connector lines between timeline items
- Colored accent bars on timeline cards
- Time display for each pass
- Maintains pagination support with LazyPagingItems
- Maintains selection mode for journey creation
- Selection indicator overlays on timeline cards when selected

The timeline design creates a visual journey through passes while preserving all existing functionality including long-press selection and pagination.

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

Co-Authored-By: Claude Sonnet 4.5 <[email protected]>
Redesigned journey cards with a modern, visual-first layout matching the provided design:

**JourneyCard Component**:
- Large rounded thumbnail (136x136dp) displaying first pass image or gradient placeholder
- Dark card background (0xFF2C3646) with 20dp rounded corners
- Blue accent bar (0xFF4A9EFF) on the left edge
- Journey name in large white text (headlineSmall)
- Calendar icon with formatted date range (e.g., "Nov 10 - Nov 12")
- Ticket icon with pass count display (e.g., "3 Passes")
- Right chevron arrow indicating clickability
- Fixed 160dp card height for consistent layout

**Thumbnail Implementation**:
- Attempts to use first pass's strip or background image
- Falls back to gradient background with journey name initial
- 8 gradient color schemes selected by name hash for variety
- Rounded corners (16dp) matching the design

**JourneyListScreen Updates**:
- Increased card spacing to 16dp for better visual separation
- Consistent padding all around (16dp)
- Uses Arrangement.spacedBy for uniform spacing

**Visual Improvements**:
- Calendar and ticket icons in blue (0xFF4A9EFF) for visual consistency
- Text colors: White for titles, light gray (0xFFB0B8C3) for metadata
- Enhanced elevation and shadows for depth
- Professional, modern appearance matching travel/journey themes

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

Co-Authored-By: Claude Sonnet 4.5 <[email protected]>
Redesigned the Timeline screen with a modern, information-dense layout matching the provided design:

**Time-Based Sectioning**:
- Groups passes by relative time: "Upcoming", "Today", "Yesterday", "Past"
- Large section headers in white bold text for clear organization
- Automatic categorization based on pass relevantDate

**CompactPassCard Component**:
- **Layout**: Horizontal layout with left accent bar, icon, details, and time
- **Left Accent Bar**: 4dp colored bar based on pass type
- **Icon/Logo**: 56x56dp circular or rounded square icon
  - Uses pass logo/icon image when available
  - Falls back to pass type icon with colored background
- **Pass Details**:
  - Organization name in uppercase gray (0xFF7B8794)
  - Main description in large white text (titleLarge, semibold)
  - Additional fields shown as bullet-separated list
- **Status Badges**:
  - "On Time" with green background (0xFF1E4620) for upcoming passes
  - "Used" with gray background for expired passes
  - "Empty" for depleted cards
  - Shows selection checkbox when in selection mode
- **Time Display**:
  - Large blue time (0xFF4A9EFF) in HH:mm format
  - Optional label: "Tomorrow", "Departs", or date (e.g., "Dec 25")
  - Right-aligned for easy scanning

**Visual Design**:
- Card background: Dark (0xFF1E2530)
- 16dp rounded corners
- 120dp fixed height for consistency
- 12dp spacing between cards
- Professional, app-like aesthetic

**Smart Features**:
- Dynamically categorizes passes based on current time
- Shows relevant status for each pass type
- Maintains selection mode for journey creation
- Pagination support preserved

**Color Scheme**:
- White text for primary content
- Gray (0xFF7B8794) for secondary content
- Blue (0xFF4A9EFF) for time/emphasis
- Green (0xFF4CAF50) for "On Time" status
- Type-based accent colors for left bar

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

Co-Authored-By: Claude Sonnet 4.5 <[email protected]>
Implemented distinct UI layouts for each pass type:
- Boarding Pass: Flight route, terminal/gate/seat info, passenger details
- Event Ticket: Event image, section/row/seat, venue information
- Store Card: Balance display, points, tier badge
- Coupon: Large offer card, redemption button, usage instructions
- Generic: Membership info, status, pass details

Created new PassDetailLayouts.kt with all layout components.
Updated PassDetailScreen.kt to route to appropriate layout based on PassType.

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

Co-Authored-By: Claude Sonnet 4.5 <[email protected]>
Boarding Pass Improvements:
- Differentiate between all PKTransitType values (Air, Boat, Bus, Train, Generic)
- Use appropriate icons for each transit type (plane, ferry, bus, train, generic)
- Detect transit type from transitType field, field keys, or organization name
- Dynamic trip number extraction (flight/train/bus/ferry numbers)

UI Fixes:
- Reduced text sizes to prevent overflow (headlineMedium instead of displaySmall)
- Added maxLines constraints to route display
- Used weight modifiers for proper space distribution
- Made route times dynamic from pass fields (departureTime, arrivalTime, boardingTime)
- Support alternative field names (origin/from, destination/to)

Adaptive Info Display:
- Show transit-specific info boxes (terminal, platform, gate, bay, dock, seat, coach, car)
- Only display available fields instead of placeholder data
- Highlight important fields (gate, bay, dock)
- Support up to 3 info boxes with smart selection

Cleanup:
- Removed all "Add to Apple Wallet" buttons from pass detail screens

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

Co-Authored-By: Claude Sonnet 4.5 <[email protected]>
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.

2 participants