@progress/kendo-vue-layout 3.7.3-dev.202211021251 → 3.7.3-dev.202211021441

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/dist/npm/main.js CHANGED
@@ -63,6 +63,8 @@ __exportStar(require("./panelbar/interfaces/PanelBarProps"), exports);
63
63
  __exportStar(require("./panelbar/interfaces/PanelBarItemProps"), exports);
64
64
  __exportStar(require("./panelbar/interfaces/RenderPanelBarItem"), exports);
65
65
  __exportStar(require("./panelbar/interfaces/PanelBarSelectEventArguments"), exports);
66
+ __exportStar(require("./tilelayout/TileLayout"), exports);
67
+ __exportStar(require("./tilelayout/interfaces/main"), exports);
66
68
  __exportStar(require("./appbar/AppBar"), exports);
67
69
  __exportStar(require("./appbar/interfaces/AppBarProps"), exports);
68
70
  __exportStar(require("./appbar/AppBarSection"), exports);
@@ -8,7 +8,7 @@ exports.packageMetadata = {
8
8
  name: '@progress/kendo-vue-layout',
9
9
  productName: 'Kendo UI for Vue',
10
10
  productCodes: ['KENDOUIVUE', 'KENDOUICOMPLETE'],
11
- publishDate: 1667392740,
11
+ publishDate: 1667399417,
12
12
  version: '',
13
13
  licensingDocsUrl: 'https://www.telerik.com/kendo-vue-ui/my-license/?utm_medium=product&utm_source=kendovue&utm_campaign=kendo-ui-vue-purchase-license-keys-warning'
14
14
  };
