Galaxy Shell / docs
Docs / Interface e recursos

Motion in the system UI

openspec/specs/motion/spec.md · Editar no GitHub ↗

Esta página ainda não tem tradução em português. O conteúdo abaixo está em inglês.

Nesta página

Motion in the system UI

Purpose

Define how the system UI animates: CSS by default, with the Motion library adopted in restricted use for exits, layout, reorder and springs. It lists what uses Motion and what stays out on purpose.

Requirements

Requirement: CSS is the default for animation

CSS SHALL be the default for animation (the Base UI data attributes and the motion tokens of host/theme.css), and Motion SHALL be used only for exits, layout and reorder animation, and springs. No part uses tw-animate-css today. Full text: section Binding contract (from AGENTS.md).

Scenario: Hover and color change

  • WHEN a component needs a hover, focus or color change
  • THEN it uses CSS and the motion tokens, not Motion

Requirement: Motion through LazyMotion strict and reduced motion

Every m component SHALL be under MotionScope, which holds LazyMotion ... strict and MotionConfig reducedMotion="user", and the full motion component MUST NOT be used. Where the profile CSS must own the resting look (the messages), a plain React element SHALL run the animate of motion/mini in an effect, and it checks prefers-reduced-motion itself. Full text: section Rules for the system UI.

Scenario: User prefers reduced motion

  • WHEN the user setting asks for reduced motion
  • THEN a message neither moves nor fades

Requirement: popLayout only in the chat document

AnimatePresence mode="popLayout" SHALL be used only in the chat document, with MotionConfig nonce and root set to the ShadowRoot. Pages with style-src 'self' and no nonce (the protected panels, the lock screen, recovery, the wallpaper) MUST use only the sync or wait mode. Full text: sections Binding contract (from AGENTS.md) and Rules for the system UI.

Scenario: Protected panel with an exit

  • WHEN a protected panel animates an exit
  • THEN it uses AnimatePresence in sync or wait mode

Requirement: Where Motion is used

The popups, the switch and the tabs of the shared parts and the notification cards SHALL use Motion, with one copy per document in the runtime of the chat and the runtime of the panels. Full text: section Binding contract (from AGENTS.md).

Scenario: Popup opens

  • WHEN a Popover, Tooltip or Select popup opens
  • THEN it renders through renderPopup with Motion

Requirement: Surfaces that stay without Motion

The approval dialogs, the change review card, the lock screen, recovery, the wallpaper, the bottom bar tabs and the overview cards SHALL stay without Motion. Recovery, the wallpaper and the lock have no Motion runtime. Full text: section Binding contract (from AGENTS.md).

Scenario: Approval dialog opens

  • WHEN an approval dialog opens
  • THEN its buttons do not move, because the dialog uses no Motion

Requirement: Every animated element is React

Every animated element SHALL be a React element, either an m component under LazyMotion ... strict or a plain React element that runs animate of motion/mini in a layout effect on mount. Full text: section Rules for the system UI.

Scenario: Message article

  • WHEN a message article animates
  • THEN it is a React element and at the end it has no inline opacity or transform

Requirement: Glass surfaces opacity ramp

On glass surfaces the animation SHALL lead with transform or scale and keep the opacity ramp at about 120 ms or less, so the alpha mask threshold passes quickly. Full text: section Rules for the system UI.

Scenario: Popup over the chat glass

  • WHEN a popup fades over a glass surface
  • THEN its opacity ramp is about 120 ms or less

Requirement: Measure layout position, not rectangles

Code that measures an element that can animate SHALL read its layout position (offsetTop, offsetHeight), not a rectangle, because a rectangle includes a running transform. Full text: section Rules for the system UI.

Scenario: Jump to a message

  • WHEN code measures a message that may be animating
  • THEN it reads offsetTop and adds the offsets of each offset parent in between

Requirement: One Motion copy per runtime

A document SHALL have one copy of Motion, in its runtime, and a runtime gets Motion only when a surface in it needs it. Full text: section Rules for the system UI.

Scenario: Chat document

  • WHEN the chat document loads Motion
  • THEN ui/app.js takes it from window.AgentNativeReact.Motion

Requirement: Entries follow the key

