handsontable 0.0.0-next-9ec04ce-20221121
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.
Potentially problematic release.
This version of handsontable might be problematic. Click here for more details.
- package/3rdparty/SheetClip/SheetClip.js +128 -0
- package/3rdparty/SheetClip/SheetClip.mjs +123 -0
- package/3rdparty/SheetClip/index.js +7 -0
- package/3rdparty/SheetClip/index.mjs +1 -0
- package/3rdparty/autoResize/autoResize.js +164 -0
- package/3rdparty/autoResize/autoResize.mjs +160 -0
- package/3rdparty/autoResize/index.js +6 -0
- package/3rdparty/autoResize/index.mjs +1 -0
- package/3rdparty/walkontable/src/border.js +746 -0
- package/3rdparty/walkontable/src/border.mjs +741 -0
- package/3rdparty/walkontable/src/calculator/constants.js +30 -0
- package/3rdparty/walkontable/src/calculator/constants.mjs +23 -0
- package/3rdparty/walkontable/src/calculator/index.js +22 -0
- package/3rdparty/walkontable/src/calculator/index.mjs +4 -0
- package/3rdparty/walkontable/src/calculator/viewportColumns.d.ts +18 -0
- package/3rdparty/walkontable/src/calculator/viewportColumns.js +297 -0
- package/3rdparty/walkontable/src/calculator/viewportColumns.mjs +292 -0
- package/3rdparty/walkontable/src/calculator/viewportRows.js +175 -0
- package/3rdparty/walkontable/src/calculator/viewportRows.mjs +170 -0
- package/3rdparty/walkontable/src/cell/coords.d.ts +16 -0
- package/3rdparty/walkontable/src/cell/coords.js +185 -0
- package/3rdparty/walkontable/src/cell/coords.mjs +180 -0
- package/3rdparty/walkontable/src/cell/range.d.ts +59 -0
- package/3rdparty/walkontable/src/cell/range.js +888 -0
- package/3rdparty/walkontable/src/cell/range.mjs +882 -0
- package/3rdparty/walkontable/src/core/_base.js +395 -0
- package/3rdparty/walkontable/src/core/_base.mjs +390 -0
- package/3rdparty/walkontable/src/core/clone.js +59 -0
- package/3rdparty/walkontable/src/core/clone.mjs +54 -0
- package/3rdparty/walkontable/src/core/core.js +130 -0
- package/3rdparty/walkontable/src/core/core.mjs +125 -0
- package/3rdparty/walkontable/src/event.js +401 -0
- package/3rdparty/walkontable/src/event.mjs +396 -0
- package/3rdparty/walkontable/src/facade/core.js +236 -0
- package/3rdparty/walkontable/src/facade/core.mjs +231 -0
- package/3rdparty/walkontable/src/filter/column.js +107 -0
- package/3rdparty/walkontable/src/filter/column.mjs +102 -0
- package/3rdparty/walkontable/src/filter/row.js +107 -0
- package/3rdparty/walkontable/src/filter/row.mjs +102 -0
- package/3rdparty/walkontable/src/index.d.ts +1 -0
- package/3rdparty/walkontable/src/index.js +37 -0
- package/3rdparty/walkontable/src/index.mjs +10 -0
- package/3rdparty/walkontable/src/overlay/_base.js +363 -0
- package/3rdparty/walkontable/src/overlay/_base.mjs +357 -0
- package/3rdparty/walkontable/src/overlay/bottom.js +397 -0
- package/3rdparty/walkontable/src/overlay/bottom.mjs +391 -0
- package/3rdparty/walkontable/src/overlay/bottomInlineStartCorner.js +140 -0
- package/3rdparty/walkontable/src/overlay/bottomInlineStartCorner.mjs +134 -0
- package/3rdparty/walkontable/src/overlay/constants.js +26 -0
- package/3rdparty/walkontable/src/overlay/constants.mjs +15 -0
- package/3rdparty/walkontable/src/overlay/index.js +34 -0
- package/3rdparty/walkontable/src/overlay/index.mjs +7 -0
- package/3rdparty/walkontable/src/overlay/inlineStart.js +385 -0
- package/3rdparty/walkontable/src/overlay/inlineStart.mjs +379 -0
- package/3rdparty/walkontable/src/overlay/top.js +415 -0
- package/3rdparty/walkontable/src/overlay/top.mjs +409 -0
- package/3rdparty/walkontable/src/overlay/topInlineStartCorner.js +130 -0
- package/3rdparty/walkontable/src/overlay/topInlineStartCorner.mjs +124 -0
- package/3rdparty/walkontable/src/overlays.js +675 -0
- package/3rdparty/walkontable/src/overlays.mjs +670 -0
- package/3rdparty/walkontable/src/renderer/_base.js +83 -0
- package/3rdparty/walkontable/src/renderer/_base.mjs +78 -0
- package/3rdparty/walkontable/src/renderer/cells.js +127 -0
- package/3rdparty/walkontable/src/renderer/cells.mjs +122 -0
- package/3rdparty/walkontable/src/renderer/colGroup.js +101 -0
- package/3rdparty/walkontable/src/renderer/colGroup.mjs +96 -0
- package/3rdparty/walkontable/src/renderer/columnHeaders.js +115 -0
- package/3rdparty/walkontable/src/renderer/columnHeaders.mjs +110 -0
- package/3rdparty/walkontable/src/renderer/index.js +118 -0
- package/3rdparty/walkontable/src/renderer/index.mjs +107 -0
- package/3rdparty/walkontable/src/renderer/rowHeaders.js +119 -0
- package/3rdparty/walkontable/src/renderer/rowHeaders.mjs +114 -0
- package/3rdparty/walkontable/src/renderer/rows.js +99 -0
- package/3rdparty/walkontable/src/renderer/rows.mjs +94 -0
- package/3rdparty/walkontable/src/renderer/table.js +317 -0
- package/3rdparty/walkontable/src/renderer/table.mjs +313 -0
- package/3rdparty/walkontable/src/scroll.js +316 -0
- package/3rdparty/walkontable/src/scroll.mjs +311 -0
- package/3rdparty/walkontable/src/selection.js +349 -0
- package/3rdparty/walkontable/src/selection.mjs +343 -0
- package/3rdparty/walkontable/src/settings.js +306 -0
- package/3rdparty/walkontable/src/settings.mjs +302 -0
- package/3rdparty/walkontable/src/table/bottom.js +56 -0
- package/3rdparty/walkontable/src/table/bottom.mjs +50 -0
- package/3rdparty/walkontable/src/table/bottomInlineStartCorner.js +57 -0
- package/3rdparty/walkontable/src/table/bottomInlineStartCorner.mjs +51 -0
- package/3rdparty/walkontable/src/table/inlineStart.js +53 -0
- package/3rdparty/walkontable/src/table/inlineStart.mjs +47 -0
- package/3rdparty/walkontable/src/table/master.js +132 -0
- package/3rdparty/walkontable/src/table/master.mjs +126 -0
- package/3rdparty/walkontable/src/table/mixin/calculatedColumns.js +93 -0
- package/3rdparty/walkontable/src/table/mixin/calculatedColumns.mjs +88 -0
- package/3rdparty/walkontable/src/table/mixin/calculatedRows.js +93 -0
- package/3rdparty/walkontable/src/table/mixin/calculatedRows.mjs +88 -0
- package/3rdparty/walkontable/src/table/mixin/stickyColumnsStart.js +85 -0
- package/3rdparty/walkontable/src/table/mixin/stickyColumnsStart.mjs +80 -0
- package/3rdparty/walkontable/src/table/mixin/stickyRowsBottom.js +90 -0
- package/3rdparty/walkontable/src/table/mixin/stickyRowsBottom.mjs +85 -0
- package/3rdparty/walkontable/src/table/mixin/stickyRowsTop.js +85 -0
- package/3rdparty/walkontable/src/table/mixin/stickyRowsTop.mjs +80 -0
- package/3rdparty/walkontable/src/table/top.js +56 -0
- package/3rdparty/walkontable/src/table/top.mjs +50 -0
- package/3rdparty/walkontable/src/table/topInlineStartCorner.js +57 -0
- package/3rdparty/walkontable/src/table/topInlineStartCorner.mjs +51 -0
- package/3rdparty/walkontable/src/table.js +1171 -0
- package/3rdparty/walkontable/src/table.mjs +1165 -0
- package/3rdparty/walkontable/src/types.js +98 -0
- package/3rdparty/walkontable/src/types.mjs +97 -0
- package/3rdparty/walkontable/src/utils/column.js +121 -0
- package/3rdparty/walkontable/src/utils/column.mjs +117 -0
- package/3rdparty/walkontable/src/utils/nodesPool.js +48 -0
- package/3rdparty/walkontable/src/utils/nodesPool.mjs +44 -0
- package/3rdparty/walkontable/src/utils/orderView/constants.js +30 -0
- package/3rdparty/walkontable/src/utils/orderView/constants.mjs +23 -0
- package/3rdparty/walkontable/src/utils/orderView/index.js +8 -0
- package/3rdparty/walkontable/src/utils/orderView/index.mjs +3 -0
- package/3rdparty/walkontable/src/utils/orderView/sharedView.js +81 -0
- package/3rdparty/walkontable/src/utils/orderView/sharedView.mjs +76 -0
- package/3rdparty/walkontable/src/utils/orderView/view.js +216 -0
- package/3rdparty/walkontable/src/utils/orderView/view.mjs +211 -0
- package/3rdparty/walkontable/src/utils/orderView/viewSize.js +68 -0
- package/3rdparty/walkontable/src/utils/orderView/viewSize.mjs +64 -0
- package/3rdparty/walkontable/src/utils/orderView/viewSizeSet.js +137 -0
- package/3rdparty/walkontable/src/utils/orderView/viewSizeSet.mjs +132 -0
- package/3rdparty/walkontable/src/utils/row.js +43 -0
- package/3rdparty/walkontable/src/utils/row.mjs +39 -0
- package/3rdparty/walkontable/src/viewport.js +491 -0
- package/3rdparty/walkontable/src/viewport.mjs +486 -0
- package/CHANGELOG.md +716 -0
- package/LICENSE.txt +25 -0
- package/README.md +140 -0
- package/base.d.ts +3 -0
- package/base.js +54 -0
- package/base.mjs +44 -0
- package/cellTypes/autocompleteType/autocompleteType.d.ts +17 -0
- package/cellTypes/autocompleteType/autocompleteType.js +16 -0
- package/cellTypes/autocompleteType/autocompleteType.mjs +10 -0
- package/cellTypes/autocompleteType/index.d.ts +1 -0
- package/cellTypes/autocompleteType/index.js +7 -0
- package/cellTypes/autocompleteType/index.mjs +1 -0
- package/cellTypes/base.d.ts +14 -0
- package/cellTypes/checkboxType/checkboxType.d.ts +14 -0
- package/cellTypes/checkboxType/checkboxType.js +14 -0
- package/cellTypes/checkboxType/checkboxType.mjs +8 -0
- package/cellTypes/checkboxType/index.d.ts +1 -0
- package/cellTypes/checkboxType/index.js +7 -0
- package/cellTypes/checkboxType/index.mjs +1 -0
- package/cellTypes/dateType/dateType.d.ts +17 -0
- package/cellTypes/dateType/dateType.js +17 -0
- package/cellTypes/dateType/dateType.mjs +11 -0
- package/cellTypes/dateType/index.d.ts +1 -0
- package/cellTypes/dateType/index.js +7 -0
- package/cellTypes/dateType/index.mjs +1 -0
- package/cellTypes/dropdownType/dropdownType.d.ts +17 -0
- package/cellTypes/dropdownType/dropdownType.js +17 -0
- package/cellTypes/dropdownType/dropdownType.mjs +11 -0
- package/cellTypes/dropdownType/index.d.ts +1 -0
- package/cellTypes/dropdownType/index.js +7 -0
- package/cellTypes/dropdownType/index.mjs +1 -0
- package/cellTypes/handsontableType/handsontableType.d.ts +14 -0
- package/cellTypes/handsontableType/handsontableType.js +15 -0
- package/cellTypes/handsontableType/handsontableType.mjs +9 -0
- package/cellTypes/handsontableType/index.d.ts +1 -0
- package/cellTypes/handsontableType/index.js +7 -0
- package/cellTypes/handsontableType/index.mjs +1 -0
- package/cellTypes/index.d.ts +47 -0
- package/cellTypes/index.js +52 -0
- package/cellTypes/index.mjs +26 -0
- package/cellTypes/numericType/index.d.ts +1 -0
- package/cellTypes/numericType/index.js +7 -0
- package/cellTypes/numericType/index.mjs +1 -0
- package/cellTypes/numericType/numericType.d.ts +17 -0
- package/cellTypes/numericType/numericType.js +17 -0
- package/cellTypes/numericType/numericType.mjs +11 -0
- package/cellTypes/passwordType/index.d.ts +1 -0
- package/cellTypes/passwordType/index.js +7 -0
- package/cellTypes/passwordType/index.mjs +1 -0
- package/cellTypes/passwordType/passwordType.d.ts +14 -0
- package/cellTypes/passwordType/passwordType.js +15 -0
- package/cellTypes/passwordType/passwordType.mjs +9 -0
- package/cellTypes/registry.d.ts +18 -0
- package/cellTypes/registry.js +60 -0
- package/cellTypes/registry.mjs +51 -0
- package/cellTypes/textType/index.d.ts +1 -0
- package/cellTypes/textType/index.js +7 -0
- package/cellTypes/textType/index.mjs +1 -0
- package/cellTypes/textType/textType.d.ts +14 -0
- package/cellTypes/textType/textType.js +14 -0
- package/cellTypes/textType/textType.mjs +8 -0
- package/cellTypes/timeType/index.d.ts +1 -0
- package/cellTypes/timeType/index.js +7 -0
- package/cellTypes/timeType/index.mjs +1 -0
- package/cellTypes/timeType/timeType.d.ts +17 -0
- package/cellTypes/timeType/timeType.js +16 -0
- package/cellTypes/timeType/timeType.mjs +10 -0
- package/common.d.ts +74 -0
- package/core.d.ts +167 -0
- package/core.js +4684 -0
- package/core.mjs +4679 -0
- package/dataMap/dataMap.js +975 -0
- package/dataMap/dataMap.mjs +970 -0
- package/dataMap/dataSource.js +325 -0
- package/dataMap/dataSource.mjs +320 -0
- package/dataMap/index.js +16 -0
- package/dataMap/index.mjs +7 -0
- package/dataMap/metaManager/index.js +339 -0
- package/dataMap/metaManager/index.mjs +334 -0
- package/dataMap/metaManager/lazyFactoryMap.js +370 -0
- package/dataMap/metaManager/lazyFactoryMap.mjs +366 -0
- package/dataMap/metaManager/metaLayers/cellMeta.js +275 -0
- package/dataMap/metaManager/metaLayers/cellMeta.mjs +270 -0
- package/dataMap/metaManager/metaLayers/columnMeta.js +153 -0
- package/dataMap/metaManager/metaLayers/columnMeta.mjs +148 -0
- package/dataMap/metaManager/metaLayers/globalMeta.js +103 -0
- package/dataMap/metaManager/metaLayers/globalMeta.mjs +98 -0
- package/dataMap/metaManager/metaLayers/tableMeta.js +73 -0
- package/dataMap/metaManager/metaLayers/tableMeta.mjs +69 -0
- package/dataMap/metaManager/metaSchema.js +4610 -0
- package/dataMap/metaManager/metaSchema.mjs +4605 -0
- package/dataMap/metaManager/mods/dynamicCellMeta.js +107 -0
- package/dataMap/metaManager/mods/dynamicCellMeta.mjs +101 -0
- package/dataMap/metaManager/mods/extendMetaProperties.js +104 -0
- package/dataMap/metaManager/mods/extendMetaProperties.mjs +99 -0
- package/dataMap/metaManager/utils.js +99 -0
- package/dataMap/metaManager/utils.mjs +91 -0
- package/dataMap/replaceData.js +119 -0
- package/dataMap/replaceData.mjs +115 -0
- package/dist/README.md +54 -0
- package/dist/handsontable.css +1941 -0
- package/dist/handsontable.full.css +2172 -0
- package/dist/handsontable.full.js +150392 -0
- package/dist/handsontable.full.min.css +47 -0
- package/dist/handsontable.full.min.js +869 -0
- package/dist/handsontable.js +94075 -0
- package/dist/handsontable.min.css +43 -0
- package/dist/handsontable.min.js +31 -0
- package/dist/languages/all.js +583 -0
- package/dist/languages/all.min.js +1 -0
- package/dist/languages/ar-AR.js +157 -0
- package/dist/languages/ar-AR.min.js +1 -0
- package/dist/languages/cs-CZ.js +157 -0
- package/dist/languages/cs-CZ.min.js +1 -0
- package/dist/languages/de-CH.js +158 -0
- package/dist/languages/de-CH.min.js +1 -0
- package/dist/languages/de-DE.js +159 -0
- package/dist/languages/de-DE.min.js +1 -0
- package/dist/languages/en-US.js +160 -0
- package/dist/languages/en-US.min.js +1 -0
- package/dist/languages/es-MX.js +161 -0
- package/dist/languages/es-MX.min.js +1 -0
- package/dist/languages/fr-FR.js +162 -0
- package/dist/languages/fr-FR.min.js +1 -0
- package/dist/languages/it-IT.js +164 -0
- package/dist/languages/it-IT.min.js +1 -0
- package/dist/languages/ja-JP.js +161 -0
- package/dist/languages/ja-JP.min.js +1 -0
- package/dist/languages/ko-KR.js +161 -0
- package/dist/languages/ko-KR.min.js +1 -0
- package/dist/languages/lv-LV.js +161 -0
- package/dist/languages/lv-LV.min.js +1 -0
- package/dist/languages/nb-NO.js +161 -0
- package/dist/languages/nb-NO.min.js +1 -0
- package/dist/languages/nl-NL.js +161 -0
- package/dist/languages/nl-NL.min.js +1 -0
- package/dist/languages/pl-PL.js +161 -0
- package/dist/languages/pl-PL.min.js +1 -0
- package/dist/languages/pt-BR.js +161 -0
- package/dist/languages/pt-BR.min.js +1 -0
- package/dist/languages/ru-RU.js +161 -0
- package/dist/languages/ru-RU.min.js +1 -0
- package/dist/languages/sr-SP.js +161 -0
- package/dist/languages/sr-SP.min.js +1 -0
- package/dist/languages/zh-CN.js +161 -0
- package/dist/languages/zh-CN.min.js +1 -0
- package/dist/languages/zh-TW.js +161 -0
- package/dist/languages/zh-TW.min.js +1 -0
- package/editorManager.js +522 -0
- package/editorManager.mjs +514 -0
- package/editors/autocompleteEditor/autocompleteEditor.d.ts +29 -0
- package/editors/autocompleteEditor/autocompleteEditor.js +584 -0
- package/editors/autocompleteEditor/autocompleteEditor.mjs +578 -0
- package/editors/autocompleteEditor/index.d.ts +1 -0
- package/editors/autocompleteEditor/index.js +7 -0
- package/editors/autocompleteEditor/index.mjs +1 -0
- package/editors/baseEditor/baseEditor.d.ts +45 -0
- package/editors/baseEditor/baseEditor.js +688 -0
- package/editors/baseEditor/baseEditor.mjs +679 -0
- package/editors/baseEditor/index.d.ts +1 -0
- package/editors/baseEditor/index.js +8 -0
- package/editors/baseEditor/index.mjs +1 -0
- package/editors/checkboxEditor/checkboxEditor.d.ts +12 -0
- package/editors/checkboxEditor/checkboxEditor.js +85 -0
- package/editors/checkboxEditor/checkboxEditor.mjs +79 -0
- package/editors/checkboxEditor/index.d.ts +1 -0
- package/editors/checkboxEditor/index.js +7 -0
- package/editors/checkboxEditor/index.mjs +1 -0
- package/editors/dateEditor/dateEditor.d.ts +18 -0
- package/editors/dateEditor/dateEditor.js +325 -0
- package/editors/dateEditor/dateEditor.mjs +318 -0
- package/editors/dateEditor/index.d.ts +1 -0
- package/editors/dateEditor/index.js +7 -0
- package/editors/dateEditor/index.mjs +1 -0
- package/editors/dropdownEditor/dropdownEditor.d.ts +7 -0
- package/editors/dropdownEditor/dropdownEditor.js +81 -0
- package/editors/dropdownEditor/dropdownEditor.mjs +74 -0
- package/editors/dropdownEditor/index.d.ts +1 -0
- package/editors/dropdownEditor/index.js +7 -0
- package/editors/dropdownEditor/index.mjs +1 -0
- package/editors/handsontableEditor/handsontableEditor.d.ts +10 -0
- package/editors/handsontableEditor/handsontableEditor.js +306 -0
- package/editors/handsontableEditor/handsontableEditor.mjs +300 -0
- package/editors/handsontableEditor/index.d.ts +1 -0
- package/editors/handsontableEditor/index.js +7 -0
- package/editors/handsontableEditor/index.mjs +1 -0
- package/editors/index.d.ts +56 -0
- package/editors/index.js +63 -0
- package/editors/index.mjs +30 -0
- package/editors/numericEditor/index.d.ts +1 -0
- package/editors/numericEditor/index.js +7 -0
- package/editors/numericEditor/index.mjs +1 -0
- package/editors/numericEditor/numericEditor.d.ts +7 -0
- package/editors/numericEditor/numericEditor.js +49 -0
- package/editors/numericEditor/numericEditor.mjs +43 -0
- package/editors/passwordEditor/index.d.ts +1 -0
- package/editors/passwordEditor/index.js +7 -0
- package/editors/passwordEditor/index.mjs +1 -0
- package/editors/passwordEditor/passwordEditor.d.ts +7 -0
- package/editors/passwordEditor/passwordEditor.js +68 -0
- package/editors/passwordEditor/passwordEditor.mjs +62 -0
- package/editors/registry.d.ts +29 -0
- package/editors/registry.js +106 -0
- package/editors/registry.mjs +94 -0
- package/editors/selectEditor/index.d.ts +1 -0
- package/editors/selectEditor/index.js +7 -0
- package/editors/selectEditor/index.mjs +1 -0
- package/editors/selectEditor/selectEditor.d.ts +16 -0
- package/editors/selectEditor/selectEditor.js +302 -0
- package/editors/selectEditor/selectEditor.mjs +296 -0
- package/editors/textEditor/caretPositioner.js +37 -0
- package/editors/textEditor/caretPositioner.mjs +33 -0
- package/editors/textEditor/index.d.ts +1 -0
- package/editors/textEditor/index.js +7 -0
- package/editors/textEditor/index.mjs +1 -0
- package/editors/textEditor/textEditor.d.ts +24 -0
- package/editors/textEditor/textEditor.js +612 -0
- package/editors/textEditor/textEditor.mjs +605 -0
- package/editors/timeEditor/index.d.ts +1 -0
- package/editors/timeEditor/index.js +7 -0
- package/editors/timeEditor/index.mjs +1 -0
- package/editors/timeEditor/timeEditor.d.ts +7 -0
- package/editors/timeEditor/timeEditor.js +70 -0
- package/editors/timeEditor/timeEditor.mjs +64 -0
- package/eventManager.d.ts +13 -0
- package/eventManager.js +236 -0
- package/eventManager.mjs +231 -0
- package/handsontable-non-commercial-license.pdf +0 -0
- package/helpers/array.d.ts +18 -0
- package/helpers/array.js +353 -0
- package/helpers/array.mjs +333 -0
- package/helpers/browser.d.ts +25 -0
- package/helpers/browser.js +231 -0
- package/helpers/browser.mjs +210 -0
- package/helpers/console.d.ts +4 -0
- package/helpers/console.js +65 -0
- package/helpers/console.mjs +56 -0
- package/helpers/data.d.ts +12 -0
- package/helpers/data.js +247 -0
- package/helpers/data.mjs +234 -0
- package/helpers/date.d.ts +1 -0
- package/helpers/date.js +22 -0
- package/helpers/date.mjs +18 -0
- package/helpers/dom/element.d.ts +49 -0
- package/helpers/dom/element.js +1117 -0
- package/helpers/dom/element.mjs +1064 -0
- package/helpers/dom/event.d.ts +4 -0
- package/helpers/dom/event.js +46 -0
- package/helpers/dom/event.mjs +39 -0
- package/helpers/dom/index.d.ts +2 -0
- package/helpers/feature.d.ts +11 -0
- package/helpers/feature.js +184 -0
- package/helpers/feature.mjs +172 -0
- package/helpers/function.d.ts +10 -0
- package/helpers/function.js +319 -0
- package/helpers/function.mjs +307 -0
- package/helpers/index.d.ts +14 -0
- package/helpers/mixed.d.ts +5 -0
- package/helpers/mixed.js +230 -0
- package/helpers/mixed.mjs +220 -0
- package/helpers/number.d.ts +5 -0
- package/helpers/number.js +142 -0
- package/helpers/number.mjs +134 -0
- package/helpers/object.d.ts +16 -0
- package/helpers/object.js +371 -0
- package/helpers/object.mjs +352 -0
- package/helpers/string.d.ts +7 -0
- package/helpers/string.js +115 -0
- package/helpers/string.mjs +104 -0
- package/helpers/templateLiteralTag.d.ts +1 -0
- package/helpers/templateLiteralTag.js +26 -0
- package/helpers/templateLiteralTag.mjs +22 -0
- package/helpers/unicode.d.ts +73 -0
- package/helpers/unicode.js +158 -0
- package/helpers/unicode.mjs +148 -0
- package/helpers/wrappers/jquery.js +50 -0
- package/helpers/wrappers/jquery.mjs +46 -0
- package/i18n/constants.js +162 -0
- package/i18n/constants.mjs +82 -0
- package/i18n/index.d.ts +2 -0
- package/i18n/index.js +18 -0
- package/i18n/index.mjs +2 -0
- package/i18n/languages/ar-AR.js +25 -0
- package/i18n/languages/ar-AR.mjs +15 -0
- package/i18n/languages/cs-CZ.js +24 -0
- package/i18n/languages/cs-CZ.mjs +14 -0
- package/i18n/languages/de-CH.d.ts +5 -0
- package/i18n/languages/de-CH.js +24 -0
- package/i18n/languages/de-CH.mjs +14 -0
- package/i18n/languages/de-DE.d.ts +5 -0
- package/i18n/languages/de-DE.js +24 -0
- package/i18n/languages/de-DE.mjs +14 -0
- package/i18n/languages/en-US.d.ts +5 -0
- package/i18n/languages/en-US.js +24 -0
- package/i18n/languages/en-US.mjs +14 -0
- package/i18n/languages/es-MX.d.ts +5 -0
- package/i18n/languages/es-MX.js +24 -0
- package/i18n/languages/es-MX.mjs +13 -0
- package/i18n/languages/fr-FR.d.ts +5 -0
- package/i18n/languages/fr-FR.js +24 -0
- package/i18n/languages/fr-FR.mjs +14 -0
- package/i18n/languages/index.d.ts +35 -0
- package/i18n/languages/index.js +42 -0
- package/i18n/languages/index.mjs +20 -0
- package/i18n/languages/it-IT.d.ts +5 -0
- package/i18n/languages/it-IT.js +24 -0
- package/i18n/languages/it-IT.mjs +14 -0
- package/i18n/languages/ja-JP.d.ts +5 -0
- package/i18n/languages/ja-JP.js +24 -0
- package/i18n/languages/ja-JP.mjs +14 -0
- package/i18n/languages/ko-KR.d.ts +5 -0
- package/i18n/languages/ko-KR.js +24 -0
- package/i18n/languages/ko-KR.mjs +14 -0
- package/i18n/languages/lv-LV.d.ts +5 -0
- package/i18n/languages/lv-LV.js +24 -0
- package/i18n/languages/lv-LV.mjs +14 -0
- package/i18n/languages/nb-NO.d.ts +5 -0
- package/i18n/languages/nb-NO.js +24 -0
- package/i18n/languages/nb-NO.mjs +14 -0
- package/i18n/languages/nl-NL.d.ts +5 -0
- package/i18n/languages/nl-NL.js +24 -0
- package/i18n/languages/nl-NL.mjs +14 -0
- package/i18n/languages/pl-PL.d.ts +5 -0
- package/i18n/languages/pl-PL.js +24 -0
- package/i18n/languages/pl-PL.mjs +14 -0
- package/i18n/languages/pt-BR.d.ts +5 -0
- package/i18n/languages/pt-BR.js +24 -0
- package/i18n/languages/pt-BR.mjs +14 -0
- package/i18n/languages/ru-RU.d.ts +5 -0
- package/i18n/languages/ru-RU.js +24 -0
- package/i18n/languages/ru-RU.mjs +14 -0
- package/i18n/languages/sr-SP.js +24 -0
- package/i18n/languages/sr-SP.mjs +14 -0
- package/i18n/languages/zh-CN.d.ts +5 -0
- package/i18n/languages/zh-CN.js +24 -0
- package/i18n/languages/zh-CN.mjs +14 -0
- package/i18n/languages/zh-TW.d.ts +5 -0
- package/i18n/languages/zh-TW.js +24 -0
- package/i18n/languages/zh-TW.mjs +14 -0
- package/i18n/phraseFormatters/index.js +31 -0
- package/i18n/phraseFormatters/index.mjs +26 -0
- package/i18n/phraseFormatters/pluralize.js +21 -0
- package/i18n/phraseFormatters/pluralize.mjs +17 -0
- package/i18n/phraseFormatters/substituteVariables.js +22 -0
- package/i18n/phraseFormatters/substituteVariables.mjs +18 -0
- package/i18n/registry.d.ts +13 -0
- package/i18n/registry.js +180 -0
- package/i18n/registry.mjs +155 -0
- package/i18n/utils.js +90 -0
- package/i18n/utils.mjs +83 -0
- package/index.d.ts +520 -0
- package/index.js +130 -0
- package/index.mjs +112 -0
- package/languages/all.js +583 -0
- package/languages/ar-AR.js +157 -0
- package/languages/ar-AR.mjs +17 -0
- package/languages/cs-CZ.js +157 -0
- package/languages/cs-CZ.mjs +16 -0
- package/languages/de-CH.js +158 -0
- package/languages/de-CH.mjs +16 -0
- package/languages/de-DE.js +159 -0
- package/languages/de-DE.mjs +16 -0
- package/languages/en-US.js +160 -0
- package/languages/en-US.mjs +16 -0
- package/languages/es-MX.js +161 -0
- package/languages/es-MX.mjs +15 -0
- package/languages/fr-FR.js +162 -0
- package/languages/fr-FR.mjs +16 -0
- package/languages/index.js +583 -0
- package/languages/index.mjs +20 -0
- package/languages/it-IT.js +164 -0
- package/languages/it-IT.mjs +16 -0
- package/languages/ja-JP.js +161 -0
- package/languages/ja-JP.mjs +16 -0
- package/languages/ko-KR.js +161 -0
- package/languages/ko-KR.mjs +16 -0
- package/languages/lv-LV.js +161 -0
- package/languages/lv-LV.mjs +16 -0
- package/languages/nb-NO.js +161 -0
- package/languages/nb-NO.mjs +16 -0
- package/languages/nl-NL.js +161 -0
- package/languages/nl-NL.mjs +16 -0
- package/languages/pl-PL.js +161 -0
- package/languages/pl-PL.mjs +16 -0
- package/languages/pt-BR.js +161 -0
- package/languages/pt-BR.mjs +16 -0
- package/languages/ru-RU.js +161 -0
- package/languages/ru-RU.mjs +16 -0
- package/languages/sr-SP.js +161 -0
- package/languages/sr-SP.mjs +16 -0
- package/languages/zh-CN.js +161 -0
- package/languages/zh-CN.mjs +16 -0
- package/languages/zh-TW.js +161 -0
- package/languages/zh-TW.mjs +16 -0
- package/mixins/hooksRefRegisterer.js +61 -0
- package/mixins/hooksRefRegisterer.mjs +56 -0
- package/mixins/localHooks.js +71 -0
- package/mixins/localHooks.mjs +66 -0
- package/package.json +751 -0
- package/pluginHooks.d.ts +256 -0
- package/pluginHooks.js +2750 -0
- package/pluginHooks.mjs +2744 -0
- package/plugins/autoColumnSize/autoColumnSize.d.ts +27 -0
- package/plugins/autoColumnSize/autoColumnSize.js +796 -0
- package/plugins/autoColumnSize/autoColumnSize.mjs +788 -0
- package/plugins/autoColumnSize/index.d.ts +1 -0
- package/plugins/autoColumnSize/index.js +8 -0
- package/plugins/autoColumnSize/index.mjs +1 -0
- package/plugins/autoRowSize/autoRowSize.d.ts +27 -0
- package/plugins/autoRowSize/autoRowSize.js +735 -0
- package/plugins/autoRowSize/autoRowSize.mjs +727 -0
- package/plugins/autoRowSize/index.d.ts +1 -0
- package/plugins/autoRowSize/index.js +8 -0
- package/plugins/autoRowSize/index.mjs +1 -0
- package/plugins/autofill/autofill.d.ts +18 -0
- package/plugins/autofill/autofill.js +694 -0
- package/plugins/autofill/autofill.mjs +687 -0
- package/plugins/autofill/index.d.ts +1 -0
- package/plugins/autofill/index.js +8 -0
- package/plugins/autofill/index.mjs +1 -0
- package/plugins/autofill/utils.js +134 -0
- package/plugins/autofill/utils.mjs +126 -0
- package/plugins/base/base.d.ts +27 -0
- package/plugins/base/base.js +345 -0
- package/plugins/base/base.mjs +339 -0
- package/plugins/base/index.d.ts +1 -0
- package/plugins/base/index.js +7 -0
- package/plugins/base/index.mjs +1 -0
- package/plugins/bindRowsWithHeaders/bindRowsWithHeaders.d.ts +9 -0
- package/plugins/bindRowsWithHeaders/bindRowsWithHeaders.js +169 -0
- package/plugins/bindRowsWithHeaders/bindRowsWithHeaders.mjs +161 -0
- package/plugins/bindRowsWithHeaders/index.d.ts +1 -0
- package/plugins/bindRowsWithHeaders/index.js +8 -0
- package/plugins/bindRowsWithHeaders/index.mjs +1 -0
- package/plugins/bindRowsWithHeaders/maps/looseBindsMap.js +80 -0
- package/plugins/bindRowsWithHeaders/maps/looseBindsMap.mjs +75 -0
- package/plugins/bindRowsWithHeaders/maps/strictBindsMap.js +103 -0
- package/plugins/bindRowsWithHeaders/maps/strictBindsMap.mjs +98 -0
- package/plugins/collapsibleColumns/collapsibleColumns.d.ts +22 -0
- package/plugins/collapsibleColumns/collapsibleColumns.js +592 -0
- package/plugins/collapsibleColumns/collapsibleColumns.mjs +584 -0
- package/plugins/collapsibleColumns/index.d.ts +1 -0
- package/plugins/collapsibleColumns/index.js +8 -0
- package/plugins/collapsibleColumns/index.mjs +1 -0
- package/plugins/columnSorting/columnSorting.d.ts +30 -0
- package/plugins/columnSorting/columnSorting.js +865 -0
- package/plugins/columnSorting/columnSorting.mjs +857 -0
- package/plugins/columnSorting/columnStatesManager.js +273 -0
- package/plugins/columnSorting/columnStatesManager.mjs +268 -0
- package/plugins/columnSorting/domHelpers.js +54 -0
- package/plugins/columnSorting/domHelpers.mjs +49 -0
- package/plugins/columnSorting/index.d.ts +1 -0
- package/plugins/columnSorting/index.js +8 -0
- package/plugins/columnSorting/index.mjs +1 -0
- package/plugins/columnSorting/rootComparator.js +52 -0
- package/plugins/columnSorting/rootComparator.mjs +48 -0
- package/plugins/columnSorting/sortFunction/checkbox.js +64 -0
- package/plugins/columnSorting/sortFunction/checkbox.mjs +58 -0
- package/plugins/columnSorting/sortFunction/date.js +61 -0
- package/plugins/columnSorting/sortFunction/date.mjs +54 -0
- package/plugins/columnSorting/sortFunction/default.js +65 -0
- package/plugins/columnSorting/sortFunction/default.mjs +59 -0
- package/plugins/columnSorting/sortFunction/numeric.js +49 -0
- package/plugins/columnSorting/sortFunction/numeric.mjs +43 -0
- package/plugins/columnSorting/sortService/engine.js +26 -0
- package/plugins/columnSorting/sortService/engine.mjs +18 -0
- package/plugins/columnSorting/sortService/index.js +13 -0
- package/plugins/columnSorting/sortService/index.mjs +3 -0
- package/plugins/columnSorting/sortService/registry.js +37 -0
- package/plugins/columnSorting/sortService/registry.mjs +30 -0
- package/plugins/columnSorting/utils.js +122 -0
- package/plugins/columnSorting/utils.mjs +110 -0
- package/plugins/columnSummary/columnSummary.d.ts +72 -0
- package/plugins/columnSummary/columnSummary.js +544 -0
- package/plugins/columnSummary/columnSummary.mjs +536 -0
- package/plugins/columnSummary/endpoints.js +557 -0
- package/plugins/columnSummary/endpoints.mjs +552 -0
- package/plugins/columnSummary/index.d.ts +1 -0
- package/plugins/columnSummary/index.js +8 -0
- package/plugins/columnSummary/index.mjs +1 -0
- package/plugins/columnSummary/utils.js +13 -0
- package/plugins/columnSummary/utils.mjs +9 -0
- package/plugins/comments/commentEditor.js +241 -0
- package/plugins/comments/commentEditor.mjs +236 -0
- package/plugins/comments/comments.d.ts +50 -0
- package/plugins/comments/comments.js +942 -0
- package/plugins/comments/comments.mjs +932 -0
- package/plugins/comments/displaySwitch.js +115 -0
- package/plugins/comments/displaySwitch.mjs +109 -0
- package/plugins/comments/index.d.ts +1 -0
- package/plugins/comments/index.js +8 -0
- package/plugins/comments/index.mjs +1 -0
- package/plugins/contextMenu/commandExecutor.js +113 -0
- package/plugins/contextMenu/commandExecutor.mjs +108 -0
- package/plugins/contextMenu/contextMenu.d.ts +65 -0
- package/plugins/contextMenu/contextMenu.js +445 -0
- package/plugins/contextMenu/contextMenu.mjs +437 -0
- package/plugins/contextMenu/cursor.js +126 -0
- package/plugins/contextMenu/cursor.mjs +121 -0
- package/plugins/contextMenu/index.d.ts +1 -0
- package/plugins/contextMenu/index.js +8 -0
- package/plugins/contextMenu/index.mjs +1 -0
- package/plugins/contextMenu/itemsFactory.js +136 -0
- package/plugins/contextMenu/itemsFactory.mjs +131 -0
- package/plugins/contextMenu/menu.js +1003 -0
- package/plugins/contextMenu/menu.mjs +997 -0
- package/plugins/contextMenu/predefinedItems/alignment.js +277 -0
- package/plugins/contextMenu/predefinedItems/alignment.mjs +259 -0
- package/plugins/contextMenu/predefinedItems/clearColumn.js +47 -0
- package/plugins/contextMenu/predefinedItems/clearColumn.mjs +29 -0
- package/plugins/contextMenu/predefinedItems/columnLeft.js +57 -0
- package/plugins/contextMenu/predefinedItems/columnLeft.mjs +39 -0
- package/plugins/contextMenu/predefinedItems/columnRight.js +55 -0
- package/plugins/contextMenu/predefinedItems/columnRight.mjs +37 -0
- package/plugins/contextMenu/predefinedItems/noItems.js +22 -0
- package/plugins/contextMenu/predefinedItems/noItems.mjs +16 -0
- package/plugins/contextMenu/predefinedItems/readOnly.js +69 -0
- package/plugins/contextMenu/predefinedItems/readOnly.mjs +51 -0
- package/plugins/contextMenu/predefinedItems/redo.js +42 -0
- package/plugins/contextMenu/predefinedItems/redo.mjs +24 -0
- package/plugins/contextMenu/predefinedItems/removeColumn.js +79 -0
- package/plugins/contextMenu/predefinedItems/removeColumn.mjs +68 -0
- package/plugins/contextMenu/predefinedItems/removeRow.js +78 -0
- package/plugins/contextMenu/predefinedItems/removeRow.mjs +67 -0
- package/plugins/contextMenu/predefinedItems/rowAbove.js +53 -0
- package/plugins/contextMenu/predefinedItems/rowAbove.mjs +35 -0
- package/plugins/contextMenu/predefinedItems/rowBelow.js +51 -0
- package/plugins/contextMenu/predefinedItems/rowBelow.mjs +33 -0
- package/plugins/contextMenu/predefinedItems/separator.js +16 -0
- package/plugins/contextMenu/predefinedItems/separator.mjs +10 -0
- package/plugins/contextMenu/predefinedItems/undo.js +42 -0
- package/plugins/contextMenu/predefinedItems/undo.mjs +24 -0
- package/plugins/contextMenu/predefinedItems.js +76 -0
- package/plugins/contextMenu/predefinedItems.mjs +57 -0
- package/plugins/contextMenu/utils.js +278 -0
- package/plugins/contextMenu/utils.mjs +261 -0
- package/plugins/copyPaste/clipboardData.js +29 -0
- package/plugins/copyPaste/clipboardData.mjs +25 -0
- package/plugins/copyPaste/contextMenuItem/copy.js +45 -0
- package/plugins/copyPaste/contextMenuItem/copy.mjs +29 -0
- package/plugins/copyPaste/contextMenuItem/cut.js +45 -0
- package/plugins/copyPaste/contextMenuItem/cut.mjs +29 -0
- package/plugins/copyPaste/copyPaste.d.ts +35 -0
- package/plugins/copyPaste/copyPaste.js +721 -0
- package/plugins/copyPaste/copyPaste.mjs +713 -0
- package/plugins/copyPaste/focusableElement.js +210 -0
- package/plugins/copyPaste/focusableElement.mjs +204 -0
- package/plugins/copyPaste/index.d.ts +1 -0
- package/plugins/copyPaste/index.js +8 -0
- package/plugins/copyPaste/index.mjs +1 -0
- package/plugins/copyPaste/pasteEvent.js +17 -0
- package/plugins/copyPaste/pasteEvent.mjs +12 -0
- package/plugins/customBorders/contextMenuItem/bottom.js +39 -0
- package/plugins/customBorders/contextMenuItem/bottom.mjs +23 -0
- package/plugins/customBorders/contextMenuItem/index.js +14 -0
- package/plugins/customBorders/contextMenuItem/index.mjs +6 -0
- package/plugins/customBorders/contextMenuItem/left.js +40 -0
- package/plugins/customBorders/contextMenuItem/left.mjs +24 -0
- package/plugins/customBorders/contextMenuItem/noBorders.js +36 -0
- package/plugins/customBorders/contextMenuItem/noBorders.mjs +20 -0
- package/plugins/customBorders/contextMenuItem/right.js +40 -0
- package/plugins/customBorders/contextMenuItem/right.mjs +24 -0
- package/plugins/customBorders/contextMenuItem/top.js +39 -0
- package/plugins/customBorders/contextMenuItem/top.mjs +23 -0
- package/plugins/customBorders/customBorders.d.ts +38 -0
- package/plugins/customBorders/customBorders.js +887 -0
- package/plugins/customBorders/customBorders.mjs +877 -0
- package/plugins/customBorders/index.d.ts +1 -0
- package/plugins/customBorders/index.js +8 -0
- package/plugins/customBorders/index.mjs +1 -0
- package/plugins/customBorders/utils.js +265 -0
- package/plugins/customBorders/utils.mjs +249 -0
- package/plugins/dragToScroll/dragToScroll.d.ts +15 -0
- package/plugins/dragToScroll/dragToScroll.js +335 -0
- package/plugins/dragToScroll/dragToScroll.mjs +327 -0
- package/plugins/dragToScroll/index.d.ts +1 -0
- package/plugins/dragToScroll/index.js +8 -0
- package/plugins/dragToScroll/index.mjs +1 -0
- package/plugins/dropdownMenu/dropdownMenu.d.ts +24 -0
- package/plugins/dropdownMenu/dropdownMenu.js +511 -0
- package/plugins/dropdownMenu/dropdownMenu.mjs +504 -0
- package/plugins/dropdownMenu/index.d.ts +1 -0
- package/plugins/dropdownMenu/index.js +8 -0
- package/plugins/dropdownMenu/index.mjs +1 -0
- package/plugins/exportFile/dataProvider.js +200 -0
- package/plugins/exportFile/dataProvider.mjs +195 -0
- package/plugins/exportFile/exportFile.d.ts +12 -0
- package/plugins/exportFile/exportFile.js +262 -0
- package/plugins/exportFile/exportFile.mjs +250 -0
- package/plugins/exportFile/index.d.ts +1 -0
- package/plugins/exportFile/index.js +8 -0
- package/plugins/exportFile/index.mjs +1 -0
- package/plugins/exportFile/typeFactory.js +30 -0
- package/plugins/exportFile/typeFactory.mjs +21 -0
- package/plugins/exportFile/types/_base.js +78 -0
- package/plugins/exportFile/types/_base.mjs +73 -0
- package/plugins/exportFile/types/csv.js +131 -0
- package/plugins/exportFile/types/csv.mjs +125 -0
- package/plugins/filters/component/_base.js +169 -0
- package/plugins/filters/component/_base.mjs +163 -0
- package/plugins/filters/component/actionBar.js +161 -0
- package/plugins/filters/component/actionBar.mjs +151 -0
- package/plugins/filters/component/condition.js +325 -0
- package/plugins/filters/component/condition.mjs +316 -0
- package/plugins/filters/component/operators.js +222 -0
- package/plugins/filters/component/operators.mjs +216 -0
- package/plugins/filters/component/value.js +278 -0
- package/plugins/filters/component/value.mjs +269 -0
- package/plugins/filters/condition/beginsWith.js +50 -0
- package/plugins/filters/condition/beginsWith.mjs +39 -0
- package/plugins/filters/condition/between.js +64 -0
- package/plugins/filters/condition/between.mjs +53 -0
- package/plugins/filters/condition/byValue.js +48 -0
- package/plugins/filters/condition/byValue.mjs +42 -0
- package/plugins/filters/condition/contains.js +50 -0
- package/plugins/filters/condition/contains.mjs +39 -0
- package/plugins/filters/condition/date/after.js +55 -0
- package/plugins/filters/condition/date/after.mjs +43 -0
- package/plugins/filters/condition/date/before.js +55 -0
- package/plugins/filters/condition/date/before.mjs +43 -0
- package/plugins/filters/condition/date/today.js +39 -0
- package/plugins/filters/condition/date/today.mjs +20 -0
- package/plugins/filters/condition/date/tomorrow.js +39 -0
- package/plugins/filters/condition/date/tomorrow.mjs +20 -0
- package/plugins/filters/condition/date/yesterday.js +39 -0
- package/plugins/filters/condition/date/yesterday.mjs +20 -0
- package/plugins/filters/condition/empty.js +35 -0
- package/plugins/filters/condition/empty.mjs +17 -0
- package/plugins/filters/condition/endsWith.js +50 -0
- package/plugins/filters/condition/endsWith.mjs +39 -0
- package/plugins/filters/condition/equal.js +49 -0
- package/plugins/filters/condition/equal.mjs +38 -0
- package/plugins/filters/condition/false.js +18 -0
- package/plugins/filters/condition/false.mjs +12 -0
- package/plugins/filters/condition/greaterThan.js +52 -0
- package/plugins/filters/condition/greaterThan.mjs +41 -0
- package/plugins/filters/condition/greaterThanOrEqual.js +52 -0
- package/plugins/filters/condition/greaterThanOrEqual.mjs +41 -0
- package/plugins/filters/condition/lessThan.js +52 -0
- package/plugins/filters/condition/lessThan.mjs +41 -0
- package/plugins/filters/condition/lessThanOrEqual.js +52 -0
- package/plugins/filters/condition/lessThanOrEqual.mjs +41 -0
- package/plugins/filters/condition/none.js +33 -0
- package/plugins/filters/condition/none.mjs +15 -0
- package/plugins/filters/condition/notBetween.js +36 -0
- package/plugins/filters/condition/notBetween.mjs +18 -0
- package/plugins/filters/condition/notContains.js +36 -0
- package/plugins/filters/condition/notContains.mjs +18 -0
- package/plugins/filters/condition/notEmpty.js +36 -0
- package/plugins/filters/condition/notEmpty.mjs +18 -0
- package/plugins/filters/condition/notEqual.js +36 -0
- package/plugins/filters/condition/notEqual.mjs +18 -0
- package/plugins/filters/condition/true.js +18 -0
- package/plugins/filters/condition/true.mjs +12 -0
- package/plugins/filters/conditionCollection.d.ts +32 -0
- package/plugins/filters/conditionCollection.js +343 -0
- package/plugins/filters/conditionCollection.mjs +337 -0
- package/plugins/filters/conditionRegisterer.js +61 -0
- package/plugins/filters/conditionRegisterer.mjs +53 -0
- package/plugins/filters/conditionUpdateObserver.d.ts +10 -0
- package/plugins/filters/conditionUpdateObserver.js +248 -0
- package/plugins/filters/conditionUpdateObserver.mjs +242 -0
- package/plugins/filters/constants.js +103 -0
- package/plugins/filters/constants.mjs +69 -0
- package/plugins/filters/dataFilter.js +98 -0
- package/plugins/filters/dataFilter.mjs +93 -0
- package/plugins/filters/filters.d.ts +56 -0
- package/plugins/filters/filters.js +1037 -0
- package/plugins/filters/filters.mjs +1026 -0
- package/plugins/filters/index.d.ts +1 -0
- package/plugins/filters/index.js +8 -0
- package/plugins/filters/index.mjs +1 -0
- package/plugins/filters/logicalOperationRegisterer.js +50 -0
- package/plugins/filters/logicalOperationRegisterer.mjs +42 -0
- package/plugins/filters/logicalOperations/conjunction.js +36 -0
- package/plugins/filters/logicalOperations/conjunction.mjs +18 -0
- package/plugins/filters/logicalOperations/disjunction.js +36 -0
- package/plugins/filters/logicalOperations/disjunction.mjs +18 -0
- package/plugins/filters/logicalOperations/disjunctionWithExtraCondition.js +40 -0
- package/plugins/filters/logicalOperations/disjunctionWithExtraCondition.mjs +22 -0
- package/plugins/filters/ui/_base.js +249 -0
- package/plugins/filters/ui/_base.mjs +231 -0
- package/plugins/filters/ui/input.js +140 -0
- package/plugins/filters/ui/input.mjs +134 -0
- package/plugins/filters/ui/link.js +86 -0
- package/plugins/filters/ui/link.mjs +80 -0
- package/plugins/filters/ui/multipleSelect.js +441 -0
- package/plugins/filters/ui/multipleSelect.mjs +434 -0
- package/plugins/filters/ui/radioInput.js +130 -0
- package/plugins/filters/ui/radioInput.mjs +124 -0
- package/plugins/filters/ui/select.js +269 -0
- package/plugins/filters/ui/select.mjs +261 -0
- package/plugins/filters/utils.js +143 -0
- package/plugins/filters/utils.mjs +134 -0
- package/plugins/formulas/engine/register.js +259 -0
- package/plugins/formulas/engine/register.mjs +247 -0
- package/plugins/formulas/engine/settings.js +115 -0
- package/plugins/formulas/engine/settings.mjs +107 -0
- package/plugins/formulas/formulas.d.ts +31 -0
- package/plugins/formulas/formulas.js +1229 -0
- package/plugins/formulas/formulas.mjs +1221 -0
- package/plugins/formulas/index.d.ts +1 -0
- package/plugins/formulas/index.js +8 -0
- package/plugins/formulas/index.mjs +1 -0
- package/plugins/formulas/utils.js +24 -0
- package/plugins/formulas/utils.mjs +19 -0
- package/plugins/hiddenColumns/contextMenuItem/hideColumn.js +76 -0
- package/plugins/hiddenColumns/contextMenuItem/hideColumn.mjs +67 -0
- package/plugins/hiddenColumns/contextMenuItem/showColumn.js +124 -0
- package/plugins/hiddenColumns/contextMenuItem/showColumn.mjs +115 -0
- package/plugins/hiddenColumns/hiddenColumns.d.ts +21 -0
- package/plugins/hiddenColumns/hiddenColumns.js +620 -0
- package/plugins/hiddenColumns/hiddenColumns.mjs +612 -0
- package/plugins/hiddenColumns/index.d.ts +1 -0
- package/plugins/hiddenColumns/index.js +8 -0
- package/plugins/hiddenColumns/index.mjs +1 -0
- package/plugins/hiddenRows/contextMenuItem/hideRow.js +76 -0
- package/plugins/hiddenRows/contextMenuItem/hideRow.mjs +67 -0
- package/plugins/hiddenRows/contextMenuItem/showRow.js +124 -0
- package/plugins/hiddenRows/contextMenuItem/showRow.mjs +115 -0
- package/plugins/hiddenRows/hiddenRows.d.ts +21 -0
- package/plugins/hiddenRows/hiddenRows.js +612 -0
- package/plugins/hiddenRows/hiddenRows.mjs +604 -0
- package/plugins/hiddenRows/index.d.ts +1 -0
- package/plugins/hiddenRows/index.js +8 -0
- package/plugins/hiddenRows/index.mjs +1 -0
- package/plugins/index.d.ts +111 -0
- package/plugins/index.js +115 -0
- package/plugins/index.mjs +75 -0
- package/plugins/manualColumnFreeze/contextMenuItem/freezeColumn.js +58 -0
- package/plugins/manualColumnFreeze/contextMenuItem/freezeColumn.mjs +49 -0
- package/plugins/manualColumnFreeze/contextMenuItem/unfreezeColumn.js +58 -0
- package/plugins/manualColumnFreeze/contextMenuItem/unfreezeColumn.mjs +49 -0
- package/plugins/manualColumnFreeze/index.d.ts +1 -0
- package/plugins/manualColumnFreeze/index.js +8 -0
- package/plugins/manualColumnFreeze/index.mjs +1 -0
- package/plugins/manualColumnFreeze/manualColumnFreeze.d.ts +11 -0
- package/plugins/manualColumnFreeze/manualColumnFreeze.js +250 -0
- package/plugins/manualColumnFreeze/manualColumnFreeze.mjs +242 -0
- package/plugins/manualColumnMove/index.d.ts +1 -0
- package/plugins/manualColumnMove/index.js +8 -0
- package/plugins/manualColumnMove/index.mjs +1 -0
- package/plugins/manualColumnMove/manualColumnMove.d.ts +14 -0
- package/plugins/manualColumnMove/manualColumnMove.js +775 -0
- package/plugins/manualColumnMove/manualColumnMove.mjs +767 -0
- package/plugins/manualColumnMove/ui/_base.js +209 -0
- package/plugins/manualColumnMove/ui/_base.mjs +204 -0
- package/plugins/manualColumnMove/ui/backlight.js +60 -0
- package/plugins/manualColumnMove/ui/backlight.mjs +54 -0
- package/plugins/manualColumnMove/ui/guideline.js +60 -0
- package/plugins/manualColumnMove/ui/guideline.mjs +54 -0
- package/plugins/manualColumnResize/index.d.ts +1 -0
- package/plugins/manualColumnResize/index.js +8 -0
- package/plugins/manualColumnResize/index.mjs +1 -0
- package/plugins/manualColumnResize/manualColumnResize.d.ts +30 -0
- package/plugins/manualColumnResize/manualColumnResize.js +690 -0
- package/plugins/manualColumnResize/manualColumnResize.mjs +680 -0
- package/plugins/manualRowMove/index.d.ts +1 -0
- package/plugins/manualRowMove/index.js +8 -0
- package/plugins/manualRowMove/index.mjs +1 -0
- package/plugins/manualRowMove/manualRowMove.d.ts +14 -0
- package/plugins/manualRowMove/manualRowMove.js +757 -0
- package/plugins/manualRowMove/manualRowMove.mjs +749 -0
- package/plugins/manualRowMove/ui/_base.js +196 -0
- package/plugins/manualRowMove/ui/_base.mjs +191 -0
- package/plugins/manualRowMove/ui/backlight.js +60 -0
- package/plugins/manualRowMove/ui/backlight.mjs +54 -0
- package/plugins/manualRowMove/ui/guideline.js +60 -0
- package/plugins/manualRowMove/ui/guideline.mjs +54 -0
- package/plugins/manualRowResize/index.d.ts +1 -0
- package/plugins/manualRowResize/index.js +8 -0
- package/plugins/manualRowResize/index.mjs +1 -0
- package/plugins/manualRowResize/manualRowResize.d.ts +29 -0
- package/plugins/manualRowResize/manualRowResize.js +652 -0
- package/plugins/manualRowResize/manualRowResize.mjs +642 -0
- package/plugins/mergeCells/calculations/autofill.js +464 -0
- package/plugins/mergeCells/calculations/autofill.mjs +459 -0
- package/plugins/mergeCells/calculations/selection.js +204 -0
- package/plugins/mergeCells/calculations/selection.mjs +199 -0
- package/plugins/mergeCells/cellCoords.js +347 -0
- package/plugins/mergeCells/cellCoords.mjs +342 -0
- package/plugins/mergeCells/cellsCollection.js +344 -0
- package/plugins/mergeCells/cellsCollection.mjs +338 -0
- package/plugins/mergeCells/contextMenuItem/toggleMerge.js +55 -0
- package/plugins/mergeCells/contextMenuItem/toggleMerge.mjs +38 -0
- package/plugins/mergeCells/index.d.ts +1 -0
- package/plugins/mergeCells/index.js +8 -0
- package/plugins/mergeCells/index.mjs +1 -0
- package/plugins/mergeCells/mergeCells.d.ts +22 -0
- package/plugins/mergeCells/mergeCells.js +1290 -0
- package/plugins/mergeCells/mergeCells.mjs +1282 -0
- package/plugins/mergeCells/utils.js +30 -0
- package/plugins/mergeCells/utils.mjs +26 -0
- package/plugins/multiColumnSorting/domHelpers.js +44 -0
- package/plugins/multiColumnSorting/domHelpers.mjs +39 -0
- package/plugins/multiColumnSorting/index.d.ts +1 -0
- package/plugins/multiColumnSorting/index.js +8 -0
- package/plugins/multiColumnSorting/index.mjs +1 -0
- package/plugins/multiColumnSorting/multiColumnSorting.d.ts +8 -0
- package/plugins/multiColumnSorting/multiColumnSorting.js +336 -0
- package/plugins/multiColumnSorting/multiColumnSorting.mjs +329 -0
- package/plugins/multiColumnSorting/rootComparator.js +55 -0
- package/plugins/multiColumnSorting/rootComparator.mjs +51 -0
- package/plugins/multiColumnSorting/utils.js +16 -0
- package/plugins/multiColumnSorting/utils.mjs +12 -0
- package/plugins/multipleSelectionHandles/index.d.ts +1 -0
- package/plugins/multipleSelectionHandles/index.js +8 -0
- package/plugins/multipleSelectionHandles/index.mjs +1 -0
- package/plugins/multipleSelectionHandles/multipleSelectionHandles.d.ts +21 -0
- package/plugins/multipleSelectionHandles/multipleSelectionHandles.js +394 -0
- package/plugins/multipleSelectionHandles/multipleSelectionHandles.mjs +386 -0
- package/plugins/nestedHeaders/index.d.ts +1 -0
- package/plugins/nestedHeaders/index.js +8 -0
- package/plugins/nestedHeaders/index.mjs +1 -0
- package/plugins/nestedHeaders/nestedHeaders.d.ts +17 -0
- package/plugins/nestedHeaders/nestedHeaders.js +666 -0
- package/plugins/nestedHeaders/nestedHeaders.mjs +658 -0
- package/plugins/nestedHeaders/stateManager/headersTree.js +288 -0
- package/plugins/nestedHeaders/stateManager/headersTree.mjs +283 -0
- package/plugins/nestedHeaders/stateManager/index.js +417 -0
- package/plugins/nestedHeaders/stateManager/index.mjs +412 -0
- package/plugins/nestedHeaders/stateManager/matrixGenerator.js +102 -0
- package/plugins/nestedHeaders/stateManager/matrixGenerator.mjs +99 -0
- package/plugins/nestedHeaders/stateManager/nodeModifiers/collapse.js +98 -0
- package/plugins/nestedHeaders/stateManager/nodeModifiers/collapse.mjs +94 -0
- package/plugins/nestedHeaders/stateManager/nodeModifiers/expand.js +95 -0
- package/plugins/nestedHeaders/stateManager/nodeModifiers/expand.mjs +91 -0
- package/plugins/nestedHeaders/stateManager/nodeModifiers/hideColumn.js +54 -0
- package/plugins/nestedHeaders/stateManager/nodeModifiers/hideColumn.mjs +50 -0
- package/plugins/nestedHeaders/stateManager/nodeModifiers/index.js +40 -0
- package/plugins/nestedHeaders/stateManager/nodeModifiers/index.mjs +35 -0
- package/plugins/nestedHeaders/stateManager/nodeModifiers/showColumn.js +55 -0
- package/plugins/nestedHeaders/stateManager/nodeModifiers/showColumn.mjs +51 -0
- package/plugins/nestedHeaders/stateManager/nodeModifiers/utils/tree.js +61 -0
- package/plugins/nestedHeaders/stateManager/nodeModifiers/utils/tree.mjs +55 -0
- package/plugins/nestedHeaders/stateManager/settingsNormalizer.js +122 -0
- package/plugins/nestedHeaders/stateManager/settingsNormalizer.mjs +119 -0
- package/plugins/nestedHeaders/stateManager/sourceSettings.js +250 -0
- package/plugins/nestedHeaders/stateManager/sourceSettings.mjs +245 -0
- package/plugins/nestedHeaders/stateManager/utils.js +75 -0
- package/plugins/nestedHeaders/stateManager/utils.mjs +70 -0
- package/plugins/nestedHeaders/utils/ghostTable.js +167 -0
- package/plugins/nestedHeaders/utils/ghostTable.mjs +162 -0
- package/plugins/nestedRows/data/dataManager.js +809 -0
- package/plugins/nestedRows/data/dataManager.mjs +804 -0
- package/plugins/nestedRows/index.d.ts +1 -0
- package/plugins/nestedRows/index.js +8 -0
- package/plugins/nestedRows/index.mjs +1 -0
- package/plugins/nestedRows/nestedRows.d.ts +12 -0
- package/plugins/nestedRows/nestedRows.js +592 -0
- package/plugins/nestedRows/nestedRows.mjs +584 -0
- package/plugins/nestedRows/ui/_base.js +28 -0
- package/plugins/nestedRows/ui/_base.mjs +23 -0
- package/plugins/nestedRows/ui/collapsing.js +562 -0
- package/plugins/nestedRows/ui/collapsing.mjs +556 -0
- package/plugins/nestedRows/ui/contextMenu.js +147 -0
- package/plugins/nestedRows/ui/contextMenu.mjs +138 -0
- package/plugins/nestedRows/ui/headers.js +157 -0
- package/plugins/nestedRows/ui/headers.mjs +151 -0
- package/plugins/nestedRows/utils/rowMoveController.js +331 -0
- package/plugins/nestedRows/utils/rowMoveController.mjs +327 -0
- package/plugins/persistentState/index.d.ts +1 -0
- package/plugins/persistentState/index.js +8 -0
- package/plugins/persistentState/index.mjs +1 -0
- package/plugins/persistentState/persistentState.d.ts +13 -0
- package/plugins/persistentState/persistentState.js +207 -0
- package/plugins/persistentState/persistentState.mjs +199 -0
- package/plugins/persistentState/storage.js +138 -0
- package/plugins/persistentState/storage.mjs +133 -0
- package/plugins/registry.d.ts +9 -0
- package/plugins/registry.js +150 -0
- package/plugins/registry.mjs +146 -0
- package/plugins/search/index.d.ts +1 -0
- package/plugins/search/index.js +8 -0
- package/plugins/search/index.mjs +1 -0
- package/plugins/search/search.d.ts +28 -0
- package/plugins/search/search.js +377 -0
- package/plugins/search/search.mjs +370 -0
- package/plugins/touchScroll/index.d.ts +1 -0
- package/plugins/touchScroll/index.js +8 -0
- package/plugins/touchScroll/index.mjs +1 -0
- package/plugins/touchScroll/touchScroll.d.ts +13 -0
- package/plugins/touchScroll/touchScroll.js +250 -0
- package/plugins/touchScroll/touchScroll.mjs +243 -0
- package/plugins/trimRows/index.d.ts +1 -0
- package/plugins/trimRows/index.js +8 -0
- package/plugins/trimRows/index.mjs +1 -0
- package/plugins/trimRows/trimRows.d.ts +17 -0
- package/plugins/trimRows/trimRows.js +393 -0
- package/plugins/trimRows/trimRows.mjs +386 -0
- package/plugins/undoRedo/index.d.ts +1 -0
- package/plugins/undoRedo/index.js +18 -0
- package/plugins/undoRedo/index.mjs +2 -0
- package/plugins/undoRedo/undoRedo.d.ts +49 -0
- package/plugins/undoRedo/undoRedo.js +935 -0
- package/plugins/undoRedo/undoRedo.mjs +928 -0
- package/registry.d.ts +6 -0
- package/registry.js +35 -0
- package/registry.mjs +26 -0
- package/renderers/autocompleteRenderer/autocompleteRenderer.d.ts +5 -0
- package/renderers/autocompleteRenderer/autocompleteRenderer.js +59 -0
- package/renderers/autocompleteRenderer/autocompleteRenderer.mjs +52 -0
- package/renderers/autocompleteRenderer/index.d.ts +1 -0
- package/renderers/autocompleteRenderer/index.js +7 -0
- package/renderers/autocompleteRenderer/index.mjs +1 -0
- package/renderers/base.d.ts +3 -0
- package/renderers/baseRenderer/baseRenderer.d.ts +5 -0
- package/renderers/baseRenderer/baseRenderer.js +46 -0
- package/renderers/baseRenderer/baseRenderer.mjs +39 -0
- package/renderers/baseRenderer/index.d.ts +1 -0
- package/renderers/baseRenderer/index.js +7 -0
- package/renderers/baseRenderer/index.mjs +1 -0
- package/renderers/checkboxRenderer/checkboxRenderer.d.ts +5 -0
- package/renderers/checkboxRenderer/checkboxRenderer.js +398 -0
- package/renderers/checkboxRenderer/checkboxRenderer.mjs +391 -0
- package/renderers/checkboxRenderer/index.d.ts +1 -0
- package/renderers/checkboxRenderer/index.js +7 -0
- package/renderers/checkboxRenderer/index.mjs +1 -0
- package/renderers/htmlRenderer/htmlRenderer.d.ts +5 -0
- package/renderers/htmlRenderer/htmlRenderer.js +25 -0
- package/renderers/htmlRenderer/htmlRenderer.mjs +19 -0
- package/renderers/htmlRenderer/index.d.ts +1 -0
- package/renderers/htmlRenderer/index.js +7 -0
- package/renderers/htmlRenderer/index.mjs +1 -0
- package/renderers/index.d.ts +45 -0
- package/renderers/index.js +48 -0
- package/renderers/index.mjs +24 -0
- package/renderers/numericRenderer/index.d.ts +1 -0
- package/renderers/numericRenderer/index.js +7 -0
- package/renderers/numericRenderer/index.mjs +1 -0
- package/renderers/numericRenderer/numericRenderer.d.ts +5 -0
- package/renderers/numericRenderer/numericRenderer.js +57 -0
- package/renderers/numericRenderer/numericRenderer.mjs +50 -0
- package/renderers/passwordRenderer/index.d.ts +1 -0
- package/renderers/passwordRenderer/index.js +7 -0
- package/renderers/passwordRenderer/index.mjs +1 -0
- package/renderers/passwordRenderer/passwordRenderer.d.ts +5 -0
- package/renderers/passwordRenderer/passwordRenderer.js +32 -0
- package/renderers/passwordRenderer/passwordRenderer.mjs +26 -0
- package/renderers/registry.d.ts +18 -0
- package/renderers/registry.js +48 -0
- package/renderers/registry.mjs +38 -0
- package/renderers/textRenderer/index.d.ts +1 -0
- package/renderers/textRenderer/index.js +7 -0
- package/renderers/textRenderer/index.mjs +1 -0
- package/renderers/textRenderer/textRenderer.d.ts +5 -0
- package/renderers/textRenderer/textRenderer.js +48 -0
- package/renderers/textRenderer/textRenderer.mjs +42 -0
- package/renderers/timeRenderer/index.d.ts +1 -0
- package/renderers/timeRenderer/index.js +7 -0
- package/renderers/timeRenderer/index.mjs +1 -0
- package/renderers/timeRenderer/timeRenderer.d.ts +5 -0
- package/renderers/timeRenderer/timeRenderer.js +26 -0
- package/renderers/timeRenderer/timeRenderer.mjs +20 -0
- package/selection/highlight/constants.js +16 -0
- package/selection/highlight/constants.mjs +6 -0
- package/selection/highlight/highlight.js +330 -0
- package/selection/highlight/highlight.mjs +325 -0
- package/selection/highlight/types/activeHeader.js +38 -0
- package/selection/highlight/types/activeHeader.mjs +32 -0
- package/selection/highlight/types/area.js +49 -0
- package/selection/highlight/types/area.mjs +43 -0
- package/selection/highlight/types/cell.js +46 -0
- package/selection/highlight/types/cell.mjs +40 -0
- package/selection/highlight/types/customSelection.js +41 -0
- package/selection/highlight/types/customSelection.mjs +35 -0
- package/selection/highlight/types/fill.js +41 -0
- package/selection/highlight/types/fill.mjs +35 -0
- package/selection/highlight/types/header.js +49 -0
- package/selection/highlight/types/header.mjs +43 -0
- package/selection/highlight/types/index.js +43 -0
- package/selection/highlight/types/index.mjs +39 -0
- package/selection/highlight/visualSelection.js +277 -0
- package/selection/highlight/visualSelection.mjs +272 -0
- package/selection/index.d.ts +5 -0
- package/selection/index.js +30 -0
- package/selection/index.mjs +6 -0
- package/selection/mouseEventHandler.js +135 -0
- package/selection/mouseEventHandler.mjs +129 -0
- package/selection/range.js +173 -0
- package/selection/range.mjs +168 -0
- package/selection/selection.js +802 -0
- package/selection/selection.mjs +796 -0
- package/selection/transformation.js +169 -0
- package/selection/transformation.mjs +163 -0
- package/selection/utils.js +256 -0
- package/selection/utils.mjs +242 -0
- package/settings.d.ts +210 -0
- package/shortcuts/context.d.ts +20 -0
- package/shortcuts/context.js +241 -0
- package/shortcuts/context.mjs +236 -0
- package/shortcuts/index.d.ts +1 -0
- package/shortcuts/index.js +6 -0
- package/shortcuts/index.mjs +1 -0
- package/shortcuts/keyObserver.js +58 -0
- package/shortcuts/keyObserver.mjs +54 -0
- package/shortcuts/manager.d.ts +10 -0
- package/shortcuts/manager.js +165 -0
- package/shortcuts/manager.mjs +159 -0
- package/shortcuts/recorder.js +165 -0
- package/shortcuts/recorder.mjs +161 -0
- package/shortcuts/utils.js +58 -0
- package/shortcuts/utils.mjs +51 -0
- package/tableView.js +1313 -0
- package/tableView.mjs +1307 -0
- package/translations/changesObservable/observable.js +175 -0
- package/translations/changesObservable/observable.mjs +170 -0
- package/translations/changesObservable/observer.js +100 -0
- package/translations/changesObservable/observer.mjs +94 -0
- package/translations/changesObservable/utils.js +50 -0
- package/translations/changesObservable/utils.mjs +46 -0
- package/translations/index.d.ts +1 -0
- package/translations/index.js +29 -0
- package/translations/index.mjs +4 -0
- package/translations/indexMapper.d.ts +48 -0
- package/translations/indexMapper.js +865 -0
- package/translations/indexMapper.mjs +859 -0
- package/translations/mapCollections/aggregatedCollection.js +139 -0
- package/translations/mapCollections/aggregatedCollection.mjs +134 -0
- package/translations/mapCollections/index.js +18 -0
- package/translations/mapCollections/index.mjs +2 -0
- package/translations/mapCollections/mapCollection.js +164 -0
- package/translations/mapCollections/mapCollection.mjs +156 -0
- package/translations/maps/hidingMap.js +63 -0
- package/translations/maps/hidingMap.mjs +58 -0
- package/translations/maps/index.js +59 -0
- package/translations/maps/index.mjs +29 -0
- package/translations/maps/indexMap.d.ts +10 -0
- package/translations/maps/indexMap.js +203 -0
- package/translations/maps/indexMap.mjs +197 -0
- package/translations/maps/indexesSequence.js +82 -0
- package/translations/maps/indexesSequence.mjs +77 -0
- package/translations/maps/linkedPhysicalIndexToValueMap.js +216 -0
- package/translations/maps/linkedPhysicalIndexToValueMap.mjs +211 -0
- package/translations/maps/physicalIndexToValueMap.js +76 -0
- package/translations/maps/physicalIndexToValueMap.mjs +71 -0
- package/translations/maps/trimmingMap.js +63 -0
- package/translations/maps/trimmingMap.mjs +58 -0
- package/translations/maps/utils/actionsOnIndexes.js +42 -0
- package/translations/maps/utils/actionsOnIndexes.mjs +37 -0
- package/translations/maps/utils/index.js +28 -0
- package/translations/maps/utils/index.mjs +22 -0
- package/translations/maps/utils/indexesSequence.js +52 -0
- package/translations/maps/utils/indexesSequence.mjs +47 -0
- package/translations/maps/utils/physicallyIndexed.js +61 -0
- package/translations/maps/utils/physicallyIndexed.mjs +56 -0
- package/utils/dataStructures/linkedList.js +263 -0
- package/utils/dataStructures/linkedList.mjs +258 -0
- package/utils/dataStructures/priorityMap.js +106 -0
- package/utils/dataStructures/priorityMap.mjs +99 -0
- package/utils/dataStructures/queue.js +83 -0
- package/utils/dataStructures/queue.mjs +78 -0
- package/utils/dataStructures/stack.js +83 -0
- package/utils/dataStructures/stack.mjs +78 -0
- package/utils/dataStructures/tree.js +254 -0
- package/utils/dataStructures/tree.mjs +246 -0
- package/utils/dataStructures/uniqueMap.js +144 -0
- package/utils/dataStructures/uniqueMap.mjs +140 -0
- package/utils/dataStructures/uniqueSet.js +78 -0
- package/utils/dataStructures/uniqueSet.mjs +74 -0
- package/utils/ghostTable.js +536 -0
- package/utils/ghostTable.mjs +531 -0
- package/utils/interval.js +134 -0
- package/utils/interval.mjs +129 -0
- package/utils/parseTable.d.ts +5 -0
- package/utils/parseTable.js +305 -0
- package/utils/parseTable.mjs +299 -0
- package/utils/rootInstance.js +48 -0
- package/utils/rootInstance.mjs +38 -0
- package/utils/samplesGenerator.js +210 -0
- package/utils/samplesGenerator.mjs +205 -0
- package/utils/staticRegister.js +92 -0
- package/utils/staticRegister.mjs +86 -0
- package/validators/autocompleteValidator/autocompleteValidator.d.ts +5 -0
- package/validators/autocompleteValidator/autocompleteValidator.js +56 -0
- package/validators/autocompleteValidator/autocompleteValidator.mjs +50 -0
- package/validators/autocompleteValidator/index.d.ts +1 -0
- package/validators/autocompleteValidator/index.js +7 -0
- package/validators/autocompleteValidator/index.mjs +1 -0
- package/validators/base.d.ts +6 -0
- package/validators/dateValidator/dateValidator.d.ts +5 -0
- package/validators/dateValidator/dateValidator.js +77 -0
- package/validators/dateValidator/dateValidator.mjs +69 -0
- package/validators/dateValidator/index.d.ts +1 -0
- package/validators/dateValidator/index.js +8 -0
- package/validators/dateValidator/index.mjs +1 -0
- package/validators/index.d.ts +33 -0
- package/validators/index.js +32 -0
- package/validators/index.mjs +16 -0
- package/validators/numericValidator/index.d.ts +1 -0
- package/validators/numericValidator/index.js +7 -0
- package/validators/numericValidator/index.mjs +1 -0
- package/validators/numericValidator/numericValidator.d.ts +5 -0
- package/validators/numericValidator/numericValidator.js +30 -0
- package/validators/numericValidator/numericValidator.mjs +24 -0
- package/validators/registry.d.ts +18 -0
- package/validators/registry.js +48 -0
- package/validators/registry.mjs +38 -0
- package/validators/timeValidator/index.d.ts +1 -0
- package/validators/timeValidator/index.js +7 -0
- package/validators/timeValidator/index.mjs +1 -0
- package/validators/timeValidator/timeValidator.d.ts +5 -0
- package/validators/timeValidator/timeValidator.js +66 -0
- package/validators/timeValidator/timeValidator.mjs +60 -0
@@ -0,0 +1,1026 @@
|
|
1
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
2
|
+
import "core-js/modules/es.object.set-prototype-of.js";
|
3
|
+
import "core-js/modules/es.object.get-prototype-of.js";
|
4
|
+
import "core-js/modules/es.reflect.construct.js";
|
5
|
+
import "core-js/modules/es.reflect.get.js";
|
6
|
+
import "core-js/modules/es.object.get-own-property-descriptor.js";
|
7
|
+
import "core-js/modules/es.symbol.js";
|
8
|
+
import "core-js/modules/es.symbol.description.js";
|
9
|
+
import "core-js/modules/es.symbol.iterator.js";
|
10
|
+
import "core-js/modules/es.array.slice.js";
|
11
|
+
import "core-js/modules/es.regexp.exec.js";
|
12
|
+
import "core-js/modules/es.object.freeze.js";
|
13
|
+
var _templateObject;
|
14
|
+
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
15
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
16
|
+
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
17
|
+
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
18
|
+
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
|
19
|
+
function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"]; if (_i == null) return; var _arr = []; var _n = true; var _d = false; var _s, _e; try { for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
|
20
|
+
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
21
|
+
import "core-js/modules/es.array.iterator.js";
|
22
|
+
import "core-js/modules/es.map.js";
|
23
|
+
import "core-js/modules/es.object.to-string.js";
|
24
|
+
import "core-js/modules/es.string.iterator.js";
|
25
|
+
import "core-js/modules/web.dom-collections.iterator.js";
|
26
|
+
import "core-js/modules/web.dom-collections.for-each.js";
|
27
|
+
import "core-js/modules/es.array.filter.js";
|
28
|
+
import "core-js/modules/es.array.from.js";
|
29
|
+
import "core-js/modules/es.function.name.js";
|
30
|
+
import "core-js/modules/es.array.concat.js";
|
31
|
+
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
32
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
33
|
+
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
34
|
+
function _get() { if (typeof Reflect !== "undefined" && Reflect.get) { _get = Reflect.get.bind(); } else { _get = function _get(target, property, receiver) { var base = _superPropBase(target, property); if (!base) return; var desc = Object.getOwnPropertyDescriptor(base, property); if (desc.get) { return desc.get.call(arguments.length < 3 ? target : receiver); } return desc.value; }; } return _get.apply(this, arguments); }
|
35
|
+
function _superPropBase(object, property) { while (!Object.prototype.hasOwnProperty.call(object, property)) { object = _getPrototypeOf(object); if (object === null) break; } return object; }
|
36
|
+
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
37
|
+
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
38
|
+
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
39
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
|
40
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
41
|
+
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
42
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
43
|
+
import { BasePlugin } from "../base/index.mjs";
|
44
|
+
import { arrayEach, arrayMap } from "../../helpers/array.mjs";
|
45
|
+
import { toSingleLine } from "../../helpers/templateLiteralTag.mjs";
|
46
|
+
import { warn } from "../../helpers/console.mjs";
|
47
|
+
import { rangeEach } from "../../helpers/number.mjs";
|
48
|
+
import EventManager from "../../eventManager.mjs";
|
49
|
+
import { addClass, removeClass } from "../../helpers/dom/element.mjs";
|
50
|
+
import { SEPARATOR } from "../contextMenu/predefinedItems.mjs";
|
51
|
+
import * as constants from "../../i18n/constants.mjs";
|
52
|
+
import ConditionComponent from "./component/condition.mjs";
|
53
|
+
import OperatorsComponent from "./component/operators.mjs";
|
54
|
+
import ValueComponent from "./component/value.mjs";
|
55
|
+
import ActionBarComponent from "./component/actionBar.mjs";
|
56
|
+
import ConditionCollection from "./conditionCollection.mjs";
|
57
|
+
import DataFilter from "./dataFilter.mjs";
|
58
|
+
import ConditionUpdateObserver from "./conditionUpdateObserver.mjs";
|
59
|
+
import { createArrayAssertion, toEmptyString, unifyColumnValues } from "./utils.mjs";
|
60
|
+
import { CONDITION_NONE, CONDITION_BY_VALUE, OPERATION_AND, OPERATION_OR, OPERATION_OR_THEN_VARIABLE } from "./constants.mjs";
|
61
|
+
import { TrimmingMap } from "../../translations/index.mjs";
|
62
|
+
export var PLUGIN_KEY = 'filters';
|
63
|
+
export var PLUGIN_PRIORITY = 250;
|
64
|
+
|
65
|
+
/**
|
66
|
+
* @plugin Filters
|
67
|
+
* @class Filters
|
68
|
+
*
|
69
|
+
* @description
|
70
|
+
* The plugin allows filtering the table data either by the built-in component or with the API.
|
71
|
+
*
|
72
|
+
* See [the filtering demo](@/guides/columns/column-filter.md) for examples.
|
73
|
+
*
|
74
|
+
* @example
|
75
|
+
* ::: only-for javascript
|
76
|
+
* ```js
|
77
|
+
* const container = document.getElementById('example');
|
78
|
+
* const hot = new Handsontable(container, {
|
79
|
+
* data: getData(),
|
80
|
+
* colHeaders: true,
|
81
|
+
* rowHeaders: true,
|
82
|
+
* dropdownMenu: true,
|
83
|
+
* filters: true
|
84
|
+
* });
|
85
|
+
* ```
|
86
|
+
* :::
|
87
|
+
*
|
88
|
+
* ::: only-for react
|
89
|
+
* ```jsx
|
90
|
+
* <HotTable
|
91
|
+
* data={getData()}
|
92
|
+
* colHeaders={true}
|
93
|
+
* rowHeaders={true}
|
94
|
+
* dropdownMenu={true}
|
95
|
+
* filters={true}
|
96
|
+
* />
|
97
|
+
* ```
|
98
|
+
* :::
|
99
|
+
*/
|
100
|
+
export var Filters = /*#__PURE__*/function (_BasePlugin) {
|
101
|
+
_inherits(Filters, _BasePlugin);
|
102
|
+
var _super = _createSuper(Filters);
|
103
|
+
function Filters(hotInstance) {
|
104
|
+
var _this;
|
105
|
+
_classCallCheck(this, Filters);
|
106
|
+
_this = _super.call(this, hotInstance);
|
107
|
+
/**
|
108
|
+
* Instance of {@link EventManager}.
|
109
|
+
*
|
110
|
+
* @private
|
111
|
+
* @type {EventManager}
|
112
|
+
*/
|
113
|
+
_this.eventManager = new EventManager(_assertThisInitialized(_this));
|
114
|
+
/**
|
115
|
+
* Instance of {@link DropdownMenu}.
|
116
|
+
*
|
117
|
+
* @private
|
118
|
+
* @type {DropdownMenu}
|
119
|
+
*/
|
120
|
+
_this.dropdownMenuPlugin = null;
|
121
|
+
/**
|
122
|
+
* Instance of {@link ConditionCollection}.
|
123
|
+
*
|
124
|
+
* @private
|
125
|
+
* @type {ConditionCollection}
|
126
|
+
*/
|
127
|
+
_this.conditionCollection = null;
|
128
|
+
/**
|
129
|
+
* Instance of {@link ConditionUpdateObserver}.
|
130
|
+
*
|
131
|
+
* @private
|
132
|
+
* @type {ConditionUpdateObserver}
|
133
|
+
*/
|
134
|
+
_this.conditionUpdateObserver = null;
|
135
|
+
/**
|
136
|
+
* Map, where key is component identifier and value represent `BaseComponent` element or it derivatives.
|
137
|
+
*
|
138
|
+
* @private
|
139
|
+
* @type {Map}
|
140
|
+
*/
|
141
|
+
_this.components = new Map([['filter_by_condition', null], ['filter_operators', null], ['filter_by_condition2', null], ['filter_by_value', null], ['filter_action_bar', null]]);
|
142
|
+
/**
|
143
|
+
* Object containing information about last selected column physical and visual index for added filter conditions.
|
144
|
+
*
|
145
|
+
* @private
|
146
|
+
* @type {object}
|
147
|
+
* @default null
|
148
|
+
*/
|
149
|
+
_this.lastSelectedColumn = null;
|
150
|
+
/**
|
151
|
+
* Map of skipped rows by plugin.
|
152
|
+
*
|
153
|
+
* @private
|
154
|
+
* @type {null|TrimmingMap}
|
155
|
+
*/
|
156
|
+
_this.filtersRowsMap = null;
|
157
|
+
|
158
|
+
// One listener for the enable/disable functionality
|
159
|
+
_this.hot.addHook('afterGetColHeader', function (col, TH) {
|
160
|
+
return _this.onAfterGetColHeader(col, TH);
|
161
|
+
});
|
162
|
+
return _this;
|
163
|
+
}
|
164
|
+
|
165
|
+
/**
|
166
|
+
* Checks if the plugin is enabled in the handsontable settings. This method is executed in {@link Hooks#beforeInit}
|
167
|
+
* hook and if it returns `true` then the {@link Filters#enablePlugin} method is called.
|
168
|
+
*
|
169
|
+
* @returns {boolean}
|
170
|
+
*/
|
171
|
+
_createClass(Filters, [{
|
172
|
+
key: "isEnabled",
|
173
|
+
value: function isEnabled() {
|
174
|
+
/* eslint-disable no-unneeded-ternary */
|
175
|
+
return this.hot.getSettings()[PLUGIN_KEY] ? true : false;
|
176
|
+
}
|
177
|
+
|
178
|
+
/**
|
179
|
+
* Enables the plugin functionality for this Handsontable instance.
|
180
|
+
*/
|
181
|
+
}, {
|
182
|
+
key: "enablePlugin",
|
183
|
+
value: function enablePlugin() {
|
184
|
+
var _this2 = this;
|
185
|
+
if (this.enabled) {
|
186
|
+
return;
|
187
|
+
}
|
188
|
+
this.filtersRowsMap = this.hot.rowIndexMapper.registerMap(this.pluginName, new TrimmingMap());
|
189
|
+
this.dropdownMenuPlugin = this.hot.getPlugin('dropdownMenu');
|
190
|
+
var dropdownSettings = this.hot.getSettings().dropdownMenu;
|
191
|
+
var menuContainer = dropdownSettings && dropdownSettings.uiContainer || this.hot.rootDocument.body;
|
192
|
+
var addConfirmationHooks = function addConfirmationHooks(component) {
|
193
|
+
component.addLocalHook('accept', function () {
|
194
|
+
return _this2.onActionBarSubmit('accept');
|
195
|
+
});
|
196
|
+
component.addLocalHook('cancel', function () {
|
197
|
+
return _this2.onActionBarSubmit('cancel');
|
198
|
+
});
|
199
|
+
component.addLocalHook('change', function (command) {
|
200
|
+
return _this2.onComponentChange(component, command);
|
201
|
+
});
|
202
|
+
return component;
|
203
|
+
};
|
204
|
+
var filterByConditionLabel = function filterByConditionLabel() {
|
205
|
+
return "".concat(_this2.hot.getTranslatedPhrase(constants.FILTERS_DIVS_FILTER_BY_CONDITION), ":");
|
206
|
+
};
|
207
|
+
var filterValueLabel = function filterValueLabel() {
|
208
|
+
return "".concat(_this2.hot.getTranslatedPhrase(constants.FILTERS_DIVS_FILTER_BY_VALUE), ":");
|
209
|
+
};
|
210
|
+
if (!this.components.get('filter_by_condition')) {
|
211
|
+
var conditionComponent = new ConditionComponent(this.hot, {
|
212
|
+
id: 'filter_by_condition',
|
213
|
+
name: filterByConditionLabel,
|
214
|
+
addSeparator: false,
|
215
|
+
menuContainer: menuContainer
|
216
|
+
});
|
217
|
+
conditionComponent.addLocalHook('afterClose', function () {
|
218
|
+
return _this2.onSelectUIClosed();
|
219
|
+
});
|
220
|
+
this.components.set('filter_by_condition', addConfirmationHooks(conditionComponent));
|
221
|
+
}
|
222
|
+
if (!this.components.get('filter_operators')) {
|
223
|
+
this.components.set('filter_operators', new OperatorsComponent(this.hot, {
|
224
|
+
id: 'filter_operators',
|
225
|
+
name: 'Operators'
|
226
|
+
}));
|
227
|
+
}
|
228
|
+
if (!this.components.get('filter_by_condition2')) {
|
229
|
+
var _conditionComponent = new ConditionComponent(this.hot, {
|
230
|
+
id: 'filter_by_condition2',
|
231
|
+
name: '',
|
232
|
+
addSeparator: true,
|
233
|
+
menuContainer: menuContainer
|
234
|
+
});
|
235
|
+
_conditionComponent.addLocalHook('afterClose', function () {
|
236
|
+
return _this2.onSelectUIClosed();
|
237
|
+
});
|
238
|
+
this.components.set('filter_by_condition2', addConfirmationHooks(_conditionComponent));
|
239
|
+
}
|
240
|
+
if (!this.components.get('filter_by_value')) {
|
241
|
+
this.components.set('filter_by_value', addConfirmationHooks(new ValueComponent(this.hot, {
|
242
|
+
id: 'filter_by_value',
|
243
|
+
name: filterValueLabel
|
244
|
+
})));
|
245
|
+
}
|
246
|
+
if (!this.components.get('filter_action_bar')) {
|
247
|
+
this.components.set('filter_action_bar', addConfirmationHooks(new ActionBarComponent(this.hot, {
|
248
|
+
id: 'filter_action_bar',
|
249
|
+
name: 'Action bar'
|
250
|
+
})));
|
251
|
+
}
|
252
|
+
if (!this.conditionCollection) {
|
253
|
+
this.conditionCollection = new ConditionCollection(this.hot);
|
254
|
+
}
|
255
|
+
if (!this.conditionUpdateObserver) {
|
256
|
+
this.conditionUpdateObserver = new ConditionUpdateObserver(this.hot, this.conditionCollection, function (physicalColumn) {
|
257
|
+
return _this2.getDataMapAtColumn(physicalColumn);
|
258
|
+
});
|
259
|
+
this.conditionUpdateObserver.addLocalHook('update', function (conditionState) {
|
260
|
+
return _this2.updateComponents(conditionState);
|
261
|
+
});
|
262
|
+
}
|
263
|
+
this.components.forEach(function (component) {
|
264
|
+
return component.show();
|
265
|
+
});
|
266
|
+
this.addHook('beforeDropdownMenuSetItems', function (items) {
|
267
|
+
return _this2.onBeforeDropdownMenuSetItems(items);
|
268
|
+
});
|
269
|
+
this.addHook('afterDropdownMenuDefaultOptions', function (defaultOptions) {
|
270
|
+
return _this2.onAfterDropdownMenuDefaultOptions(defaultOptions);
|
271
|
+
});
|
272
|
+
this.addHook('afterDropdownMenuShow', function () {
|
273
|
+
return _this2.onAfterDropdownMenuShow();
|
274
|
+
});
|
275
|
+
this.addHook('afterDropdownMenuHide', function () {
|
276
|
+
return _this2.onAfterDropdownMenuHide();
|
277
|
+
});
|
278
|
+
this.addHook('afterChange', function (changes) {
|
279
|
+
return _this2.onAfterChange(changes);
|
280
|
+
});
|
281
|
+
|
282
|
+
// Temp. solution (extending menu items bug in contextMenu/dropdownMenu)
|
283
|
+
if (this.hot.getSettings().dropdownMenu && this.dropdownMenuPlugin) {
|
284
|
+
this.dropdownMenuPlugin.disablePlugin();
|
285
|
+
this.dropdownMenuPlugin.enablePlugin();
|
286
|
+
}
|
287
|
+
_get(_getPrototypeOf(Filters.prototype), "enablePlugin", this).call(this);
|
288
|
+
}
|
289
|
+
|
290
|
+
/**
|
291
|
+
* Disables the plugin functionality for this Handsontable instance.
|
292
|
+
*/
|
293
|
+
}, {
|
294
|
+
key: "disablePlugin",
|
295
|
+
value: function disablePlugin() {
|
296
|
+
var _this3 = this;
|
297
|
+
if (this.enabled) {
|
298
|
+
var _this$dropdownMenuPlu;
|
299
|
+
if ((_this$dropdownMenuPlu = this.dropdownMenuPlugin) !== null && _this$dropdownMenuPlu !== void 0 && _this$dropdownMenuPlu.enabled) {
|
300
|
+
this.dropdownMenuPlugin.menu.clearLocalHooks();
|
301
|
+
}
|
302
|
+
this.components.forEach(function (component, key) {
|
303
|
+
component.destroy();
|
304
|
+
_this3.components.set(key, null);
|
305
|
+
});
|
306
|
+
this.conditionCollection.destroy();
|
307
|
+
this.conditionCollection = null;
|
308
|
+
this.hot.rowIndexMapper.unregisterMap(this.pluginName);
|
309
|
+
}
|
310
|
+
_get(_getPrototypeOf(Filters.prototype), "disablePlugin", this).call(this);
|
311
|
+
}
|
312
|
+
|
313
|
+
/* eslint-disable jsdoc/require-description-complete-sentence */
|
314
|
+
/**
|
315
|
+
* @memberof Filters#
|
316
|
+
* @function addCondition
|
317
|
+
* @description
|
318
|
+
* Adds condition to the conditions collection at specified column index.
|
319
|
+
*
|
320
|
+
* Possible predefined conditions:
|
321
|
+
* * `begins_with` - Begins with
|
322
|
+
* * `between` - Between
|
323
|
+
* * `by_value` - By value
|
324
|
+
* * `contains` - Contains
|
325
|
+
* * `empty` - Empty
|
326
|
+
* * `ends_with` - Ends with
|
327
|
+
* * `eq` - Equal
|
328
|
+
* * `gt` - Greater than
|
329
|
+
* * `gte` - Greater than or equal
|
330
|
+
* * `lt` - Less than
|
331
|
+
* * `lte` - Less than or equal
|
332
|
+
* * `none` - None (no filter)
|
333
|
+
* * `not_between` - Not between
|
334
|
+
* * `not_contains` - Not contains
|
335
|
+
* * `not_empty` - Not empty
|
336
|
+
* * `neq` - Not equal.
|
337
|
+
*
|
338
|
+
* Possible operations on collection of conditions:
|
339
|
+
* * `conjunction` - [**Conjunction**](https://en.wikipedia.org/wiki/Logical_conjunction) on conditions collection (by default), i.e. for such operation: <br/> c1 AND c2 AND c3 AND c4 ... AND cn === TRUE, where c1 ... cn are conditions.
|
340
|
+
* * `disjunction` - [**Disjunction**](https://en.wikipedia.org/wiki/Logical_disjunction) on conditions collection, i.e. for such operation: <br/> c1 OR c2 OR c3 OR c4 ... OR cn === TRUE, where c1, c2, c3, c4 ... cn are conditions.
|
341
|
+
* * `disjunctionWithExtraCondition` - **Disjunction** on first `n - 1`\* conditions from collection with an extra requirement computed from the last condition, i.e. for such operation: <br/> c1 OR c2 OR c3 OR c4 ... OR cn-1 AND cn === TRUE, where c1, c2, c3, c4 ... cn are conditions.
|
342
|
+
*
|
343
|
+
* \* when `n` is collection size; it's used i.e. for one operation introduced from UI (when choosing from filter's drop-down menu two conditions with OR operator between them, mixed with choosing values from the multiple choice select)
|
344
|
+
*
|
345
|
+
* **Note**: Mind that you cannot mix different types of operations (for instance, if you use `conjunction`, use it consequently for a particular column).
|
346
|
+
*
|
347
|
+
* @example
|
348
|
+
* ::: only-for javascript
|
349
|
+
* ```js
|
350
|
+
* const container = document.getElementById('example');
|
351
|
+
* const hot = new Handsontable(container, {
|
352
|
+
* data: getData(),
|
353
|
+
* filters: true
|
354
|
+
* });
|
355
|
+
*
|
356
|
+
* // access to filters plugin instance
|
357
|
+
* const filtersPlugin = hot.getPlugin('filters');
|
358
|
+
*
|
359
|
+
* // add filter "Greater than" 95 to column at index 1
|
360
|
+
* filtersPlugin.addCondition(1, 'gt', [95]);
|
361
|
+
* filtersPlugin.filter();
|
362
|
+
*
|
363
|
+
* // add filter "By value" to column at index 1
|
364
|
+
* // in this case all value's that don't match will be filtered.
|
365
|
+
* filtersPlugin.addCondition(1, 'by_value', [['ing', 'ed', 'as', 'on']]);
|
366
|
+
* filtersPlugin.filter();
|
367
|
+
*
|
368
|
+
* // add filter "Begins with" with value "de" AND "Not contains" with value "ing"
|
369
|
+
* filtersPlugin.addCondition(1, 'begins_with', ['de'], 'conjunction');
|
370
|
+
* filtersPlugin.addCondition(1, 'not_contains', ['ing'], 'conjunction');
|
371
|
+
* filtersPlugin.filter();
|
372
|
+
*
|
373
|
+
* // add filter "Begins with" with value "de" OR "Not contains" with value "ing"
|
374
|
+
* filtersPlugin.addCondition(1, 'begins_with', ['de'], 'disjunction');
|
375
|
+
* filtersPlugin.addCondition(1, 'not_contains', ['ing'], 'disjunction');
|
376
|
+
* filtersPlugin.filter();
|
377
|
+
* ```
|
378
|
+
* :::
|
379
|
+
*
|
380
|
+
* ::: only-for react
|
381
|
+
* ```jsx
|
382
|
+
* const hotRef = useRef(null);
|
383
|
+
*
|
384
|
+
* ...
|
385
|
+
*
|
386
|
+
* <HotTable
|
387
|
+
* ref={hotRef}
|
388
|
+
* data={getData()}
|
389
|
+
* filters={true}
|
390
|
+
* />
|
391
|
+
*
|
392
|
+
* // access to filters plugin instance
|
393
|
+
* const hot = hotRef.current.hotInstance;
|
394
|
+
* const filtersPlugin = hot.getPlugin('filters');
|
395
|
+
*
|
396
|
+
* // add filter "Greater than" 95 to column at index 1
|
397
|
+
* filtersPlugin.addCondition(1, 'gt', [95]);
|
398
|
+
* filtersPlugin.filter();
|
399
|
+
*
|
400
|
+
* // add filter "By value" to column at index 1
|
401
|
+
* // in this case all value's that don't match will be filtered.
|
402
|
+
* filtersPlugin.addCondition(1, 'by_value', [['ing', 'ed', 'as', 'on']]);
|
403
|
+
* filtersPlugin.filter();
|
404
|
+
*
|
405
|
+
* // add filter "Begins with" with value "de" AND "Not contains" with value "ing"
|
406
|
+
* filtersPlugin.addCondition(1, 'begins_with', ['de'], 'conjunction');
|
407
|
+
* filtersPlugin.addCondition(1, 'not_contains', ['ing'], 'conjunction');
|
408
|
+
* filtersPlugin.filter();
|
409
|
+
*
|
410
|
+
* // add filter "Begins with" with value "de" OR "Not contains" with value "ing"
|
411
|
+
* filtersPlugin.addCondition(1, 'begins_with', ['de'], 'disjunction');
|
412
|
+
* filtersPlugin.addCondition(1, 'not_contains', ['ing'], 'disjunction');
|
413
|
+
* filtersPlugin.filter();
|
414
|
+
* ```
|
415
|
+
* :::
|
416
|
+
*
|
417
|
+
* @param {number} column Visual column index.
|
418
|
+
* @param {string} name Condition short name.
|
419
|
+
* @param {Array} args Condition arguments.
|
420
|
+
* @param {string} [operationId=conjunction] `id` of operation which is performed on the column.
|
421
|
+
*/
|
422
|
+
/* eslint-enable jsdoc/require-description-complete-sentence */
|
423
|
+
}, {
|
424
|
+
key: "addCondition",
|
425
|
+
value: function addCondition(column, name, args) {
|
426
|
+
var operationId = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : OPERATION_AND;
|
427
|
+
var physicalColumn = this.hot.toPhysicalColumn(column);
|
428
|
+
this.conditionCollection.addCondition(physicalColumn, {
|
429
|
+
command: {
|
430
|
+
key: name
|
431
|
+
},
|
432
|
+
args: args
|
433
|
+
}, operationId);
|
434
|
+
}
|
435
|
+
|
436
|
+
/**
|
437
|
+
* Removes conditions at specified column index.
|
438
|
+
*
|
439
|
+
* @param {number} column Visual column index.
|
440
|
+
*/
|
441
|
+
}, {
|
442
|
+
key: "removeConditions",
|
443
|
+
value: function removeConditions(column) {
|
444
|
+
var physicalColumn = this.hot.toPhysicalColumn(column);
|
445
|
+
this.conditionCollection.removeConditions(physicalColumn);
|
446
|
+
}
|
447
|
+
|
448
|
+
/**
|
449
|
+
* Clears all conditions previously added to the collection for the specified column index or, if the column index
|
450
|
+
* was not passed, clear the conditions for all columns.
|
451
|
+
*
|
452
|
+
* @param {number} [column] Visual column index.
|
453
|
+
*/
|
454
|
+
}, {
|
455
|
+
key: "clearConditions",
|
456
|
+
value: function clearConditions(column) {
|
457
|
+
if (column === void 0) {
|
458
|
+
this.conditionCollection.clean();
|
459
|
+
} else {
|
460
|
+
var physicalColumn = this.hot.toPhysicalColumn(column);
|
461
|
+
this.conditionCollection.removeConditions(physicalColumn);
|
462
|
+
}
|
463
|
+
}
|
464
|
+
|
465
|
+
/**
|
466
|
+
* Filters data based on added filter conditions.
|
467
|
+
*
|
468
|
+
* @fires Hooks#beforeFilter
|
469
|
+
* @fires Hooks#afterFilter
|
470
|
+
*/
|
471
|
+
}, {
|
472
|
+
key: "filter",
|
473
|
+
value: function filter() {
|
474
|
+
var _this4 = this;
|
475
|
+
var dataFilter = this._createDataFilter();
|
476
|
+
var needToFilter = !this.conditionCollection.isEmpty();
|
477
|
+
var visibleVisualRows = [];
|
478
|
+
var conditions = this.conditionCollection.exportAllConditions();
|
479
|
+
var allowFiltering = this.hot.runHooks('beforeFilter', conditions);
|
480
|
+
if (allowFiltering !== false) {
|
481
|
+
if (needToFilter) {
|
482
|
+
var trimmedRows = [];
|
483
|
+
this.hot.batchExecution(function () {
|
484
|
+
_this4.filtersRowsMap.clear();
|
485
|
+
visibleVisualRows = arrayMap(dataFilter.filter(), function (rowData) {
|
486
|
+
return rowData.meta.visualRow;
|
487
|
+
});
|
488
|
+
var visibleVisualRowsAssertion = createArrayAssertion(visibleVisualRows);
|
489
|
+
rangeEach(_this4.hot.countSourceRows() - 1, function (row) {
|
490
|
+
if (!visibleVisualRowsAssertion(row)) {
|
491
|
+
trimmedRows.push(row);
|
492
|
+
}
|
493
|
+
});
|
494
|
+
arrayEach(trimmedRows, function (physicalRow) {
|
495
|
+
_this4.filtersRowsMap.setValueAtIndex(physicalRow, true);
|
496
|
+
});
|
497
|
+
}, true);
|
498
|
+
if (!visibleVisualRows.length) {
|
499
|
+
this.hot.deselectCell();
|
500
|
+
}
|
501
|
+
} else {
|
502
|
+
this.filtersRowsMap.clear();
|
503
|
+
}
|
504
|
+
}
|
505
|
+
this.hot.runHooks('afterFilter', conditions);
|
506
|
+
this.hot.view.adjustElementsSize(true);
|
507
|
+
this.hot.render();
|
508
|
+
this.clearColumnSelection();
|
509
|
+
}
|
510
|
+
|
511
|
+
/**
|
512
|
+
* Gets last selected column index.
|
513
|
+
*
|
514
|
+
* @returns {{visualIndex: number, physicalIndex: number} | null} Returns `null` when a column is
|
515
|
+
* not selected. Otherwise, returns an object with `visualIndex` and `physicalIndex` properties containing
|
516
|
+
* the index of the column.
|
517
|
+
*/
|
518
|
+
}, {
|
519
|
+
key: "getSelectedColumn",
|
520
|
+
value: function getSelectedColumn() {
|
521
|
+
var _this$hot$getSelected;
|
522
|
+
var highlight = (_this$hot$getSelected = this.hot.getSelectedRangeLast()) === null || _this$hot$getSelected === void 0 ? void 0 : _this$hot$getSelected.highlight;
|
523
|
+
if (!highlight) {
|
524
|
+
return null;
|
525
|
+
}
|
526
|
+
return {
|
527
|
+
visualIndex: highlight.col,
|
528
|
+
physicalIndex: this.hot.toPhysicalColumn(highlight.col)
|
529
|
+
};
|
530
|
+
}
|
531
|
+
|
532
|
+
/**
|
533
|
+
* Clears column selection.
|
534
|
+
*
|
535
|
+
* @private
|
536
|
+
*/
|
537
|
+
}, {
|
538
|
+
key: "clearColumnSelection",
|
539
|
+
value: function clearColumnSelection() {
|
540
|
+
var selectedColumn = this.getSelectedColumn();
|
541
|
+
if (selectedColumn !== null) {
|
542
|
+
this.hot.selectCell(0, selectedColumn.visualIndex);
|
543
|
+
}
|
544
|
+
}
|
545
|
+
|
546
|
+
/**
|
547
|
+
* Returns handsontable source data with cell meta based on current selection.
|
548
|
+
*
|
549
|
+
* @param {number} [column] The physical column index. By default column index accept the value of the selected column.
|
550
|
+
* @returns {Array} Returns array of objects where keys as row index.
|
551
|
+
*/
|
552
|
+
}, {
|
553
|
+
key: "getDataMapAtColumn",
|
554
|
+
value: function getDataMapAtColumn(column) {
|
555
|
+
var _this5 = this;
|
556
|
+
var visualColumn = this.hot.toVisualColumn(column);
|
557
|
+
var data = [];
|
558
|
+
arrayEach(this.hot.getSourceDataAtCol(visualColumn), function (value, rowIndex) {
|
559
|
+
var _this5$hot$getDataAtC;
|
560
|
+
var _this5$hot$getCellMet = _this5.hot.getCellMeta(rowIndex, visualColumn),
|
561
|
+
row = _this5$hot$getCellMet.row,
|
562
|
+
col = _this5$hot$getCellMet.col,
|
563
|
+
visualCol = _this5$hot$getCellMet.visualCol,
|
564
|
+
visualRow = _this5$hot$getCellMet.visualRow,
|
565
|
+
type = _this5$hot$getCellMet.type,
|
566
|
+
instance = _this5$hot$getCellMet.instance,
|
567
|
+
dateFormat = _this5$hot$getCellMet.dateFormat,
|
568
|
+
locale = _this5$hot$getCellMet.locale;
|
569
|
+
var dataValue = (_this5$hot$getDataAtC = _this5.hot.getDataAtCell(_this5.hot.toVisualRow(rowIndex), visualColumn)) !== null && _this5$hot$getDataAtC !== void 0 ? _this5$hot$getDataAtC : value;
|
570
|
+
data.push({
|
571
|
+
meta: {
|
572
|
+
row: row,
|
573
|
+
col: col,
|
574
|
+
visualCol: visualCol,
|
575
|
+
visualRow: visualRow,
|
576
|
+
type: type,
|
577
|
+
instance: instance,
|
578
|
+
dateFormat: dateFormat,
|
579
|
+
locale: locale
|
580
|
+
},
|
581
|
+
value: toEmptyString(dataValue)
|
582
|
+
});
|
583
|
+
});
|
584
|
+
return data;
|
585
|
+
}
|
586
|
+
|
587
|
+
/**
|
588
|
+
* `afterChange` listener.
|
589
|
+
*
|
590
|
+
* @private
|
591
|
+
* @param {Array} changes Array of changes.
|
592
|
+
*/
|
593
|
+
}, {
|
594
|
+
key: "onAfterChange",
|
595
|
+
value: function onAfterChange(changes) {
|
596
|
+
var _this6 = this;
|
597
|
+
if (changes) {
|
598
|
+
arrayEach(changes, function (change) {
|
599
|
+
var _change = _slicedToArray(change, 2),
|
600
|
+
prop = _change[1];
|
601
|
+
var columnIndex = _this6.hot.propToCol(prop);
|
602
|
+
if (_this6.conditionCollection.hasConditions(columnIndex)) {
|
603
|
+
_this6.updateValueComponentCondition(columnIndex);
|
604
|
+
}
|
605
|
+
});
|
606
|
+
}
|
607
|
+
}
|
608
|
+
|
609
|
+
/**
|
610
|
+
* Update the condition of ValueComponent, based on the handled changes.
|
611
|
+
*
|
612
|
+
* @private
|
613
|
+
* @param {number} columnIndex Column index of handled ValueComponent condition.
|
614
|
+
*/
|
615
|
+
}, {
|
616
|
+
key: "updateValueComponentCondition",
|
617
|
+
value: function updateValueComponentCondition(columnIndex) {
|
618
|
+
var dataAtCol = this.hot.getDataAtCol(columnIndex);
|
619
|
+
var selectedValues = unifyColumnValues(dataAtCol);
|
620
|
+
this.conditionUpdateObserver.updateStatesAtColumn(columnIndex, selectedValues);
|
621
|
+
}
|
622
|
+
|
623
|
+
/**
|
624
|
+
* Restores components to its saved state.
|
625
|
+
*
|
626
|
+
* @private
|
627
|
+
* @param {Array} components List of components.
|
628
|
+
*/
|
629
|
+
}, {
|
630
|
+
key: "restoreComponents",
|
631
|
+
value: function restoreComponents(components) {
|
632
|
+
var _this$getSelectedColu;
|
633
|
+
var physicalIndex = (_this$getSelectedColu = this.getSelectedColumn()) === null || _this$getSelectedColu === void 0 ? void 0 : _this$getSelectedColu.physicalIndex;
|
634
|
+
components.forEach(function (component) {
|
635
|
+
if (component.isHidden()) {
|
636
|
+
return;
|
637
|
+
}
|
638
|
+
component.restoreState(physicalIndex);
|
639
|
+
});
|
640
|
+
this.updateDependentComponentsVisibility();
|
641
|
+
}
|
642
|
+
|
643
|
+
/**
|
644
|
+
* After dropdown menu show listener.
|
645
|
+
*
|
646
|
+
* @private
|
647
|
+
*/
|
648
|
+
}, {
|
649
|
+
key: "onAfterDropdownMenuShow",
|
650
|
+
value: function onAfterDropdownMenuShow() {
|
651
|
+
this.restoreComponents(Array.from(this.components.values()));
|
652
|
+
}
|
653
|
+
|
654
|
+
/**
|
655
|
+
* After dropdown menu hide listener.
|
656
|
+
*
|
657
|
+
* @private
|
658
|
+
*/
|
659
|
+
}, {
|
660
|
+
key: "onAfterDropdownMenuHide",
|
661
|
+
value: function onAfterDropdownMenuHide() {
|
662
|
+
this.components.get('filter_by_condition').getSelectElement().closeOptions();
|
663
|
+
this.components.get('filter_by_condition2').getSelectElement().closeOptions();
|
664
|
+
}
|
665
|
+
|
666
|
+
/**
|
667
|
+
* Before dropdown menu set menu items listener.
|
668
|
+
*
|
669
|
+
* @private
|
670
|
+
*/
|
671
|
+
}, {
|
672
|
+
key: "onBeforeDropdownMenuSetItems",
|
673
|
+
value: function onBeforeDropdownMenuSetItems() {
|
674
|
+
var _this7 = this;
|
675
|
+
if (this.dropdownMenuPlugin) {
|
676
|
+
this.dropdownMenuPlugin.menu.addLocalHook('afterOpen', function () {
|
677
|
+
_this7.dropdownMenuPlugin.menu.hotMenu.updateSettings({
|
678
|
+
hiddenRows: true
|
679
|
+
});
|
680
|
+
});
|
681
|
+
}
|
682
|
+
}
|
683
|
+
|
684
|
+
/**
|
685
|
+
* After dropdown menu default options listener.
|
686
|
+
*
|
687
|
+
* @private
|
688
|
+
* @param {object} defaultOptions ContextMenu default item options.
|
689
|
+
*/
|
690
|
+
}, {
|
691
|
+
key: "onAfterDropdownMenuDefaultOptions",
|
692
|
+
value: function onAfterDropdownMenuDefaultOptions(defaultOptions) {
|
693
|
+
defaultOptions.items.push({
|
694
|
+
name: SEPARATOR
|
695
|
+
});
|
696
|
+
this.components.forEach(function (component) {
|
697
|
+
defaultOptions.items.push(component.getMenuItemDescriptor());
|
698
|
+
});
|
699
|
+
}
|
700
|
+
|
701
|
+
/**
|
702
|
+
* Get an operation, based on the number and types of arguments (where arguments are states of components).
|
703
|
+
*
|
704
|
+
* @param {string} suggestedOperation Operation which was chosen by user from UI.
|
705
|
+
* @param {object} byConditionState1 State of first condition component.
|
706
|
+
* @param {object} byConditionState2 State of second condition component.
|
707
|
+
* @param {object} byValueState State of value component.
|
708
|
+
* @private
|
709
|
+
* @returns {string}
|
710
|
+
*/
|
711
|
+
}, {
|
712
|
+
key: "getOperationBasedOnArguments",
|
713
|
+
value: function getOperationBasedOnArguments(suggestedOperation, byConditionState1, byConditionState2, byValueState) {
|
714
|
+
var operation = suggestedOperation;
|
715
|
+
if (operation === OPERATION_OR && byConditionState1.command.key !== CONDITION_NONE && byConditionState2.command.key !== CONDITION_NONE && byValueState.command.key !== CONDITION_NONE) {
|
716
|
+
operation = OPERATION_OR_THEN_VARIABLE;
|
717
|
+
} else if (byValueState.command.key !== CONDITION_NONE) {
|
718
|
+
if (byConditionState1.command.key === CONDITION_NONE || byConditionState2.command.key === CONDITION_NONE) {
|
719
|
+
operation = OPERATION_AND;
|
720
|
+
}
|
721
|
+
}
|
722
|
+
return operation;
|
723
|
+
}
|
724
|
+
|
725
|
+
/**
|
726
|
+
* On action bar submit listener.
|
727
|
+
*
|
728
|
+
* @private
|
729
|
+
* @param {string} submitType The submit type.
|
730
|
+
*/
|
731
|
+
}, {
|
732
|
+
key: "onActionBarSubmit",
|
733
|
+
value: function onActionBarSubmit(submitType) {
|
734
|
+
var _this$dropdownMenuPlu3;
|
735
|
+
if (submitType === 'accept') {
|
736
|
+
var selectedColumn = this.getSelectedColumn();
|
737
|
+
if (selectedColumn === null) {
|
738
|
+
var _this$dropdownMenuPlu2;
|
739
|
+
(_this$dropdownMenuPlu2 = this.dropdownMenuPlugin) === null || _this$dropdownMenuPlu2 === void 0 ? void 0 : _this$dropdownMenuPlu2.close();
|
740
|
+
return;
|
741
|
+
}
|
742
|
+
var physicalIndex = selectedColumn.physicalIndex;
|
743
|
+
var byConditionState1 = this.components.get('filter_by_condition').getState();
|
744
|
+
var byConditionState2 = this.components.get('filter_by_condition2').getState();
|
745
|
+
var byValueState = this.components.get('filter_by_value').getState();
|
746
|
+
var operation = this.getOperationBasedOnArguments(this.components.get('filter_operators').getActiveOperationId(), byConditionState1, byConditionState2, byValueState);
|
747
|
+
this.conditionUpdateObserver.groupChanges();
|
748
|
+
var columnStackPosition = this.conditionCollection.getColumnStackPosition(physicalIndex);
|
749
|
+
if (columnStackPosition === -1) {
|
750
|
+
columnStackPosition = void 0;
|
751
|
+
}
|
752
|
+
this.conditionCollection.removeConditions(physicalIndex);
|
753
|
+
if (byConditionState1.command.key !== CONDITION_NONE) {
|
754
|
+
this.conditionCollection.addCondition(physicalIndex, byConditionState1, operation, columnStackPosition);
|
755
|
+
if (byConditionState2.command.key !== CONDITION_NONE) {
|
756
|
+
this.conditionCollection.addCondition(physicalIndex, byConditionState2, operation, columnStackPosition);
|
757
|
+
}
|
758
|
+
}
|
759
|
+
if (byValueState.command.key !== CONDITION_NONE) {
|
760
|
+
this.conditionCollection.addCondition(physicalIndex, byValueState, operation, columnStackPosition);
|
761
|
+
}
|
762
|
+
this.conditionUpdateObserver.flush();
|
763
|
+
this.components.forEach(function (component) {
|
764
|
+
return component.saveState(physicalIndex);
|
765
|
+
});
|
766
|
+
this.filtersRowsMap.clear();
|
767
|
+
this.filter();
|
768
|
+
}
|
769
|
+
(_this$dropdownMenuPlu3 = this.dropdownMenuPlugin) === null || _this$dropdownMenuPlu3 === void 0 ? void 0 : _this$dropdownMenuPlu3.close();
|
770
|
+
}
|
771
|
+
|
772
|
+
/**
|
773
|
+
* On component change listener.
|
774
|
+
*
|
775
|
+
* @private
|
776
|
+
* @param {BaseComponent} component Component inheriting BaseComponent.
|
777
|
+
* @param {object} command Menu item object (command).
|
778
|
+
*/
|
779
|
+
}, {
|
780
|
+
key: "onComponentChange",
|
781
|
+
value: function onComponentChange(component, command) {
|
782
|
+
this.updateDependentComponentsVisibility();
|
783
|
+
if (component.constructor === ConditionComponent && !command.inputsCount) {
|
784
|
+
this.setListeningDropdownMenu();
|
785
|
+
}
|
786
|
+
}
|
787
|
+
|
788
|
+
/**
|
789
|
+
* On component SelectUI closed listener.
|
790
|
+
*
|
791
|
+
* @private
|
792
|
+
*/
|
793
|
+
}, {
|
794
|
+
key: "onSelectUIClosed",
|
795
|
+
value: function onSelectUIClosed() {
|
796
|
+
this.setListeningDropdownMenu();
|
797
|
+
}
|
798
|
+
|
799
|
+
/**
|
800
|
+
* Listen to the keyboard input on document body and forward events to instance of Handsontable
|
801
|
+
* created by DropdownMenu plugin.
|
802
|
+
*
|
803
|
+
* @private
|
804
|
+
*/
|
805
|
+
}, {
|
806
|
+
key: "setListeningDropdownMenu",
|
807
|
+
value: function setListeningDropdownMenu() {
|
808
|
+
if (this.dropdownMenuPlugin) {
|
809
|
+
this.dropdownMenuPlugin.setListening();
|
810
|
+
}
|
811
|
+
}
|
812
|
+
|
813
|
+
/**
|
814
|
+
* Updates visibility of some of the components, based on the state of the parent component.
|
815
|
+
*
|
816
|
+
* @private
|
817
|
+
*/
|
818
|
+
}, {
|
819
|
+
key: "updateDependentComponentsVisibility",
|
820
|
+
value: function updateDependentComponentsVisibility() {
|
821
|
+
var component = this.components.get('filter_by_condition');
|
822
|
+
var _component$getState = component.getState(),
|
823
|
+
command = _component$getState.command;
|
824
|
+
var componentsToShow = [this.components.get('filter_by_condition2'), this.components.get('filter_operators')];
|
825
|
+
if (command.showOperators) {
|
826
|
+
this.showComponents.apply(this, componentsToShow);
|
827
|
+
} else {
|
828
|
+
this.hideComponents.apply(this, componentsToShow);
|
829
|
+
}
|
830
|
+
}
|
831
|
+
|
832
|
+
/**
|
833
|
+
* On after get column header listener.
|
834
|
+
*
|
835
|
+
* @private
|
836
|
+
* @param {number} col Visual column index.
|
837
|
+
* @param {HTMLTableCellElement} TH Header's TH element.
|
838
|
+
*/
|
839
|
+
}, {
|
840
|
+
key: "onAfterGetColHeader",
|
841
|
+
value: function onAfterGetColHeader(col, TH) {
|
842
|
+
var physicalColumn = this.hot.toPhysicalColumn(col);
|
843
|
+
if (this.enabled && this.conditionCollection.hasConditions(physicalColumn)) {
|
844
|
+
addClass(TH, 'htFiltersActive');
|
845
|
+
} else {
|
846
|
+
removeClass(TH, 'htFiltersActive');
|
847
|
+
}
|
848
|
+
}
|
849
|
+
|
850
|
+
/**
|
851
|
+
* Creates DataFilter instance based on condition collection.
|
852
|
+
*
|
853
|
+
* @private
|
854
|
+
* @param {ConditionCollection} conditionCollection Condition collection object.
|
855
|
+
* @returns {DataFilter}
|
856
|
+
*/
|
857
|
+
}, {
|
858
|
+
key: "_createDataFilter",
|
859
|
+
value: function _createDataFilter() {
|
860
|
+
var _this8 = this;
|
861
|
+
var conditionCollection = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : this.conditionCollection;
|
862
|
+
return new DataFilter(conditionCollection, function (physicalColumn) {
|
863
|
+
return _this8.getDataMapAtColumn(physicalColumn);
|
864
|
+
});
|
865
|
+
}
|
866
|
+
|
867
|
+
/**
|
868
|
+
* It updates the components state. The state is triggered by ConditionUpdateObserver, which
|
869
|
+
* reacts to any condition added to the condition collection. It may be added through the UI
|
870
|
+
* components or by API call.
|
871
|
+
*
|
872
|
+
* @private
|
873
|
+
* @param {object} conditionsState An object with the state generated by UI components.
|
874
|
+
*/
|
875
|
+
}, {
|
876
|
+
key: "updateComponents",
|
877
|
+
value: function updateComponents(conditionsState) {
|
878
|
+
var _this$dropdownMenuPlu4;
|
879
|
+
if (!((_this$dropdownMenuPlu4 = this.dropdownMenuPlugin) !== null && _this$dropdownMenuPlu4 !== void 0 && _this$dropdownMenuPlu4.enabled)) {
|
880
|
+
return;
|
881
|
+
}
|
882
|
+
var _conditionsState$edit = conditionsState.editedConditionStack,
|
883
|
+
conditions = _conditionsState$edit.conditions,
|
884
|
+
column = _conditionsState$edit.column;
|
885
|
+
var conditionsByValue = conditions.filter(function (condition) {
|
886
|
+
return condition.name === CONDITION_BY_VALUE;
|
887
|
+
});
|
888
|
+
var conditionsWithoutByValue = conditions.filter(function (condition) {
|
889
|
+
return condition.name !== CONDITION_BY_VALUE;
|
890
|
+
});
|
891
|
+
if (conditionsByValue.length >= 2 || conditionsWithoutByValue.length >= 3) {
|
892
|
+
warn(toSingleLine(_templateObject || (_templateObject = _taggedTemplateLiteral(["The filter conditions have been applied properly, but couldn\u2019t be displayed visually. \n The overall amount of conditions exceed the capability of the dropdown menu. \n For more details see the documentation."], ["The filter conditions have been applied properly, but couldn\u2019t be displayed visually.\\x20\n The overall amount of conditions exceed the capability of the dropdown menu.\\x20\n For more details see the documentation."]))));
|
893
|
+
} else {
|
894
|
+
var operationType = this.conditionCollection.getOperation(column);
|
895
|
+
this.components.get('filter_by_condition').updateState(conditionsWithoutByValue[0], column);
|
896
|
+
this.components.get('filter_by_condition2').updateState(conditionsWithoutByValue[1], column);
|
897
|
+
this.components.get('filter_operators').updateState(operationType, column);
|
898
|
+
this.components.get('filter_by_value').updateState(conditionsState);
|
899
|
+
}
|
900
|
+
}
|
901
|
+
|
902
|
+
/**
|
903
|
+
* Returns indexes of passed components inside list of `dropdownMenu` items.
|
904
|
+
*
|
905
|
+
* @private
|
906
|
+
* @param {...BaseComponent} components List of components.
|
907
|
+
* @returns {Array}
|
908
|
+
*/
|
909
|
+
}, {
|
910
|
+
key: "getIndexesOfComponents",
|
911
|
+
value: function getIndexesOfComponents() {
|
912
|
+
var indexes = [];
|
913
|
+
if (!this.dropdownMenuPlugin) {
|
914
|
+
return indexes;
|
915
|
+
}
|
916
|
+
var menu = this.dropdownMenuPlugin.menu;
|
917
|
+
for (var _len = arguments.length, components = new Array(_len), _key = 0; _key < _len; _key++) {
|
918
|
+
components[_key] = arguments[_key];
|
919
|
+
}
|
920
|
+
arrayEach(components, function (component) {
|
921
|
+
arrayEach(menu.menuItems, function (item, index) {
|
922
|
+
if (item.key === component.getMenuItemDescriptor().key) {
|
923
|
+
indexes.push(index);
|
924
|
+
}
|
925
|
+
});
|
926
|
+
});
|
927
|
+
return indexes;
|
928
|
+
}
|
929
|
+
|
930
|
+
/**
|
931
|
+
* Changes visibility of component.
|
932
|
+
*
|
933
|
+
* @private
|
934
|
+
* @param {boolean} visible Determine if components should be visible.
|
935
|
+
* @param {...BaseComponent} components List of components.
|
936
|
+
*/
|
937
|
+
}, {
|
938
|
+
key: "changeComponentsVisibility",
|
939
|
+
value: function changeComponentsVisibility() {
|
940
|
+
var visible = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : true;
|
941
|
+
if (!this.dropdownMenuPlugin) {
|
942
|
+
return;
|
943
|
+
}
|
944
|
+
var menu = this.dropdownMenuPlugin.menu;
|
945
|
+
var hotMenu = menu.hotMenu;
|
946
|
+
var hiddenRows = hotMenu.getPlugin('hiddenRows');
|
947
|
+
for (var _len2 = arguments.length, components = new Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {
|
948
|
+
components[_key2 - 1] = arguments[_key2];
|
949
|
+
}
|
950
|
+
var indexes = this.getIndexesOfComponents.apply(this, components);
|
951
|
+
if (visible) {
|
952
|
+
hiddenRows.showRows(indexes);
|
953
|
+
} else {
|
954
|
+
hiddenRows.hideRows(indexes);
|
955
|
+
}
|
956
|
+
hotMenu.render();
|
957
|
+
}
|
958
|
+
|
959
|
+
/**
|
960
|
+
* Hides components of filters `dropdownMenu`.
|
961
|
+
*
|
962
|
+
* @private
|
963
|
+
* @param {...BaseComponent} components List of components.
|
964
|
+
*/
|
965
|
+
}, {
|
966
|
+
key: "hideComponents",
|
967
|
+
value: function hideComponents() {
|
968
|
+
for (var _len3 = arguments.length, components = new Array(_len3), _key3 = 0; _key3 < _len3; _key3++) {
|
969
|
+
components[_key3] = arguments[_key3];
|
970
|
+
}
|
971
|
+
this.changeComponentsVisibility.apply(this, [false].concat(components));
|
972
|
+
}
|
973
|
+
|
974
|
+
/**
|
975
|
+
* Shows components of filters `dropdownMenu`.
|
976
|
+
*
|
977
|
+
* @private
|
978
|
+
* @param {...BaseComponent} components List of components.
|
979
|
+
*/
|
980
|
+
}, {
|
981
|
+
key: "showComponents",
|
982
|
+
value: function showComponents() {
|
983
|
+
for (var _len4 = arguments.length, components = new Array(_len4), _key4 = 0; _key4 < _len4; _key4++) {
|
984
|
+
components[_key4] = arguments[_key4];
|
985
|
+
}
|
986
|
+
this.changeComponentsVisibility.apply(this, [true].concat(components));
|
987
|
+
}
|
988
|
+
|
989
|
+
/**
|
990
|
+
* Destroys the plugin instance.
|
991
|
+
*/
|
992
|
+
}, {
|
993
|
+
key: "destroy",
|
994
|
+
value: function destroy() {
|
995
|
+
var _this9 = this;
|
996
|
+
if (this.enabled) {
|
997
|
+
this.components.forEach(function (component, key) {
|
998
|
+
if (component !== null) {
|
999
|
+
component.destroy();
|
1000
|
+
_this9.components.set(key, null);
|
1001
|
+
}
|
1002
|
+
});
|
1003
|
+
this.conditionCollection.destroy();
|
1004
|
+
this.conditionUpdateObserver.destroy();
|
1005
|
+
this.hot.rowIndexMapper.unregisterMap(this.pluginName);
|
1006
|
+
}
|
1007
|
+
_get(_getPrototypeOf(Filters.prototype), "destroy", this).call(this);
|
1008
|
+
}
|
1009
|
+
}], [{
|
1010
|
+
key: "PLUGIN_KEY",
|
1011
|
+
get: function get() {
|
1012
|
+
return PLUGIN_KEY;
|
1013
|
+
}
|
1014
|
+
}, {
|
1015
|
+
key: "PLUGIN_PRIORITY",
|
1016
|
+
get: function get() {
|
1017
|
+
return PLUGIN_PRIORITY;
|
1018
|
+
}
|
1019
|
+
}, {
|
1020
|
+
key: "PLUGIN_DEPS",
|
1021
|
+
get: function get() {
|
1022
|
+
return ['plugin:DropdownMenu', 'plugin:HiddenRows', 'cell-type:checkbox'];
|
1023
|
+
}
|
1024
|
+
}]);
|
1025
|
+
return Filters;
|
1026
|
+
}(BasePlugin);
|