提交 524ab7d4 编写于 作者: zhaofengliang920817's avatar zhaofengliang920817

Merge branch 'dev' into dev-share

...@@ -49,15 +49,15 @@ ...@@ -49,15 +49,15 @@
// 统计上报 - 应用启动 // 统计上报 - 应用启动
// #ifdef APP-ANDROID || APP-IOS || WEB // #ifdef APP-ANDROID || APP-IOS || WEB
uni.report({ // uni.report({
name: 'uni-app-launch', // name: 'uni-app-launch',
options: res, // options: res,
success(res_data) { // success(res_data) {
console.log(res_data); // console.log(res_data);
}, fail(err) { // }, fail(err) {
console.log(err); // console.log(err);
} // }
}) // })
// #endif // #endif
// #ifdef APP // #ifdef APP
if (process.env.NODE_ENV !== 'development') { //真机运行可以注释此条件 if (process.env.NODE_ENV !== 'development') { //真机运行可以注释此条件
...@@ -90,14 +90,14 @@ ...@@ -90,14 +90,14 @@
// #ifdef APP-ANDROID || APP-IOS || WEB // #ifdef APP-ANDROID || APP-IOS || WEB
// 统计上报 - 应用显示 // 统计上报 - 应用显示
uni.report({ // uni.report({
name: 'uni-app-show', // name: 'uni-app-show',
success(res_data) { // success(res_data) {
console.log(res_data); // console.log(res_data);
}, fail(err) { // }, fail(err) {
console.log(err); // console.log(err);
} // }
}) // })
// #endif // #endif
}, },
onHide: function () { onHide: function () {
...@@ -107,14 +107,14 @@ ...@@ -107,14 +107,14 @@
// #ifdef APP-ANDROID || APP-IOS || WEB // #ifdef APP-ANDROID || APP-IOS || WEB
// 统计上报 - 应用进入后台 // 统计上报 - 应用进入后台
uni.report({ // uni.report({
name: 'uni-app-hide', // name: 'uni-app-hide',
success(res) { // success(res) {
console.log(res); // console.log(res);
}, fail(err) { // }, fail(err) {
console.log(err); // console.log(err);
} // }
}) // })
// #endif // #endif
}, },
// #ifdef APP-ANDROID // #ifdef APP-ANDROID
...@@ -139,20 +139,20 @@ ...@@ -139,20 +139,20 @@
onExit() { onExit() {
console.log('App Exit') console.log('App Exit')
}, },
onError(err : any) { // onError(err : any) {
// #ifdef APP-ANDROID || APP-IOS || WEB // // #ifdef APP-ANDROID || APP-IOS || WEB
// 统计上报 - 应用发生错误 // // 统计上报 - 应用发生错误
uni.report({ // uni.report({
name: 'uni-app-error', // name: 'uni-app-error',
options: err, // options: err,
success(res) { // success(res) {
console.log(res); // console.log(res);
}, fail(err) { // }, fail(err) {
console.log(err); // console.log(err);
} // }
}) // })
// #endif // // #endif
}, // },
// #endif // #endif
methods: { methods: {
increasetLifeCycleNum() { increasetLifeCycleNum() {
......
// 仅测试 console.log 时机问题 // 仅测试 console.log 时机问题
import './test-main-console.uts' import './test-main-console.uts'
// #ifdef APP-ANDROID || APP-IOS || WEB // #ifdef APP-ANDROID || APP-IOS || WEB
import { uniStat } from '@/uni_modules/uni-stat/plugin.uts' // import { uniStat } from '@/uni_modules/uni-stat/plugin.uts'
// #endif // #endif
import App from './App.uvue' import App from './App.uvue'
import { createSSRApp } from 'vue' import { createSSRApp } from 'vue'
// 统计配置 // // 统计配置
const collectItems = { // const collectItems = {
uniStatPageLog: true // uniStatPageLog: true
} // }
const statOptions = { // const statOptions = {
debug: false, // debug: false,
collectItems: collectItems, // collectItems: collectItems,
} // }
export function createApp() { export function createApp() {
const app = createSSRApp(App) const app = createSSRApp(App)
// #ifdef APP-ANDROID || APP-IOS || WEB // // #ifdef APP-ANDROID || APP-IOS || WEB
app.use(uniStat, statOptions) // app.use(uniStat, statOptions)
// #endif // // #endif
// app.mixin({ // app.mixin({
// onReady() { // onReady() {
// setTimeout(() => { // setTimeout(() => {
......
...@@ -2,8 +2,8 @@ ...@@ -2,8 +2,8 @@
"name": "Hello uni-app x", "name": "Hello uni-app x",
"appid": "__UNI__HelloUniAppX", "appid": "__UNI__HelloUniAppX",
"description": "", "description": "",
"versionName": "1.6", "versionName": "1.6.3",
"versionCode": 10600, "versionCode": 10603,
"uni-app-x": {}, "uni-app-x": {},
/* 快应用特有相关 */ /* 快应用特有相关 */
"quickapp": {}, "quickapp": {},
......
此差异已折叠。
...@@ -6,6 +6,13 @@ const FIRST_PAGE_PATH = '/pages/API/dialog-page/dialog-page' ...@@ -6,6 +6,13 @@ const FIRST_PAGE_PATH = '/pages/API/dialog-page/dialog-page'
const NEXT_PAGE_PATH = '/pages/API/dialog-page/next-page' const NEXT_PAGE_PATH = '/pages/API/dialog-page/next-page'
describe('dialog page', () => { describe('dialog page', () => {
if (process.env.UNI_AUTOMATOR_APP_WEBVIEW == 'true') {
it('skip app-webview', () => {
expect(1).toBe(1)
})
return
}
let page; let page;
let initLifeCycleNum; let initLifeCycleNum;
let lifecycleNum; let lifecycleNum;
......
...@@ -90,6 +90,7 @@ ...@@ -90,6 +90,7 @@
url: '/pages/API/dialog-page/dialog-1?name=dialog1', url: '/pages/API/dialog-page/dialog-1?name=dialog1',
success(res) { success(res) {
console.log('openDialogPage1ToHomePage success', res) console.log('openDialogPage1ToHomePage success', res)
uni.showToast({title: '在首页打开了 dialogPage'})
}, },
fail(err) { fail(err) {
console.log('openDialogPage1ToHomePage fail', err) console.log('openDialogPage1ToHomePage fail', err)
......
...@@ -15,6 +15,9 @@ ...@@ -15,6 +15,9 @@
<button class="privacy-button" type="primary" @tap="resetPrivacyAuthorization"> <button class="privacy-button" type="primary" @tap="resetPrivacyAuthorization">
重置隐私协议授权状态 重置隐私协议授权状态
</button> </button>
<button class="privacy-button" @tap="openPrivacyDialog">
显示隐私政策弹框
</button>
</view> </view>
</view> </view>
</template> </template>
...@@ -63,6 +66,11 @@ ...@@ -63,6 +66,11 @@
}, },
resetPrivacyAuthorization(){ resetPrivacyAuthorization(){
uni.resetPrivacyAuthorization() uni.resetPrivacyAuthorization()
},
openPrivacyDialog(){
uni.openDialogPage({
url: '/pages/component/button/privacy',
})
} }
} }
} }
......
...@@ -39,6 +39,11 @@ ...@@ -39,6 +39,11 @@
url: 'buttonstatus', url: 'buttonstatus',
}) })
}, },
openPrivacyDialog() {
uni.openDialogPage({
url: '/pages/component/button/privacy',
})
},
//用于自动化测试 //用于自动化测试
checkUniButtonElement() : boolean { checkUniButtonElement() : boolean {
const button = uni.getElementById("testButton") const button = uni.getElementById("testButton")
...@@ -71,7 +76,10 @@ ...@@ -71,7 +76,10 @@
<enum-data :items="type_enum" title="按钮的类型" @change="radio_change_type_enum"></enum-data> <enum-data :items="type_enum" title="按钮的类型" @change="radio_change_type_enum"></enum-data>
<input-data :defaultValue="text" title="按钮的文案" type="text" @confirm="confirm_text_input"></input-data> <input-data :defaultValue="text" title="按钮的文案" type="text" @confirm="confirm_text_input"></input-data>
<view style="height: 10px;"></view> <view style="height: 10px;"></view>
<button @click="openPrivacyDialog">open-type实现隐私政策弹框</button>
<view style="height: 10px;"></view>
<button @click="navigateToChild">更多示例</button> <button @click="navigateToChild">更多示例</button>
<view style="height: 10px;"></view>
</view> </view>
</scroll-view> </scroll-view>
</template> </template>
......
<template> <template>
<view class="dialog-container"> <view class="dialog-container">
<view class="dialog-content"> <view class="dialog-content">
<view style="width: 100%;justify-content: center;align-items: center;"> <view style="width: 100%;justify-content: center;align-items: center;background-color: #fff;">
<image src="../image/logo.png" style="margin-top: 25px;width: 60px;height: 60px;"></image> <image src="../image/logo.png" style="margin-top: 25px;width: 60px;height: 60px;"></image>
</view> </view>
<text style="text-align: center;margin-top: 20px;font-size: 20px;color: black;"> 个人信息保护指引</text> <text style="text-align: center;padding-top: 20px;font-size: 20px;color: black;background-color: #fff;"> 个人信息保护指引</text>
<scroll-view style="flex: 1;align-content: center;margin-top: 10px;margin-left: 25px;margin-right: 25px;" <scroll-view style="flex: 1;align-content: center;padding-top: 10px;padding-left: 25px;padding-right: 25px;background-color: #fff;"
show-scrollbar="false"> show-scrollbar="false">
<rich-text style="font-size: 14px;color: red;" :nodes="htmlString" @itemclick="itemClick"></rich-text> <rich-text style="font-size: 14px;color: red;" :nodes="htmlString" @itemclick="itemClick"></rich-text>
</scroll-view> </scroll-view>
...@@ -67,9 +67,9 @@ ...@@ -67,9 +67,9 @@
} }
.dialog-content { .dialog-content {
height: 43%; height: 60%;
width: 80%; width: 80%;
background-color: #fff; /* background-color: #fff; */
border-radius: 12px; border-radius: 12px;
} }
...@@ -80,10 +80,10 @@ ...@@ -80,10 +80,10 @@
.button { .button {
border: 0px; border: 0px;
border-radius: 0px; border-radius: 0px;
font-size: 20px; font-size: 15px;
color: lightgrey; color: lightgrey;
text-align: center; text-align: center;
line-height: 60px; line-height: 40px;
} }
.button-hover1 { .button-hover1 {
......
<template> <template>
<view> <view>
<text class="tips">说明:如果本地无 uts 插件编译环境请提交打包自定义基座查看效果</text>
<!-- native-button 通过 native-view 绑定原生button 实现的UTS插件-标准模式组件 -->
<native-button class="native-button" style="width: 200px; height: 100px;" :text="buttonText" @buttonTap="ontap" <native-button class="native-button" style="width: 200px; height: 100px;" :text="buttonText" @buttonTap="ontap"
@load="onload"></native-button> @load="onload"></native-button>
<!-- native-time-picker 通过 native-view 绑定原生time-picker 实现的UTS插件-标准模式组件 -->
<native-time-picker class="native-time-picker" :hour=2 :minute=3 @changed="onChanged"></native-time-picker> <native-time-picker class="native-time-picker" :hour=2 :minute=3 @changed="onChanged"></native-time-picker>
</view> </view>
</template> </template>
...@@ -39,6 +42,14 @@ ...@@ -39,6 +42,14 @@
</script> </script>
<style> <style>
.tips {
font-size: 14px;
color: #BEBEBE;
margin: 25px auto 25px auto;
text-align: center;
}
.native-button { .native-button {
height: 100px; height: 100px;
width: 100px; width: 100px;
......
...@@ -55,4 +55,12 @@ describe('rich-text-test', () => { ...@@ -55,4 +55,12 @@ describe('rich-text-test', () => {
}); });
}); });
it('rich-text parent click', async () => {
const element = await page.$('#rich-text-parent')
await element.tap()
await page.waitFor(500)
const element2 = await page.$('#rich-text-str')
expect(await element2.text()).toBe("true")
})
}) })
...@@ -16,9 +16,13 @@ ...@@ -16,9 +16,13 @@
<text class="uni-subtitle-text">selectable</text> <text class="uni-subtitle-text">selectable</text>
<button type="default" @click="changeText">修改文本内容</button> <button type="default" @click="changeText">修改文本内容</button>
</view> </view>
<view class="text-box"> <view class="text-box" id="rich-text-parent" @click="richTextParentClick">
<rich-text id="richtext" style="border: 1px; border-style: solid; border-color: red;" :selectable="true" <rich-text id="richtext" style="border: 1px; border-style: solid; border-color: red;" :selectable="true"
:nodes="text"></rich-text> :nodes="text"></rich-text>
<view>
<text>rich-text-parent</text>
<text id='rich-text-str'>{{richTextStr}}</text>
</view>
</view> </view>
</view> </view>
</view> </view>
...@@ -35,7 +39,8 @@ ...@@ -35,7 +39,8 @@
// 自动化测试 // 自动化测试
autoTest: false, autoTest: false,
testNodes: '<img src="https://qiniu-web-assets.dcloud.net.cn/unidoc/zh/uni@2x.png"></img>', testNodes: '<img src="https://qiniu-web-assets.dcloud.net.cn/unidoc/zh/uni@2x.png"></img>',
isItemClickTrigger: false isItemClickTrigger: false,
richTextStr: false
} }
}, },
onReady() { onReady() {
...@@ -71,6 +76,9 @@ ...@@ -71,6 +76,9 @@
}, },
getWindowInfoForTest() : GetWindowInfoResult { getWindowInfoForTest() : GetWindowInfoResult {
return uni.getWindowInfo(); return uni.getWindowInfo();
},
richTextParentClick() {
this.richTextStr = true;
} }
} }
} }
......
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
:http-cache="httpCache" :play-strategy="playStrategy" :danmu-list="danmuList" @play="onPlay" @pause="onPause" :http-cache="httpCache" :play-strategy="playStrategy" :danmu-list="danmuList" @play="onPlay" @pause="onPause"
@ended="onEnded" @timeupdate="onTimeUpdate" @waiting="onWaiting" @error="onError" @progress="onProgress" @ended="onEnded" @timeupdate="onTimeUpdate" @waiting="onWaiting" @error="onError" @progress="onProgress"
@fullscreenclick="onFullScreenClick" @controlstoggle="onControlsToggle" @fullscreenchange="onFullScreenChange"> @fullscreenclick="onFullScreenClick" @controlstoggle="onControlsToggle" @fullscreenchange="onFullScreenChange">
<!-- #ifdef APP-ANDROID --> <!-- #ifdef APP -->
<image v-if="subCompEnable && subCompShow" class="img-fast-backward" <image v-if="subCompEnable && subCompShow" class="img-fast-backward"
src="../../../static/test-video/fast-backward.png" @tap="fastBackward"></image> src="../../../static/test-video/fast-backward.png" @tap="fastBackward"></image>
<image v-if="subCompEnable && subCompShow" class="img-fast-forward" <image v-if="subCompEnable && subCompShow" class="img-fast-forward"
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
<button type="primary" @click="pause">视频格式示例</button> <button type="primary" @click="pause">视频格式示例</button>
</navigator> </navigator>
</view> </view>
<!-- #ifdef APP-ANDROID --> <!-- #ifdef APP -->
<view class="uni-flex uni-btn-v" style="justify-content: space-between;align-items: center;"> <view class="uni-flex uni-btn-v" style="justify-content: space-between;align-items: center;">
<text class="uni-title" style="width: 80%;">子组件实现快进、快退、发送弹幕功能(全屏后显示)</text> <text class="uni-title" style="width: 80%;">子组件实现快进、快退、发送弹幕功能(全屏后显示)</text>
<switch :checked="subCompEnable" @change="onSubCompEnableChange" /> <switch :checked="subCompEnable" @change="onSubCompEnableChange" />
......
...@@ -417,6 +417,6 @@ describe("page screenshot test", () => { ...@@ -417,6 +417,6 @@ describe("page screenshot test", () => {
return `__pages_test__/${currentPagePath.replace(/\//g, "-").substring(1)}` return `__pages_test__/${currentPagePath.replace(/\//g, "-").substring(1)}`
} }
}) })
await page.waitFor(500); await page.waitFor(800);
}); });
}); });
<template> <template>
<!-- #ifdef APP --> <!-- #ifdef APP -->
<scroll-view style="flex: 1; background-color: #f8f8f8" enable-back-to-top="true"> <scroll-view style="flex: 1;" enable-back-to-top="true">
<!-- #endif --> <!-- #endif -->
<view class="uni-container"> <view class="uni-container">
<view v-if="!hasLeftWin" class="uni-header-logo"> <view v-if="!hasLeftWin" class="uni-header-logo">
...@@ -79,11 +79,7 @@ ...@@ -79,11 +79,7 @@
goPage(url : string) { goPage(url : string) {
if (url == '/set-tab-bar') { if (url == '/set-tab-bar') {
this.showPop() this.showPop()
}else if (url == '/show-privacy-dialog') { }else {
uni.openDialogPage({
url: '/pages/component/button/privacy',
})
} else {
if (this.hasLeftWin) { if (this.hasLeftWin) {
uni.reLaunch({ url }) uni.reLaunch({ url })
} else { } else {
......
<template> <template>
<!-- #ifdef APP --> <!-- #ifdef APP -->
<scroll-view style="flex: 1; background-color: #f8f8f8" enable-back-to-top="true"> <scroll-view style="flex: 1;" enable-back-to-top="true">
<!-- #endif --> <!-- #endif -->
<view class="uni-container"> <view class="uni-container">
<view v-if="!hasLeftWin" class="uni-header-logo"> <view v-if="!hasLeftWin" class="uni-header-logo">
......
<template> <template>
<!-- #ifdef APP --> <!-- #ifdef APP -->
<scroll-view style="flex: 1; background-color: #f8f8f8" enable-back-to-top="true"> <scroll-view style="flex: 1;" enable-back-to-top="true">
<!-- #endif --> <!-- #endif -->
<view class="uni-container"> <view class="uni-container">
<view v-if="!hasLeftWin" class="uni-header-logo"> <view v-if="!hasLeftWin" class="uni-header-logo">
...@@ -113,7 +113,19 @@ ...@@ -113,7 +113,19 @@
// #endif // #endif
onReady() { onReady() {
// #ifdef UNI-APP-X && APP // #ifdef UNI-APP-X && APP
uni.getPrivacySetting({
success(res) {
if (res.needAuthorization) {
uni.onPrivacyAuthorizationChange((res) => {
if (!res.needAuthorization) {
checkUpdate(this.$refs['upgradePopup'] as UniUpgradeCenterAppComponentPublicInstance) checkUpdate(this.$refs['upgradePopup'] as UniUpgradeCenterAppComponentPublicInstance)
}
})
} else {
checkUpdate(this.$refs['upgradePopup'] as UniUpgradeCenterAppComponentPublicInstance)
}
}
})
// #endif // #endif
}, },
onShow() { onShow() {
......
...@@ -158,16 +158,5 @@ function addSetTabBarPage(menuItem : MenuItem) { ...@@ -158,16 +158,5 @@ function addSetTabBarPage(menuItem : MenuItem) {
group: null, group: null,
items: [] items: []
} as MenuItem) } as MenuItem)
menuItem.items.push({
id: 'show-privacy-dialog',
name: '隐私政策',
index: 0,
path: 'show-privacy-dialog',
style: {
navigationBarTitleText: '隐私政策弹框'
},
group: null,
items: []
} as MenuItem)
} }
} }
<template> <template>
<!-- #ifdef APP --> <!-- #ifdef APP -->
<scroll-view style="flex: 1; background-color: #f8f8f8" enable-back-to-top="true"> <scroll-view style="flex: 1;" enable-back-to-top="true">
<!-- #endif --> <!-- #endif -->
<view class="uni-container"> <view class="uni-container">
<view v-if="!hasLeftWin" class="uni-header-logo"> <view v-if="!hasLeftWin" class="uni-header-logo">
......
## 0.8.5(2024-10-26)
- 优化 去除不必要代码
## 0.8.4(2024-10-26)
- 修复 uni-app x 项目升级到 4.31 alpha 后中间有空隙的Bug
## 0.8.3(2024-07-31) ## 0.8.3(2024-07-31)
- 修复 部分类型报错 - 修复 部分类型报错
## 0.8.2(2024-07-15) ## 0.8.2(2024-07-15)
......
...@@ -8,6 +8,8 @@ ...@@ -8,6 +8,8 @@
src="/uni_modules/uni-upgrade-center-app/static/app/bg_top.png"></image> src="/uni_modules/uni-upgrade-center-app/static/app/bg_top.png"></image>
</view> </view>
<view class="content-space"></view>
<view class="content-body"> <view class="content-body">
<view class="content-body-title"> <view class="content-body-title">
<text class="text title">{{subTitle}}</text> <text class="text title">{{subTitle}}</text>
...@@ -372,6 +374,15 @@ ...@@ -372,6 +374,15 @@
border-bottom-style: solid; border-bottom-style: solid;
} }
.content-space {
width: 100%;
height: 50px;
background-color: #fff;
position: absolute;
top: 140px;
z-index: -1;
}
.content-top-image { .content-top-image {
width: 100%; width: 100%;
position: relative; position: relative;
......
{ {
"id": "uni-upgrade-center-app", "id": "uni-upgrade-center-app",
"displayName": "升级中心 uni-upgrade-center - App", "displayName": "升级中心 uni-upgrade-center - App",
"version": "0.8.3", "version": "0.8.5",
"description": "uni升级中心 - 客户端检查更新", "description": "uni升级中心 - 客户端检查更新",
"keywords": [ "keywords": [
"uniCloud", "uniCloud",
...@@ -48,7 +48,9 @@ ...@@ -48,7 +48,9 @@
"client": { "client": {
"App": { "App": {
"app-vue": "y", "app-vue": "y",
"app-nvue": "y" "app-nvue": "y",
"app-harmony": "u",
"app-uvue": "y"
}, },
"H5-mobile": { "H5-mobile": {
"Safari": "n", "Safari": "n",
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册