Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion snippets/copy-prompt-button.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@ const DEFAULT_PROMPT = `# Setup Kernel
- Tell the user they can use the live view immediately.
- If browser creation fails, stop and ask the user for help.`;

export const CopyPromptButton = ({ prompt = DEFAULT_PROMPT, label = 'copy prompt' } = {}) => {
export const CopyPromptButton = (props) => {
const { prompt = DEFAULT_PROMPT, label = 'copy prompt' } = props || {};
const [copied, setCopied] = useState(false);

const handleCopy = useCallback(async () => {
Expand Down
Loading