Repository navigation
Add agent skills banner to utilities #170
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
0f2e574
feat: add agent skills banner to utilities
baransu 778eb17
feat: redesign skills banner and update copy
baransu 03baf83
feat: light theme and new copy for skills banner
baransu 639398b
refactor: one promo block on every tool page
baransu f298e93
feat: skills promo as third card in the utilities grid
baransu d711fef
refactor: drop skills promo from the utilities index
baransu b7c9f65
fix: align skills chip with Jam logo, show Copied next to copy icon
baransu 7d266fc
fix: fine tune icon and copy
peckz File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,79 @@ | ||
| import { GitHubLogoIcon } from "@radix-ui/react-icons"; | ||
| import { Check, Copy, Terminal } from "lucide-react"; | ||
| import { cn } from "@/lib/utils"; | ||
| import { useCopyToClipboard } from "./hooks/useCopyToClipboard"; | ||
| import { SKILLS_URL } from "./utils/jam-cta"; | ||
|
|
||
| const INSTALL_COMMAND = "npx skills add jamdotdev/skills"; | ||
|
|
||
| interface SkillsBannerProps { | ||
| className?: string; | ||
| } | ||
|
|
||
| export default function SkillsBanner({ className }: SkillsBannerProps) { | ||
| const { buttonText, handleCopy } = useCopyToClipboard(); | ||
| const copied = buttonText !== "Copy"; | ||
|
|
||
| const githubLink = ( | ||
| <a | ||
| href={SKILLS_URL} | ||
| target="_blank" | ||
| rel="noopener noreferrer" | ||
| className="inline-flex shrink-0 items-center gap-1.5 text-sm text-muted-foreground transition-colors hover:text-foreground" | ||
| > | ||
| <GitHubLogoIcon aria-hidden="true" /> | ||
| View on GitHub | ||
| </a> | ||
| ); | ||
|
|
||
| return ( | ||
| <div className={cn("rounded-xl border p-4 text-left sm:p-5", className)}> | ||
| <div className="flex items-center gap-2"> | ||
| <span className="inline-flex h-10 w-10 shrink-0 items-center justify-center rounded-lg text-foreground"> | ||
| <Terminal className="h-5 w-5" aria-hidden="true" /> | ||
| </span> | ||
| <p className="min-w-0 flex-1 font-medium leading-5"> | ||
| Teach your coding agent to show its work | ||
| </p> | ||
| <span className="hidden sm:inline-flex">{githubLink}</span> | ||
| </div> | ||
|
|
||
| <p className="mt-2 text-sm leading-5 text-muted-foreground sm:mt-1 sm:pl-12"> | ||
| Open-source Jam skills: record a demo, attach proof to the PR, mark up a | ||
| screenshot, fix a bug from a recording. | ||
| </p> | ||
|
|
||
| <button | ||
| type="button" | ||
| onClick={() => handleCopy(INSTALL_COMMAND)} | ||
| aria-label={copied ? "Copied" : "Copy install command"} | ||
| className="mt-4 flex w-full items-start gap-2 sm:items-center rounded-lg bg-muted py-1.5 pl-3 pr-1.5 font-mono text-sm transition-[background-color,transform] duration-150 ease-out hover:bg-border/60 active:scale-[0.98]" | ||
| > | ||
| <span | ||
| className="shrink-0 leading-5 text-muted-foreground" | ||
| aria-hidden="true" | ||
| > | ||
| $ | ||
| </span> | ||
| <code className="min-w-0 flex-1 break-words text-left leading-5 sm:truncate"> | ||
| {INSTALL_COMMAND} | ||
| </code> | ||
| <span | ||
| className="inline-flex shrink-0 items-center gap-1.5 rounded-md p-1.5 text-muted-foreground" | ||
| aria-hidden="true" | ||
| > | ||
| {copied ? ( | ||
| <> | ||
| <Check className="h-4 w-4 text-[#5BA832]" /> | ||
| <span className="font-sans text-xs leading-4">Copied</span> | ||
| </> | ||
| ) : ( | ||
| <Copy className="h-4 w-4" /> | ||
| )} | ||
| </span> | ||
| </button> | ||
|
|
||
| <div className="mt-3 sm:hidden">{githubLink}</div> | ||
| </div> | ||
| ); | ||
| } | ||
This file was deleted.
Oops, something went wrong.
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
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
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
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
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
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
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
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
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
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
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
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
Oops, something went wrong.
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.