{"dependencies":[{"ETag":"067338CB68E1ED7E79A7160469D7CA12","name":"0.json","size":157513,"type":"json","url":"https://gw.alipayobjects.com/os/tb_miniapp_doc/32049cb6-1093-4538-894b-e06e23287779/herbox/0.json"}],"sourceCode":{"app.acss":"page {\n background-color: #f7f7f7;\n box-sizing: border-box;\n}\n\n.page {\n font-family: -apple-system-font, Helvetica Neue, Helvetica, sans-serif;\n font-size: 24rpx;\n padding: 32rpx;\n flex: 1;\n}\n\n.page-description {\n margin-bottom: 32rpx;\n}\n\n.page-section {\n background: #fff;\n margin-bottom: 32rpx;\n}\n\n.page-section-title {\n padding: 16rpx 32rpx;\n}\n\n.page-section-demo {\n padding: 32rpx;\n}\n\n.page-section-btns {\n border-top: 1px solid #ddd;\n display: flex;\n justify-content: space-around;\n align-items: center;\n}\n\n.page-section-btns > view {\n flex: 1;\n height: 84rpx;\n display: flex;\n align-items: center;\n justify-content: space-around;\n color: #ff5500;\n}\n.page-section-btns > view + view {\n border-left: 1px solid #ddd;\n}\n\nbutton {\n margin-top: 20rpx;\n margin-bottom: 20rpx;\n}\n\n.bc_blue {\n background-color: #49a9ee;\n}\n\n.bc_red {\n background-color: #f04134;\n}\n\n.bc_yellow {\n background-color: #ffbf00;\n}\n\n.bc_green {\n background-color: #00a854;\n}\n\n.form-row {\n display: flex;\n align-items: center;\n padding: 0 30rpx;\n height: 88rpx;\n align-items: center;\n}\n\n.form-row-label {\n width: 180rpx;\n font-size: 34rpx;\n margin-right: 10rpx;\n text-align: left;\n color: #000;\n}\n\n.form-row-content {\n flex: 1;\n font-size: 34rpx;\n}\n\n.form-line {\n height: 1px;\n background-color: #ddd;\n margin-left: 30rpx;\n}\n","app.js":"App({\n onLaunch(options) {\n console.log('App Launch', options);\n console.log('getSystemInfoSync', my.getSystemInfoSync());\n console.log('SDKVersion', my.SDKVersion);\n },\n onShow() {\n console.log('App Show');\n },\n onHide() {\n console.log('App Hide');\n },\n globalData: {\n hasLogin: false,\n },\n});\n","app.json":"{\n \"pages\": [\n \"page/tabBar/component/index\",\n \"page/tabBar/API/index\",\n \"page/common/search/search\"\n ],\n \"subPackages\": [\n {\n \"root\": \"page/API\",\n \"pages\": [\n \"events/events\",\n \"share/share\",\n \"action-sheet/action-sheet\",\n \"alert/alert\",\n \"animation/animation\",\n \"canvas/canvas\",\n \"card-pack/card-pack\",\n \"choose-city/choose-city\",\n \"choose-location/choose-location\",\n \"confirm/confirm\",\n \"contact/contact\",\n \"date-picker/date-picker\",\n \"option-menu/option-menu\",\n \"download-file/download-file\",\n \"file/file\",\n \"ocr/ocr\",\n \"ocr-idcard-face/ocr-idcard-face\",\n \"ocr-business-card/ocr-business-card\",\n \"ocr-vehicle/ocr-vehicle\",\n \"ocr-driver-license/ocr-driver-license\",\n \"ocr-business-license/ocr-business-license\",\n \"ocr-bank-card/ocr-bank-card\",\n \"ocr-train-ticket/ocr-train-ticket\",\n \"ocr-passport/ocr-passport\",\n \"ocr-general/ocr-general\",\n \"ocr-vehicle-plate/ocr-vehicle-plate\",\n \"ocr-vin/ocr-vin\",\n \"get-auth-code/get-auth-code\",\n \"get-location/get-location\",\n \"get-network-type/get-network-type\",\n \"get-system-info/get-system-info\",\n \"get-server-time/get-server-time\",\n \"get-user-info/get-user-info\",\n \"get-image-info/get-image-info\",\n \"image/image\",\n \"keyboard/keyboard\",\n \"loading/loading\",\n \"make-phone-call/make-phone-call\",\n \"memory-warning/memory-warning\",\n \"multi-level-select/multi-level-select\",\n \"options-select/options-select\",\n \"navigation-bar-loading/navigation-bar-loading\",\n \"navigator/navigator\",\n \"open-location/open-location\",\n \"pull-down-refresh/pull-down-refresh\",\n \"pay-sign-center/pay-sign-center\",\n \"request/request\",\n \"request-payment/request-payment\",\n \"scan-code/scan-code\",\n \"set-navigation-bar/set-navigation-bar\",\n \"show-auth-guide/show-auth-guide\",\n \"storage/storage\",\n \"toast/toast\",\n \"upload-file/upload-file\",\n \"vibrate/vibrate\",\n \"watch-shake/watch-shake\",\n \"clipboard/clipboard\",\n \"bluetooth/bluetooth\",\n \"rsa/rsa\",\n \"page-scroll-to/page-scroll-to\",\n \"websocket/websocket\",\n \"zm-credit-borrow/zm-credit-borrow\",\n \"create-selector-query/create-selector-query\",\n \"sdk-version/sdk-version\",\n \"user-capture-screen/user-capture-screen\",\n \"screen/screen\",\n \"compress-image/compress-image\",\n \"report-analytics/report-analytics\",\n \"text-risk-identification/text-risk-identification\",\n \"create-inner-audiocontext/create-inner-audiocontext\",\n \"get-background-audio-manager/get-background-audio-manager\",\n \"generate-image-from-code/generate-image-from-code\",\n \"get-title-color/get-title-color\"\n ]\n },\n {\n \"root\": \"page/component\",\n \"pages\": [\n \"button/button\",\n \"canvas/canvas\",\n \"checkbox/checkbox\",\n \"form/form\",\n \"icon/icon\",\n \"image/image\",\n \"input/input\",\n \"label/label\",\n \"map/map\",\n \"navigator/navigate\",\n \"navigator/redirect\",\n \"navigator/reLaunch\",\n \"navigator/navigator\",\n \"picker/picker\",\n \"picker-view/picker-view\",\n \"progress/progress\",\n \"radio/radio\",\n \"scroll-view/scroll-view\",\n \"slider/slider\",\n \"swiper/swiper\",\n \"switch/switch\",\n \"text/text\",\n \"textarea/textarea\",\n \"view/view\",\n \"lifestyle/lifestyle\",\n \"contact-button/contact-button\",\n \"webview/webview\",\n \"cover-view/cover-view\",\n \"movable-view/movable-view\",\n \"list/list\",\n \"tabs/tabs\",\n \"card/card\",\n \"vtabs/vtabs\",\n \"grid/grid\",\n \"steps/steps\",\n \"footer/footer\",\n \"favorite/favorite\",\n \"popover/popover\",\n \"modal/modal\",\n \"popup/popup\",\n \"filter/filter\",\n \"page-result/page-result\",\n \"message/message\",\n \"tips/tips\",\n \"notice/notice\",\n \"swipe-action/swipe-action\",\n \"amount-input/amount-input\",\n \"badge/badge\",\n \"search-bar/search-bar\",\n \"calendar/calendar\",\n \"stepper/stepper\",\n \"input-item/input-item\",\n \"am-checkbox/am-checkbox\",\n \"video/video\",\n \"am-icon/am-icon\",\n \"flex/flex\",\n \"rich-text/rich-text\"\n ]\n }\n ],\n \"preloadRule\": {\n \"page/tabBar/component/index\": {\n \"network\": \"all\",\n \"packages\": [\"page/component\"]\n },\n \"page/tabBar/API/index\": {\n \"network\": \"wifi\",\n \"packages\": [\"page/API\"]\n }\n },\n \"window\": {\n \"enableWK\": \"YES\",\n \"enableDSL\": true,\n \"defaultTitle\": \"商家应用\",\n \"backgroundColor\": \"#F5F5F9\",\n \"pullRefresh\": false,\n \"allowsBounceVertical\": \"YES\",\n \"titleBarColor\": \"#000\",\n \"navigationBarForceEnable\": \"true\"\n },\n \"tabBar\": {\n \"textColor\": \"#404040\",\n \"selectedColor\": \"#ff5500\",\n \"backgroundColor\": \"#F5F5F9\",\n \"items\": [\n {\n \"pagePath\": \"page/tabBar/component/index\",\n \"icon\": \"image/component.png\",\n \"activeIcon\": \"image/component_filled.png\",\n \"name\": \"组件\"\n },\n {\n \"pagePath\": \"page/tabBar/API/index\",\n \"icon\": \"image/api.png\",\n \"activeIcon\": \"image/api_filled.png\",\n \"name\": \"API\"\n }\n ]\n },\n \"debug\": true\n}\n","ext.json":"{\n \"extEnable\": false,\n \"ext\": {},\n \"extPages\": {\n \"pages/component/index\": {\n \"defaultTitle\": \"override\",\n \"optionMenu\": {\n \"icon\": \"xx\"\n }\n }\n },\n \"pages\": [\n \"pages/component/index\"\n ]\n}","mini.project.json":"{\n \"cloud\": {\n \"type\": \"CLOUDAPP\"\n },\n \"miniprogramRoot\": \"client\"\n}\n","package-lock.json":"{\n \"name\": \"mini-program-demo\",\n \"version\": \"1.0.0\",\n \"lockfileVersion\": 1,\n \"requires\": true,\n \"dependencies\": {\n \"mini-antui\": {\n \"version\": \"0.4.35\",\n \"resolved\": \"https://registry.npm.taobao.org/mini-antui/download/mini-antui-0.4.35.tgz\",\n \"integrity\": \"sha1-4y2N8cZKxVj4Rx2y5GBzsg3k3Sw=\"\n }\n }\n}\n","package.json":"{\n \"name\": \"mini-program-demo\",\n \"version\": \"1.0.0\",\n \"description\": \"\",\n \"main\": \"app.js\",\n \"scripts\": {\n \"test\": \"echo \\\"Error: no test specified\\\" && exit 1\"\n },\n \"author\": \"\",\n \"license\": \"ISC\",\n \"dependencies\": {\n \"mini-antui\": \"^0.4.18\"\n }\n}\n","page/API/action-sheet/action-sheet.axml":"<view class=\"page\">\n <view class=\"page-description\">操作菜单 API</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.showActionSheet</view>\n <view class=\"page-section-demo\">\n <button type=\"primary\" onTap=\"showActionSheet\">显示操作菜单</button>\n </view>\n </view>\n</view>\n","page/API/action-sheet/action-sheet.js":"Page({\n showActionSheet() {\n my.showActionSheet({\n title: '淘宝-ActionSheet',\n items: ['菜单一', '菜单二', '菜单三'],\n cancelButtonText: '取消好了',\n success: (res) => {\n const btn = res.index === -1 ? '取消' : '第' + res.index + '个';\n my.alert({\n title: `你点了${btn}按钮`\n });\n },\n });\n },\n});\n","page/API/action-sheet/action-sheet.json":"{\n \"defaultTitle\": \"Action Sheet\"\n}\n","page/API/alert/alert.axml":"<view class=\"page\">\n <view class=\"page-description\">警告框 API</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.alert</view>\n <view class=\"page-section-demo\">\n <button type=\"primary\" onTap=\"alert\">显示警告框</button>\n </view>\n </view>\n</view>\n","page/API/alert/alert.js":"Page({\n alert() {\n my.alert({\n title: '亲',\n content: '您本月的账单已出',\n buttonText: '我知道了',\n success: () => {\n my.alert({\n title: '用户点击了「我知道了」',\n });\n }\n });\n },\n})\n","page/API/alert/alert.json":"{\n \"defaultTitle\": \"Alert\"\n}\n","page/API/animation/animation.acss":".animation-element {\n width: 200rpx;\n height: 200rpx;\n background-color: #ff5500;\n transform: scaleX(1) scaleY(1);\n}\n","page/API/animation/animation.axml":"<view class=\"page\">\n <view class=\"page-description\">动画 API</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.createAnimation</view>\n <view class=\"page-section-demo\">\n <view class=\"animation-element\" animation=\"{{animation}}\"></view>\n </view>\n <view class=\"page-section-btns\">\n <view type=\"primary\" onTap=\"rotate\">旋转</view>\n <view type=\"primary\" onTap=\"scale\"> 缩放</view>\n <view type=\"primary\" onTap=\"translate\">移动</view>\n </view>\n <view class=\"page-section-btns\">\n <view type=\"primary\" onTap=\"skew\">倾斜</view>\n <view type=\"primary\" onTap=\"rotateAndScale\">旋转并缩放</view>\n <view type=\"primary\" onTap=\"rotateThenScale\">旋转后缩放</view>\n </view>\n <view class=\"page-section-btns\">\n <view type=\"primary\" onTap=\"all\">同时展示全部</view>\n <view type=\"primary\" onTap=\"allInQueue\">顺序展示全部</view>\n <view type=\"primary\" onTap=\"reset\">还原</view>\n </view>\n </view>\n</view>\n","page/API/animation/animation.js":"Page({\n onReady() {\n this.animation = my.createAnimation()\n },\n rotate() {\n this.animation.rotate(Math.random() * 720 - 360).step()\n this.setData({ animation: this.animation.export() })\n },\n scale() {\n this.animation.scale(Math.random() * 2).step()\n this.setData({ animation: this.animation.export() })\n },\n translate() {\n this.animation.translate(Math.random() * 100 - 50, Math.random() * 100 - 50).step()\n this.setData({ animation: this.animation.export() })\n },\n skew() {\n this.animation.skew(Math.random() * 90, Math.random() * 90).step()\n this.setData({ animation: this.animation.export() })\n },\n rotateAndScale() {\n this.animation.rotate(Math.random() * 720 - 360)\n .scale(Math.random() * 2)\n .step()\n this.setData({ animation: this.animation.export() })\n },\n rotateThenScale() {\n this.animation.rotate(Math.random() * 720 - 360).step()\n .scale(Math.random() * 2).step()\n this.setData({ animation: this.animation.export() })\n },\n all() {\n this.animation.rotate(Math.random() * 720 - 360)\n .scale(Math.random() * 2)\n .translate(Math.random() * 100 - 50, Math.random() * 100 - 50)\n .skew(Math.random() * 90, Math.random() * 90)\n .step()\n this.setData({ animation: this.animation.export() })\n },\n allInQueue() {\n this.animation.rotate(Math.random() * 720 - 360).step()\n .scale(Math.random() * 2).step()\n .translate(Math.random() * 100 - 50, Math.random() * 100 - 50).step()\n .skew(Math.random() * 90, Math.random() * 90).step()\n this.setData({ animation: this.animation.export() })\n },\n reset() {\n this.animation.rotate3d(0, 0, 0, 0)\n .rotateX(0)\n .rotateY(0)\n .rotateZ(0)\n .scale(1)\n .translate(0, 0)\n .skew(0, 0)\n .step({ duration: 0 })\n this.setData({ animation: this.animation.export() })\n }\n})\n","page/API/animation/animation.json":"{\n \"defaultTitle\": \"Animation\"\n}\n","page/API/bluetooth/bluetooth.acss":".help-info {\n padding:10px;\n color:#000000;\n}\n\n.help-title {\n padding:10px;\n color:#FC0D1B;\n}\n","page/API/bluetooth/bluetooth.axml":"<view class=\"page\">\n <view class=\"page-description\">蓝牙 API</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">本机蓝牙开关状态</view>\n <view class=\"page-section-demo\">\n <button type=\"primary\" onTap=\"openBluetoothAdapter\">初始化蓝牙</button>\n <button type=\"primary\" onTap=\"closeBluetoothAdapter\">关闭本机蓝牙</button>\n <button type=\"primary\" onTap=\"getBluetoothAdapterState\">获取蓝牙状态</button>\n </view>\n\n <view class=\"page-section-title\">扫描蓝牙设备</view>\n <view class=\"page-section-demo\">\n <button type=\"primary\" onTap=\"startBluetoothDevicesDiscovery\">开始搜索</button>\n <button type=\"primary\" onTap=\"getBluetoothDevices\">所有搜索到的设备</button>\n <button type=\"primary\" onTap=\"getConnectedBluetoothDevices\">所有已连接的设备</button>\n <button type=\"primary\" onTap=\"stopBluetoothDevicesDiscovery\">停止搜索</button>\n </view>\n\n <view class=\"page-section-title\">连接设备</view>\n <view class=\"page-section-demo\">\n <input class=\"input\" onInput=\"bindKeyInput\" type=\"{{text}}\" placeholder=\"输入要连接的设备的deviceId\"></input>\n <button type=\"primary\" onTap=\"connectBLEDevice\">连接设备</button>\n <button type=\"primary\" onTap=\"getBLEDeviceServices\">获取设备服务</button>\n <button type=\"primary\" onTap=\"getBLEDeviceCharacteristics\">获取读写特征</button>\n <button type=\"primary\" onTap=\"disconnectBLEDevice\">断开设备连接</button>\n </view>\n\n <view class=\"page-section-title\">读写数据</view>\n <view class=\"page-section-demo\">\n <button type=\"primary\" onTap=\"notifyBLECharacteristicValueChange\">监听特征值数据变化</button>\n <button type=\"primary\" onTap=\"readBLECharacteristicValue\">读取数据</button>\n <button type=\"primary\" onTap=\"writeBLECharacteristicValue\">写入数据</button>\n <button type=\"primary\" onTap=\"offBLECharacteristicValueChange\">取消特征值监听</button>\n </view>\n\n <view class=\"page-section-title\">其他事件</view>\n <view class=\"page-section-demo\">\n <button type=\"primary\" onTap=\"bluetoothAdapterStateChange\">本机蓝牙状态变化</button>\n <button type=\"primary\" onTap=\"offBluetoothAdapterStateChange\">取消本机蓝牙状态监听</button>\n <button type=\"primary\" onTap=\"BLEConnectionStateChanged\">蓝牙连接状态变化</button>\n <button type=\"primary\" onTap=\"offBLEConnectionStateChanged\">取消蓝牙连接状态监听</button>\n \n </view>\n\n </view>\n</view>","page/API/bluetooth/bluetooth.js":"Page({\n data: {\n devid: '0D9C82AD-1CC0-414D-9526-119E08D28124',\n serid: 'FEE7',\n notifyId: '36F6',\n writeId: '36F5',\n charid: '',\n alldev: [{ deviceId: '' }],\n },\n //获取本机蓝牙开关状态\n openBluetoothAdapter() {\n my.openBluetoothAdapter({\n success: res => {\n if (!res.isSupportBLE) {\n my.alert({ content: '抱歉,您的手机蓝牙暂不可用' });\n return;\n }\n my.alert({ content: '初始化成功!' });\n },\n fail: error => {\n my.alert({ content: JSON.stringify(error) });\n },\n });\n },\n closeBluetoothAdapter() {\n my.closeBluetoothAdapter({\n success: () => {\n my.alert({ content: '关闭蓝牙成功!' });\n },\n fail: error => {\n my.alert({ content: JSON.stringify(error) });\n },\n });\n },\n getBluetoothAdapterState() {\n my.getBluetoothAdapterState({\n success: res => {\n if (!res.available) {\n my.alert({ content: '抱歉,您的手机蓝牙暂不可用' });\n return;\n }\n my.alert({ content: JSON.stringify(res) });\n },\n fail: error => {\n my.alert({ content: JSON.stringify(error) });\n },\n });\n },\n //扫描蓝牙设备\n startBluetoothDevicesDiscovery() {\n my.startBluetoothDevicesDiscovery({\n allowDuplicatesKey: false,\n success: () => {\n my.onBluetoothDeviceFound({\n success: res => {\n // my.alert({content:'监听新设备'+JSON.stringify(res)});\n var deviceArray = res.devices;\n for (var i = deviceArray.length - 1; i >= 0; i--) {\n var deviceObj = deviceArray[i];\n //通过设备名称或者广播数据匹配目标设备,然后记录deviceID后面使用\n if (deviceObj.name == this.data.name) {\n my.alert({ content: '目标设备被找到' });\n my.offBluetoothDeviceFound();\n this.setData({\n deviceId: deviceObj.deviceId,\n });\n break;\n }\n }\n },\n fail: error => {\n my.alert({ content: '监听新设备失败' + JSON.stringify(error) });\n },\n });\n },\n fail: error => {\n my.alert({ content: '启动扫描失败' + JSON.stringify(error) });\n },\n });\n },\n //停止扫描\n stopBluetoothDevicesDiscovery() {\n my.stopBluetoothDevicesDiscovery({\n success: res => {\n my.offBluetoothDeviceFound();\n my.alert({ content: '操作成功!' });\n },\n fail: error => {\n my.alert({ content: JSON.stringify(error) });\n },\n });\n },\n //获取正在连接中的设备\n getConnectedBluetoothDevices() {\n my.getConnectedBluetoothDevices({\n success: res => {\n if (res.devices.length === 0) {\n my.alert({ content: '没有在连接中的设备!' });\n return;\n }\n my.alert({ content: JSON.stringify(res) });\n devid = res.devices[0].deviceId;\n },\n fail: error => {\n my.alert({ content: JSON.stringify(error) });\n },\n });\n },\n\n //获取所有搜索到的设备\n getBluetoothDevices() {\n my.getBluetoothDevices({\n success: res => {\n my.alert({ content: JSON.stringify(res) });\n },\n fail: error => {\n my.alert({ content: JSON.stringify(error) });\n },\n });\n },\n\n bindKeyInput(e) {\n this.setData({\n devid: e.detail.value,\n });\n },\n\n //连接设备\n connectBLEDevice() {\n my.connectBLEDevice({\n deviceId: this.data.devid,\n success: res => {\n my.alert({ content: '连接成功' });\n },\n fail: error => {\n my.alert({ content: JSON.stringify(error) });\n },\n });\n },\n //断开连接\n disconnectBLEDevice() {\n my.disconnectBLEDevice({\n deviceId: this.data.devid,\n success: () => {\n my.alert({ content: '断开连接成功!' });\n },\n fail: error => {\n my.alert({ content: JSON.stringify(error) });\n },\n });\n },\n //获取连接设备的server,必须要再连接状态状态之下才能获取\n getBLEDeviceServices() {\n my.getConnectedBluetoothDevices({\n success: res => {\n if (res.devices.length === 0) {\n my.alert({ content: '没有已连接的设备' });\n return;\n }\n my.getBLEDeviceServices({\n deviceId: this.data.devid,\n success: res => {\n my.alert({ content: JSON.stringify(res) });\n this.setData({\n serid: res.services[0].serviceId,\n });\n },\n fail: error => {\n my.alert({ content: JSON.stringify(error) });\n },\n });\n },\n });\n },\n //获取连接设备的charid,必须要再连接状态状态之下才能获取(这里分别筛选出读写特征字)\n getBLEDeviceCharacteristics() {\n my.getConnectedBluetoothDevices({\n success: res => {\n if (res.devices.length === 0) {\n my.alert({ content: '没有已连接的设备' });\n return;\n }\n this.setData({\n devid: res.devices[0].deviceId,\n });\n my.getBLEDeviceCharacteristics({\n deviceId: this.data.devid,\n serviceId: this.data.serid,\n success: res => {\n my.alert({ content: JSON.stringify(res) });\n //特征字对象属性见文档,根据属性匹配读写特征字并记录,然后后面读写使用\n this.setData({\n charid: res.characteristics[0].characteristicId,\n });\n },\n fail: error => {\n my.alert({ content: JSON.stringify(error) });\n },\n });\n },\n });\n },\n //读写数据\n readBLECharacteristicValue() {\n my.getConnectedBluetoothDevices({\n success: res => {\n if (res.devices.length === 0) {\n my.alert({ content: '没有已连接的设备' });\n return;\n }\n this.setData({\n devid: res.devices[0].deviceId,\n });\n my.readBLECharacteristicValue({\n deviceId: this.data.devid,\n serviceId: this.data.serid,\n characteristicId: this.data.notifyId,\n //1、安卓读取服务\n // serviceId:'0000180d-0000-1000-8000-00805f9b34fb',\n // characteristicId:'00002a38-0000-1000-8000-00805f9b34fb',\n success: res => {\n my.alert({ content: JSON.stringify(res) });\n },\n fail: error => {\n my.alert({ content: '读取失败' + JSON.stringify(error) });\n },\n });\n },\n });\n },\n\n writeBLECharacteristicValue() {\n my.getConnectedBluetoothDevices({\n success: res => {\n if (res.devices.length === 0) {\n my.alert({ content: '没有已连接的设备' });\n return;\n }\n this.setData({\n devid: res.devices[0].deviceId,\n });\n\n my.writeBLECharacteristicValue({\n deviceId: this.data.devid,\n serviceId: this.data.serid,\n characteristicId: this.data.charid,\n //安卓写入服务\n //serviceId:'0000180d-0000-1000-8000-00805f9b34fb',\n //characteristicId:'00002a39-0000-1000-8000-00805f9b34fb',\n value: 'ABCD',\n success: res => {\n my.alert({ content: '写入数据成功!' });\n },\n fail: error => {\n my.alert({ content: JSON.stringify(error) });\n },\n });\n },\n });\n },\n notifyBLECharacteristicValueChange() {\n my.getConnectedBluetoothDevices({\n success: res => {\n if (res.devices.length === 0) {\n my.alert({ content: '没有已连接的设备' });\n return;\n }\n this.setData({\n devid: res.devices[0].deviceId,\n });\n\n my.notifyBLECharacteristicValueChange({\n state: true,\n deviceId: this.data.devid,\n serviceId: this.data.serid,\n characteristicId: this.data.notifyId,\n success: () => {\n //监听特征值变化的事件\n my.onBLECharacteristicValueChange({\n success: res => {\n // my.alert({content: '特征值变化:'+JSON.stringify(res)});\n my.alert({ content: '得到响应数据 = ' + res.value });\n },\n });\n my.alert({ content: '监听成功' });\n },\n fail: error => {\n my.alert({ content: '监听失败' + JSON.stringify(error) });\n },\n });\n },\n });\n },\n offBLECharacteristicValueChange() {\n my.offBLECharacteristicValueChange();\n },\n //其他事件\n bluetoothAdapterStateChange() {\n my.onBluetoothAdapterStateChange(this.getBind('onBluetoothAdapterStateChange'));\n },\n onBluetoothAdapterStateChange() {\n if (res.error) {\n my.alert({ content: JSON.stringify(error) });\n } else {\n my.alert({ content: '本机蓝牙状态变化:' + JSON.stringify(res) });\n }\n },\n offBluetoothAdapterStateChange() {\n my.offBluetoothAdapterStateChange(this.getBind('onBluetoothAdapterStateChange'));\n },\n getBind(name) {\n if (!this[`bind${name}`]) {\n this[`bind${name}`] = this[name].bind(this);\n }\n return this[`bind${name}`];\n },\n BLEConnectionStateChanged() {\n my.onBLEConnectionStateChanged(this.getBind('onBLEConnectionStateChanged'));\n },\n onBLEConnectionStateChanged(res) {\n if (res.error) {\n my.alert({ content: JSON.stringify(error) });\n } else {\n my.alert({ content: '连接状态变化:' + JSON.stringify(res) });\n }\n },\n offBLEConnectionStateChanged() {\n my.offBLEConnectionStateChanged(this.getBind('onBLEConnectionStateChanged'));\n },\n onUnload() {\n this.offBLEConnectionStateChanged();\n this.offBLECharacteristicValueChange();\n this.offBluetoothAdapterStateChange();\n this.closeBluetoothAdapter();\n },\n});\n","page/API/bluetooth/bluetooth.json":"{\n \"defaultTitle\": \"Bluetooth\"\n}\n","page/API/canvas/canvas.acss":".canvas-element {\n width: 300px;\n align-self: stretch;\n height: 400px;\n}\n\n.canvas-buttons {\n padding: 50rpx 50rpx 10rpx;\n border-top: 1px solid #ccc;\n display: flex;\n flex-grow: 1;\n overflow-y: scroll;\n flex-direction: row;\n flex-wrap: wrap;\n align-self: stretch;\n height: 400rpx;\n box-sizing: border-box;\n}\n\n.canvas-button {\n font-size: 28rpx;\n width: 290rpx;\n margin: 20rpx auto;\n}\n\n.canvas-button-reset {\n width: 610rpx;\n margin: 20rpx auto;\n}\n","page/API/canvas/canvas.axml":"<view class=\"page\">\n <view class=\"page-description\">画布 API</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.createCanvasContext</view>\n <view class=\"page-section-demo\">\n <canvas class=\"canvas-element\" id=\"canvas\" onTap=\"log\" onTouchStart=\"log\"></canvas>\n </view>\n <scroll-view class=\"canvas-buttons\" scroll-y=\"true\">\n <button a:for=\"{{methods}}\" a:for-item=\"method\"\n class=\"canvas-button\" type=\"primary\" onTap=\"{{method}}\">{{method}}</button>\n </scroll-view>\n <scroll-view class=\"canvas-buttons\" scroll-y=\"true\" style=\"height: 150rpx;\">\n <button class=\"canvas-button\" type=\"primary\" onTap=\"toTempFilePath\">toTempFilePath</button>\n <button class=\"canvas-button\" type=\"primary\" onTap=\"getImageData\">getImageData</button>\n <button class=\"canvas-button\" type=\"primary\" onTap=\"putImageData\">putImageData</button>\n </scroll-view>\n </view>\n</view>\n\n","page/API/canvas/canvas.js":"import example from './example.js';\n\nlet imageData;\nPage({\n onLoad() {\n this.context = my.createCanvasContext('canvas');\n\n var methods = Object.keys(example);\n this.setData({\n methods: methods,\n });\n\n var that = this;\n methods.forEach(function(method) {\n that[method] = function() {\n example[method](that.context);\n that.context.draw();\n };\n });\n },\n log(e) {\n console.log('canvas', e);\n },\n toTempFilePath() {\n this.context.toTempFilePath({\n success(res) {\n my.previewImage({\n urls: [res.apFilePath],\n });\n },\n fail(res) {\n my.alert({\n title: 'toTempFilePath',\n content: `error: ${res.error}`,\n });\n },\n });\n },\n getImageData() {\n this.context.setFillStyle('red')\n this.context.fillRect(10, 10, 150, 100)\n this.context.draw(false, () => {\n this.context.getImageData({\n x: 0,\n y: 0,\n width: 100,\n height: 100,\n fail: error => {\n console.log(error);\n },\n success: (res) => {\n console.log(res.width); // 100\n console.log(res.height); // 100\n console.log(res.data instanceof Uint8ClampedArray); // true\n console.log(res.data.length); // 100 * 100 * 4\n imageData = res.data;\n },\n })\n });\n },\n\n putImageData() {\n this.context.clearRect(0,0,100,100);\n this.context.draw(true, () => {\n setTimeout(() => {\n this.context.putImageData({\n x: 0,\n y: 0,\n width: 100,\n data: imageData,\n fail: error => {\n console.log(error);\n },\n success(xx) {\n console.log('canvasPutImageData', xx)\n }\n })\n }, 2000)\n })\n },\n});\n","page/API/canvas/canvas.json":"{\n \"defaultTitle\": \"Canvas\"\n}\n","page/API/canvas/example.axml":"<view class=\"page\">\n <view class=\"page__hd\">\n <text class=\"page__title\">{{method}}</text>\n <text class=\"page__desc\">{{introduction}}</text>\n </view>\n <view class=\"page__bd\">\n <view class=\"section section_gap\">\n <canvas style=\"width: 100%; height: 300px;\" id=\"mycanvas\"></canvas>\n </view>\n </view>\n</view>","page/API/canvas/example.js":"var example = {};\n\nexample.rotate = function(context) {\n context.save();\n context.beginPath();\n context.rotate((10 * Math.PI) / 180);\n context.rect(225, 75, 20, 10);\n context.setFillStyle('#ff5500');\n context.fill();\n context.restore();\n};\n\nexample.scale = function(context) {\n context.save();\n context.beginPath();\n context.setStrokeStyle('#ff5500');\n context.rect(25, 25, 50, 50);\n context.stroke();\n\n context.scale(2, 2);\n\n context.beginPath();\n context.rect(25, 25, 50, 50);\n context.stroke();\n context.restore();\n};\n\nexample.reset = function(context) {\n context.save();\n context.beginPath();\n\n context.setFillStyle('#ff5500');\n context.setStrokeStyle('#ff5500');\n context.setFontSize(10);\n\n context.setShadow(0, 0, 0, 'rgba(0, 0, 0, 0)');\n\n context.setLineCap('butt');\n context.setLineJoin('miter');\n context.setLineWidth(1);\n context.setMiterLimit(10);\n context.restore();\n};\n\nexample.translate = function(context) {\n context.save();\n context.beginPath();\n context.setFillStyle('#ff5500');\n context.rect(10, 10, 100, 50);\n context.fill();\n\n context.translate(70, 70);\n\n context.beginPath();\n context.fill();\n context.restore();\n};\n\nexample.save = function(context) {\n context.save();\n context.beginPath();\n context.setStrokeStyle('#ff5500');\n context.save();\n\n context.scale(2, 2);\n context.setStrokeStyle('#ff5500');\n context.rect(0, 0, 100, 100);\n context.stroke();\n context.restore();\n\n context.rect(0, 0, 50, 50);\n context.stroke();\n context.restore();\n};\n\nexample.restore = function(context) {\n context.save();\n [3, 2, 1].forEach(function(item) {\n context.beginPath();\n context.setStrokeStyle('#ff5500');\n context.save();\n context.scale(item, item);\n context.rect(10, 10, 100, 100);\n context.stroke();\n context.restore();\n });\n context.restore();\n};\n\nexample.drawImage = function(context) {\n context.save();\n //example.rotate(context);\n context.drawImage('/image/ant.png', 0, 0);\n //example.fillText(context);\n context.restore();\n};\n\nexample.fillText = function(context) {\n context.save();\n context.beginPath();\n context.setStrokeStyle('#ff5500');\n context.moveTo(0, 10);\n context.lineTo(300, 10);\n context.stroke();\n\n // context.save();\n // context.scale(1.5, 1.5);\n // context.translate(20, 20);\n context.setFontSize(10);\n context.fillText('Hello Alipay', 0, 30);\n context.setFontSize(20);\n context.fillText('Hello Alipay', 200, 30);\n\n // context.restore();\n\n context.beginPath();\n context.moveTo(0, 30);\n context.lineTo(300, 30);\n context.stroke();\n context.restore();\n};\n\nexample.fill = function(context) {\n context.save();\n context.beginPath();\n context.setFillStyle('#ff5500');\n context.rect(20, 20, 150, 100);\n context.fill();\n context.restore();\n};\n\nexample.stroke = function(context) {\n context.save();\n context.beginPath();\n context.setStrokeStyle('#ff5500');\n context.moveTo(20, 20);\n context.lineTo(20, 100);\n context.lineTo(70, 100);\n\n context.stroke();\n context.restore();\n};\n\nexample.clearRect = function(context) {\n context.save();\n context.beginPath();\n context.setFillStyle('#ff5500');\n context.rect(0, 0, 300, 150);\n context.fill();\n context.clearRect(20, 20, 100, 50);\n context.restore();\n};\n\nexample.beginPath = function(context) {\n context.save();\n context.beginPath();\n context.setLineWidth(5);\n context.setStrokeStyle('#ff5500');\n context.moveTo(0, 75);\n context.lineTo(250, 75);\n context.stroke();\n\n context.beginPath();\n context.setStrokeStyle('#ff5500');\n context.moveTo(50, 0);\n context.lineTo(150, 130);\n context.stroke();\n context.restore();\n};\n\nexample.closePath = function(context) {\n context.save();\n context.beginPath();\n context.setStrokeStyle('#ff5500');\n context.moveTo(20, 20);\n context.lineTo(20, 100);\n context.lineTo(70, 100);\n context.closePath();\n context.stroke();\n context.restore();\n};\n\nexample.moveTo = function(context) {\n context.save();\n context.beginPath();\n context.setStrokeStyle('#ff5500');\n context.moveTo(0, 0);\n context.lineTo(300, 150);\n context.stroke();\n context.restore();\n};\n\nexample.lineTo = function(context) {\n context.save();\n context.beginPath();\n context.setStrokeStyle('#ff5500');\n context.moveTo(20, 20);\n context.lineTo(20, 100);\n context.lineTo(70, 100);\n context.stroke();\n context.restore();\n};\n\nexample.rect = function(context) {\n context.save();\n context.beginPath();\n context.setStrokeStyle('#ff5500');\n context.rect(20, 20, 150, 100);\n context.stroke();\n context.restore();\n};\n\nexample.arc = function(context) {\n context.save();\n context.beginPath();\n context.setStrokeStyle('#ff5500');\n context.arc(75, 75, 50, 0, Math.PI * 2, true);\n context.moveTo(110, 75);\n context.arc(75, 75, 35, 0, Math.PI, false);\n context.moveTo(65, 65);\n context.arc(60, 65, 5, 0, Math.PI * 2, true);\n context.moveTo(95, 65);\n context.arc(90, 65, 5, 0, Math.PI * 2, true);\n context.stroke();\n context.restore();\n};\n\nexample.quadraticCurveTo = function(context) {\n context.save();\n context.beginPath();\n context.setStrokeStyle('#ff5500');\n context.moveTo(20, 20);\n context.quadraticCurveTo(20, 100, 200, 20);\n context.stroke();\n context.restore();\n};\n\nexample.bezierCurveTo = function(context) {\n context.save();\n context.beginPath();\n context.setStrokeStyle('#ff5500');\n context.moveTo(20, 20);\n context.bezierCurveTo(20, 100, 200, 100, 200, 20);\n context.stroke();\n context.restore();\n};\n\nexample.setFillStyle = function(context) {\n context.save();\n [\n 'rgb(183, 218, 243)',\n 'rgb(39, 156, 240)',\n 'rgb(67, 168, 240)',\n 'rgb(119, 194, 247)',\n ].forEach(function(item, index) {\n context.setFillStyle(item);\n context.beginPath();\n context.rect(0 + 75 * index, 0, 50, 50);\n context.fill();\n });\n context.restore();\n};\n\nexample.gradient = function(ctx) {\n ctx.save();\n const grd = ctx.createCircularGradient(90, 60, 50);\n grd.addColorStop(0, 'blue');\n grd.addColorStop(1, 'red');\n ctx.setFillStyle(grd);\n ctx.fillRect(20, 20, 250, 180);\n ctx.restore();\n};\n\nexample.createPattern = function(ctx) {\n ctx.save();\n const grd = ctx.createPattern(\n 'https://gw.alipayobjects.com/zos/rmsportal/CuyuyNQuuJvOYOsYvPYd.png',\n 'repeat'\n );\n ctx.setFillStyle(grd);\n ctx.fillRect(20, 20, 250, 180);\n ctx.restore();\n};\n\nexample.setStrokeStyle = function(context) {\n context.save();\n [\n 'rgb(183, 218, 243)',\n 'rgb(39, 156, 240)',\n 'rgb(67, 168, 240)',\n 'rgb(119, 194, 247)',\n ].forEach(function(item, index) {\n context.setStrokeStyle(item);\n context.beginPath();\n context.rect(0 + 75 * index, 0, 50, 50);\n context.stroke();\n });\n context.restore();\n};\n\nexample.setGlobalAlpha = function(context) {\n context.save();\n context.setFillStyle('#ff5500');\n [1, 0.5, 0.1].forEach(function(item, index) {\n context.setGlobalAlpha(item);\n context.beginPath();\n context.rect(0 + 75 * index, 0, 50, 50);\n context.fill();\n });\n context.restore();\n};\n\nexample.setShadow = function(context) {\n context.save();\n context.beginPath();\n context.setFillStyle('#ff5500');\n context.setShadow(10, 10, 10, 'rgb(183, 218, 243)');\n context.rect(10, 10, 100, 100);\n context.fill();\n context.restore();\n};\n\nexample.setFontSize = function(context) {\n context.save();\n [10, 20, 30, 40].forEach(function(item, index) {\n context.setFontSize(item);\n context.fillText('Hello, world', 20, 20 + 40 * index);\n });\n context.restore();\n};\n\nexample.setLineCap = function(context) {\n context.save();\n context.setLineWidth(10);\n ['butt', 'round', 'square'].forEach(function(item, index) {\n context.beginPath();\n context.setStrokeStyle('#ff5500');\n context.setLineCap(item);\n context.moveTo(20, 20 + 20 * index);\n context.lineTo(100, 20 + 20 * index);\n context.stroke();\n });\n context.restore();\n};\n\nexample.setLineJoin = function(context) {\n context.save();\n context.setLineWidth(10);\n ['bevel', 'round', 'miter'].forEach(function(item, index) {\n context.beginPath();\n context.setStrokeStyle('#ff5500');\n context.setLineJoin(item);\n context.moveTo(20 + 80 * index, 20);\n context.lineTo(100 + 80 * index, 50);\n context.lineTo(20 + 80 * index, 100);\n context.stroke();\n });\n context.restore();\n};\n\nexample.setLineWidth = function(context) {\n context.save();\n [2, 4, 6, 8, 10].forEach(function(item, index) {\n context.beginPath();\n context.setStrokeStyle('#ff5500');\n context.setLineWidth(item);\n context.moveTo(20, 20 + 20 * index);\n context.lineTo(100, 20 + 20 * index);\n context.stroke();\n });\n context.restore();\n};\n\nexample.setMiterLimit = function(context) {\n context.save();\n context.setLineWidth(4);\n\n [2, 4, 6, 8, 10].forEach(function(item, index) {\n context.beginPath();\n context.setStrokeStyle('#ff5500');\n context.setMiterLimit(item);\n context.moveTo(20 + 80 * index, 20);\n context.lineTo(100 + 80 * index, 50);\n context.lineTo(20 + 80 * index, 100);\n context.stroke();\n });\n context.restore();\n};\n\nexample.measureText = function(context) {\n context.save();\n context.font = 'italic bold 50px cursive';\n const { width } = context.measureText('hello world');\n console.log(width);\n context.fillText('hello world', 20, 60);\n context.restore();\n};\n\nexample.setLineDash = function(context) {\n context.save();\n\n context.setLineDash([10, 20], 5);\n context.beginPath();\n context.moveTo(0, 100);\n context.lineTo(400, 100);\n context.stroke();\n\n context.restore();\n};\n\nexport default example;\n","page/API/card-pack/card-pack.axml":"<view class=\"page\">\r\n <view class=\"page-description\">卡包 API</view>\r\n <view class=\"page-section\">\r\n <view class=\"page-section-title\">卡/券/票 列表页</view>\r\n <view class=\"page-section-demo\">\r\n <button type=\"primary\" onTap=\"openCardList\">打开卡列表</button>\r\n <button type=\"primary\" onTap=\"openVoucherList\">打开券列表</button>\r\n <button type=\"primary\" onTap=\"openTicketList\">打开票列表</button>\r\n </view>\r\n\r\n <view class=\"page-section-title\">卡/券/票 详情页</view>\r\n <view class=\"page-section-demo\">\r\n <button type=\"primary\" onTap=\"openCardDetail\">打开卡详情页</button>\r\n <button type=\"primary\" onTap=\"openVoucherDetail\">打开劵详情页</button>\r\n <button type=\"primary\" onTap=\"openTicketDetail\">打开票详情页</button>\r\n <button type=\"primary\" onTap=\"openKBVoucherDetail\"> 打开口碑券详情</button>\r\n <button type=\"primary\" onTap=\"gotoDetail\"> 进入口碑客卡券详情</button>\r\n </view>\r\n\r\n <view class=\"page-section-title\">卡/券/票 单商户列表页</view>\r\n <view class=\"page-section-demo\">\r\n <button type=\"primary\" onTap=\"openMerchantCardList\">打开卡商户列表页</button>\r\n <button type=\"primary\" onTap=\"openMerchantVoucherList\">打开券商户列表页</button>\r\n <button type=\"primary\" onTap=\"openMerchantTicketList\">打开票商户列表页</button>\r\n </view>\r\n </view>\r\n</view>","page/API/card-pack/card-pack.js":"Page({\r\n data: {},\r\n onLoad() {},\r\n\r\n//-----------卡/券/票 列表页JSAPI: 只有success fail等回调入参\r\nopenCardList(){\r\n my.openCardList({\r\n success:(res)=>{\r\n my.showToast({content: '调用成功:'+JSON.stringify(res), });\r\n },\r\n fail:(error)=>{\r\n my.alert({content: '调用失败:'+JSON.stringify(error), });\r\n },\r\n complete:(res)=>{\r\n my.alert({content: 'complete回调!',});\r\n }\r\n });\r\n},\r\n\r\nopenVoucherList(){\r\n my.openVoucherList({\r\n success:(res)=>{\r\n my.showToast({content: '调用成功:'+JSON.stringify(res), });\r\n },\r\n fail:(error)=>{\r\n my.alert({content: '调用失败:'+JSON.stringify(error), });\r\n },\r\n complete:(e)=>{\r\n my.showToast({content: 'complete回调!',});\r\n }\r\n });\r\n},\r\n\r\nopenTicketList(){\r\n my.openTicketList({\r\n success:(res)=>{\r\n my.showToast({content: '调用成功:'+JSON.stringify(res), });\r\n },\r\n fail:(error)=>{\r\n my.alert({content: '调用失败:'+JSON.stringify(error), });\r\n },\r\n complete:(e)=>{\r\n my.showToast({content: 'complete回调!',});\r\n }\r\n });\r\n},\r\n\r\n//---------卡/券/票 详情页JSAPI: passId 或者 partnerId + serialNumber 二选一的入参\r\nopenCardDetail(){\r\n my.openCardDetail({//卡 不支持partnerId方式\r\n passId:'12339004637',\r\n success:(res)=>{\r\n my.showToast({content: '调用成功:'+JSON.stringify(res), });\r\n },\r\n fail:(error)=>{\r\n my.alert({content: '调用失败:'+JSON.stringify(error), });\r\n },\r\n complete:(res)=>{\r\n my.showToast({content: 'complete回调!',});\r\n }\r\n }); \r\n},\r\nopenVoucherDetail(){\r\n my.openVoucherDetail({\r\n passId:'15153594937',//\r\n //partnerId:'2088521411242352',\r\n // serialNumber:'20170904000730023708007XVP2W',\r\n //开发环境\r\n //passId:\"7001350165\",\r\n // partnerId:'2088302084359231',\r\n // serialNumber:'2017060218522661677653862',\r\n success:(res)=>{\r\n my.showToast({content: '调用成功:'+JSON.stringify(res), });\r\n },\r\n fail:(error)=>{\r\n my.alert({content: '调用失败:'+JSON.stringify(error), });\r\n },\r\n complete:(e)=>{\r\n my.showToast({content: 'complete回调!',});\r\n }\r\n }); \r\n},\r\n\r\nopenTicketDetail(){\r\n my.openTicketDetail({\r\n passId:\"11688279837\",\r\n //partnerId:'2013080800000754',\r\n //serialNumber:'T150P4607471458101261',\r\n //passId:\"7001020065\",\r\n //partnerId:'2088101162864452',\r\n //serialNumber:'2017033120573899567387727',\r\n success:(res)=>{\r\n my.showToast({content: '调用成功:'+JSON.stringify(res), });\r\n },\r\n fail:(error)=>{\r\n my.alert({content: '调用失败:'+JSON.stringify(error), });\r\n },\r\n complete:(e)=>{\r\n my.showToast({content: 'complete回调!',});\r\n }\r\n });\r\n},\r\n\r\n//打开口碑券详情\r\nopenKBVoucherDetail(){\r\n my.openKBVoucherDetail({\r\n passId:'13813142037',\r\n //partnerId:'2088912612862076',\r\n //serialNumber:'201708010007300237080079G88A',\r\n\r\n // passId:'7001430265',\r\n // partnerId:'2088102147297014',\r\n // serialNumber:'201708250007300265750000AWST',\r\n success:(res)=>{\r\n my.showToast({content: '调用成功:'+JSON.stringify(res), });\r\n },\r\n fail:(error)=>{\r\n my.alert({content: '调用失败:'+JSON.stringify(error), });\r\n },\r\n complete:(e)=>{\r\n my.showToast({content: 'complete回调!',});\r\n }\r\n });\r\n},\r\n//口碑客劵详情页\r\n gotoDetail() {\r\n my.navigateToCouponDetail({\r\n itemId: '2017072010076000000015900884',\r\n chInfo: 'ch_cainiao__spmid_a13.b579',\r\n success: (res) => {\r\n my.alert({\r\n title: 'success',\r\n content: JSON.stringify(res),\r\n });\r\n },\r\n fail: (res) => {\r\n my.alert({\r\n title: 'fail',\r\n content: JSON.stringify(res),\r\n });\r\n },\r\n complete:(res)=>{\r\n my.showToast({content: 'complete回调!',});\r\n }\r\n });\r\n }, \r\n\r\n\r\n//--------------------卡/券/票 单商户列表页: partnerId 入参\r\nopenMerchantCardList(){\r\n my.openMerchantCardList({\r\n partnerId:'2088621202286735',\r\n success:(res)=>{\r\n my.showToast({content: '调用成功:'+JSON.stringify(res), });\r\n },\r\n fail:(error)=>{\r\n my.alert({content: '调用失败:'+JSON.stringify(error), });\r\n },\r\n complete:(e)=>{\r\n my.showToast({content: 'complete回调!',});\r\n }\r\n });\r\n},\r\n\r\nopenMerchantVoucherList(){\r\n my.openMerchantVoucherList({\r\n partnerId:'2088521411242352',\r\n success:(res)=>{\r\n my.showToast({content: '调用成功:'+JSON.stringify(res), });\r\n },\r\n fail:(error)=>{\r\n my.alert({content: '调用失败:'+JSON.stringify(error), });\r\n },\r\n complete:(e)=>{\r\n my.showToast({content: 'complete回调!',});\r\n }\r\n });\r\n},\r\n\r\nopenMerchantTicketList(){\r\n my.openMerchantTicketList({\r\n partnerId:'2013080800000754',\r\n success:(res)=>{\r\n my.showToast({content: '调用成功:'+JSON.stringify(res), });\r\n },\r\n fail:(error)=>{\r\n my.alert({content: '调用失败:'+JSON.stringify(error), });\r\n },\r\n complete:(e)=>{\r\n my.showToast({content: 'complete回调!',});\r\n }\r\n });\r\n\r\n},\r\n})\r\n","page/API/card-pack/card-pack.json":"{\n \"defaultTitle\": \"淘宝卡包\"\n}","page/API/choose-city/choose-city.axml":"<view class=\"page\">\n <view class=\"page-description\">选择城市 API</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.chooseCity</view>\n <view class=\"page-section-demo\">\n <button type=\"primary\" onTap=\"chooseCity\">选择城市</button>\n </view>\n </view>\n <view class=\"page-description\">修改当前定位城市的名称 API</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.setLocatedCity</view>\n <view class=\"page-section-demo\">\n <button type=\"primary\" onTap=\"setLocatedCity\">修改当前定位城市的名称</button>\n </view>\n </view>\n</view>\n","page/API/choose-city/choose-city.js":"Page({\n chooseCity() {\n my.chooseCity({\n showLocatedCity: true,\n showHotCities: true,\n success: (res) => {\n my.alert({\n title: 'chooseCity response: ' + JSON.stringify(res),\n });\n },\n });\n },\n setLocatedCity() {\n my.onLocatedComplete({\n success: (res) => {\n my.setLocatedCity({\n locatedCityId:res.locatedCityId,//res.locatedCityId\n locatedCityName:'修改后的城市名', \n success: (res) => {\n my.alert({ content: '修改当前定位城市成功' + JSON.stringify(res), });\n },\n fail: (error) => {\n my.alert({ content: '修改当前定位城市失败' + JSON.stringify(error), });\n },\n });\n },\n fail: (error) => {\n my.alert({ content: 'onLocatedComplete失败' + JSON.stringify(error), });\n }\n });\n my.chooseCity({\n showLocatedCity: true,\n showHotCities: true,\n setLocatedCity: true,\n success: (res) => {\n my.alert({\n title: 'chooseCity response: ' + JSON.stringify(res),\n });\n },\n });\n },\n});\n","page/API/choose-city/choose-city.json":"{\n \"defaultTitle\": \"City\"\n}\n","page/API/choose-location/choose-location.acss":".page-body-info {\n height: 250rpx;\n}\n.page-body-text-location {\n display: flex;\n font-size: 50rpx;\n}\n.page-body-text-location text {\n margin: 10rpx;\n}\n.page-section-location-text{\n color: #49a9ee;\n}","page/API/choose-location/choose-location.axml":"<view class=\"page\">\n <view class=\"page-section\">\n <view class=\"page-section-demo\">\n <text>经度:</text>\n <input value=\"{{longitude}}\"></input>\n </view>\n <view class=\"page-section-demo\">\n <text>纬度:</text>\n <input value=\"{{latitude}}\"></input>\n </view>\n <view class=\"page-section-demo\">\n <text>位置名称:</text>\n <input value=\"{{name}}\"></input>\n </view>\n <view class=\"page-section-demo\">\n <text>详细位置:</text>\n <input value=\"{{address}}\"></input>\n </view> \n <view class=\"page-section-btns\">\n <view onTap=\"chooseLocation\">选择位置</view>\n </view>\n </view>\n</view>\n","page/API/choose-location/choose-location.js":"Page({\n data: {\n longitude: '120.126293',\n latitude: '30.274653',\n name: '黄龙万科中心',\n address: '学院路77号',\n },\n chooseLocation() {\n var that = this\n my.chooseLocation({\n success:(res)=>{\n console.log(JSON.stringify(res))\n that.setData({\n longitude:res.longitude,\n latitude:res.latitude,\n name:res.name,\n address:res.address\n })\n },\n fail:(error)=>{\n my.alert({content: '调用失败:'+JSON.stringify(error), });\n },\n });\n },\n})\n","page/API/choose-location/choose-location.json":"{\n \"defaultTitle\": \"选择位置\"\n}\n","page/API/clipboard/clipboard.acss":".clipboard-button {\n margin-left: 5px;\n}\n","page/API/clipboard/clipboard.axml":"<view class=\"page\">\n <view class=\"page-section\">\n <view class=\"page-section-title\">setClipboard</view>\n <view class=\"page-section-demo\">\n <input onInput=\"handleInput\" value=\"{{text}}\" />\n <button class=\"clipboard-button\" type=\"primary\" size=\"mini\" onTap=\"handleCopy\">复制</button>\n </view>\n </view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">getClipboard</view>\n <view class=\"page-section-demo\">\n <input onInput=\"bindInput\" value=\"{{copy}}\" disabled />\n <button class=\"clipboard-button\" type=\"default\" size=\"mini\" onTap=\"handlePaste\">粘贴</button>\n </view>\n </view>\n</view>\n","page/API/clipboard/clipboard.js":"Page({\n data: {\n text: '3.1415926',\n copy: '',\n },\n\n handleInput(e) {\n this.setData({\n text: e.detail.value,\n });\n },\n\n handleCopy() {\n my.setClipboard({\n text: this.data.text,\n });\n },\n\n handlePaste() {\n my.getClipboard({\n success: ({ text }) => {\n this.setData({ copy: text });\n },\n });\n },\n});\n","page/API/clipboard/clipboard.json":"{\n \"defaultTitle\": \"Clipboard\"\n}\n","page/API/compress-image/compress-image.axml":"<view class=\"page\">\n <view class=\"page-description\">压缩图片 API</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.compressImage</view>\n <view class=\"page-section-demo\">\n <button type=\"primary\" onTap=\"selectImage\" hover-class=\"defaultTap\">选择图片</button>\n <image\n src=\"{{compressedSrc}}\" \n mode=\"{{mode}}\" />\n </view>\n </view>\n</view>\n\n\n","page/API/compress-image/compress-image.js":"Page({\n data: {\n compressedSrc: '',\n mode: 'aspectFit',\n },\n selectImage() {\n my.chooseImage({\n count: 1,\n success: (res) => {\n my.compressImage({\n apFilePaths: res.apFilePaths,\n level: 1,\n success: data => {\n console.log(data);\n this.setData({\n compressedSrc: data.apFilePaths[0],\n })\n }\n })\n }\n })\n },\n});","page/API/confirm/confirm.axml":"<view class=\"page\">\n <view class=\"page-description\">确认框 API</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.confirm</view>\n <view class=\"page-section-demo\">\n <button type=\"primary\" onTap=\"comfirm\">显示确认框</button>\n </view>\n </view>\n</view>\n","page/API/confirm/confirm.js":"Page({\n comfirm() {\n my.confirm({\n title: '温馨提示',\n content: '您是否想查询快递单号:\\n1234567890',\n confirmButtonText: '马上查询',\n cancelButtonText: '暂不需要',\n success: (result) => {\n my.alert({\n title: `${result.confirm}`,\n });\n },\n });\n },\n});\n","page/API/confirm/confirm.json":"{\n \"defaultTitle\": \"Confirm\"\n}\n","page/API/contact/contact.acss":"","page/API/contact/contact.axml":"<view class=\"page\">\n\n <view class=\"page-description\">联系人 API</view>\n\n <!--<view class=\"page-section\">\n <view class=\"page-section-title\">my.choosePhoneContact</view>\n <view class=\"page-section-demo\">\n <button type=\"primary\" onTap=\"choosePhoneContact\">唤起本地通讯录</button>\n </view>\n </view>\n\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.chooseAlipayContact</view>\n <view class=\"page-section-demo\">\n <button type=\"primary\" onTap=\"chooseAlipayContact\">唤起淘宝通讯录</button>\n </view>\n </view>\n\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.chooseContact</view>\n <view class=\"page-section-demo\">\n <button type=\"primary\" onTap=\"chooseContact\">选择联系人</button>\n </view>\n </view>-->\n\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.addPhoneContact</view>\n <view class=\"page-section-demo\">\n\n <view style=\"font-size:18px;margin-top:18px;margin-bottom:18px\">\n <text style=\"font-size:18px;margin-top:18px;margin-bottom:18px\">基本信息</text>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">昵称</view>\n <view class=\"form-row-content\">\n <input id=\"nickName\" onInput=\"onInput\" class=\"input\" value=\"七月流火\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">姓氏</view>\n <view class=\"form-row-content\">\n <input id=\"lastName\" onInput=\"onInput\" class=\"input\" value=\"Last\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">中间名</view>\n <view class=\"form-row-content\">\n <input id=\"middleName\" onInput=\"onInput\" class=\"input\" value=\"Middle\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">名字</view>\n <view class=\"form-row-content\">\n <input id=\"firstName\" onInput=\"onInput\" class=\"input\" value=\"First\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">备注</view>\n <view class=\"form-row-content\">\n <input id=\"remark\" onInput=\"onInput\" class=\"input\" value=\"这里是备注\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">手机号</view>\n <view class=\"form-row-content\">\n <input id=\"mobilePhoneNumber\" onInput=\"onInput\" class=\"input\" value=\"13800000000\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">淘宝账号</view>\n <view class=\"form-row-content\">\n <input id=\"alipayAccount\" onInput=\"onInput\" class=\"input\" value=\"alipay@alipay.com\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">微信号</view>\n <view class=\"form-row-content\">\n <input id=\"weChatNumber\" onInput=\"onInput\" class=\"input\" value=\"liuhuo\" />\n </view>\n </view>\n\n <view style=\"font-size:18px;margin-top:18px;margin-bottom:18px\">\n <text style=\"font-size:18px;margin-top:18px;margin-bottom:18px\">联系地址</text>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">国家</view>\n <view class=\"form-row-content\">\n <input id=\"addressCountry\" onInput=\"onInput\" class=\"input\" value=\"US\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">省份</view>\n <view class=\"form-row-content\">\n <input id=\"addressState\" onInput=\"onInput\" class=\"input\" value=\"California\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">城市</view>\n <view class=\"form-row-content\">\n <input id=\"addressCity\" onInput=\"onInput\" class=\"input\" value=\"San Francisco\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">街道</view>\n <view class=\"form-row-content\">\n <input id=\"addressStreet\" onInput=\"onInput\" class=\"input\" value=\"Mountain View\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">邮政编码</view>\n <view class=\"form-row-content\">\n <input id=\"addressPostalCode\" onInput=\"onInput\" class=\"input\" value=\"94016\" />\n </view>\n </view>\n\n <view style=\"font-size:18px;margin-top:18px;margin-bottom:18px\">\n <text style=\"font-size:18px;margin-top:18px;margin-bottom:18px\">工作</text>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">公司</view>\n <view class=\"form-row-content\">\n <input id=\"organization\" onInput=\"onInput\" class=\"input\" value=\"AntFin\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">职位</view>\n <view class=\"form-row-content\">\n <input id=\"title\" onInput=\"onInput\" class=\"input\" value=\"Developer\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">工作传真</view>\n <view class=\"form-row-content\">\n <input id=\"workFaxNumber\" onInput=\"onInput\" class=\"input\" value=\"11111111\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">工作电话</view>\n <view class=\"form-row-content\">\n <input id=\"workPhoneNumber\" onInput=\"onInput\" class=\"input\" value=\"11111112\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">公司电话</view>\n <view class=\"form-row-content\">\n <input id=\"hostNumber\" onInput=\"onInput\" class=\"input\" value=\"11111113\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">电子邮件</view>\n <view class=\"form-row-content\">\n <input id=\"email\" onInput=\"onInput\" class=\"input\" value=\"liuhuo01@sina.com\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">网站</view>\n <view class=\"form-row-content\">\n <input id=\"url\" onInput=\"onInput\" class=\"input\" value=\"www.alipay.com\" />\n </view>\n </view>\n\n <view style=\"font-size:18px;margin-top:18px;margin-bottom:18px\">\n <text style=\"font-size:18px;margin-top:18px;margin-bottom:18px\">工作地址</text>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">国家</view>\n <view class=\"form-row-content\">\n <input id=\"workAddressCountry\" onInput=\"onInput\" class=\"input\" value=\"China\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">省份</view>\n <view class=\"form-row-content\">\n <input id=\"workAddressState\" onInput=\"onInput\" class=\"input\" value=\"Zhejiang\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">城市</view>\n <view class=\"form-row-content\">\n <input id=\"workAddressCity\" onInput=\"onInput\" class=\"input\" value=\"Hangzhou\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">街道</view>\n <view class=\"form-row-content\">\n <input id=\"workAddressStreet\" onInput=\"onInput\" class=\"input\" value=\"Tianmushan Road\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">邮政编码</view>\n <view class=\"form-row-content\">\n <input id=\"workAddressPostalCode\" onInput=\"onInput\" class=\"input\" value=\"361005\" />\n </view>\n </view>\n\n <view style=\"font-size:18px;margin-top:18px;margin-bottom:18px\">\n <text style=\"font-size:18px;margin-top:18px;margin-bottom:18px\">住宅</text>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">传真</view>\n <view class=\"form-row-content\">\n <input id=\"homeFaxNumber\" onInput=\"onInput\" class=\"input\" value=\"11111114\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">电话</view>\n <view class=\"form-row-content\">\n <input id=\"homePhoneNumber\" onInput=\"onInput\" class=\"input\" value=\"11111115\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">国家</view>\n <view class=\"form-row-content\">\n <input id=\"homeAddressCountry\" onInput=\"onInput\" class=\"input\" value=\"Canada\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">省份</view>\n <view class=\"form-row-content\">\n <input id=\"homeAddressState\" onInput=\"onInput\" class=\"input\" value=\"Ontario\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">城市</view>\n <view class=\"form-row-content\">\n <input id=\"homeAddressCity\" onInput=\"onInput\" class=\"input\" value=\"Toronto\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">街道</view>\n <view class=\"form-row-content\">\n <input id=\"homeAddressStreet\" onInput=\"onInput\" class=\"input\" value=\"No.234 Road\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">邮政编码</view>\n <view class=\"form-row-content\">\n <input id=\"homeAddressPostalCode\" onInput=\"onInput\" class=\"input\" value=\"123456\" />\n </view>\n </view>\n\n <button type=\"primary\" onTap=\"addPhoneContact\">添加到手机联系人</button>\n\n </view>\n </view>\n\n</view>\n","page/API/contact/contact.js":"Page({\n data:{\n \"photoFilePath\": \"/sdcard/DCIM/Camera/a.jpg\",\n \"nickName\": \"七月流火\",\n \"lastName\": \"Last\",\n \"middleName\": \"Middle\",\n \"firstName\": \"First\",\n \"remark\": \"这里是备注\",\n \"mobilePhoneNumber\": \"13800000000\",\n \"homePhoneNumber\": \"11111115\",\n \"workPhoneNumber\": \"11111112\",\n \"homeFaxNumber\": \"11111114\",\n \"workFaxNumber\": \"11111111\",\n \"hostNumber\": \"11111113\",\n \"weChatNumber\": \"liuhuo\",\n \"alipayAccount\": \"alipay@alipay.com\",\n \"addressCountry\": \"US\",\n \"addressState\": \"California\",\n \"addressCity\": \"San Francisco\",\n \"addressStreet\": \"Mountain View\",\n \"addressPostalCode\": \"94016\",\n \"workAddressCountry\": \"China\",\n \"workAddressState\": \"Zhejiang\",\n \"workAddressCity\": \"Hangzhou\",\n \"workAddressStreet\": \"Tianmushan Road\",\n \"workAddressPostalCode\": \"361005\",\n \"homeAddressCountry\": \"Canada\",\n \"homeAddressState\": \"Ontairo\",\n \"homeAddressCity\": \"Toronto\",\n \"homeAddressStreet\": \"No.234 Road\",\n \"homeAddressPostalCode\": \"123456\",\n \"organization\": \"AntFin\",\n \"title\": \"Developer\",\n \"email\": \"liuhuo01@sina.com\",\n \"url\": \"www.alipay.com\",\n success: (res) => {\n my.alert({\n content: 'addPhoneContact response: ' + JSON.stringify(res)\n });\n },\n fail: (res) => {\n my.alert({\n content: 'addPhoneContact response: ' + JSON.stringify(res)\n });\n }\n },\n choosePhoneContact() {\n my.choosePhoneContact({\n success: (res) => {\n my.alert({\n content: 'choosePhoneContact response: ' + JSON.stringify(res)\n });\n },\n fail: (res) => {\n my.alert({\n content: 'choosePhoneContact response: ' + JSON.stringify(res)\n });\n },\n });\n },\n chooseAlipayContact() {\n my.chooseAlipayContact({\n count: 2,\n success: (res) => {\n my.alert({\n content: 'chooseAlipayContact response: ' + JSON.stringify(res)\n });\n },\n fail: (res) => {\n my.alert({\n content: 'chooseAlipayContact response: ' + JSON.stringify(res)\n });\n },\n });\n },\n chooseContact() {\n my.chooseContact({\n chooseType: 'multi', // 多选模式\n includeMe: true, // 包含自己\n includeMobileContactMode: 'known',//仅包含双向手机通讯录联系人,也即双方手机通讯录都存有对方号码的联系人\n multiChooseMax: 3, // 最多能选择三个联系人\n multiChooseMaxTips: '超过选择的最大人数了',\n success: (res) => {\n my.alert({\n content: 'chooseContact : ' + JSON.stringify(res)\n });\n },\n fail: (res) => {\n my.alert({\n content: 'chooseContact : ' + JSON.stringify(res)\n });\n },\n });\n },\n onInput(e) {\n this.data[e.currentTarget.id] = e.detail.value;\n },\n addPhoneContact() {\n if (my.canIUse('addPhoneContact')) {\n my.addPhoneContact(this.data);\n } else {\n my.alert({ \n title: '\b\b客户端版本过低',\n content: 'my.addPhoneContact() 需要\b 10.1.32 \b及以上版本'\n });\n }\n }\n});\n","page/API/contact/contact.json":"{\n \"defaultTitle\": \"Contact\"\n}\n","page/API/create-inner-audiocontext/create-inner-audiocontext.acss":".video-page {\n width: 100%;\n}\n\n.video-contain {\n display: flex;\n align-items: center;\n justify-content: center;\n margin-top: 24px\n}\n\n.video {\nwidth: 320px;\nheight: 225px;\n}\n\n.operation-item {\n height: 48px;\n background-color: #54acee;\n margin: 20px 40px 0 40px;\n display: flex;\n align-items: center;\n justify-content: center;\n font-size: 20px\n}\n\n.row {\n height: 40px;\n background: white;\n margin:10px 20px 0 20px;\n display: flex;\n flex-direction: row;\n align-items: center;\n padding: 0 0 0 12px;\n justify-content: space-between\n}\n\n.row-extra {\n width: 120px\n}\n","page/API/create-inner-audiocontext/create-inner-audiocontext.axml":"<view class=\"video-page\">\n\n <view class=\"video-contain\">\n <audio id=\"myAudio\" />\n </view>\n <view class=\"video-contain\">\n <audio id=\"audio2\" />\n </view>\n <view class=\"operation-item\" style=\"background-color:lightblue\">\b{{title}}</view>\n <view class=\"operation-item\" onTap=\"play\">播放</view>\n <view class=\"operation-item\" onTap=\"pause\">暂停</view>\n <view class=\"operation-item\" onTap=\"seek\">seek{{seek}}s播放</view>\n <view class=\"operation-item\" onTap=\"stop\">停止播放</view>\n <view class=\"operation-item\" onTap=\"destroy\">destroy</view>\n <view class=\"operation-item\" onTap=\"getAllProps\">显示属性</view>\n\n <picker onChange=\"offCallback\" value=\"{{callbackIndex}}\" range=\"{{callbackArr}}\" >\n <view class=\"row\">\n <view class=\"row-title\">offCallback</view>\n <view class=\"row-extra\">当前选择:{{callback}}</view>\n </view>\n </picker>\n\n \n <view class=\"operation-item\" onTap=\"play2\">播放audio2</view>\n <view class=\"operation-item\" onTap=\"pause2\">暂停audio2</view>\n <view class=\"operation-item\" onTap=\"getAllProps2\">显示属性2</view>\n\n <picker onChange=\"offCallback2\" value=\"{{callback2Index}}\" range=\"{{callback2Arr}}\" >\n <view class=\"row\">\n <view class=\"row-title\">offCallback</view>\n <view class=\"row-extra\">当前选择:{{callback2}}</view>\n </view>\n </picker>\n\n</view>","page/API/create-inner-audiocontext/create-inner-audiocontext.js":"Page({\n data: {\n src: 'http://ws.stream.qqmusic.qq.com/M500001VfvsJ21xFqb.mp3?guid=ffffffff82def4af4b12b3cd9337d5e7&uin=346897220&vkey=6292F51E1E384E06DCBDC9AB7C49FD713D632D313AC4858BACB8DDD29067D3C601481D36E62053BF8DFEAF74C0A5CCFADD6471160CAF3E6A&fromtag=46',\n //src : '&*()E$$$1',\n title: 'initial',\n autoplay: false,\n loop: 'false',\n startTime : 0,\n volume : 0.5,\n obeyMuteSwitch: 'false',\n seek: 0,\n callbackArr : [\n 'offCanplay',\n 'offPlay',\n 'offPause',\n 'offStop',\n 'offEnded',\n 'offTimeUpdate',\n 'offError',\n 'offWaiting',\n 'offSeeking',\n 'offSeeked' \n ],\n callbackIndex : 0,\n callback: 'offCanplay'\n},\n\nonReady(e) {\n this.innerAudioContext = my.createInnerAudioContext();\n //this.innerAudioContext.autoplay = true\n //this.innerAudioContext.src=\"http://www.ytmp3.cn/down/50564.mp3\";\n this.innerAudioContext.src = 'http://ws.stream.qqmusic.qq.com/M500001VfvsJ21xFqb.mp3?guid=ffffffff82def4af4b12b3cd9337d5e7&uin=346897220&vkey=6292F51E1E384E061FF02C31F716658E5C81F5594D561F2E88B854E81CAAB7806D5E4F103E55D33C16F3FAC506D1AB172DE8600B37E43FAD&fromtag=46'\n\n console.log(\"onReady over\")\n this.onCanplay = this.onCanplay.bind(this);\n this.innerAudioContext.onCanplay(this.onCanplay);\n\n this.onPlay = this.onPlay.bind(this);\n this.innerAudioContext.onPlay(this.onPlay)\n \n this.onPause = this.onPause.bind(this);\n this.innerAudioContext.onPause(this.onPause);\n \n this.onStop = this.onStop.bind(this);\n this.innerAudioContext.onStop(this.onStop);\n\n this.onError = this.onError.bind(this);\n this.innerAudioContext.onError(this.onError);\n\n this.onEnded = this.onEnded.bind(this);\n this.innerAudioContext.onEnded(this.onEnded);\n\n this.onTimeUpdate = this.onTimeUpdate.bind(this);\n this.innerAudioContext.onTimeUpdate(this.onTimeUpdate);\n\n this.onWaiting = this.onWaiting.bind(this);\n this.innerAudioContext.onWaiting(this.onWaiting);\n\n this.onSeeking = this.onSeeking.bind(this);\n this.innerAudioContext.onSeeking(this.onSeeking);\n\n this.onSeeked = this.onSeeked.bind(this);\n this.innerAudioContext.onSeeked(this.onSeeked);\n\n this.innerAudioContext2 = my.createInnerAudioContext();\n console.log(\"--------\" + JSON.stringify(this.data))\n //this.innerAudioContext2.autoplay = true;\n this.innerAudioContext2.src = 'http://sc1.111ttt.cn/2018/1/03/13/396131153555.mp3';\n this.innerAudioContext2.onPlay(()=>{\n console.log('开始播放2');\n });\n this.innerAudioContext2.onPause(()=>{\n console.log('停止播放2');\n });\n \n},\n\nplay(res){\n console.log(\"call play\");\n this.innerAudioContext.play();\n console.log(\"finish call play\");\n //my.alert({ content: '\b\b开始播放:' + JSON.stringify(res) });\n},\n\nplay2(res){\n console.log(\"call play2\");\n this.innerAudioContext2.play();\n console.log(\"finish call play2\");\n //my.alert({ content: '\b\b开始播放:' + JSON.stringify(res) });\n},\n\npause2(){\n console.log(\"call pause2\");\n this.innerAudioContext2.pause()\n console.log(\"finish call pause2\");\n},\n\npause(){\n console.log(\"call pause\");\n this.innerAudioContext.pause()\n console.log(\"finish call pause\");\n},\nstop(){\n console.log(\"call stop\");\n this.innerAudioContext.stop();\n console.log(\"finish call stop\");\n},\nseek(){\n console.log(\"call seek\");\n var seekVal = this.data.seek;\n console.log(\"seek to: \" + seekVal)\n this.innerAudioContext.seek(380);\n console.log(\"finish call seek\");\n},\ndestroy() {\n console.log(\"call destroy\");\n this.innerAudioContext.destroy();\n console.log(\"finish call destroy\");\n\n},\n\nonCanplay() {\n this.innerAudioContext.onCanplay(() => {\n this.setData({title:'onCanplay'})\n console.log('onCanplay')\n });\n},\nonPlay() {\n this.setData({title:'onPlay'})\n console.log('onPlay')\n},\nonPause() {\n this.setData({title:'onPause'})\n console.log('onPause')\n},\nonEnded() {\n this.setData({title:'onEnded'})\n console.log('onEnded')\n},\nonTimeUpdate() {\n this.setData({title:'onTimeUpdate'})\n console.log('onTimeUpdate')\n},\nonError() {\n this.setData({title:'onError'})\n console.log('onError')\n},\nonStop() {\n this.setData({title:'onStop'})\n console.log('onStop')\n},\nonWaiting() {\n this.setData({title:'onWaiting'})\n console.log('onWaiting')\n},\nonSeeking() {\n this.setData({title:'onSeeking'})\n console.log('onSeeking')\n},\nonSeeked() {\n this.setData({title:'onSeeked'})\n console.log('onSeeked')\n},\n\noffCallback(e) {\n const index = e.detail.value\n const {callbackArr} = this.data;\n\n this.setData({\n callback : callbackArr[index]\n })\n\n var item = callbackArr[index]\n\n switch(callbackArr[index]) {\n case 'offCanplay':\n this.innerAudioContext.offCanplay(this.onCanplay);\n console.log('offCanplay')\n break;\n case 'offPlay':\n console.log('offPlay--------1')\n this.onPlay();\n console.log('offPlay')\n this.innerAudioContext.offPlay(this.onPlay);\n console.log('offPlay--------2')\n break;\n case 'offPause':\n this.innerAudioContext.offPause(this.onPause)\n console.log('offPause')\n break;\n case 'offStop':\n this.innerAudioContext.offStop(this.onStop)\n console.log('offStop')\n break;\n case 'offEnded':\n this.innerAudioContext.offEnded(this.onEnded)\n console.log('offEnded')\n break;\n case 'offTimeUpdate':\n this.innerAudioContext.offTimeUpdate(this.onTimeUpdate)\n console.log('offTimeUpdate')\n break;\n case 'offError':\n this.innerAudioContext.offError(this.onError)\n console.log('offError')\n break;\n case 'offWaiting':\n this.innerAudioContext.offWaiting(this.onWaiting)\n break;\n case 'offSeeking':\n this.innerAudioContext.offSeeking(this.onSeeking)\n console.log('offSeeking')\n break;\n case 'offSeeked':\n \n this.innerAudioContext.offSeeked(this.onSeeked)\n console.log('offSeeked')\n break; \n default: break;\n }\n},\n\ngetAllProps() {\n var src = this.innerAudioContext.src;\n var startTime = this.innerAudioContext.startTime;\n var autoplay = this.innerAudioContext.autoplay;\n var loop = this.innerAudioContext.loop;\n var obeyMuteSwitch = this.innerAudioContext.obeyMuteSwitch;\n var duration = this.innerAudioContext.duration;\n var currentTime = this.innerAudioContext.currentTime;\n var paused = this.innerAudioContext.paused;\n var buffered = this.innerAudioContext.buffered;\n var volume = this.innerAudioContext.volume;\n var result = \"src: \" + src + \"\\n\" + \n \"startTime: \" + startTime + \"\\n\" + \n \"autoplay: \" + autoplay + \"\\n\" + \n \"loop: \" + loop + \"\\n\" + \n \"obeyMuteSwitch: \" + obeyMuteSwitch + \"\\n\" + \n \"duration: \" + duration + \"\\n\" + \n \"currentTime: \" + currentTime + \"\\n\" + \n \"paused: \" + paused + \"\\n\" + \n \"buffered: \" + buffered + \"\\n\" + \n \"volume: \" + volume + \"\\n\";\n my.alert({ content: '\b\b音频属性:' + result });\n console.log(result); \n},\n\n getAllProps2() {\n var src = this.innerAudioContext2.src;\n var startTime = this.innerAudioContext2.startTime;\n var autoplay = this.innerAudioContext2.autoplay;\n var loop = this.innerAudioContext2.loop;\n var obeyMuteSwitch = this.innerAudioContext2.obeyMuteSwitch;\n var duration = this.innerAudioContext2.duration;\n var currentTime = this.innerAudioContext2.currentTime;\n var paused = this.innerAudioContext2.paused;\n var buffered = this.innerAudioContext2.buffered;\n var volume = this.innerAudioContext2.volume;\n var result = \"src: \" + src + \"\\n\" + \n \"startTime: \" + startTime + \"\\n\" + \n \"autoplay: \" + autoplay + \"\\n\" + \n \"loop: \" + loop + \"\\n\" + \n \"obeyMuteSwitch: \" + obeyMuteSwitch + \"\\n\" + \n \"duration: \" + duration + \"\\n\" + \n \"currentTime: \" + currentTime + \"\\n\" + \n \"paused: \" + paused + \"\\n\" + \n \"buffered: \" + buffered + \"\\n\" + \n \"startTime: \" + startTime + \"\\n\" + \n \"volume: \" + volume + \"\\n\";\n my.alert({ content: '\b\b音频属性:' + result });\n console.log(result); \n}\n\n});\n","page/API/create-inner-audiocontext/create-inner-audiocontext.json":"{\n \"defaultTitle\": \"播放前景音乐\"\n}","page/API/create-selector-query/create-selector-query.axml":"<view class=\"page\">\n <view class=\"page-description\">节点查询 API</view>\n <view class=\"page-section\">\n <view className=\"all\">节点 all1</view>\n <view className=\"all\">节点 all2</view>\n <view id=\"one\">节点 one</view>\n <view id=\"scroll\" style=\"height:200px;overflow: auto\">\n <view style=\"height:400px\">独立滚动区域</view>\n </view>\n <button type=\"primary\" onTap=\"createSelectorQuery\">节点查询</button>\n </view>\n</view>","page/API/create-selector-query/create-selector-query.js":"Page({\n createSelectorQuery() {\n my.createSelectorQuery()\n .select('#non-exists').boundingClientRect()\n .select('#one').boundingClientRect()\n .selectAll('.all').boundingClientRect()\n .select('#scroll').scrollOffset()\n .selectViewport().boundingClientRect()\n .selectViewport().scrollOffset().exec((ret) => {\n console.log(ret);\n my.alert({\n content: JSON.stringify(ret, null, 2),\n });\n })\n },\n});","page/API/date-picker/date-picker.acss":"button + button {\n margin-top: 20rpx;\n}","page/API/date-picker/date-picker.axml":"<view class=\"page\">\n <view class=\"page-description\">选择日期 API</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.datePicker</view>\n <view class=\"page-section-demo\">\n <button class=\"page-body-button\" type=\"primary\" onTap=\"datePicker\">选择日期-1</button>\n <button class=\"page-body-button\" type=\"primary\" onTap=\"datePickerHMS\">选择日期-2</button>\n <button class=\"page-body-button\" type=\"primary\" onTap=\"datePickerYMDHMS\">选择日期-3</button>\n </view>\n </view>\n</view>\n","page/API/date-picker/date-picker.js":"Page({\n datePicker() {\n my.datePicker({\n currentDate: '2016-10-10',\n startDate: '2016-10-9',\n endDate: '2017-10-9',\n success: (res) => {\n my.alert({\n title: 'datePicker response: ' + JSON.stringify(res)\n });\n },\n });\n },\n datePickerHMS() {\n my.datePicker({\n format: 'HH:mm:ss',\n currentDate: '12:12:12',\n startDate: '11:11:11',\n endDate: '13:13:13',\n success: (res) => {\n my.alert({\n title: 'datePicker response: ' + JSON.stringify(res)\n });\n },\n });\n },\n datePickerYMDHMS() {\n my.datePicker({\n format: 'yyyy-MM-dd HH:mm:ss',\n currentDate: '2012-01-09 11:11:11',\n startDate: '2012-01-01 11:11:11',\n endDate: '2012-01-10 11:11:11',\n success: (res) => {\n my.alert({\n title: 'datePicker response: ' + JSON.stringify(res)\n });\n },\n });\n },\n});\n","page/API/date-picker/date-picker.json":"{\n \"defaultTitle\": \"Date Picker\"\n}\n","page/API/download-file/download-file.acss":"","page/API/download-file/download-file.axml":"<view class=\"container\">\n <button onTap=\"download\">下载图片并显示</button>\n</view>\n","page/API/download-file/download-file.js":"Page({\n download() {\n my.downloadFile({\n url: 'http://img.alicdn.com/tfs/TB1x669SXXXXXbdaFXXXXXXXXXX-520-280.jpg',\n success({ apFilePath }) {\n my.previewImage({\n urls: [apFilePath],\n });\n },\n fail(res) {\n my.alert({\n content: res.errorMessage || res.error,\n });\n },\n });\n },\n})\n","page/API/download-file/download-file.json":"{\n \"defaultTitle\": \"下载文件\"\n}\n","page/API/events/events.axml":"<view class=\"page\">\n <view>\n 点击标题,测试容器事件\n </view>\n</view>\n","page/API/events/events.js":"Page({\n onLoad() {\n this.titleClick = my.on('titleClick', () => {\n console.log('title clicked')\n my.alert({\n title: '亲',\n content: '您刚刚点击了标题',\n buttonText: '我知道了',\n })\n })\n },\n onUnload(){\n this.titleClick.remove();\n },\n})","page/API/file/file.acss":".image {\n width: 300rpx;\n height: 300rpx;\n}\n.image-plus {\n width: 150rpx;\n height: 150rpx;\n margin: 10rpx;\n border: 1px solid #999;\n position: relative;\n justify-content: center;\n}\n.image-plus-horizontal {\n align-self: center;\n background-color: #d9d9d9;\n width: 4rpx;\n height: 80rpx;\n justify-content: center;\n}\n.image-plus-vertical {\n align-self: center;\n background-color: #d9d9d9;\n width: 80rpx;\n height: 4rpx;\n}\n\n.page-body-info {\n height: 400rpx;\n padding-bottom: 50rpx; \n}\n","page/API/file/file.axml":"<view class=\"page\">\n <view class=\"page-description\">文件 API</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">选择文件</view>\n <block a:if=\"{{tempFilePath != ''}}\">\n <image src=\"{{tempFilePath}}\" class=\"image\"></image>\n </block>\n <block a:if=\"{{tempFilePath === '' && savedFilePath != ''}}\">\n <image src=\"{{savedFilePath}}\" class=\"image\"></image>\n </block>\n <block a:if=\"{{tempFilePath === '' && savedFilePath === ''}}\">\n <view class=\"image-plus\" onTap=\"chooseImage\">\n <view class=\"image-plus-horizontal\">\n <view class=\"image-plus-vertical\"></view>\n </view>\n </block>\n <view class=\"page-section-demo\">\n <button class=\"page-body-button\" type=\"primary\" onTap=\"saveFile\">保存文件</button>\n <button class=\"page-body-button\" type=\"primary\" onTap=\"getFileInfo\">获取文件信息</button>\n <button class=\"page-body-button\" type=\"primary\" onTap=\"getSavedFileInfo\">获取保存的文件信息</button>\n <button class=\"page-body-button\" type=\"primary\" onTap=\"getSavedFileList\">获取保存的文件列表</button>\n <button class=\"page-body-button\" type=\"primary\" onTap=\"removeSavedFile\">移除保存的文件</button>\n <!-- <button class=\"page-body-button\" type=\"primary\" onTap=\"openDocument\">预览文件</button> -->\n <button class=\"page-body-button\" onTap=\"clear\">删除文件</button>\n </view>\n </view>\n</view>\n","page/API/file/file.js":"Page({\n data: {\n tempFilePath: '',\n savedFilePath: '',\n },\n onLoad() {\n my.getStorage({\n key: 'savedFilePath', // 缓存数据的 key\n success: (res) => {\n this.setData({\n savedFilePath: res.data ? res.data : '',\n });\n },\n });\n },\n chooseImage() {\n my.chooseImage({\n count: 1,\n success: (res) => {\n console.log('chooseImage', res);\n this.setData({\n tempFilePath: res.apFilePaths[0],\n });\n },\n });\n },\n saveFile() {\n if (this.data.tempFilePath.length > 0) {\n const that = this;\n my.saveFile({\n apFilePath: this.data.tempFilePath,\n success(res) {\n console.log('saveFile', res);\n that.setData({\n savedFilePath: res.apFilePath,\n });\n my.setStorage({ key: 'savedFilePath', data: res.apFilePath });\n my.alert({\n title: '保存成功', // alert 框的标题\n content: `下次进入应用时,此文件仍可用:${JSON.stringify(res)}`,\n });\n },\n });\n }\n },\n getFileInfo() {\n my.getFileInfo({\n apFilePath:this.data.tempFilePath,\n digestAlgorithm:'sha1',\n success:(res)=>{\n my.alert({\n title: '文件信息',\n content: JSON.stringify(res),\n });\n console.log(JSON.stringify(res))\n }\n })\n },\n getSavedFileInfo() {\n my.getSavedFileInfo({\n apFilePath: this.data.savedFilePath,\n success: (res) => {\n my.alert({\n title: '文件信息',\n content: JSON.stringify(res),\n });\n console.log(JSON.stringify(res))\n }\n })\n },\n getSavedFileList() {\n my.getSavedFileList({\n success: (res) => {\n my.alert({\n title: '已保存文件列表',\n content: JSON.stringify(res),\n });\n console.log(JSON.stringify(res))\n }\n });\n },\n\n removeSavedFile() {\n my.getSavedFileList({\n success: (res) => {\n my.removeSavedFile({\n apFilePath: res.fileList[0].apFilePath,\n success: (res) => {\n my.alert({\n title: '移除文件成功',\n content: JSON.stringify(res),\n });\n console.log('remove success')\n }\n })\n }\n });\n },\n openDocument() {\n my.showLoading({\n content: '文件下载中...',\n delay: '0',\n });\n //首先download file\n my.downloadFile({\n url: 'https://gw.alipayobjects.com/os/basement_prod/1ce3efc7-a8e0-4111-83e5-4cc8de73170e.pdf',\n success({ apFilePath }) {\n if (my.canIUse('openDocument')) {\n my.hideLoading();\n my.openDocument({\n filePath: apFilePath,\n fileType: 'pdf',\n success: (res) => {\n console.log('open document success')\n }\n })\n } else {\n my.alert({ \n title: '客户端版本过低',\n content: 'my.openDocument() 需要 10.1.50 及以上版本'\n });\n } \n }\n });\n },\n clear() {\n my.setStorage({ key: 'savedFilePath', data: '' })\n this.setData({\n tempFilePath: '',\n savedFilePath: '',\n });\n },\n});\n","page/API/file/file.json":"{\n \"defaultTitle\": \"文件\"\n}\n","page/API/generate-image-from-code/generate-image-from-code.axml":"<view class=\"page\">\n <view class=\"page-description\">压缩图片 API</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.generateImageFromCode</view>\n <view class=\"page-section-demo\">\n <button type=\"primary\" onTap=\"buttonClick\" hover-class=\"defaultTap\">生成二维码</button>\n <image\n src=\"{{imageStr}}\" \n mode=\"{{mode}}\" />\n </view>\n </view>\n</view>\n\n\n","page/API/generate-image-from-code/generate-image-from-code.js":"Page({\n data: {\n imageStr: '',\n mode: 'aspectFit',\n },\n buttonClick() {\n my.generateImageFromCode({\n code: 'https://www.alipay.com',\n format: 'QRCODE',\n width:200,\n correctLevel: 'H',\n success:(data)=>{\n console.log(data)\n this.setData({\n imageStr: data.image\n })\n \n }\n })\n },\n});","page/API/get-auth-code/get-auth-code.acss":".page-body-wrapper {\n margin-top: 200px;\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n align-self: stretch;\n padding: 0 50px;\n box-sizing: border-box;\n}\n.page-body-button {\n align-self: stretch;\n}\n","page/API/get-auth-code/get-auth-code.axml":"<view class=\"page\">\n <view class=\"page-section\">\n <view>请不要一进入商家应用就弹框授权,建议先了解商家应用的服务内容</view>\n <button type=\"primary\" onTap=\"getAuthCode\">\n 获取授权码\n </button>\n </view>\n</view>\n","page/API/get-auth-code/get-auth-code.js":"Page({\n onLoad() {},\n data: {},\n getAuthCode: () => {\n my.getAuthCode({\n scopes: 'auth_user',\n success: ({ authCode }) => {\n my.alert({\n content: authCode,\n });\n },\n });\n },\n});\n","page/API/get-auth-code/get-auth-code.json":"{\n \"defaultTitle\": \"获取授权码\"\n}\n","page/API/get-background-audio-manager/get-background-audio-manager.acss":"","page/API/get-background-audio-manager/get-background-audio-manager.axml":"<!-- audio.wxml -->\n<button onTap=\"audioPlay\">播放</button>\n<button onTap=\"audioPause\">暂停</button>\n<button onTap=\"audioStop\">停止</button>\n<button onTap=\"audio14\">seek到14秒</button>\n<button onTap=\"audioStart\">seek开头</button>\n<button onTap=\"getAllProps\">获取后台音频属性</button>\n","page/API/get-background-audio-manager/get-background-audio-manager.js":"Page({\n onReady(e) {\n this.backgroundAudioManager = my.getBackgroundAudioManager();\n //this.backgroundAudioManager.src = '';\n //this.backgroundAudioManager.startTime = 10000;\n this.backgroundAudioManager.src = 'http://ws.stream.qqmusic.qq.com/M500001VfvsJ21xFqb.mp3?guid=ffffffff82def4af4b12b3cd9337d5e7&uin=346897220&vkey=6292F51E1E384E061FF02C31F716658E5C81F5594D561F2E88B854E81CAAB7806D5E4F103E55D33C16F3FAC506D1AB172DE8600B37E43FAD&fromtag=46'\n \n\n this.backgroundAudioManager.onPlay(()=>{\n console.log(\"back onPlay\")\n my.alert({\n content:'开始播放'\n });\n })\n this.backgroundAudioManager.onPause(()=>{\n console.log(\"back onPause\")\n my.alert({\n content:'暂停播放'\n });\n })\n this.backgroundAudioManager.onCanplay(()=>{\n console.log(\"back onCanplay\")\n my.alert({\n content:'音频进入可以播放状态'\n });\n })\n this.backgroundAudioManager.onStop(()=>{\n console.log(\"back onStop\")\n my.alert({\n content:'背景音频停止事件'\n });\n })\n this.backgroundAudioManager.onEnded(()=>{\n console.log(\"back onEnded\")\n my.alert({\n content:'背景音频自然播放结束事件'\n });\n })\n this.backgroundAudioManager.onTimeUpdate(()=>{\n console.log(\"onTimeUpdate\")\n /*my.alert({\n content:'背景音频播放进度更新事件'\n });*/\n })\n this.backgroundAudioManager.onPrev(()=>{\n console.log(\"back onPrev\")\n my.alert({\n content:'点击上一曲事件'\n });\n })\n this.backgroundAudioManager.onNext(()=>{\n console.log(\"back onNext\")\n my.alert({\n content:'点击下一曲事件'\n });\n })\n this.backgroundAudioManager.onError(()=>{\n console.log(\"back onError\")\n my.alert({\n content:'背景音频播放错误事件'\n });\n })\n this.backgroundAudioManager.onWaiting(()=>{\n console.log(\"back onWaiting\")\n })\n },\n\n audioPlay: function () {\n console.log(\"call play\");\n this.backgroundAudioManager.play();\n console.log(\"call play end\");\n },\n audioPause: function () {\n console.log(\"call pause\");\n this.backgroundAudioManager.pause()\n },\n audioStop: function () {\n console.log(\"call stop\")\n this.backgroundAudioManager.stop()\n },\n audio14: function () {\n console.log(\"call seek 14\")\n this.backgroundAudioManager.seek(14)\n },\n audioStart: function () {\n console.log(\"call seek 0\")\n this.backgroundAudioManager.seek(0)\n },\n\n getAllProps(){\n let result = {\n duration:this.backgroundAudioManager.duration,\n currentTime:this.backgroundAudioManager.currentTime,\n paused:this.backgroundAudioManager.paused,\n startTime:this.backgroundAudioManager.startTime,\n buffered:this.backgroundAudioManager.buffered,\n src:this.backgroundAudioManager.src,\n }\n my.alert({ content:JSON.stringify(result) });\n\n }\n\n})\n","page/API/get-background-audio-manager/get-background-audio-manager.json":"{\n \"defaultTitle\": \"播放背景音乐\"\n}","page/API/get-image-info/get-image-info.axml":"<view class=\"page\">\n <view class=\"page-description\">获取图片信息 API</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.getImageInfo</view>\n <view class=\"page-section-demo\">\n <image src=\"{{src}}\" onError=\"imageError\" onLoad=\"imageLoad\" />\n <button type=\"primary\" onTap=\"getImageInfo\">获取图片信息</button>\n </view>\n </view>\n</view>\n\n\n","page/API/get-image-info/get-image-info.js":"Page({\n data: {\n src: 'https://img.alicdn.com/tps/TB1sXGYIFXXXXc5XpXXXXXXXXXX.jpg',\n },\n getImageInfo() {\n my.getImageInfo({\n src: this.data.src,\n success: (res) => {\n my.alert({\n content: JSON.stringify(res),\n });\n }\n })\n }\n});","page/API/get-location/format-location.js":"function formatLocation(longitude, latitude) {\n longitude = Number(longitude).toFixed(2)\n latitude = Number(latitude).toFixed(2)\n\n return {\n longitude: longitude.toString().split('.'),\n latitude: latitude.toString().split('.')\n }\n}\n\nexport default formatLocation\n","page/API/get-location/get-location.acss":".page-body-info {\n height: 250rpx;\n}\n.page-body-text-small {\n font-size: 24rpx;\n color: #000;\n margin-bottom: 100rpx;\n}\n.page-body-text-location {\n display: flex;\n font-size: 50rpx;\n}\n.page-body-text-location text {\n margin: 10rpx;\n}\n","page/API/get-location/get-location.axml":"<view class=\"page\">\n <view class=\"page-section\">\n <view class=\"page-section-demo\">\n <view>当前位置经纬度</view>\n <block a:if=\"{{hasLocation === false}}\">\n <text>未获取</text>\n </block>\n <block a:if=\"{{hasLocation === true}}\">\n <view class=\"page-body-text-location\">\n <text>E{{location.longitude[0]}}°{{location.longitude[1]}}′</text>\n <text>N{{location.latitude[0]}}°{{location.latitude[1]}}′</text>\n </view>\n </block>\n </view>\n\n <view class=\"page-section-btns\">\n <view onTap=\"getLocation\">获取位置</view>\n <view onTap=\"clear\">清空</view>\n </view>\n </view>\n</view>\n","page/API/get-location/get-location.js":"import formatLocation from './format-location.js';\n\nPage({\n data: {\n hasLocation: false,\n },\n getLocation() {\n var that = this;\n my.showLoading();\n my.getLocation({\n success(res) {\n my.hideLoading();\n console.log(res)\n that.setData({\n hasLocation: true,\n location: formatLocation(res.longitude, res.latitude)\n })\n },\n fail() {\n my.hideLoading();\n my.alert({ title: '定位失败' });\n },\n })\n },\n clear() {\n this.setData({\n hasLocation: false\n })\n }\n})\n","page/API/get-location/get-location.json":"{\n \"defaultTitle\": \"获取位置\"\n}\n","page/API/get-network-type/get-network-type.acss":".page-body-info {\n height: 200rpx;\n}\n.page-body-text-network-type {\n font-size: 80rpx;\n font-family: Helvetica;\n}\n","page/API/get-network-type/get-network-type.axml":"<view class=\"page\">\n <view class=\"page-section\">\n <view class=\"page-section-demo\">\n <view class=\"page-body-title\">网络状态</view>\n <block a:if=\"{{hasNetworkType === false}}\">\n <text class=\"page-body-text\">未获取</text>\n <text class=\"page-body-text\">点击按钮可获取网络状态</text>\n </block>\n <block a:if=\"{{hasNetworkType === true}}\">\n <text class=\"page-body-text-network-type\">{{networkType}}</text>\n </block>\n </view>\n\n <view class=\"page-section-btns\">\n <view onTap=\"getNetworkType\">获取手机网络状态</view>\n <view onTap=\"clear\">清空</view>\n </view>\n </view>\n</view>\n","page/API/get-network-type/get-network-type.js":"Page({\n data: {\n hasNetworkType: false\n },\n onLoad() {\n this.onChange = this.onChange.bind(this);\n // my.onNetworkChange(this.onChange);\n },\n onChange(res){\n console.log('onNetworkChange', res);\n this.setData({\n hasNetworkType: true,\n networkType: res.networkType\n });\n },\n onUnload() {\n // my.offNetworkChange(this.onChange);\n },\n getNetworkType() {\n my.getNetworkType({\n success: (res) => {\n this.setData({\n hasNetworkType: true,\n networkType: res.networkType\n })\n }\n })\n },\n clear() {\n this.setData({\n hasNetworkType: false,\n networkType: ''\n })\n },\n});\n","page/API/get-network-type/get-network-type.json":"{\n \"defaultTitle\": \"获取手机网络状态\"\n}\n","page/API/get-server-time/get-server-time.axml":"<view class=\"page\">\n <view class=\"page-section\">\n <view class=\"page-section-btns\">\n <view onTap=\"getServerTime\">获取服务器时间</view>\n </view>\n </view>\n</view>","page/API/get-server-time/get-server-time.js":"Page({\n\n getServerTime(){\n my.getServerTime({\n success: (res) => {\n my.alert({\n content: res.time,\n });\n },\n });\n }\n})\n","page/API/get-system-info/get-system-info.acss":"","page/API/get-system-info/get-system-info.axml":"<view class=\"page\">\n <view class=\"page-section\">\n <view class=\"page-section-demo\">\n <text>手机型号</text>\n <input type=\"text\" disabled=\"{{true}}\" value=\"{{systemInfo.model}}\"></input>\n </view>\n <view class=\"page-section-demo\">\n <text>语言</text>\n <input type=\"text\" disabled=\"{{true}}\" value=\"{{systemInfo.language}}\"></input>\n </view>\n <view class=\"page-section-demo\">\n <text>版本</text>\n <input type=\"text\" disabled=\"{{true}}\" value=\"{{systemInfo.version}}\"></input>\n </view>\n <view class=\"page-section-demo\">\n <text>window宽度</text>\n <input type=\"text\" disabled=\"{{true}}\" value=\"{{systemInfo.windowWidth}}\"></input>\n </view>\n <view class=\"page-section-demo\">\n <text>window高度</text>\n <input type=\"text\" disabled=\"{{true}}\" value=\"{{systemInfo.windowHeight}}\"></input>\n </view>\n <view class=\"page-section-demo\">\n <text>DPI</text>\n <input type=\"text\" disabled=\"{{true}}\" value=\"{{systemInfo.pixelRatio}}\"></input>\n </view>\n <view class=\"page-section-btns\">\n <view onTap=\"getSystemInfo\">获取手机系统信息</view>\n <view onTap=\"getSystemInfoSync\">同步获取手机系统信息</view>\n </view>\n </view>\n</view>\n","page/API/get-system-info/get-system-info.js":"Page({\n data: {\n systemInfo: {}\n },\n getSystemInfo() {\n my.getSystemInfo({\n success: (res) => {\n this.setData({\n systemInfo: res\n })\n }\n })\n },\n getSystemInfoSync() {\n this.setData({\n systemInfo: my.getSystemInfoSync(),\n });\n },\n})\n","page/API/get-system-info/get-system-info.json":"{\n \"defaultTitle\": \"获取手机系统信息\"\n}\n","page/API/get-title-color/get-title-color.acss":"","page/API/get-title-color/get-title-color.axml":"<view>\n <view class=\"page-section-demo\">\n <text>目前导航栏的背景色:\n </text>\n <input type=\"text\" disabled=\"{{true}}\" value=\"{{titleColor.color}}\">\n </input>\n </view>\n <view class=\"page-section-btns\">\n <view onTap=\"getTitleColor\">获取导航栏背景颜色\n </view>\n </view>\n</view>","page/API/get-title-color/get-title-color.js":"Page({\n data: {\n titleColor: {},\n },\n getTitleColor() {\n my.getTitleColor({\n success: (res) => {\n this.setData({\n titleColor: res\n })\n }\n })\n }\n});\n","page/API/get-title-color/get-title-color.json":"{\n \"defaultTitle\": \"获取导航栏背景颜色\"\n}\n","page/API/get-user-info/get-user-info.acss":".userinfo-avatar {\n text-align: center;\n}\n\n.userinfo-avatar-img {\n border-radius: 64px;\n width: 64px;\n height: 64px;\n}\n\n.userinfo-nickname {\n font-size: 12px;\n text-align: center;\n}","page/API/get-user-info/get-user-info.axml":"<view class=\"page\">\n <view class=\"page-section\">\n <view class=\"page-section-demo\">\n <block a:if=\"{{hasUserInfo === false}}\">\n <text>点击 [获取] 可获取用户头像及昵称</text>\n </block>\n <block a:if=\"{{hasUserInfo === true}}\">\n <view class=\"userinfo-avatar\">\n <image class=\"userinfo-avatar-img\" src=\"{{userInfo.avatar}}\"></image>\n </view>\n <view class=\"userinfo-nickname\">{{userInfo.nickName}}</view>\n </block>\n </view>\n <view class=\"page-section-btns\">\n <view onTap=\"getUserInfo\">获取</view>\n <view onTap=\"clear\">清空</view>\n </view>\n </view>\n</view>\n","page/API/get-user-info/get-user-info.js":"var app = getApp()\nPage({\n data: {\n hasUserInfo: false\n },\n getUserInfo() {\n my.getAuthCode({\n scopes: 'auth_user',\n fail: (error) => {\n console.error('getAuthCode', error);\n },\n success: () => {\n // do login...\n // then\n my.getAuthUserInfo({\n fail: (error) => {\n console.error('getAuthUserInfo', error);\n },\n success: (userInfo) => {\n console.log(`userInfo:`, userInfo);\n this.setData({\n userInfo,\n hasUserInfo: true,\n });\n abridge.alert({\n title: JSON.stringify(userInfo), // alert 框的标题\n });\n }\n });\n }\n });\n },\n clear() {\n this.setData({\n hasUserInfo: false,\n userInfo: {}\n })\n }\n})\n","page/API/get-user-info/get-user-info.json":"{\n \"defaultTitle\": \"获取用户信息\"\n}\n","page/API/image/image.acss":"","page/API/image/image.axml":"<view class=\"page\">\n <view class=\"page-section\">\n <view class=\"page-section-btns\">\n <view onTap=\"chooseImage\">选择照片</view>\n <view onTap=\"previewImage\">预览照片</view>\n <!--<view onTap=\"saveImage\">保存照片</view>-->\n </view>\n </view>\n</view>\n","page/API/image/image.js":"Page({\n chooseImage() {\n my.chooseImage({\n sourceType: ['camera','album'],\n count: 2,\n success: (res) => {\n my.alert({\n content: JSON.stringify(res),\n \n });\n },\n fail:()=>{\n my.showToast({\n content: 'fail', // 文字内容\n });\n }\n })\n },\n previewImage() {\n my.previewImage({\n current: 2,\n urls: [\n 'https://img.alicdn.com/tps/TB1sXGYIFXXXXc5XpXXXXXXXXXX.jpg',\n 'https://img.alicdn.com/tps/TB1pfG4IFXXXXc6XXXXXXXXXXXX.jpg',\n 'https://img.alicdn.com/tps/TB1h9xxIFXXXXbKXXXXXXXXXXXX.jpg'\n ],\n });\n },\n saveImage() {\n my.saveImage({\n url: 'https://img.alicdn.com/tps/TB1sXGYIFXXXXc5XpXXXXXXXXXX.jpg',\n showActionSheet: true,\n success: () => {\n my.alert({\n title: '保存成功',\n });\n },\n });\n }\n});","page/API/image/image.json":"{\n \"defaultTitle\": \"图片\"\n}\n","page/API/keyboard/keyboard.axml":"<view class=\"page\">\n <view class=\"page-description\">输入框</view>\n <view class=\"page-section\">\n <view class=\"form-row\">\n <view class=\"form-row-label\">密码键盘</view>\n <view class=\"form-row-content\">\n <input class=\"input\" password type=\"text\" onInput=\"bindHideKeyboard\" placeholder=\"输入 123 自动收起键盘\" />\n </view>\n </view>\n\n <view class=\"form-row\">\n <view class=\"form-row-label\">数字键盘</view>\n <view class=\"form-row-content\">\n <input class=\"input\" type=\"digit\" onInput=\"bindHideKeyboard\" placeholder=\"输入 123 自动收起键盘\" />\n </view>\n </view>\n </view>\n</view>\n","page/API/keyboard/keyboard.js":"Page({\n bindHideKeyboard(e) {\n if (e.detail.value === \"123\") {\n // 收起键盘\n my.hideKeyboard();\n }\n },\n});\n","page/API/keyboard/keyboard.json":"{\n \"defaultTitle\": \"键盘\"\n}","page/API/loading/loading.acss":".tips{\n margin-left: 10px;\n margin-top: 20px; \n color: red;\n font-size: 12px;\n}\n.tips .item {\n margin: 5px 0;\n color: #888888;\n line-height: 14px;\n}","page/API/loading/loading.axml":"<view class=\"page\">\n <view class=\"page-section\">\n <view class=\"page-section-title\">\n 显示 loading 后,会覆盖整个h5页面,页面元素不能交互。\n </view>\n <view class=\"page-section-btns\">\n <view onTap=\"showLoading\">显示加载提示</view>\n </view>\n </view>\n</view>\n","page/API/loading/loading.js":"Page({\n showLoading() {\n my.showLoading({\n content: '加载中...',\n delay: '1000',\n });\n setTimeout(() => {\n my.hideLoading();\n }, 5000);\n },\n});\n","page/API/loading/loading.json":"{\n \"defaultTitle\": \"加载提示\"\n}\n","page/API/make-phone-call/make-phone-call.acss":"","page/API/make-phone-call/make-phone-call.axml":"<view class=\"page\">\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.makePhoneCall</view>\n <view class=\"page-section-btns\">\n <view onTap=\"makePhoneCall\">打电话</view>\n </view>\n </view>\n</view>\n","page/API/make-phone-call/make-phone-call.js":"Page({\n makePhoneCall() {\n my.makePhoneCall({ number: '95888' });\n },\n});\n","page/API/make-phone-call/make-phone-call.json":"{\n \"defaultTitle\": \"打电话\"\n}\n","page/API/memory-warning/memory-warning.acss":"","page/API/memory-warning/memory-warning.axml":"<view class=\"page\">\n\n <button type=\"primary\" onTap=\"onMemoryWarning\">\n \b开始监听内存不足告警\n </button>\n\n</view>\n","page/API/memory-warning/memory-warning.js":"Page({\n onLoad() {\n this.callback = (res) => {\n var levelString = '\u001diOS 设备, 无 level 传入.';\n switch (res.level) {\n case 10:\n levelString = 'Android 设备, level = TRIM_MEMORY_RUNNING_LOW';\n break;\n case 15:\n levelString = 'Android 设备, level = TRIM_MEMORY_RUNNING_CRITICAL';\n break;\n }\n my.alert({\n title: '收到内存不足告警',\n content: levelString\n });\n };\n this.isApiAvailable = my.canIUse('onMemoryWarning');\n },\n onMemoryWarning() {\n if (this.isApiAvailable) {\n my.onMemoryWarning(this.callback);\n } else {\n my.alert({\n title: '\b\b客户端版本过低',\n content: 'my.onMemoryWarning() 和 my.offMemoryWarning() 需要\b 10.1.35 \b及以上版本'\n });\n }\n },\n onUnload() {\n if (this.isApiAvailable) {\n my.offMemoryWarning(this.callback); \n }\n }\n});\n","page/API/memory-warning/memory-warning.json":"{\n \"defaultTitle\": \"OnMemoryWarning\"\n}\n","page/API/multi-level-select/multi-level-select.axml":"<view class=\"page\">\n <view class=\"page-description\">多级联选择器 API</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.multiLevelSelect</view>\n <view class=\"page-section-demo\">\n <button type=\"primary\" onTap=\"openMultiLevelSelect\">多级联选择器</button>\n </view>\n </view>\n</view>\n","page/API/multi-level-select/multi-level-select.js":"Page({\n openMultiLevelSelect() {\n my.multiLevelSelect({\n title: '多级联选择器',//级联选择标题\n list: [\n {\n name: \"杭州市\",//条目名称\n subList: [\n {\n name: \"西湖区\",\n subList: [\n {\n name: \"古翠街道\"\n },\n {\n name: \"文新街道\"\n }\n ]\n },\n {\n name: \"上城区\",\n subList: [\n {\n name: \"延安街道\"\n },\n {\n name: \"龙翔桥街道\"\n }\n ]\n }\n ]//级联子数据列表\n }],//级联数据列表\n success:(res)=>{\n my.alert({title:JSON.stringify(res)})\n }\n });\n }\n})\n","page/API/multi-level-select/multi-level-select.json":"{\n \"defaultTitle\": \"多级联选择器\"\n}","page/API/navigation-bar-loading/navigation-bar-loading.acss":"button + button {\n margin-top: 20rpx;\n}\n","page/API/navigation-bar-loading/navigation-bar-loading.axml":"<view class=\"page\">\n <view class=\"page-section\">\n <button type=\"primary\" onTap=\"showNavigationBarLoading\">显示加载动画</button>\n <button onTap=\"hideNavigationBarLoading\">隐藏加载动画</button>\n </view>\n</view>\n","page/API/navigation-bar-loading/navigation-bar-loading.js":"Page({\n showNavigationBarLoading() {\n my.showNavigationBarLoading()\n },\n hideNavigationBarLoading() {\n my.hideNavigationBarLoading()\n }\n})\n","page/API/navigation-bar-loading/navigation-bar-loading.json":"{\n \"defaultTitle\": \"标题栏加载动画\"\n}\n","page/API/navigator/navigator.acss":"button + button {\n margin-top: 20rpx;\n}\n","page/API/navigator/navigator.axml":"<view class=\"page\">\n <view class=\"page-section\">\n <button type=\"primary\" onTap=\"navigateTo\">跳转新页面</button>\n <button type=\"primary\" onTap=\"navigateBack\">返回上一页</button>\n <button type=\"primary\" onTap=\"redirectTo\">在当前页面打开 - 获取用户信息</button>\n <button type=\"primary\" onTap=\"switchTab\">跳转 Tab - 组件</button>\n <view class=\"page-description\">本Demo不具备商家应用跳转功能,仅展示 API 的使用,具体接入请参考商家应用官方文档 API 的商家应用相互跳转部分。</view>\n <button type=\"primary\" onTap=\"navigateToMiniProgram\">跳转到商家应用</button>\n <button type=\"primary\" onTap=\"navigateBackMiniProgram\">跳回商家应用</button>\n </view>\n</view>\n","page/API/navigator/navigator.js":"Page({\n navigateTo() {\n my.navigateTo({ url: '../get-user-info/get-user-info' })\n },\n navigateBack() {\n my.navigateBack()\n },\n redirectTo() {\n my.redirectTo({ url: '../get-user-info/get-user-info' })\n },\n navigateToMiniProgram() {\n if (my.canIUse('navigateToMiniProgram')) {\n my.navigateToMiniProgram({\n appId: '2017072607907880',\n extraData: {\n \"data1\": \"test\"\n },\n success: (res) => {\n console.log(JSON.stringfy(res))\n },\n fail: (res) => {\n console.log(JSON.stringfy(res))\n }\n });\n }\n },\n navigateBackMiniProgram() {\n if (my.canIUse('navigateBackMiniProgram')) {\n my.navigateBackMiniProgram({\n extraData: {\n \"data1\": \"test\"\n },\n success: (res) => {\n console.log(JSON.stringfy(res))\n },\n fail: (res) => {\n console.log(JSON.stringfy(res))\n }\n });\n }\n },\n switchTab() {\n my.switchTab({\n url: '/page/tabBar/component/index',\n success: () => {\n my.showToast({\n content: '成功',\n type: 'success',\n duration: 4000\n });\n }\n }\n );\n },\n})\n","page/API/navigator/navigator.json":"{\n \"defaultTitle\": \"页面跳转\"\n}\n","page/API/ocr-bank-card/ocr-bank-card.acss":"@import \"/page/API/ocr-template/ocr-template.acss\";\n","page/API/ocr-bank-card/ocr-bank-card.axml":"<import src=\"../ocr-template/ocr-template.axml\"/>\n<template is=\"ocr-template\" data=\"{{textArry,imgUrl}}\"/>","page/API/ocr-bank-card/ocr-bank-card.js":"Page({\n data: {\n textArry: [],\n imgUrl: \"https://gw.alipayobjects.com/zos/rmsportal/HRJifiDxDoDRnmrIzFQn.jpg\"\n },\n onLoad() {\n this.callFn(this.data.imgUrl);\n },\n callFn(url){\n my.showLoading({\n content: '加载中...',\n delay: 100,\n });\n my.ocr({\n ocrType: 'ocr_bank_card',\n path: url,\n success: (res) => {\n let data = JSON.parse(res.result.outputs[0].outputValue.dataValue);\n let {card_num}=data;\n this.setData({\n imgUrl:url,\n textArry: [\n { title: '卡号', message: card_num }\n ],\n });\n my.hideLoading();\n },\n fail: (res) => {\n my.hideLoading();\n\n my.alert({\n title:'fail',\n content:JSON.stringify(res),\n });\n },\n\n });\n },\n photoSubmit() {//点击上传\n my.chooseImage({\n count: 1,\n success: (res) => {\n this.callFn(res.apFilePaths[0]);\n },\n });\n },\n imageLoad(e){\n\n },\n imageError(e){\n\n }\n});\n","page/API/ocr-bank-card/ocr-bank-card.json":"{\n \"defaultTitle\": \"银行卡识别\"\n}","page/API/ocr-business-card/ocr-business-card.acss":"@import \"/page/API/ocr-template/ocr-template.acss\";\n","page/API/ocr-business-card/ocr-business-card.axml":"<import src=\"../ocr-template/ocr-template.axml\"/>\n<template is=\"ocr-template\" data=\"{{textArry,imgUrl}}\"/>","page/API/ocr-business-card/ocr-business-card.js":"Page({\n data: {\n textArry: [],\n imgUrl: \"https://gw.alipayobjects.com/zos/rmsportal/ELiPtNKfHIGlpjOotpoC.jpg\"\n },\n onLoad() {\n this.callFn(this.data.imgUrl);\n },\n callFn(url){\n my.showLoading({\n content: '加载中...',\n delay: 100,\n });\n my.ocr({\n ocrType: 'ocr_business_card',\n path: url,\n success: (res) => {\n let data = JSON.parse(res.result.outputs[0].outputValue.dataValue);\n let {name, company, department, title, tel_cell, tel_work, addr, email}=data;\n this.setData({\n imgUrl:url,\n textArry: [\n { title: '姓名', message: name },\n { title: '公司', message: company },\n { title: '部门', message: department },\n { title: '职位', message: title },\n { title: '手机号码', message: tel_cell },\n { title: '电话号码', message: tel_work },\n { title: '地址', message: addr },\n { title: '邮箱', message: email }\n\n ],\n });\n my.hideLoading();\n },\n fail: (res) => {\n my.hideLoading();\n\n my.alert({\n title:'fail',\n content:JSON.stringify(res),\n });\n },\n\n });\n },\n photoSubmit() {//点击上传\n my.chooseImage({\n count: 1,\n success: (res) => {\n this.callFn(res.apFilePaths[0]);\n },\n });\n },\n imageLoad(e){\n\n },\n imageError(e){\n\n }\n});\n","page/API/ocr-business-card/ocr-business-card.json":"{\n \"defaultTitle\": \"名片识别\"\n}","page/API/ocr-business-license/ocr-business-license.acss":"@import \"/page/API/ocr-template/ocr-template.acss\";\n","page/API/ocr-business-license/ocr-business-license.axml":"<import src=\"../ocr-template/ocr-template.axml\"/>\n<template is=\"ocr-template\" data=\"{{textArry,imgUrl}}\"/>","page/API/ocr-business-license/ocr-business-license.js":"Page({\n data: {\n textArry: [],\n imgUrl: \"https://gw.alipayobjects.com/zos/rmsportal/CLaHUdhxQUlVRnlFPisN.jpg\"\n },\n onLoad() {\n this.callFn(this.data.imgUrl);\n },\n callFn(url){\n my.showLoading({\n content: '加载中...',\n delay: 100,\n });\n my.ocr({\n ocrType: 'ocr_business_license',\n path: url,\n success: (res) => {\n let data = JSON.parse(res.result.outputs[0].outputValue.dataValue);\n let {reg_num, person,business,captial,establish_date, name, address, valid_period}=data;\n this.setData({\n imgUrl:url,\n textArry: [\n { title: '注册号', message: reg_num },\n { title: '法人', message: person },\n { title: '公司名称', message: name },\n { title: '地址', message: address },\n { title: '注册时间', message: this.reData(establish_date) },\n { title: '营业期限', message: this.reData(valid_period) },\n { title: '注册资本', message: captial },\n { title: '经营范围', message: business },\n\n ],\n });\n my.hideLoading();\n },\n fail: (res) => {\n my.hideLoading();\n\n my.alert({\n title:'fail',\n content:JSON.stringify(res),\n });\n },\n\n });\n },\n reData(data) {\n return data.substring(0,4)+'年'+data.substring(4,6)+'月'+data.substring(6,8)+'日'\n },\n photoSubmit() {//点击上传\n my.chooseImage({\n count: 1,\n success: (res) => {\n this.callFn(res.apFilePaths[0]);\n },\n });\n },\n imageLoad(e){\n\n },\n imageError(e){\n\n }\n});\n","page/API/ocr-business-license/ocr-business-license.json":"{\n \"defaultTitle\": \"营业执照识别\"\n}","page/API/ocr-driver-license/ocr-driver-license.acss":"@import \"/page/API/ocr-template/ocr-template.acss\";\n","page/API/ocr-driver-license/ocr-driver-license.axml":"<import src=\"../ocr-template/ocr-template.axml\"/>\n<template is=\"ocr-template\" data=\"{{textArry,imgUrl}}\"/>","page/API/ocr-driver-license/ocr-driver-license.js":"Page({\n data: {\n textArry: [],\n imgUrl: \"https://gw.alipayobjects.com/zos/rmsportal/VSYVmTFPyVyNlxYvRGBJ.jpg\"\n },\n onLoad() {\n this.callFn(this.data.imgUrl);\n },\n callFn(url){\n my.showLoading({\n content: '加载中...',\n delay: 100,\n });\n my.ocr({\n ocrType: 'ocr_driver_license',\n side:'face',\n path: url,\n success: (res) => {\n let data = JSON.parse(res.result.outputs[0].outputValue.dataValue);\n let {num, name,sex,addr, start_date, vehicle_type, end_date}=data;\n this.setData({\n imgUrl:url,\n textArry: [\n { title: '证号', message: num },\n { title: '姓名', message: name },\n { title: '性别', message: sex},\n { title: '地址', message: addr},\n { title: '准驾车型', message: vehicle_type },\n { title: '起始日期', message: this.reData(start_date) },\n { title: '有效日期', message: end_date },\n ],\n });\n my.hideLoading();\n },\n fail: (res) => {\n my.hideLoading();\n\n my.alert({\n title:'fail',\n content:JSON.stringify(res),\n });\n },\n\n });\n },\n photoSubmit() {//点击上传\n my.chooseImage({\n count: 1,\n success: (res) => {\n this.callFn(res.apFilePaths[0]);\n },\n });\n },\n reData(data) {\n return data.substring(0,4)+'年'+data.substring(4,6)+'月'+data.substring(6,8)+'日'\n },\n imageLoad(e){\n\n },\n imageError(e){\n\n }\n});\n","page/API/ocr-driver-license/ocr-driver-license.json":"{\n \"defaultTitle\": \"驾驶证识别\"\n}","page/API/ocr-general/ocr-general.acss":"@import \"/page/API/ocr-template/ocr-template.acss\";\n","page/API/ocr-general/ocr-general.axml":"<import src=\"../ocr-template/ocr-template.axml\"/>\n<template is=\"ocr-template\" data=\"{{textArry,imgUrl}}\"/>","page/API/ocr-general/ocr-general.js":"Page({\n data: {\n textArry: [],\n imgUrl: \"https://gw.alipayobjects.com/zos/rmsportal/OgNRRkBjbyUSSGoqvKDZ.jpg\"\n },\n onLoad() {\n this.callFn(this.data.imgUrl);\n },\n callFn(url){\n my.showLoading({\n content: '加载中...',\n delay: 100,\n });\n this.data.textArry=[];\n my.ocr({\n ocrType: 'ocr_general',\n path: url,\n success: (res) => {\n let data = res.result.text;\n for(var i=0;i<data.length;i++){\n this.data.textArry.push({ title: i+1, message: data[i] });\n }\n this.setData({\n imgUrl:url,\n textArry: this.data.textArry,\n });\n my.hideLoading();\n },\n fail: (res) => {\n my.hideLoading();\n my.alert({\n title:'fail',\n content:JSON.stringify(res),\n });\n },\n\n });\n },\n photoSubmit() {//点击上传\n my.chooseImage({\n count: 1,\n success: (res) => {\n this.callFn(res.apFilePaths[0]);\n },\n });\n },\n imageLoad(e){\n\n },\n imageError(e){\n\n }\n});\n","page/API/ocr-general/ocr-general.json":"{\n \"defaultTitle\": \"通用文字识别\"\n}","page/API/ocr-idcard-face/ocr-idcard-face.acss":"@import \"/page/API/ocr-template/ocr-template.acss\";\n","page/API/ocr-idcard-face/ocr-idcard-face.axml":"<import src=\"../ocr-template/ocr-template.axml\"/>\n<template is=\"ocr-template\" data=\"{{textArry,imgUrl}}\"/>","page/API/ocr-idcard-face/ocr-idcard-face.js":"Page({\n data: {\n textArry: [],\n imgUrl: \"https://gw.alipayobjects.com/zos/rmsportal/bqeolZyhDKKJwGsgeHtm.jpg\"\n },\n onLoad() {\n this.callFn(this.data.imgUrl);\n },\n callFn(url){\n my.showLoading({\n content: '加载中...',\n delay: 100,\n });\n my.ocr({\n ocrType: 'ocr_idcard',\n side: 'face',\n path: url,\n success: (res) => {\n let data = JSON.parse(res.result.outputs[0].outputValue.dataValue);\n let {name, sex, nationality, birth, address, num}=data;\n this.setData({\n imgUrl:url,\n textArry: [\n {title: '姓名', message: name},\n {title: '性别', message: sex},\n {title: '民族', message: nationality},\n {title: '出生', message: this.reData(birth)},\n {title: '地址', message: address},\n {title: '身份号码', message: num}\n ],\n });\n my.hideLoading();\n },\n fail: (res) => {\n my.hideLoading();\n\n my.alert({\n title:'fail',\n content:JSON.stringify(res),\n });\n },\n\n });\n },\n photoSubmit() {//点击上传\n my.chooseImage({\n count: 1,\n success: (res) => {\n this.callFn(res.apFilePaths[0]);\n },\n });\n },\n reData(data) {\n return data.substring(0,4)+'年'+data.substring(4,6)+'月'+data.substring(6,8)+'日'\n },\n imageLoad(e){\n\n },\n imageError(e){\n\n }\n});\n","page/API/ocr-idcard-face/ocr-idcard-face.json":"{\n \"defaultTitle\": \"身份证识别\"\n}","page/API/ocr-passport/ocr-passport.acss":"@import \"/page/API/ocr-template/ocr-template.acss\";\n","page/API/ocr-passport/ocr-passport.axml":"<import src=\"../ocr-template/ocr-template.axml\"/>\n<template is=\"ocr-template\" data=\"{{textArry,imgUrl}}\"/>","page/API/ocr-passport/ocr-passport.js":"Page({\n data: {\n textArry: [\n { title: '签发机关', message: '公安部出入境管理局' },\n { title: '生日', message: '2020年12月27日' },\n { title: '出生地', message: '四川' },\n { title: '国籍', message: 'CHN' },\n { title: '到期日期', message: '2044年04月08日' },\n { title: '发证日期', message: '2024年04月09日' },\n { title: '发证地址', message: '四川' },\n { title: '姓名英文', message: 'ZHIXIAOBAO' },\n { title: '姓名中文', message: '支小宝' },\n { title: '护照号码', message: 'E09222222' },\n { title: '身份ID', message: 'MCNONCNF<<<<A9' },\n { title: '性别', message: 'F' },\n { title: '国家', message: 'CHN' }\n ],\n imgUrl: \"https://gw.alipayobjects.com/zos/rmsportal/JUcFsOCCRzlYpEHkKczj.jpg\"\n },\n onLoad() {\n this.callFn(this.data.imgUrl);\n },\n callFn(url){\n my.showLoading({\n content: '加载中...',\n delay: 100,\n });\n my.ocr({\n ocrType: 'ocr_passport',\n path: url,\n success: (res) => {\n let data = JSON.parse(res.result.outputs[0].outputValue.dataValue);\n\n let {authority, birth_date, birth_place, country, expiry_date, issue_date, issue_place, name, name_cn, passport_no, person_id, sex, src_country\n }=data;\n this.setData({\n imgUrl:url,\n textArry: [\n { title: '签发机关', message: authority },\n { title: '生日', message: this.reData(birth_date) },\n { title: '出生地', message: birth_place },\n { title: '国籍', message: country },\n { title: '到期日期', message: this.reData(expiry_date) },\n { title: '发证日期', message: this.reData(issue_date) },\n { title: '发证地址', message: issue_place },\n { title: '姓名英文', message: name },\n { title: '姓名中文', message: name_cn },\n { title: '护照号码', message: passport_no },\n { title: '身份ID', message: person_id },\n { title: '性别', message: sex },\n { title: '国家', message: src_country }\n ],\n });\n my.hideLoading();\n },\n fail: (res) => {\n my.hideLoading();\n\n my.alert({\n title:'fail',\n content:JSON.stringify(res),\n });\n },\n\n });\n },\n photoSubmit() {//点击上传\n my.chooseImage({\n count: 1,\n success: (res) => {\n this.callFn(res.apFilePaths[0]);\n },\n });\n },\n reData(data) {\n return data.substring(0,4)+'年'+data.substring(4,6)+'月'+data.substring(6,8)+'日'\n },\n imageLoad(e){\n\n },\n imageError(e){\n\n }\n});\n","page/API/ocr-passport/ocr-passport.json":"{\n \"defaultTitle\": \"护照识别\"\n}","page/API/ocr-template/ocr-template.acss":".api {\n font-family: -apple-system-font,Helvetica Neue,Helvetica,sans-serif;\n font-size: 28rpx;\n padding: 32rpx;\n}\n\n.container {\n padding-top: 48rpx;\n}\n\n.photo-bg {\n height: 600rpx;\n width: 100%;\n text-align: center;\n}\n\n.card {\n width: 600rpx;\n height: 600rpx;\n vertical-align: middle;\n}\n\n.content {\n padding: 0 20rpx;\n background: #fff;\n}\n\n.content .fn {\n display: block;\n height: 80rpx;\n line-height: 80rpx;\n color: #8f8f8f;\n font-size: 25rpx;\n}\n\n.list {\n position: relative;\n box-sizing: border-box;\n padding: 20rpx 0;\n margin-bottom: 5px;\n border: #dee8f0 solid 1px;\n}\n\n.list:last-child {\n margin: 0;\n}\n\n.fn-left {\n display: inline-block;\n position: absolute;\n top:30%;\n width: 150rpx;\n margin-left: 23rpx;\n}\n\n.fn-right {\n box-sizing: border-box;\n display: inline-block;\n width: 520rpx;\n padding-left: 23rpx;\n margin-left: 170rpx;\n color: #335c92;\n border-left: #dee8f0 solid 1px;\n}\n\n.btn-con {\n width: 100%;\n overflow: hidden;\n padding: 20rpx 0;\n background: #fff;\n}\n\n.photo-submit {\n margin: 0 auto;\n width: 90%;\n height: 100rpx;\n line-height: 100rpx;\n font-size: 35rpx;\n}\n\n.foot{\n height: 120rpx;\n line-height: 120rpx;\n text-align: center;\n font-size: 25rpx;\n color: #6f6f6f;\n font-family: PingFangSC-Regular;\n}\n\n.ali-cloud {\n width: 75px;\n height: 16px;\n vertical-align:middle\n}","page/API/ocr-template/ocr-template.axml":"<template name=\"ocr-template\">\n<view>\n <view class=\"photo-bg\">\n <image class=\"card\" src={{imgUrl}} mode=\"aspectFit\" onError=\"imageError\" onLoad=\"imageLoad\" />\n </view>\n <view class=\"content\">\n <text class=\"fn\">识别结果</text>\n <view\n class=\"list\"\n a:for=\"{{textArry}}\">\n <text class=\"fn-left\"> {{item.title}} </text>\n <text class=\"fn-right\"> {{item.message}} </text>\n </view>\n\n </view>\n <view class=\"btn-con\">\n <button\n catchTap=\"photoSubmit\"\n class=\"photo-submit\"\n type=\"primary\">上传图片</button>\n </view>\n</view>\n<view class=\"foot\">\n Powered by <image class=\"ali-cloud\" src=\"/image/ocr/ali-cloud.png\" mode=\"center\" />\n</view>\n</template>","page/API/ocr-template/ocr-template.js":"Page({});\n","page/API/ocr-train-ticket/ocr-train-ticket.acss":"@import \"/page/API/ocr-template/ocr-template.acss\";\n","page/API/ocr-train-ticket/ocr-train-ticket.axml":"<import src=\"../ocr-template/ocr-template.axml\"/>\n<template is=\"ocr-template\" data=\"{{textArry,imgUrl}}\"/>","page/API/ocr-train-ticket/ocr-train-ticket.js":"Page({\n data: {\n textArry: [],\n imgUrl: \"https://gw.alipayobjects.com/zos/rmsportal/bQcotnJacNoSYPeNfAjZ.jpg\"\n },\n onLoad() {\n this.callFn(this.data.imgUrl);\n },\n callFn(url){\n my.showLoading({\n content: '加载中...',\n delay: 100,\n });\n my.ocr({\n ocrType: 'ocr_train_ticket',\n path: url,\n success: (res) => {\n let data = res.result;\n let {date, destination, origin, level, number, place, price}=data;\n this.setData({\n imgUrl:url,\n textArry: [\n { title: '乘坐时间', message: date },\n { title: '目的地', message: destination },\n { title: '出发地', message: origin },\n { title: '车型', message: level },\n { title: '车次', message: number },\n { title: '座位', message: place },\n { title: '票价', message: price }\n ],\n });\n my.hideLoading();\n },\n fail: (res) => {\n my.hideLoading();\n\n my.alert({\n title:'fail',\n content:JSON.stringify(res),\n });\n },\n\n });\n },\n photoSubmit() {//点击上传\n my.chooseImage({\n count: 1,\n success: (res) => {\n this.callFn(res.apFilePaths[0]);\n },\n });\n },\n imageLoad(e){\n\n },\n imageError(e){\n\n }\n});\n","page/API/ocr-train-ticket/ocr-train-ticket.json":"{\n \"defaultTitle\": \"火车票识别\"\n}","page/API/ocr-vehicle-plate/ocr-vehicle-plate.acss":"@import \"/page/API/ocr-template/ocr-template.acss\";\n","page/API/ocr-vehicle-plate/ocr-vehicle-plate.axml":"<import src=\"../ocr-template/ocr-template.axml\"/>\n<template is=\"ocr-template\" data=\"{{textArry,imgUrl}}\"/>","page/API/ocr-vehicle-plate/ocr-vehicle-plate.js":"Page({\n data: {\n textArry: [],\n imgUrl: \"https://gw.alipayobjects.com/zos/rmsportal/uvBjLdgIbHlADgSmobOU.jpg\"\n },\n onLoad() {\n this.callFn(this.data.imgUrl);\n },\n callFn(url){\n my.ocr({\n ocrType: 'ocr_vehicle_plate',\n path: url,\n success: (res) => {\n let data = JSON.parse(res.result.outputs[0].outputValue.dataValue);\n this.setData({\n imgUrl:url,\n textArry: [\n { title: '车牌号', message: data.plates[0].txt },\n\n ],\n });\n my.hideLoading();\n },\n fail: (res) => {\n my.hideLoading();\n\n my.alert({\n title:'fail',\n content:JSON.stringify(res),\n });\n },\n\n });\n },\n photoSubmit() {//点击上传\n my.chooseImage({\n count: 1,\n success: (res) => {\n this.callFn(res.apFilePaths[0]);\n },\n });\n },\n imageLoad(e){\n\n },\n imageError(e){\n\n }\n});\n","page/API/ocr-vehicle-plate/ocr-vehicle-plate.json":"{\n \"defaultTitle\": \"车牌识别\"\n}","page/API/ocr-vehicle/ocr-vehicle.acss":"@import \"/page/API/ocr-template/ocr-template.acss\";\n","page/API/ocr-vehicle/ocr-vehicle.axml":"<import src=\"../ocr-template/ocr-template.axml\"/>\n<template is=\"ocr-template\" data=\"{{textArry,imgUrl}}\"/>","page/API/ocr-vehicle/ocr-vehicle.js":"Page({\n data: {\n textArry: [\n { title: '车牌号码', message: '浙BC9188' },\n { title: '车辆类型', message: '小型轿车' },\n { title: '所有人', message: '支小宝' },\n { title: '地址', message: '浙江省宁波市江东区园丁街88弄' },\n { title: '使用性质', message: '出租转非' },\n { title: '品牌型号', message: '桑塔纳牌SVW7180LE1' },\n { title: '识别代码', message: 'LSVAU033661234567' },\n { title: '发动机号', message: '0009827' },\n { title: '注册日期', message: '2006年07月21日' },\n { title: '发证日期', message: '2013年07月08日' },\n ],\n imgUrl: \"https://gw.alipayobjects.com/zos/rmsportal/xyWhFGfKPgIlwMtztXnf.jpg\"\n },\n onLoad() {\n this.callFn(this.data.imgUrl);\n },\n callFn(url){\n my.showLoading({\n content: '加载中...',\n delay: 100,\n });\n my.ocr({\n ocrType: 'ocr_vehicle',\n path: url,\n success: (res) => {\n console.log('res', res);\n let data = JSON.parse(res.result.outputs[0].outputValue.dataValue);\n let {plate_num, addr, vehicle_type, owner, use_character, model, vin, engine_num, register_date, issue_date}=data;\n this.setData({\n imgUrl:url,\n textArry: [\n { title: '车牌号码', message: plate_num },\n { title: '车辆类型', message: vehicle_type },\n { title: '所有人', message: owner },\n { title: '地址', message: addr },\n { title: '使用性质', message: use_character },\n { title: '品牌型号', message: model },\n { title: '识别代码', message: vin },\n { title: '发动机号', message: engine_num },\n { title: '注册日期', message: this.reData(register_date) },\n { title: '发证日期', message: this.reData(issue_date) },\n ],\n });\n my.hideLoading();\n },\n fail: (res) => {\n my.hideLoading();\n\n my.alert({\n title:'fail',\n content:JSON.stringify(res),\n });\n },\n\n });\n },\n photoSubmit() {//点击上传\n my.chooseImage({\n count: 1,\n success: (res) => {\n this.callFn(res.apFilePaths[0]);\n },\n });\n },\n reData(data) {\n return data.substring(0,4)+'年'+data.substring(4,6)+'月'+data.substring(6,8)+'日'\n },\n imageLoad(e){\n\n },\n imageError(e){\n\n }\n});\n","page/API/ocr-vehicle/ocr-vehicle.json":"{\n \"defaultTitle\": \"行驶证识别\"\n}","page/API/ocr-vin/ocr-vin.acss":"@import \"/page/API/ocr-template/ocr-template.acss\";\n","page/API/ocr-vin/ocr-vin.axml":"<import src=\"../ocr-template/ocr-template.axml\"/>\n<template is=\"ocr-template\" data=\"{{textArry,imgUrl}}\"/>","page/API/ocr-vin/ocr-vin.js":"Page({\n data: {\n textArry: [],\n imgUrl: \"https://gw.alipayobjects.com/zos/rmsportal/GPbtvSnPedYahofahAKX.jpg\"\n },\n onLoad() {\n this.callFn(this.data.imgUrl);\n },\n callFn(url){\n my.ocr({\n ocrType: 'ocr_vin',\n path: url,\n success: (res) => {\n let data = res.result.vin;\n this.setData({\n imgUrl:url,\n textArry: [\n { title: '车架号', message: data },\n ],\n });\n my.hideLoading();\n },\n fail: (res) => {\n my.hideLoading();\n my.alert({\n title:'fail',\n content:JSON.stringify(res),\n });\n },\n\n });\n },\n photoSubmit() {//点击上传\n my.chooseImage({\n count: 1,\n success: (res) => {\n this.callFn(res.apFilePaths[0]);\n },\n });\n },\n imageLoad(e){\n\n },\n imageError(e){\n\n }\n});\n","page/API/ocr-vin/ocr-vin.json":"{\n \"defaultTitle\": \"vin识别\"\n}","page/API/ocr/ocr.acss":".btn-area .navigator {\n background-color: #ff5500;\n height: 80rpx;\n line-height: 80rpx;\n width: 100%;\n color: #fff;\n font-size: 14px;\n text-align: center;\n border-radius: 3px;\n margin-bottom: 15px;\n}\n","page/API/ocr/ocr.axml":"<view class=\"page\">\n <view class=\"btn-area\">\n <navigator class=\"navigator\" url=\"../ocr-idcard-face/ocr-idcard-face\">身份证识别</navigator>\n <navigator class=\"navigator\" url=\"../ocr-vehicle/ocr-vehicle\">行驶证识别</navigator>\n <navigator class=\"navigator\" url=\"../ocr-driver-license/ocr-driver-license\">驾驶证识别</navigator>\n <navigator class=\"navigator\" url=\"../ocr-business-license/ocr-business-license\">营业执照识别</navigator>\n <navigator class=\"navigator\" url=\"../ocr-bank-card/ocr-bank-card\">银行卡识别</navigator>\n <navigator class=\"navigator\" url=\"../ocr-general/ocr-general\">通用文字识别</navigator>\n <navigator class=\"navigator\" url=\"../ocr-train-ticket/ocr-train-ticket\">火车票识别</navigator>\n <navigator class=\"navigator\" url=\"../ocr-passport/ocr-passport\">护照识别</navigator>\n <navigator class=\"navigator\" url=\"../ocr-vehicle-plate/ocr-vehicle-plate\">车牌识别</navigator>\n <navigator class=\"navigator\" url=\"../ocr-business-card/ocr-business-card\">名片识别</navigator>\n <navigator class=\"navigator\" url=\"../ocr-vin/ocr-vin\">vin识别</navigator>\n </view>\n</view>","page/API/ocr/ocr.js":"Page({\n\n});","page/API/ocr/ocr.json":"{\n \"defaultTitle\": \"OCR\"\n}","page/API/open-location/open-location.acss":"","page/API/open-location/open-location.axml":"<view class=\"page\">\n <view class=\"page-section\">\n <view class=\"page-section-demo\">\n <text>经度</text>\n <input type=\"text\" disabled=\"{{true}}\" value=\"{{longitude}}\" name=\"longitude\"></input>\n </view>\n <view class=\"page-section-demo\">\n <text>纬度</text>\n <input type=\"text\" disabled=\"{{true}}\" value=\"{{latitude}}\" name=\"latitude\"></input>\n </view>\n <view class=\"page-section-demo\">\n <text>位置名称</text>\n <input type=\"text\" disabled=\"{{true}}\" value=\"{{name}}\" name=\"name\"></input>\n </view>\n <view class=\"page-section-demo\">\n <text>详细位置</text>\n <input type=\"text\" disabled=\"{{true}}\" value=\"{{address}}\" name=\"address\"></input>\n </view>\n <view class=\"page-section-btns\">\n <view type=\"primary\" formType=\"submit\" onTap=\"openLocation\">查看位置</view>\n </view>\n </view>\n</view>\n","page/API/open-location/open-location.js":"Page({\n data: {\n longitude: '120.126293',\n latitude: '30.274653',\n name: '黄龙万科中心',\n address: '学院路77号',\n },\n\n openLocation() {\n my.openLocation({\n longitude: this.data.longitude,\n latitude: this.data.latitude,\n name: this.data.name,\n address: this.data.address,\n })\n }\n})\n","page/API/open-location/open-location.json":"{\n \"defaultTitle\": \"查看位置\"\n}\n","page/API/option-menu/option-menu.axml":"<view class=\"page\">\n <view class=\"page-description\">设置 optionMenu 按钮</view>\n</view>\n","page/API/option-menu/option-menu.js":"Page({\n onOptionMenuClick(e) {\n my.alert({\n content: `click option menu with index: ${JSON.stringify(e.data.index)}`,\n });\n },\n});\n","page/API/option-menu/option-menu.json":"{\n \"defaultTitle\": \"option-menu\",\n \"optionMenu\": {\n \"icon\": \"https://gw.alipayobjects.com/zos/rmsportal/gNnidPxAGHizBQYKznaO.png\"\n }\n}\n","page/API/options-select/options-select.axml":"<view class=\"page\">\n <view class=\"page-description\">选项选择器 API</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.optionsSelect</view>\n <view class=\"page-section-demo\">\n <button type=\"primary\" onTap=\"openOne\">单列选择器</button>\n </view>\n <view class=\"page-section-demo\">\n <button type=\"primary\" onTap=\"openTwo\">双列选择器</button>\n </view>\n </view>\n</view>\n","page/API/options-select/options-select.js":"Page({\n openOne() {\n my.optionsSelect({\n title: \"还款日选择\",\n optionsOne: [\"每周一\", \"每周二\", \"每周三\", \"每周四\", \"每周五\", \"每周六\", \"每周日\"],\n selectedOneIndex: 2,\n success(res) {\n my.alert({\n content: JSON.stringify(res, null, 2),\n });\n }\n });\n },\n openTwo() {\n my.optionsSelect({\n title: \"出生年月选择\",\n optionsOne: [\"2014年\", \"2013年\", \"2012年\", \"2011年\", \"2010年\", \"2009年\", \"2008年\"],\n optionsTwo: [\"一月\", '二月', '三月', '四月', '五月', '六月', '七月', '八月', '九月', '十月', '十一月', '十二月'],\n selectedOneIndex: 3,\n selectedTwoIndex: 5,\n success(res) {\n my.alert({\n content: JSON.stringify(res, null, 2),\n });\n }\n });\n },\n});\n","page/API/options-select/options-select.json":"{\n \"defaultTitle\": \"选项选择器\"\n}","page/API/page-scroll-to/page-scroll-to.axml":"<view class=\"page\">\n <view class=\"page-description\">页面滚动 API</view>\n\n <view class=\"page-section\">\n <view class=\"page-section-title\">\n my.pageScrollTo\n </view>\n <view class=\"page-section-demo\">\n <input type=\"text\" placeholder=\"key\" name=\"key\" value=\"{{scrollTop}}\" onInput=\"scrollTopChange\"></input>\n </view>\n <view class=\"page-section-btns\">\n <view onTap=\"scrollTo\">页面滚动</view>\n </view>\n </view>\n\n <view style=\"height:1000px\"/>\n</view>\n","page/API/page-scroll-to/page-scroll-to.js":"Page({\n data: {\n scrollTop: 0,\n },\n scrollTopChange(e) {\n this.setData({\n scrollTop: e.detail.value,\n });\n },\n onPageScroll({ scrollTop }) {\n console.log('onPageScroll', scrollTop);\n },\n scrollTo() {\n my.pageScrollTo({\n scrollTop: parseInt(this.data.scrollTop),\n });\n },\n});\n","page/API/pay-sign-center/pay-sign-center.axml":"<view class=\"page\">\n <view class=\"page-description\">淘宝代扣 API</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.paySignCenter</view>\n <view class=\"page-section-demo\">\n <button type=\"primary\" onTap=\"paySignCenter\">淘宝代扣</button>\n </view>\n </view>\n</view>\n","page/API/pay-sign-center/pay-sign-center.js":"Page({\n paySignCenter() {\n my.paySignCenter({\n signStr: 'biz_content%3d%257B%2522access_params%2522%253A%257B%2522channel%2522%253A%2522ALIPAYAPP%2522%257D%252C%2522external_agreement_no%2522%253A%2522yufa11111%2522%252C%2522personal_product_code%2522%253A%2522GENERAL_WITHHOLDING_P%2522%252C%2522product_code%2522%253A%2522GENERAL_WITHHOLDING%2522%252C%2522sign_scene%2522%253A%2522INDUSTRY%257CCARRENTAL%2522%252C%2522third_party_type%2522%253A%2522PARTNER%2522%257D%26sign%3dJ9ysCCt7MaYcL1d%252Bt89jTxYyT4FNVt5gdRzNJ5P4WUfV2xM%252FZ2vg14sAC%252FXLyaA4PIw%252B2yCA5zA1UQtqwOuO7Q7Dlzeyg0yZTVrjw55CalNBnhFKcyEHXDXHmO%252F2kWO9mWlI8VFdgtYmK6FX%252FOB%252F2vmoM9DYqWsRkqiT6%252Bnd90o%253D%26timestamp%3d2017-09-22%2b14%253A45%253A04%26sign_type%3dRSA%26charset%3dUTF-8%26app_id%3d2017060807451366%26method%3dalipay.user.agreement.page.sign%26version%3d1.0',\n success: (res) => {\n my.alert({\n title: 'success', // alert 框的标题\n content: JSON.stringify(res)\n });\n },\n fail: (res) => {\n my.alert({\n title: 'fail', // alert 框的标题\n content: JSON.stringify(res)\n });\n }\n });\n },\n});\n","page/API/pay-sign-center/pay-sign-center.json":"{\n \"defaultTitle\": \"淘宝代扣\"\n}","page/API/pull-down-refresh/pull-down-refresh.acss":"","page/API/pull-down-refresh/pull-down-refresh.axml":"<view class=\"page\">\n <view class=\"page-section\">\n <view class=\"page-section-title\">下滑页面即可刷新</view>\n <view class=\"page-section-btns\">\n <view type=\"primary\" onTap=\"stopPullDownRefresh\">停止刷新</view>\n </view>\n </view>\n</view>\n","page/API/pull-down-refresh/pull-down-refresh.js":"Page({\n onPullDownRefresh() {\n console.log('onPullDownRefresh', new Date());\n },\n stopPullDownRefresh() {\n my.stopPullDownRefresh({\n complete(res) {\n console.log(res, new Date())\n }\n })\n }\n});\n","page/API/pull-down-refresh/pull-down-refresh.json":"{\n \"defaultTitle\": \"下拉刷新\",\n \"pullRefresh\": true\n}\n","page/API/report-analytics/report-analytics.acss":".report {\n width: 100%;\n background: #ff5500;\n color: #fff;\n border: 1px solid #ff5500;\n height: 47px;\n line-height: 47px;\n border-radius: 5px;\n text-align: center;\n font-size: 18px;\n}\n","page/API/report-analytics/report-analytics.axml":"<view class=\"page\">\n <view class=\"page-description\">自定义分析 API</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.reportAnalytics</view>\n <view class=\"page-section-demo\">\n <view class=\"report\" onTap=\"reportAnalytics\">\b自定义分析</view>\n </view>\n </view>\n</view>","page/API/report-analytics/report-analytics.js":"Page({\n reportAnalytics() {\n my.reportAnalytics('demo_click', {});\n my.alert({\n content: '数据上报成功,请到商家应用管理后台-数据分析中查看',\n });\n },\n});\n","page/API/request-payment/request-payment.acss":"","page/API/request-payment/request-payment.axml":"<view class=\"page\">\n<view class=\"page-description\">本 demo 不具备支付功能,仅展示 API 的使用,具体接入支付请参考商家应用官方文档 API 的支付部分。</view>\n\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.tradePay</view>\n <view class=\"page-section-btns\">\n <view onTap=\"tradePay\">发起支付请求</view>\n </view>\n </view>\n</view>\n","page/API/request-payment/request-payment.js":"Page({\n data: {},\n tradePay() {\n my.tradePay({\n orderStr: 'xxx', //完整的支付参数拼接成的字符串,从服务端获取,具体是方法请参考商家应用开发文档\n success: (res) => {\n my.alert({\n title: res.resultCode,\n });\n },\n fail: (res) => {\n my.alert({\n content: JSON.stringify(res),\n });\n },\n });\n }\n})\n","page/API/request-payment/request-payment.json":"{\n \"defaultTitle\": \"发起支付\"\n}\n","page/API/request/request.acss":"","page/API/request/request.axml":"<view class=\"page\">\n <!--<view class=\"page-section\">\n <view class=\"page-section-title\">my.request</view>\n <view class=\"page-section-btns\">\n <view onTap=\"request\">发起请求</view>\n <view onTap=\"requestAndAbort\">发起后取消请求</view>\n </view>\n </view>-->\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.httpRequest</view>\n <view class=\"page-section-btns\">\n <view onTap=\"httpRequest\">发起请求</view>\n </view>\n </view>\n</view>\n","page/API/request/request.js":"Page({\n httpRequest() {\n my.httpRequest({\n url: 'http://httpbin.org/post',\n method: 'POST',\n data: {\n from: '淘宝',\n production: 'AlipayJSAPI',\n },\n dataType: 'json',\n success: function(res) {\n my.alert({content: JSON.stringify(res)});\n },\n fail: function(res) {\n my.alert({content: JSON.stringify(res)});\n },\n complete: function(res) {\n // my.alert({title: 'complete'});\n }\n });\n },\n request() {\n my.request({\n url: 'https://httpbin.org/post',\n method: 'POST',\n data: {\n from: '淘宝',\n production: 'AlipayJSAPI',\n },\n dataType: 'json',\n success: function(res) {\n my.alert({content: JSON.stringify(res)});\n },\n fail: function(res) {\n my.alert({content: JSON.stringify(res)});\n },\n complete: function(res) {\n // my.alert({title: 'complete'});\n }\n });\n },\n requestAndAbort() {\n const task = my.request({\n url: 'https://httpbin.org/post',\n method: 'POST',\n data: {\n from: '淘宝',\n production: 'AlipayJSAPI',\n },\n dataType: 'json',\n success: function(res) {\n my.alert({content: JSON.stringify(res)});\n },\n fail: function(res) {\n my.alert({content: JSON.stringify(res)});\n },\n complete: function(res) {\n // my.alert({title: 'complete'});\n }\n });\n task.abort();\n },\n})\n","page/API/request/request.json":"{\n \"defaultTitle\": \"网络请求\"\n}\n","page/API/rsa/rsa.axml":"<view class=\"page\">\n <view class=\"page-section\">\n <view class=\"page-section-title\">输入:</view>\n <view class=\"page-section-demo\">\n <textarea value=\"{{inputValue}}\" maxlength=\"500\" onInput=\"onInput\" />\n </view>\n\n <view class=\"page-section-title\">输出:</view>\n <view class=\"page-section-demo\">\n <textarea value=\"{{outputValue}}\" maxlength=\"500\" />\n </view>\n\n <view class=\"page-section-btns\">\n <view size=\"mini\" onTap=\"onEncrypt\">加密</view>\n <view size=\"mini\" onTap=\"onDecrypt\">解密</view>\n </view>\n </view>\n</view>\n","page/API/rsa/rsa.js":"Page({\n data: {\n inputValue: '',\n outputValue: '',\n },\n onInput: function (e) {\n this.setData({ inputValue: e.detail.value });\n },\n onEncrypt: function () {\n my.rsa({\n action: 'encrypt',\n text: this.data.inputValue,\n key: 'MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDKmi0dUSVQ04hL6GZGPMFK8+d6\\n' +\n 'GzulagP27qSUBYxIJfE04KT+OHVeFFb6K+8nWDea5mkmZrIgp022zZVDgdWPNM62\\n' +\n '3ouBwHlsfm2ekey8PpQxfXaj8lhM9t8rJlC4FEc0s8Qp7Q5/uYrowQbT9m6t7BFK\\n' +\n '3egOO2xOKzLpYSqfbQIDAQAB',\n success: (result) => {\n this.setData({ outputValue: result.text });\n },\n fail(e) {\n my.alert({\n content: e.errorMessage || e.error,\n });\n },\n });\n },\n onDecrypt: function () {\n my.rsa({\n action: 'decrypt',\n text: this.data.inputValue,\n key: 'MIICdwIBADANBgkqhkiG9w0BAQEFAASCAmEwggJdAgEAAoGBAMqaLR1RJVDTiEvo\\n' +\n 'ZkY8wUrz53obO6VqA/bupJQFjEgl8TTgpP44dV4UVvor7ydYN5rmaSZmsiCnTbbN\\n' +\n 'lUOB1Y80zrbei4HAeWx+bZ6R7Lw+lDF9dqPyWEz23ysmULgURzSzxCntDn+5iujB\\n' +\n 'BtP2bq3sEUrd6A47bE4rMulhKp9tAgMBAAECgYBjsfRLPdfn6v9hou1Y2KKg+F5K\\n' +\n 'ZsY2AnIK+6l+sTAzfIAx7e0ir7OJZObb2eyn5rAOCB1r6RL0IH+MWaN+gZANNG9g\\n' +\n 'pXvRgcZzFY0oqdMZDuSJjpMTj7OEUlPyoGncBfvjAg0zdt9QGAG1at9Jr3i0Xr4X\\n' +\n '6WrFhtfVlmQUY1VsoQJBAPK2Qj/ClkZNtrSDfoD0j083LcNICqFIIGkNQ+XeuTwl\\n' +\n '+Gq4USTyaTOEe68MHluiciQ+QKvRAUd4E1zeZRZ02ikCQQDVscINBPTtTJt1JfAo\\n' +\n 'wRfTzA0Lvgig136xLLeQXREcgq1lzgkf+tGyUGYoy9BXsV0mOuYAT9ldja4jhJeq\\n' +\n 'cEulAkEAuSJ5KjV9dyb0RIFAz5C8d8o5KAodwaRIxJkPv5nCZbT45j6t9qbJxDg8\\n' +\n 'N+vghDlHI4owvl5wwVlAO8iQBy8e8QJBAJe9CVXFV0XJR/n/XnER66FxGzJjVi0f\\n' +\n '185nOlFARI5CHG5VxxT2PUCo5mHBl8ctIj+rQvalvGs515VQ6YEVDCECQE3S0AU2\\n' +\n 'BKyFVNtTpPiTyRUWqig4EbSXwjXdr8iBBJDLsMpdWsq7DCwv/ToBoLg+cQ4Crc5/\\n5DChU8P30EjOiEo=',\n success: (result) => {\n this.setData({ outputValue: result.text });\n },\n fail(e) {\n my.alert({\n content: e.errorMessage || e.error,\n });\n },\n });\n },\n});\n","page/API/scan-code/scan-code.acss":"","page/API/scan-code/scan-code.axml":"<view class=\"page\">\n <view class=\"page-section\">\n <form onSubmit=\"scanCode\">\n <view>\n <button type=\"primary\" onTap=\"scan\">扫码</button>\n </view>\n </form>\n </view>\n</view>\n","page/API/scan-code/scan-code.js":"Page({\n scan() {\n my.scan({\n type: 'qr',\n success: (res) => {\n my.alert({ title: res.code });\n },\n });\n }\n})\n\n","page/API/scan-code/scan-code.json":"{\n \"defaultTitle\": \"Scan\"\n}\n","page/API/screen/screen.axml":"<view class=\"page\">\n <view class=\"page-description\">屏幕亮度 API</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">设置是否保持屏幕长亮状态</view>\n <view class=\"page-section-demo\">\n <switch checked=\"{{status}}\" onChange=\"switchKeepScreenOn\"/>\n </view>\n </view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">设置屏幕亮度</view>\n <view class=\"page-section-demo\">\n <slider value=\"{{brightness}}\" max=\"1\" min=\"0\" onChange=\"sliderChange\" step=\"0.02\"/>\n </view>\n </view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">获取屏幕亮度</view>\n <view class=\"page-section-demo\">\n <button type=\"primary\" onTap=\"getBrightness\">获取屏幕亮度</button>\n </view>\n </view>\n</view>\n\n\n","page/API/screen/screen.js":"Page({\n data: {\n status: false,\n brightness: 1,\n },\n onLoad() {\n my.getScreenBrightness({\n success: res => {\n this.setData({\n brightness: res.brightness\n })\n },\n })\n },\n sliderChange(e) {\n my.setScreenBrightness({\n brightness: e.detail.value,\n success: (res) => {\n this.setData({\n brightness: e.detail.value,\n })\n }\n })\n },\n switchKeepScreenOn(e) {\n my.setKeepScreenOn({\n keepScreenOn: e.detail.value,\n success: (res) => {\n this.setData({\n status: e.detail.value,\n })\n }\n })\n },\n getBrightness() {\n my.getScreenBrightness({\n success: res => {\n my.alert({\n content: `当前屏幕亮度:${res.brightness}`\n });\n }\n })\n }\n});","page/API/sdk-version/sdk-version.axml":"<view class=\"page\">\n <view class=\"page-description\">获取基础库版本号 API</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.SDKVersion</view>\n <view class=\"page-section-demo\">\n <button type=\"primary\" onTap=\"getSDKVersion\">获取基础库版本号</button>\n </view>\n </view>\n</view>","page/API/sdk-version/sdk-version.js":"Page({\n getSDKVersion() {\n my.alert({\n content: my.SDKVersion,\n });\n }, \n});\n","page/API/set-navigation-bar/set-navigation-bar.acss":".page-section-btns {\n padding: 26rpx;\n}\n","page/API/set-navigation-bar/set-navigation-bar.axml":"<view class=\"page\">\n <view class=\"page-description\">设置导航栏 API</view>\n <form onSubmit=\"setNavigationBar\" style=\"align-self:stretch\">\n <view class=\"page-section\">\n <view class=\"page-section-demo\">\n <input class=\"page-body-form-value\" type=\"text\" placeholder=\"标题\" name=\"title\"></input>\n <input class=\"page-body-form-value\" type=\"text\" placeholder=\"导航栏背景色\" name=\"backgroundColor\"></input>\n <input class=\"page-body-form-value\" type=\"text\" placeholder=\"导航栏底部边框颜色\" name=\"borderBottomColor\"></input>\n <input class=\"page-body-form-value\" type=\"text\" placeholder=\"导航栏图片地址\" name=\"image\"></input>\n </view>\n <view class=\"page-section-btns\">\n <button type=\"primary\" size=\"mini\" formType=\"submit\">设置</button>\n <button type=\"primary\" size=\"mini\" onTap=\"resetNavigationBar\">重置</button>\n </view>\n </view>\n </form>\n <view class=\"tips\">\n tips:\n <view class=\"item\">1. image:图片链接地址,必须 https,请使用一张3x高清图。若设置了 image,则 title 参数失效</view>\n <view class=\"item\">2. backgroundColor: 导航栏背景色,支持 16 进制颜色值</view>\n <view class=\"item\">3. borderBottomColor: 导航栏底部边框颜色,支持16进制颜色值。若设置了 backgroundColor,borderBottomColor 会不生效,默认会和 backgroundColor 颜色一样。</view>\n </view>\n</view>\n","page/API/set-navigation-bar/set-navigation-bar.js":"Page({\n setNavigationBar(e) {\n var title = e.detail.value.title;\n var backgroundColor = e.detail.value.backgroundColor;\n var borderBottomColor = e.detail.value.borderBottomColor;\n var image = e.detail.value.image;\n console.log(title)\n my.setNavigationBar({\n title,\n backgroundColor,\n borderBottomColor,\n image,\n })\n },\n resetNavigationBar() {\n my.setNavigationBar({\n reset: true,\n title: '重置导航栏样式',\n });\n }\n})\n","page/API/set-navigation-bar/set-navigation-bar.json":"{\n \"defaultTitle\": \"设置页面导航栏\"\n}\n","page/API/share/share.axml":"<view class=\"page\">\n <view class=\"page-description\">点击右上角开始自定义分享</view>\n</view>\n","page/API/share/share.js":"Page({\n onShareAppMessage() {\n return {\n title: '分享 View 组件',\n desc: 'View 组件很通用',\n path: 'page/component/view/view',\n };\n },\n});\n","page/API/share/share.json":"{\n \"defaultTitle\": \"onShareAppMessage\"\n}\n","page/API/show-auth-guide/show-auth-guide.axml":"<view class=\"page\">\n <view class=\"page-description\">权限引导 API</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.showAuthGuide</view>\n <view class=\"page-section-demo\">\n <button type=\"primary\" onTap=\"showAuthGuide\">权限引导</button>\n </view>\n </view>\n</view>\n","page/API/show-auth-guide/show-auth-guide.js":"Page({\n showAuthGuide() {\n my.showAuthGuide({ \n bizType:'AppletPG',\n authType:'LBS',\n success:(res)=>{\n //shown为true时表示会显示权限引导弹窗,为false时表示用户已经授权\n my.alert({content: '调用成功:'+JSON.stringify(res), });\n },\n fail:(error)=>{\n my.alert({content: '调用失败:'+JSON.stringify(error), });\n },\n });\n },\n});\n","page/API/show-auth-guide/show-auth-guide.json":"{\n \"defaultTitle\": \"权限引导\"\n}\n","page/API/start-zm-verify/start-zm-verify.acss":"","page/API/start-zm-verify/start-zm-verify.axml":"<view class=\"page\">\n <view class=\"page-description\">芝麻认证 API</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.startZMVerify</view>\n <view class=\"page-section-demo\">\n <button type=\"primary\" onTap=\"startZMVerify\">唤起认证页面</button>\n </view>\n </view>\n</view>\n","page/API/start-zm-verify/start-zm-verify.js":"Page({\n startZMVerify() {\n if (!my.canIUse('startZMVerify')) {\n my.alert({\n title: '\b\b客户端版本过低',\n content: '请升级淘宝版本'\n });\n return;\n }\n\n my.startZMVerify({\n bizNo: 'demo',\n success: (res) => {\n my.alert({ title: 'success:' + JSON.stringify(res)});\n },\n fail: (res) => {\n my.alert({ title: 'fail: ' + JSON.stringify(res)});\n },\n });\n }\n})\n\n","page/API/start-zm-verify/start-zm-verify.json":"{\n \"defaultTitle\": \"芝麻认证\"\n}\n","page/API/storage/storage.axml":"<view class=\"page\">\n <view class=\"page-description\">数据存储 API</view>\n <view class=\"page-section\">\n <view class=\"page-section-demo\">\n <input type=\"text\" placeholder=\"key\" name=\"key\" value=\"{{key}}\" onInput=\"keyChange\"></input>\n <input type=\"text\" placeholder=\"data\" name=\"data\" value=\"{{data}}\" onInput=\"dataChange\"></input>\n </view>\n <view class=\"page-section-btns\">\n <view onTap=\"setStorage\">存储数据</view>\n <view onTap=\"getStorage\">读取数据</view>\n <view onTap=\"removeStorage\">删除数据</view>\n <view onTap=\"clearStorage\">清除数据</view>\n <view onTap=\"getStorageInfo\">获取数据信息</view>\n </view>\n </view>\n <view class=\"page-section\">\n <view class=\"page-section-demo\">\n <input type=\"text\" placeholder=\"key\" name=\"keySync\" value=\"{{keySync}}\" onInput=\"keyChangeSync\"></input>\n <input type=\"text\" placeholder=\"data\" name=\"dataSync\" value=\"{{dataSync}}\" onInput=\"dataChangeSync\"></input>\n </view>\n <view class=\"page-section-btns\">\n <view onTap=\"setStorageSync\">同步存储数据</view>\n <view onTap=\"getStorageSync\">同步读取数据</view>\n <view onTap=\"removeStorageSync\">同步删除数据</view>\n <view onTap=\"clearStorageSync\">同步清除数据</view>\n <view onTap=\"getStorageInfoSync\">同步获取数据信息</view>\n </view>\n </view>\n</view>\n","page/API/storage/storage.js":"Page({\n data: {\n key: '',\n data: '',\n keySync: '',\n dataSync: '',\n },\n\n keyChange(e) {\n console.log(e);\n this.setData({\n key: e.detail.value,\n });\n },\n\n dataChange(e) {\n this.setData({\n data: e.detail.value,\n });\n },\n\n keyChangeSync(e) {\n console.log(e);\n this.setData({\n keySync: e.detail.value,\n });\n },\n\n dataChangeSync(e) {\n this.setData({\n dataSync: e.detail.value,\n });\n },\n\n getStorage() {\n var key = this.data.key;\n var data = this.data.data;\n console.log('data: ', this.data);\n if (key.length === 0) {\n this.setData({\n key: key,\n data: data,\n });\n\n my.alert({\n title: '读取数据失败',\n content: 'key 不能为空',\n });\n } else {\n let that = this;\n my.getStorage({\n key,\n success(res) {\n my.alert({\n title: '读取数据成功',\n content: \"data: '\" + JSON.stringify(res.data) + \"'\",\n });\n },\n });\n console.log('读取数据成功', my.getStorageSync({ key }).data);\n }\n },\n\n setStorage() {\n var key = this.data.key;\n var data = this.data.data;\n if (key.length === 0) {\n this.setData({\n key: key,\n data: data,\n });\n\n my.alert({\n title: '保存数据失败',\n content: 'key 不能为空',\n });\n } else {\n let that = this;\n my.setStorage({\n key: key,\n data: data,\n success() {\n that.setData({\n key: key,\n data: data,\n });\n\n my.alert({\n title: '存储数据成功',\n content: `${key}: ${data}`,\n });\n },\n });\n }\n },\n\n removeStorage() {\n let that = this;\n my.removeStorage({\n key: that.data.key,\n success() {\n that.setData({\n key: '',\n data: '',\n });\n\n my.alert({\n title: '删除数据成功',\n content: '',\n });\n },\n });\n },\n clearStorage() {\n let that = this;\n my.clearStorage({\n key: that.data.key,\n success() {\n that.setData({\n key: '',\n data: '',\n });\n\n my.alert({\n title: '清除数据成功',\n content: '',\n });\n },\n });\n },\n getStorageInfo() {\n let that = this;\n my.getStorageInfo({\n success(res) {\n my.alert({\n content: JSON.stringify({\n keys: res.keys,\n currentSize: res.currentSize,\n limitSize: res.limitSize,\n }),\n });\n },\n });\n },\n\n getStorageSync() {\n var key = this.data.keySync;\n var data = this.data.dataSync;\n console.log('data: ', this.data);\n if (key.length === 0) {\n this.setData({\n keySync: key,\n dataSync: data,\n });\n\n my.alert({\n title: '同步读取数据失败',\n content: 'key 不能为空',\n });\n } else {\n let res = my.getStorageSync({ key: key });\n if (!res.error) {\n my.alert({\n title: '同步读取数据成功',\n content: \"data: '\" + JSON.stringify(res.data) + \"'\",\n });\n }\n }\n },\n\n setStorageSync() {\n var key = this.data.keySync;\n var data = this.data.dataSync;\n if (key.length === 0) {\n this.setData({\n keySync: key,\n dataSync: data,\n });\n\n my.alert({\n title: '同步保存数据失败',\n content: 'key 不能为空',\n });\n } else {\n let res = my.setStorageSync({ key: key, data: data });\n if (!res.error) {\n this.setData({\n keySync: key,\n dataSync: data,\n });\n\n my.alert({\n title: '同步存储数据成功',\n content: `${key}: ${data}`,\n });\n }\n }\n },\n\n removeStorageSync() {\n let res = my.removeStorageSync({ key: this.data.keySync });\n if (!res.error) {\n this.setData({\n keySync: '',\n dataSync: '',\n });\n\n my.alert({\n title: '同步删除数据成功',\n content: '',\n });\n }\n },\n clearStorageSync() {\n let res = my.clearStorageSync();\n if (!res.error) {\n this.setData({\n keySync: '',\n dataSync: '',\n });\n\n my.alert({\n title: '同步清除数据成功',\n content: '',\n });\n }\n },\n getStorageInfoSync() {\n let res = my.getStorageInfoSync();\n if (!res.error) {\n my.alert({\n content: JSON.stringify({\n keys: res.keys,\n currentSize: res.currentSize,\n limitSize: res.limitSize,\n }),\n });\n }\n },\n});\n","page/API/storage/storage.json":"{\n \"defaultTitle\": \"Storage\"\n}\n","page/API/text-risk-identification/text-risk-identification.axml":"<view class=\"page\">\n <view class=\"page-description\">\b文本风险识别 API</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.textRiskIdentification</view>\n <view class=\"page-section-demo\">\n <textarea placeholder=\"输入文本内容\" onInput=\"handleInput\" name=\"textarea\"/>\n <button type=\"primary\" onTap=\"textRiskIdentification\">开始识别</button>\n </view>\n </view>\n</view>\n\n\n","page/API/text-risk-identification/text-risk-identification.js":"Page({\n data: {\n value: '',\n },\n handleInput(event) {\n this.setData({\n value: event.detail.value,\n });\n },\n textRiskIdentification() {\n my.textRiskIdentification({\n content: this.data.value,\n type: ['keyword', '0', '1', '2', '3'],\n success: (res) => {\n my.alert({\n title: this.data.value,\n content: JSON.stringify(res),\n });\n },\n });\n },\n});\n","page/API/toast/toast.acss":"","page/API/toast/toast.axml":"<view class=\"page\">\n <view class=\"page-description\">Toast API</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.showToast</view>\n <view class=\"page-section-btns\">\n <view type=\"primary\" onTap=\"showToastSuccess\">显示提示</view>\n <!--<view type=\"primary\" onTap=\"showToastFail\">显示 fail 提示</view>-->\n </view>\n <!--<view class=\"page-section-btns\">\n <view type=\"primary\" onTap=\"showToastException\">显示 exception 提示</view>\n <view type=\"primary\" onTap=\"showToastNone\">显示 none 弱提示</view>\n </view>-->\n </view>\n\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.hideToast</view>\n <view class=\"page-section-btns\">\n <view onTap=\"hideToast\">隐藏弱提示</view>\n </view>\n </view>\n</view>\n","page/API/toast/toast.js":"Page({\n showToastSuccess() {\n my.showToast({\n content: '操作成功',\n duration: 3000,\n success: () => {\n my.alert({\n title: 'toast 消失了',\n });\n },\n });\n },\n // showToastFail() {\n // my.showToast({\n // type: 'fail',\n // content: '操作失败',\n // duration: 3000,\n // success: () => {\n // my.alert({\n // title: 'toast 消失了',\n // });\n // },\n // });\n // },\n // showToastException() {\n // my.showToast({\n // type: 'exception',\n // content: '网络异常',\n // duration: 3000,\n // success: () => {\n // my.alert({\n // title: 'toast 消失了',\n // });\n // },\n // });\n // },\n // showToastNone() {\n // my.showToast({\n // type: 'none',\n // content: '提醒',\n // duration: 3000,\n // success: () => {\n // my.alert({\n // title: 'toast 消失了',\n // });\n // },\n // });\n // },\n hideToast() {\n my.hideToast();\n },\n});\n","page/API/toast/toast.json":"{\n \"defaultTitle\": \"Toast\"\n}\n","page/API/upload-file/upload-file.acss":"","page/API/upload-file/upload-file.axml":"<view class=\"page\">\n <button type=\"primary\" onTap=\"uploadFile\">上传图片</button>\n</view>\n","page/API/upload-file/upload-file.js":"Page({\n uploadFile() {\n my.chooseImage({\n chooseImage: 1,\n success: res => {\n const path = res.apFilePaths[0];\n console.log(path);\n my.uploadFile({\n url: 'http://httpbin.org/post',\n fileType: 'image',\n fileName: 'file',\n filePath: path,\n success: res => {\n my.alert({ title: '上传成功' });\n },\n fail: function(res) {\n my.alert({ title: '上传失败' });\n },\n });\n },\n });\n },\n});\n","page/API/upload-file/upload-file.json":"{\n \"defaultTitle\": \"Upload File\"\n}\n","page/API/user-capture-screen/user-capture-screen.axml":"<view class=\"page\">\n <view class=\"page-description\">用户截屏事件 API</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.onUserCaptureScreen</view>\n <view class=\"page-section-demo\">\n <view>目前状态:{{ condition ? \"已经开启监听\" : '已经取消监听' }}</view>\n <view a:if=\"{{condition}}\">\n <button type=\"primary\" onTap=\"offUserCaptureScreen\">取消监听屏幕事件</button>\n </view>\n <view a:else>\n <button type=\"primary\" onTap=\"onUserCaptureScreen\">开启\b监听屏幕事件</button>\n </view>\n </view>\n </view>\n</view>","page/API/user-capture-screen/user-capture-screen.js":"Page({\n data: {\n condition: false,\n },\n onReady() {\n my.onUserCaptureScreen(() => {\n my.alert({\n content: '收到用户截图',\n });\n });\n },\n offUserCaptureScreen() {\n my.offUserCaptureScreen();\n this.setData({\n condition: false,\n });\n },\n onUserCaptureScreen() {\n my.onUserCaptureScreen(() => {\n my.alert({\n content: '收到用户截图'\n });\n });\n this.setData({\n condition: true,\n });\n },\n});\n","page/API/vibrate/vibrate.acss":"","page/API/vibrate/vibrate.axml":"<view class=\"page\">\n\n <button type=\"primary\" onTap=\"vibrate\">\n 开始振动\n </button>\n\n <button type=\"primary\" onTap=\"vibrateLong\">\n 长时间振动 (400ms)\n </button>\n\n <button type=\"primary\" onTap=\"vibrateShort\">\n 短时间振动 (40ms)\n </button>\n\n</view>\n","page/API/vibrate/vibrate.js":"Page({\n vibrate() {\n my.vibrate({\n success: () => {\n my.alert({ title: '振动起来了'});\n }\n });\n },\n vibrateLong() {\n if (my.canIUse('vibrateLong')) {\n my.vibrateLong((res) => { });\n } else {\n my.alert({\n title: '\b\b客户端版本过低',\n content: 'my.vibrateLong() 需要\b 10.1.35 \b及以上版本'\n });\n }\n },\n vibrateShort() {\n if (my.canIUse('vibrateShort')) {\n my.vibrateShort((res) => { });\n } else {\n my.alert({\n title: '\b\b客户端版本过低',\n content: 'my.vibrateShort() 需要\b 10.1.35 \b及以上版本'\n });\n }\n }\n});\n","page/API/vibrate/vibrate.json":"{\n \"defaultTitle\": \"Vibrate\"\n}\n","page/API/watch-shake/watch-shake.acss":"","page/API/watch-shake/watch-shake.axml":"<view class=\"page\">\n <button type=\"primary\" onTap=\"watchShake\">\n 绑定摇一摇,点击 Shake 按钮看效果\n </button>\n</view>\n","page/API/watch-shake/watch-shake.js":"Page({\n watchShake() {\n my.watchShake({\n success: function() {\n console.log('动起来了')\n my.alert({ title:'动起来了 o.o'});\n }\n });\n },\n});\n","page/API/watch-shake/watch-shake.json":"{\n \"defaultTitle\": \"Shake\"\n}\n","page/API/websocket/websocket.acss":".buttons {\n padding:12rpx;\n line-height:1.2;\n height: 60rpx;\n width:200rpx;\n font-size: 30rpx;\n text-align:center;\n margin-top: 40rpx;\n}\n\n.server_addr {\n width: 600rpx;\n text-align:center;\n color: #6a6f77;\n margin-top: 20rpx;\n}\n\n.subView {\n align-items: center;\n}\n\n.message_text {\n margin-top: 40rpx;\n width: 500rpx;\n height: 40rpx;\n}\n\n.run_log {\n margin-top: 30rpx;\n}\n","page/API/websocket/websocket.axml":"<view class=\"container\">\n <view class=\"subView\">\n <input class=\"server_addr\" placeholder=\"wss://YourServer/\" onConfirm=\"onServerAddressComplete\" onBlur=\"onServerAddressComplete\"/>\n </view>\n <view class=\"subView\">\n <button class=\"buttons\" name=\"startButton\" onTap=\"connect_start\">开始连接</button>\n </view>\n <view class=\"subView\" a:if=\"{{sendMessageAbility}}\">\n <input class=\"message_text\" placeholder=\"输入要发送的消息:\" onConfirm=\"onSendMessageReady\" onBlur=\"onSendMessageReady\"/>\n </view>\n <view class=\"subView\" a:if=\"{{sendMessageAbility}}\">\n <button class=\"buttons\" name=\"sendButton\" onTap=\"send_start\">发送数据</button>\n </view>\n <view class=\"subView\" a:if=\"{{closeLinkAbility}}\">\n <button class=\"buttons\" name=\"closeButton\" onTap=\"close_start\">关闭</button>\n </view>\n <view>\n <text class=\"run_log\">{{log}}</text>\n <view/>\n</view>\n","page/API/websocket/websocket.js":"// 获取应用实例\nconst app = getApp();\n\nPage({\n data: {\n appid: 'aaaaaaaa',\n websocketServer: '开发者服务器接口地址,必须是 wss 协议,且域名必须是后台配置的合法域名',\n sendMessageAbility: false,\n toSendMessage: 'test',\n closeLinkAbility: false,\n log: '',\n },\n\n onLoad() {\n // 注意: 回调方法的注册在整个商家应用启动阶段只要做一次,调多次会有多次回调\n my.onSocketClose((res) => {\n my.alert({content: '连接已关闭!'});\n this.setData({\n sendMessageAbility: false,\n closeLinkAbility: false,\n });\n });\n // 注意: 回调方法的注册在整个商家应用启动阶段只要做一次,调多次会有多次回调\n my.onSocketOpen((res) => {\n my.alert({content: '连接已打开!'});\n this.setData({\n sendMessageAbility: true,\n closeLinkAbility: true,\n });\n });\n\n my.onSocketError(function(res){\n my.alert('WebSocket 连接打开失败,请检查!' + res);\n });\n\n // 注意: 回调方法的注册在整个商家应用启动阶段只要做一次,调多次会有多次回调\n my.onSocketMessage((res) => {\n my.alert({content: '收到数据!' + JSON.stringify(res)});\n });\n },\n\n onServerAddressComplete(e) {\n this.setData({\n websocketServer:e.detail.value,\n });\n },\n\n onSendMessageReady(e) {\n this.setData({\n toSendMessage:e.detail.value,\n });\n },\n\n connect_start() {\n my.connectSocket({\n url: this.data.websocketServer, // 开发者服务器接口地址,必须是 wss 协议,且域名必须是后台配置的合法域名\n success: (res) => {\n my.showToast({\n content: 'success', // 文字内容\n });\n },\n fail:()=>{\n my.showToast({\n content: 'fail', // 文字内容\n });\n }\n });\n },\n\n send_start() {\n my.sendSocketMessage({\n data: this.data.toSendMessage, // 需要发送的内容\n success: (res) => {\n my.alert({content: '数据发送!' + this.data.toSendMessage});\n },\n });\n },\n\n close_start() {\n my.closeSocket();\n },\n});\n","page/API/websocket/websocket.json":"{}","page/API/zm-credit-borrow/zm-credit-borrow.axml":"<view class=\"page\">\n <view class=\"page-description\">芝麻信用借还 API</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">my.zmCreditBorrow</view>\n <view class=\"page-section-demo\">\n <button type=\"primary\" onTap=\"zmCreditBorrow\">芝麻信用借还</button>\n </view>\n </view>\n</view>\n","page/API/zm-credit-borrow/zm-credit-borrow.js":"Page({\n zmCreditBorrow() {\n const vNow = new Date();\n let sNow = '';\n sNow += String(vNow.getFullYear());\n sNow += String(vNow.getMonth() + 1);\n sNow += String(vNow.getDate());\n sNow += String(vNow.getHours());\n sNow += String(vNow.getMinutes());\n sNow += String(vNow.getSeconds());\n sNow += String(vNow.getMilliseconds());\n my.zmCreditBorrow({\n out_order_no: sNow,\n product_code: 'w1010100000000002858',\n credit_biz: 'ZMRT171102175151',\n invoke_type: 'TINYAPP',\n goods_name: encodeURIComponent('串珠玩具租借'),\n rent_unit: 'DAY_YUAN',\n rent_amount: '0.01',\n deposit_amount: '1.00',\n deposit_state: 'Y',\n invoke_state: '{\"user_name\":\"' + encodeURIComponent('天使之翼II') + '\"}',\n success: (res) => {\n my.alert({\n content: JSON.stringify(res),\n });\n },\n });\n },\n});\n","page/API/zm-credit-borrow/zm-credit-borrow.json":"{\n \"defaultTitle\": \"芝麻信用借还\"\n}","page/common/components/block-list/block-list.acss":".block-list-container {\n width: 100%;\n display: flex;\n justify-content: center;\n background-color: #fff;\n}\n\n.block-list {\n display: flex;\n justify-content: start;\n flex-wrap: wrap;\n width: 100%;\n padding-bottom: 20rpx;\n}\n\n.block-item {\n height: 50rpx;\n margin-right: 20rpx;\n margin-bottom: 20rpx;\n display: flex;\n justify-content: center;\n align-items: center;\n color: #333;\n font-size: 24rpx;\n background-color: rgba(245, 245, 245, 0.71);\n padding: 0 18rpx;\n}","page/common/components/block-list/block-list.axml":"<view class=\"block-list-container {{className}}\">\n <view class=\"block-list\">\n <block a:for=\"{{listData}}\">\n <navigator a:if=\"{{item.url}}\" url=\"{{item.url}}\">\n <view class=\"block-item\" onTap=\"onItemTap\" data-name=\"{{item.name}}\">{{item.name}}</view>\n </navigator>\n <view a:else class=\"block-item\" onTap=\"onItemTap\" data-name=\"{{item.name}}\">{{item.name}}</view>\n </block>\n </view>\n</view>","page/common/components/block-list/block-list.js":"Component({\n methods: {\n onItemTap(e) {\n const { onItemTap } = this.props;\n const { name } = e.target.dataset;\n if (onItemTap) {\n onItemTap({ name });\n }\n }\n }\n});","page/common/components/block-list/block-list.json":"{\n \"component\": true\n}","page/common/search/search.acss":"page {\n background-color: #fff;\n}\n\n.page {\n padding: 0;\n}\n\n.search-bar {\n position: sticky;\n top: 0;\n background-color: #fff;\n z-index: 2;\n padding-top: 14rpx;\n overflow: hidden;\n}\n\n.am-search-input {\n height: 35px;\n line-height: 35px;\n}\n\n.am-search-synthetic {\n height: 35px;\n line-height: 35px;\n}\n\n.am-search-value {\n height: 35px;\n}\n\n.am-search-clear {\n height: 35px;\n width: 35px;\n}\n\n.am-search-cancel {\n color: #333;\n}\n\n.search-bar .am-search-input {\n background-color: rgba(0, 0, 0, 0.05);\n}\n\n.search-container {\n box-sizing: border-box;\n padding: 20px 12px;\n}\n\n.history {\n position: relative;\n padding-left: 2px;\n padding-bottom: 1px;\n color: #333;\n font-size: 36rpx;\n font-weight: bold;\n}\n\n.history .clear {\n position: absolute;\n right: 10px;\n top: 50%;\n transform: translateY(-50%);\n height: 40rpx;\n width: 40rpx;\n background-image: url('/image/clear.png');\n background-size: 50%;\n background-position: center;\n background-repeat: no-repeat;\n}\n\n.history-list {\n margin-top: 10px;\n}\n\n.hot {\n padding-left: 2px;\n padding-bottom: 2px;\n color: #333;\n font-size: 36rpx;\n font-weight: bold; \n}\n\n.hot-list {\n margin-top: 10px; \n}\n\n.search-results {\n padding: 16px 12 0 0px;\n}\n\n.component-name {\n color: #333;\n margin-right: 10rpx;\n}\n\n.thumb {\n height: 60rpx;\n width: 60rpx;\n margin-right: 30rpx;\n}\n\n.component .am-list-line-bottom::after {\n left: auto;\n right: 0;\n width: calc(100% - 80rpx);\n}\n\n.am-list-body::before {\n display: none;\n}\n\n.am-list-body::after {\n display: none;\n}\n\n.list-header {\n height: 100rpx;\n display: flex;\n align-items: center;\n background-color: #fff;\n color: #333;\n font-weight: bold;\n font-size: 34rpx;\n}\n\n.am-list-header {\n padding: 8px 16px 0px;\n}\n\n.no-search-result {\n height: 300px;\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n}\n\n.no-search-result image {\n width: 87rpx;\n height: 87rpx;\n}\n\n.no-search-result text {\n margin-top: 37rpx;\n color: #999;\n font-size: 28rpx;\n}","page/common/search/search.axml":"<view class=\"page\">\n <view class=\"search-bar\">\n <search-bar\n focus=\"{{true}}\"\n value=\"{{value}}\"\n placeholder=\"搜索你想要的组件和API\"\n onInput=\"onInput\"\n onCancel=\"onCancel\"\n onClear=\"onClear\"\n onSubmit=\"onSubmit\"\n showCancelButton=\"{{false}}\" />\n </view>\n <view class=\"search-container\" a:if=\"{{componentSuggestions.length === 0 && apiSuggestions.length === 0}}\">\n <view a:if=\"{{value.length === 0}}\">\n <view a:if=\"{{ history.length > 0 }}\" style=\"border-bottom: 1rpx solid #F5F5F5; margin-bottom: 16px;\">\n <view class=\"history\">历史<view class=\"clear\" onTap=\"clear\"></view></view>\n <block-list listData=\"{{history}}\" class=\"history-list\" onItemTap=\"onItemTap\" />\n </view>\n <view>\n <view class=\"hot\">热门</view>\n <block-list listData=\"{{hot}}\" class=\"history-list\" />\n </view>\n </view>\n <view class=\"no-search-result\" a:else>\n <image src=\"/image/icon/no_search_result.png\" />\n <text>未找到搜索结果</text>\n </view>\n </view>\n <view class=\"search-results\" a:else>\n <view a:if=\"{{componentSuggestions.length > 0}}\" class=\"component\">\n <list>\n <view slot=\"header\" class=\"list-header\">组件</view>\n <block a:for=\"{{componentSuggestions}}\">\n <list-item\n arrow=\"{{true}}\"\n multipleLine=\"{{false}}\"\n key=\"items-{{item.name}}\"\n last=\"{{index === componentSuggestions.length - 1}}\">\n <view\n onTap=\"onListItemTap\"\n data-url=\"{{item.path}}\"\n data-name=\"{{item.name}}\"\n style=\"display: flex; align-items: center\">\n <image src=\"{{item.thumb}}\" class=\"thumb\" />\n <text class=\"component-name\">{{item.name}}</text>\n </view>\n </list-item>\n </block>\n </list>\n </view>\n <view a:if=\"{{apiSuggestions.length > 0}}\" class=\"api\">\n <list>\n <view slot=\"header\" class=\"list-header\">API</view>\n <block a:for=\"{{apiSuggestions}}\">\n <list-item\n arrow=\"{{true}}\"\n multipleLine=\"{{false}}\"\n key=\"items-{{item.name}}\"\n last=\"{{index === apiSuggestions.length - 1}}\">\n <view\n onTap=\"onListItemTap\"\n data-url=\"{{item.path}}\"\n data-name=\"{{item.name}}\"\n style=\"display: flex; align-items: center\">\n <image src=\"{{item.thumb}}\" class=\"thumb\" a:if=\"{{thumb}}\" />\n <text class=\"component-name\">{{item.name}}</text>\n </view>\n </list-item>\n </block>\n </view>\n </list>\n </view>\n</view>","page/common/search/search.js":"import debounce from '/util/debounce';\n\nconst componentList = [\n {\n name: '金额输入',\n thumb: '/image/icon/amount-input.png',\n path: '/page/component/amount-input/amount-input',\n suggestion: 'amountinput金额输入',\n },\n {\n name: '按钮',\n thumb: '/image/icon/button.png',\n path: '/page/component/button/button',\n suggestion: 'button按钮',\n },\n {\n name: '日历',\n thumb: '/image/icon/calendar.png',\n path: '/page/component/calendar/calendar',\n suggestion: 'calendar日历',\n },\n {\n name: '卡片',\n thumb: '/image/icon/card.png',\n path: '/page/component/card/card',\n suggestion: 'card卡片',\n },\n {\n name: '复选框',\n thumb: '/image/icon/checkbox.png',\n path: '/page/component/checkbox/checkbox',\n suggestion: 'checkbox复选框',\n },\n {\n name: '复选框',\n thumb: '/image/icon/radio.png',\n path: '/page/component/am-checkbox/am-checkbox',\n suggestion: 'checkbox复选框',\n },\n {\n name: '云客服',\n thumb: '/image/icon/contact-button.png',\n path: '/page/component/contact-button/contact-button',\n suggestion: 'contactbutton云客服',\n },\n {\n name: '画布',\n thumb: '/image/icon/canvas.png',\n path: '/page/component/canvas/canvas',\n suggestion: 'canvas画布',\n },\n {\n name: '筛选',\n thumb: '/image/icon/filter.png',\n path: '/page/component/filter/filter',\n suggestion: 'filter筛选',\n },\n {\n name: '页脚',\n thumb: '/image/icon/footer.png',\n path: '/page/component/footer/footer',\n suggestion: 'footer页脚',\n },\n {\n name: '表单',\n thumb: '/image/icon/form.png',\n path: '/page/component/form/form',\n suggestion: 'form表单',\n },\n {\n name: '宫格',\n thumb: '/image/icon/grid.png',\n path: '/page/component/grid/grid',\n suggestion: 'grid宫格',\n },\n {\n name: '图标',\n thumb: '/image/icon/icon.png',\n path: '/page/component/icon/icon',\n suggestion: 'icon图标',\n },\n {\n name: '图片',\n thumb: '/image/icon/image.png',\n path: '/page/component/image/image',\n suggestion: 'image图片媒体',\n },\n {\n name: '文本输入',\n thumb: '/image/icon/input.png',\n path: '/page/component/input-item/input-item',\n suggestion: 'inputitem文本输入',\n },\n {\n name: '标签',\n thumb: '/image/icon/label.png',\n path: '/page/component/label/label',\n suggestion: 'label标签',\n },\n {\n name: '跳转生活号',\n thumb: '/image/icon/lifestyle.png',\n path: '/page/component/lifestyle/lifestyle',\n suggestion: 'lifestyle跳转生活号',\n },\n {\n name: '列表',\n thumb: '/image/icon/form.png',\n path: '/page/component/list/list',\n suggestion: 'list列表',\n },\n // {\n // name: '地图',\n // thumb: '/image/icon/map.png',\n // path: '/page/component/map/map',\n // suggestion: 'map地图',\n // },\n {\n name: '结果页',\n thumb: '/image/icon/message.png',\n path: '/page/component/message/massage',\n suggestion: 'message结果页',\n },\n {\n name: '对话框',\n thumb: '/image/icon/modal.png',\n path: '/page/component/modal/modal',\n suggestion: 'modal对话框',\n },\n {\n name: '导航',\n thumb: '/image/icon/navigator.png',\n path: '/page/component/navigator/navigator',\n suggestion: 'navigator导航',\n },\n {\n name: '通告栏',\n thumb: '/image/icon/notice.png',\n path: '/page/component/notice/notice',\n suggestion: 'notice通告栏',\n },\n {\n name: '徽标',\n thumb: '/image/icon/view.png',\n path: '/page/component/badge/badge',\n suggestion: 'badge徽标',\n },\n // { name: '异常页', thumb: '/image/icon/page-result.png', path: '/page/component/page-result/page-result', suggestion: 'pageresult局部异常页面' },\n // {\n // name: '选择器',\n // thumb: '/image/icon/picker.png',\n // path: '/page/component/picker/picker',\n // suggestion: 'picker选择器',\n // },\n {\n name: '选择器视图',\n thumb: '/image/icon/picker-view.png',\n path: '/page/component/picker-view/picker-view',\n suggestion: 'pickerview选择器视图',\n },\n {\n name: '气泡',\n thumb: '/image/icon/popover.png',\n path: '/page/component/popover/popover',\n suggestion: 'popover气泡',\n },\n {\n name: '弹出菜单',\n thumb: '/image/icon/popup.png',\n path: '/page/component/popup/popup',\n suggestion: 'popup弹出菜单',\n },\n {\n name: '进度条',\n thumb: '/image/icon/progress.png',\n path: '/page/component/progress/progress',\n suggestion: 'progress进度条',\n },\n {\n name: '单选框',\n thumb: '/image/icon/radio.png',\n path: '/page/component/radio/radio',\n suggestion: 'radio单选框',\n },\n {\n name: '搜索框',\n thumb: '/image/icon/search-bar.png',\n path: '/page/component/search-bar/search-bar',\n suggestion: 'searchbar搜索框',\n },\n {\n name: '滑动条',\n thumb: '/image/icon/slider.png',\n path: '/page/component/slider/slider',\n suggestion: 'slider滑动条',\n },\n {\n name: '步进器',\n thumb: '/image/icon/stepper.png',\n path: '/page/component/stepper/stepper',\n suggestion: 'stepper步进器',\n },\n {\n name: '步骤条',\n thumb: '/image/icon/steps.png',\n path: '/page/component/steps/steps',\n suggestion: 'steps步骤条',\n },\n {\n name: '可滑动单元格',\n thumb: '/image/icon/swipe-action.png',\n path: '/page/component/swipe-action/swipe-action',\n suggestion: 'swipeaction可滑动单元格手势',\n },\n {\n name: '开关',\n thumb: '/image/icon/switch.png',\n path: '/page/component/switch/switch',\n suggestion: 'switch开关',\n },\n {\n name: '顶部选项卡',\n thumb: '/image/icon/tabs.png',\n path: '/page/component/tabs/tabs',\n suggestion: 'tabs顶部选项卡',\n },\n {\n name: '多行输入框',\n thumb: '/image/icon/textarea.png',\n path: '/page/component/textarea/textarea',\n suggestion: 'textarea多行输入框',\n },\n {\n name: '引导',\n thumb: '/image/icon/tips.png',\n path: '/page/component/tips/tips',\n suggestion: 'tips引导',\n },\n {\n name: '纵向选项卡',\n thumb: '/image/icon/vtabs.png',\n path: '/page/component/vtabs/vtabs',\n suggestion: 'vtabs纵向选项卡',\n },\n {\n name: '内嵌webview',\n thumb: '/image/icon/webview.png',\n path: '/page/component/webview/webview',\n suggestion: 'webview内嵌webview',\n },\n {\n name: '基础视图',\n thumb: '/image/icon/view.png',\n path: '/page/component/view/view',\n suggestion: 'view视图容器',\n },\n {\n name: '滑动视图',\n thumb: '/image/icon/swiper.png',\n path: '/page/component/swiper/swiper',\n suggestion: 'swiper滑动视图容器',\n },\n {\n name: '滚动视图',\n thumb: '/image/icon/scroll-view.png',\n path: '/page/component/scroll-view/scroll-view',\n suggestion: 'scrollview滚动视图',\n },\n {\n name: '输入框',\n thumb: '/image/icon/input.png',\n path: '/page/component/input/input',\n suggestion: 'input输入框文本输入',\n },\n {\n name: '文字',\n thumb: '/image/icon/text.png',\n path: '/page/component/text/text',\n suggestion: 'text文本文字',\n },\n];\n\nconst apiList = [\n {\n name: '获取授权码',\n path: '/page/API/get-auth-code/get-auth-code',\n suggestion: 'getauthcode获取授权码',\n },\n {\n name: '获取授信息',\n path: '/page/API/get-user-info/get-user-info',\n suggestion: 'getuserinfo获取用户信息',\n },\n {\n name: '发起支付',\n path: '/page/API/request-payment/request-payment',\n suggestion: 'requestpayment发起支付',\n },\n {\n name: '淘宝卡包',\n path: '/page/API/card-pack/card-pack',\n suggestion: 'cardpack淘宝卡包',\n },\n {\n name: '芝麻信用借还',\n path: '/page/API/zm-credit-borrow/zm-credit-borrow',\n suggestion: 'zmcreditborrow芝麻信用借还',\n },\n {\n name: '文本风险识别',\n path: '/page/API/text-risk-identification/text-risk-identification',\n suggestion: 'textriskidentification风险文本识别',\n },\n { name: '警告框', path: '/page/API/alert/alert', suggestion: 'alert警告框' },\n {\n name: '确认框',\n path: '/page/API/confirm/confirm',\n suggestion: 'confirm确认框',\n },\n { name: '弱提示', path: '/page/API/toast/toast', suggestion: 'toast弱提示' },\n {\n name: '加载提示',\n path: '/page/API/loading/loading',\n suggestion: 'loading加载提示',\n },\n {\n name: '操作菜单',\n path: '/page/API/action-sheet/action-sheet',\n suggestion: 'actionsheet操作菜单',\n },\n {\n name: '设置界面导航栏',\n path: '/page/API/set-navigation-bar/set-navigation-bar',\n suggestion: 'setnavigationbar设置界面导航栏',\n },\n // {\n // name: '设置optionMenu',\n // path: '/page/API/option-menu/option-menu',\n // suggestion: 'optionmenu设置optionmenu',\n // },\n {\n name: '页面跳转',\n path: '/page/API/navigator/navigator',\n suggestion: 'navigator页面跳转',\n },\n // {\n // name: '下拉刷新',\n // path: '/page/API/pull-down-refresh/pull-down-refresh',\n // suggestion: 'pulldownrefresh下拉刷新',\n // },\n {\n name: '创建动画',\n path: '/page/API/animation/animation',\n suggestion: 'animation创建动画',\n },\n {\n name: '创建绘画',\n path: '/page/API/canvas/canvas',\n suggestion: 'canvas创建绘画画布',\n },\n {\n name: '选择日期',\n path: '/page/API/date-picker/date-picker',\n suggestion: 'datepicker选择日期选择',\n },\n {\n name: '滚动页面',\n path: '/page/API/page-scroll-to/page-scroll-to',\n suggestion: 'pagescrollto滚动页面',\n },\n {\n name: '节点查询',\n path: '/page/API/create-selector-query/create-selector-query',\n suggestion: 'createselectorquery节点查询',\n },\n {\n name: '联系人',\n path: '/page/API/contact/contact',\n suggestion: 'contact联系人',\n },\n // {\n // name: '标题栏加载动画',\n // path: '/page/API/navigation-bar-loading/navigation-bar-loading',\n // suggestion: 'navigationbarloading标题栏加载动画',\n // },\n {\n name: '选择城市',\n path: '/page/API/choose-city/choose-city',\n suggestion: 'choosecity选择城市选择',\n },\n // {\n // name: '隐藏键盘',\n // path: '/page/API/keyboard/keyboard',\n // suggestion: 'hidekeyboard隐藏键盘',\n // },\n // {\n // name: '级联选择',\n // path: '/page/API/multi-level-select/multi-level-select',\n // suggestion: 'multilevelselect级联选择',\n // },\n // {\n // name: '选项选择',\n // path: '/page/API/options-select/options-select',\n // suggestion: 'multilevelselect级联选择',\n // },\n {\n name: '获取手机网络状态',\n path: '/page/API/get-network-type/get-network-type',\n suggestion: 'getnetworktype获取手机网络状态',\n },\n {\n name: '获取手机系统信息',\n path: '/page/API/get-system-info/get-system-info',\n suggestion: 'getsysteminfo获取手机系统信息',\n },\n {\n name: '振动',\n path: '/page/API/vibrate/vibrate',\n suggestion: 'vibrate振动',\n },\n {\n name: '剪贴板',\n path: '/page/API/clipboard/clipboard',\n suggestion: 'clipboard剪贴板',\n },\n {\n name: '获取基础库版本',\n path: '/page/API/sdk-version/sdk-version',\n suggestion: 'sdkversion获取基础库版本',\n },\n {\n name: '屏幕亮度',\n path: '/page/API/screen/screen',\n suggestion: 'screen屏幕亮度',\n },\n {\n name: '摇一摇',\n path: '/page/API/watch-shake/watch-shake',\n suggestion: 'watchshake摇一摇',\n },\n {\n name: '拨打电话',\n path: '/page/API/make-phone-call/make-phone-call',\n suggestion: 'makephonecall拨打电话',\n },\n {\n name: '用户截屏事件',\n path: '/page/API/user-capture-screen/user-capture-screen',\n suggestion: 'usercapturescreen用户截屏事件',\n },\n {\n name: '获取服务器时间',\n path: '/page/API/get-server-time/get-server-time',\n suggestion: 'getservertime获取服务器时间',\n },\n // {\n // name: '内存不足警告',\n // path: '/page/API/memory-warning//memory-warning',\n // suggestion: 'memorywarning内存不足警告',\n // },\n // {\n // name: '发起HTTP请求',\n // path: '/page/API/request/request',\n // suggestion: 'request发起请求发起http请求网络',\n // },\n // {\n // name: '上传文件',\n // path: '/page/API/upload-file/upload-file',\n // suggestion: 'uploadfile上传文件网络',\n // },\n // {\n // name: '下载文件',\n // path: '/page/API/download-file/download-file',\n // suggestion: 'downloadfile下载文件网络',\n // },\n // {\n // name: 'Websocket',\n // path: '/page/API/websocket/websocket',\n // suggestion: 'websocket网络',\n // },\n {\n name: '图片',\n path: '/page/API/image/image',\n suggestion: 'image图片多媒体',\n },\n // {\n // name: '获取图片信息',\n // path: '/page/API/get-image-info/get-image-info',\n // suggestion: 'getimageinfo获取图片信息',\n // },\n // {\n // name: '压缩图片',\n // path: '/page/API/compress-image/compress-image',\n // suggestion: 'compressimage压缩图片',\n // },\n {\n name: '获取当前位置',\n path: '/page/API/get-location/get-location',\n suggestion: 'getlocation获取当前位置地图',\n },\n // {\n // name: '使用原生地图查看位置',\n // path: '/page/API/open-location/open-location',\n // suggestion: 'openlocation使用原生地图查看位置',\n // },\n // {\n // name: '打开地图选择位置',\n // path: '/page/API/choose-location/choose-location',\n // suggestion: 'chooselocation打开地图选择位置',\n // },\n {\n name: '缓存',\n path: '/page/API/storage/storage',\n suggestion: 'storage缓存',\n },\n {\n name: '扫码 Scan',\n path: '/page/API/scan-code/scan-code',\n suggestion: 'scan-code扫码',\n },\n // {\n // name: '自定义分享',\n // path: '/page/API/share/share',\n // suggestion: 'share自定义分享',\n // },\n { name: '文件', path: '/page/API/file/file', suggestion: 'file文件' },\n // {\n // name: '蓝牙',\n // path: '/page/API/bluetooth/bluetooth',\n // suggestion: 'bluetooth蓝牙',\n // },\n // { name: '数据安全', path: '/page/API/rsa/rsa', suggestion: 'rsa数据安全' },\n // {\n // name: '自定义分析',\n // path: '/page/API/report-analytics/report-analytics',\n // suggestion: 'reportanalytics数据分析',\n // },\n {\n name: '容器事件',\n path: '/page/API/events/events',\n suggestion: 'events容器事件',\n },\n // { name: 'OCR', path: '/page/API/ocr/ocr', suggestion: 'ocr' },\n];\n\nPage({\n data: {\n value: '',\n history: my.getStorageSync({ key: 'searchHistory' }).data || [],\n hot: [\n { name: 'ScrollView', url: '/page/component/scroll-view/scroll-view' },\n { name: '地图', url: '/page/component/map/map' },\n { name: 'Icon', url: '/page/component/icon/icon' },\n { name: 'Card', url: '/page/component/card/card' },\n { name: '获取授权码', url: '/page/API/get-auth-code/get-auth-code' },\n { name: 'Popup', url: '/page/component/popup/popup' },\n // { name: '发起HTTP请求', url: '/page/API/request/request' },\n { name: '画布', url: '/page/component/canvas/canvas' },\n { name: '导航', url: '/page/API/navigator/navigator' },\n ],\n componentSuggestions: [],\n apiSuggestions: [],\n },\n onLoad() {\n this.setData({\n history: my.getStorageSync({ key: 'searchHistory' }).data,\n });\n console.log(my.getStorageSync({ key: 'searchHistory' }).data);\n this.onInput = debounce(this.onInput.bind(this), 400);\n my.setNavigationBar({\n borderBottomColor: '#fff',\n });\n },\n clear() {\n my.confirm({\n content: '确定删除相关历史?',\n success: res => {\n if (res.confirm) {\n my.clearStorage();\n this.setData({\n history: [],\n });\n }\n },\n });\n },\n onInput(keyword) {\n this.setData({\n value: keyword,\n });\n const regExp = /[A-Za-z]/;\n if (keyword === '' || (regExp.test(keyword) && keyword.length === 1)) {\n this.setData({\n componentSuggestions: [],\n apiSuggestions: [],\n });\n return;\n }\n const componentSuggestions = [];\n const apiSuggestions = [];\n for (let i = 0; i < componentList.length; i++) {\n if (\n componentList[i].suggestion\n .toLocaleLowerCase()\n .indexOf(keyword.toLocaleLowerCase()) != -1\n ) {\n componentSuggestions.push(componentList[i]);\n }\n }\n\n for (let i = 0; i < apiList.length; i++) {\n if (\n apiList[i].suggestion\n .toLocaleLowerCase()\n .indexOf(keyword.toLocaleLowerCase()) != -1\n ) {\n apiSuggestions.push(apiList[i]);\n }\n }\n this.setData({ componentSuggestions, apiSuggestions });\n },\n onClear() {\n this.setData({\n value: '',\n });\n },\n onCancel() {\n this.setData({\n componentSuggestions: [],\n apiSuggestions: [],\n value: '',\n });\n my.navigateBack();\n },\n onItemTap({ name }) {\n this.setData({\n value: name,\n });\n\n this.onInput(name);\n },\n onListItemTap(e) {\n const { name, url } = e.target.dataset;\n this.addToHistory(name);\n my.navigateTo({ url });\n },\n addToHistory(keyword) {\n const searchHistory =\n my.getStorageSync({ key: 'searchHistory' }).data || [];\n let index = -1;\n\n for (let i = 0; i < searchHistory.length; i++) {\n if (searchHistory[i].name === keyword) {\n index = i;\n break;\n }\n }\n\n let history = [];\n\n if (searchHistory.length >= 8) {\n if (index === -1) {\n history = [{ name: keyword }, ...searchHistory.slice(0, 7)];\n } else {\n searchHistory.splice(index, 1).slice(0, 7);\n history = [{ name: keyword }, ...searchHistory];\n }\n } else {\n if (index === -1) {\n history = [{ name: keyword }, ...searchHistory];\n } else {\n searchHistory.splice(index, 1);\n history = [{ name: keyword }, ...searchHistory];\n }\n }\n\n my.setStorageSync({\n key: 'searchHistory',\n data: history,\n });\n\n this.setData({\n history,\n });\n },\n});\n","page/common/search/search.json":"{\n \"defaultTitle\": \"搜索\",\n \"transparentTitle\": \"none\",\n \"allowsBounceVertical\": \"NO\",\n \"usingComponents\": {\n \"search-bar\": \"mini-antui/es/search-bar/index\",\n \"block-list\": \"/page/common/components/block-list/block-list\",\n \"list\":\"mini-antui/es/list/index\",\n \"list-item\":\"mini-antui/es/list/list-item/index\"\n }\n}","page/component/am-checkbox/am-checkbox.acss":"","page/component/am-checkbox/am-checkbox.axml":"<list>\n <view slot=\"header\">\n 列表+复选框\n </view>\n <block a:for=\"{{items}}\">\n <list-item\n thumb=\"\"\n arrow=\"{{false}}\"\n index=\"{{index}}\"\n key=\"items-{{index}}\"\n last=\"{{index === (items.length - 1)}}\"\n >\n <view slot=\"prefix\" style=\"display: flex; align-items: center;\">\n <am-checkbox id=\"{{item.id}}\" data-name=\"{{item.value}}\" disabled=\"{{item.disabled}}\" checked=\"{{item.checked}}\" onChange=\"onChange\" />\n </view>\n <label for=\"{{item.id}}\">{{item.title}}</label>\n </list-item>\n </block>\n</list>\n<view style=\"padding: 16px;\">\n <view style=\"color: #888; font-size: 14px;\">\n 协议\n </view>\n <view style=\"margin-top: 10px;\">\n <label style=\"display: flex; line-height: 24px;\">\n <am-checkbox />\n <text style=\"text-indent: 8px; color: #888\">同意 《信用支付服务合同》</text>\n </label>\n </view>\n</view>\n<view style=\"padding: 16px; background-color: #fff;\">\n <form onSubmit=\"onSubmit\" onReset=\"onReset\">\n <view>\n <view style=\"color: #666; font-size: 14px; margin-bottom: 5px;\">选择你用过的框架:</view>\n <view>\n <checkbox-group name=\"libs\">\n <label a:for=\"{{items2}}\" style=\"display: flex; align-items: center; height: 30px;\">\n <am-checkbox value=\"{{item.name}}\" checked=\"{{item.checked}}\" disabled=\"{{item.disabled}}\" />\n <text style=\"color: #888; font-size: 14px; margin-left: 8px;\">{{item.value}}</text>\n </label>\n </checkbox-group>\n </view>\n <view style=\"margin-top: 10px;\">\n <button type=\"primary\" size=\"mini\" formType=\"submit\">submit</button>\n </view>\n </view>\n </form>\n</view>\n","page/component/am-checkbox/am-checkbox.js":"Page({\n data: {\n items: [\n { checked: true, disabled: false, value: 'a', title: '复选框-默认选中', id: 'checkbox1' },\n { checked: false, disabled: false, value: 'b', title: '复选框-默认未选中', id: 'checkbox2' },\n { checked: true, disabled: true, value: 'c', title: '复选框-默认选中disabled', id: 'checkbox3' },\n { checked: false, disabled: true, value: 'd', title: '复选框-默认未选中disabled', id: 'checkbox4' },\n ],\n items2: [\n { name: 'react', value: 'React', checked: true },\n { name: 'vue', value: 'Vue.js' },\n { name: 'ember', value: 'Ember.js' },\n { name: 'backbone', value: 'Backbone.js', disabled: true },\n ],\n },\n onSubmit(e) {\n my.alert({\n content: `你选择的框架是 ${e.detail.value.libs.join(', ')}`,\n });\n },\n onReset() {},\n onChange(e) { console.log(e); },\n});\n","page/component/am-checkbox/am-checkbox.json":"{\n \"defaultTitle\": \"复选框\",\n \"usingComponents\": {\n \"am-checkbox\": \"mini-antui/es/am-checkbox/index\",\n \"list\": \"mini-antui/es/list/index\",\n \"list-item\": \"mini-antui/es/list/list-item/index\"\n }\n}","page/component/am-icon/am-icon.acss":".icon-title {\n margin-top: 20px;\n margin-bottom: 10px;\n margin-left: 10px;\n color: #333;\n font-size: 16px;\n}\n\n.icon-list {\n background: #fff;\n}\n\n.icon-item {\n display: inline-flex;\n width: 33.33333%;\n height: 80px;\n align-items: center;\n flex-direction: column;\n justify-content: center;\n}\n\n.icon-desc {\n margin-top: 10px;\n}\n","page/component/am-icon/am-icon.axml":"<view>\n <view class=\"icon-title\">基础</view>\n <view class=\"icon-list\">\n <block a:for=\"{{basicTypes}}\">\n <view class=\"icon-item\">\n <am-icon type=\"{{item}}\" />\n <text class=\"icon-desc\">{{item}}<text>\n </view>\n </block>\n </view>\n <view class=\"icon-title\">描边风格</view>\n <view class=\"icon-list\">\n <block a:for=\"{{strokeTypes}}\">\n <view class=\"icon-item\">\n <am-icon type=\"{{item}}\" />\n <text class=\"icon-desc\">{{item}}<text>\n </view>\n </block>\n </view>\n <view class=\"icon-title\">实心风格</view>\n <view class=\"icon-list\">\n <block a:for=\"{{solidTypes}}\">\n <view class=\"icon-item\">\n <am-icon type=\"{{item}}\" />\n <text class=\"icon-desc\">{{item}}<text>\n </view>\n </block>\n </view>\n</view>","page/component/am-icon/am-icon.js":"Page({\n data: {\n basicTypes: [\n 'arrow-left',\n 'arrow-up',\n 'arrow-right',\n 'arrow-down',\n 'cross',\n 'plus',\n ],\n strokeTypes: [\n 'close-o',\n 'dislike-o',\n 'heart-o',\n 'help-o',\n 'like-o',\n 'location-o',\n 'info-o',\n 'success-o',\n 'wait-o',\n 'warning-o',\n 'star-o',\n 'download',\n 'friends',\n 'circle',\n 'delete',\n 'charge',\n 'card',\n 'notice',\n 'qrcode',\n 'reload',\n 'scan',\n 'money',\n 'search',\n 'setting',\n 'share',\n 'zoom-in',\n 'zoom-out',\n ],\n solidTypes: [\n 'close',\n 'dislike',\n 'heart',\n 'help',\n 'like',\n 'location',\n 'info',\n 'success',\n 'wait',\n 'warning',\n 'star',\n ],\n },\n});\n","page/component/am-icon/am-icon.json":"{\n \"defaultTitle\": \"AmountIcon\",\n \"usingComponents\": {\n \"am-icon\": \"mini-antui/es/am-icon/index\"\n }\n}\n","page/component/amount-input/amount-input.acss":"/* required by usingComponents */","page/component/amount-input/amount-input.axml":"<view>\n <amount-input\n type=\"digit\"\n title=\"转入金额\"\n extra=\"建议转入¥100以上金额\"\n placeholder=\"输入转入金额\"\n value=\"{{value}}\"\n maxLength=\"10\"\n focus=\"{{true}}\"\n btnText=\"全部提现\"\n onClear=\"onInputClear\"\n onInput=\"onInput\"\n onButtonClick=\"onButtonClick\"\n onConfirm=\"onInputConfirm\"\n onBlur=\"onInputBlur\"\n onFocus=\"onInputFocus\" />\n</view>","page/component/amount-input/amount-input.js":"Page({\n data: {\n value: 200,\n },\n onInputClear() {\n this.setData({\n value: '',\n });\n },\n onInputConfirm(e) {\n console.log(e);\n my.alert({\n content: 'confirmed',\n });\n },\n onInput(e) {\n console.log(e);\n const { value } = e.detail;\n this.setData({\n value,\n });\n },\n onButtonClick() {\n my.alert({\n content: 'button clicked',\n });\n },\n onInputFocus(e) {\n console.log(e);\n },\n onInputBlur(e) {\n console.log(e);\n },\n});\n","page/component/amount-input/amount-input.json":"{\n \"defaultTitle\": \"AmountInput\",\n \"usingComponents\": {\n \"amount-input\": \"mini-antui/es/amount-input/index\"\n }\n}","page/component/badge/badge.acss":"","page/component/badge/badge.axml":"<view>\n <list>\n <block a:for=\"{{items}}\">\n <list-item\n arrow=\"{{true}}\"\n index=\"{{index}}\"\n key=\"items-{{index}}\"\n last=\"{{index === (items.length - 1)}}\"\n >\n <view>\n <badge a:if=\"{{item.isWrap}}\" text=\"{{item.text}}\" dot=\"{{item.dot}}\">\n <view slot=\"inner\" style=\"height: 24px; width: 24px; background-color: #ddd;\"></view>\n </badge>\n <text style=\"margin-left: {{ item.isWrap ? '12px' : '0' }}\">{{item.intro}}</text>\n </view>\n <view slot=\"extra\">\n <badge a:if=\"{{!item.isWrap}}\" text=\"{{item.text}}\" dot=\"{{item.dot}}\" overflowCount=\"{{item.overflowCount}}\" /> \n </view>\n </list-item>\n </block>\n </list>\n</view>\n","page/component/badge/badge.js":"Page({\n data: {\n items: [\n {\n dot: true,\n text: '',\n isWrap: true,\n intro: 'Dot Badge',\n },\n {\n dot: false,\n text: 1,\n isWrap: true,\n intro: 'Text Badge',\n },\n {\n dot: false,\n text: 99,\n isWrap: false,\n intro: '数字',\n },\n {\n dot: false,\n text: 100,\n overflowCount: 99,\n isWrap: false,\n intro: '数字超过overflowCount',\n },\n {\n dot: false,\n text: 'new',\n isWrap: false,\n intro: '文字',\n },\n ],\n },\n});\n","page/component/badge/badge.json":"{\n \"defaultTitle\": \"徽标\",\n \"usingComponents\": {\n \"list\": \"mini-antui/es/list/index\",\n \"list-item\": \"mini-antui/es/list/list-item/index\",\n \"badge\": \"mini-antui/es/badge/index\"\n }\n}","page/component/button/button.acss":".red {\n background-color: red;\n border-color: red;\n color: #fff;\n}\n\nbutton + button {\n margin-top: 32rpx;\n}\n","page/component/button/button.axml":"<view class=\"page\">\n <view class=\"page-description\">按钮</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">type-primary/ghost</view>\n <view class=\"page-section-demo\">\n <button type=\"primary\">主要操作 Normal</button>\n <button type=\"primary\" loading>操作</button>\n <button type=\"primary\" disabled>主要操作 Disable</button>\n <button type=\"ghost\">ghost操作</button>\n <button type=\"ghost\" loading>ghost操作</button>\n <button type=\"ghost\" disabled>ghost操作 Disable</button>\n </view>\n </view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">type-default</view>\n <view class=\"page-section-demo\">\n <button data-aspm-click=\"xxx\">辅助操作 Normal</button>\n <button disabled>辅助操作 Disable</button>\n </view>\n </view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">type-warn</view>\n <view class=\"page-section-demo\">\n <button type=\"warn\">警告类操作 Normal</button>\n <button type=\"warn\" disabled>警告类操作 Disable</button>\n <button type=\"warn\" hover-class=\"red\">hover-red</button>\n </view>\n </view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">Size</view>\n <view class=\"page-section-demo\">\n <button size=\"mini\" loading>提交</button>\n <button style=\"margin-left: 10px;\" type=\"primary\" size=\"mini\">选项</button>\n </view>\n </view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">open</view>\n <view class=\"page-section-demo\">\n <button open-type=\"share\">share</button>\n </view>\n </view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">Form</view>\n <view class=\"page-section-demo\">\n <form onSubmit=\"onSubmit\" onReset=\"onReset\">\n <button form-type=\"submit\" type=\"primary\">submit</button>\n <button form-type=\"reset\">reset</button>\n </form>\n </view>\n </view>\n</view>\n\n","page/component/button/button.js":"Page({\n data: {},\n onShareAppMessage() {\n return {\n title: 'view page',\n path: 'page/component/view/view',\n };\n },\n onSubmit() {\n my.alert({ title: 'You click submit' });\n },\n onReset() {\n my.alert({ title: 'You click reset' });\n },\n});\n\n","page/component/button/button.json":"{\n \"defaultTitle\": \"Button\"\n}","page/component/calendar/calendar.acss":"/* required by usingComponents */\n.am-calendar-selected .am-calendar-block {\n background-color: #ff5500;\n}\n","page/component/calendar/calendar.axml":"<view>\n <calendar\n type=\"range\"\n tagData=\"{{tagData}}\"\n onSelect=\"handleSelect\"\n onMonthChange=\"onMonthChange\" />\n</view>","page/component/calendar/calendar.js":"Page({\n data: {\n tagData: [\n { date: '2018-05-14', tag: '还房贷', tagColor: 5 },\n { date: '2018-05-28', tag: '公积金', tagColor: 2 },\n ],\n },\n handleSelect() {},\n onMonthChange() {},\n});","page/component/calendar/calendar.json":"{\n \"defaultTitle\": \"Calendar\",\n \"usingComponents\":{\n \"calendar\": \"mini-antui/es/calendar/index\"\n }\n}","page/component/canvas/canvas.acss":".canvas-view {\n display: flex;\n justify-content: center;\n}\n\n.canvas {\n width: 305px;\n height: 305px;\n background-color: #fff;\n}\n","page/component/canvas/canvas.axml":"<view class=\"page\">\n <view class=\"canvas-view\">\n <canvas \n id=\"canvas\"\n width=\"610\"\n height=\"610\"\n class=\"canvas\"\n onTouchStart=\"log\"\n onTouchMove=\"log\"\n onTouchEnd=\"log\"\n />\n </view>\n</view>\n\n\n","page/component/canvas/canvas.js":"Page({\n onReady() {\n this.point = {\n x: Math.random() * 590,\n y: Math.random() * 590,\n dx: Math.random() * 10,\n dy: Math.random() * 10,\n r: Math.round(Math.random() * 255 | 0),\n g: Math.round(Math.random() * 255 | 0),\n b: Math.round(Math.random() * 255 | 0),\n };\n\n this.interval = setInterval(this.draw.bind(this), 17);\n this.ctx = my.createCanvasContext('canvas');\n },\n\n draw() {\n const { ctx } = this;\n ctx.setFillStyle('#FFF');\n ctx.fillRect(0, 0, 610, 610);\n\n ctx.beginPath();\n ctx.arc(this.point.x, this.point.y, 20, 0, 2 * Math.PI);\n ctx.setFillStyle('rgb(' + this.point.r + ', ' + this.point.g + ', ' + this.point.b + ')');\n ctx.fill();\n ctx.draw();\n\n this.point.x += this.point.dx;\n this.point.y += this.point.dy;\n if (this.point.x <= 10 || this.point.x >= 590) {\n this.point.dx = -this.point.dx;\n this.point.r = Math.round(Math.random() * 255 | 0);\n this.point.g = Math.round(Math.random() * 255 | 0);\n this.point.b = Math.round(Math.random() * 255 | 0);\n }\n\n if (this.point.y <= 10 || this.point.y >= 590) {\n this.point.dy = -this.point.dy;\n this.point.r = Math.round(Math.random() * 255 | 0);\n this.point.g = Math.round(Math.random() * 255 | 0);\n this.point.b = Math.round(Math.random() * 255 | 0);\n }\n },\n drawBall() {\n\n },\n log(e) {\n if (e.touches && e.touches[0]) {\n console.log(e.type, e.touches[0].x, e.touches[0].y);\n } else {\n console.log(e.type);\n }\n },\n onUnload() {\n clearInterval(this.interval);\n },\n});\n\n","page/component/canvas/canvas.json":"{\n \"defaultTitle\": \"Canvas\"\n}\n","page/component/card/card.acss":"/* required by usingComponents */","page/component/card/card.axml":"<view class=\"container\">\n <card\n title=\"卡片标题1\"\n subTitle=\"副标题非必填1\"\n onClick=\"onCardClick\"\n info=\"点击了第一个card\"\n />\n <view style=\"margin-top: 10px;\" />\n <card\n thumb=\"{{thumb}}\"\n title=\"卡片标题2\"\n subTitle=\"副标题非必填2\"\n onClick=\"onCardClick\"\n info=\"点击了第二个card\"\n />\n <view style=\"margin-top: 10px;\" />\n <card\n thumb=\"{{thumb}}\"\n title=\"卡片标题3\"\n subTitle=\"副标题非必填3\"\n onClick=\"onCardClick\"\n footer=\"描述文字\"\n footerImg=\"{{footerImg}}\"\n info=\"点击了第三个card\"\n />\n","page/component/card/card.js":"Page({\n data: {\n thumb: 'https://gw.alipayobjects.com/zos/rmsportal/VBqNBOiGYkCjqocXjdUj.png',\n footerImg: 'https://gw.alipayobjects.com/zos/rmsportal/VBqNBOiGYkCjqocXjdUj.png',\n },\n onCardClick: function(ev) {\n my.showToast({\n content: ev.info,\n });\n }\n});","page/component/card/card.json":"{\n \"defaultTitle\": \"Card\",\n \"usingComponents\":{\n \"card\": \"mini-antui/es/card/index\"\n }\n}","page/component/checkbox/checkbox.acss":".checkbox {\n display: block;\n margin-bottom: 20rpx;\n}\n\nbutton + button {\n margin-top: 32rpx;\n}\n\n.checkbox-text {\n font-size:34rpx;\n line-height: 1.2;\n}\n","page/component/checkbox/checkbox.axml":"<view class=\"page\">\n <view class=\"page-description\">多项选择器</view>\n <form onSubmit=\"onSubmit\" onReset=\"onReset\">\n <view class=\"page-section\">\n <view class=\"page-section-title\">选择你用过的框架:</view>\n <view class=\"page-section-demo\">\n <checkbox-group onChange=\"onChange\" name=\"libs\">\n <label class=\"checkbox\" a:for=\"{{items}}\" key=\"label-{{index}}\">\n <checkbox value=\"{{item.name}}\" checked=\"{{item.checked}}\" disabled=\"{{item.disabled}}\" />\n <text class=\"checkbox-text\">{{item.value}}</text>\n </label>\n </checkbox-group>\n </view>\n <view class=\"page-section-btns\">\n <view><button type=\"ghost\" size=\"mini\" formType=\"reset\">reset</button></view>\n <view><button type=\"primary\" size=\"mini\" formType=\"submit\">submit</button></view>\n </view>\n </view>\n </form>\n</view>\n","page/component/checkbox/checkbox.js":"Page({\n data: {\n items: [\n { name: 'angular', value: 'AngularJS' },\n { name: 'react', value: 'React', checked: true },\n { name: 'polymer', value: 'Polymer' },\n { name: 'vue', value: 'Vue.js' },\n { name: 'ember', value: 'Ember.js' },\n { name: 'backbone', value: 'Backbone.js', disabled: true },\n ],\n },\n onSubmit(e) {\n console.log('onSubmit', e);\n my.alert({\n content: `你选择的框架是 ${e.detail.value.libs.join(', ')}`,\n });\n },\n onReset(e) {\n console.log('onReset', e);\n },\n onChange(e) {\n console.log(e);\n },\n});\n","page/component/checkbox/checkbox.json":"{\n \"defaultTitle\": \"Checkbox\"\n}","page/component/contact-button/contact-button.acss":".page-section-title {\n padding: 32rpx 32rpx;\n text-align: center;\n}\n.page-section-demo {\n display: flex;\n justify-content: center;\n}\n","page/component/contact-button/contact-button.axml":"<view class=\"page\">\n <view class=\"page-description\">唤起云客服</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">点击下方图标唤起云客服功能</view>\n <view class=\"page-section-demo\">\n <contact-button tnt-inst-id=\"FRYFEGCN\" scene=\"SCE00000725\" size=\"46\" color=\"#e15151\" />\n </view>\n <view class=\"page-section-demo\">\n <contact-button tnt-inst-id=\"FRYFEGCN\" scene=\"SCE00000725\" size=\"46\" icon=\"{{src}}\" />\n </view>\n </view>\n</view>\n","page/component/contact-button/contact-button.js":"Page({\n data: {\n src: '/image/ant.png',\n },\n});\n","page/component/contact-button/contact-button.json":"{\n \"defaultTitle\": \"唤起云客服\"\n}\n","page/component/cover-view/cover-view.acss":"cover-image {\n position: absolute;\n left: 20px;\n top: 100px;\n height: 50px;\n width: 50px;\n}\n\n.cover-view {\n position: absolute;\n top: calc(50% - 75rpx);\n left: calc(50% - 150rpx);\n display:flex;\n flex-direction:row;\n background-color: rgba(0, 0, 0, 0);\n}\n\n.cover-view-item{\n width: 100rpx;\n height: 150rpx;\n font-size: 26rpx;\n}\n\n.cover-view-item-1 {\n background-color: rgba(26, 173, 25, 0.7);\n}\n\n.cover-view-item-2 {\n background-color: rgba(39, 130, 215, 0.7);\n}\n\n.cover-view-item-3 {\n background-color: rgba(255, 255, 255, 0.7);\n}\n","page/component/cover-view/cover-view.axml":"<view class=\"page\">\n <view class=\"page-description\">cover-view</view>\n <view class=\"page-section\">\n <view class=\"page-section-demo\" style=\"position: relative;\">\n <map\n longitude=\"{{longitude}}\"\n latitude=\"{{latitude}}\"\n scale=\"{{scale}}\"\n style=\"width: 100%; height: 200px;\"\n include-points=\"{{includePoints}}\"\n />\n <cover-view class=\"cover-view\">\n <cover-view class=\"cover-view-item cover-view-item-1\"></cover-view>\n <cover-view class=\"cover-view-item cover-view-item-2\"></cover-view>\n <cover-view class=\"cover-view-item cover-view-item-3\"></cover-view>\n </cover-view>\n <cover-image style=\"\" src=\"/image/ant.png\" />\n </view>\n </view>\n</view>\n","page/component/cover-view/cover-view.js":"Page({\n data: {\n scale: 14,\n longitude: 120.10675,\n latitude: 30.266786,\n includePoints: [{\n latitude: 30.266786,\n longitude: 120.10675,\n }],\n }\n});\n","page/component/cover-view/cover-view.json":"{}","page/component/favorite/favorite.acss":".favorite {\n padding: 0 16px;\n}\n\n.name {\n margin-top: 24px;\n text-align: center;\n color: rgba(51, 51, 51, 0.49);\n font-size: 16px;\n}\n\n.name text {\n position: relative;\n}\n\n.name text::after {\n position: absolute;\n left: 50%;\n display: block;\n content: '';\n width: 32px;\n height: 1px;\n margin-top: 5px;\n background-color: rgba(51, 51, 51, 0.49);\n transform: scaleY(0.5) translateX(-50%);\n}\n\n.title {\n margin-top: 37px;\n color: #999;\n line-height: 18px;\n font-size: 13px;\n}\n\n.explanation {\n margin-top: 12px;\n font-size: 14px;\n line-height: 20px;\n color: #999;\n}","page/component/favorite/favorite.axml":"<view class=\"favorite\">\n <favorite>收藏商家应用示例</favorite>\n <view class=\"name\">\n <text>Favorite</text>\n </view>\n <view class=\"title\">\n <view>收藏组件</view>\n <view>favorite</view>\n </view>\n <view class=\"explanation\">\n 提示用户收藏商家应用,收藏后,用户可直接从商家应用收藏进入,再次使用几率大大增加。可根据用户当前收藏状态,判断是否显示组件,并根据用户首次收藏或关闭收藏组件行为,控制展示内容及疲劳度。\n </view>\n</view>","page/component/favorite/favorite.js":"Page({\n\n});","page/component/favorite/favorite.json":"{\n \"defaultTitle\": \"收藏组件\",\n \"titleBarColor\": \"#262833\"\n}","page/component/filter/filter.acss":"","page/component/filter/filter.axml":"<filter show=\"{{show}}\" max=\"{{1}}\">\n <block a:for=\"{{items}}\">\n <filter-item value=\"{{item.value}}\" id=\"{{item.id}}\" onChange=\"handleCallBack\" selected=\"{{item.selected}}\"/>\n </block>\n</filter>","page/component/filter/filter.js":"Page({\n data: {\n show: true,\n items: [\n { id: 1, value: '衣服' },\n { id: 1, value: '橱柜' },\n { id: 1, value: '衣架' },\n { id: 3, value: '数码产品' },\n { id: 4, value: '防盗门' },\n { id: 5, value: '椅子' },\n { id: 7, value: '显示器' },\n { id: 6, value: '某最新款电子产品' },\n { id: 8, value: '某某某某某牌电视游戏底座' },\n ]\n },\n handleCallBack(data) {\n my.alert({\n content: data\n });\n },\n toggleFilter() {\n this.setData({\n show: !this.data.show,\n });\n }\n});","page/component/filter/filter.json":"{\n \"defaultTitle\": \"Filter\",\n \"usingComponents\":{\n \"filter\": \"mini-antui/es/filter/index\",\n \"filter-item\": \"mini-antui/es/filter/filter-item/index\"\n }\n}","page/component/flex/flex.acss":".flex-container {\n padding: 10px;\n}\n\n.sub-title {\n color: #888;\n font-size: 14px;\n padding: 30px 0 18px 0;\n}\n\n.placeholder {\n background-color: #ebebef;\n color: #bbb;\n text-align: center;\n height: 30px;\n line-height: 30px;\n width: 100%;\n}\n\n.placeholder.inline {\n width: 80px;\n margin: 9px 9px 9px 0;\n}\n\n.placeholder.small {\n height: 20px;\n line-height: 20px\n}","page/component/flex/flex.axml":"<view class=\"flex-container\">\n <view class=\"sub-title\">Basic</view>\n <flex>\n <flex-item><view class=\"placeholder\">Block</view></flex-item>\n <flex-item><view class=\"placeholder\">Block</view></flex-item>\n </flex>\n <view style=\"height: 20px;\" />\n <flex>\n <flex-item><view class=\"placeholder\">Block</view></flex-item>\n <flex-item><view class=\"placeholder\">Block</view></flex-item>\n <flex-item><view class=\"placeholder\">Block</view></flex-item>\n </flex>\n <view style=\"height: 20px;\" />\n <flex>\n <flex-item><view class=\"placeholder\">Block</view></flex-item>\n <flex-item><view class=\"placeholder\">Block</view></flex-item>\n <flex-item><view class=\"placeholder\">Block</view></flex-item>\n <flex-item><view class=\"placeholder\">Block</view></flex-item>\n </flex>\n <view className=\"sub-title\">Wrap</view>\n <flex wrap=\"wrap\">\n <view class=\"placeholder inline\">Block</view>\n <view class=\"placeholder inline\">Block</view>\n <view class=\"placeholder inline\">Block</view>\n <view class=\"placeholder inline\">Block</view>\n <view class=\"placeholder inline\">Block</view>\n </flex>\n <view className=\"sub-title\">Align</view>\n <flex justify=\"center\">\n <view class=\"placeholder inline\">Block</view>\n <view class=\"placeholder inline\">Block</view>\n <view class=\"placeholder inline\">Block</view>\n </flex>\n <flex justify=\"end\">\n <view class=\"placeholder inline\">Block</view>\n <view class=\"placeholder inline\">Block</view>\n <view class=\"placeholder inline\">Block</view>\n </flex>\n <flex justify=\"between\">\n <view class=\"placeholder inline\">Block</view>\n <view class=\"placeholder inline\">Block</view>\n <view class=\"placeholder inline\">Block</view>\n </flex>\n <flex align=\"start\">\n <view class=\"placeholder inline\">Block</view>\n <view class=\"placeholder inline small\">Block</view>\n <view class=\"placeholder inline\">Block</view>\n </flex>\n <flex align=\"end\">\n <view class=\"placeholder inline\">Block</view>\n <view class=\"placeholder inline small\">Block</view>\n <view class=\"placeholder inline\">Block</view>\n </flex>\n <flex align=\"baseline\">\n <view class=\"placeholder inline\">Block</view>\n <view class=\"placeholder inline small\">Block</view>\n <view class=\"placeholder inline\">Block</view>\n </flex>\n</view>","page/component/flex/flex.js":"Page({});\n","page/component/flex/flex.json":"{\n \"usingComponents\": {\n \"flex\": \"mini-antui/es/flex/index\",\n \"flex-item\": \"mini-antui/es/flex/flex-item/index\"\n }\n}","page/component/footer/footer.acss":"","page/component/footer/footer.axml":"<view>\n <view style=\"margin-top: 50px;\" />\n <footer\n copyright=\"{{copyright}}\" />\n <view style=\"margin-top: 50px;\" />\n <footer\n copyright=\"{{copyright}}\"\n links=\"{{links}}\" />\n <view style=\"margin-top: 50px;\" />\n <footer\n copyright=\"{{copyright}}\"\n links=\"{{singleLink}}\" />\n <view style=\"margin-top: 50px\" />\n <footer\n links=\"{{links}}\" /> \n</view>","page/component/footer/footer.js":"Page({\n data: {\n copyright: '© 2004-2017 Alipay.com. All rights reserved.',\n links: [\n { text: '底部链接', url: '../view/view' },\n { text: '底部链接', url: '../view/view' },\n ],\n singleLink: [\n { text: '底部链接', url: '../view/view' },\n ],\n },\n});","page/component/footer/footer.json":"{\n \"defaultTitle\": \"Footer\",\n \"usingComponents\":{\n \"footer\": \"mini-antui/es/footer/index\"\n }\n}","page/component/form/form.acss":"button + button {\n margin-top: 32rpx;\n}","page/component/form/form.axml":"<view class=\"page\">\n <view class=\"page-description\">表单</view>\n <form onSubmit=\"onSubmit\" onReset=\"onReset\">\n <view class=\"page-section\">\n <view class=\"page-section-title\">Slider</view>\n <view class=\"page-section-demo\">\n <slider value=\"80\" name=\"slider\" show-value />\n </view>\n </view>\n <view class=\"page-section\">\n <view class=\"form-row\">\n <view class=\"form-row-label\">Switch</view>\n <view class=\"form-row-content\" style=\"text-align: right\">\n <switch name=\"switch\" />\n </view>\n </view>\n <view class=\"form-line\" />\n <view class=\"form-row\">\n <view class=\"form-row-label\">Input</view>\n <view class=\"form-row-content\">\n <input name=\"input\" class=\"input\" placeholder=\"input something\" />\n </view>\n </view>\n </view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">Radio</view>\n <view class=\"page-section-demo\">\n <radio-group name=\"radio-group\">\n <label><radio value=\"radio1\" />radio1</label>\n <label><radio value=\"radio2\" />radio2</label>\n </radio-group>\n </view>\n </view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">Checkbox</view>\n <view class=\"page-section-demo\">\n <checkbox-group name=\"checkbox\">\n <label><checkbox value=\"checkbox1\" />checkbox1</label>\n <label><checkbox value=\"checkbox2\" />checkbox2</label>\n </checkbox-group>\n </view>\n <view class=\"page-section-btns\">\n <view><button type=\"ghost\" size=\"mini\" formType=\"reset\">Reset</button></view>\n <view><button type=\"primary\" size=\"mini\" formType=\"submit\">Submit</button></view>\n </view>\n </view>\n </form>\n</view>\n","page/component/form/form.js":"\nPage({\n data: {},\n onSubmit(e) {\n my.alert({\n content: `数据:${JSON.stringify(e.detail.value)}`,\n });\n },\n onReset() {\n \n },\n});\n","page/component/form/form.json":"{\n \"defaultTitle\": \"Form\"\n}","page/component/grid/grid.acss":".am-grid {\n display: flex;\n flex-direction: row;\n flex-wrap: wrap;\n background-color: white;\n}\n\n.am-grid-4 {\n padding-top: 7px;\n padding-bottom: 7px;\n}\n\n.am-grid-5 {\n padding-top: 6px;\n padding-bottom: 7px;\n}\n\n.am-grid-item {\n text-align: center;\n position: relative;\n}\n\n.am-grid-3 .am-grid-border {\n position: absolute;\n left: 0;\n bottom: 0;\n width: 100%;\n height: 100%;\n border-bottom: 1rpx solid #eee;\n border-right: 1rpx solid #eee;\n box-sizing: border-box;\n}\n\n.am-grid-3 .am-grid-right {\n border-right: none;\n}\n\n.am-grid-3 .am-grid-bottom {\n border-bottom: none;\n}\n\n.am-grid-3 .am-grid-top {\n height: calc(100% - 15px);\n}\n\n.am-grid-item-wrapper {\n position: absolute;\n left: 0;\n bottom: 0;\n width: 100%;\n height: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n flex-direction: column;\n}\n\n.am-grid-2 .am-grid-item-wrapper {\n flex-direction: row;\n justify-content: flex-start;\n}\n\n.am-grid-icon-container {\n display: flex;\n justify-content: center;\n align-items: center;\n}\n\n.am-grid-icon {\n flex: 1;\n width: 36px;\n height: 36px;\n}\n\n.am-grid-text-wrapper {\n display: flex;\n flex-direction: column;\n align-items: flex-start;\n}\n\n.am-grid-3 .am-grid-text-wrapper {\n align-items: center;\n}\n\n.am-grid-3 .am-grid-text {\n height: 20px;\n line-height: 20px;\n}\n\n.am-grid-3 .am-grid-desc {\n height: 17px;\n line-height: 17px;\n}\n\n.am-grid-text {\n color: #333;\n font-size: 14px;\n line-height: 1;\n margin-top: 14px;\n}\n\n.am-grid-desc {\n color: #999;\n font-size: 12px;\n}\n\n.am-grid-2 .am-grid-item.has-desc {\n padding-top: 70px;\n}\n\n.am-grid-3 .am-grid-item {\n padding-top: 125px;\n}\n\n.am-grid-3.am-grid-no-line {\n padding: 8px 16px 0 16px;\n}\n\n.am-grid-no-line .am-grid-item {\n padding-top: 110px;\n}\n\n.am-grid-2 .am-grid-item {\n padding-top: 64px;\n}\n\n\n.am-grid-4 .am-grid-item {\n padding-top: 68px;\n}\n\n.am-grid-4.circular .am-grid-item {\n padding-top: 82px;\n}\n\n.am-grid-3 {\n padding: 0 16px;\n}\n\n.am-grid-3 .am-grid-text {\n margin-top: 12px;\n}\n\n.am-grid-no-line .am-grid-border {\n border-right: none;\n border-bottom: none;\n}\n\n.am-grid-4.circular {\n padding-top: 3px;\n}\n\n.am-grid-4.circular .am-grid-icon-container {\n margin-top: 13px;\n padding: 8px;\n border-radius: 50%;\n background-color: #D8D8D8;\n}\n\n.am-grid-2 .am-grid-icon-container {\n margin-left: 16px;\n}\n\n.am-grid-2 .am-grid-icon {\n width: 28px;\n height: 28px;\n}\n\n.am-grid-4 .am-grid-icon-container {\n margin-top: 7px;\n}\n\n.am-grid-4 .am-grid-icon {\n height: 28px;\n width: 28px;\n}\n\n.am-grid-4.circular .am-grid-icon {\n width: 26px;\n height: 26px;\n flex: 1;\n}\n\n.am-grid-4.circular .am-grid-text {\n height: 16px;\n line-height: 16px;\n}\n\n.am-grid-5 .am-grid-item {\n padding-top: 75px;\n}\n\n.am-grid-5 .am-grid-icon {\n border-radius: 50%;\n width: 43px;\n height: 43px;\n}\n\n.am-grid-2 .am-grid-text {\n margin-top: 0;\n margin-left: 12px;\n height: 24px;\n line-height: 24px;\n font-size: 17px;\n}\n\n.am-grid-2 .am-grid-desc {\n margin-left: 12px;\n height: 16px;\n line-height: 16px;\n}\n\n.am-grid-4 .am-grid-text {\n font-size: 13px;\n height: 13px;\n line-height: 13px;\n margin-top: 7px;\n}\n.am-grid-5 .am-grid-text {\n font-size: 12px;\n margin-top: 7px;\n}","page/component/grid/grid.axml":"<view style=\"margin-top: 10px;\" />\n<grid onGridItemClick=\"onItemClick\" columnNum=\"{{3}}\" list=\"{{list3}}\" />\n<view style=\"margin-top: 10px;\" />\n<grid onGridItemClick=\"onItemClick\" columnNum=\"{{3}}\" list=\"{{list1}}\" />\n<view style=\"margin-top: 10px;\" />\n<grid onGridItemClick=\"onItemClick\" columnNum=\"{{3}}\" list=\"{{list3}}\" hasLine=\"{{false}}\" />","page/component/grid/grid.js":"Page({\n data: {\n list1: [\n {\n icon: 'https://gw.alipayobjects.com/zos/rmsportal/VBqNBOiGYkCjqocXjdUj.png',\n text: '标题文字',\n },\n {\n icon: 'https://gw.alipayobjects.com/zos/rmsportal/VBqNBOiGYkCjqocXjdUj.png',\n text: '标题文字',\n },\n {\n icon: 'https://gw.alipayobjects.com/zos/rmsportal/VBqNBOiGYkCjqocXjdUj.png',\n text: '标题文字',\n },\n {\n icon: 'https://gw.alipayobjects.com/zos/rmsportal/VBqNBOiGYkCjqocXjdUj.png',\n text: '标题文字',\n },\n {\n icon: 'https://gw.alipayobjects.com/zos/rmsportal/VBqNBOiGYkCjqocXjdUj.png',\n text: '标题文字',\n },\n {\n icon: 'https://gw.alipayobjects.com/zos/rmsportal/VBqNBOiGYkCjqocXjdUj.png',\n text: '标题文字',\n },\n {\n icon: 'https://gw.alipayobjects.com/zos/rmsportal/VBqNBOiGYkCjqocXjdUj.png',\n text: '标题文字',\n },\n {\n icon: 'https://gw.alipayobjects.com/zos/rmsportal/VBqNBOiGYkCjqocXjdUj.png',\n text: '标题文字',\n },\n {\n icon: 'https://gw.alipayobjects.com/zos/rmsportal/VBqNBOiGYkCjqocXjdUj.png',\n text: '标题文字',\n },\n ],\n list3: [\n {\n icon: 'https://gw.alipayobjects.com/zos/rmsportal/VBqNBOiGYkCjqocXjdUj.png',\n text: '标题文字',\n desc: '描述信息',\n },\n {\n icon: 'https://gw.alipayobjects.com/zos/rmsportal/VBqNBOiGYkCjqocXjdUj.png',\n text: '标题文字',\n desc: '描述信息',\n },\n {\n icon: 'https://gw.alipayobjects.com/zos/rmsportal/VBqNBOiGYkCjqocXjdUj.png',\n text: '标题文字',\n desc: '描述信息',\n },\n {\n icon: 'https://gw.alipayobjects.com/zos/rmsportal/VBqNBOiGYkCjqocXjdUj.png',\n text: '标题文字',\n desc: '描述信息',\n },\n {\n icon: 'https://gw.alipayobjects.com/zos/rmsportal/VBqNBOiGYkCjqocXjdUj.png',\n text: '标题文字',\n desc: '描述信息',\n },\n {\n icon: 'https://gw.alipayobjects.com/zos/rmsportal/VBqNBOiGYkCjqocXjdUj.png',\n text: '标题文字',\n desc: '描述信息',\n },\n {\n icon: 'https://gw.alipayobjects.com/zos/rmsportal/VBqNBOiGYkCjqocXjdUj.png',\n text: '标题文字',\n desc: '描述信息',\n },\n {\n icon: 'https://gw.alipayobjects.com/zos/rmsportal/VBqNBOiGYkCjqocXjdUj.png',\n text: '标题文字',\n desc: '描述信息',\n },\n {\n icon: 'https://gw.alipayobjects.com/zos/rmsportal/VBqNBOiGYkCjqocXjdUj.png',\n text: '标题文字',\n desc: '描述信息',\n },\n ],\n },\n onItemClick(ev) {\n my.alert({\n content: ev.detail.index,\n });\n },\n});","page/component/grid/grid.json":"{\n \"defaultTitle\": \"Grid\",\n \"usingComponents\":{\n \"grid\": \"mini-antui/es/grid/index\"\n }\n}","page/component/icon/icon.acss":".icon-list {\n display: -webkit-flex;\n display: flex;\n -webkit-flex-wrap: wrap;\n flex-wrap: wrap;\n}\n\n.item {\n display: -webkit-flex;\n display: flex;\n flex-direction: column;\n -webkit-flex-direction: column;\n margin-bottom: 10px;\n margin-right: 10px;\n align-items: center;\n -webkit-align-items: center;\n}\n","page/component/icon/icon.axml":"<view class=\"page\">\n <view class=\"page-description\">图标</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">Type</view>\n <view class=\"page-section-demo icon-list\">\n <block a:for=\"{{iconType}}\">\n <view class=\"item\">\n <icon type=\"{{item}}\" aria-label=\"{{item}}\" size=\"45\"/>\n <text>{{item}}</text>\n </view>\n </block>\n </view>\n </view>\n\n <view class=\"page-section\">\n <view class=\"page-section-title\">Size</view>\n <view class=\"page-section-demo icon-list\">\n <block a:for=\"{{iconSize}}\">\n <view class=\"item\">\n <icon type=\"success\" size=\"{{item}}\"/>\n <text>{{item}}</text>\n </view>\n </block>\n </view>\n </view>\n\n <view class=\"page-section\">\n <view class=\"page-section-title\">Color</view>\n <view class=\"page-section-demo icon-list\">\n <block a:for=\"{{iconColor}}\">\n <view class=\"item\">\n <icon type=\"success\" size=\"45\" color=\"{{item}}\"/>\n <text style=\"color:{{item}}\">{{item}}</text>\n </view>\n </block>\n </view>\n </view>\n</view>\n","page/component/icon/icon.js":"Page({\n data: {\n iconSize: [20, 30, 40, 50, 60],\n iconColor: [\n 'red', 'yellow', 'blue', 'green',\n ],\n iconType: [\n 'success',\n 'info',\n 'warn',\n 'waiting',\n 'clear',\n 'success_no_circle',\n 'download',\n 'cancel',\n 'search',\n ],\n },\n});\n","page/component/icon/icon.json":"{\n \"defaultTitle\": \"Icon\"\n}","page/component/image/image.acss":".page-section-demo {\n display: flex;\n justify-content: space-around;\n}\n.image {\n background-color: red;\n width: 100px;\n height: 100px;\n}\n","page/component/image/image.axml":"<view class=\"page\">\n <view class=\"page-description\">图片</view>\n <view class=\"page-section\" a:for=\"{{array}}\" a:for-item=\"item\">\n <view class=\"page-section-title\">{{item.text}}</view>\n <view class=\"page-section-demo\" onTap=\"onTap\">\n <image class=\"image\"\n data-name=\"{{item.mode}}\"\n onTap=\"onTap\"\n mode=\"{{item.mode}}\" src=\"{{src}}\" onError=\"imageError\" onLoad=\"imageLoad\" />\n </view>\n </view>\n</view>\n","page/component/image/image.js":"Page({\n data: {\n array: [\n {\n mode: 'scaleToFill',\n text: 'scaleToFill:不保持纵横比缩放图片,使图片完全适应',\n },\n {\n mode: 'aspectFit',\n text: 'aspectFit:保持纵横比缩放图片,使图片的长边能完全显示出来',\n },\n {\n mode: 'aspectFill',\n text: 'aspectFill:保持纵横比缩放图片,只保证图片的短边能完全显示出来',\n },\n {\n mode: 'widthFix',\n text: 'widthFix:宽度不变,高度自动变化,保持原图宽高比不变',\n },\n {\n mode: 'top',\n text: 'top:不缩放图片,只显示图片的顶部区域',\n },\n {\n mode: 'bottom',\n text: 'bottom:不缩放图片,只显示图片的底部区域',\n },\n {\n mode: 'center',\n text: 'center:不缩放图片,只显示图片的中间区域',\n },\n {\n mode: 'left',\n text: 'left:不缩放图片,只显示图片的左边区域',\n },\n {\n mode: 'right',\n text: 'right:不缩放图片,只显示图片的右边边区域',\n },\n {\n mode: 'top left',\n text: 'top left:不缩放图片,只显示图片的左上边区域',\n },\n {\n mode: 'top right',\n text: 'top right:不缩放图片,只显示图片的右上边区域',\n },\n {\n mode: 'bottom left',\n text: 'bottom left:不缩放图片,只显示图片的左下边区域',\n },\n {\n mode: 'bottom right',\n text: 'bottom right:不缩放图片,只显示图片的右下边区域',\n },\n ],\n src: '/image/taobao.jpg',\n },\n imageError(e) {\n console.log('image 发生 error 事件,携带值为', e.detail.errMsg);\n },\n onTap(e) {\n console.log('image 发生 tap 事件', e);\n },\n imageLoad(e) {\n console.log('image 加载成功', e);\n },\n});\n","page/component/image/image.json":"{\n \"defaultTitle\": \"Image\"\n}","page/component/input-item/input-item.acss":".extra {\n background-image: url('https://gw.alipayobjects.com/zos/rmsportal/dOfSJfWQvYdvsZiJStvg.svg');\n background-size: contain;\n background-repeat: no-repeat;\n background-position: right center;\n opacity: 0.2;\n height: 20px;\n width: 20px;\n padding-left: 10px;\n}","page/component/input-item/input-item.axml":"<view>\n <view style=\"margin-top: 10px;\" />\n <list>\n <input-item\n data-field=\"cardNo\"\n clear=\"{{true}}\"\n value=\"{{cardNo}}\"\n className=\"dadada\"\n placeholder=\"银行卡号\"\n focus=\"{{inputFocus}}\"\n onInput=\"onItemInput\"\n onFocus=\"onItemFocus\"\n onBlur=\"onItemBlur\"\n onConfirm=\"onItemConfirm\"\n onClear=\"onClear\"\n >\n 卡号\n <view slot=\"extra\" class=\"extra\" onTap=\"onExtraTap\"></view>\n </input-item>\n <picker-item\n data-field=\"bank\"\n placeholder=\"选择发卡银行\"\n value=\"{{bank}}\"\n onPickerTap=\"onPickerTap\"\n >\n 发卡银行\n </picker-item>\n <input-item\n data-field=\"name\"\n placeholder=\"姓名\"\n type=\"text\"\n value=\"{{name}}\"\n clear=\"{{true}}\"\n onInput=\"onItemInput\"\n onClear=\"onClear\"\n >\n 姓名\n </input-item>\n <input-item\n data-field=\"password\"\n placeholder=\"密码\"\n password\n >\n 密码\n </input-item>\n <input-item\n data-field=\"remark\"\n placeholder=\"备注\"\n last=\"{{true}}\"\n />\n </list>\n <view style=\"margin: 10px;\">\n <button type=\"primary\" onTap=\"onAutoFocus\">聚焦</button>\n <view>\n</view>","page/component/input-item/input-item.js":"const banks = ['网商银行', '建设银行', '工商银行', '浦发银行'];\n\nPage({\n data: {\n cardNo: '1234****',\n inputFocus: true,\n bank: '',\n name: '',\n },\n onAutoFocus() {\n this.setData({\n inputFocus: true,\n });\n },\n onExtraTap() {\n my.alert({\n content: 'extra tapped',\n });\n },\n onItemInput(e) {\n this.setData({\n [e.target.dataset.field]: e.detail.value,\n });\n },\n onItemFocus() {\n this.setData({\n inputFocus: false,\n });\n },\n onItemBlur() {},\n onItemConfirm() {},\n onClear(e) {\n this.setData({\n [e.target.dataset.field]: '',\n });\n },\n onPickerTap() {\n my.showActionSheet({\n title: '选择发卡银行',\n items: banks,\n success: (res) => {\n this.setData({\n bank: banks[res.index],\n });\n },\n });\n },\n});\n","page/component/input-item/input-item.json":"{\n \"defaultTitle\": \"InputItem\",\n \"usingComponents\": {\n \"list\": \"mini-antui/es/list/index\",\n \"list-item\": \"mini-antui/es/list/list-item/index\",\n \"input-item\": \"mini-antui/es/input-item/index\",\n \"picker-item\": \"mini-antui/es/picker-item/index\"\n }\n}","page/component/input/input.acss":".extra-info {\n border-top: 1px solid #ddd;\n margin-left: 30rpx;\n padding: 20rpx 0;\n overflow: auto;\n}\n\n.search-outer {\n box-sizing: border-box;\n display: flex;\n height: 40px;\n overflow: hidden;\n padding: 8px;\n border-bottom: 1px solid #ddd;\n background-color: #efeff4;\n}\n\n.search-outer * {\n box-sizing: border-box;\n}\n\n.search-input {\n flex: 1;\n text-align: left;\n display: block;\n color: #000;\n height: 24px;\n font-size: 15px;\n background-color: #fff;\n border-color: transparent;\n}\n\n.search-input:focus + .search-cancel {\n margin-right: 0;\n opacity: 1;\n}\n\n.search-cancel {\n margin-right: -40px;\n display: inline-block;\n opacity: 0;\n padding-left: 8px;\n height: 24px;\n line-height: 24px;\n font-size: 16px;\n color: #ff5500;\n text-align: right;\n transition: margin-right 0.3s, opacity 0.3s;\n transition-delay: 0.1s;\n}\n","page/component/input/input.axml":"<view class=\"page\">\n <view class=\"page-description\">输入框</view>\n <view class=\"page-section\">\n <view class=\"form-row\">\n <view class=\"form-row-label\">受控聚焦</view>\n <view class=\"form-row-content\">\n <input class=\"input\" focus=\"{{focus}}\" onFocus=\"onFocus\" onBlur=\"onBlur\" placeholder=\"input something\" />\n </view>\n </view>\n <view class=\"page-section-btns\">\n <button size=\"mini\" onTap=\"bindButtonTap\">聚焦</button>\n </view>\n </view>\n <view class=\"page-section\">\n <view class=\"form-row\">\n <view class=\"form-row-label\"><label for=\"controlled\">显示输入</label></view>\n <view class=\"form-row-content\">\n <input class=\"input\" id=\"controlled\" onInput=\"bindKeyInput\" placeholder=\"show input content\" />\n </view>\n </view>\n <view class=\"extra-info\">你输入的是:{{inputValue}}</view>\n </view>\n <view class=\"page-section\">\n <view class=\"form-row\">\n <view class=\"form-row-label\">最大长度</view>\n <view class=\"form-row-content\">\n <input class=\"input\" maxlength=\"10\" placeholder=\"maxlength 10\" />\n </view>\n </view>\n <view class=\"form-line\" />\n <view class=\"form-row\">\n <view class=\"form-row-label\">收起键盘</view>\n <view class=\"form-row-content\">\n <input class=\"input\" onInput=\"bindHideKeyboard\" placeholder=\"输入 123 自动收起键盘\" />\n </view>\n </view>\n <view class=\"form-line\" />\n <view class=\"form-row\">\n <view class=\"form-row-label\">输入密码</view>\n <view class=\"form-row-content\">\n <input class=\"input\" password type=\"text\" placeholder=\"密码输入框\" />\n </view>\n </view>\n <view class=\"form-line\" />\n <view class=\"form-row\">\n <view class=\"form-row-label\">输入数字</view>\n <view class=\"form-row-content\">\n <input class=\"input\" type=\"number\" placeholder=\"数字输入框\" />\n </view>\n </view>\n <view class=\"form-line\" />\n <view class=\"form-row\">\n <view class=\"form-row-label\">小数点键盘</view>\n <view class=\"form-row-content\">\n <input class=\"input\" type=\"digit\" placeholder=\"带小数点的数字键盘\" />\n </view>\n </view>\n <view class=\"form-line\" />\n <view class=\"form-row\">\n <view class=\"form-row-label\">身份证键盘</view>\n <view class=\"form-row-content\">\n <input class=\"input\" type=\"idcard\" placeholder=\"身份证输入键盘\" />\n </view>\n </view>\n </view>\n\n\n <view class=\"page-section\">\n <view class=\"page-section-title\">搜索框</view>\n <view class=\"page-section-demo\">\n <view class=\"search-outer\">\n <input\n class=\"search-input\"\n placeholder=\"搜索\"\n value=\"{{search}}\"\n onConfirm=\"doneSearch\"\n onInput=\"handleSearch\"\n />\n <text class=\"search-cancel\" onTap=\"clearSearch\">取消</text>\n </view>\n </view>\n </view>\n</view>\n","page/component/input/input.js":"Page({\n data: {\n focus: false,\n inputValue: '',\n },\n\n bindButtonTap() {\n // blur 事件和这个冲突\n setTimeout(() => {\n this.onFocus();\n }, 100);\n },\n onFocus() {\n this.setData({\n focus: true,\n });\n },\n onBlur() {\n this.setData({\n focus: false,\n });\n },\n\n bindKeyInput(e) {\n this.setData({\n inputValue: e.detail.value,\n });\n },\n\n bindHideKeyboard(e) {\n if (e.detail.value === '123') {\n // 收起键盘\n my.hideKeyboard();\n }\n },\n\n handleSearch(e) {\n console.log('search', e.detail.value);\n this.setData({\n search: e.detail.value,\n });\n },\n doneSearch() {\n console.log('doneSearch', this.data.search);\n my.hideKeyboard();\n },\n clearSearch() {\n console.log('clear search', this.data.search);\n this.setData({\n search: '',\n });\n },\n});\n","page/component/input/input.json":"{\n \"defaultTitle\": \"Input\"\n}","page/component/label/label.acss":"checkbox-group > view,\nradio-group > view {\n margin-bottom: 12rpx;\n}","page/component/label/label.axml":"<view class=\"page\">\n <view class=\"page-section\">\n <view class=\"page-section-title\">Checkbox</view>\n <view class=\"page-section-demo\">\n <checkbox-group>\n <view>\n <label>\n <checkbox value=\"AngularJS\" />\n <text> AngularJS</text>\n </label>\n </view>\n <view>\n <label>\n <checkbox value=\"React\" />\n <text> React</text>\n </label>\n </view>\n </checkbox-group>\n </view>\n </view>\n\n <view class=\"page-section\">\n <view class=\"page-section-title\">Radio</view>\n <view class=\"page-section-demo\">\n <radio-group>\n <view>\n <radio id=\"AngularJS\" value=\"AngularJS\" />\n <label for=\"AngularJS\">AngularJS</label>\n </view>\n <view>\n <radio id=\"React\" value=\"React\" />\n <label for=\"React\">React</label>\n </view>\n </radio-group>\n </view>\n </view>\n\n <view class=\"page-section\">\n <view class=\"page-section-title\">label中有多个 Checkbox ,点击后只选中一个</view>\n <view class=\"page-section-demo\">\n <label>\n <checkbox>选中我</checkbox>\n <checkbox>选不中</checkbox>\n <checkbox>选不中</checkbox>\n <checkbox>选不中</checkbox>\n <view>\n <text>Click Me</text>\n </view>\n </label>\n </view>\n </view>\n</view>\n","page/component/label/label.js":"\nPage({\n data: {},\n});\n","page/component/label/label.json":"{\n \"defaultTitle\": \"Label\"\n}","page/component/lifestyle/lifestyle.axml":"<view>\n <lifestyle a:if=\"{{canUse}}\" publicId='2016021701146995'/>\n <view a:else>请升级淘宝支持生活号跳转</view>\n</view>\n","page/component/lifestyle/lifestyle.js":"Page({\n data:{\n canUse: my.canIUse('lifestyle'),\n }\n});\n","page/component/lifestyle/lifestyle.json":"{\n \"defaultTitle\": \"跳转到生活号\"\n}","page/component/list/list.acss":".dyt-list {\n margin-top: 0;\n}\n.dyt-list .am-list-item-thumb {\n border-radius: 5px;\n}\n.dyt-list .am-list-brief {\n color: #909090;\n}\n\n.dyt-list .am-list-extra {\n color: #000;\n}\n\n.am-list-sticky {\n position: sticky;\n top: 0;\n background-color: #fff;\n z-index: 2;\n}","page/component/list/list.axml":"<view>\n\t<scroll-view style=\"height: 100vh;\" scroll-y onScrollToLower=\"onScrollToLower\">\n\t\t<list>\n\t\t\t<view slot=\"header\">\n\t\t\t\t列表头部\n\t\t\t</view>\n\t\t\t<block a:for=\"{{items}}\">\n\t\t\t\t<list-item\n\t\t\t\t\tthumb=\"{{item.thumb}}\"\n\t\t\t\t\tarrow=\"{{item.arrow}}\"\n\t\t\t\t\talign=\"{{item.align}}\"\n\t\t\t\t\tindex=\"{{index}}\"\n\t\t\t\t\tonClick=\"onItemClick\"\n\t\t\t\t\tkey=\"items-{{index}}\"\n\t\t\t\t\tlast=\"{{index === (items.length - 1)}}\"\n\t\t\t\t>\n\t\t\t\t\t{{item.title}}\n\t\t\t\t\t<view class=\"am-list-brief\">{{item.brief}}</view>\n\t\t\t\t\t<view slot=\"extra\">\n\t\t\t\t\t\t{{item.extra}}\n\t\t\t\t\t</view>\n\t\t\t </list-item>\n\t\t\t</block>\n\t\t\t<view slot=\"footer\">\n\t\t\t\t列表尾部\n\t\t\t</view>\n\t\t</list>\n\t\t<list>\n\t\t\t<view slot=\"header\">\n\t\t\t\t列表头部\n\t\t\t</view>\n\t\t\t<block a:for=\"{{items2}}\">\n\t\t\t\t<list-item\n\t\t\t\t\tthumb=\"{{item.thumb}}\"\n\t\t\t\t\tarrow=\"{{item.arrow}}\"\n\t\t\t\t\tonClick=\"onItemClick\"\n\t\t\t\t\tindex=\"items2-{{index}}\"\n\t\t\t\t\tkey=\"items2-{{index}}\"\n\t\t\t\t\tlast=\"{{index === (items2.length - 1)}}\"\n\t\t\t\t>\n\t\t\t\t\t{{item.title}}\n\t\t\t\t\t<view class=\"am-list-brief\">{{item.brief}}</view>\n\t\t\t\t\t<view a:if=\"{{item.extra}}\" slot=\"extra\">\n\t\t\t\t\t\t{{item.extra}}\n\t\t\t\t\t</view>\n\t\t\t\t</list-item>\n\t\t\t</block>\n\t\t\t<view slot=\"footer\">\n\t\t\t\t列表尾部\n\t\t\t</view>\n\t\t</list>\n\t\t<list>\n\t\t\t<view slot=\"header\">\n\t\t\t\t列表头部\n\t\t\t</view>\n\t\t\t<block a:for=\"{{items3}}\">\n\t\t\t\t<list-item\n\t\t\t\t\tthumb=\"{{item.thumb}}\"\n\t\t\t\t\tarrow=\"{{item.arrow}}\"\n\t\t\t\t\tindex=\"items3-{{index}}\"\n\t\t\t\t\tonClick=\"onItemClick\"\n\t\t\t\t\tkey=\"items3-{{index}}\"\n\t\t\t\t\tlast=\"{{index === (items3.length - 1)}}\"\n\t\t\t\t\tmultipleLine=\"{{true}}\"\n\t\t\t\t>\n\t\t\t\t\t{{item.title}}\n\t\t\t\t\t<view class=\"am-list-brief\">{{item.brief}}</view>\n\t\t\t\t\t<view a:if=\"{{item.extra}}\" slot=\"extra\">\n\t\t\t\t\t\t{{item.extra}}\n\t\t\t\t\t</view>\n\t\t\t\t</list-item>\n\t\t\t</block>\n\t\t\t<view slot=\"footer\">\n\t\t\t\t列表尾部\n\t\t\t</view>\n\t\t</list>\n\t\t<list>\n\t\t\t<view slot=\"header\">\n\t\t\t\t列表头部\n\t\t\t</view>\n\t\t\t<block a:for=\"{{items4}}\">\n\t\t\t\t<list-item\n\t\t\t\t\tthumb=\"{{item.thumb}}\"\n\t\t\t\t\tarrow=\"{{item.arrow}}\"\n\t\t\t\t\tonClick=\"onItemClick\"\n\t\t\t\t\tindex=\"items4-{{index}}\"\n\t\t\t\t\tlast=\"{{index === (items4.length - 1)}}\"\n\t\t\t\t\tkey=\"items4-{{index}}\"\n\t\t\t\t\tmultipleLine=\"{{true}}\"\n\t\t\t\t>\n\t\t\t\t\t{{item.title}}\n\t\t\t\t\t<view class=\"am-list-brief\">{{item.brief}}</view>\n\t\t\t\t\t<view a:if=\"{{item.extra}}\" slot=\"extra\">\n\t\t\t\t\t\t{{item.extra}}\n\t\t\t\t\t</view>\n\t\t\t\t</list-item>\n\t\t\t</block>\n\t\t\t<view slot=\"footer\">\n\t\t\t\t列表尾部\n\t\t\t</view>\n\t\t</list>\n\t\t<list>\n\t\t\t<view slot=\"header\">\n\t\t\t\t小图文列表\n\t\t\t</view>\n\t\t\t<block a:for=\"{{itemsThumb}}\">\n\t\t\t\t<list-item\n\t\t\t\t\tthumb=\"{{item.thumb}}\"\n\t\t\t\t\tarrow=\"{{item.arrow}}\"\n\t\t\t\t\tonClick=\"onItemClick\"\n\t\t\t\t\tindex=\"itemsThumb-{{index}}\"\n\t\t\t\t\tlast=\"{{index === (itemsThumb.length - 1)}}\"\n\t\t\t\t\tkey=\"itemsThumb-{{index}}\"\n\t\t\t\t>\n\t\t\t\t\t{{item.title}}\n\t\t\t\t\t<view class=\"am-list-brief\">{{item.brief}}</view>\n\t\t\t\t\t<view a:if=\"{{item.extra}}\" slot=\"extra\">\n\t\t\t\t\t\t{{item.extra}}\n\t\t\t\t\t</view>\n\t\t\t\t</list-item>\n\t\t\t</block>\n\t\t</list>\n\t\t<list>\n\t\t\t<view slot=\"header\">\n\t\t\t\t小图文双行列表\n\t\t\t</view>\n\t\t\t<block a:for=\"{{itemsThumbMultiple}}\">\n\t\t\t\t<list-item\n\t\t\t\t\tthumb=\"{{item.thumb}}\"\n\t\t\t\t\tarrow=\"{{item.arrow}}\"\n\t\t\t\t\tonClick=\"onItemClick\"\n\t\t\t\t\tindex=\"items-multiple-{{index}}\"\n\t\t\t\t\tlast=\"{{index === (itemsThumbMultiple.length - 1)}}\"\n\t\t\t\t\tkey=\"items-multiple-{{index}}\"\n\t\t\t\t\tmultipleLine=\"{{true}}\"\n\t\t\t\t>\n\t\t\t\t\t{{item.title}}\n\t\t\t\t\t<view class=\"am-list-brief\">{{item.brief}}</view>\n\t\t\t\t\t<view a:if=\"{{item.extra}}\" slot=\"extra\">\n\t\t\t\t\t\t{{item.extra}}\n\t\t\t\t\t</view>\n\t\t\t\t</list-item>\n\t\t\t</block>\n\t\t</list>\n\t\t<list >\n\t\t\t<view slot=\"header\">\n\t\t\t\t无限滚动列表\n\t\t\t</view>\n\t\t\t<block a:for=\"{{items5}}\">\n\t\t\t\t<list-item\n\t\t\t\t\tclassName=\"{{item.sticky ? 'am-list-sticky' : ''}}\"\n\t\t\t\t\tthumb=\"{{item.thumb}}\"\n\t\t\t\t\tarrow=\"{{item.arrow}}\"\n\t\t\t\t\talign=\"{{item.align}}\"\n\t\t\t\t\tlast=\"{{index === (items5.length - 1)}}\"\n\t\t\t\t\tindex=\"{{index}}\"\n\t\t\t\t\tkey=\"items5-{{index}}\"\n\t\t\t\t\tonClick=\"onItemClick\"\n\t\t\t\t\tdisabled=\"{{item.sticky}}\"\n\t\t\t\t\twrap=\"{{true}}\"\n\t\t\t\t>\n\t\t\t\t\t{{item.title}}{{index}}\n\t\t\t\t\t<view a:if=\"{{item.extra}}\" slot=\"extra\">\n\t\t\t\t\t\t{{item.extra}}\n\t\t\t\t\t</view>\n\t\t\t\t</list-item>\n\t\t\t</block>\n\t\t\t<view slot=\"footer\">\n\t\t\t\t列表尾部\n\t\t\t</view>\n\t\t</list>\n\t</scroll-view>\n</view>\n\n\n","page/component/list/list.js":"\nconst newitems = [\n {\n thumb: 'https://gw.alipayobjects.com/zos/rmsportal/KXDIRejMrRdKlSEcLseB.png',\n title: '固定到头部',\n arrow: true,\n sticky: true,\n },\n {\n title: '标题文字不换行很长很长很长很长很长很长很长很长很长很长',\n arrow: true,\n },\n {\n title: '标题文字换行很长很长很长很长很长很长很长很长很长很长',\n arrow: true,\n textMode: 'wrap',\n },\n {\n title: '标题文字很长很长很长很长很长很长很长很长很长很长很长很长很长很长',\n extra: '没有箭头',\n textMode: 'wrap',\n },\n {\n title: '标题文字很长很长很长很长很长很长很长很长很长很长很长很长很长很长',\n extra: '子元素垂直对齐',\n textMode: 'wrap',\n align: 'top',\n },\n {\n title: '标题文字换行很长很长很长很长很长很长很长很长很长很长',\n arrow: true,\n textMode: 'wrap',\n },\n {\n title: '标题文字很长很长很长很长很长很长很长很长很长很长很长很长很长很长',\n extra: '没有箭头',\n textMode: 'wrap',\n },\n {\n title: '标题文字很长很长很长很长很长很长很长很长很长很长很长很长很长很长',\n extra: '子元素垂直对齐',\n textMode: 'wrap',\n align: 'top',\n },\n {\n title: '标题文字换行很长很长很长很长很长很长很长很长很长很长',\n arrow: true,\n textMode: 'wrap',\n },\n {\n title: '标题文字很长很长很长很长很长很长很长很长很长很长很长很长很长很长',\n extra: '没有箭头',\n textMode: 'wrap',\n },\n {\n title: '标题文字很长很长很长很长很长很长很长很长很长很长很长很长很长很长',\n extra: '子元素垂直对齐',\n textMode: 'wrap',\n align: 'top',\n },\n {\n title: '标题文字换行很长很长很长很长很长很长很长很长很长很长',\n arrow: true,\n textMode: 'wrap',\n },\n {\n title: '标题文字很长很长很长很长很长很长很长很长很长很长很长很长很长很长',\n extra: '没有箭头',\n textMode: 'wrap',\n },\n {\n title: '标题文字很长很长很长很长很长很长很长很长很长很长很长很长很长很长',\n extra: '子元素垂直对齐',\n textMode: 'wrap',\n align: 'top',\n },\n];\nPage({\n data: {\n items: [\n {\n title: '单行列表',\n extra: '详细信息',\n },\n ],\n items2: [\n {\n title: '多行列表',\n arrow: true,\n },\n {\n title: '多行列表',\n arrow: 'up',\n },\n {\n title: '多行列表',\n arrow: 'down',\n },\n {\n title: '多行列表',\n arrow: 'empty',\n },\n {\n title: '多行列表',\n },\n ],\n items3: [\n {\n title: '双行列表',\n brief: '描述信息',\n arrow: true,\n },\n ],\n items4: [\n {\n title: '双行列表',\n brief: '描述信息',\n arrow: true,\n },\n {\n title: '双行列表',\n brief: '描述信息',\n arrow: true,\n },\n {\n title: '双行列表',\n brief: '描述信息',\n arrow: true,\n },\n ],\n itemsThumb: [\n {\n thumb: 'https://tfsimg.alipay.com/images/partner/T12rhxXkxcXXXXXXXX',\n title: '标题文字',\n extra: '描述文字',\n arrow: true,\n },\n {\n thumb: 'https://tfsimg.alipay.com/images/partner/T12rhxXkxcXXXXXXXX',\n title: '标题文字',\n arrow: true,\n },\n {\n thumb: 'https://tfsimg.alipay.com/images/partner/T12rhxXkxcXXXXXXXX',\n title: '标题文字',\n arrow: true,\n },\n ],\n itemsThumbMultiple: [\n {\n thumb: 'https://tfsimg.alipay.com/images/partner/T12rhxXkxcXXXXXXXX',\n title: '标题文字',\n brief: '描述信息',\n },\n {\n thumb: 'https://tfsimg.alipay.com/images/partner/T12rhxXkxcXXXXXXXX',\n title: '标题文字',\n },\n {\n thumb: 'https://tfsimg.alipay.com/images/partner/T12rhxXkxcXXXXXXXX',\n title: '标题文字',\n },\n ],\n items5: [\n {\n thumb: 'https://gw.alipayobjects.com/zos/rmsportal/KXDIRejMrRdKlSEcLseB.png',\n title: '固定到头部',\n brief: '描述信息',\n arrow: true,\n sticky: true,\n },\n {\n title: '标题文字不换行很长很长很长很长很长很长很长很长很长很长',\n arrow: true,\n align: 'middle',\n },\n {\n title: '标题文字换行很长很长很长很长很长很长很长很长很长很长',\n arrow: true,\n align: 'top',\n },\n {\n title: '标题文字很长很长很长很长很长很长很长很长很长很长很长很长很长很长',\n extra: '没有箭头',\n align: 'bottom',\n },\n {\n title: '标题文字很长很长很长很长很长很长很长很长很长很长很长很长很长很长',\n extra: '子元素垂直对齐',\n align: 'top',\n },\n {\n title: '标题文字换行很长很长很长很长很长很长很长很长很长很长',\n arrow: true,\n },\n {\n title: '标题文字很长很长很长很长很长很长很长很长很长很长很长很长很长很长',\n extra: '没有箭头',\n },\n {\n title: '标题文字很长很长很长很长很长很长很长很长很长很长很长很长很长很长',\n extra: '子元素垂直对齐',\n align: 'top',\n },\n {\n title: '标题文字换行很长很长很长很长很长很长很长很长很长很长',\n arrow: true,\n },\n {\n title: '标题文字很长很长很长很长很长很长很长很长很长很长很长很长很长很长',\n extra: '没有箭头',\n },\n {\n title: '标题文字很长很长很长很长很长很长很长很长很长很长很长很长很长很长',\n extra: '子元素垂直对齐',\n align: 'top',\n },\n {\n title: '标题文字换行很长很长很长很长很长很长很长很长很长很长',\n arrow: true,\n },\n {\n title: '标题文字很长很长很长很长很长很长很长很长很长很长很长很长很长很长',\n extra: '没有箭头',\n },\n {\n title: '标题文字很长很长很长很长很长很长很长很长很长很长很长很长很长很长',\n extra: '子元素垂直对齐',\n align: 'middle',\n },\n ],\n },\n onItemClick(ev) {\n my.alert({\n content: `点击了第${ev.index}行`,\n });\n },\n onScrollToLower() {\n const { items5 } = this.data;\n const newItems = items5.concat(newitems);\n console.log(newItems.length);\n this.setData({\n items5: newItems,\n });\n },\n});\n","page/component/list/list.json":"{\n \"defaultTitle\": \"List\",\n \"usingComponents\":{\n \"list\": \"mini-antui/es/list/index\",\n \"list-item\": \"mini-antui/es/list/list-item/index\"\n }\n}","page/component/map/map.axml":"<view class=\"page\">\n <view class=\"page-section\">\n <view class=\"page-section-demo\">\n <map\n id=\"map\"\n longitude=\"{{longitude}}\"\n latitude=\"{{latitude}}\"\n scale=\"{{scale}}\"\n controls=\"{{controls}}\"\n onControlTap=\"controltap\"\n markers=\"{{markers}}\"\n onMarkerTap=\"markertap\"\n polyline=\"{{polyline}}\"\n polygon=\"{{polygon}}\"\n circles=\"{{circles}}\"\n onRegionChange=\"regionchange\"\n onTap=\"tap\"\n onCalloutTap=\"callouttap\"\n show-location style=\"width: 100%; height: 200px;\"\n include-points=\"{{includePoints}}\"\n ground-overlays=\"{{ground-overlays}}\">\n </map>\n </view>\n </view>\u001b\n <view class=\"page-section-btns\">\n <view onTap=\"demoResetMap\">恢复</view>\n <view onTap=\"demoGetCenterLocation\">获取中心点坐标</view>\n <view onTap=\"demoMoveToLocation\">回到定位点</view>\n </view>\n <view class=\"page-section-btns\">\n <view onTap=\"demoMarkerAnimation\">Marker 动画</view>\n <view onTap=\"demoMarkerLabel\">Label</view>\n <view onTap=\"demoMarkerCustomCallout\">CustomCallout</view>\n </view>\n <view class=\"page-section-btns\">\n <view onTap=\"demoMarkerAppendStr\">文字Marker</view>\n <view onTap=\"demoTrafficOverlay\">路况展示</view>\n <view onTap=\"demoShowRoute\">步行路线规划</view>\n </view>\n <view class=\"page-section-btns\">\n <view onTap=\"demoCompass\">指南针</view>\n <view onTap=\"demoScale\">比例尺</view>\n <view onTap=\"demoGesture\">手势</view>\n </view>\n <view class=\"page-section-btns\">\n <view onTap=\"demoPolyline\">线</view>\n <view onTap=\"demoPolygon\">多边形</view>\n <view onTap=\"demoCircle\">圆</view>\n </view>\n <view class=\"page-section-btns\">\n </view>\n</view>\n","page/component/map/map.js":"const markers = [\n {\n id: 0,\n latitude: 30.266786,\n longitude: 120.10675,\n width: 19,\n height: 31,\n iconPath: '/image/mark_bs.png',\n callout: {\n content: 'callout',\n },\n },\n];\n\nconst animMarker = [\n {\n id: 1,\n latitude: 30.266786,\n longitude: 120.10675,\n width: 19,\n height: 31,\n\n iconPath: '/image/mark_bs.png',\n\n fixedPoint: {\n originX: 200,\n originY: 150,\n },\n markerLevel: 2,\n },\n];\n\nconst labelMarker = [\n {\n id: 2,\n latitude: 30.266786,\n longitude: 120.10675,\n width: 19,\n height: 31,\n iconPath: '/image/mark_bs.png',\n label: {\n content: 'Hello Label',\n color: '#00FF00',\n fontSize: 14,\n borderRadius: 3,\n bgColor: '#ffffff',\n padding: 10,\n },\n markerLevel: 2,\n },\n];\nconst customCalloutMarker = [\n {\n id: 3,\n latitude: 30.266786,\n longitude: 120.10675,\n width: 19,\n height: 31,\n iconPath: '/image/mark_bs.png',\n customCallout: {\n type: 2,\n descList: [\n {\n desc: '预计',\n descColor: '#333333',\n },\n {\n desc: '5分钟',\n descColor: '#ff5500',\n },\n {\n desc: '到达',\n descColor: '#333333',\n },\n ],\n isShow: 1,\n },\n markerLevel: 2,\n },\n];\n\nconst iconAppendStrMarker = [\n {\n id: 34,\n latitude: 30.266786,\n longitude: 120.10675,\n width: 19,\n height: 31,\n iconAppendStr: 'iconAppendStr',\n markerLevel: 2,\n },\n];\n\nvar myTrafficEnabled = 0;\nvar myCompassEnabled = 0;\nvar myScaleEnabled = 0;\nvar myGestureEnabled = 0;\n\nconst longitude = 120.10675;\nconst latitude = 30.266786;\nconst includePoints = [\n {\n latitude: 30.266786,\n longitude: 120.10675,\n },\n];\n\nPage({\n data: {\n scale: 14,\n longitude,\n latitude,\n includePoints,\n },\n onReady() {\n // 使用 my.createMapContext 获取 map 上下文\n this.mapCtx = my.createMapContext('map');\n },\n demoResetMap() {\n this.setData({\n scale: 14,\n longitude,\n latitude,\n includePoints,\n 'ground-overlays': [],\n circles: [],\n polygon: [],\n polyline: [],\n });\n this.mapCtx.clearRoute();\n },\n demoGetCenterLocation() {\n this.mapCtx.getCenterLocation({\n success: res => {\n my.alert({\n content:\n 'longitude:' +\n res.longitude +\n '\\nlatitude:' +\n res.latitude +\n '\\nscale:' +\n res.scale,\n });\n console.log(res.longitude);\n console.log(res.latitude);\n console.log(res.scale);\n },\n });\n },\n demoMoveToLocation() {\n this.mapCtx.moveToLocation();\n },\n demoMarkerAnimation() {\n if (!my.canIUse('createMapContext.return.updateComponents')) {\n my.alert({\n title: '\b\b客户端版本过低',\n content: 'this.mapCtx.updateComponents 需要\b 10.1.35 \b及以上版本',\n });\n return;\n }\n this.mapCtx.updateComponents({\n markers: animMarker,\n });\n this.mapCtx.updateComponents({\n command: {\n markerAnim: [{ markerId: 1, type: 0 }],\n },\n });\n },\n demoMarkerLabel() {\n if (!my.canIUse('createMapContext.return.updateComponents')) {\n my.alert({\n title: '\b\b客户端版本过低',\n content: 'this.mapCtx.updateComponents 需要\b 10.1.35 \b及以上版本',\n });\n return;\n }\n this.mapCtx.updateComponents({\n scale: 14,\n longitude,\n latitude,\n includePoints,\n markers: labelMarker,\n });\n },\n demoMarkerCustomCallout() {\n this.mapCtx.updateComponents({\n scale: 14,\n longitude,\n latitude,\n includePoints,\n markers: customCalloutMarker,\n });\n },\n demoMarkerAppendStr() {\n this.mapCtx.updateComponents({\n scale: 14,\n longitude,\n latitude,\n includePoints,\n markers: iconAppendStrMarker,\n });\n },\n demoTrafficOverlay() {\n if (!my.canIUse('createMapContext.return.updateComponents')) {\n my.alert({\n title: '\b\b客户端版本过低',\n content: 'this.mapCtx.updateComponents 需要\b 10.1.35 \b及以上版本',\n });\n return;\n }\n myTrafficEnabled = (myTrafficEnabled + 1) % 2;\n this.mapCtx.updateComponents({\n setting: { trafficEnabled: myTrafficEnabled },\n });\n },\n demoShowRoute() {\n this.mapCtx.showRoute({\n startLat: 30.257839,\n startLng: 120.062726,\n endLat: 30.256718,\n endLng: 120.059985,\n zIndex: 4,\n routeColor: '#FFB90F',\n iconPath: '/image/map_alr.png',\n iconWidth: 10,\n routeWidth: 10,\n });\n },\n demoCompass() {\n myCompassEnabled = (myCompassEnabled + 1) % 2;\n this.mapCtx.showsCompass({ isShowsCompass: myCompassEnabled });\n },\n demoScale() {\n myScaleEnabled = (myScaleEnabled + 1) % 2;\n this.mapCtx.showsScale({ isShowsScale: myScaleEnabled });\n },\n demoGesture() {\n myGestureEnabled = (myGestureEnabled + 1) % 2;\n this.mapCtx.gestureEnable({ isGestureEnable: myGestureEnabled });\n },\n demoPolyline() {\n this.setData({\n scale: 16,\n longitude,\n latitude,\n polyline: [\n {\n points: [\n {\n // 右上\n latitude: 30.264786,\n longitude: 120.10775,\n },\n {\n // 左下\n latitude: 30.268786,\n longitude: 120.10575,\n },\n ],\n color: '#FF0000DD',\n width: 10,\n dottedLine: false,\n iconPath: '/image/map_alr.png',\n iconWidth: 10,\n },\n ],\n });\n },\n demoPolygon() {\n this.setData({\n scale: 16,\n longitude,\n latitude,\n polygon: [\n {\n points: [\n {\n // 右上\n latitude: 30.264786,\n longitude: 120.10775,\n },\n {\n // 右下\n latitude: 30.268786,\n longitude: 120.10775,\n },\n {\n // 左下\n latitude: 30.268786,\n longitude: 120.10575,\n },\n {\n // 左上\n latitude: 30.264786,\n longitude: 120.10575,\n },\n ],\n fillColor: '#BB0000DD',\n width: 5,\n },\n ],\n });\n },\n demoCircle() {\n this.setData({\n scale: 16,\n longitude,\n latitude,\n circles: [\n {\n longitude,\n latitude,\n color: '#BB76FF88',\n fillColor: '#BB76FF33',\n radius: 100,\n strokeWidth: 3,\n },\n ],\n });\n },\n regionchange(e) {\n console.log('regionchange', e);\n },\n markertap(e) {\n console.log('marker tap', e);\n },\n controltap(e) {\n console.log('control tap', e);\n },\n tap() {\n console.log('tap');\n },\n callouttap(e) {\n console.log('callout tap', e);\n },\n});\n","page/component/map/map.json":"{\n \"defaultTitle\": \"Map\"\n}\n","page/component/message/message.acss":"/* required by usingComponents */","page/component/message/message.axml":"<view>\n <message\n title=\"{{title}}\"\n subTitle=\"{{subTitle}}\"\n type=\"success\" \n mainButton=\"{{messageButton.mainButton}}\" \n subButton=\"{{messageButton.subButton}}\" \n onTapMain=\"goBack\">\n </message>\n</view>","page/component/message/message.js":"Page({\n data: {\n title: \"操作成功\",\n subTitle: \"内容详情可折行,建议不超过两行\",\n messageButton: {\n mainButton: {\n buttonText: \"主要操作\"\n },\n subButton: {\n buttonText: \"辅助操作\"\n }\n }\n },\n goBack() {\n my.navigateBack();\n }\n});","page/component/message/message.json":"{\n \"defaultTitle\": \"Message\",\n \"usingComponents\":{\n \"message\": \"mini-antui/es/message/index\"\n }\n}","page/component/modal/modal.acss":"","page/component/modal/modal.axml":"\n<view>\n\t<view style=\"margin-top: 10px;\" />\n\t<button onTap=\"openModal21\" style=\"margin: 0 10px;\">带图弹窗</button>\n\t<view style=\"margin-top: 10px;\" />\n\t<button onTap=\"openModal22\" style=\"margin: 0 10px;\">带图弹窗-小图</button>\n\t<view style=\"margin-top: 10px;\" />\n\t<button onTap=\"openModal2\" style=\"margin: 0 10px;\">带图弹窗-大图</button>\n\t<view style=\"margin-top: 10px;\" />\n\t<button onTap=\"openModal\" style=\"margin: 0 10px;\">通用modal</button>\n\t<view style=\"margin-top: 10px;\" />\n\t<button onTap=\"openModal3\" style=\"margin: 0 10px;\">运营活动弹窗-大</button>\n\t<view style=\"margin-top: 10px;\" />\n\t<button onTap=\"openModal4\" style=\"margin: 0 10px;\">运营活动弹窗-小</button>\n\t<modal\n\t\tshow=\"{{modalOpened21}}\"\n\t\tonModalClick=\"onModalClick21\"\n\t\tonModalClose=\"onModalClose21\"\n\t\ttopImage=\"https://gw.alipayobjects.com/zos/rmsportal/yFeFExbGpDxvDYnKHcrs.png\"\n\t>\n\t\t<view slot=\"header\">标题单行</view>\n\t\t说明当前状态、提示用户解决方案,最好不要超过两行。\n\t\t<view slot=\"footer\">确定</view>\n\t</modal>\n\t<modal\n\t\tshow=\"{{modalOpened2}}\"\n\t\tonModalClick=\"onModalClick2\"\n\t\tonModalClose=\"onModalClose2\"\n\t\ttopImage=\"https://gw.alipayobjects.com/zos/rmsportal/yFeFExbGpDxvDYnKHcrs.png\"\n\t\ttopImageSize=\"lg\"\n\t\tcloseType=\"1\"\n\t>\n\t\t<view slot=\"header\">标题单行</view>\n\t\t说明当前状态、提示用户解决方案,最好不要超过两行。\n\t\t<view slot=\"footer\">确定</view>\n\t</modal>\n\t<modal\n\t\tshow=\"{{modalOpened22}}\"\n\t\tonModalClick=\"onModalClick22\"\n\t\tonModalClose=\"onModalClose22\"\n\t\ttopImage=\"https://gw.alipayobjects.com/zos/rmsportal/yFeFExbGpDxvDYnKHcrs.png\"\n\t\ttopImageSize=\"sm\"\n\t>\n\t\t<view slot=\"header\">标题单行</view>\n\t\t说明当前状态、提示用户解决方案,最好不要超过两行。\n\t\t<view slot=\"footer\">确定</view>\n\t</modal>\n\t<modal\n\t\tshow=\"{{modalOpened}}\"\n\t\tonModalClick=\"onModalClick\"\n\t\tonModalClose=\"onModalClose\"\n\t>\n\t\t<view style=\"margin: 20px 0 10px 0;\">扫一扫登录</view>\n\t\t<image mode=\"widthFix\" style=\"width: 100%;\" src=\"https://img.alicdn.com/imgextra/O1CN0172T1Su2B2Hxg1v5IJ_!!8280-2-xcode.png\" />\n\t\t二维码每分钟自动更新\n\t\t<view slot=\"footer\">确定</view>\n\t</modal>\n\t<modal\n\t\tshow=\"{{modalOpened3}}\"\n\t\tonModalClose=\"onModalClick3\"\n\t\tadvice=\"{{true}}\"\n\t\t>\n\t\t<view style=\"display: flex; height: 465px; width: 319px;\">\n\t\t\t<image\n\t\t\t\tstyle=\"height: 465px;width: 319px;\"\n\t\t\t\tsrc=\"https://gw.alipayobjects.com/zos/rmsportal/vJzAWQLgeDLGOMKiIgZt.png\"\n\t\t\t/>\n\t\t</view>\n\t</modal>\n\t<modal\n\t\tshow=\"{{modalOpened4}}\"\n\t\tonModalClose=\"onModalClick4\"\n\t\tadvice=\"{{true}}\"\n\t\t>\n\t\t<view style=\"display: flex; width: 270px; height: 350px;\">\n\t\t\t<image\n\t\t\t\tstyle=\"width: 270px;height: 350px;\"\n\t\t\t\tsrc=\"https://gw.alipayobjects.com/zos/rmsportal/vJzAWQLgeDLGOMKiIgZt.png\"\n\t\t\t/>\n\t\t</view>\n\t</modal>\n</view>","page/component/modal/modal.js":"Page({\n data: {\n modalOpened: false,\n modalOpened2: false,\n modalOpened21: false,\n modalOpened22: false,\n modalOpened3: false,\n modalOpened4: false,\n },\n openModal() {\n this.setData({\n modalOpened: true,\n });\n },\n onModalClick() {\n this.setData({\n modalOpened: false,\n });\n },\n onModalClose() {\n this.setData({\n modalOpened: false,\n });\n },\n openModal2() {\n this.setData({\n modalOpened2: true,\n });\n },\n onModalClick2() {\n this.setData({\n modalOpened2: false,\n });\n },\n onModalClose2() {\n this.setData({\n modalOpened2: false,\n });\n },\n openModal21() {\n this.setData({\n modalOpened21: true,\n });\n },\n onModalClick21() {\n this.setData({\n modalOpened21: false,\n });\n },\n onModalClose21() {\n this.setData({\n modalOpened21: false,\n });\n },\n openModal22() {\n this.setData({\n modalOpened22: true,\n });\n },\n onModalClick22() {\n this.setData({\n modalOpened22: false,\n });\n },\n onModalClose22() {\n this.setData({\n modalOpened22: false,\n });\n },\n openModal3() {\n this.setData({\n modalOpened3: true,\n });\n },\n onModalClick3() {\n this.setData({\n modalOpened3: false,\n });\n },\n openModal4() {\n this.setData({\n modalOpened4: true,\n });\n },\n onModalClick4() {\n this.setData({\n modalOpened4: false,\n });\n },\n});","page/component/modal/modal.json":"{\n \"defaultTitle\": \"Modal\",\n \"usingComponents\":{\n \"modal\": \"mini-antui/es/modal/index\"\n }\n}","page/component/movable-view/movable-view.acss":"movable-area {\n height: 400rpx;\n width: 400rpx;\n margin: 50rpx 0rpx 0 50rpx;\n background-color: #ccc;\n overflow: hidden;\n}\n\nmovable-view {\n display: flex;\n align-items: center;\n justify-content: center;\n height: 200rpx;\n width: 200rpx;\n background: #ff5500;\n color: #fff;\n}\n\n.max {\n width: 600rpx;\n height: 600rpx;\n}\n","page/component/movable-view/movable-view.axml":"<view class=\"page\">\n <view class=\"page-description\">可移动视图</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">movable-view区域小于movable-area</view>\n <view class=\"page-section-demo\">\n <movable-area>\n <movable-view x=\"{{x}}\" y=\"{{y}}\" direction=\"all\">movable-view</movable-view>\n </movable-area>\n </view>\n <button style=\"margin-left: 10px; mrigin-right: 10px;\" type=\"primary\" onTap=\"onButtonTap\">点击移动到 (30px, 30px)</button>\n </view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">movable-view区域大于movable-area</view>\n <view class=\"page-section-demo\">\n <movable-area>\n <movable-view class=\"max\" direction=\"all\">movable-view</movable-view>\n </movable-area>\n </view>\n </view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">只可以横向移动</view>\n <view class=\"page-section-demo\">\n <movable-area>\n <movable-view direction=\"horizontal\">\n movable-view\n </movable-view>\n </movable-area>\n </view>\n </view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">只可以纵向移动</view>\n <view class=\"page-section-demo\">\n <movable-area>\n <movable-view direction=\"vertical\">\n movable-view\n </movable-view>\n </movable-area>\n </view>\n </view>\n</view>\n","page/component/movable-view/movable-view.js":"Page({\n data: {\n x: 0,\n y: 0,\n },\n onButtonTap() {\n const { x, y } = this.data;\n if (x === 30) {\n this.setData({\n x: x + 1,\n y: y + 1,\n });\n } else {\n this.setData({\n x: 30,\n y: 30\n });\n }\n },\n});\n","page/component/movable-view/movable-view.json":"{\n \"allowsBounceVertical\": \"NO\"\n}\n","page/component/navigator/navigate.axml":"<view class=\"page\">\n <view class=\"page-description\" style=\"text-align: center; margin-top: 200px;\">\n 我是一个新的页面\n </view>\n</view>\n","page/component/navigator/navigate.js":"Page({\n onLoad(options) {\n console.log(options);\n this.setData({\n title: options.title,\n });\n },\n});\n","page/component/navigator/navigator.acss":"navigator {\n background-color: lightcoral;\n color: #fff;\n margin-bottom: 10rpx;\n padding: 20rpx;\n text-align: center;\n}\n\n.navigator-hover {\n background-color: lightskyblue;\n color: #fff;\n}\n","page/component/navigator/navigator.axml":"<view class=\"page\">\n <view class=\"page-description\">导航栏</view>\n <navigator open-type=\"navigate\" url=\"./navigate\" hover-class=\"navigator-hover\">跳转到新页面</navigator>\n <navigator open-type=\"redirect\" url=\"./redirect\" hover-class=\"navigator-hover\">在当前页打开</navigator>\n <navigator open-type=\"switchTab\" url=\"/page/API/index/index\" hover-class=\"navigator-hover\">跳转到另外一个 Tab - API</navigator>\n <navigator open-type=\"reLaunch\" url=\"/page/component/index\" hover-class=\"navigator-hover\">重新打开</navigator>\n <navigator open-type=\"navigateBack\" hover-class=\"navigator-hover\">返回上一页面</navigator>\n</view>\n","page/component/navigator/navigator.js":"Page({});\n","page/component/navigator/navigator.json":"{\n \"defaultTitle\": \"Navigator\"\n}","page/component/navigator/redirect.axml":"<view class=\"page\">\n <view class=\"page-description\">\n 这是当前页,点击左上角返回回到上级菜单\n </view>\n</view>\n","page/component/navigator/redirect.js":"Page({\n onLoad(options) {\n console.log(options);\n this.setData({\n title: options.title,\n });\n },\n});\n","page/component/navigator/reLaunch.axml":"<view class=\"page\">\n <button onTap=\"index\">点击回到首页</button>\n</view>\n","page/component/navigator/reLaunch.js":"Page({\n index() {\n my.reLaunch({\n url: '/page/tabBar/component/index',\n });\n },\n});\n","page/component/notice/notice.acss":".demo-title{\n font-size: 15px;\n font-weight: 500;\n padding: 10px 5px;\n border-bottom: 1px solid #ccc;\n}\n\n.demo-item{\n margin-bottom: 10px;\n}","page/component/notice/notice.axml":"<view class=\"demo-title\">NoticeBar 通告栏</view>\n<view class=\"demo-item\">\n <notice>因全国公民身份系统升级,添加银行卡银行卡银行卡银行卡</notice>\n</view>\n<view class=\"demo-item\">\n <notice mode=\"link\" onClick=\"linkClick\">因全国公民身份系统升级,添加银行卡银行卡银行卡银行卡</notice>\n</view>\n<view class=\"demo-item\">\n <notice mode=\"closable\" onClick=\"closableClick\" show=\"{{closeShow}}\">因全国公民身份系统升级,添加银行卡银行卡银行卡银行卡</notice>\n</view>\n<view class=\"demo-item\">\n <notice mode=\"link\" action=\"去看看\" onClick=\"linkActionClick\">因全国公民身份系统升级,添加银行卡银行卡银行卡银行卡</notice>\n</view>\n<view class=\"demo-item\">\n <notice mode=\"closable\" action=\"不再提示\" onClick=\"closableActionClick\" show=\"{{closeActionShow}}\">因全国公民身份系统升级,添加银行卡银行卡银行卡银行卡</notice>\n</view>","page/component/notice/notice.js":"Page({\n data:{\n closeShow:true,\n closeActionShow:true\n },\n linkClick() {\n my.showToast({\n content: '你点击了图标Link NoticeBar',\n duration: 3000\n });\n },\n closableClick() {\n this.setData({\n closeShow:false\n })\n my.showToast({\n content: '你点击了图标close NoticeBar',\n duration: 3000\n });\n },\n linkActionClick() {\n my.showToast({\n content: '你点击了文本Link NoticeBar',\n duration: 3000\n });\n },\n closableActionClick() {\n this.setData({\n closeActionShow:false\n })\n my.showToast({\n content: '你点击了文本close NoticeBar',\n duration: 3000\n });\n }\n})","page/component/notice/notice.json":"{\n \"defaultTitle\": \"Notice\",\n \"usingComponents\":{\n \"notice\": \"mini-antui/es/notice/index\"\n }\n}","page/component/page-result/page-result.acss":".am-page-result {\n display: flex;\n flex-direction: column;\n}\n.am-page-result-btns {\n flex: 1;\n display: flex;\n flex-direction: column;\n justify-content: flex-end;\n align-content: center;\n padding-bottom: 100rpx;\n}\n.am-page-result-btns > view {\n color: #ff5500;\n font-size: 40rpx;\n margin-top: 52rpx;\n text-align: center;\n}\n","page/component/page-result/page-result.axml":"<view>\n <page-result\n type=\"network\"\n title=\"网络不给力\"\n brief=\"事件上最遥远的距离莫过于此\"\n >\n <view class=\"am-page-result-btns\">\n <view onTap=\"backHome\">回到首页</view>\n <view>示例按钮</view>\n </view>\n </page-result>\n</view>","page/component/page-result/page-result.js":"Page({\n backHome() {\n my.navigateBack();\n }\n});","page/component/page-result/page-result.json":"{\n \"defaultTitle\": \"Page-result\",\n \"usingComponents\":{\n \"page-result\": \"mini-antui/es/page-result/index\"\n }\n}","page/component/picker-view/picker-view.acss":".my-picker {\n background: #EFEFF4;\n}\n","page/component/picker-view/picker-view.axml":"<view class=\"page\">\n <view class=\"page-description\">嵌入页面的滚动选择器</view>\n <view class=\"page-section\">\n <view class=\"page-section-demo\">\n <picker-view value=\"{{value}}\" onChange=\"onChange\" class=\"my-picker\">\n <picker-view-column>\n <view>2011</view>\n <view>2012</view>\n <view>2013</view>\n <view>2014</view>\n <view>2015</view>\n <view>2016</view>\n <view>2017</view>\n <view>2018</view>\n </picker-view-column>\n <picker-view-column>\n <view>春</view>\n <view>夏</view>\n <view>秋</view>\n <view>冬</view>\n </picker-view-column>\n </picker-view>\n </view>\n </view>\n</view>","page/component/picker-view/picker-view.js":"Page({\n data: {},\n onChange(e) {\n console.log(e.detail.value);\n this.setData({\n value: e.detail.value,\n });\n },\n});\n","page/component/picker-view/picker-view.json":"{\n \"defaultTitle\": \"Picker View\"\n}","page/component/picker/picker.acss":".date-radio {\n padding: 26rpx;\n}\n\n.date-radio label + label {\n margin-left: 20rpx;\n}\n\n\n.row {\n display: flex;\n align-items: center;\n padding: 0 30rpx;\n}\n\n.row-title {\n flex: 1;\n padding-top: 28rpx;\n padding-bottom: 28rpx;\n font-size: 34rpx;\n color: #000;\n}\n\n.row-extra {\n flex-basis: initial;\n font-size: 32rpx;\n color: #888;\n}\n\n.row-arrow {\n width: 32rpx;\n height: 32rpx;\n margin-left: 16rpx;\n}","page/component/picker/picker.axml":"<view class=\"page\">\n <view class=\"page-description\">选择器</view>\n <view class=\"page-section\">\n <picker onChange=\"bindPickerChange\" value=\"{{index}}\" range=\"{{array}}\">\n <view class=\"row\">\n <view class=\"row-title\">地区选择器</view>\n <view class=\"row-extra\">当前选择:{{array[index]}}</view>\n <image class=\"row-arrow\" src=\"/image/arrowright.png\" mode=\"aspectFill\" />\n </view>\n </picker>\n </view>\n\n <view class=\"page-section\">\n <picker onChange=\"bindObjPickerChange\" value=\"{{arrIndex}}\" range=\"{{objectArray}}\" range-key=\"name\">\n <view class=\"row\">\n <view class=\"row-title\">ObjectArray</view>\n <view class=\"row-extra\">当前选择:{{objectArray[arrIndex].name}}</view>\n <image class=\"row-arrow\" src=\"/image/arrowright.png\" mode=\"aspectFill\" />\n </view>\n </picker>\n </view>\n</view>\n","page/component/picker/picker.js":"Page({\n data: {\n array: ['中国', '美国', '巴西', '日本'],\n objectArray: [\n {\n id: 0,\n name: '美国',\n },\n {\n id: 1,\n name: '中国',\n },\n {\n id: 2,\n name: '巴西',\n },\n {\n id: 3,\n name: '日本',\n },\n ],\n arrIndex: 0,\n index: 0\n },\n bindPickerChange(e) {\n console.log('picker发送选择改变,携带值为', e.detail.value);\n this.setData({\n index: e.detail.value,\n });\n },\n bindObjPickerChange(e) {\n console.log('picker发送选择改变,携带值为', e.detail.value);\n this.setData({\n arrIndex: e.detail.value,\n });\n },\n});\n\n","page/component/picker/picker.json":"{\n \"defaultTitle\": \"Picker\"\n}","page/component/popover/popover.acss":".demo-popover {\n display: flex;\n align-items: center;\n justify-content: center;\n width: 100%;\n height: 400px;\n}\n.demo-popover-btn {\n width: 100px;\n height: 100px;\n line-height: 100px;\n text-align: center;\n background-color: #fff;\n border: 1px solid #dddddd;\n border-radius: 2px;\n}\n.demo-popover-test-btns {\n display: flex;\n justify-content: space-around;\n}\n.demo-popover-test-btn {\n width: 45%;\n}","page/component/popover/popover.axml":"<view class=\"demo-popover\">\n <popover\n position=\"{{position}}\"\n show=\"{{show}}\"\n showMask=\"{{showMask}}\"\n onMaskClick=\"onMaskClick\"\n >\n <view class=\"demo-popover-btn\" onTap=\"onShowPopoverTap\">点击{{show ? '隐藏' : '显示'}}</view>\n <view slot=\"items\">\n <popover-item onItemClick=\"itemTap1\">\n <text>{{position}}</text>\n </popover-item>\n <popover-item onItemClick=\"itemTap2\">\n <text>line2</text>\n </popover-item>\n </view>\n </popover>\n</view>\n<view class=\"demo-popover-test-btns\">\n <button class=\"demo-popover-test-btn\" onTap=\"onNextPositionTap\">下个位置</button>\n <button class=\"demo-popover-test-btn\" onTap=\"onMaskChangeTap\">蒙层{{showMask ? '隐藏' : '显示'}}</button>\n</view>","page/component/popover/popover.js":"const position = ['top', 'topRight', 'rightTop', 'right', 'rightBottom', 'bottomRight', 'bottom', 'bottomLeft', 'leftBottom', 'left', 'leftTop', 'topLeft'];\nPage({\n data: {\n position: position[0],\n show: false,\n showMask: true,\n },\n onShowPopoverTap() {\n this.setData({\n show: !this.data.show,\n });\n },\n onNextPositionTap() {\n let index = position.indexOf(this.data.position);\n index = index >= position.length - 1 ? 0 : index + 1;\n this.setData({\n show: true,\n position: position[index],\n });\n },\n onMaskChangeTap() {\n this.setData({\n showMask: !this.data.showMask,\n });\n },\n onMaskClick() {\n this.setData({\n show: false,\n });\n },\n itemTap1() {\n my.alert({\n content: '点击1',\n });\n },\n itemTap2() {\n my.alert({\n content: '点击2',\n });\n },\n});","page/component/popover/popover.json":"{ \n \"defaultTitle\": \"Popover\",\n \"usingComponents\": {\n \"popover\": \"mini-antui/es/popover/index\",\n \"popover-item\": \"mini-antui/es/popover/popover-item/index\"\n }\n}","page/component/popup/popup.acss":".btn-container {\n width: 100%;\n height: 100vh;\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n}\n\n.btn-container button {\n width: 250px;\n}\n\n.box.top, .box.bottom {\n height: 200px;\n}\n\n.box.left, .box.right {\n width: 200px;\n height: 100%;\n}\n\n.box {\n background-color: #fff;\n display: flex;\n justify-content: center;\n align-items: center;\n}","page/component/popup/popup.axml":"<view>\n <view class=\"btn-container\">\n <button onTap=\"onTopBtnTap\">上</button>\n <button onTap=\"onButtomBtnTap\">下</button>\n <button onTap=\"onRightBtnTap\">右 无mask</button>\n <button onTap=\"onLeftBtnTap\">左 无动画</button>\n </view>\n <popup show=\"{{showLeft}}\" animation=\"{{false}}\" position=\"left\" onClose=\"onPopupClose\">\n <view class=\"box left\">hello world</view>\n </popup>\n <popup show=\"{{showRight}}\" position=\"right\" mask=\"{{false}}\" onClose=\"onPopupClose\">\n <view class=\"box right\" style=\"display: flex; flex-direction: column;\">\n <view>hello world</view>\n <view style=\"margin-top: 20px;\">\n <button onTap=\"onPopupClose\" style=\"width: 100px;\">关闭</button>\n </view>\n </view>\n </popup>\n <popup show=\"{{showTop}}\" position=\"top\" onClose=\"onPopupClose\">\n <view class=\"box top\">hello world</view>\n </popup>\n <popup show=\"{{showBottom}}\" position=\"bottom\" onClose=\"onPopupClose\">\n <view class=\"box bottom\">hello world</view>\n </popup>\n</view>","page/component/popup/popup.js":"Page({\n data: {\n showLeft: false,\n showRight: false,\n showTop: false,\n showBottom: false,\n },\n onTopBtnTap() {\n this.setData({\n showTop: true,\n });\n },\n onRightBtnTap() {\n this.setData({\n showRight: true,\n });\n },\n onLeftBtnTap() {\n this.setData({\n showLeft: true,\n });\n },\n onButtomBtnTap() {\n this.setData({\n showBottom: true,\n });\n },\n onPopupClose() {\n this.setData({\n showLeft: false,\n showRight: false,\n showTop: false,\n showBottom: false,\n });\n },\n});","page/component/popup/popup.json":"{\n \"defaultTitle\": \"Popup\",\n \"usingComponents\":{\n \"popup\": \"mini-antui/es/popup/index\"\n }\n}","page/component/progress/progress.acss":"progress{\n margin-bottom: 60rpx;\n}\n","page/component/progress/progress.axml":"<view class=\"page\">\n <view class=\"page-description\">进度条</view>\n <view class=\"page-section\">\n <view class=\"page-section-demo\">\n <progress percent=\"20\" show-info/>\n <progress percent=\"40\" active/>\n <progress percent=\"60\" stroke-width=\"10\"/>\n <progress percent=\"80\" color=\"#10AEFF\"/>\n <progress percent=\"80\" activeColor=\"#6abf47\" backgroundColor=\"#f4333c\" />\n </view>\n </view>\n</view>\n","page/component/progress/progress.js":"Page({});\n","page/component/progress/progress.json":"{\n \"defaultTitle\": \"Progress\"\n}","page/component/radio/radio.acss":".radio {\n display: block;\n margin-bottom: 20rpx;\n}\n.radio-text {\n line-height: 1.8;\n}\n","page/component/radio/radio.axml":"<view class=\"page\">\n <view class=\"page-description\">单选框</view>\n <view class=\"page-section\">\n <view class=\"section section_gap\">\n <form onSubmit=\"onSubmit\" onReset=\"onReset\">\n <view class=\"page-section-demo\">\n <radio-group class=\"radio-group\" onChange=\"radioChange\" name=\"lib\">\n <label class=\"radio\" a:for=\"{{items}}\" key=\"label-{{index}}\">\n <radio value=\"{{item.name}}\" checked=\"{{item.checked}}\" disabled=\"{{item.disabled}}\" />\n <text class=\"radio-text\">{{item.value}}</text>\n </label>\n </radio-group>\n </view>\n <view class=\"page-section-btns\">\n <view><button size=\"mini\" type=\"ghost\" formType=\"reset\">reset</button></view>\n <view><button size=\"mini\" type=\"primary\" formType=\"submit\">submit</button></view>\n </view>\n </form>\n </view>\n </view>\n</view>\n","page/component/radio/radio.js":"Page({\n data: {\n items: [\n { name: 'angular', value: 'AngularJS' },\n { name: 'react', value: 'React', checked: true },\n { name: 'polymer', value: 'Polymer' },\n { name: 'vue', value: 'Vue.js' },\n { name: 'ember', value: 'Ember.js' },\n { name: 'backbone', value: 'Backbone.js', disabled: true },\n ],\n },\n onSubmit(e) {\n my.alert({\n content: e.detail.value.lib,\n });\n console.log('onSubmit', e.detail);\n },\n onReset(e) {\n console.log('onReset', e);\n },\n radioChange(e) {\n console.log('你选择的框架是:', e.detail.value);\n },\n});\n","page/component/radio/radio.json":"{\n \"defaultTitle\": \"Radio\"\n}","page/component/rich-text/rich-text.acss":".wrapper {\n padding: 20rpx;\n}","page/component/rich-text/rich-text.axml":"<view>\n <rich-text nodes=\"{{nodes}}\" bindtap=\"tap\"></rich-text>\n</view>","page/component/rich-text/rich-text.js":"Page({\n data: {\n nodes: [{\n name: 'div',\n attrs: {\n class: 'wrapper',\n style: 'color: orange;',\n },\n children: [{\n type: 'text',\n text: 'Hello World!',\n }],\n }],\n },\n tap() {\n console.log('tap');\n },\n});\n","page/component/rich-text/rich-text.json":"{\n \"defaultTitle\": \"Rich-Text\"\n}","page/component/scroll-view/scroll-view.acss":".scroll-view_H{\n white-space: nowrap;\n display:flex;\n}\n.scroll-view-item{\n height: 200px;\n}\n.scroll-view-item_H{\n flex-shrink:0;\n flex-grow:0;\n width: 300px;\n height: 200px;\n}\n","page/component/scroll-view/scroll-view.axml":"<view class=\"page\">\n <view class=\"page-description\">可滚动视图区域</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">vertical scroll</view>\n <view class=\"page-section-demo\">\n <scroll-view scroll-y=\"{{true}}\" style=\"height: 200px;\" onScrollToUpper=\"upper\" onScrollToLower=\"lower\" onScroll=\"scroll\" scroll-into-view=\"{{toView}}\" scroll-top=\"{{scrollTop}}\">\n <view id=\"blue\" class=\"scroll-view-item bc_blue\"></view>\n <view id=\"red\" class=\"scroll-view-item bc_red\"></view>\n <view id=\"yellow\" class=\"scroll-view-item bc_yellow\"></view>\n <view id=\"green\" class=\"scroll-view-item bc_green\"></view>\n </scroll-view>\n </view>\n <view class=\"page-section-btns\">\n <view onTap=\"tap\">next</view>\n <view onTap=\"tapMove\">move</view>\n <view onTap=\"scrollToTop\">scrollToTop</view>\n </view>\n </view>\n\n <view class=\"page-section\">\n <view class=\"page-section-title\">horizontal scroll</view>\n <view class=\"page-section-demo\">\n <scroll-view class=\"scroll-view_H\" scroll-x=\"{{true}}\" style=\"width: 100%\" >\n <view id=\"blue2\" class=\"scroll-view-item_H bc_blue\"></view>\n <view id=\"red2\" class=\"scroll-view-item_H bc_red\"></view>\n <view id=\"yellow2\" class=\"scroll-view-item_H bc_yellow\"></view>\n <view id=\"green2\" class=\"scroll-view-item_H bc_green\"></view>\n </scroll-view>\n </view>\n </view>\n</view>\n","page/component/scroll-view/scroll-view.js":"import debounce from '/util/debounce';\n\nconst order = ['blue', 'red', 'green', 'yellow'];\n\nPage({\n data: {\n toView: 'red',\n scrollTop: 100,\n },\n onLoad() {\n this.scroll = debounce(this.scroll.bind(this), 100);\n },\n upper(e) {\n console.log(e);\n },\n lower(e) {\n console.log(e);\n },\n scroll(e) {\n this.setData({\n scrollTop: e.detail.scrollTop,\n });\n },\n scrollEnd() {\n\n },\n scrollToTop(e) {\n console.log(e);\n this.setData({\n scrollTop: 0,\n });\n },\n tap(e) {\n for (let i = 0; i < order.length; ++i) {\n if (order[i] === this.data.toView) {\n const next = (i + 1) % order.length;\n this.setData({\n toView: order[next],\n scrollTop: next * 200,\n });\n break;\n }\n }\n },\n tapMove() {\n this.setData({\n scrollTop: this.data.scrollTop + 10,\n });\n },\n});\n","page/component/scroll-view/scroll-view.json":"{\n \"defaultTitle\": \"Scroll View\"\n}","page/component/search-bar/search-bar.acss":"/* required by usingComponents */","page/component/search-bar/search-bar.axml":"<view>\n <search-bar\n value=\"{{value}}\"\n placeholder=\"搜索\"\n onInput=\"handleInput\"\n onClear=\"handleClear\"\n onFocus=\"handleFocus\"\n onBlur=\"handleBlur\"\n onCancel=\"handleCancel\"\n onSubmit=\"handleSubmit\"\n showCancelButton=\"{{false}}\" />\n</view>","page/component/search-bar/search-bar.js":"Page({});","page/component/search-bar/search-bar.json":"{\n \"defaultTitle\": \"SearchBar\",\n \"usingComponents\":{\n \"search-bar\": \"mini-antui/es/search-bar/index\"\n }\n}","page/component/slider/slider.axml":"<view class=\"page\">\n <view class=\"page-description\">滑块</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">设置step</view>\n <view class=\"page-section-demo\">\n <slider value=\"5\" onChange=\"slider2change\" step=\"5\"/>\n </view>\n </view>\n\n <view class=\"page-section\">\n <view class=\"page-section-title\">设置最小/最大值范围</view>\n <view class=\"page-section-demo\">\n <slider value=\"33\" onChange=\"slider4change\" min=\"25\" max=\"50\" show-value/>\n </view>\n </view>\n\n <view class=\"page-section\">\n <view class=\"page-section-title\">自定义样式</view>\n <view class=\"page-section-demo\">\n <slider value=\"33\" onChange=\"slider4change\" min=\"25\" max=\"50\" show-value\n backgroundColor=\"#FFAA00\" activeColor=\"#00aaee\" trackSize=\"2\" handleSize=\"6\" handleColor=\"blue\" />\n </view>\n </view>\n</view>\n","page/component/slider/slider.js":"const pageData = {};\n\nfor (let i = 1; i < 5; ++i) {\n (function (index) {\n pageData['slider' + index + 'change'] = function (e) {\n console.log('slider' + index + '发生change事件,携带值为', e.detail.value);\n };\n })(i);\n}\nPage(pageData);\n","page/component/slider/slider.json":"{\n \"defaultTitle\": \"Slider\"\n}","page/component/stepper/stepper.acss":"/* required by usingComponents */","page/component/stepper/stepper.axml":"<list>\n <list-item disabled=\"{{true}}\">\n Show number value\n <view slot=\"extra\">\n <stepper onChange=\"callBackFn\" step=\"{{1}}\" showNumber readOnly=\"{{false}}\" value=\"{{value}}\" min=\"{{2}}\" max=\"{{12}}\" />\n </view>\n </list-item>\n <list-item disabled=\"{{true}}\">\n Do not show number value\n <view slot=\"extra\">\n <stepper onChange=\"callBackFn\" step=\"{{1}}\" readOnly=\"{{false}}\" value=\"{{value}}\" min=\"{{2}}\" max=\"{{12}}\" />\n </view>\n </list-item>\n <list-item disabled=\"{{true}}\">\n Disabled\n <view slot=\"extra\">\n <stepper onChange=\"callBackFn\" showNumber value=\"{{11}}\" min=\"{{2}}\" max=\"{{12}}\" disabled />\n </view>\n </list-item>\n <list-item disabled=\"{{true}}\">\n readOnly\n <view slot=\"extra\">\n <stepper onChange=\"callBackFn\" showNumber value=\"{{11}}\" min=\"{{2}}\" max=\"{{12}}\" readOnly />\n </view>\n </list-item>\n <list-item>\n <button onTap=\"modifyValue\">修改setper初始值</button>\n </list-item>\n</list>","page/component/stepper/stepper.js":"Page({\n data: {\n value: 8,\n },\n callBackFn(value){\n console.log(value);\n },\n modifyValue() {\n this.setData({\n value: this.data.value + 1,\n });\n }\n});","page/component/stepper/stepper.json":"{\n \"defaultTitle\": \"Stepper\",\n \"usingComponents\":{\n \"stepper\": \"mini-antui/es/stepper/index\",\n \"list\": \"mini-antui/es/list/index\",\n \"list-item\": \"mini-antui/es/list/list-item/index\"\n }\n}","page/component/steps/steps.acss":".demo-steps-class {\n margin: 20px 0;\n border-bottom: 1px solid #e5e5e5;\n}\n.demo-btn-container {\n display: flex;\n justify-content: space-between;\n margin: 20px;\n}\n.demo-btn {\n width: 47%;\n}\n\n.am-vertical-step-line.is-active {\n background-color: #ff5500;\n}\n\n.am-hor-step-icon.is-active {\n background-color: #ff5500;\n}\n","page/component/steps/steps.axml":"<steps \n className=\"demo-steps-class\"\n activeIndex=\"{{activeIndex}}\"\n items=\"{{items}}\"\n></steps>\n<steps \n className=\"demo-steps-class\"\n activeIndex=\"{{activeIndex}}\"\n items=\"{{items2}}\"\n>\n</steps>\n<steps \n className=\"demo-steps-class\"\n direction=\"vertical\"\n failIndex=\"{{failIndex}}\"\n activeIndex=\"{{activeIndex}}\"\n items=\"{{items2}}\"\n>\n</steps>\n<view class=\"demo-btn-container\">\n <button class=\"demo-btn\" onTap=\"preStep\">\b上一步</button>\n <button class=\"demo-btn\" onTap=\"nextStep\">\b下一步</button>\n</view>\n<view class=\"demo-btn-container\">\n <button class=\"demo-btn\" onTap=\"setFailIndex\">\b设置错误项</button>\n <button class=\"demo-btn\" onTap=\"cancelFailIndex\">\b取消错误项</button>\n</view>","page/component/steps/steps.js":"Page({\n data: {\n activeIndex: 1,\n failIndex: 0,\n items: [{\n title: '步骤1',\n }, {\n title: '步骤2',\n }, {\n title: '步骤3',\n }],\n items2: [{\n title: '步骤1',\n description: '这是步骤1的描述文档,文字足够多的时候会换行',\n }, {\n title: '步骤2 如果标题足够长的话也会换行的',\n description: '这是步骤2',\n }, {\n title: '步骤3',\n description: '这是步骤3',\n }, {\n title: '步骤4',\n description: '不超过六个字',\n }],\n },\n nextStep() {\n this.setData({\n activeIndex: this.data.activeIndex + 1,\n });\n },\n preStep() {\n this.setData({\n activeIndex: this.data.activeIndex - 1,\n });\n },\n setFailIndex() {\n this.setData({\n failIndex: 3,\n });\n },\n cancelFailIndex() {\n this.setData({\n failIndex: 0,\n });\n },\n});","page/component/steps/steps.json":"{\n \"defaultTitle\": \"Steps\",\n \"usingComponents\":{\n \"steps\": \"mini-antui/es/steps/index\"\n }\n}","page/component/swipe-action/swipe-action.acss":"","page/component/swipe-action/swipe-action.axml":"<view>\n\t<list>\n\t\t<swipe-action\n\t\t\tindex=\"{{1}}\"\n\t\t\trestore=\"{{swipeIndex !== null && swipeIndex !== 1}}\"\n\t\t\tright=\"{{right1}}\"\n\t\t\tonRightItemClick=\"onRightItemClick\"\n\t\t\tonSwipeStart=\"onSwipeStart\"\n\t\t\textra=\"item1\"\n\t\t>\n\t\t\t<list-item\n\t\t\t\tarrow=\"horizontal\"\n\t\t\t\tindex=\"1\"\n\t\t\t\tkey=\"items-1\"\n\t\t\t\tonClick=\"onItemClick\"\n\t\t\t>\n\t\t\t\t只有删除\n\t\t\t</list-item>\n\t\t</swipe-action>\n\t\t<swipe-action index=\"{{2}}\" restore=\"{{swipeIndex !== null && swipeIndex !== 2}}\" right=\"{{right2}}\" data-some=\"ddd\" onRightItemClick=\"onRightItemClick\" onSwipeStart=\"onSwipeStart\" extra=\"item2\">\n\t\t\t<list-item\n\t\t\t\tarrow=\"horizontal\"\n\t\t\t\tindex=\"2\"\n\t\t\t\tkey=\"items-2\"\n\t\t\t\tonClick=\"onItemClick\"\n\t\t\t\tlast=\"{{true}}\"\n\t\t\t>\n\t\t\t\t修改 + 删除\n\t\t\t</list-item>\n\t\t</swipe-action>\n\t</list>\n</view>","page/component/swipe-action/swipe-action.js":"Page({\n data: {\n swipeIndex: null,\n right1: [{ type: 'delete', text: '删除' }],\n right2: [{ type: 'edit', text: '取消收藏' }, { type: 'delete', text: '删除' }],\n },\n onRightItemClick(e) {\n my.confirm({\n title: '温馨提示',\n content: `${e.index}-${e.extra}-${JSON.stringify(e.detail)}`,\n confirmButtonText: '确定',\n cancelButtonText: '取消',\n success: (result) => {\n if (result.confirm) {\n my.showToast({\n content: '确定 => 执行滑动删除还原',\n });\n e.done();\n } else {\n my.showToast({\n content: '取消 => 滑动删除状态保持不变',\n });\n }\n },\n });\n },\n onItemClick(e) {\n my.alert({\n content: `dada${e.index}`,\n });\n },\n onSwipeStart(e) {\n this.setData({\n swipeIndex: e.index || null,\n });\n },\n});","page/component/swipe-action/swipe-action.json":"{\n \"defaultTitle\": \"SwipeAction\",\n \"usingComponents\": {\n \"list\": \"mini-antui/es/list/index\",\n \"list-item\": \"mini-antui/es/list/list-item/index\",\n \"swipe-action\": \"mini-antui/es/swipe-action/index\"\n }\n}","page/component/swiper/swiper.acss":".swiper-item{\n display: block;\n height: 150px;\n margin:10px;\n}\n\n\n.margin-t {\n margin-top: 24px;\n}\n","page/component/swiper/swiper.axml":"<view class=\"page\">\n <view class=\"page-description\">滑块视图容器</view>\n <view class=\"page-section\">\n <view class=\"page-section-demo\">\n <swiper\n style=\"height:150px\"\n class=\"demo-swiper\"\n previousMargin=\"10px\"\n nextMargin=\"10px\"\n indicator-dots=\"{{indicatorDots}}\"\n autoplay=\"{{autoplay}}\"\n vertical=\"{{vertical}}\"\n interval=\"{{interval}}\"\n circular=\"{{circular}}\"\n >\n <swiper-item key=\"swiper-item-{{index}}\" a:for=\"{{background}}\">\n <view class=\"swiper-item bc_{{item}}\"></view>\n </swiper-item>\n </swiper>\n <view class=\"margin-t\">\n <slider onChange=\"intervalChange\" value=\"{{interval}}\" show-value min=\"500\" max=\"2000\"/>\n <view>interval</view>\n </view>\n </view>\n <view class=\"page-section-btns\">\n <view onTap=\"changeIndicatorDots\">indicator-dots</view>\n <view onTap=\"changeAutoplay\">autoplay</view>\n <view onTap=\"changeVertical\">vertical</view>\n </view>\n <view class=\"page-section-btns\">\n <view onTap=\"changeCircular\">circular</view>\n </view>\n </view>\n</view>\n","page/component/swiper/swiper.js":"Page({\n data: {\n background: ['blue', 'red', 'yellow'],\n indicatorDots: true,\n autoplay: false,\n vertical: false,\n interval: 1000,\n circular: false,\n },\n onLoad() {\n },\n changeIndicatorDots(e) {\n this.setData({\n indicatorDots: !this.data.indicatorDots,\n });\n },\n changeVertical() {\n this.setData({\n vertical: !this.data.vertical,\n });\n },\n changeCircular(e) {\n this.setData({\n circular: !this.data.circular,\n });\n },\n changeAutoplay(e) {\n this.setData({\n autoplay: !this.data.autoplay,\n });\n },\n intervalChange(e) {\n this.setData({\n interval: e.detail.value,\n });\n },\n});\n","page/component/swiper/swiper.json":"{\n \"defaultTitle\": \"Swiper\",\n \"pullRefresh\": false,\n \"allowsBounceVertical\": false\n}","page/component/switch/switch.acss":".switch-item + .switch-item {\n margin-top: 20rpx;\n}\n","page/component/switch/switch.axml":"<view class=\"page\">\n <view class=\"page-description\">开关</view>\n <view class=\"page-section\">\n <view class=\"page-section-demo switch-list\">\n <view class=\"switch-item\">\n <switch checked onChange=\"switch1Change\" aria-label=\"{{switch1 ? 'switch opened' : 'switch closed'}}\" />\n </view>\n <view class=\"switch-item\">\n <switch onChange=\"switch2Change\"/>\n </view>\n <view class=\"switch-item\">\n <switch color=\"red\" checked />\n </view>\n </view>\n </view>\n</view>\n","page/component/switch/switch.js":"Page({\n data: {\n switch1: true,\n },\n switch1Change(e) {\n console.log('switch1 发生 change 事件,携带值为', e.detail.value);\n this.setData({\n switch1: e.detail.value,\n });\n },\n switch2Change(e){\n console.log('switch2 发生 change 事件,携带值为', e.detail.value);\n },\n});\n","page/component/switch/switch.json":"{\n \"defaultTitle\": \"Switch\"\n}","page/component/tabs/tabs.acss":".tab-content {\n display: flex;\n justify-content: center;\n align-items: center;\n height: 300px;\n}","page/component/tabs/tabs.axml":"<view>\n <tabs\n tabs=\"{{tabs}}\"\n showPlus=\"{{true}}\"\n onTabClick=\"handleTabClick\"\n onChange=\"handleTabChange\"\n onPlusClick=\"handlePlusClick\"\n activeTab=\"{{activeTab}}\"\n swipeable=\"{{true}}\"\n tabBarActiveTextColor=\"#ff5500\"\n tabBarUnderlineColor=\"#ff5500\"\n >\n <block a:for=\"{{tabs}}\">\n <tab-content key=\"{{index}}\">\n <view class=\"tab-content\">content of {{item.title}}</view>\n </tab-content>\n </block>\n </tabs>\n</view>","page/component/tabs/tabs.js":"Page({\n data: {\n tabs: [\n {\n title: '选项',\n badgeType: 'text',\n badgeText: '6',\n },\n {\n title: '选项二',\n badgeType: 'dot',\n },\n { title: '3 Tab' },\n { title: '4 Tab' },\n { title: '5 Tab' },\n ],\n activeTab: 2,\n },\n handleTabClick({ index }) {\n this.setData({\n activeTab: index,\n });\n },\n handleTabChange({ index }) {\n this.setData({\n activeTab: index,\n });\n },\n handlePlusClick() {\n my.alert({\n content: 'plus clicked',\n });\n },\n});","page/component/tabs/tabs.json":"{\n \"defaultTitle\": \"Tabs\",\n \"usingComponents\":{\n \"tabs\": \"mini-antui/es/tabs/index\",\n \"tab-content\": \"mini-antui/es/tabs/tab-content/index\"\n }\n}","page/component/text/text.acss":".page {\n padding: 0;\n}\n\n.text-demo-title {\n margin-left: 30rpx;\n margin-top: 30rpx;\n}\n\n.text-demo-text {\n font-size: 36rpx;\n}","page/component/text/text.axml":"<view class=\"page\">\n <view class=\"page-description\">\n <view class=\"text-demo-title\">\n <text class=\"text-demo-text\">这是一段文本。\\n<text>\\</text><text>n</text> 可以换行。</text>\n </view> \n </view>\n <view class=\"page-section\">\n <view class=\"page-section-demo\">\n <text>{{text}}</text>\n </view>\n </view>\n</view>\n","page/component/text/text.js":"Page({\n data: {\n text: `淘宝是一个大型生活服务类的平台,用户群非常广泛,上至五六十岁,下至十几岁。\n 这里不仅有官方自营应用,还有第三方接入应用,用户的选择很多。\n 只有你的产品做得足够简单,才能让更多的用户使用。而更多人的使用,也意味着你更大的收益。\\n\\n:)\n `,\n },\n});\n","page/component/text/text.json":"{\n \"defaultTitle\": \"Text\"\n}\n","page/component/textarea/textarea.acss":"","page/component/textarea/textarea.axml":"<!--textarea.axml-->\n<view class=\"page\">\n <view class=\"page-description\">文本框</view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">受控聚焦</view>\n <view class=\"page-section-demo\">\n <textarea focus=\"{{focus}}\" onFocus=\"onFocus\" onBlur=\"onBlur\" placeholder=\"Please input something\" />\n </view>\n <view class=\"page-section-btns\">\n <button type=\"default\" size=\"mini\" onTap=\"bindButtonTap\">聚焦</button>\n </view>\n </view>\n <view class=\"page-section\">\n <view class=\"page-section-title\">自适应高度</view>\n <view class=\"page-section-demo\">\n <textarea onBlur=\"bindTextAreaBlur\" auto-height placeholder=\"Please input something\" />\n </view>\n </view>\n\n <view class=\"page-section\">\n <view class=\"page-section-title\">结合表单</view>\n <form onSubmit=\"bindFormSubmit\">\n <view class=\"page-section-demo\">\n <textarea name=\"textarea\"placeholder=\"Please input something\" />\n </view>\n <view class=\"page-section-btns\">\n <button form-type=\"submit\" size=\"mini\" type=\"primary\">提交</button>\n </view> \n </form>\n </view>\n</view>\n","page/component/textarea/textarea.js":"Page({\n data: {\n height: 20,\n focus: false,\n },\n bindButtonTap() {\n this.onFocus();\n },\n onFocus() {\n this.setData({\n focus: true,\n });\n },\n onBlur() {\n this.setData({\n focus: false,\n });\n },\n\n bindTextAreaBlur(e) {\n console.log(e.detail.value);\n },\n bindFormSubmit(e) {\n my.alert({\n content: e.detail.value.textarea,\n });\n },\n});\n","page/component/textarea/textarea.json":"{\n \"defaultTitle\": \"Textarea\"\n}","page/component/tips/tips.acss":".rectangle {\n position: fixed;\n bottom: 100px;\n}\n\n.dialog {\n position: fixed;\n bottom: 10px;\n}\n\n.content {\n font-size: 14px;\n color: #fff;\n}\n\n.opt-button {\n width: 51px;\n height: 27px;\n display: flex;\n justify-content: center;\n align-items: center;\n color: #fff;\n font-size: 12px;\n border: #68BAF7 solid 1rpx;\n}\n\n.add-home {\n width: 72px;\n height: 27px;\n display: flex;\n justify-content: center;\n align-items: center;\n background-color: #56ADEB;\n color: #fff;\n font-size: 14px;\n}","page/component/tips/tips.axml":"<view>\n <tips-dialog\n show=\"{{showDialog}}\"\n className=\"dialog\"\n type=\"dialog\"\n >\n <view class=\"content\" slot=\"content\">\n <view>hello,</view>\n <view>欢迎使用商家应用扩展组件库mini-antui</view>\n </view>\n <view slot=\"operation\" class=\"opt-button\" onTap=\"onDialogTap\">知道了</view> \n </tips-dialog>\n <tips-dialog\n iconUrl=\"https://gw.alipayobjects.com/zos/rmsportal/AzRAgQXlnNbEwQRvEwiu.png\"\n type=\"rectangle\"\n className=\"rectangle\"\n onCloseTap=\"onCloseTap\"\n show=\"{{showRectangle}}\">\n <view class=\"content\" slot=\"content\">\n 把“城市服务”添加到首页\n </view>\n <view slot=\"operation\" class=\"add-home\" onTap=\"onRectangleTap\">立即添加</view>\n </tips-dialog>\n</view>","page/component/tips/tips.js":"Page({\n data: {\n showRectangle: true,\n showDialog: true,\n },\n onCloseTap() {\n this.setData({\n showRectangle: false,\n });\n },\n onRectangleTap() {\n my.alert({\n content: 'do something',\n });\n },\n onDialogTap() {\n this.setData({\n showDialog: false,\n });\n },\n});\n","page/component/tips/tips.json":"{\n \"defaultTitle\": \"Tips\",\n \"usingComponents\":{\n \"tips-dialog\": \"mini-antui/es/tips/tips-dialog/index\",\n \"tips-plain\": \"mini-antui/es/tips/tips-plain/index\"\n }\n}","page/component/video/video.acss":".video-page {\n width: 100%;\n}\n\n.video-contain {\n display: flex;\n align-items: center;\n justify-content: center;\n margin-top: 24px\n}\n\n.video {\nwidth: 320px;\nheight: 225px;\n}\n\n.operation-item {\n height: 48px;\n background-color: #54acee;\n margin: 20px 40px 0 40px;\n display: flex;\n align-items: center;\n justify-content: center;\n font-size: 20px\n}\n","page/component/video/video.axml":"<view class=\"video-page\">\n<view class=\"video-contain\">\n <video \n src=\"{{src}}\" \n class=\"video\" \n id=\"video\"\n poster=\"https://zos.alipayobjects.com/rmsportal/SSWkSLDrrgsLFDfsjzTZ.png\"\n autoplay=\"{{autoplay}}\"\n object-fit=\"{{objectFit}}\"\n loop=\"{{loop}}\"\n show-fullscreen-btn=\"{{showFullscreenBtn}}\"\n show-center-play-btn=\"{{showCenterPlayBtn}}\"\n onPlay=\"onPlay\"\n onPause=\"onPause\"\n onEnded=\"onEnded\"\n onTimeUpdate=\"onTimeUpdate\"\n onLoading=\"onLoading\"\n onStop=\"onStop\"\n enableNative=\"{{true}}\"\n muted=\"{{muted}}\"\n >\n </video>\n </view>\n <view class=\"operation-item\" style=\"background-color:lightblue\">\b{{title}}</view>\n <view class=\"operation-item\" onTap=\"play\">播放</view>\n <view class=\"operation-item\" onTap=\"pause\">暂停</view>\n <view class=\"operation-item\" onTap=\"seek\">跳到15s\b播放</view>\n <view class=\"operation-item\" onTap=\"mute\">静音</view>\n <view class=\"operation-item\" onTap=\"playbackRate\">倍速播放</view>\n <view class=\"operation-item\" onTap=\"requestFullScreen\">全屏</view>\n <view class=\"operation-item\" onTap=\"exitFullScreen\">退出全屏</view>\n <view class=\"operation-item\" onTap=\"showStatusBar\">显示状态栏</view>\n <view class=\"operation-item\" onTap=\"hideStatusBar\">隐藏状态栏</view>\n <view class=\"operation-item\" onTap=\"stop\">停止播放</view>\n</view>\n","page/component/video/video.js":"Page({\n data: {\n src: \"http://flv.bn.netease.com/tvmrepo/2012/7/C/7/E868IGRC7-mobile.mp4\",\n //src:\"https://youtu.be/J_WcqN1Hipg\",\n title: 'initial',\n autoplay: 'false',\n objectFit: 'contain',\n showFullscreenBtn: 'fals\be',\n showCenterPlayBtn: 'false',\n muted: 'false',\n loop: 'false',\n // extraInfo:{\n // stoken:'%2bqEaZgO9Tt6Bg7c1%2bbS3H2r%2b8dWgk4m74sV3mlJZD5XfovsPuOxsinYham66Lua6sOZFRrlBRrjBPK%2fgkZOFfTYPP01UptHg%2b4SAxwKMUVvhxjUhs%2fg58428lInm7seis8F6lf2bmpxrAM6Ia4qOeA%3d%3d',\n // ptoken:'eRt41ih0ieHGso2Mse3aUGjGrXzTSj70kgqyHLwTfNh%2fKz0bsH1Go4ChZjwlM1PrDO1nq3RW7CarxaUnKOq5M25BfHH9aGvdCOHcce89uJfrLqLOk6NEwR%2fY5LsLSYNSnzl5YSYl359xKGL3cHvfcw%3d%3d',\n // stoken:'2TTH0S/OBuQoBthtlNtu/df4zKuh2qkavbd1QRtmM5X1RT3YehRjKmFoEmnsjv9dp3GWrzEcG8y5qHJr8Mwm76aYwWqKnIY9YCRE6l606ySYgfiohgBsA199EjHwI0XG6x2OC0Q9FzgqGDkD0Z+sow==',\n // ptoken:'iPqLrZnna90HCdsypMibpVz2eNdYBDqQmoAL89BiKVJFa/lS9zpSv2PsQgLTJYSc9uhHuYeEClEB4xeMiYyMmnG8UQQKyIPXqxfSwrQmDL72Yt1yCgvDze3DeQesjpNYKo9YruJ99nSqvmPLvjIpGA==',\n // isYouku: false, // 是否优酷商家应用,据此设置ccode\n // srcType: 0, // 0是vid,1是showId\n // }\n },\n\n\n\n //extrainfo:{\n //会员\n //stoken:'%2bqEaZgO9Tt6Bg7c1%2bbS3H2r%2b8dWgk4m74sV3mlJZD5XfovsPuOxsinYham66Lua6sOZFRrlBRrjBPK%2fgkZOFfTYPP01UptHg%2b4SAxwKMUVvhxjUhs%2fg58428lInm7seis8F6lf2bmpxrAM6Ia4qOeA%3d%3d',\n //ptoken:'eRt41ih0ieHGso2Mse3aUGjGrXzTSj70kgqyHLwTfNh%2fKz0bsH1Go4ChZjwlM1PrDO1nq3RW7CarxaUnKOq5M25BfHH9aGvdCOHcce89uJfrLqLOk6NEwR%2fY5LsLSYNSnzl5YSYl359xKGL3cHvfcw%3d%3d',\n //stoken:'+qEaZgO9Tt6Bg7c1+bS3H2r+8dWgk4m74sV3mlJZD5XfovsPuOxsinYham66Lua6sOZFRrlBRrjBPK/gkZOFfTYPP01UptHg+4SAxwKMUVvhxjUhs/g58428lInm7seis8F6lf2bmpxrAM6Ia4qOeA==',\n //ptoken:'eRt41ih0ieHGso2Mse3aUGjGrXzTSj70kgqyHLwTfNh/Kz0bsH1Go4ChZjwlM1PrDO1nq3RW7CarxaUnKOq5M25BfHH9aGvdCOHcce89uJfrLqLOk6NEwR/Y5LsLSYNSnzl5YSYl359xKGL3cHvfcw==',\n //非会员\n //stoken:'2TTH0S/OBuQoBthtlNtu/df4zKuh2qkavbd1QRtmM5X1RT3YehRjKmFoEmnsjv9dp3GWrzEcG8y5qHJr8Mwm76aYwWqKnIY9YCRE6l606ySYgfiohgBsA199EjHwI0XG6x2OC0Q9FzgqGDkD0Z+sow==',\n //ptoken:'iPqLrZnna90HCdsypMibpVz2eNdYBDqQmoAL89BiKVJFa/lS9zpSv2PsQgLTJYSc9uhHuYeEClEB4xeMiYyMmnG8UQQKyIPXqxfSwrQmDL72Yt1yCgvDze3DeQesjpNYKo9YruJ99nSqvmPLvjIpGA==',\n //isYouku: true,\n //srcType :0\n //}\n onShow(){\n this.videoContext = my.createVideoContext('video');\n this.muted = this.data.muted === 'true';\n },\n onPlay(){\n console.log('onPlay');\n this.setData({title:'onPlay'})\n },\n onPause(){\n console.log('onPause');\n this.setData({title:'onPause'})\n },\n onEnded(){\n console.log('onEnded');\n this.setData({title:'onEnded'});\n },\n onTimeUpdate(){\n console.log('onTimeUpdate');\n this.setData({title:'onTimeUpdate'})\n },\n onLoading(res){\n my.alert({ content: '\b\b加载中!' + JSON.stringify(res) });\n console.log('onLoading');\n this.setData({title:'onLoading'})\n },\n onStop(){\n console.log('onStop');\n this.setData({title:'onStop'})\n },\n play(){\n this.videoContext.play();\n this.videoContext.mute(this.muted);\n },\n pause(){\n this.videoContext.pause()\n },\n seek(){\n this.videoContext.seek(15)\n },\n mute(){\n this.videoContext.mute(!this.muted);\n this.muted = !this.muted;\n },\n stop(){\n this.videoContext.stop();\n this.setData({muted:this.muted.toString()})\n },\n playbackRate(res){\n this.videoContext.playbackRate(1.5),\n my.alert({content: '\b\b倍速播放中!' + JSON.stringify(res)});\n },\n requestFullScreen(){\n this.videoContext.requestFullScreen({ direction:90,});\n // setTimeout(() => { this.videoContext.exitFullScreen()},2000)\n },\n exitFullScreen(){\n this.videoContext.requestFullScreen();\n setTimeout(() => { this.videoContext.exitFullScreen()},2000)\n },\n showStatusBar(){\n this.videoContext.requestFullScreen();\n setTimeout(() => { this.videoContext.showStatusBar()},2000)\n },\n hideStatusBar(){\n this.videoContext.requestFullScreen();\n setTimeout(() => { this.videoContext.hideStatusBar()},2000)\n }\n});\n","page/component/video/video.json":"{\n \"defaultTitle\": \"video\"\n}","page/component/view/view.acss":".red {\n background: red;\n}\n.stream {\n display: flex;\n flex-direction: column;\n padding: 10rpx;\n}\n.post + .post {\n margin-top: 10rpx;\n}\n.post {\n display: flex;\n}\n.postUser {\n flex: 0 1 auto;\n padding-bottom: 20rpx;\n}\n.postUser__name {\n width: 180rpx;\n color: #57727C;\n font-size: 24rpx;\n font-weight: 700;\n line-height: 1;\n text-align: center;\n margin-top: 60rpx;\n}\n.postBody {\n flex: 1 1 0%;\n position: relative;\n padding: 30rpx;\n border: 2rpx solid #CAD0D2;\n border-radius: 8rpx;\n}\n.postBody:after,\n.postBody:before {\n right: 100%;\n top: 70rpx;\n border: solid transparent;\n content: \" \";\n height: 0;\n width: 0;\n position: absolute;\n pointer-events: none;\n}\n.postBody:after {\n border-color: transparent;\n border-right-color: #ffffff;\n border-width: 16rpx;\n margin-top: -16rpx;\n}\n.postBody:before {\n border-color: transparent;\n border-right-color: #CAD0D2;\n border-width: 18rpx;\n margin-top: -18rpx;\n}\n.postBody__content {\n color: #57727C;\n font-size: 24rpx;\n}\n.postBody__date {\n margin-top: 10rpx;\n color: #86969C;\n font-size: 20rpx;\n text-transform: uppercase;\n letter-spacing: 2rpx;\n}\n\n.red {\n color: red;\n}","page/component/view/view.axml":"<view class=\"page\">\n <view>\n <button a:if=\"{{returnIndex}}\" onTap=\"returnIndex\">回到首页</button>\n </view>\n <view class=\"page-description\">视图容器,相当于 web 的 div 或者 react-native 的 View。</view>\n <view class=\"page-section\">\n <view class=\"page-section-demo\">\n <view class=\"stream\">\n <view class=\"post\">\n <view class=\"postUser\">\n <view class=\"postUser__name\">Chris</view>\n </view>\n <view class=\"postBody\">\n <view class=\"postBody__content\">\n 欢迎使用淘宝商家应用!!!\n </view>\n <view class=\"postBody__date\">\n May 20\n </view>\n </view>\n </view>\n\n <view class=\"post\">\n <view class=\"postUser\">\n <view class=\"postUser__name\">Jack</view>\n </view>\n <view class=\"postBody\">\n <view class=\"postBody__content\">\n @Chris 我该如何上手?\n </view>\n <view class=\"postBody__date\">\n May 21\n </view>\n </view>\n </view>\n\n <view class=\"post\">\n <view class=\"postUser\">\n <view class=\"postUser__name\">Chris</view>\n </view>\n <view class=\"postBody\">\n <view class=\"postBody__content\">\n 你可以查看 Demo,对商家应用有一个简单的了解;然后下载我们的 IDE 进行开发。\n </view>\n <view class=\"postBody__date\">\n May 22\n </view>\n </view>\n </view>\n\n <view class=\"post\">\n <view class=\"postUser\">\n <view class=\"postUser__name\">Jessie</view>\n </view>\n <!-- hover red -->\n <view class=\"postBody\" hover-class=\"red\">\n <view class=\"postBody__content\">\n 赞!\n </view>\n <view class=\"postBody__date\" hidden>\n June 1\n </view>\n </view>\n </view>\n\n <view class=\"post\" hidden>\n <view class=\"postUser\">\n <view class=\"postUser__name\">Jessie</view>\n </view>\n <view class=\"postBody\">\n <view class=\"postBody__content\">\n 赞! +1\n </view>\n <view class=\"postBody__date\">\n June 1\n </view>\n </view>\n </view>\n </view>\n </view>\n </view>\n</view>","page/component/view/view.js":"Page({\n data: {\n pageName: 'component/view',\n },\n onLoad() {\n this.setData({\n returnIndex: getCurrentPages().length === 1,\n })\n },\n returnIndex() {\n my.switchTab({ url: '/page/tabBar/component/index' });\n },\n});\n","page/component/view/view.json":"{\n \"defaultTitle\": \"View\"\n}","page/component/vtabs/vtabs.acss":"","page/component/vtabs/vtabs.axml":"<view>\n <vtabs\n tabs=\"{{tabs}}\"\n onTabClick=\"handleChange\"\n onChange=\"onChange\"\n activeTab=\"{{activeTab}}\"\n tabBarActiveTextColor=\"#ff5500\"\n tabBarUnderlineColor=\"#ff5500\"\n >\n <block a:for=\"{{tabs}}\">\n <vtab-content anchor=\"{{item.anchor}}\">\n <view style=\"border: 1px solid #eee; height: 800px; box-sizing: border-box\">\n <text>content of {{item.title}}\n </text>\n </view>\n </vtab-content>\n </block>\n </vtabs>\n</view>","page/component/vtabs/vtabs.js":"Page({\n data: {\n activeTab: 2,\n tabs: [\n { title: '选项二', anchor: 'a', badgeType: 'dot' },\n { title: '选项', anchor: 'b', badgeType: 'text', badgeText: '新' },\n { title: '不超过五字', anchor: 'c' },\n { title: '选项四', anchor: 'd' },\n { title: '选项五', anchor: 'e' },\n { title: '选项六', anchor: 'f' },\n ],\n },\n handleChange(index) {\n this.setData({\n activeTab: index,\n });\n },\n onChange(index) {\n this.setData({\n activeTab: index,\n });\n },\n});\n","page/component/vtabs/vtabs.json":"{\n \"defaultTitle\": \"VTabs\",\n \"usingComponents\": {\n \"vtabs\": \"mini-antui/es/vtabs/index\",\n \"vtab-content\": \"mini-antui/es/vtabs/vtab-content/index\"\n },\n \"allowsBounceVertical\": false\n}","page/component/webview/webview.acss":"","page/component/webview/webview.axml":"<view class=\"page\">\n <web-view src=\"https://render.alipay.com/p/w/tinyapp-demo-h5/index.html\" onMessage=\"onmessage\"></web-view>\n</view>","page/component/webview/webview.js":"Page({\n data: {},\n onShareAppMessage(options) {\n my.alert({content:JSON.stringify(options.webViewUrl)});\n return {\n title: '分享 web-View 组件',\n desc: 'View 组件很通用',\n path: 'page/component/component-pages/webview/baidu',\n 'web-view': options.webViewUrl,\n };\n },\n onmessage(e){\n my.alert({\n content: '拿到数据'+JSON.stringify(e), // alert 框的标题\n });\n }\n});","page/component/webview/webview.json":"{}","page/tabBar/API/index.acss":".banner {\n width: 100%;\n background-color: #262833;\n background-size: 100%;\n background-repeat: no-repeat;\n position: relative;\n}\n\n.fake-searchbar {\n position: absolute;\n bottom: 0;\n left: 50%;\n transform: translate(-50%, 50%);\n height: 92rpx;\n width: 91.4%;\n display: flex;\n justify-content: center;\n align-items: center;\n background-color: #fff;\n border-radius: 4rpx;\n box-shadow: rgba(153, 153, 153, 0.24) 0 2px 7px;\n}\n\n.fake-placeholder {\n margin-left: 12rpx;\n color: rgba(153, 153, 153, 0.89);\n font-size: 28rpx;\n}\n\n.component-name {\n color: #333;\n margin-right: 10rpx;\n}\n\n.list {\n padding: 32rpx;\n}\n\n.list-header {\n height: 100rpx;\n display: flex;\n align-items: center;\n background-color: #fff;\n color: #333;\n font-weight: bold;\n font-size: 34rpx;\n padding-left: 32rpx;\n}\n\n.am-list-header {\n box-sizing: border-box;\n padding: 0;\n}\n\n.am-list-body::before {\n display: none;\n}\n\n.list-item {\n margin-bottom: 35rpx;\n}\n\n.am-list-item {\n padding-right: 15px;\n}\n\n.am-list-line {\n padding-right: 0;\n}","page/tabBar/API/index.axml":"<view>\n <view class=\"banner\" style=\"height:60rpx\">\n <view class=\"fake-searchbar\" onTap=\"onSearchBarTap\">\n <icon type=\"search\" size=\"14\" color=\"#1D1D1D\" />\n <text class=\"fake-placeholder\">搜索你想要的组件和API</text>\n </view>\n </view>\n <view class=\"list\" style=\"padding-top: 80rpx\">\n <block a:for=\"{{APIList}}\" a:for-item=\"list\">\n <list className=\"list-item\">\n <view slot=\"header\" class=\"list-header\">{{list.type}}</view>\n <block a:for=\"{{list.list}}\">\n <list-item arrow=\"{{true}}\" multipleLine=\"{{false}}\" key=\"items-{{item.name}}\" last=\"{{index === list.list.length - 1}}\">\n <navigator url=\"{{item.path}}\" style=\"display: flex; align-items: center\">\n <text class=\"component-name\">{{item.name}}</text>\n </navigator>\n </list-item>\n </block>\n </list>\n </block>\n </view>\n</view>","page/tabBar/API/index.js":"let openAPIList = [\n {\n name: '获取授权码',\n path: '/page/API/get-auth-code/get-auth-code',\n },\n];\n\nif (my.ap) {\n openAPIList = openAPIList.concat([\n {\n name: '获取用户信息',\n path: '/page/API/get-user-info/get-user-info',\n },\n {\n name: '发起支付',\n path: '/page/API/request-payment/request-payment',\n },\n {\n name: '淘宝卡包',\n path: '/page/API/card-pack/card-pack',\n },\n {\n name: '芝麻信用借还',\n path: '/page/API/zm-credit-borrow/zm-credit-borrow',\n },\n ]);\n\n if (my.canIUse('textRiskIdentification')) {\n openAPIList = openAPIList.concat([\n {\n name: '文本风险识别',\n path: '/page/API/text-risk-identification/text-risk-identification',\n },\n ]);\n }\n if (my.canIUse('generateImageFromCode')) {\n openAPIList = openAPIList.concat([\n {\n name: '生成二维码',\n path: '/page/API/generate-image-from-code/generate-image-from-code',\n },\n ]);\n }\n}\n\nlet interfaceList = [\n {\n name: '警告框',\n path: '/page/API/alert/alert',\n },\n {\n name: '确认框',\n path: '/page/API/confirm/confirm',\n },\n {\n name: '弱提示',\n path: '/page/API/toast/toast',\n },\n {\n name: '加载提示',\n path: '/page/API/loading/loading',\n },\n {\n name: '操作菜单',\n path: '/page/API/action-sheet/action-sheet',\n },\n {\n name: '设置界面导航栏',\n path: '/page/API/set-navigation-bar/set-navigation-bar',\n },\n // {\n // name: '设置optionMenu',\n // path: '/page/API/option-menu/option-menu',\n // },\n {\n name: '页面跳转',\n path: '/page/API/navigator/navigator',\n },\n // {\n // name: '下拉刷新',\n // path: '/page/API/pull-down-refresh/pull-down-refresh',\n // },\n {\n name: '创建动画',\n path: '/page/API/animation/animation',\n },\n {\n name: '创建绘画',\n path: '/page/API/canvas/canvas',\n },\n {\n name: '选择日期',\n path: '/page/API/date-picker/date-picker',\n },\n {\n name: '滚动页面',\n path: '/page/API/page-scroll-to/page-scroll-to',\n },\n {\n name: '节点查询',\n path: '/page/API/create-selector-query/create-selector-query',\n },\n];\n\nif (my.ap) {\n interfaceList = interfaceList.concat([\n {\n name: '联系人',\n path: '/page/API/contact/contact',\n },\n // {\n // name: '标题栏加载动画',\n // path: '/page/API/navigation-bar-loading/navigation-bar-loading',\n // },\n {\n name: '选择城市',\n path: '/page/API/choose-city/choose-city',\n },\n // {\n // name: '隐藏键盘',\n // path: '/page/API/keyboard/keyboard',\n // },\n ]);\n\n if (my.canIUse('multiLevelSelect')) {\n interfaceList = interfaceList.concat([\n // {\n // name: '级联选择',\n // path: '/page/API/multi-level-select/multi-level-select',\n // },\n ]);\n }\n\n if (my.canIUse('optionsSelect')) {\n interfaceList = interfaceList.concat([\n // {\n // name: '选项选择器',\n // path: '/page/API/options-select/options-select',\n // },\n ]);\n }\n\n if (my.canIUse('getTitleColor')) {\n interfaceList = interfaceList.concat([\n {\n name: '获取导航栏背景颜色',\n path: '/page/API/get-title-color/get-title-color',\n },\n ]);\n }\n}\n\nlet deviceAPIList = [\n {\n name: '获取手机网络状态',\n path: '/page/API/get-network-type/get-network-type',\n },\n {\n name: '获取手机系统信息',\n path: '/page/API/get-system-info/get-system-info',\n },\n {\n name: '振动',\n path: '/page/API/vibrate/vibrate',\n },\n {\n name: '剪贴板',\n path: '/page/API/clipboard/clipboard',\n },\n];\n\nif (my.ap) {\n deviceAPIList = deviceAPIList.concat([\n {\n name: '获取基础版本库',\n path: '/page/API/sdk-version/sdk-version',\n },\n {\n name: '屏幕亮度',\n path: '/page/API/screen/screen',\n },\n {\n name: '摇一摇',\n path: '/page/API/watch-shake/watch-shake',\n },\n {\n name: '拨打电话',\n path: '/page/API/make-phone-call/make-phone-call',\n },\n {\n name: '用户截屏事件',\n path: '/page/API/user-capture-screen/user-capture-screen',\n },\n {\n name: '获取服务器时间',\n path: '/page/API/get-server-time/get-server-time',\n },\n // {\n // name: '内存不足告警',\n // path: '/page/API/memory-warning/memory-warning',\n // },\n ]);\n}\n\nconst networkAPIList = [\n {\n name: '发起HTTP请求',\n path: '/page/API/request/request',\n },\n // {\n // name: '上传文件',\n // path: '/page/API/upload-file/upload-file',\n // },\n // {\n // name: '下载文件',\n // path: '/page/API/download-file/download-file',\n // },\n // {\n // name: 'Websocket',\n // path: '/page/API/websocket/websocket',\n // },\n];\n\nconst mediaAPIList = [\n {\n name: '图片',\n path: '/page/API/image/image',\n },\n // {\n // name: '获取图片信息',\n // path: '/page/API/get-image-info/get-image-info',\n // },\n // {\n // name: '压缩图片',\n // path: '/page/API/compress-image/compress-image',\n // },\n];\n\nconst locationAPIList = [\n {\n name: '获取当前位置',\n path: '/page/API/get-location/get-location',\n },\n // {\n // name: '使用原生地图查看位置',\n // path: '/page/API/open-location/open-location',\n // },\n // {\n // name: '打开地图选择位置',\n // path: '/page/API/choose-location/choose-location',\n // },\n];\n\nlet otherAPIList = [\n {\n name: '缓存',\n path: '/page/API/storage/storage',\n },\n {\n name: '扫码 Scan',\n path: '/page/API/scan-code/scan-code',\n },\n // {\n // name: '自定义分享',\n // path: '/page/API/share/share',\n // },\n];\n\nif (my.ap) {\n otherAPIList = otherAPIList.concat([\n {\n name: '文件',\n path: '/page/API/file/file',\n },\n // {\n // name: '蓝牙',\n // path: '/page/API/bluetooth/bluetooth',\n // },\n // {\n // name: '数据安全',\n // path: '/page/API/rsa/rsa',\n // },\n // {\n // name: '自定义分析',\n // path: '/page/API/report-analytics/report-analytics',\n // },\n ]);\n\n if (my.canIUse('on')) {\n otherAPIList = otherAPIList.concat([\n // {\n // name: '容器事件',\n // path: '/page/API/events/events',\n // },\n ]);\n }\n\n if (my.canIUse('ocr')) {\n otherAPIList = otherAPIList.concat([\n // {\n // name: 'OCR',\n // path: '/page/API/ocr/ocr',\n // },\n ]);\n }\n}\n\nconst APIList = [\n // {\n // type: '开放接口',\n // list: openAPIList,\n // },\n {\n type: '界面',\n list: interfaceList,\n },\n {\n type: '设备',\n list: deviceAPIList,\n },\n // {\n // type: '网络',\n // list: networkAPIList,\n // },\n {\n type: '多媒体',\n list: mediaAPIList,\n },\n {\n type: '位置',\n list: locationAPIList,\n },\n {\n type: '其他',\n list: otherAPIList,\n },\n];\n\nPage({\n data: {\n APIList,\n },\n onSearchBarTap() {\n my.navigateTo({\n url: '/page/common/search/search',\n });\n },\n});\n","page/tabBar/API/index.json":"{\n \"defaultTitle\": \"API\",\n \"titleBarColor\": \"#262833\",\n \"allowsBounceVertical\": \"NO\",\n \"transparentTitle\": \"none\",\n \"usingComponents\": {\n \"block-list\": \"/page/common/components/block-list/block-list\",\n \"list\":\"mini-antui/es/list/index\",\n \"list-item\":\"mini-antui/es/list/list-item/index\"\n }\n}","page/tabBar/component/index.acss":".banner {\n height: 455rpx;\n width: 100%;\n background-image: url('/image/component_bg.png');\n background-size: contain;\n background-repeat: no-repeat;\n position: relative;\n z-index: 2;\n}\n\n.logo {\n width: 105rpx;\n height: 117rpx;\n position: absolute;\n top: 122rpx;\n left: 50%;\n transform: translate(-50%);\n}\n\n.logo image {\n width: 100%;\n height: 100%;\n}\n\n.title {\n font-size: 46rpx;\n color: #fff;\n position: absolute;\n top: 260rpx;\n left: 50%;\n font-weight: bold;\n transform: translate(-50%);\n}\n\n.sub-title {\n color: rgba(255, 255, 255, 0.48);\n font-size: 24rpx;\n position: absolute;\n top: 330rpx;\n left: 50%;\n transform: translate(-50%);\n}\n\n.fake-searchbar {\n position: absolute;\n bottom: 0;\n left: 50%;\n transform: translate(-50%, 50%);\n height: 92rpx;\n width: 91.4%;\n display: flex;\n justify-content: center;\n align-items: center;\n background-color: #fff;\n border-radius: 4rpx;\n box-shadow: rgba(153, 153, 153, 0.24) 0 2px 7px;\n}\n\n.fake-placeholder {\n margin-left: 12rpx;\n color: rgba(153, 153, 153, 0.89);\n font-size: 28rpx;\n}\n\n.hot {\n padding-top: 60px;\n padding-bottom: 30rpx;\n padding-left: 4.26%;\n padding-right: 4.26%;\n box-sizing: border-box;\n}\n\n.tabs {\n height: 92rpx;\n position: sticky;\n background-color: #fff;\n z-index: 1;\n}\n\n.tabs.shadow {\n box-shadow: rgba(153, 153, 153, 0.24) 0 2px 7px;\n}\n\n.tabs-bar {\n padding: 0 64rpx;\n display: flex;\n height: 100%;\n}\n\n.tabs-bar-tab {\n bottom: 0;\n flex: 1;\n display: flex;\n justify-content: center;\n}\n\n.tabs-bar-tab {\n font-size: 32rpx;\n}\n\n.tabs-bar-tab-title {\n color: #999;\n padding: 16rpx 0;\n display: flex;\n align-items: center;\n border-bottom: 3px solid transparent;\n box-sizing: border-box;\n}\n\n.tabs-bar-tab-title.active {\n font-weight: bold;\n color: #ff5500;\n border-bottom: 3px solid #ff5500;\n}\n\n.component-name {\n color: rgb(51, 51, 51);\n margin-right: 10rpx;\n}\n\n.component-brief {\n color: #ccc;\n font-size: 34rpx;\n}\n\n.list {\n padding: 32rpx;\n flex-shrink: 0;\n box-sizing: border-box;\n width: 100%;\n}\n\n.list-header {\n padding-top: 40rpx;\n padding-bottom: 20rpx;\n display: flex;\n align-items: center;\n background-color: #fff;\n color: #333;\n font-weight: bold;\n font-size: 34rpx;\n padding-left: 32rpx;\n}\n\n.thumb {\n height: 60rpx;\n width: 60rpx;\n margin-right: 30rpx;\n}\n\n.am-list-header {\n box-sizing: border-box;\n padding: 0;\n}\n\n.am-list-body::before {\n display: none;\n}\n\n.list-item {\n margin-bottom: 35rpx;\n}\n\n.list-wrap {\n overflow: hidden;\n}\n\n.list-container {\n display: flex;\n width: 100%;\n transition-duration: 500ms;\n}\n","page/tabBar/component/index.axml":"<view>\n <view class=\"banner\">\n <view class=\"logo\" style=\"opacity: {{titleOpacity}}\"><image src=\"/image/component_logo.png\" mode=\"aspectFit\" /></view>\n <view class=\"title\" style=\"opacity: {{titleOpacity}}\">商家应用官方示例</view>\n <view class=\"sub-title\"style=\"opacity: {{titleOpacity}}\">以下展示商家应用官方组件和API</view>\n <view class=\"fake-searchbar\" onTap=\"onSearchBarTap\">\n <icon type=\"search\" size=\"14\" color=\"#1D1D1D\" />\n <text class=\"fake-placeholder\">搜索你想要的组件和API</text>\n </view>\n </view>\n <block-list listData=\"{{hot}}\" className=\"hot\" />\n <view class=\"tabs {{shadow ? 'shadow' : ''}}\" style=\"top: {{top}}px\">\n <view class=\"tabs-bar\">\n <block a:for=\"{{tabs}}\">\n <view class=\"tabs-bar-tab\" data-index=\"{{index}}\" onTap=\"onTabBarTap\">\n <view class=\"tabs-bar-tab-title {{activeTab === index ? 'active' : ''}}\">{{item}}</view>\n </view>\n </block>\n </view>\n </view>\n <view class=\"list-wrap\">\n <view class=\"list-container\" style=\"{{ transform: 'translate3d(' +(-activeTab * 100) + 'vw, 0, 0)' }}\">\n <view class=\"list\" style=\"{{ height: activeTab === 0 ? 'auto' : 0 }}\">\n <block a:for=\"{{basicComponentList}}\" a:for-item=\"list\">\n <list className=\"list-item\">\n <view slot=\"header\" class=\"list-header\">{{list.type}}</view>\n <block a:for=\"{{list.list}}\">\n <list-item arrow=\"{{true}}\" multipleLine=\"{{false}}\" key=\"items-{{item.name}}\" last=\"{{true}}\">\n <navigator url=\"{{item.path}}\" style=\"display: flex; align-items: center\">\n <image src=\"{{item.thumb}}\" class=\"thumb\" mode=\"aspectFit\" />\n <text class=\"component-name\">{{item.name}}</text>\n <text class=\"component-brief\">{{item.nameEn}}</text>\n </navigator>\n </list-item>\n </block>\n </list>\n </block>\n </view>\n <view class=\"list\" style=\"{{ height: activeTab === 1 ? 'auto' : 0 }}\">\n <block a:for=\"{{extComponentList}}\" a:for-item=\"list\">\n <list className=\"list-item\">\n <view slot=\"header\" class=\"list-header\">{{list.type}}</view>\n <block a:for=\"{{list.list}}\">\n <list-item arrow=\"{{true}}\" multipleLine=\"{{false}}\" key=\"items-{{item.name}}\" last=\"{{true}}\">\n <navigator url=\"{{item.path}}\" style=\"display: flex; align-items: center\">\n <image src=\"{{item.thumb}}\" class=\"thumb\" mode=\"aspectFit\" />\n <text class=\"component-name\">{{item.name}}</text>\n <text class=\"component-brief\">{{item.nameEn}}</text>\n </navigator>\n </list-item>\n </block>\n </list>\n </block>\n </view>\n </view>\n </view>\n</view>\n","page/tabBar/component/index.js":"const basicContainers = [\n {\n name: '基础视图',\n thumb: '/image/icon/view.png',\n nameEn: 'View',\n path: '/page/component/view/view',\n },\n {\n name: '滚动视图',\n thumb: '/image/icon/scroll-view.png',\n nameEn: 'ScrollView',\n path: '/page/component/scroll-view/scroll-view',\n },\n {\n name: '滑动视图',\n thumb: '/image/icon/swiper.png',\n nameEn: 'Swiper',\n path: '/page/component/swiper/swiper',\n },\n {\n name: '可移动视图',\n thumb: '/image/icon/movable-view.png',\n nameEn: 'MovableView',\n path: '/page/component/movable-view/movable-view',\n },\n {\n name: '原生视图',\n thumb: '/image/icon/cover-view.png',\n nameEn: 'CoverView',\n path: '/page/component/cover-view/cover-view',\n },\n];\n\nconst basicBasics = [\n {\n name: '文字',\n thumb: '/image/icon/text.png',\n nameEn: 'Text',\n path: '/page/component/text/text',\n },\n {\n name: '图标',\n thumb: '/image/icon/icon.png',\n nameEn: 'Icon',\n path: '/page/component/icon/icon',\n },\n {\n name: '富文本',\n thumb: '/image/icon/form.png',\n nameEn: 'RichText',\n path: '/page/component/rich-text/rich-text',\n },\n];\n\nconst basicFeedBacks = [\n {\n name: '进度条',\n thumb: '/image/icon/progress.png',\n nameEn: 'Progress',\n path: '/page/component/progress/progress',\n },\n];\n\nconst basicForms = [\n {\n name: '按钮',\n thumb: '/image/icon/button.png',\n nameEn: 'Button',\n path: '/page/component/button/button',\n },\n {\n name: '表单',\n thumb: '/image/icon/form.png',\n nameEn: 'Form',\n path: '/page/component/form/form',\n },\n {\n name: '标签',\n thumb: '/image/icon/label.png',\n nameEn: 'Label',\n path: '/page/component/label/label',\n },\n {\n name: '输入框',\n thumb: '/image/icon/input.png',\n nameEn: 'Input',\n path: '/page/component/input/input',\n },\n {\n name: '多行输入框',\n thumb: '/image/icon/textarea.png',\n nameEn: 'Textarea',\n path: '/page/component/textarea/textarea',\n },\n {\n name: '单选框',\n thumb: '/image/icon/radio.png',\n nameEn: 'Radio',\n path: '/page/component/radio/radio',\n },\n {\n name: '复选框',\n thumb: '/image/icon/checkbox.png',\n nameEn: 'Checkbox',\n path: '/page/component/checkbox/checkbox',\n },\n {\n name: '开关',\n thumb: '/image/icon/switch.png',\n nameEn: 'Switch',\n path: '/page/component/switch/switch',\n },\n {\n name: '滑动条',\n thumb: '/image/icon/slider.png',\n nameEn: 'Slider',\n path: '/page/component/slider/slider',\n },\n {\n name: '选择器视图',\n thumb: '/image/icon/picker-view.png',\n nameEn: 'PickerView',\n path: '/page/component/picker-view/picker-view',\n },\n // {\n // name: '选择器',\n // thumb: '/image/icon/picker.png',\n // nameEn: 'Picker',\n // path: '/page/component/picker/picker',\n // },\n];\n\nconst basicNavigators = [\n {\n name: '导航',\n thumb: '/image/icon/navigator.png',\n nameEn: 'Navigator',\n path: '/page/component/navigator/navigator',\n },\n];\n\nconst basicMedias = [\n {\n name: '图片',\n thumb: '/image/icon/image.png',\n nameEn: 'Image',\n path: '/page/component/image/image',\n },\n];\n\nconst basicMaps = [\n {\n name: '地图',\n thumb: '/image/icon/map.png',\n nameEn: 'Map',\n path: '/page/component/map/map',\n },\n];\n\nconst basicCanvas = [\n {\n name: '画布',\n thumb: '/image/icon/canvas.png',\n nameEn: 'Canvas',\n path: '/page/component/canvas/canvas',\n },\n];\n\nconst basicOpens = [\n {\n name: '内嵌webview',\n thumb: '/image/icon/webview.png',\n nameEn: 'Webview',\n path: '/page/component/webview/webview',\n },\n // {\n // name: '跳转生活号',\n // thumb: '/image/icon/lifestyle.png',\n // nameEn: 'Lifestyle',\n // path: '/page/component/lifestyle/lifestyle',\n // },\n // {\n // name: '跳转云客服',\n // thumb: '/image/icon/contact-button.png',\n // nameEn: 'contact-button',\n // path: '/page/component/contact-button/contact-button',\n // },\n // {\n // name: '收藏',\n // thumb: '/image/icon/favorite.png',\n // nameEn: 'Favorite',\n // path: '/page/component/favorite/favorite',\n // },\n];\n\nlet basicComponentList = [\n {\n type: '视图容器',\n list: basicContainers,\n },\n {\n type: '基础组件',\n list: basicBasics,\n },\n {\n type: '反馈',\n list: basicFeedBacks,\n },\n {\n type: '表单',\n list: basicForms,\n },\n {\n type: '导航',\n list: basicNavigators,\n },\n {\n type: '媒体',\n list: basicMedias,\n },\n {\n type: '画布',\n list: basicCanvas,\n },\n];\n\nif (my.ap) {\n basicComponentList = basicComponentList.concat([\n // {\n // type: '地图',\n // list: basicMaps,\n // },\n // {\n // type: '开放组件',\n // list: basicOpens,\n // },\n ]);\n}\n\nconst extContainers = [\n {\n name: '列表',\n thumb: '/image/icon/form.png',\n nameEn: 'List',\n path: '/page/component/list/list',\n },\n {\n name: '顶部选项卡',\n thumb: '/image/icon/tabs.png',\n nameEn: 'Tabs',\n path: '/page/component/tabs/tabs',\n },\n {\n name: '纵向选项卡',\n thumb: '/image/icon/vtabs.png',\n nameEn: 'VTabs',\n path: '/page/component/vtabs/vtabs',\n },\n {\n name: '卡片',\n thumb: '/image/icon/card.png',\n nameEn: 'Card',\n path: '/page/component/card/card',\n },\n {\n name: '宫格',\n thumb: '/image/icon/grid.png',\n nameEn: 'Grid',\n path: '/page/component/grid/grid',\n },\n {\n name: '步骤条',\n thumb: '/image/icon/steps.png',\n nameEn: 'Steps',\n path: '/page/component/steps/steps',\n },\n {\n name: '页脚',\n thumb: '/image/icon/footer.png',\n nameEn: 'Footer',\n path: '/page/component/footer/footer',\n },\n {\n name: 'Flex 布局',\n thumb: '/image/icon/view.png',\n nameEn: 'Flex',\n path: '/page/component/flex/flex',\n },\n];\n\nconst pops = [\n {\n name: '气泡',\n thumb: '/image/icon/popover.png',\n nameEn: 'Popover',\n path: '/page/component/popover/popover',\n },\n {\n name: '筛选',\n thumb: '/image/icon/filter.png',\n nameEn: 'Filter',\n path: '/page/component/filter/filter',\n },\n {\n name: '对话框',\n thumb: '/image/icon/modal.png',\n nameEn: 'Modal',\n path: '/page/component/modal/modal',\n },\n {\n name: '弹出菜单',\n thumb: '/image/icon/popup.png',\n nameEn: 'Popup',\n path: '/page/component/popup/popup',\n },\n];\n\nconst extForms = [\n {\n name: '文本输入',\n thumb: '/image/icon/input.png',\n nameEn: 'InputItem',\n path: '/page/component/input-item/input-item',\n },\n {\n name: '金额输入',\n thumb: '/image/icon/amount-input.png',\n nameEn: 'AmountInput',\n path: '/page/component/amount-input/amount-input',\n },\n {\n name: '搜索框',\n thumb: '/image/icon/search-bar.png',\n nameEn: 'SearchBar',\n path: '/page/component/search-bar/search-bar',\n },\n {\n name: '复选框',\n thumb: '/image/icon/radio.png',\n nameEn: 'AMCheckBox',\n path: '/page/component/am-checkbox/am-checkbox',\n },\n];\n\nconst results = [\n // {\n // name: '异常页',\n // thumb: '/image/icon/page-result.png',\n // nameEn: 'PageResult',\n // path: '/page/component/page-result/page-result',\n // },\n {\n name: '结果页',\n thumb: '/image/icon/message.png',\n nameEn: 'Message',\n path: '/page/component/message/message',\n },\n];\n\nconst tips = [\n {\n name: '引导',\n thumb: '/image/icon/tips.png',\n nameEn: 'Tips',\n path: '/page/component/tips/tips',\n },\n {\n name: '通告栏',\n thumb: '/image/icon/notice.png',\n nameEn: 'Notice',\n path: '/page/component/notice/notice',\n },\n {\n name: '徽标',\n thumb: '/image/icon/view.png',\n nameEn: 'Badge',\n path: '/page/component/badge/badge',\n },\n];\n\nconst gestures = [\n {\n name: '可滑动单元格',\n thumb: '/image/icon/swipe-action.png',\n nameEn: 'SwipeAction',\n path: '/page/component/swipe-action/swipe-action',\n },\n];\n\nconst inputs = [];\n\nconst others = [\n {\n name: '日历',\n thumb: '/image/icon/calendar.png',\n nameEn: 'Calendar',\n path: '/page/component/calendar/calendar',\n },\n {\n name: '步进器',\n thumb: '/image/icon/stepper.png',\n nameEn: 'Stepper',\n path: '/page/component/stepper/stepper',\n },\n {\n name: '图标',\n thumb: '/image/icon/icon.png',\n nameEn: 'AMIcon',\n path: '/page/component/am-icon/am-icon',\n },\n];\n\nconst extComponentList = [\n {\n type: '布局导航',\n list: extContainers,\n },\n {\n type: '操作浮层',\n list: pops,\n },\n {\n type: '结果类',\n list: results,\n },\n {\n type: '提示引导',\n list: tips,\n },\n {\n type: '表单类',\n list: extForms,\n },\n {\n type: '手势类',\n list: gestures,\n },\n {\n type: '其他',\n list: others,\n },\n];\n\nPage({\n data: {\n top: 0,\n hot: [\n { name: 'ScrollView', url: '/page/component/scroll-view/scroll-view' },\n { name: '地图', url: '/page/component/map/map' },\n { name: 'Icon', url: '/page/component/icon/icon' },\n { name: 'Card', url: '/page/component/card/card' },\n { name: '获取授权码', url: '/page/API/get-auth-code/get-auth-code' },\n { name: 'Popup', url: '/page/component/popup/popup' },\n // { name: '发起HTTP请求', url: '/page/API/request/request' },\n { name: '画布', url: '/page/component/canvas/canvas' },\n { name: '导航', url: '/page/API/navigator/navigator' },\n ],\n tabs: ['基础组件', '扩展组件'],\n activeTab: 0,\n basicComponentList,\n extComponentList,\n titleOpacity: 1,\n shadow: false,\n },\n onPageScroll(e) {\n const { scrollTop } = e;\n let titleOpacity = 1 - scrollTop * 0.02;\n let shadow = false;\n\n if (titleOpacity < 0) {\n titleOpacity = 0;\n }\n\n if (titleOpacity > 1) {\n titleOpacity = 1;\n }\n\n if (scrollTop > 80) {\n my.setNavigationBar({\n title: '商家应用官方示例',\n });\n } else {\n my.setNavigationBar({\n title: ' ',\n });\n }\n\n if (scrollTop > 320) {\n shadow = true;\n } else {\n shadow = false;\n }\n\n this.setData({\n shadow,\n titleOpacity,\n });\n },\n onSearchBarTap() {\n my.navigateTo({\n url: '/page/common/search/search',\n });\n },\n onTabBarTap(e) {\n const { index } = e.target.dataset;\n this.setData({\n activeTab: index,\n });\n },\n onLoad() {\n my.getSystemInfo({\n success: res => {\n if (res.statusBarHeight && res.titleBarHeight) {\n this.setData({\n top: res.statusBarHeight + res.titleBarHeight,\n });\n }\n },\n });\n },\n});\n","page/tabBar/component/index.json":"{\n \"defaultTitle\": \"\",\n \"allowsBounceVertical\": \"NO\",\n \"transparentTitle\": \"auto\",\n \"titleBarColor\": \"#262833\",\n \"usingComponents\": {\n \"block-list\": \"/page/common/components/block-list/block-list\",\n \"list\":\"mini-antui/es/list/index\",\n \"list-item\":\"mini-antui/es/list/list-item/index\"\n }\n}","README.md":"","util/debounce.js":"export default function debounce(fn, wait) {\n var timeout;\n return function() {\n var ctx = this, args = arguments;\n clearTimeout(timeout);\n timeout = setTimeout(function() {\n fn.apply(ctx, args);\n }, wait);\n };\n}\n"},"dist":[{"ETag":"190B10FE36F0717EBC7CF303E07A6DDC","name":"0.json","size":2321176,"type":"json","url":"https://gw.alipayobjects.com/os/tb_miniapp_doc/83297bd5-ac89-4a72-b606-2e4a0fd165a2/herbox/0.json"}],"name":"mini-program-demo","description":"","buildVersion":"0.72.7","preCompilerVersion":"0.4.0","component2":false}