提交 7b39c084 编写于 作者: H hdx

canvas: 移动到模板 tab

上级 9df7d42b
...@@ -234,14 +234,6 @@ ...@@ -234,14 +234,6 @@
"navigationBarTitleText": "redirectPage" "navigationBarTitleText": "redirectPage"
} }
}, },
// #ifdef WEB
{
"path": "pages/component/canvas/canvas",
"style": {
"navigationBarTitleText": "canvas"
}
},
// #endif
{ {
"path": "pages/component/web-view/web-view", "path": "pages/component/web-view/web-view",
"style": { "style": {
...@@ -1115,6 +1107,14 @@ ...@@ -1115,6 +1107,14 @@
"navigationBarTitleText": "自定义TabBar" "navigationBarTitleText": "自定义TabBar"
} }
}, },
// #ifdef WEB
{
"path": "pages/template/browser-canvas/browser-canvas",
"style": {
"navigationBarTitleText": "如何使用浏览器 canvas"
}
},
// #endif
// #ifdef APP // #ifdef APP
{ {
"path": "pages/template/calendar/calendar", "path": "pages/template/calendar/calendar",
......
...@@ -182,29 +182,25 @@ ...@@ -182,29 +182,25 @@
}, */ }, */
] as Page[], ] as Page[],
}, },
/* // {
{ // id: 'map',
id: 'map', // name: '地图',
name: '地图', // pages: [
pages: [ // {
{ // name: 'map',
name: 'map', // enable: false
enable: false // }
} // ] as Page[]
] as Page[] // },
}, // {
*/ // id: 'canvas',
// #ifdef WEB // name: '画布',
{ // pages: [
id: 'canvas', // {
name: '画布', // name: 'canvas'
pages: [ // }
{ // ] as Page[]
name: 'canvas' // },
}
] as Page[]
},
// #endif
{ {
id: 'web-view', id: 'web-view',
name: '网页', name: '网页',
......
...@@ -185,6 +185,15 @@ ...@@ -185,6 +185,15 @@
open: false, open: false,
pages: [] as Page[], pages: [] as Page[],
}, },
// #endif
// #ifdef WEB
{
id: 'browser-canvas',
url: 'browser-canvas',
name: '如何使用浏览器 canvas',
open: false,
pages: [] as Page[],
},
// #endif // #endif
] as ListItem[], ] as ListItem[],
arrowUpIcon: '/static/icons/arrow-up.png', arrowUpIcon: '/static/icons/arrow-up.png',
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
export default { export default {
data() { data() {
return { return {
title: 'Canvas', title: '浏览器 canvas',
drawing: null as UniElement | null, drawing: null as UniElement | null,
canvasElement: null as HTMLCanvasElement | null, canvasElement: null as HTMLCanvasElement | null,
canvasContext: null as CanvasRenderingContext2D | null, canvasContext: null as CanvasRenderingContext2D | null,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册