From 8d217d1e40cb779e1e8939c8be5d44799aed645e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E5=B0=8Fo?= Date: Fri, 2 Sep 2022 17:40:24 +0800 Subject: [PATCH] =?UTF-8?q?=E9=87=8D=E6=96=B0=E6=95=B4=E7=90=86=E5=85=A5?= =?UTF-8?q?=E9=97=A8=E6=96=87=E6=A1=A3=201.7.x?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/chapter1/dev.html | 128 ++++ docs/chapter1/dev.md | 4 +- docs/chapter1/layout2.md | 2 +- docs/chapter1/quickstart.html | 306 +++++++++ docs/chapter1/quickstart.md | 2 +- docs/chapter1/quickstart2.md | 2 +- docs/chapter2/communication.md | 4 +- docs/chapter2/mpa/quickstart.md | 2 +- docs/controls/README.md | 2 +- docs/controls/base/badges.md | 2 +- docs/controls/base/header.md | 2 +- docs/controls/base/icons.md | 2 +- docs/controls/base/layout.md | 2 +- docs/controls/base/nav.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 | 12 +- docs/controls/main/accordion.md | 2 +- docs/controls/main/actionsheet.md | 4 +- docs/controls/main/animate.md | 2 +- docs/controls/main/btn.md | 2 +- docs/controls/main/dialog.md | 8 +- docs/controls/main/dropdown.md | 4 +- docs/controls/main/floor.md | 4 +- docs/controls/main/hint.md | 2 +- docs/controls/main/input.md | 2 +- docs/controls/main/levelselect.md | 2 +- docs/controls/main/list-layout.md | 16 +- docs/controls/main/list.md | 6 +- docs/controls/main/listview.md | 4 +- docs/controls/main/loading.md | 2 +- docs/controls/main/mask.md | 2 +- docs/controls/main/number.md | 2 +- docs/controls/main/pickerdate.md | 2 +- docs/controls/main/pullrefresh.md | 2 +- docs/controls/main/rating.md | 2 +- docs/controls/main/searchbar-head.md | 2 +- docs/controls/main/searchbar.md | 2 +- docs/controls/main/select-popup.md | 4 +- docs/controls/main/select.md | 6 +- docs/controls/main/sidebar.md | 4 +- docs/controls/main/slide.md | 10 +- docs/controls/main/stepbar.md | 4 +- docs/controls/main/storage.md | 4 +- docs/controls/main/store.md | 2 +- docs/controls/main/swipe.md | 8 +- docs/controls/main/tab-foot-dynamic.md | 2 +- docs/controls/main/tab-head-dynamic.md | 2 +- docs/controls/main/tab.md | 14 +- docs/controls/main/toggle.md | 2 +- docs/controls/main/upload.md | 2 +- docs/linkapi.md | 5 +- docs/prepros-6.config | 10 +- docs/prepros.config | 912 ------------------------- docs/store/about.md | 2 +- docs/store/attribute.md | 4 +- docs/store/case.md | 8 +- docs/store/class.md | 4 +- docs/store/computed.md | 4 +- docs/store/controls.md | 8 +- docs/store/distance.md | 2 +- docs/store/event.md | 2 +- docs/store/form-dynamic.md | 2 +- docs/store/form.md | 12 +- docs/store/mixins.md | 2 +- docs/store/template.md | 2 +- 68 files changed, 560 insertions(+), 1041 deletions(-) create mode 100644 docs/chapter1/dev.html create mode 100644 docs/chapter1/quickstart.html delete mode 100644 docs/prepros.config diff --git a/docs/chapter1/dev.html b/docs/chapter1/dev.html new file mode 100644 index 0000000..e402130 --- /dev/null +++ b/docs/chapter1/dev.html @@ -0,0 +1,128 @@ + + + + dev.md + + +

开发方式

+

一、单页开发

+

下载单页开发包

+ +

!> 单页开发预览需要IIS部署,或者node工程的支持,默认需要3个文件。

+

index.html

+
<!DOCTYPE html>
+<html>
+    <head>
+        <meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
+        <title>BUI</title>
+        <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/buijs@latest/lib/latest/bui.css" />
+    </head>
+    <body>
+        <div id="bui-router"></div>
+
+        <!-- content -->
+        <script src="https://cdn.jsdelivr.net/npm/buijs@latest/lib/zepto.js"></script>
+        <script src="https://cdn.jsdelivr.net/npm/buijs@latest/lib/latest/bui.js"></script>
+        <script>
+            // router init
+            window.router = bui.router();
+
+            bui.ready(function(global){
+                // router init, will find default page. pages/main/main.html pages/main/main.js 
+                router.init({
+                    id: "#bui-router"
+                })
+            })
+        </script>
+    </body>
+</html>
+
+

pages/main/main.html

+
<!-- BUI标准结构 -->
+<div class="bui-page bui-box-vertical">
+    <header>
+        <!-- 顶部固定内容 -->
+        <div class="bui-bar">
+            <div class="bui-bar-left">
+                <div class="bui-btn"><i class="icon-back"></i></div>
+            </div>
+            <div class="bui-bar-main">BUI首页</div>
+            <div class="bui-bar-right"></div>
+        </div>
+    </header>
+    <main>
+        <!-- 中间滚动内容 -->
+        <div class="bui-btn warning">中间按钮</div>
+    </main>
+    <footer>
+        <!-- 底部固定内容 -->
+        <div class="bui-btn primary">底部按钮</div>
+    </footer>
+</div>
+
+

pages/main/main.js 特定的模块包装

+
loader.define(function(requires,exports,module,global){
+    // requires: 加载模块
+    // module: 模块信息
+    // global: 获取全局方法
+    bui.alert("done");
+
+})
+
+

二、多页开发

+

下载多页开发包

+ +

index.html

+

+<!DOCTYPE HTML>
+<html>
+    <head>
+        <meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
+        <title>BUI</title>
+        <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/buijs@latest/lib/latest/bui.css" />
+    </head>
+    <body>
+        <!-- BUI标准结构 -->
+        <div class="bui-page bui-box-vertical">
+            <header>
+                <!-- 顶部固定内容 -->
+                <div class="bui-bar">
+                    <div class="bui-bar-left">
+                        <div class="bui-btn"><i class="icon-back"></i></div>
+                    </div>
+                    <div class="bui-bar-main">BUI首页</div>
+                    <div class="bui-bar-right"></div>
+                </div>
+            </header>
+            <main>
+                <!-- 中间滚动内容 -->
+                <div class="bui-btn warning">中间按钮</div>
+            </main>
+            <footer>
+                <!-- 底部固定内容 -->
+                <div class="bui-btn primary">底部按钮</div>
+            </footer>
+        </div>
+
+        <script src="https://cdn.jsdelivr.net/npm/buijs@latest/lib/zepto.js"></script>
+        <script src="https://cdn.jsdelivr.net/npm/buijs@latest/lib/latest/bui.js"></script>
+        <script>
+            bui.ready(function(global){
+                // init
+                bui.alert("done")
+            })
+        </script>
+    </body>
+</html>
+
+
+

点击在线预览

+ + + \ No newline at end of file diff --git a/docs/chapter1/dev.md b/docs/chapter1/dev.md index 17977aa..cfe2b1e 100644 --- a/docs/chapter1/dev.md +++ b/docs/chapter1/dev.md @@ -2,12 +2,12 @@ ### 一、单页开发 -[下载单页开发包](http://easybui.com/downloads/source/bui/bui_router_dev_latest.zip) +[下载单页开发包](https://www.easybui.com/p/download.html) * 优点:体验好,媲美app,操控强,按需加载或一次性加载; * 缺点:不支持后端语言输出展示,不支持seo; -!> 单页开发预览需要部署,或者node工程的支持,默认需要3个文件,。 +!> 单页开发预览需要IIS部署,或者node工程的支持,默认需要3个文件。 *index.html* diff --git a/docs/chapter1/layout2.md b/docs/chapter1/layout2.md index 0296869..c4746ea 100644 --- a/docs/chapter1/layout2.md +++ b/docs/chapter1/layout2.md @@ -1,7 +1,7 @@ # 布局 - + ## 弹性布局 diff --git a/docs/chapter1/quickstart.html b/docs/chapter1/quickstart.html new file mode 100644 index 0000000..26c84c3 --- /dev/null +++ b/docs/chapter1/quickstart.html @@ -0,0 +1,306 @@ + + + + quickstart.md + + +

