Skip to content

feat(site): scroll long commands on one line, like Doorplate - #118

Merged
junjuny0227 merged 1 commit into
mainfrom
feat/site-scrolling-commands
Nov 6, 2026
Merged

junjuny0227 merged 1 commit into
mainfrom
feat/site-scrolling-commands

Conversation

@junjuny0227

Copy link
Copy Markdown
Owner

Summary

Port Doorplate #85 and #86 to the Repot site: long copyable commands stay on one line and scroll sideways instead of wrapping (no more paths split mid-word), each end that hides text fades out, and a thin overlay scrollbar shows while the pointer is over the box or it has focus.

Type

  • feat
  • fix
  • refactor / chore
  • docs
  • ci / build

Changes

  • sections/ScrollingCode.tsx: copied unchanged from Doorplate (scrollState pure function, data-hidden-start / data-hidden-end, draggable 4px thumb, ResizeObserver re-measure). CopyCommand renders the command through it.
  • site.css: Doorplate's command rules (white-space: pre, centered button, hidden native scrollbar, end fades, hover/focus scrollbar, no transitions under reduced motion) and .hero .downloads { width: 100% } so the hero column does not grow to a command's width.
  • Tests: Doorplate's two copy.test.tsx tests (scrollState cases, no fade/scrollbar in server markup); app.test.tsx patterns follow the new .command-text wrapper.

Checks

  • cargo fmt --check
  • cargo clippy --workspace --all-targets -- -D warnings
  • cargo test --workspace
  • pnpm --filter @repot/desktop typecheck / test / build
  • Ran the real flow if behavior changed (--example scan / --example export, or tauri dev)
  • Not checked locally, CI only (say which, e.g. Windows/Linux providers, shellcheck)

Site typecheck / test (38) / build, pnpm exec biome ci .. Headless Chrome on the build with mac, Windows and Linux user agents at 1280 and 390 px: every one-line box is 44px (the two-line Scoop command 64px), no page overflow, every overflowing command reports a hidden end and has a scrollbar, fitting ones have neither. On the xattr box with real mouse events: rest (right end fades, bar hidden) → hover (bar shown) → drag the thumb (scrolled to the end, left end fades, right fade gone) → pointer leaves (bar hidden). Reduced motion: no transition.

Spec and generated files

  • Spec updated in this PR if a product decision changed, or no decision changed
  • Generated files regenerated from their source, not edited by hand (scan.json, snapshots/, icons/) (not touched)
  • Snapshot diffs read and intended (not touched)

Boundaries

  • repot-core does not depend on Tauri and does no network calls (not touched)
  • Commands and file reads go through Env; tests use FakeEnv and fixtures, not real tools (not touched)
  • No new crate or npm dependency, or the plan/spec was updated first
  • The app still only reads the device; it writes only to the export folder (not touched)

@github-actions github-actions Bot added the enhancement New feature or request label Nov 6, 2026
@junjuny0227
junjuny0227 merged commit 0945e45 into main Nov 6, 2026
11 checks passed
@junjuny0227
junjuny0227 deleted the feat/site-scrolling-commands branch November 6, 2026 03:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant