Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Q
quantum-blocks
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
ui
quantum-blocks
Commits
1c3dbe1c
Commit
1c3dbe1c
authored
Jan 03, 2023
by
徐光星
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 修复保存页面时重载缩略图的问题
parent
3016010f
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
6 deletions
+3
-6
index.ts
app/web/page/editor/component/BasicPageFormModal/index.ts
+1
-6
index.vue
app/web/page/editor/component/DynamicComponent/index.vue
+2
-0
No files found.
app/web/page/editor/component/BasicPageFormModal/index.ts
View file @
1c3dbe1c
...
@@ -119,12 +119,7 @@ export default class DynamicForm extends Vue {
...
@@ -119,12 +119,7 @@ export default class DynamicForm extends Vue {
const
imgName
=
btoa
(
`coverImage-
${
uuidv4
().
substr
(
0
,
8
)}
`
);
const
imgName
=
btoa
(
`coverImage-
${
uuidv4
().
substr
(
0
,
8
)}
`
);
const
gridEle
=
document
.
querySelector
(
'
.Dcm-container-panel
'
);
const
gridEle
=
document
.
querySelector
(
'
.Dcm-container-panel
'
);
this
.
changeStyle
(
'
forward
'
);
this
.
changeStyle
(
'
forward
'
);
const
canvas
=
await
html2canvas
(
gridEle
as
HTMLElement
,
{
useCORS
:
true
,
allowTaint
:
true
,
ignoreElements
:
(
element
:
any
)
=>
{
const
canvas
=
await
html2canvas
(
gridEle
as
HTMLElement
,
{
useCORS
:
true
,
allowTaint
:
true
});
if
(
element
.
className
.
toLowerCase
()
==
'
ignore-html2canvas-loop
'
)
{
return
element
;
}
return
false
;
}
});
this
.
changeStyle
(
'
backward
'
);
this
.
changeStyle
(
'
backward
'
);
const
base64
=
canvas
.
toDataURL
();
const
base64
=
canvas
.
toDataURL
();
const
{
data
:
{
uptoken
}
}
=
await
editorApi
.
getUpToken
();
const
{
data
:
{
uptoken
}
}
=
await
editorApi
.
getUpToken
();
...
...
app/web/page/editor/component/DynamicComponent/index.vue
View file @
1c3dbe1c
...
@@ -9,6 +9,7 @@
...
@@ -9,6 +9,7 @@
<p
slot=
"title"
>
{{
config
.
title
}}
</p>
<p
slot=
"title"
>
{{
config
.
title
}}
</p>
<div
class=
"dynamic-row-card"
>
<div
class=
"dynamic-row-card"
>
<img
<img
data-html2canvas-ignore=
"true"
class=
"ignore-html2canvas-loop"
class=
"ignore-html2canvas-loop"
:src=
"config.coverImage || 'http://activitystatic.q-gp.com/low_code.jpg'"
:src=
"config.coverImage || 'http://activitystatic.q-gp.com/low_code.jpg'"
/>
/>
...
@@ -27,6 +28,7 @@
...
@@ -27,6 +28,7 @@
<p
slot=
"title"
>
{{
config
.
title
}}
</p>
<p
slot=
"title"
>
{{
config
.
title
}}
</p>
<div
class=
"dynamic-row-card"
>
<div
class=
"dynamic-row-card"
>
<img
<img
data-html2canvas-ignore=
"true"
class=
"ignore-html2canvas-loop"
class=
"ignore-html2canvas-loop"
:src=
"config.coverImage || 'http://activitystatic.q-gp.com/low_code.jpg'"
:src=
"config.coverImage || 'http://activitystatic.q-gp.com/low_code.jpg'"
/>
/>
...
...
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