Skip to content

SiteBuilder 0.3.0

Choose a tag to compare

@spinlockd spinlockd released this 24 Oct 06:59
· 26 commits to main since this release
0.3.0
3a66fe7

SiteBuilder 0.3.0 adds a navigation bar, materials, and dividers.

New

  • NavigationBar is a bar with a site's title and main links. It stays at the top of the window, over a blurred material. Its content is centered at a maxWidth that you match to the page's content. On screens narrower than 641 pixels, the links move into a menu built on a <details> element, so it works with touch, a pointer, the keyboard, and screen readers, without JavaScript.
  • The current page is marked: every link to the page being viewed gets aria-current="page", and the navigation bar shows it in the tint.
  • Material and background(_:) give views SwiftUI's translucent, blurred backgrounds, from ultraThin to ultraThick, plus bar. A material becomes nearly opaque when the browser reports a preference for reduced transparency, or can't blur.
  • Divider draws a hairline across a VStack or down an HStack, and stays visible in forced colors mode.
  • frame(maxWidth: .infinity) fills the available width, as in SwiftUI.

Changed

  • Built-in views ship their styles only when a page uses them.