Skip to content

DivineDominion/10min-Window-AutoLayout

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

10min AutoLayout Challenge

Video demo: https://twitter.com/teilweise/status/1295700159184154624

Can you recreate this layout in 10min in SwiftUI?

Behavior when resizing the window:

  • Only valid window sizes. You can't resize vertically and end up with tons of space. 20pt padding from window border to content, aka the default passing.
  • If the window is wide enough, all buttons have the same width and space between the leftmost one and the Cancel/OK pair to the right.
  • As the width of the window decreases, the text reflows and the buttons shrink.
  • As the text reflows, it takes up more vertical space and increases the window height.
  • As the buttons shrink, the "OK" and "Cancel" buttons reduce in width uniformly until their intrinsic content size (the text content) is reached as the minimum size.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages