mirror of
https://github.com/supabase/supabase.git
synced 2026-07-25 08:52:43 -04:00
23 lines
636 B
TypeScript
23 lines
636 B
TypeScript
type HandlerContext = {
|
|
children: string
|
|
}
|
|
|
|
const preserveChildren = ({ children }: HandlerContext): string => children
|
|
|
|
const PromptTitle = ({ children }: HandlerContext): string => {
|
|
const title = children.trim()
|
|
return title ? `**${title}**` : ''
|
|
}
|
|
|
|
// PromptCopy is clipboard-only metadata. PromptContent is the visible source of
|
|
// truth and is preserved below, so including both would duplicate the prompt.
|
|
const PromptCopy = (_context: HandlerContext): string => ''
|
|
|
|
export const PromptPanel = {
|
|
PromptPanel: preserveChildren,
|
|
Prompt: preserveChildren,
|
|
PromptTitle,
|
|
PromptCopy,
|
|
PromptContent: preserveChildren,
|
|
}
|