Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
DCloud
unidocs-uni-app-x-zh
提交
7c4c4053
U
unidocs-uni-app-x-zh
项目概览
DCloud
/
unidocs-uni-app-x-zh
通知
124
Star
0
Fork
28
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
7
列表
看板
标记
里程碑
合并请求
9
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
U
unidocs-uni-app-x-zh
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
7
Issue
7
列表
看板
标记
里程碑
合并请求
9
合并请求
9
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
7c4c4053
编写于
4月 24, 2024
作者:
G
git_robot
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
更新 pagesJson.json
上级
a94f68b1
变更
1
显示空白变更内容
内联
并排
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
docs/.vuepress/utils/pagesJson.json
docs/.vuepress/utils/pagesJson.json
+1
-1
未找到文件。
docs/.vuepress/utils/pagesJson.json
浏览文件 @
7c4c4053
{
"pages"
:{
"compatibility"
:
"**pages.json 兼容性**
\n
| | Android | iOS | web |
\n
| :- | :- | :- | :- |
\n
| globalStyle | 3.9 | 4.11 | 4.0 |
\n
| topWindow | x | x | 4.0 |
\n
| leftWindow | x | x | 4.0 |
\n
| rightWindow | x | x | 4.0 |
\n
| pages | 3.9 | 4.11 | 4.0 |
\n
| tabBar | 3.9 | 4.11 | 4.0 |
\n
| condition | 3.9 | 4.11 | 4.0 |
\n
| subPackages | x | x | 4.0 |
\n
| workers | x | x | 4.0 |
\n
| preloadRule | x | x | 4.0 |
\n
| easycom | 3.9 | 4.11 | 4.0 |
\n
| uniIdRouter | 3.99 | 4.11 | 4.0 |
\n
| entryPagePath | x | x | 4.0 |"
,
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| globalStyle | [globalStyle 配置项列表](#pages-globalstyle) | - | 否 | 默认页面的窗口表现 |
\n
| topWindow | [topWindow 配置项列表](#pages-topwindow) | - | 否 | 上窗体 |
\n
| leftWindow | [leftWindow 配置项列表](#pages-leftwindow) | - | 否 | 左窗体 |
\n
| rightWindow | [rightWindow 配置项列表](#pages-rightwindow) | - | 否 | 右窗体 |
\n
| pages | Array
\\
<[PagesOptionsPage](#pagesoptionspage)> | - | 是 | 页面路径及窗口表现 |
\n
| tabBar | [tabBar 配置项列表](#pages-tabbar) | - | 否 | 底部 tab 的表现 |
\n
| condition | [condition 配置项列表](#pages-condition) | - | 否 | 启动模式 |
\n
| subPackages | Array
\\
<[PagesSubPackages](#pagessubpackages)> | - | 否 | 分包加载配置 |
\n
| workers | string | - | 否 | 使用 Worker 处理多线程任务时,设置 Worker 代码放置的目录 |
\n
| preloadRule | object | - | 否 | 声明分包预下载的规则 |
\n
| easycom | [easycom 配置项列表](#pages-easycom) | - | 否 | 组件自动引入规则 |
\n
| uniIdRouter | [uniIdRouter 配置项列表](#pages-uniidrouter) | - | 否 | 根据用户登录状态、页面是否要求登录、以及接口返回的用户token验证状态自动跳转登录页面。详细教程:[详见](https://doc.dcloud.net.cn/uniCloud/uni-id/summary.html#uni-id-router) |
\n
| entryPagePath | string | - | 否 | 默认启动首页,新增于HBuilderX 3.7.0 |"
},
"pages_globalStyle"
:{
"compatibility"
:
"**globalStyle 兼容性**
\n
| | Android | iOS | web |
\n
| :- | :- | :- | :- |
\n
| navigationBarBackgroundColor | 3.9 | 4.11 | 4.0 |
\n
| navigationBarTextStyle | 3.9 | 4.11 | 4.0 |
\n
| navigationBarTitleText | 3.9 | 4.11 | 4.0 |
\n
| navigationStyle | 3.9 | 4.11 | 4.0 |
\n
| backgroundColor | 3.99 | x | x |
\n
| backgroundColorContent | 4.0 | 4.11 | 4.11 |
\n
| enablePullDownRefresh | 3.9 | 4.11 | 4.0 |
\n
| onReachBottomDistance | x | x | 4.0 |
\n
| backgroundColorTop | x | x | 4.0 |
\n
| backgroundColorBottom | x | x | 4.0 |
\n
| titleImage | x | x | 4.0 |
\n
| transparentTitle | x | x | 4.0 |
\n
| titlePenetrate | x | x | 4.0 |
\n
| pageOrientation | 4.13 | x | x |
\n
| usingComponents | x | x | 4.0 |
\n
| leftWindow | x | x | 4.0 |
\n
| topWindow | x | x | 4.0 |
\n
| rightWindow | x | x | 4.0 |
\n
| rpxCalcMaxDeviceWidth | x | x | 4.0 |
\n
| rpxCalcBaseDeviceWidth | x | x | 4.0 |
\n
| rpxCalcIncludeWidth | x | x | 4.0 |
\n
| maxWidth | x | x | 4.0 |
\n
| h5 | x | x | 4.0 |"
,
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| navigationBarBackgroundColor | string ([string.ColorString](/uts/data-type.md#ide-string)) | `app`: #F8F8F8<br/>`web`: #F8F8F8<br/>`mp-weixin、mp-qq、mp-baidu、mp-toutiao、mp-lark、mp-jd`: #000000<br/>`mp-alipay、mp-kuaishou`: #ffffff | 否 | 导航栏背景颜色(同状态栏背景色) |
\n
| navigationBarTextStyle | 'white'
\\
| 'black' |
\"
black
\"
| 否 | 导航栏标题颜色,仅支持 black/white(支付宝小程序不支持,请使用 [my.setNavigationBar](https://opendocs.alipay.com/mini/api/xwq8e6))。 |
\n
| navigationBarTitleText | string | - | 否 | 导航栏标题文字内容 |
\n
| navigationStyle | 'default'
\\
| 'custom' |
\"
default
\"
| 否 | 导航栏样式,仅支持 default/custom。custom即取消默认的原生导航栏,需看[使用注意](https://uniapp.dcloud.net.cn/collocation/pages.html#customnav)。 |
\n
| backgroundColor | string ([string.ColorString](/uts/data-type.md#ide-string)) |
\"
#ffffff
\"
| 否 | 下拉刷新显示出来的窗口的背景色(无下拉刷新时,此颜色无效果) |
\n
| backgroundColorContent | string ([string.ColorString](/uts/data-type.md#ide-string)) |
\"
#ffffff
\"
| 否 | 页面容器背景色 |
\n
| enablePullDownRefresh | boolean | false | 否 | 是否开启下拉刷新,详见[页面生命周期](https://doc.dcloud.net.cn/uni-app-x/page.html)。 |
\n
| onReachBottomDistance | number | 50 | 否 | 页面上拉触底事件触发时距页面底部距离,单位只支持px,详见[页面生命周期](https://doc.dcloud.net.cn/uni-app-x/page.html)。 |
\n
| backgroundColorTop | string ([string.ColorString](/uts/data-type.md#ide-string)) |
\"
#ffffff
\"
| 否 | 顶部窗口的背景色(bounce回弹区域), 仅 iOS 平台 |
\n
| backgroundColorBottom | string ([string.ColorString](/uts/data-type.md#ide-string)) |
\"
#ffffff
\"
| 否 | 底部窗口的背景色(bounce回弹区域), 仅 iOS 平台 |
\n
| titleImage | string ([string.ImageURIString](/uts/data-type.md#ide-string)) | - | 否 | 导航栏图片地址(替换当前文字标题),支付宝小程序内必须使用https的图片链接地址 |
\n
| transparentTitle | 'always'
\\
| 'auto'
\\
| 'none' |
\"
none
\"
| 否 | 导航栏整体(前景、背景)透明设置。支持 always 一直透明 / auto 滑动自适应 / none 不透明 |
\n
| titlePenetrate | 'YES'
\\
| 'NO' |
\"
NO
\"
| 否 | 导航栏点击穿透 |
\n
| pageOrientation | 'auto'
\\
| 'portrait'
\\
| 'landscape' |
\"
portrait
\"
| 否 | 横屏配置,屏幕旋转设置,仅支持 auto / portrait / landscape 详见 [响应显示区域变化](https://uniapp.dcloud.net.cn/collocation/pages.htmld#globalstyle)。 |
\n
| usingComponents | object | - | 否 | 引用小程序组件,参考 [小程序组件](https://uniapp.dcloud.net.cn/tutorial/miniprogram-subject.html)。 |
\n
| leftWindow | boolean | true | 否 | 当存在 leftWindow时,默认是否显示 leftWindow |
\n
| topWindow | boolean | true | 否 | 当存在 topWindow时,默认是否显示 topWindow |
\n
| rightWindow | boolean | true | 否 | 当存在 rightWindow时,默认是否显示 rightWindow |
\n
| rpxCalcMaxDeviceWidth | number | 960 | 否 | rpx 计算所支持的最大设备宽度,单位 px |
\n
| rpxCalcBaseDeviceWidth | number | 375 | 否 | rpx 计算使用的基准设备宽度,设备实际宽度超出 rpx 计算所支持的最大设备宽度时将按基准宽度计算,单位 px |
\n
| rpxCalcIncludeWidth | number | 750 | 否 | rpx 计算特殊处理的值,始终按实际的设备宽度计算,单位 rpx |
\n
| maxWidth | number | - | 否 | 单位px,当浏览器可见区域宽度大于maxWidth时,两侧留白,当小于等于maxWidth时,页面铺满;不同页面支持配置不同的maxWidth;maxWidth = leftWindow(可选)+page(页面主体)+rightWindow(可选) |
\n
| h5 | [h5 配置项列表](#globalstyle-h5) | - | 否 | H5 特有配置 |"
,
"description"
:
"默认页面的窗口表现"
},
"globalStyle_h5"
:{
"compatibility"
:
"**h5 兼容性**
\n
| | Android | iOS | web |
\n
| :- | :- | :- | :- |
\n
| titleNView | x | x | 4.0 |
\n
| pullToRefresh | x | x | 4.0 |"
,
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| titleNView | [titleNView 配置项列表](#h5-titlenview) | - | 否 | 导航栏设置 |
\n
| pullToRefresh | [pullToRefresh 配置项列表](#h5-pulltorefresh) | - | 否 | 下拉刷新 |"
,
"description"
:
"H5 特有配置"
},
"h5_titleNView"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| backgroundColor | string ([string.ColorString](/uts/data-type.md#ide-string)) |
\"
#f7f7f7
\"
| 否 | 背景颜色,颜色值格式为
\"
#RRGGBB
\"
。 |
\n
| buttons | array | - | 否 | 自定义按钮,参考 [buttons](https://uniapp.dcloud.net.cn/collocation/pages.html?id=h5-titlenview-buttons)。 |
\n
| titleColor | string ([string.ColorString](/uts/data-type.md#ide-string)) |
\"
#000000
\"
| 否 | 标题文字颜色 |
\n
| titleText | string | - | 否 | 标题文字内容 |
\n
| titleSize | string | - | 否 | 标题文字字体大小 |
\n
| type | 'defaultValue'
\\
| 'transparent' |
\"
defaultValue
\"
| 否 | 导航栏样式。
\"
default
\"
-默认样式;
\"
transparent
\"
-透明渐变。 |
\n
| searchInput | object | - | 否 | 导航栏上的搜索框样式,详见:[searchInput](https://uniapp.dcloud.net.cn/collocation/pages.html?id=h5-searchinput)。 |"
,
"description"
:
"导航栏设置"
},
"h5_pullToRefresh"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| support | boolean | - | 否 | 是否开启窗口的下拉刷新功能 |
\n
| color | string ([string.ColorString](/uts/data-type.md#ide-string)) | - | 否 | 颜色值格式为
\"
#RRGGBB
\"
,仅
\"
circle
\"
样式下拉刷新支持此属性。 |
\n
| type | 'defaultValue'
\\
| 'circle' | - | 否 | 下拉刷新控件样式 |
\n
| height | string | - | 否 | 窗口的下拉刷新控件进入刷新状态的拉拽高度。支持百分比,如
\"
10%
\"
;像素值,如
\"
50px
\"
。 |
\n
| range | string | - | 否 | 窗口可下拉拖拽的范围。支持百分比,如
\"
10%
\"
;像素值,如
\"
50px
\"
。 |
\n
| offset | string | - | 否 | 下拉刷新控件的起始位置。仅对
\"
circle
\"
样式下拉刷新控件有效,用于定义刷新控件下拉时的起始位置。支持百分比,如
\"
10%
\"
;像素值,如
\"
50px
\"
。 |
\n
| contentdown | [contentdown 配置项列表](#pulltorefresh-contentdown) | - | 否 | 在下拉可刷新状态时下拉刷新控件显示的内容 |
\n
| contentover | [contentover 配置项列表](#pulltorefresh-contentover) | - | 否 | 在释放可刷新状态时下拉刷新控件显示的内容 |
\n
| contentrefresh | [contentrefresh 配置项列表](#pulltorefresh-contentrefresh) | - | 否 | 在正在刷新状态时下拉刷新控件显示的内容 |"
,
"description"
:
"下拉刷新"
},
"pullToRefresh_contentdown"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| caption | string | - | 否 | 下拉刷新控件上显示的标题内容 |"
,
"description"
:
"在下拉可刷新状态时下拉刷新控件显示的内容"
},
"pullToRefresh_contentover"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| caption | string | - | 否 | 下拉刷新控件上显示的标题内容 |"
,
"description"
:
"在释放可刷新状态时下拉刷新控件显示的内容"
},
"pullToRefresh_contentrefresh"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| caption | string | - | 否 | 下拉刷新控件上显示的标题内容 |"
,
"description"
:
"在正在刷新状态时下拉刷新控件显示的内容"
},
"pages_topWindow"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| path | string | - | 否 | 配置页面路径 |
\n
| style | object | - | 否 | 配置页面窗口表现,配置项参考下方 [pageStyle](https://uniapp.dcloud.net.cn/collocation/pages.html?id=style) |
\n
| matchMedia | [matchMedia 配置项列表](#topwindow-matchmedia) | - | 否 | 配置显示该窗口的规则,配置项参考下方 [matchMedia](https://uniapp.dcloud.net.cn/collocation/pages.html?id=matchmedia) |"
,
"description"
:
"上窗体"
},
"topWindow_matchMedia"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| minWidth | number | 768 | 否 | 当设备可见区域宽度 minWidth 时,显示该 window+ |"
,
"description"
:
"配置显示该窗口的规则,配置项参考下方 [matchMedia](https://uniapp.dcloud.net.cn/collocation/pages.html?id=matchmedia)"
},
"pages_leftWindow"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| path | string | - | 否 | 配置页面路径 |
\n
| style | object | - | 否 | 配置页面窗口表现,配置项参考下方 [pageStyle](https://uniapp.dcloud.net.cn/collocation/pages.html?id=style) |
\n
| matchMedia | [matchMedia 配置项列表](#leftwindow-matchmedia) | - | 否 | 配置显示该窗口的规则,配置项参考下方 [matchMedia](https://uniapp.dcloud.net.cn/collocation/pages.html?id=matchmedia) |"
,
"description"
:
"左窗体"
},
"leftWindow_matchMedia"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| minWidth | number | 768 | 否 | 当设备可见区域宽度 minWidth 时,显示该 window+ |"
,
"description"
:
"配置显示该窗口的规则,配置项参考下方 [matchMedia](https://uniapp.dcloud.net.cn/collocation/pages.html?id=matchmedia)"
},
"pages_rightWindow"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| path | string | - | 否 | 配置页面路径 |
\n
| style | object | - | 否 | 配置页面窗口表现,配置项参考下方 [pageStyle](https://uniapp.dcloud.net.cn/collocation/pages.html?id=style) |
\n
| matchMedia | [matchMedia 配置项列表](#rightwindow-matchmedia) | - | 否 | 配置显示该窗口的规则,配置项参考下方 [matchMedia](https://uniapp.dcloud.net.cn/collocation/pages.html?id=matchmedia) |"
,
"description"
:
"右窗体"
},
"rightWindow_matchMedia"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| minWidth | number | 768 | 否 | 当设备可见区域宽度 minWidth 时,显示该 window+ |"
,
"description"
:
"配置显示该窗口的规则,配置项参考下方 [matchMedia](https://uniapp.dcloud.net.cn/collocation/pages.html?id=matchmedia)"
},
"PagesOptionsPage"
:{
"compatibility"
:
"**PagesOptionsPage 兼容性**
\n
| | Android | iOS | web |
\n
| :- | :- | :- | :- |
\n
| path | 3.9 | 4.11 | 4.0 |
\n
| style | 3.9 | 4.11 | 4.0 |
\n
| needLogin | 3.99 | 4.11 | 4.0 |"
,
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| path | string ([string.PageURIString](/uts/data-type.md#ide-string)) | - | 是 | 配置页面路径 |
\n
| style | [style 配置项列表](#pagesoptionspage-style) | - | 否 | 配置页面窗口表现,配置项参考下方 [pageStyle](https://doc.dcloud.net.cn/uni-app-x/collocation/pagesjson.html#pagesoptionspage-style)。 |
\n
| needLogin | boolean | false | 否 | 是否需要登录才可访问 |"
},
"PagesOptionsPage_style"
:{
"compatibility"
:
"**style 兼容性**
\n
| | Android | iOS | web |
\n
| :- | :- | :- | :- |
\n
| navigationBarBackgroundColor | 3.9 | 4.11 | 4.0 |
\n
| navigationBarTextStyle | 3.9 | 4.11 | 4.0 |
\n
| navigationBarTitleText | 3.9 | 4.11 | 4.0 |
\n
| navigationBarShadow | x | x | 4.0 |
\n
| navigationStyle | 3.9 | 4.11 | 4.0 |
\n
| backgroundColor | 3.99 | 4.11 | x |
\n
| backgroundColorContent | 4.0 | 4.11 | 4.11 |
\n
| backgroundTextStyle | x | x | 4.0 |
\n
| enablePullDownRefresh | 3.9 | 4.11 | 4.0 |
\n
| onReachBottomDistance | x | x | 4.0 |
\n
| pageOrientation | 4.13 | x | x |
\n
| backgroundColorTop | x | x | 4.0 |
\n
| backgroundColorBottom | x | x | 4.0 |
\n
| titleImage | x | x | 4.0 |
\n
| transparentTitle | x | x | 4.0 |
\n
| titlePenetrate | x | x | 4.0 |
\n
| usingComponents | x | x | 4.0 |
\n
| leftWindow | x | x | 4.0 |
\n
| topWindow | x | x | 4.0 |
\n
| rightWindow | x | x | 4.0 |
\n
| maxWidth | x | x | 4.0 |"
,
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| navigationBarBackgroundColor | string ([string.ColorString](/uts/data-type.md#ide-string)) | `app`: #F8F8F8<br/>`web`: #F8F8F8<br/>`mp-weixin、mp-qq、mp-baidu、mp-toutiao、mp-lark、mp-jd`: #000000<br/>`mp-alipay、mp-kuaishou`: #ffffff | 否 | 导航栏背景颜色(同状态栏背景色) |
\n
| navigationBarTextStyle | 'white'
\\
| 'black' |
\"
black
\"
| 否 | 导航栏标题颜色,仅支持 black/white |
\n
| navigationBarTitleText | string | - | 否 | 导航栏标题文字内容 |
\n
| navigationBarShadow | [navigationBarShadow 配置项列表](#style-navigationbarshadow) | - | 否 | 导航栏阴影,配置参考下方 [导航栏阴影](https://doc.dcloud.net.cn/uni-app-x/collocation/pagesjson.html#pagesoptionspage-style) |
\n
| navigationStyle | 'default'
\\
| 'custom' |
\"
default
\"
| 否 | 导航栏样式,仅支持 default/custom。custom即取消默认的原生导航栏,需看[使用注意](https://uniapp.dcloud.net.cn/collocation/pages.html#customnav)。 |
\n
| backgroundColor | string ([string.ColorString](/uts/data-type.md#ide-string)) |
\"
#ffffff
\"
| 否 | 下拉刷新显示出来的窗口的背景色(无下拉刷新时,此颜色无效果) |
\n
| backgroundColorContent | string ([string.ColorString](/uts/data-type.md#ide-string)) |
\"
#ffffff
\"
| 否 | 页面容器背景色 |
\n
| backgroundTextStyle | 'dark'
\\
| 'light' |
\"
dark
\"
| 否 | 下拉 loading 的样式,仅支持 dark/light |
\n
| enablePullDownRefresh | boolean | false | 否 | 是否开启下拉刷新,详见[页面生命周期](https://doc.dcloud.net.cn/uni-app-x/page.html)。 |
\n
| onReachBottomDistance | number | 50 | 否 | 页面上拉触底事件触发时距页面底部距离,单位只支持px,详见[页面生命周期](https://doc.dcloud.net.cn/uni-app-x/page.html)。 |
\n
| pageOrientation | 'auto'
\\
| 'portrait'
\\
| 'landscape' |
\"
portrait
\"
| 否 | 页面旋转设置,支持 auto 设备自适应 / portrait 竖向 / landscape 横向 |
\n
| backgroundColorTop | string ([string.ColorString](/uts/data-type.md#ide-string)) |
\"
#ffffff
\"
| 否 | 顶部窗口的背景色(bounce回弹区域), 仅 iOS 平台 |
\n
| backgroundColorBottom | string ([string.ColorString](/uts/data-type.md#ide-string)) |
\"
#ffffff
\"
| 否 | 底部窗口的背景色(bounce回弹区域), 仅 iOS 平台 |
\n
| titleImage | string ([string.ImageURIString](/uts/data-type.md#ide-string)) | - | 否 | 导航栏图片地址(替换当前文字标题),支付宝小程序内必须使用https的图片链接地址 |
\n
| transparentTitle | 'always'
\\
| 'auto'
\\
| 'none' |
\"
none
\"
| 否 | 导航栏整体(前景、背景)透明设置。支持 always 一直透明 / auto 滑动自适应 / none 不透明 |
\n
| titlePenetrate | 'YES'
\\
| 'NO' |
\"
NO
\"
| 否 | 导航栏点击穿透 |
\n
| h5 | [h5 配置项列表](#style-h5) | - | 否 | 编译到 H5 平台的特定样式 |
\n
| usingComponents | object | - | 否 | 引用小程序组件,参考 [小程序组件https://uniapp.dcloud.net.cn/tutorial/miniprogram-subject.html#小程序自定义组件支持)。 |
\n
| leftWindow | boolean | true | 否 | 当存在 leftWindow时,当前页面是否显示 leftWindow |
\n
| topWindow | boolean | true | 否 | 当存在 topWindow时,当前页面是否显示 topWindow |
\n
| rightWindow | boolean | true | 否 | 当存在 rightWindow时,当前页面是否显示 rightWindow |
\n
| maxWidth | number | - | 否 | 单位px,当浏览器可见区域宽度大于maxWidth时,两侧留白,当小于等于maxWidth时,页面铺满;不同页面支持配置不同的maxWidth;maxWidth = leftWindow(可选)+page(页面主体)+rightWindow(可选) |"
,
"description"
:
"配置页面窗口表现,配置项参考下方 [pageStyle](https://doc.dcloud.net.cn/uni-app-x/collocation/pagesjson.html#pagesoptionspage-style)。"
},
"style_navigationBarShadow"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| colorType | 'grey'
\\
| 'blue'
\\
| 'green'
\\
| 'orange'
\\
| 'red'
\\
| 'yellow' | - | 否 | 阴影的颜色,支持:grey、blue、green、orange、red、yellow |"
,
"description"
:
"导航栏阴影,配置参考下方 [导航栏阴影](https://doc.dcloud.net.cn/uni-app-x/collocation/pagesjson.html#pagesoptionspage-style)"
},
"style_h5"
:{
"compatibility"
:
"**h5 兼容性**
\n
| | Android | iOS | web |
\n
| :- | :- | :- | :- |
\n
| titleNView | x | x | 4.0 |
\n
| pullToRefresh | x | x | 4.0 |"
,
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| titleNView | [titleNView 配置项列表](#h5-titlenview) | - | 否 | 导航栏设置 |
\n
| pullToRefresh | [pullToRefresh 配置项列表](#h5-pulltorefresh) | - | 否 | 下拉刷新 |"
,
"description"
:
"编译到 H5 平台的特定样式"
},
"pages_tabBar"
:{
"compatibility"
:
"**tabBar 兼容性**
\n
| | Android | iOS | web |
\n
| :- | :- | :- | :- |
\n
| color | 3.9 | 4.11 | 4.0 |
\n
| selectedColor | 3.9 | 4.11 | 4.0 |
\n
| backgroundColor | 3.9 | 4.11 | 4.0 |
\n
| borderStyle | x | x | 4.0 |
\n
| blurEffect | x | x | 4.0 |
\n
| list | 3.9 | 4.11 | 4.0 |
\n
| fontSize | x | x | 4.0 |
\n
| iconWidth | x | x | 4.0 |
\n
| spacing | x | x | 4.0 |
\n
| height | x | x | 4.0 |
\n
| midButton | x | x | 4.0 |
\n
| iconfontSrc | x | x | 4.0 |
\n
| backgroundImage | 3.9 | 4.11 | x |
\n
| backgroundRepeat | 3.9 | 4.11 | x |
\n
| redDotColor | 3.9 | 4.11 | x |"
,
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| color | string ([string.ColorString](/uts/data-type.md#ide-string)) | - | 是 | tab 上的文字默认颜色 |
\n
| selectedColor | string ([string.ColorString](/uts/data-type.md#ide-string)) | - | 是 | tab 上的文字选中时的颜色 |
\n
| backgroundColor | string ([string.ColorString](/uts/data-type.md#ide-string)) | - | 是 | tab 的背景色 |
\n
| borderStyle | string |
\"
black
\"
| 否 | tabbar 上边框的颜色,可选值 black、white(App、H5 也支持其他颜色值)。 |
\n
| blurEffect | 'dark'
\\
| 'extralight'
\\
| 'light'
\\
| 'none' |
\"
none
\"
| 否 | IOS 高斯模糊效果,可选值 dark/extralight/light/none(参考:[使用说明](https://uniapp.dcloud.net.cn//tutorial/app-blureffect.html)) |
\n
| list | Array
\\
<[PagesOptionsTabbarList](#pagesoptionstabbarlist)> | - | 是 | tab 的列表,详见 list 属性说明,最少2个、最多5个 tab |
\n
| fontSize | string |
\"
10px
\"
| 否 | 文字默认大小 |
\n
| iconWidth | string |
\"
24px
\"
| 否 | 图标默认宽度(高度等比例缩放) |
\n
| spacing | string |
\"
3px
\"
| 否 | 图标和文字的间距 |
\n
| height | string |
\"
50px
\"
| 否 | tabBar 默认高度 |
\n
| midButton | [midButton 配置项列表](#tabbar-midbutton) | - | 否 | 中间按钮 仅在 list 项为偶数时有效 |
\n
| iconfontSrc | string | - | 否 | list设置 iconfont 属性时,需要指定字体文件路径 |
\n
| backgroundImage | string | - | 否 | 设置背景图片,优先级高于 backgroundColor |
\n
| backgroundRepeat | 'repeat'
\\
| 'repeat-x'
\\
| 'repeat-y'
\\
| 'no-repeat' |
\"
no-repeat
\"
| 否 | 设置标题栏的背景图平铺方式 |
\n
| redDotColor | string ([string.ColorString](/uts/data-type.md#ide-string)) | - | 否 | tabbar上红点颜色 |"
,
"description"
:
"底部 tab 的表现"
},
"PagesOptionsTabbarList"
:{
"compatibility"
:
"**PagesOptionsTabbarList 兼容性**
\n
| | Android | iOS | web |
\n
| :- | :- | :- | :- |
\n
| iconfont | 3.9 | 4.11 | 4.0 |
\n
| pagePath | 3.9 | 4.11 | 4.0 |
\n
| text | 3.9 | 4.11 | 4.0 |
\n
| iconPath | 3.9 | 4.11 | 4.0 |
\n
| selectedIconPath | 3.9 | 4.11 | 4.0 |
\n
| visible | 3.9 | 4.11 | 4.0 |"
,
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| iconfont | [iconfont 配置项列表](#pagesoptionstabbarlist-iconfont) | - | 否 | 字体图标,优先级高于 iconPath |
\n
| pagePath | string ([string.PageURIString](/uts/data-type.md#ide-string)) | - | 是 | 页面路径,必须在 pages 中先定义 |
\n
| text | string | - | 是 | tab 上按钮文字,在 App 和 H5 平台为非必填。例如中间可放一个没有文字的+号图标 |
\n
| iconPath | string ([string.ImageURIString](/uts/data-type.md#ide-string)) | - | 否 | 图片路径,icon 大小限制为40kb,建议尺寸为 81px * 81px,当 position 为 top 时,此参数无效,不支持网络图片,不支持字体图标 |
\n
| selectedIconPath | string ([string.ImageURIString](/uts/data-type.md#ide-string)) | - | 否 | 选中时的图片路径,icon 大小限制为40kb,建议尺寸为 81px * 81px ,当 position 为 top 时,此参数无效 |
\n
| visible | boolean | - | 否 | 该项是否显示,默认显示 |"
},
"PagesOptionsTabbarList_iconfont"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| text | string | - | 否 | 字库 Unicode 码 |
\n
| selectedText | string | - | 否 | 选中后字库 Unicode 码 |
\n
| fontSize | string | - | 否 | 字体图标字号(px) |
\n
| color | string ([string.ColorString](/uts/data-type.md#ide-string)) | - | 否 | 字体图标颜色 |
\n
| selectedColor | string ([string.ColorString](/uts/data-type.md#ide-string)) | - | 否 | 字体图标选中颜色 |"
,
"description"
:
"字体图标,优先级高于 iconPath"
},
"tabBar_midButton"
:{
"compatibility"
:
"**midButton 兼容性**
\n
| | Android | iOS | web |
\n
| :- | :- | :- | :- |
\n
| width | x | x | 4.0 |
\n
| height | x | x | 4.0 |
\n
| text | x | x | 4.0 |
\n
| iconPath | x | x | 4.0 |
\n
| iconWidth | x | x | 4.0 |
\n
| backgroundImage | x | x | 4.0 |"
,
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| width | string |
\"
80px
\"
| 否 | 中间按钮的宽度,tabBar 其它项为减去此宽度后平分,默认值为与其它项平分宽度 |
\n
| height | string |
\"
80px
\"
| 否 | 中间按钮的高度,可以大于 tabBar 高度,达到中间凸起的效果 |
\n
| text | string | - | 否 | 中间按钮的文字 |
\n
| iconPath | string ([string.ImageURIString](/uts/data-type.md#ide-string)) | - | 否 | 中间按钮的图片路径 |
\n
| iconWidth | string |
\"
24px
\"
| 否 | 图标默认宽度(高度等比例缩放) |
\n
| backgroundImage | string ([string.ImageURIString](/uts/data-type.md#ide-string)) | - | 否 | 中间按钮的背景图片路径 |"
,
"description"
:
"中间按钮 仅在 list 项为偶数时有效"
},
"pages_condition"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| current | number | - | 是 | 当前激活的模式,list节点的索引值。 |
\n
| list | Array
\\
<[PagesConditionItem](#pagesconditionitem)> | - | 是 | 启动模式列表 |"
,
"description"
:
"启动模式"
},
"PagesConditionItem"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| name | string | - | 是 | 启动模式名称 |
\n
| path | string ([string.PageURIString](/uts/data-type.md#ide-string)) | - | 是 | 启动页面路径 |
\n
| query | string | - | 否 | 启动参数,可在页面的 onLoad 函数里获得 |"
},
"PagesSubPackages"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| root | string | - | 是 | 子包的根目录 |
\n
| pages | Array
\\
<[PagesOptionsPage](#pagesoptionspage)> | - | 是 | 子包由哪些页面组成 |"
},
"pages_easycom"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| autoscan | boolean | true | 否 | 是否开启自动扫描,开启后将会自动扫描符合components/组件名称/组件名称.vue/uvue目录结构的组件 |
\n
| custom | object | - | 否 | 以正则方式自定义组件匹配规则。如果autoscan不能满足需求,可以使用custom自定义匹配规则 |"
,
"description"
:
"组件自动引入规则"
},
"pages_uniIdRouter"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| loginPage | string ([string.PageURIString](/uts/data-type.md#ide-string)) | - | 否 | 登录页面路径 |
\n
| resToLogin | boolean | - | 否 | 是否开启自动根据响应体判断跳转登录页面,默认true(开启) |
\n
| needLogin | Array
\\
<string,[string.PageURIString](/uts/data-type.md#ide-string)> | - | 否 | - |"
,
"description"
:
"根据用户登录状态、页面是否要求登录、以及接口返回的用户token验证状态自动跳转登录页面。详细教程:[详见](https://doc.dcloud.net.cn/uniCloud/uni-id/summary.html#uni-id-router)"
},
"tutorial"
:
"## 参见
\n
[相关 Bug](https://issues.dcloud.net.cn/?mid=collocation.pages_json)"
}
\ No newline at end of file
{
"pages"
:{
"compatibility"
:
"**pages.json 兼容性**
\n
| | Android | iOS | web |
\n
| :- | :- | :- | :- |
\n
| globalStyle | 3.9 | 4.11 | 4.0 |
\n
| topWindow | x | x | 4.0 |
\n
| leftWindow | x | x | 4.0 |
\n
| rightWindow | x | x | 4.0 |
\n
| pages | 3.9 | 4.11 | 4.0 |
\n
| tabBar | 3.9 | 4.11 | 4.0 |
\n
| condition | 3.9 | 4.11 | 4.0 |
\n
| subPackages | x | x | 4.0 |
\n
| workers | x | x | 4.0 |
\n
| preloadRule | x | x | 4.0 |
\n
| easycom | 3.9 | 4.11 | 4.0 |
\n
| uniIdRouter | 3.99 | 4.11 | 4.0 |
\n
| entryPagePath | x | x | 4.0 |"
,
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| globalStyle | [globalStyle 配置项列表](#pages-globalstyle) | - | 否 | 默认页面的窗口表现 |
\n
| topWindow | [topWindow 配置项列表](#pages-topwindow) | - | 否 | 上窗体 |
\n
| leftWindow | [leftWindow 配置项列表](#pages-leftwindow) | - | 否 | 左窗体 |
\n
| rightWindow | [rightWindow 配置项列表](#pages-rightwindow) | - | 否 | 右窗体 |
\n
| pages | Array
\\
<[PagesOptionsPage](#pagesoptionspage)> | - | 是 | 页面路径及窗口表现 |
\n
| tabBar | [tabBar 配置项列表](#pages-tabbar) | - | 否 | 底部 tab 的表现 |
\n
| condition | [condition 配置项列表](#pages-condition) | - | 否 | 启动模式 |
\n
| subPackages | Array
\\
<[PagesSubPackages](#pagessubpackages)> | - | 否 | 分包加载配置 |
\n
| workers | string | - | 否 | 使用 Worker 处理多线程任务时,设置 Worker 代码放置的目录 |
\n
| preloadRule | object | - | 否 | 声明分包预下载的规则 |
\n
| easycom | [easycom 配置项列表](#pages-easycom) | - | 否 | 组件自动引入规则 |
\n
| uniIdRouter | [uniIdRouter 配置项列表](#pages-uniidrouter) | - | 否 | 根据用户登录状态、页面是否要求登录、以及接口返回的用户token验证状态自动跳转登录页面。详细教程:[详见](https://doc.dcloud.net.cn/uniCloud/uni-id/summary.html#uni-id-router) |
\n
| entryPagePath | string | - | 否 | 默认启动首页,新增于HBuilderX 3.7.0 |"
},
"pages_globalStyle"
:{
"compatibility"
:
"**globalStyle 兼容性**
\n
| | Android | iOS | web |
\n
| :- | :- | :- | :- |
\n
| navigationBarBackgroundColor | 3.9 | 4.11 | 4.0 |
\n
| navigationBarTextStyle | 3.9 | 4.11 | 4.0 |
\n
| navigationBarTitleText | 3.9 | 4.11 | 4.0 |
\n
| navigationStyle | 3.9 | 4.11 | 4.0 |
\n
| backgroundColor | 3.99 | x | x |
\n
| backgroundColorContent | 4.0 | 4.11 | 4.11 |
\n
| enablePullDownRefresh | 3.9 | 4.11 | 4.0 |
\n
| onReachBottomDistance | x | x | 4.0 |
\n
| backgroundColorTop | x | x | 4.0 |
\n
| backgroundColorBottom | x | x | 4.0 |
\n
| titleImage | x | x | 4.0 |
\n
| transparentTitle | x | x | 4.0 |
\n
| titlePenetrate | x | x | 4.0 |
\n
| pageOrientation | 4.13 | x | x |
\n
| usingComponents | x | x | 4.0 |
\n
| leftWindow | x | x | 4.0 |
\n
| topWindow | x | x | 4.0 |
\n
| rightWindow | x | x | 4.0 |
\n
| rpxCalcMaxDeviceWidth | x | x | 4.0 |
\n
| rpxCalcBaseDeviceWidth | x | x | 4.0 |
\n
| rpxCalcIncludeWidth | x | x | 4.0 |
\n
| maxWidth | x | x | 4.0 |
\n
| h5 | x | x | 4.0 |"
,
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| navigationBarBackgroundColor | string ([string.ColorString](/uts/data-type.md#ide-string)) | `app`: #F8F8F8<br/>`web`: #F8F8F8<br/>`mp-weixin、mp-qq、mp-baidu、mp-toutiao、mp-lark、mp-jd`: #000000<br/>`mp-alipay、mp-kuaishou`: #ffffff | 否 | 导航栏背景颜色(同状态栏背景色) |
\n
| navigationBarTextStyle | 'white'
\\
| 'black' |
\"
black
\"
| 否 | 导航栏标题颜色,仅支持 black/white(支付宝小程序不支持,请使用 [my.setNavigationBar](https://opendocs.alipay.com/mini/api/xwq8e6))。 |
\n
| navigationBarTitleText | string | - | 否 | 导航栏标题文字内容 |
\n
| navigationStyle | 'default'
\\
| 'custom' |
\"
default
\"
| 否 | 导航栏样式,仅支持 default/custom。custom即取消默认的原生导航栏,需看[使用注意](https://uniapp.dcloud.net.cn/collocation/pages.html#customnav)。 |
\n
| backgroundColor | string ([string.ColorString](/uts/data-type.md#ide-string)) |
\"
#ffffff
\"
| 否 | 下拉刷新显示出来的窗口的背景色(无下拉刷新时,此颜色无效果) |
\n
| backgroundColorContent | string ([string.ColorString](/uts/data-type.md#ide-string)) |
\"
#ffffff
\"
| 否 | 页面容器背景色 |
\n
| enablePullDownRefresh | boolean | false | 否 | 是否开启下拉刷新,详见[页面生命周期](https://doc.dcloud.net.cn/uni-app-x/page.html)。 |
\n
| onReachBottomDistance | number | 50 | 否 | 页面上拉触底事件触发时距页面底部距离,单位只支持px,详见[页面生命周期](https://doc.dcloud.net.cn/uni-app-x/page.html)。 |
\n
| backgroundColorTop | string ([string.ColorString](/uts/data-type.md#ide-string)) |
\"
#ffffff
\"
| 否 | 顶部窗口的背景色(bounce回弹区域), 仅 iOS 平台 |
\n
| backgroundColorBottom | string ([string.ColorString](/uts/data-type.md#ide-string)) |
\"
#ffffff
\"
| 否 | 底部窗口的背景色(bounce回弹区域), 仅 iOS 平台 |
\n
| titleImage | string ([string.ImageURIString](/uts/data-type.md#ide-string)) | - | 否 | 导航栏图片地址(替换当前文字标题),支付宝小程序内必须使用https的图片链接地址 |
\n
| transparentTitle | 'always'
\\
| 'auto'
\\
| 'none' |
\"
none
\"
| 否 | 导航栏整体(前景、背景)透明设置。支持 always 一直透明 / auto 滑动自适应 / none 不透明 |
\n
| titlePenetrate | 'YES'
\\
| 'NO' |
\"
NO
\"
| 否 | 导航栏点击穿透 |
\n
| pageOrientation | 'auto'
\\
| 'portrait'
\\
| 'landscape' |
\"
portrait
\"
| 否 | 横屏配置,屏幕旋转设置,仅支持 auto / portrait / landscape 详见 [响应显示区域变化](https://uniapp.dcloud.net.cn/collocation/pages.html#globalstyle)。 |
\n
| usingComponents | object | - | 否 | 引用小程序组件,参考 [小程序组件](https://uniapp.dcloud.net.cn/tutorial/miniprogram-subject.html)。 |
\n
| leftWindow | boolean | true | 否 | 当存在 leftWindow时,默认是否显示 leftWindow |
\n
| topWindow | boolean | true | 否 | 当存在 topWindow时,默认是否显示 topWindow |
\n
| rightWindow | boolean | true | 否 | 当存在 rightWindow时,默认是否显示 rightWindow |
\n
| rpxCalcMaxDeviceWidth | number | 960 | 否 | rpx 计算所支持的最大设备宽度,单位 px |
\n
| rpxCalcBaseDeviceWidth | number | 375 | 否 | rpx 计算使用的基准设备宽度,设备实际宽度超出 rpx 计算所支持的最大设备宽度时将按基准宽度计算,单位 px |
\n
| rpxCalcIncludeWidth | number | 750 | 否 | rpx 计算特殊处理的值,始终按实际的设备宽度计算,单位 rpx |
\n
| maxWidth | number | - | 否 | 单位px,当浏览器可见区域宽度大于maxWidth时,两侧留白,当小于等于maxWidth时,页面铺满;不同页面支持配置不同的maxWidth;maxWidth = leftWindow(可选)+page(页面主体)+rightWindow(可选) |
\n
| h5 | [h5 配置项列表](#globalstyle-h5) | - | 否 | H5 特有配置 |"
,
"description"
:
"默认页面的窗口表现"
},
"globalStyle_h5"
:{
"compatibility"
:
"**h5 兼容性**
\n
| | Android | iOS | web |
\n
| :- | :- | :- | :- |
\n
| titleNView | x | x | 4.0 |
\n
| pullToRefresh | x | x | 4.0 |"
,
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| titleNView | [titleNView 配置项列表](#h5-titlenview) | - | 否 | 导航栏设置 |
\n
| pullToRefresh | [pullToRefresh 配置项列表](#h5-pulltorefresh) | - | 否 | 下拉刷新 |"
,
"description"
:
"H5 特有配置"
},
"h5_titleNView"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| backgroundColor | string ([string.ColorString](/uts/data-type.md#ide-string)) |
\"
#f7f7f7
\"
| 否 | 背景颜色,颜色值格式为
\"
#RRGGBB
\"
。 |
\n
| buttons | array | - | 否 | 自定义按钮,参考 [buttons](https://uniapp.dcloud.net.cn/collocation/pages.html?id=h5-titlenview-buttons)。 |
\n
| titleColor | string ([string.ColorString](/uts/data-type.md#ide-string)) |
\"
#000000
\"
| 否 | 标题文字颜色 |
\n
| titleText | string | - | 否 | 标题文字内容 |
\n
| titleSize | string | - | 否 | 标题文字字体大小 |
\n
| type | 'defaultValue'
\\
| 'transparent' |
\"
defaultValue
\"
| 否 | 导航栏样式。
\"
default
\"
-默认样式;
\"
transparent
\"
-透明渐变。 |
\n
| searchInput | object | - | 否 | 导航栏上的搜索框样式,详见:[searchInput](https://uniapp.dcloud.net.cn/collocation/pages.html?id=h5-searchinput)。 |"
,
"description"
:
"导航栏设置"
},
"h5_pullToRefresh"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| support | boolean | - | 否 | 是否开启窗口的下拉刷新功能 |
\n
| color | string ([string.ColorString](/uts/data-type.md#ide-string)) | - | 否 | 颜色值格式为
\"
#RRGGBB
\"
,仅
\"
circle
\"
样式下拉刷新支持此属性。 |
\n
| type | 'defaultValue'
\\
| 'circle' | - | 否 | 下拉刷新控件样式 |
\n
| height | string | - | 否 | 窗口的下拉刷新控件进入刷新状态的拉拽高度。支持百分比,如
\"
10%
\"
;像素值,如
\"
50px
\"
。 |
\n
| range | string | - | 否 | 窗口可下拉拖拽的范围。支持百分比,如
\"
10%
\"
;像素值,如
\"
50px
\"
。 |
\n
| offset | string | - | 否 | 下拉刷新控件的起始位置。仅对
\"
circle
\"
样式下拉刷新控件有效,用于定义刷新控件下拉时的起始位置。支持百分比,如
\"
10%
\"
;像素值,如
\"
50px
\"
。 |
\n
| contentdown | [contentdown 配置项列表](#pulltorefresh-contentdown) | - | 否 | 在下拉可刷新状态时下拉刷新控件显示的内容 |
\n
| contentover | [contentover 配置项列表](#pulltorefresh-contentover) | - | 否 | 在释放可刷新状态时下拉刷新控件显示的内容 |
\n
| contentrefresh | [contentrefresh 配置项列表](#pulltorefresh-contentrefresh) | - | 否 | 在正在刷新状态时下拉刷新控件显示的内容 |"
,
"description"
:
"下拉刷新"
},
"pullToRefresh_contentdown"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| caption | string | - | 否 | 下拉刷新控件上显示的标题内容 |"
,
"description"
:
"在下拉可刷新状态时下拉刷新控件显示的内容"
},
"pullToRefresh_contentover"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| caption | string | - | 否 | 下拉刷新控件上显示的标题内容 |"
,
"description"
:
"在释放可刷新状态时下拉刷新控件显示的内容"
},
"pullToRefresh_contentrefresh"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| caption | string | - | 否 | 下拉刷新控件上显示的标题内容 |"
,
"description"
:
"在正在刷新状态时下拉刷新控件显示的内容"
},
"pages_topWindow"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| path | string | - | 否 | 配置页面路径 |
\n
| style | object | - | 否 | 配置页面窗口表现,配置项参考下方 [pageStyle](https://uniapp.dcloud.net.cn/collocation/pages.html?id=style) |
\n
| matchMedia | [matchMedia 配置项列表](#topwindow-matchmedia) | - | 否 | 配置显示该窗口的规则,配置项参考下方 [matchMedia](https://uniapp.dcloud.net.cn/collocation/pages.html?id=matchmedia) |"
,
"description"
:
"上窗体"
},
"topWindow_matchMedia"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| minWidth | number | 768 | 否 | 当设备可见区域宽度 minWidth 时,显示该 window+ |"
,
"description"
:
"配置显示该窗口的规则,配置项参考下方 [matchMedia](https://uniapp.dcloud.net.cn/collocation/pages.html?id=matchmedia)"
},
"pages_leftWindow"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| path | string | - | 否 | 配置页面路径 |
\n
| style | object | - | 否 | 配置页面窗口表现,配置项参考下方 [pageStyle](https://uniapp.dcloud.net.cn/collocation/pages.html?id=style) |
\n
| matchMedia | [matchMedia 配置项列表](#leftwindow-matchmedia) | - | 否 | 配置显示该窗口的规则,配置项参考下方 [matchMedia](https://uniapp.dcloud.net.cn/collocation/pages.html?id=matchmedia) |"
,
"description"
:
"左窗体"
},
"leftWindow_matchMedia"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| minWidth | number | 768 | 否 | 当设备可见区域宽度 minWidth 时,显示该 window+ |"
,
"description"
:
"配置显示该窗口的规则,配置项参考下方 [matchMedia](https://uniapp.dcloud.net.cn/collocation/pages.html?id=matchmedia)"
},
"pages_rightWindow"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| path | string | - | 否 | 配置页面路径 |
\n
| style | object | - | 否 | 配置页面窗口表现,配置项参考下方 [pageStyle](https://uniapp.dcloud.net.cn/collocation/pages.html?id=style) |
\n
| matchMedia | [matchMedia 配置项列表](#rightwindow-matchmedia) | - | 否 | 配置显示该窗口的规则,配置项参考下方 [matchMedia](https://uniapp.dcloud.net.cn/collocation/pages.html?id=matchmedia) |"
,
"description"
:
"右窗体"
},
"rightWindow_matchMedia"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| minWidth | number | 768 | 否 | 当设备可见区域宽度 minWidth 时,显示该 window+ |"
,
"description"
:
"配置显示该窗口的规则,配置项参考下方 [matchMedia](https://uniapp.dcloud.net.cn/collocation/pages.html?id=matchmedia)"
},
"PagesOptionsPage"
:{
"compatibility"
:
"**PagesOptionsPage 兼容性**
\n
| | Android | iOS | web |
\n
| :- | :- | :- | :- |
\n
| path | 3.9 | 4.11 | 4.0 |
\n
| style | 3.9 | 4.11 | 4.0 |
\n
| needLogin | 3.99 | 4.11 | 4.0 |"
,
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| path | string ([string.PageURIString](/uts/data-type.md#ide-string)) | - | 是 | 配置页面路径 |
\n
| style | [style 配置项列表](#pagesoptionspage-style) | - | 否 | 配置页面窗口表现,配置项参考下方 [pageStyle](https://doc.dcloud.net.cn/uni-app-x/collocation/pagesjson.html#pagesoptionspage-style)。 |
\n
| needLogin | boolean | false | 否 | 是否需要登录才可访问 |"
},
"PagesOptionsPage_style"
:{
"compatibility"
:
"**style 兼容性**
\n
| | Android | iOS | web |
\n
| :- | :- | :- | :- |
\n
| navigationBarBackgroundColor | 3.9 | 4.11 | 4.0 |
\n
| navigationBarTextStyle | 3.9 | 4.11 | 4.0 |
\n
| navigationBarTitleText | 3.9 | 4.11 | 4.0 |
\n
| navigationBarShadow | x | x | 4.0 |
\n
| navigationStyle | 3.9 | 4.11 | 4.0 |
\n
| backgroundColor | 3.99 | 4.11 | x |
\n
| backgroundColorContent | 4.0 | 4.11 | 4.11 |
\n
| backgroundTextStyle | x | x | 4.0 |
\n
| enablePullDownRefresh | 3.9 | 4.11 | 4.0 |
\n
| onReachBottomDistance | x | x | 4.0 |
\n
| pageOrientation | 4.13 | x | x |
\n
| backgroundColorTop | x | x | 4.0 |
\n
| backgroundColorBottom | x | x | 4.0 |
\n
| titleImage | x | x | 4.0 |
\n
| transparentTitle | x | x | 4.0 |
\n
| titlePenetrate | x | x | 4.0 |
\n
| usingComponents | x | x | 4.0 |
\n
| leftWindow | x | x | 4.0 |
\n
| topWindow | x | x | 4.0 |
\n
| rightWindow | x | x | 4.0 |
\n
| maxWidth | x | x | 4.0 |"
,
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| navigationBarBackgroundColor | string ([string.ColorString](/uts/data-type.md#ide-string)) | `app`: #F8F8F8<br/>`web`: #F8F8F8<br/>`mp-weixin、mp-qq、mp-baidu、mp-toutiao、mp-lark、mp-jd`: #000000<br/>`mp-alipay、mp-kuaishou`: #ffffff | 否 | 导航栏背景颜色(同状态栏背景色) |
\n
| navigationBarTextStyle | 'white'
\\
| 'black' |
\"
black
\"
| 否 | 导航栏标题颜色,仅支持 black/white |
\n
| navigationBarTitleText | string | - | 否 | 导航栏标题文字内容 |
\n
| navigationBarShadow | [navigationBarShadow 配置项列表](#style-navigationbarshadow) | - | 否 | 导航栏阴影,配置参考下方 [导航栏阴影](https://doc.dcloud.net.cn/uni-app-x/collocation/pagesjson.html#pagesoptionspage-style) |
\n
| navigationStyle | 'default'
\\
| 'custom' |
\"
default
\"
| 否 | 导航栏样式,仅支持 default/custom。custom即取消默认的原生导航栏,需看[使用注意](https://uniapp.dcloud.net.cn/collocation/pages.html#customnav)。 |
\n
| backgroundColor | string ([string.ColorString](/uts/data-type.md#ide-string)) |
\"
#ffffff
\"
| 否 | 下拉刷新显示出来的窗口的背景色(无下拉刷新时,此颜色无效果) |
\n
| backgroundColorContent | string ([string.ColorString](/uts/data-type.md#ide-string)) |
\"
#ffffff
\"
| 否 | 页面容器背景色 |
\n
| backgroundTextStyle | 'dark'
\\
| 'light' |
\"
dark
\"
| 否 | 下拉 loading 的样式,仅支持 dark/light |
\n
| enablePullDownRefresh | boolean | false | 否 | 是否开启下拉刷新,详见[页面生命周期](https://doc.dcloud.net.cn/uni-app-x/page.html)。 |
\n
| onReachBottomDistance | number | 50 | 否 | 页面上拉触底事件触发时距页面底部距离,单位只支持px,详见[页面生命周期](https://doc.dcloud.net.cn/uni-app-x/page.html)。 |
\n
| pageOrientation | 'auto'
\\
| 'portrait'
\\
| 'landscape' |
\"
portrait
\"
| 否 | 页面旋转设置,支持 auto 设备自适应 / portrait 竖向 / landscape 横向 |
\n
| backgroundColorTop | string ([string.ColorString](/uts/data-type.md#ide-string)) |
\"
#ffffff
\"
| 否 | 顶部窗口的背景色(bounce回弹区域), 仅 iOS 平台 |
\n
| backgroundColorBottom | string ([string.ColorString](/uts/data-type.md#ide-string)) |
\"
#ffffff
\"
| 否 | 底部窗口的背景色(bounce回弹区域), 仅 iOS 平台 |
\n
| titleImage | string ([string.ImageURIString](/uts/data-type.md#ide-string)) | - | 否 | 导航栏图片地址(替换当前文字标题),支付宝小程序内必须使用https的图片链接地址 |
\n
| transparentTitle | 'always'
\\
| 'auto'
\\
| 'none' |
\"
none
\"
| 否 | 导航栏整体(前景、背景)透明设置。支持 always 一直透明 / auto 滑动自适应 / none 不透明 |
\n
| titlePenetrate | 'YES'
\\
| 'NO' |
\"
NO
\"
| 否 | 导航栏点击穿透 |
\n
| h5 | [h5 配置项列表](#style-h5) | - | 否 | 编译到 H5 平台的特定样式 |
\n
| usingComponents | object | - | 否 | 引用小程序组件,参考 [小程序组件https://uniapp.dcloud.net.cn/tutorial/miniprogram-subject.html#小程序自定义组件支持)。 |
\n
| leftWindow | boolean | true | 否 | 当存在 leftWindow时,当前页面是否显示 leftWindow |
\n
| topWindow | boolean | true | 否 | 当存在 topWindow时,当前页面是否显示 topWindow |
\n
| rightWindow | boolean | true | 否 | 当存在 rightWindow时,当前页面是否显示 rightWindow |
\n
| maxWidth | number | - | 否 | 单位px,当浏览器可见区域宽度大于maxWidth时,两侧留白,当小于等于maxWidth时,页面铺满;不同页面支持配置不同的maxWidth;maxWidth = leftWindow(可选)+page(页面主体)+rightWindow(可选) |"
,
"description"
:
"配置页面窗口表现,配置项参考下方 [pageStyle](https://doc.dcloud.net.cn/uni-app-x/collocation/pagesjson.html#pagesoptionspage-style)。"
},
"style_navigationBarShadow"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| colorType | 'grey'
\\
| 'blue'
\\
| 'green'
\\
| 'orange'
\\
| 'red'
\\
| 'yellow' | - | 否 | 阴影的颜色,支持:grey、blue、green、orange、red、yellow |"
,
"description"
:
"导航栏阴影,配置参考下方 [导航栏阴影](https://doc.dcloud.net.cn/uni-app-x/collocation/pagesjson.html#pagesoptionspage-style)"
},
"style_h5"
:{
"compatibility"
:
"**h5 兼容性**
\n
| | Android | iOS | web |
\n
| :- | :- | :- | :- |
\n
| titleNView | x | x | 4.0 |
\n
| pullToRefresh | x | x | 4.0 |"
,
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| titleNView | [titleNView 配置项列表](#h5-titlenview) | - | 否 | 导航栏设置 |
\n
| pullToRefresh | [pullToRefresh 配置项列表](#h5-pulltorefresh) | - | 否 | 下拉刷新 |"
,
"description"
:
"编译到 H5 平台的特定样式"
},
"pages_tabBar"
:{
"compatibility"
:
"**tabBar 兼容性**
\n
| | Android | iOS | web |
\n
| :- | :- | :- | :- |
\n
| color | 3.9 | 4.11 | 4.0 |
\n
| selectedColor | 3.9 | 4.11 | 4.0 |
\n
| backgroundColor | 3.9 | 4.11 | 4.0 |
\n
| borderStyle | x | x | 4.0 |
\n
| blurEffect | x | x | 4.0 |
\n
| list | 3.9 | 4.11 | 4.0 |
\n
| fontSize | x | x | 4.0 |
\n
| iconWidth | x | x | 4.0 |
\n
| spacing | x | x | 4.0 |
\n
| height | x | x | 4.0 |
\n
| midButton | x | x | 4.0 |
\n
| iconfontSrc | x | x | 4.0 |
\n
| backgroundImage | 3.9 | 4.11 | x |
\n
| backgroundRepeat | 3.9 | 4.11 | x |
\n
| redDotColor | 3.9 | 4.11 | x |"
,
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| color | string ([string.ColorString](/uts/data-type.md#ide-string)) | - | 是 | tab 上的文字默认颜色 |
\n
| selectedColor | string ([string.ColorString](/uts/data-type.md#ide-string)) | - | 是 | tab 上的文字选中时的颜色 |
\n
| backgroundColor | string ([string.ColorString](/uts/data-type.md#ide-string)) | - | 是 | tab 的背景色 |
\n
| borderStyle | string |
\"
black
\"
| 否 | tabbar 上边框的颜色,可选值 black、white(App、H5 也支持其他颜色值)。 |
\n
| blurEffect | 'dark'
\\
| 'extralight'
\\
| 'light'
\\
| 'none' |
\"
none
\"
| 否 | IOS 高斯模糊效果,可选值 dark/extralight/light/none(参考:[使用说明](https://uniapp.dcloud.net.cn//tutorial/app-blureffect.html)) |
\n
| list | Array
\\
<[PagesOptionsTabbarList](#pagesoptionstabbarlist)> | - | 是 | tab 的列表,详见 list 属性说明,最少2个、最多5个 tab |
\n
| fontSize | string |
\"
10px
\"
| 否 | 文字默认大小 |
\n
| iconWidth | string |
\"
24px
\"
| 否 | 图标默认宽度(高度等比例缩放) |
\n
| spacing | string |
\"
3px
\"
| 否 | 图标和文字的间距 |
\n
| height | string |
\"
50px
\"
| 否 | tabBar 默认高度 |
\n
| midButton | [midButton 配置项列表](#tabbar-midbutton) | - | 否 | 中间按钮 仅在 list 项为偶数时有效 |
\n
| iconfontSrc | string | - | 否 | list设置 iconfont 属性时,需要指定字体文件路径 |
\n
| backgroundImage | string | - | 否 | 设置背景图片,优先级高于 backgroundColor |
\n
| backgroundRepeat | 'repeat'
\\
| 'repeat-x'
\\
| 'repeat-y'
\\
| 'no-repeat' |
\"
no-repeat
\"
| 否 | 设置标题栏的背景图平铺方式 |
\n
| redDotColor | string ([string.ColorString](/uts/data-type.md#ide-string)) | - | 否 | tabbar上红点颜色 |"
,
"description"
:
"底部 tab 的表现"
},
"PagesOptionsTabbarList"
:{
"compatibility"
:
"**PagesOptionsTabbarList 兼容性**
\n
| | Android | iOS | web |
\n
| :- | :- | :- | :- |
\n
| iconfont | 3.9 | 4.11 | 4.0 |
\n
| pagePath | 3.9 | 4.11 | 4.0 |
\n
| text | 3.9 | 4.11 | 4.0 |
\n
| iconPath | 3.9 | 4.11 | 4.0 |
\n
| selectedIconPath | 3.9 | 4.11 | 4.0 |
\n
| visible | 3.9 | 4.11 | 4.0 |"
,
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| iconfont | [iconfont 配置项列表](#pagesoptionstabbarlist-iconfont) | - | 否 | 字体图标,优先级高于 iconPath |
\n
| pagePath | string ([string.PageURIString](/uts/data-type.md#ide-string)) | - | 是 | 页面路径,必须在 pages 中先定义 |
\n
| text | string | - | 是 | tab 上按钮文字,在 App 和 H5 平台为非必填。例如中间可放一个没有文字的+号图标 |
\n
| iconPath | string ([string.ImageURIString](/uts/data-type.md#ide-string)) | - | 否 | 图片路径,icon 大小限制为40kb,建议尺寸为 81px * 81px,当 position 为 top 时,此参数无效,不支持网络图片,不支持字体图标 |
\n
| selectedIconPath | string ([string.ImageURIString](/uts/data-type.md#ide-string)) | - | 否 | 选中时的图片路径,icon 大小限制为40kb,建议尺寸为 81px * 81px ,当 position 为 top 时,此参数无效 |
\n
| visible | boolean | - | 否 | 该项是否显示,默认显示 |"
},
"PagesOptionsTabbarList_iconfont"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| text | string | - | 否 | 字库 Unicode 码 |
\n
| selectedText | string | - | 否 | 选中后字库 Unicode 码 |
\n
| fontSize | string | - | 否 | 字体图标字号(px) |
\n
| color | string ([string.ColorString](/uts/data-type.md#ide-string)) | - | 否 | 字体图标颜色 |
\n
| selectedColor | string ([string.ColorString](/uts/data-type.md#ide-string)) | - | 否 | 字体图标选中颜色 |"
,
"description"
:
"字体图标,优先级高于 iconPath"
},
"tabBar_midButton"
:{
"compatibility"
:
"**midButton 兼容性**
\n
| | Android | iOS | web |
\n
| :- | :- | :- | :- |
\n
| width | x | x | 4.0 |
\n
| height | x | x | 4.0 |
\n
| text | x | x | 4.0 |
\n
| iconPath | x | x | 4.0 |
\n
| iconWidth | x | x | 4.0 |
\n
| backgroundImage | x | x | 4.0 |"
,
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| width | string |
\"
80px
\"
| 否 | 中间按钮的宽度,tabBar 其它项为减去此宽度后平分,默认值为与其它项平分宽度 |
\n
| height | string |
\"
80px
\"
| 否 | 中间按钮的高度,可以大于 tabBar 高度,达到中间凸起的效果 |
\n
| text | string | - | 否 | 中间按钮的文字 |
\n
| iconPath | string ([string.ImageURIString](/uts/data-type.md#ide-string)) | - | 否 | 中间按钮的图片路径 |
\n
| iconWidth | string |
\"
24px
\"
| 否 | 图标默认宽度(高度等比例缩放) |
\n
| backgroundImage | string ([string.ImageURIString](/uts/data-type.md#ide-string)) | - | 否 | 中间按钮的背景图片路径 |"
,
"description"
:
"中间按钮 仅在 list 项为偶数时有效"
},
"pages_condition"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| current | number | - | 是 | 当前激活的模式,list节点的索引值。 |
\n
| list | Array
\\
<[PagesConditionItem](#pagesconditionitem)> | - | 是 | 启动模式列表 |"
,
"description"
:
"启动模式"
},
"PagesConditionItem"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| name | string | - | 是 | 启动模式名称 |
\n
| path | string ([string.PageURIString](/uts/data-type.md#ide-string)) | - | 是 | 启动页面路径 |
\n
| query | string | - | 否 | 启动参数,可在页面的 onLoad 函数里获得 |"
},
"PagesSubPackages"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| root | string | - | 是 | 子包的根目录 |
\n
| pages | Array
\\
<[PagesOptionsPage](#pagesoptionspage)> | - | 是 | 子包由哪些页面组成 |"
},
"pages_easycom"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| autoscan | boolean | true | 否 | 是否开启自动扫描,开启后将会自动扫描符合components/组件名称/组件名称.vue/uvue目录结构的组件 |
\n
| custom | object | - | 否 | 以正则方式自定义组件匹配规则。如果autoscan不能满足需求,可以使用custom自定义匹配规则 |"
,
"description"
:
"组件自动引入规则"
},
"pages_uniIdRouter"
:{
"table"
:
"| 属性 | 类型 | 默认值 | 必填 | 描述 |
\n
| :- | :- | :- | :- | :- |
\n
| loginPage | string ([string.PageURIString](/uts/data-type.md#ide-string)) | - | 否 | 登录页面路径 |
\n
| resToLogin | boolean | - | 否 | 是否开启自动根据响应体判断跳转登录页面,默认true(开启) |
\n
| needLogin | Array
\\
<string,[string.PageURIString](/uts/data-type.md#ide-string)> | - | 否 | - |"
,
"description"
:
"根据用户登录状态、页面是否要求登录、以及接口返回的用户token验证状态自动跳转登录页面。详细教程:[详见](https://doc.dcloud.net.cn/uniCloud/uni-id/summary.html#uni-id-router)"
},
"tutorial"
:
"## 参见
\n
[相关 Bug](https://issues.dcloud.net.cn/?mid=collocation.pages_json)"
}
\ No newline at end of file
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录