Skip to content

Demo guests keep a template drive, with one setup bar and the Atomic Place logo - #1782

Closed
joepio wants to merge 12 commits into
developfrom
claude/project-thread-u8vgm0
Closed

joepio wants to merge 12 commits into
developfrom
claude/project-thread-u8vgm0

Conversation

@joepio

@joepio joepio commented Sep 25, 2026

Copy link
Copy Markdown
Member

Before: someone trying the demo without an account couldn't really move on from it. The demo bar went away, leaving the demo took them to a gallery that asked them to sign in, and a page deleted along with the demo showed a bare error. Each setup step put its title and buttons somewhere different: the demo bar split them left and right, the gallery put Close next to the logo, and the naming step had "Back to templates" in the middle of the page. Buttons inside dialogs had a shadow that spilled out, and the welcome screen wasn't centered.

After: a demo guest can pick a template and create a drive on this device without an account. The demo bar stays up with "Leave demo" (back to the start screen) and "Choose a template". A deleted page shows "This page no longer exists" with a way to your drive or the templates. Every setup step uses one top bar: the step's title on the left, its actions on the right, Create drive on the naming step, and the Atomic Place logo linking to atomic.place. Buttons in dialogs keep their shadow inside the dialog, and the welcome screen is centered.

How: this merges onboarding-demo-bar onto current develop, which already has the identity handover. Where they conflicted:

  • prepareTemplateDrive: keeps develop's guest path (registerLocalOnlyDrive(home), no prepareDriveSharing). Its unit test follows develop.
  • cleanupDemoDrive in startDemo.ts: both sides already kept the guest's agent, so there is one exclusion with one merged comment.
  • demoSession.ts: keeps develop's readInteractiveDemo and adds the branch's demoForDrive, which is built on it.
  • DemoRoute.tsx: develop imported readDemoDrive from DemoExitButton, but the branch removed it. It now uses demoForDrive.
  • DemoExitButton.tsx: the finally inside the component is gone, since the React Compiler rule doesn't allow it. The reset now comes after the try/catch.
  • template-recovery.spec.ts: keeps develop's /api/me 204 mock, the not.toHaveURL(/\/app\/demo/) wait and the optional Wuchale diagnostics expectation. Then it clicks the demo bar's "Choose a template" and checks the naming step through the Setup bar's "Name your drive".
  • Locales: develop's .po files, regenerated by the dev server until they stopped changing.

Related Issues

None.

Checklist

  • Add changelog entry linking to issue, describe API changes
  • Add or update tests if needed
  • Update docs if needed

Generated by Claude Code

A visitor who pressed Try the app, left the demo and created a drive from a
template got "Sign in to check Cloud Server hosting." prepareTemplateDrive
asked the control plane for enrollments, which needs a session a demo guest
never has. A guest has no account, so nothing can be hosted for it: treat its
home as unenrolled. A real account without a session still has to sign in.

Fixes ATOMIC-BROWSER-1F
The bar that lets a visitor out of the demo sometimes did not show. It
read the template-preview record first and only fell back to the demo
manifest when there was none, so a stale preview record (a closed tab,
an abandoned "Use this template") hid the demo's bar for good. Each
record is now matched against the current drive on its own
(demoForDrive), and the bar shows whenever the current drive is a demo
drive, on the template gallery too.

The interactive demo is no longer listed as a template. Its next step
is choosing one: the bar offers "Leave demo" and "Choose a template",
and the gallery offers "Back to the demo" (or "Back to the preview").
A template preview says "Back to templates", so no label names a page
the user has not been on. The demo drive is cleaned up once the user
creates a drive of their own.

Also fixes a type error in prepareTemplateDrive, where agent.subject
may be undefined.
…ends

Leaving the demo deleted every resource under the demo drive, and a
guest's own profile is a row in the demo's Team table. The guest kept
using that agent, so the next write, such as creating a drive from a
template, failed with "Resource has no store". The cleanup now skips
the current agent.

"Leave demo" took a guest to the template gallery, which is what
"Choose a template" is for. A guest now returns to the start screen; a
signed-in user still goes to their own drive.

Going back in history after leaving a demo or a template preview opened
a deleted page with a raw "was destroyed" error and Retry / Use proxy
buttons that cannot help. A deleted resource now says so and offers the
current drive or the template gallery.
Buttons during setup sat in different places: the demo bar had them left
and right, the gallery put Close next to the logo, and the naming step
had "Back to templates" in the middle of the page above its heading.
SetupBar is now the one bar for all of them: the step's title on the
left, its actions on the right, secondary before primary.

- Demo: "Demo workspace" with Leave demo / Choose a template.
- Template preview: "Preview: <name>" with Back to templates / Use this
  template.
