aegon-lv97 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/gen-ai/build-report/chartStreamRefs.ts +227 -0
- package/gen-ai/build-report/coherence-check/index.vue +559 -0
- package/gen-ai/build-report/components/ReportChapterWorkspace.vue +4571 -0
- package/gen-ai/build-report/components/ReportConfigPanel.vue +727 -0
- package/gen-ai/build-report/components/ReportGenerateSettingsPanel.vue +2361 -0
- package/gen-ai/build-report/components/ReportGeneratingPanel.vue +1765 -0
- package/gen-ai/build-report/components/ReportPromptPanel.vue +625 -0
- package/gen-ai/build-report/components/ReportSourceFileSummary.vue +665 -0
- package/gen-ai/build-report/components/ReportSourcesPanel.vue +1327 -0
- package/gen-ai/build-report/components/ReportTemplateDetail.vue +191 -0
- package/gen-ai/build-report/components/ReportTemplateEditorFormPanel.vue +667 -0
- package/gen-ai/build-report/components/ReportTemplatePicker.vue +302 -0
- package/gen-ai/build-report/components/ReportWorkflowSidebar.vue +148 -0
- package/gen-ai/build-report/components/paramsSetting.vue +886 -0
- package/gen-ai/build-report/components/reportEdit.vue +2283 -0
- package/gen-ai/build-report/index.vue +856 -0
- package/gen-ai/build-report/report-domain.ts +1133 -0
- package/gen-ai/build-report/report-template-data.ts +295 -0
- package/gen-ai/build-report/useReportWorkflow.ts +1386 -0
- package/gen-ai/common/assets/NotoSans-SC.woff2 +0 -0
- package/gen-ai/common/assets/NotoSans-TC.woff2 +0 -0
- package/gen-ai/common/assets/NotoSans.woff2 +0 -0
- package/gen-ai/common/assets/fonts.css +278 -0
- package/gen-ai/common/assets/pagination.css +163 -0
- package/gen-ai/common/directives/btnLoading.ts +455 -0
- package/gen-ai/common/directives/debounce.ts +98 -0
- package/gen-ai/common/directives/index.ts +30 -0
- package/gen-ai/common/en.md +417 -0
- package/gen-ai/common/index.ts +36 -0
- package/gen-ai/common/types/component-expose.ts +9 -0
- package/gen-ai/common/utils/api-res-status.ts +7 -0
- package/gen-ai/common/utils/navigation.ts +59 -0
- package/gen-ai/common/utils/remote-request.ts +45 -0
- package/gen-ai/common/utils/scroll.ts +577 -0
- package/gen-ai/components/AIExport/docx-export.ts +950 -0
- package/gen-ai/components/AIExport/docxExport.ts +2566 -0
- package/gen-ai/components/AIExport/index.ts +52 -0
- package/gen-ai/components/AIExport/parseMarkdownHtml.ts +653 -0
- package/gen-ai/components/CapsuleScrollbar.vue +149 -0
- package/gen-ai/components/ChapterTitleScroll.vue +468 -0
- package/gen-ai/components/EntryHeroNavCards.vue +379 -0
- package/gen-ai/components/GenAiPagination.vue +52 -0
- package/gen-ai/components/ModelCard.vue +1114 -0
- package/gen-ai/components/Preview/FilePreviewPage.vue +949 -0
- package/gen-ai/components/Preview/PreviewCapsuleScroll.vue +205 -0
- package/gen-ai/components/Preview/PreviewOutlineTree.vue +148 -0
- package/gen-ai/components/Preview/index.ts +11 -0
- package/gen-ai/components/Preview/preview.ts +724 -0
- package/gen-ai/components/PromptField.vue +505 -0
- package/gen-ai/components/RecentReportsTable.vue +974 -0
- package/gen-ai/components/ReportCollapsibleSection.vue +172 -0
- package/gen-ai/components/ReportHistoryList.vue +637 -0
- package/gen-ai/components/ReportSectionConfirmPopover.vue +251 -0
- package/gen-ai/components/editor/ChapterTiptapEditor.vue +3718 -0
- package/gen-ai/components/editor/StructureBlockView.vue +441 -0
- package/gen-ai/components/editor/TiptapToolbar.vue +1036 -0
- package/gen-ai/components/editor/TypewriterDocEditor.vue +422 -0
- package/gen-ai/components/editor/_StructureOrgNode.vue +326 -0
- package/gen-ai/components/editor/index.ts +28 -0
- package/gen-ai/components/editor/parseMarkdownHtml.ts +754 -0
- package/gen-ai/components/editor/reviewCitationTip.ts +163 -0
- package/gen-ai/gen-entry/api/index.ts +32 -0
- package/gen-ai/gen-entry/index.vue +287 -0
- package/gen-ai/gen-entry/types/index.ts +4 -0
- package/gen-ai/i.mark +2 -0
- package/gen-ai/management-center/index.vue +1815 -0
- package/gen-ai/management-center/mockData.ts +248 -0
- package/gen-ai/management-center/types/index.ts +37 -0
- package/gen-ai/model-manager/TemplateEditorFormPanel.vue +661 -0
- package/gen-ai/model-manager/api/index.ts +32 -0
- package/gen-ai/model-manager/api/mockApi.ts +33 -0
- package/gen-ai/model-manager/index.vue +1583 -0
- package/gen-ai/model-manager/mockData.ts +177 -0
- package/gen-ai/model-manager/template-detail-shared.ts +154 -0
- package/gen-ai/model-manager/template-editor.vue +345 -0
- package/gen-ai/model-manager/types/index.ts +40 -0
- package/gen-ai/model-manager/utils.ts +25 -0
- package/package.json +12 -0
|
@@ -0,0 +1,637 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div ref="listRootRef" class="report-history-list" :class="{ 'is-embedded': !showTitle }">
|
|
3
|
+
<div v-if="showTitle" class="report-history-list__title">{{ title }}</div>
|
|
4
|
+
<div class="report-history-list__items">
|
|
5
|
+
<div
|
|
6
|
+
v-for="item in items"
|
|
7
|
+
:key="item.key"
|
|
8
|
+
class="report-history-list__row"
|
|
9
|
+
:class="{
|
|
10
|
+
'is-active': item.key === activeKey,
|
|
11
|
+
'is-draft': item.kind === 'draft',
|
|
12
|
+
}"
|
|
13
|
+
@click="handleSelect(item)"
|
|
14
|
+
>
|
|
15
|
+
<span class="report-history-list__indicator" aria-hidden="true" />
|
|
16
|
+
<div class="report-history-list__item">
|
|
17
|
+
<!-- 存為草稿:首行提示卡片 + 淺色繼續編輯 / 刪除 -->
|
|
18
|
+
<template v-if="item.kind === 'draft'">
|
|
19
|
+
<div class="report-history-list__draft-body">
|
|
20
|
+
<div class="report-history-list__draft-title">{{ item.title }}</div>
|
|
21
|
+
<div class="report-history-list__draft-actions" @click.stop>
|
|
22
|
+
<button
|
|
23
|
+
type="button"
|
|
24
|
+
class="report-history-list__draft-btn"
|
|
25
|
+
@click="emit('continue-draft', item)"
|
|
26
|
+
>
|
|
27
|
+
繼續編輯
|
|
28
|
+
</button>
|
|
29
|
+
<button
|
|
30
|
+
type="button"
|
|
31
|
+
class="report-history-list__draft-btn"
|
|
32
|
+
@click="handleDelete(item)"
|
|
33
|
+
>
|
|
34
|
+
刪除
|
|
35
|
+
</button>
|
|
36
|
+
</div>
|
|
37
|
+
</div>
|
|
38
|
+
</template>
|
|
39
|
+
|
|
40
|
+
<template v-else>
|
|
41
|
+
<div class="report-history-list__body">
|
|
42
|
+
<div class="report-history-list__item-title">
|
|
43
|
+
{{ item.title }}
|
|
44
|
+
</div>
|
|
45
|
+
<div class="report-history-list__meta">
|
|
46
|
+
<span class="report-history-list__author">{{ item.author }}</span>
|
|
47
|
+
<span class="report-history-list__time">{{
|
|
48
|
+
formatHistoryTime(item.finalizedAt)
|
|
49
|
+
}}</span>
|
|
50
|
+
</div>
|
|
51
|
+
</div>
|
|
52
|
+
|
|
53
|
+
<div class="report-history-list__item-trailing">
|
|
54
|
+
<button
|
|
55
|
+
v-if="editable"
|
|
56
|
+
type="button"
|
|
57
|
+
class="report-history-list__menu"
|
|
58
|
+
aria-label="重命名"
|
|
59
|
+
@click.stop="openRenamePopover(item, $event)"
|
|
60
|
+
>
|
|
61
|
+
<span class="report-history-list__menu-dots" aria-hidden="true">⋮</span>
|
|
62
|
+
</button>
|
|
63
|
+
</div>
|
|
64
|
+
</template>
|
|
65
|
+
</div>
|
|
66
|
+
</div>
|
|
67
|
+
</div>
|
|
68
|
+
|
|
69
|
+
<!-- 點擊 … 直接彈出重命名:寬度同章節歷史,位於當前行下方 -->
|
|
70
|
+
<el-popover
|
|
71
|
+
:visible="renamePopoverVisible"
|
|
72
|
+
virtual-triggering
|
|
73
|
+
:virtual-ref="renameVirtualRef"
|
|
74
|
+
placement="bottom-start"
|
|
75
|
+
:width="renamePopoverWidth"
|
|
76
|
+
:show-arrow="false"
|
|
77
|
+
:teleported="true"
|
|
78
|
+
:popper-options="renamePopperOptions"
|
|
79
|
+
popper-class="report-history-rename-popper"
|
|
80
|
+
:gpu-acceleration="false"
|
|
81
|
+
@update:visible="onRenamePopoverVisible"
|
|
82
|
+
>
|
|
83
|
+
<div class="report-history-rename-panel" @click.stop>
|
|
84
|
+
<div class="report-history-rename-panel__title">重命名</div>
|
|
85
|
+
<el-input
|
|
86
|
+
ref="renameTextareaRef"
|
|
87
|
+
v-model="renameDraft"
|
|
88
|
+
type="textarea"
|
|
89
|
+
:rows="renameTextareaRows"
|
|
90
|
+
maxlength="50"
|
|
91
|
+
show-word-limit
|
|
92
|
+
resize="none"
|
|
93
|
+
class="report-history-rename-panel__textarea"
|
|
94
|
+
@keydown.esc.stop="cancelRename"
|
|
95
|
+
/>
|
|
96
|
+
<div class="report-history-rename-panel__actions">
|
|
97
|
+
<el-button class="report-history-rename-panel__btn" @click="handleDeleteFromRename">
|
|
98
|
+
<el-icon :size="14"><CloseBold /></el-icon>
|
|
99
|
+
<span>刪除</span>
|
|
100
|
+
</el-button>
|
|
101
|
+
<el-button
|
|
102
|
+
class="report-history-rename-panel__btn report-history-rename-panel__btn--primary"
|
|
103
|
+
@click="confirmRename"
|
|
104
|
+
>
|
|
105
|
+
<el-icon :size="14"><Select /></el-icon>
|
|
106
|
+
<span>確認</span>
|
|
107
|
+
</el-button>
|
|
108
|
+
</div>
|
|
109
|
+
</div>
|
|
110
|
+
</el-popover>
|
|
111
|
+
</div>
|
|
112
|
+
</template>
|
|
113
|
+
|
|
114
|
+
<script setup lang="ts">
|
|
115
|
+
import { CloseBold, Select } from '@element-plus/icons-vue'
|
|
116
|
+
import { ElButton, ElIcon, ElInput, ElMessage, ElMessageBox, ElPopover } from 'element-plus'
|
|
117
|
+
import { computed, nextTick, onMounted, onUnmounted, ref } from 'vue'
|
|
118
|
+
import { formatReportHistoryTime } from '../build-report/report-domain'
|
|
119
|
+
|
|
120
|
+
export interface ReportHistoryItem {
|
|
121
|
+
key: string
|
|
122
|
+
title: string
|
|
123
|
+
author: string
|
|
124
|
+
finalizedAt: string
|
|
125
|
+
recordId?: string
|
|
126
|
+
kind?: 'draft' | 'history'
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
const props = withDefaults(
|
|
130
|
+
defineProps<{
|
|
131
|
+
title?: string
|
|
132
|
+
items: ReportHistoryItem[]
|
|
133
|
+
activeKey?: string
|
|
134
|
+
showTitle?: boolean
|
|
135
|
+
editable?: boolean
|
|
136
|
+
}>(),
|
|
137
|
+
{
|
|
138
|
+
title: '報告歷史',
|
|
139
|
+
activeKey: '',
|
|
140
|
+
showTitle: true,
|
|
141
|
+
editable: false,
|
|
142
|
+
}
|
|
143
|
+
)
|
|
144
|
+
|
|
145
|
+
const emit = defineEmits<{
|
|
146
|
+
'update:activeKey': [key: string]
|
|
147
|
+
'update:items': [items: ReportHistoryItem[]]
|
|
148
|
+
select: [item: ReportHistoryItem]
|
|
149
|
+
'continue-draft': [item: ReportHistoryItem]
|
|
150
|
+
/** 重命名彈窗點確認(由父組件調接口後再 update:items) */
|
|
151
|
+
'rename-confirm': [payload: { key: string; title: string }]
|
|
152
|
+
/** 重命名彈窗「刪除」或草稿卡刪除(由父組件調 deleteSectionVersion) */
|
|
153
|
+
'delete-confirm': [payload: { key: string }]
|
|
154
|
+
}>()
|
|
155
|
+
|
|
156
|
+
const now = ref(Date.now())
|
|
157
|
+
const listRootRef = ref<HTMLElement | null>(null)
|
|
158
|
+
const renameVirtualRef = ref<HTMLElement | null>(null)
|
|
159
|
+
const renamingItem = ref<ReportHistoryItem | null>(null)
|
|
160
|
+
const renameDraft = ref('')
|
|
161
|
+
const renamePopoverWidth = ref(280)
|
|
162
|
+
const renameTextareaRows = ref(3)
|
|
163
|
+
const renameTextareaRef = ref<InstanceType<typeof ElInput> | null>(null)
|
|
164
|
+
const renameOffsetKey = ref(0)
|
|
165
|
+
let timeRefreshTimer: number | null = null
|
|
166
|
+
|
|
167
|
+
const renamePopoverVisible = computed(() => !!renamingItem.value)
|
|
168
|
+
|
|
169
|
+
const renamePopperOptions = computed(() => {
|
|
170
|
+
void renameOffsetKey.value
|
|
171
|
+
const list = listRootRef.value
|
|
172
|
+
const anchor = renameVirtualRef.value
|
|
173
|
+
let skid = 0
|
|
174
|
+
if (list && anchor) {
|
|
175
|
+
const listRect = list.getBoundingClientRect()
|
|
176
|
+
const anchorRect = anchor.getBoundingClientRect()
|
|
177
|
+
skid = Math.round(listRect.left - anchorRect.left)
|
|
178
|
+
}
|
|
179
|
+
return {
|
|
180
|
+
modifiers: [
|
|
181
|
+
{
|
|
182
|
+
name: 'offset',
|
|
183
|
+
options: { offset: [skid, 8] },
|
|
184
|
+
},
|
|
185
|
+
{
|
|
186
|
+
name: 'flip',
|
|
187
|
+
enabled: false,
|
|
188
|
+
},
|
|
189
|
+
],
|
|
190
|
+
}
|
|
191
|
+
})
|
|
192
|
+
|
|
193
|
+
onMounted(() => {
|
|
194
|
+
timeRefreshTimer = window.setInterval(() => {
|
|
195
|
+
now.value = Date.now()
|
|
196
|
+
}, 30_000)
|
|
197
|
+
})
|
|
198
|
+
|
|
199
|
+
onUnmounted(() => {
|
|
200
|
+
if (timeRefreshTimer) window.clearInterval(timeRefreshTimer)
|
|
201
|
+
})
|
|
202
|
+
|
|
203
|
+
function formatHistoryTime(finalizedAt: string) {
|
|
204
|
+
return formatReportHistoryTime(finalizedAt, now.value)
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
function handleSelect(item: ReportHistoryItem) {
|
|
208
|
+
if (renamingItem.value) return
|
|
209
|
+
emit('update:activeKey', item.key)
|
|
210
|
+
emit('select', item)
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
function syncRenamePopoverWidth() {
|
|
214
|
+
const list = listRootRef.value
|
|
215
|
+
if (!list) return
|
|
216
|
+
renamePopoverWidth.value = Math.max(200, list.clientWidth)
|
|
217
|
+
// 按實際寬度估算:剛好放下 50 個漢字的行數
|
|
218
|
+
const contentW = renamePopoverWidth.value - 48
|
|
219
|
+
const charsPerLine = Math.max(8, Math.floor(contentW / 13))
|
|
220
|
+
renameTextareaRows.value = Math.max(2, Math.ceil(50 / charsPerLine))
|
|
221
|
+
renameOffsetKey.value += 1
|
|
222
|
+
}
|
|
223
|
+
|
|
224
|
+
async function openRenamePopover(item: ReportHistoryItem, event: MouseEvent) {
|
|
225
|
+
const trigger = event.currentTarget as HTMLElement | null
|
|
226
|
+
const row = trigger?.closest('.report-history-list__row') as HTMLElement | null
|
|
227
|
+
const itemEl = row?.querySelector('.report-history-list__item') as HTMLElement | null
|
|
228
|
+
renameVirtualRef.value = itemEl ?? row
|
|
229
|
+
renamingItem.value = item
|
|
230
|
+
renameDraft.value = item.title
|
|
231
|
+
// 點擊 … 聯動選中背景
|
|
232
|
+
emit('update:activeKey', item.key)
|
|
233
|
+
emit('select', item)
|
|
234
|
+
syncRenamePopoverWidth()
|
|
235
|
+
await nextTick()
|
|
236
|
+
syncRenamePopoverWidth()
|
|
237
|
+
renameTextareaRef.value?.focus()
|
|
238
|
+
}
|
|
239
|
+
|
|
240
|
+
function cancelRename() {
|
|
241
|
+
renamingItem.value = null
|
|
242
|
+
renameDraft.value = ''
|
|
243
|
+
renameVirtualRef.value = null
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
function onRenamePopoverVisible(visible: boolean) {
|
|
247
|
+
if (!visible) cancelRename()
|
|
248
|
+
}
|
|
249
|
+
|
|
250
|
+
function confirmRename() {
|
|
251
|
+
const item = renamingItem.value
|
|
252
|
+
if (!item) return
|
|
253
|
+
const nextTitle = renameDraft.value.trim()
|
|
254
|
+
if (!nextTitle) {
|
|
255
|
+
ElMessage.warning('名稱不能為空')
|
|
256
|
+
return
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
// 交由父組件調用 updateSectionVersionName,成功後再回寫 items
|
|
260
|
+
emit('rename-confirm', { key: item.key, title: nextTitle.slice(0, 50) })
|
|
261
|
+
cancelRename()
|
|
262
|
+
}
|
|
263
|
+
|
|
264
|
+
/** 重命名彈窗左側「刪除」→ 刪除當前 card 對應版本 */
|
|
265
|
+
async function handleDeleteFromRename() {
|
|
266
|
+
const item = renamingItem.value
|
|
267
|
+
if (!item) return
|
|
268
|
+
await handleDelete(item)
|
|
269
|
+
}
|
|
270
|
+
|
|
271
|
+
async function handleDelete(item: ReportHistoryItem) {
|
|
272
|
+
const isDraft = item.kind === 'draft'
|
|
273
|
+
try {
|
|
274
|
+
await ElMessageBox.confirm(
|
|
275
|
+
isDraft ? '確定刪除此草稿?' : `確定刪除「${item.title}」?`,
|
|
276
|
+
'確認刪除',
|
|
277
|
+
{
|
|
278
|
+
confirmButtonText: '刪除',
|
|
279
|
+
cancelButtonText: '取消',
|
|
280
|
+
type: 'warning',
|
|
281
|
+
}
|
|
282
|
+
)
|
|
283
|
+
} catch {
|
|
284
|
+
return
|
|
285
|
+
}
|
|
286
|
+
|
|
287
|
+
if (renamingItem.value?.key === item.key) {
|
|
288
|
+
cancelRename()
|
|
289
|
+
}
|
|
290
|
+
|
|
291
|
+
// 交由父組件調用 deleteSectionVersion,成功後再刷新列表
|
|
292
|
+
emit('delete-confirm', { key: item.key })
|
|
293
|
+
}
|
|
294
|
+
</script>
|
|
295
|
+
|
|
296
|
+
<style scoped>
|
|
297
|
+
.report-history-list {
|
|
298
|
+
--history-row-h: 62px;
|
|
299
|
+
--history-row-gap: 6px;
|
|
300
|
+
border-top: 1px solid #f0f0f0;
|
|
301
|
+
padding-top: 20px;
|
|
302
|
+
}
|
|
303
|
+
|
|
304
|
+
.report-history-list.is-embedded {
|
|
305
|
+
border-top: none;
|
|
306
|
+
padding-top: 0;
|
|
307
|
+
}
|
|
308
|
+
|
|
309
|
+
.report-history-list__title {
|
|
310
|
+
font-size: 15px;
|
|
311
|
+
font-weight: 500;
|
|
312
|
+
font-family: var(--gen-ai-font-family, 'Noto Sans', 'Noto Sans TC', sans-serif);
|
|
313
|
+
color: #303133;
|
|
314
|
+
margin-bottom: 12px;
|
|
315
|
+
}
|
|
316
|
+
|
|
317
|
+
.report-history-list__items {
|
|
318
|
+
display: flex;
|
|
319
|
+
flex-direction: column;
|
|
320
|
+
gap: var(--history-row-gap);
|
|
321
|
+
max-height: calc(var(--history-row-h) * 20 + var(--history-row-gap) * 19);
|
|
322
|
+
overflow-x: hidden;
|
|
323
|
+
overflow-y: auto;
|
|
324
|
+
scrollbar-width: thin;
|
|
325
|
+
scrollbar-color: #999 transparent;
|
|
326
|
+
}
|
|
327
|
+
|
|
328
|
+
.report-history-list__row {
|
|
329
|
+
display: grid;
|
|
330
|
+
grid-template-columns: 4px minmax(0, 1fr);
|
|
331
|
+
column-gap: 0;
|
|
332
|
+
align-items: stretch;
|
|
333
|
+
cursor: pointer;
|
|
334
|
+
}
|
|
335
|
+
|
|
336
|
+
.report-history-list__indicator {
|
|
337
|
+
width: 4px;
|
|
338
|
+
border-radius: 2px;
|
|
339
|
+
background: transparent;
|
|
340
|
+
align-self: stretch;
|
|
341
|
+
margin-block: 12px;
|
|
342
|
+
min-height: 0;
|
|
343
|
+
transition: background 0.15s;
|
|
344
|
+
}
|
|
345
|
+
|
|
346
|
+
.report-history-list__row.is-active .report-history-list__indicator {
|
|
347
|
+
background: #c53355;
|
|
348
|
+
}
|
|
349
|
+
|
|
350
|
+
.report-history-list__row.is-draft {
|
|
351
|
+
grid-template-columns: minmax(0, 1fr);
|
|
352
|
+
column-gap: 0;
|
|
353
|
+
}
|
|
354
|
+
|
|
355
|
+
.report-history-list__row.is-draft .report-history-list__indicator {
|
|
356
|
+
display: none;
|
|
357
|
+
}
|
|
358
|
+
|
|
359
|
+
.report-history-list__row.is-draft.is-active .report-history-list__indicator {
|
|
360
|
+
background: transparent;
|
|
361
|
+
}
|
|
362
|
+
|
|
363
|
+
.report-history-list__item {
|
|
364
|
+
display: flex;
|
|
365
|
+
align-items: center;
|
|
366
|
+
justify-content: space-between;
|
|
367
|
+
gap: 10px;
|
|
368
|
+
padding: 12px 8px;
|
|
369
|
+
border-radius: 12px;
|
|
370
|
+
transition: background 0.15s;
|
|
371
|
+
min-width: 0;
|
|
372
|
+
}
|
|
373
|
+
|
|
374
|
+
.report-history-list__item-trailing {
|
|
375
|
+
display: flex;
|
|
376
|
+
align-items: flex-start;
|
|
377
|
+
gap: 2px;
|
|
378
|
+
flex-shrink: 0;
|
|
379
|
+
}
|
|
380
|
+
|
|
381
|
+
.report-history-list__row.is-active .report-history-list__item {
|
|
382
|
+
background: #fdf0f3;
|
|
383
|
+
}
|
|
384
|
+
|
|
385
|
+
.report-history-list__row.is-draft .report-history-list__item {
|
|
386
|
+
background: #fff5f7;
|
|
387
|
+
}
|
|
388
|
+
|
|
389
|
+
.report-history-list__row.is-draft.is-active .report-history-list__item {
|
|
390
|
+
background: #fdf0f3;
|
|
391
|
+
}
|
|
392
|
+
|
|
393
|
+
.report-history-list__row:not(.is-active):hover .report-history-list__item {
|
|
394
|
+
background: #fafafa;
|
|
395
|
+
}
|
|
396
|
+
|
|
397
|
+
.report-history-list__row.is-draft:not(.is-active):hover .report-history-list__item {
|
|
398
|
+
background: #fff0f3;
|
|
399
|
+
}
|
|
400
|
+
|
|
401
|
+
.report-history-list__draft-body {
|
|
402
|
+
display: flex;
|
|
403
|
+
flex-direction: column;
|
|
404
|
+
align-items: stretch;
|
|
405
|
+
gap: 10px;
|
|
406
|
+
width: 100%;
|
|
407
|
+
min-width: 0;
|
|
408
|
+
}
|
|
409
|
+
|
|
410
|
+
.report-history-list__draft-title {
|
|
411
|
+
width: 100%;
|
|
412
|
+
min-width: 0;
|
|
413
|
+
/* 與定稿版本(.report-history-list__item-title)字體一致 */
|
|
414
|
+
font-size: 15px;
|
|
415
|
+
font-weight: 500;
|
|
416
|
+
font-family: var(--gen-ai-font-family, 'Noto Sans', 'Noto Sans TC', sans-serif);
|
|
417
|
+
font-synthesis: none;
|
|
418
|
+
color: #c53355;
|
|
419
|
+
line-height: 1.4;
|
|
420
|
+
letter-spacing: normal;
|
|
421
|
+
}
|
|
422
|
+
|
|
423
|
+
.report-history-list__draft-actions {
|
|
424
|
+
display: inline-flex;
|
|
425
|
+
align-items: center;
|
|
426
|
+
justify-content: center;
|
|
427
|
+
gap: 8px;
|
|
428
|
+
width: 100%;
|
|
429
|
+
flex-shrink: 0;
|
|
430
|
+
}
|
|
431
|
+
|
|
432
|
+
.report-history-list__draft-btn {
|
|
433
|
+
display: inline-flex;
|
|
434
|
+
align-items: center;
|
|
435
|
+
justify-content: center;
|
|
436
|
+
box-sizing: border-box;
|
|
437
|
+
height: 28px;
|
|
438
|
+
padding: 0 12px;
|
|
439
|
+
border-radius: 4px;
|
|
440
|
+
border: 1px solid #f0c2cc;
|
|
441
|
+
background: #fdf0f2;
|
|
442
|
+
color: #c53355;
|
|
443
|
+
/* 與定稿版本標題同字族/字重 */
|
|
444
|
+
font-size: 15px;
|
|
445
|
+
font-weight: 500;
|
|
446
|
+
font-family: var(--gen-ai-font-family, 'Noto Sans', 'Noto Sans TC', sans-serif);
|
|
447
|
+
font-synthesis: none;
|
|
448
|
+
line-height: 1;
|
|
449
|
+
letter-spacing: normal;
|
|
450
|
+
cursor: pointer;
|
|
451
|
+
transition:
|
|
452
|
+
background 0.15s ease,
|
|
453
|
+
border-color 0.15s ease;
|
|
454
|
+
}
|
|
455
|
+
|
|
456
|
+
.report-history-list__draft-btn:hover {
|
|
457
|
+
background: #fff;
|
|
458
|
+
border-color: #c53355;
|
|
459
|
+
}
|
|
460
|
+
|
|
461
|
+
.report-history-list__body {
|
|
462
|
+
flex: 1;
|
|
463
|
+
min-width: 0;
|
|
464
|
+
}
|
|
465
|
+
|
|
466
|
+
.report-history-list__item-title {
|
|
467
|
+
font-size: 15px;
|
|
468
|
+
font-weight: 500;
|
|
469
|
+
font-family: var(--gen-ai-font-family, 'Noto Sans', 'Noto Sans TC', sans-serif);
|
|
470
|
+
font-synthesis: none;
|
|
471
|
+
color: #303133;
|
|
472
|
+
line-height: 1.4;
|
|
473
|
+
letter-spacing: normal;
|
|
474
|
+
overflow: hidden;
|
|
475
|
+
text-overflow: ellipsis;
|
|
476
|
+
white-space: nowrap;
|
|
477
|
+
}
|
|
478
|
+
|
|
479
|
+
.report-history-list__meta {
|
|
480
|
+
margin-top: 2px;
|
|
481
|
+
color: #999;
|
|
482
|
+
font-size: 12px;
|
|
483
|
+
line-height: 1.4;
|
|
484
|
+
display: flex;
|
|
485
|
+
align-items: center;
|
|
486
|
+
justify-content: space-between;
|
|
487
|
+
gap: 8px;
|
|
488
|
+
}
|
|
489
|
+
|
|
490
|
+
.report-history-list__author {
|
|
491
|
+
min-width: 0;
|
|
492
|
+
overflow: hidden;
|
|
493
|
+
text-overflow: ellipsis;
|
|
494
|
+
white-space: nowrap;
|
|
495
|
+
}
|
|
496
|
+
|
|
497
|
+
.report-history-list__time {
|
|
498
|
+
flex-shrink: 0;
|
|
499
|
+
white-space: nowrap;
|
|
500
|
+
}
|
|
501
|
+
|
|
502
|
+
.report-history-list__menu {
|
|
503
|
+
display: inline-flex;
|
|
504
|
+
align-items: center;
|
|
505
|
+
justify-content: center;
|
|
506
|
+
align-self: center;
|
|
507
|
+
width: 20px;
|
|
508
|
+
min-height: 36px;
|
|
509
|
+
padding: 0;
|
|
510
|
+
border: none;
|
|
511
|
+
background: transparent;
|
|
512
|
+
color: #1a1a1a;
|
|
513
|
+
cursor: pointer;
|
|
514
|
+
flex-shrink: 0;
|
|
515
|
+
}
|
|
516
|
+
|
|
517
|
+
.report-history-list__row:hover .report-history-list__menu,
|
|
518
|
+
.report-history-list__row.is-active .report-history-list__menu {
|
|
519
|
+
color: #c53355;
|
|
520
|
+
}
|
|
521
|
+
|
|
522
|
+
.report-history-list__menu-dots {
|
|
523
|
+
display: block;
|
|
524
|
+
font-size: 26px;
|
|
525
|
+
font-weight: 900;
|
|
526
|
+
line-height: 1;
|
|
527
|
+
transform: translateY(-1px);
|
|
528
|
+
}
|
|
529
|
+
</style>
|
|
530
|
+
|
|
531
|
+
<style>
|
|
532
|
+
/* teleported popover:與章節歷史同寬,掛在當前行下方 */
|
|
533
|
+
.report-history-rename-popper.el-popover.el-popper {
|
|
534
|
+
padding: 14px 16px;
|
|
535
|
+
border: 1px solid #ebeef5;
|
|
536
|
+
border-radius: 8px;
|
|
537
|
+
box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
|
|
538
|
+
box-sizing: border-box;
|
|
539
|
+
}
|
|
540
|
+
|
|
541
|
+
.report-history-rename-panel__title {
|
|
542
|
+
margin: 0 0 12px;
|
|
543
|
+
font-size: 15px;
|
|
544
|
+
font-weight: 500;
|
|
545
|
+
color: #303133;
|
|
546
|
+
line-height: 1.4;
|
|
547
|
+
}
|
|
548
|
+
|
|
549
|
+
.report-history-rename-panel__textarea {
|
|
550
|
+
width: 100%;
|
|
551
|
+
}
|
|
552
|
+
|
|
553
|
+
.report-history-rename-panel__textarea .el-textarea__inner {
|
|
554
|
+
font-size: 13px;
|
|
555
|
+
line-height: 1.5;
|
|
556
|
+
color: #303133;
|
|
557
|
+
overflow-y: auto;
|
|
558
|
+
box-shadow: 0 0 0 1px #dcdfe6 inset;
|
|
559
|
+
/* 與章節下拉 el-scrollbar 同款:寬 8px、滑塊高 50px */
|
|
560
|
+
scrollbar-width: thin;
|
|
561
|
+
scrollbar-color: #999 transparent;
|
|
562
|
+
}
|
|
563
|
+
|
|
564
|
+
.report-history-rename-panel__textarea .el-textarea__inner:hover {
|
|
565
|
+
box-shadow: 0 0 0 1px #c0c4cc inset;
|
|
566
|
+
}
|
|
567
|
+
|
|
568
|
+
.report-history-rename-panel__textarea .el-textarea__inner:focus {
|
|
569
|
+
box-shadow: 0 0 0 1px #c53355 inset;
|
|
570
|
+
}
|
|
571
|
+
|
|
572
|
+
.report-history-rename-panel__textarea .el-textarea__inner::-webkit-scrollbar {
|
|
573
|
+
width: 8px;
|
|
574
|
+
}
|
|
575
|
+
|
|
576
|
+
.report-history-rename-panel__textarea .el-textarea__inner::-webkit-scrollbar-track {
|
|
577
|
+
background: transparent;
|
|
578
|
+
}
|
|
579
|
+
|
|
580
|
+
.report-history-rename-panel__textarea .el-textarea__inner::-webkit-scrollbar-thumb {
|
|
581
|
+
min-height: 50px;
|
|
582
|
+
border-radius: 4px;
|
|
583
|
+
background-color: #999;
|
|
584
|
+
}
|
|
585
|
+
|
|
586
|
+
.report-history-rename-panel__actions {
|
|
587
|
+
display: flex;
|
|
588
|
+
align-items: center;
|
|
589
|
+
justify-content: center;
|
|
590
|
+
gap: 8px;
|
|
591
|
+
margin-top: 12px;
|
|
592
|
+
}
|
|
593
|
+
|
|
594
|
+
.report-history-rename-panel__btn.el-button {
|
|
595
|
+
display: inline-flex;
|
|
596
|
+
align-items: center;
|
|
597
|
+
justify-content: center;
|
|
598
|
+
gap: 4px;
|
|
599
|
+
height: 32px;
|
|
600
|
+
padding: 0 14px;
|
|
601
|
+
margin: 0;
|
|
602
|
+
}
|
|
603
|
+
|
|
604
|
+
.report-history-rename-panel__btn--primary.el-button {
|
|
605
|
+
--el-button-bg-color: #c53355;
|
|
606
|
+
--el-button-border-color: #c53355;
|
|
607
|
+
--el-button-hover-bg-color: #a82a47;
|
|
608
|
+
--el-button-hover-border-color: #a82a47;
|
|
609
|
+
--el-button-active-bg-color: #a82a47;
|
|
610
|
+
--el-button-active-border-color: #a82a47;
|
|
611
|
+
color: #fff;
|
|
612
|
+
background: #c53355;
|
|
613
|
+
border-color: #c53355;
|
|
614
|
+
}
|
|
615
|
+
|
|
616
|
+
.report-history-rename-panel__btn--primary.el-button:hover,
|
|
617
|
+
.report-history-rename-panel__btn--primary.el-button:focus {
|
|
618
|
+
color: #fff;
|
|
619
|
+
background: #a82a47;
|
|
620
|
+
border-color: #a82a47;
|
|
621
|
+
}
|
|
622
|
+
|
|
623
|
+
/* 章節歷史 / 報告歷史:超過 20 條後垂直滾動條強制 寬 3px、高 8px */
|
|
624
|
+
.report-history-list__items::-webkit-scrollbar {
|
|
625
|
+
width: 3px;
|
|
626
|
+
height: 8px;
|
|
627
|
+
}
|
|
628
|
+
|
|
629
|
+
.report-history-list__items::-webkit-scrollbar-thumb {
|
|
630
|
+
background: #999;
|
|
631
|
+
border-radius: 999px;
|
|
632
|
+
}
|
|
633
|
+
|
|
634
|
+
.report-history-list__items::-webkit-scrollbar-track {
|
|
635
|
+
background: transparent;
|
|
636
|
+
}
|
|
637
|
+
</style>
|