Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
DCloud
uni-app
提交
f115e148
U
uni-app
项目概览
DCloud
/
uni-app
3 个月 前同步成功
通知
775
Star
38709
Fork
3642
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
8
列表
看板
标记
里程碑
合并请求
1
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
U
uni-app
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
8
Issue
8
列表
看板
标记
里程碑
合并请求
1
合并请求
1
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
提交
f115e148
编写于
2年前
作者:
Q
qiang
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
chore: build
上级
f52b7959
变更
13
隐藏空白更改
内联
并排
Showing
13 changed file
with
62 addition
and
30 deletion
+62
-30
packages/uni-app-plus/dist/uni.runtime.esm.js
packages/uni-app-plus/dist/uni.runtime.esm.js
+6
-5
packages/uni-cloud/lib/uni.plugin.js
packages/uni-cloud/lib/uni.plugin.js
+3
-0
packages/uni-h5/dist/uni-h5.cjs.js
packages/uni-h5/dist/uni-h5.cjs.js
+28
-1
packages/uni-h5/dist/uni-h5.es.js
packages/uni-h5/dist/uni-h5.es.js
+16
-16
packages/uni-mp-alipay/dist/uni.api.esm.js
packages/uni-mp-alipay/dist/uni.api.esm.js
+1
-1
packages/uni-mp-baidu/dist/uni.api.esm.js
packages/uni-mp-baidu/dist/uni.api.esm.js
+1
-1
packages/uni-mp-kuaishou/dist/uni.api.esm.js
packages/uni-mp-kuaishou/dist/uni.api.esm.js
+1
-1
packages/uni-mp-lark/dist/uni.api.esm.js
packages/uni-mp-lark/dist/uni.api.esm.js
+1
-1
packages/uni-mp-qq/dist/uni.api.esm.js
packages/uni-mp-qq/dist/uni.api.esm.js
+1
-1
packages/uni-mp-toutiao/dist/uni.api.esm.js
packages/uni-mp-toutiao/dist/uni.api.esm.js
+1
-1
packages/uni-mp-weixin/dist/uni.api.esm.js
packages/uni-mp-weixin/dist/uni.api.esm.js
+1
-1
packages/uni-mp-weixin/dist/uni.compiler.js
packages/uni-mp-weixin/dist/uni.compiler.js
+1
-0
packages/uni-quickapp-webview/dist/uni.api.esm.js
packages/uni-quickapp-webview/dist/uni.api.esm.js
+1
-1
未找到文件。
packages/uni-app-plus/dist/uni.runtime.esm.js
浏览文件 @
f115e148
...
@@ -13374,11 +13374,15 @@ function weexGetSystemInfoSync() {
...
@@ -13374,11 +13374,15 @@ function weexGetSystemInfoSync() {
}
}
const getDeviceInfo = defineSyncApi('getDeviceInfo', () => {
const getDeviceInfo = defineSyncApi('getDeviceInfo', () => {
weexGetSystemInfoSync();
weexGetSystemInfoSync();
const { deviceBrand, deviceModel, osName, osVersion } = systemInfo;
const { deviceBrand, deviceModel, osName, osVersion
, deviceOrientation, deviceType,
} = systemInfo;
const brand = deviceBrand.toLowerCase();
const brand = deviceBrand.toLowerCase();
return {
return {
deviceBrand: brand,
deviceBrand: brand,
deviceModel,
deviceModel,
devicePixelRatio: plus.screen.scale,
deviceId: deviceId$1(),
deviceOrientation,
deviceType,
brand,
brand,
model: deviceModel,
model: deviceModel,
system: `${osName === 'ios' ? 'iOS' : 'Android'} ${osVersion}`,
system: `${osName === 'ios' ? 'iOS' : 'Android'} ${osVersion}`,
...
@@ -13417,15 +13421,12 @@ const getSystemInfoSync = defineSyncApi('getSystemInfoSync', () => {
...
@@ -13417,15 +13421,12 @@ const getSystemInfoSync = defineSyncApi('getSystemInfoSync', () => {
const appBaseInfo = getAppBaseInfo();
const appBaseInfo = getAppBaseInfo();
_initSystemInfo = true;
_initSystemInfo = true;
const { osName, osLanguage, osVersion } = systemInfo;
const { osName, osLanguage, osVersion } = systemInfo;
const { pixelRatio } = windowInfo;
const osLanguageSplit = osLanguage.split('-');
const osLanguageSplit = osLanguage.split('-');
const osLanguageSplitLast = osLanguageSplit[osLanguageSplit.length - 1];
const osLanguageSplitLast = osLanguageSplit[osLanguageSplit.length - 1];
let _osLanguage = `${osLanguageSplit[0]}${osLanguageSplitLast ? '-' + osLanguageSplitLast : ''}`;
let _osLanguage = `${osLanguageSplit[0]}${osLanguageSplitLast ? '-' + osLanguageSplitLast : ''}`;
let extraData = {
let extraData = {
errMsg: 'getSystemInfo:ok',
errMsg: 'getSystemInfo:ok',
fontSizeSetting: appBaseInfo.hostFontSizeSetting,
fontSizeSetting: appBaseInfo.hostFontSizeSetting,
devicePixelRatio: pixelRatio,
deviceId: deviceId$1(),
uniCompileVersion: __uniConfig.compilerVersion,
uniCompileVersion: __uniConfig.compilerVersion,
uniRuntimeVersion: __uniConfig.compilerVersion,
uniRuntimeVersion: __uniConfig.compilerVersion,
osLanguage: _osLanguage,
osLanguage: _osLanguage,
...
@@ -13434,7 +13435,7 @@ const getSystemInfoSync = defineSyncApi('getSystemInfoSync', () => {
...
@@ -13434,7 +13435,7 @@ const getSystemInfoSync = defineSyncApi('getSystemInfoSync', () => {
extraData.romName = osName;
extraData.romName = osName;
extraData.romVersion = osVersion;
extraData.romVersion = osVersion;
}
}
const _systemInfo = extend(
windowInfo, system
Info, deviceInfo, appBaseInfo, extraData);
const _systemInfo = extend(
systemInfo, window
Info, deviceInfo, appBaseInfo, extraData);
delete _systemInfo.screenTop;
delete _systemInfo.screenTop;
delete _systemInfo.enableDebug;
delete _systemInfo.enableDebug;
delete _systemInfo.theme;
delete _systemInfo.theme;
...
...
This diff is collapsed.
Click to expand it.
packages/uni-cloud/lib/uni.plugin.js
浏览文件 @
f115e148
...
@@ -71,6 +71,9 @@ function initUniCloudEnv() {
...
@@ -71,6 +71,9 @@ function initUniCloudEnv() {
}
}
spaces
.
forEach
((
s
)
=>
uniCloudSpaces
.
push
(
s
));
spaces
.
forEach
((
s
)
=>
uniCloudSpaces
.
push
(
s
));
process
.
env
.
UNI_CLOUD_PROVIDER
=
JSON
.
stringify
(
uniCloudSpaces
.
map
((
space
)
=>
{
process
.
env
.
UNI_CLOUD_PROVIDER
=
JSON
.
stringify
(
uniCloudSpaces
.
map
((
space
)
=>
{
if
(
space
.
provider
===
'
tcb
'
)
{
space
.
provider
=
'
tencent
'
;
}
if
(
space
.
clientSecret
)
{
if
(
space
.
clientSecret
)
{
return
{
return
{
provider
:
space
.
provider
||
'
aliyun
'
,
provider
:
space
.
provider
||
'
aliyun
'
,
...
...
This diff is collapsed.
Click to expand it.
packages/uni-h5/dist/uni-h5.cjs.js
浏览文件 @
f115e148
...
@@ -10021,6 +10021,20 @@ const getStorageInfoSync = /* @__PURE__ */ defineSyncApi("getStorageInfoSync", (
...
@@ -10021,6 +10021,20 @@ const getStorageInfoSync = /* @__PURE__ */ defineSyncApi("getStorageInfoSync", (
const
getStorageInfo
=
/* @__PURE__ */
defineAsyncApi
(
"
getStorageInfo
"
,
(
_
,
{
resolve
})
=>
{
const
getStorageInfo
=
/* @__PURE__ */
defineAsyncApi
(
"
getStorageInfo
"
,
(
_
,
{
resolve
})
=>
{
resolve
(
getStorageInfoSync
());
resolve
(
getStorageInfoSync
());
});
});
const
UUID_KEY
=
"
__DC_STAT_UUID
"
;
const
storage
=
window
.
localStorage
||
window
.
sessionStorage
||
{};
let
deviceId
;
function
deviceId$1
()
{
deviceId
=
deviceId
||
storage
[
UUID_KEY
];
if
(
!
deviceId
)
{
deviceId
=
Date
.
now
()
+
""
+
Math
.
floor
(
Math
.
random
()
*
1
e7
);
try
{
storage
[
UUID_KEY
]
=
deviceId
;
}
catch
(
error
)
{
}
}
return
deviceId
;
}
let
browserInfo
;
let
browserInfo
;
function
initBrowserInfo
()
{
function
initBrowserInfo
()
{
{
{
...
@@ -10029,10 +10043,23 @@ function initBrowserInfo() {
...
@@ -10029,10 +10043,23 @@ function initBrowserInfo() {
}
}
const
getDeviceInfo
=
/* @__PURE__ */
defineSyncApi
(
"
getDeviceInfo
"
,
()
=>
{
const
getDeviceInfo
=
/* @__PURE__ */
defineSyncApi
(
"
getDeviceInfo
"
,
()
=>
{
initBrowserInfo
();
initBrowserInfo
();
const
{
deviceBrand
,
deviceModel
,
brand
,
model
,
platform
,
system
}
=
browserInfo
;
const
{
deviceBrand
,
deviceModel
,
brand
,
model
,
platform
,
system
,
deviceOrientation
,
deviceType
}
=
browserInfo
;
return
{
return
{
deviceBrand
,
deviceBrand
,
deviceModel
,
deviceModel
,
devicePixelRatio
:
window
.
devicePixelRatio
,
deviceId
:
deviceId$1
(),
deviceOrientation
,
deviceType
,
brand
,
brand
,
model
,
model
,
system
,
system
,
...
...
This diff is collapsed.
Click to expand it.
packages/uni-h5/dist/uni-h5.es.js
浏览文件 @
f115e148
...
@@ -16417,7 +16417,7 @@ function getBrowserInfo() {
...
@@ -16417,7 +16417,7 @@ function getBrowserInfo() {
osversion += ` x${framework[1]}`;
osversion += ` x${framework[1]}`;
}
}
} else if (isMac) {
} else if (isMac) {
osname = "
Mac
";
osname = "
macOS
";
const _osversion = osversionFind && osversionFind.match(/Mac OS X (.+)/) || "";
const _osversion = osversionFind && osversionFind.match(/Mac OS X (.+)/) || "";
if (osversion) {
if (osversion) {
osversion = _osversion[1].replace(/_/g, ".");
osversion = _osversion[1].replace(/_/g, ".");
...
@@ -16532,10 +16532,23 @@ function initBrowserInfo() {
...
@@ -16532,10 +16532,23 @@ function initBrowserInfo() {
}
}
const getDeviceInfo = /* @__PURE__ */ defineSyncApi("getDeviceInfo", () => {
const getDeviceInfo = /* @__PURE__ */ defineSyncApi("getDeviceInfo", () => {
initBrowserInfo();
initBrowserInfo();
const { deviceBrand, deviceModel, brand, model, platform, system } = browserInfo;
const {
deviceBrand,
deviceModel,
brand,
model,
platform,
system,
deviceOrientation,
deviceType
} = browserInfo;
return {
return {
deviceBrand,
deviceBrand,
deviceModel,
deviceModel,
devicePixelRatio: window.devicePixelRatio,
deviceId: deviceId$1(),
deviceOrientation,
deviceType,
brand,
brand,
model,
model,
system,
system,
...
@@ -16573,24 +16586,11 @@ const getSystemInfoSync = /* @__PURE__ */ defineSyncApi("getSystemInfoSync", ()
...
@@ -16573,24 +16586,11 @@ const getSystemInfoSync = /* @__PURE__ */ defineSyncApi("getSystemInfoSync", ()
const deviceInfo = getDeviceInfo();
const deviceInfo = getDeviceInfo();
const appBaseInfo = getAppBaseInfo();
const appBaseInfo = getAppBaseInfo();
_initBrowserInfo = true;
_initBrowserInfo = true;
const {
const { ua: ua2, browserName, browseVersion, osname, osversion } = browserInfo;
ua: ua2,
deviceType,
browserName,
browseVersion,
osname,
osversion,
deviceOrientation
} = browserInfo;
const { pixelRatio: pixelRatio2 } = windowInfo;
const systemInfo = extend(windowInfo, deviceInfo, appBaseInfo, {
const systemInfo = extend(windowInfo, deviceInfo, appBaseInfo, {
ua: ua2,
ua: ua2,
deviceType,
browserName,
browserName,
browseVersion,
browseVersion,
deviceId: deviceId$1(),
devicePixelRatio: pixelRatio2,
deviceOrientation,
uniPlatform: "web",
uniPlatform: "web",
uniCompileVersion: __uniConfig.compilerVersion,
uniCompileVersion: __uniConfig.compilerVersion,
uniRuntimeVersion: __uniConfig.compilerVersion,
uniRuntimeVersion: __uniConfig.compilerVersion,
...
...
This diff is collapsed.
Click to expand it.
packages/uni-mp-alipay/dist/uni.api.esm.js
浏览文件 @
f115e148
...
@@ -961,7 +961,7 @@ function populateParameters(fromRes, toRes) {
...
@@ -961,7 +961,7 @@ function populateParameters(fromRes, toRes) {
osVersion
,
osVersion
,
hostTheme
:
theme
,
hostTheme
:
theme
,
hostVersion
,
hostVersion
,
hostLanguage
:
language
.
split
(
'
_
'
,
'
-
'
),
hostLanguage
:
language
.
replace
(
'
_
'
,
'
-
'
),
hostName
:
_hostName
,
hostName
:
_hostName
,
hostSDKVersion
:
_SDKVersion
,
hostSDKVersion
:
_SDKVersion
,
hostFontSizeSetting
:
fontSizeSetting
,
hostFontSizeSetting
:
fontSizeSetting
,
...
...
This diff is collapsed.
Click to expand it.
packages/uni-mp-baidu/dist/uni.api.esm.js
浏览文件 @
f115e148
...
@@ -954,7 +954,7 @@ function populateParameters(fromRes, toRes) {
...
@@ -954,7 +954,7 @@ function populateParameters(fromRes, toRes) {
osVersion
,
osVersion
,
hostTheme
:
theme
,
hostTheme
:
theme
,
hostVersion
,
hostVersion
,
hostLanguage
:
language
.
split
(
'
_
'
,
'
-
'
),
hostLanguage
:
language
.
replace
(
'
_
'
,
'
-
'
),
hostName
:
_hostName
,
hostName
:
_hostName
,
hostSDKVersion
:
_SDKVersion
,
hostSDKVersion
:
_SDKVersion
,
hostFontSizeSetting
:
fontSizeSetting
,
hostFontSizeSetting
:
fontSizeSetting
,
...
...
This diff is collapsed.
Click to expand it.
packages/uni-mp-kuaishou/dist/uni.api.esm.js
浏览文件 @
f115e148
...
@@ -960,7 +960,7 @@ function populateParameters(fromRes, toRes) {
...
@@ -960,7 +960,7 @@ function populateParameters(fromRes, toRes) {
osVersion
,
osVersion
,
hostTheme
:
theme
,
hostTheme
:
theme
,
hostVersion
,
hostVersion
,
hostLanguage
:
language
.
split
(
'
_
'
,
'
-
'
),
hostLanguage
:
language
.
replace
(
'
_
'
,
'
-
'
),
hostName
:
_hostName
,
hostName
:
_hostName
,
hostSDKVersion
:
_SDKVersion
,
hostSDKVersion
:
_SDKVersion
,
hostFontSizeSetting
:
fontSizeSetting
,
hostFontSizeSetting
:
fontSizeSetting
,
...
...
This diff is collapsed.
Click to expand it.
packages/uni-mp-lark/dist/uni.api.esm.js
浏览文件 @
f115e148
...
@@ -948,7 +948,7 @@ function populateParameters(fromRes, toRes) {
...
@@ -948,7 +948,7 @@ function populateParameters(fromRes, toRes) {
osVersion
,
osVersion
,
hostTheme
:
theme
,
hostTheme
:
theme
,
hostVersion
,
hostVersion
,
hostLanguage
:
language
.
split
(
'
_
'
,
'
-
'
),
hostLanguage
:
language
.
replace
(
'
_
'
,
'
-
'
),
hostName
:
_hostName
,
hostName
:
_hostName
,
hostSDKVersion
:
_SDKVersion
,
hostSDKVersion
:
_SDKVersion
,
hostFontSizeSetting
:
fontSizeSetting
,
hostFontSizeSetting
:
fontSizeSetting
,
...
...
This diff is collapsed.
Click to expand it.
packages/uni-mp-qq/dist/uni.api.esm.js
浏览文件 @
f115e148
...
@@ -958,7 +958,7 @@ function populateParameters(fromRes, toRes) {
...
@@ -958,7 +958,7 @@ function populateParameters(fromRes, toRes) {
osVersion
,
osVersion
,
hostTheme
:
theme
,
hostTheme
:
theme
,
hostVersion
,
hostVersion
,
hostLanguage
:
language
.
split
(
'
_
'
,
'
-
'
),
hostLanguage
:
language
.
replace
(
'
_
'
,
'
-
'
),
hostName
:
_hostName
,
hostName
:
_hostName
,
hostSDKVersion
:
_SDKVersion
,
hostSDKVersion
:
_SDKVersion
,
hostFontSizeSetting
:
fontSizeSetting
,
hostFontSizeSetting
:
fontSizeSetting
,
...
...
This diff is collapsed.
Click to expand it.
packages/uni-mp-toutiao/dist/uni.api.esm.js
浏览文件 @
f115e148
...
@@ -948,7 +948,7 @@ function populateParameters(fromRes, toRes) {
...
@@ -948,7 +948,7 @@ function populateParameters(fromRes, toRes) {
osVersion
,
osVersion
,
hostTheme
:
theme
,
hostTheme
:
theme
,
hostVersion
,
hostVersion
,
hostLanguage
:
language
.
split
(
'
_
'
,
'
-
'
),
hostLanguage
:
language
.
replace
(
'
_
'
,
'
-
'
),
hostName
:
_hostName
,
hostName
:
_hostName
,
hostSDKVersion
:
_SDKVersion
,
hostSDKVersion
:
_SDKVersion
,
hostFontSizeSetting
:
fontSizeSetting
,
hostFontSizeSetting
:
fontSizeSetting
,
...
...
This diff is collapsed.
Click to expand it.
packages/uni-mp-weixin/dist/uni.api.esm.js
浏览文件 @
f115e148
...
@@ -929,7 +929,7 @@ function populateParameters(fromRes, toRes) {
...
@@ -929,7 +929,7 @@ function populateParameters(fromRes, toRes) {
osVersion
,
osVersion
,
hostTheme
:
theme
,
hostTheme
:
theme
,
hostVersion
,
hostVersion
,
hostLanguage
:
language
.
split
(
'
_
'
,
'
-
'
),
hostLanguage
:
language
.
replace
(
'
_
'
,
'
-
'
),
hostName
:
_hostName
,
hostName
:
_hostName
,
hostSDKVersion
:
_SDKVersion
,
hostSDKVersion
:
_SDKVersion
,
hostFontSizeSetting
:
fontSizeSetting
,
hostFontSizeSetting
:
fontSizeSetting
,
...
...
This diff is collapsed.
Click to expand it.
packages/uni-mp-weixin/dist/uni.compiler.js
浏览文件 @
f115e148
...
@@ -116,6 +116,7 @@ const customElements = [
...
@@ -116,6 +116,7 @@ const customElements = [
'
page-meta
'
,
'
page-meta
'
,
'
navigation-bar
'
,
'
navigation-bar
'
,
'
match-media
'
,
'
match-media
'
,
'
ad-custom
'
,
];
];
const
compilerOptions
=
{
const
compilerOptions
=
{
nodeTransforms
:
[
uniCliShared
.
transformRef
,
uniCliShared
.
transformComponentLink
,
transformAd
],
nodeTransforms
:
[
uniCliShared
.
transformRef
,
uniCliShared
.
transformComponentLink
,
transformAd
],
...
...
This diff is collapsed.
Click to expand it.
packages/uni-quickapp-webview/dist/uni.api.esm.js
浏览文件 @
f115e148
...
@@ -957,7 +957,7 @@ function populateParameters(fromRes, toRes) {
...
@@ -957,7 +957,7 @@ function populateParameters(fromRes, toRes) {
osVersion
,
osVersion
,
hostTheme
:
theme
,
hostTheme
:
theme
,
hostVersion
,
hostVersion
,
hostLanguage
:
language
.
split
(
'
_
'
,
'
-
'
),
hostLanguage
:
language
.
replace
(
'
_
'
,
'
-
'
),
hostName
:
_hostName
,
hostName
:
_hostName
,
hostSDKVersion
:
_SDKVersion
,
hostSDKVersion
:
_SDKVersion
,
hostFontSizeSetting
:
fontSizeSetting
,
hostFontSizeSetting
:
fontSizeSetting
,
...
...
This diff is collapsed.
Click to expand it.
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录
新手
引导
客服
返回
顶部