This commit is contained in:
@@ -355,7 +355,7 @@ function autoRun() {
|
|||||||
:next-line-text="nextLineText"
|
:next-line-text="nextLineText"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<!-- 中:调试控制按钮 -->
|
<!-- 调试控制按钮 -->
|
||||||
<n-flex align="center" justify="center" style="margin-top: 20px">
|
<n-flex align="center" justify="center" style="margin-top: 20px">
|
||||||
<!-- 步骤控制 -->
|
<!-- 步骤控制 -->
|
||||||
<n-tooltip>
|
<n-tooltip>
|
||||||
@@ -423,7 +423,7 @@ function autoRun() {
|
|||||||
</n-tooltip>
|
</n-tooltip>
|
||||||
</n-flex>
|
</n-flex>
|
||||||
|
|
||||||
<!-- 下:调试进度条 -->
|
<!-- 调试进度条 -->
|
||||||
<n-flex v-if="debugData && debugData.trace" vertical>
|
<n-flex v-if="debugData && debugData.trace" vertical>
|
||||||
<n-slider
|
<n-slider
|
||||||
v-model:value="currentStep"
|
v-model:value="currentStep"
|
||||||
@@ -433,105 +433,74 @@ function autoRun() {
|
|||||||
:tooltip="false"
|
:tooltip="false"
|
||||||
/>
|
/>
|
||||||
<!-- 步骤信息 -->
|
<!-- 步骤信息 -->
|
||||||
<n-text
|
<n-text class="step-info">
|
||||||
depth="3"
|
|
||||||
style="text-align: center; font-size: 12px; white-space: nowrap"
|
|
||||||
>
|
|
||||||
步骤: {{ currentStep + 1 }} / {{ debugData.trace.length }}
|
步骤: {{ currentStep + 1 }} / {{ debugData.trace.length }}
|
||||||
</n-text>
|
</n-text>
|
||||||
</n-flex>
|
</n-flex>
|
||||||
</n-flex>
|
</n-flex>
|
||||||
|
|
||||||
<!-- 右侧:调试信息面板 -->
|
<!-- 右侧:调试信息面板 -->
|
||||||
<n-card :bordered="true" size="small" style="width: 350px">
|
<n-card :bordered="true" title="调试信息" size="small" style="width: 350px">
|
||||||
<template #header>
|
|
||||||
<n-flex justify="space-between" align="center">
|
|
||||||
<n-flex align="center">
|
|
||||||
<n-icon>
|
|
||||||
<Icon icon="mdi:bug" :width="16" :height="16" />
|
|
||||||
</n-icon>
|
|
||||||
<n-text strong>调试信息</n-text>
|
|
||||||
</n-flex>
|
|
||||||
</n-flex>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<!-- 变量部分 -->
|
<!-- 变量部分 -->
|
||||||
<n-collapse :default-expanded-names="['variables']">
|
<n-flex vertical style="margin-bottom: 16px">
|
||||||
<n-collapse-item name="variables">
|
<n-text strong style="margin-bottom: 8px">变量</n-text>
|
||||||
<template #header>
|
<n-scrollbar style="max-height: 260px">
|
||||||
<n-flex align="center">
|
<n-flex
|
||||||
<n-icon>
|
v-if="formattedVariables.length === 0"
|
||||||
<Icon icon="mdi:variable" :width="14" :height="14" />
|
vertical
|
||||||
</n-icon>
|
style="padding: 20px; text-align: center"
|
||||||
<n-text>变量</n-text>
|
>
|
||||||
</n-flex>
|
<n-text type="info">暂无变量</n-text>
|
||||||
</template>
|
</n-flex>
|
||||||
<n-scrollbar style="max-height: 260px">
|
<n-flex v-else vertical>
|
||||||
<n-space
|
<n-card
|
||||||
v-if="formattedVariables.length === 0"
|
v-for="variable in formattedVariables"
|
||||||
vertical
|
:key="variable.name"
|
||||||
style="padding: 20px; text-align: center"
|
size="small"
|
||||||
|
:bordered="true"
|
||||||
>
|
>
|
||||||
<n-text type="info">暂无变量</n-text>
|
<n-flex vertical>
|
||||||
</n-space>
|
<n-flex justify="space-between" align="center">
|
||||||
<n-space v-else vertical>
|
<n-text class="debug-text-title" strong type="primary">{{
|
||||||
<n-card
|
variable.name
|
||||||
v-for="variable in formattedVariables"
|
}}</n-text>
|
||||||
:key="variable.name"
|
<n-tag size="small" type="info">{{ variable.type }}</n-tag>
|
||||||
size="small"
|
</n-flex>
|
||||||
:bordered="true"
|
<n-text code class="debug-text">
|
||||||
>
|
{{ variable.value }}
|
||||||
<n-space vertical :size="8">
|
</n-text>
|
||||||
<n-flex justify="space-between" align="center">
|
</n-flex>
|
||||||
<n-text strong type="primary">{{ variable.name }}</n-text>
|
</n-card>
|
||||||
<n-tag size="small" type="info">{{ variable.type }}</n-tag>
|
</n-flex>
|
||||||
</n-flex>
|
</n-scrollbar>
|
||||||
<n-text
|
</n-flex>
|
||||||
code
|
|
||||||
style="
|
|
||||||
font-size: 12px;
|
|
||||||
white-space: pre-wrap;
|
|
||||||
word-break: break-all;
|
|
||||||
"
|
|
||||||
>
|
|
||||||
{{ variable.value }}
|
|
||||||
</n-text>
|
|
||||||
</n-space>
|
|
||||||
</n-card>
|
|
||||||
</n-space>
|
|
||||||
</n-scrollbar>
|
|
||||||
</n-collapse-item>
|
|
||||||
</n-collapse>
|
|
||||||
|
|
||||||
<!-- 输出部分 -->
|
<!-- 输出部分 -->
|
||||||
<n-collapse v-if="currentOutput" :default-expanded-names="['output']">
|
<n-flex v-if="currentOutput" vertical>
|
||||||
<n-collapse-item name="output">
|
<n-text strong style="margin-bottom: 8px">输出({{ outputLines }}行)</n-text>
|
||||||
<template #header>
|
<n-card size="small" :bordered="true">
|
||||||
<n-flex align="center">
|
<n-scrollbar style="max-height: 300px">
|
||||||
<n-icon>
|
<n-text code class="debug-text">
|
||||||
<Icon icon="mdi:console" :width="14" :height="14" />
|
{{ currentOutput }}
|
||||||
</n-icon>
|
</n-text>
|
||||||
<n-text>输出({{ outputLines }}行)</n-text>
|
</n-scrollbar>
|
||||||
</n-flex>
|
</n-card>
|
||||||
</template>
|
</n-flex>
|
||||||
<n-card size="small" :bordered="true">
|
|
||||||
<n-scrollbar style="max-height: 300px">
|
|
||||||
<n-text
|
|
||||||
code
|
|
||||||
style="
|
|
||||||
font-size: 12px;
|
|
||||||
white-space: pre-wrap;
|
|
||||||
word-break: break-all;
|
|
||||||
display: block;
|
|
||||||
"
|
|
||||||
>
|
|
||||||
{{ currentOutput }}
|
|
||||||
</n-text>
|
|
||||||
</n-scrollbar>
|
|
||||||
</n-card>
|
|
||||||
</n-collapse-item>
|
|
||||||
</n-collapse>
|
|
||||||
</n-card>
|
</n-card>
|
||||||
</n-flex>
|
</n-flex>
|
||||||
</template>
|
</template>
|
||||||
<style scoped></style>
|
<style scoped>
|
||||||
|
.debug-text-title {
|
||||||
|
font-size: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.debug-text {
|
||||||
|
font-size: 20px;
|
||||||
|
white-space: pre-wrap;
|
||||||
|
word-break: break-all;
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
.step-info {
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|||||||
Reference in New Issue
Block a user