快速入门

+
+

有Node基础,使用第一种方式即可,无Node基础,可以按第二种方式操作一次。

+
+

一、下载开发包并解压

+

下载单页开发包

+

修改解压的目录名为 demo, 打开终端命令行。

+
    +
  1. npm 安装依赖即可预览
    # 进入工程目录
    +cd demo
    +# 安装依赖,加上淘宝源会速度快一点,或使用cnpm
    +npm install --registry=https://registry.npm.taobao.org
    +# 运行预览
    +npm run dev
    +
    +
  2. +
+

效果预览

+

+

二、 使用CDN版本

+ +

1. 新建 index.html 页面

+

+<!DOCTYPE HTML>
+<html>
+    <head>
+        <meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
+        <title>BUI</title>
+        <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/buijs@latest/lib/latest/bui.css" />
+    </head>
+    <body>
+        <!-- 结构内容位置 -->
+
+        <script src="https://cdn.jsdelivr.net/npm/buijs@latest/lib/zepto.js"></script>
+        <script src="https://cdn.jsdelivr.net/npm/buijs@latest/lib/latest/bui.js"></script>
+        <script>
+            // 多页开发: 一个页面必须要有一个 bui.ready, 且只能有一个
+            bui.ready(function(global){
+                // init
+                bui.alert("done")
+            })
+        </script>
+    </body>
+</html>
+
+
+

2. 新增BUI标准结构

+

放在body结构里面。

+
<!-- BUI标准结构 -->
+<div class="bui-page bui-box-vertical">
+    <header>
+        <!-- 顶部固定内容 -->
+        <div class="bui-bar">
+            <div class="bui-bar-left">
+                <div class="bui-btn"><i class="icon-back"></i></div>
+            </div>
+            <div class="bui-bar-main">BUI首页</div>
+            <div class="bui-bar-right"></div>
+        </div>
+    </header>
+    <main>
+        <!-- 中间滚动内容 -->
+    </main>
+    <footer>
+        <!-- 底部固定内容 -->
+    </footer>
+</div>
+
+
+

3. 使用BUI控件

+

一个控件包含结构与初始化脚本,分别增加到main内容里面,以及bui.ready的初始化里面。

+
<!-- 轮播图结构 -->
+<div id="uiSlide" class="bui-slide"></div>
+
+
+
// 轮播图控件初始化
+var uiSlide = bui.slide({
+        id: "#uiSlide",
+        height: 380,
+        autopage: true,
+        data: [{
+            image: "http://easybui.com/demo/images/banner01.png",
+        },{
+            image: "http://easybui.com/demo/images/banner02.png",
+        }]
+    })
+
+

完整代码

+

+<!DOCTYPE HTML>
+<html>
+    <head>
+        <title>BUI</title>
+        <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/buijs@latest/lib/latest/bui.css" />
+    </head>
+    <body>
+        <!-- BUI标准结构 -->
+        <div class="bui-page bui-box-vertical">
+            <header>
+                <!-- 顶部固定内容 -->
+                <div class="bui-bar">
+                    <div class="bui-bar-left">
+                        <div class="bui-btn"><i class="icon-back"></i></div>
+                    </div>
+                    <div class="bui-bar-main">BUI首页</div>
+                    <div class="bui-bar-right"></div>
+                </div>
+            </header>
+            <main>
+                <!-- 中间滚动内容 -->
+                <div id="uiSlide" class="bui-slide"></div>
+
+            </main>
+            <footer>
+                <!-- 底部固定内容 -->
+            </footer>
+        </div>
+        <script src="https://cdn.jsdelivr.net/npm/buijs@latest/lib/zepto.js"></script>
+        <script src="https://cdn.jsdelivr.net/npm/buijs@latest/lib/latest/bui.js"></script>
+        <script>
+            // 多页开发: 一个页面必须要有一个 bui.ready, 且只能有一个
+            bui.ready(function(global){
+                // init
+                // 轮播图控件初始化
+                var uiSlide = bui.slide({
+                        id: "#uiSlide",
+                        height: 380,
+                        autopage: true,
+                        data: [{
+                            image: "http://easybui.com/demo/images/banner01.png",
+                        },{
+                            image: "http://easybui.com/demo/images/banner02.png",
+                        }]
+                    })
+            })
+        </script>
+    </body>
+</html>
+
+
+
+

以上是BUI最基础的用法,简单好理解,但随着需求的变更,慢慢就越写越乱,不好维护。需要组件化把可以复用的代码抽离,比方轮播图是可以公共使用的。

+
+

4. 新增自定义组件

+

还是以轮播图组件为例子,抽离原本的代码,做参数合并操作。单页多页都是一样的用法。

+
+

组件化以后,需要部署或打开跨域的chrome才能访问。

+
+

pages/slide.html

+
<div class="bui-slide"></div>
+
+

pages/slide.js

+
// 组件包装器
+loader.define(function(requires, exports, module, global){
+
+  // 接收参数 1.6.x 支持
+    // let props = bui.history.getParams(module.id);
+
+    // 接收参数 1.7.x 支持
+    let props = module.props;
+
+    // 合并默认参数,如果没传参数则使用默认,可以保证组件正常展示。
+    let params = $.extend(true,{
+          height: 380,
+          autopage: true,
+          loop: true,
+          data: [{ image: "http://easybui.com/demo/images/banner01.png" }]
+      },props);
+
+      // id比较特殊,需要改成通过component生成的id 
+      params.id = `#${module.id} .bui-slide`;
+
+    // 轮播图控件初始化
+    const uiSlide = bui.slide(params);
+
+    // 抛出接口供外部调用
+    return uiSlide;
+})
+
+

在页面的任何地方,使用component 标签即可使用。

+
<component id="homeSlide" name="pages/slide" height="300"></component>
+<component id="tabSlide" name="pages/slide" height="200"></component>
+
+

完整代码:

+

+<!DOCTYPE HTML>
+<html>
+    <head>
+        <title>BUI</title>
+        <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/buijs@latest/lib/latest/bui.css" />
+    </head>
+    <body>
+        <!-- BUI标准结构 -->
+        <div class="bui-page bui-box-vertical">
+            <header>
+                <!-- 顶部固定内容 -->
+                <div class="bui-bar">
+                    <div class="bui-bar-left">
+                        <div class="bui-btn"><i class="icon-back"></i></div>
+                    </div>
+                    <div class="bui-bar-main">BUI首页</div>
+                    <div class="bui-bar-right"></div>
+                </div>
+            </header>
+            <main>
+                <!-- 中间滚动内容 -->
+                <component id="homeSlide" name="pages/slide" height="300"></component>
+
+            </main>
+            <footer>
+                <!-- 底部固定内容 -->
+            </footer>
+        </div>
+        <script src="https://cdn.jsdelivr.net/npm/buijs@latest/lib/zepto.js"></script>
+        <script src="https://cdn.jsdelivr.net/npm/buijs@latest/lib/latest/bui.js"></script>
+        <script>
+            // 多页开发: 一个页面必须要有一个 bui.ready, 且只能有一个
+            bui.ready(function(global){
+                // init
+
+            })
+        </script>
+    </body>
+</html>
+
+
+

