App bar

The top bar of a phone screen (Material's top app bar, the iOS navigation bar): back or menu, a title and subtitle, actions, and an optional row under it. It elevates once the content scrolls, or hides while scrolling down.

Source on GitHub

Patterns (scroll inside each phone)
    Back, title and subtitle, actions; elevates once it scrolls
    Cancel Done
      center (iOS) and scroll-behavior="hide": away going down, back going up
        variant="filled" with a search row (the bottom slot)
          size="lg" with a segmented control under it
          Code

          API

          For AI agents: this API as Markdown, or every component in llms-full.txt.

          <ray-app-bar> · RayAppBar

          It follows the scroller of its ray-app-shell, else scroll-target, else the window; clear of the notch (safe-area inset). The title is plain text: put a heading in the default slot when the page needs one.

          PropertyAttributeTypeDefaultDescription
          labellabelstringThe title.
          descriptiondescriptionstringA line under the title.
          centercenter reflectsbooleanThe title centered (iOS).
          variantvariant reflectsdefault | filled | transparentdefaultdefault: the page background; filled: the primary color; transparent: until it elevates.
          sizesize reflectssm | md | lgmdHeight: 48, 56 or 64 px.
          scrollBehaviorscroll-behavior reflectselevate | hide | noneelevateWhile the content scrolls: elevate (border and shadow), hide (also slides away going down, back going up), none.
          stickysticky reflectsbooleanSticks to the top of the window (outside a shell).
          scrollTargetscroll-targetstringA selector of the element whose scrolling it follows (default: its shell's, else the window).
          SlotDescription
          (default)Title content after the label (a heading, a select).
          startBefore the title: back or menu button.
          endActions.
          bottomA row under the bar: tabs, a search field.
          PartDescription
          barThe bar.
          startThe start area.
          titleThe title area.
          endThe actions area.
          bottomThe row under the bar.