Skip to content

docs(agents): add hover-to-copy button for the agent prompt#177

Merged
moskovich merged 1 commit into
mainfrom
docs/agents-copy-button
Jun 21, 2026
Merged

docs(agents): add hover-to-copy button for the agent prompt#177
moskovich merged 1 commit into
mainfrom
docs/agents-copy-button

Conversation

@moskovich

Copy link
Copy Markdown
Contributor

What

The agent-quickstart prompt ("Read https://docs.feralfile.com/agents/ and set me up to play artwork on my Art Computer.") now has a hover-to-copy button.

How

  • Enable Material for MkDocs' content.code.copy feature.
  • Render the prompt as a code block tagged .copy-prompt instead of a blockquote, so Material injects a copy button on hover.
  • Add docs/stylesheets/extra.css to make that one block wrap like a sentence instead of scrolling horizontally.

Notes

  • Enabling content.code.copy adds a hover copy button to all code blocks site-wide (including the Setup commands) — standard Material behavior and a useful bonus, but a sitewide change.
  • Verified with mkdocs build --strict (passes) and a local mkdocs serve.

Enable Material's content.code.copy feature and render the
"set me up to play artwork" prompt as a code block so it gets a
hover copy button. Scope a .copy-prompt class with extra.css so the
block wraps like a sentence instead of scrolling horizontally.
@cloudflare-workers-and-pages

Copy link
Copy Markdown

Deploying docs with  Cloudflare Pages  Cloudflare Pages

Latest commit: dc63c00
Status: ✅  Deploy successful!
Preview URL: https://9acda171.docs-dhu.pages.dev
Branch Preview URL: https://docs-agents-copy-button.docs-dhu.pages.dev

View logs

@moskovich moskovich merged commit f38956e into main Jun 21, 2026
2 checks passed
@moskovich moskovich deleted the docs/agents-copy-button branch June 21, 2026 03:19
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