5. 组件动态传参

+

部分参数我们通过属性的方式传过去,对象类型的参数则需要动态传过去。

+
<component id="homeSlide" name="pages/slide" delay="true"></component>
+
+
// 动态编译,且只编译一次,参数只传一次
+loader.delay({
+    id:"#homeSlide",
+    param: {
+        height: 300,
+        data: [{ image: "http://easybui.com/demo/images/banner01.png" },
+        { image: "http://easybui.com/demo/images/banner02.png" }]
+    }
+})
+
+

完整代码

+

+<!DOCTYPE HTML>
+<html>
+    <head>
+        <title>BUI</title>
+        <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/buijs@latest/lib/latest/bui.css" />
+    </head>
+    <body>
+        <!-- BUI标准结构 -->
+        <div class="bui-page bui-box-vertical">
+            <header>
+                <!-- 顶部固定内容 -->
+                <div class="bui-bar">
+                    <div class="bui-bar-left">
+                        <div class="bui-btn"><i class="icon-back"></i></div>
+                    </div>
+                    <div class="bui-bar-main">BUI首页</div>
+                    <div class="bui-bar-right"></div>
+                </div>
+            </header>
+            <main>
+                <!-- 中间滚动内容 -->
+                <component id="homeSlide" name="pages/slide" delay="true"></component>
+
+            </main>
+            <footer>
+                <!-- 底部固定内容 -->
+            </footer>
+        </div>
+        <script src="https://cdn.jsdelivr.net/npm/buijs@latest/lib/zepto.js"></script>
+        <script src="https://cdn.jsdelivr.net/npm/buijs@latest/lib/latest/bui.js"></script>
+        <script>
+            // 多页开发: 一个页面必须要有一个 bui.ready, 且只能有一个
+            bui.ready(function(global){
+                // 动态编译传参,且只编译一次,参数只传一次
+                loader.delay({
+                    id:"#homeSlide",
+                    param: {
+                        height: 300,
+                        data: [{ image: "http://easybui.com/demo/images/banner01.png" },
+                        { image: "http://easybui.com/demo/images/banner02.png" }]
+                    }
+                })
+            })
+        </script>
+    </body>
+</html>
+
+
+

更多内容请继续参考文档或实践。

