From b80d408287c4aa7fbb49df3c257f2f42c64c1352 Mon Sep 17 00:00:00 2001 From: sup39 Date: Fri, 7 Oct 2022 23:41:48 +0900 Subject: [PATCH] fix padStart() in --- site/.vuepress/components/Preview.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/site/.vuepress/components/Preview.vue b/site/.vuepress/components/Preview.vue index 1f90874..07af535 100644 --- a/site/.vuepress/components/Preview.vue +++ b/site/.vuepress/components/Preview.vue @@ -28,7 +28,7 @@ export default { const {config: {qft}} = this; if (qft == null) return; const {x, y, fontSize, fgRGB, fgA, fgRGB2, fgA2, bgRGB, bgA, width} = qft; - const i2s = (rgb, a) => '#'+rgb.toString(16).padStart('0', 6)+a.toString(16).padStart('0', 2); + const i2s = (rgb, a) => '#'+rgb.toString(16).padStart(6, '0')+a.toString(16).padStart(2, '0'); const bg = i2s(bgRGB, bgA); const fg1 = i2s(fgRGB, fgA); return {