Conversation
Changed text rendering to use viewBox-relative units instead of pixels so text scales proportionally with the postcard size. - Changed fontSize from pixels to relative units (divided by 5) - Adjusted strokeWidth to scale properly (divided by 20) - Updated lineHeight calculations to use relative units Fixes #43 Co-authored-by: Marco Wettstein <macrozone@users.noreply.github.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
@claude there was a missunerstanding. i meant the text on the back of the card (the message) |
|
Claude finished @macrozone's task —— View job ✅ CompletedFixed the misunderstanding - I've now applied the text scaling to the message on the BACK of the postcard. Changes made:
The text on the back of the postcard will now maintain proper proportions at any size. |
Converted the postcard back side to use SVG with viewBox-relative units so the message text scales proportionally with the postcard size. Co-authored-by: Marco Wettstein <macrozone@users.noreply.github.com>
|
@claude ok, does not work, because svg does not has automatic line breaks. any other idea? can we make it relative to the preview container? or measure? |
|
Claude finished @macrozone's task —— View job ✅ Fixed: Text scaling with proper line wrappingI've successfully replaced the SVG-based back side with an HTML/CSS approach that properly handles text wrapping while maintaining scalability. Changes Made:
How it works:
The text on the back of the postcard will now maintain proper proportions at any size while supporting automatic line breaks. |
- Replaced SVG rendering with HTML elements and CSS for the postcard back - Added ResizeObserver to scale text relative to container size - Message text now supports automatic line breaks with whitespace-pre-wrap - All text elements scale proportionally with postcard size Co-authored-by: Marco Wettstein <macrozone@users.noreply.github.com>
Fixes #43
Changes
Result
Text on postcards will now maintain proper proportions at any size.
Generated with Claude Code