This commit is contained in:
syuilo 2025-09-15 08:59:01 +09:00
parent 0306298071
commit 205ca12178
1 changed files with 4 additions and 4 deletions

View File

@ -51,8 +51,8 @@ const canShare = computed(() => navigator.canShare && navigator.canShare(shareDa
const qrCodeEl = useTemplateRef('qrCodeEl');
const avatarColor = computed(() => tinycolor(instance.themeColor ?? '#86b300'));
const avatarHsl = computed(() => avatarColor.value.toHsl());
const qrColor = computed(() => tinycolor(instance.themeColor ?? '#86b300'));
const qrHsl = computed(() => qrColor.value.toHsl());
function share() {
if (!canShare.value) return;
@ -78,10 +78,10 @@ const qrCodeInstance = new QRCodeStyling({
crossOrigin: 'anonymous',
},
dotsOptions: {
color: tinycolor(`hsl(${avatarHsl.value.h}, 100, 18)`).toRgbString(),
color: tinycolor(`hsl(${qrHsl.value.h}, 100, 18)`).toRgbString(),
},
backgroundOptions: {
color: tinycolor(`hsl(${avatarHsl.value.h}, 100, 97)`).toRgbString(),
color: tinycolor(`hsl(${qrHsl.value.h}, 100, 97)`).toRgbString(),
},
});