Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
P
poc-fe
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
poc
poc-fe
Commits
71a3429e
Commit
71a3429e
authored
Apr 22, 2025
by
tyyin lan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: 编辑器指令编辑插入内容失去格式
parent
a5cf8520
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
3 deletions
+7
-3
content-optimization-edit.vue
src/components/custom-editor/content-optimization-edit.vue
+7
-3
No files found.
src/components/custom-editor/content-optimization-edit.vue
View file @
71a3429e
...
@@ -149,7 +149,11 @@ function handleInsertContent() {
...
@@ -149,7 +149,11 @@ function handleInsertContent() {
if
(
editor
)
{
if
(
editor
)
{
editor
.
selection
.
collapse
()
editor
.
selection
.
collapse
()
editor
.
execCommand
(
'mceInsertNewLine'
)
editor
.
execCommand
(
'mceInsertNewLine'
)
editor
.
execCommand
(
'InsertHTML'
,
false
,
editResponseContent
.
value
)
editor
.
execCommand
(
'InsertHTML'
,
false
,
contentOptimizationEditMRRef
.
value
?.
getRenderTextContent
()
||
editResponseContent
.
value
,
)
editor
.
execCommand
(
'mceInsertNewLine'
)
editor
.
execCommand
(
'mceInsertNewLine'
)
contentEditStatus
.
value
=
'Normal'
contentEditStatus
.
value
=
'Normal'
...
@@ -286,7 +290,7 @@ function toneSelectMenuRenderOption({ node, option }: { node: VNode; option: Dro
...
@@ -286,7 +290,7 @@ function toneSelectMenuRenderOption({ node, option }: { node: VNode; option: Dro
</div>
</div>
<Transition>
<Transition>
<div
v-show=
"editResponseLoading"
class=
"flex select-none items-center justify-between"
>
<div
v-show=
"editResponseLoading"
class=
"flex select-none items-center justify-between
pr-[10px]
"
>
<span>
<span>
<
template
v-if=
"!editResponseContent"
>
生成中...
</
template
>
<
template
v-if=
"!editResponseContent"
>
生成中...
</
template
>
</span>
</span>
...
@@ -298,7 +302,7 @@ function toneSelectMenuRenderOption({ node, option }: { node: VNode; option: Dro
...
@@ -298,7 +302,7 @@ function toneSelectMenuRenderOption({ node, option }: { node: VNode; option: Dro
</Transition>
</Transition>
<Transition>
<Transition>
<div
v-show=
"isShowReplaceToolbar"
class=
"mt-[9px]"
>
<div
v-show=
"isShowReplaceToolbar"
class=
"mt-[9px]
pr-[10px]
"
>
<n-button
type=
"primary"
size=
"small"
@
click=
"handleReplaceContent"
<n-button
type=
"primary"
size=
"small"
@
click=
"handleReplaceContent"
>
替换
>
替换
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment