浏览代码

Merge branch 'hotfix/docs' into develop

zhixin 6 年之前
父节点
当前提交
123221bad8

+ 1 - 0
site/_includes/icons/facebook.svg

@@ -0,0 +1 @@
+<svg viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M1343 12v264h-157q-86 0-116 36t-30 108v189h293l-39 296h-254v759h-306v-759h-255v-296h255v-218q0-186 104-288.5t277-102.5q147 0 228 12z"></path></svg>

文件差异内容过多而无法显示
+ 1 - 1
site/_includes/icons/github.svg


+ 1 - 0
site/_includes/icons/linkedin.svg

@@ -0,0 +1 @@
+<svg viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M477 625v991h-330v-991h330zm21-306q1 73-50.5 122t-135.5 49h-2q-82 0-132-49t-50-122q0-74 51.5-122.5t134.5-48.5 133 48.5 51 122.5zm1166 729v568h-329v-530q0-105-40.5-164.5t-126.5-59.5q-63 0-105.5 34.5t-63.5 85.5q-11 30-11 81v553h-329q2-399 2-647t-1-296l-1-48h329v144h-2q20-32 41-56t56.5-52 87-43.5 114.5-15.5q171 0 275 113.5t104 332.5z"></path></svg>

文件差异内容过多而无法显示
+ 1 - 0
site/_includes/icons/mail.svg


文件差异内容过多而无法显示
+ 1 - 1
site/_includes/icons/twitter.svg


+ 42 - 0
site/_includes/opencollective.html

@@ -0,0 +1,42 @@
+<div class="container">
+  <div class="pt-md-5">
+    <div>
+      <h3>Backers</h3>
+    </div>
+
+    <div>
+      Thank you to all our backers!
+      🙏 [<a href="https://opencollective.com/bootstrap-table#backer" target="_blank">
+        Become a backer
+      </a>]
+    </div>
+
+    <div>
+      <a href="https://opencollective.com/bootstrap-table#backers" target="_blank">
+        <img src="https://opencollective.com/bootstrap-table/backers.svg?width=890">
+      </a>
+    </div>
+  </div>
+
+  <div class="pt-md-5 pb-md-5">
+    <div>
+      <h3>Sponsors</h3>
+    </div>
+
+    <div>
+      Support this project by becoming a sponsor.
+      Your logo will show up here with a link to your website.
+      [<a href="https://opencollective.com/bootstrap-table#sponsor" target="_blank">
+        Become a sponsor
+      </a>]
+    </div>
+
+    <div>
+      <a href="https://opencollective.com/bootstrap-table/sponsor/0/website" target="_blank"><img src="https://opencollective.com/bootstrap-table/sponsor/0/avatar.svg"></a>
+      <a href="https://opencollective.com/bootstrap-table/sponsor/1/website" target="_blank"><img src="https://opencollective.com/bootstrap-table/sponsor/1/avatar.svg"></a>
+      <a href="https://opencollective.com/bootstrap-table/sponsor/2/website" target="_blank"><img src="https://opencollective.com/bootstrap-table/sponsor/2/avatar.svg"></a>
+      <a href="https://opencollective.com/bootstrap-table/sponsor/3/website" target="_blank"><img src="https://opencollective.com/bootstrap-table/sponsor/3/avatar.svg"></a>
+      <a href="https://opencollective.com/bootstrap-table/sponsor/4/website" target="_blank"><img src="https://opencollective.com/bootstrap-table/sponsor/4/avatar.svg"></a>
+    </div>
+  </div>
+</div>

+ 1 - 1
site/_includes/stylesheet.html

@@ -7,6 +7,6 @@
 {% endif %}
 {% if page.layout != "examples" %}
 <link href="{{ site.baseurl }}/assets/css/docs.min.css" rel="stylesheet">
-<link href="{{ site.baseurl }}/assets/css/style.css" rel="stylesheet">
+<link href="{{ site.baseurl }}/assets/css/style.css?m=1" rel="stylesheet">
 {% endif %}
 {%- endif -%}

+ 66 - 7
site/assets/css/style.css

@@ -13,19 +13,78 @@
 
 .donate td {
   text-align: center;
+  vertical-align: middle !important;
 }
 
-.donate .paypal {
-  margin-top: 70px;
-  display: block;
+.donate svg.navbar-nav-svg {
+  width: 96px;
 }
 
-.donate svg {
-  width: 96px;
+#share-buttons {
+  display: inline-block;
+  vertical-align: middle;
+}
+
+#share-buttons > a {
+  position: relative;
+  text-align: left;
+  height: 36px;
+  width: 32px;
+  float: left;
+  text-align: center;
+  color: silver;
+}
+
+#share-buttons > a {
+  position: relative;
+  text-align: left;
+  height: 36px;
+  width: 32px;
+  float: left;
+  text-align: center;
+  color: silver;
+}
+
+#share-buttons > a > svg {
+  height: 18px;
+  fill: #d5d5d5;
+  margin-top: 9px;
+}
+
+#share-buttons > .github:hover,
+#share-buttons > .github:hover svg {
+  color: #000;
+  fill: #000;
+}
+
+#share-buttons > .twitter:hover,
+#share-buttons > .twitter:hover svg {
+  color: #55acee;
+  fill: #55acee;
+}
+
+#share-buttons > .facebook:hover,
+#share-buttons > .facebook:hover svg {
+  color: #3b5998;
+  fill: #3b5998;
+}
+
+#share-buttons > .linkedin:hover,
+#share-buttons > .linkedin:hover svg {
+  color: #0077b5;
+  fill: #0077b5;
+}
+
+#share-buttons > .mail:hover,
+#share-buttons > .mail:hover svg {
+  color: #7d7d7d;
+  fill: #7d7d7d;
 }
 
-.donate .btn-primary {
-  margin-top: 75px;
+.share-desc {
+  font-size: 12px;
+  color: #777;
+  text-align: left;
 }
 
 .post-date {

+ 4 - 0
site/docs/api/table-options.md

@@ -408,6 +408,8 @@ The table options are defined in `jQuery.fn.bootstrapTable.defaults`.
 
 - **Default:** `function(params) { return params }`
 
+- **Example:** [Query Params](https://examples.bootstrap-table.com/#options/query-params.html)
+
 ## queryParamsType
 
 - **Attribute:** `data-query-params-type`
@@ -420,6 +422,8 @@ The table options are defined in `jQuery.fn.bootstrapTable.defaults`.
 
 - **Default:** `'limit'`
 
+- **Example:** [Query Params Type](https://examples.bootstrap-table.com/#options/query-params-type.html)
+
 ## responseHandler
 
 - **Attribute:** `data-response-handler`

+ 5 - 5
site/docs/getting-started/download.md

@@ -16,18 +16,18 @@ Source CSS, JavaScript, locales, and extensions, along with our docs.
 
 <a href="{{ site.repo }}" class="btn btn-bd-primary" role="button">Via GitHub</a>
 
-## CDN
+## UNPKG
 
-The folks over at [CDNJS](http://www.cdnjs.com/libraries/bootstrap-table) and [bootcss](http://open.bootcss.com/bootstrap-table/) graciously provide CDN support for CSS and JavaScript of Bootstrap table. Just use these CDN links.
+The folks over at [UNPKG](https://unpkg.com/bootstrap-table@{{ site.current_version }}/dist/) graciously provide CDN support for CSS and JavaScript of Bootstrap table. Just use these links.
 
 {% highlight html %}
 <!-- Latest compiled and minified CSS -->
-<link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/bootstrap-table/{{ site.current_version }}/bootstrap-table.min.css">
+<link rel="stylesheet" href="https://unpkg.com/bootstrap-table@{{ site.current_version }}/dist/bootstrap-table.min.css">
 
 <!-- Latest compiled and minified JavaScript -->
-<script src="//cdnjs.cloudflare.com/ajax/libs/bootstrap-table/{{ site.current_version }}/bootstrap-table.min.js"></script>
+<script src="https://unpkg.com/bootstrap-table@{{ site.current_version }}/dist/bootstrap-table.min.js"></script>
 <!-- Latest compiled and minified Locales -->
-<script src="//cdnjs.cloudflare.com/ajax/libs/bootstrap-table/{{ site.current_version }}/locale/bootstrap-table-zh-CN.min.js"></script>
+<script src="https://unpkg.com/bootstrap-table@{{ site.current_version }}/dist/locale/bootstrap-table-zh-CN.min.js"></script>
 {% endhighlight %}
 
 ## Package managers

+ 4 - 4
site/docs/getting-started/introduction.md

@@ -18,7 +18,7 @@ Looking to quickly add Bootstrap Table to your project? Use CDN, provided for fr
 Copy-paste the stylesheet `<link>` into your `<head>` before all other stylesheets to load our CSS.
 
 {% highlight html %}
-<link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/bootstrap-table/{{ site.current_version }}/bootstrap-table.min.css">
+<link rel="stylesheet" href="https://unpkg.com/bootstrap-table@{{ site.current_version }}/dist/bootstrap-table.min.css">
 {% endhighlight %}
 
 ### JS
@@ -26,7 +26,7 @@ Copy-paste the stylesheet `<link>` into your `<head>` before all other styleshee
 Place the following `<script>`s near the end of your pages, right before the closing `</body>` tag, to enable them. jQuery must come first, then Bootstrap.js, and then our JavaScript plugins.
 
 {% highlight html %}
-<script src="//cdnjs.cloudflare.com/ajax/libs/bootstrap-table/{{ site.current_version }}/bootstrap-table.min.js"></script>
+<script src="https://unpkg.com/bootstrap-table@{{ site.current_version }}/dist/bootstrap-table.min.js"></script>
 {% endhighlight %}
 
 ## Starter template
@@ -54,7 +54,7 @@ Put it all together and your pages should look like this:
     <!-- Bootstrap CSS -->
     <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.2.1/css/bootstrap.min.css" integrity="sha384-GJzZqFGwb1QTTN6wy59ffF1BuGJpLSa9DkKMp0DgiMDm4iYMj70gZWKYbI706tWS" crossorigin="anonymous">
     <link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.6.3/css/all.css" integrity="sha384-UHRtZLI+pbxtHCWp1t77Bi1L4ZtiqrqD80Kn4Z8NTSRyMA2Fd33n5dQ8lWUE00s/" crossorigin="anonymous">
-    <link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/bootstrap-table/{{ site.current_version }}/bootstrap-table.min.css">
+    <link rel="stylesheet" href="https://unpkg.com/bootstrap-table@{{ site.current_version }}/dist/bootstrap-table.min.css">
 
     <title>Hello, Bootstrap Table!</title>
   </head>
@@ -86,7 +86,7 @@ Put it all together and your pages should look like this:
     <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.6/umd/popper.min.js" integrity="sha384-wHAiFfRlMFy6i5SRaxvfOCifBUQy1xHdJ/yoi7FRNXMRBu5WHdZYu1hA6ZOblgut" crossorigin="anonymous"></script>
     <script src="https://stackpath.bootstrapcdn.com/bootstrap/4.2.1/js/bootstrap.min.js" integrity="sha384-B0UglyR+jN6CkvvICOB2joaf5I4l3gm9GU6Hc1og6Ls7i6U/mkkaduKaBhlAXv9k" crossorigin="anonymous"></script>
     <script src="https://cdnjs.cloudflare.com/ajax/libs/core-js/2.6.2/core.min.js"></script>
-    <script src="//cdnjs.cloudflare.com/ajax/libs/bootstrap-table/{{ site.current_version }}/bootstrap-table.min.js"></script>
+    <script src="https://unpkg.com/bootstrap-table@{{ site.current_version }}/dist/bootstrap-table.min.js"></script>
   </body>
 </html>
 {% endhighlight %}

+ 32 - 9
site/donate.md

@@ -7,31 +7,54 @@ redirect_from:
   - "/es/donate/"
 ---
 
-Bootstrap Table is a free plug-in which is made in my spare time.
-
-If your project gets the help from Bootstrap Table, you can donate to Bootstrap Table.
-
-With your help, I believe that I will continue to strive to let Bootstrap Table be better.
+Bootstrap Table is an MIT licensed open source project and completely free to use. However, the amount of effort needed to maintain and develop new features for the project is not sustainable without proper financial backing. You can support Bootstrap Table development via the following methods:
 
 <table class="table donate">
 <tbody>
   <tr>
+    <td><h2>Share The Love</h2></td>
     <td><img src="{{ site.base_url }}/assets/images/paypalLogo.png"></td>
-    <td>{%- include icons/opencollective.svg class="navbar-nav-svg" -%}</td>
     <td><img src="{{ site.base_url }}/assets/images/alipayLogo.png"></td>
     <td><img src="{{ site.base_url }}/assets/images/weixinLogo.png"></td>
   </tr>
   <tr>
     <td>
+      <span style="color: silver;">Share on: </span>
+      <div id="share-buttons">
+        <a class="github" href="{{ site.repo }}" target="_blank" title="Star this on GitHub">
+          {% include icons/github.svg %}
+        </a>
+
+        <a class="twitter" href="http://twitter.com/home?status={{ site.url }}" target="_blank" title="Share this on Twitter">
+          {% include icons/twitter.svg %}
+        </a>
+
+        <a class="facebook" href="http://www.facebook.com/share.php?u={{ site.url }}" target="_blank" title="Share this on Facebook">
+          {% include icons/facebook.svg %}
+        </a>
+
+        <a class="linkedin" href="https://www.linkedin.com/shareArticle?mini=true&amp;url={{ site.url }}&amp;title=&amp;summary=&amp;source=" target="_blank" title="Share this on Linkedin">
+          {% include icons/linkedin.svg %}
+        </a>
+
+        <a class="mail" href="mailto:?&amp;body={{ site.url }}" target="_blank" title="Share this through Email">
+          {% include icons/mail.svg %}
+        </a>
+      </div>
+
+      <p class="share-desc">
+      If you like Bootstrap Table, but you do not have any money to spare, please share the love by posting something about this website on social media. You can use the buttons above. They will share the homepage. Thank you, you are the best!
+      </p>
+    </td>
+    <td>
       <a class="paypal" href="https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=ZDHP676FQDUT6">
         <img src="https://www.paypalobjects.com/en_US/i/btn/btn_donateCC_LG.gif">
       </a>
     </td>
-    <td>
-      <a class="btn btn-primary" href="https://opencollective.com/bootstrap-table">Contribute</a>
-    </td>
     <td><img src="{{ site.base_url }}/assets/images/alipay.jpg"></td>
     <td><img src="{{ site.base_url }}/assets/images/weixin.png"></td>
   </tr>
 </tbody>
 </table>
+
+{% include opencollective.html %}

+ 5 - 3
site/index.html

@@ -73,11 +73,11 @@ bower install bootstrap-table
     <!-- Icon by Bytesize https://github.com/danklammer/bytesize-icons -->
     {% include icons/download.svg width="32" height="32" class="text-primary mb-2" %}
     <h3>CDN</h3>
-    <p>When you only need to include Bootstrap Table’s compiled CSS or JS, you can use <a href="http://www.cdnjs.com/libraries/bootstrap-table">CDNJS</a>.</p>
+    <p>When you only need to include Bootstrap Table’s compiled CSS or JS, you can use <a href="https://unpkg.com/bootstrap-table@{{ site.current_version }}/dist/">UNPKG</a>.</p>
 
 {% highlight html %}
-<link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/bootstrap-table/{{ site.current_version }}/bootstrap-table.min.css">
-<script src="//cdnjs.cloudflare.com/ajax/libs/bootstrap-table/{{ site.current_version }}/bootstrap-table.min.js"></script>
+<link rel="stylesheet" href="https://unpkg.com/bootstrap-table@{{ site.current_version }}/dist/bootstrap-table.min.css">
+<script src="https://unpkg.com/bootstrap-table@{{ site.current_version }}/dist/bootstrap-table.min.js"></script>
 {% endhighlight %}
 
     <hr class="half-rule">
@@ -99,4 +99,6 @@ bower install bootstrap-table
       Browse Examples
     </a>
   </div>
+
+  {% include opencollective.html %}
 </div>