@revolist/revogrid 3.1.8 → 3.2.5
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/index.js +455 -217
- package/custom-element/resize-observer.js +25 -11
- package/dist/cjs/css-shim-9f5bc84d.js +9 -0
- package/dist/cjs/{debounce-e9b040d9.js → debounce-6cea2774.js} +4 -1
- package/dist/cjs/{dom-c8b6d1a7.js → dom-fcb646f0.js} +4 -1
- package/dist/cjs/{index-d3f67f2e.js → index-cb904e00.js} +193 -91
- package/dist/cjs/index.cjs.js +3 -0
- package/dist/cjs/loader.cjs.js +7 -4
- package/dist/cjs/{resize-observer-8dc80084.js → resize-observer-bf327d6a.js} +25 -10
- package/dist/cjs/revo-grid.cjs.js +13 -7
- package/dist/cjs/revo-grid_11.cjs.entry.js +244 -6
- package/dist/cjs/revogr-clipboard.cjs.entry.js +4 -1
- package/dist/cjs/revogr-filter-panel.cjs.entry.js +5 -2
- package/dist/collection/collection-manifest.json +2 -2
- package/dist/collection/components/button/button.js +3 -0
- package/dist/collection/components/clipboard/revogr-clipboard.js +3 -0
- package/dist/collection/components/data/cellRenderer.js +3 -0
- package/dist/collection/components/data/columnService.js +3 -0
- package/dist/collection/components/data/revogr-data.js +3 -0
- package/dist/collection/components/data/rowRenderer.js +3 -0
- package/dist/collection/components/header/headerCellRenderer.js +11 -1
- package/dist/collection/components/header/headerRenderer.js +3 -0
- package/dist/collection/components/header/revogr-header.js +3 -0
- package/dist/collection/components/order/orderRenderer.js +3 -0
- package/dist/collection/components/order/revogr-order-editor.js +3 -0
- package/dist/collection/components/order/rowOrderService.js +3 -0
- package/dist/collection/components/overlay/autofill.service.js +3 -0
- package/dist/collection/components/overlay/clipboard.service.js +3 -0
- package/dist/collection/components/overlay/editors/edit.utils.js +3 -0
- package/dist/collection/components/overlay/editors/text.js +3 -0
- package/dist/collection/components/overlay/keyboard.service.js +3 -0
- package/dist/collection/components/overlay/revogr-edit.js +3 -0
- package/dist/collection/components/overlay/revogr-overlay-selection.js +3 -0
- package/dist/collection/components/overlay/selection.utils.js +3 -0
- package/dist/collection/components/revo-grid/revo-grid-style.css +18 -1
- package/dist/collection/components/revo-grid/revo-grid.js +53 -15
- package/dist/collection/components/revo-grid/viewport.helpers.js +3 -0
- package/dist/collection/components/revo-grid/viewport.interfaces.js +3 -0
- package/dist/collection/components/revo-grid/viewport.js +3 -0
- package/dist/collection/components/revo-grid/viewport.resize.service.js +3 -0
- package/dist/collection/components/revo-grid/viewport.scrolling.service.js +3 -0
- package/dist/collection/components/revo-grid/viewport.section.js +3 -0
- package/dist/collection/components/revo-grid/viewport.service.js +3 -0
- package/dist/collection/components/rowHeaders/revogr-row-headers.js +3 -0
- package/dist/collection/components/rowHeaders/row-header-render.js +3 -0
- package/dist/collection/components/scroll/revogr-viewport-scroll.js +5 -2
- package/dist/collection/components/scrollable/revogr-scroll-virtual.js +3 -0
- package/dist/collection/components/selection-focus/revogr-focus.js +3 -0
- package/dist/collection/components/selection-temp-range/revogr-temp-range.js +3 -0
- package/dist/collection/global/global.js +3 -0
- package/dist/collection/index.js +3 -0
- package/dist/collection/plugins/autoSizeColumn.js +3 -0
- package/dist/collection/plugins/basePlugin.js +3 -0
- package/dist/collection/plugins/dispatcher.js +22 -0
- package/dist/collection/plugins/export/csv.js +3 -0
- package/dist/collection/plugins/export/export.plugin.js +3 -0
- package/dist/collection/plugins/export/types.js +3 -0
- package/dist/collection/plugins/filter/conditions/equal.js +3 -0
- package/dist/collection/plugins/filter/conditions/number/greaterThan.js +3 -0
- package/dist/collection/plugins/filter/conditions/number/greaterThanOrEqual.js +3 -0
- package/dist/collection/plugins/filter/conditions/number/lessThan.js +3 -0
- package/dist/collection/plugins/filter/conditions/number/lessThanOrEqual.js +3 -0
- package/dist/collection/plugins/filter/conditions/set.js +3 -0
- package/dist/collection/plugins/filter/conditions/string/beginswith.js +3 -0
- package/dist/collection/plugins/filter/conditions/string/contains.js +3 -0
- package/dist/collection/plugins/filter/filter.button.js +3 -0
- package/dist/collection/plugins/filter/filter.plugin.js +3 -0
- package/dist/collection/plugins/filter/filter.pop.js +3 -0
- package/dist/collection/plugins/filter/filter.service.js +3 -0
- package/dist/collection/plugins/filter/filter.types.js +3 -0
- package/dist/collection/plugins/groupingColumn/columnGroupsRenderer.js +3 -0
- package/dist/collection/plugins/groupingColumn/grouping.col.plugin.js +3 -0
- package/dist/collection/plugins/groupingColumn/headerGroupRenderer.js +3 -0
- package/dist/collection/plugins/groupingRow/grouping.const.js +3 -0
- package/dist/collection/plugins/groupingRow/grouping.row.expand.service.js +3 -0
- package/dist/collection/plugins/groupingRow/grouping.row.plugin.js +3 -0
- package/dist/collection/plugins/groupingRow/grouping.row.renderer.js +3 -0
- package/dist/collection/plugins/groupingRow/grouping.row.types.js +3 -0
- package/dist/collection/plugins/groupingRow/grouping.service.js +3 -0
- package/dist/collection/plugins/groupingRow/grouping.trimmed.service.js +3 -0
- package/dist/collection/plugins/moveColumn/columnDragPlugin.js +148 -0
- package/dist/collection/plugins/moveColumn/columnOrderHandler.js +63 -0
- package/dist/collection/plugins/sorting/sorting.plugin.js +3 -0
- package/dist/collection/plugins/sorting/sorting.sign.js +3 -0
- package/dist/collection/plugins/stretchPlugin.js +3 -0
- package/dist/collection/plugins/trimmed/trimmed.plugin.js +3 -0
- package/dist/collection/services/cell.helpers.js +3 -0
- package/dist/collection/services/column.data.provider.js +3 -0
- package/dist/collection/services/data.provider.js +3 -0
- package/dist/collection/services/dimension.provider.js +3 -0
- package/dist/collection/services/localScrollService.js +3 -0
- package/dist/collection/services/resizable.directive.js +3 -0
- package/dist/collection/services/selection.store.connector.js +3 -0
- package/dist/collection/services/viewport.provider.js +3 -0
- package/dist/collection/store/dataSource/data.proxy.js +3 -0
- package/dist/collection/store/dataSource/data.store.js +3 -0
- package/dist/collection/store/dimension/dimension.helpers.js +3 -0
- package/dist/collection/store/dimension/dimension.store.js +3 -0
- package/dist/collection/store/selection/selection.helpers.js +3 -0
- package/dist/collection/store/selection/selection.store.js +3 -0
- package/dist/collection/store/selection/selection.store.service.js +3 -0
- package/dist/collection/store/storeTypes.js +3 -0
- package/dist/collection/store/viewPort/viewport.helpers.js +3 -0
- package/dist/collection/store/viewPort/viewport.store.js +3 -0
- package/dist/collection/themeManager/theme.compact.js +3 -0
- package/dist/collection/themeManager/theme.default.js +3 -0
- package/dist/collection/themeManager/theme.material.js +3 -0
- package/dist/collection/themeManager/themeService.js +3 -0
- package/dist/collection/utils/closestPolifill.js +3 -0
- package/dist/collection/utils/consts.js +3 -0
- package/dist/collection/utils/generateAlphabetHeader.js +3 -0
- package/dist/collection/utils/keyCodes.js +3 -0
- package/dist/collection/utils/keyCodes.utils.js +3 -0
- package/dist/collection/utils/platform.js +3 -0
- package/dist/collection/utils/resizeObserver.js +3 -0
- package/dist/collection/utils/store.utils.js +3 -0
- package/dist/collection/utils/utils.js +3 -0
- package/dist/esm/css-shim-e1e1ea5e.js +7 -0
- package/dist/esm/{debounce-8dadcda7.js → debounce-e4e6dd45.js} +5 -2
- package/dist/esm/{dom-1b195079.js → dom-21bd1807.js} +4 -1
- package/dist/esm/{index-42c84e7c.js → index-6f753b3c.js} +193 -91
- package/dist/esm/index.js +3 -1
- package/dist/esm/loader.js +7 -4
- package/dist/esm/polyfills/css-shim.js +1 -1
- package/dist/esm/{resize-observer-56b7b34f.js → resize-observer-00c48d78.js} +25 -11
- package/dist/esm/revo-grid.js +13 -7
- package/dist/esm/revo-grid_11.entry.js +244 -6
- package/dist/esm/revogr-clipboard.entry.js +4 -1
- package/dist/esm/revogr-filter-panel.entry.js +5 -2
- package/dist/esm-es5/css-shim-e1e1ea5e.js +4 -0
- package/dist/esm-es5/{debounce-8dadcda7.js → debounce-e4e6dd45.js} +4 -1
- package/dist/esm-es5/{dom-1b195079.js → dom-21bd1807.js} +3 -0
- package/dist/esm-es5/index-6f753b3c.js +5 -0
- package/dist/esm-es5/index.js +3 -0
- package/dist/esm-es5/loader.js +4 -1
- package/dist/esm-es5/resize-observer-00c48d78.js +4 -0
- package/dist/esm-es5/revo-grid.js +4 -1
- package/dist/esm-es5/revo-grid_11.entry.js +4 -1
- package/dist/esm-es5/revogr-clipboard.entry.js +4 -1
- package/dist/esm-es5/revogr-filter-panel.entry.js +4 -1
- package/dist/revo-grid/css-shim-bcf89cc0.system.js +4 -0
- package/dist/revo-grid/css-shim-e1e1ea5e.js +4 -0
- package/dist/revo-grid/{debounce-f40a88f6.system.js → debounce-5a33c710.system.js} +4 -1
- package/dist/revo-grid/{debounce-d097578d.js → debounce-726bdadb.js} +4 -1
- package/dist/revo-grid/{dom-1b195079.js → dom-21bd1807.js} +3 -0
- package/dist/revo-grid/{dom-ee2dd1b3.system.js → dom-726246e2.system.js} +3 -0
- package/dist/revo-grid/index-f14b41a0.system.js +5 -0
- package/dist/revo-grid/index-f30d1de1.js +5 -0
- package/dist/revo-grid/index.esm.js +3 -0
- package/dist/revo-grid/index.system.js +3 -0
- package/dist/revo-grid/resize-observer-00c48d78.js +4 -0
- package/dist/revo-grid/resize-observer-8af0bc0e.system.js +4 -0
- package/dist/revo-grid/revo-grid.esm.js +4 -1
- package/dist/revo-grid/revo-grid.js +3 -2
- package/dist/revo-grid/revo-grid.system.js +4 -1
- package/dist/revo-grid/revo-grid_11.entry.js +4 -1
- package/dist/revo-grid/revo-grid_11.system.entry.js +4 -1
- package/dist/revo-grid/revogr-clipboard.entry.js +4 -1
- package/dist/revo-grid/revogr-clipboard.system.entry.js +4 -1
- package/dist/revo-grid/revogr-filter-panel.entry.js +4 -1
- package/dist/revo-grid/revogr-filter-panel.system.entry.js +4 -1
- package/dist/types/components/revo-grid/revo-grid.d.ts +6 -0
- package/dist/types/components.d.ts +108 -56
- package/dist/types/plugins/dispatcher.d.ts +10 -0
- package/dist/types/plugins/moveColumn/columnDragPlugin.d.ts +66 -0
- package/dist/types/plugins/moveColumn/columnOrderHandler.d.ts +12 -0
- package/dist/types/services/resizable.directive.d.ts +1 -1
- package/dist/types/stencil-public-runtime.d.ts +189 -186
- package/loader/cdn.js +3 -1
- package/loader/index.cjs.js +3 -1
- package/loader/index.d.ts +0 -1
- package/loader/index.es2017.js +3 -1
- package/loader/index.js +3 -1
- package/package.json +22 -20
- package/dist/cjs/css-shim-e33df79c.js +0 -6
- package/dist/esm/css-shim-8d75038b.js +0 -4
- package/dist/esm-es5/css-shim-8d75038b.js +0 -1
- package/dist/esm-es5/index-42c84e7c.js +0 -1
- package/dist/esm-es5/resize-observer-56b7b34f.js +0 -1
- package/dist/revo-grid/css-shim-88bfb262.system.js +0 -1
- package/dist/revo-grid/css-shim-8d75038b.js +0 -1
- package/dist/revo-grid/index-a15e7527.system.js +0 -1
- package/dist/revo-grid/index-a7f99799.js +0 -1
- package/dist/revo-grid/resize-observer-56b7b34f.js +0 -1
- package/dist/revo-grid/resize-observer-7a7b9757.system.js +0 -1
|
@@ -0,0 +1,148 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Built by Revolist
|
|
3
|
+
*/
|
|
4
|
+
/**
|
|
5
|
+
* Plugin for column manual move
|
|
6
|
+
*/
|
|
7
|
+
import debounce from 'lodash/debounce';
|
|
8
|
+
import each from 'lodash/each';
|
|
9
|
+
import { getItemByPosition } from '../../store/dimension/dimension.helpers';
|
|
10
|
+
import BasePlugin from '../basePlugin';
|
|
11
|
+
import { ColumnOrderHandler } from './columnOrderHandler';
|
|
12
|
+
import { dispatch } from '../dispatcher';
|
|
13
|
+
const COLUMN_CLICK = 'column-click';
|
|
14
|
+
const MOVE = 'column-mouse-move';
|
|
15
|
+
const DRAG_END = 'column-drag-end';
|
|
16
|
+
const BEFORE_DRAG_END = 'before-column-drag-end';
|
|
17
|
+
// use this event subscription to drop D&D for particular columns
|
|
18
|
+
const DRAG_START = 'column-drag-start';
|
|
19
|
+
export default class ColumnPlugin extends BasePlugin {
|
|
20
|
+
constructor(revogrid, providers) {
|
|
21
|
+
super(revogrid);
|
|
22
|
+
this.revogrid = revogrid;
|
|
23
|
+
this.providers = providers;
|
|
24
|
+
this.moveFunc = debounce((e) => this.doMove(e), 5);
|
|
25
|
+
this.staticDragData = null;
|
|
26
|
+
this.dragData = null;
|
|
27
|
+
this.localSubscriptions = {};
|
|
28
|
+
this.orderUi = new ColumnOrderHandler();
|
|
29
|
+
revogrid.registerVNode([this.orderUi.render()]);
|
|
30
|
+
/** Register events */
|
|
31
|
+
this.localSubscriptions['mouseleave'] = {
|
|
32
|
+
target: document,
|
|
33
|
+
callback: (e) => this.onMouseOut(e),
|
|
34
|
+
};
|
|
35
|
+
this.localSubscriptions['mouseup'] = {
|
|
36
|
+
target: document,
|
|
37
|
+
callback: (e) => this.onMouseUp(e),
|
|
38
|
+
};
|
|
39
|
+
this.localSubscriptions['mousemove'] = {
|
|
40
|
+
target: document,
|
|
41
|
+
callback: (e) => this.move(e),
|
|
42
|
+
};
|
|
43
|
+
this.addEventListener(COLUMN_CLICK, ({ detail }) => this.dragStart(detail));
|
|
44
|
+
}
|
|
45
|
+
dragStart({ event, data }) {
|
|
46
|
+
const { defaultPrevented } = dispatch(this.revogrid, DRAG_START, data);
|
|
47
|
+
// check if allowed to drag particulat column
|
|
48
|
+
if (defaultPrevented) {
|
|
49
|
+
return;
|
|
50
|
+
}
|
|
51
|
+
this.clearOrder();
|
|
52
|
+
const { mouseleave, mouseup, mousemove } = this.localSubscriptions;
|
|
53
|
+
mouseleave.target.addEventListener('mouseleave', mouseleave.callback);
|
|
54
|
+
mouseup.target.addEventListener('mouseup', mouseup.callback);
|
|
55
|
+
const dataEl = event.target.closest('revogr-header');
|
|
56
|
+
const scrollEl = event.target.closest('revogr-viewport-scroll');
|
|
57
|
+
if (!dataEl || !scrollEl) {
|
|
58
|
+
return;
|
|
59
|
+
}
|
|
60
|
+
this.staticDragData = {
|
|
61
|
+
startPos: event.x,
|
|
62
|
+
data,
|
|
63
|
+
dataEl,
|
|
64
|
+
scrollEl,
|
|
65
|
+
gridEl: this.revogrid,
|
|
66
|
+
};
|
|
67
|
+
this.dragData = this.getData(this.staticDragData);
|
|
68
|
+
mousemove.target.addEventListener('mousemove', mousemove.callback);
|
|
69
|
+
this.orderUi.start(event, this.dragData);
|
|
70
|
+
}
|
|
71
|
+
doMove(e) {
|
|
72
|
+
if (!this.staticDragData) {
|
|
73
|
+
return;
|
|
74
|
+
}
|
|
75
|
+
const dragData = (this.dragData = this.getData(this.staticDragData));
|
|
76
|
+
if (!dragData) {
|
|
77
|
+
return;
|
|
78
|
+
}
|
|
79
|
+
const start = this.staticDragData.startPos;
|
|
80
|
+
if (Math.abs(start - e.x) > 10) {
|
|
81
|
+
const x = getLeftRelative(e.x, dragData);
|
|
82
|
+
const rgCol = getItemByPosition(dragData.cols, x);
|
|
83
|
+
this.orderUi.autoscroll(x, dragData.elRect.width);
|
|
84
|
+
this.orderUi.showHandler(rgCol.end + dragData.xOffset, dragData.gridRect.width);
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
move(e) {
|
|
88
|
+
dispatch(this.revogrid, MOVE, Object.assign({}, e));
|
|
89
|
+
// then do move
|
|
90
|
+
this.moveFunc(e);
|
|
91
|
+
}
|
|
92
|
+
onMouseOut(_) {
|
|
93
|
+
this.clearOrder();
|
|
94
|
+
}
|
|
95
|
+
onMouseUp(e) {
|
|
96
|
+
// apply new positions
|
|
97
|
+
if (this.dragData) {
|
|
98
|
+
const newItem = getItemByPosition(this.dragData.cols, getLeftRelative(e.x, this.dragData));
|
|
99
|
+
const startItem = getItemByPosition(this.dragData.cols, getLeftRelative(this.staticDragData.startPos, this.dragData));
|
|
100
|
+
// prevent position change if needed
|
|
101
|
+
const { defaultPrevented: stopDrag } = dispatch(this.revogrid, BEFORE_DRAG_END, Object.assign(Object.assign({}, this.staticDragData), { startPosition: startItem, newPosition: newItem }));
|
|
102
|
+
if (!stopDrag) {
|
|
103
|
+
const store = this.providers.column.stores[this.dragData.type].store;
|
|
104
|
+
const items = [...store.get('items')];
|
|
105
|
+
const toMove = items.splice(startItem.itemIndex, 1);
|
|
106
|
+
items.splice(newItem.itemIndex, 0, ...toMove);
|
|
107
|
+
store.set('items', items);
|
|
108
|
+
}
|
|
109
|
+
dispatch(this.revogrid, DRAG_END, this.dragData);
|
|
110
|
+
}
|
|
111
|
+
this.clearOrder();
|
|
112
|
+
}
|
|
113
|
+
clearLocalSubscriptions() {
|
|
114
|
+
each(this.localSubscriptions, ({ target, callback }, key) => target.removeEventListener(key, callback));
|
|
115
|
+
}
|
|
116
|
+
clearOrder() {
|
|
117
|
+
this.clearLocalSubscriptions();
|
|
118
|
+
this.orderUi.stop();
|
|
119
|
+
}
|
|
120
|
+
/**
|
|
121
|
+
* Clearing subscription
|
|
122
|
+
*/
|
|
123
|
+
clearSubscriptions() {
|
|
124
|
+
super.clearSubscriptions();
|
|
125
|
+
this.clearLocalSubscriptions();
|
|
126
|
+
}
|
|
127
|
+
getData({ gridEl, dataEl, scrollEl, data, }) {
|
|
128
|
+
const gridRect = gridEl.getBoundingClientRect();
|
|
129
|
+
const elRect = dataEl.getBoundingClientRect();
|
|
130
|
+
return {
|
|
131
|
+
el: dataEl,
|
|
132
|
+
elScroll: scrollEl,
|
|
133
|
+
elRect,
|
|
134
|
+
gridRect,
|
|
135
|
+
data,
|
|
136
|
+
type: data.pin || 'rgCol',
|
|
137
|
+
xOffset: elRect.left - gridRect.left,
|
|
138
|
+
rows: this.getDimension('rgRow'),
|
|
139
|
+
cols: this.getDimension('rgCol'),
|
|
140
|
+
};
|
|
141
|
+
}
|
|
142
|
+
getDimension(type) {
|
|
143
|
+
return this.providers.dimension.stores[type].getCurrentState();
|
|
144
|
+
}
|
|
145
|
+
}
|
|
146
|
+
export function getLeftRelative(absoluteX, { xOffset, gridRect }) {
|
|
147
|
+
return absoluteX - gridRect.left - xOffset;
|
|
148
|
+
}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Built by Revolist
|
|
3
|
+
*/
|
|
4
|
+
import { h } from '@stencil/core';
|
|
5
|
+
export class ColumnOrderHandler {
|
|
6
|
+
constructor() {
|
|
7
|
+
this.offset = 0;
|
|
8
|
+
}
|
|
9
|
+
renderAutoscroll(_, parent) {
|
|
10
|
+
if (!parent) {
|
|
11
|
+
return;
|
|
12
|
+
}
|
|
13
|
+
this.autoscrollEl = document.createElement('div');
|
|
14
|
+
this.autoscrollEl.classList.add('drag-auto-scroll-y');
|
|
15
|
+
parent.appendChild(this.autoscrollEl);
|
|
16
|
+
}
|
|
17
|
+
autoscroll(pos, dataContainerSize, direction = 'translateX') {
|
|
18
|
+
if (!this.autoscrollEl) {
|
|
19
|
+
return;
|
|
20
|
+
}
|
|
21
|
+
const helperOffset = 10;
|
|
22
|
+
// calculate current y position inside of the grid active holder
|
|
23
|
+
// 3 - size of element + border
|
|
24
|
+
const maxScroll = Math.min(pos + helperOffset, dataContainerSize - 3);
|
|
25
|
+
this.autoscrollEl.style.transform = `${direction}(${maxScroll}px)`;
|
|
26
|
+
this.autoscrollEl.scrollIntoView({
|
|
27
|
+
block: 'nearest',
|
|
28
|
+
inline: 'nearest',
|
|
29
|
+
});
|
|
30
|
+
}
|
|
31
|
+
start(e, { el, gridRect, elScroll }, dir = 'left') {
|
|
32
|
+
const scrollContainerRect = elScroll.getBoundingClientRect();
|
|
33
|
+
if (scrollContainerRect) {
|
|
34
|
+
this.offset = scrollContainerRect[dir] - gridRect[dir];
|
|
35
|
+
}
|
|
36
|
+
this.renderAutoscroll(e, el);
|
|
37
|
+
}
|
|
38
|
+
stop() {
|
|
39
|
+
var _a;
|
|
40
|
+
if (this.element) {
|
|
41
|
+
this.element.hidden = true;
|
|
42
|
+
}
|
|
43
|
+
(_a = this.autoscrollEl) === null || _a === void 0 ? void 0 : _a.remove();
|
|
44
|
+
this.autoscrollEl = undefined;
|
|
45
|
+
this.offset = 0;
|
|
46
|
+
}
|
|
47
|
+
showHandler(pos, size, direction = 'translateX') {
|
|
48
|
+
if (!this.element) {
|
|
49
|
+
return;
|
|
50
|
+
}
|
|
51
|
+
// do not allow overcross top of the scrollable area, header excluded
|
|
52
|
+
if (this.offset) {
|
|
53
|
+
pos = Math.max(pos, this.offset);
|
|
54
|
+
}
|
|
55
|
+
// can not be bigger then grid end
|
|
56
|
+
pos = Math.min(pos, size);
|
|
57
|
+
this.element.style.transform = `${direction}(${pos}px)`;
|
|
58
|
+
this.element.hidden = false;
|
|
59
|
+
}
|
|
60
|
+
render() {
|
|
61
|
+
return h("div", { class: "drag-position-y", hidden: true, ref: (el) => (this.element = el) });
|
|
62
|
+
}
|
|
63
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Built by Revolist
|
|
3
|
+
*/
|
|
4
|
+
/*
|
|
5
|
+
Stencil Client Patch Esm v2.17.3 | MIT Licensed | https://stenciljs.com
|
|
6
|
+
*/
|
|
7
|
+
var __assign=function(){return (__assign=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var s in t=arguments[r])Object.prototype.hasOwnProperty.call(t,s)&&(e[s]=t[s]);return e}).apply(this,arguments)},StyleNode=function(){this.start=0,this.end=0,this.previous=null,this.parent=null,this.rules=null,this.parsedCssText="",this.cssText="",this.atRule=!1,this.type=0,this.keyframesName="",this.selector="",this.parsedSelector="";};function parse(e){return parseCss(lex(e=clean(e)),e)}function clean(e){return e.replace(RX.comments,"").replace(RX.port,"")}function lex(e){var t=new StyleNode;t.start=0,t.end=e.length;for(var r=t,n=0,s=e.length;n<s;n++)if(e[n]===OPEN_BRACE){r.rules||(r.rules=[]);var o=r,a=o.rules[o.rules.length-1]||null;(r=new StyleNode).start=n+1,r.parent=o,r.previous=a,o.rules.push(r);}else e[n]===CLOSE_BRACE&&(r.end=n+1,r=r.parent||t);return t}function parseCss(e,t){var r=t.substring(e.start,e.end-1);if(e.parsedCssText=e.cssText=r.trim(),e.parent){var n=e.previous?e.previous.end:e.parent.start;r=(r=(r=_expandUnicodeEscapes(r=t.substring(n,e.start-1))).replace(RX.multipleSpaces," ")).substring(r.lastIndexOf(";")+1);var s=e.parsedSelector=e.selector=r.trim();e.atRule=0===s.indexOf(AT_START),e.atRule?0===s.indexOf(MEDIA_START)?e.type=types.MEDIA_RULE:s.match(RX.keyframesRule)&&(e.type=types.KEYFRAMES_RULE,e.keyframesName=e.selector.split(RX.multipleSpaces).pop()):0===s.indexOf(VAR_START)?e.type=types.MIXIN_RULE:e.type=types.STYLE_RULE;}var o=e.rules;if(o)for(var a=0,i=o.length,l=void 0;a<i&&(l=o[a]);a++)parseCss(l,t);return e}function _expandUnicodeEscapes(e){return e.replace(/\\([0-9a-f]{1,6})\s/gi,(function(){for(var e=arguments[1],t=6-e.length;t--;)e="0"+e;return "\\"+e}))}var types={STYLE_RULE:1,KEYFRAMES_RULE:7,MEDIA_RULE:4,MIXIN_RULE:1e3},OPEN_BRACE="{",CLOSE_BRACE="}",RX={comments:/\/\*[^*]*\*+([^/*][^*]*\*+)*\//gim,port:/@import[^;]*;/gim,customProp:/(?:^[^;\-\s}]+)?--[^;{}]*?:[^{};]*?(?:[;\n]|$)/gim,mixinProp:/(?:^[^;\-\s}]+)?--[^;{}]*?:[^{};]*?{[^}]*?}(?:[;\n]|$)?/gim,mixinApply:/@apply\s*\(?[^);]*\)?\s*(?:[;\n]|$)?/gim,varApply:/[^;:]*?:[^;]*?var\([^;]*\)(?:[;\n]|$)?/gim,keyframesRule:/^@[^\s]*keyframes/,multipleSpaces:/\s+/g},VAR_START="--",MEDIA_START="@media",AT_START="@";function findRegex(e,t,r){e.lastIndex=0;var n=t.substring(r).match(e);if(n){var s=r+n.index;return {start:s,end:s+n[0].length}}return null}var VAR_USAGE_START=/\bvar\(/,VAR_ASSIGN_START=/\B--[\w-]+\s*:/,COMMENTS=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//gim,TRAILING_LINES=/^[\t ]+\n/gm;function resolveVar(e,t,r){return e[t]?e[t]:r?executeTemplate(r,e):""}function findVarEndIndex(e,t){for(var r=0,n=t;n<e.length;n++){var s=e[n];if("("===s)r++;else if(")"===s&&--r<=0)return n+1}return n}function parseVar(e,t){var r=findRegex(VAR_USAGE_START,e,t);if(!r)return null;var n=findVarEndIndex(e,r.start),s=e.substring(r.end,n-1).split(","),o=s[0],a=s.slice(1);return {start:r.start,end:n,propName:o.trim(),fallback:a.length>0?a.join(",").trim():void 0}}function compileVar(e,t,r){var n=parseVar(e,r);if(!n)return t.push(e.substring(r,e.length)),e.length;var s=n.propName,o=null!=n.fallback?compileTemplate(n.fallback):void 0;return t.push(e.substring(r,n.start),(function(e){return resolveVar(e,s,o)})),n.end}function executeTemplate(e,t){for(var r="",n=0;n<e.length;n++){var s=e[n];r+="string"==typeof s?s:s(t);}return r}function findEndValue(e,t){for(var r=!1,n=!1,s=t;s<e.length;s++){var o=e[s];if(r)n&&'"'===o&&(r=!1),n||"'"!==o||(r=!1);else if('"'===o)r=!0,n=!0;else if("'"===o)r=!0,n=!1;else {if(";"===o)return s+1;if("}"===o)return s}}return s}function removeCustomAssigns(e){for(var t="",r=0;;){var n=findRegex(VAR_ASSIGN_START,e,r),s=n?n.start:e.length;if(t+=e.substring(r,s),!n)break;r=findEndValue(e,s);}return t}function compileTemplate(e){var t=0;e=removeCustomAssigns(e=e.replace(COMMENTS,"")).replace(TRAILING_LINES,"");for(var r=[];t<e.length;)t=compileVar(e,r,t);return r}function resolveValues(e){var t={};e.forEach((function(e){e.declarations.forEach((function(e){t[e.prop]=e.value;}));}));for(var r={},n=Object.entries(t),s=function(e){var t=!1;if(n.forEach((function(e){var n=e[0],s=executeTemplate(e[1],r);s!==r[n]&&(r[n]=s,t=!0);})),!t)return "break"},o=0;o<10;o++){if("break"===s())break}return r}function getSelectors(e,t){if(void 0===t&&(t=0),!e.rules)return [];var r=[];return e.rules.filter((function(e){return e.type===types.STYLE_RULE})).forEach((function(e){var n=getDeclarations(e.cssText);n.length>0&&e.parsedSelector.split(",").forEach((function(e){e=e.trim(),r.push({selector:e,declarations:n,specificity:computeSpecificity(),nu:t});})),t++;})),r}function computeSpecificity(e){return 1}var IMPORTANT="!important",FIND_DECLARATIONS=/(?:^|[;\s{]\s*)(--[\w-]*?)\s*:\s*(?:((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};{])+)|\{([^}]*)\}(?:(?=[;\s}])|$))/gm;function getDeclarations(e){for(var t,r=[];t=FIND_DECLARATIONS.exec(e.trim());){var n=normalizeValue(t[2]),s=n.value,o=n.important;r.push({prop:t[1].trim(),value:compileTemplate(s),important:o});}return r}function normalizeValue(e){var t=(e=e.replace(/\s+/gim," ").trim()).endsWith(IMPORTANT);return t&&(e=e.slice(0,e.length-IMPORTANT.length).trim()),{value:e,important:t}}function getActiveSelectors(e,t,r){var n=[],s=getScopesForElement(t,e);return r.forEach((function(e){return n.push(e)})),s.forEach((function(e){return n.push(e)})),sortSelectors(getSelectorsForScopes(n).filter((function(t){return matches(e,t.selector)})))}function getScopesForElement(e,t){for(var r=[];t;){var n=e.get(t);n&&r.push(n),t=t.parentElement;}return r}function getSelectorsForScopes(e){var t=[];return e.forEach((function(e){t.push.apply(t,e.selectors);})),t}function sortSelectors(e){return e.sort((function(e,t){return e.specificity===t.specificity?e.nu-t.nu:e.specificity-t.specificity})),e}function matches(e,t){return ":root"===t||"html"===t||e.matches(t)}function parseCSS(e){var t=parse(e),r=compileTemplate(e);return {original:e,template:r,selectors:getSelectors(t),usesCssVars:r.length>1}}function addGlobalStyle(e,t){if(e.some((function(e){return e.styleEl===t})))return !1;var r=parseCSS(t.textContent);return r.styleEl=t,e.push(r),!0}function updateGlobalScopes(e){var t=resolveValues(getSelectorsForScopes(e));e.forEach((function(e){e.usesCssVars&&(e.styleEl.textContent=executeTemplate(e.template,t));}));}function reScope(e,t){var r=e.template.map((function(r){return "string"==typeof r?replaceScope(r,e.scopeId,t):r})),n=e.selectors.map((function(r){return __assign(__assign({},r),{selector:replaceScope(r.selector,e.scopeId,t)})}));return __assign(__assign({},e),{template:r,selectors:n,scopeId:t})}function replaceScope(e,t,r){return e=replaceAll(e,"\\.".concat(t),".".concat(r))}function replaceAll(e,t,r){return e.replace(new RegExp(t,"g"),r)}function loadDocument(e,t){return loadDocumentStyles(e,t),loadDocumentLinks(e,t).then((function(){updateGlobalScopes(t);}))}function startWatcher(e,t){"undefined"!=typeof MutationObserver&&new MutationObserver((function(){loadDocumentStyles(e,t)&&updateGlobalScopes(t);})).observe(document.head,{childList:!0});}function loadDocumentLinks(e,t){for(var r=[],n=e.querySelectorAll('link[rel="stylesheet"][href]:not([data-no-shim])'),s=0;s<n.length;s++)r.push(addGlobalLink(e,t,n[s]));return Promise.all(r)}function loadDocumentStyles(e,t){return Array.from(e.querySelectorAll("style:not([data-styles]):not([data-no-shim])")).map((function(e){return addGlobalStyle(t,e)})).some(Boolean)}function addGlobalLink(e,t,r){var n=r.href;return fetch(n).then((function(e){return e.text()})).then((function(s){if(hasCssVariables(s)&&r.parentNode){hasRelativeUrls(s)&&(s=fixRelativeUrls(s,n));var o=e.createElement("style");o.setAttribute("data-styles",""),o.textContent=s,addGlobalStyle(t,o),r.parentNode.insertBefore(o,r),r.remove();}})).catch((function(e){console.error(e);}))}var CSS_VARIABLE_REGEXP=/[\s;{]--[-a-zA-Z0-9]+\s*:/m;function hasCssVariables(e){return e.indexOf("var(")>-1||CSS_VARIABLE_REGEXP.test(e)}var CSS_URL_REGEXP=/url[\s]*\([\s]*['"]?(?!(?:https?|data)\:|\/)([^\'\"\)]*)[\s]*['"]?\)[\s]*/gim;function hasRelativeUrls(e){return CSS_URL_REGEXP.lastIndex=0,CSS_URL_REGEXP.test(e)}function fixRelativeUrls(e,t){var r=t.replace(/[^/]*$/,"");return e.replace(CSS_URL_REGEXP,(function(e,t){var n=r+t;return e.replace(t,n)}))}var CustomStyle=function(){function e(e,t){this.win=e,this.doc=t,this.count=0,this.hostStyleMap=new WeakMap,this.hostScopeMap=new WeakMap,this.globalScopes=[],this.scopesMap=new Map,this.didInit=!1;}return e.prototype.i=function(){var e=this;return this.didInit||!this.win.requestAnimationFrame?Promise.resolve():(this.didInit=!0,new Promise((function(t){e.win.requestAnimationFrame((function(){startWatcher(e.doc,e.globalScopes),loadDocument(e.doc,e.globalScopes).then((function(){return t()}));}));})))},e.prototype.addLink=function(e){var t=this;return addGlobalLink(this.doc,this.globalScopes,e).then((function(){t.updateGlobal();}))},e.prototype.addGlobalStyle=function(e){addGlobalStyle(this.globalScopes,e)&&this.updateGlobal();},e.prototype.createHostStyle=function(e,t,r,n){if(this.hostScopeMap.has(e))throw new Error("host style already created");var s=this.registerHostTemplate(r,t,n),o=this.doc.createElement("style");return o.setAttribute("data-no-shim",""),s.usesCssVars?n?(o["s-sc"]=t="".concat(s.scopeId,"-").concat(this.count),o.textContent="/*needs update*/",this.hostStyleMap.set(e,o),this.hostScopeMap.set(e,reScope(s,t)),this.count++):(s.styleEl=o,s.usesCssVars||(o.textContent=executeTemplate(s.template,{})),this.globalScopes.push(s),this.updateGlobal(),this.hostScopeMap.set(e,s)):o.textContent=r,o},e.prototype.removeHost=function(e){var t=this.hostStyleMap.get(e);t&&t.remove(),this.hostStyleMap.delete(e),this.hostScopeMap.delete(e);},e.prototype.updateHost=function(e){var t=this.hostScopeMap.get(e);if(t&&t.usesCssVars&&t.isScoped){var r=this.hostStyleMap.get(e);if(r){var n=resolveValues(getActiveSelectors(e,this.hostScopeMap,this.globalScopes));r.textContent=executeTemplate(t.template,n);}}},e.prototype.updateGlobal=function(){updateGlobalScopes(this.globalScopes);},e.prototype.registerHostTemplate=function(e,t,r){var n=this.scopesMap.get(t);return n||((n=parseCSS(e)).scopeId=t,n.isScoped=r,this.scopesMap.set(t,n)),n},e}();!function(e){!e||e.__cssshim||e.CSS&&e.CSS.supports&&e.CSS.supports("color","var(--c)")||(e.__cssshim=new CustomStyle(e,e.document));}("undefined"!=typeof window&&window);
|
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
|
|
1
|
+
/*!
|
|
2
|
+
* Built by Revolist
|
|
3
|
+
*/
|
|
4
|
+
import { h } from './index-6f753b3c.js';
|
|
2
5
|
|
|
3
6
|
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
4
7
|
|
|
@@ -555,4 +558,4 @@ function debounce(func, wait, options) {
|
|
|
555
558
|
|
|
556
559
|
var debounce_1 = debounce;
|
|
557
560
|
|
|
558
|
-
export { AndOrButton as A, FILTER_PROP as F, TrashButton as T, _baseGetTag as _, _root as a, _freeGlobal as b, createCommonjsModule as c, isObject_1 as d, _Symbol as e, isSymbol_1 as f, isFilterBtn as g, commonjsGlobal as h, isObjectLike_1 as i,
|
|
561
|
+
export { AndOrButton as A, FILTER_PROP as F, TrashButton as T, _baseGetTag as _, _root as a, _freeGlobal as b, createCommonjsModule as c, isObject_1 as d, _Symbol as e, isSymbol_1 as f, isFilterBtn as g, commonjsGlobal as h, isObjectLike_1 as i, debounce_1 as j, FilterButton as k, toNumber_1 as t };
|
|
@@ -1,5 +1,8 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Built by Revolist
|
|
3
|
+
*/
|
|
1
4
|
/*
|
|
2
|
-
Stencil Client Patch Browser v2.
|
|
5
|
+
Stencil Client Patch Browser v2.17.3 | MIT Licensed | https://stenciljs.com
|
|
3
6
|
*/
|
|
4
7
|
(function(){
|
|
5
8
|
var aa=new Set("annotation-xml color-profile font-face font-face-src font-face-uri font-face-format font-face-name missing-glyph".split(" "));function g(a){var b=aa.has(a);a=/^[a-z][.0-9_a-z]*-[\-.0-9_a-z]*$/.test(a);return !b&&a}function l(a){var b=a.isConnected;if(void 0!==b)return b;for(;a&&!(a.__CE_isImportDocument||a instanceof Document);)a=a.parentNode||(window.ShadowRoot&&a instanceof ShadowRoot?a.host:void 0);return !(!a||!(a.__CE_isImportDocument||a instanceof Document))}
|