diff --git a/gh-pages/docs/components/action.html b/gh-pages/docs/components/action.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/action.html +++ b/gh-pages/docs/components/action.html @@ -37,8 +37,8 @@
- - + + diff --git a/gh-pages/docs/components/alert.html b/gh-pages/docs/components/alert.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/alert.html +++ b/gh-pages/docs/components/alert.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/audio.html b/gh-pages/docs/components/audio.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/audio.html +++ b/gh-pages/docs/components/audio.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/button-group.html b/gh-pages/docs/components/button-group.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/button-group.html +++ b/gh-pages/docs/components/button-group.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/button.html b/gh-pages/docs/components/button.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/button.html +++ b/gh-pages/docs/components/button.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/card.html b/gh-pages/docs/components/card.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/card.html +++ b/gh-pages/docs/components/card.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/cards.html b/gh-pages/docs/components/cards.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/cards.html +++ b/gh-pages/docs/components/cards.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/carousel.html b/gh-pages/docs/components/carousel.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/carousel.html +++ b/gh-pages/docs/components/carousel.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/chart.html b/gh-pages/docs/components/chart.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/chart.html +++ b/gh-pages/docs/components/chart.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/collapse.html b/gh-pages/docs/components/collapse.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/collapse.html +++ b/gh-pages/docs/components/collapse.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/color.html b/gh-pages/docs/components/color.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/color.html +++ b/gh-pages/docs/components/color.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/component.html b/gh-pages/docs/components/component.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/component.html +++ b/gh-pages/docs/components/component.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/container.html b/gh-pages/docs/components/container.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/container.html +++ b/gh-pages/docs/components/container.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/crud.html b/gh-pages/docs/components/crud.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/crud.html +++ b/gh-pages/docs/components/crud.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/date.html b/gh-pages/docs/components/date.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/date.html +++ b/gh-pages/docs/components/date.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/dialog.html b/gh-pages/docs/components/dialog.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/dialog.html +++ b/gh-pages/docs/components/dialog.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/divider.html b/gh-pages/docs/components/divider.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/divider.html +++ b/gh-pages/docs/components/divider.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/drawer.html b/gh-pages/docs/components/drawer.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/drawer.html +++ b/gh-pages/docs/components/drawer.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/dropdown-button.html b/gh-pages/docs/components/dropdown-button.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/dropdown-button.html +++ b/gh-pages/docs/components/dropdown-button.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/each.html b/gh-pages/docs/components/each.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/each.html +++ b/gh-pages/docs/components/each.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/array.html b/gh-pages/docs/components/form/array.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/array.html +++ b/gh-pages/docs/components/form/array.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/button-group.html b/gh-pages/docs/components/form/button-group.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/button-group.html +++ b/gh-pages/docs/components/form/button-group.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/button-toolbar.html b/gh-pages/docs/components/form/button-toolbar.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/button-toolbar.html +++ b/gh-pages/docs/components/form/button-toolbar.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/button.html b/gh-pages/docs/components/form/button.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/button.html +++ b/gh-pages/docs/components/form/button.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/chain-select.html b/gh-pages/docs/components/form/chain-select.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/chain-select.html +++ b/gh-pages/docs/components/form/chain-select.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/checkbox.html b/gh-pages/docs/components/form/checkbox.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/checkbox.html +++ b/gh-pages/docs/components/form/checkbox.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/checkboxes.html b/gh-pages/docs/components/form/checkboxes.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/checkboxes.html +++ b/gh-pages/docs/components/form/checkboxes.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/city.html b/gh-pages/docs/components/form/city.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/city.html +++ b/gh-pages/docs/components/form/city.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/color.html b/gh-pages/docs/components/form/color.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/color.html +++ b/gh-pages/docs/components/form/color.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/combo.html b/gh-pages/docs/components/form/combo.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/combo.html +++ b/gh-pages/docs/components/form/combo.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/date-range.html b/gh-pages/docs/components/form/date-range.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/date-range.html +++ b/gh-pages/docs/components/form/date-range.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/date.html b/gh-pages/docs/components/form/date.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/date.html +++ b/gh-pages/docs/components/form/date.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/datetime-range.html b/gh-pages/docs/components/form/datetime-range.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/datetime-range.html +++ b/gh-pages/docs/components/form/datetime-range.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/datetime.html b/gh-pages/docs/components/form/datetime.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/datetime.html +++ b/gh-pages/docs/components/form/datetime.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/diff-editor.html b/gh-pages/docs/components/form/diff-editor.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/diff-editor.html +++ b/gh-pages/docs/components/form/diff-editor.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/editor.html b/gh-pages/docs/components/form/editor.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/editor.html +++ b/gh-pages/docs/components/form/editor.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/fieldset.html b/gh-pages/docs/components/form/fieldset.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/fieldset.html +++ b/gh-pages/docs/components/form/fieldset.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/file.html b/gh-pages/docs/components/form/file.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/file.html +++ b/gh-pages/docs/components/form/file.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/formitem.html b/gh-pages/docs/components/form/formitem.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/formitem.html +++ b/gh-pages/docs/components/form/formitem.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/formula.html b/gh-pages/docs/components/form/formula.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/formula.html +++ b/gh-pages/docs/components/form/formula.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/grid.html b/gh-pages/docs/components/form/grid.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/grid.html +++ b/gh-pages/docs/components/form/grid.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/group.html b/gh-pages/docs/components/form/group.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/group.html +++ b/gh-pages/docs/components/form/group.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/hbox.html b/gh-pages/docs/components/form/hbox.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/hbox.html +++ b/gh-pages/docs/components/form/hbox.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/hidden.html b/gh-pages/docs/components/form/hidden.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/hidden.html +++ b/gh-pages/docs/components/form/hidden.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/image.html b/gh-pages/docs/components/form/image.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/image.html +++ b/gh-pages/docs/components/form/image.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/index.html b/gh-pages/docs/components/form/index.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/index.html +++ b/gh-pages/docs/components/form/index.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/input-group.html b/gh-pages/docs/components/form/input-group.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/input-group.html +++ b/gh-pages/docs/components/form/input-group.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/list.html b/gh-pages/docs/components/form/list.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/list.html +++ b/gh-pages/docs/components/form/list.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/matrix.html b/gh-pages/docs/components/form/matrix.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/matrix.html +++ b/gh-pages/docs/components/form/matrix.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/nestedselect.html b/gh-pages/docs/components/form/nestedselect.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/nestedselect.html +++ b/gh-pages/docs/components/form/nestedselect.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/number.html b/gh-pages/docs/components/form/number.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/number.html +++ b/gh-pages/docs/components/form/number.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/options.html b/gh-pages/docs/components/form/options.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/options.html +++ b/gh-pages/docs/components/form/options.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/panel.html b/gh-pages/docs/components/form/panel.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/panel.html +++ b/gh-pages/docs/components/form/panel.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/picker.html b/gh-pages/docs/components/form/picker.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/picker.html +++ b/gh-pages/docs/components/form/picker.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/radios.html b/gh-pages/docs/components/form/radios.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/radios.html +++ b/gh-pages/docs/components/form/radios.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/range.html b/gh-pages/docs/components/form/range.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/range.html +++ b/gh-pages/docs/components/form/range.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/rating.html b/gh-pages/docs/components/form/rating.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/rating.html +++ b/gh-pages/docs/components/form/rating.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/repeat.html b/gh-pages/docs/components/form/repeat.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/repeat.html +++ b/gh-pages/docs/components/form/repeat.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/rich-text.html b/gh-pages/docs/components/form/rich-text.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/rich-text.html +++ b/gh-pages/docs/components/form/rich-text.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/select.html b/gh-pages/docs/components/form/select.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/select.html +++ b/gh-pages/docs/components/form/select.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/service.html b/gh-pages/docs/components/form/service.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/service.html +++ b/gh-pages/docs/components/form/service.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/static.html b/gh-pages/docs/components/form/static.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/static.html +++ b/gh-pages/docs/components/form/static.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/subform.html b/gh-pages/docs/components/form/subform.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/subform.html +++ b/gh-pages/docs/components/form/subform.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/switch.html b/gh-pages/docs/components/form/switch.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/switch.html +++ b/gh-pages/docs/components/form/switch.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/table.html b/gh-pages/docs/components/form/table.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/table.html +++ b/gh-pages/docs/components/form/table.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/tabs-transfer.html b/gh-pages/docs/components/form/tabs-transfer.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/tabs-transfer.html +++ b/gh-pages/docs/components/form/tabs-transfer.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/tabs.html b/gh-pages/docs/components/form/tabs.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/tabs.html +++ b/gh-pages/docs/components/form/tabs.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/tag.html b/gh-pages/docs/components/form/tag.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/tag.html +++ b/gh-pages/docs/components/form/tag.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/text.html b/gh-pages/docs/components/form/text.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/text.html +++ b/gh-pages/docs/components/form/text.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/textarea.html b/gh-pages/docs/components/form/textarea.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/textarea.html +++ b/gh-pages/docs/components/form/textarea.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/time.html b/gh-pages/docs/components/form/time.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/time.html +++ b/gh-pages/docs/components/form/time.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/transfer.html b/gh-pages/docs/components/form/transfer.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/transfer.html +++ b/gh-pages/docs/components/form/transfer.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/tree.html b/gh-pages/docs/components/form/tree.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/tree.html +++ b/gh-pages/docs/components/form/tree.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/form/treeselect.html b/gh-pages/docs/components/form/treeselect.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/form/treeselect.html +++ b/gh-pages/docs/components/form/treeselect.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/grid.html b/gh-pages/docs/components/grid.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/grid.html +++ b/gh-pages/docs/components/grid.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/hbox.html b/gh-pages/docs/components/hbox.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/hbox.html +++ b/gh-pages/docs/components/hbox.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/html.html b/gh-pages/docs/components/html.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/html.html +++ b/gh-pages/docs/components/html.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/icon.html b/gh-pages/docs/components/icon.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/icon.html +++ b/gh-pages/docs/components/icon.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/iframe.html b/gh-pages/docs/components/iframe.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/iframe.html +++ b/gh-pages/docs/components/iframe.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/image.html b/gh-pages/docs/components/image.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/image.html +++ b/gh-pages/docs/components/image.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/images.html b/gh-pages/docs/components/images.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/images.html +++ b/gh-pages/docs/components/images.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/json.html b/gh-pages/docs/components/json.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/json.html +++ b/gh-pages/docs/components/json.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/link.html b/gh-pages/docs/components/link.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/link.html +++ b/gh-pages/docs/components/link.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/list.html b/gh-pages/docs/components/list.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/list.html +++ b/gh-pages/docs/components/list.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/mapping.html b/gh-pages/docs/components/mapping.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/mapping.html +++ b/gh-pages/docs/components/mapping.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/nav.html b/gh-pages/docs/components/nav.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/nav.html +++ b/gh-pages/docs/components/nav.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/page.html b/gh-pages/docs/components/page.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/page.html +++ b/gh-pages/docs/components/page.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/panel.html b/gh-pages/docs/components/panel.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/panel.html +++ b/gh-pages/docs/components/panel.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/progress.html b/gh-pages/docs/components/progress.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/progress.html +++ b/gh-pages/docs/components/progress.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/qrcode.html b/gh-pages/docs/components/qrcode.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/qrcode.html +++ b/gh-pages/docs/components/qrcode.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/remark.html b/gh-pages/docs/components/remark.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/remark.html +++ b/gh-pages/docs/components/remark.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/service.html b/gh-pages/docs/components/service.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/service.html +++ b/gh-pages/docs/components/service.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/spinner.html b/gh-pages/docs/components/spinner.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/spinner.html +++ b/gh-pages/docs/components/spinner.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/status.html b/gh-pages/docs/components/status.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/status.html +++ b/gh-pages/docs/components/status.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/switch.html b/gh-pages/docs/components/switch.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/switch.html +++ b/gh-pages/docs/components/switch.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/table.html b/gh-pages/docs/components/table.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/table.html +++ b/gh-pages/docs/components/table.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/tabs.html b/gh-pages/docs/components/tabs.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/tabs.html +++ b/gh-pages/docs/components/tabs.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/tasks.html b/gh-pages/docs/components/tasks.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/tasks.html +++ b/gh-pages/docs/components/tasks.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/tpl.html b/gh-pages/docs/components/tpl.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/tpl.html +++ b/gh-pages/docs/components/tpl.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/video.html b/gh-pages/docs/components/video.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/video.html +++ b/gh-pages/docs/components/video.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/wizard.html b/gh-pages/docs/components/wizard.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/wizard.html +++ b/gh-pages/docs/components/wizard.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/components/wrapper.html b/gh-pages/docs/components/wrapper.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/components/wrapper.html +++ b/gh-pages/docs/components/wrapper.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/concepts/action.html b/gh-pages/docs/concepts/action.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/concepts/action.html +++ b/gh-pages/docs/concepts/action.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/concepts/data-mapping.html b/gh-pages/docs/concepts/data-mapping.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/concepts/data-mapping.html +++ b/gh-pages/docs/concepts/data-mapping.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/concepts/datascope-and-datachain.html b/gh-pages/docs/concepts/datascope-and-datachain.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/concepts/datascope-and-datachain.html +++ b/gh-pages/docs/concepts/datascope-and-datachain.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/concepts/expression.html b/gh-pages/docs/concepts/expression.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/concepts/expression.html +++ b/gh-pages/docs/concepts/expression.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/concepts/linkage.html b/gh-pages/docs/concepts/linkage.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/concepts/linkage.html +++ b/gh-pages/docs/concepts/linkage.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/concepts/schema.html b/gh-pages/docs/concepts/schema.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/concepts/schema.html +++ b/gh-pages/docs/concepts/schema.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/concepts/style.html b/gh-pages/docs/concepts/style.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/concepts/style.html +++ b/gh-pages/docs/concepts/style.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/concepts/template.html b/gh-pages/docs/concepts/template.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/concepts/template.html +++ b/gh-pages/docs/concepts/template.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/index.html b/gh-pages/docs/index.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/index.html +++ b/gh-pages/docs/index.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/start/custom.html b/gh-pages/docs/start/custom.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/start/custom.html +++ b/gh-pages/docs/start/custom.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/start/getting-started.html b/gh-pages/docs/start/getting-started.html index 7aa8f30c..970d1a1d 100644 --- a/gh-pages/docs/start/getting-started.html +++ b/gh-pages/docs/start/getting-started.html @@ -37,8 +37,8 @@ - - + + diff --git a/gh-pages/docs/start/getting-started_0f2c46d.js b/gh-pages/docs/start/getting-started_0f2c46d.js new file mode 100644 index 00000000..e0a8548b --- /dev/null +++ b/gh-pages/docs/start/getting-started_0f2c46d.js @@ -0,0 +1,82 @@ +amis.define('docs/start/getting-started.md', function(require, exports, module, define) { + + module.exports = { + "title": "快速开始", + "description": null, + "html": "amis 有两种使用方法:
\n\nnpm 适合用在 React 项目中,可以完整使用 amis 的所有功能,方便扩展。
\nSDK 适合对前端或 React 不了解的开发者,它不依赖 npm 及 webpack,直接引入代码就能使用,但需要注意这种方式难以支持 自定义组件,只能使用 amis 内置的组件。
\nnpm i amis\n
目前支持三种主题:default(默认主题)
、cxd(云舍)
和dark(暗黑)
html 中引入:
\n<link href=\"./node_modules/amis/lib/themes/default.css\" />\n<!-- 或 <link href=\"./node_modules/amis/lib/themes/cxd.css\" /> -->\n<!-- 或 <link href=\"./node_modules/amis/lib/themes/dark.css\" /> -->\n
js 中引入:
\nimport './node_modules/amis/lib/themes/default.css';\n// 或 import './node_modules/amis/lib/themes/cxd.css';\n// 或 import './node_modules/amis/lib/themes/dark.css';\n
\n\n\n上面只是示例,请根据自己的项目结构调整引用路径
\n
renderAmis(\n {\n type: 'page',\n title: '简单页面',\n body: '内容'\n },\n {},\n {\n // env...\n theme: 'default' // cxd 或 dark\n }\n);\n
\n可以在 React Component 这么使用(TypeScript)。
\nnpm i axios copy-to-clipboard\n
\n\n为了方便示例,上面选用了我们常用几个插件库,你完全可以选择自己喜欢的插件并重新实现
\n
import * as React from 'react';\nimport axios from 'axios';\nimport copy from 'copy-to-clipboard';\n\nimport {render as renderAmis} from 'amis';\nimport {alert, confirm} from 'amis/lib/components/Alert';\nimport {toast} from 'amis/lib/components/Toast';\n\nclass MyComponent extends React.Component<any, any> {\n render() {\n return (\n <div>\n <p>通过 amis 渲染页面</p>\n {renderAmis(\n {\n // 这里是 amis 的 Json 配置。\n type: 'page',\n title: '简单页面',\n body: '内容'\n },\n {\n // props...\n },\n {\n // env\n // 这些是 amis 需要的一些接口实现\n // 可以参考后面的参数介绍。\n\n jumpTo: (location: string /*目标地址*/) => {\n // 用来实现页面跳转, actionType:link、url 都会进来。\n // 因为不清楚所在环境中是否使用了 spa 模式,所以自己实现这个方法吧。\n },\n\n updateLocation: (\n location: string /*目标地址*/,\n replace: boolean /*是replace,还是push?*/\n ) => {\n // 地址替换,跟 jumpTo 类似\n },\n\n fetcher: ({\n url, // 接口地址\n method, // 请求方法 get、post、put、delete\n data, // 请求数据\n responseType,\n config, // 其他配置\n headers // 请求头\n }: any) => {\n config = config || {};\n config.withCredentials = true;\n responseType && (config.responseType = responseType);\n\n if (config.cancelExecutor) {\n config.cancelToken = new (axios as any).CancelToken(\n config.cancelExecutor\n );\n }\n\n config.headers = headers || {};\n\n if (method !== 'post' && method !== 'put' && method !== 'patch') {\n if (data) {\n config.params = data;\n }\n\n return (axios as any)[method](url, config);\n } else if (data && data instanceof FormData) {\n config.headers = config.headers || {};\n config.headers['Content-Type'] = 'multipart/form-data';\n } else if (\n data &&\n typeof data !== 'string' &&\n !(data instanceof Blob) &&\n !(data instanceof ArrayBuffer)\n ) {\n data = JSON.stringify(data);\n config.headers = config.headers || {};\n config.headers['Content-Type'] = 'application/json';\n }\n\n return (axios as any)[method](url, data, config);\n },\n isCancel: (value: any) => (axios as any).isCancel(value),\n notify: (\n type: 'error' | 'success' /**/,\n msg: string /*提示内容*/\n ) => {\n toast[type]\n ? toast[type](msg, type === 'error' ? '系统错误' : '系统消息')\n : console.warn('[Notify]', type, msg);\n },\n alert,\n confirm,\n copy: content => {\n copy(content);\n toast.success('内容已复制到粘贴板');\n }\n }\n )}\n </div>\n );\n }\n}\n
\n(schema, props, env) => JSX.Element;\n
\n即页面配置,请前往 配置与组件 了解
\n一般都用不上,如果你想传递一些数据给渲染器内部使用,可以传递 data 数据进去。如:
\n() =>\n renderAmis(schema, {\n data: {\n username: 'amis'\n }\n });\n
\n这样,内部所有组件都能拿到 username
这个变量的值。当然,这里的 key 并不一定必须是 data , 你也可以是其它 key,但必须配合 schema 中的 detectField
属性一起使用。 如:
() =>\n renderAmis(\n {\n //其它配置\n detectField: 'somekey'\n },\n {\n somekey: {\n username: 'amis'\n }\n }\n );\n
\n环境变量,可以理解为这个渲染器工具的配置项,需要使用 amis 用户实现部分接口。他有下面若干参数:
\n接口请求器,实现该函数才可以实现 ajax 发送,函数签名如下:
\n(config: {\n url; // 接口地址\n method; // 请求方法 get、post、put、delete\n data; // 请求数据\n responseType;\n config; // 其他配置\n headers; // 请求头\n}) => Promise<fetcherResult>;\n
\n\n\n你可以使用任何你喜欢的 ajax 请求库来实现这个接口
\n
(type: string, msg: string) => void\n
\n用来实现消息提示。
\n(msg: string) => void\n
\n用来实现警告提示。
\n(msg: string) => boolean | Promise<boolean>\n
\n用来实现确认框。返回 boolean 值
\n(to: string, action?: Action, ctx?: object) => void\n
\n用来实现页面跳转,因为不清楚所在环境中是否使用了 spa 模式,所以用户自己实现吧。
\n(location: any, replace?: boolean) => void\n
\n地址替换,跟 jumpTo 类似。
\n目前支持是三种主题:default
、cxd
和 dark
(link: string) => boolean;\n
\n判断目标地址是否为当前页面。
\n(contents: string, options?: {shutup: boolean})\n
\n用来实现内容复制。
\n默认为 'global',决定 store 是否为全局共用的,如果想单占一个 store,请设置不同的值。
\n() => HTMLElement;\n
\n用来决定弹框容器。
\n(schema: any, path: string) => Promise<Function>\n
\n可以通过它懒加载自定义组件,比如: https://github.com/baidu/amis/blob/master/__tests__/factory.test.tsx#L64-L91。
\n固顶间距,当你的有其他固顶元素时,需要设置一定的偏移量,否则会重叠。
\n固底间距,当你的有其他固底元素时,需要设置一定的偏移量,否则会重叠。
\n内置 rich-text 为 frolaEditor,想要使用,请自行购买,或者自己实现 rich-text 渲染器。
\nJSSDK 的代码从以下地址获取:
\n\n以上的 SDK 地址是一个页面跳转,会跳转到一个 CDN 地址,而且每次跳转都是最新的版本,随着 amis 的升级这个地址会一直变动,需要将这两个文件下载到本地,分别命名为 sdk.js 和 sdk.css,然后类似如下的方式使用:
\n<!DOCTYPE html>\n<html lang=\"zh\">\n <head>\n <meta charset=\"UTF-8\" />\n <title>AMIS Demo</title>\n <meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />\n <meta\n name=\"viewport\"\n content=\"width=device-width, initial-scale=1, maximum-scale=1\"\n />\n <meta http-equiv=\"X-UA-Compatible\" content=\"IE=Edge\" />\n <link rel=\"stylesheet\" href=\"amis/sdk.css\" />\n <style>\n html,\n body,\n .app-wrapper {\n position: relative;\n width: 100%;\n height: 100%;\n margin: 0;\n padding: 0;\n }\n </style>\n </head>\n <body>\n <div id=\"root\" class=\"app-wrapper\"></div>\n <script src=\"amis/sdk.js\"></script>\n <script type=\"text/javascript\">\n (function () {\n let amis = amisRequire('amis/embed');\n let amisScoped = amis.embed('#root', {\n type: 'page',\n title: 'AMIS Demo',\n body: 'hello world'\n });\n })();\n </script>\n </body>\n</html>\n
\namis.embed
函数还支持以下配置项来控制 amis 的行为,比如在 fetcher 的时候加入自己的处理逻辑,这些函数参数的说明在前面也有介绍。
let amisScoped = amis.embed(\n '#root',\n {\n type: 'page',\n title: 'AMIS Demo',\n body: 'This is a simple amis page.'\n },\n {\n // props 一般不用传。\n },\n {\n fetcher: (url, method, data, config) => {\n // 可以不传,用来实现 ajax 请求\n },\n\n jumpTo: location => {\n // 可以不传,用来实现页面跳转\n },\n\n updateLocation: (location, replace) => {\n // 可以不传,用来实现地址栏更新\n },\n\n isCurrentUrl: url => {\n // 可以不传,用来判断是否目标地址当前地址。\n },\n\n copy: content => {\n // 可以不传,用来实现复制到剪切板\n },\n\n notify: (type, msg) => {\n // 可以不传,用来实现通知\n },\n\n alert: content => {\n // 可以不传,用来实现提示\n },\n\n confirm: content => {\n // 可以不传,用来实现确认框。\n }\n }\n);\n
\n同时返回的 amisScoped
对象可以获取到 amis 渲染的内部信息,它有如下方法:
getComponentByName(name)
用于获取渲染出来的组件,比如下面的示例
{\n \"type\": \"page\",\n \"name\": \"page1\",\n \"title\": \"表单页面\",\n \"body\": {\n \"type\": \"form\",\n \"name\": \"form1\",\n \"controls\": [\n {\n \"label\": \"Name\",\n \"type\": \"text\",\n \"name\": \"name1\"\n }\n ]\n }\n}\n
\n可以通过 amisScoped.getComponentByName('page1.form1').getValues()
来获取到所有表单的值,需要注意 page 和 form 都需要有 name 属性。
amis 有两种使用方法:
\n\nnpm 适合用在 React 项目中,可以完整使用 amis 的所有功能,方便扩展。
\nSDK 适合对前端或 React 不了解的开发者,它不依赖 npm 及 webpack,直接引入代码就能使用,但需要注意这种方式难以支持 自定义组件,只能使用 amis 内置的组件。
\nnpm i amis\n
目前支持三种主题:default(默认主题)
、cxd(云舍)
和dark(暗黑)
html 中引入:
\n<link href=\"./node_modules/amis/lib/themes/default.css\" />\n<!-- 或 <link href=\"./node_modules/amis/lib/themes/cxd.css\" /> -->\n<!-- 或 <link href=\"./node_modules/amis/lib/themes/dark.css\" /> -->\n
js 中引入:
\nimport './node_modules/amis/lib/themes/default.css';\n// 或 import './node_modules/amis/lib/themes/cxd.css';\n// 或 import './node_modules/amis/lib/themes/dark.css';\n
\n\n\n上面只是示例,请根据自己的项目结构调整引用路径
\n
renderAmis(\n {\n type: 'page',\n title: '简单页面',\n body: '内容'\n },\n {},\n {\n // env...\n theme: 'default' // cxd 或 dark\n }\n);\n
\n可以在 React Component 这么使用(TypeScript)。
\nimport * as React from 'react';\nimport {render as renderAmis} from 'amis';\n\nclass MyComponent extends React.Component<any, any> {\n render() {\n return (\n <div>\n <p>通过 amis 渲染页面</p>\n {renderAmis(\n {\n // schema\n // 这里是 amis 的 Json 配置。\n type: 'page',\n title: '简单页面',\n body: '内容'\n },\n {\n // props\n },\n {\n // env\n // 这些是 amis 需要的一些接口实现\n // 可以参考后面的参数介绍。\n\n updateLocation: (\n location: string /*目标地址*/,\n replace: boolean /*是replace,还是push?*/\n ) => {\n // 用来更新地址栏\n },\n\n jumpTo: (location: string /*目标地址*/) => {\n // 页面跳转, actionType: link、url 都会进来。\n },\n\n fetcher: ({\n url,\n method,\n data,\n config\n }: {\n url: string /*目标地址*/;\n method: 'get' | 'post' | 'put' | 'delete' /*发送方式*/;\n data: object | void /*数据*/;\n config: object /*其他配置*/;\n }) => {\n // 用来发送 Ajax 请求,建议使用 axios\n },\n notify: (\n type: 'error' | 'success' /**/,\n msg: string /*提示内容*/\n ) => {\n // 用来提示用户\n },\n alert: (content: string /*提示信息*/) => {\n // 另外一种提示,可以直接用系统框\n },\n confirm: (content: string /*提示信息*/) => {\n // 确认框。\n }\n }\n )}\n </div>\n );\n }\n}\n
\n(schema:Schema, props?:any, env?: any) => JSX.Element
参数说明:
\nschema
即页面配置,请前往 配置与组件 了解.props
一般都用不上,如果你想传递一些数据给渲染器内部使用,可以传递 data 数据进去。如:
() =>\n renderAmis(schema, {\n data: {\n username: 'amis'\n }\n });\n
\n这样,内部所有组件都能拿到 username
这个变量的值。当然,这里的 key 并不一定必须是 data , 你也可以是其它 key,但必须配合 schema 中的 detectField
属性一起使用。 如:
() =>\n renderAmis(\n {\n //其它配置\n detectField: 'somekey'\n },\n {\n somekey: {\n username: 'amis'\n }\n }\n );\n
\nenv
环境变量,可以理解为这个渲染器工具的配置项,需要调用者实现部分接口。
session: string
默认为 'global',决定 store 是否为全局共用的,如果想单占一个 store,请设置不同的值。fetcher: (config: fetcherConfig) => Promise<fetcherResult>
用来实现 ajax 发送。
示例
\nfetcher: ({\n url,\n method,\n data,\n responseType,\n config,\n headers\n}: any) => {\n config = config || {};\n config.withCredentials = true;\n responseType && (config.responseType = responseType);\n\n if (config.cancelExecutor) {\n config.cancelToken = new (axios as any).CancelToken(config.cancelExecutor);\n }\n\n config.headers = headers || {};\n\n if (method !== 'post' && method !== 'put' && method !== 'patch') {\n if (data) {\n config.params = data;\n }\n\n return (axios as any)[method](url, config);\n } else if (data && data instanceof FormData) {\n // config.headers = config.headers || {};\n // config.headers['Content-Type'] = 'multipart/form-data';\n } else if (data\n && typeof data !== 'string'\n && !(data instanceof Blob)\n && !(data instanceof ArrayBuffer)\n ) {\n data = JSON.stringify(data);\n // config.headers = config.headers || {};\n config.headers['Content-Type'] = 'application/json';\n }\n\n return (axios as any)[method](url, data, config);\n}\n
\nisCancel: (e:error) => boolean
判断 ajax 异常是否为一个 cancel 请求。
示例
\nisCancel: (value: any) => (axios as any).isCancel(value)\n
\nnotify: (type:string, msg: string) => void
用来实现消息提示。
alert: (msg:string) => void
用来实现警告提示。confirm: (msg:string) => boolean | Promise<boolean>
用来实现确认框。jumpTo: (to:string, action?: Action, ctx?: object) => void
用来实现页面跳转,因为不清楚所在环境中是否使用了 spa 模式,所以用户自己实现吧。updateLocation: (location:any, replace?:boolean) => void
地址替换,跟 jumpTo 类似。isCurrentUrl: (link:string) => boolean
判断目标地址是否为当前页面。theme: 'default' | 'cxd'
目前支持两种主题。copy: (contents:string, options?: {shutup: boolean}) => void
用来实现,内容复制。getModalContainer: () => HTMLElement
用来决定弹框容器。loadRenderer: (chema:any, path:string) => Promise<Function>
可以通过它懒加载自定义组件,比如: https://github.com/baidu/amis/blob/master/__tests__/factory.test.tsx#L64-L91。affixOffsetTop: number
固顶间距,当你的有其他固顶元素时,需要设置一定的偏移量,否则会重叠。affixOffsetBottom: number
固底间距,当你的有其他固底元素时,需要设置一定的偏移量,否则会重叠。richTextToken: string
内置 rich-text 为 frolaEditor,想要使用,请自行购买,或者自己实现 rich-text 渲染器。JSSDK 的代码从以下地址获取:
\n\n以上的 SDK 地址是一个页面跳转,会跳转到一个 CDN 地址,而且每次跳转都是最新的版本,随着 amis 的升级这个地址会一直变动,需要将这两个文件下载到本地,分别命名为 sdk.js 和 sdk.css,然后类似如下的方式使用:
\n<!DOCTYPE html>\n<html lang=\"zh\">\n <head>\n <meta charset=\"UTF-8\" />\n <title>AMIS Demo</title>\n <meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />\n <meta\n name=\"viewport\"\n content=\"width=device-width, initial-scale=1, maximum-scale=1\"\n />\n <meta http-equiv=\"X-UA-Compatible\" content=\"IE=Edge\" />\n <link rel=\"stylesheet\" href=\"amis/sdk.css\" />\n <style>\n html,\n body,\n .app-wrapper {\n position: relative;\n width: 100%;\n height: 100%;\n margin: 0;\n padding: 0;\n }\n </style>\n </head>\n <body>\n <div id=\"root\" class=\"app-wrapper\"></div>\n <script src=\"amis/sdk.js\"></script>\n <script type=\"text/javascript\">\n (function () {\n let amis = amisRequire('amis/embed');\n let amisScoped = amis.embed('#root', {\n type: 'page',\n title: 'AMIS Demo',\n body: 'hello world'\n });\n })();\n </script>\n </body>\n</html>\n
\namis.embed
函数还支持以下配置项来控制 amis 的行为,比如在 fetcher 的时候加入自己的处理逻辑,这些函数参数的说明在前面也有介绍。
let amisScoped = amis.embed(\n '#root',\n {\n type: 'page',\n title: 'AMIS Demo',\n body: 'This is a simple amis page.'\n },\n {\n // props 一般不用传。\n },\n {\n fetcher: (url, method, data, config) => {\n // 可以不传,用来实现 ajax 请求\n },\n\n jumpTo: (location) => {\n // 可以不传,用来实现页面跳转\n },\n\n updateLocation: (location, replace) => {\n // 可以不传,用来实现地址栏更新\n },\n\n isCurrentUrl: (url) => {\n // 可以不传,用来判断是否目标地址当前地址。\n },\n\n copy: (content) => {\n // 可以不传,用来实现复制到剪切板\n },\n\n notify: (type, msg) => {\n // 可以不传,用来实现通知\n },\n\n alert: (content) => {\n // 可以不传,用来实现提示\n },\n\n confirm: (content) => {\n // 可以不传,用来实现确认框。\n }\n }\n);\n
\n同时返回的 amisScoped
对象可以获取到 amis 渲染的内部信息,它有如下方法:
getComponentByName(name)
用于获取渲染出来的组件,比如下面的示例
{\n \"type\": \"page\",\n \"name\": \"page1\",\n \"title\": \"表单页面\",\n \"body\": {\n \"type\": \"form\",\n \"name\": \"form1\",\n \"controls\": [\n {\n \"label\": \"Name\",\n \"type\": \"text\",\n \"name\": \"name1\"\n }\n ]\n }\n}\n
\n可以通过 amisScoped.getComponentByName('page1.form1').getValues()
来获取到所有表单的值,需要注意 page 和 form 都需要有 name 属性。
API 类型用于配置请求接口的格式,涉及请求方式、请求地址、请求数据体等等相关配置
\n如果你只需要配置简单的 ajax 接口,可以使用简单字符串格式,如下:
\n[<method>:]<url>\n
示例:
\n{\n \"api\": \"get:/api/initData\", // get 请求\n \"api\": \"post:/api/initData\", // post 请求\n \"api\": \"put:/api/initData\", // put 请求\n \"api\": \"delete:/api/initData\" // delete 请求\n}\n
\n所有配置在 amis 组件中的接口,都要符合下面的返回格式
\n{\n \"status\": 0,\n \"msg\": \"\",\n \"data\": {\n ...其他字段\n }\n}\n
\n0
,表示当前接口正确返回,否则按错误请求处理;toast
显示;key-value
结构的对象。status
、msg
和 data
字段为接口返回的必要字段;
{\n \"status\": 0,\n \"msg\": \"\",\n \"data\": {\n // 正确\n \"text\": \"World!\"\n }\n}\n
\n直接返回字符串或者数组都是不推荐的
\n{\n \"status\": 0,\n \"msg\": \"\",\n \"data\": \"some string\" // 错误,使用 key 包装\n}\n
\n部分组件为了可以兼容,支持下面这种直接返回数组的用法,但并不推荐这种方式。
\n{\n \"status\": 0,\n \"msg\": \"\",\n \"data\": [\"a\", \"b\"] // 不推荐,使用 key 包装\n}\n
\nAPI 还支持配置对象类型
\n{\n \"api\": {\n \"method\": \"get\",\n \"url\": \"xxxx\",\n \"data\": {\n xxx\n },\n ... // 其他配置\n }\n}\n
\n可以配置method
指定接口的请求方式,支持:get
、post
、put
、delete
。
\n\n\n
method
值留空时:\n
\n- 在初始化接口中,默认为
\nget
请求- 在
\nform
提交接口,默认为post
请求
可以配置url
指定接口请求地址,支持模板字符串。
可以配置data
,配置自定义接口请求数据体。
支持数据映射
\n\n\n当
\nmethod
配置为get
时,data
中的值默认会添加到请求路径中
可以配置dataType
,来指定请求的数据体格式,默认为json
\n\n下面例子中 api 没有配置
\ndata
属性,因为form
会默认将所有表单项的值进行提交。
默认是application/json
,不需要额外配置
配置"dataType": "form"
,可配置发送体格式为application/x-www-form-urlencoded
配置"dataType": "form-data"
,可配置发送体格式为multipart/form-data
当表单项中文件类型数据,则自动使用multipart/form-data
数据体
\n\n\n
asBlob
配置项会指定当前 File 控件不再自己上传了,而是直接把文件数据作为表单项的值,文件内容会在 Form 表单提交的接口里面一起带上。
可以配置headers
对象,添加自定义请求头
可以配置表达式sendOn
来实现:当符合某个条件的情况下,接口才触发请求
查看 选项 2 的source
属性,他是 API 类型值,支持配置sendOn
表达式,实现根据条件请求接口。
当你在某种情况下,需要非常频繁的请求同一个接口,例如列表中,每一行中都有一个 Service 进行数据拉取操作,
\n\n如上,如果你打开浏览器网络面板,会发现/api/mock2/page/initData
接口将重复请求多次,次数为你当前列表的数据条数。
这往往并不理想,你可以设置cache
来设置缓存时间,单位是毫秒,在设置的缓存时间内,同样的请求将不会重复发起,而是会获取缓存好的请求响应数据。
这下我们再打开网络面板,发现只有一条请求了
\namis 的 API 配置,如果无法配置出你想要的请求结构,那么可以配置requestAdaptor
发送适配器
发送适配器是指在接口请求前,对请求进行一些自定义处理,例如修改发送数据体、添加请求头、等等,基本用法是,获取暴露的api
参数,并且对该参数进行一些修改,并return
出去:
如果在 JSON 文件中配置的话,requestAdaptor
只支持字符串形式,如下:
上例中的适配器实际上是如下代码的字符串形式:
\nreturn {\n ...api,\n data: {\n ...api.data, // 获取暴露的 api 中的 data 变量\n foo: 'bar' // 新添加数据\n }\n};\n
\n如果你的使用环境为 js 文件,则可以直接传入函数,如下:
\nconst schema = {\n type: 'form',\n api: {\n method: 'post',\n url: 'https://houtai.baidu.com/api/mock2/form/saveForm',\n requestAdaptor: function (api) {\n return {\n ...api,\n data: {\n ...api.data, // 获取暴露的 api 中的 data 变量\n foo: 'bar' // 新添加数据\n }\n };\n }\n },\n controls: [\n {\n type: 'text',\n name: 'name',\n label: '姓名:'\n },\n {\n name: 'text',\n type: 'email',\n label: '邮箱:'\n }\n ]\n};\n
\n上面例子中,我们获取暴露的api
对象中的data
变量,并且为其添加了一个新的字段foo
,并且一起返回出去就可以了,这样我们的请求数据体中就会加上我们这个新的字段。
api
变量中一般会包含下面几个属性:
你也可以使用debugger
自行进行调试。
同样的,如果后端返回的响应结构不符合 amis 的接口格式要求,而后端不方便调整时,可以配置adaptor
实现接收适配器
接受欧适配器是指在接口请求后,对响应进行一些自定义处理,例如修改响应的数据结构、修改响应的数据等等。
\n例如:接口正确返回的格式中,会返回"code": 200
,而 amis 中,接口返回格式需要"status": 0
,这时候就需要接收适配器进行调整结构。
如果在 JSON 文件中配置的话,adaptor
只支持字符串形式,如下:
{\n \"type\": \"form\",\n \"api\": {\n \"method\": \"post\",\n \"url\": \"https://houtai.baidu.com/api/mock2/form/saveForm\",\n \"adaptor\": \"return {\\n ...payload,\\n status: payload.code === 200 ? 0 : payload.code\\n}\"\n },\n \"controls\": [\n {\n \"type\": \"text\",\n \"name\": \"name\",\n \"label\": \"姓名:\"\n },\n {\n \"name\": \"file\",\n \"type\": \"file\",\n \"label\": \"附件:\",\n \"asBlob\": true\n }\n ]\n}\n
\n上例中的适配器实际上是如下代码的字符串形式:
\nreturn {\n ...payload,\n status: payload.code === 200 ? 0 : payload.code\n};\n
\n如果你的使用环境为 js 文件,则可以直接传入函数,如下:
\nconst schema = {\n type: 'form',\n api: {\n method: 'post',\n url: 'https://houtai.baidu.com/api/mock2/form/saveForm',\n adaptor: function (payload, response) {\n return {\n ...payload,\n status: payload.code === 200 ? 0 : payload.code\n };\n }\n },\n controls: [\n {\n type: 'text',\n name: 'name',\n label: '姓名:'\n },\n {\n name: 'email',\n type: 'email',\n label: '邮箱:'\n }\n ]\n};\n
\n返回的数据是否替换掉当前的数据,默认为 false
(即追加),设置为true
就是完全替换当前数据。
字段名 | \n说明 | \n类型 | \n备注 | \n
---|---|---|---|
method | \n请求方式 | \n字符串 | \n支持:get、post、put、delete | \n
url | \n请求地址 | \n模板字符串 | \n- | \n
data | \n请求数据 | \n对象或字符串 | \n支持数据映射 | \n
dataType | \n数据体格式 | \n字符串 | \n默认为 json 可以配置成 form 或者 form-data 。当 data 中包含文件时,自动会采用 form-data(multipart/form-data) 格式。当配置为 form 时为 application/x-www-form-urlencoded 格式。 | \n
qsOptions | \n-- | \n对象或字符串 | \n当 dataType 为 form 或者 form-data 的时候有用。具体参数请参考这里,默认设置为: { arrayFormat: 'indices', encodeValuesOnly: true } | \n
headers | \n请求头 | \n对象 | \n- | \n
sendOn | \n请求条件 | \n表达式 | \n- | \n
cache | \n接口缓存时间 | \n整型数字 | \n- | \n
requestAdaptor | \n发送适配器 | \n字符串 | \n,支持字符串串格式,或者直接就是函数如: | \n
adaptor | \n接收适配器 | \n字符串 | \n如果接口返回不符合要求,可以通过配置一个适配器来处理成 amis 需要的。同样支持 Function 或者 字符串函数体格式 | \n
replaceData | \n替换当前数据 | \n布尔 | \n返回的数据是否替换掉当前的数据,默认为 false ,即:追加 ,设置成 true 就是完全替换。 | \n
API 类型用于配置请求接口的格式,涉及请求方式、请求地址、请求数据体等等相关配置
\n如果你只需要配置简单的 ajax 接口,可以使用简单字符串格式,如下:
\n[<method>:]<url>\n
示例:
\n{\n \"api\": \"get:/api/initData\", // get 请求\n \"api\": \"post:/api/initData\", // post 请求\n \"api\": \"put:/api/initData\", // put 请求\n \"api\": \"delete:/api/initData\" // delete 请求\n}\n
\n所有配置在 amis 组件中的接口,都要符合下面的返回格式
\n{\n \"status\": 0,\n \"msg\": \"\",\n \"data\": {\n ...其他字段\n }\n}\n
\n0
,表示当前接口正确返回,否则按错误请求处理;toast
显示;key-value
结构的对象。status
、msg
和 data
字段为接口返回的必要字段;
{\n \"status\": 0,\n \"msg\": \"\",\n \"data\": {\n // 正确\n \"text\": \"World!\"\n }\n}\n
\n直接返回字符串或者数组都是不推荐的
\n{\n \"status\": 0,\n \"msg\": \"\",\n \"data\": \"some string\" // 错误,使用 key 包装\n}\n
\n部分组件为了可以兼容,支持下面这种直接返回数组的用法,但并不推荐这种方式。
\n{\n \"status\": 0,\n \"msg\": \"\",\n \"data\": [\"a\", \"b\"] // 不推荐,使用 key 包装\n}\n
\nAPI 还支持配置对象类型
\n{\n \"api\": {\n \"method\": \"get\",\n \"url\": \"xxxx\",\n \"data\": {\n xxx\n },\n ... // 其他配置\n }\n}\n
\n可以配置method
指定接口的请求方式,支持:get
、post
、put
、delete
。
\n\n\n
method
值留空时:\n
\n- 在初始化接口中,默认为
\nget
请求- 在
\nform
提交接口,默认为post
请求
可以配置url
指定接口请求地址,支持模板字符串。
可以配置data
,配置自定义接口请求数据体。
支持数据映射
\n\n\n当
\nmethod
配置为get
时,data
中的值默认会添加到请求路径中
可以配置dataType
,来指定请求的数据体格式,默认为json
\n\n下面例子中 api 没有配置
\ndata
属性,因为form
会默认将所有表单项的值进行提交。
默认是application/json
,不需要额外配置
配置"dataType": "form"
,可配置发送体格式为application/x-www-form-urlencoded
配置"dataType": "form-data"
,可配置发送体格式为multipart/form-data
当表单项中文件类型数据,则自动使用multipart/form-data
数据体
\n\n\n
asBlob
配置项会指定当前 File 控件不再自己上传了,而是直接把文件数据作为表单项的值,文件内容会在 Form 表单提交的接口里面一起带上。
可以配置headers
对象,添加自定义请求头
可以配置表达式sendOn
来实现:当符合某个条件的情况下,接口才触发请求
查看 选项 2 的source
属性,他是 API 类型值,支持配置sendOn
表达式,实现根据条件请求接口。
当你在某种情况下,需要非常频繁的请求同一个接口,例如列表中,每一行中都有一个 Service 进行数据拉取操作,
\n\n如上,如果你打开浏览器网络面板,会发现/api/mock2/page/initData
接口将重复请求多次,次数为你当前列表的数据条数。
这往往并不理想,你可以设置cache
来设置缓存时间,单位是毫秒,在设置的缓存时间内,同样的请求将不会重复发起,而是会获取缓存好的请求响应数据。
这下我们再打开网络面板,发现只有一条请求了
\namis 的 API 配置,如果无法配置出你想要的请求结构,那么可以配置requestAdaptor
发送适配器
发送适配器 是指在接口请求前,对请求进行一些自定义处理,例如修改发送数据体、添加请求头、等等,基本用法是,获取暴露的api
参数,并且对该参数进行一些修改,并return
出去:
发送适配器暴露以下参数以供用户进行操作:
\n如果在 JSON 文件中配置的话,requestAdaptor
只支持字符串形式。
字符串形式实际上可以认为是外层包裹了一层函数,你需要补充内部的函数实现,并将修改好的 api
对象 return
出去:
function (api) {\n // 你的适配器代码\n}\n
\n用法示例:
\n\n上例中的适配器实际上是如下代码的字符串形式:
\n// 进行一些操作\n\n// 一定要将调整后的 api 对象 return 出去\nreturn {\n ...api,\n data: {\n ...api.data, // 获取暴露的 api 中的 data 变量\n foo: 'bar' // 新添加数据\n }\n};\n
\n如果你的使用环境为 js 文件,则可以直接传入函数,如下:
\nconst schema = {\n type: 'form',\n api: {\n method: 'post',\n url: 'https://houtai.baidu.com/api/mock2/form/saveForm',\n requestAdaptor: function (api) {\n return {\n ...api,\n data: {\n ...api.data, // 获取暴露的 api 中的 data 变量\n foo: 'bar' // 新添加数据\n }\n };\n }\n },\n controls: [\n {\n type: 'text',\n name: 'name',\n label: '姓名:'\n },\n {\n name: 'text',\n type: 'email',\n label: '邮箱:'\n }\n ]\n};\n
\n上面例子中,我们获取暴露的api
对象中的data
变量,并且为其添加了一个新的字段foo
,并且一起返回出去就可以了,这样我们的请求数据体中就会加上我们这个新的字段。
你也可以使用debugger
自行进行调试。
同样的,如果后端返回的响应结构不符合 amis 的接口格式要求,而后端不方便调整时,可以配置adaptor
实现接收适配器
接收适配器 是指在接口请求后,对响应进行一些自定义处理,例如修改响应的数据结构、修改响应的数据等等。
\n例如:接口正确返回的格式中,会返回"code": 200
,而 amis 中,接口返回格式需要"status": 0
,这时候就需要接收适配器进行调整结构。
接收适配器器暴露以下参数以供用户进行操作:
\n如果在 JSON 文件中配置的话,adaptor
只支持字符串形式。
字符串形式实际上可以认为是外层包裹了一层函数,你需要补充内部的函数实现,并将修改好的 payload
对象 return
出去:
function (payload, responsee) {\n // 你的适配器代码\n}\n
\n用法示例:
\n{\n \"type\": \"form\",\n \"api\": {\n \"method\": \"post\",\n \"url\": \"https://houtai.baidu.com/api/mock2/form/saveForm\",\n \"adaptor\": \"return {\\n ...payload,\\n status: payload.code === 200 ? 0 : payload.code\\n}\"\n },\n \"controls\": [\n {\n \"type\": \"text\",\n \"name\": \"name\",\n \"label\": \"姓名:\"\n },\n {\n \"name\": \"file\",\n \"type\": \"file\",\n \"label\": \"附件:\",\n \"asBlob\": true\n }\n ]\n}\n
\n上例中的适配器实际上是如下代码的字符串形式:
\n// 进行一些操作\n\n// 一定要将调整后的 payload 对象 return 出去\nreturn {\n ...payload,\n status: payload.code === 200 ? 0 : payload.code\n};\n
\n如果你的使用环境为 js 文件,则可以直接传入函数,如下:
\nconst schema = {\n type: 'form',\n api: {\n method: 'post',\n url: 'https://houtai.baidu.com/api/mock2/form/saveForm',\n adaptor: function (payload, response) {\n return {\n ...payload,\n status: payload.code === 200 ? 0 : payload.code\n };\n }\n },\n controls: [\n {\n type: 'text',\n name: 'name',\n label: '姓名:'\n },\n {\n name: 'email',\n type: 'email',\n label: '邮箱:'\n }\n ]\n};\n
\n返回的数据是否替换掉当前的数据,默认为 false
(即追加),设置为true
就是完全替换当前数据。
字段名 | \n说明 | \n类型 | \n备注 | \n
---|---|---|---|
method | \n请求方式 | \n字符串 | \n支持:get、post、put、delete | \n
url | \n请求地址 | \n模板字符串 | \n- | \n
data | \n请求数据 | \n对象或字符串 | \n支持数据映射 | \n
dataType | \n数据体格式 | \n字符串 | \n默认为 json 可以配置成 form 或者 form-data 。当 data 中包含文件时,自动会采用 form-data(multipart/form-data) 格式。当配置为 form 时为 application/x-www-form-urlencoded 格式。 | \n
qsOptions | \n-- | \n对象或字符串 | \n当 dataType 为 form 或者 form-data 的时候有用。具体参数请参考这里,默认设置为: { arrayFormat: 'indices', encodeValuesOnly: true } | \n
headers | \n请求头 | \n对象 | \n- | \n
sendOn | \n请求条件 | \n表达式 | \n- | \n
cache | \n接口缓存时间 | \n整型数字 | \n- | \n
requestAdaptor | \n发送适配器 | \n字符串 | \n,支持字符串串格式,或者直接就是函数如: | \n
adaptor | \n接收适配器 | \n字符串 | \n如果接口返回不符合要求,可以通过配置一个适配器来处理成 amis 需要的。同样支持 Function 或者 字符串函数体格式 | \n
replaceData | \n替换当前数据 | \n布尔 | \n返回的数据是否替换掉当前的数据,默认为 false ,即:追加 ,设置成 true 就是完全替换。 | \n