+ + + \ No newline at end of file diff --git a/docs/chapter1/quickstart.md b/docs/chapter1/quickstart.md index 6dad16a..6805d64 100644 --- a/docs/chapter1/quickstart.md +++ b/docs/chapter1/quickstart.md @@ -4,7 +4,7 @@ ### 一、下载开发包并解压 -[下载单页开发包](http://easybui.com/downloads/source/bui/bui_router_dev_latest.zip) +[下载单页开发包](https://www.easybui.com/p/download.html) 修改解压的目录名为 demo, 打开终端命令行。 diff --git a/docs/chapter1/quickstart2.md b/docs/chapter1/quickstart2.md index b0c9a94..70b624a 100644 --- a/docs/chapter1/quickstart2.md +++ b/docs/chapter1/quickstart2.md @@ -137,7 +137,7 @@ uiSlide.to(1); ?> 最终组合以后的代码, 你可以点击这里 在线预览效果 - + _index.html_ diff --git a/docs/chapter2/communication.md b/docs/chapter2/communication.md index f25d988..f9d7967 100644 --- a/docs/chapter2/communication.md +++ b/docs/chapter2/communication.md @@ -1,6 +1,6 @@ # 组件通讯 -## 组件同步通讯 +## 一、组件同步通讯 > 1.7.x 以上版本 @@ -174,7 +174,7 @@ loader.define(function (requires, exports, module, global) { }); ``` -## 组件异步通讯 +## 二、组件异步通讯 组件异步通讯的开发方式太过零散,已经不推荐了 diff --git a/docs/chapter2/mpa/quickstart.md b/docs/chapter2/mpa/quickstart.md index 95011ff..78f95db 100644 --- a/docs/chapter2/mpa/quickstart.md +++ b/docs/chapter2/mpa/quickstart.md @@ -137,7 +137,7 @@ uiSlide.to(1); ?> 最终组合以后的代码, 你可以点击这里 在线预览效果 - + _index.html_ diff --git a/docs/controls/README.md b/docs/controls/README.md index 006273e..40f28ea 100644 --- a/docs/controls/README.md +++ b/docs/controls/README.md @@ -4,7 +4,7 @@ [Demo](http://easybui.com/demo/) - + ## 控件示例说明 diff --git a/docs/controls/base/badges.md b/docs/controls/base/badges.md index e9490ce..2c8c1ad 100644 --- a/docs/controls/base/badges.md +++ b/docs/controls/base/badges.md @@ -1,4 +1,4 @@ # 红点提醒 - + diff --git a/docs/controls/base/header.md b/docs/controls/base/header.md index 2bdd721..7398ef4 100644 --- a/docs/controls/base/header.md +++ b/docs/controls/base/header.md @@ -1,4 +1,4 @@ # 头部 - + diff --git a/docs/controls/base/icons.md b/docs/controls/base/icons.md index 4468c46..55ba36c 100644 --- a/docs/controls/base/icons.md +++ b/docs/controls/base/icons.md @@ -10,5 +10,5 @@ !> 如果要引入第三方图标库, 第三方图标库不能以`icon`,`icon-` 命名, 可以全部修改为 `icons-` 之类的, 或者在下载图标库前, 进行配置. - + diff --git a/docs/controls/base/layout.md b/docs/controls/base/layout.md index b970136..289ebe1 100644 --- a/docs/controls/base/layout.md +++ b/docs/controls/base/layout.md @@ -1,7 +1,7 @@ # 布局 - + ## 弹性布局 diff --git a/docs/controls/base/nav.md b/docs/controls/base/nav.md index aeb7dbf..860bd67 100644 --- a/docs/controls/base/nav.md +++ b/docs/controls/base/nav.md @@ -1,4 +1,4 @@ # 导航 - \ No newline at end of file + \ No newline at end of file diff --git a/docs/controls/base/sub.md b/docs/controls/base/sub.md index f413f0c..78b4bd3 100644 --- a/docs/controls/base/sub.md +++ b/docs/controls/base/sub.md @@ -1,4 +1,4 @@ # 角标 - + diff --git a/docs/controls/base/table.md b/docs/controls/base/table.md index 85042dc..adc1ea4 100644 --- a/docs/controls/base/table.md +++ b/docs/controls/base/table.md @@ -1,4 +1,4 @@ # 表格 - + diff --git a/docs/controls/base/tag.md b/docs/controls/base/tag.md index b6e5790..9315418 100644 --- a/docs/controls/base/tag.md +++ b/docs/controls/base/tag.md @@ -1,4 +1,4 @@ # 标签 - + diff --git a/docs/controls/form/form-view.md b/docs/controls/form/form-view.md index a9a53e3..c6b8d6a 100644 --- a/docs/controls/form/form-view.md +++ b/docs/controls/form/form-view.md @@ -2,8 +2,8 @@ ## 表单展示 - + ## 表单填写 - + diff --git a/docs/controls/form/form.md b/docs/controls/form/form.md index d44d0fd..ebabccd 100644 --- a/docs/controls/form/form.md +++ b/docs/controls/form/form.md @@ -2,7 +2,7 @@ ## 按钮效果 - + ## 单选框 @@ -27,20 +27,20 @@ var val = $('.radio[name="interest2"]:checked').val(); ``` - + ## 复选框 - + ## 开关按钮 - + ## 滑动条 - + ## 进度条 - + diff --git a/docs/controls/main/accordion.md b/docs/controls/main/accordion.md index 316ce95..a17de31 100644 --- a/docs/controls/main/accordion.md +++ b/docs/controls/main/accordion.md @@ -6,4 +6,4 @@ ?> 可以控制全部展示,还是一次只展示一个. - + diff --git a/docs/controls/main/actionsheet.md b/docs/controls/main/actionsheet.md index c5fc5b5..9ad2b48 100644 --- a/docs/controls/main/actionsheet.md +++ b/docs/controls/main/actionsheet.md @@ -4,8 +4,8 @@ ## 弹出菜单 - + ## 自定义弹出菜单 - + diff --git a/docs/controls/main/animate.md b/docs/controls/main/animate.md index a71bbcd..c3c31e0 100644 --- a/docs/controls/main/animate.md +++ b/docs/controls/main/animate.md @@ -2,4 +2,4 @@ [查看 API](http://www.easybui.com/guide/api/classes/bui.animate.html) - + diff --git a/docs/controls/main/btn.md b/docs/controls/main/btn.md index e1120e2..dc69e44 100644 --- a/docs/controls/main/btn.md +++ b/docs/controls/main/btn.md @@ -4,4 +4,4 @@ ?> 用于绑定按钮上带有 href 属性的跳转, 单页开发只需要在`index.js` 绑定一次就可以了. - + diff --git a/docs/controls/main/dialog.md b/docs/controls/main/dialog.md index 61ff8c0..f1dff5b 100644 --- a/docs/controls/main/dialog.md +++ b/docs/controls/main/dialog.md @@ -6,7 +6,7 @@ ?> 如果是一个对象,会变成字符串. 如果要定制弹出框样式,可以使用 `bui.confirm` - + ## 确认框 @@ -14,7 +14,7 @@ ?> 支持传对象参数,`content`参数支持 html 结构 - + ## 弹出输入 @@ -22,7 +22,7 @@ ?> 支持传对象参数,`content`参数支持 html 结构 - + ## 自定义对话框 @@ -30,4 +30,4 @@ ?> `bui.alert`,`bui.confirm` 等都是基于 `bui.dialog` 创建, dialog 非常灵活,可以设置全屏,可以自由定制交互,可以自定义位置等, 具体使用请查看 api. - + diff --git a/docs/controls/main/dropdown.md b/docs/controls/main/dropdown.md index 1b482d0..a92a0cc 100644 --- a/docs/controls/main/dropdown.md +++ b/docs/controls/main/dropdown.md @@ -4,8 +4,8 @@ ## 普通下拉菜单 - + ## 二级下拉菜单 - + diff --git a/docs/controls/main/floor.md b/docs/controls/main/floor.md index 5063fb3..f2ed49f 100644 --- a/docs/controls/main/floor.md +++ b/docs/controls/main/floor.md @@ -6,8 +6,8 @@ ## 楼层滚动 - + ## 通讯录 - + diff --git a/docs/controls/main/hint.md b/docs/controls/main/hint.md index 453a4c3..dbe72f1 100644 --- a/docs/controls/main/hint.md +++ b/docs/controls/main/hint.md @@ -4,4 +4,4 @@ ?> 可以控制不同位置,并且可以不自动消失 - + diff --git a/docs/controls/main/input.md b/docs/controls/main/input.md index ee8d179..1afb16d 100644 --- a/docs/controls/main/input.md +++ b/docs/controls/main/input.md @@ -2,4 +2,4 @@ [查看 API](http://www.easybui.com/guide/api/classes/bui.input.html) - + diff --git a/docs/controls/main/levelselect.md b/docs/controls/main/levelselect.md index 411b0cd..80288e6 100644 --- a/docs/controls/main/levelselect.md +++ b/docs/controls/main/levelselect.md @@ -2,4 +2,4 @@ [查看 API](http://www.easybui.com/guide/api/classes/bui.levelselect.html) - + diff --git a/docs/controls/main/list-layout.md b/docs/controls/main/list-layout.md index b5b83de..8bf3f03 100644 --- a/docs/controls/main/list-layout.md +++ b/docs/controls/main/list-layout.md @@ -2,29 +2,29 @@ ## 普通列表 - + ## 多行列表 - + ## 小图标列表 - + ## 大图标列表 - + ## 图文列表 - + ## 图片列表 - + ## 宫格列表 - + ## 交互列表 ?> 滑动类效果,请使用扫码在手机操作. - + diff --git a/docs/controls/main/list.md b/docs/controls/main/list.md index 4aa46c3..1a9a504 100644 --- a/docs/controls/main/list.md +++ b/docs/controls/main/list.md @@ -8,11 +8,11 @@ ?> bui.list`重点理解`field`的字段配置. 你只需要传接口,模板,就会自动请求分页. 除非特殊功能无法满足,不然建议使用`bui.list`代替`bui.scroll`. 当第 1 页的数目加起来还不足出现滚动条的高度的时候,会自动请求下一页. - + ## 自定义分页加载 - + ## 自动分页+交互列表 @@ -21,4 +21,4 @@ - li 标签属性 `status=1` 手动拼接侧滑菜单,这样可以避免再次 dom 操作 - 设置固定高度可以少遍历一次 - + diff --git a/docs/controls/main/listview.md b/docs/controls/main/listview.md index a606498..15848b4 100644 --- a/docs/controls/main/listview.md +++ b/docs/controls/main/listview.md @@ -6,7 +6,7 @@ ?> 这里面包含 2 种渲染, 在属性 `status=1`的时候, 以静态渲染为主, 如果里面不包含自定义菜单结构,不渲染. - + ## 自动分页+交互列表 @@ -15,4 +15,4 @@ - li 标签属性 `status=1` 手动拼接侧滑菜单,这样可以避免再次 dom 操作 - 设置固定高度可以少遍历一次 - + diff --git a/docs/controls/main/loading.md b/docs/controls/main/loading.md index f78750d..a322b6c 100644 --- a/docs/controls/main/loading.md +++ b/docs/controls/main/loading.md @@ -4,4 +4,4 @@ ?> 如果不传`appendTo`参数,默认是增加在 body 里面,默认只创建一个 - + diff --git a/docs/controls/main/mask.md b/docs/controls/main/mask.md index a681d23..7acb80d 100644 --- a/docs/controls/main/mask.md +++ b/docs/controls/main/mask.md @@ -4,4 +4,4 @@ ?> 如果不传`appendTo`参数,默认是增加在 body 里面,默认只创建一个 - + diff --git a/docs/controls/main/number.md b/docs/controls/main/number.md index a861de8..5d252fd 100644 --- a/docs/controls/main/number.md +++ b/docs/controls/main/number.md @@ -2,4 +2,4 @@ [查看 API](http://www.easybui.com/guide/api/classes/bui.number.html) - + diff --git a/docs/controls/main/pickerdate.md b/docs/controls/main/pickerdate.md index 4b91dfa..8b28133 100644 --- a/docs/controls/main/pickerdate.md +++ b/docs/controls/main/pickerdate.md @@ -4,7 +4,7 @@ ?> 滑动效果请扫码在手机观看. - + ## 显示日期 diff --git a/docs/controls/main/pullrefresh.md b/docs/controls/main/pullrefresh.md index 4307f2b..abb24b6 100644 --- a/docs/controls/main/pullrefresh.md +++ b/docs/controls/main/pullrefresh.md @@ -2,4 +2,4 @@ [查看 API](http://www.easybui.com/guide/api/classes/bui.pullrefresh.html) - + diff --git a/docs/controls/main/rating.md b/docs/controls/main/rating.md index 5f3097e..e8ed4f3 100644 --- a/docs/controls/main/rating.md +++ b/docs/controls/main/rating.md @@ -2,4 +2,4 @@ [查看 API](http://www.easybui.com/guide/api/classes/bui.rating.html) - + diff --git a/docs/controls/main/searchbar-head.md b/docs/controls/main/searchbar-head.md index 0b705c7..70315c4 100644 --- a/docs/controls/main/searchbar-head.md +++ b/docs/controls/main/searchbar-head.md @@ -2,4 +2,4 @@ [查看 API](http://www.easybui.com/guide/api/classes/bui.searchbar.html) - + diff --git a/docs/controls/main/searchbar.md b/docs/controls/main/searchbar.md index 65bb973..16c1f5a 100644 --- a/docs/controls/main/searchbar.md +++ b/docs/controls/main/searchbar.md @@ -2,4 +2,4 @@ [查看 API](http://www.easybui.com/guide/api/classes/bui.searchbar.html) - + diff --git a/docs/controls/main/select-popup.md b/docs/controls/main/select-popup.md index 8d9d193..d4a05c0 100644 --- a/docs/controls/main/select-popup.md +++ b/docs/controls/main/select-popup.md @@ -6,8 +6,8 @@ ## 左侧菜单 - + ## 两侧菜单 - + diff --git a/docs/controls/main/select.md b/docs/controls/main/select.md index 5567445..45bf320 100644 --- a/docs/controls/main/select.md +++ b/docs/controls/main/select.md @@ -6,12 +6,12 @@ ## 普通选择列表 - + ## 弹出选择列表 - + ## 级联选择列表 - + diff --git a/docs/controls/main/sidebar.md b/docs/controls/main/sidebar.md index 874d0d0..f55eebe 100644 --- a/docs/controls/main/sidebar.md +++ b/docs/controls/main/sidebar.md @@ -6,8 +6,8 @@ ## 左侧菜单 - + ## 两侧菜单 - + diff --git a/docs/controls/main/slide.md b/docs/controls/main/slide.md index f2e1ad3..12b28d7 100644 --- a/docs/controls/main/slide.md +++ b/docs/controls/main/slide.md @@ -6,20 +6,20 @@ ## 焦点图 - + ## 标题焦点图 - + ## 跨屏焦点图 - + ## 欢迎引导页 - + ## 滚动公告 - + diff --git a/docs/controls/main/stepbar.md b/docs/controls/main/stepbar.md index 56f6ef5..fb59d68 100644 --- a/docs/controls/main/stepbar.md +++ b/docs/controls/main/stepbar.md @@ -4,8 +4,8 @@ ## 纵向步骤条 - + ## 横向步骤条 - + diff --git a/docs/controls/main/storage.md b/docs/controls/main/storage.md index 53bf300..9e04a47 100644 --- a/docs/controls/main/storage.md +++ b/docs/controls/main/storage.md @@ -6,8 +6,8 @@ ## 存储字符串 - + ## 存储 json - + diff --git a/docs/controls/main/store.md b/docs/controls/main/store.md index e0cc8c4..afc2880 100644 --- a/docs/controls/main/store.md +++ b/docs/controls/main/store.md @@ -2,4 +2,4 @@ [查看 API](http://www.easybui.com/guide/api/classes/bui.store.html) - + diff --git a/docs/controls/main/swipe.md b/docs/controls/main/swipe.md index 1760a89..9ba97e0 100644 --- a/docs/controls/main/swipe.md +++ b/docs/controls/main/swipe.md @@ -6,16 +6,16 @@ ## 左右抽屉菜单 - + ## 上下抽屉菜单 - + ## 仿日历交互 - + ## 复杂嵌套交互 - + diff --git a/docs/controls/main/tab-foot-dynamic.md b/docs/controls/main/tab-foot-dynamic.md index 42bb860..29b0274 100644 --- a/docs/controls/main/tab-foot-dynamic.md +++ b/docs/controls/main/tab-foot-dynamic.md @@ -2,4 +2,4 @@ [查看 API](http://www.easybui.com/guide/api/classes/bui.tab.html) - + diff --git a/docs/controls/main/tab-head-dynamic.md b/docs/controls/main/tab-head-dynamic.md index f4a5dc3..b549dad 100644 --- a/docs/controls/main/tab-head-dynamic.md +++ b/docs/controls/main/tab-head-dynamic.md @@ -2,4 +2,4 @@ [查看 API](http://www.easybui.com/guide/api/classes/bui.tab.html) - + diff --git a/docs/controls/main/tab.md b/docs/controls/main/tab.md index 6cd1935..ca889c4 100644 --- a/docs/controls/main/tab.md +++ b/docs/controls/main/tab.md @@ -6,28 +6,28 @@ ## 固定选项卡 - + ## 滑动选项卡 - + ## 底部选项卡 - + ## 纵向选项卡 - + ## 多层嵌套选项卡 - + ## 选项卡动态渲染 1.5.2 - + ## 纵向选项卡动态渲染 1.5.2 - + diff --git a/docs/controls/main/toggle.md b/docs/controls/main/toggle.md index 21b6d01..a066731 100644 --- a/docs/controls/main/toggle.md +++ b/docs/controls/main/toggle.md @@ -2,4 +2,4 @@ [查看 API](http://www.easybui.com/guide/api/classes/bui.toggle.html) - + diff --git a/docs/controls/main/upload.md b/docs/controls/main/upload.md index 709a0e8..97336ef 100644 --- a/docs/controls/main/upload.md +++ b/docs/controls/main/upload.md @@ -6,4 +6,4 @@ ?> 后台按`formdata`的方式接收`file`字段就好. - + diff --git a/docs/linkapi.md b/docs/linkapi.md index 53cdfa1..9cb819d 100644 --- a/docs/linkapi.md +++ b/docs/linkapi.md @@ -2,12 +2,9 @@ ?> Link API 为原生开发平台, 供Link轻应用原生开发使用. -* [Link API PC](http://docs.bingocloud.cn/btapi/) +* [Link API PC](https://docs.bingosoft.net/btapi/) * [Link 平台相关文件](https://github.com/bingo-oss/mobile-btjsapi/) -**link API 移动版, 请使用Link 扫码体验** - -link API 移动版 ## 常见问题 diff --git a/docs/prepros-6.config b/docs/prepros-6.config index 8860305..7da29e1 100644 --- a/docs/prepros-6.config +++ b/docs/prepros-6.config @@ -22,7 +22,7 @@ "selectedView": "file-tree" }, "fileWatcher": { - "enabled": false, + "enabled": true, "watchedExtensions": [ "less", "sass", @@ -60,7 +60,7 @@ "wp-includes" ], "server": { - "port": 7911, + "port": 7893, "assignNewPortAutomatically": true, "enable": true, "proxy": { @@ -170,13 +170,13 @@ "join_vars": true, "collapse_vars": true, "reduce_vars": true, - "warnings": false, + "warnings": true, "negate_iife": true, "pure_getters": false, "pure_funcs": [], "drop_console": false, "expression": false, - "keep_fargs": false, + "keep_fargs": true, "keep_fnames": false, "passes": 1, "keep_infinity": false, @@ -226,7 +226,7 @@ "colorRgba": true, "overflowWrap": true }, - "file-type-typescript": "{\"compilers\":[\"typescript\",\"uglify-js\"],\"autoCompile\":true,\"sourceMap\":false,\"output\":{\"outputType\":\"REPLACE_SEGMENT\",\"replaceSegments\":[\"typescript\",\"ts\"],\"replaceSegmentsWith\":\"js\",\"relative\":\"\"},\"compiler-uglify-js\":{\"enabled\":true,\"mangle\":true},\"compiler-typescript\":{\"enabled\":true}}", + "file-type-typescript": "{\"compilers\":[\"typescript\",\"uglify-js\"]}", "babel": { "useBabelRc": true, "presets": { diff --git a/docs/prepros.config b/docs/prepros.config deleted file mode 100644 index 0173589..0000000 --- a/docs/prepros.config +++ /dev/null @@ -1,912 +0,0 @@ -{ - "version": "7", - "about": "This is a Prepros (https://prepros.io) configuration file. You can commit this file to a git repo to backup and sync project configurations.", - "config": { - "proxy": { - "enable": false, - "target": "", - "useLocalAssets": false - }, - "reload": { - "enable": true, - "delay": 0, - "animate": true, - "afterUpload": false - }, - "sync": { - "enable": false, - "mouse": true, - "keyboard": true, - "form": true, - "scroll": true - }, - "watcher": { - "enable": false, - "maxFiles": 2000, - "usePolling": false, - "pollingInterval": 500, - "extensions": [ - ".ls", - ".html", - ".htm", - ".php" - ], - "ignore": { - "patterns": [ - "node_modules", - ".*", - "bower_components", - "prepros.config", - "Prepros Export", - "prepros-6.config", - "prepros.cfg", - "wp-admin", - "wp-includes" - ], - "exceptions": [] - } - }, - "exporter": { - "ignore": { - "patterns": [ - "config.rb", - "prepros.config", - "prepros-6.config", - "node_modules", - "Prepros Export", - ".git", - ".idea", - ".sass-cache", - ".hg", - ".svn", - ".cache", - ".DS_Store", - "*.sass", - "*.scss", - "*.less", - "*.pug", - "*.jade", - "*.styl", - "*.haml", - "*.slim", - "*.coffee", - "*.ls", - "*.kit", - "*.ts" - ], - "exceptions": [] - } - }, - "uploader": { - "remotePath": "", - "timeout": 20000, - "autoUpload": false, - "connectionType": "ftp", - "history": [] - }, - "packages": { - "createPackageLock": true - }, - "tasks": { - "autoprefixer": { - "cascade": true, - "add": true, - "remove": true, - "supports": true, - "flexbox": true, - "grid": "autoplace", - "browsers": [ - "last 5 versions" - ], - "sourceMap": false - }, - "babel": { - "sourceMap": false, - "presets": { - "@babel/preset-env": { - "enable": true, - "options": { - "targets": [ - "> 2%", - "not dead" - ], - "preserveImports": false - } - }, - "@babel/preset-react": true, - "@babel/preset-flow": false - }, - "plugins": { - "@babel/plugin-proposal-class-properties": false, - "@babel/plugin-proposal-decorators": { - "enable": false, - "options": { - "decoratorsBeforeExport": true - } - }, - "@babel/plugin-proposal-export-namespace-from": false, - "@babel/plugin-proposal-function-sent": false, - "@babel/plugin-proposal-nullish-coalescing-operator": false, - "@babel/plugin-proposal-numeric-separator": false, - "@babel/plugin-proposal-optional-chaining": false, - "@babel/plugin-proposal-private-methods": false, - "@babel/plugin-proposal-throw-expressions": false - }, - "customPresets": [], - "customPlugins": [] - }, - "bundle-js": { - "sourceMap": false, - "exclude": [ - "node_modules", - "bower_components" - ], - "devMode": true, - "globals": [], - "externals": [], - "babel": { - "enable": true, - "options": { - "sourceMap": false, - "presets": { - "@babel/preset-env": { - "enable": true, - "options": { - "targets": [ - "> 2%", - "not dead" - ], - "preserveImports": false - } - }, - "@babel/preset-react": true, - "@babel/preset-flow": false - }, - "plugins": { - "@babel/plugin-proposal-class-properties": false, - "@babel/plugin-proposal-decorators": { - "enable": false, - "options": { - "decoratorsBeforeExport": true - } - }, - "@babel/plugin-proposal-export-namespace-from": false, - "@babel/plugin-proposal-function-sent": false, - "@babel/plugin-proposal-nullish-coalescing-operator": false, - "@babel/plugin-proposal-numeric-separator": false, - "@babel/plugin-proposal-optional-chaining": false, - "@babel/plugin-proposal-private-methods": false, - "@babel/plugin-proposal-throw-expressions": false - }, - "customPresets": [], - "customPlugins": [] - } - }, - "css": { - "enable": true - }, - "fonts": { - "enable": true - } - }, - "coffeescript": { - "header": false, - "bare": false, - "sourceMap": false - }, - "command": { - "command": "", - "rootDir": "" - }, - "concat-js": { - "sourceMap": false, - "rootDir": "" - }, - "copy": { - "sourceMap": false - }, - "dart-sass": { - "indentType": "space", - "indentWidth": 2, - "linefeed": "lf", - "sourceMap": false - }, - "haml": { - "doubleQuoteAttributes": true - }, - "jpg": { - "quality": 90 - }, - "less": { - "javascriptEnabled": false, - "strictImports": false, - "insecure": false, - "math": "always", - "strictUnits": false, - "dumpLineNumbers": false, - "sourceMap": false - }, - "markdown": { - "githubFlavored": true, - "wrapWithHtml": false - }, - "minify-css": { - "sourceMap": false - }, - "minify-html": { - "caseSensitive": false, - "collapseBooleanAttributes": true, - "collapseInlineTagWhitespace": false, - "collapseWhitespace": true, - "conservativeCollapse": false, - "decodeEntities": false, - "html5": true, - "includeAutoGeneratedTags": true, - "keepClosingSlash": false, - "minifyCSS": true, - "minifyJS": true, - "preserveLineBreaks": false, - "preventAttributesEscaping": false, - "processConditionalComments": false, - "removeAttributeQuotes": false, - "removeComments": true, - "removeEmptyAttributes": false, - "removeEmptyElement": false, - "removeOptionalTags": false, - "removeRedundantAttributes": false, - "removeScriptTypeAttributes": false, - "removeStyleLinkTypeAttributes": false, - "removeTagWhitespace": false, - "sortAttributes": false, - "sortClassName": false, - "useShortDoctype": true - }, - "minify-js": { - "parse": { - "bare_returns": false - }, - "compress": { - "arrows": true, - "arguments": false, - "booleans": true, - "booleans_as_integers": false, - "collapse_vars": true, - "comparisons": true, - "computed_props": true, - "conditionals": true, - "dead_code": true, - "directives": true, - "drop_console": false, - "drop_debugger": true, - "evaluate": true, - "expression": false, - "global_defs": [], - "hoist_funs": false, - "hoist_props": true, - "hoist_vars": false, - "if_return": true, - "inline": 3, - "join_vars": true, - "keep_fargs": true, - "keep_infinity": false, - "loops": true, - "negate_iife": true, - "properties": true, - "pure_funcs": [], - "pure_getters": false, - "reduce_vars": true, - "sequences": true, - "side_effects": true, - "switches": true, - "top_retain": [], - "typeofs": true, - "unsafe": false, - "unsafe_arrows": false, - "unsafe_comps": false, - "unsafe_Function": false, - "unsafe_math": false, - "unsafe_proto": false, - "unsafe_regexp": false, - "unsafe_undefined": false, - "unused": true - }, - "mangle": { - "eval": false, - "reserved": [] - }, - "output": { - "ascii_only": false, - "braces": false, - "comments": "none", - "inline_script": true, - "keep_numbers": false, - "keep_quoted_props": false, - "preamble": null, - "quote_keys": false, - "quote_style": 0, - "semicolons": true, - "shebang": true, - "webkit": false, - "wrap_iife": false, - "wrap_func_args": true - }, - "sourceMap": false, - "toplevel": false, - "ie8": false, - "keep_classnames": false, - "keep_fnames": false, - "safari10": false - }, - "node-sass": { - "indentType": "space", - "indentWidth": 2, - "linefeed": "lf", - "outputStyle": "expanded", - "precision": 10, - "sourceMap": false, - "sourceComments": false - }, - "png": { - "quality": 90 - }, - "postcss-import": { - "ignoreKeywords": [], - "sourceMap": false - }, - "postcss-preset-env": { - "stage": 2, - "browsers": [ - "> 2%", - "not dead" - ], - "sourceMap": false - }, - "pug": { - "pretty": true - }, - "slim": { - "indent": "space", - "indentSize": 2, - "pretty": true - }, - "stylus": { - "useNib": true, - "sourceMap": false, - "linenos": false - }, - "svg": { - "cleanupAttrs": true, - "removeDoctype": true, - "removeXMLProcInst": true, - "removeComments": true, - "removeMetadata": true, - "removeTitle": true, - "removeDesc": true, - "removeUselessDefs": true, - "removeEditorsNSData": true, - "removeEmptyAttrs": true, - "removeHiddenElems": true, - "removeEmptyText": true, - "removeEmptyContainers": true, - "removeViewBox": false, - "cleanupEnableBackground": true, - "convertStyleToAttrs": true, - "convertColors": true, - "convertPathData": true, - "convertTransform": true, - "removeUnknownsAndDefaults": true, - "removeNonInheritableGroupAttrs": true, - "removeUselessStrokeAndFill": true, - "removeUnusedNS": true, - "cleanupIDs": true, - "cleanupNumericValues": true, - "moveElemsAttrsToGroup": true, - "moveGroupAttrsToElems": true, - "collapseGroups": true, - "removeRasterImages": false, - "mergePaths": true, - "convertShapeToPath": true, - "sortAttrs": true, - "removeDimensions": true - }, - "turf": { - "rootDir": "" - }, - "typescript": { - "allowJs": false, - "allowSyntheticDefaultImports": true, - "allowUmdGlobalAccess": false, - "allowUnreachableCode": false, - "allowUnusedLabels": false, - "alwaysStrict": false, - "charset": "utf8", - "checkJs": false, - "declaration": false, - "disableSizeLimit": false, - "downlevelIteration": false, - "emitBOM": false, - "emitDecoratorMetadata": false, - "experimentalDecorators": false, - "forceConsistentCasingInFileNames": false, - "importHelpers": false, - "jsx": "React", - "keyofStringsOnly": false, - "lib": [], - "maxNodeModuleJsDepth": 0, - "module": "ES2015", - "moduleResolution": "NodeJs", - "newLine": "LineFeed", - "noFallthroughCasesInSwitch": false, - "noImplicitAny": false, - "noImplicitReturns": false, - "noImplicitThis": false, - "noStrictGenericChecks": false, - "noUnusedLocals": false, - "noUnusedParameters": false, - "noImplicitUseStrict": false, - "noLib": false, - "noResolve": false, - "preserveConstEnums": false, - "jsxFactory": "React.createElement", - "removeComments": false, - "skipLibCheck": false, - "sourceMap": false, - "strict": false, - "strictFunctionTypes": false, - "strictBindCallApply": false, - "strictNullChecks": false, - "strictPropertyInitialization": false, - "suppressExcessPropertyErrors": false, - "suppressImplicitAnyIndexErrors": false, - "target": "ES3", - "resolveJsonModule": false, - "esModuleInterop": false, - "useDefineForClassFields": false - } - }, - "fileTypes": { - "sass": { - "extensions": [ - ".scss", - ".sass" - ], - "autoCompile": true, - "sourceMap": false, - "tasks": [ - { - "task": "dart-sass", - "enable": true - }, - { - "task": "autoprefixer", - "enable": true - }, - { - "task": "minify-css", - "enable": false - } - ], - "output": { - "extension": ".css", - "type": "REPLACE_SEGMENTS", - "segments": [ - { - "segment": "scss", - "replaceWith": "css" - }, - { - "segment": "sass", - "replaceWith": "css" - } - ] - } - }, - "less": { - "extensions": [ - ".less" - ], - "autoCompile": true, - "sourceMap": false, - "tasks": [ - { - "task": "less", - "enable": true - }, - { - "task": "autoprefixer", - "enable": true - }, - { - "task": "minify-css", - "enable": false - } - ], - "output": { - "extension": ".css", - "type": "REPLACE_SEGMENTS", - "segments": [ - { - "segment": "less", - "replaceWith": "css" - } - ] - } - }, - "pug": { - "extensions": [ - ".pug", - ".jade" - ], - "autoCompile": true, - "tasks": [ - { - "task": "pug", - "enable": true - }, - { - "task": "minify-html", - "enable": false - } - ], - "output": { - "extension": ".html", - "type": "REPLACE_SEGMENTS", - "segments": [ - { - "segment": "pug", - "replaceWith": "html" - } - ] - } - }, - "css": { - "extensions": [ - ".css" - ], - "autoCompile": false, - "sourceMap": false, - "tasks": [ - { - "task": "copy", - "enable": true - }, - { - "task": "postcss-import", - "enable": false - }, - { - "task": "postcss-preset-env", - "enable": false - }, - { - "task": "autoprefixer", - "enable": true - }, - { - "task": "minify-css", - "enable": true - } - ], - "output": { - "extension": ".css", - "type": "SOURCE_RELATIVE", - "relativePath": "", - "suffix": "-dist", - "alwaysSuffix": false - } - }, - "javascript": { - "extensions": [ - ".js", - ".jsx" - ], - "autoCompile": false, - "sourceMap": false, - "tasks": [ - { - "task": "copy", - "enable": true - }, - { - "task": "concat-js", - "enable": false - }, - { - "task": "babel", - "enable": false - }, - { - "task": "bundle-js", - "enable": false - }, - { - "task": "minify-js", - "enable": true - } - ], - "output": { - "extension": ".js", - "type": "SOURCE_RELATIVE", - "relativePath": "", - "suffix": "-dist", - "alwaysSuffix": false - } - }, - "stylus": { - "extensions": [ - ".styl" - ], - "autoCompile": true, - "sourceMap": false, - "tasks": [ - { - "task": "stylus", - "enable": true - }, - { - "task": "autoprefixer", - "enable": true - }, - { - "task": "minify-css", - "enable": false - } - ], - "output": { - "extension": ".css", - "type": "REPLACE_SEGMENTS", - "segments": [ - { - "segment": "stylus", - "replaceWith": "css" - }, - { - "segment": "styl", - "replaceWith": "css" - } - ] - } - }, - "markdown": { - "extensions": [ - ".md", - ".markdown", - ".mkd" - ], - "autoCompile": false, - "tasks": [ - { - "task": "markdown", - "enable": true - }, - { - "task": "minify-html", - "enable": false - } - ], - "output": { - "extension": ".html", - "type": "REPLACE_SEGMENTS", - "segments": [ - { - "segment": "markdown", - "replaceWith": "html" - } - ] - } - }, - "haml": { - "extensions": [ - ".haml" - ], - "autoCompile": true, - "tasks": [ - { - "task": "haml", - "enable": true - }, - { - "task": "minify-html", - "enable": false - } - ], - "output": { - "extension": ".html", - "type": "REPLACE_SEGMENTS", - "segments": [ - { - "segment": "haml", - "replaceWith": "html" - } - ] - } - }, - "slim": { - "extensions": [ - ".slim" - ], - "autoCompile": true, - "tasks": [ - { - "task": "slim", - "enable": true - }, - { - "task": "minify-html", - "enable": false - } - ], - "output": { - "extension": ".html", - "type": "REPLACE_SEGMENTS", - "segments": [ - { - "segment": "slim", - "replaceWith": "html" - } - ] - } - }, - "coffeescript": { - "extensions": [ - ".coffee" - ], - "autoCompile": true, - "sourceMap": false, - "tasks": [ - { - "task": "coffeescript", - "enable": true - }, - { - "task": "babel", - "enable": false - }, - { - "task": "bundle-js", - "enable": false - }, - { - "task": "minify-js", - "enable": false - } - ], - "output": { - "extension": ".js", - "type": "REPLACE_SEGMENTS", - "segments": [ - { - "segment": "coffee-script", - "replaceWith": "js" - }, - { - "segment": "coffeescript", - "replaceWith": "js" - }, - { - "segment": "coffee", - "replaceWith": "js" - } - ] - } - }, - "turf": { - "extensions": [ - ".turf", - ".kit" - ], - "autoCompile": true, - "tasks": [ - { - "task": "turf", - "enable": true - }, - { - "task": "minify-html", - "enable": false - } - ], - "output": { - "extension": ".html", - "type": "REPLACE_SEGMENTS", - "segments": [ - { - "segment": "turf", - "replaceWith": "html" - } - ] - } - }, - "typescript": { - "extensions": [ - ".ts", - ".tsx" - ], - "autoCompile": true, - "sourceMap": false, - "tasks": [ - { - "task": "typescript", - "enable": true - }, - { - "task": "babel", - "enable": false - }, - { - "task": "bundle-js", - "enable": false - }, - { - "task": "minify-js", - "enable": false - } - ], - "output": { - "extension": ".js", - "type": "REPLACE_SEGMENTS", - "segments": [ - { - "segment": "typescript", - "replaceWith": "js" - }, - { - "segment": "ts", - "replaceWith": "js" - } - ] - } - }, - "jpg": { - "extensions": [ - ".jpg", - ".jpeg" - ], - "tasks": [ - { - "task": "jpg", - "enable": true - } - ], - "output": { - "extension": ".jpg", - "type": "SOURCE_RELATIVE", - "relativePath": "" - } - }, - "png": { - "extensions": [ - ".png" - ], - "tasks": [ - { - "task": "png", - "enable": true - } - ], - "output": { - "extension": ".png", - "type": "SOURCE_RELATIVE", - "relativePath": "" - } - }, - "svg": { - "extensions": [ - ".svg" - ], - "tasks": [ - { - "task": "svg", - "enable": true - } - ], - "output": { - "extension": ".svg", - "type": "SOURCE_RELATIVE", - "relativePath": "" - } - } - }, - "files": [] - } -} diff --git a/docs/store/about.md b/docs/store/about.md index 2975241..2a55842 100644 --- a/docs/store/about.md +++ b/docs/store/about.md @@ -7,4 +7,4 @@ [查看示例](http://easybui.com/demo/#pages/store/index) - + diff --git a/docs/store/attribute.md b/docs/store/attribute.md index abc7569..a7a05d4 100644 --- a/docs/store/attribute.md +++ b/docs/store/attribute.md @@ -2,7 +2,7 @@ # 属性与值绑定 - + ### 1. 属性动态绑定 @@ -78,7 +78,7 @@ var bs = bui.store({ #### 效果预览 - + 查看效果 diff --git a/docs/store/case.md b/docs/store/case.md index f844687..42992d8 100644 --- a/docs/store/case.md +++ b/docs/store/case.md @@ -4,7 +4,7 @@ ## 1. 待办处理 - + ### 预览 @@ -14,7 +14,7 @@ ?> 如果数据一开始有值,还需要把值跟模板里的数据进行比对,处理成选中状态. - + ### 预览 @@ -23,7 +23,7 @@ ## 3. 多选联动复杂场景 - + ### 预览 @@ -33,7 +33,7 @@ ### 2.2 代码优化版 - + ### 预览 diff --git a/docs/store/class.md b/docs/store/class.md index b5fec8c..6ce3e03 100644 --- a/docs/store/class.md +++ b/docs/store/class.md @@ -2,7 +2,7 @@ # Class 与 Style 的绑定 - + ### 1. Class 绑定 @@ -84,7 +84,7 @@ html: ### 3. 显示与隐藏 - + ?> `b-show` 可以根据数据的状态来控制当前元素的显示或者隐藏. `b-model` 是双向绑定的内容,可以查看[表单绑定](store/form.md)的章节. diff --git a/docs/store/computed.md b/docs/store/computed.md index a8b5e4c..be547d9 100644 --- a/docs/store/computed.md +++ b/docs/store/computed.md @@ -6,7 +6,7 @@ ?> 模板不支持表达式, 模板尽量精简, 把表达式定义到 `computed` 里面, 可以处理跟`data`相关的计算. - + #### 例子1: @@ -205,7 +205,7 @@ if( this.firstName && this.lastName ){ ?> `watch` 可以用来监听 `data` 里面的键值的变化以后处理其它事情. `watch`函数返回当前监听变量的新值跟旧值`newVal,oldVal`. 比方下面的例子. - + #### 例子4: diff --git a/docs/store/controls.md b/docs/store/controls.md index 59f0731..85286b7 100644 --- a/docs/store/controls.md +++ b/docs/store/controls.md @@ -16,7 +16,7 @@ bui的控件都是以DOM交互为主, 这种方式可以很好的在各种低版 ### 效果预览 - + 下拉刷新 @@ -86,7 +86,7 @@ var bs = bui.store({ ### 效果预览 - + 下拉菜单 @@ -310,7 +310,7 @@ var bs = bui.store({ ### 效果预览 - + 轮播图 @@ -369,7 +369,7 @@ var bs = bui.store({ ### 效果预览 - + 选项卡 diff --git a/docs/store/distance.md b/docs/store/distance.md index 6a5dea8..7b756ec 100644 --- a/docs/store/distance.md +++ b/docs/store/distance.md @@ -1,7 +1,7 @@ # 实例 - + ### 1. 创建一个`store`实例. diff --git a/docs/store/event.md b/docs/store/event.md index 9ec30b7..878393b 100644 --- a/docs/store/event.md +++ b/docs/store/event.md @@ -2,7 +2,7 @@ # 事件处理 - + ### 1. 基本使用 diff --git a/docs/store/form-dynamic.md b/docs/store/form-dynamic.md index df6e7ac..44002eb 100644 --- a/docs/store/form-dynamic.md +++ b/docs/store/form-dynamic.md @@ -1,7 +1,7 @@ # 4. 动态表单 - + ```html
diff --git a/docs/store/form.md b/docs/store/form.md index ab8d412..4b139c4 100644 --- a/docs/store/form.md +++ b/docs/store/form.md @@ -6,7 +6,7 @@ !> 注意: input 的type类型必须声明是哪种类型(text,radio,checkbox)等. - + #### 示例: @@ -76,7 +76,7 @@ var bs = bui.store({ ### 3. 多选双向 - + ?> 多选是一个数组, 里面的值会跟自己本身的值进行比较,如果一致,会是选中状态. `b-text` 输出数组会加上逗号. @@ -129,7 +129,7 @@ var bs = bui.store({ ### 5. 选择列表 - + ?> 下面只是展示 select 的用法, 实际上移动端我们一般使用 `bui.select`控件. @@ -274,15 +274,15 @@ var bs = bui.store({ #### 多选联动 - + 这个例子是一个自定义的模拟select, 我们放在[综合案例](store/case.md)里面讲. #### 弹窗选择交互 - + ### 5.动态表单 - + diff --git a/docs/store/mixins.md b/docs/store/mixins.md index 8078a5f..0c43a0c 100644 --- a/docs/store/mixins.md +++ b/docs/store/mixins.md @@ -129,6 +129,6 @@ loader.define(function(require,export,module){ ### 案例 - + ?> 在一个模块里面处理三个Tab不好维护, 可以把每个tab的内容进行分发. 这是一个`bui.floor`跟 `bui.store`结合的例子. 其中用到了延迟加载, 滚动到第2个的时候, 会自动加载第3个模板, 加载了模板以后, 还需要通过实例的 `bs.$mount`方法, 重新编译该组件的数据. diff --git a/docs/store/template.md b/docs/store/template.md index eb24ee9..f851b6a 100644 --- a/docs/store/template.md +++ b/docs/store/template.md @@ -1,6 +1,6 @@ # 模板渲染 - + ### 1. ES6 模板