From d55f3865e70ab4e2975629ec6c8e8f0aa7ebcc94 Mon Sep 17 00:00:00 2001 From: ningmengchongshui <916415899@qq.com> Date: Sat, 15 Jun 2024 15:08:16 +0800 Subject: [PATCH] =?UTF-8?q?update:=20=E5=A2=9E=E5=8A=A0=E6=B5=8F=E8=A7=88?= =?UTF-8?q?=E5=99=A8=E5=B0=BA=E5=AF=B8=E6=8F=90=E7=A4=BA&=E4=BF=AE?= =?UTF-8?q?=E6=AD=A3=E7=B1=BB=E5=9E=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- image/main.ts | 1 + src/core/plugins/index.ts | 3 +-- src/utils/puppeteer.ts | 7 +------ 3 files changed, 3 insertions(+), 8 deletions(-) diff --git a/image/main.ts b/image/main.ts index 8c00547..596f033 100644 --- a/image/main.ts +++ b/image/main.ts @@ -61,4 +61,5 @@ app.use(router.routes()) // listen 8000 app.listen(Port, () => { console.log('Server is running on port ' + Port) + console.log('自行调整BOT浏览器尺寸 753 X 1180') }) diff --git a/src/core/plugins/index.ts b/src/core/plugins/index.ts index b8edc5d..c8fbc88 100644 --- a/src/core/plugins/index.ts +++ b/src/core/plugins/index.ts @@ -257,12 +257,11 @@ export class Plugin { * @param cfg * @returns */ - async renderImg(plugin, tpl, data, cfg) { + async renderImg(plugin, tpl, data, cfg = {}) { return Common.render(plugin, tpl, data, { ...cfg, e: this.e }) } } - /** * @deprecated 已废弃 */ diff --git a/src/utils/puppeteer.ts b/src/utils/puppeteer.ts index 2d89d19..766259c 100644 --- a/src/utils/puppeteer.ts +++ b/src/utils/puppeteer.ts @@ -21,12 +21,7 @@ export const PuppeteerLunchConfig = new BaseConfig({ '--no-zygote', '--single-process' ] - // 设置浏览器默认尺寸 - // defaultViewport: { - // width: 1280, - // height: 853, - // isMobile: true - // } + // BOT浏览器默认尺寸 753 X 1180 }) /**