// Motun.jsx — 墨吞:把这则笔记变成作品(文生图 / 谱曲 / 动画·视频 / 成稿 PPT / 文本转 HTML) // 让创意,从文字记录,到数字化生成。(演示流程,未接真实 API) const { useState: useStateM, createElement: hM } = React; // —— 精细 AI 图标(stroke 1.5 · currentColor · 24 画板)—— // function gicon(children) { return (props) => { const { size = 18 } = props || {}; return hM('svg', { width: size, height: size, viewBox: '0 0 24 24', fill: 'none', stroke: 'currentColor', strokeWidth: 1.5, strokeLinecap: 'round', strokeLinejoin: 'round' }, children); }; } const GIcon = { // 文生图:相框 + 日出山峦 + 文字行 → 闪光 image: gicon([ hM('rect', { key: 0, x: 3.5, y: 5, width: 17, height: 14, rx: 2 }), hM('circle', { key: 1, cx: 8.5, cy: 9.5, r: 1.4 }), hM('path', { key: 2, d: 'M4 17l4.5-4.2 3 2.6 3.2-3.4L20 16' }), hM('path', { key: 3, d: 'M18 4.2l.6 1.6 1.6.6-1.6.6-.6 1.6-.6-1.6L15.8 6.4l1.6-.6.6-1.6Z', fill: 'currentColor', stroke: 'none' }), ]), // 谱曲:五线谱 + 音符 + 波形尾 music: gicon([ hM('path', { key: 0, d: 'M4 7h9M4 11h6M4 15h7', opacity: .55 }), hM('circle', { key: 1, cx: 15.5, cy: 16.5, r: 2.2 }), hM('path', { key: 2, d: 'M17.7 16.5V7.5l3.3-1.2v8' }), hM('circle', { key: 3, cx: 18.8, cy: 15.3, r: 2.2 }), ]), // 动画 / 视频:场记板 + 播放 video: gicon([ hM('path', { key: 0, d: 'M3.5 9.5h17V18a1.5 1.5 0 0 1-1.5 1.5H5A1.5 1.5 0 0 1 3.5 18V9.5Z' }), hM('path', { key: 1, d: 'M3.8 9.5 5 5.6l16-.0' , opacity: 0 }), hM('path', { key: 2, d: 'M4 9.5 4.8 6l15.4-1.4.5 3.4' }), hM('path', { key: 3, d: 'M8 6.2 9.4 9M12 5.6 13.4 8.4M16 5 17.4 7.8', opacity: .6 }), hM('path', { key: 4, d: 'M10.5 12.5v4l3.5-2-3.5-2Z', fill: 'currentColor', stroke: 'none' }), ]), // 成稿 PPT:幻灯片 + 标题 + 柱图 deck: gicon([ hM('rect', { key: 0, x: 3.5, y: 4.5, width: 17, height: 13, rx: 1.5 }), hM('path', { key: 1, d: 'M6.5 8h6', opacity: .7 }), hM('path', { key: 2, d: 'M7 14.5v-2.5M10 14.5v-4M13 14.5v-1.8' }), hM('path', { key: 3, d: 'M12 17.5V20M9 20h6' }), ]), // 文本转 HTML:浏览器窗 + 代码尖括号 html: gicon([ hM('rect', { key: 0, x: 3.5, y: 5, width: 17, height: 14, rx: 2 }), hM('path', { key: 1, d: 'M3.5 9h17', opacity: .7 }), hM('circle', { key: 2, cx: 6, cy: 7, r: .6, fill: 'currentColor', stroke: 'none' }), hM('circle', { key: 3, cx: 8, cy: 7, r: .6, fill: 'currentColor', stroke: 'none' }), hM('path', { key: 4, d: 'M10.5 12.5 8.5 14.5l2 2M13.5 12.5l2 2-2 2' }), ]), }; const MOTUN_TOOLS = [ { id: 'image', name: '文生图', ico: 'image', kind: 'image', label: '一幅插画' }, { id: 'music', name: '谱曲', ico: 'music', kind: 'audio', label: '环境配乐 · 0:30' }, { id: 'video', name: '动画 / 视频', ico: 'video', kind: 'video', label: '短片草稿' }, { id: 'deck', name: '成稿 PPT', ico: 'deck', kind: 'deck', label: '提案 · 5 页' }, { id: 'html', name: '文本转 HTML', ico: 'html', kind: 'html', label: '网页一页' }, ]; function ResultBody({ kind }) { if (kind === 'image') return
; if (kind === 'audio') return (