diff --git a/examples/hello-uniapp/pages.json b/examples/hello-uniapp/pages.json
index 735de004ab9d09dba121fd5055e68d60775443c8..998db06a646a9e5bfdb719a802fd3dda49a57c9f 100644
--- a/examples/hello-uniapp/pages.json
+++ b/examples/hello-uniapp/pages.json
@@ -14,11 +14,6 @@
"color": "#999999"
}]
}
- },
- "h5": {
- "titleNView": {
- "buttons": []
- }
}
}
},
@@ -35,11 +30,6 @@
"color": "#999999"
}]
}
- },
- "h5": {
- "titleNView": {
- "buttons": []
- }
}
}
},
@@ -56,11 +46,6 @@
"color": "#999999"
}]
}
- },
- "h5": {
- "titleNView": {
- "buttons": []
- }
}
}
},
@@ -485,6 +470,12 @@
"navigationBarTitleText": "关于"
}
},
+ {
+ "path": "platforms/h5/about/about",
+ "style": {
+ "navigationBarTitleText": "关于"
+ }
+ },
{
"path": "platforms/app-plus/tabbar/tabbar",
"style": {
diff --git a/examples/hello-uniapp/pages/tabBar/API/API.vue b/examples/hello-uniapp/pages/tabBar/API/API.vue
index 1cb854c157654cf5f940a517cbeb24b6dcbed289..f869e55592e7cc3b26618619b67314604cc3be13 100644
--- a/examples/hello-uniapp/pages/tabBar/API/API.vue
+++ b/examples/hello-uniapp/pages/tabBar/API/API.vue
@@ -234,7 +234,12 @@
},
onNavigationBarButtonTap(e) {
uni.navigateTo({
- url: '/platforms/app-plus/about/about'
+ // #ifdef APP-PLUS
+ url: '/platforms/app-plus/about/about',
+ // #endif
+ // #ifdef H5
+ url: '/platforms/h5/about/about',
+ // #endif
})
},
methods: {
diff --git a/examples/hello-uniapp/pages/tabBar/component/component.vue b/examples/hello-uniapp/pages/tabBar/component/component.vue
index ca296ba316e133c1d900a6c0d77efde1ed161cbe..598a52c2c7b020a092747b1730afa3d4cd914f5e 100644
--- a/examples/hello-uniapp/pages/tabBar/component/component.vue
+++ b/examples/hello-uniapp/pages/tabBar/component/component.vue
@@ -28,58 +28,62 @@
data() {
return {
lists: [{
- id: 'view',
- name: '视图容器',
- open: false,
- pages: [
- 'view',
- 'scroll-view',
- 'swiper',
- //#ifndef H5
- 'movable-view',
- //#endif
- ]
- }, {
- id: 'content',
- name: '基础内容',
- open: false,
- pages: ['text', 'rich-text', 'icon', 'progress']
- }, {
- id: 'form',
- name: '表单组件',
- open: false,
- pages: ['button', 'checkbox', 'form', 'input', 'label', 'picker', 'picker-view', 'radio',
- 'slider',
- 'switch', 'textarea'
- ]
- }, {
- id: 'nav',
- name: '导航',
- open: false,
- pages: ['navigator']
- }, {
- id: 'media',
- name: '媒体组件',
- open: false,
- pages: ['image', 'audio', 'video']
- }, {
- id: 'map',
- name: '地图',
- open: false,
- pages: ['map']
+ id: 'view',
+ name: '视图容器',
+ open: false,
+ pages: [
+ 'view',
+ 'scroll-view',
+ 'swiper',
+ //#ifndef H5
+ 'movable-view',
+ //#endif
+ ]
+ }, {
+ id: 'content',
+ name: '基础内容',
+ open: false,
+ pages: ['text', 'rich-text', 'icon', 'progress']
+ }, {
+ id: 'form',
+ name: '表单组件',
+ open: false,
+ pages: ['button', 'checkbox', 'form', 'input', 'label', 'picker', 'picker-view', 'radio',
+ 'slider',
+ 'switch', 'textarea'
+ ]
+ }, {
+ id: 'nav',
+ name: '导航',
+ open: false,
+ pages: ['navigator']
+ }, {
+ id: 'media',
+ name: '媒体组件',
+ open: false,
+ pages: ['image', 'audio', 'video']
+ }, {
+ id: 'map',
+ name: '地图',
+ open: false,
+ pages: ['map']
+
+ },
// #ifndef H5
- }, {
- id: 'web-view',
- name: '网页',
- open: false,
- pages: ['web-view'],
+ {
+ id: 'web-view',
+ name: '网页',
+ open: false,
+ pages: ['web-view'],
+
+ },
// #endif
- }]
+ ]
}
},
onLoad() {
// #ifdef APP-PLUS
- //web-view组件支持本地html,依赖最新版的客户端基座
+ // web-view组件支持本地html,依赖最新版的客户端基座
var innerversion = plus.runtime.innerVersion;
var _v = innerversion.substring(innerversion.lastIndexOf('.') + 1, innerversion.length);
if (_v && parseInt(_v) >= 53650) {
@@ -103,7 +107,12 @@
},
onNavigationBarButtonTap(e) {
uni.navigateTo({
- url: '/platforms/app-plus/about/about'
+ // #ifdef APP-PLUS
+ url: '/platforms/app-plus/about/about',
+ // #endif
+ // #ifdef H5
+ url: '/platforms/h5/about/about',
+ // #endif
})
},
methods: {
diff --git a/examples/hello-uniapp/pages/tabBar/template/template.vue b/examples/hello-uniapp/pages/tabBar/template/template.vue
index 9a82911b476a6b2102eec0ded7ae889eea814c7c..238b392c22592629be2539a11fa27f554ba7ca85 100644
--- a/examples/hello-uniapp/pages/tabBar/template/template.vue
+++ b/examples/hello-uniapp/pages/tabBar/template/template.vue
@@ -191,12 +191,12 @@
}, {
name: '倒计时',
url: 'countdown'
- }
+ },
// #ifdef APP-PLUS
- , {
+ {
name: '聊天窗口 chat',
url: 'im-chat'
- }
+ },
// #endif
]
}
@@ -209,7 +209,12 @@
},
onNavigationBarButtonTap(e) {
uni.navigateTo({
- url: '/platforms/app-plus/about/about'
+ // #ifdef APP-PLUS
+ url: '/platforms/app-plus/about/about',
+ // #endif
+ // #ifdef H5
+ url: '/platforms/h5/about/about',
+ // #endif
})
},
methods: {
diff --git a/examples/hello-uniapp/platforms/h5/about/about.vue b/examples/hello-uniapp/platforms/h5/about/about.vue
new file mode 100644
index 0000000000000000000000000000000000000000..8f427890f13f981a89272b30f7b963eb6f665d2e
--- /dev/null
+++ b/examples/hello-uniapp/platforms/h5/about/about.vue
@@ -0,0 +1,71 @@
+
+
+
+
+
+ 扫码体验uni-app
+
+
+ uni-app
+ 是一个使用 Vue.js 开发跨平台应用的前端框架 。
+
+
+
+
+
+
+
+