d2coreui 21.0.33 → 23.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/clipboard/clipboardUtils.d.ts +4 -3
- package/components/clipboard/clipboardUtils.js +47 -22
- package/components/clipboard/clipboardUtils.js.map +1 -1
- package/components/codemirror/SyntaxHighlighter.d.ts +21 -21
- package/components/codemirror/SyntaxHighlighter.js +45 -44
- package/components/codemirror/SyntaxHighlighter.js.map +1 -1
- package/components/collapse/expandable.d.ts +13 -12
- package/components/collapse/expandable.js +20 -20
- package/components/collapse/expandable.js.map +1 -1
- package/components/color/colorPicker.d.ts +20 -20
- package/components/color/colorPicker.js +53 -53
- package/components/color/colorPicker.js.map +1 -1
- package/components/color/colorSwatch.d.ts +13 -12
- package/components/color/colorSwatch.js +62 -62
- package/components/color/colorSwatch.js.map +1 -1
- package/components/color/colorUtils.d.ts +7 -7
- package/components/color/colorUtils.js +43 -43
- package/components/color/colorUtils.js.map +1 -1
- package/components/date/dateRangeInput.d.ts +66 -64
- package/components/date/dateRangeInput.js +292 -297
- package/components/date/dateRangeInput.js.map +1 -1
- package/components/date/dateRangeInputAdvancedPanel.d.ts +27 -26
- package/components/date/dateRangeInputAdvancedPanel.js +130 -115
- package/components/date/dateRangeInputAdvancedPanel.js.map +1 -1
- package/components/date/dateRangeInputConfirm.d.ts +31 -29
- package/components/date/dateRangeInputConfirm.js +132 -121
- package/components/date/dateRangeInputConfirm.js.map +1 -1
- package/components/date/dateTimeInput.d.ts +72 -69
- package/components/date/dateTimeInput.js +440 -412
- package/components/date/dateTimeInput.js.map +1 -1
- package/components/date/durationInput.d.ts +59 -56
- package/components/date/durationInput.js +269 -280
- package/components/date/durationInput.js.map +1 -1
- package/components/form/NiceFormItem.d.ts +14 -14
- package/components/form/NiceFormItem.js +28 -31
- package/components/form/NiceFormItem.js.map +1 -1
- package/components/grid/cell/beanAccessor.d.ts +9 -0
- package/components/grid/cell/beanAccessor.js +13 -0
- package/components/grid/cell/beanAccessor.js.map +1 -0
- package/components/grid/cell/cellEditorUtils.d.ts +4 -4
- package/components/grid/cell/cellEditorUtils.js +8 -8
- package/components/grid/cell/customEnumCellEditor.d.ts +4 -26
- package/components/grid/cell/customEnumCellEditor.js +82 -91
- package/components/grid/cell/customEnumCellEditor.js.map +1 -1
- package/components/grid/cell/dataGridCellEditorComponent.d.ts +14 -0
- package/components/grid/cell/dataGridCellEditorComponent.js +49 -0
- package/components/grid/cell/dataGridCellEditorComponent.js.map +1 -0
- package/components/grid/cell/dateCellEditor.d.ts +4 -25
- package/components/grid/cell/dateCellEditor.js +53 -72
- package/components/grid/cell/dateCellEditor.js.map +1 -1
- package/components/grid/cell/durationCellEditor.d.ts +4 -24
- package/components/grid/cell/durationCellEditor.js +74 -97
- package/components/grid/cell/durationCellEditor.js.map +1 -1
- package/components/grid/cell/hexaOctetStringCellEditor.d.ts +4 -24
- package/components/grid/cell/hexaOctetStringCellEditor.js +70 -94
- package/components/grid/cell/hexaOctetStringCellEditor.js.map +1 -1
- package/components/grid/cell/hexaValueCellEditor.d.ts +4 -24
- package/components/grid/cell/hexaValueCellEditor.js +65 -89
- package/components/grid/cell/hexaValueCellEditor.js.map +1 -1
- package/components/grid/cell/numberCellEditor.d.ts +4 -27
- package/components/grid/cell/numberCellEditor.js +73 -95
- package/components/grid/cell/numberCellEditor.js.map +1 -1
- package/components/grid/cell/rangeSelector.d.ts +78 -78
- package/components/grid/cell/rangeSelector.js +526 -518
- package/components/grid/cell/rangeSelector.js.map +1 -1
- package/components/grid/cell/simpleStatusTextCellEditor.d.ts +4 -32
- package/components/grid/cell/simpleStatusTextCellEditor.js +106 -116
- package/components/grid/cell/simpleStatusTextCellEditor.js.map +1 -1
- package/components/grid/cell/statusTextCellEditor.d.ts +4 -32
- package/components/grid/cell/statusTextCellEditor.js +136 -159
- package/components/grid/cell/statusTextCellEditor.js.map +1 -1
- package/components/grid/cell/tableDefaultRowStyleRules.d.ts +20 -20
- package/components/grid/cell/tableDefaultRowStyleRules.js +29 -18
- package/components/grid/cell/tableDefaultRowStyleRules.js.map +1 -1
- package/components/grid/cell/textCellEditor.d.ts +4 -21
- package/components/grid/cell/textCellEditor.js +63 -85
- package/components/grid/cell/textCellEditor.js.map +1 -1
- package/components/grid/cell/withAgGridHooks.d.ts +3 -0
- package/components/grid/cell/withAgGridHooks.js +15 -0
- package/components/grid/cell/withAgGridHooks.js.map +1 -0
- package/components/grid/columnUtils.d.ts +5 -5
- package/components/grid/columnUtils.js +26 -26
- package/components/grid/columnUtils.js.map +1 -1
- package/components/grid/config/columnTransfer.d.ts +21 -22
- package/components/grid/config/columnTransfer.js +205 -201
- package/components/grid/config/columnTransfer.js.map +1 -1
- package/components/grid/config/dataGridEditor.d.ts +41 -41
- package/components/grid/config/dataGridEditor.js +181 -160
- package/components/grid/config/dataGridEditor.js.map +1 -1
- package/components/grid/config/rowHeightCalculator.d.ts +8 -0
- package/components/grid/config/rowHeightCalculator.js +20 -0
- package/components/grid/config/rowHeightCalculator.js.map +1 -0
- package/components/grid/config/rowStylePicker.d.ts +27 -25
- package/components/grid/config/rowStylePicker.js +127 -109
- package/components/grid/config/rowStylePicker.js.map +1 -1
- package/components/grid/dataGrid.d.ts +218 -206
- package/components/grid/dataGrid.js +1629 -1538
- package/components/grid/dataGrid.js.map +1 -1
- package/components/grid/detail/detailHeaderPanel.d.ts +13 -13
- package/components/grid/detail/detailHeaderPanel.js +25 -25
- package/components/grid/detail/detailHeaderPanel.js.map +1 -1
- package/components/grid/export/contextMenu.d.ts +18 -24
- package/components/grid/export/contextMenu.js +116 -113
- package/components/grid/export/contextMenu.js.map +1 -1
- package/components/grid/export/progressPopup.d.ts +29 -29
- package/components/grid/export/progressPopup.js +93 -93
- package/components/grid/export/progressPopup.js.map +1 -1
- package/components/grid/export/worker/clipboardExport.d.ts +1 -1
- package/components/grid/export/worker/clipboardExport.js +8 -8
- package/components/grid/export/worker/csvExport.d.ts +1 -1
- package/components/grid/export/worker/csvExport.js +8 -8
- package/components/grid/export/worker/pdfExport.d.ts +1 -1
- package/components/grid/export/worker/pdfExport.js +81 -81
- package/components/grid/export/worker/pdfExport.js.map +1 -1
- package/components/grid/export/worker/txtExport.d.ts +1 -1
- package/components/grid/export/worker/txtExport.js +19 -19
- package/components/grid/extendedDataGrid.d.ts +140 -140
- package/components/grid/extendedDataGrid.js +704 -695
- package/components/grid/extendedDataGrid.js.map +1 -1
- package/components/grid/filter/customColumnFilter.d.ts +5 -21
- package/components/grid/filter/customColumnFilter.js +11 -82
- package/components/grid/filter/customColumnFilter.js.map +1 -1
- package/components/grid/filter/dataGridColumnFilter.d.ts +17 -0
- package/components/grid/filter/dataGridColumnFilter.js +49 -0
- package/components/grid/filter/dataGridColumnFilter.js.map +1 -0
- package/components/grid/filter/dateColumnFilter.d.ts +7 -11
- package/components/grid/filter/dateColumnFilter.js +22 -56
- package/components/grid/filter/dateColumnFilter.js.map +1 -1
- package/components/grid/filter/textColumnFilter.d.ts +8 -20
- package/components/grid/filter/textColumnFilter.js +24 -76
- package/components/grid/filter/textColumnFilter.js.map +1 -1
- package/components/grid/filter/wildcardQuickFilterEngine.d.ts +7 -0
- package/components/grid/filter/wildcardQuickFilterEngine.js +48 -0
- package/components/grid/filter/wildcardQuickFilterEngine.js.map +1 -0
- package/components/grid/header/simpleHeader.d.ts +17 -16
- package/components/grid/header/simpleHeader.js +230 -186
- package/components/grid/header/simpleHeader.js.map +1 -1
- package/components/grid/panel/dataGridPagination.d.ts +16 -16
- package/components/grid/panel/dataGridPagination.js +58 -58
- package/components/grid/panel/dataGridPagination.js.map +1 -1
- package/components/grid/panel/loadingOverlay.d.ts +6 -6
- package/components/grid/panel/loadingOverlay.js +10 -10
- package/components/grid/panel/loadingOverlay.js.map +1 -1
- package/components/grid/panel/noRecordsOverlay.d.ts +6 -6
- package/components/grid/panel/noRecordsOverlay.js +10 -10
- package/components/grid/panel/noRecordsOverlay.js.map +1 -1
- package/components/grid/panel/tablePagination.d.ts +10 -10
- package/components/grid/panel/tablePagination.js +45 -45
- package/components/grid/panel/tablePagination.js.map +1 -1
- package/components/icons/dropdownArrow.d.ts +8 -0
- package/components/icons/dropdownArrow.js +59 -0
- package/components/icons/dropdownArrow.js.map +1 -0
- package/components/icons/undoIcon.d.ts +8 -8
- package/components/icons/undoIcon.js +6 -6
- package/components/input/autoCompleteInput.d.ts +35 -35
- package/components/input/autoCompleteInput.js +122 -121
- package/components/input/autoCompleteInput.js.map +1 -1
- package/components/input/draftUtils.d.ts +4 -4
- package/components/input/draftUtils.js +48 -48
- package/components/input/draftUtils.js.map +1 -1
- package/components/input/draftail.d.ts +1 -1
- package/components/input/draftail.js +1 -1
- package/components/input/hexaFormattedInput.d.ts +16 -16
- package/components/input/hexaFormattedInput.js +54 -54
- package/components/input/hexaFormattedInput.js.map +1 -1
- package/components/input/mask/helpers.d.ts +28 -28
- package/components/input/mask/helpers.js +112 -112
- package/components/input/mask/helpers.js.map +1 -1
- package/components/input/mask/inputMaskCore.d.ts +46 -46
- package/components/input/mask/inputMaskCore.js +278 -278
- package/components/input/mask/inputMaskCore.js.map +1 -1
- package/components/input/mask/pattern.d.ts +20 -20
- package/components/input/mask/pattern.js +78 -78
- package/components/input/mask/pattern.js.map +1 -1
- package/components/input/maskedInput.d.ts +373 -351
- package/components/input/maskedInput.js +224 -224
- package/components/input/maskedInput.js.map +1 -1
- package/components/input/passwordInput.d.ts +9 -9
- package/components/input/passwordInput.js +55 -55
- package/components/input/passwordInput.js.map +1 -1
- package/components/input/simpleAutoComplete.d.ts +12 -12
- package/components/input/simpleAutoComplete.js +41 -43
- package/components/input/simpleAutoComplete.js.map +1 -1
- package/components/input/textarea/extractSpansOfClasses.d.ts +15 -15
- package/components/input/textarea/extractSpansOfClasses.js +96 -96
- package/components/input/textarea/extractSpansOfClasses.js.map +1 -1
- package/components/input/textarea/getRanges.d.ts +1 -1
- package/components/input/textarea/getRanges.js +73 -73
- package/components/input/textarea/getRanges.js.map +1 -1
- package/components/input/textarea/getType.d.ts +1 -1
- package/components/input/textarea/getType.js +26 -26
- package/components/input/textarea/getType.js.map +1 -1
- package/components/input/textarea/highlighedContents.d.ts +6 -6
- package/components/input/textarea/highlighedContents.js +10 -10
- package/components/input/textarea/mentionsWithHighlighting.d.ts +27 -27
- package/components/input/textarea/mentionsWithHighlighting.js +60 -60
- package/components/input/textarea/mentionsWithHighlighting.js.map +1 -1
- package/components/keyboard/keyboardUtils.d.ts +5 -5
- package/components/keyboard/keyboardUtils.js +32 -32
- package/components/modal/draggableModalProvider.d.ts +4 -4
- package/components/modal/draggableModalProvider.js +21 -21
- package/components/modal/draggableModalProvider.js.map +1 -1
- package/components/modal/impl/clamp.d.ts +1 -1
- package/components/modal/impl/clamp.js +1 -1
- package/components/modal/impl/clamp.js.map +1 -1
- package/components/modal/impl/draggableModal.d.ts +12 -12
- package/components/modal/impl/draggableModal.js +17 -17
- package/components/modal/impl/draggableModal.js.map +1 -1
- package/components/modal/impl/draggableModalContext.d.ts +9 -9
- package/components/modal/impl/draggableModalContext.js +2 -2
- package/components/modal/impl/draggableModalContext.js.map +1 -1
- package/components/modal/impl/draggableModalInner.d.ts +15 -13
- package/components/modal/impl/draggableModalInner.js +57 -55
- package/components/modal/impl/draggableModalInner.js.map +1 -1
- package/components/modal/impl/draggableModalReducer.d.ts +66 -62
- package/components/modal/impl/draggableModalReducer.js +77 -78
- package/components/modal/impl/draggableModalReducer.js.map +1 -1
- package/components/modal/impl/getWindowSize.d.ts +4 -4
- package/components/modal/impl/getWindowSize.js +4 -4
- package/components/modal/impl/getWindowSize.js.map +1 -1
- package/components/modal/impl/index.d.ts +3 -3
- package/components/modal/impl/index.js +3 -3
- package/components/modal/impl/index.js.map +1 -1
- package/components/modal/impl/resizeHandle.d.ts +3 -3
- package/components/modal/impl/resizeHandle.js +4 -4
- package/components/modal/impl/resizeHandle.js.map +1 -1
- package/components/modal/impl/useDrag.d.ts +5 -5
- package/components/modal/impl/useDrag.js +42 -42
- package/components/modal/impl/useDrag.js.map +1 -1
- package/components/modal/impl/usePrevious.d.ts +1 -1
- package/components/modal/impl/usePrevious.js +8 -8
- package/components/modal/impl/usePrevious.js.map +1 -1
- package/components/modal/impl/useResize.d.ts +7 -7
- package/components/modal/impl/useResize.js +46 -46
- package/components/modal/impl/useResize.js.map +1 -1
- package/components/modal/modalDialog.d.ts +49 -49
- package/components/modal/modalDialog.js +152 -152
- package/components/modal/modalDialog.js.map +1 -1
- package/components/picker/enumValuePicker.d.ts +16 -16
- package/components/picker/enumValuePicker.js +34 -34
- package/components/picker/enumValuePicker.js.map +1 -1
- package/components/platformSpecific.d.ts +10 -10
- package/components/platformSpecific.js +27 -27
- package/components/scrollTo/onlyText.d.ts +4 -4
- package/components/scrollTo/onlyText.js +30 -30
- package/components/scrollTo/onlyText.js.map +1 -1
- package/components/scrollTo/scrollTo.d.ts +41 -39
- package/components/scrollTo/scrollTo.js +264 -264
- package/components/scrollTo/scrollTo.js.map +1 -1
- package/components/style/withCss.d.ts +9 -0
- package/components/style/withCss.js +6 -0
- package/components/style/withCss.js.map +1 -0
- package/components/style/withInputNumberCss.d.ts +6 -0
- package/components/style/withInputNumberCss.js +13 -0
- package/components/style/withInputNumberCss.js.map +1 -0
- package/components/table/dragSortingTable.d.ts +13 -14
- package/components/table/dragSortingTable.js +96 -82
- package/components/table/dragSortingTable.js.map +1 -1
- package/components/text/impl/innerSize.d.ts +2 -2
- package/components/text/impl/innerSize.js +12 -12
- package/components/text/impl/series.d.ts +1 -1
- package/components/text/impl/series.js +28 -28
- package/components/text/impl/shallowEqual.d.ts +1 -1
- package/components/text/impl/shallowEqual.js +18 -18
- package/components/text/impl/shallowEqual.js.map +1 -1
- package/components/text/impl/uniqueId.d.ts +1 -1
- package/components/text/impl/uniqueId.js +4 -4
- package/components/text/impl/whilst.d.ts +1 -1
- package/components/text/impl/whilst.js +19 -19
- package/components/text/impl/whilst.js.map +1 -1
- package/components/text/textFit.d.ts +38 -38
- package/components/text/textFit.js +165 -168
- package/components/text/textFit.js.map +1 -1
- package/i18n/components.cs.json +101 -100
- package/i18n/components.sk.json +101 -100
- package/i18n/components.uk.json +101 -100
- package/i18n/componentsLocaleHolder.d.ts +3 -3
- package/i18n/componentsLocaleHolder.js +28 -28
- package/i18n/componentsLocaleHolder.js.map +1 -1
- package/package.json +71 -70
- package/style/index.less +274 -298
- package/style/modal/DraggableModal.css +43 -40
- package/style/modal/ResizeHandle.css +27 -19
- package/tsconfig.build.json +24 -24
- package/tsconfig.json +11 -11
- package/components/grid/cell/wildcardQuickFilter.d.ts +0 -11
- package/components/grid/cell/wildcardQuickFilter.js +0 -61
- package/components/grid/cell/wildcardQuickFilter.js.map +0 -1
- package/components/table/dataTable.d.ts +0 -17
- package/components/table/dataTable.js +0 -79
- package/components/table/dataTable.js.map +0 -1
- package/style/antd/antd-tree-showline.css +0 -25
- package/style/antd/full-height-tabs.scss +0 -63
- package/style/draftail/draftail-editor.css +0 -179
- package/style/table/dragSortingTable.css +0 -7
|
@@ -1,59 +1,59 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { Button,
|
|
3
|
-
import i18n from "d2core/i18n/i18n";
|
|
4
|
-
import { CaretLeftOutlined, CaretRightOutlined, CheckOutlined, StepBackwardOutlined, StepForwardOutlined } from "@ant-design/icons";
|
|
5
|
-
export default class DataGridPagination extends React.Component {
|
|
6
|
-
constructor(props) {
|
|
7
|
-
super(props);
|
|
8
|
-
this.state = {};
|
|
9
|
-
}
|
|
10
|
-
render() {
|
|
11
|
-
const { disabled, total, pageSize, current } = this.props;
|
|
12
|
-
const rangeStart = total === 0 ? 0 : (current - 1) * pageSize + 1;
|
|
13
|
-
const rangeEnd = current * pageSize > total ? total : current * pageSize;
|
|
14
|
-
const totalPages = Math.ceil(total / pageSize);
|
|
15
|
-
return (React.createElement(React.Fragment, null,
|
|
16
|
-
React.createElement("li", {
|
|
17
|
-
React.createElement(Button.Group, null,
|
|
18
|
-
React.createElement(Button, { title: i18n("First Page"), disabled: disabled || current === 1, icon: React.createElement(StepBackwardOutlined, null), onClick: () => {
|
|
19
|
-
this.props.onGoToPage(0);
|
|
20
|
-
} }),
|
|
21
|
-
React.createElement(Button, { title: i18n("Previous Page"), disabled: disabled || current === 1, icon: React.createElement(CaretLeftOutlined, null), onClick: () => {
|
|
22
|
-
this.props.onGoToPage(current - 1);
|
|
23
|
-
} }),
|
|
24
|
-
React.createElement(Popover, { placement: "bottom", trigger: disabled || totalPages <= 1 ? [] : ["hover", "click"], content: React.createElement(
|
|
25
|
-
React.createElement(InputNumber, { disabled: disabled || total === 0, min: 1, max: totalPages, value: this.state.gotoPageNumber ? this.state.gotoPageNumber : this.props.current, onChange: (newValue) => {
|
|
26
|
-
if (typeof newValue === "number") {
|
|
27
|
-
this.setState({ gotoPageNumber: newValue });
|
|
28
|
-
}
|
|
29
|
-
}, onKeyDown: (e) => {
|
|
30
|
-
if (e.
|
|
31
|
-
if (this.state.gotoPageNumber) {
|
|
32
|
-
this.props.onGoToPage(this.state.gotoPageNumber);
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
} }),
|
|
36
|
-
React.createElement(Button, { title: i18n("Goto Page"), type: "primary", onClick: () => {
|
|
37
|
-
if (this.state.gotoPageNumber) {
|
|
38
|
-
this.props.onGoToPage(this.state.gotoPageNumber);
|
|
39
|
-
}
|
|
40
|
-
} },
|
|
41
|
-
React.createElement(CheckOutlined, null))) },
|
|
42
|
-
React.createElement(Button, { disabled: disabled, style: { width: 80, paddingLeft: 0, paddingRight: 0 } },
|
|
43
|
-
React.createElement("span", { style: {
|
|
44
|
-
display: "inline-block",
|
|
45
|
-
width: "100%",
|
|
46
|
-
textAlign: "center",
|
|
47
|
-
} },
|
|
48
|
-
total === 0 ? 0 : current,
|
|
49
|
-
" / ",
|
|
50
|
-
totalPages))),
|
|
51
|
-
React.createElement(Button, { title: i18n("Next Page"), disabled: disabled || current === totalPages || total === 0, icon: React.createElement(CaretRightOutlined, null), onClick: () => {
|
|
52
|
-
this.props.onGoToPage(current + 1);
|
|
53
|
-
} }),
|
|
54
|
-
React.createElement(Button, { title: i18n("Last Page"), disabled: disabled || current === totalPages || total === 0, icon: React.createElement(StepForwardOutlined, null), onClick: () => {
|
|
55
|
-
this.props.onGoToPage(totalPages);
|
|
56
|
-
} }))));
|
|
57
|
-
}
|
|
58
|
-
}
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { Button, InputNumber, Popover, Space } from "antd";
|
|
3
|
+
import i18n from "d2core/i18n/i18n";
|
|
4
|
+
import { CaretLeftOutlined, CaretRightOutlined, CheckOutlined, StepBackwardOutlined, StepForwardOutlined } from "@ant-design/icons";
|
|
5
|
+
export default class DataGridPagination extends React.Component {
|
|
6
|
+
constructor(props) {
|
|
7
|
+
super(props);
|
|
8
|
+
this.state = {};
|
|
9
|
+
}
|
|
10
|
+
render() {
|
|
11
|
+
const { disabled, total, pageSize, current } = this.props;
|
|
12
|
+
const rangeStart = total === 0 ? 0 : (current - 1) * pageSize + 1;
|
|
13
|
+
const rangeEnd = current * pageSize > total ? total : current * pageSize;
|
|
14
|
+
const totalPages = Math.ceil(total / pageSize);
|
|
15
|
+
return (React.createElement(React.Fragment, null,
|
|
16
|
+
React.createElement("li", { style: { margin: "0 12px", lineHeight: "32px", whiteSpace: "nowrap" } }, `${rangeStart}-${rangeEnd} ${i18n('of')} ${total}`),
|
|
17
|
+
React.createElement(Button.Group, null,
|
|
18
|
+
React.createElement(Button, { title: i18n("First Page"), disabled: disabled || current === 1, icon: React.createElement(StepBackwardOutlined, null), onClick: () => {
|
|
19
|
+
this.props.onGoToPage(0);
|
|
20
|
+
} }),
|
|
21
|
+
React.createElement(Button, { title: i18n("Previous Page"), disabled: disabled || current === 1, icon: React.createElement(CaretLeftOutlined, null), onClick: () => {
|
|
22
|
+
this.props.onGoToPage(current - 1);
|
|
23
|
+
} }),
|
|
24
|
+
React.createElement(Popover, { placement: "bottom", trigger: disabled || totalPages <= 1 ? [] : ["hover", "click"], content: React.createElement(Space.Compact, null,
|
|
25
|
+
React.createElement(InputNumber, { disabled: disabled || total === 0, min: 1, max: totalPages, value: this.state.gotoPageNumber ? this.state.gotoPageNumber : this.props.current, onChange: (newValue) => {
|
|
26
|
+
if (typeof newValue === "number") {
|
|
27
|
+
this.setState({ gotoPageNumber: newValue });
|
|
28
|
+
}
|
|
29
|
+
}, onKeyDown: (e) => {
|
|
30
|
+
if (e.code === "Enter") {
|
|
31
|
+
if (this.state.gotoPageNumber) {
|
|
32
|
+
this.props.onGoToPage(this.state.gotoPageNumber);
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
} }),
|
|
36
|
+
React.createElement(Button, { title: i18n("Goto Page"), type: "primary", onClick: () => {
|
|
37
|
+
if (this.state.gotoPageNumber) {
|
|
38
|
+
this.props.onGoToPage(this.state.gotoPageNumber);
|
|
39
|
+
}
|
|
40
|
+
} },
|
|
41
|
+
React.createElement(CheckOutlined, null))) },
|
|
42
|
+
React.createElement(Button, { disabled: disabled, style: { width: 80, paddingLeft: 0, paddingRight: 0 } },
|
|
43
|
+
React.createElement("span", { style: {
|
|
44
|
+
display: "inline-block",
|
|
45
|
+
width: "100%",
|
|
46
|
+
textAlign: "center",
|
|
47
|
+
} },
|
|
48
|
+
total === 0 ? 0 : current,
|
|
49
|
+
" / ",
|
|
50
|
+
totalPages))),
|
|
51
|
+
React.createElement(Button, { title: i18n("Next Page"), disabled: disabled || current === totalPages || total === 0, icon: React.createElement(CaretRightOutlined, null), onClick: () => {
|
|
52
|
+
this.props.onGoToPage(current + 1);
|
|
53
|
+
} }),
|
|
54
|
+
React.createElement(Button, { title: i18n("Last Page"), disabled: disabled || current === totalPages || total === 0, icon: React.createElement(StepForwardOutlined, null), onClick: () => {
|
|
55
|
+
this.props.onGoToPage(totalPages);
|
|
56
|
+
} }))));
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
59
|
//# sourceMappingURL=dataGridPagination.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dataGridPagination.js","sourceRoot":"","sources":["../../../../../components/grid/panel/dataGridPagination.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAC,MAAM,EAAE,
|
|
1
|
+
{"version":3,"file":"dataGridPagination.js","sourceRoot":"","sources":["../../../../../components/grid/panel/dataGridPagination.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAC,MAAM,EAAE,WAAW,EAAE,OAAO,EAAE,KAAK,EAAC,MAAM,MAAM,CAAC;AACzD,OAAO,IAAI,MAAM,kBAAkB,CAAC;AACpC,OAAO,EACH,iBAAiB,EACjB,kBAAkB,EAClB,aAAa,EACb,oBAAoB,EACpB,mBAAmB,EACtB,MAAM,mBAAmB,CAAC;AAe3B,MAAM,CAAC,OAAO,OAAO,kBAAmB,SAAQ,KAAK,CAAC,SAA2D;IAC7G,YAAY,KAAwC;QAChD,KAAK,CAAC,KAAK,CAAC,CAAC;QAEb,IAAI,CAAC,KAAK,GAAG,EAAE,CAAA;IACnB,CAAC;IAED,MAAM;QACF,MAAM,EAAC,QAAQ,EAAE,KAAK,EAAE,QAAQ,EAAE,OAAO,EAAC,GAAG,IAAI,CAAC,KAAK,CAAC;QACxD,MAAM,UAAU,GAAG,KAAK,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,OAAO,GAAG,CAAC,CAAC,GAAG,QAAQ,GAAG,CAAC,CAAC;QAClE,MAAM,QAAQ,GAAG,OAAO,GAAG,QAAQ,GAAG,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,OAAO,GAAG,QAAQ,CAAC;QACzE,MAAM,UAAU,GAAG,IAAI,CAAC,IAAI,CAAC,KAAK,GAAG,QAAQ,CAAC,CAAC;QAC/C,OAAO,CACH;YACI,4BAAI,KAAK,EAAE,EAAC,MAAM,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,EAAE,UAAU,EAAE,QAAQ,EAAC,IAClE,GAAG,UAAU,IAAI,QAAQ,IAAI,IAAI,CAAC,IAAI,CAAC,IAAI,KAAK,EAAE,CAClD;YACL,oBAAC,MAAM,CAAC,KAAK;gBACT,oBAAC,MAAM,IACH,KAAK,EAAE,IAAI,CAAC,YAAY,CAAC,EACzB,QAAQ,EAAE,QAAQ,IAAI,OAAO,KAAK,CAAC,EACnC,IAAI,EAAE,oBAAC,oBAAoB,OAAE,EAC7B,OAAO,EAAE,GAAG,EAAE;wBACV,IAAI,CAAC,KAAK,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC;oBAC7B,CAAC,GACH;gBACF,oBAAC,MAAM,IACH,KAAK,EAAE,IAAI,CAAC,eAAe,CAAC,EAC5B,QAAQ,EAAE,QAAQ,IAAI,OAAO,KAAK,CAAC,EACnC,IAAI,EAAE,oBAAC,iBAAiB,OAAE,EAC1B,OAAO,EAAE,GAAG,EAAE;wBACV,IAAI,CAAC,KAAK,CAAC,UAAU,CAAC,OAAO,GAAG,CAAC,CAAC,CAAC;oBACvC,CAAC,GACH;gBACF,oBAAC,OAAO,IACJ,SAAS,EAAC,QAAQ,EAClB,OAAO,EAAE,QAAQ,IAAI,UAAU,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,OAAO,EAAE,OAAO,CAAC,EAC9D,OAAO,EACH,oBAAC,KAAK,CAAC,OAAO;wBACV,oBAAC,WAAW,IACR,QAAQ,EAAE,QAAQ,IAAI,KAAK,KAAK,CAAC,EACjC,GAAG,EAAE,CAAC,EAAE,GAAG,EAAE,UAAU,EACvB,KAAK,EAAE,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,OAAO,EACjF,QAAQ,EAAE,CAAC,QAAQ,EAAE,EAAE;gCACnB,IAAI,OAAO,QAAQ,KAAK,QAAQ,EAAE,CAAC;oCAC/B,IAAI,CAAC,QAAQ,CAAC,EAAC,cAAc,EAAE,QAAQ,EAAC,CAAC,CAAC;gCAC9C,CAAC;4BACL,CAAC,EACD,SAAS,EAAE,CAAC,CAAC,EAAE,EAAE;gCACb,IAAI,CAAC,CAAC,IAAI,KAAK,OAAO,EAAE,CAAC;oCACrB,IAAI,IAAI,CAAC,KAAK,CAAC,cAAc,EAAE,CAAC;wCAC5B,IAAI,CAAC,KAAK,CAAC,UAAU,CAAC,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,CAAC;oCACrD,CAAC;gCACL,CAAC;4BACL,CAAC,GACH;wBACF,oBAAC,MAAM,IACH,KAAK,EAAE,IAAI,CAAC,WAAW,CAAC,EACxB,IAAI,EAAC,SAAS,EACd,OAAO,EAAE,GAAG,EAAE;gCACV,IAAI,IAAI,CAAC,KAAK,CAAC,cAAc,EAAE,CAAC;oCAC5B,IAAI,CAAC,KAAK,CAAC,UAAU,CAAC,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,CAAC;gCACrD,CAAC;4BACL,CAAC;4BAED,oBAAC,aAAa,OAAE,CACX,CACG;oBAEpB,oBAAC,MAAM,IAAC,QAAQ,EAAE,QAAQ,EAAE,KAAK,EAAE,EAAC,KAAK,EAAE,EAAE,EAAE,WAAW,EAAE,CAAC,EAAE,YAAY,EAAE,CAAC,EAAC;wBAC3E,8BAAM,KAAK,EAAE;gCACT,OAAO,EAAE,cAAc;gCACvB,KAAK,EAAE,MAAM;gCACb,SAAS,EAAE,QAAQ;6BACtB;4BAAG,KAAK,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,OAAO;;4BAAK,UAAU,CAAQ,CAC/C,CACH;gBACV,oBAAC,MAAM,IACH,KAAK,EAAE,IAAI,CAAC,WAAW,CAAC,EACxB,QAAQ,EAAE,QAAQ,IAAI,OAAO,KAAK,UAAU,IAAI,KAAK,KAAK,CAAC,EAC3D,IAAI,EAAE,oBAAC,kBAAkB,OAAE,EAC3B,OAAO,EAAE,GAAG,EAAE;wBACV,IAAI,CAAC,KAAK,CAAC,UAAU,CAAC,OAAO,GAAG,CAAC,CAAC,CAAC;oBACvC,CAAC,GACH;gBACF,oBAAC,MAAM,IACH,KAAK,EAAE,IAAI,CAAC,WAAW,CAAC,EACxB,QAAQ,EAAE,QAAQ,IAAI,OAAO,KAAK,UAAU,IAAI,KAAK,KAAK,CAAC,EAC3D,IAAI,EAAE,oBAAC,mBAAmB,OAAE,EAC5B,OAAO,EAAE,GAAG,EAAE;wBACV,IAAI,CAAC,KAAK,CAAC,UAAU,CAAC,UAAU,CAAC,CAAC;oBACtC,CAAC,GACH,CACS,CAChB,CACN,CAAC;IACN,CAAC;CAEJ","sourcesContent":["import React from \"react\";\r\nimport {Button, InputNumber, Popover, Space} from \"antd\";\r\nimport i18n from \"d2core/i18n/i18n\";\r\nimport {\r\n CaretLeftOutlined,\r\n CaretRightOutlined,\r\n CheckOutlined,\r\n StepBackwardOutlined,\r\n StepForwardOutlined\r\n} from \"@ant-design/icons\";\r\n\r\ninterface DataGridPaginationProps {\r\n disabled?: boolean\r\n current: number\r\n pageSize: number\r\n total: number\r\n\r\n onGoToPage(page: number): void\r\n}\r\n\r\ninterface DataGridPaginationState {\r\n gotoPageNumber?: number\r\n}\r\n\r\nexport default class DataGridPagination extends React.Component<DataGridPaginationProps, DataGridPaginationState> {\r\n constructor(props: Readonly<DataGridPaginationProps>) {\r\n super(props);\r\n\r\n this.state = {}\r\n }\r\n\r\n render() {\r\n const {disabled, total, pageSize, current} = this.props;\r\n const rangeStart = total === 0 ? 0 : (current - 1) * pageSize + 1;\r\n const rangeEnd = current * pageSize > total ? total : current * pageSize;\r\n const totalPages = Math.ceil(total / pageSize);\r\n return (\r\n <>\r\n <li style={{margin: \"0 12px\", lineHeight: \"32px\", whiteSpace: \"nowrap\"}}>\r\n {`${rangeStart}-${rangeEnd} ${i18n('of')} ${total}`}\r\n </li>\r\n <Button.Group>\r\n <Button\r\n title={i18n(\"First Page\")}\r\n disabled={disabled || current === 1}\r\n icon={<StepBackwardOutlined/>}\r\n onClick={() => {\r\n this.props.onGoToPage(0);\r\n }}\r\n />\r\n <Button\r\n title={i18n(\"Previous Page\")}\r\n disabled={disabled || current === 1}\r\n icon={<CaretLeftOutlined/>}\r\n onClick={() => {\r\n this.props.onGoToPage(current - 1);\r\n }}\r\n />\r\n <Popover\r\n placement=\"bottom\"\r\n trigger={disabled || totalPages <= 1 ? [] : [\"hover\", \"click\"]}\r\n content={\r\n <Space.Compact>\r\n <InputNumber\r\n disabled={disabled || total === 0}\r\n min={1} max={totalPages}\r\n value={this.state.gotoPageNumber ? this.state.gotoPageNumber : this.props.current}\r\n onChange={(newValue) => {\r\n if (typeof newValue === \"number\") {\r\n this.setState({gotoPageNumber: newValue});\r\n }\r\n }}\r\n onKeyDown={(e) => {\r\n if (e.code === \"Enter\") {\r\n if (this.state.gotoPageNumber) {\r\n this.props.onGoToPage(this.state.gotoPageNumber);\r\n }\r\n }\r\n }}\r\n />\r\n <Button\r\n title={i18n(\"Goto Page\")}\r\n type=\"primary\"\r\n onClick={() => {\r\n if (this.state.gotoPageNumber) {\r\n this.props.onGoToPage(this.state.gotoPageNumber);\r\n }\r\n }}\r\n >\r\n <CheckOutlined/>\r\n </Button>\r\n </Space.Compact>\r\n }>\r\n <Button disabled={disabled} style={{width: 80, paddingLeft: 0, paddingRight: 0}}>\r\n <span style={{\r\n display: \"inline-block\",\r\n width: \"100%\",\r\n textAlign: \"center\",\r\n }}>{total === 0 ? 0 : current} / {totalPages}</span>\r\n </Button>\r\n </Popover>\r\n <Button\r\n title={i18n(\"Next Page\")}\r\n disabled={disabled || current === totalPages || total === 0}\r\n icon={<CaretRightOutlined/>}\r\n onClick={() => {\r\n this.props.onGoToPage(current + 1);\r\n }}\r\n />\r\n <Button\r\n title={i18n(\"Last Page\")}\r\n disabled={disabled || current === totalPages || total === 0}\r\n icon={<StepForwardOutlined/>}\r\n onClick={() => {\r\n this.props.onGoToPage(totalPages);\r\n }}\r\n />\r\n </Button.Group>\r\n </>\r\n );\r\n }\r\n\r\n}"]}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
export default class LoadingOverlay extends React.PureComponent {
|
|
3
|
-
loadingOverlayRenderer: () => React.ReactElement;
|
|
4
|
-
constructor(props: Readonly<any>);
|
|
5
|
-
render(): React.ReactElement<any, string | React.JSXElementConstructor<any>>;
|
|
6
|
-
}
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
export default class LoadingOverlay extends React.PureComponent {
|
|
3
|
+
loadingOverlayRenderer: () => React.ReactElement;
|
|
4
|
+
constructor(props: Readonly<any>);
|
|
5
|
+
render(): React.ReactElement<any, string | React.JSXElementConstructor<any>>;
|
|
6
|
+
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
export default class LoadingOverlay extends React.PureComponent {
|
|
3
|
-
constructor(props) {
|
|
4
|
-
super(props);
|
|
5
|
-
this.loadingOverlayRenderer = props.api.
|
|
6
|
-
}
|
|
7
|
-
render() {
|
|
8
|
-
return (this.loadingOverlayRenderer());
|
|
9
|
-
}
|
|
10
|
-
}
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
export default class LoadingOverlay extends React.PureComponent {
|
|
3
|
+
constructor(props) {
|
|
4
|
+
super(props);
|
|
5
|
+
this.loadingOverlayRenderer = props.api.getGridOption('context').loadingOverlayRenderer;
|
|
6
|
+
}
|
|
7
|
+
render() {
|
|
8
|
+
return (this.loadingOverlayRenderer());
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
11
|
//# sourceMappingURL=loadingOverlay.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"loadingOverlay.js","sourceRoot":"","sources":["../../../../../components/grid/panel/loadingOverlay.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,MAAM,CAAC,OAAO,OAAO,cAAe,SAAQ,KAAK,CAAC,aAAa;IAG3D,YAAY,KAAoB;QAC5B,KAAK,CAAC,KAAK,CAAC,CAAC;QACb,IAAI,CAAC,sBAAsB,GAAG,KAAK,CAAC,GAAG,CAAC,
|
|
1
|
+
{"version":3,"file":"loadingOverlay.js","sourceRoot":"","sources":["../../../../../components/grid/panel/loadingOverlay.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,MAAM,CAAC,OAAO,OAAO,cAAe,SAAQ,KAAK,CAAC,aAAa;IAG3D,YAAY,KAAoB;QAC5B,KAAK,CAAC,KAAK,CAAC,CAAC;QACb,IAAI,CAAC,sBAAsB,GAAG,KAAK,CAAC,GAAG,CAAC,aAAa,CAAC,SAAS,CAAC,CAAC,sBAAsB,CAAC;IAC5F,CAAC;IAED,MAAM;QACF,OAAO,CAAC,IAAI,CAAC,sBAAsB,EAAE,CAAC,CAAC;IAC3C,CAAC;CACJ","sourcesContent":["import * as React from \"react\";\r\n\r\nexport default class LoadingOverlay extends React.PureComponent {\r\n loadingOverlayRenderer: () => React.ReactElement;\r\n\r\n constructor(props: Readonly<any>) {\r\n super(props);\r\n this.loadingOverlayRenderer = props.api.getGridOption('context').loadingOverlayRenderer;\r\n }\r\n\r\n render() {\r\n return (this.loadingOverlayRenderer());\r\n }\r\n}"]}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
export default class NoRecordsOverlay extends React.PureComponent<any> {
|
|
3
|
-
noRecordsOverlayRenderer: () => React.ReactElement;
|
|
4
|
-
constructor(props: Readonly<any>);
|
|
5
|
-
render(): JSX.Element;
|
|
6
|
-
}
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
export default class NoRecordsOverlay extends React.PureComponent<any> {
|
|
3
|
+
noRecordsOverlayRenderer: () => React.ReactElement;
|
|
4
|
+
constructor(props: Readonly<any>);
|
|
5
|
+
render(): React.JSX.Element;
|
|
6
|
+
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
export default class NoRecordsOverlay extends React.PureComponent {
|
|
3
|
-
constructor(props) {
|
|
4
|
-
super(props);
|
|
5
|
-
this.noRecordsOverlayRenderer = props.api.
|
|
6
|
-
}
|
|
7
|
-
render() {
|
|
8
|
-
return React.createElement("div", { style: { pointerEvents: "auto" } }, this.noRecordsOverlayRenderer());
|
|
9
|
-
}
|
|
10
|
-
}
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
export default class NoRecordsOverlay extends React.PureComponent {
|
|
3
|
+
constructor(props) {
|
|
4
|
+
super(props);
|
|
5
|
+
this.noRecordsOverlayRenderer = props.api.getGridOption('context').noRecordsOverlayRenderer;
|
|
6
|
+
}
|
|
7
|
+
render() {
|
|
8
|
+
return React.createElement("div", { style: { pointerEvents: "auto" } }, this.noRecordsOverlayRenderer());
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
11
|
//# sourceMappingURL=noRecordsOverlay.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"noRecordsOverlay.js","sourceRoot":"","sources":["../../../../../components/grid/panel/noRecordsOverlay.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,MAAM,CAAC,OAAO,OAAO,gBAAiB,SAAQ,KAAK,CAAC,aAAkB;IAGlE,YAAY,KAAoB;QAC5B,KAAK,CAAC,KAAK,CAAC,CAAC;QACb,IAAI,CAAC,wBAAwB,GAAG,KAAK,CAAC,GAAG,CAAC,
|
|
1
|
+
{"version":3,"file":"noRecordsOverlay.js","sourceRoot":"","sources":["../../../../../components/grid/panel/noRecordsOverlay.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,MAAM,CAAC,OAAO,OAAO,gBAAiB,SAAQ,KAAK,CAAC,aAAkB;IAGlE,YAAY,KAAoB;QAC5B,KAAK,CAAC,KAAK,CAAC,CAAC;QACb,IAAI,CAAC,wBAAwB,GAAG,KAAK,CAAC,GAAG,CAAC,aAAa,CAAC,SAAS,CAAC,CAAC,wBAAwB,CAAC;IAChG,CAAC;IAED,MAAM;QACF,OAAO,6BAAK,KAAK,EAAE,EAAC,aAAa,EAAE,MAAM,EAAC,IACrC,IAAI,CAAC,wBAAwB,EAAE,CAC9B,CAAC;IACX,CAAC;CACJ","sourcesContent":["import * as React from \"react\";\r\n\r\nexport default class NoRecordsOverlay extends React.PureComponent<any> {\r\n noRecordsOverlayRenderer: () => React.ReactElement;\r\n\r\n constructor(props: Readonly<any>) {\r\n super(props);\r\n this.noRecordsOverlayRenderer = props.api.getGridOption('context').noRecordsOverlayRenderer;\r\n }\r\n\r\n render() {\r\n return <div style={{pointerEvents: \"auto\"}}>\r\n {this.noRecordsOverlayRenderer()}\r\n </div>;\r\n }\r\n}"]}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { PaginationProps } from "antd/es/pagination";
|
|
3
|
-
interface PaginationComponentState {
|
|
4
|
-
gotoPageNumber?: number | null;
|
|
5
|
-
}
|
|
6
|
-
export default class PaginationComponent extends React.Component<PaginationProps, PaginationComponentState> {
|
|
7
|
-
constructor(props: Readonly<PaginationProps>);
|
|
8
|
-
render(): JSX.Element;
|
|
9
|
-
}
|
|
10
|
-
export {};
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { PaginationProps } from "antd/es/pagination";
|
|
3
|
+
interface PaginationComponentState {
|
|
4
|
+
gotoPageNumber?: number | null;
|
|
5
|
+
}
|
|
6
|
+
export default class PaginationComponent extends React.Component<PaginationProps, PaginationComponentState> {
|
|
7
|
+
constructor(props: Readonly<PaginationProps>);
|
|
8
|
+
render(): React.JSX.Element;
|
|
9
|
+
}
|
|
10
|
+
export {};
|
|
@@ -1,46 +1,46 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { CheckOutlined } from "@ant-design/icons";
|
|
3
|
-
import { Button,
|
|
4
|
-
import i18n from "d2core/i18n/i18n";
|
|
5
|
-
export default class PaginationComponent extends React.Component {
|
|
6
|
-
constructor(props) {
|
|
7
|
-
super(props);
|
|
8
|
-
this.state = {
|
|
9
|
-
gotoPageNumber: null
|
|
10
|
-
};
|
|
11
|
-
}
|
|
12
|
-
render() {
|
|
13
|
-
const pageCount = this.props.total && this.props.pageSize ? Math.ceil(this.props.total / this.props.pageSize) : 1;
|
|
14
|
-
return (React.createElement("div", null,
|
|
15
|
-
React.createElement(Pagination, Object.assign({ showSizeChanger: false }, this.props, { itemRender: (page, type, originalElement) => {
|
|
16
|
-
if (page === this.props.current && type === "page") {
|
|
17
|
-
return (React.createElement(Popover, { title: "", placement: "bottom", content: React.createElement(
|
|
18
|
-
React.createElement(InputNumber, { min: 1, max: pageCount, value: this.state.gotoPageNumber ? this.state.gotoPageNumber : this.props.current, onChange: (newValue) => {
|
|
19
|
-
if (typeof newValue === "number") {
|
|
20
|
-
this.setState({ gotoPageNumber: newValue });
|
|
21
|
-
}
|
|
22
|
-
}, onKeyDown: (e) => {
|
|
23
|
-
if (e.
|
|
24
|
-
if (this.state.gotoPageNumber && this.props.onChange) {
|
|
25
|
-
this.props.onChange(this.state.gotoPageNumber, this.props.pageSize);
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
} }),
|
|
29
|
-
React.createElement(Button, { title: i18n("Goto Page"), type: "primary", onClick: () => {
|
|
30
|
-
if (this.state.gotoPageNumber && this.props.onChange) {
|
|
31
|
-
this.props.onChange(this.state.gotoPageNumber, this.props.pageSize);
|
|
32
|
-
}
|
|
33
|
-
} },
|
|
34
|
-
React.createElement(CheckOutlined, null))), trigger: "hover", onOpenChange: (visible) => {
|
|
35
|
-
if (!visible) {
|
|
36
|
-
this.setState({ gotoPageNumber: null });
|
|
37
|
-
}
|
|
38
|
-
}, overlayClassName: "control-panel-popover" }, originalElement));
|
|
39
|
-
}
|
|
40
|
-
else {
|
|
41
|
-
return originalElement;
|
|
42
|
-
}
|
|
43
|
-
} }))));
|
|
44
|
-
}
|
|
45
|
-
}
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { CheckOutlined } from "@ant-design/icons";
|
|
3
|
+
import { Button, InputNumber, Pagination, Popover, Space } from "antd";
|
|
4
|
+
import i18n from "d2core/i18n/i18n";
|
|
5
|
+
export default class PaginationComponent extends React.Component {
|
|
6
|
+
constructor(props) {
|
|
7
|
+
super(props);
|
|
8
|
+
this.state = {
|
|
9
|
+
gotoPageNumber: null
|
|
10
|
+
};
|
|
11
|
+
}
|
|
12
|
+
render() {
|
|
13
|
+
const pageCount = this.props.total && this.props.pageSize ? Math.ceil(this.props.total / this.props.pageSize) : 1;
|
|
14
|
+
return (React.createElement("div", null,
|
|
15
|
+
React.createElement(Pagination, Object.assign({ showSizeChanger: false }, this.props, { itemRender: (page, type, originalElement) => {
|
|
16
|
+
if (page === this.props.current && type === "page") {
|
|
17
|
+
return (React.createElement(Popover, { title: "", placement: "bottom", content: React.createElement(Space.Compact, null,
|
|
18
|
+
React.createElement(InputNumber, { min: 1, max: pageCount, value: this.state.gotoPageNumber ? this.state.gotoPageNumber : this.props.current, onChange: (newValue) => {
|
|
19
|
+
if (typeof newValue === "number") {
|
|
20
|
+
this.setState({ gotoPageNumber: newValue });
|
|
21
|
+
}
|
|
22
|
+
}, onKeyDown: (e) => {
|
|
23
|
+
if (e.code === "Enter") {
|
|
24
|
+
if (this.state.gotoPageNumber && this.props.onChange) {
|
|
25
|
+
this.props.onChange(this.state.gotoPageNumber, this.props.pageSize);
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
} }),
|
|
29
|
+
React.createElement(Button, { title: i18n("Goto Page"), type: "primary", onClick: () => {
|
|
30
|
+
if (this.state.gotoPageNumber && this.props.onChange) {
|
|
31
|
+
this.props.onChange(this.state.gotoPageNumber, this.props.pageSize);
|
|
32
|
+
}
|
|
33
|
+
} },
|
|
34
|
+
React.createElement(CheckOutlined, null))), trigger: "hover", onOpenChange: (visible) => {
|
|
35
|
+
if (!visible) {
|
|
36
|
+
this.setState({ gotoPageNumber: null });
|
|
37
|
+
}
|
|
38
|
+
}, overlayClassName: "control-panel-popover" }, originalElement));
|
|
39
|
+
}
|
|
40
|
+
else {
|
|
41
|
+
return originalElement;
|
|
42
|
+
}
|
|
43
|
+
} }))));
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
46
|
//# sourceMappingURL=tablePagination.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tablePagination.js","sourceRoot":"","sources":["../../../../../components/grid/panel/tablePagination.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAC,aAAa,EAAC,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAAC,MAAM,EAAE,
|
|
1
|
+
{"version":3,"file":"tablePagination.js","sourceRoot":"","sources":["../../../../../components/grid/panel/tablePagination.tsx"],"names":[],"mappings":"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","sourcesContent":["import React from \"react\";\r\nimport {CheckOutlined} from \"@ant-design/icons\";\r\nimport {Button, InputNumber, Pagination, Popover, Space} from \"antd\";\r\nimport i18n from \"d2core/i18n/i18n\";\r\nimport {PaginationProps} from \"antd/es/pagination\";\r\n\r\ninterface PaginationComponentState {\r\n gotoPageNumber?: number | null\r\n}\r\n\r\nexport default class PaginationComponent extends React.Component<PaginationProps, PaginationComponentState> {\r\n constructor(props: Readonly<PaginationProps>) {\r\n super(props);\r\n this.state = {\r\n gotoPageNumber: null\r\n }\r\n }\r\n\r\n render() {\r\n const pageCount = this.props.total && this.props.pageSize ? Math.ceil(this.props.total / this.props.pageSize) : 1;\r\n return (\r\n <div>\r\n <Pagination\r\n showSizeChanger={false}\r\n {...this.props}\r\n itemRender={(page, type, originalElement) => {\r\n if (page === this.props.current && type === \"page\") {\r\n return (\r\n <Popover\r\n title=\"\"\r\n placement=\"bottom\"\r\n content={\r\n <Space.Compact>\r\n <InputNumber min={1} max={pageCount}\r\n value={this.state.gotoPageNumber ? this.state.gotoPageNumber : this.props.current}\r\n onChange={(newValue) => {\r\n if (typeof newValue === \"number\") {\r\n this.setState({gotoPageNumber: newValue});\r\n }\r\n }}\r\n onKeyDown={(e) => {\r\n if (e.code === \"Enter\") {\r\n if (this.state.gotoPageNumber && this.props.onChange) {\r\n this.props.onChange(this.state.gotoPageNumber, this.props.pageSize!);\r\n }\r\n }\r\n }}\r\n />\r\n <Button title={i18n(\"Goto Page\")} type=\"primary\" onClick={() => {\r\n if (this.state.gotoPageNumber && this.props.onChange) {\r\n this.props.onChange(this.state.gotoPageNumber, this.props.pageSize!);\r\n }\r\n }}>\r\n <CheckOutlined/>\r\n </Button>\r\n </Space.Compact>\r\n }\r\n trigger=\"hover\"\r\n onOpenChange={(visible) => {\r\n if (!visible) {\r\n this.setState({gotoPageNumber: null});\r\n }\r\n }}\r\n overlayClassName=\"control-panel-popover\"\r\n >\r\n {originalElement}\r\n </Popover>\r\n );\r\n } else {\r\n return originalElement;\r\n }\r\n }}\r\n />\r\n </div>\r\n );\r\n }\r\n}"]}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { AntdIconProps } from "@ant-design/icons/lib/components/AntdIcon";
|
|
3
|
+
export interface DropdownArrowProps extends AntdIconProps {
|
|
4
|
+
opened?: boolean;
|
|
5
|
+
}
|
|
6
|
+
export default class DropdownArrow extends React.PureComponent<DropdownArrowProps> {
|
|
7
|
+
render(): React.JSX.Element;
|
|
8
|
+
}
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
var __rest = (this && this.__rest) || function (s, e) {
|
|
2
|
+
var t = {};
|
|
3
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
4
|
+
t[p] = s[p];
|
|
5
|
+
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
6
|
+
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
7
|
+
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
8
|
+
t[p[i]] = s[p[i]];
|
|
9
|
+
}
|
|
10
|
+
return t;
|
|
11
|
+
};
|
|
12
|
+
import React from "react";
|
|
13
|
+
import { createStyles } from "antd-style";
|
|
14
|
+
import { DownOutlined } from "@ant-design/icons";
|
|
15
|
+
import WithCss from "d2coreui/components/style/withCss";
|
|
16
|
+
const useStyles = createStyles(({ token, css, cx }) => {
|
|
17
|
+
return {
|
|
18
|
+
dropdownArrow: css `
|
|
19
|
+
transform-origin: 50% 50%;
|
|
20
|
+
margin-left: ${token.controlPaddingHorizontalSM}px;
|
|
21
|
+
`,
|
|
22
|
+
dropdownArrowIcon: css `
|
|
23
|
+
color: ${token.colorTextDisabled};
|
|
24
|
+
font-size: ${token.fontSizeSM}px;
|
|
25
|
+
vertical-align: center;
|
|
26
|
+
cursor: pointer;
|
|
27
|
+
transition: color 0.3s;
|
|
28
|
+
|
|
29
|
+
&:hover {
|
|
30
|
+
color: ${token.colorTextSecondary};
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
&:active {
|
|
34
|
+
color: ${token.colorText};
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
+ i {
|
|
38
|
+
margin-left: 6px;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
svg {
|
|
42
|
+
transition: transform 0.3s;
|
|
43
|
+
}
|
|
44
|
+
`,
|
|
45
|
+
dropdownArrowIconOpen: css `
|
|
46
|
+
svg {
|
|
47
|
+
transform: rotate(180deg);
|
|
48
|
+
}
|
|
49
|
+
`
|
|
50
|
+
};
|
|
51
|
+
}, { label: "dropdownArrow" });
|
|
52
|
+
export default class DropdownArrow extends React.PureComponent {
|
|
53
|
+
render() {
|
|
54
|
+
const _a = this.props, { opened } = _a, restProps = __rest(_a, ["opened"]);
|
|
55
|
+
return (React.createElement(WithCss, { useStyles: useStyles }, (css) => React.createElement("span", { className: css.styles.dropdownArrow },
|
|
56
|
+
React.createElement(DownOutlined, Object.assign({}, restProps, { className: opened ? css.cx(css.styles.dropdownArrowIcon, css.styles.dropdownArrowIconOpen) : css.styles.dropdownArrowIcon, role: "button", tabIndex: -1 })))));
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
//# sourceMappingURL=dropdownArrow.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dropdownArrow.js","sourceRoot":"","sources":["../../../../components/icons/dropdownArrow.tsx"],"names":[],"mappings":";;;;;;;;;;;AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAC,YAAY,EAAC,MAAM,YAAY,CAAC;AACxC,OAAO,EAAC,YAAY,EAAC,MAAM,mBAAmB,CAAC;AAC/C,OAAO,OAAO,MAAM,mCAAmC,CAAC;AAIxD,MAAM,SAAS,GAAG,YAAY,CAAC,CAAC,EAAC,KAAK,EAAE,GAAG,EAAE,EAAE,EAAC,EAAE,EAAE;IAChD,OAAO;QACH,aAAa,EAAE,GAAG,CAAA;;2BAEC,KAAK,CAAC,0BAA0B;SAClD;QAED,iBAAiB,EAAE,GAAG,CAAA;qBACT,KAAK,CAAC,iBAAiB;yBACnB,KAAK,CAAC,UAAU;;;;;;yBAMhB,KAAK,CAAC,kBAAkB;;;;yBAIxB,KAAK,CAAC,SAAS;;;;;;;;;;SAU/B;QAED,qBAAqB,EAAE,GAAG,CAAA;;;;SAIzB;KACJ,CAAC;AACN,CAAC,EAAE,EAAC,KAAK,EAAE,eAAe,EAAC,CAAC,CAAC;AAM7B,MAAM,CAAC,OAAO,OAAO,aAAc,SAAQ,KAAK,CAAC,aAAiC;IAC9E,MAAM;QACF,MAAM,KAAyB,IAAI,CAAC,KAAK,EAAnC,EAAC,MAAM,OAA4B,EAAvB,SAAS,cAArB,UAAsB,CAAa,CAAC;QAE1C,OAAO,CACH,oBAAC,OAAO,IAAC,SAAS,EAAE,SAAS,IACzB,CAAC,GAAG,EAAE,EAAE,CACJ,8BAAM,SAAS,EAAE,GAAG,CAAC,MAAM,CAAC,aAAa;YACrC,oBAAC,YAAY,oBAAK,SAAS,IACb,SAAS,EAAE,MAAM,CAAC,CAAC,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,CAAC,MAAM,CAAC,iBAAiB,EAAE,GAAG,CAAC,MAAM,CAAC,qBAAqB,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,MAAM,CAAC,iBAAiB,EACzH,IAAI,EAAC,QAAQ,EAAC,QAAQ,EAAE,CAAC,CAAC,IACtC,CACH,CACA,CACd,CAAC;IACN,CAAC;CACJ","sourcesContent":["import React from \"react\";\r\nimport {createStyles} from \"antd-style\";\r\nimport {DownOutlined} from \"@ant-design/icons\";\r\nimport WithCss from \"d2coreui/components/style/withCss\";\r\nimport {AntdIconProps} from \"@ant-design/icons/lib/components/AntdIcon\";\r\n\r\n// @ts-ignore\r\nconst useStyles = createStyles(({token, css, cx}) => {\r\n return {\r\n dropdownArrow: css`\r\n transform-origin: 50% 50%;\r\n margin-left: ${token.controlPaddingHorizontalSM}px;\r\n `,\r\n\r\n dropdownArrowIcon: css`\r\n color: ${token.colorTextDisabled};\r\n font-size: ${token.fontSizeSM}px;\r\n vertical-align: center;\r\n cursor: pointer;\r\n transition: color 0.3s;\r\n\r\n &:hover {\r\n color: ${token.colorTextSecondary};\r\n }\r\n\r\n &:active {\r\n color: ${token.colorText};\r\n }\r\n\r\n + i {\r\n margin-left: 6px;\r\n }\r\n\r\n svg {\r\n transition: transform 0.3s;\r\n }\r\n `,\r\n\r\n dropdownArrowIconOpen: css`\r\n svg {\r\n transform: rotate(180deg);\r\n }\r\n `\r\n };\r\n}, {label: \"dropdownArrow\"});\r\n\r\nexport interface DropdownArrowProps extends AntdIconProps {\r\n opened?: boolean\r\n}\r\n\r\nexport default class DropdownArrow extends React.PureComponent<DropdownArrowProps> {\r\n render() {\r\n const {opened, ...restProps} = this.props;\r\n\r\n return (\r\n <WithCss useStyles={useStyles}>{\r\n (css) =>\r\n <span className={css.styles.dropdownArrow}>\r\n <DownOutlined {...restProps}\r\n className={opened ? css.cx(css.styles.dropdownArrowIcon, css.styles.dropdownArrowIconOpen) : css.styles.dropdownArrowIcon}\r\n role=\"button\" tabIndex={-1}\r\n />\r\n </span>\r\n }</WithCss>\r\n );\r\n }\r\n}\r\n"]}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { CSSProperties } from "react";
|
|
2
|
-
declare const UndoIcon: (props: {
|
|
3
|
-
style?: CSSProperties;
|
|
4
|
-
}) => JSX.Element;
|
|
5
|
-
declare const UndoMenuIcon: (props: {
|
|
6
|
-
style?: CSSProperties;
|
|
7
|
-
}) => JSX.Element;
|
|
8
|
-
export { UndoIcon, UndoMenuIcon };
|
|
1
|
+
import React, { CSSProperties } from "react";
|
|
2
|
+
declare const UndoIcon: (props: {
|
|
3
|
+
style?: CSSProperties;
|
|
4
|
+
}) => React.JSX.Element;
|
|
5
|
+
declare const UndoMenuIcon: (props: {
|
|
6
|
+
style?: CSSProperties;
|
|
7
|
+
}) => React.JSX.Element;
|
|
8
|
+
export { UndoIcon, UndoMenuIcon };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import Icon from "@ant-design/icons/es/components/Icon";
|
|
3
|
-
const UndoIcon = (props) => (React.createElement(Icon, { component: () => React.createElement("svg", { preserveAspectRatio: "xMidYMid meet", viewBox: "0 0 14 14", width: 14, height: 14, style: props.style },
|
|
4
|
-
React.createElement("path", { d: "m 8.327691,3.3283097 c 2.800837,0 5.07135,2.3743226 5.07135,5.303197 0,2.9288733 -2.270513,5.3031963 -5.07135,5.3031963 H 4.946796 v -0.883866 h 3.380895 c 2.334032,0 4.226127,-1.978602 4.226127,-4.4193303 0,-2.4407292 -1.892095,-4.4193308 -4.226127,-4.4193308 H 2.338436 L 4.904535,6.8955935 4.306962,7.5204869 0.720677,3.7702428 4.306962,0.01999879 4.904535,0.64489216 2.338436,3.3283097 Z", style: { display: "inline", fill: "currentColor" } })) }));
|
|
5
|
-
const UndoMenuIcon = (props) => (React.createElement(UndoIcon, { style: Object.assign({ marginRight: 6, width: 12, height: 12 }, props.style) }));
|
|
6
|
-
export { UndoIcon, UndoMenuIcon };
|
|
1
|
+
import React from "react";
|
|
2
|
+
import Icon from "@ant-design/icons/es/components/Icon";
|
|
3
|
+
const UndoIcon = (props) => (React.createElement(Icon, { component: () => React.createElement("svg", { preserveAspectRatio: "xMidYMid meet", viewBox: "0 0 14 14", width: 14, height: 14, style: props.style },
|
|
4
|
+
React.createElement("path", { d: "m 8.327691,3.3283097 c 2.800837,0 5.07135,2.3743226 5.07135,5.303197 0,2.9288733 -2.270513,5.3031963 -5.07135,5.3031963 H 4.946796 v -0.883866 h 3.380895 c 2.334032,0 4.226127,-1.978602 4.226127,-4.4193303 0,-2.4407292 -1.892095,-4.4193308 -4.226127,-4.4193308 H 2.338436 L 4.904535,6.8955935 4.306962,7.5204869 0.720677,3.7702428 4.306962,0.01999879 4.904535,0.64489216 2.338436,3.3283097 Z", style: { display: "inline", fill: "currentColor" } })) }));
|
|
5
|
+
const UndoMenuIcon = (props) => (React.createElement(UndoIcon, { style: Object.assign({ marginRight: 6, width: 12, height: 12 }, props.style) }));
|
|
6
|
+
export { UndoIcon, UndoMenuIcon };
|
|
7
7
|
//# sourceMappingURL=undoIcon.js.map
|
|
@@ -1,35 +1,35 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { AutoCompleteProps } from "antd/es/auto-complete";
|
|
3
|
-
import { DefaultOptionType } from "antd/es/select";
|
|
4
|
-
interface InputSearchWithHistoryProps extends Omit<AutoCompleteProps, "onChange" | "onSearch" | "placeholder" | "options"> {
|
|
5
|
-
value?: string;
|
|
6
|
-
options?: string[];
|
|
7
|
-
placeholder?: string;
|
|
8
|
-
prefix?: React.ReactNode;
|
|
9
|
-
onChange(searchString: string): void;
|
|
10
|
-
onSearch(): void;
|
|
11
|
-
onPressEnter?(): void;
|
|
12
|
-
inputReadonly?: boolean;
|
|
13
|
-
stringFormatter?(rawString: string): string;
|
|
14
|
-
}
|
|
15
|
-
interface InputSearchWithHistoryState {
|
|
16
|
-
opened: boolean;
|
|
17
|
-
loading: boolean;
|
|
18
|
-
searchString?: string;
|
|
19
|
-
}
|
|
20
|
-
export default class AutoCompleteInput extends React.Component<InputSearchWithHistoryProps, InputSearchWithHistoryState> {
|
|
21
|
-
static get defaultProps(): {
|
|
22
|
-
onSearch: () => void;
|
|
23
|
-
onChange: () => void;
|
|
24
|
-
};
|
|
25
|
-
private autocomplete;
|
|
26
|
-
constructor(props: Readonly<InputSearchWithHistoryProps>);
|
|
27
|
-
focus(): void;
|
|
28
|
-
static getDerivedStateFromProps(props: InputSearchWithHistoryProps, state: InputSearchWithHistoryState): Partial<InputSearchWithHistoryState>;
|
|
29
|
-
setSearchString(searchString: string): void;
|
|
30
|
-
getAutocompleteOptions(): DefaultOptionType[];
|
|
31
|
-
onSearch(): void;
|
|
32
|
-
onSelect(searchString: string): void;
|
|
33
|
-
render(): JSX.Element;
|
|
34
|
-
}
|
|
35
|
-
export {};
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { AutoCompleteProps } from "antd/es/auto-complete";
|
|
3
|
+
import { DefaultOptionType } from "antd/es/select";
|
|
4
|
+
interface InputSearchWithHistoryProps extends Omit<AutoCompleteProps, "onChange" | "onSearch" | "placeholder" | "options"> {
|
|
5
|
+
value?: string;
|
|
6
|
+
options?: string[];
|
|
7
|
+
placeholder?: string;
|
|
8
|
+
prefix?: React.ReactNode;
|
|
9
|
+
onChange(searchString: string): void;
|
|
10
|
+
onSearch(): void;
|
|
11
|
+
onPressEnter?(): void;
|
|
12
|
+
inputReadonly?: boolean;
|
|
13
|
+
stringFormatter?(rawString: string): string;
|
|
14
|
+
}
|
|
15
|
+
interface InputSearchWithHistoryState {
|
|
16
|
+
opened: boolean;
|
|
17
|
+
loading: boolean;
|
|
18
|
+
searchString?: string;
|
|
19
|
+
}
|
|
20
|
+
export default class AutoCompleteInput extends React.Component<InputSearchWithHistoryProps, InputSearchWithHistoryState> {
|
|
21
|
+
static get defaultProps(): {
|
|
22
|
+
onSearch: () => void;
|
|
23
|
+
onChange: () => void;
|
|
24
|
+
};
|
|
25
|
+
private autocomplete;
|
|
26
|
+
constructor(props: Readonly<InputSearchWithHistoryProps>);
|
|
27
|
+
focus(): void;
|
|
28
|
+
static getDerivedStateFromProps(props: InputSearchWithHistoryProps, state: InputSearchWithHistoryState): Partial<InputSearchWithHistoryState>;
|
|
29
|
+
setSearchString(searchString: string): void;
|
|
30
|
+
getAutocompleteOptions(): DefaultOptionType[];
|
|
31
|
+
onSearch(): void;
|
|
32
|
+
onSelect(searchString: string): void;
|
|
33
|
+
render(): React.JSX.Element;
|
|
34
|
+
}
|
|
35
|
+
export {};
|