Browse Source

Update extensions docs (#4839)

文翼 5 years ago
parent
commit
71cd1a17d2

+ 2 - 4
.gitignore

@@ -5,10 +5,8 @@ bower_components
 _gh_pages
 
 # use scss instead
-src/bootstrap-table.css
-src/bootstrap-table.css.map
-src/themes/**/*.css
-src/themes/**/*.css.map
+src/**/*.css
+src/**/*.css.map
 .sass-cache
 
 # old docs

+ 1 - 0
package.json

@@ -46,6 +46,7 @@
     "js:build:min": "cross-env NODE_ENV=production rollup -c",
     "js:build:banner": "foreach -g \"dist/**/*.min.js\" -x \"headr #{path} -o #{path} --version --homepage --author --license\"",
     "js:build": "run-s js:build:*",
+    "css:build:src": "node-sass --output-style expanded src -o src",
     "css:build:base": "node-sass --output-style expanded src -o dist",
     "css:build:min": "foreach -g \"dist/**/*.css\" -x \"cleancss --level 1 #{path} -o #{dir}/#{name}.min.css\"",
     "css:build:banner": "foreach -g \"dist/**/*.min.css\" -x \"headr #{path} -o #{path} --version --homepage --author --license\"",

+ 2 - 0
site/docs/extensions/accent-neutralise.md

@@ -25,6 +25,8 @@ toc: true
 
 ### searchAccentNeutralise
 
+- **Attribute:** `data-search-accent-neutralise`
+
 - **Type:** `Boolean`
 
 - **Detail:**

+ 4 - 0
site/docs/extensions/addrbar.md

@@ -22,6 +22,8 @@ Every time when changing page, sorting and searching operation, it will change t
 
 ### addrbar
 
+- **Attribute:** `data-addrbar`
+
 - **Type:** `Boolean`
 
 - **Detail:**
@@ -32,6 +34,8 @@ Every time when changing page, sorting and searching operation, it will change t
 
 ### addrPrefix
 
+- **Attribute:** `data-addr-prefix`
+
 - **Type:** `String`
 
 - **Detail:**

+ 8 - 0
site/docs/extensions/auto-refresh.md

@@ -20,6 +20,8 @@ toc: true
 
 ### autoRefresh
 
+- **Attribute:** `data-auto-refresh`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -30,6 +32,8 @@ toc: true
 
 ### autoRefreshStatus
 
+- **Attribute:** `data-auto-refresh-status`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -40,6 +44,8 @@ toc: true
 
 ### autoRefreshInterval
 
+- **Attribute:** `data-auto-refresh-interval`
+
 - **type:** `Number`
 
 - **Detail:**
@@ -50,6 +56,8 @@ toc: true
 
 ### autoRefreshSilent
 
+- **Attribute:** `data-auto-refresh-silent`
+
 - **type:** `Boolean`
 
 - **Detail:**

+ 16 - 0
site/docs/extensions/cookie.md

@@ -20,6 +20,8 @@ toc: true
 
 ### cookie
 
+- **Attribute:** `data-cookie`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -30,6 +32,8 @@ toc: true
 
 ### cookieExpire
 
+- **Attribute:** `data-cookie-expire`
+
 - **type:** `String`
 
 - **Detail:**
@@ -40,6 +44,8 @@ toc: true
 
 ### cookiePath
 
+- **Attribute:** `data-cookie-path`
+
 - **type:** `String`
 
 - **Detail:**
@@ -50,6 +56,8 @@ toc: true
 
 ### cookieDomain
 
+- **Attribute:** `data-cookie-domain`
+
 - **type:** `String`
 
 - **Detail:**
@@ -60,6 +68,8 @@ toc: true
 
 ### cookieSecure
 
+- **Attribute:** `data-cookie-secure`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -70,6 +80,8 @@ toc: true
 
 ### cookieIdTable
 
+- **Attribute:** `data-cookie-id-table`
+
 - **type:** `String`
 
 - **Detail:**
@@ -80,6 +92,8 @@ toc: true
 
 ### cookieStorage
 
+- **Attribute:** `data-cookie-storage`
+
 - **type:** `String`
 
 - **Detail:**
@@ -90,6 +104,8 @@ toc: true
 
 ### cookiesEnabled
 
+- **Attribute:** `data-cookies-enabled`
+
 - **type:** `Array`
 
 - **Detail:**

+ 8 - 0
site/docs/extensions/copy-rows.md

@@ -22,6 +22,8 @@ This extension adds functionality for copying selected rows to the clipboard. Cu
 
 ### showCopyRows
 
+- **Attribute:** `data-show-copy-rows`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -32,6 +34,8 @@ This extension adds functionality for copying selected rows to the clipboard. Cu
 
 ### copyWithHidden
 
+- **Attribute:** `data-copy-width-hidden`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -42,6 +46,8 @@ This extension adds functionality for copying selected rows to the clipboard. Cu
 
 ### copyDelimiter
 
+- **Attribute:** `data-copy-delimiter`
+
 - **type:** `String`
 
 - **Detail:**
@@ -52,6 +58,8 @@ This extension adds functionality for copying selected rows to the clipboard. Cu
 
 ### copyNewline
 
+- **Attribute:** `data-copy-newline`
+
 - **type:** `String`
 
 - **Detail:**

+ 2 - 0
site/docs/extensions/defer-url.md

@@ -20,6 +20,8 @@ toc: true
 
 ### deferUrl
 
+- **Attribute:** `data-defer-url`
+
 - **type:** `String`
 
 - **Detail:**

+ 4 - 0
site/docs/extensions/editable.md

@@ -18,6 +18,8 @@ Use Plugin: [x-editable](https://github.com/vitalets/x-editable)
 
 ### editable
 
+- **Attribute:** `data-editable`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -30,6 +32,8 @@ Use Plugin: [x-editable](https://github.com/vitalets/x-editable)
 
 ### editable
 
+- **Attribute:** `data-editable`
+
 - **type:** `Object | Function`
 
 - **Detail:**

+ 10 - 0
site/docs/extensions/export.md

@@ -24,6 +24,8 @@ This is an important link to check out as some file types may require extra step
 
 ### showExport
 
+- **Attribute:** `data-show-export`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -34,6 +36,8 @@ This is an important link to check out as some file types may require extra step
 
 ### exportDataType
 
+- **Attribute:** `data-export-data-type`
+
 - **type:** `String`
 
 - **Detail:**
@@ -44,6 +48,8 @@ This is an important link to check out as some file types may require extra step
 
 ### exportTypes
 
+- **Attribute:** `data-export-types`
+
 - **type:** `Array`
 
 - **Detail:**
@@ -54,6 +60,8 @@ This is an important link to check out as some file types may require extra step
 
 ### exportOptions
 
+- **Attribute:** `data-export-options`
+
 - **type:** `Object`
 
 - **Detail:**
@@ -76,6 +84,8 @@ This is an important link to check out as some file types may require extra step
 
 ### forceExport
 
+- **Attribute:** `data-force-export`
+
 - **type:** `Boolean`
 
 - **Detail:**

+ 37 - 0
site/docs/extensions/filter-control.md

@@ -23,6 +23,8 @@ Dependence if you use the datepicker option: [bootstrap-datepicker](https://gith
 
 ### filterControl
 
+- **Attribute:** `data-filter-control`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -33,6 +35,8 @@ Dependence if you use the datepicker option: [bootstrap-datepicker](https://gith
 
 ### filterControlContainer
 
+- **Attribute:** `data-filter-control-container`
+
 - **type:** `Selector`
 
 - **Detail:**
@@ -44,6 +48,8 @@ Dependence if you use the datepicker option: [bootstrap-datepicker](https://gith
 
 ### filterDataCollector
 
+- **Attribute:** `data-filter-data-collector`
+
 - **type:** `Function`
 
 - **Detail:**
@@ -54,6 +60,8 @@ Dependence if you use the datepicker option: [bootstrap-datepicker](https://gith
 
 ### alignmentSelectControlOptions
 
+- **Attribute:** `data-alignment-select-control-options`
+
 - **type:** `String`
 
 - **Detail:**
@@ -64,6 +72,8 @@ Dependence if you use the datepicker option: [bootstrap-datepicker](https://gith
 
 ### hideUnusedSelectOptions
 
+- **Attribute:** `data-hide-unused-select-options`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -74,6 +84,8 @@ Dependence if you use the datepicker option: [bootstrap-datepicker](https://gith
 
 ### disableControlWhenSearch
 
+- **Attribute:** `data-disable-control-when-search`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -84,6 +96,8 @@ Dependence if you use the datepicker option: [bootstrap-datepicker](https://gith
 
 ### searchOnEnterKey
 
+- **Attribute:** `data-search-on-enter-key`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -96,6 +110,8 @@ Dependence if you use the datepicker option: [bootstrap-datepicker](https://gith
 
 ### filterControl
 
+- **Attribute:** `data-filter-control`
+
 - **type:** `String`
 
 - **Detail:**
@@ -106,6 +122,8 @@ Dependence if you use the datepicker option: [bootstrap-datepicker](https://gith
 
 ### filterData
 
+- **Attribute:** `data-filter-data`
+
 - **type:** `String`
 
 - **Detail:**
@@ -116,6 +134,8 @@ Dependence if you use the datepicker option: [bootstrap-datepicker](https://gith
 
 ### filterDefault
 
+- **Attribute:** `data-filter-default`
+
 - **type:** `String`
 
 - **Detail:**
@@ -125,6 +145,9 @@ Dependence if you use the datepicker option: [bootstrap-datepicker](https://gith
 - **Default:** `undefined`
 
 ### filterDatepickerOptions
+
+- **Attribute:** `data-filter-datepicker-options`
+
 - **type:** `Object`
 
 - **Detail:**
@@ -134,6 +157,9 @@ Dependence if you use the datepicker option: [bootstrap-datepicker](https://gith
 - **Default:** `undefined`
 
 ### filterStrictSearch
+
+- **Attribute:** `data-filter-strict-search`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -143,6 +169,9 @@ Dependence if you use the datepicker option: [bootstrap-datepicker](https://gith
 - **Default:** `false`
 
 ### filterStartsWithSearch
+
+- **attribute:** `data-filter-starts-with-search`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -152,6 +181,9 @@ Dependence if you use the datepicker option: [bootstrap-datepicker](https://gith
 - **Default:** `false`
 
 ### filterControlPlaceholder
+
+- **attribute:** `data-filter-control-placeholder`
+
 - **type:** `String`
 
 - **Detail:**
@@ -161,6 +193,9 @@ Dependence if you use the datepicker option: [bootstrap-datepicker](https://gith
 - **Default:** `''`
 
 ### filterOrderBy
+
+- **attribute:** `data-filter-order-by`
+
 - **type:** `String`
 
 - **Detail:**
@@ -170,11 +205,13 @@ Dependence if you use the datepicker option: [bootstrap-datepicker](https://gith
 - **Default:** `'asc'`
 
 ### Icons
+
 * clear: 'glyphicon-trash icon-clear'
 
 ## Locale
 
 ### formatClearFilters
+
 - **type:** `Function`
 
 - **Default:** `function () { return "Clear Filters";}`

+ 4 - 0
site/docs/extensions/fixed-columns.md

@@ -21,6 +21,8 @@ toc: true
 
 ### fixedColumns
 
+- **attribute:** `data-fixed-columns`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -31,6 +33,8 @@ toc: true
 
 ### fixedNumber
 
+- **attribute:** `data-fixed-number`
+
 - **type:** Number
 
 - **Detail:**

+ 6 - 0
site/docs/extensions/group-by-v2.md

@@ -21,6 +21,8 @@ toc: true
 
 ### groupBy
 
+- **attribute:** `data-group-by`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -31,6 +33,8 @@ toc: true
 
 ### groupByField
 
+- **attribute:** `data-group-by-field`
+
 - **type:** `String`
 
 - **Detail:**
@@ -41,6 +45,8 @@ toc: true
 
 ### groupByFormatter
 
+- **attribute:** `data-group-by-formatter`
+
 - **type:** `Function`
 
 - **Detail:**

+ 3 - 2
site/docs/extensions/key-events.md

@@ -20,12 +20,13 @@ toc: true
 
 ### keyEvents
 
+- **attribute:** `data-key-events`
+
 - **type:** `Boolean`
 
 - **Detail:**
 
-
-True to enable the key events. The key event list is:
+  True to enable the key events. The key event list is:
     * s: It will be focused the search textbox if it is enabled.
     * r: It will refresh the table if the showRefresh option is enabled.
     * t: It will toggle the table view if the showToggle option is enabled.

+ 10 - 0
site/docs/extensions/mobile.md

@@ -20,6 +20,8 @@ toc: true
 
 ### mobileResponsive
 
+- **attribute:** `data-mobile-responsive`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -30,6 +32,8 @@ toc: true
 
 ### checkOnInit
 
+- **attribute:** `data-check-on-init`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -40,6 +44,8 @@ toc: true
 
 ### minWidth
 
+- **attribute:** `data-min-width`
+
 - **type:** `Integer`
 
 - **Detail:**
@@ -50,6 +56,8 @@ toc: true
 
 ### minHeight
 
+- **attribute:** `data-min-height`
+
 - **type:** `Integer`
 
 - **Detail:**
@@ -60,6 +68,8 @@ toc: true
 
 ### columnsHidden
 
+- **attribute:** `data-columns-hidden`
+
 - **type:** `String`
 
 - **Detail:**

+ 8 - 0
site/docs/extensions/multiple-sort.md

@@ -20,6 +20,8 @@ toc: true
 
 ### showMultiSort
 
+- **attribute:** `data-show-multi-sort`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -30,6 +32,8 @@ toc: true
 
 ### showMultiSortButton
 
+- **attribute:** `data-show-multi-sort-button`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -40,6 +44,8 @@ toc: true
 
 ### multiSortStrictSort
 
+- **attribute:** `data-multi-sort-strict-sort`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -50,6 +56,8 @@ toc: true
 
 ### sortPriority
 
+- **attribute:** `data-sort-priority`
+
 - **type:** `Object`
 
 - **Detail:**

+ 2 - 0
site/docs/extensions/page-jump-to.md

@@ -21,6 +21,8 @@ toc: true
 
 ### showJumpTo
 
+- **attribute:** `data-show-jump-to`
+
 - **type:** `Boolean`
 
 - **Detail:**

+ 16 - 0
site/docs/extensions/print.md

@@ -22,6 +22,8 @@ Adds a button to the toolbar for printing the table in a predefined configurable
 
 ### showPrint
 
+- **attribute:** `data-show-print`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -32,6 +34,8 @@ Adds a button to the toolbar for printing the table in a predefined configurable
 
 ### printAsFilteredAndSortedOnUI
 
+- **attribute:** `data-print-as-filtered-and-sorted-on-ui`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -42,6 +46,8 @@ Adds a button to the toolbar for printing the table in a predefined configurable
 
 ### printSortColumn
 
+- **attribute:** `data-print-sort-column`
+
 - **type:** `String`
 
 - **Detail:**
@@ -52,6 +58,8 @@ Adds a button to the toolbar for printing the table in a predefined configurable
 
 ### printSortOrder
 
+- **attribute:** `data-print-sort-order`
+
 - **type:** `String`
 
 - **Detail:**
@@ -62,6 +70,8 @@ Adds a button to the toolbar for printing the table in a predefined configurable
 
 ### printPageBuilder
 
+- **attribute:** `data-print-page-builder`
+
 - **type:** `Function`
 
 - **Detail:**
@@ -74,6 +84,8 @@ Adds a button to the toolbar for printing the table in a predefined configurable
 
 ### printFilter
 
+- **attribute:** `data-print-filter`
+
 - **type:** `String`
 
 - **Detail:**
@@ -84,6 +96,8 @@ Adds a button to the toolbar for printing the table in a predefined configurable
 
 ### printIgnore
 
+- **attribute:** `data-print-ignore`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -94,6 +108,8 @@ Adds a button to the toolbar for printing the table in a predefined configurable
 
 ### printFormatter
 
+- **attribute:** `data-print-formatter`
+
 - **type:** `Function`
 
 - **Detail:**

+ 6 - 0
site/docs/extensions/reorder-columns.md

@@ -28,6 +28,8 @@ Dependence:
 
 ### reorderableColumns
 
+- **attribute:** `data-reorderable-columns`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -38,6 +40,8 @@ Dependence:
 
 ### maxMovingRows
 
+- **attribute:** `data-max-moving-rows`
+
 - **type:** `Integer`
 
 - **Detail:**
@@ -48,6 +52,8 @@ Dependence:
 
 ### dragaccept
 
+- **attribute:** `data-dragaccept`
+
 - **type:** `String`
 
 - **Detail:**

+ 16 - 0
site/docs/extensions/reorder-rows.md

@@ -27,6 +27,8 @@ if you want you can include the bootstrap-table-reorder-rows.css file to use the
 
 ### reorderableRows
 
+- **attribute:** `data-reorderable-rows`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -37,6 +39,8 @@ if you want you can include the bootstrap-table-reorder-rows.css file to use the
 
 ### onDragStyle
 
+- **attribute:** `data-on-drag-style`
+
 - **type:** `String`
 
 - **Detail:**
@@ -47,6 +51,8 @@ if you want you can include the bootstrap-table-reorder-rows.css file to use the
 
 ### onDropStyle
 
+- **attribute:** `data-on-drop-style`
+
 - **type:** `String`
 
 - **Detail:**
@@ -57,6 +63,8 @@ if you want you can include the bootstrap-table-reorder-rows.css file to use the
 
 ### onDragClass
 
+- **attribute:** `data-on-drag-class`
+
 - **type:** `String`
 
 - **Detail:**
@@ -67,6 +75,8 @@ if you want you can include the bootstrap-table-reorder-rows.css file to use the
 
 ### dragHandle
 
+- **attribute:** `data-drag-handle`
+
 - **type:** `String`
 
 - **Detail:**
@@ -77,6 +87,8 @@ if you want you can include the bootstrap-table-reorder-rows.css file to use the
 
 ### useRowAttrFunc
 
+- **attribute:** `data-use-row-attr-func`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -87,6 +99,8 @@ if you want you can include the bootstrap-table-reorder-rows.css file to use the
 
 ### onReorderRowsDrag
 
+- **attribute:** `data-on-reorder-rows-drag`
+
 - **type:** `Function`
 
 - **Detail:**
@@ -97,6 +111,8 @@ if you want you can include the bootstrap-table-reorder-rows.css file to use the
 
 ### onReorderRowsDrop
 
+- **attribute:** `data-on-reorder-rows-drop`
+
 - **type:** `Function`
 
 - **Detail:**

+ 2 - 0
site/docs/extensions/resizable.md

@@ -22,6 +22,8 @@ Dependence: [jquery-resizable-columns](https://github.com/dobtco/jquery-resizabl
 
 ### resizable
 
+- **attribute:** `data-resizable`
+
 - **type:** `Boolean`
 
 - **Detail:**

+ 8 - 0
site/docs/extensions/sticky-header.md

@@ -22,6 +22,8 @@ This is an extension which provides a sticky header for the table when scrolling
 
 ### stickyHeader
 
+- **attribute:** `data-sticky-header`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -32,6 +34,8 @@ This is an extension which provides a sticky header for the table when scrolling
 
 ### stickyHeaderOffsetY
 
+- **attribute:** `data-sticky-header-offset-y`
+
 - **type:** `Number`
 
 - **Detail:**
@@ -42,6 +46,8 @@ This is an extension which provides a sticky header for the table when scrolling
 
 ### stickyHeaderOffsetLeft
 
+- **attribute:** `data-sticky-header-offset-left`
+
 - **type:** `Number | String`
 
 - **Detail:**
@@ -52,6 +58,8 @@ This is an extension which provides a sticky header for the table when scrolling
 
 ### stickyHeaderOffsetRight
 
+- **attribute:** `data-sticky-header-offset-right`
+
 - **type:** `Number | String`
 
 - **Detail:**

+ 8 - 2
site/docs/extensions/toolbar.md

@@ -20,6 +20,8 @@ toc: true
 
 ### advancedSearch
 
+- **attribute:** `data-advanced-search`
+
 - **type:** `Boolean`
 
 - **Detail:**
@@ -30,6 +32,8 @@ toc: true
 
 ### idForm
 
+- **attribute:** `data-id-form`
+
 - **type:** `String`
 
 - **Detail:**
@@ -40,6 +44,8 @@ toc: true
 
 ### actionForm
 
+- **attribute:** `data-action-form`
+
 - **type:** `String`
 
 - **Detail:**
@@ -50,6 +56,8 @@ toc: true
 
 ### idTable
 
+- **attribute:** `data-id-table`
+
 - **type:** `String`
 
 - **Detail:**
@@ -62,7 +70,6 @@ toc: true
 
 ### formatAdvancedSearch
 
-
 - **Detail:**
 
    Title of the advanced search modal
@@ -71,7 +78,6 @@ toc: true
 
 ### formatAdvancedCloseButton
 
-
 - **Detail:**
 
    Text of the close button

+ 24 - 4
site/docs/extensions/treegrid.md

@@ -20,42 +20,62 @@ Dependence: [jquery-treegrid](https://github.com/maxazan/jquery-treegrid) v0.3.0
 
 ## Options
 
+### treeEnable
+
+- **attribute:** `data-tree-enable`
+
+- **type:** `Boolean`
+
+- **Detail:**
+
+   Set `true` to enable the tree grid.
+
+- **Default:** `false`
+
 ### idField
 
+- **attribute:** `data-id-field`
+
 - **type:** `String`
 
 - **Detail:**
 
-   overwrite the default idField to `'id'`
+   Overwrite the default idField to `'id'`.
 
 - **Default:** `'id'`
 
 ### treeShowField
 
+- **attribute:** `data-tree-show-field`
+
 - **type:** `String`
 
 - **Detail:**
 
-
+  Set the `treeShowField` will auto enable the tree grid.
 
 - **Default:** `''`
 
 ### parentIdField
 
+- **attribute:** `data-parent-id-field`
+
 - **type:** `String`
 
 - **Detail:**
 
-
+  Set the parent id field.
 
 - **Default:** `'pid'`
 
 ### rootParentId
 
+- **attribute:** `data-root-parent-id`
+
 - **type:** `String`
 
 - **Detail:**
 
-
+  Set the root parent id.
 
 - **Default:** `null`