@get-set/gs-sortable 0.0.34 → 0.0.36
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.
|
@@ -12,14 +12,14 @@ const calculateOnSort = (ref) => {
|
|
|
12
12
|
const $items = Array.from(ref.grid.children);
|
|
13
13
|
const itemsCount = $items.filter(x => !x.classList.contains('gs-sortable-item-inmove')).length;
|
|
14
14
|
const info = (_a = window.GSSortableConfigue) === null || _a === void 0 ? void 0 : _a.draggableInfo;
|
|
15
|
-
let { containerPT
|
|
15
|
+
let { containerPT, containerPL, currentHeight, currentWidth, itemWidth, gapX, gapY, } = ref.uiData;
|
|
16
16
|
let currentLeft = containerPL;
|
|
17
17
|
let currentTop = containerPT;
|
|
18
18
|
let maxHeight = 0;
|
|
19
19
|
let placeholderSeted = info === undefined;
|
|
20
20
|
let inProcessEl;
|
|
21
|
-
const containerCoord = (0, general_1.getOffsetFromWindow)(ref.grid);
|
|
22
|
-
if (info) {
|
|
21
|
+
const containerCoord = (0, general_1.getOffsetFromWindow)(info === null || info === void 0 ? void 0 : info.ref.grid);
|
|
22
|
+
if (info !== undefined) {
|
|
23
23
|
const $el = info.$el;
|
|
24
24
|
const elCoord = (0, general_1.getOffsetFromWindow)($el);
|
|
25
25
|
inProcessEl = {
|
|
@@ -32,61 +32,57 @@ const calculateOnSort = (ref) => {
|
|
|
32
32
|
let plIndex = (_b = info === null || info === void 0 ? void 0 : info.index) !== null && _b !== void 0 ? _b : 0;
|
|
33
33
|
let colHeight = 0;
|
|
34
34
|
let itIndex = 0;
|
|
35
|
-
$items.
|
|
35
|
+
$items.map(el => {
|
|
36
36
|
if (!el.classList.contains('gs-sortable-item-inmove')) {
|
|
37
37
|
const height = el.offsetHeight;
|
|
38
38
|
const width = el.offsetWidth;
|
|
39
39
|
if (params.type === types_1.default.column) {
|
|
40
|
-
if (!placeholderSeted
|
|
41
|
-
|
|
42
|
-
|
|
40
|
+
if (!placeholderSeted) {
|
|
41
|
+
let placeholderTop = currentTop === containerPT ? containerPT : currentTop + gapY;
|
|
42
|
+
let placeholderLeft = containerPL;
|
|
43
43
|
if (Math.abs(placeholderTop - inProcessEl.top) <
|
|
44
44
|
inProcessEl.height / 2 &&
|
|
45
45
|
Math.abs(placeholderLeft - inProcessEl.left) <
|
|
46
46
|
inProcessEl.width / 2) {
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
info.newLeft = placeholderLeft;
|
|
50
|
-
}
|
|
47
|
+
info.newTop = placeholderTop;
|
|
48
|
+
info.newLeft = placeholderLeft;
|
|
51
49
|
placeholderSeted = true;
|
|
52
50
|
plIndex = itIndex;
|
|
53
51
|
}
|
|
54
52
|
}
|
|
55
53
|
if (!el.classList.contains('gs-sortable-placeholder')) {
|
|
56
54
|
if (currentTop === containerPT) {
|
|
57
|
-
currentTop
|
|
58
|
-
currentHeight
|
|
55
|
+
currentTop = containerPT + height;
|
|
56
|
+
currentHeight = currentHeight + height;
|
|
59
57
|
}
|
|
60
58
|
else {
|
|
61
|
-
currentTop
|
|
62
|
-
currentHeight
|
|
59
|
+
currentTop = currentTop + gapY + height;
|
|
60
|
+
currentHeight = currentHeight + height + gapY;
|
|
63
61
|
}
|
|
64
62
|
}
|
|
65
63
|
}
|
|
66
64
|
else if (params.type === types_1.default.row) {
|
|
67
|
-
if (!placeholderSeted
|
|
68
|
-
|
|
69
|
-
|
|
65
|
+
if (!placeholderSeted) {
|
|
66
|
+
let placeholderLeft = currentLeft === containerPL ? containerPL : currentLeft + gapX;
|
|
67
|
+
let placeholderTop = containerPT;
|
|
70
68
|
if (Math.abs(placeholderTop - inProcessEl.top) <
|
|
71
69
|
inProcessEl.height / 2 &&
|
|
72
70
|
Math.abs(placeholderLeft - inProcessEl.left) <
|
|
73
71
|
inProcessEl.width / 2) {
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
info.newLeft = placeholderLeft;
|
|
77
|
-
}
|
|
72
|
+
info.newTop = placeholderTop;
|
|
73
|
+
info.newLeft = placeholderLeft;
|
|
78
74
|
placeholderSeted = true;
|
|
79
75
|
plIndex = itIndex;
|
|
80
76
|
}
|
|
81
77
|
}
|
|
82
78
|
if (!el.classList.contains('gs-sortable-placeholder')) {
|
|
83
79
|
if (currentLeft === containerPL) {
|
|
84
|
-
currentLeft
|
|
85
|
-
currentWidth
|
|
80
|
+
currentLeft = containerPL + width;
|
|
81
|
+
currentWidth = currentWidth + width;
|
|
86
82
|
}
|
|
87
83
|
else {
|
|
88
|
-
currentLeft
|
|
89
|
-
currentWidth
|
|
84
|
+
currentLeft = currentLeft + gapX + width;
|
|
85
|
+
currentWidth = currentWidth + width + gapX;
|
|
90
86
|
}
|
|
91
87
|
if (height > maxHeight) {
|
|
92
88
|
maxHeight = height;
|
|
@@ -98,14 +94,12 @@ const calculateOnSort = (ref) => {
|
|
|
98
94
|
? containerPL
|
|
99
95
|
: containerPL + (itIndex % params.count) * (itemWidth + gapX);
|
|
100
96
|
const placeholderTop = currentTop;
|
|
101
|
-
if (inProcessEl
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
info.newLeft = placeholderLeft;
|
|
108
|
-
}
|
|
97
|
+
if (Math.abs(placeholderTop - inProcessEl.top) <
|
|
98
|
+
inProcessEl.height / 2 &&
|
|
99
|
+
Math.abs(placeholderLeft - inProcessEl.left) <
|
|
100
|
+
inProcessEl.width / 2) {
|
|
101
|
+
info.newTop = placeholderTop;
|
|
102
|
+
info.newLeft = placeholderLeft;
|
|
109
103
|
placeholderSeted = true;
|
|
110
104
|
plIndex = itIndex;
|
|
111
105
|
}
|
|
@@ -117,12 +111,12 @@ const calculateOnSort = (ref) => {
|
|
|
117
111
|
if (itIndex % params.count === params.count - 1 ||
|
|
118
112
|
itIndex === itemsCount - 1) {
|
|
119
113
|
if (top === containerPT) {
|
|
120
|
-
currentHeight
|
|
114
|
+
currentHeight = currentHeight + colHeight;
|
|
121
115
|
}
|
|
122
116
|
else {
|
|
123
|
-
currentHeight
|
|
117
|
+
currentHeight = currentHeight + colHeight + gapY;
|
|
124
118
|
}
|
|
125
|
-
currentTop
|
|
119
|
+
currentTop = currentTop + colHeight + gapY;
|
|
126
120
|
colHeight = 0;
|
|
127
121
|
}
|
|
128
122
|
}
|
|
@@ -130,9 +124,141 @@ const calculateOnSort = (ref) => {
|
|
|
130
124
|
itIndex += 1;
|
|
131
125
|
}
|
|
132
126
|
});
|
|
133
|
-
|
|
134
|
-
if (info) {
|
|
127
|
+
{
|
|
135
128
|
info.index = plIndex;
|
|
129
|
+
({
|
|
130
|
+
containerPT,
|
|
131
|
+
containerPL,
|
|
132
|
+
currentHeight,
|
|
133
|
+
currentWidth,
|
|
134
|
+
itemWidth,
|
|
135
|
+
gapX,
|
|
136
|
+
gapY,
|
|
137
|
+
} = ref.uiData);
|
|
138
|
+
currentLeft = containerPL;
|
|
139
|
+
currentTop = containerPT;
|
|
140
|
+
itIndex = 0;
|
|
141
|
+
$items.map(el => {
|
|
142
|
+
if (!el.classList.contains('gs-sortable-item-inmove')) {
|
|
143
|
+
const height = el.offsetHeight;
|
|
144
|
+
const width = el.offsetWidth;
|
|
145
|
+
if (params.type === types_1.default.column) {
|
|
146
|
+
if (itIndex === plIndex) {
|
|
147
|
+
info.placeholder.style.left = `${containerPL}px`;
|
|
148
|
+
info.newLeft = containerPL;
|
|
149
|
+
if (currentTop === containerPT) {
|
|
150
|
+
info.newTop = containerPT;
|
|
151
|
+
info.placeholder.style.top = `${containerPT}px`;
|
|
152
|
+
currentTop = containerPT + inProcessEl.height;
|
|
153
|
+
}
|
|
154
|
+
else {
|
|
155
|
+
info.newTop = currentTop + gapY;
|
|
156
|
+
info.placeholder.style.top = `${currentTop + gapY}px`;
|
|
157
|
+
currentTop = currentTop + gapY + inProcessEl.height;
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
if (!el.classList.contains('gs-sortable-placeholder')) {
|
|
161
|
+
el.style.left = `${containerPL}px`;
|
|
162
|
+
if (currentTop === containerPT) {
|
|
163
|
+
el.style.top = `${containerPT}px`;
|
|
164
|
+
currentTop = containerPT + height;
|
|
165
|
+
currentHeight = currentHeight + height;
|
|
166
|
+
}
|
|
167
|
+
else {
|
|
168
|
+
el.style.top = `${currentTop + gapY}px`;
|
|
169
|
+
currentTop = currentTop + gapY + height;
|
|
170
|
+
currentHeight = currentHeight + height + gapY;
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
else if (params.type === types_1.default.row) {
|
|
175
|
+
if (itIndex === plIndex) {
|
|
176
|
+
info.placeholder.style.top = `${containerPT}px`;
|
|
177
|
+
info.newTop = containerPT;
|
|
178
|
+
if (currentLeft === containerPL) {
|
|
179
|
+
info.newLeft = containerPL;
|
|
180
|
+
info.placeholder.style.left = `${containerPL}px`;
|
|
181
|
+
currentLeft = containerPL + inProcessEl.width;
|
|
182
|
+
}
|
|
183
|
+
else {
|
|
184
|
+
info.newLeft = currentLeft + gapX;
|
|
185
|
+
info.placeholder.style.left = `${currentLeft + gapX}px`;
|
|
186
|
+
currentLeft = currentLeft + gapX + inProcessEl.width;
|
|
187
|
+
}
|
|
188
|
+
}
|
|
189
|
+
if (!el.classList.contains('gs-sortable-placeholder')) {
|
|
190
|
+
el.style.top = `${containerPT}px`;
|
|
191
|
+
if (currentLeft === containerPL) {
|
|
192
|
+
el.style.left = `${containerPL}px`;
|
|
193
|
+
currentLeft = containerPL + width;
|
|
194
|
+
currentWidth = currentWidth + width;
|
|
195
|
+
}
|
|
196
|
+
else {
|
|
197
|
+
el.style.left = `${currentLeft + gapX}px`;
|
|
198
|
+
currentLeft = currentLeft + gapX + width;
|
|
199
|
+
currentWidth = currentWidth + width + gapX;
|
|
200
|
+
}
|
|
201
|
+
}
|
|
202
|
+
if (height > maxHeight) {
|
|
203
|
+
maxHeight = height;
|
|
204
|
+
}
|
|
205
|
+
}
|
|
206
|
+
else if (params.type === types_1.default.grid) {
|
|
207
|
+
if (itIndex === plIndex) {
|
|
208
|
+
const left = itIndex % params.count === 0
|
|
209
|
+
? containerPL
|
|
210
|
+
: containerPL +
|
|
211
|
+
(itIndex % params.count) * (itemWidth + gapX);
|
|
212
|
+
const top = currentTop;
|
|
213
|
+
if (inProcessEl.height > colHeight) {
|
|
214
|
+
colHeight = inProcessEl.height;
|
|
215
|
+
}
|
|
216
|
+
if (itIndex % params.count === params.count - 1 ||
|
|
217
|
+
itIndex === itemsCount - 1) {
|
|
218
|
+
if (top === containerPT) {
|
|
219
|
+
currentHeight = currentHeight + colHeight;
|
|
220
|
+
}
|
|
221
|
+
else {
|
|
222
|
+
currentHeight = currentHeight + colHeight + gapY;
|
|
223
|
+
}
|
|
224
|
+
currentTop = currentTop + colHeight + gapY;
|
|
225
|
+
colHeight = 0;
|
|
226
|
+
ref.grid.style.height = `${currentHeight}px`;
|
|
227
|
+
}
|
|
228
|
+
itIndex += 1;
|
|
229
|
+
info.newTop = top;
|
|
230
|
+
info.newLeft = left;
|
|
231
|
+
info.placeholder.style.left = `${left}px`;
|
|
232
|
+
info.placeholder.style.top = `${top}px`;
|
|
233
|
+
}
|
|
234
|
+
if (!el.classList.contains('gs-sortable-placeholder')) {
|
|
235
|
+
const left = itIndex % params.count === 0
|
|
236
|
+
? containerPL
|
|
237
|
+
: containerPL +
|
|
238
|
+
(itIndex % params.count) * (itemWidth + gapX);
|
|
239
|
+
const top = currentTop;
|
|
240
|
+
if (height > colHeight) {
|
|
241
|
+
colHeight = height;
|
|
242
|
+
}
|
|
243
|
+
if (itIndex % params.count === params.count - 1 ||
|
|
244
|
+
itIndex === itemsCount - 1) {
|
|
245
|
+
if (top === containerPT) {
|
|
246
|
+
currentHeight = currentHeight + colHeight;
|
|
247
|
+
}
|
|
248
|
+
else {
|
|
249
|
+
currentHeight = currentHeight + colHeight + gapY;
|
|
250
|
+
}
|
|
251
|
+
currentTop = currentTop + colHeight + gapY;
|
|
252
|
+
colHeight = 0;
|
|
253
|
+
ref.grid.style.height = `${currentHeight}px`;
|
|
254
|
+
}
|
|
255
|
+
el.style.left = `${left}px`;
|
|
256
|
+
el.style.top = `${top}px`;
|
|
257
|
+
}
|
|
258
|
+
}
|
|
259
|
+
itIndex += 1;
|
|
260
|
+
}
|
|
261
|
+
});
|
|
136
262
|
}
|
|
137
263
|
}
|
|
138
264
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"calculateOnSort.js","sourceRoot":"","sources":["../../src/actions/calculateOnSort.tsx"],"names":[],"mappings":";;;;;AACA,+DAAuC;AACvC,uCAAgD;AAEhD,MAAM,eAAe,GAAG,CAAC,GAAkB,EAAQ,EAAE;;IACnD,MAAM,MAAM,GAAG,GAAG,CAAC,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"calculateOnSort.js","sourceRoot":"","sources":["../../src/actions/calculateOnSort.tsx"],"names":[],"mappings":";;;;;AACA,+DAAuC;AACvC,uCAAgD;AAEhD,MAAM,eAAe,GAAG,CAAC,GAAkB,EAAQ,EAAE;;IACnD,MAAM,MAAM,GAAG,GAAG,CAAC,aAAa,CAAC;IACjC,IAAI,CAAC,MAAM,CAAC,SAAS,EAAE;QACrB,MAAM,MAAM,GAAG,KAAK,CAAC,IAAI,CAAC,GAAG,CAAC,IAAI,CAAC,QAAQ,CAAkB,CAAC;QAC9D,MAAM,UAAU,GAAG,MAAM,CAAC,MAAM,CAC9B,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,QAAQ,CAAC,yBAAyB,CAAC,CACtD,CAAC,MAAM,CAAC;QACT,MAAM,IAAI,GAAG,MAAA,MAAM,CAAC,kBAAkB,0CAAE,aAA8B,CAAC;QACvE,IAAI,EACF,WAAW,EACX,WAAW,EACX,aAAa,EACb,YAAY,EACZ,SAAS,EACT,IAAI,EACJ,IAAI,GACL,GAAG,GAAG,CAAC,MAAO,CAAC;QAEhB,IAAI,WAAW,GAAG,WAAW,CAAC;QAC9B,IAAI,UAAU,GAAG,WAAW,CAAC;QAC7B,IAA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