修改点离线样式
This commit is contained in:
@@ -10,7 +10,7 @@ export const useGenThumbnail = async (canvas_id: string = 'mtCanvasArea') => {
|
||||
// //记录要移除的svg元素
|
||||
const shouldRemoveSvgNodes = []
|
||||
// 获取到所有的SVG 得到一个数组 目前只有自定义连线需要特殊处理 别的元素直接使用html2canvas就可以
|
||||
|
||||
|
||||
const svgElements: NodeListOf<HTMLElement> = document.body.querySelectorAll(`#${canvas_id} .mt-line-render`)
|
||||
// 遍历这个数组
|
||||
for (const item of svgElements) {
|
||||
@@ -41,7 +41,7 @@ export const useGenThumbnail = async (canvas_id: string = 'mtCanvasArea') => {
|
||||
|
||||
const width = el.offsetWidth
|
||||
const height = el.offsetHeight
|
||||
|
||||
|
||||
const canvas = await html2canvas(el, {
|
||||
useCORS: true,
|
||||
scale: 2,
|
||||
|
||||
Reference in New Issue
Block a user