Skip to content

The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.

636 B
Raw Blame
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,
}