Lyna
SupportBlog
IntroductionFeaturesIntegrationsTips & TricksChangelog
Design

Responsive Design

Lyna provides a responsive design workflow built on Tailwind CSS breakpoints. Edit styles at specific screen sizes, resize frames to match devices, and preview multiple viewports simultaneously.


Tailwind breakpoints

BreakpointMin widthDefault preview widthTypical use
Base0px375pxMobile (default, no prefix)
SM640px640pxLarge phones
MD768px768pxTablets
LG1024px1024pxLaptops
XL1280px1280pxDesktops
2XL1536px1536pxLarge screens

Tailwind is mobile-first: unprefixed styles apply to all sizes. Prefixed styles (e.g., md:flex-row) override at that width and above.


Breakpoint selector

The breakpoint selector sits at the top of the Styles panel with all six breakpoints as clickable buttons:

  • Mobile icon for Base and SM
  • Tablet icon for MD
  • Laptop icon for LG
  • Desktop icon for XL and 2XL

How breakpoint editing works

Select a breakpoint and modify a style:

  1. Lyna prefixes the Tailwind class with the breakpoint (e.g., md:flex-row)
  2. The frame resizes to the breakpoint's preview width
  3. Previous breakpoint preview styles are cleared
  4. Changes flush to the sandbox and the iframe soft-reloads

Returning to Base restores the frame's previous width.


Device presets

The frame top bar has a device selector with real device dimensions:

Desktop

DeviceResolution
Desktop1440 x 1024
Wireframe1440 x 1024
TV1280 x 720
iMac1280 x 720

Laptop

DeviceResolution
MacBook Air 151536 x 960
MacBook Pro 141512 x 982
MacBook Pro 161728 x 1117
MacBook Pro1440 x 900
Surface Book1500 x 1000

Tablet

DeviceResolution
iPad Pro 12.91024 x 1366
iPad Pro 11834 x 1194
iPad Air 10.9820 x 1180
iPad Mini 8.3744 x 1133
Surface Pro 81440 x 960
Android Expanded1280 x 800

Phone

DeviceResolution
iPhone 17 Pro Max430 x 932
iPhone 17 Pro393 x 852
iPhone 17393 x 852
Android Large360 x 800
Android Small360 x 640

Selecting a preset resizes the frame to match. You can also enter Custom dimensions.


Frame rotation

The Rotate button toggles between portrait and landscape by swapping width and height. Useful for testing tablet layouts in both orientations.


Quick device presets

Four common presets are available from the breakpoint controls:

  • Desktop (1440px)
  • MacBook Air (1536px)
  • iPad Pro 11 (834px)
  • iPhone 16 (393px)

Multi-frame preview

The canvas supports multiple frames at once:

  • Add frames at different viewport sizes to see multiple breakpoints simultaneously
  • Compare mobile, tablet, and desktop side by side
  • Each frame operates independently for scrolling, interaction, and navigation

Powerful for verifying responsive layouts across all target devices without resizing a single frame.


Responsive style workflow

  1. Start with Base (mobile): Design the mobile layout first. Set layout, spacing, and typography at Base.
  2. Move up to MD: Click MD. Frame resizes to 768px. Adjust for tablet, e.g. flex-col to md:flex-row.
  3. Move up to LG: Click LG. Frame resizes to 1024px. Add desktop-specific adjustments like wider containers or larger fonts.
  4. Test at all sizes: Use the device selector or drag resize handles. Add frames for side-by-side comparison.
  5. Refine in code: For complex responsive behavior, edit Tailwind classes directly in the code editor.

Tips

  • Design mobile-first: Start at Base and work up. Follows Tailwind's approach and produces cleaner CSS.
  • Use multi-frame canvas: Mobile and desktop visible at the same time catches layout issues you'd miss testing one size at a time.
  • Test with real device presets: Use actual device dimensions instead of arbitrary sizes.
  • Check in Preview mode: After responsive changes, switch to Preview and resize the window to test breakpoint transitions.