A message entry SHALL follow the key of the message, not the mount and not the position, because the core re-keys a sent message at the end of a turn. Full text: section Rules for the system UI.

Scenario: Message gets its id

  • WHEN a shown message only gets its id at the end of the turn
  • THEN it does not enter again

Requirement: An exit keeps the element in the DOM

An exit SHALL keep the element in the DOM for its duration, so code and tests that expect it gone at once MUST wait for it. Full text: section Rules for the system UI.

Scenario: Unpinning a component

  • WHEN a pin is removed
  • THEN it stays in the DOM, inert, until its exit ends

Requirement: Every component of the system UI is React

Every component of the system UI SHALL be a React component; the owner said on 2026-11-05: "Todo componente que nós fazemos deve estar usando react". Full text: section Binding contract (from AGENTS.md).

Scenario: New system UI component

  • WHEN a component is added to the system UI
  • THEN it is a React component

Status

Doc status: current contract. Motion adopted 2026-11-05 in restricted use. Checked 2026-11-11.

Status

Adopted on 2026-11-05, in restricted use ("uso restrito"). The user first asked to compare animation libraries ("Estou interessado em usar uma lib de motion como motion.dev no sistema para poder ter melhores animações, compare as alternativas") and then for a spike of Motion (motion 14.9.1, MIT, https://motion.dev) against the CSP, the ShadowRoot and the glass of the chat. After the spike the questions were "Adotar o Motion na UI do sistema, em uso restrito?" and then "Adotar o Motion e seguir para revisão e publicação no main?", and the user answered "Adotar e publicar". Restricted use was my recommendation, and the user accepted it with that answer: CSS stays the default, and Motion is for what CSS cannot do.

The same day the user also said "Todo componente que nós fazemos deve estar usando react" and "Vamos fazer isso" to turning the hand-made message articles into React components, which the adoption carries.

On 2026-11-06 the user said "pode adicionar "motion" aos componentes agora". The user named no list, so the list below is my reading: the shared shadcn parts that animate (popups, the switch, the tabs) and the notification cards. What stays out, and why, is under "What does not use Motion".

Rules for the system UI

Rule 1 is the accepted recommendation; the others follow from the user rule that every component is React and from the findings of the spike below.

  1. CSS is the default: the data attributes of Base UI and the motion tokens of host/theme.css (--motion-fast, --motion-base, --ease-standard, openspec/specs/css-structure/spec.md) for hover, focus and color changes. Motion is for what CSS cannot do: the exit of an element that React removes, layout and reorder animation, and springs. Since 2026-11-06 the popups of the shared parts are in this second group. No part uses tw-animate-css today; its import stays in shadcn-host.css for a CSS entry that needs it.
  2. Every animated element is a React element, in one of two ways. An m component (for example m.section) under LazyMotion ... strict, never the full motion component, so the bundle carries only the features that the root loads (finding 10): Motion then owns opacity and transform of that element for its whole life and writes them inline on every render, so use it where that is fine, as on the pins, and for exits and layout. A plain React element whose component runs the animate of motion/mini in a layout effect on mount, and removes the inline opacity and transform when it ends and stops the animation on unmount: use it where the profile CSS must own the resting look, as on the messages (finding 6).
  3. Every m component is under MotionScope (ui-src/host/ui/motion.jsx), which holds LazyMotion ... strict and MotionConfig reducedMotion="user". The default of reducedMotion is "never", which ignores the user setting (finding 4), and an m component with no LazyMotion above it does not animate at all, with no error. A shared part brings its own scope, so it works in any root. MotionConfig does not reach the imperative animate, so a component that uses it checks prefers-reduced-motion itself.
  4. AnimatePresence mode="popLayout" works only in the chat document: it needs MotionConfig nonce (the chat has it in document.body.dataset.nonce) and root set to the ShadowRoot (window.shell.root). The pages with style-src 'self' and no nonce (the protected panels, the lock screen, recovery, the wallpaper) use only the sync or wait mode (findings 1 to 3).
  5. On glass surfaces lead with transform or scale and keep the opacity ramp at about 120 ms or less, so the alpha mask threshold passes quickly (finding 9).
  6. Code that measures an element that can animate reads its layout position (offsetTop, offsetHeight), not a rectangle, because a rectangle includes a running transform (finding 5). offsetTop is relative to the offset parent, so add the offsets, and the border of each offset parent in between, up to the element that you measure from; profile CSS can position an element in between (finding 14).
  7. The system has five separate runtimes (chat, panels, recovery, wallpaper, lock). A document has one copy of Motion, in its runtime: ui/app.js takes it from window.AgentNativeReact.Motion, and the panel modules from window.AgentNativePanel. A runtime gets Motion only when a surface in it needs it (finding 10): recovery, the wallpaper and the lock have none.
  8. A mount is not an entry, and a position is not one either. The core re-keys a sent message at the end of a turn, so an entry that follows the mount alone plays twice, and it can insert the reply before a surface published during the turn, so an entry that follows the position flags the wrong message (findings 12 and 15). Follow the key, and treat as the same message a shown message whose key is gone and whose content is the same, or a shown message with no id whose key is gone and that sat at the same index with the same role (the text that mergeHistory rebuilds from the parts can differ from the stored one).
  9. An exit keeps the element in the DOM for its duration: code and tests that expect it gone at once must wait for it (finding 7).

What uses Motion today

The chat document (host/shadcn-host.js holds the one copy) and the protected panels (host/shadcn-panel.js):

  • ui-src/host/ui/motion-presets.js: one preset per window theme (office, galaxy, ninja) with the popup variants, the notification card (cardInitial, cardTransition, cardExit) and the message entry (message), plus the partSpring and opacityRamp that every theme shares (theme-packs.md, sections 4 and 5). A Motion part reads --ui-theme-id from the computed theme sheet when it mounts (motionPresetOfDocument), so a theme change needs no reload, and an unknown id is office. Office: the popup scales 0.98 to 1 with no bounce (opacity 90 ms, out in 80 ms), a card slides in 12 px in 140 ms, a message rises 8 px in 140 ms with no stagger. Galaxy: the popup scales 0.9 to 1 on a spring (visualDuration 0.28, bounce 0.25; opacity and exit 120 ms), a card drops 16 px on that spring (the history closes gaps on it), a message rises 16 px as before. Every popup variant keeps an opacity track, and no opacity ramp of a glass surface passes 120 ms. The message entry and the pins of ui-src/app.jsx cannot import a module (the seed takes its spring generator from the window globals), so messageEntries there is a copy of the message field of each preset and test/motion-presets.test.js holds the two equal.
  • ui-src/host/ui/panel-entry.js and host/panel-base.css: a solid panel (the class material-solid, so Office) enters with the CSS animation panel-entry, a rise of 8 px and a fade in --motion-base, which the panel runtime plays again at each show (visibilitychange: it sets data-panel-entering on main, which the rule requires, and removes it at a hide or after the entry, so a theme change on an open panel starts none). A glass panel has none, because a transform on main would leave the blur of the window behind it, and the Start menu of Office opts out with data-panel-entry="none" because it is translucent. Reduced motion has none.
  • host/workspace-zoom.js (CSS and WAAPI, no Motion): the overview card zoom reads its duration from --motion-zoom (Office 200 ms, Galaxy 320 ms, default 300 ms) and its start radius from --radius-surface.
  • ui-src/host/ui/motion.jsx: MotionScope, the re-export of the shared spring and opacity ramp, and renderPopup. Each runtime imports ui/motion-globals.js first.
  • Popups of ui/popover.jsx, ui/tooltip.jsx and ui/select.jsx: the Base UI popup renders through renderPopup, an m.div that follows state.open. It scales from the value of the theme preset (0.98 in Office, 0.9 in Galaxy) with the opacity ramp of rule 5, and closes in 80 ms (Office) or 120 ms (Galaxy). Base UI keeps it mounted until the opacity animation ends (finding 11), so the scale of the exit has the same duration. The Select had no animation before.
  • ui/switch.jsx: the thumb is an m.span that moves in rem on a spring.
  • ui/tabs.jsx: the mark of the active tab is one m.span with a layoutId inside a LayoutGroup per list, and it slides between the tabs on a spring. The label sits above it. host.css colors it in the settings ([data-slot="tabs-indicator"]). The panels of the tabs do not animate.
  • notifications.jsx: each card is an m.li in AnimatePresence. A new card enters by the preset of the theme (Office slides 12 px in 140 ms; Galaxy drops 16 px on a spring), a removed one slides out in 120 ms and is inert meanwhile. In the history the others close the gap (layout="position"), and the history that opens does not animate. A popup has no layout animation, because its window fits <main> at once and a card that moved would be cut until it arrived. When the last popups leave, <main> fades as before, inert during the fade (since 2026-11-06), and the cards drop with no exit (a new key on AnimatePresence), and the same holds for a card removed while the document is hidden: a hidden window draws no frames to end an exit in, so its removed cards would pile up. That key remounts the cards that stay too, so a popup among them enters again when the window shows.
  • App of ui-src/app.jsx provides MotionScope to the conversation.
  • Message articles: React owns each one as a plain article with its key, rendered by ChatMessage. A message enters when the conversation is mounted, its key was not shown at the last commit and it is not a re-key of a shown message (rule 8). It rises by the entry of the theme (Office 8 px in 140 ms; Galaxy 16 px on a spring, visualDuration 0.3, bounce 0.2) with an opacity ramp of 120 ms linear, through the WAAPI animate of motion/mini in a layout effect on mount; the messages that enter in one commit follow each other by the stagger of the theme (Galaxy 40 ms, Office none), at most 4 steps. The entry reads the computed opacity and transform of the article first and ends at them, so a profile rule on those properties is the resting look, and it runs one animate per property: Motion commits the last keyframe inline when a property ends, and each property removes its own value at once. At the end the article has no style attribute, and the markers are updated once. With reduced motion a message neither moves nor fades. The history of a conversation that opens does not animate.
  • keepFramesOnMove: the #messages container moves a child that it already holds with moveBefore. React 19.3.1 moves a keyed child with insertBefore or appendChild, and a moved inline frame loads its document again. React has this behind its enableMoveBefore flag, which the installed build does not carry; remove the function when it does.
  • Pinned column: each pin is an m.section with layout inside AnimatePresence mode="popLayout" root={window.shell.root}. A pin scales in on a spring, an unpinned one scales out, and the others close the gap on the same spring; the opacity of a pin ramps in 120 ms linear both ways (rule 5). A leaving pin is inert from React (useIsPresent), because it stays over the slot that the others slide into and the seed style.css is not a trusted place for the rule. The key per conversation makes a conversation switch replace the column with no animation.
  • jumpToMessage adds up offsetTop and the border (clientTop) of each offset parent in between to the scroller (rule 6). A sticky or hidden ancestor is not handled.
  • Before the Motion runtime runs, ui/motion-globals.js pins the globals of window that Motion reads, in the chat document and in the panels (MotionCheckAppearSync, MotionHandoffAnimation, MotionHandoffIsComplete, MotionHandoffMarkAsComplete, MotionHasOptimisedAnimation, MotionCancelOptimisedAnimation, __MOTION_INSPECT__) as own non-writable undefined properties, so a named element or child frame cannot shadow them; Motion calls some of them when they are set. Generated frames must stay inside the ShadowRoot, where named access to window does not apply. MotionIsMounted is not pinned, because Motion writes it.
  • scripts/test-ui-browser.js waits for the exit of an unpinned surface and checks that every message article is a React element, that a new message keeps the inline frame loaded, that a new message enters, that a message that only gets its id does not enter again, the sequence of finding 15, that the first message of an empty conversation enters, that an entered message keeps no inline opacity or transform, that with reduced motion a new message starts no animation, that a leaving pin is inert, the pinned globals and the jump under a bordered positioned list.
  • test/shadcn-settings.test.js checks that a popup opens from transparent, that it stays mounted for its exit, the one tab mark that slides, and both with reduced motion. test/shadcn-panels.test.js checks the entry, the inert exit and the closed gap of the notification cards, and the thumb.

What does not use Motion

Each of these is a decision with a reason, not a pending step:

  • The approval dialogs and the change review card. Their buttons must not move, and the review button arms only when the card holds one place, so a moving entry would work against the protection.
  • The lock screen, recovery and the wallpaper page. They keep their own runtimes with no Motion (rule 7).
  • The bottom bar tabs. fitWorkspaceTabs measures every child of the list and updateWorkspaceTabIndicator reads rectangles, so a transform or a tab in its exit gives them wrong values (finding 5). The active tab already has its own animated indicator.
  • The cards of the workspace overview. The compositor draws a live plane behind each slot that the host reports, and a transform would separate them.
  • The composer itself and the other surfaces whose visibility host.js sets through hidden: an exit needs React to own that state, and host.js needs the IDs. Its tooltips and the model picker are the shared popups above.
  • The volume meter, hover, focus and color changes, where CSS is enough (rule 1).

Accepted

  • Notification cards take presses while they move: an entering card from its first frame, and in the history while the others close the gap. A local application can cause these shifts by posting or replacing a notification, and a press can land on another card. /action only emits ActionInvoked and closes that card, and the sender already runs as the user. New cards pushing older ones down predates Motion.
  • A popup that is opaque at rest crosses the alpha mask threshold of the chat window while it fades, about 100 ms on each side, so those frames can show a glass plate (finding 9). The ramp of rule 5 is the mitigation, and the Popover and the Tooltip faded with CSS before; the Select is new here.
  • The tab mark has no radius correction. The tabs of the settings have the same size, so the mark only translates. A horizontal list with tabs of different widths would stretch its corners during the slide.
  • An overlay with a copy of shared-runtime.js from before 2026-11-06 builds a shadcn-host.js with no Motion, and the base ui/app.js stops at load. host.js then shows its error about the trusted interface. The trial of the overlay does not catch it, because host.js reports the mount without the conversation (openspec/specs/immutable-base/spec.md); the way out is the safe mode.
  • On a compositor without alphaGlass the glass region of a new message can be up to 16 px off until the next scroll or mutation: the host measures the regions on mutations and not at the end of a transform. This is the fallback path only.
  • The fade of 120 ms makes an inline frame translucent for that time. Generated HTML can neither start nor time it.
  • Limits of the entry rule (review round 2): a local:<index> key that is still present hides the entry of a different message with no id that lands on that index; a shown message that disappears in the same commit can cancel the entry of a new message with the same content; a re-key remounts the article, so an entry still in progress is cut, which needs the end of the turn within about 450 ms of the send.
  • The pinned window names are non-writable, so a future Motion path that assigned one in strict code would throw. Today only the optimized appear path writes them, and nothing here uses it.
  • A leaving pin can still post a draft to the composer during its exit, as a pinned or inline surface always can.
  • The entry reads the resting look at mount: a resting transform with a percentage is resolved to pixels then, and a profile @keyframes or transition on .chat-message would be read mid-state (the profile owns the resting look through plain rules). The entry was checked only with a resting translation, not a rotation or scale.

Record of the spike (2026-11-05)

The spike ran on the branch claude/motion-spike in two steps. The first version kept the hand-made message articles and animated them with the imperative animate of motion/mini; the second let React own the articles. Until then ui-src/app.jsx created each article by hand, filled it through a portal and ordered the container with moveBefore in synchronizeOrder, which is gone. The dependency adds framer-motion, motion-dom, motion-utils and tslib to the lockfile.

Findings

  1. CSP of the chat document (style-src 'self' 'nonce-...'): no violation. Motion writes styles through the CSSOM and WAAPI, which the policy does not cover. The only style element comes from popLayout; it takes the nonce from MotionConfig nonce.
  2. CSP of the protected panel pages and the lock page (style-src 'self', no nonce): m components, exits, layout animations and the WAAPI animate work. popLayout does not: its style element is blocked (style-src-elem), the leaving element stays in the flow, and the others move only after it is gone.
  3. ShadowRoot: AnimatePresence root={window.shell.root} puts the popLayout style inside the ShadowRoot, and it applies there. Without root it would go to document.head and match nothing in the ShadowRoot.
  4. Reduced motion: MotionConfig reducedMotion is "never" by default, so every root must set "user". Then transform and layout animations stop and opacity still fades. The imperative animate knows nothing of the setting, so the code that uses it checks the media query itself (the first version, and the messages since review round 1).
  5. Rectangles include a running transform. The marker click of the message rail computed its scroll target with getBoundingClientRect, and missed by the entry offset of a message that was still animating (the browser harness failed on it).
  6. Inline styles. An m component keeps the values that it animated as an inline style and writes them again on every render, so clearing them when the animation completes does not last: a message that entered kept opacity: 1; transform: none until it unmounted, and a profile rule on those two properties applied to the history and not to it, unless the rule has !important, which beats a non-important inline style. A message of the history had no animation props and no inline style. Review round 1 moved the messages to the animate of motion/mini, which leaves no inline style (rule 2).
  7. The exit is a contract change: an unpinned surface stays in the DOM for the time of its exit.
  8. Profile CSS. style.css belongs to the profile (replace_ui), and the agent can restyle a CSS animation there. A Motion animation lives in the trusted JavaScript, so the profile cannot change its timing (a rule with !important can still override the animated properties), and an old profile style.css keeps its own animations beside it (the column still has its CSS slide pinned-column-in).
  9. Glass (nested, alpha mask on). The glass follows a transform: the blur moves with the bubble. An opacity fade does not blend the glass: below the mask threshold the bubble has no material at all (only faint text), at the threshold one captured frame shows a gray plate with smeared text, and above it the glass is there at once, lighter than at rest. This is the alpha mask (openspec/specs/glass-alpha-mask/spec.md, alpha of 0.18 or more), not Motion: a CSS fade would do the same.
  10. Size. ui/app.js goes from 205533 to 349223 bytes (limit 512000). Measured with esbuild, minified, React external: m + LazyMotion + domAnimation + AnimatePresence + MotionConfig 88.8 KB (32.4 KB gzip); with domMax (layout, drag) 137.1 KB (46.9 KB); the hybrid animate alone 68.3 KB (25.1 KB); motion/mini animate + spring 12.4 KB (5.1 KB). At adoption ui/app.js is 349424 bytes; after review round 1, with animate of motion/mini, spring and useIsPresent back in the closure, 354894 bytes; after review round 2, 356208 bytes.
  11. Base UI documents Motion as its JavaScript animation path (render with a motion element, keepMounted, AnimatePresence), and detects the end of a closing animation only when it animates opacity. The spike did not exercise a Base UI popup.
  12. Keys that change in place. The core stores a sent message with no id (key local:<index>) and replaces the whole list at the end of the turn (mergeHistory), where the message gets its id. Its article remounts, so an entry that follows the mount alone would play twice. The entry follows the position instead. The nested run cannot send and the first harness states all had ids, so the first version of the spike had this bug.
  13. Reorders are real: mergeHistory places an inline component at its tool anchor, which can differ from where it sat before. Without keepFramesOnMove the harness check "reorder preserves inline state" fails with React-owned articles.
  14. Offset parents. The first fix of finding 5 read article.offsetTop - scroller.offsetTop, which holds only while neither the scroller nor #messages is positioned. A probe with a profile-like #messages { position: relative; margin-top: 300px } landed the marker jump 300 px low; jumpToMessage now adds the offsets up to the scroller or to the offset parent that it shares with the scroller, and the same probe lands at 24 px (found at adoption).
  15. Position is not identity either (review round 1). publishSurface (core/surfaces.js) pushes a surface message during the turn, so before idle the list ends with the sent message (key local:<index>) and the surface. At session.idle mergeHistory returns the sent message with its id, the reply and then the surface: the reply sat below the count of the last commit and never entered, and the shown surface was the one flagged. The entry now follows the key, with a re-key found by content.

Proof and limits

  • Browser, headless Chrome 157 with scripts/test-ui-browser.js and its nonce-only CSP, on the second version: 63 PASS and 0 FAIL (main had 59; the four new checks are listed above); no securitypolicyviolation in the host document. The probes read the entry, the popLayout rule inside the ShadowRoot (none in document.head), the layout move and the conversation switch with no animation. With the call of keepFramesOnMove removed, the reorder check fails.
  • At adoption the harness has one more check, "marker click lands on its message under a positioned message list" (finding 14), which fails on the build of the spike: 64 PASS and 0 FAIL. A scratch probe in the same browser also lands the jump 24 px below the scroller top with a positioned main (plus its border).
  • Reduced motion, same browser, on the second version at adoption: 63 PASS and 0 FAIL (62 before the check of finding 14); the missing check is "marker navigation starts smoothly", which the harness runs only without reduced motion. The probes show an entry with transform: none and only the opacity ramp, a pin exit that jumps to its scale and fades, and no layout move of the remaining pin.
  • Strict CSP: a scratch page with the header of protectedPageCsp, same browser. It is not a real panel page.
  • Nested, first version (runs 336794b8, 767ae671, c5c3688a; one output, software renderer, no provider): the glass frames of finding 9 came from a QA-only variant, never committed, that animates the history on mount with a 90 s linear ramp.
  • Nested, second version at adoption (run 0ceccb8c; one output, software renderer, synthetic profile, no provider, alphaGlassEnabled and chatAlphaGlass true): the history of the React-owned articles renders as glass bubbles after the box expands. The run cannot send, so no new message enters there, and the 120 ms ramp was not seen nested.
  • Review round 1, same browser: 77 PASS and 0 FAIL, and 70 PASS and 0 FAIL with reduced motion. On the build of e572e44 these new checks failed: the pinned globals, the bordered list, the inline style after an entry, the reply before a shown surface and the inert pin, and with reduced motion also "starts no animation" and the shown surface, which Motion faded again. The other new checks held there too. A scratch probe read the message entry as an opacity animation of 120 ms linear and a transform of 550 ms on the linear() easing of the spring, with delays of 0, 40 and 80 ms for three messages and no style attribute after; the pin opacity as 120 ms linear on entry and exit.
  • Review round 2, same browser: 82 PASS and 0 FAIL, and 72 PASS and 0 FAIL with reduced motion. On the build of ff26e57 two new checks failed: a re-keyed message whose text changed entered again, and under a profile rule .chat-message { opacity: 0.5; transform: translateX(3px) } an entering message showed opacity 1 after its opacity ramp.
  • Components, 2026-11-06, same browser: ui/app.js goes from 356249 to 210688 bytes, shadcn-host.js from 770756 to 918233 and shadcn-panel.js from 318679 to 461361. The chat document carries about 2 KB more in total, because Motion moved instead of doubling, and each panel page parses about 143 KB more.
  • Components, nested on 2026-11-06 (run 3a41ef98; one output, synthetic profile, no provider, Electron host): the mark of the active tab, the thumb in both states, the first open of a Select, its close and the notification history panel render correctly at rest. A second run with --session-bus (2cf8722f) posted real notifications through the private bus: three popup cards show at full opacity in a window that was hidden before them, a press on the close button of one takes it out, and the history shows them. A capture does not show the motion, so the entry and the exit have only the browser proof. In both these runs and a run of the commit before this change the popup cards are light on a dark desktop, so that look does not come from this work.
  • Not proven: Electron 45 (the browser proof is Chrome), the live session, a real GPU, the region path of a compositor without alphaGlass, the pinned column in a nested run, and the feel of the springs, which needs the user.

Binding contract (from AGENTS.md)

This section holds, word for word, the rule that AGENTS.md kept for this feature until 2026-11-10, when AGENTS.md was reduced to the short invariants (openspec/changes/audit-2026-11-10/design.md, F10). It binds exactly as AGENTS.md does; AGENTS.md keeps the short invariant and points here. Change both in the same commit.

On 2026-11-05 the user adopted the animation library Motion (motion, https://motion.dev) for the system UI in restricted use ("Adotar e publicar", after "Adotar o Motion na UI do sistema, em uso restrito?"), and said that every component is React ("Todo componente que nós fazemos deve estar usando react"). CSS stays the default (Base UI data attributes and the motion tokens of host/theme.css; no part uses tw-animate-css today); Motion is only for exits, layout and reorder animation, and springs, through m under LazyMotion ... strict and MotionConfig reducedMotion="user", or the animate of motion/mini in an effect where the profile CSS must own the resting look (the messages). popLayout works only in the chat document; the pages without a style nonce use sync or wait. On 2026-11-06 the user asked for Motion in the components ("pode adicionar "motion" aos componentes agora"): the popups, the switch and the tabs of the shared parts and the notification cards use it, with one copy per document in the runtimes of the chat and the panels. The approval dialogs, the change review card, the lock screen, recovery, the wallpaper, the bottom bar tabs and the overview cards stay out on purpose. See openspec/specs/motion/spec.md.