From ab3325fc900e4233c028e70e89247d5c55008a6c Mon Sep 17 00:00:00 2001 From: qiang Date: Mon, 28 Nov 2022 19:28:03 +0800 Subject: [PATCH] chore: build --- packages/uni-app-plus/dist/index.v3.js | 30 +++++++++++++------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/packages/uni-app-plus/dist/index.v3.js b/packages/uni-app-plus/dist/index.v3.js index a01ca23ebf..c14de8a507 100644 --- a/packages/uni-app-plus/dist/index.v3.js +++ b/packages/uni-app-plus/dist/index.v3.js @@ -7633,21 +7633,21 @@ var serviceContext = (function () { function useWebviewThemeChange (webview, getWebviewStyle) { if (__uniConfig.darkmode) { const fn = () => { - const { - animationAlphaBGColor, background, - backgroundColorBottom, backgroundColorTop, - titleNView: { backgroundColor, titleColor } = {} - } = getWebviewStyle(); - webview && webview.setStyle({ - animationAlphaBGColor, - background, - backgroundColorBottom, - backgroundColorTop, - titleNView: { - backgroundColor, - titleColor - } - }); + const webviewStyle = getWebviewStyle(); + const style = { + animationAlphaBGColor: webviewStyle.animationAlphaBGColor, + background: webviewStyle.background, + backgroundColorBottom: webviewStyle.backgroundColorBottom, + backgroundColorTop: webviewStyle.backgroundColorTop + }; + var titleNView = webviewStyle.titleNView; + if (typeof titleNView !== 'undefined') { + style.titleNView = typeof titleNView === 'object' ? { + backgroundColor: titleNView.backgroundColor, + titleColor: titleNView.titleColor + } : titleNView; + } + webview && webview.setStyle(webviewStyle); }; onThemeChange(fn); webview.addEventListener('close', () => offThemeChange(fn)); -- GitLab