import { CodeBlockRuntime } from '@rspress/core/theme'; import { ArrowRight } from 'lucide-react'; import { useI18n } from '../i18n'; import './TestFramework.css'; import './TestProject.css'; export function TestProject({ hideHeading = false, }: { hideHeading?: boolean }) { const t = useI18n(); const prepareDescription = t('projectNodeDescription'); const cards = [ { file: 'nodes/order.ts', lang: 'typescript', code: `defineNode({ name: 'order.prepare', description: ${JSON.stringify(prepareDescription)}, inputSchema: z.strictObject({ status: z.literal('paid'), }), async execute({ input }) { await orders.create(input); }, });`, }, { file: 'midscene-node-spec.md', lang: 'markdown', code: `### order.prepare ${prepareDescription} - status: "paid"`, }, { file: 'case.yaml', lang: 'yaml', code: `steps: - order.prepare: status: paid`, }, ]; return (
{!hideHeading && (
{t('projectEyebrow')}

{t('projectHeading')}

{t('projectDesc')}

)}
    {cards.map((card, index) => (
  1. {index > 0 && (
  2. ))}
); }