Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
DCloud
uni-app
提交
364112ab
U
uni-app
项目概览
DCloud
/
uni-app
2 个月 前同步成功
通知
716
Star
38705
Fork
3642
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
7
列表
看板
标记
里程碑
合并请求
1
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
U
uni-app
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
7
Issue
7
列表
看板
标记
里程碑
合并请求
1
合并请求
1
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
364112ab
编写于
11月 14, 2018
作者:
X
xiaoyucoding
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
modify: 条件编译屏蔽 H5 上不支持的示例
上级
506afee6
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
88 addition
and
57 deletion
+88
-57
examples/hello-uniapp/pages/tabBar/API/API.vue
examples/hello-uniapp/pages/tabBar/API/API.vue
+78
-54
examples/hello-uniapp/pages/tabBar/component/component.vue
examples/hello-uniapp/pages/tabBar/component/component.vue
+10
-3
未找到文件。
examples/hello-uniapp/pages/tabBar/API/API.vue
浏览文件 @
364112ab
...
...
@@ -10,12 +10,12 @@
<view
class=
"uni-list"
>
<view
class=
"uni-list-cell uni-collapse"
>
<view
class=
"uni-list-cell-navigate uni-navigate-bottom"
hover-class=
"uni-list-cell-hover"
:class=
"list.open ? 'uni-active' : ''"
@
click=
"trigerCollapse(index)"
>
@
click=
"trigerCollapse(index)"
>
{{
list
.
name
}}
</view>
<view
class=
"uni-list uni-collapse"
:class=
"list.open ? 'uni-active' : ''"
>
<view
class=
"uni-list-cell"
hover-class=
"uni-list-cell-hover"
v-for=
"(item,key) in list.pages"
:key=
"key"
:url=
"item.url"
@
click=
"goDetailPage(item.url)"
>
@
click=
"goDetailPage(item.url)"
>
<view
class=
"uni-list-cell-navigate uni-navigate-right"
>
{{
item
.
name
}}
</view>
</view>
</view>
...
...
@@ -27,39 +27,44 @@
<
script
>
export
default
{
data
()
{
let
list
=
[
{
let
list
=
[{
id
:
'
page
'
,
name
:
'
界面
'
,
open
:
false
,
pages
:
[{
name
:
'
设置界面标题
'
,
url
:
'
set-navigation-bar-title
'
},
{
name
:
'
页面跳转
'
,
url
:
'
navigator
'
},
{
name
:
'
下拉刷新
'
,
url
:
'
pull-down-refresh
'
},
{
name
:
'
创建动画
'
,
url
:
'
animation
'
},
{
name
:
'
创建绘画
'
,
url
:
'
canvas
'
},
{
name
:
'
显示操作菜单
'
,
url
:
'
action-sheet
'
},
{
name
:
'
显示模态弹窗
'
,
url
:
'
modal
'
},
{
name
:
'
显示加载提示框
'
,
url
:
'
show-loading
'
},
{
name
:
'
显示消息提示框
'
,
url
:
'
toast
'
}]
name
:
'
设置界面标题
'
,
url
:
'
set-navigation-bar-title
'
},
{
name
:
'
页面跳转
'
,
url
:
'
navigator
'
},
{
name
:
'
下拉刷新
'
,
url
:
'
pull-down-refresh
'
},
//#ifndef H5
{
name
:
'
创建动画
'
,
url
:
'
animation
'
},
{
name
:
'
创建绘画
'
,
url
:
'
canvas
'
},
//#endif
{
name
:
'
显示操作菜单
'
,
url
:
'
action-sheet
'
},
{
name
:
'
显示模态弹窗
'
,
url
:
'
modal
'
},
{
name
:
'
显示加载提示框
'
,
url
:
'
show-loading
'
},
{
name
:
'
显示消息提示框
'
,
url
:
'
toast
'
}
]
},
{
id
:
'
device
'
,
name
:
'
设备
'
,
...
...
@@ -73,13 +78,17 @@
},
{
name
:
'
打电话
'
,
url
:
'
make-phone-call
'
},
{
},
//#ifndef H5
{
name
:
'
扫码
'
,
url
:
'
scan-code
'
},
{
name
:
'
剪贴板
'
,
url
:
'
clipboard
'
},
{
},
//#endif
{
name
:
'
监听加速度传感器
'
,
url
:
'
on-accelerometer-change
'
},
{
...
...
@@ -117,19 +126,27 @@
pages
:
[{
name
:
'
图片
'
,
url
:
'
image
'
},
{
},
//#ifndef H5
{
name
:
'
录音
'
,
url
:
'
voice
'
},
{
name
:
'
背景音频
'
,
url
:
'
background-audio
'
},
{
},
//#endif
{
name
:
'
视频
'
,
url
:
'
video
'
},
{
},
//#ifndef H5
{
name
:
'
文件
'
,
url
:
'
file
'
}]
},
//#endif
]
},
{
id
:
'
location
'
,
name
:
'
位置
'
,
...
...
@@ -152,7 +169,9 @@
name
:
'
数据存储
'
,
url
:
'
storage
'
}]
},
{
},
//#ifndef H5
{
id
:
'
login
'
,
name
:
'
登录
'
,
open
:
false
,
...
...
@@ -163,7 +182,8 @@
name
:
'
获取用户信息
'
,
url
:
'
get-user-info
'
}]
},
{
},
{
id
:
'
payment
'
,
name
:
'
支付
'
,
open
:
false
,
...
...
@@ -171,7 +191,8 @@
name
:
'
发起支付
'
,
url
:
'
request-payment
'
}]
},
{
},
{
id
:
'
share
'
,
name
:
'
分享
'
,
open
:
false
,
...
...
@@ -179,9 +200,10 @@
name
:
'
分享
'
,
url
:
'
share
'
}]
}
},
//#endif
//#ifdef APP-PLUS
,
{
{
id
:
'
speech
'
,
name
:
'
语音
'
,
open
:
false
,
...
...
@@ -197,7 +219,7 @@
name
:
'
推送
'
,
url
:
'
/platforms/app-plus/push/push
'
}]
}
}
,
//#endif
];
return
{
...
...
@@ -210,7 +232,7 @@
path
:
'
/pages/tabBar/API/API
'
}
},
onNavigationBarButtonTap
(
e
){
onNavigationBarButtonTap
(
e
)
{
uni
.
navigateTo
({
url
:
'
/platforms/app-plus/about/about
'
})
...
...
@@ -237,13 +259,15 @@
</
script
>
<
style
>
.uni-card
{
box-shadow
:
none
;
}
.uni-list
:after
{
height
:
0
;
}
.uni-list
:before
{
height
:
0
;
}
</
style
>
.uni-card
{
box-shadow
:
none
;
}
.uni-list
:after
{
height
:
0
;
}
.uni-list
:before
{
height
:
0
;
}
</
style
>
examples/hello-uniapp/pages/tabBar/component/component.vue
浏览文件 @
364112ab
...
...
@@ -31,7 +31,14 @@
id
:
'
view
'
,
name
:
'
视图容器
'
,
open
:
false
,
pages
:
[
'
view
'
,
'
scroll-view
'
,
'
swiper
'
,
'
movable-view
'
]
pages
:
[
'
view
'
,
'
scroll-view
'
,
'
swiper
'
,
//#ifndef H5
'
movable-view
'
,
//#endif
]
},
{
id
:
'
content
'
,
name
:
'
基础内容
'
,
...
...
@@ -60,13 +67,13 @@
name
:
'
地图
'
,
open
:
false
,
pages
:
[
'
map
'
]
// #ifndef H5
// #ifndef H5
},
{
id
:
'
web-view
'
,
name
:
'
网页
'
,
open
:
false
,
pages
:
[
'
web-view
'
],
// #endif
// #endif
}]
}
},
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录