mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-20 16:40:13 +01:00
This commit is contained in:
parent
45143bf319
commit
f964627038
2 changed files with 2 additions and 2 deletions
|
|
@ -56,7 +56,7 @@ export const exportImage = (id: string) => {
|
|||
setStorageVal(Constants.LOCAL_EXPORTIMG, window.siyuan.storage[Constants.LOCAL_EXPORTIMG]);
|
||||
setTimeout(() => {
|
||||
addScript("stage/protyle/js/html2canvas.min.js?v=1.4.1", "protyleHtml2canvas").then(() => {
|
||||
window.html2canvas(previewElement.parentElement).then((canvas) => {
|
||||
window.html2canvas(previewElement.parentElement, {useCORS: true}).then((canvas) => {
|
||||
canvas.toBlob((blob: Blob) => {
|
||||
const formData = new FormData();
|
||||
formData.append("file", blob, btnsElement[1].getAttribute("data-title"));
|
||||
|
|
|
|||
2
app/src/types/index.d.ts
vendored
2
app/src/types/index.d.ts
vendored
|
|
@ -39,7 +39,7 @@ interface Window {
|
|||
dataLayer: any[]
|
||||
siyuan: ISiyuan
|
||||
webkit: any
|
||||
html2canvas: (element: Element) => Promise<any>;
|
||||
html2canvas: (element: Element, opitons: {useCORS: boolean}) => Promise<any>;
|
||||
JSAndroid: {
|
||||
returnDesktop(): void
|
||||
openExternal(url: string): void
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue