Sliding-pane UIs: webOS Enyo ideas to React drag layouts

11 steps · about 3 h 53 min · Intermediate

  1. State: A Component's Memory (doc, react.dev, 20 min)

    Pane layouts are state, so start with how React stores and updates it.

  2. Choosing the State Structure (doc, react.dev, 20 min)

    Pane widths and open or closed flags are easy to store redundantly, and this shows how to avoid that.

  3. Managing State (doc, react.dev, 30 min)

    Covers lifting state and reducers, which you need to coordinate several panes.

  4. Enyo (software) (article, Wikipedia, 10 min)

    Gives the history of the webOS framework that popularised sliding panels.

  5. Enyo 2.0 beta 5 brings panels, bootplates, and more (article, webOS Nation, 8 min)

    Names Enyo's original arrangers (card, carousel, collapsing), the vocabulary for sliding layouts.

  6. enyojs/layout: UI infrastructure for Enyo applications (repo, GitHub (enyojs), 15 min)

    Shows the original Panels and Slideable design next to a flexbox-like Fittable layout.

  7. Pointer Events (article, 12 Days of Web, 20 min)

    Walks through building a draggable resize handle with pointer capture and keyboard support.

  8. How to Use Pointer Events in JavaScript (article, TutorialReference, 20 min)

    Covers pointer capture and touch-action: none, the details that make drags work on touch screens.

  9. Basic concepts of scroll snap - CSS - MDN Web Docs (guide, MDN, 20 min)

    Teaches the browser's built-in snapping, so you can compare it with snapping to fractions in JavaScript.

  10. GitHub - bvaughn/react-resizable-panels (repo, GitHub (bvaughn), 30 min)

    A widely used split-pane library to compare against; look at its Panel, Group and min/max size constraints.

  11. GitHub - vcarl/sashay: Sliding panes for the web (repo, vcarl (GitHub), 40 min)

    Capstone: read a modern React 19 sliding-pane library with a zero-dependency core, snapping, throw physics and URL-encoded layouts.