feat(hero): try-it block with the walletless pull command - #248
Open
alpergundogdu wants to merge 2 commits into
Open
alpergundogdu wants to merge 2 commits into
alpergundogdu wants to merge 2 commits into
Conversation
Add a block at the foot of the hero that turns the seeded catalogue (public/models.json) into one copy-paste command per model: - a model dropdown with size, license and source; - the install-and-pull line by BLAKE3 hash, with a macOS/Linux | Windows switch that defaults to the visitor's OS (curl | sh, or irm | iex in PowerShell); - a copy button that falls back to selecting the command when the clipboard is blocked; - an #try anchor for launch copy to link to. Copy lives in lib/copy.ts and the command in lib/models.ts, and llms-full.txt mirrors the block with every model's command. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
The llms-full.txt Windows example command currently omits the required b3: prefix, making the mirrored copy-paste instruction incorrect.
Get a fresh assessment by requesting another Copilot review.
Review effort: Lite
Findings: 1
Open (1)
What changed in this PR
Adds a new “Try it: pull a real model” block at the bottom of the homepage hero, backed by a seeded model catalogue and shared command-building helpers, and mirrors the content into the llms-full.txt static export.
Changes:
- Introduces
lib/models.ts(catalogue + OS detection + command builder + size formatting) withvitestcoverage. - Adds a new client component
TryItrendered fromHero, including model selection, OS toggle, and copy-to-clipboard fallback behavior. - Extends
llms-full.txtgeneration to include the try-it copy and per-model commands, and adds installer URLs tolib/links.ts.
| File | Description |
|---|---|
| lib/models.ts | Adds model catalogue types/data export, platform detection, command builder, and size formatting. |
| lib/models.test.ts | Adds tests validating catalogue invariants and command/platform helpers. |
| lib/links.ts | Adds installer URLs used by the generated pull commands. |
| lib/copy.ts | Adds try-it headline/lead/notes copy for homepage + llms mirroring. |
| components/site/TryIt.tsx | Implements the hero “try it” UI (model dropdown, OS switch, copy behavior). |
| components/site/Hero.tsx | Renders the new TryIt block under the existing hero terminal. |
| app/llms-full.txt/route.ts | Mirrors the try-it block content and model commands into llms-full.txt. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Deploying website with
|
| Latest commit: |
25f765a
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://979fde8b.website-70y.pages.dev |
| Branch Preview URL: | https://feat-try-it-out.website-70y.pages.dev |
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Summary
A "try it: pull a real model." block at the foot of the hero, on the same paper background, below the illustrative terminal (which stays). It turns the seeded catalogue in
public/models.jsoninto one copy-paste command per model.aria-hidden, with the install-and-pull line by BLAKE3 hash:curl -fsSL https://up.decdn.org/decdn.sh | sh -s -- pull b3:<hash>irm https://up.decdn.org/decdn.ps1 | iex; decdn-sponsored pull b3:<hash>useSyncExternalStore, so the static HTML always renders the POSIX line and there's no hydration mismatch.#tryanchor for launch posts and the homepage banner to link to.lib/copy.ts, the command builder inlib/models.ts(with tests), andllms-full.txtmirrors the block with every model's command.The installers are served by sponsord: decdn/sponsord#6 (the
decdn-sponsoredCLI anddecdn.sh), plus the Windowsdecdn.ps1in a follow-up. The/dl/binary hosting behind them isn't live yet, so the commands work end to end once it is.Test plan
pnpm format:check,pnpm lint,pnpm typecheckpnpm test: 484 passed, includinglib/models.test.ts(catalogue hashes, both commands, OS detection)pnpm build, includingcheck:outandcheck:og-imagemodels.json), the OS switch swaps the command and prompt, and copy falls back to selecting the command🤖 Generated with Claude Code