@revolist/revogrid 3.6.7 → 3.6.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/custom-element/_baseIteratee.js +3 -1
- package/custom-element/_baseIteratee.js.map +1 -0
- package/custom-element/columnService.js +6 -4
- package/custom-element/columnService.js.map +1 -0
- package/custom-element/consts.js +3 -1
- package/custom-element/consts.js.map +1 -0
- package/custom-element/data.store.js +55 -33
- package/custom-element/data.store.js.map +1 -0
- package/custom-element/debounce.js +3 -1
- package/custom-element/debounce.js.map +1 -0
- package/custom-element/dimension.helpers.js +3 -1
- package/custom-element/dimension.helpers.js.map +1 -0
- package/custom-element/each.js +2 -0
- package/custom-element/each.js.map +1 -0
- package/custom-element/filter.button.js +2 -0
- package/custom-element/filter.button.js.map +1 -0
- package/custom-element/identity.js +2 -0
- package/custom-element/identity.js.map +1 -0
- package/custom-element/index.d.ts +9 -16
- package/custom-element/index.js +4 -15
- package/custom-element/index.js.map +1 -0
- package/custom-element/isSymbol.js +3 -1
- package/custom-element/isSymbol.js.map +1 -0
- package/custom-element/keys.js +3 -1
- package/custom-element/keys.js.map +1 -0
- package/custom-element/localScrollService.js +2 -0
- package/custom-element/localScrollService.js.map +1 -0
- package/custom-element/resize-observer.js +2 -0
- package/custom-element/resize-observer.js.map +1 -0
- package/custom-element/revo-grid.js +29 -154
- package/custom-element/revo-grid.js.map +1 -0
- package/custom-element/revogr-clipboard.js +4 -4
- package/custom-element/revogr-clipboard.js.map +1 -0
- package/custom-element/revogr-data.js +2 -0
- package/custom-element/revogr-data.js.map +1 -0
- package/custom-element/revogr-data2.js +14 -3
- package/custom-element/revogr-data2.js.map +1 -0
- package/custom-element/revogr-edit.js +2 -0
- package/custom-element/revogr-edit.js.map +1 -0
- package/custom-element/revogr-edit2.js +7 -3
- package/custom-element/revogr-edit2.js.map +1 -0
- package/custom-element/revogr-filter-panel.js +10 -6
- package/custom-element/revogr-filter-panel.js.map +1 -0
- package/custom-element/revogr-focus.js +2 -0
- package/custom-element/revogr-focus.js.map +1 -0
- package/custom-element/revogr-focus2.js +8 -2
- package/custom-element/revogr-focus2.js.map +1 -0
- package/custom-element/revogr-header.js +2 -0
- package/custom-element/revogr-header.js.map +1 -0
- package/custom-element/revogr-header2.js +11 -3
- package/custom-element/revogr-header2.js.map +1 -0
- package/custom-element/revogr-order-editor.js +2 -0
- package/custom-element/revogr-order-editor.js.map +1 -0
- package/custom-element/revogr-order-editor2.js +8 -3
- package/custom-element/revogr-order-editor2.js.map +1 -0
- package/custom-element/revogr-overlay-selection.js +2 -0
- package/custom-element/revogr-overlay-selection.js.map +1 -0
- package/custom-element/revogr-overlay-selection2.js +42 -40
- package/custom-element/revogr-overlay-selection2.js.map +1 -0
- package/custom-element/revogr-row-headers.js +2 -0
- package/custom-element/revogr-row-headers.js.map +1 -0
- package/custom-element/revogr-row-headers2.js +9 -2
- package/custom-element/revogr-row-headers2.js.map +1 -0
- package/custom-element/revogr-scroll-virtual.js +2 -0
- package/custom-element/revogr-scroll-virtual.js.map +1 -0
- package/custom-element/revogr-scroll-virtual2.js +5 -2
- package/custom-element/revogr-scroll-virtual2.js.map +1 -0
- package/custom-element/revogr-temp-range.js +2 -0
- package/custom-element/revogr-temp-range.js.map +1 -0
- package/custom-element/revogr-temp-range2.js +8 -4
- package/custom-element/revogr-temp-range2.js.map +1 -0
- package/custom-element/revogr-viewport-scroll.js +2 -0
- package/custom-element/revogr-viewport-scroll.js.map +1 -0
- package/custom-element/revogr-viewport-scroll2.js +6 -11
- package/custom-element/revogr-viewport-scroll2.js.map +1 -0
- package/custom-element/selection.utils.js +2 -0
- package/custom-element/selection.utils.js.map +1 -0
- package/custom-element/themeService.js +65 -0
- package/custom-element/themeService.js.map +1 -0
- package/custom-element/toInteger.js +2 -0
- package/custom-element/toInteger.js.map +1 -0
- package/custom-element/toNumber.js +3 -1
- package/custom-element/toNumber.js.map +1 -0
- package/custom-element/utils.js +2 -0
- package/custom-element/utils.js.map +1 -0
- package/dist/cjs/{debounce-6cea2774.js → debounce-a0628875.js} +3 -1
- package/dist/cjs/debounce-a0628875.js.map +1 -0
- package/dist/cjs/{index-cb904e00.js → index-c209f988.js} +667 -315
- package/dist/cjs/index-c209f988.js.map +1 -0
- package/dist/cjs/index.cjs.js +2 -0
- package/dist/cjs/index.cjs.js.map +1 -0
- package/dist/cjs/loader.cjs.js +6 -26
- package/dist/cjs/loader.cjs.js.map +1 -0
- package/dist/cjs/{resize-observer-bf327d6a.js → resize-observer-cc749e66.js} +2 -0
- package/dist/cjs/resize-observer-cc749e66.js.map +1 -0
- package/dist/cjs/revo-grid.cjs.js +9 -60
- package/dist/cjs/revo-grid.cjs.js.map +1 -0
- package/dist/cjs/revo-grid_11.cjs.entry.js +169 -180
- package/dist/cjs/revo-grid_11.cjs.entry.js.map +1 -0
- package/dist/cjs/revogr-clipboard.cjs.entry.js +4 -3
- package/dist/cjs/revogr-clipboard.cjs.entry.js.map +1 -0
- package/dist/cjs/revogr-filter-panel.cjs.entry.js +11 -6
- package/dist/cjs/revogr-filter-panel.cjs.entry.js.map +1 -0
- package/dist/collection/collection-manifest.json +16 -16
- package/dist/collection/components/button/button.js +2 -1
- package/dist/collection/components/button/button.js.map +1 -0
- package/dist/collection/components/clipboard/revogr-clipboard.js +86 -80
- package/dist/collection/components/clipboard/revogr-clipboard.js.map +1 -0
- package/dist/collection/components/data/cellRenderer.js +5 -5
- package/dist/collection/components/data/cellRenderer.js.map +1 -0
- package/dist/collection/components/data/columnService.js +9 -8
- package/dist/collection/components/data/columnService.js.map +1 -0
- package/dist/collection/components/data/revogr-data.js +258 -226
- package/dist/collection/components/data/revogr-data.js.map +1 -0
- package/dist/collection/components/data/rowRenderer.js +2 -1
- package/dist/collection/components/data/rowRenderer.js.map +1 -0
- package/dist/collection/components/header/headerCellRenderer.js +6 -7
- package/dist/collection/components/header/headerCellRenderer.js.map +1 -0
- package/dist/collection/components/header/headerRenderer.js +7 -8
- package/dist/collection/components/header/headerRenderer.js.map +1 -0
- package/dist/collection/components/header/revogr-header.js +259 -233
- package/dist/collection/components/header/revogr-header.js.map +1 -0
- package/dist/collection/components/order/orderRenderer.js +3 -6
- package/dist/collection/components/order/orderRenderer.js.map +1 -0
- package/dist/collection/components/order/revogr-order-editor.js +279 -252
- package/dist/collection/components/order/revogr-order-editor.js.map +1 -0
- package/dist/collection/components/order/rowOrderService.js +2 -1
- package/dist/collection/components/order/rowOrderService.js.map +1 -0
- package/dist/collection/components/overlay/autofill.service.js +8 -7
- package/dist/collection/components/overlay/autofill.service.js.map +1 -0
- package/dist/collection/components/overlay/clipboard.service.js +4 -3
- package/dist/collection/components/overlay/clipboard.service.js.map +1 -0
- package/dist/collection/components/overlay/editors/edit.utils.js +2 -1
- package/dist/collection/components/overlay/editors/edit.utils.js.map +1 -0
- package/dist/collection/components/overlay/editors/text.js +4 -3
- package/dist/collection/components/overlay/editors/text.js.map +1 -0
- package/dist/collection/components/overlay/keyboard.service.js +6 -5
- package/dist/collection/components/overlay/keyboard.service.js.map +1 -0
- package/dist/collection/components/overlay/revogr-edit.js +112 -96
- package/dist/collection/components/overlay/revogr-edit.js.map +1 -0
- package/dist/collection/components/overlay/revogr-overlay-selection.js +546 -482
- package/dist/collection/components/overlay/revogr-overlay-selection.js.map +1 -0
- package/dist/collection/components/overlay/selection.utils.js +2 -1
- package/dist/collection/components/overlay/selection.utils.js.map +1 -0
- package/dist/collection/components/revo-grid/revo-grid-style.css +7 -13
- package/dist/collection/components/revo-grid/revo-grid.js +1668 -1638
- package/dist/collection/components/revo-grid/revo-grid.js.map +1 -0
- package/dist/collection/components/revo-grid/viewport.helpers.js +1 -0
- package/dist/collection/components/revo-grid/viewport.helpers.js.map +1 -0
- package/dist/collection/components/revo-grid/viewport.interfaces.js +1 -3
- package/dist/collection/components/revo-grid/viewport.interfaces.js.map +1 -0
- package/dist/collection/components/revo-grid/viewport.js +4 -7
- package/dist/collection/components/revo-grid/viewport.js.map +1 -0
- package/dist/collection/components/revo-grid/viewport.resize.service.js +3 -2
- package/dist/collection/components/revo-grid/viewport.resize.service.js.map +1 -0
- package/dist/collection/components/revo-grid/viewport.scrolling.service.js +1 -0
- package/dist/collection/components/revo-grid/viewport.scrolling.service.js.map +1 -0
- package/dist/collection/components/revo-grid/viewport.section.js +5 -7
- package/dist/collection/components/revo-grid/viewport.section.js.map +1 -0
- package/dist/collection/components/revo-grid/viewport.service.js +7 -6
- package/dist/collection/components/revo-grid/viewport.service.js.map +1 -0
- package/dist/collection/components/rowHeaders/revogr-row-headers.js +161 -147
- package/dist/collection/components/rowHeaders/revogr-row-headers.js.map +1 -0
- package/dist/collection/components/rowHeaders/row-header-render.js +1 -0
- package/dist/collection/components/rowHeaders/row-header-render.js.map +1 -0
- package/dist/collection/components/scroll/revogr-viewport-scroll-style.css +2 -4
- package/dist/collection/components/scroll/revogr-viewport-scroll.js +172 -168
- package/dist/collection/components/scroll/revogr-viewport-scroll.js.map +1 -0
- package/dist/collection/components/scrollable/revogr-scroll-virtual.js +159 -137
- package/dist/collection/components/scrollable/revogr-scroll-virtual.js.map +1 -0
- package/dist/collection/components/selection-focus/revogr-focus.js +153 -128
- package/dist/collection/components/selection-focus/revogr-focus.js.map +1 -0
- package/dist/collection/components/selection-temp-range/revogr-temp-range-style.css +1 -1
- package/dist/collection/components/selection-temp-range/revogr-temp-range.js +92 -77
- package/dist/collection/components/selection-temp-range/revogr-temp-range.js.map +1 -0
- package/dist/collection/global/global.js +3 -2
- package/dist/collection/global/global.js.map +1 -0
- package/dist/collection/index.js +1 -0
- package/dist/collection/index.js.map +1 -0
- package/dist/collection/plugins/autoSizeColumn.js +7 -6
- package/dist/collection/plugins/autoSizeColumn.js.map +1 -0
- package/dist/collection/plugins/basePlugin.js +1 -0
- package/dist/collection/plugins/basePlugin.js.map +1 -0
- package/dist/collection/plugins/dispatcher.js +1 -0
- package/dist/collection/plugins/dispatcher.js.map +1 -0
- package/dist/collection/plugins/export/csv.js +2 -1
- package/dist/collection/plugins/export/csv.js.map +1 -0
- package/dist/collection/plugins/export/export.plugin.js +6 -5
- package/dist/collection/plugins/export/export.plugin.js.map +1 -0
- package/dist/collection/plugins/export/types.js +1 -3
- package/dist/collection/plugins/export/types.js.map +1 -0
- package/dist/collection/plugins/filter/conditions/equal.js +1 -0
- package/dist/collection/plugins/filter/conditions/equal.js.map +1 -0
- package/dist/collection/plugins/filter/conditions/number/greaterThan.js +1 -0
- package/dist/collection/plugins/filter/conditions/number/greaterThan.js.map +1 -0
- package/dist/collection/plugins/filter/conditions/number/greaterThanOrEqual.js +3 -2
- package/dist/collection/plugins/filter/conditions/number/greaterThanOrEqual.js.map +1 -0
- package/dist/collection/plugins/filter/conditions/number/lessThan.js +1 -0
- package/dist/collection/plugins/filter/conditions/number/lessThan.js.map +1 -0
- package/dist/collection/plugins/filter/conditions/number/lessThanOrEqual.js +3 -2
- package/dist/collection/plugins/filter/conditions/number/lessThanOrEqual.js.map +1 -0
- package/dist/collection/plugins/filter/conditions/set.js +1 -0
- package/dist/collection/plugins/filter/conditions/set.js.map +1 -0
- package/dist/collection/plugins/filter/conditions/string/beginswith.js +1 -0
- package/dist/collection/plugins/filter/conditions/string/beginswith.js.map +1 -0
- package/dist/collection/plugins/filter/conditions/string/contains.js +1 -0
- package/dist/collection/plugins/filter/conditions/string/contains.js.map +1 -0
- package/dist/collection/plugins/filter/filter.button.js +7 -12
- package/dist/collection/plugins/filter/filter.button.js.map +1 -0
- package/dist/collection/plugins/filter/filter.plugin.js +5 -4
- package/dist/collection/plugins/filter/filter.plugin.js.map +1 -0
- package/dist/collection/plugins/filter/filter.pop.js +254 -238
- package/dist/collection/plugins/filter/filter.pop.js.map +1 -0
- package/dist/collection/plugins/filter/filter.service.js +9 -8
- package/dist/collection/plugins/filter/filter.service.js.map +1 -0
- package/dist/collection/plugins/filter/filter.style.css +2 -3
- package/dist/collection/plugins/filter/filter.types.js +1 -3
- package/dist/collection/plugins/filter/filter.types.js.map +1 -0
- package/dist/collection/plugins/groupingColumn/columnGroupsRenderer.js +6 -5
- package/dist/collection/plugins/groupingColumn/columnGroupsRenderer.js.map +1 -0
- package/dist/collection/plugins/groupingColumn/grouping.col.plugin.js +4 -3
- package/dist/collection/plugins/groupingColumn/grouping.col.plugin.js.map +1 -0
- package/dist/collection/plugins/groupingColumn/headerGroupRenderer.js +4 -3
- package/dist/collection/plugins/groupingColumn/headerGroupRenderer.js.map +1 -0
- package/dist/collection/plugins/groupingRow/grouping.const.js +2 -1
- package/dist/collection/plugins/groupingRow/grouping.const.js.map +1 -0
- package/dist/collection/plugins/groupingRow/grouping.row.expand.service.js +3 -2
- package/dist/collection/plugins/groupingRow/grouping.row.expand.service.js.map +1 -0
- package/dist/collection/plugins/groupingRow/grouping.row.plugin.js +14 -13
- package/dist/collection/plugins/groupingRow/grouping.row.plugin.js.map +1 -0
- package/dist/collection/plugins/groupingRow/grouping.row.renderer.js +6 -10
- package/dist/collection/plugins/groupingRow/grouping.row.renderer.js.map +1 -0
- package/dist/collection/plugins/groupingRow/grouping.row.types.js +1 -3
- package/dist/collection/plugins/groupingRow/grouping.row.types.js.map +1 -0
- package/dist/collection/plugins/groupingRow/grouping.service.js +2 -1
- package/dist/collection/plugins/groupingRow/grouping.service.js.map +1 -0
- package/dist/collection/plugins/groupingRow/grouping.trimmed.service.js +2 -1
- package/dist/collection/plugins/groupingRow/grouping.trimmed.service.js.map +1 -0
- package/dist/collection/plugins/moveColumn/columnDragPlugin.js +8 -7
- package/dist/collection/plugins/moveColumn/columnDragPlugin.js.map +1 -0
- package/dist/collection/plugins/moveColumn/columnOrderHandler.js +2 -1
- package/dist/collection/plugins/moveColumn/columnOrderHandler.js.map +1 -0
- package/dist/collection/plugins/sorting/sorting.plugin.js +8 -7
- package/dist/collection/plugins/sorting/sorting.plugin.js.map +1 -0
- package/dist/collection/plugins/sorting/sorting.sign.js +2 -1
- package/dist/collection/plugins/sorting/sorting.sign.js.map +1 -0
- package/dist/collection/plugins/stretchPlugin.js +4 -3
- package/dist/collection/plugins/stretchPlugin.js.map +1 -0
- package/dist/collection/plugins/trimmed/trimmed.plugin.js +1 -0
- package/dist/collection/plugins/trimmed/trimmed.plugin.js.map +1 -0
- package/dist/collection/services/cell.helpers.js +2 -1
- package/dist/collection/services/cell.helpers.js.map +1 -0
- package/dist/collection/services/column.data.provider.js +14 -13
- package/dist/collection/services/column.data.provider.js.map +1 -0
- package/dist/collection/services/data.provider.js +4 -3
- package/dist/collection/services/data.provider.js.map +1 -0
- package/dist/collection/services/dimension.provider.js +5 -4
- package/dist/collection/services/dimension.provider.js.map +1 -0
- package/dist/collection/services/localScrollService.js +2 -1
- package/dist/collection/services/localScrollService.js.map +1 -0
- package/dist/collection/services/resizable.directive.js +3 -4
- package/dist/collection/services/resizable.directive.js.map +1 -0
- package/dist/collection/services/selection.store.connector.js +3 -2
- package/dist/collection/services/selection.store.connector.js.map +1 -0
- package/dist/collection/services/viewport.provider.js +4 -3
- package/dist/collection/services/viewport.provider.js.map +1 -0
- package/dist/collection/store/dataSource/data.proxy.js +1 -0
- package/dist/collection/store/dataSource/data.proxy.js.map +1 -0
- package/dist/collection/store/dataSource/data.store.js +10 -9
- package/dist/collection/store/dataSource/data.store.js.map +1 -0
- package/dist/collection/store/dimension/dimension.helpers.js +5 -4
- package/dist/collection/store/dimension/dimension.helpers.js.map +1 -0
- package/dist/collection/store/dimension/dimension.store.js +9 -7
- package/dist/collection/store/dimension/dimension.store.js.map +1 -0
- package/dist/collection/store/selection/selection.helpers.js +2 -1
- package/dist/collection/store/selection/selection.helpers.js.map +1 -0
- package/dist/collection/store/selection/selection.store.js +4 -3
- package/dist/collection/store/selection/selection.store.js.map +1 -0
- package/dist/collection/store/selection/selection.store.service.js +2 -1
- package/dist/collection/store/selection/selection.store.service.js.map +1 -0
- package/dist/collection/store/storeTypes.js +1 -0
- package/dist/collection/store/storeTypes.js.map +1 -0
- package/dist/collection/store/viewPort/viewport.helpers.js +2 -1
- package/dist/collection/store/viewPort/viewport.helpers.js.map +1 -0
- package/dist/collection/store/viewPort/viewport.store.js +4 -3
- package/dist/collection/store/viewPort/viewport.store.js.map +1 -0
- package/dist/collection/themeManager/theme.compact.js +1 -0
- package/dist/collection/themeManager/theme.compact.js.map +1 -0
- package/dist/collection/themeManager/theme.default.js +1 -0
- package/dist/collection/themeManager/theme.default.js.map +1 -0
- package/dist/collection/themeManager/theme.material.js +1 -0
- package/dist/collection/themeManager/theme.material.js.map +1 -0
- package/dist/collection/themeManager/themeService.js +9 -8
- package/dist/collection/themeManager/themeService.js.map +1 -0
- package/dist/collection/utils/closestPolifill.js +1 -0
- package/dist/collection/utils/closestPolifill.js.map +1 -0
- package/dist/collection/utils/consts.js +1 -0
- package/dist/collection/utils/consts.js.map +1 -0
- package/dist/collection/utils/generateAlphabetHeader.js +1 -0
- package/dist/collection/utils/generateAlphabetHeader.js.map +1 -0
- package/dist/collection/utils/keyCodes.js +1 -0
- package/dist/collection/utils/keyCodes.js.map +1 -0
- package/dist/collection/utils/keyCodes.utils.js +4 -3
- package/dist/collection/utils/keyCodes.utils.js.map +1 -0
- package/dist/collection/utils/platform.js +1 -0
- package/dist/collection/utils/platform.js.map +1 -0
- package/dist/collection/utils/resizeObserver.js +1 -0
- package/dist/collection/utils/resizeObserver.js.map +1 -0
- package/dist/collection/utils/store.utils.js +1 -0
- package/dist/collection/utils/store.utils.js.map +1 -0
- package/dist/collection/utils/utils.js +1 -0
- package/dist/collection/utils/utils.js.map +1 -0
- package/dist/esm/{debounce-e4e6dd45.js → debounce-cb7aac48.js} +3 -1
- package/dist/esm/debounce-cb7aac48.js.map +1 -0
- package/dist/esm/{index-6f753b3c.js → index-f21f8a13.js} +667 -311
- package/dist/esm/index-f21f8a13.js.map +1 -0
- package/dist/esm/index.js +2 -0
- package/dist/esm/index.js.map +1 -0
- package/dist/esm/loader.js +6 -26
- package/dist/esm/loader.js.map +1 -0
- package/dist/esm/{resize-observer-00c48d78.js → resize-observer-4f34a839.js} +2 -0
- package/dist/esm/resize-observer-4f34a839.js.map +1 -0
- package/dist/esm/revo-grid.js +7 -61
- package/dist/esm/revo-grid.js.map +1 -0
- package/dist/esm/revo-grid_11.entry.js +169 -180
- package/dist/esm/revo-grid_11.entry.js.map +1 -0
- package/dist/esm/revogr-clipboard.entry.js +4 -3
- package/dist/esm/revogr-clipboard.entry.js.map +1 -0
- package/dist/esm/revogr-filter-panel.entry.js +11 -6
- package/dist/esm/revogr-filter-panel.entry.js.map +1 -0
- package/dist/esm-es5/{debounce-e4e6dd45.js → debounce-cb7aac48.js} +2 -1
- package/dist/esm-es5/debounce-cb7aac48.js.map +1 -0
- package/dist/esm-es5/index-f21f8a13.js +5 -0
- package/dist/esm-es5/index-f21f8a13.js.map +1 -0
- package/dist/esm-es5/index.js +1 -0
- package/dist/esm-es5/index.js.map +1 -0
- package/dist/esm-es5/loader.js +2 -1
- package/dist/esm-es5/loader.js.map +1 -0
- package/dist/esm-es5/{resize-observer-00c48d78.js → resize-observer-4f34a839.js} +2 -1
- package/dist/esm-es5/resize-observer-4f34a839.js.map +1 -0
- package/dist/esm-es5/revo-grid.js +2 -1
- package/dist/esm-es5/revo-grid.js.map +1 -0
- package/dist/esm-es5/revo-grid_11.entry.js +3 -2
- package/dist/esm-es5/revo-grid_11.entry.js.map +1 -0
- package/dist/esm-es5/revogr-clipboard.entry.js +3 -2
- package/dist/esm-es5/revogr-clipboard.entry.js.map +1 -0
- package/dist/esm-es5/revogr-filter-panel.entry.js +3 -2
- package/dist/esm-es5/revogr-filter-panel.entry.js.map +1 -0
- package/dist/revo-grid/{debounce-5a33c710.system.js → debounce-3aba7c4d.system.js} +2 -1
- package/dist/revo-grid/debounce-3aba7c4d.system.js.map +1 -0
- package/dist/revo-grid/debounce-cb7aac48.js +5 -0
- package/dist/revo-grid/debounce-cb7aac48.js.map +1 -0
- package/dist/revo-grid/index-20224007.system.js +6 -0
- package/dist/revo-grid/index-20224007.system.js.map +1 -0
- package/dist/revo-grid/index-f21f8a13.js +6 -0
- package/dist/revo-grid/index-f21f8a13.js.map +1 -0
- package/dist/revo-grid/index.esm.js +2 -0
- package/dist/revo-grid/index.esm.js.map +1 -0
- package/dist/revo-grid/index.system.js +2 -1
- package/dist/revo-grid/index.system.js.map +1 -0
- package/dist/revo-grid/{resize-observer-8af0bc0e.system.js → resize-observer-2a36c9e4.system.js} +2 -1
- package/dist/revo-grid/resize-observer-2a36c9e4.system.js.map +1 -0
- package/dist/revo-grid/resize-observer-4f34a839.js +5 -0
- package/dist/revo-grid/resize-observer-4f34a839.js.map +1 -0
- package/dist/revo-grid/revo-grid.esm.js +2 -1
- package/dist/revo-grid/revo-grid.esm.js.map +1 -0
- package/dist/revo-grid/revo-grid.js +1 -7
- package/dist/revo-grid/revo-grid.system.js +2 -1
- package/dist/revo-grid/revo-grid.system.js.map +1 -0
- package/dist/revo-grid/revo-grid_11.entry.js +2 -1
- package/dist/revo-grid/revo-grid_11.entry.js.map +1 -0
- package/dist/revo-grid/revo-grid_11.system.entry.js +3 -2
- package/dist/revo-grid/revo-grid_11.system.entry.js.map +1 -0
- package/dist/revo-grid/revogr-clipboard.entry.js +2 -1
- package/dist/revo-grid/revogr-clipboard.entry.js.map +1 -0
- package/dist/revo-grid/revogr-clipboard.system.entry.js +3 -2
- package/dist/revo-grid/revogr-clipboard.system.entry.js.map +1 -0
- package/dist/revo-grid/revogr-filter-panel.entry.js +2 -1
- package/dist/revo-grid/revogr-filter-panel.entry.js.map +1 -0
- package/dist/revo-grid/revogr-filter-panel.system.entry.js +3 -2
- package/dist/revo-grid/revogr-filter-panel.system.entry.js.map +1 -0
- package/dist/types/components/data/cellRenderer.d.ts +1 -1
- package/dist/types/components/data/columnService.d.ts +4 -4
- package/dist/types/components/header/headerCellRenderer.d.ts +1 -1
- package/dist/types/components/header/headerRenderer.d.ts +1 -1
- package/dist/types/components/order/orderRenderer.d.ts +1 -1
- package/dist/types/components/order/rowOrderService.d.ts +1 -1
- package/dist/types/components/overlay/autofill.service.d.ts +1 -1
- package/dist/types/components/overlay/clipboard.service.d.ts +1 -1
- package/dist/types/components/overlay/editors/text.d.ts +1 -1
- package/dist/types/components/overlay/keyboard.service.d.ts +1 -1
- package/dist/types/components/overlay/revogr-overlay-selection.d.ts +9 -3
- package/dist/types/components/overlay/selection.utils.d.ts +1 -1
- package/dist/types/components/revo-grid/viewport.d.ts +1 -1
- package/dist/types/components/revo-grid/viewport.interfaces.d.ts +5 -5
- package/dist/types/components/revo-grid/viewport.scrolling.service.d.ts +1 -1
- package/dist/types/components/revo-grid/viewport.section.d.ts +1 -1
- package/dist/types/components/revo-grid/viewport.service.d.ts +3 -3
- package/dist/types/components/rowHeaders/row-header-render.d.ts +1 -1
- package/dist/types/components.d.ts +26 -0
- package/dist/types/plugins/autoSizeColumn.d.ts +1 -1
- package/dist/types/plugins/dispatcher.d.ts +1 -1
- package/dist/types/plugins/export/csv.d.ts +1 -1
- package/dist/types/plugins/export/export.plugin.d.ts +1 -1
- package/dist/types/plugins/export/types.d.ts +2 -2
- package/dist/types/plugins/filter/filter.button.d.ts +1 -1
- package/dist/types/plugins/filter/filter.plugin.d.ts +6 -6
- package/dist/types/plugins/filter/filter.pop.d.ts +4 -4
- package/dist/types/plugins/filter/filter.service.d.ts +1 -1
- package/dist/types/plugins/filter/filter.types.d.ts +5 -5
- package/dist/types/plugins/groupingColumn/columnGroupsRenderer.d.ts +1 -1
- package/dist/types/plugins/groupingColumn/grouping.col.plugin.d.ts +1 -1
- package/dist/types/plugins/groupingColumn/headerGroupRenderer.d.ts +1 -1
- package/dist/types/plugins/groupingRow/grouping.row.renderer.d.ts +1 -1
- package/dist/types/plugins/groupingRow/grouping.row.types.d.ts +5 -5
- package/dist/types/plugins/groupingRow/grouping.service.d.ts +1 -1
- package/dist/types/plugins/moveColumn/columnDragPlugin.d.ts +5 -5
- package/dist/types/plugins/sorting/sorting.plugin.d.ts +1 -1
- package/dist/types/plugins/sorting/sorting.sign.d.ts +1 -1
- package/dist/types/plugins/trimmed/trimmed.plugin.d.ts +2 -2
- package/dist/types/services/column.data.provider.d.ts +4 -4
- package/dist/types/services/data.provider.d.ts +1 -1
- package/dist/types/services/dimension.provider.d.ts +2 -2
- package/dist/types/services/localScrollService.d.ts +1 -1
- package/dist/types/services/resizable.directive.d.ts +2 -2
- package/dist/types/services/selection.store.connector.d.ts +2 -2
- package/dist/types/services/viewport.provider.d.ts +1 -1
- package/dist/types/stencil-public-runtime.d.ts +95 -20
- package/dist/types/store/dataSource/data.proxy.d.ts +1 -1
- package/dist/types/store/dataSource/data.store.d.ts +4 -4
- package/dist/types/store/dimension/dimension.helpers.d.ts +3 -3
- package/dist/types/store/selection/selection.store.d.ts +1 -1
- package/dist/types/store/viewPort/viewport.helpers.d.ts +2 -2
- package/loader/index.d.ts +10 -1
- package/loader/package.json +1 -0
- package/package.json +10 -10
- package/dist/cjs/css-shim-9f5bc84d.js +0 -9
- package/dist/cjs/dom-fcb646f0.js +0 -78
- package/dist/esm/css-shim-e1e1ea5e.js +0 -7
- package/dist/esm/dom-21bd1807.js +0 -76
- package/dist/esm/polyfills/css-shim.js +0 -1
- package/dist/esm-es5/css-shim-e1e1ea5e.js +0 -4
- package/dist/esm-es5/dom-21bd1807.js +0 -24
- package/dist/esm-es5/index-6f753b3c.js +0 -4
- package/dist/revo-grid/css-shim-bcf89cc0.system.js +0 -4
- package/dist/revo-grid/css-shim-e1e1ea5e.js +0 -4
- package/dist/revo-grid/debounce-726bdadb.js +0 -4
- package/dist/revo-grid/dom-21bd1807.js +0 -22
- package/dist/revo-grid/dom-726246e2.system.js +0 -24
- package/dist/revo-grid/index-f14b41a0.system.js +0 -5
- package/dist/revo-grid/index-f30d1de1.js +0 -5
- package/dist/revo-grid/resize-observer-00c48d78.js +0 -4
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built by Revolist
|
|
3
3
|
*/
|
|
4
|
-
import{r as t,c as
|
|
4
|
+
import{r as t,c as s}from"./index-f21f8a13.js";const o=class{constructor(o){t(this,o);this.copyRegion=s(this,"copyRegion",3);this.pasteRegion=s(this,"pasteRegion",3)}onPaste(t){const s=this.getData(t);const o=s.types.indexOf("text/html")>-1;const n=o?s.getData("text/html"):s.getData("text");const r=o?this.htmlParse(n):this.textParse(n);this.pasteRegion.emit(r);t.preventDefault()}copyStarted(t){this.copyRegion.emit(this.getData(t));t.preventDefault()}async doCopy(t,s){t.setData("text/plain",s?this.parserCopy(s):"")}parserCopy(t){return t.map((t=>t.join("\t"))).join("\n")}textParse(t){const s=[];const o=t.split(/\r\n|\n|\r/);for(let t in o){s.push(o[t].split("\t"))}return s}htmlParse(t){const s=[];const o=document.createRange().createContextualFragment(t).querySelector("table");for(const t of Array.from(o.rows)){s.push(Array.from(t.cells).map((t=>t.innerText)))}return s}getData(t){return t.clipboardData||(window===null||window===void 0?void 0:window.clipboardData)}};export{o as revogr_clipboard};
|
|
5
|
+
//# sourceMappingURL=revogr-clipboard.entry.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["Clipboard","onPaste","e","clipboardData","this","getData","isHTML","types","indexOf","data","parsedData","htmlParse","textParse","pasteRegion","emit","preventDefault","copyStarted","copyRegion","doCopy","setData","parserCopy","map","rgRow","join","result","rows","split","y","push","table","document","createRange","createContextualFragment","querySelector","Array","from","cells","cell","innerText","window"],"sources":["src/components/clipboard/revogr-clipboard.tsx"],"sourcesContent":["import { Component, Listen, Method, Event, EventEmitter } from '@stencil/core';\nimport { RevoGrid } from '../../interfaces';\n\n@Component({ tag: 'revogr-clipboard' })\nexport class Clipboard {\n @Event({ bubbles: false }) copyRegion: EventEmitter<DataTransfer>;\n @Event({ bubbles: false }) pasteRegion: EventEmitter<string[][]>;\n @Listen('paste', { target: 'document' }) onPaste(e: ClipboardEvent) {\n const clipboardData = this.getData(e);\n const isHTML = clipboardData.types.indexOf('text/html') > -1;\n const data = isHTML ? clipboardData.getData('text/html') : clipboardData.getData('text');\n const parsedData = isHTML ? this.htmlParse(data) : this.textParse(data);\n this.pasteRegion.emit(parsedData);\n e.preventDefault();\n }\n @Listen('copy', { target: 'document' }) copyStarted(e: ClipboardEvent) {\n this.copyRegion.emit(this.getData(e));\n e.preventDefault();\n }\n @Method() async doCopy(e: DataTransfer, data?: RevoGrid.DataFormat[][]) {\n e.setData('text/plain', data ? this.parserCopy(data) : '');\n }\n\n parserCopy(data: RevoGrid.DataFormat[][]) {\n return data.map(rgRow => rgRow.join('\\t')).join('\\n');\n }\n\n private textParse(data: string) {\n const result: string[][] = [];\n const rows = data.split(/\\r\\n|\\n|\\r/);\n for (let y in rows) {\n result.push(rows[y].split('\\t'));\n }\n return result;\n }\n\n private htmlParse(data: string) {\n const result: string[][] = [];\n const table = document.createRange().createContextualFragment(data).querySelector('table');\n for (const rgRow of Array.from(table.rows)) {\n result.push(Array.from(rgRow.cells).map(cell => cell.innerText));\n }\n return result;\n }\n\n private getData(e: ClipboardEvent) {\n return e.clipboardData || ((window as unknown) as { clipboardData: DataTransfer | null })?.clipboardData;\n }\n}\n"],"mappings":";;;qDAIaA,EAAS,M,yGAGqB,OAAAC,CAAQC,GAC/C,MAAMC,EAAgBC,KAAKC,QAAQH,GACnC,MAAMI,EAASH,EAAcI,MAAMC,QAAQ,cAAgB,EAC3D,MAAMC,EAAOH,EAASH,EAAcE,QAAQ,aAAeF,EAAcE,QAAQ,QACjF,MAAMK,EAAaJ,EAASF,KAAKO,UAAUF,GAAQL,KAAKQ,UAAUH,GAClEL,KAAKS,YAAYC,KAAKJ,GACtBR,EAAEa,gB,CAEoC,WAAAC,CAAYd,GAClDE,KAAKa,WAAWH,KAAKV,KAAKC,QAAQH,IAClCA,EAAEa,gB,CAEM,YAAMG,CAAOhB,EAAiBO,GACtCP,EAAEiB,QAAQ,aAAcV,EAAOL,KAAKgB,WAAWX,GAAQ,G,CAGzD,UAAAW,CAAWX,GACT,OAAOA,EAAKY,KAAIC,GAASA,EAAMC,KAAK,QAAOA,KAAK,K,CAG1C,SAAAX,CAAUH,GAChB,MAAMe,EAAqB,GAC3B,MAAMC,EAAOhB,EAAKiB,MAAM,cACxB,IAAK,IAAIC,KAAKF,EAAM,CAClBD,EAAOI,KAAKH,EAAKE,GAAGD,MAAM,M,CAE5B,OAAOF,C,CAGD,SAAAb,CAAUF,GAChB,MAAMe,EAAqB,GAC3B,MAAMK,EAAQC,SAASC,cAAcC,yBAAyBvB,GAAMwB,cAAc,SAClF,IAAK,MAAMX,KAASY,MAAMC,KAAKN,EAAMJ,MAAO,CAC1CD,EAAOI,KAAKM,MAAMC,KAAKb,EAAMc,OAAOf,KAAIgB,GAAQA,EAAKC,Y,CAEvD,OAAOd,C,CAGD,OAAAnB,CAAQH,GACd,OAAOA,EAAEC,gBAAmBoC,SAA6D,MAA7DA,cAAM,SAANA,OAA+DpC,c"}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
var __awaiter=this&&this.__awaiter||function(t,e,r,n){function o(t){return t instanceof r?t:new r((function(e){e(t)}))}return new(r||(r=Promise))((function(r,a){function i(t){try{c(n.next(t))}catch(t){a(t)}}function u(t){try{c(n["throw"](t))}catch(t){a(t)}}function c(t){t.done?r(t.value):o(t.value).then(i,u)}c((n=n.apply(t,e||[])).next())}))};var __generator=this&&this.__generator||function(t,e){var r={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},n,o,a,i;return i={next:u(0),throw:u(1),return:u(2)},typeof Symbol==="function"&&(i[Symbol.iterator]=function(){return this}),i;function u(t){return function(e){return c([t,e])}}function c(
|
|
1
|
+
var __awaiter=this&&this.__awaiter||function(t,e,r,n){function o(t){return t instanceof r?t:new r((function(e){e(t)}))}return new(r||(r=Promise))((function(r,a){function i(t){try{c(n.next(t))}catch(t){a(t)}}function u(t){try{c(n["throw"](t))}catch(t){a(t)}}function c(t){t.done?r(t.value):o(t.value).then(i,u)}c((n=n.apply(t,e||[])).next())}))};var __generator=this&&this.__generator||function(t,e){var r={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},n,o,a,i;return i={next:u(0),throw:u(1),return:u(2)},typeof Symbol==="function"&&(i[Symbol.iterator]=function(){return this}),i;function u(t){return function(e){return c([t,e])}}function c(u){if(n)throw new TypeError("Generator is already executing.");while(i&&(i=0,u[0]&&(r=0)),r)try{if(n=1,o&&(a=u[0]&2?o["return"]:u[0]?o["throw"]||((a=o["return"])&&a.call(o),0):o.next)&&!(a=a.call(o,u[1])).done)return a;if(o=0,a)u=[u[0]&2,a.value];switch(u[0]){case 0:case 1:a=u;break;case 4:r.label++;return{value:u[1],done:false};case 5:r.label++;o=u[1];u=[0];continue;case 7:u=r.ops.pop();r.trys.pop();continue;default:if(!(a=r.trys,a=a.length>0&&a[a.length-1])&&(u[0]===6||u[0]===2)){r=0;continue}if(u[0]===3&&(!a||u[1]>a[0]&&u[1]<a[3])){r.label=u[1];break}if(u[0]===6&&r.label<a[1]){r.label=a[1];a=u;break}if(a&&r.label<a[2]){r.label=a[2];r.ops.push(u);break}if(a[2])r.ops.pop();r.trys.pop();continue}u=e.call(t,r)}catch(t){u=[6,t];o=0}finally{n=a=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:true}}};
|
|
2
2
|
/*!
|
|
3
3
|
* Built by Revolist
|
|
4
|
-
*/System.register(["./index-
|
|
4
|
+
*/System.register(["./index-20224007.system.js"],(function(t){"use strict";var e,r;return{setters:[function(t){e=t.r;r=t.c}],execute:function(){var n=t("revogr_clipboard",function(){function t(t){e(this,t);this.copyRegion=r(this,"copyRegion",3);this.pasteRegion=r(this,"pasteRegion",3)}t.prototype.onPaste=function(t){var e=this.getData(t);var r=e.types.indexOf("text/html")>-1;var n=r?e.getData("text/html"):e.getData("text");var o=r?this.htmlParse(n):this.textParse(n);this.pasteRegion.emit(o);t.preventDefault()};t.prototype.copyStarted=function(t){this.copyRegion.emit(this.getData(t));t.preventDefault()};t.prototype.doCopy=function(t,e){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(r){t.setData("text/plain",e?this.parserCopy(e):"");return[2]}))}))};t.prototype.parserCopy=function(t){return t.map((function(t){return t.join("\t")})).join("\n")};t.prototype.textParse=function(t){var e=[];var r=t.split(/\r\n|\n|\r/);for(var n in r){e.push(r[n].split("\t"))}return e};t.prototype.htmlParse=function(t){var e=[];var r=document.createRange().createContextualFragment(t).querySelector("table");for(var n=0,o=Array.from(r.rows);n<o.length;n++){var a=o[n];e.push(Array.from(a.cells).map((function(t){return t.innerText})))}return e};t.prototype.getData=function(t){return t.clipboardData||(window===null||window===void 0?void 0:window.clipboardData)};return t}())}}}));
|
|
5
|
+
//# sourceMappingURL=revogr-clipboard.system.entry.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["Clipboard","exports","class_1","prototype","onPaste","e","clipboardData","this","getData","isHTML","types","indexOf","data","parsedData","htmlParse","textParse","pasteRegion","emit","preventDefault","copyStarted","copyRegion","doCopy","setData","parserCopy","map","rgRow","join","result","rows","split","y","push","table","document","createRange","createContextualFragment","querySelector","_i","_a","Array","from","length","cells","cell","innerText","window"],"sources":["src/components/clipboard/revogr-clipboard.tsx"],"sourcesContent":["import { Component, Listen, Method, Event, EventEmitter } from '@stencil/core';\nimport { RevoGrid } from '../../interfaces';\n\n@Component({ tag: 'revogr-clipboard' })\nexport class Clipboard {\n @Event({ bubbles: false }) copyRegion: EventEmitter<DataTransfer>;\n @Event({ bubbles: false }) pasteRegion: EventEmitter<string[][]>;\n @Listen('paste', { target: 'document' }) onPaste(e: ClipboardEvent) {\n const clipboardData = this.getData(e);\n const isHTML = clipboardData.types.indexOf('text/html') > -1;\n const data = isHTML ? clipboardData.getData('text/html') : clipboardData.getData('text');\n const parsedData = isHTML ? this.htmlParse(data) : this.textParse(data);\n this.pasteRegion.emit(parsedData);\n e.preventDefault();\n }\n @Listen('copy', { target: 'document' }) copyStarted(e: ClipboardEvent) {\n this.copyRegion.emit(this.getData(e));\n e.preventDefault();\n }\n @Method() async doCopy(e: DataTransfer, data?: RevoGrid.DataFormat[][]) {\n e.setData('text/plain', data ? this.parserCopy(data) : '');\n }\n\n parserCopy(data: RevoGrid.DataFormat[][]) {\n return data.map(rgRow => rgRow.join('\\t')).join('\\n');\n }\n\n private textParse(data: string) {\n const result: string[][] = [];\n const rows = data.split(/\\r\\n|\\n|\\r/);\n for (let y in rows) {\n result.push(rows[y].split('\\t'));\n }\n return result;\n }\n\n private htmlParse(data: string) {\n const result: string[][] = [];\n const table = document.createRange().createContextualFragment(data).querySelector('table');\n for (const rgRow of Array.from(table.rows)) {\n result.push(Array.from(rgRow.cells).map(cell => cell.innerText));\n }\n return result;\n }\n\n private getData(e: ClipboardEvent) {\n return e.clipboardData || ((window as unknown) as { clipboardData: DataTransfer | null })?.clipboardData;\n }\n}\n"],"mappings":";;;qJAIaA,EAASC,EAAA,8B,wGAGqBC,EAAAC,UAAAC,QAAA,SAAQC,GAC/C,IAAMC,EAAgBC,KAAKC,QAAQH,GACnC,IAAMI,EAASH,EAAcI,MAAMC,QAAQ,cAAgB,EAC3D,IAAMC,EAAOH,EAASH,EAAcE,QAAQ,aAAeF,EAAcE,QAAQ,QACjF,IAAMK,EAAaJ,EAASF,KAAKO,UAAUF,GAAQL,KAAKQ,UAAUH,GAClEL,KAAKS,YAAYC,KAAKJ,GACtBR,EAAEa,gB,EAEoChB,EAAAC,UAAAgB,YAAA,SAAYd,GAClDE,KAAKa,WAAWH,KAAKV,KAAKC,QAAQH,IAClCA,EAAEa,gB,EAEYhB,EAAAC,UAAAkB,OAAN,SAAahB,EAAiBO,G,qFACtCP,EAAEiB,QAAQ,aAAcV,EAAOL,KAAKgB,WAAWX,GAAQ,I,iBAGzDV,EAAAC,UAAAoB,WAAA,SAAWX,GACT,OAAOA,EAAKY,KAAI,SAAAC,GAAS,OAAAA,EAAMC,KAAK,KAAX,IAAkBA,KAAK,K,EAG1CxB,EAAAC,UAAAY,UAAA,SAAUH,GAChB,IAAMe,EAAqB,GAC3B,IAAMC,EAAOhB,EAAKiB,MAAM,cACxB,IAAK,IAAIC,KAAKF,EAAM,CAClBD,EAAOI,KAAKH,EAAKE,GAAGD,MAAM,M,CAE5B,OAAOF,C,EAGDzB,EAAAC,UAAAW,UAAA,SAAUF,GAChB,IAAMe,EAAqB,GAC3B,IAAMK,EAAQC,SAASC,cAAcC,yBAAyBvB,GAAMwB,cAAc,SAClF,IAAoB,IAAAC,EAAA,EAAAC,EAAAC,MAAMC,KAAKR,EAAMJ,MAAjBS,EAAAC,EAAAG,OAAAJ,IAAwB,CAAvC,IAAMZ,EAAKa,EAAAD,GACdV,EAAOI,KAAKQ,MAAMC,KAAKf,EAAMiB,OAAOlB,KAAI,SAAAmB,GAAQ,OAAAA,EAAKC,SAAL,I,CAElD,OAAOjB,C,EAGDzB,EAAAC,UAAAK,QAAA,SAAQH,GACd,OAAOA,EAAEC,gBAAmBuC,SAA6D,MAA7DA,cAAM,SAANA,OAA+DvC,c,WA1CzE,G"}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built by Revolist
|
|
3
3
|
*/
|
|
4
|
-
import{h as t,r as e,c as i,H as s}from"./index-f30d1de1.js";import{j as o,g as r,A as n,T as l}from"./debounce-726bdadb.js";const a=(e,i)=>t("button",Object.assign({},e,{class:Object.assign(Object.assign({},"object"==typeof e.class?e.class:e.class?{[e.class]:!0}:""),{"revo-button":!0})}),i);Element.prototype.matches||(Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector),Element.prototype.closest||(Element.prototype.closest=function(t){let e=this;do{if(Element.prototype.matches.call(e,t))return e;e=e.parentElement||e.parentNode}while(null!==e&&1===e.nodeType);return null});const d=class{constructor(t){e(this,t),this.filterChange=i(this,"filterChange",7),this.filterCaptionsInternal={title:"Filter by condition",save:"Save",reset:"Reset",cancel:"Close"},this.isFilterIdSet=!1,this.filterId=0,this.currentFilterId=-1,this.currentFilterType="none",this.filterItems={},this.filterTypes={},this.filterNames={},this.filterEntities={},this.disableDynamicFiltering=!1,this.debouncedApplyFilter=o((()=>{this.filterChange.emit(this.filterItems)}),400)}onMouseDown(t){if(this.changes&&!t.defaultPrevented){const e=t.target;this.isOutside(e)&&!r(e)&&(this.changes=void 0)}}async show(t){this.changes=t,this.changes&&(this.changes.type=this.changes.type||"none")}async getChanges(){return this.changes}componentWillRender(){if(!this.isFilterIdSet){this.isFilterIdSet=!0;const t=Object.keys(this.filterItems);for(const e of t)this.filterId+=this.filterItems[e].length}}renderSelectOptions(e,i=!1){var s;const o=[],r=null===(s=this.changes)||void 0===s?void 0:s.prop;i||o.push(t("option",{selected:"none"===this.currentFilterType,value:"none"},r&&this.filterItems[r]&&this.filterItems[r].length>0?"Add more condition...":this.filterNames.none));for(let i in this.filterTypes)o.push(...this.filterTypes[i].map((i=>t("option",{value:i,selected:e===i},this.filterNames[i])))),o.push(t("option",{disabled:!0}));return o}renderExtra(e,i){const s=this.filterItems[e];return s?"input"!==this.filterEntities[s[i].type].extra?"":t("input",{id:`filter-input-${s[i].id}`,placeholder:"Enter value...",type:"text",value:s[i].value,onInput:this.onUserInput.bind(this,i,e),onKeyDown:t=>this.onKeyDown(t)}):""}getFilterItemsList(){var e;const i=null===(e=this.changes)||void 0===e?void 0:e.prop;if(!i&&0!==i)return"";const s=this.filterItems[i]||[];return t("div",{key:this.filterId},s.map(((e,s)=>{let o;return s!==this.filterItems[i].length-1&&(o=t("div",{onClick:()=>this.toggleFilterAndOr(e.id)},t(n,{isAnd:"and"===e.relation}))),t("div",{key:e.id,class:"multi-filter-list"},t("div",{class:{"select-input":!0}},t("select",{class:"select-css select-filter",onChange:t=>this.onFilterTypeChange(t,i,s)},this.renderSelectOptions(this.filterItems[i][s].type,!0)),t("div",{class:"multi-filter-list-action"},o),t("div",{onClick:()=>this.onRemoveFilter(e.id)},t(l,null))),t("div",null,this.renderExtra(i,s)))})),s.length>0?t("div",{class:"add-filter-divider"}):"")}render(){if(!this.changes)return t(s,{style:{display:"none"}});const e={display:"block",left:`${this.changes.x}px`,top:`${this.changes.y}px`},i=Object.assign(this.filterCaptionsInternal,this.filterCaptions);return t(s,{style:e},t("label",null,i.title),t("div",{class:"filter-holder"},this.getFilterItemsList()),t("div",{class:"add-filter"},t("select",{id:"add-filter",class:"select-css",onChange:t=>this.onAddNewFilter(t)},this.renderSelectOptions(this.currentFilterType))),t("div",{class:"filter-actions"},this.disableDynamicFiltering&&t(a,{class:{red:!0,save:!0},onClick:()=>this.onSave()},i.save),t(a,{class:{red:!0,reset:!0},onClick:()=>this.onReset()},i.reset),t(a,{class:{light:!0,cancel:!0},onClick:()=>this.onCancel()},i.cancel)))}onFilterTypeChange(t,e,i){this.filterItems[e][i].type=t.target.value,this.filterId++,setTimeout((()=>{const t=document.getElementById("filter-input-"+this.filterItems[e][i].id);t&&t.focus()}),0),this.disableDynamicFiltering||this.debouncedApplyFilter()}onAddNewFilter(t){this.currentFilterType=t.target.value,this.addNewFilterToProp();const e=document.getElementById("add-filter");e&&(e.value="none",this.currentFilterType="none"),this.disableDynamicFiltering||this.debouncedApplyFilter()}addNewFilterToProp(){var t;const e=null===(t=this.changes)||void 0===t?void 0:t.prop;(e||0===e)&&(this.filterItems[e]||(this.filterItems[e]=[]),"none"!==this.currentFilterType&&(this.filterId++,this.currentFilterId=this.filterId,this.filterItems[e].push({id:this.currentFilterId,type:this.currentFilterType,value:"",relation:"and"}),setTimeout((()=>{const t=document.getElementById("filter-input-"+this.currentFilterId);t&&t.focus()}),0)))}onUserInput(t,e,i){this.filterItems[e][t].value=i.target.value,this.disableDynamicFiltering||this.debouncedApplyFilter()}onKeyDown(t){if("enter"!==t.key.toLowerCase())t.stopPropagation();else{const t=document.getElementById("add-filter");t&&(t.value="none",this.currentFilterType="none",this.addNewFilterToProp(),t.focus())}}onSave(){this.filterChange.emit(this.filterItems)}onCancel(){this.changes=void 0}onReset(){this.assertChanges(),delete this.filterItems[this.changes.prop],this.filterId++,this.filterChange.emit(this.filterItems)}onRemoveFilter(t){this.assertChanges(),this.filterId++;const e=this.changes.prop,i=this.filterItems[e];if(!i)return;const s=i.findIndex((e=>e.id===t));-1!==s&&(i.splice(s,1),0===i.length&&delete this.filterItems[e],this.disableDynamicFiltering||this.debouncedApplyFilter())}toggleFilterAndOr(t){this.assertChanges(),this.filterId++;const e=this.filterItems[this.changes.prop];if(!e)return;const i=e.findIndex((e=>e.id===t));-1!==i&&(e[i].relation="and"===e[i].relation?"or":"and",this.disableDynamicFiltering||this.debouncedApplyFilter())}assertChanges(){if(!this.changes)throw new Error("Changes required per edit")}isOutside(t){const e=document.getElementById("add-filter");return e&&(e.value="none"),this.currentFilterType="none",this.changes.type="none",this.currentFilterId=-1,!t.classList.contains(`[uuid="${this.uuid}"]`)&&!(null==t?void 0:t.closest(`[uuid="${this.uuid}"]`))}};d.style=".revo-drag-icon{-webkit-mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 438 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M421.875,70.40625 C426.432292,70.40625 430.175781,68.9414062 433.105469,66.0117188 C436.035156,63.0820312 437.5,59.3385417 437.5,54.78125 L437.5,54.78125 L437.5,15.71875 C437.5,11.1614583 436.035156,7.41796875 433.105469,4.48828125 C430.175781,1.55859375 426.432292,0.09375 421.875,0.09375 L421.875,0.09375 L15.625,0.09375 C11.0677083,0.09375 7.32421875,1.55859375 4.39453125,4.48828125 C1.46484375,7.41796875 0,11.1614583 0,15.71875 L0,15.71875 L0,54.78125 C0,59.3385417 1.46484375,63.0820312 4.39453125,66.0117188 C7.32421875,68.9414062 11.0677083,70.40625 15.625,70.40625 L15.625,70.40625 L421.875,70.40625 Z M421.875,226.65625 C426.432292,226.65625 430.175781,225.191406 433.105469,222.261719 C436.035156,219.332031 437.5,215.588542 437.5,211.03125 L437.5,211.03125 L437.5,171.96875 C437.5,167.411458 436.035156,163.667969 433.105469,160.738281 C430.175781,157.808594 426.432292,156.34375 421.875,156.34375 L421.875,156.34375 L15.625,156.34375 C11.0677083,156.34375 7.32421875,157.808594 4.39453125,160.738281 C1.46484375,163.667969 0,167.411458 0,171.96875 L0,171.96875 L0,211.03125 C0,215.588542 1.46484375,219.332031 4.39453125,222.261719 C7.32421875,225.191406 11.0677083,226.65625 15.625,226.65625 L15.625,226.65625 L421.875,226.65625 Z M421.875,382.90625 C426.432292,382.90625 430.175781,381.441406 433.105469,378.511719 C436.035156,375.582031 437.5,371.838542 437.5,367.28125 L437.5,367.28125 L437.5,328.21875 C437.5,323.661458 436.035156,319.917969 433.105469,316.988281 C430.175781,314.058594 426.432292,312.59375 421.875,312.59375 L421.875,312.59375 L15.625,312.59375 C11.0677083,312.59375 7.32421875,314.058594 4.39453125,316.988281 C1.46484375,319.917969 0,323.661458 0,328.21875 L0,328.21875 L0,367.28125 C0,371.838542 1.46484375,375.582031 4.39453125,378.511719 C7.32421875,381.441406 11.0677083,382.90625 15.625,382.90625 L15.625,382.90625 L421.875,382.90625 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 438 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M421.875,70.40625 C426.432292,70.40625 430.175781,68.9414062 433.105469,66.0117188 C436.035156,63.0820312 437.5,59.3385417 437.5,54.78125 L437.5,54.78125 L437.5,15.71875 C437.5,11.1614583 436.035156,7.41796875 433.105469,4.48828125 C430.175781,1.55859375 426.432292,0.09375 421.875,0.09375 L421.875,0.09375 L15.625,0.09375 C11.0677083,0.09375 7.32421875,1.55859375 4.39453125,4.48828125 C1.46484375,7.41796875 0,11.1614583 0,15.71875 L0,15.71875 L0,54.78125 C0,59.3385417 1.46484375,63.0820312 4.39453125,66.0117188 C7.32421875,68.9414062 11.0677083,70.40625 15.625,70.40625 L15.625,70.40625 L421.875,70.40625 Z M421.875,226.65625 C426.432292,226.65625 430.175781,225.191406 433.105469,222.261719 C436.035156,219.332031 437.5,215.588542 437.5,211.03125 L437.5,211.03125 L437.5,171.96875 C437.5,167.411458 436.035156,163.667969 433.105469,160.738281 C430.175781,157.808594 426.432292,156.34375 421.875,156.34375 L421.875,156.34375 L15.625,156.34375 C11.0677083,156.34375 7.32421875,157.808594 4.39453125,160.738281 C1.46484375,163.667969 0,167.411458 0,171.96875 L0,171.96875 L0,211.03125 C0,215.588542 1.46484375,219.332031 4.39453125,222.261719 C7.32421875,225.191406 11.0677083,226.65625 15.625,226.65625 L15.625,226.65625 L421.875,226.65625 Z M421.875,382.90625 C426.432292,382.90625 430.175781,381.441406 433.105469,378.511719 C436.035156,375.582031 437.5,371.838542 437.5,367.28125 L437.5,367.28125 L437.5,328.21875 C437.5,323.661458 436.035156,319.917969 433.105469,316.988281 C430.175781,314.058594 426.432292,312.59375 421.875,312.59375 L421.875,312.59375 L15.625,312.59375 C11.0677083,312.59375 7.32421875,314.058594 4.39453125,316.988281 C1.46484375,319.917969 0,323.661458 0,328.21875 L0,328.21875 L0,367.28125 C0,371.838542 1.46484375,375.582031 4.39453125,378.511719 C7.32421875,381.441406 11.0677083,382.90625 15.625,382.90625 L15.625,382.90625 L421.875,382.90625 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");width:11px;height:7px;background-size:cover;background-repeat:no-repeat}.revo-alt-icon{-webkit-mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 384 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M192.4375,383 C197.424479,383 201.663411,381.254557 205.154297,377.763672 L205.154297,377.763672 L264.25,318.667969 C270.234375,312.683594 271.605794,306.075846 268.364258,298.844727 C265.122721,291.613607 259.51237,287.998047 251.533203,287.998047 L251.533203,287.998047 L213.382812,287.998047 L213.382812,212.445312 L288.935547,212.445312 L288.935547,250.595703 C288.935547,258.57487 292.551107,264.185221 299.782227,267.426758 C307.013346,270.668294 313.621094,269.296875 319.605469,263.3125 L319.605469,263.3125 L378.701172,204.216797 C382.192057,200.725911 383.9375,196.486979 383.9375,191.5 C383.9375,186.513021 382.192057,182.274089 378.701172,178.783203 L378.701172,178.783203 L319.605469,119.6875 C313.621094,114.201823 307.013346,112.955078 299.782227,115.947266 C292.551107,118.939453 288.935547,124.42513 288.935547,132.404297 L288.935547,132.404297 L288.935547,170.554688 L213.382812,170.554688 L213.382812,95.0019531 L251.533203,95.0019531 C259.51237,95.0019531 264.998047,91.3863932 267.990234,84.1552734 C270.982422,76.9241536 269.735677,70.3164062 264.25,64.3320312 L264.25,64.3320312 L205.154297,5.23632812 C201.663411,1.74544271 197.424479,0 192.4375,0 C187.450521,0 183.211589,1.74544271 179.720703,5.23632812 L179.720703,5.23632812 L120.625,64.3320312 C114.640625,70.3164062 113.269206,76.9241536 116.510742,84.1552734 C119.752279,91.3863932 125.36263,95.0019531 133.341797,95.0019531 L133.341797,95.0019531 L171.492188,95.0019531 L171.492188,170.554688 L95.9394531,170.554688 L95.9394531,132.404297 C95.9394531,124.42513 92.3238932,118.814779 85.0927734,115.573242 C77.8616536,112.331706 71.2539062,113.703125 65.2695312,119.6875 L65.2695312,119.6875 L6.17382812,178.783203 C2.68294271,182.274089 0.9375,186.513021 0.9375,191.5 C0.9375,196.486979 2.68294271,200.725911 6.17382812,204.216797 L6.17382812,204.216797 L65.2695312,263.3125 C71.2539062,268.798177 77.8616536,270.044922 85.0927734,267.052734 C92.3238932,264.060547 95.9394531,258.57487 95.9394531,250.595703 L95.9394531,250.595703 L95.9394531,212.445312 L171.492188,212.445312 L171.492188,287.998047 L133.341797,287.998047 C125.36263,287.998047 119.876953,291.613607 116.884766,298.844727 C113.892578,306.075846 115.139323,312.683594 120.625,318.667969 L120.625,318.667969 L179.720703,377.763672 C183.211589,381.254557 187.450521,383 192.4375,383 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 384 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M192.4375,383 C197.424479,383 201.663411,381.254557 205.154297,377.763672 L205.154297,377.763672 L264.25,318.667969 C270.234375,312.683594 271.605794,306.075846 268.364258,298.844727 C265.122721,291.613607 259.51237,287.998047 251.533203,287.998047 L251.533203,287.998047 L213.382812,287.998047 L213.382812,212.445312 L288.935547,212.445312 L288.935547,250.595703 C288.935547,258.57487 292.551107,264.185221 299.782227,267.426758 C307.013346,270.668294 313.621094,269.296875 319.605469,263.3125 L319.605469,263.3125 L378.701172,204.216797 C382.192057,200.725911 383.9375,196.486979 383.9375,191.5 C383.9375,186.513021 382.192057,182.274089 378.701172,178.783203 L378.701172,178.783203 L319.605469,119.6875 C313.621094,114.201823 307.013346,112.955078 299.782227,115.947266 C292.551107,118.939453 288.935547,124.42513 288.935547,132.404297 L288.935547,132.404297 L288.935547,170.554688 L213.382812,170.554688 L213.382812,95.0019531 L251.533203,95.0019531 C259.51237,95.0019531 264.998047,91.3863932 267.990234,84.1552734 C270.982422,76.9241536 269.735677,70.3164062 264.25,64.3320312 L264.25,64.3320312 L205.154297,5.23632812 C201.663411,1.74544271 197.424479,0 192.4375,0 C187.450521,0 183.211589,1.74544271 179.720703,5.23632812 L179.720703,5.23632812 L120.625,64.3320312 C114.640625,70.3164062 113.269206,76.9241536 116.510742,84.1552734 C119.752279,91.3863932 125.36263,95.0019531 133.341797,95.0019531 L133.341797,95.0019531 L171.492188,95.0019531 L171.492188,170.554688 L95.9394531,170.554688 L95.9394531,132.404297 C95.9394531,124.42513 92.3238932,118.814779 85.0927734,115.573242 C77.8616536,112.331706 71.2539062,113.703125 65.2695312,119.6875 L65.2695312,119.6875 L6.17382812,178.783203 C2.68294271,182.274089 0.9375,186.513021 0.9375,191.5 C0.9375,196.486979 2.68294271,200.725911 6.17382812,204.216797 L6.17382812,204.216797 L65.2695312,263.3125 C71.2539062,268.798177 77.8616536,270.044922 85.0927734,267.052734 C92.3238932,264.060547 95.9394531,258.57487 95.9394531,250.595703 L95.9394531,250.595703 L95.9394531,212.445312 L171.492188,212.445312 L171.492188,287.998047 L133.341797,287.998047 C125.36263,287.998047 119.876953,291.613607 116.884766,298.844727 C113.892578,306.075846 115.139323,312.683594 120.625,318.667969 L120.625,318.667969 L179.720703,377.763672 C183.211589,381.254557 187.450521,383 192.4375,383 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");width:11px;height:11px;background-size:cover;background-repeat:no-repeat}.arrow-down{position:absolute;right:5px;top:0}.arrow-down svg{width:8px;margin-top:5px;margin-left:5px;opacity:0.4}.cell-value-wrapper{margin-right:10px;overflow:hidden;text-overflow:ellipsis}.revo-button{position:relative;overflow:hidden;color:#fff;background-color:#6200ee;height:34px;line-height:34px;padding:0 15px;outline:0;border:0;border-radius:7px;box-sizing:border-box;cursor:pointer}.revo-button.green{background-color:#2ee072;border:1px solid #20d565}.revo-button.red{background-color:#E0662E;border:1px solid #d55920}.revo-button:disabled,.revo-button[disabled]{cursor:not-allowed !important;filter:opacity(0.35) !important}.revo-button.light{border:2px solid #cedefa;line-height:32px;background:none;color:#4876ca;box-shadow:none}revogr-filter-panel{position:absolute;display:block;top:0;left:0;z-index:100;opacity:1;transform:none;background-color:#fff;transform-origin:62px 0px;box-shadow:0 5px 18px -2px rgba(0, 0, 0, 0.2);padding:10px;border-radius:4px;min-width:220px;text-align:left}revogr-filter-panel .filter-holder>div{display:flex;flex-direction:column}revogr-filter-panel label{color:gray;font-size:13px;font-weight:600;display:block;padding:8px 0}revogr-filter-panel select{width:100%}revogr-filter-panel input[type=text]{border:0;min-height:34px;margin:5px 0;background:#f3f3f3;border-radius:5px;padding:0 10px;box-sizing:border-box;width:100%}revogr-filter-panel button{margin-top:10px;margin-right:5px}revogr-filter-panel .filter-actions{text-align:right;margin-right:-5px}.rgHeaderCell:hover .rv-filter{transition:opacity 267ms cubic-bezier(0.4, 0, 0.2, 1) 0ms, transform 178ms cubic-bezier(0.4, 0, 0.2, 1) 0ms}.rgHeaderCell:hover .rv-filter,.rgHeaderCell .rv-filter.active{opacity:1}.rgHeaderCell .rv-filter{height:24px;width:24px;background:none;border:0;opacity:0;visibility:visible;cursor:pointer;border-radius:4px}.rgHeaderCell .rv-filter.active{color:#10224a}.rgHeaderCell .rv-filter .filter-img{color:gray;width:11px}.select-css{display:block;font-family:sans-serif;font-weight:600;color:#444;line-height:1.3;padding:0.6em 1.4em 0.5em 0.8em;width:100%;max-width:100%;box-sizing:border-box;margin:0;border:1px solid #f1f1f1;box-shadow:transparent;border-radius:0.5em;appearance:none;background-color:#fff;background-image:url(\"data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%23007CB2%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E\"), linear-gradient(to bottom, #ffffff 0%, #ffffff 100%);background-repeat:no-repeat, repeat;background-position:right 0.7em top 50%, 0 0;background-size:0.65em auto, 100%;}.select-css::-ms-expand{display:none}.select-css:hover{border-color:#c5c5c5}.select-css:focus{border-color:#f1f1f1;box-shadow:0 0 1px 3px rgba(59, 153, 252, 0.7);box-shadow:0 0 0 3px -moz-mac-focusring;color:#222;outline:none}.select-css option{font-weight:normal}.select-css:disabled,.select-css[aria-disabled=true]{color:gray;background-image:url(\"data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22graytext%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E\"), linear-gradient(to bottom, #ffffff 0%, #ffffff 100%)}.select-css:disabled:hover,.select-css[aria-disabled=true]{border-color:#f1f1f1}.multi-filter-list{margin-top:5px;margin-bottom:5px}.multi-filter-list div{white-space:nowrap}.multi-filter-list .multi-filter-list-action{display:flex;justify-content:space-between;align-items:center}.multi-filter-list .and-or-button{margin:0 0 0 10px;min-width:58px;cursor:pointer}.multi-filter-list .trash-button{margin:0 0 -2px 6px;cursor:pointer;width:22px;height:22px;color:gray;font-size:18px}.multi-filter-list .trash-button .trash-img{width:1em}.add-filter-divider{display:block;margin:0 -10px 10px -10px;border-bottom:1px solid #d9d9d9;height:10px;box-shadow:0 4px 5px rgba(0, 0, 0, 0.05)}.select-input{display:flex;justify-content:space-between;align-items:center}";export{d as revogr_filter_panel}
|
|
4
|
+
import{h as t,r as i,c as e,H as s}from"./index-f21f8a13.js";import{j as r,g as o,A as n,T as l}from"./debounce-cb7aac48.js";const a=(i,e)=>t("button",Object.assign({},i,{class:Object.assign(Object.assign({},typeof i.class==="object"?i.class:i.class?{[i.class]:true}:""),{["revo-button"]:true})}),e);(function t(){if(!Element.prototype.matches){Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector}if(!Element.prototype.closest){Element.prototype.closest=function(t){let i=this;do{if(Element.prototype.matches.call(i,t)){return i}i=i.parentElement||i.parentNode}while(i!==null&&i.nodeType===1);return null}}})();const d=".revo-drag-icon{-webkit-mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 438 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M421.875,70.40625 C426.432292,70.40625 430.175781,68.9414062 433.105469,66.0117188 C436.035156,63.0820312 437.5,59.3385417 437.5,54.78125 L437.5,54.78125 L437.5,15.71875 C437.5,11.1614583 436.035156,7.41796875 433.105469,4.48828125 C430.175781,1.55859375 426.432292,0.09375 421.875,0.09375 L421.875,0.09375 L15.625,0.09375 C11.0677083,0.09375 7.32421875,1.55859375 4.39453125,4.48828125 C1.46484375,7.41796875 0,11.1614583 0,15.71875 L0,15.71875 L0,54.78125 C0,59.3385417 1.46484375,63.0820312 4.39453125,66.0117188 C7.32421875,68.9414062 11.0677083,70.40625 15.625,70.40625 L15.625,70.40625 L421.875,70.40625 Z M421.875,226.65625 C426.432292,226.65625 430.175781,225.191406 433.105469,222.261719 C436.035156,219.332031 437.5,215.588542 437.5,211.03125 L437.5,211.03125 L437.5,171.96875 C437.5,167.411458 436.035156,163.667969 433.105469,160.738281 C430.175781,157.808594 426.432292,156.34375 421.875,156.34375 L421.875,156.34375 L15.625,156.34375 C11.0677083,156.34375 7.32421875,157.808594 4.39453125,160.738281 C1.46484375,163.667969 0,167.411458 0,171.96875 L0,171.96875 L0,211.03125 C0,215.588542 1.46484375,219.332031 4.39453125,222.261719 C7.32421875,225.191406 11.0677083,226.65625 15.625,226.65625 L15.625,226.65625 L421.875,226.65625 Z M421.875,382.90625 C426.432292,382.90625 430.175781,381.441406 433.105469,378.511719 C436.035156,375.582031 437.5,371.838542 437.5,367.28125 L437.5,367.28125 L437.5,328.21875 C437.5,323.661458 436.035156,319.917969 433.105469,316.988281 C430.175781,314.058594 426.432292,312.59375 421.875,312.59375 L421.875,312.59375 L15.625,312.59375 C11.0677083,312.59375 7.32421875,314.058594 4.39453125,316.988281 C1.46484375,319.917969 0,323.661458 0,328.21875 L0,328.21875 L0,367.28125 C0,371.838542 1.46484375,375.582031 4.39453125,378.511719 C7.32421875,381.441406 11.0677083,382.90625 15.625,382.90625 L15.625,382.90625 L421.875,382.90625 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 438 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M421.875,70.40625 C426.432292,70.40625 430.175781,68.9414062 433.105469,66.0117188 C436.035156,63.0820312 437.5,59.3385417 437.5,54.78125 L437.5,54.78125 L437.5,15.71875 C437.5,11.1614583 436.035156,7.41796875 433.105469,4.48828125 C430.175781,1.55859375 426.432292,0.09375 421.875,0.09375 L421.875,0.09375 L15.625,0.09375 C11.0677083,0.09375 7.32421875,1.55859375 4.39453125,4.48828125 C1.46484375,7.41796875 0,11.1614583 0,15.71875 L0,15.71875 L0,54.78125 C0,59.3385417 1.46484375,63.0820312 4.39453125,66.0117188 C7.32421875,68.9414062 11.0677083,70.40625 15.625,70.40625 L15.625,70.40625 L421.875,70.40625 Z M421.875,226.65625 C426.432292,226.65625 430.175781,225.191406 433.105469,222.261719 C436.035156,219.332031 437.5,215.588542 437.5,211.03125 L437.5,211.03125 L437.5,171.96875 C437.5,167.411458 436.035156,163.667969 433.105469,160.738281 C430.175781,157.808594 426.432292,156.34375 421.875,156.34375 L421.875,156.34375 L15.625,156.34375 C11.0677083,156.34375 7.32421875,157.808594 4.39453125,160.738281 C1.46484375,163.667969 0,167.411458 0,171.96875 L0,171.96875 L0,211.03125 C0,215.588542 1.46484375,219.332031 4.39453125,222.261719 C7.32421875,225.191406 11.0677083,226.65625 15.625,226.65625 L15.625,226.65625 L421.875,226.65625 Z M421.875,382.90625 C426.432292,382.90625 430.175781,381.441406 433.105469,378.511719 C436.035156,375.582031 437.5,371.838542 437.5,367.28125 L437.5,367.28125 L437.5,328.21875 C437.5,323.661458 436.035156,319.917969 433.105469,316.988281 C430.175781,314.058594 426.432292,312.59375 421.875,312.59375 L421.875,312.59375 L15.625,312.59375 C11.0677083,312.59375 7.32421875,314.058594 4.39453125,316.988281 C1.46484375,319.917969 0,323.661458 0,328.21875 L0,328.21875 L0,367.28125 C0,371.838542 1.46484375,375.582031 4.39453125,378.511719 C7.32421875,381.441406 11.0677083,382.90625 15.625,382.90625 L15.625,382.90625 L421.875,382.90625 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");width:11px;height:7px;background-size:cover;background-repeat:no-repeat}.revo-alt-icon{-webkit-mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 384 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M192.4375,383 C197.424479,383 201.663411,381.254557 205.154297,377.763672 L205.154297,377.763672 L264.25,318.667969 C270.234375,312.683594 271.605794,306.075846 268.364258,298.844727 C265.122721,291.613607 259.51237,287.998047 251.533203,287.998047 L251.533203,287.998047 L213.382812,287.998047 L213.382812,212.445312 L288.935547,212.445312 L288.935547,250.595703 C288.935547,258.57487 292.551107,264.185221 299.782227,267.426758 C307.013346,270.668294 313.621094,269.296875 319.605469,263.3125 L319.605469,263.3125 L378.701172,204.216797 C382.192057,200.725911 383.9375,196.486979 383.9375,191.5 C383.9375,186.513021 382.192057,182.274089 378.701172,178.783203 L378.701172,178.783203 L319.605469,119.6875 C313.621094,114.201823 307.013346,112.955078 299.782227,115.947266 C292.551107,118.939453 288.935547,124.42513 288.935547,132.404297 L288.935547,132.404297 L288.935547,170.554688 L213.382812,170.554688 L213.382812,95.0019531 L251.533203,95.0019531 C259.51237,95.0019531 264.998047,91.3863932 267.990234,84.1552734 C270.982422,76.9241536 269.735677,70.3164062 264.25,64.3320312 L264.25,64.3320312 L205.154297,5.23632812 C201.663411,1.74544271 197.424479,0 192.4375,0 C187.450521,0 183.211589,1.74544271 179.720703,5.23632812 L179.720703,5.23632812 L120.625,64.3320312 C114.640625,70.3164062 113.269206,76.9241536 116.510742,84.1552734 C119.752279,91.3863932 125.36263,95.0019531 133.341797,95.0019531 L133.341797,95.0019531 L171.492188,95.0019531 L171.492188,170.554688 L95.9394531,170.554688 L95.9394531,132.404297 C95.9394531,124.42513 92.3238932,118.814779 85.0927734,115.573242 C77.8616536,112.331706 71.2539062,113.703125 65.2695312,119.6875 L65.2695312,119.6875 L6.17382812,178.783203 C2.68294271,182.274089 0.9375,186.513021 0.9375,191.5 C0.9375,196.486979 2.68294271,200.725911 6.17382812,204.216797 L6.17382812,204.216797 L65.2695312,263.3125 C71.2539062,268.798177 77.8616536,270.044922 85.0927734,267.052734 C92.3238932,264.060547 95.9394531,258.57487 95.9394531,250.595703 L95.9394531,250.595703 L95.9394531,212.445312 L171.492188,212.445312 L171.492188,287.998047 L133.341797,287.998047 C125.36263,287.998047 119.876953,291.613607 116.884766,298.844727 C113.892578,306.075846 115.139323,312.683594 120.625,318.667969 L120.625,318.667969 L179.720703,377.763672 C183.211589,381.254557 187.450521,383 192.4375,383 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 384 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M192.4375,383 C197.424479,383 201.663411,381.254557 205.154297,377.763672 L205.154297,377.763672 L264.25,318.667969 C270.234375,312.683594 271.605794,306.075846 268.364258,298.844727 C265.122721,291.613607 259.51237,287.998047 251.533203,287.998047 L251.533203,287.998047 L213.382812,287.998047 L213.382812,212.445312 L288.935547,212.445312 L288.935547,250.595703 C288.935547,258.57487 292.551107,264.185221 299.782227,267.426758 C307.013346,270.668294 313.621094,269.296875 319.605469,263.3125 L319.605469,263.3125 L378.701172,204.216797 C382.192057,200.725911 383.9375,196.486979 383.9375,191.5 C383.9375,186.513021 382.192057,182.274089 378.701172,178.783203 L378.701172,178.783203 L319.605469,119.6875 C313.621094,114.201823 307.013346,112.955078 299.782227,115.947266 C292.551107,118.939453 288.935547,124.42513 288.935547,132.404297 L288.935547,132.404297 L288.935547,170.554688 L213.382812,170.554688 L213.382812,95.0019531 L251.533203,95.0019531 C259.51237,95.0019531 264.998047,91.3863932 267.990234,84.1552734 C270.982422,76.9241536 269.735677,70.3164062 264.25,64.3320312 L264.25,64.3320312 L205.154297,5.23632812 C201.663411,1.74544271 197.424479,0 192.4375,0 C187.450521,0 183.211589,1.74544271 179.720703,5.23632812 L179.720703,5.23632812 L120.625,64.3320312 C114.640625,70.3164062 113.269206,76.9241536 116.510742,84.1552734 C119.752279,91.3863932 125.36263,95.0019531 133.341797,95.0019531 L133.341797,95.0019531 L171.492188,95.0019531 L171.492188,170.554688 L95.9394531,170.554688 L95.9394531,132.404297 C95.9394531,124.42513 92.3238932,118.814779 85.0927734,115.573242 C77.8616536,112.331706 71.2539062,113.703125 65.2695312,119.6875 L65.2695312,119.6875 L6.17382812,178.783203 C2.68294271,182.274089 0.9375,186.513021 0.9375,191.5 C0.9375,196.486979 2.68294271,200.725911 6.17382812,204.216797 L6.17382812,204.216797 L65.2695312,263.3125 C71.2539062,268.798177 77.8616536,270.044922 85.0927734,267.052734 C92.3238932,264.060547 95.9394531,258.57487 95.9394531,250.595703 L95.9394531,250.595703 L95.9394531,212.445312 L171.492188,212.445312 L171.492188,287.998047 L133.341797,287.998047 C125.36263,287.998047 119.876953,291.613607 116.884766,298.844727 C113.892578,306.075846 115.139323,312.683594 120.625,318.667969 L120.625,318.667969 L179.720703,377.763672 C183.211589,381.254557 187.450521,383 192.4375,383 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");width:11px;height:11px;background-size:cover;background-repeat:no-repeat}.arrow-down{position:absolute;right:5px;top:0}.arrow-down svg{width:8px;margin-top:5px;margin-left:5px;opacity:0.4}.cell-value-wrapper{margin-right:10px;overflow:hidden;text-overflow:ellipsis}.revo-button{position:relative;overflow:hidden;color:#fff;background-color:#6200ee;height:34px;line-height:34px;padding:0 15px;outline:0;border:0;border-radius:7px;box-sizing:border-box;cursor:pointer}.revo-button.green{background-color:#2ee072;border:1px solid #20d565}.revo-button.red{background-color:#E0662E;border:1px solid #d55920}.revo-button:disabled,.revo-button[disabled]{cursor:not-allowed !important;filter:opacity(0.35) !important}.revo-button.light{border:2px solid #cedefa;line-height:32px;background:none;color:#4876ca;box-shadow:none}revogr-filter-panel{position:absolute;display:block;top:0;left:0;z-index:100;opacity:1;transform:none;background-color:#fff;transform-origin:62px 0px;box-shadow:0 5px 18px -2px rgba(0, 0, 0, 0.2);padding:10px;border-radius:4px;min-width:220px;text-align:left}revogr-filter-panel .filter-holder>div{display:flex;flex-direction:column}revogr-filter-panel label{color:gray;font-size:13px;font-weight:600;display:block;padding:8px 0}revogr-filter-panel select{width:100%}revogr-filter-panel input[type=text]{border:0;min-height:34px;margin:5px 0;background:#f3f3f3;border-radius:5px;padding:0 10px;box-sizing:border-box;width:100%}revogr-filter-panel button{margin-top:10px;margin-right:5px}revogr-filter-panel .filter-actions{text-align:right;margin-right:-5px}.rgHeaderCell:hover .rv-filter{transition:opacity 267ms cubic-bezier(0.4, 0, 0.2, 1) 0ms, transform 178ms cubic-bezier(0.4, 0, 0.2, 1) 0ms}.rgHeaderCell:hover .rv-filter,.rgHeaderCell .rv-filter.active{opacity:1}.rgHeaderCell .rv-filter{height:24px;width:24px;background:none;border:0;opacity:0;visibility:visible;cursor:pointer;border-radius:4px}.rgHeaderCell .rv-filter.active{color:#10224a}.rgHeaderCell .rv-filter .filter-img{color:gray;width:11px}.select-css{display:block;font-family:sans-serif;font-weight:600;color:#444;line-height:1.3;padding:0.6em 1.4em 0.5em 0.8em;width:100%;max-width:100%;box-sizing:border-box;margin:0;border:1px solid #f1f1f1;box-shadow:transparent;border-radius:0.5em;appearance:none;background-color:#fff;background-image:url(\"data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%23007CB2%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E\"), linear-gradient(to bottom, #ffffff 0%, #ffffff 100%);background-repeat:no-repeat, repeat;background-position:right 0.7em top 50%, 0 0;background-size:0.65em auto, 100%;}.select-css::-ms-expand{display:none}.select-css:hover{border-color:rgb(197, 197, 197)}.select-css:focus{border-color:#f1f1f1;box-shadow:0 0 1px 3px rgba(59, 153, 252, 0.7);box-shadow:0 0 0 3px -moz-mac-focusring;color:#222;outline:none}.select-css option{font-weight:normal}.select-css:disabled,.select-css[aria-disabled=true]{color:gray;background-image:url(\"data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22graytext%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E\"), linear-gradient(to bottom, #ffffff 0%, #ffffff 100%)}.select-css:disabled:hover,.select-css[aria-disabled=true]{border-color:#f1f1f1}.multi-filter-list{margin-top:5px;margin-bottom:5px}.multi-filter-list div{white-space:nowrap}.multi-filter-list .multi-filter-list-action{display:flex;justify-content:space-between;align-items:center}.multi-filter-list .and-or-button{margin:0 0 0 10px;min-width:58px;cursor:pointer}.multi-filter-list .trash-button{margin:0 0 -2px 6px;cursor:pointer;width:22px;height:22px;color:gray;font-size:18px}.multi-filter-list .trash-button .trash-img{width:1em}.add-filter-divider{display:block;margin:0 -10px 10px -10px;border-bottom:1px solid #d9d9d9;height:10px;box-shadow:0 4px 5px rgba(0, 0, 0, 0.05)}.select-input{display:flex;justify-content:space-between;align-items:center}";const h="none";const c="multi-filter-list";const p="multi-filter-list-action";const f=class{constructor(t){i(this,t);this.filterChange=e(this,"filterChange",7);this.filterCaptionsInternal={title:"Filter by condition",save:"Save",reset:"Reset",cancel:"Close"};this.debouncedApplyFilter=r((()=>{this.filterChange.emit(this.filterItems)}),400);this.isFilterIdSet=false;this.filterId=0;this.currentFilterId=-1;this.currentFilterType=h;this.changes=undefined;this.uuid=undefined;this.filterItems={};this.filterTypes={};this.filterNames={};this.filterEntities={};this.filterCaptions=undefined;this.disableDynamicFiltering=false}onMouseDown(t){if(this.changes&&!t.defaultPrevented){const i=t.target;if(this.isOutside(i)&&!o(i)){this.changes=undefined}}}async show(t){this.changes=t;if(this.changes){this.changes.type=this.changes.type||h}}async getChanges(){return this.changes}componentWillRender(){if(!this.isFilterIdSet){this.isFilterIdSet=true;const t=Object.keys(this.filterItems);for(const i of t){this.filterId+=this.filterItems[i].length}}}renderSelectOptions(i,e=false){var s;const r=[];const o=(s=this.changes)===null||s===void 0?void 0:s.prop;if(!e){r.push(t("option",{selected:this.currentFilterType===h,value:h},o&&this.filterItems[o]&&this.filterItems[o].length>0?"Add more condition...":this.filterNames[h]))}for(let e in this.filterTypes){r.push(...this.filterTypes[e].map((e=>t("option",{value:e,selected:i===e},this.filterNames[e]))));r.push(t("option",{disabled:true}))}return r}renderExtra(i,e){const s=this.filterItems[i];if(!s)return"";if(this.filterEntities[s[e].type].extra!=="input")return"";return t("input",{id:`filter-input-${s[e].id}`,placeholder:"Enter value...",type:"text",value:s[e].value,onInput:this.onUserInput.bind(this,e,i),onKeyDown:t=>this.onKeyDown(t)})}getFilterItemsList(){var i;const e=(i=this.changes)===null||i===void 0?void 0:i.prop;if(!(e||e===0))return"";const s=this.filterItems[e]||[];return t("div",{key:this.filterId},s.map(((i,s)=>{let r;if(s!==this.filterItems[e].length-1){r=t("div",{onClick:()=>this.toggleFilterAndOr(i.id)},t(n,{isAnd:i.relation==="and"}))}return t("div",{key:i.id,class:c},t("div",{class:{"select-input":true}},t("select",{class:"select-css select-filter",onChange:t=>this.onFilterTypeChange(t,e,s)},this.renderSelectOptions(this.filterItems[e][s].type,true)),t("div",{class:p},r),t("div",{onClick:()=>this.onRemoveFilter(i.id)},t(l,null))),t("div",null,this.renderExtra(e,s)))})),s.length>0?t("div",{class:"add-filter-divider"}):"")}render(){if(!this.changes){return t(s,{style:{display:"none"}})}const i={display:"block",left:`${this.changes.x}px`,top:`${this.changes.y}px`};const e=Object.assign(this.filterCaptionsInternal,this.filterCaptions);return t(s,{style:i},t("label",null,e.title),t("div",{class:"filter-holder"},this.getFilterItemsList()),t("div",{class:"add-filter"},t("select",{id:"add-filter",class:"select-css",onChange:t=>this.onAddNewFilter(t)},this.renderSelectOptions(this.currentFilterType))),t("div",{class:"filter-actions"},this.disableDynamicFiltering&&t(a,{class:{red:true,save:true},onClick:()=>this.onSave()},e.save),t(a,{class:{red:true,reset:true},onClick:()=>this.onReset()},e.reset),t(a,{class:{light:true,cancel:true},onClick:()=>this.onCancel()},e.cancel)))}onFilterTypeChange(t,i,e){const s=t.target;const r=s.value;this.filterItems[i][e].type=r;this.filterId++;setTimeout((()=>{const t=document.getElementById("filter-input-"+this.filterItems[i][e].id);if(t)t.focus()}),0);if(!this.disableDynamicFiltering)this.debouncedApplyFilter()}onAddNewFilter(t){const i=t.target;const e=i.value;this.currentFilterType=e;this.addNewFilterToProp();const s=document.getElementById("add-filter");if(s){s.value=h;this.currentFilterType=h}if(!this.disableDynamicFiltering)this.debouncedApplyFilter()}addNewFilterToProp(){var t;const i=(t=this.changes)===null||t===void 0?void 0:t.prop;if(!(i||i===0))return;if(!this.filterItems[i]){this.filterItems[i]=[]}if(this.currentFilterType==="none")return;this.filterId++;this.currentFilterId=this.filterId;this.filterItems[i].push({id:this.currentFilterId,type:this.currentFilterType,value:"",relation:"and"});setTimeout((()=>{const t=document.getElementById("filter-input-"+this.currentFilterId);if(t)t.focus()}),0)}onUserInput(t,i,e){this.filterItems[i][t].value=e.target.value;if(!this.disableDynamicFiltering)this.debouncedApplyFilter()}onKeyDown(t){if(t.key.toLowerCase()==="enter"){const t=document.getElementById("add-filter");if(t){t.value=h;this.currentFilterType=h;this.addNewFilterToProp();t.focus()}return}t.stopPropagation()}onSave(){this.filterChange.emit(this.filterItems)}onCancel(){this.changes=undefined}onReset(){this.assertChanges();delete this.filterItems[this.changes.prop];this.filterId++;this.filterChange.emit(this.filterItems)}onRemoveFilter(t){this.assertChanges();this.filterId++;const i=this.changes.prop;const e=this.filterItems[i];if(!e)return;const s=e.findIndex((i=>i.id===t));if(s===-1)return;e.splice(s,1);if(e.length===0)delete this.filterItems[i];if(!this.disableDynamicFiltering)this.debouncedApplyFilter()}toggleFilterAndOr(t){this.assertChanges();this.filterId++;const i=this.changes.prop;const e=this.filterItems[i];if(!e)return;const s=e.findIndex((i=>i.id===t));if(s===-1)return;e[s].relation=e[s].relation==="and"?"or":"and";if(!this.disableDynamicFiltering)this.debouncedApplyFilter()}assertChanges(){if(!this.changes){throw new Error("Changes required per edit")}}isOutside(t){const i=document.getElementById("add-filter");if(i)i.value=h;this.currentFilterType=h;this.changes.type=h;this.currentFilterId=-1;if(t.classList.contains(`[uuid="${this.uuid}"]`)){return false}return!(t===null||t===void 0?void 0:t.closest(`[uuid="${this.uuid}"]`))}};f.style=d;export{f as revogr_filter_panel};
|
|
5
|
+
//# sourceMappingURL=revogr-filter-panel.entry.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["RevoButton","props","children","h","Object","assign","class","closest","Element","prototype","matches","msMatchesSelector","webkitMatchesSelector","s","el","this","call","parentElement","parentNode","nodeType","filterStyleCss","defaultType","FILTER_LIST_CLASS","FILTER_LIST_CLASS_ACTION","FilterPanel","filterCaptionsInternal","title","save","reset","cancel","debouncedApplyFilter","debounce","filterChange","emit","filterItems","onMouseDown","e","changes","defaultPrevented","target","isOutside","isFilterBtn","undefined","show","newEntity","type","getChanges","componentWillRender","isFilterIdSet","keys","prop","filterId","length","renderSelectOptions","isDefaultTypeRemoved","options","_a","push","selected","currentFilterType","value","filterNames","gIndex","filterTypes","map","k","disabled","renderExtra","index","currentFilter","filterEntities","extra","id","placeholder","onInput","onUserInput","bind","onKeyDown","getFilterItemsList","propFilters","key","d","andOrButton","onClick","toggleFilterAndOr","AndOrButton","isAnd","relation","onChange","onFilterTypeChange","onRemoveFilter","TrashButton","render","Host","style","display","left","x","top","y","capts","filterCaptions","onAddNewFilter","disableDynamicFiltering","red","onSave","onReset","light","onCancel","setTimeout","input","document","getElementById","focus","addNewFilterToProp","select","currentFilterId","event","toLowerCase","stopPropagation","assertChanges","items","findIndex","splice","Error","classList","contains","uuid"],"sources":["src/components/button/button.tsx","src/utils/closestPolifill.ts","src/plugins/filter/filter.style.scss?tag=revogr-filter-panel","src/plugins/filter/filter.pop.tsx"],"sourcesContent":["import { h } from '@stencil/core';\nimport { JSXBase, VNode } from '@stencil/core/internal';\n\ninterface Props extends Partial<JSXBase.ButtonHTMLAttributes<HTMLButtonElement>> {}\n\nexport const RevoButton = (props: Props, children: VNode[]) => {\n return (\n <button\n {...props}\n class={{\n ...(typeof props.class === 'object' ? props.class : props.class ? { [props.class]: true } : ''),\n ['revo-button']: true,\n }}\n >\n {children}\n </button>\n );\n};\n","(function closest() {\n if (!Element.prototype.matches) {\n Element.prototype.matches =\n ((Element.prototype as unknown) as { msMatchesSelector: (selectors: string) => boolean }).msMatchesSelector || Element.prototype.webkitMatchesSelector;\n }\n\n if (!Element.prototype.closest) {\n Element.prototype.closest = function (s: string) {\n let el: HTMLElement | Element | (Node & ParentNode) = this;\n\n do {\n if (Element.prototype.matches.call(el, s)) {\n return el;\n }\n el = el.parentElement || el.parentNode;\n } while (el !== null && el.nodeType === 1);\n return null;\n };\n }\n})();\n","revogr-filter-panel {\n position: absolute;\n display: block;\n top: 0;\n left: 0;\n z-index: 100;\n\n opacity: 1;\n transform: none;\n background-color: #fff;\n transform-origin: 62px 0px;\n box-shadow: 0 5px 18px -2px rgba(black, 20%);\n padding: 10px;\n border-radius: 4px;\n\n min-width: 220px;\n text-align: left;\n\n .filter-holder > div {\n display: flex;\n flex-direction: column;\n }\n\n label {\n color: gray;\n font-size: 13px;\n font-weight: 600;\n display: block;\n padding: 8px 0;\n }\n\n select {\n width: 100%;\n }\n\n input[type=\"text\"] {\n border: 0;\n min-height: 34px;\n margin: 5px 0;\n background: #f3f3f3;\n border-radius: 5px;\n padding: 0 10px;\n box-sizing: border-box;\n width: 100%;\n }\n\n button {\n margin-top: 10px;\n margin-right: 5px;\n }\n\n\n .filter-actions {\n text-align: right;\n margin-right: -5px;\n }\n}\n\n.rgHeaderCell {\n &:hover .rv-filter {\n transition: opacity 267ms cubic-bezier(0.4, 0, 0.2, 1) 0ms, transform 178ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;\n }\n &:hover .rv-filter,\n .rv-filter.active {\n opacity: 1;\n }\n\n .rv-filter {\n $btn-size: 24px;\n height: $btn-size;\n width: $btn-size;\n background: none;\n border: 0;\n opacity: 0;\n visibility: visible;\n cursor: pointer;\n border-radius: 4px;\n\n &.active {\n color: #10224a;\n }\n\n .filter-img {\n $img-size: 11px;\n color: gray;\n width: $img-size;\n }\n }\n}\n\n.select-css {\n $gradient: \"data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%23007CB2%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E\";\n $linearGradient: linear-gradient(to bottom, #ffffff 0%, #ffffff 100%);\n $borderColor: #f1f1f1;\n\n display: block;\n font-family: sans-serif;\n font-weight: 600;\n color: #444;\n line-height: 1.3;\n padding: 0.6em 1.4em 0.5em 0.8em;\n width: 100%;\n max-width: 100%; /* useful when width is set to anything other than 100% */\n box-sizing: border-box;\n margin: 0;\n border: 1px solid $borderColor;\n box-shadow: transparent;\n border-radius: 0.5em;\n appearance: none;\n background-color: #fff;\n background-image: url($gradient), $linearGradient;\n background-repeat: no-repeat, repeat;\n /* arrow icon position (1em from the right, 50% vertical) , then gradient position*/\n background-position: right 0.7em top 50%, 0 0;\n /* icon size, then gradient */\n background-size: 0.65em auto, 100%;\n\n /* Hide arrow icon in IE browsers */\n &::-ms-expand {\n display: none;\n }\n /* Hover style */\n &:hover {\n border-color: rgb(197, 197, 197);\n }\n /* Focus style */\n &:focus {\n border-color: $borderColor;\n box-shadow: 0 0 1px 3px rgba(59, 153, 252, 0.7);\n box-shadow: 0 0 0 3px -moz-mac-focusring;\n color: #222;\n outline: none;\n }\n\n /* Set options to normal weight */\n option {\n font-weight: normal;\n }\n\n /* Disabled styles */\n &:disabled,\n &[aria-disabled=\"true\"] {\n color: gray;\n background-image: url(\"data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22graytext%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E\"),\n linear-gradient(to bottom, #ffffff 0%, #ffffff 100%);\n }\n\n &:disabled:hover,\n &[aria-disabled=\"true\"] {\n border-color: $borderColor;\n }\n}\n\n.multi-filter-list {\n margin-top: 5px;\n margin-bottom: 5px;\n\n div {\n white-space: nowrap;\n }\n\n .multi-filter-list-action {\n display: flex;\n\n justify-content: space-between;\n align-items: center;\n }\n\n .and-or-button {\n margin: 0 0 0 10px;\n min-width: 58px;\n cursor: pointer;\n }\n .trash-button {\n $btn-remove-size: 22px;\n margin: 0 0 -2px 6px;\n cursor: pointer;\n\n width: $btn-remove-size;\n height: $btn-remove-size;\n color: gray;\n font-size: 18px;\n\n\n .trash-img {\n width: 1em;\n }\n }\n}\n\n.add-filter-divider {\n display: block;\n margin: 0 -10px 10px -10px;\n\n border-bottom: 1px solid #d9d9d9;\n height: 10px;\n box-shadow: 0 4px 5px rgb(0 0 0 / 5%);\n}\n\n.select-input {\n display: flex;\n justify-content: space-between;\n align-items: center;\n}","import { Component, h, Host, Listen, Prop, State, Event, EventEmitter, VNode, Method } from '@stencil/core';\nimport { FilterType } from './filter.service';\nimport { RevoGrid } from '../../interfaces';\nimport { AndOrButton, isFilterBtn, TrashButton } from './filter.button';\nimport { RevoButton } from '../../components/button/button';\nimport '../../utils/closestPolifill';\nimport { LogicFunction } from './filter.types';\nimport { FilterCaptions } from './filter.plugin';\nimport debounce from 'lodash/debounce';\n\n/**\n * @typedef FilterItem\n * @type {object}\n * @property {ColumnProp} prop - column id\n * @property {FilterType} type - filter type definition\n * @property {any} value - value for additional filtering, text value or some id\n */\nexport type FilterItem = {\n prop?: RevoGrid.ColumnProp;\n type?: FilterType;\n value?: any;\n};\n\nexport type FilterData = {\n id: number;\n type: FilterType;\n value?: any;\n relation: 'and' | 'or';\n};\n\nexport type MultiFilterItem = {\n [prop: string]: FilterData[];\n};\n\nexport type ShowData = {\n x: number;\n y: number;\n} & FilterItem;\n\nconst defaultType: FilterType = 'none';\n\nconst FILTER_LIST_CLASS = 'multi-filter-list';\nconst FILTER_LIST_CLASS_ACTION = 'multi-filter-list-action';\n\n@Component({\n tag: 'revogr-filter-panel',\n styleUrl: 'filter.style.scss',\n})\nexport class FilterPanel {\n private filterCaptionsInternal: FilterCaptions = {\n title: 'Filter by condition',\n save: 'Save',\n reset: 'Reset',\n cancel: 'Close',\n };\n @State() isFilterIdSet = false;\n @State() filterId = 0;\n @State() currentFilterId: number = -1;\n @State() currentFilterType: FilterType = defaultType;\n @State() changes: ShowData | undefined;\n @Prop({ mutable: true, reflect: true }) uuid: string;\n @Prop() filterItems: MultiFilterItem = {};\n @Prop() filterTypes: Record<string, string[]> = {};\n @Prop() filterNames: Record<string, string> = {};\n @Prop() filterEntities: Record<string, LogicFunction> = {};\n @Prop() filterCaptions: FilterCaptions | undefined;\n @Prop() disableDynamicFiltering: boolean = false;\n @Event() filterChange: EventEmitter<MultiFilterItem>;\n @Listen('mousedown', { target: 'document' }) onMouseDown(e: MouseEvent): void {\n if (this.changes && !e.defaultPrevented) {\n const el = e.target as HTMLElement;\n if (this.isOutside(el) && !isFilterBtn(el)) {\n this.changes = undefined;\n }\n }\n }\n @Method() async show(newEntity?: ShowData) {\n this.changes = newEntity;\n if (this.changes) {\n this.changes.type = this.changes.type || defaultType;\n }\n }\n\n @Method() async getChanges() {\n return this.changes;\n }\n\n componentWillRender() {\n if (!this.isFilterIdSet) {\n this.isFilterIdSet = true;\n const filterItems = Object.keys(this.filterItems);\n for (const prop of filterItems) {\n // we set the proper filterId so there won't be any conflict when removing filters\n this.filterId += this.filterItems[prop].length;\n }\n }\n }\n\n renderSelectOptions(type: FilterType, isDefaultTypeRemoved = false) {\n const options: VNode[] = [];\n const prop = this.changes?.prop;\n\n if (!isDefaultTypeRemoved) {\n options.push(\n <option selected={this.currentFilterType === defaultType} value={defaultType}>\n {prop && this.filterItems[prop] && this.filterItems[prop].length > 0 ? 'Add more condition...' : this.filterNames[defaultType]}\n </option>,\n );\n }\n\n for (let gIndex in this.filterTypes) {\n options.push(\n ...this.filterTypes[gIndex].map(k => (\n <option value={k} selected={type === k}>\n {this.filterNames[k]}\n </option>\n )),\n );\n options.push(<option disabled></option>);\n }\n return options;\n }\n\n renderExtra(prop: RevoGrid.ColumnProp, index: number) {\n const currentFilter = this.filterItems[prop];\n\n if (!currentFilter) return '';\n\n if (this.filterEntities[currentFilter[index].type].extra !== 'input') return '';\n\n return (\n <input\n id={`filter-input-${currentFilter[index].id}`}\n placeholder=\"Enter value...\"\n type=\"text\"\n value={currentFilter[index].value}\n onInput={this.onUserInput.bind(this, index, prop)}\n onKeyDown={e => this.onKeyDown(e)}\n />\n );\n }\n\n getFilterItemsList() {\n const prop = this.changes?.prop;\n if (!(prop || prop === 0)) return '';\n\n const propFilters = this.filterItems[prop] || [];\n return (\n <div key={this.filterId}>\n {propFilters.map((d, index) => {\n let andOrButton;\n\n // hide toggle button if there is only one filter and the last one\n if (index !== this.filterItems[prop].length - 1) {\n andOrButton = (\n <div onClick={() => this.toggleFilterAndOr(d.id)}>\n <AndOrButton isAnd={d.relation === 'and'} />\n </div>\n );\n }\n\n return (\n <div key={d.id} class={FILTER_LIST_CLASS}>\n <div class={{ 'select-input': true }}>\n <select class=\"select-css select-filter\" onChange={e => this.onFilterTypeChange(e, prop, index)}>\n {this.renderSelectOptions(this.filterItems[prop][index].type, true)}\n </select>\n <div class={FILTER_LIST_CLASS_ACTION}>{andOrButton}</div>\n <div onClick={() => this.onRemoveFilter(d.id)}>\n <TrashButton />\n </div>\n </div>\n <div>{this.renderExtra(prop, index)}</div>\n </div>\n );\n })}\n\n {propFilters.length > 0 ? <div class=\"add-filter-divider\"></div> : ''}\n </div>\n );\n }\n\n render() {\n if (!this.changes) {\n return <Host style={{ display: 'none' }}></Host>;\n }\n const style = {\n display: 'block',\n left: `${this.changes.x}px`,\n top: `${this.changes.y}px`,\n };\n\n const capts = Object.assign(this.filterCaptionsInternal, this.filterCaptions);\n\n return (\n <Host style={style}>\n <label>{capts.title}</label>\n <div class=\"filter-holder\">{this.getFilterItemsList()}</div>\n\n <div class=\"add-filter\">\n <select id=\"add-filter\" class=\"select-css\" onChange={e => this.onAddNewFilter(e)}>\n {this.renderSelectOptions(this.currentFilterType)}\n </select>\n </div>\n <div class=\"filter-actions\">\n {this.disableDynamicFiltering &&\n <RevoButton class={{ red: true, save: true }} onClick={() => this.onSave()}>\n {capts.save}\n </RevoButton>\n }\n <RevoButton class={{ red: true, reset: true }} onClick={() => this.onReset()}>\n {capts.reset}\n </RevoButton>\n <RevoButton class={{ light: true, cancel: true }} onClick={() => this.onCancel()}>\n {capts.cancel}\n </RevoButton>\n </div>\n </Host>\n );\n }\n\n private onFilterTypeChange(e: Event, prop: RevoGrid.ColumnProp, index: number) {\n const el = e.target as HTMLSelectElement;\n const type = el.value as FilterType;\n\n this.filterItems[prop][index].type = type;\n\n // this re-renders the input to know if we need extra input\n this.filterId++;\n\n // adding setTimeout will wait for the next tick DOM update then focus on input\n setTimeout(() => {\n const input = document.getElementById('filter-input-' + this.filterItems[prop][index].id) as HTMLInputElement;\n if (input) input.focus();\n }, 0);\n\n if (!this.disableDynamicFiltering) this.debouncedApplyFilter();\n }\n\n private debouncedApplyFilter = debounce(() => {\n this.filterChange.emit(this.filterItems);\n }, 400);\n\n private onAddNewFilter(e: Event) {\n const el = e.target as HTMLSelectElement;\n const type = el.value as FilterType;\n\n this.currentFilterType = type;\n this.addNewFilterToProp();\n\n // reset value after adding new filter\n const select = document.getElementById('add-filter') as HTMLSelectElement;\n if (select) {\n select.value = defaultType;\n this.currentFilterType = defaultType;\n }\n\n if (!this.disableDynamicFiltering) this.debouncedApplyFilter();\n }\n\n private addNewFilterToProp() {\n const prop = this.changes?.prop;\n if (!(prop || prop === 0)) return;\n\n if (!this.filterItems[prop]) {\n this.filterItems[prop] = [];\n }\n\n if (this.currentFilterType === 'none') return;\n\n this.filterId++;\n this.currentFilterId = this.filterId;\n\n this.filterItems[prop].push({\n id: this.currentFilterId,\n type: this.currentFilterType,\n value: '',\n relation: 'and',\n });\n\n // adding setTimeout will wait for the next tick DOM update then focus on input\n setTimeout(() => {\n const input = document.getElementById('filter-input-' + this.currentFilterId) as HTMLInputElement;\n if (input) input.focus();\n }, 0);\n }\n\n private onUserInput(index: number, prop: RevoGrid.ColumnProp, event: Event) {\n // update the value of the filter item\n this.filterItems[prop][index].value = (event.target as HTMLInputElement).value;\n\n if (!this.disableDynamicFiltering) this.debouncedApplyFilter();\n }\n\n private onKeyDown(e: KeyboardEvent) {\n if (e.key.toLowerCase() === 'enter') {\n const select = document.getElementById('add-filter') as HTMLSelectElement;\n if (select) {\n select.value = defaultType;\n this.currentFilterType = defaultType;\n this.addNewFilterToProp();\n select.focus();\n }\n return;\n }\n // keep event local, don't escalate farther to dom\n e.stopPropagation();\n }\n\n private onSave() {\n this.filterChange.emit(this.filterItems);\n }\n\n private onCancel() {\n this.changes = undefined;\n }\n\n private onReset() {\n this.assertChanges();\n\n delete this.filterItems[this.changes.prop];\n\n // this updates the DOM which is used by getFilterItemsList() key\n this.filterId++;\n\n this.filterChange.emit(this.filterItems);\n }\n\n private onRemoveFilter(id: number) {\n this.assertChanges();\n\n // this is for reactivity issues for getFilterItemsList()\n this.filterId++;\n\n const prop = this.changes.prop;\n\n const items = this.filterItems[prop];\n if (!items) return;\n\n const index = items.findIndex(d => d.id === id);\n if (index === -1) return;\n items.splice(index, 1);\n\n // let's remove the prop if no more filters so the filter icon will be removed\n if (items.length === 0) delete this.filterItems[prop];\n\n if (!this.disableDynamicFiltering) this.debouncedApplyFilter();\n }\n\n private toggleFilterAndOr(id: number) {\n this.assertChanges();\n\n // this is for reactivity issues for getFilterItemsList()\n this.filterId++;\n\n const prop = this.changes.prop;\n\n const items = this.filterItems[prop];\n if (!items) return;\n\n const index = items.findIndex(d => d.id === id);\n if (index === -1) return;\n\n items[index].relation = items[index].relation === 'and' ? 'or' : 'and';\n if (!this.disableDynamicFiltering) this.debouncedApplyFilter();\n }\n\n private assertChanges() {\n if (!this.changes) {\n throw new Error('Changes required per edit');\n }\n }\n\n private isOutside(e: HTMLElement | null) {\n const select = document.getElementById('add-filter') as HTMLSelectElement;\n if (select) select.value = defaultType;\n\n this.currentFilterType = defaultType;\n this.changes.type = defaultType;\n this.currentFilterId = -1;\n if (e.classList.contains(`[uuid=\"${this.uuid}\"]`)) {\n return false;\n }\n return !e?.closest(`[uuid=\"${this.uuid}\"]`);\n }\n}\n"],"mappings":";;;6HAKO,MAAMA,EAAa,CAACC,EAAcC,IAErCC,EAAA,SAAAC,OAAAC,OAAA,GACMJ,EAAK,CACTK,MAAKF,OAAAC,OAAAD,OAAAC,OAAA,UACQJ,EAAMK,QAAU,SAAWL,EAAMK,MAAQL,EAAMK,MAAQ,CAAE,CAACL,EAAMK,OAAQ,MAAS,IAAE,CAC9F,CAAC,eAAgB,SAGlBJ,ICdP,SAAUK,IACR,IAAKC,QAAQC,UAAUC,QAAS,CAC9BF,QAAQC,UAAUC,QACdF,QAAQC,UAAgFE,mBAAqBH,QAAQC,UAAUG,qB,CAGrI,IAAKJ,QAAQC,UAAUF,QAAS,CAC9BC,QAAQC,UAAUF,QAAU,SAAUM,GACpC,IAAIC,EAAkDC,KAEtD,EAAG,CACD,GAAIP,QAAQC,UAAUC,QAAQM,KAAKF,EAAID,GAAI,CACzC,OAAOC,C,CAETA,EAAKA,EAAGG,eAAiBH,EAAGI,U,OACrBJ,IAAO,MAAQA,EAAGK,WAAa,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AAWkC,EAAMrD,GAAOmB,WAAa,MAAQ,KAAO,MACjE,IAAKxE,KAAKwF,wBAAyBxF,KAAKe,sB,CAGlC,aAAA0F,GACN,IAAKzG,KAAKsB,QAAS,CACjB,MAAM,IAAIuF,MAAM,4B,EAIZ,SAAApF,CAAUJ,GAChB,MAAM+E,EAASJ,SAASC,eAAe,cACvC,GAAIG,EAAQA,EAAOvD,MAAQvC,EAE3BN,KAAK4C,kBAAoBtC,EACzBN,KAAKsB,QAAQQ,KAAOxB,EACpBN,KAAKqG,iBAAmB,EACxB,GAAIhF,EAAEyF,UAAUC,SAAS,UAAU/G,KAAKgH,UAAW,CACjD,OAAO,K,CAET,QAAQ3F,IAAC,MAADA,SAAC,SAADA,EAAG7B,QAAQ,UAAUQ,KAAKgH,U"}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
var __awaiter=this&&this.__awaiter||function(t,
|
|
1
|
+
var __awaiter=this&&this.__awaiter||function(e,t,i,r){function n(e){return e instanceof i?e:new i((function(t){t(e)}))}return new(i||(i=Promise))((function(i,o){function s(e){try{a(r.next(e))}catch(e){o(e)}}function l(e){try{a(r["throw"](e))}catch(e){o(e)}}function a(e){e.done?i(e.value):n(e.value).then(s,l)}a((r=r.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var i={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},r,n,o,s;return s={next:l(0),throw:l(1),return:l(2)},typeof Symbol==="function"&&(s[Symbol.iterator]=function(){return this}),s;function l(e){return function(t){return a([e,t])}}function a(l){if(r)throw new TypeError("Generator is already executing.");while(s&&(s=0,l[0]&&(i=0)),i)try{if(r=1,n&&(o=l[0]&2?n["return"]:l[0]?n["throw"]||((o=n["return"])&&o.call(n),0):n.next)&&!(o=o.call(n,l[1])).done)return o;if(n=0,o)l=[l[0]&2,o.value];switch(l[0]){case 0:case 1:o=l;break;case 4:i.label++;return{value:l[1],done:false};case 5:i.label++;n=l[1];l=[0];continue;case 7:l=i.ops.pop();i.trys.pop();continue;default:if(!(o=i.trys,o=o.length>0&&o[o.length-1])&&(l[0]===6||l[0]===2)){i=0;continue}if(l[0]===3&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(l[0]===6&&i.label<o[1]){i.label=o[1];o=l;break}if(o&&i.label<o[2]){i.label=o[2];i.ops.push(l);break}if(o[2])i.ops.pop();i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e];n=0}finally{r=o=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:true}}};
|
|
2
2
|
/*!
|
|
3
3
|
* Built by Revolist
|
|
4
|
-
*/System.register(["./index-f14b41a0.system.js","./debounce-5a33c710.system.js"],(function(t){"use strict";var e,i,r,n,o,s,l,a;return{setters:[function(t){e=t.h;i=t.r;r=t.c;n=t.H},function(t){o=t.j;s=t.g;l=t.A;a=t.T}],execute:function(){var c=function(t,i){var r,n;return e("button",Object.assign({},t,{class:Object.assign(Object.assign({},typeof t.class==="object"?t.class:t.class?(r={},r[t.class]=true,r):""),(n={},n["revo-button"]=true,n))}),i)};(function t(){if(!Element.prototype.matches){Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector}if(!Element.prototype.closest){Element.prototype.closest=function(t){var e=this;do{if(Element.prototype.matches.call(e,t)){return e}e=e.parentElement||e.parentNode}while(e!==null&&e.nodeType===1);return null}}})();var d=".revo-drag-icon{-webkit-mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 438 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M421.875,70.40625 C426.432292,70.40625 430.175781,68.9414062 433.105469,66.0117188 C436.035156,63.0820312 437.5,59.3385417 437.5,54.78125 L437.5,54.78125 L437.5,15.71875 C437.5,11.1614583 436.035156,7.41796875 433.105469,4.48828125 C430.175781,1.55859375 426.432292,0.09375 421.875,0.09375 L421.875,0.09375 L15.625,0.09375 C11.0677083,0.09375 7.32421875,1.55859375 4.39453125,4.48828125 C1.46484375,7.41796875 0,11.1614583 0,15.71875 L0,15.71875 L0,54.78125 C0,59.3385417 1.46484375,63.0820312 4.39453125,66.0117188 C7.32421875,68.9414062 11.0677083,70.40625 15.625,70.40625 L15.625,70.40625 L421.875,70.40625 Z M421.875,226.65625 C426.432292,226.65625 430.175781,225.191406 433.105469,222.261719 C436.035156,219.332031 437.5,215.588542 437.5,211.03125 L437.5,211.03125 L437.5,171.96875 C437.5,167.411458 436.035156,163.667969 433.105469,160.738281 C430.175781,157.808594 426.432292,156.34375 421.875,156.34375 L421.875,156.34375 L15.625,156.34375 C11.0677083,156.34375 7.32421875,157.808594 4.39453125,160.738281 C1.46484375,163.667969 0,167.411458 0,171.96875 L0,171.96875 L0,211.03125 C0,215.588542 1.46484375,219.332031 4.39453125,222.261719 C7.32421875,225.191406 11.0677083,226.65625 15.625,226.65625 L15.625,226.65625 L421.875,226.65625 Z M421.875,382.90625 C426.432292,382.90625 430.175781,381.441406 433.105469,378.511719 C436.035156,375.582031 437.5,371.838542 437.5,367.28125 L437.5,367.28125 L437.5,328.21875 C437.5,323.661458 436.035156,319.917969 433.105469,316.988281 C430.175781,314.058594 426.432292,312.59375 421.875,312.59375 L421.875,312.59375 L15.625,312.59375 C11.0677083,312.59375 7.32421875,314.058594 4.39453125,316.988281 C1.46484375,319.917969 0,323.661458 0,328.21875 L0,328.21875 L0,367.28125 C0,371.838542 1.46484375,375.582031 4.39453125,378.511719 C7.32421875,381.441406 11.0677083,382.90625 15.625,382.90625 L15.625,382.90625 L421.875,382.90625 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 438 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M421.875,70.40625 C426.432292,70.40625 430.175781,68.9414062 433.105469,66.0117188 C436.035156,63.0820312 437.5,59.3385417 437.5,54.78125 L437.5,54.78125 L437.5,15.71875 C437.5,11.1614583 436.035156,7.41796875 433.105469,4.48828125 C430.175781,1.55859375 426.432292,0.09375 421.875,0.09375 L421.875,0.09375 L15.625,0.09375 C11.0677083,0.09375 7.32421875,1.55859375 4.39453125,4.48828125 C1.46484375,7.41796875 0,11.1614583 0,15.71875 L0,15.71875 L0,54.78125 C0,59.3385417 1.46484375,63.0820312 4.39453125,66.0117188 C7.32421875,68.9414062 11.0677083,70.40625 15.625,70.40625 L15.625,70.40625 L421.875,70.40625 Z M421.875,226.65625 C426.432292,226.65625 430.175781,225.191406 433.105469,222.261719 C436.035156,219.332031 437.5,215.588542 437.5,211.03125 L437.5,211.03125 L437.5,171.96875 C437.5,167.411458 436.035156,163.667969 433.105469,160.738281 C430.175781,157.808594 426.432292,156.34375 421.875,156.34375 L421.875,156.34375 L15.625,156.34375 C11.0677083,156.34375 7.32421875,157.808594 4.39453125,160.738281 C1.46484375,163.667969 0,167.411458 0,171.96875 L0,171.96875 L0,211.03125 C0,215.588542 1.46484375,219.332031 4.39453125,222.261719 C7.32421875,225.191406 11.0677083,226.65625 15.625,226.65625 L15.625,226.65625 L421.875,226.65625 Z M421.875,382.90625 C426.432292,382.90625 430.175781,381.441406 433.105469,378.511719 C436.035156,375.582031 437.5,371.838542 437.5,367.28125 L437.5,367.28125 L437.5,328.21875 C437.5,323.661458 436.035156,319.917969 433.105469,316.988281 C430.175781,314.058594 426.432292,312.59375 421.875,312.59375 L421.875,312.59375 L15.625,312.59375 C11.0677083,312.59375 7.32421875,314.058594 4.39453125,316.988281 C1.46484375,319.917969 0,323.661458 0,328.21875 L0,328.21875 L0,367.28125 C0,371.838542 1.46484375,375.582031 4.39453125,378.511719 C7.32421875,381.441406 11.0677083,382.90625 15.625,382.90625 L15.625,382.90625 L421.875,382.90625 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");width:11px;height:7px;background-size:cover;background-repeat:no-repeat}.revo-alt-icon{-webkit-mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 384 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M192.4375,383 C197.424479,383 201.663411,381.254557 205.154297,377.763672 L205.154297,377.763672 L264.25,318.667969 C270.234375,312.683594 271.605794,306.075846 268.364258,298.844727 C265.122721,291.613607 259.51237,287.998047 251.533203,287.998047 L251.533203,287.998047 L213.382812,287.998047 L213.382812,212.445312 L288.935547,212.445312 L288.935547,250.595703 C288.935547,258.57487 292.551107,264.185221 299.782227,267.426758 C307.013346,270.668294 313.621094,269.296875 319.605469,263.3125 L319.605469,263.3125 L378.701172,204.216797 C382.192057,200.725911 383.9375,196.486979 383.9375,191.5 C383.9375,186.513021 382.192057,182.274089 378.701172,178.783203 L378.701172,178.783203 L319.605469,119.6875 C313.621094,114.201823 307.013346,112.955078 299.782227,115.947266 C292.551107,118.939453 288.935547,124.42513 288.935547,132.404297 L288.935547,132.404297 L288.935547,170.554688 L213.382812,170.554688 L213.382812,95.0019531 L251.533203,95.0019531 C259.51237,95.0019531 264.998047,91.3863932 267.990234,84.1552734 C270.982422,76.9241536 269.735677,70.3164062 264.25,64.3320312 L264.25,64.3320312 L205.154297,5.23632812 C201.663411,1.74544271 197.424479,0 192.4375,0 C187.450521,0 183.211589,1.74544271 179.720703,5.23632812 L179.720703,5.23632812 L120.625,64.3320312 C114.640625,70.3164062 113.269206,76.9241536 116.510742,84.1552734 C119.752279,91.3863932 125.36263,95.0019531 133.341797,95.0019531 L133.341797,95.0019531 L171.492188,95.0019531 L171.492188,170.554688 L95.9394531,170.554688 L95.9394531,132.404297 C95.9394531,124.42513 92.3238932,118.814779 85.0927734,115.573242 C77.8616536,112.331706 71.2539062,113.703125 65.2695312,119.6875 L65.2695312,119.6875 L6.17382812,178.783203 C2.68294271,182.274089 0.9375,186.513021 0.9375,191.5 C0.9375,196.486979 2.68294271,200.725911 6.17382812,204.216797 L6.17382812,204.216797 L65.2695312,263.3125 C71.2539062,268.798177 77.8616536,270.044922 85.0927734,267.052734 C92.3238932,264.060547 95.9394531,258.57487 95.9394531,250.595703 L95.9394531,250.595703 L95.9394531,212.445312 L171.492188,212.445312 L171.492188,287.998047 L133.341797,287.998047 C125.36263,287.998047 119.876953,291.613607 116.884766,298.844727 C113.892578,306.075846 115.139323,312.683594 120.625,318.667969 L120.625,318.667969 L179.720703,377.763672 C183.211589,381.254557 187.450521,383 192.4375,383 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 384 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M192.4375,383 C197.424479,383 201.663411,381.254557 205.154297,377.763672 L205.154297,377.763672 L264.25,318.667969 C270.234375,312.683594 271.605794,306.075846 268.364258,298.844727 C265.122721,291.613607 259.51237,287.998047 251.533203,287.998047 L251.533203,287.998047 L213.382812,287.998047 L213.382812,212.445312 L288.935547,212.445312 L288.935547,250.595703 C288.935547,258.57487 292.551107,264.185221 299.782227,267.426758 C307.013346,270.668294 313.621094,269.296875 319.605469,263.3125 L319.605469,263.3125 L378.701172,204.216797 C382.192057,200.725911 383.9375,196.486979 383.9375,191.5 C383.9375,186.513021 382.192057,182.274089 378.701172,178.783203 L378.701172,178.783203 L319.605469,119.6875 C313.621094,114.201823 307.013346,112.955078 299.782227,115.947266 C292.551107,118.939453 288.935547,124.42513 288.935547,132.404297 L288.935547,132.404297 L288.935547,170.554688 L213.382812,170.554688 L213.382812,95.0019531 L251.533203,95.0019531 C259.51237,95.0019531 264.998047,91.3863932 267.990234,84.1552734 C270.982422,76.9241536 269.735677,70.3164062 264.25,64.3320312 L264.25,64.3320312 L205.154297,5.23632812 C201.663411,1.74544271 197.424479,0 192.4375,0 C187.450521,0 183.211589,1.74544271 179.720703,5.23632812 L179.720703,5.23632812 L120.625,64.3320312 C114.640625,70.3164062 113.269206,76.9241536 116.510742,84.1552734 C119.752279,91.3863932 125.36263,95.0019531 133.341797,95.0019531 L133.341797,95.0019531 L171.492188,95.0019531 L171.492188,170.554688 L95.9394531,170.554688 L95.9394531,132.404297 C95.9394531,124.42513 92.3238932,118.814779 85.0927734,115.573242 C77.8616536,112.331706 71.2539062,113.703125 65.2695312,119.6875 L65.2695312,119.6875 L6.17382812,178.783203 C2.68294271,182.274089 0.9375,186.513021 0.9375,191.5 C0.9375,196.486979 2.68294271,200.725911 6.17382812,204.216797 L6.17382812,204.216797 L65.2695312,263.3125 C71.2539062,268.798177 77.8616536,270.044922 85.0927734,267.052734 C92.3238932,264.060547 95.9394531,258.57487 95.9394531,250.595703 L95.9394531,250.595703 L95.9394531,212.445312 L171.492188,212.445312 L171.492188,287.998047 L133.341797,287.998047 C125.36263,287.998047 119.876953,291.613607 116.884766,298.844727 C113.892578,306.075846 115.139323,312.683594 120.625,318.667969 L120.625,318.667969 L179.720703,377.763672 C183.211589,381.254557 187.450521,383 192.4375,383 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");width:11px;height:11px;background-size:cover;background-repeat:no-repeat}.arrow-down{position:absolute;right:5px;top:0}.arrow-down svg{width:8px;margin-top:5px;margin-left:5px;opacity:0.4}.cell-value-wrapper{margin-right:10px;overflow:hidden;text-overflow:ellipsis}.revo-button{position:relative;overflow:hidden;color:#fff;background-color:#6200ee;height:34px;line-height:34px;padding:0 15px;outline:0;border:0;border-radius:7px;box-sizing:border-box;cursor:pointer}.revo-button.green{background-color:#2ee072;border:1px solid #20d565}.revo-button.red{background-color:#E0662E;border:1px solid #d55920}.revo-button:disabled,.revo-button[disabled]{cursor:not-allowed !important;filter:opacity(0.35) !important}.revo-button.light{border:2px solid #cedefa;line-height:32px;background:none;color:#4876ca;box-shadow:none}revogr-filter-panel{position:absolute;display:block;top:0;left:0;z-index:100;opacity:1;transform:none;background-color:#fff;transform-origin:62px 0px;box-shadow:0 5px 18px -2px rgba(0, 0, 0, 0.2);padding:10px;border-radius:4px;min-width:220px;text-align:left}revogr-filter-panel .filter-holder>div{display:flex;flex-direction:column}revogr-filter-panel label{color:gray;font-size:13px;font-weight:600;display:block;padding:8px 0}revogr-filter-panel select{width:100%}revogr-filter-panel input[type=text]{border:0;min-height:34px;margin:5px 0;background:#f3f3f3;border-radius:5px;padding:0 10px;box-sizing:border-box;width:100%}revogr-filter-panel button{margin-top:10px;margin-right:5px}revogr-filter-panel .filter-actions{text-align:right;margin-right:-5px}.rgHeaderCell:hover .rv-filter{transition:opacity 267ms cubic-bezier(0.4, 0, 0.2, 1) 0ms, transform 178ms cubic-bezier(0.4, 0, 0.2, 1) 0ms}.rgHeaderCell:hover .rv-filter,.rgHeaderCell .rv-filter.active{opacity:1}.rgHeaderCell .rv-filter{height:24px;width:24px;background:none;border:0;opacity:0;visibility:visible;cursor:pointer;border-radius:4px}.rgHeaderCell .rv-filter.active{color:#10224a}.rgHeaderCell .rv-filter .filter-img{color:gray;width:11px}.select-css{display:block;font-family:sans-serif;font-weight:600;color:#444;line-height:1.3;padding:0.6em 1.4em 0.5em 0.8em;width:100%;max-width:100%;box-sizing:border-box;margin:0;border:1px solid #f1f1f1;box-shadow:transparent;border-radius:0.5em;appearance:none;background-color:#fff;background-image:url(\"data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%23007CB2%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E\"), linear-gradient(to bottom, #ffffff 0%, #ffffff 100%);background-repeat:no-repeat, repeat;background-position:right 0.7em top 50%, 0 0;background-size:0.65em auto, 100%;}.select-css::-ms-expand{display:none}.select-css:hover{border-color:#c5c5c5}.select-css:focus{border-color:#f1f1f1;box-shadow:0 0 1px 3px rgba(59, 153, 252, 0.7);box-shadow:0 0 0 3px -moz-mac-focusring;color:#222;outline:none}.select-css option{font-weight:normal}.select-css:disabled,.select-css[aria-disabled=true]{color:gray;background-image:url(\"data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22graytext%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E\"), linear-gradient(to bottom, #ffffff 0%, #ffffff 100%)}.select-css:disabled:hover,.select-css[aria-disabled=true]{border-color:#f1f1f1}.multi-filter-list{margin-top:5px;margin-bottom:5px}.multi-filter-list div{white-space:nowrap}.multi-filter-list .multi-filter-list-action{display:flex;justify-content:space-between;align-items:center}.multi-filter-list .and-or-button{margin:0 0 0 10px;min-width:58px;cursor:pointer}.multi-filter-list .trash-button{margin:0 0 -2px 6px;cursor:pointer;width:22px;height:22px;color:gray;font-size:18px}.multi-filter-list .trash-button .trash-img{width:1em}.add-filter-divider{display:block;margin:0 -10px 10px -10px;border-bottom:1px solid #d9d9d9;height:10px;box-shadow:0 4px 5px rgba(0, 0, 0, 0.05)}.select-input{display:flex;justify-content:space-between;align-items:center}";var p="none";var u="multi-filter-list";var f="multi-filter-list-action";var h=t("revogr_filter_panel",function(){function t(t){var e=this;i(this,t);this.filterChange=r(this,"filterChange",7);this.filterCaptionsInternal={title:"Filter by condition",save:"Save",reset:"Reset",cancel:"Close"};this.isFilterIdSet=false;this.filterId=0;this.currentFilterId=-1;this.currentFilterType=p;this.filterItems={};this.filterTypes={};this.filterNames={};this.filterEntities={};this.disableDynamicFiltering=false;this.debouncedApplyFilter=o((function(){e.filterChange.emit(e.filterItems)}),400)}t.prototype.onMouseDown=function(t){if(this.changes&&!t.defaultPrevented){var e=t.target;if(this.isOutside(e)&&!s(e)){this.changes=undefined}}};t.prototype.show=function(t){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){this.changes=t;if(this.changes){this.changes.type=this.changes.type||p}return[2]}))}))};t.prototype.getChanges=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){return[2,this.changes]}))}))};t.prototype.componentWillRender=function(){if(!this.isFilterIdSet){this.isFilterIdSet=true;var t=Object.keys(this.filterItems);for(var e=0,i=t;e<i.length;e++){var r=i[e];this.filterId+=this.filterItems[r].length}}};t.prototype.renderSelectOptions=function(t,i){var r=this;if(i===void 0){i=false}var n;var o=[];var s=(n=this.changes)===null||n===void 0?void 0:n.prop;if(!i){o.push(e("option",{selected:this.currentFilterType===p,value:p},s&&this.filterItems[s]&&this.filterItems[s].length>0?"Add more condition...":this.filterNames[p]))}for(var l in this.filterTypes){o.push.apply(o,this.filterTypes[l].map((function(i){return e("option",{value:i,selected:t===i},r.filterNames[i])})));o.push(e("option",{disabled:true}))}return o};t.prototype.renderExtra=function(t,i){var r=this;var n=this.filterItems[t];if(!n)return"";if(this.filterEntities[n[i].type].extra!=="input")return"";return e("input",{id:"filter-input-".concat(n[i].id),placeholder:"Enter value...",type:"text",value:n[i].value,onInput:this.onUserInput.bind(this,i,t),onKeyDown:function(t){return r.onKeyDown(t)}})};t.prototype.getFilterItemsList=function(){var t=this;var i;var r=(i=this.changes)===null||i===void 0?void 0:i.prop;if(!(r||r===0))return"";var n=this.filterItems[r]||[];return e("div",{key:this.filterId},n.map((function(i,n){var o;if(n!==t.filterItems[r].length-1){o=e("div",{onClick:function(){return t.toggleFilterAndOr(i.id)}},e(l,{isAnd:i.relation==="and"}))}return e("div",{key:i.id,class:u},e("div",{class:{"select-input":true}},e("select",{class:"select-css select-filter",onChange:function(e){return t.onFilterTypeChange(e,r,n)}},t.renderSelectOptions(t.filterItems[r][n].type,true)),e("div",{class:f},o),e("div",{onClick:function(){return t.onRemoveFilter(i.id)}},e(a,null))),e("div",null,t.renderExtra(r,n)))})),n.length>0?e("div",{class:"add-filter-divider"}):"")};t.prototype.render=function(){var t=this;if(!this.changes){return e(n,{style:{display:"none"}})}var i={display:"block",left:"".concat(this.changes.x,"px"),top:"".concat(this.changes.y,"px")};var r=Object.assign(this.filterCaptionsInternal,this.filterCaptions);return e(n,{style:i},e("label",null,r.title),e("div",{class:"filter-holder"},this.getFilterItemsList()),e("div",{class:"add-filter"},e("select",{id:"add-filter",class:"select-css",onChange:function(e){return t.onAddNewFilter(e)}},this.renderSelectOptions(this.currentFilterType))),e("div",{class:"filter-actions"},this.disableDynamicFiltering&&e(c,{class:{red:true,save:true},onClick:function(){return t.onSave()}},r.save),e(c,{class:{red:true,reset:true},onClick:function(){return t.onReset()}},r.reset),e(c,{class:{light:true,cancel:true},onClick:function(){return t.onCancel()}},r.cancel)))};t.prototype.onFilterTypeChange=function(t,e,i){var r=this;var n=t.target;var o=n.value;this.filterItems[e][i].type=o;this.filterId++;setTimeout((function(){var t=document.getElementById("filter-input-"+r.filterItems[e][i].id);if(t)t.focus()}),0);if(!this.disableDynamicFiltering)this.debouncedApplyFilter()};t.prototype.onAddNewFilter=function(t){var e=t.target;var i=e.value;this.currentFilterType=i;this.addNewFilterToProp();var r=document.getElementById("add-filter");if(r){r.value=p;this.currentFilterType=p}if(!this.disableDynamicFiltering)this.debouncedApplyFilter()};t.prototype.addNewFilterToProp=function(){var t=this;var e;var i=(e=this.changes)===null||e===void 0?void 0:e.prop;if(!(i||i===0))return;if(!this.filterItems[i]){this.filterItems[i]=[]}if(this.currentFilterType==="none")return;this.filterId++;this.currentFilterId=this.filterId;this.filterItems[i].push({id:this.currentFilterId,type:this.currentFilterType,value:"",relation:"and"});setTimeout((function(){var e=document.getElementById("filter-input-"+t.currentFilterId);if(e)e.focus()}),0)};t.prototype.onUserInput=function(t,e,i){this.filterItems[e][t].value=i.target.value;if(!this.disableDynamicFiltering)this.debouncedApplyFilter()};t.prototype.onKeyDown=function(t){if(t.key.toLowerCase()==="enter"){var e=document.getElementById("add-filter");if(e){e.value=p;this.currentFilterType=p;this.addNewFilterToProp();e.focus()}return}t.stopPropagation()};t.prototype.onSave=function(){this.filterChange.emit(this.filterItems)};t.prototype.onCancel=function(){this.changes=undefined};t.prototype.onReset=function(){this.assertChanges();delete this.filterItems[this.changes.prop];this.filterId++;this.filterChange.emit(this.filterItems)};t.prototype.onRemoveFilter=function(t){this.assertChanges();this.filterId++;var e=this.changes.prop;var i=this.filterItems[e];if(!i)return;var r=i.findIndex((function(e){return e.id===t}));if(r===-1)return;i.splice(r,1);if(i.length===0)delete this.filterItems[e];if(!this.disableDynamicFiltering)this.debouncedApplyFilter()};t.prototype.toggleFilterAndOr=function(t){this.assertChanges();this.filterId++;var e=this.changes.prop;var i=this.filterItems[e];if(!i)return;var r=i.findIndex((function(e){return e.id===t}));if(r===-1)return;i[r].relation=i[r].relation==="and"?"or":"and";if(!this.disableDynamicFiltering)this.debouncedApplyFilter()};t.prototype.assertChanges=function(){if(!this.changes){throw new Error("Changes required per edit")}};t.prototype.isOutside=function(t){var e=document.getElementById("add-filter");if(e)e.value=p;this.currentFilterType=p;this.changes.type=p;this.currentFilterId=-1;if(t.classList.contains('[uuid="'.concat(this.uuid,'"]'))){return false}return!(t===null||t===void 0?void 0:t.closest('[uuid="'.concat(this.uuid,'"]')))};return t}());h.style=d}}}));
|
|
4
|
+
*/System.register(["./index-20224007.system.js","./debounce-3aba7c4d.system.js"],(function(e){"use strict";var t,i,r,n,o,s,l,a;return{setters:[function(e){t=e.h;i=e.r;r=e.c;n=e.H},function(e){o=e.j;s=e.g;l=e.A;a=e.T}],execute:function(){var c=function(e,i){var r,n;return t("button",Object.assign({},e,{class:Object.assign(Object.assign({},typeof e.class==="object"?e.class:e.class?(r={},r[e.class]=true,r):""),(n={},n["revo-button"]=true,n))}),i)};(function e(){if(!Element.prototype.matches){Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector}if(!Element.prototype.closest){Element.prototype.closest=function(e){var t=this;do{if(Element.prototype.matches.call(t,e)){return t}t=t.parentElement||t.parentNode}while(t!==null&&t.nodeType===1);return null}}})();var d=".revo-drag-icon{-webkit-mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 438 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M421.875,70.40625 C426.432292,70.40625 430.175781,68.9414062 433.105469,66.0117188 C436.035156,63.0820312 437.5,59.3385417 437.5,54.78125 L437.5,54.78125 L437.5,15.71875 C437.5,11.1614583 436.035156,7.41796875 433.105469,4.48828125 C430.175781,1.55859375 426.432292,0.09375 421.875,0.09375 L421.875,0.09375 L15.625,0.09375 C11.0677083,0.09375 7.32421875,1.55859375 4.39453125,4.48828125 C1.46484375,7.41796875 0,11.1614583 0,15.71875 L0,15.71875 L0,54.78125 C0,59.3385417 1.46484375,63.0820312 4.39453125,66.0117188 C7.32421875,68.9414062 11.0677083,70.40625 15.625,70.40625 L15.625,70.40625 L421.875,70.40625 Z M421.875,226.65625 C426.432292,226.65625 430.175781,225.191406 433.105469,222.261719 C436.035156,219.332031 437.5,215.588542 437.5,211.03125 L437.5,211.03125 L437.5,171.96875 C437.5,167.411458 436.035156,163.667969 433.105469,160.738281 C430.175781,157.808594 426.432292,156.34375 421.875,156.34375 L421.875,156.34375 L15.625,156.34375 C11.0677083,156.34375 7.32421875,157.808594 4.39453125,160.738281 C1.46484375,163.667969 0,167.411458 0,171.96875 L0,171.96875 L0,211.03125 C0,215.588542 1.46484375,219.332031 4.39453125,222.261719 C7.32421875,225.191406 11.0677083,226.65625 15.625,226.65625 L15.625,226.65625 L421.875,226.65625 Z M421.875,382.90625 C426.432292,382.90625 430.175781,381.441406 433.105469,378.511719 C436.035156,375.582031 437.5,371.838542 437.5,367.28125 L437.5,367.28125 L437.5,328.21875 C437.5,323.661458 436.035156,319.917969 433.105469,316.988281 C430.175781,314.058594 426.432292,312.59375 421.875,312.59375 L421.875,312.59375 L15.625,312.59375 C11.0677083,312.59375 7.32421875,314.058594 4.39453125,316.988281 C1.46484375,319.917969 0,323.661458 0,328.21875 L0,328.21875 L0,367.28125 C0,371.838542 1.46484375,375.582031 4.39453125,378.511719 C7.32421875,381.441406 11.0677083,382.90625 15.625,382.90625 L15.625,382.90625 L421.875,382.90625 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 438 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M421.875,70.40625 C426.432292,70.40625 430.175781,68.9414062 433.105469,66.0117188 C436.035156,63.0820312 437.5,59.3385417 437.5,54.78125 L437.5,54.78125 L437.5,15.71875 C437.5,11.1614583 436.035156,7.41796875 433.105469,4.48828125 C430.175781,1.55859375 426.432292,0.09375 421.875,0.09375 L421.875,0.09375 L15.625,0.09375 C11.0677083,0.09375 7.32421875,1.55859375 4.39453125,4.48828125 C1.46484375,7.41796875 0,11.1614583 0,15.71875 L0,15.71875 L0,54.78125 C0,59.3385417 1.46484375,63.0820312 4.39453125,66.0117188 C7.32421875,68.9414062 11.0677083,70.40625 15.625,70.40625 L15.625,70.40625 L421.875,70.40625 Z M421.875,226.65625 C426.432292,226.65625 430.175781,225.191406 433.105469,222.261719 C436.035156,219.332031 437.5,215.588542 437.5,211.03125 L437.5,211.03125 L437.5,171.96875 C437.5,167.411458 436.035156,163.667969 433.105469,160.738281 C430.175781,157.808594 426.432292,156.34375 421.875,156.34375 L421.875,156.34375 L15.625,156.34375 C11.0677083,156.34375 7.32421875,157.808594 4.39453125,160.738281 C1.46484375,163.667969 0,167.411458 0,171.96875 L0,171.96875 L0,211.03125 C0,215.588542 1.46484375,219.332031 4.39453125,222.261719 C7.32421875,225.191406 11.0677083,226.65625 15.625,226.65625 L15.625,226.65625 L421.875,226.65625 Z M421.875,382.90625 C426.432292,382.90625 430.175781,381.441406 433.105469,378.511719 C436.035156,375.582031 437.5,371.838542 437.5,367.28125 L437.5,367.28125 L437.5,328.21875 C437.5,323.661458 436.035156,319.917969 433.105469,316.988281 C430.175781,314.058594 426.432292,312.59375 421.875,312.59375 L421.875,312.59375 L15.625,312.59375 C11.0677083,312.59375 7.32421875,314.058594 4.39453125,316.988281 C1.46484375,319.917969 0,323.661458 0,328.21875 L0,328.21875 L0,367.28125 C0,371.838542 1.46484375,375.582031 4.39453125,378.511719 C7.32421875,381.441406 11.0677083,382.90625 15.625,382.90625 L15.625,382.90625 L421.875,382.90625 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");width:11px;height:7px;background-size:cover;background-repeat:no-repeat}.revo-alt-icon{-webkit-mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 384 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M192.4375,383 C197.424479,383 201.663411,381.254557 205.154297,377.763672 L205.154297,377.763672 L264.25,318.667969 C270.234375,312.683594 271.605794,306.075846 268.364258,298.844727 C265.122721,291.613607 259.51237,287.998047 251.533203,287.998047 L251.533203,287.998047 L213.382812,287.998047 L213.382812,212.445312 L288.935547,212.445312 L288.935547,250.595703 C288.935547,258.57487 292.551107,264.185221 299.782227,267.426758 C307.013346,270.668294 313.621094,269.296875 319.605469,263.3125 L319.605469,263.3125 L378.701172,204.216797 C382.192057,200.725911 383.9375,196.486979 383.9375,191.5 C383.9375,186.513021 382.192057,182.274089 378.701172,178.783203 L378.701172,178.783203 L319.605469,119.6875 C313.621094,114.201823 307.013346,112.955078 299.782227,115.947266 C292.551107,118.939453 288.935547,124.42513 288.935547,132.404297 L288.935547,132.404297 L288.935547,170.554688 L213.382812,170.554688 L213.382812,95.0019531 L251.533203,95.0019531 C259.51237,95.0019531 264.998047,91.3863932 267.990234,84.1552734 C270.982422,76.9241536 269.735677,70.3164062 264.25,64.3320312 L264.25,64.3320312 L205.154297,5.23632812 C201.663411,1.74544271 197.424479,0 192.4375,0 C187.450521,0 183.211589,1.74544271 179.720703,5.23632812 L179.720703,5.23632812 L120.625,64.3320312 C114.640625,70.3164062 113.269206,76.9241536 116.510742,84.1552734 C119.752279,91.3863932 125.36263,95.0019531 133.341797,95.0019531 L133.341797,95.0019531 L171.492188,95.0019531 L171.492188,170.554688 L95.9394531,170.554688 L95.9394531,132.404297 C95.9394531,124.42513 92.3238932,118.814779 85.0927734,115.573242 C77.8616536,112.331706 71.2539062,113.703125 65.2695312,119.6875 L65.2695312,119.6875 L6.17382812,178.783203 C2.68294271,182.274089 0.9375,186.513021 0.9375,191.5 C0.9375,196.486979 2.68294271,200.725911 6.17382812,204.216797 L6.17382812,204.216797 L65.2695312,263.3125 C71.2539062,268.798177 77.8616536,270.044922 85.0927734,267.052734 C92.3238932,264.060547 95.9394531,258.57487 95.9394531,250.595703 L95.9394531,250.595703 L95.9394531,212.445312 L171.492188,212.445312 L171.492188,287.998047 L133.341797,287.998047 C125.36263,287.998047 119.876953,291.613607 116.884766,298.844727 C113.892578,306.075846 115.139323,312.683594 120.625,318.667969 L120.625,318.667969 L179.720703,377.763672 C183.211589,381.254557 187.450521,383 192.4375,383 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 384 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M192.4375,383 C197.424479,383 201.663411,381.254557 205.154297,377.763672 L205.154297,377.763672 L264.25,318.667969 C270.234375,312.683594 271.605794,306.075846 268.364258,298.844727 C265.122721,291.613607 259.51237,287.998047 251.533203,287.998047 L251.533203,287.998047 L213.382812,287.998047 L213.382812,212.445312 L288.935547,212.445312 L288.935547,250.595703 C288.935547,258.57487 292.551107,264.185221 299.782227,267.426758 C307.013346,270.668294 313.621094,269.296875 319.605469,263.3125 L319.605469,263.3125 L378.701172,204.216797 C382.192057,200.725911 383.9375,196.486979 383.9375,191.5 C383.9375,186.513021 382.192057,182.274089 378.701172,178.783203 L378.701172,178.783203 L319.605469,119.6875 C313.621094,114.201823 307.013346,112.955078 299.782227,115.947266 C292.551107,118.939453 288.935547,124.42513 288.935547,132.404297 L288.935547,132.404297 L288.935547,170.554688 L213.382812,170.554688 L213.382812,95.0019531 L251.533203,95.0019531 C259.51237,95.0019531 264.998047,91.3863932 267.990234,84.1552734 C270.982422,76.9241536 269.735677,70.3164062 264.25,64.3320312 L264.25,64.3320312 L205.154297,5.23632812 C201.663411,1.74544271 197.424479,0 192.4375,0 C187.450521,0 183.211589,1.74544271 179.720703,5.23632812 L179.720703,5.23632812 L120.625,64.3320312 C114.640625,70.3164062 113.269206,76.9241536 116.510742,84.1552734 C119.752279,91.3863932 125.36263,95.0019531 133.341797,95.0019531 L133.341797,95.0019531 L171.492188,95.0019531 L171.492188,170.554688 L95.9394531,170.554688 L95.9394531,132.404297 C95.9394531,124.42513 92.3238932,118.814779 85.0927734,115.573242 C77.8616536,112.331706 71.2539062,113.703125 65.2695312,119.6875 L65.2695312,119.6875 L6.17382812,178.783203 C2.68294271,182.274089 0.9375,186.513021 0.9375,191.5 C0.9375,196.486979 2.68294271,200.725911 6.17382812,204.216797 L6.17382812,204.216797 L65.2695312,263.3125 C71.2539062,268.798177 77.8616536,270.044922 85.0927734,267.052734 C92.3238932,264.060547 95.9394531,258.57487 95.9394531,250.595703 L95.9394531,250.595703 L95.9394531,212.445312 L171.492188,212.445312 L171.492188,287.998047 L133.341797,287.998047 C125.36263,287.998047 119.876953,291.613607 116.884766,298.844727 C113.892578,306.075846 115.139323,312.683594 120.625,318.667969 L120.625,318.667969 L179.720703,377.763672 C183.211589,381.254557 187.450521,383 192.4375,383 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");width:11px;height:11px;background-size:cover;background-repeat:no-repeat}.arrow-down{position:absolute;right:5px;top:0}.arrow-down svg{width:8px;margin-top:5px;margin-left:5px;opacity:0.4}.cell-value-wrapper{margin-right:10px;overflow:hidden;text-overflow:ellipsis}.revo-button{position:relative;overflow:hidden;color:#fff;background-color:#6200ee;height:34px;line-height:34px;padding:0 15px;outline:0;border:0;border-radius:7px;box-sizing:border-box;cursor:pointer}.revo-button.green{background-color:#2ee072;border:1px solid #20d565}.revo-button.red{background-color:#E0662E;border:1px solid #d55920}.revo-button:disabled,.revo-button[disabled]{cursor:not-allowed !important;filter:opacity(0.35) !important}.revo-button.light{border:2px solid #cedefa;line-height:32px;background:none;color:#4876ca;box-shadow:none}revogr-filter-panel{position:absolute;display:block;top:0;left:0;z-index:100;opacity:1;transform:none;background-color:#fff;transform-origin:62px 0px;box-shadow:0 5px 18px -2px rgba(0, 0, 0, 0.2);padding:10px;border-radius:4px;min-width:220px;text-align:left}revogr-filter-panel .filter-holder>div{display:flex;flex-direction:column}revogr-filter-panel label{color:gray;font-size:13px;font-weight:600;display:block;padding:8px 0}revogr-filter-panel select{width:100%}revogr-filter-panel input[type=text]{border:0;min-height:34px;margin:5px 0;background:#f3f3f3;border-radius:5px;padding:0 10px;box-sizing:border-box;width:100%}revogr-filter-panel button{margin-top:10px;margin-right:5px}revogr-filter-panel .filter-actions{text-align:right;margin-right:-5px}.rgHeaderCell:hover .rv-filter{transition:opacity 267ms cubic-bezier(0.4, 0, 0.2, 1) 0ms, transform 178ms cubic-bezier(0.4, 0, 0.2, 1) 0ms}.rgHeaderCell:hover .rv-filter,.rgHeaderCell .rv-filter.active{opacity:1}.rgHeaderCell .rv-filter{height:24px;width:24px;background:none;border:0;opacity:0;visibility:visible;cursor:pointer;border-radius:4px}.rgHeaderCell .rv-filter.active{color:#10224a}.rgHeaderCell .rv-filter .filter-img{color:gray;width:11px}.select-css{display:block;font-family:sans-serif;font-weight:600;color:#444;line-height:1.3;padding:0.6em 1.4em 0.5em 0.8em;width:100%;max-width:100%;box-sizing:border-box;margin:0;border:1px solid #f1f1f1;box-shadow:transparent;border-radius:0.5em;appearance:none;background-color:#fff;background-image:url(\"data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%23007CB2%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E\"), linear-gradient(to bottom, #ffffff 0%, #ffffff 100%);background-repeat:no-repeat, repeat;background-position:right 0.7em top 50%, 0 0;background-size:0.65em auto, 100%;}.select-css::-ms-expand{display:none}.select-css:hover{border-color:rgb(197, 197, 197)}.select-css:focus{border-color:#f1f1f1;box-shadow:0 0 1px 3px rgba(59, 153, 252, 0.7);box-shadow:0 0 0 3px -moz-mac-focusring;color:#222;outline:none}.select-css option{font-weight:normal}.select-css:disabled,.select-css[aria-disabled=true]{color:gray;background-image:url(\"data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22graytext%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E\"), linear-gradient(to bottom, #ffffff 0%, #ffffff 100%)}.select-css:disabled:hover,.select-css[aria-disabled=true]{border-color:#f1f1f1}.multi-filter-list{margin-top:5px;margin-bottom:5px}.multi-filter-list div{white-space:nowrap}.multi-filter-list .multi-filter-list-action{display:flex;justify-content:space-between;align-items:center}.multi-filter-list .and-or-button{margin:0 0 0 10px;min-width:58px;cursor:pointer}.multi-filter-list .trash-button{margin:0 0 -2px 6px;cursor:pointer;width:22px;height:22px;color:gray;font-size:18px}.multi-filter-list .trash-button .trash-img{width:1em}.add-filter-divider{display:block;margin:0 -10px 10px -10px;border-bottom:1px solid #d9d9d9;height:10px;box-shadow:0 4px 5px rgba(0, 0, 0, 0.05)}.select-input{display:flex;justify-content:space-between;align-items:center}";var p="none";var u="multi-filter-list";var f="multi-filter-list-action";var h=e("revogr_filter_panel",function(){function e(e){var t=this;i(this,e);this.filterChange=r(this,"filterChange",7);this.filterCaptionsInternal={title:"Filter by condition",save:"Save",reset:"Reset",cancel:"Close"};this.debouncedApplyFilter=o((function(){t.filterChange.emit(t.filterItems)}),400);this.isFilterIdSet=false;this.filterId=0;this.currentFilterId=-1;this.currentFilterType=p;this.changes=undefined;this.uuid=undefined;this.filterItems={};this.filterTypes={};this.filterNames={};this.filterEntities={};this.filterCaptions=undefined;this.disableDynamicFiltering=false}e.prototype.onMouseDown=function(e){if(this.changes&&!e.defaultPrevented){var t=e.target;if(this.isOutside(t)&&!s(t)){this.changes=undefined}}};e.prototype.show=function(e){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){this.changes=e;if(this.changes){this.changes.type=this.changes.type||p}return[2]}))}))};e.prototype.getChanges=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){return[2,this.changes]}))}))};e.prototype.componentWillRender=function(){if(!this.isFilterIdSet){this.isFilterIdSet=true;var e=Object.keys(this.filterItems);for(var t=0,i=e;t<i.length;t++){var r=i[t];this.filterId+=this.filterItems[r].length}}};e.prototype.renderSelectOptions=function(e,i){var r=this;if(i===void 0){i=false}var n;var o=[];var s=(n=this.changes)===null||n===void 0?void 0:n.prop;if(!i){o.push(t("option",{selected:this.currentFilterType===p,value:p},s&&this.filterItems[s]&&this.filterItems[s].length>0?"Add more condition...":this.filterNames[p]))}for(var l in this.filterTypes){o.push.apply(o,this.filterTypes[l].map((function(i){return t("option",{value:i,selected:e===i},r.filterNames[i])})));o.push(t("option",{disabled:true}))}return o};e.prototype.renderExtra=function(e,i){var r=this;var n=this.filterItems[e];if(!n)return"";if(this.filterEntities[n[i].type].extra!=="input")return"";return t("input",{id:"filter-input-".concat(n[i].id),placeholder:"Enter value...",type:"text",value:n[i].value,onInput:this.onUserInput.bind(this,i,e),onKeyDown:function(e){return r.onKeyDown(e)}})};e.prototype.getFilterItemsList=function(){var e=this;var i;var r=(i=this.changes)===null||i===void 0?void 0:i.prop;if(!(r||r===0))return"";var n=this.filterItems[r]||[];return t("div",{key:this.filterId},n.map((function(i,n){var o;if(n!==e.filterItems[r].length-1){o=t("div",{onClick:function(){return e.toggleFilterAndOr(i.id)}},t(l,{isAnd:i.relation==="and"}))}return t("div",{key:i.id,class:u},t("div",{class:{"select-input":true}},t("select",{class:"select-css select-filter",onChange:function(t){return e.onFilterTypeChange(t,r,n)}},e.renderSelectOptions(e.filterItems[r][n].type,true)),t("div",{class:f},o),t("div",{onClick:function(){return e.onRemoveFilter(i.id)}},t(a,null))),t("div",null,e.renderExtra(r,n)))})),n.length>0?t("div",{class:"add-filter-divider"}):"")};e.prototype.render=function(){var e=this;if(!this.changes){return t(n,{style:{display:"none"}})}var i={display:"block",left:"".concat(this.changes.x,"px"),top:"".concat(this.changes.y,"px")};var r=Object.assign(this.filterCaptionsInternal,this.filterCaptions);return t(n,{style:i},t("label",null,r.title),t("div",{class:"filter-holder"},this.getFilterItemsList()),t("div",{class:"add-filter"},t("select",{id:"add-filter",class:"select-css",onChange:function(t){return e.onAddNewFilter(t)}},this.renderSelectOptions(this.currentFilterType))),t("div",{class:"filter-actions"},this.disableDynamicFiltering&&t(c,{class:{red:true,save:true},onClick:function(){return e.onSave()}},r.save),t(c,{class:{red:true,reset:true},onClick:function(){return e.onReset()}},r.reset),t(c,{class:{light:true,cancel:true},onClick:function(){return e.onCancel()}},r.cancel)))};e.prototype.onFilterTypeChange=function(e,t,i){var r=this;var n=e.target;var o=n.value;this.filterItems[t][i].type=o;this.filterId++;setTimeout((function(){var e=document.getElementById("filter-input-"+r.filterItems[t][i].id);if(e)e.focus()}),0);if(!this.disableDynamicFiltering)this.debouncedApplyFilter()};e.prototype.onAddNewFilter=function(e){var t=e.target;var i=t.value;this.currentFilterType=i;this.addNewFilterToProp();var r=document.getElementById("add-filter");if(r){r.value=p;this.currentFilterType=p}if(!this.disableDynamicFiltering)this.debouncedApplyFilter()};e.prototype.addNewFilterToProp=function(){var e=this;var t;var i=(t=this.changes)===null||t===void 0?void 0:t.prop;if(!(i||i===0))return;if(!this.filterItems[i]){this.filterItems[i]=[]}if(this.currentFilterType==="none")return;this.filterId++;this.currentFilterId=this.filterId;this.filterItems[i].push({id:this.currentFilterId,type:this.currentFilterType,value:"",relation:"and"});setTimeout((function(){var t=document.getElementById("filter-input-"+e.currentFilterId);if(t)t.focus()}),0)};e.prototype.onUserInput=function(e,t,i){this.filterItems[t][e].value=i.target.value;if(!this.disableDynamicFiltering)this.debouncedApplyFilter()};e.prototype.onKeyDown=function(e){if(e.key.toLowerCase()==="enter"){var t=document.getElementById("add-filter");if(t){t.value=p;this.currentFilterType=p;this.addNewFilterToProp();t.focus()}return}e.stopPropagation()};e.prototype.onSave=function(){this.filterChange.emit(this.filterItems)};e.prototype.onCancel=function(){this.changes=undefined};e.prototype.onReset=function(){this.assertChanges();delete this.filterItems[this.changes.prop];this.filterId++;this.filterChange.emit(this.filterItems)};e.prototype.onRemoveFilter=function(e){this.assertChanges();this.filterId++;var t=this.changes.prop;var i=this.filterItems[t];if(!i)return;var r=i.findIndex((function(t){return t.id===e}));if(r===-1)return;i.splice(r,1);if(i.length===0)delete this.filterItems[t];if(!this.disableDynamicFiltering)this.debouncedApplyFilter()};e.prototype.toggleFilterAndOr=function(e){this.assertChanges();this.filterId++;var t=this.changes.prop;var i=this.filterItems[t];if(!i)return;var r=i.findIndex((function(t){return t.id===e}));if(r===-1)return;i[r].relation=i[r].relation==="and"?"or":"and";if(!this.disableDynamicFiltering)this.debouncedApplyFilter()};e.prototype.assertChanges=function(){if(!this.changes){throw new Error("Changes required per edit")}};e.prototype.isOutside=function(e){var t=document.getElementById("add-filter");if(t)t.value=p;this.currentFilterType=p;this.changes.type=p;this.currentFilterId=-1;if(e.classList.contains('[uuid="'.concat(this.uuid,'"]'))){return false}return!(e===null||e===void 0?void 0:e.closest('[uuid="'.concat(this.uuid,'"]')))};return e}());h.style=d}}}));
|
|
5
|
+
//# sourceMappingURL=revogr-filter-panel.system.entry.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["RevoButton","props","children","h","Object","assign","class","_b","_c","closest","Element","prototype","matches","msMatchesSelector","webkitMatchesSelector","s","el","this","call","parentElement","parentNode","nodeType","filterStyleCss","defaultType","FILTER_LIST_CLASS","FILTER_LIST_CLASS_ACTION","FilterPanel","exports","filterCaptionsInternal","title","save","reset","cancel","debouncedApplyFilter","debounce","_this","filterChange","emit","filterItems","class_1","onMouseDown","e","changes","defaultPrevented","target","isOutside","isFilterBtn","undefined","show","newEntity","type","getChanges","componentWillRender","isFilterIdSet","keys","_i","filterItems_1","length","prop","filterId","renderSelectOptions","isDefaultTypeRemoved","options","_a","push","selected","currentFilterType","value","filterNames","gIndex","filterTypes","apply","map","k","disabled","renderExtra","index","currentFilter","filterEntities","extra","id","concat","placeholder","onInput","onUserInput","bind","onKeyDown","getFilterItemsList","propFilters","key","d","andOrButton","onClick","toggleFilterAndOr","AndOrButton","isAnd","relation","onChange","onFilterTypeChange","onRemoveFilter","TrashButton","render","Host","style","display","left","x","top","y","capts","filterCaptions","onAddNewFilter","disableDynamicFiltering","red","onSave","onReset","light","onCancel","setTimeout","input","document","getElementById","focus","addNewFilterToProp","select","currentFilterId","event","toLowerCase","stopPropagation","assertChanges","items","findIndex","splice","Error","classList","contains","uuid"],"sources":["src/components/button/button.tsx","src/utils/closestPolifill.ts","src/plugins/filter/filter.style.scss?tag=revogr-filter-panel","src/plugins/filter/filter.pop.tsx"],"sourcesContent":["import { h } from '@stencil/core';\nimport { JSXBase, VNode } from '@stencil/core/internal';\n\ninterface Props extends Partial<JSXBase.ButtonHTMLAttributes<HTMLButtonElement>> {}\n\nexport const RevoButton = (props: Props, children: VNode[]) => {\n return (\n <button\n {...props}\n class={{\n ...(typeof props.class === 'object' ? props.class : props.class ? { [props.class]: true } : ''),\n ['revo-button']: true,\n }}\n >\n {children}\n </button>\n );\n};\n","(function closest() {\n if (!Element.prototype.matches) {\n Element.prototype.matches =\n ((Element.prototype as unknown) as { msMatchesSelector: (selectors: string) => boolean }).msMatchesSelector || Element.prototype.webkitMatchesSelector;\n }\n\n if (!Element.prototype.closest) {\n Element.prototype.closest = function (s: string) {\n let el: HTMLElement | Element | (Node & ParentNode) = this;\n\n do {\n if (Element.prototype.matches.call(el, s)) {\n return el;\n }\n el = el.parentElement || el.parentNode;\n } while (el !== null && el.nodeType === 1);\n return null;\n };\n }\n})();\n","revogr-filter-panel {\n position: absolute;\n display: block;\n top: 0;\n left: 0;\n z-index: 100;\n\n opacity: 1;\n transform: none;\n background-color: #fff;\n transform-origin: 62px 0px;\n box-shadow: 0 5px 18px -2px rgba(black, 20%);\n padding: 10px;\n border-radius: 4px;\n\n min-width: 220px;\n text-align: left;\n\n .filter-holder > div {\n display: flex;\n flex-direction: column;\n }\n\n label {\n color: gray;\n font-size: 13px;\n font-weight: 600;\n display: block;\n padding: 8px 0;\n }\n\n select {\n width: 100%;\n }\n\n input[type=\"text\"] {\n border: 0;\n min-height: 34px;\n margin: 5px 0;\n background: #f3f3f3;\n border-radius: 5px;\n padding: 0 10px;\n box-sizing: border-box;\n width: 100%;\n }\n\n button {\n margin-top: 10px;\n margin-right: 5px;\n }\n\n\n .filter-actions {\n text-align: right;\n margin-right: -5px;\n }\n}\n\n.rgHeaderCell {\n &:hover .rv-filter {\n transition: opacity 267ms cubic-bezier(0.4, 0, 0.2, 1) 0ms, transform 178ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;\n }\n &:hover .rv-filter,\n .rv-filter.active {\n opacity: 1;\n }\n\n .rv-filter {\n $btn-size: 24px;\n height: $btn-size;\n width: $btn-size;\n background: none;\n border: 0;\n opacity: 0;\n visibility: visible;\n cursor: pointer;\n border-radius: 4px;\n\n &.active {\n color: #10224a;\n }\n\n .filter-img {\n $img-size: 11px;\n color: gray;\n width: $img-size;\n }\n }\n}\n\n.select-css {\n $gradient: \"data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%23007CB2%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E\";\n $linearGradient: linear-gradient(to bottom, #ffffff 0%, #ffffff 100%);\n $borderColor: #f1f1f1;\n\n display: block;\n font-family: sans-serif;\n font-weight: 600;\n color: #444;\n line-height: 1.3;\n padding: 0.6em 1.4em 0.5em 0.8em;\n width: 100%;\n max-width: 100%; /* useful when width is set to anything other than 100% */\n box-sizing: border-box;\n margin: 0;\n border: 1px solid $borderColor;\n box-shadow: transparent;\n border-radius: 0.5em;\n appearance: none;\n background-color: #fff;\n background-image: url($gradient), $linearGradient;\n background-repeat: no-repeat, repeat;\n /* arrow icon position (1em from the right, 50% vertical) , then gradient position*/\n background-position: right 0.7em top 50%, 0 0;\n /* icon size, then gradient */\n background-size: 0.65em auto, 100%;\n\n /* Hide arrow icon in IE browsers */\n &::-ms-expand {\n display: none;\n }\n /* Hover style */\n &:hover {\n border-color: rgb(197, 197, 197);\n }\n /* Focus style */\n &:focus {\n border-color: $borderColor;\n box-shadow: 0 0 1px 3px rgba(59, 153, 252, 0.7);\n box-shadow: 0 0 0 3px -moz-mac-focusring;\n color: #222;\n outline: none;\n }\n\n /* Set options to normal weight */\n option {\n font-weight: normal;\n }\n\n /* Disabled styles */\n &:disabled,\n &[aria-disabled=\"true\"] {\n color: gray;\n background-image: url(\"data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22graytext%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E\"),\n linear-gradient(to bottom, #ffffff 0%, #ffffff 100%);\n }\n\n &:disabled:hover,\n &[aria-disabled=\"true\"] {\n border-color: $borderColor;\n }\n}\n\n.multi-filter-list {\n margin-top: 5px;\n margin-bottom: 5px;\n\n div {\n white-space: nowrap;\n }\n\n .multi-filter-list-action {\n display: flex;\n\n justify-content: space-between;\n align-items: center;\n }\n\n .and-or-button {\n margin: 0 0 0 10px;\n min-width: 58px;\n cursor: pointer;\n }\n .trash-button {\n $btn-remove-size: 22px;\n margin: 0 0 -2px 6px;\n cursor: pointer;\n\n width: $btn-remove-size;\n height: $btn-remove-size;\n color: gray;\n font-size: 18px;\n\n\n .trash-img {\n width: 1em;\n }\n }\n}\n\n.add-filter-divider {\n display: block;\n margin: 0 -10px 10px -10px;\n\n border-bottom: 1px solid #d9d9d9;\n height: 10px;\n box-shadow: 0 4px 5px rgb(0 0 0 / 5%);\n}\n\n.select-input {\n display: flex;\n justify-content: space-between;\n align-items: center;\n}","import { Component, h, Host, Listen, Prop, State, Event, EventEmitter, VNode, Method } from '@stencil/core';\nimport { FilterType } from './filter.service';\nimport { RevoGrid } from '../../interfaces';\nimport { AndOrButton, isFilterBtn, TrashButton } from './filter.button';\nimport { RevoButton } from '../../components/button/button';\nimport '../../utils/closestPolifill';\nimport { LogicFunction } from './filter.types';\nimport { FilterCaptions } from './filter.plugin';\nimport debounce from 'lodash/debounce';\n\n/**\n * @typedef FilterItem\n * @type {object}\n * @property {ColumnProp} prop - column id\n * @property {FilterType} type - filter type definition\n * @property {any} value - value for additional filtering, text value or some id\n */\nexport type FilterItem = {\n prop?: RevoGrid.ColumnProp;\n type?: FilterType;\n value?: any;\n};\n\nexport type FilterData = {\n id: number;\n type: FilterType;\n value?: any;\n relation: 'and' | 'or';\n};\n\nexport type MultiFilterItem = {\n [prop: string]: FilterData[];\n};\n\nexport type ShowData = {\n x: number;\n y: number;\n} & FilterItem;\n\nconst defaultType: FilterType = 'none';\n\nconst FILTER_LIST_CLASS = 'multi-filter-list';\nconst FILTER_LIST_CLASS_ACTION = 'multi-filter-list-action';\n\n@Component({\n tag: 'revogr-filter-panel',\n styleUrl: 'filter.style.scss',\n})\nexport class FilterPanel {\n private filterCaptionsInternal: FilterCaptions = {\n title: 'Filter by condition',\n save: 'Save',\n reset: 'Reset',\n cancel: 'Close',\n };\n @State() isFilterIdSet = false;\n @State() filterId = 0;\n @State() currentFilterId: number = -1;\n @State() currentFilterType: FilterType = defaultType;\n @State() changes: ShowData | undefined;\n @Prop({ mutable: true, reflect: true }) uuid: string;\n @Prop() filterItems: MultiFilterItem = {};\n @Prop() filterTypes: Record<string, string[]> = {};\n @Prop() filterNames: Record<string, string> = {};\n @Prop() filterEntities: Record<string, LogicFunction> = {};\n @Prop() filterCaptions: FilterCaptions | undefined;\n @Prop() disableDynamicFiltering: boolean = false;\n @Event() filterChange: EventEmitter<MultiFilterItem>;\n @Listen('mousedown', { target: 'document' }) onMouseDown(e: MouseEvent): void {\n if (this.changes && !e.defaultPrevented) {\n const el = e.target as HTMLElement;\n if (this.isOutside(el) && !isFilterBtn(el)) {\n this.changes = undefined;\n }\n }\n }\n @Method() async show(newEntity?: ShowData) {\n this.changes = newEntity;\n if (this.changes) {\n this.changes.type = this.changes.type || defaultType;\n }\n }\n\n @Method() async getChanges() {\n return this.changes;\n }\n\n componentWillRender() {\n if (!this.isFilterIdSet) {\n this.isFilterIdSet = true;\n const filterItems = Object.keys(this.filterItems);\n for (const prop of filterItems) {\n // we set the proper filterId so there won't be any conflict when removing filters\n this.filterId += this.filterItems[prop].length;\n }\n }\n }\n\n renderSelectOptions(type: FilterType, isDefaultTypeRemoved = false) {\n const options: VNode[] = [];\n const prop = this.changes?.prop;\n\n if (!isDefaultTypeRemoved) {\n options.push(\n <option selected={this.currentFilterType === defaultType} value={defaultType}>\n {prop && this.filterItems[prop] && this.filterItems[prop].length > 0 ? 'Add more condition...' : this.filterNames[defaultType]}\n </option>,\n );\n }\n\n for (let gIndex in this.filterTypes) {\n options.push(\n ...this.filterTypes[gIndex].map(k => (\n <option value={k} selected={type === k}>\n {this.filterNames[k]}\n </option>\n )),\n );\n options.push(<option disabled></option>);\n }\n return options;\n }\n\n renderExtra(prop: RevoGrid.ColumnProp, index: number) {\n const currentFilter = this.filterItems[prop];\n\n if (!currentFilter) return '';\n\n if (this.filterEntities[currentFilter[index].type].extra !== 'input') return '';\n\n return (\n <input\n id={`filter-input-${currentFilter[index].id}`}\n placeholder=\"Enter value...\"\n type=\"text\"\n value={currentFilter[index].value}\n onInput={this.onUserInput.bind(this, index, prop)}\n onKeyDown={e => this.onKeyDown(e)}\n />\n );\n }\n\n getFilterItemsList() {\n const prop = this.changes?.prop;\n if (!(prop || prop === 0)) return '';\n\n const propFilters = this.filterItems[prop] || [];\n return (\n <div key={this.filterId}>\n {propFilters.map((d, index) => {\n let andOrButton;\n\n // hide toggle button if there is only one filter and the last one\n if (index !== this.filterItems[prop].length - 1) {\n andOrButton = (\n <div onClick={() => this.toggleFilterAndOr(d.id)}>\n <AndOrButton isAnd={d.relation === 'and'} />\n </div>\n );\n }\n\n return (\n <div key={d.id} class={FILTER_LIST_CLASS}>\n <div class={{ 'select-input': true }}>\n <select class=\"select-css select-filter\" onChange={e => this.onFilterTypeChange(e, prop, index)}>\n {this.renderSelectOptions(this.filterItems[prop][index].type, true)}\n </select>\n <div class={FILTER_LIST_CLASS_ACTION}>{andOrButton}</div>\n <div onClick={() => this.onRemoveFilter(d.id)}>\n <TrashButton />\n </div>\n </div>\n <div>{this.renderExtra(prop, index)}</div>\n </div>\n );\n })}\n\n {propFilters.length > 0 ? <div class=\"add-filter-divider\"></div> : ''}\n </div>\n );\n }\n\n render() {\n if (!this.changes) {\n return <Host style={{ display: 'none' }}></Host>;\n }\n const style = {\n display: 'block',\n left: `${this.changes.x}px`,\n top: `${this.changes.y}px`,\n };\n\n const capts = Object.assign(this.filterCaptionsInternal, this.filterCaptions);\n\n return (\n <Host style={style}>\n <label>{capts.title}</label>\n <div class=\"filter-holder\">{this.getFilterItemsList()}</div>\n\n <div class=\"add-filter\">\n <select id=\"add-filter\" class=\"select-css\" onChange={e => this.onAddNewFilter(e)}>\n {this.renderSelectOptions(this.currentFilterType)}\n </select>\n </div>\n <div class=\"filter-actions\">\n {this.disableDynamicFiltering &&\n <RevoButton class={{ red: true, save: true }} onClick={() => this.onSave()}>\n {capts.save}\n </RevoButton>\n }\n <RevoButton class={{ red: true, reset: true }} onClick={() => this.onReset()}>\n {capts.reset}\n </RevoButton>\n <RevoButton class={{ light: true, cancel: true }} onClick={() => this.onCancel()}>\n {capts.cancel}\n </RevoButton>\n </div>\n </Host>\n );\n }\n\n private onFilterTypeChange(e: Event, prop: RevoGrid.ColumnProp, index: number) {\n const el = e.target as HTMLSelectElement;\n const type = el.value as FilterType;\n\n this.filterItems[prop][index].type = type;\n\n // this re-renders the input to know if we need extra input\n this.filterId++;\n\n // adding setTimeout will wait for the next tick DOM update then focus on input\n setTimeout(() => {\n const input = document.getElementById('filter-input-' + this.filterItems[prop][index].id) as HTMLInputElement;\n if (input) input.focus();\n }, 0);\n\n if (!this.disableDynamicFiltering) this.debouncedApplyFilter();\n }\n\n private debouncedApplyFilter = debounce(() => {\n this.filterChange.emit(this.filterItems);\n }, 400);\n\n private onAddNewFilter(e: Event) {\n const el = e.target as HTMLSelectElement;\n const type = el.value as FilterType;\n\n this.currentFilterType = type;\n this.addNewFilterToProp();\n\n // reset value after adding new filter\n const select = document.getElementById('add-filter') as HTMLSelectElement;\n if (select) {\n select.value = defaultType;\n this.currentFilterType = defaultType;\n }\n\n if (!this.disableDynamicFiltering) this.debouncedApplyFilter();\n }\n\n private addNewFilterToProp() {\n const prop = this.changes?.prop;\n if (!(prop || prop === 0)) return;\n\n if (!this.filterItems[prop]) {\n this.filterItems[prop] = [];\n }\n\n if (this.currentFilterType === 'none') return;\n\n this.filterId++;\n this.currentFilterId = this.filterId;\n\n this.filterItems[prop].push({\n id: this.currentFilterId,\n type: this.currentFilterType,\n value: '',\n relation: 'and',\n });\n\n // adding setTimeout will wait for the next tick DOM update then focus on input\n setTimeout(() => {\n const input = document.getElementById('filter-input-' + this.currentFilterId) as HTMLInputElement;\n if (input) input.focus();\n }, 0);\n }\n\n private onUserInput(index: number, prop: RevoGrid.ColumnProp, event: Event) {\n // update the value of the filter item\n this.filterItems[prop][index].value = (event.target as HTMLInputElement).value;\n\n if (!this.disableDynamicFiltering) this.debouncedApplyFilter();\n }\n\n private onKeyDown(e: KeyboardEvent) {\n if (e.key.toLowerCase() === 'enter') {\n const select = document.getElementById('add-filter') as HTMLSelectElement;\n if (select) {\n select.value = defaultType;\n this.currentFilterType = defaultType;\n this.addNewFilterToProp();\n select.focus();\n }\n return;\n }\n // keep event local, don't escalate farther to dom\n e.stopPropagation();\n }\n\n private onSave() {\n this.filterChange.emit(this.filterItems);\n }\n\n private onCancel() {\n this.changes = undefined;\n }\n\n private onReset() {\n this.assertChanges();\n\n delete this.filterItems[this.changes.prop];\n\n // this updates the DOM which is used by getFilterItemsList() key\n this.filterId++;\n\n this.filterChange.emit(this.filterItems);\n }\n\n private onRemoveFilter(id: number) {\n this.assertChanges();\n\n // this is for reactivity issues for getFilterItemsList()\n this.filterId++;\n\n const prop = this.changes.prop;\n\n const items = this.filterItems[prop];\n if (!items) return;\n\n const index = items.findIndex(d => d.id === id);\n if (index === -1) return;\n items.splice(index, 1);\n\n // let's remove the prop if no more filters so the filter icon will be removed\n if (items.length === 0) delete this.filterItems[prop];\n\n if (!this.disableDynamicFiltering) this.debouncedApplyFilter();\n }\n\n private toggleFilterAndOr(id: number) {\n this.assertChanges();\n\n // this is for reactivity issues for getFilterItemsList()\n this.filterId++;\n\n const prop = this.changes.prop;\n\n const items = this.filterItems[prop];\n if (!items) return;\n\n const index = items.findIndex(d => d.id === id);\n if (index === -1) return;\n\n items[index].relation = items[index].relation === 'and' ? 'or' : 'and';\n if (!this.disableDynamicFiltering) this.debouncedApplyFilter();\n }\n\n private assertChanges() {\n if (!this.changes) {\n throw new Error('Changes required per edit');\n }\n }\n\n private isOutside(e: HTMLElement | null) {\n const select = document.getElementById('add-filter') as HTMLSelectElement;\n if (select) select.value = defaultType;\n\n this.currentFilterType = defaultType;\n this.changes.type = defaultType;\n this.currentFilterId = -1;\n if (e.classList.contains(`[uuid=\"${this.uuid}\"]`)) {\n return false;\n }\n return !e?.closest(`[uuid=\"${this.uuid}\"]`);\n }\n}\n"],"mappings":";;;8OAKO,IAAMA,EAAa,SAACC,EAAcC,G,QACvC,OACEC,EAAA,SAAAC,OAAAC,OAAA,GACMJ,EAAK,CACTK,MAAKF,OAAAC,OAAAD,OAAAC,OAAA,UACQJ,EAAMK,QAAU,SAAWL,EAAMK,MAAQL,EAAMK,OAAKC,EAAA,GAAKA,EAACN,EAAMK,OAAQ,KAAIC,GAAK,KAAEC,EAAA,GAC9FA,EAAC,eAAgB,KAAIA,MAGtBN,EAGP,GCjBA,SAAUO,IACR,IAAKC,QAAQC,UAAUC,QAAS,CAC9BF,QAAQC,UAAUC,QACdF,QAAQC,UAAgFE,mBAAqBH,QAAQC,UAAUG,qB,CAGrI,IAAKJ,QAAQC,UAAUF,QAAS,CAC9BC,QAAQC,UAAUF,QAAU,SAAUM,GACpC,IAAIC,EAAkDC,KAEtD,EAAG,CACD,GAAIP,QAAQC,UAAUC,QAAQM,KAAKF,EAAID,GAAI,CACzC,OAAOC,C,CAETA,EAAKA,EAAGG,eAAiBH,EAAGI,U,OACrBJ,IAAO,MAAQA,EAAGK,WAAa,GACxC,OAAO,I,EAGZ,EAnBD,GCAA,IAAMC,EAAiB,80bCuCvB,IAAMC,EAA0B,OAEhC,IAAMC,EAAoB,oBAC1B,IAAMC,EAA2B,2B,IAMpBC,EAAWC,EAAA,iC,8EACdV,KAAAW,uBAAyC,CAC/CC,MAAO,sBACPC,KAAM,OACNC,MAAO,QACPC,OAAQ,SA0LFf,KAAAgB,qBAA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|
-
export
|
|
14
|
-
export
|
|
15
|
-
export
|
|
13
|
+
export type ColumnSource = Observable<DataSourceState<RevoGrid.ColumnRegular, RevoGrid.DimensionCols>>;
|
|
14
|
+
export type RowSource = Observable<DataSourceState<DataType, RevoGrid.DimensionRows>>;
|
|
15
|
+
export type ColumnStores = {
|
|
16
16
|
[T in RevoGrid.DimensionCols]: ColumnSource;
|
|
17
17
|
};
|
|
18
|
-
export
|
|
18
|
+
export type RowStores = {
|
|
19
19
|
[T in RevoGrid.DimensionRows]: RowSource;
|
|
20
20
|
};
|
|
21
21
|
export default class ColumnService implements ColumnServiceI {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { VNode } from '../../stencil-public-runtime';
|
|
2
2
|
import { RevoGrid, Selection } from '../../interfaces';
|
|
3
3
|
import { ResizeEvent } from '../../services/resizable.directive';
|
|
4
|
-
|
|
4
|
+
type Props = {
|
|
5
5
|
column: RevoGrid.VirtualPositionItem;
|
|
6
6
|
data?: RevoGrid.ColumnRegular;
|
|
7
7
|
range?: Selection.RangeArea;
|
|
@@ -3,7 +3,7 @@ import { EventData } from './selection.utils';
|
|
|
3
3
|
import SelectionStoreService from '../../store/selection/selection.store.service';
|
|
4
4
|
import ColumnService from '../data/columnService';
|
|
5
5
|
import { DataSourceState } from '../../store/dataSource/data.store';
|
|
6
|
-
|
|
6
|
+
type Config = {
|
|
7
7
|
selectionStoreService: SelectionStoreService;
|
|
8
8
|
dimensionRow: Observable<RevoGrid.DimensionSettingsState>;
|
|
9
9
|
dimensionCol: Observable<RevoGrid.DimensionSettingsState>;
|
|
@@ -2,7 +2,7 @@ import SelectionStoreService from '../../store/selection/selection.store.service
|
|
|
2
2
|
import { Observable, RevoGrid, Selection } from '../../interfaces';
|
|
3
3
|
import ColumnService from '../data/columnService';
|
|
4
4
|
import { DataSourceState } from '../../store/dataSource/data.store';
|
|
5
|
-
|
|
5
|
+
type Config = {
|
|
6
6
|
selectionStoreService: SelectionStoreService;
|
|
7
7
|
columnService: ColumnService;
|
|
8
8
|
dataStore: Observable<DataSourceState<RevoGrid.DataType, RevoGrid.DimensionRows>>;
|
|
@@ -4,7 +4,7 @@ import { Edition, RevoGrid } from '../../../interfaces';
|
|
|
4
4
|
* Closes editor when called
|
|
5
5
|
* @param preventFocus - if true editor will not be closed and next cell will not be focused
|
|
6
6
|
*/
|
|
7
|
-
export
|
|
7
|
+
export type SaveCallback = (value: Edition.SaveData, preventFocus: boolean) => void;
|
|
8
8
|
export declare class TextEditor implements Edition.EditorBase {
|
|
9
9
|
column: RevoGrid.ColumnRegular;
|
|
10
10
|
private saveCallback?;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Observable, Selection } from '../../interfaces';
|
|
2
2
|
import SelectionStoreService from '../../store/selection/selection.store.service';
|
|
3
3
|
import { EventData } from './selection.utils';
|
|
4
|
-
|
|
4
|
+
type Config = {
|
|
5
5
|
selectionStoreService: SelectionStoreService;
|
|
6
6
|
selectionStore: Observable<Selection.SelectionStoreState>;
|
|
7
7
|
doEdit(val?: any): void;
|
|
@@ -10,7 +10,6 @@ export declare class OverlaySelection {
|
|
|
10
10
|
private autoFillService;
|
|
11
11
|
private clipboardService;
|
|
12
12
|
private orderEditor;
|
|
13
|
-
private readonly events;
|
|
14
13
|
element: HTMLElement;
|
|
15
14
|
readonly: boolean;
|
|
16
15
|
range: boolean;
|
|
@@ -43,8 +42,17 @@ export declare class OverlaySelection {
|
|
|
43
42
|
internalSelectionChanged: EventEmitter<Selection.ChangedRange>;
|
|
44
43
|
/** Range data apply */
|
|
45
44
|
internalRangeDataApply: EventEmitter<Edition.BeforeRangeSaveDataDetails>;
|
|
45
|
+
onMouseMove(e: MouseEvent): void;
|
|
46
|
+
/** Pointer left document, clear any active operation */
|
|
47
|
+
onMouseOut(): void;
|
|
48
|
+
/** Action finished inside of the document */
|
|
49
|
+
onMouseUp(): void;
|
|
46
50
|
/** Row drag started */
|
|
47
51
|
onCellDrag(e: CustomEvent<MouseEvent>): void;
|
|
52
|
+
/** Recived keyboard down from element */
|
|
53
|
+
onKeyUp(e: KeyboardEvent): void;
|
|
54
|
+
/** Recived keyboard down from element */
|
|
55
|
+
onKeyDown(e: KeyboardEvent): void;
|
|
48
56
|
/** Create selection store */
|
|
49
57
|
selectionServiceSet(s: Observable<Selection.SelectionStoreState>): void;
|
|
50
58
|
createAutoFillService(): void;
|
|
@@ -52,8 +60,6 @@ export declare class OverlaySelection {
|
|
|
52
60
|
createClipboardService(): void;
|
|
53
61
|
connectedCallback(): void;
|
|
54
62
|
disconnectedCallback(): void;
|
|
55
|
-
protected addListener(name: string, func: (e: Event) => void): void;
|
|
56
|
-
protected removeListener(type: string): void;
|
|
57
63
|
private renderRange;
|
|
58
64
|
private renderEditCell;
|
|
59
65
|
render(): any;
|
|
@@ -7,7 +7,7 @@ export interface ElementScroll {
|
|
|
7
7
|
changeScroll?(e: RevoGrid.ViewPortScrollEvent): Promise<RevoGrid.ViewPortScrollEvent>;
|
|
8
8
|
setScroll(e: RevoGrid.ViewPortScrollEvent): Promise<void>;
|
|
9
9
|
}
|
|
10
|
-
|
|
10
|
+
type Props = {
|
|
11
11
|
viewports: ViewportStores;
|
|
12
12
|
dimensions: DimensionStores;
|
|
13
13
|
orderRef(e: OrdererService): void;
|