chore(frontend): 移除未使用的新手引导组件残留代码

删除开发过程中遗留的未使用文件:
- TourDescription.vue: 未被使用的结构化描述组件
- useTourStepDescription.ts: 步骤key映射,引用的组件从未创建
- TourStepDescriptions/: 空的组件目录

当前实现通过 i18n + HTML 字符串直接提供描述内容,无需这些文件。
This commit is contained in:
shaw
2025-12-29 17:12:19 +08:00
parent 6a55b153fc
commit ef22d6f628
4 changed files with 0 additions and 257 deletions

View File

@@ -1,157 +0,0 @@
<template>
<div class="tour-description">
<!-- 主要段落 -->
<p v-if="mainText" class="main-text">{{ mainText }}</p>
<!-- 特性列表 -->
<div v-if="features && features.length > 0" class="features-section">
<p v-if="featuresTitle" class="section-title">{{ featuresTitle }}</p>
<ul class="features-list">
<li v-for="(feature, index) in features" :key="index">
<span v-if="feature.icon" class="feature-icon">{{ feature.icon }}</span>
<span v-if="feature.label" class="feature-label">{{ feature.label }}</span>
<span class="feature-text">{{ feature.text }}</span>
</li>
</ul>
</div>
<!-- 提示框 -->
<div v-if="tip" :class="['tip-box', `tip-${tip.type || 'info'}`]">
<span v-if="tip.label" class="tip-label">{{ tip.label }}</span>
<div v-if="tip.text" class="tip-text">{{ tip.text }}</div>
<ul v-if="tip.items && tip.items.length > 0" class="tip-list">
<li v-for="(item, index) in tip.items" :key="index">{{ item }}</li>
</ul>
</div>
<!-- 行动提示 -->
<p v-if="action" class="action-text">{{ action }}</p>
<!-- 额外说明 -->
<p v-if="note" class="note-text">{{ note }}</p>
</div>
</template>
<script setup lang="ts">
export interface TourFeature {
icon?: string
label?: string
text: string
}
export interface TourTip {
type?: 'info' | 'success' | 'warning' | 'example'
label?: string
text?: string
items?: string[]
}
export interface TourDescriptionProps {
mainText?: string
featuresTitle?: string
features?: TourFeature[]
tip?: TourTip
action?: string
note?: string
}
defineProps<TourDescriptionProps>()
</script>
<style scoped>
.tour-description {
line-height: 1.7;
font-size: 14px;
}
.main-text {
margin-bottom: 12px;
color: #374151;
}
.section-title {
margin-bottom: 8px;
font-weight: 600;
color: #1f2937;
}
.features-section {
margin-bottom: 12px;
}
.features-list {
margin-left: 20px;
font-size: 13px;
}
.features-list li {
margin-bottom: 6px;
}
.feature-icon {
margin-right: 4px;
}
.feature-label {
font-weight: 600;
margin-right: 4px;
}
.tip-box {
padding: 8px 12px;
border-radius: 4px;
border-left: 3px solid;
font-size: 13px;
margin-bottom: 12px;
}
.tip-info {
background: #eff6ff;
border-left-color: #3b82f6;
}
.tip-success {
background: #f0fdf4;
border-left-color: #10b981;
}
.tip-warning {
background: #fef3c7;
border-left-color: #f59e0b;
}
.tip-example {
background: #f0fdf4;
border-left-color: #10b981;
}
.tip-label {
font-weight: 600;
display: block;
margin-bottom: 4px;
}
.tip-text {
margin-bottom: 4px;
}
.tip-list {
margin: 8px 0 0 16px;
}
.tip-list li {
margin-bottom: 4px;
}
.action-text {
margin-top: 12px;
color: #10b981;
font-weight: 600;
}
.note-text {
font-size: 13px;
color: #6b7280;
margin-top: 8px;
}
</style>

View File

@@ -1,20 +0,0 @@
<template>
<section
class="tour-step-description"
:lang="locale"
:data-step-key="stepKey"
>
<slot />
</section>
</template>
<script setup lang="ts">
import type { TourStepKey } from '@/composables/useTourStepDescription'
interface TourStepDescriptionProps {
stepKey: TourStepKey
locale: string
}
defineProps<TourStepDescriptionProps>()
</script>

View File

@@ -1 +0,0 @@
export { default as TourStepDescription } from './TourStepDescription.vue'