From 605369e2c2f7a2ed575b387b5120491148e6b524 Mon Sep 17 00:00:00 2001 From: imouou Date: Fri, 31 May 2019 18:50:44 +0800 Subject: [PATCH] 1.5.3 --- docs/README.md | 2 + docs/_sidebar.md | 10 +- docs/changelog.md | 82 ++++++++++- docs/chapter1/about.md | 2 +- docs/chapter1/debug.md | 2 +- docs/chapter1/installation.md | 2 +- docs/chapter1/multipage.md | 2 +- docs/chapter1/quickstart.md | 56 +++---- docs/chapter1/why.md | 23 +-- docs/chapter2/controls.md | 3 +- docs/chapter2/life.md | 67 +++++++++ docs/chapter2/loader.md | 154 +++++++++++++++++++- docs/chapter2/router.md | 8 +- docs/controls/base/badges.md | 2 +- docs/controls/base/header.md | 2 +- docs/controls/base/icons.md | 2 +- docs/controls/base/navbar.md | 2 +- docs/controls/base/sub.md | 2 +- docs/controls/base/table.md | 2 +- docs/controls/base/tag.md | 2 +- docs/controls/form/form-view.md | 4 +- docs/controls/form/form.md | 26 ++-- docs/controls/main/accordion.md | 6 +- docs/controls/main/actionsheet.md | 6 +- docs/controls/main/animate.md | 4 +- docs/controls/main/btn.md | 4 +- docs/controls/main/dialog.md | 17 ++- docs/controls/main/dropdown.md | 6 +- docs/controls/main/hint.md | 4 +- docs/controls/main/input.md | 4 +- docs/controls/main/levelselect.md | 4 +- docs/controls/main/list-layout.md | 16 +- docs/controls/main/list.md | 8 +- docs/controls/main/listview.md | 11 ++ docs/controls/main/loading.md | 4 +- docs/controls/main/mask.md | 4 +- docs/controls/main/number.md | 4 +- docs/controls/main/pickerdate.md | 4 +- docs/controls/main/pullrefresh.md | 4 +- docs/controls/main/rating.md | 4 +- docs/controls/main/searchbar-head.md | 4 +- docs/controls/main/searchbar.md | 4 +- docs/controls/main/select-popup.md | 6 +- docs/controls/main/select.md | 8 +- docs/controls/main/sidebar.md | 6 +- docs/controls/main/slide.md | 12 +- docs/controls/main/stepbar.md | 6 +- docs/controls/main/storage.md | 6 +- docs/controls/main/store.md | 4 +- docs/controls/main/swipe.md | 10 +- docs/controls/main/tab-foot-dynamic.md | 4 +- docs/controls/main/tab-head-dynamic.md | 4 +- docs/controls/main/tab.md | 16 +- docs/controls/main/toggle.md | 4 +- docs/controls/main/upload.md | 4 +- docs/help.md | 5 +- docs/static/images/router/router_click.png | Bin 0 -> 151083 bytes docs/static/images/router/router_flow.png | Bin 87627 -> 214340 bytes docs/static/images/router/router_life.png | Bin 0 -> 195534 bytes docs/static/images/router/router_life2.png | Bin 0 -> 234037 bytes docs/static/images/router/router_main.png | Bin 0 -> 103775 bytes docs/store/about.md | 2 + docs/store/case.md | 116 ++++++++++++++- docs/store/debug.md | 7 + docs/store/distance.md | 162 +++++++++++++++------ docs/store/form.md | 7 +- docs/store/template-synatax.md | 2 +- docs/store/template.md | 101 +++++++++++-- docs/ui/standard.md | 4 +- 69 files changed, 851 insertions(+), 224 deletions(-) create mode 100644 docs/chapter2/life.md create mode 100644 docs/static/images/router/router_click.png create mode 100644 docs/static/images/router/router_life.png create mode 100644 docs/static/images/router/router_life2.png create mode 100644 docs/static/images/router/router_main.png create mode 100644 docs/store/debug.md diff --git a/docs/README.md b/docs/README.md index b334145..41c8676 100644 --- a/docs/README.md +++ b/docs/README.md @@ -9,6 +9,8 @@ | BUI 1.5.x 文档更新 |2018-11-06 | | BUI 1.5.1 文档更新 |2019-1-14 | | BUI 1.5.2 文档更新 |2019-3-19 | +| 更新数据驱动章节 |2019-4-01 | +| 更新模块生命周期章节 |2019-5-29 | !> 注意: `1.5.x` 的切图规范为 `750px` 设计稿, `1.4.x` 旧版切图规范为 `540px` 设计稿, 两者不能直接替换更新, 请先确保你的文档跟你当前开发的bui版本一致. `bui.version`可以查看版本, `bui.currentPlatform`可以查看当前`bui.js` 属于哪个平台. diff --git a/docs/_sidebar.md b/docs/_sidebar.md index 36fb98a..f1d35bb 100644 --- a/docs/_sidebar.md +++ b/docs/_sidebar.md @@ -1,4 +1,8 @@ -* [1.4.x 旧版教程入口](http://www.easybui.com/guide-1.4.x/) +* 链接 + * [1.4.x 旧版教程入口](http://www.easybui.com/guide-1.4.x/) + * [Link 专栏](linkapi.md) + * [BUI 专栏](article.md) + * 入门 @@ -13,8 +17,9 @@ * 进阶 - * [单页路由](chapter2/router.md) * [模块化](chapter2/loader.md) + * [单页路由](chapter2/router.md) + * [单页生命周期](chapter2/life.md) * [控件用法](chapter2/controls.md) * [动画交互](chapter2/animate.md) * [常用方法](chapter2/method.md) @@ -29,6 +34,7 @@ * [表单绑定](store/form.md) * [模板渲染](store/template.md) * [事件处理](store/event.md) + * [数据调试](store/debug.md) * [控件结合](store/controls.md) * [综合案例](store/case.md) diff --git a/docs/changelog.md b/docs/changelog.md index d66009b..1880f7f 100644 --- a/docs/changelog.md +++ b/docs/changelog.md @@ -3,7 +3,87 @@ ## 目录 [TOC] -## 1.5.2 20190328 +## 1.5.3 20190501 + +### 升级指南 + +** 一, 资源替换: ** + +执行命令, 选择你使用的平台, buijs 需要更新到 0.5.0 命令才会生效 + +``` +# 更新 webapp 平台 bui.css, bui.js +$ buijs update + +# 更新 dcloud 平台 bui.css, bui.js +$ buijs update -p dcloud + +# 更新 apicloud 平台 bui.css, bui.js +$ buijs update -p apicloud + +# 更新 appcan 平台 bui.css, bui.js +$ buijs update -p appcan +``` + +b-el bs.$els.demo.innerText +bs.items.$set +b-on +bs.$set +b-key +b-ref 子组件 + + +### 重要更新 + +微信IOS版运行的表单, 如果出现底部有灰色的区域, 监听取消焦点以后,调用scrollIntoView可以解决. +``` +router.$("input,textarea").on("blur", function() { + this.scrollIntoView(false) +}) +``` + +### bui.css +1. 修复默认路由跳转效果,在IPhone第一次跳会闪白问题. + +### bui.router +1. 优化firstAnimate参数, 当等于true时, 要跳转过去的页面如果是地图,chart等比较耗性能的页面, 应该采用这种动画优先的方式,避免跳转过程中渲染图表导致卡顿. 如果是跟 store 一起使用,则不建议开启, 会先跳转过去后再进行数据渲染. +2. 修复bui.back 如果是指定模块名时,后退的页面不正确. + +### bui.extend +1. 新增插件扩展 + +### bui.array +1. bui.array.set 支持替换整个数据 +2. bui.array.getAll 支持获取多个数组是否存在 + +### bui.store +1. 修复set 方法会触发2次trigger问题 +2. + +### bui.number +1. 新增 parentId 参数, 默认: .bui-page , 正常初始化一组, 只需一次, 不用id 参数, 这样即使在列表里的 number 动态的也能正常初始化. +2. + +### bui.getPageParams +1. 修复在单页路由的 bui.ready 里面拿不到页面参数问题 + +### bui.upload +1. startAll 方法,新增 needFileinfo参数, 可以把文件的基本信息一起传给接口, 对于实现一个页面多个上传类型,共享一个文件上传控件. + +### bui.searchbar +1. 新增value方法,获取当前的关键字. + +### bui.list, bui.pullrefresh, bui.scroll, bui.router, bui.tab, bui.slide +1. 新增resize方法 + +### bui.upload, bui.fileselect +1. 新增resize方法, 压缩图片 + +### bui.list +1. 新增autoUpdatePage参数,默认true +1. 新增updatePage方法, 用于手动更新判断是否还有最后一页数据. + +## 1.5.2 20190401 ### 升级指南 diff --git a/docs/chapter1/about.md b/docs/chapter1/about.md index 64626d5..d49a728 100644 --- a/docs/chapter1/about.md +++ b/docs/chapter1/about.md @@ -3,7 +3,7 @@ ## BUI 是什么? -?> BUI 是用来`快速构建界面交互`的UI框架, 专注webapp开发, 开发者只需关注业务的开发, 界面的布局及交互交给BUI, 开发出来的应用, `可以嵌入平台` ( 微信, 小程序, 钉钉, 淘宝, 支付宝等 ), 亦可以跟其它第三方平台`打包成独立应用`( Bingotouch , Cordova , Dcloud , APICloud , Appcan , 前海圆舟 等), 最终可以`全跨平台展示`. +?> BUI 是用来`快速构建界面交互`的UI交互框架, 专注webapp开发, 开发者只需关注业务的开发, 界面的布局及交互交给BUI, 开发出来的应用, `可以嵌入平台` ( Link, 微信, 小程序, 钉钉, 淘宝, 支付宝等 ), 亦可以跟其它第三方平台`打包成独立应用`( Bingotouch , Cordova , Dcloud , APICloud , Appcan , 前海圆舟 等), 最终可以`全跨平台展示`. ?> 结合BUI提供的[BUI-Fast编辑插件](buifast), [NPM工具](chapter1/installation), BUI更是一个移动快速开发的解决方案. 可以解决以下常见问题. diff --git a/docs/chapter1/debug.md b/docs/chapter1/debug.md index c439202..163b556 100644 --- a/docs/chapter1/debug.md +++ b/docs/chapter1/debug.md @@ -38,7 +38,7 @@ $ npm run dev js: -!> ajax请求的时候使用`相对路径`. +!> **注意:** ajax请求的时候请使用`相对路径`,这样代理才会正确转发. ``` bui.ajax({ diff --git a/docs/chapter1/installation.md b/docs/chapter1/installation.md index 31bff43..c44d1e5 100644 --- a/docs/chapter1/installation.md +++ b/docs/chapter1/installation.md @@ -5,6 +5,7 @@ 1. 编辑器 ( 推荐: `vscode`, `Atom` 或 `Sublimetext3` ); 2. `bui-fast` [点击下载](https://github.com/imouou/BUI-Fast-Snippets/releases) (配合编辑器快速书写插件, 支持 Vscode, Atom , Sublimetext , Webstorm , APICloudIDE ) [查看安装说明](tools/buifast.md); +3. [`buijs`](tools/buijs) cli工程构建工具, 用于快速构建工程,模板,更新平台等功能 ## 下载开发包 @@ -12,7 +13,6 @@ - [下载BUI单页开发包](http://www.easybui.com/downloads/source/bui/bui_router_dev_latest.zip) - - [下载BUI多页开发包](http://www.easybui.com/downloads/source/bui/bui_dev_latest.zip) ## 了解规范 diff --git a/docs/chapter1/multipage.md b/docs/chapter1/multipage.md index 5bead21..731c0aa 100644 --- a/docs/chapter1/multipage.md +++ b/docs/chapter1/multipage.md @@ -1,4 +1,4 @@ -# 多页路由 +# 多页路由开发 ?> [上一节](chapter1/quickstart) 我们用最简单的方式,创建了一个`index.html`, 当我们创建了多个页面以后, 就需要页面跳转了. diff --git a/docs/chapter1/quickstart.md b/docs/chapter1/quickstart.md index 9904aae..f4368d4 100644 --- a/docs/chapter1/quickstart.md +++ b/docs/chapter1/quickstart.md @@ -74,16 +74,7 @@ *焦点图结构* ```html -
-
-
    -
  • - - -
  • -
-
-
+
``` !> 脚本初始化必须在 `bui.ready` 里面执行, 多页开发`一个页面对应一个` bui.ready 其它自由编写, 便于自己维护就好. @@ -93,10 +84,17 @@ ```js // 焦点图控件初始化 var uiSlide = bui.slide({ - id:"#uiSlide", - height:380, - autopage:true - }) + id: "#slide", + height: 380, + autopage: true, + data: [{ + image: "images/banner01.png", + url: "pages/ui_controls/bui.slide_title.html", + },{ + image: "images/banner02.png", + url: "pages/ui_controls/bui.slide_title.html", + }] + }) ``` ?> 给实例增加事件监听. @@ -148,20 +146,7 @@
-
-
-
    -
  • - - -
  • -
  • - - -
  • -
-
-
+