Skip to content

Terminal style cards - #14

Merged
AzertoxHDW merged 8 commits into
mainfrom
claude/terminal-style-cards-011dt2HnscfDvU9iFB8ohvY5
Nov 19, 2025
Merged

Terminal style cards#14
AzertoxHDW merged 8 commits into
mainfrom
claude/terminal-style-cards-011dt2HnscfDvU9iFB8ohvY5

Conversation

@AzertoxHDW

Copy link
Copy Markdown
Owner

No description provided.

- Added terminal window wrapper with title bar and control buttons (close, minimize, maximize)
- Implemented CRT-style effects: glow, scanlines, and screen curve
- Styled title bar with macOS-style colored buttons
- Cards now have terminal window aesthetic with enhanced visual appeal
- Removed unused dashboard-card CSS classes
- Removed CRT scanline effects for cleaner look
- Removed glow effects (both primary color and screen curve)
- Reduced border thickness and shadow intensity for flat design
- Restructured card header: icon and title now side-by-side in flex row
- Removed bottom margin from icon wrapper for better alignment
- Added draggable functionality using existing draggable action
- Converted grid layout to absolute positioning for free-form placement
- Title bar acts as drag handle with grab cursor
- Cards stack with z-index management (click to bring to front)
- Initial positions: cards arranged in 2x2 grid layout
- Fixed card width at 380px for consistency
- Added user-select: none to title bar to prevent text selection while dragging
- Calculate centered initial positions dynamically based on viewport width
- Increased card width from 380px to 450px for better content visibility
- Fixed drag smoothness by removing transform transition (was causing lag)
- Transition now only applies to border-color and box-shadow
- Removed hover translateY effect that conflicted with dragging
- Added onMount to recalculate positions for proper centering on client-side
- Added onDragStart callback to bring window to front when dragging starts
- Added mousedown handler on terminal-content to bring window to front when clicking anywhere on the content
- Dual approach ensures clicking either title bar or content area brings window to front
- Fixes issue where stopPropagation in draggable action prevented mousedown events
- Changed from tracking full position state (x, y, zIndex) to only tracking z-index
- Draggable action now autonomously manages all positioning via style.left/top
- Updating z-index no longer triggers re-render that resets position
- Clicking to bring window to front now only updates z-index, preserving dragged position
- Removed CardPosition interface in favor of simpler number-based z-index store
- Removed reactive store for z-index that was causing re-renders
- Now using bind:this to get DOM references to card elements
- Directly manipulating element.style.zIndex without triggering Svelte reactivity
- Clicking or dragging cards only updates z-index via DOM, no component re-render
- Position managed entirely by draggable action, no state interference
@AzertoxHDW
AzertoxHDW merged commit 5fb23b8 into main Nov 19, 2025
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