@@ -0,0 +1,53 @@
1
+ declare type DefaultData<V> = object | ((this: V) => {});
2
+ declare type DefaultMethods<V> = {
3
+ [key: string]: (this: V, ...args: any[]) => any;
4
+ };
5
+ import { DefineComponent, RecordPropsDefinition, ComponentOptions, Vue2type } from '../additionalTypes';
6
+ /**
7
+ * @hidden
8
+ */
9
+ export interface ResizeHandlersProps {
10
+ resizable: string | boolean;
11
+ onResize?: (e: any, args: {
12
+ end: boolean;
13
+ direction: any;
14
+ }) => void;
15
+ onPress?: (e: any) => void;
16
+ rtl: boolean;
17
+ }
18
+ /**
19
+ * @hidden
20
+ */
21
+ interface ResizeHandlersState {
22
+ }
23
+ /**
24
+ * @hidden
25
+ */
26
+ interface ResizeHandlersData {
27
+ }
28
+ /**
29
+ * @hidden
30
+ */
31
+ export interface ResizeHandlersMethods {
32
+ [key: string]: any;
33
+ }
34
+ /**
35
+ * @hidden
36
+ */
37
+ export interface ResizeHandlersComputed {
38
+ [key: string]: any;
39
+ }
40
+ /**
41
+ * @hidden
42
+ */
43
+ export interface ResizeHandlersAll extends ResizeHandlersMethods, ResizeHandlersState, ResizeHandlersData, ResizeHandlersComputed, Vue2type {
44
+ }
45
+ /**
46
+ * @hidden
47
+ */
48
+ declare const ResizeHandlersVue2: ComponentOptions<Vue2type, DefaultData<ResizeHandlersData>, DefaultMethods<ResizeHandlersAll>, ResizeHandlersComputed, RecordPropsDefinition<ResizeHandlersProps>>;
49
+ /**
50
+ * @hidden
51
+ */
52
+ declare const ResizeHandlers: DefineComponent<ResizeHandlersProps, any, ResizeHandlersData, ResizeHandlersComputed, ResizeHandlersMethods, {}, {}, {}, string, ResizeHandlersProps, ResizeHandlersProps, {}>;
53
+ export { ResizeHandlers, ResizeHandlersVue2 };
@@ -0,0 +1,86 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.ResizeHandlersVue2 = exports.ResizeHandlers = void 0;
7
+ // @ts-ignore
8
+ var Vue = require("vue");
9
+ var allVue = Vue;
10
+ var gh = allVue.h;
11
+ var isV3 = allVue.version && allVue.version[0] === '3';
12
+ /**
13
+ * @hidden
14
+ */
15
+ var ResizeHandlersVue2 = {
16
+ name: 'KendoResizeHandlers',
17
+ props: {
18
+ resizable: [String, Boolean],
19
+ rtl: Boolean
20
+ },
21
+ // @ts-ignore
22
+ setup: !isV3 ? undefined : function () {
23
+ var v3 = !!isV3;
24
+ return {
25
+ v3: v3
26
+ };
27
+ },
28
+ render: function render(createElement) {
29
+ var h = gh || createElement;
30
+ var _a = this.$props,
31
+ resizable = _a.resizable,
32
+ onPress = _a.onPress,
33
+ rtl = _a.rtl;
34
+ if (!resizable) {
35
+ return null;
36
+ }
37
+ // const Handle = (props: { onResize: any; style: {}; d: string; onPress: any }) => (
38
+ // // @ts-ignore
39
+ // <Draggable
40
+ // onPress={props.onPress}
41
+ // onDrag={(data: any) => { props.onResize(data.event, false, props.d); }}
42
+ // onRelease={(data: any) => { props.onResize(data.event, true, props.d); }}
43
+ // >
44
+ // <div className={'k-resize-handle k-cursor-' + props.d + '-resize'}
45
+ // style={{ bottom: 0, right: 0, ...props.style }} />
46
+ // </Draggable>
47
+ // );
48
+ return h("div")
49
+ // <React.Fragment>
50
+ // {resizable !== 'vertical' && (
51
+ // <Handle
52
+ // onPress={onPress}
53
+ // onResize={this.handleResize}
54
+ // d="ew"
55
+ // style={rtl ? { top: 0, width: 9, left: 0, right: '' } : { top: 0, width: 9, right: 0, left: '' }}
56
+ // />
57
+ // )}
58
+ // {resizable !== 'horizontal' && (
59
+ // <Handle onPress={onPress} onResize={this.handleResize} d="ns" style={{ left: 0, height: 9 }} />)}
60
+ // {(resizable === true) && (
61
+ // <Handle
62
+ // onPress={onPress}
63
+ // onResize={this.handleResize}
64
+ // d={rtl ? 'nesw' : 'nwse'}
65
+ // style={rtl ? { width: 9, height: 9, right: '', left: 0 } : { width: 9, height: 9, right: 0, left: '' }}
66
+ // />)}
67
+ // </React.Fragment>
68
+ ;
69
+ },
70
+
71
+ methods: {
72
+ handleResize: function handleResize(event, isEnd, direction) {
73
+ event.originalEvent.preventDefault();
74
+ this.$props.onResize(event, {
75
+ end: isEnd,
76
+ direction: direction
77
+ });
78
+ }
79
+ }
80
+ };
81
+ exports.ResizeHandlersVue2 = ResizeHandlersVue2;
82
+ /**
83
+ * @hidden
84
+ */
85
+ var ResizeHandlers = ResizeHandlersVue2;
86
+ exports.ResizeHandlers = ResizeHandlers;
@@ -0,0 +1,51 @@
1
+ declare type DefaultData<V> = object | ((this: V) => {});
2
+ declare type DefaultMethods<V> = {
3
+ [key: string]: (this: V, ...args: any[]) => any;
4
+ };
5
+ import { DefineComponent, RecordPropsDefinition, ComponentOptions, Vue2type } from '../additionalTypes';
6
+ import { TileStrictPosition, TileLayoutItem } from './interfaces/main';
7
+ /**
8
+ * @hidden
9
+ */
10
+ export interface TileProps extends TileLayoutItem {
11
+ update?: (index: number, dRow: number, dCol: number, row: number, col: number) => void;
12
+ index: number;
13
+ defaultPosition: TileStrictPosition;
14
+ ignoreDrag?: (event: any) => boolean;
15
+ }
16
+ /**
17
+ * @hidden
18
+ */
19
+ interface TileState {
20
+ }
21
+ /**
22
+ * @hidden
23
+ */
24
+ interface TileData {
25
+ }
26
+ /**
27
+ * @hidden
28
+ */
29
+ export interface TileMethods {
30
+ [key: string]: any;
31
+ }
32
+ /**
33
+ * @hidden
34
+ */
35
+ export interface TileComputed {
36
+ [key: string]: any;
37
+ }
38
+ /**
39
+ * @hidden
40
+ */
41
+ export interface TileAll extends TileMethods, TileState, TileData, TileComputed, Vue2type {
42
+ }
43
+ /**
44
+ * @hidden
45
+ */
46
+ declare const TileVue2: ComponentOptions<Vue2type, DefaultData<TileData>, DefaultMethods<TileAll>, TileComputed, RecordPropsDefinition<TileProps>>;
47
+ /**
48
+ * @hidden
49
+ */
50
+ declare const Tile: DefineComponent<TileProps, any, TileData, TileComputed, TileMethods, {}, {}, {}, string, TileProps, TileProps, {}>;
51
+ export { Tile, TileVue2 };
@@ -0,0 +1,361 @@
1
+ "use strict";
2
+
3
+ var __assign = undefined && undefined.__assign || function () {
4
+ __assign = Object.assign || function (t) {
5
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
6
+ s = arguments[i];
7
+ for (var p in s) {
8
+ if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
9
+ }
10
+ }
11
+ return t;
12
+ };
13
+ return __assign.apply(this, arguments);
14
+ };
15
+ Object.defineProperty(exports, "__esModule", {
16
+ value: true
17
+ });
18
+ exports.TileVue2 = exports.Tile = void 0;
19
+ // @ts-ignore
20
+ var Vue = require("vue");
21
+ var allVue = Vue;
22
+ var gh = allVue.h;
23
+ var isV3 = allVue.version && allVue.version[0] === '3';
24
+ var kendo_vue_common_1 = require("@progress/kendo-vue-common");
25
+ var ResizeHandlers_1 = require("./ResizeHandlers");
26
+ /**
27
+ * @hidden
28
+ */
29
+ var ANIMATION_DURATION = 200;
30
+ /**
31
+ * @hidden
32
+ */
33
+ var TileVue2 = {
34
+ name: 'KendoTile',
35
+ props: {
36
+ defaultPosition: {
37
+ type: Object,
38
+ required: true
39
+ },
40
+ index: Number,
41
+ hintStyle: Object,
42
+ hintClassName: String,
43
+ header: [String, Function, Object],
44
+ body: [String, Function, Object],
45
+ item: [String, Function, Object],
46
+ resizable: {
47
+ type: [String, Boolean],
48
+ default: true,
49
+ validator: function validator(value) {
50
+ return ['horizontal', 'vertical', true, false].includes(value);
51
+ }
52
+ },
53
+ reorderable: {
54
+ type: Boolean,
55
+ default: true
56
+ }
57
+ },
58
+ created: function created() {
59
+ // state = {
60
+ // rtl: false
61
+ // };
62
+ // oldSize = {};
63
+ // draggable: { element: HTMLElement | null } | null = null;
64
+ // dragging = false;
65
+ // resizing = false;
66
+ // element: HTMLElement | null = null;
67
+ // get dragElement() {
68
+ // return this.draggable ? this.draggable.element : undefined;
69
+ // }
70
+ // ignoreDrag: boolean = false;
71
+ // pressOffset = { x: 0, y: 0 };
72
+ // pressXY = { x: 0, y: 0 };
73
+ // currentTranslate = { x: 0, y: 0 };
74
+ // preventDataOps: any = undefined;
75
+ },
76
+ mounted: function mounted() {
77
+ // if (!this.element) {
78
+ // return;
79
+ // }
80
+ // if (getComputedStyle(this.element).direction === 'rtl') {
81
+ // this.setState({
82
+ // rtl: true
83
+ // });
84
+ // }
85
+ },
86
+ updated: function updated() {
87
+ // const dragElement = this.dragElement;
88
+ // if (!dragElement) {
89
+ // return;
90
+ // }
91
+ // const newBox = dragElement.getBoundingClientRect();
92
+ // const oldBox = this.oldSize as any;
93
+ // if (this.resizing) {
94
+ // const diffCol = newBox.width - oldBox.width;
95
+ // if (this.state.rtl) {
96
+ // const currentM: number = parseFloat(dragElement.style.marginLeft || '0');
97
+ // dragElement.style.marginLeft = (currentM - diffCol) + 'px';
98
+ // } else {
99
+ // const currentM: number = parseFloat(dragElement.style.marginRight || '0');
100
+ // dragElement.style.marginRight = (currentM + diffCol) + 'px';
101
+ // }
102
+ // this.pressXY.x += this.state.rtl ? -diffCol : diffCol;
103
+ // const diffRow = newBox.height - oldBox.height;
104
+ // const currentBot: number = parseFloat(dragElement.style!.height!.substring(12) as any);
105
+ // dragElement.style.height = `calc(100% + ${(currentBot + diffRow)}px)`;
106
+ // this.pressXY.y += diffRow;
107
+ // }
108
+ // const deltaX = oldBox.left - newBox.left;
109
+ // const deltaY = oldBox.top - newBox.top;
110
+ // if (deltaX === 0 && deltaY === 0) {
111
+ // return;
112
+ // }
113
+ // if (this.dragging) {
114
+ // if ((prevProps.defaultPosition.order !== this.$props.defaultPosition.order ||
115
+ // prevProps.defaultPosition.col !== this.$props.defaultPosition.col)) {
116
+ // this.currentTranslate.x = 0;
117
+ // this.currentTranslate.y = 0;
118
+ // dragElement.style.transform = '';
119
+ // }
120
+ // return;
121
+ // }
122
+ // if (Math.abs(deltaY) < 15 && Math.abs(deltaX) < 15) {
123
+ // // improves performance and removes random flickering
124
+ // return;
125
+ // }
126
+ // requestAnimationFrame(() => {
127
+ // const domNode = this.element;
128
+ // if (!domNode) {
129
+ // return;
130
+ // }
131
+ // domNode.style.transform = `translate(${deltaX}px, ${deltaY}px)`;
132
+ // domNode.style.transition = 'transform 0s';
133
+ // requestAnimationFrame(() => {
134
+ // domNode.style.transform = '';
135
+ // domNode.style.transition = `transform ${ANIMATION_DURATION}ms cubic-bezier(0.2, 0, 0, 1) 0s`;
136
+ // });
137
+ // });
138
+ },
139
+ // @ts-ignore
140
+ setup: !isV3 ? undefined : function () {
141
+ var v3 = !!isV3;
142
+ return {
143
+ v3: v3
144
+ };
145
+ },
146
+ render: function render(createElement) {
147
+ var _this = this;
148
+ var h = gh || createElement;
149
+ var defaultSlots = (0, kendo_vue_common_1.getDefaultSlots)(this);
150
+ if (clearTimeout && typeof clearTimeout === 'function') {
151
+ clearTimeout(this.preventDataOps);
152
+ this.preventDataOps = window.setTimeout(function () {
153
+ _this.preventDataOps = undefined;
154
+ }, 200);
155
+ }
156
+ var position = this.$props.defaultPosition;
157
+ var resizable = this.$props.resizable;
158
+ var itemStyles = __assign({
159
+ gridColumnStart: position.col,
160
+ gridColumnEnd: "span ".concat(position.colSpan),
161
+ gridRowStart: position.row,
162
+ gridRowEnd: "span ".concat(position.rowSpan),
163
+ outline: 'none',
164
+ order: position.order
165
+ }, this.$props.hintStyle);
166
+ var card = h("div", {
167
+ ref: function ref(e) {
168
+ _this.draggable = e ? {
169
+ element: e
170
+ } : null;
171
+ },
172
+ "class": (0, kendo_vue_common_1.classNames)('k-tilelayout-item k-card', {
173
+ 'k-cursor-grab': this.reorderable
174
+ }, this.$props.className),
175
+ style: __assign({
176
+ height: '100%'
177
+ }, this.$props.style)
178
+ }, [defaultSlots,
179
+ // @ts-ignore
180
+ h(ResizeHandlers_1.ResizeHandlers, {
181
+ onPress: this.handlePress,
182
+ on: this.v3 ? undefined : {
183
+ "press": this.handlePress,
184
+ "resize": this.handleResize
185
+ },
186
+ onResize: this.handleResize,
187
+ resizable: resizable,
188
+ attrs: this.v3 ? undefined : {
189
+ resizable: resizable,
190
+ rtl: this.state.rtl
191
+ },
192
+ rtl: this.state.rtl
193
+ })]);
194
+ return h("div", {
195
+ style: itemStyles,
196
+ "class": this.$props.hintClassName
197
+ }, [
198
+ // @ts-ignore function children
199
+ h(kendo_vue_common_1.Draggable, {
200
+ ref: function ref(e) {
201
+ _this.draggable = e;
202
+ },
203
+ onDrag: this.$props.reorderable ? this.handleDrag : undefined,
204
+ on: this.v3 ? undefined : {
205
+ "drag": this.$props.reorderable ? this.handleDrag : undefined,
206
+ "release": this.$props.reorderable ? this.handleRelease : undefined,
207
+ "press": this.$props.reorderable ? this.handlePress : undefined
208
+ },
209
+ onRelease: this.$props.reorderable ? this.handleRelease : undefined,
210
+ onPress: this.$props.reorderable ? this.handlePress : undefined
211
+ }, this.v3 ? function () {
212
+ return [card];
213
+ } : [card])]);
214
+ },
215
+ methods: {
216
+ handleResize: function handleResize(e, q) {
217
+ if (q.end) {
218
+ this.handleRelease();
219
+ return;
220
+ }
221
+ if (!this.element) {
222
+ return;
223
+ }
224
+ var x = e.clientX;
225
+ var y = e.clientY;
226
+ this.resizing = true;
227
+ var dX = (q.direction !== 'ns' ? x - this.pressXY.x : 0) * (this.state.rtl ? -1 : 1);
228
+ var dY = q.direction !== 'ew' ? y - this.pressXY.y : 0;
229
+ if (this.dragElement) {
230
+ if (this.state.rtl) {
231
+ this.dragElement.style.marginLeft = -dX + 'px';
232
+ } else {
233
+ this.dragElement.style.marginRight = -dX + 'px';
234
+ }
235
+ this.dragElement.style.height = "calc(100% + ".concat(dY, "px)");
236
+ }
237
+ this.element.classList.add('k-layout-item-hint', 'k-layout-item-hint-resize');
238
+ if (this.preventDataOps) {
239
+ return;
240
+ }
241
+ var col = 0;
242
+ var row = 0;
243
+ var wrapBox = this.element.getBoundingClientRect();
244
+ if (dX > wrapBox.width / this.$props.defaultPosition.colSpan / 3) {
245
+ col = 1;
246
+ }
247
+ if (dX < -wrapBox.width / this.$props.defaultPosition.colSpan / 1.25) {
248
+ col = -1;
249
+ }
250
+ // vertical
251
+ if (dY > wrapBox.height / this.$props.defaultPosition.rowSpan / 3) {
252
+ row = 1;
253
+ }
254
+ if (dY < -wrapBox.height / this.$props.defaultPosition.rowSpan / 1.25) {
255
+ row = -1;
256
+ }
257
+ if (col !== 0 || row !== 0) {
258
+ this.$props.update(this.$props.index, 0, 0, row, col);
259
+ }
260
+ },
261
+ handlePress: function handlePress(e) {
262
+ if (!this.dragElement) {
263
+ return;
264
+ }
265
+ this.ignoreDrag = false;
266
+ if (this.$props.ignoreDrag && this.$props.ignoreDrag(e.event.originalEvent)) {
267
+ this.ignoreDrag = true;
268
+ return;
269
+ }
270
+ if (this.element) {
271
+ this.element.style.zIndex = '10';
272
+ this.element.classList.add('k-layout-item-hint');
273
+ }
274
+ this.dragElement.classList.remove('k-cursor-grab');
275
+ this.dragElement.classList.add('k-cursor-grabbing');
276
+ var rec = this.dragElement.getBoundingClientRect();
277
+ this.pressXY = {
278
+ x: e.event.clientX,
279
+ y: e.event.clientY
280
+ };
281
+ this.pressOffset = {
282
+ x: e.event.clientX - rec.x,
283
+ y: e.event.clientY - rec.y
284
+ };
285
+ },
286
+ handleDrag: function handleDrag(e) {
287
+ if (this.ignoreDrag) {
288
+ return;
289
+ }
290
+ var dragElement = this.dragElement;
291
+ if (e.event.originalEvent.defaultPrevented || !dragElement) {
292
+ return;
293
+ }
294
+ this.dragging = true;
295
+ e.event.originalEvent.preventDefault();
296
+ var rec = dragElement.getBoundingClientRect();
297
+ this.currentTranslate = {
298
+ x: e.event.clientX - rec.x - this.pressOffset.x + this.currentTranslate.x,
299
+ y: e.event.clientY - rec.y - this.pressOffset.y + this.currentTranslate.y
300
+ };
301
+ dragElement.style.transform = "translate(".concat(this.currentTranslate.x, "px, ").concat(this.currentTranslate.y, "px)");
302
+ dragElement.style.transition = 'transform 0s';
303
+ if (this.preventDataOps) {
304
+ return;
305
+ }
306
+ var col = 0;
307
+ var row = 0;
308
+ if (this.currentTranslate.y > 0.7 * rec.height / this.$props.defaultPosition.rowSpan) {
309
+ row = 1;
310
+ }
311
+ if (this.currentTranslate.y < 0.7 * -rec.height / this.$props.defaultPosition.rowSpan) {
312
+ row = -1;
313
+ }
314
+ if (this.currentTranslate.x > 0.7 * rec.width / this.$props.defaultPosition.colSpan) {
315
+ col = 1;
316
+ }
317
+ if (this.currentTranslate.x < 0.7 * -rec.width / this.$props.defaultPosition.colSpan) {
318
+ col = -1;
319
+ }
320
+ this.$props.update(this.$props.index, row, this.state.rtl ? -col : col, 0, 0);
321
+ },
322
+ handleRelease: function handleRelease() {
323
+ this.dragging = this.resizing = false;
324
+ this.currentTranslate = {
325
+ x: 0,
326
+ y: 0
327
+ };
328
+ if (this.element) {
329
+ this.element.style.zIndex = '1';
330
+ this.element.classList.remove('k-layout-item-hint', 'k-layout-item-hint-resize');
331
+ }
332
+ var dragElement = this.dragElement;
333
+ if (dragElement) {
334
+ dragElement.style.transform = 'translate(0px, 0px)';
335
+ dragElement.style.transition = "transform ".concat(ANIMATION_DURATION, "ms cubic-bezier(0.2, 0, 0, 1) 0s");
336
+ dragElement.style.marginRight = '0px';
337
+ dragElement.style.marginLeft = '0px';
338
+ dragElement.style.height = '100%';
339
+ dragElement.classList.remove('k-cursor-grabbing');
340
+ dragElement.classList.add('k-cursor-grab');
341
+ }
342
+ }
343
+ }
344
+ // /**
345
+ // * @hidden
346
+ // */
347
+ // getSnapshotBeforeUpdate(_: any) {
348
+ // this.oldSize = {};
349
+ // if (this.dragElement) {
350
+ // this.oldSize = this.dragElement.getBoundingClientRect();
351
+ // }
352
+ // return null;
353
+ // }
354
+ };
355
+
356
+ exports.TileVue2 = TileVue2;
357
+ /**
358
+ * @hidden
359
+ */
360
+ var Tile = TileVue2;
361
+ exports.Tile = Tile;
@@ -0,0 +1,108 @@
1
+ declare type DefaultData<V> = object | ((this: V) => {});
2
+ declare type DefaultMethods<V> = {
3
+ [key: string]: (this: V, ...args: any[]) => any;
4
+ };
5
+ import { DefineComponent, RecordPropsDefinition, ComponentOptions, Vue2type } from '../additionalTypes';
6
+ import { TileLayoutGap, TileLayoutItem, TilePosition, TileLayoutRepositionEvent, TileStrictPosition, TileLayoutAutoFlow } from './interfaces/main';
7
+ /**
8
+ * Represents the properties of [TileLayout](% slug overview_tilelayout %) component.
9
+ */
10
+ export interface TileLayoutProps {
11
+ /**
12
+ * Sets the `id` property of the root element.
13
+ */
14
+ id?: string;
15
+ /**
16
+ * Represents the `dir` HTML attribute. This is used to switch from LTR to RTL.
17
+ */
18
+ dir?: string;
19
+ /**
20
+ * Specifies the gaps between the tiles ([see example]({% slug overview_tilelayout %}#toc-tilelayout-configuration-options)).
21
+ *
22
+ * * The possible keys are:
23
+ * * `rows`
24
+ * * `columns`
25
+ */
26
+ gap?: TileLayoutGap;
27
+ /**
28
+ * Specifies the default number of columns ([see example]({% slug overview_tilelayout %}#toc-tilelayout-configuration-options)).
29
+ */
30
+ columns?: number;
31
+ /**
32
+ * Specifies the default width of the columns ([see example]({% slug overview_tilelayout %}#toc-tilelayout-configuration-options)).
33
+ */
34
+ columnWidth?: number | string;
35
+ /**
36
+ * Specifies the default height of the rows ([see example]({% slug overview_tilelayout %}#toc-tilelayout-configuration-options)).
37
+ */
38
+ rowHeight?: number | string;
39
+ /**
40
+ * Represents the `key` field of the TileLayout item. Used for setting unique keys to the TileLayout items.
41
+ */
42
+ dataItemKey?: string;
43
+ /**
44
+ * The collection of items that will be rendered in the TileLayout
45
+ * ([see example]({% slug overview_tilelayout %}#toc-tilelayout-configuration-options)).
46
+ */
47
+ items?: TileLayoutItem[];
48
+ /**
49
+ * The list of tiles' positions which are used when the TileLayout is in controlled mode
50
+ * ([see example]({% slug tiles_tilelayout %}#toc-controlling-the-position)).
51
+ */
52
+ positions?: TilePosition[];
53
+ /**
54
+ * Fires when the user repositions the tile by either dragging or resizing
55
+ * ([see example]({% slug tiles_tilelayout %}#toc-controlling-the-position)).
56
+ */
57
+ onReposition?: (event: TileLayoutRepositionEvent) => void;
58
+ /**
59
+ * Controls how the auto-placement algorithm works, specifying exactly how auto-placed items get flowed into the TileLayout.
60
+ * For further reference, check [grid-auto-flow CSS](https://developer.mozilla.org/en-US/docs/Web/CSS/grid-auto-flow) article.
61
+ * Defaults to `column`
62
+ * ([see example]({% slug autoflows_tilelayout %})).
63
+ */
64
+ autoFlow?: TileLayoutAutoFlow | String;
65
+ /**
66
+ * Use this callback to prevent or allow dragging of the tiles based on specific dom event.
67
+ * Setting `ignoreDrag={(e) => { return !(e.target.classList.contains("k-card-title")); }}` will make only the headers draggable.
68
+ * Setting `ignoreDrag={(e) => { return e.target.nodeName == "INPUT"; }}` will ignore dragging input elements.
69
+ */
70
+ ignoreDrag?: (event: any) => boolean;
71
+ }
72
+ /**
73
+ * @hidden
74
+ */
75
+ export interface TileLayoutState {
76
+ positions: TileStrictPosition[];
77
+ }
78
+ /**
79
+ * @hidden
80
+ */
81
+ interface TileLayoutData {
82
+ }
83
+ /**
84
+ * @hidden
85
+ */
86
+ export interface TileLayoutMethods {
87
+ [key: string]: any;
88
+ }
89
+ /**
90
+ * @hidden
91
+ */
92
+ export interface TileLayoutComputed {
93
+ [key: string]: any;
94
+ }
95
+ /**
96
+ * @hidden
97
+ */
98
+ export interface TileLayoutAll extends TileLayoutMethods, TileLayoutState, TileLayoutData, TileLayoutComputed, Vue2type {
99
+ }
100
+ /**
101
+ * @hidden
102
+ */
103
+ declare const TileLayoutVue2: ComponentOptions<Vue2type, DefaultData<TileLayoutData>, DefaultMethods<TileLayoutAll>, TileLayoutComputed, RecordPropsDefinition<TileLayoutProps>>;
104
+ /**
105
+ * @hidden
106
+ */
107
+ declare const TileLayout: DefineComponent<TileLayoutProps, any, TileLayoutData, TileLayoutComputed, TileLayoutMethods, {}, {}, {}, string, TileLayoutProps, TileLayoutProps, {}>;
108
+ export { TileLayout, TileLayoutVue2 };