fix
This commit is contained in:
@@ -16,14 +16,27 @@
|
||||
placeholder="粘贴外部 AI 返回的完整 HTML 代码..."
|
||||
/>
|
||||
<div v-if="splitResult" class="split-result">
|
||||
<n-tag size="small" type="success">HTML · {{ splitResult.html.length }} 字符</n-tag>
|
||||
<n-tag size="small" type="info">CSS · {{ splitResult.css.length }} 字符</n-tag>
|
||||
<n-tag size="small" type="warning">JS · {{ splitResult.js.length }} 字符</n-tag>
|
||||
<n-tag size="small" type="success"
|
||||
>HTML · {{ splitResult.html.length }} 字符</n-tag
|
||||
>
|
||||
<n-tag size="small" type="info"
|
||||
>CSS · {{ splitResult.css.length }} 字符</n-tag
|
||||
>
|
||||
<n-tag size="small" type="warning"
|
||||
>JS · {{ splitResult.js.length }} 字符</n-tag
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
<div class="action-bar">
|
||||
<n-button :disabled="!rawCode.trim()" @click="applyPreview">应用预览</n-button>
|
||||
<n-button type="primary" :disabled="!splitResult" :loading="submitting" @click="submit">
|
||||
<n-button :disabled="!rawCode.trim()" @click="applyPreview"
|
||||
>应用预览</n-button
|
||||
>
|
||||
<n-button
|
||||
type="primary"
|
||||
:disabled="!splitResult"
|
||||
:loading="submitting"
|
||||
@click="submit"
|
||||
>
|
||||
提交
|
||||
</n-button>
|
||||
</div>
|
||||
|
||||
@@ -2,7 +2,9 @@
|
||||
<n-flex align="center" justify="space-between" class="title">
|
||||
<div>
|
||||
<n-text class="titleText">预览</n-text>
|
||||
<n-text v-if="!!submission.id" depth="3">({{ submission.view_count || 0 }})</n-text>
|
||||
<n-text v-if="!!submission.id" depth="3"
|
||||
>({{ submission.view_count || 0 }})</n-text
|
||||
>
|
||||
</div>
|
||||
<n-flex>
|
||||
<n-button quaternary @click="download" :disabled="!showDL">下载</n-button>
|
||||
|
||||
@@ -75,7 +75,14 @@
|
||||
transition: 'all 0.2s',
|
||||
}"
|
||||
>
|
||||
<div style="display: flex; justify-content: space-between; align-items: flex-start; gap: 8px">
|
||||
<div
|
||||
style="
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: flex-start;
|
||||
gap: 8px;
|
||||
"
|
||||
>
|
||||
<span>{{ round.question }}</span>
|
||||
<span
|
||||
v-if="round.prompt_level"
|
||||
@@ -86,7 +93,8 @@
|
||||
color: levelColors[round.prompt_level],
|
||||
marginTop: '2px',
|
||||
}"
|
||||
>L{{ round.prompt_level }}</span>
|
||||
>L{{ round.prompt_level }}</span
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -152,7 +160,13 @@ const rounds = computed(() => {
|
||||
break
|
||||
}
|
||||
}
|
||||
result.push({ question: msg.content, prompt_level: msg.prompt_level ?? null, html, css, js })
|
||||
result.push({
|
||||
question: msg.content,
|
||||
prompt_level: msg.prompt_level ?? null,
|
||||
html,
|
||||
css,
|
||||
js,
|
||||
})
|
||||
}
|
||||
return result
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user