diff --git a/src/core/helpers/hidpi.js b/src/core/helpers/hidpi.js index fb678dde839d33959f1c228a5c720c9bc75988c4..09fecb39c1c40d1e066e9e1fa5d5eb6eb531a462 100644 --- a/src/core/helpers/hidpi.js +++ b/src/core/helpers/hidpi.js @@ -1,7 +1,7 @@ import { hasOwn } -from 'uni-shared' + from 'uni-shared' export const pixelRatio = (function () { const canvas = document.createElement('canvas') diff --git a/src/core/runtime/mp/polyfill/state/proxy.js b/src/core/runtime/mp/polyfill/state/proxy.js index c82d373316e334e72551d9f52e617cec07abb2f3..8f73532cef7cb81b54764e31e8530f7ce6ec7a2a 100644 --- a/src/core/runtime/mp/polyfill/state/proxy.js +++ b/src/core/runtime/mp/polyfill/state/proxy.js @@ -1,7 +1,7 @@ import { noop } -from 'uni-shared' + from 'uni-shared' const sharedPropertyDefinition = { enumerable: true, diff --git a/src/platforms/app-plus/service/framework/plugins/lifecycle.js b/src/platforms/app-plus/service/framework/plugins/lifecycle.js index 3d96af07295c772453cfc16d92f5406ee903953f..0cb29efb02cd585b6d7ae2068edc48ce4c64d8bb 100644 --- a/src/platforms/app-plus/service/framework/plugins/lifecycle.js +++ b/src/platforms/app-plus/service/framework/plugins/lifecycle.js @@ -14,7 +14,7 @@ import { import { lifecycleMixin } -from 'uni-core/service/plugins/lifecycle' + from 'uni-core/service/plugins/lifecycle' import { VD_SYNC_VERSION @@ -23,7 +23,7 @@ import { import { ON_REACH_BOTTOM_DISTANCE } -from '../../constants' + from '../../constants' import { NAVBAR_HEIGHT diff --git a/src/platforms/h5/service/index.js b/src/platforms/h5/service/index.js index f7c67a80dab35d7f75d359d7758e2d18c3fa5702..d4343add2b4d323136fe59c10af92622a1dcd56d 100644 --- a/src/platforms/h5/service/index.js +++ b/src/platforms/h5/service/index.js @@ -9,7 +9,7 @@ import { getApp, getCurrentPages } -from 'uni-core/service/plugins/app' + from 'uni-core/service/plugins/app' initOn(UniServiceJSBridge.on, { getApp, diff --git a/src/shared/color.js b/src/shared/color.js index fb2d2168dec73310853743b7b30b23e748586a8f..93fd113a8e404921ba4e7dd6045714a688a506bd 100644 --- a/src/shared/color.js +++ b/src/shared/color.js @@ -8,14 +8,14 @@ a: number; } */ -export function hexToRgba(hex) { +export function hexToRgba (hex) { // 异常情况 if (!hex) { return { r: 0, g: 0, b: 0, - a: 0, + a: 0 } } // 去掉 # @@ -27,7 +27,7 @@ export function hexToRgba(hex) { r: 0, g: 0, b: 0, - a: 0, + a: 0 } } // 格式化 tmpHex,使其变成 rrggbb 或 rrggbbaa @@ -36,9 +36,9 @@ export function hexToRgba(hex) { tmpHex = tmpHex.replace(/(\w{1})/g, '$1$1') } // rgba - let [sr, sg, sb, sa] = tmpHex.match(/(\w{2})/g) + const [sr, sg, sb, sa] = tmpHex.match(/(\w{2})/g) // rgb - const r = parseInt(sr, 16), g = parseInt(sg, 16), b = parseInt(sb, 16) + const r = parseInt(sr, 16); const g = parseInt(sg, 16); const b = parseInt(sb, 16) if (!sa) { return { r, g, b, a: 1 }