mirror of
https://gitlab.com/mbugroup/lti-web-client.git
synced 2026-05-20 13:32:00 +00:00
fix: set background color for shared image
This commit is contained in:
+3
-2
@@ -593,7 +593,9 @@ export function DetailDailyChecklistContent() {
|
|||||||
let shareData: ShareData;
|
let shareData: ShareData;
|
||||||
|
|
||||||
if (isMobile) {
|
if (isMobile) {
|
||||||
const htmlBlob = await htmlToImage.toBlob(document.body);
|
const htmlBlob = await htmlToImage.toBlob(document.body, {
|
||||||
|
backgroundColor: '#ffffff',
|
||||||
|
});
|
||||||
const imgFile = new File(
|
const imgFile = new File(
|
||||||
[htmlBlob!],
|
[htmlBlob!],
|
||||||
`daily-checklist-${header?.date}-${header?.kandang_name}-${header?.category}.png`,
|
`daily-checklist-${header?.date}-${header?.kandang_name}-${header?.category}.png`,
|
||||||
@@ -606,7 +608,6 @@ export function DetailDailyChecklistContent() {
|
|||||||
files: [imgFile],
|
files: [imgFile],
|
||||||
title: baseTitle,
|
title: baseTitle,
|
||||||
text: fullMessage,
|
text: fullMessage,
|
||||||
url: window.location.href,
|
|
||||||
};
|
};
|
||||||
} else {
|
} else {
|
||||||
shareData = {
|
shareData = {
|
||||||
|
|||||||
Reference in New Issue
Block a user