Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
黄粱一梦--Y
hello uni-app x
提交
add636fc
H
hello uni-app x
项目概览
黄粱一梦--Y
/
hello uni-app x
与 Fork 源项目一致
Fork自
DCloud / hello uni-app x
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
H
hello uni-app x
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
add636fc
编写于
7月 08, 2023
作者:
W
wanganxp
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
缩短了tabbar页面的层级,把api里的页面和界面分开。遗留页面生命周期和页面下拉刷新待完善
上级
e4667d08
变更
7
显示空白变更内容
内联
并排
Showing
7 changed file
with
1446 addition
and
1335 deletion
+1446
-1335
pages.json
pages.json
+585
-597
pages/API/modal/modal.uvue
pages/API/modal/modal.uvue
+1
-1
pages/API/page-lifecircle/page-lifecircle.uvue
pages/API/page-lifecircle/page-lifecircle.uvue
+40
-0
pages/API/pull-down-refresh/pull-down-refresh.uvue
pages/API/pull-down-refresh/pull-down-refresh.uvue
+83
-0
pages/tabBar/API.uvue
pages/tabBar/API.uvue
+475
-475
pages/tabBar/CSS.uvue
pages/tabBar/CSS.uvue
+2
-2
pages/tabBar/component.uvue
pages/tabBar/component.uvue
+260
-260
未找到文件。
pages.json
浏览文件 @
add636fc
{
{
"pages"
:
[
//pages数组中第一项表示应用启动页,参考:https://uniapp.dcloud.io/collocation/pages
"pages"
:
[
//pages数组中第一项表示应用启动页,参考:https://uniapp.dcloud.io/collocation/pages
{
{
"path"
:
"pages/tabBar/component
/component"
,
"path"
:
"pages/tabBar
/component"
,
"style"
:
{
"style"
:
{
"navigationBarTitleText"
:
"内置组件"
,
"navigationBarTitleText"
:
"内置组件"
,
"backgroundColor"
:
"#F8F8F8"
"backgroundColor"
:
"#F8F8F8"
...
@@ -128,7 +128,7 @@
...
@@ -128,7 +128,7 @@
}
}
},
},
{
{
"path"
:
"pages/tabBar/API
/API"
,
"path"
:
"pages/tabBar
/API"
,
"style"
:
{
"style"
:
{
"navigationBarTitleText"
:
"接口"
,
"navigationBarTitleText"
:
"接口"
,
"backgroundColor"
:
"#F8F8F8"
"backgroundColor"
:
"#F8F8F8"
...
@@ -151,6 +151,17 @@
...
@@ -151,6 +151,17 @@
"style"
:
{
"style"
:
{
"navigationBarTitleText"
:
"新UVUE页面2"
"navigationBarTitleText"
:
"新UVUE页面2"
}
}
},
{
"path"
:
"pages/API/page-scrollTo/page-scrollTo"
,
"style"
:
{
"navigationBarTitleText"
:
"页面滚动"
}
},
{
"path"
:
"pages/API/page-lifecircle/page-lifecircle"
,
"style"
:
{
"navigationBarTitleText"
:
"页面生命周期"
}
},
},
{
{
"path"
:
"pages/API/storage/storage"
,
"path"
:
"pages/API/storage/storage"
,
...
@@ -189,7 +200,7 @@
...
@@ -189,7 +200,7 @@
}
}
},
},
{
{
"path"
:
"pages/tabBar/CSS
/CSS"
,
"path"
:
"pages/tabBar
/CSS"
,
"style"
:
{
"style"
:
{
"navigationBarTitleText"
:
"CSS"
,
"navigationBarTitleText"
:
"CSS"
,
"backgroundColor"
:
"#F8F8F8"
"backgroundColor"
:
"#F8F8F8"
...
@@ -446,12 +457,12 @@
...
@@ -446,12 +457,12 @@
"style"
:
{
"style"
:
{
"navigationBarTitleText"
:
"text-decoration-line"
"navigationBarTitleText"
:
"text-decoration-line"
}
}
},
{
},
{
"path"
:
"pages/CSS/transition/transition"
,
"path"
:
"pages/CSS/transition/transition"
,
"style"
:
{
"style"
:
{
"navigationBarTitleText"
:
"Transition"
"navigationBarTitleText"
:
"Transition"
}
}
},
{
},
{
"path"
:
"pages/CSS/transform/transform"
,
"path"
:
"pages/CSS/transform/transform"
,
"style"
:
{
"style"
:
{
"navigationBarTitleText"
:
"Transform"
"navigationBarTitleText"
:
"Transform"
...
@@ -459,123 +470,100 @@
...
@@ -459,123 +470,100 @@
},
{
},
{
"path"
:
"pages/API/request/request"
,
"path"
:
"pages/API/request/request"
,
"style"
:
{
"style"
:
{
"navigationBarTitleText"
:
""
,
"navigationBarTitleText"
:
"request网络"
"enablePullDownRefresh"
:
false
}
}
},
{
},
{
"path"
:
"pages/API/upload-file/upload-file"
,
"path"
:
"pages/API/upload-file/upload-file"
,
"style"
:
{
"style"
:
{
"navigationBarTitleText"
:
""
,
"navigationBarTitleText"
:
"上传文件"
"enablePullDownRefresh"
:
false
}
}
},
{
},
{
"path"
:
"pages/API/download-file/download-file"
,
"path"
:
"pages/API/download-file/download-file"
,
"style"
:
{
"style"
:
{
"navigationBarTitleText"
:
""
,
"navigationBarTitleText"
:
"下载文件"
"enablePullDownRefresh"
:
false
}
}
},
{
},
{
"path"
:
"pages/API/websocket-socketTask/websocket-socketTask"
,
"path"
:
"pages/API/websocket-socketTask/websocket-socketTask"
,
"style"
:
{
"style"
:
{
"navigationBarTitleText"
:
""
,
"navigationBarTitleText"
:
""
"enablePullDownRefresh"
:
false
}
}
},
{
},
{
"path"
:
"pages/API/websocket-global/websocket-global"
,
"path"
:
"pages/API/websocket-global/websocket-global"
,
"style"
:
{
"style"
:
{
"navigationBarTitleText"
:
""
,
"navigationBarTitleText"
:
""
"enablePullDownRefresh"
:
false
}
}
},
{
},
{
"path"
:
"pages/API/get-system-info/get-system-info"
,
"path"
:
"pages/API/get-system-info/get-system-info"
,
"style"
:
{
"style"
:
{
"navigationBarTitleText"
:
""
,
"navigationBarTitleText"
:
""
"enablePullDownRefresh"
:
false
}
}
},
{
},
{
"path"
:
"pages/API/get-device-info/get-device-info"
,
"path"
:
"pages/API/get-device-info/get-device-info"
,
"style"
:
{
"style"
:
{
"navigationBarTitleText"
:
""
,
"navigationBarTitleText"
:
""
"enablePullDownRefresh"
:
false
}
}
},
{
},
{
"path"
:
"pages/API/get-app-base-info/get-app-base-info"
,
"path"
:
"pages/API/get-app-base-info/get-app-base-info"
,
"style"
:
{
"style"
:
{
"navigationBarTitleText"
:
""
,
"navigationBarTitleText"
:
""
"enablePullDownRefresh"
:
false
}
}
},
{
},
{
"path"
:
"pages/API/get-system-setting/get-system-setting"
,
"path"
:
"pages/API/get-system-setting/get-system-setting"
,
"style"
:
{
"style"
:
{
"navigationBarTitleText"
:
""
,
"navigationBarTitleText"
:
""
"enablePullDownRefresh"
:
false
}
}
},
{
},
{
"path"
:
"pages/API/get-app-authorize-setting/get-app-authorize-setting"
,
"path"
:
"pages/API/get-app-authorize-setting/get-app-authorize-setting"
,
"style"
:
{
"style"
:
{
"navigationBarTitleText"
:
""
,
"navigationBarTitleText"
:
""
"enablePullDownRefresh"
:
false
}
}
},
{
},
{
"path"
:
"pages/API/preview-image/preview-image"
,
"path"
:
"pages/API/preview-image/preview-image"
,
"style"
:
{
"style"
:
{
"navigationBarTitleText"
:
"图片预览"
,
"navigationBarTitleText"
:
"图片预览"
"enablePullDownRefresh"
:
false
}
}
},
{
},
{
"path"
:
"pages/component/scroll-view/scroll-view-refresher"
,
"path"
:
"pages/component/scroll-view/scroll-view-refresher"
,
"style"
:
"style"
:
{
{
"navigationBarTitleText"
:
"scroll-view-refresher"
"navigationBarTitleText"
:
"scroll-view-refresher"
,
"enablePullDownRefresh"
:
false
}
}
,{
"path"
:
"pages/component/list/list"
,
"style"
:
{
"navigationBarTitleText"
:
"列表到详情示例"
,
"enablePullDownRefresh"
:
false
}
}
},
{
"path"
:
"pages/component/list/list"
,
"style"
:
{
"navigationBarTitleText"
:
"列表到详情示例"
}
}
,{
},
{
"path"
:
"pages/API/get-network-type/get-network-type"
,
"path"
:
"pages/API/get-network-type/get-network-type"
,
"style"
:
"style"
:
{
{
"navigationBarTitleText"
:
""
"navigationBarTitleText"
:
""
,
"enablePullDownRefresh"
:
false
}
}
}
},
{
,{
"path"
:
"pages/component/list/detail/detail"
,
"path"
:
"pages/component/list/detail/detail"
,
"style"
:
{
"style"
:
"navigationBarTitleText"
:
"详情示例"
{
"navigationBarTitleText"
:
"详情示例"
,
"enablePullDownRefresh"
:
false
}
}
}
}
,
{
//
,
{
"path"
:
"pages/API/page-scrollTo/page-scrollTo
"
,
//
"path"
:
"pages/API/pull-down-refresh/pull-down-refresh
"
,
"style"
:
{
//
"style"
:
{
"navigationBarTitleText"
:
"pageScrollTo
"
,
//
"navigationBarTitleText"
:
"页面下拉刷新
"
,
"enablePullDownRefresh"
:
fals
e
//
"enablePullDownRefresh"
:
tru
e
}
//
}
}
//
}
],
],
"globalStyle"
:
{
"globalStyle"
:
{
"pageOrientation"
:
"portrait"
,
"pageOrientation"
:
"portrait"
,
...
@@ -597,19 +585,19 @@
...
@@ -597,19 +585,19 @@
"borderStyle"
:
"black"
,
"borderStyle"
:
"black"
,
"backgroundColor"
:
"#F8F8F8"
,
"backgroundColor"
:
"#F8F8F8"
,
"list"
:
[{
"list"
:
[{
"pagePath"
:
"pages/tabBar/component
/component"
,
"pagePath"
:
"pages/tabBar
/component"
,
"iconPath"
:
"static/component.png"
,
"iconPath"
:
"static/component.png"
,
"selectedIconPath"
:
"static/componentHL.png"
,
"selectedIconPath"
:
"static/componentHL.png"
,
"text"
:
"内置组件"
"text"
:
"内置组件"
},
},
{
{
"pagePath"
:
"pages/tabBar/API
/API"
,
"pagePath"
:
"pages/tabBar
/API"
,
"iconPath"
:
"static/api.png"
,
"iconPath"
:
"static/api.png"
,
"selectedIconPath"
:
"static/apiHL.png"
,
"selectedIconPath"
:
"static/apiHL.png"
,
"text"
:
"接口"
"text"
:
"接口"
},
},
{
{
"pagePath"
:
"pages/tabBar/CSS
/CSS"
,
"pagePath"
:
"pages/tabBar
/CSS"
,
"iconPath"
:
"static/extui.png"
,
"iconPath"
:
"static/extui.png"
,
"selectedIconPath"
:
"static/extuiHL.png"
,
"selectedIconPath"
:
"static/extuiHL.png"
,
"text"
:
"CSS"
"text"
:
"CSS"
...
...
pages/API/modal/modal.uvue
浏览文件 @
add636fc
...
@@ -41,7 +41,7 @@
...
@@ -41,7 +41,7 @@
</view>
</view>
</template>
</template>
<script lang="ts">
<script lang="
u
ts">
type ItemType = {
type ItemType = {
value : string,
value : string,
name : string,
name : string,
...
...
pages/API/page-lifecircle/page-lifecircle.uvue
0 → 100644
浏览文件 @
add636fc
<template>
<view>
<text>onLoad触发时间</text>
</view>
</template>
<script>
export default {
data() {
return {
}
},
onLoad() {
// const d = Date.now();
// const s = d.toDateString()
console.log("onLoad");
},
onShow() {
console.log("onShow");
},
onReady() {
console.log("onReady");
},
onHide() {
console.log("onHide");
},
onUnload() {
console.log("onUnLoad");
},
methods: {
}
}
</script>
<style>
</style>
pages/API/pull-down-refresh/pull-down-refresh.uvue
0 → 100644
浏览文件 @
add636fc
<template>
<view>
<page-head :title="title"></page-head>
<view class="uni-padding-wrap uni-common-mt">
<view style="font-size: 12px; color: #666;">注:PC 不支持下拉刷新</view>
<view class="text" v-for="(num,index) in data" :key="index">list - {{num}}</view>
<view class="uni-loadmore" v-if="showLoadMore">{{loadMoreText}}</view>
</view>
</view>
</template>
<script lang="uts">
export default {
data() {
return {
title: '下拉刷新 + 加载更多',
data: [],
loadMoreText: "加载中...",
showLoadMore: false,
max: 0
}
},
onLoad() {
this.initData();
},
onUnload() {
this.max = 0,
this.data = [],
this.loadMoreText = "加载更多",
this.showLoadMore = false;
},
onReachBottom() {
console.log("onReachBottom");
if (this.max > 40) {
this.loadMoreText = "没有更多数据了!"
return;
}
this.showLoadMore = true;
setTimeout(() => {
this.setListData();
}, 300);
},
onPullDownRefresh() {
console.log('onPullDownRefresh');
this.initData();
},
methods: {
initData(){
setTimeout(() => {
this.max = 0;
this.data = [];
let data = [];
this.max += 20;
for (var i = this.max - 19; i < this.max + 1; i++) {
data.push(i)
}
this.data = this.data.concat(data);
uni.stopPullDownRefresh();
}, 300);
},
setListData() {
let data = [];
this.max += 10;
for (var i = this.max - 9; i < this.max + 1; i++) {
data.push(i)
}
this.data = this.data.concat(data);
}
}
}
</script>
<style>
.text {
margin: 16rpx 0;
width:100%;
background-color: #fff;
height: 120rpx;
line-height: 120rpx;
text-align: center;
color: #555;
border-radius: 8rpx;
}
</style>
pages/tabBar/API
/API
.uvue
→
pages/tabBar/API.uvue
浏览文件 @
add636fc
...
@@ -44,50 +44,55 @@
...
@@ -44,50 +44,55 @@
return {
return {
list: [{
list: [{
id: "page",
id: "page",
name: "
界面",
name: "
页面",
open: false,
open: false,
pages: [
pages: [
{
name: "设置导航条",
url: "set-navigation-bar-title"
},
//#ifdef APP-PLUS
{
name: "原生子窗体",
url: "subnvue",
},
//#endif
{
{
name: "页面跳转",
name: "页面跳转",
url: "navigator",
url: "navigator",
enable: true
enable: true
},
},
//#ifndef MP-TOUTIAO
{
name: "设置导航条",
url: "set-navigation-bar-title"
},
{
{
name: "设置TabBar",
name: "设置TabBar",
url: "set-tabbar",
url: "set-tabbar",
},
},
//#endif
{
{
name: "下拉刷新",
name: "下拉刷新",
url: "pull-down-refresh",
url: "pull-down-refresh",
},
},
{
name: "页面生命周期",
url: "page-lifecircle",
enable: true
},
{
name: "将页面滚动到目标位置",
url: "page-scrollTo",
enable: true
},
] as Page[],
},
{
id: "ui",
name: "界面",
open: false,
pages: [
{
{
name: "创建动画",
name: "创建动画",
url: "animation",
url: "animation",
},
},
// #ifndef QUICKAPP-WEBVIEW-UNION
{
{
name: "创建绘画",
name: "创建绘画",
url: "canvas",
url: "canvas",
},
},
// #endif
// #ifndef MP-LARK
{
{
name: "节点信息",
name: "节点信息",
url: "get-node-info",
url: "get-node-info",
},
},
// #endif
{
{
name: "节点布局交互状态",
name: "节点布局交互状态",
url: "intersection-observer",
url: "intersection-observer",
...
@@ -112,11 +117,6 @@
...
@@ -112,11 +117,6 @@
url: "toast",
url: "toast",
enable: true
enable: true
},
},
{
name: "将页面滚动到目标位置",
url: "page-scrollTo",
enable: true
},
] as Page[],
] as Page[],
},
},
{
{
...
@@ -184,19 +184,19 @@
...
@@ -184,19 +184,19 @@
url: "brightness",
url: "brightness",
},
},
// #endif
// #endif
// #ifdef APP
-PLUS || MP-WEIXIN || MP-QQ || MP-JD
// #ifdef APP
|| MP-WEIXIN || MP-QQ || MP-JD
{
{
name: "蓝牙",
name: "蓝牙",
url: "bluetooth",
url: "bluetooth",
},
},
// #endif
// #endif
// #ifdef APP
-PLUS || MP-WEIXIN || MP-QQ
// #ifdef APP
|| MP-WEIXIN || MP-QQ
{
{
name: "生物认证",
name: "生物认证",
url: "soter",
url: "soter",
},
},
// #endif
// #endif
// #ifdef APP
-PLUS || MP-WEIXIN
// #ifdef APP
|| MP-WEIXIN
{
{
name: "iBeacon",
name: "iBeacon",
url: "ibeacon",
url: "ibeacon",
...
@@ -214,7 +214,7 @@
...
@@ -214,7 +214,7 @@
url: "on-compass-change",
url: "on-compass-change",
},
},
// #endif
// #endif
//#ifdef APP
-PLUS
//#ifdef APP
{
{
name: "监听距离传感器",
name: "监听距离传感器",
url: "/platforms/app-plus/proximity/proximity",
url: "/platforms/app-plus/proximity/proximity",
...
@@ -287,7 +287,7 @@
...
@@ -287,7 +287,7 @@
url: "inner-audio",
url: "inner-audio",
},
},
// #endif
// #endif
// #ifdef APP
-PLUS || MP-WEIXIN || MP-BAIDU || MP-QQ|| MP-JD
// #ifdef APP
|| MP-WEIXIN || MP-BAIDU || MP-QQ|| MP-JD
{
{
name: "录音",
name: "录音",
url: "voice",
url: "voice",
...
@@ -344,7 +344,7 @@
...
@@ -344,7 +344,7 @@
url: "map",
url: "map",
},
},
// #endif
// #endif
// #ifdef APP
-PLUS
// #ifdef APP
{
{
name: "地图搜索",
name: "地图搜索",
url: "map-search",
url: "map-search",
...
@@ -363,7 +363,7 @@
...
@@ -363,7 +363,7 @@
url: "storage",
url: "storage",
enable: true
enable: true
},
},
// #ifdef APP
-PLUS
// #ifdef APP
{
{
name: "SQLite",
name: "SQLite",
url: "sqlite",
url: "sqlite",
...
@@ -371,7 +371,7 @@
...
@@ -371,7 +371,7 @@
// #endif
// #endif
] as Page[],
] as Page[],
},
},
// #ifdef APP
-PLUS || MP-WEIXIN
// #ifdef APP
|| MP-WEIXIN
{
{
id: "rewarded-video-ad",
id: "rewarded-video-ad",
url: "rewarded-video-ad",
url: "rewarded-video-ad",
...
@@ -381,7 +381,7 @@
...
@@ -381,7 +381,7 @@
pages: [] as Page[]
pages: [] as Page[]
},
},
// #endif
// #endif
// #ifdef APP
-PLUS
// #ifdef APP
{
{
id: "full-screen-video-ad",
id: "full-screen-video-ad",
url: "full-screen-video-ad",
url: "full-screen-video-ad",
...
@@ -421,7 +421,7 @@
...
@@ -421,7 +421,7 @@
] as Page[],
] as Page[],
},
},
// #endif
// #endif
// #ifdef APP
-PLUS || MP-WEIXIN
// #ifdef APP
|| MP-WEIXIN
{
{
id: "payment",
id: "payment",
name: "支付",
name: "支付",
...
@@ -434,7 +434,7 @@
...
@@ -434,7 +434,7 @@
] as Page[],
] as Page[],
},
},
// #endif
// #endif
// #ifdef APP
-PLUS
// #ifdef APP
{
{
id: "speech",
id: "speech",
name: "语音",
name: "语音",
...
@@ -501,5 +501,5 @@
...
@@ -501,5 +501,5 @@
</script>
</script>
<style>
<style>
@import '../../
../common/uni-uvue.css';
@import '../../
common/uni-uvue.css';
</style>
</style>
\ No newline at end of file
pages/tabBar/CSS
/CSS
.uvue
→
pages/tabBar/CSS.uvue
浏览文件 @
add636fc
<template>
A
<template>
<view class="uni-container">
<view class="uni-container">
<view class="uni-header-logo">
<view class="uni-header-logo">
<image class="uni-header-image" src="/static/extuiIndex.png"></image>
<image class="uni-header-image" src="/static/extuiIndex.png"></image>
...
@@ -355,5 +355,5 @@
...
@@ -355,5 +355,5 @@
</script>
</script>
<style>
<style>
@import '../../
../
common/uni-uvue.css';
@import '../../common/uni-uvue.css';
</style>
</style>
\ No newline at end of file
pages/tabBar/component
/component
.uvue
→
pages/tabBar/component.uvue
浏览文件 @
add636fc
...
@@ -261,5 +261,5 @@
...
@@ -261,5 +261,5 @@
</script>
</script>
<style>
<style>
@import '../../
../common/uni-uvue.css';
@import '../../
common/uni-uvue.css';
</style>
</style>
\ No newline at end of file
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录