- Gallery: "Choose a template" with Back to the demo, Back to the
  preview, or Close.
- Naming step: "Name your drive" with a single back, to the preview when
  one is open and to the templates otherwise.

The new-drive dialog has no bar and keeps its inline back and heading.
The naming step was the one screen whose main action still sat in the
page, under the form. It now sits in the top bar next to Back, like
Use this template and Choose a template on the other steps. The button
submits the form through its form attribute, so Enter in the name field
still works. The New drive dialog keeps its inline button.
The gallery showed the wordmark above its content, under a bar that
already names the step. The logo now leads the setup bar on every step,
separated from the step's title, and shrinks on a phone so both buttons
still fit.
The welcome screen (Create account, Sign in, Try the live demo) sat at
the top of an otherwise empty page. It is short and has nothing below
it, so it now sits in the middle of the screen. Auto margins keep it
scrollable on a screen too small to hold it. The forms after it still
start at the top.
A hovered or focused button used the card shadow, whose last layer has
an 80px blur 53px below it. Inside a scroll area, such as the New drive
dialog's content, that halo was cut off in a hard line under Create a
blank drive and beside the dialog's close button. Buttons now use a
compact version of the same shadow that stays within about 1rem.
The wordmark in the setup bar, on the welcome screen, on the invite page
and on About is now a link to the website. It opens outside the app (a
new tab, or the system browser in the desktop and Android apps), so it
never replaces a half-finished onboarding step. The link is named
"Atomic Place website", also where the logo itself is decorative.
Logo takes link={false} for a place that must not link.
The homepage branch centred the welcome screen the same way in 0ae1052.
Using its exact code here means whichever branch merges second does not
conflict on it.
Demo guests keep a template drive, the demo bar stays up with Leave demo,
deleted pages get a "no longer exists" screen, and setup has one bar with
the title, actions, Create drive and the Atomic Place logo.

Conflicts with the identity handover already on develop:
- prepareTemplateDrive: keep develop's registerLocalOnlyDrive for guests
  (no prepareDriveSharing); its test follows develop.
- startDemo cleanupDemoDrive: one comment for keeping the guest's agent.
- demoSession: keep readInteractiveDemo and add demoForDrive.
- DemoRoute: readDemoDrive is gone, so ask demoForDrive instead.
- DemoExitButton: no finally inside the component (React Compiler).
- template-recovery e2e: develop's /api/me 204, URL wait and diagnostics,
  then the demo bar's Choose a template and the Setup bar's naming title.
- locales: develop's .po files, regenerated by the dev server.

joepio commented Sep 25, 2026

Copy link
Copy Markdown
Member Author

This failed in batch run 4643 (#1844) on every retry, so I took it out of the batch. The spec files and template code were identical to this branch, so the failure is this PR's own, not a merge interaction.

  • drive-template-onboarding.spec.ts:5 (both variants) times out at line 47 waiting for getByRole('region', { name: 'Template preview' }). This PR removes that region and uses the shared Setup bar instead.
  • drive-template-onboarding.spec.ts:204 can't find the Back to the demo button in region "Setup" (line 242).
  • template-recovery.spec.ts:9 and :62 wait for getByText('Name your drive') in region "Setup". The page snapshot shows the Setup region with only the logo link, "Back to templates" and "Create drive", and no title text. SetupBar's Title is hidden below 600px, which may be why.

Once the specs match the new bar, it can go into the next batch.


Generated by Claude Code

The naming step's title ("Name your drive") and the gallery's "Back to
the demo" / "Back to the preview" were never extracted, so a production
build rendered them blank: the bar had no title and the way back to the
demo was an unnamed button. Extracted with wuchale (stable on a second
run); "Welcome", "Board" and "Team chat" are no longer used and become
obsolete entries.

The template adoption spec still looked for the "Template preview"
region and the inline "Give your space a name" heading, both replaced by
the Setup bar. It now uses the Setup region, and on a phone, where the
bar hides the step title, checks the naming step by its Create button.
joepio added a commit that referenced this pull request Sep 25, 2026
…, #1779, #1780, #1784, #1782) (#1852)

Combined batch, green on Mancave in run on 01d080f (CI and Downstream).

Includes #1772, #1777, #1779, #1780, #1784 and #1782, and restores six
catalog strings from #1820 and #1787 that earlier batches dropped.

joepio commented Sep 25, 2026

Copy link
Copy Markdown
Member Author

Landed on develop in 4a3a0bf via the combined batch #1852 (green on Mancave). Closing.


Generated by Claude Code

@joepio joepio closed this Sep 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant