@progress/kendo-vue-layout 3.8.4-dev.202302221027 → 3.8.4-dev.202302231256

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.
Files changed (59) hide show
  1. package/dist/cdn/js/kendo-vue-layout.js +1 -1
  2. package/dist/es/gridlayout/GridLayout.d.ts +44 -0
  3. package/dist/es/gridlayout/GridLayout.js +125 -0
  4. package/dist/es/gridlayout/GridLayoutItem.d.ts +47 -0
  5. package/dist/es/gridlayout/GridLayoutItem.js +69 -0
  6. package/dist/es/gridlayout/interfaces/GridLayoutColumnProps.d.ts +10 -0
  7. package/dist/es/gridlayout/interfaces/GridLayoutColumnProps.js +1 -0
  8. package/dist/es/gridlayout/interfaces/GridLayoutItemProps.d.ts +39 -0
  9. package/dist/es/gridlayout/interfaces/GridLayoutItemProps.js +1 -0
  10. package/dist/es/gridlayout/interfaces/GridLayoutProps.d.ts +94 -0
  11. package/dist/es/gridlayout/interfaces/GridLayoutProps.js +1 -0
  12. package/dist/es/gridlayout/interfaces/GridLayoutRowProps.d.ts +10 -0
  13. package/dist/es/gridlayout/interfaces/GridLayoutRowProps.js +1 -0
  14. package/dist/es/main.d.ts +8 -0
  15. package/dist/es/main.js +8 -0
  16. package/dist/es/package-metadata.js +1 -1
  17. package/dist/es/stacklayout/StackLayout.d.ts +44 -0
  18. package/dist/es/stacklayout/StackLayout.js +93 -0
  19. package/dist/es/stacklayout/StackLayoutProps.d.ts +75 -0
  20. package/dist/es/stacklayout/StackLayoutProps.js +1 -0
  21. package/dist/esm/gridlayout/GridLayout.d.ts +44 -0
  22. package/dist/esm/gridlayout/GridLayout.js +125 -0
  23. package/dist/esm/gridlayout/GridLayoutItem.d.ts +47 -0
  24. package/dist/esm/gridlayout/GridLayoutItem.js +69 -0
  25. package/dist/esm/gridlayout/interfaces/GridLayoutColumnProps.d.ts +10 -0
  26. package/dist/esm/gridlayout/interfaces/GridLayoutColumnProps.js +1 -0
  27. package/dist/esm/gridlayout/interfaces/GridLayoutItemProps.d.ts +39 -0
  28. package/dist/esm/gridlayout/interfaces/GridLayoutItemProps.js +1 -0
  29. package/dist/esm/gridlayout/interfaces/GridLayoutProps.d.ts +94 -0
  30. package/dist/esm/gridlayout/interfaces/GridLayoutProps.js +1 -0
  31. package/dist/esm/gridlayout/interfaces/GridLayoutRowProps.d.ts +10 -0
  32. package/dist/esm/gridlayout/interfaces/GridLayoutRowProps.js +1 -0
  33. package/dist/esm/main.d.ts +8 -0
  34. package/dist/esm/main.js +8 -0
  35. package/dist/esm/package-metadata.js +1 -1
  36. package/dist/esm/stacklayout/StackLayout.d.ts +44 -0
  37. package/dist/esm/stacklayout/StackLayout.js +93 -0
  38. package/dist/esm/stacklayout/StackLayoutProps.d.ts +75 -0
  39. package/dist/esm/stacklayout/StackLayoutProps.js +1 -0
  40. package/dist/npm/gridlayout/GridLayout.d.ts +44 -0
  41. package/dist/npm/gridlayout/GridLayout.js +132 -0
  42. package/dist/npm/gridlayout/GridLayoutItem.d.ts +47 -0
  43. package/dist/npm/gridlayout/GridLayoutItem.js +76 -0
  44. package/dist/npm/gridlayout/interfaces/GridLayoutColumnProps.d.ts +10 -0
  45. package/dist/npm/gridlayout/interfaces/GridLayoutColumnProps.js +2 -0
  46. package/dist/npm/gridlayout/interfaces/GridLayoutItemProps.d.ts +39 -0
  47. package/dist/npm/gridlayout/interfaces/GridLayoutItemProps.js +2 -0
  48. package/dist/npm/gridlayout/interfaces/GridLayoutProps.d.ts +94 -0
  49. package/dist/npm/gridlayout/interfaces/GridLayoutProps.js +2 -0
  50. package/dist/npm/gridlayout/interfaces/GridLayoutRowProps.d.ts +10 -0
  51. package/dist/npm/gridlayout/interfaces/GridLayoutRowProps.js +2 -0
  52. package/dist/npm/main.d.ts +8 -0
  53. package/dist/npm/main.js +8 -0
  54. package/dist/npm/package-metadata.js +1 -1
  55. package/dist/npm/stacklayout/StackLayout.d.ts +44 -0
  56. package/dist/npm/stacklayout/StackLayout.js +100 -0
  57. package/dist/npm/stacklayout/StackLayoutProps.d.ts +75 -0
  58. package/dist/npm/stacklayout/StackLayoutProps.js +2 -0
  59. package/package.json +13 -13
@@ -0,0 +1,44 @@
1
+ import { DefineComponent, RecordPropsDefinition, ComponentOptions, Vue2type } from '../additionalTypes';
2
+ declare type DefaultData<V> = object | ((this: V) => {});
3
+ declare type DefaultMethods<V> = {
4
+ [key: string]: (this: V, ...args: any[]) => any;
5
+ };
6
+ import { GridLayoutProps } from './interfaces/GridLayoutProps';
7
+ /**
8
+ * @hidden
9
+ */
10
+ export interface GridLayoutData {
11
+ }
12
+ /**
13
+ * @hidden
14
+ */
15
+ export interface GridLayoutState {
16
+ v3: boolean;
17
+ }
18
+ /**
19
+ * @hidden
20
+ */
21
+ export interface GridLayoutMethods {
22
+ [key: string]: any;
23
+ }
24
+ /**
25
+ * @hidden
26
+ */
27
+ export interface GridLayoutComputed {
28
+ [key: string]: any;
29
+ }
30
+ /**
31
+ * @hidden
32
+ */
33
+ export interface GridLayoutAll extends Vue2type, GridLayoutMethods, GridLayoutState, GridLayoutData, GridLayoutComputed {
34
+ }
35
+ /**
36
+ * @hidden
37
+ */
38
+ declare let GridLayoutVue2: ComponentOptions<GridLayoutAll, DefaultData<GridLayoutData>, DefaultMethods<GridLayoutAll>, GridLayoutComputed, RecordPropsDefinition<GridLayoutProps>>;
39
+ /**
40
+ * Represents the Object which is passed to
41
+ * callback of the GridLayout component.
42
+ */
43
+ declare const GridLayout: DefineComponent<GridLayoutProps, any, GridLayoutData, GridLayoutComputed, GridLayoutMethods, {}, {}, {}, string, GridLayoutProps, GridLayoutProps, {}>;
44
+ export { GridLayout, GridLayoutVue2 };
@@ -0,0 +1,125 @@
1
+ // @ts-ignore
2
+ import * as Vue from 'vue';
3
+ var allVue = Vue;
4
+ var gh = allVue.h;
5
+ var isV3 = allVue.version && allVue.version[0] === '3';
6
+ import { validatePackage } from '@progress/kendo-licensing';
7
+ import { packageMetadata } from '../package-metadata';
8
+ import { getListeners, guid, templateRendering } from '@progress/kendo-vue-common';
9
+ import { GridLayoutItem } from './GridLayoutItem';
10
+ /**
11
+ * @hidden
12
+ */
13
+ var GridLayoutVue2 = {
14
+ name: 'KendoGridLayout',
15
+ props: {
16
+ id: String,
17
+ gap: {
18
+ type: Object
19
+ },
20
+ align: {
21
+ type: Object,
22
+ validator: function validator(value) {
23
+ return ['top', 'middle', 'bottom', 'stretch'].includes(value.vertical) && ['start', 'center', 'end', 'stretch'].includes(value.horizontal);
24
+ }
25
+ },
26
+ rows: Array,
27
+ cols: Array,
28
+ items: Array
29
+ },
30
+ created: function created() {
31
+ validatePackage(packageMetadata);
32
+ this.layoutId = guid();
33
+ },
34
+ computed: {
35
+ hAlign: function hAlign() {
36
+ return this.$props.align && this.$props.align.horizontal ? this.$props.align.horizontal : 'stretch';
37
+ },
38
+ vAlign: function vAlign() {
39
+ return this.$props.align && this.$props.align.vertical ? this.$props.align.vertical : 'stretch';
40
+ },
41
+ gridLayoutClasses: function gridLayoutClasses() {
42
+ return {
43
+ 'k-grid-layout': true,
44
+ 'k-justify-items-start': this.hAlign === 'start',
45
+ 'k-justify-items-center': this.hAlign === 'center',
46
+ 'k-justify-items-end': this.hAlign === 'end',
47
+ 'k-justify-items-stretch': this.hAlign === 'stretch',
48
+ 'k-align-items-start': this.vAlign === 'top',
49
+ 'k-align-items-center': this.vAlign === 'middle',
50
+ 'k-align-items-end': this.vAlign === 'bottom',
51
+ 'k-align-items-stretch': this.vAlign === 'stretch'
52
+ };
53
+ },
54
+ gapStyle: function gapStyle() {
55
+ return this.gap ? "".concat(typeof this.gap.rows === 'number' ? this.gap.rows + 'px' : this.gap.rows) + ' ' + "".concat(typeof this.gap.cols === 'number' ? this.gap.cols + 'px' : this.gap.cols) : undefined;
56
+ },
57
+ gridTemplateRowsStyle: function gridTemplateRowsStyle() {
58
+ return this.$props.rows && this.$props.rows.map(function (row) {
59
+ return "".concat(typeof row.height === 'number' ? row.height + 'px' : row.height);
60
+ }).join(' ');
61
+ },
62
+ gridTemplateColumnsStyle: function gridTemplateColumnsStyle() {
63
+ return this.$props.cols && this.$props.cols.map(function (col) {
64
+ return "".concat(typeof col.width === 'number' ? col.width + 'px' : col.width);
65
+ }).join(' ');
66
+ },
67
+ gridLayoutStyles: function gridLayoutStyles() {
68
+ return {
69
+ gap: this.gapStyle,
70
+ gridTemplateColumns: this.gridTemplateColumnsStyle,
71
+ gridTemplateRows: this.gridTemplateRowsStyle
72
+ };
73
+ }
74
+ },
75
+ // @ts-ignore
76
+ setup: !isV3 ? undefined : function () {
77
+ var v3 = !!isV3;
78
+ return {
79
+ v3: v3
80
+ };
81
+ },
82
+ render: function render(createElement) {
83
+ var h = gh || createElement;
84
+ var _a = this.$props,
85
+ id = _a.id,
86
+ items = _a.items;
87
+ return h("div", {
88
+ "class": this.gridLayoutClasses,
89
+ style: this.gridLayoutStyles,
90
+ id: id || this.layoutId,
91
+ attrs: this.v3 ? undefined : {
92
+ id: id || this.layoutId
93
+ }
94
+ }, [items.map(function (item) {
95
+ var contentTemplate = templateRendering.call(this, item.content, getListeners.call(this));
96
+ return (
97
+ // @ts-ignore
98
+ h(GridLayoutItem, {
99
+ content: contentTemplate,
100
+ attrs: this.v3 ? undefined : {
101
+ content: contentTemplate,
102
+ id: item.id,
103
+ col: item.col,
104
+ colSpan: item.colSpan,
105
+ row: item.row,
106
+ rowSpan: item.rowSpan
107
+ },
108
+ "class": item.class,
109
+ style: item.style,
110
+ id: item.id,
111
+ col: item.col,
112
+ colSpan: item.colSpan,
113
+ row: item.row,
114
+ rowSpan: item.rowSpan
115
+ })
116
+ );
117
+ }, this)]);
118
+ }
119
+ };
120
+ /**
121
+ * Represents the Object which is passed to
122
+ * callback of the GridLayout component.
123
+ */
124
+ var GridLayout = GridLayoutVue2;
125
+ export { GridLayout, GridLayoutVue2 };
@@ -0,0 +1,47 @@
1
+ import { DefineComponent, RecordPropsDefinition, ComponentOptions, Vue2type } from '../additionalTypes';
2
+ declare type DefaultData<V> = object | ((this: V) => {});
3
+ declare type DefaultMethods<V> = {
4
+ [key: string]: (this: V, ...args: any[]) => any;
5
+ };
6
+ import { GridLayoutItemProps } from './interfaces/GridLayoutItemProps';
7
+ /**
8
+ * Represents the Object which is passed to the [`ref`](https://vuejs.org/docs/refs-and-the-dom.html)
9
+ * callback of the GridLayoutItem component.
10
+ */
11
+ /**
12
+ * @hidden
13
+ */
14
+ export interface GridLayoutItemState {
15
+ v3: boolean;
16
+ }
17
+ /**
18
+ * @hidden
19
+ */
20
+ export interface GridLayoutItemData {
21
+ }
22
+ /**
23
+ * @hidden
24
+ */
25
+ export interface GridLayoutItemMethods {
26
+ [key: string]: any;
27
+ }
28
+ /**
29
+ * @hidden
30
+ */
31
+ export interface GridLayoutItemComputed {
32
+ [key: string]: any;
33
+ }
34
+ /**
35
+ * @hidden
36
+ */
37
+ export interface GridLayoutItemAll extends Vue2type, GridLayoutItemMethods, GridLayoutItemState, GridLayoutItemData, GridLayoutItemComputed {
38
+ }
39
+ /**
40
+ * @hidden
41
+ */
42
+ declare let GridLayoutItemVue2: ComponentOptions<GridLayoutItemAll, DefaultData<GridLayoutItemData>, DefaultMethods<GridLayoutItemAll>, GridLayoutItemComputed, RecordPropsDefinition<GridLayoutItemProps>>;
43
+ /**
44
+ * @hidden
45
+ */
46
+ declare const GridLayoutItem: DefineComponent<GridLayoutItemProps, any, GridLayoutItemData, GridLayoutItemComputed, GridLayoutItemMethods, {}, {}, {}, string, GridLayoutItemProps, GridLayoutItemProps, {}>;
47
+ export { GridLayoutItem, GridLayoutItemVue2 };
@@ -0,0 +1,69 @@
1
+ // @ts-ignore
2
+ import * as Vue from 'vue';
3
+ var allVue = Vue;
4
+ var gh = allVue.h;
5
+ var isV3 = allVue.version && allVue.version[0] === '3';
6
+ var ref = allVue.ref;
7
+ var inject = allVue.inject;
8
+ import { validatePackage } from '@progress/kendo-licensing';
9
+ import { packageMetadata } from '../package-metadata';
10
+ import { getTemplate, guid } from '@progress/kendo-vue-common';
11
+ /**
12
+ * @hidden
13
+ */
14
+ var GridLayoutItemVue2 = {
15
+ name: 'KendoGridLayoutItem',
16
+ props: {
17
+ content: [String, Function, Object],
18
+ id: String,
19
+ col: Number,
20
+ colSpan: Number,
21
+ row: Number,
22
+ rowSpan: Number
23
+ },
24
+ created: function created() {
25
+ validatePackage(packageMetadata);
26
+ this.itemId = guid();
27
+ },
28
+ // @ts-ignore
29
+ setup: !isV3 ? undefined : function () {
30
+ var v3 = !!isV3;
31
+ return {
32
+ v3: v3
33
+ };
34
+ },
35
+ computed: {
36
+ gridLayoutItemStyles: function gridLayoutItemStyles() {
37
+ var _a = this.$props,
38
+ row = _a.row,
39
+ col = _a.col,
40
+ rowSpan = _a.rowSpan,
41
+ colSpan = _a.colSpan;
42
+ return {
43
+ gridArea: "".concat(row || 'auto', " / ").concat(col || 'auto', " / ").concat(rowSpan ? 'span ' + rowSpan : 'auto', " / ").concat(colSpan ? 'span ' + colSpan : 'auto')
44
+ };
45
+ }
46
+ },
47
+ render: function render(createElement) {
48
+ var h = gh || createElement;
49
+ var _a = this.$props,
50
+ id = _a.id,
51
+ content = _a.content;
52
+ var contentToRender = getTemplate.call(this, {
53
+ h: h,
54
+ template: content
55
+ });
56
+ return h("div", {
57
+ style: this.gridLayoutItemStyles,
58
+ id: id || this.itemId,
59
+ attrs: this.v3 ? undefined : {
60
+ id: id || this.itemId
61
+ }
62
+ }, [contentToRender]);
63
+ }
64
+ };
65
+ /**
66
+ * @hidden
67
+ */
68
+ var GridLayoutItem = GridLayoutItemVue2;
69
+ export { GridLayoutItem, GridLayoutItemVue2 };
@@ -0,0 +1,10 @@
1
+ /**
2
+ * Represents the props of the [Kendo UI for Vue GridLayout column]({% slug overview_gridlayout %}).
3
+ */
4
+ export interface GridLayoutColumnProps {
5
+ /**
6
+ * Specifies the width of the GridLayout
7
+ * column ([see example]({% slug overview_gridlayout %}#toc-vue-gridlayout-demo-preview)).
8
+ */
9
+ width?: number | string;
10
+ }
@@ -0,0 +1,39 @@
1
+ /**
2
+ * Represents the props of the [Kendo UI for Vue GridLayoutItem component]({% slug overview_gridlayout %}).
3
+ */
4
+ export interface GridLayoutItemProps {
5
+ /**
6
+ * Sets additional CSS classes to the GridLayoutItem.
7
+ */
8
+ class?: string;
9
+ /**
10
+ * Sets additional CSS styles to the GridLayoutItem.
11
+ */
12
+ style?: any;
13
+ /**
14
+ * Sets the `id` property of the root GridLayoutItem element.
15
+ */
16
+ id?: string;
17
+ /**
18
+ * Defines the column line from which the element will start ([see example]({% slug items_gridlayout %}#toc-items)).
19
+ */
20
+ col?: number;
21
+ /**
22
+ * Specifies the number of columns over which the element will span ([see example]({% slug items_gridlayout %}#toc-items)).
23
+ * Defaults to `1`.
24
+ */
25
+ colSpan?: number;
26
+ /**
27
+ * Defines the row line from which the element will start ([see example]({% slug items_gridlayout %}#toc-items)).
28
+ */
29
+ row?: number;
30
+ /**
31
+ * Specifies the number of rows over which the element will span ([see example]({% slug items_gridlayout %}#toc-items)).
32
+ * Defaults to `1`.
33
+ */
34
+ rowSpan?: number;
35
+ /**
36
+ * Sets the content of the GridLayoutItem.
37
+ */
38
+ content?: any;
39
+ }
@@ -0,0 +1,94 @@
1
+ import { GridLayoutColumnProps } from './GridLayoutColumnProps';
2
+ import { GridLayoutRowProps } from './GridLayoutRowProps';
3
+ /**
4
+ * Represents the props of the [Kendo UI for Vue GridLayout component]({% slug overview_gridlayout %}).
5
+ */
6
+ export interface GridLayoutProps {
7
+ /**
8
+ * Sets additional CSS classes to the GridLayout.
9
+ */
10
+ className?: string;
11
+ /**
12
+ * Sets additional CSS styles to the GridLayout.
13
+ */
14
+ style?: any;
15
+ /**
16
+ * Sets the `id` property of the root GridLayout element.
17
+ */
18
+ id?: string;
19
+ /**
20
+ * Specifies the gaps between the elements ([see example]({% slug layout_gridlayout %}#toc-gaps)).
21
+ *
22
+ * * The possible keys are:
23
+ * * `rows`
24
+ * * `columns`
25
+ */
26
+ gap?: GridLayoutGap;
27
+ /**
28
+ * Specifies the horizontal and vertical alignment of the inner GridLayout elements (see demos
29
+ * [here]({% slug layout_gridlayout %}#toc-horizontal-align) and [here]({% slug layout_gridlayout %}#toc-vertical-align)).
30
+ *
31
+ * The possible keys are:
32
+ * * `horizontal`&mdash;Defines the possible horizontal alignment of the inner GridLayout elements.
33
+ * * `start`&mdash;Uses the start point of the container.
34
+ * * `center`&mdash;Uses the central point of the container.
35
+ * * `end`&mdash;Uses the end point of the container.
36
+ * * (Default)`stretch`&mdash;Stretches the items to fill the width of the container.
37
+ * * `vertical`&mdash; Defines the possible vertical alignment of the inner GridLayout elements.
38
+ * * `top`&mdash;Uses the top point of the container.
39
+ * * `middle`&mdash;Uses the middle point of the container.
40
+ * * `bottom`&mdash;Uses the bottom point of the container.
41
+ * * (Default)`stretch`&mdash;Stretches the items to fill the height of the container.
42
+ */
43
+ align?: GridLayoutAlign | any;
44
+ /**
45
+ * Specifies the default number of columns and their widths ([see example]({% slug layout_gridlayout %}#toc-rows-and-columns)).
46
+ */
47
+ cols?: GridLayoutColumnProps[];
48
+ /**
49
+ * Specifies the default number of rows and their height ([see example]({% slug layout_gridlayout %}#toc-rows-and-columns)).
50
+ */
51
+ rows?: GridLayoutRowProps[];
52
+ /**
53
+ * The collection of GridLayoutItems.
54
+ */
55
+ items?: GridLayoutProps[];
56
+ }
57
+ /**
58
+ * Specifies the gaps between the elements.
59
+ */
60
+ export interface GridLayoutGap {
61
+ /**
62
+ * Represents the row gap between the elements
63
+ */
64
+ rows?: number | string;
65
+ /**
66
+ * Represents the column gap between the elements
67
+ */
68
+ cols?: number | string;
69
+ }
70
+ /**
71
+ * Specifies the horizontal and vertical alignment of the inner GridLayout elements.
72
+ */
73
+ export interface GridLayoutAlign {
74
+ /**
75
+ * Defines the possible horizontal alignment of the inner GridLayout elements.
76
+ *
77
+ * The available values are:
78
+ * - `start`&mdash;Uses the start point of the container.
79
+ * - `center`&mdash;Uses the center point of the container.
80
+ * - `end`&mdash;Uses the end point of the container.
81
+ * - (Default)`stretch`&mdash;Stretches the items to fill the width of the container.
82
+ */
83
+ horizontal?: 'start' | 'center' | 'end' | 'stretch';
84
+ /**
85
+ * Defines the possible vertical alignment of the inner GridLayout elements.
86
+ *
87
+ * The available values are:
88
+ * - `top`&mdash;Uses the top point of the container.
89
+ * - `middle`&mdash;Uses the middle point of the container.
90
+ * - `bottom`&mdash;Uses the bottom point of the container.
91
+ * - (Default)`stretch`&mdash;Stretches the items to fill the height of the container.
92
+ */
93
+ vertical?: 'top' | 'middle' | 'bottom' | 'stretch';
94
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,10 @@
1
+ /**
2
+ * Represents the props of the [Kendo UI for Vue GridLayout row]({% slug overview_gridlayout %}).
3
+ */
4
+ export interface GridLayoutRowProps {
5
+ /**
6
+ * Specifies the height of the GridLayout
7
+ * row ([see example]({% slug overview_gridlayout %}#toc-vue-gridlayout-demo-preview)).
8
+ */
9
+ height?: number | string;
10
+ }
package/dist/es/main.d.ts CHANGED
@@ -61,3 +61,11 @@ export * from './bottomnavigation/BottomNavigationItemProps';
61
61
  export * from './bottomnavigation/BottomNavigationItem';
62
62
  export * from './bottomnavigation/models/events';
63
63
  export * from './expansionpanel/main';
64
+ export * from './gridlayout/GridLayout';
65
+ export * from './gridlayout/GridLayoutItem';
66
+ export * from './gridlayout/interfaces/GridLayoutProps';
67
+ export * from './gridlayout/interfaces/GridLayoutItemProps';
68
+ export * from './gridlayout/interfaces/GridLayoutRowProps';
69
+ export * from './gridlayout/interfaces/GridLayoutColumnProps';
70
+ export * from './stacklayout/StackLayout';
71
+ export * from './stacklayout/StackLayoutProps';
package/dist/es/main.js CHANGED
@@ -61,3 +61,11 @@ export * from './bottomnavigation/BottomNavigationItemProps';
61
61
  export * from './bottomnavigation/BottomNavigationItem';
62
62
  export * from './bottomnavigation/models/events';
63
63
  export * from './expansionpanel/main';
64
+ export * from './gridlayout/GridLayout';
65
+ export * from './gridlayout/GridLayoutItem';
66
+ export * from './gridlayout/interfaces/GridLayoutProps';
67
+ export * from './gridlayout/interfaces/GridLayoutItemProps';
68
+ export * from './gridlayout/interfaces/GridLayoutRowProps';
69
+ export * from './gridlayout/interfaces/GridLayoutColumnProps';
70
+ export * from './stacklayout/StackLayout';
71
+ export * from './stacklayout/StackLayoutProps';
@@ -5,7 +5,7 @@ export var packageMetadata = {
5
5
  name: '@progress/kendo-vue-layout',
6
6
  productName: 'Kendo UI for Vue',
7
7
  productCodes: ['KENDOUIVUE', 'KENDOUICOMPLETE'],
8
- publishDate: 1677060858,
8
+ publishDate: 1677156185,
9
9
  version: '',
10
10
  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'
11
11
  };
@@ -0,0 +1,44 @@
1
+ import { DefineComponent, RecordPropsDefinition, ComponentOptions, Vue2type } from '../additionalTypes';
2
+ declare type DefaultData<V> = object | ((this: V) => {});
3
+ declare type DefaultMethods<V> = {
4
+ [key: string]: (this: V, ...args: any[]) => any;
5
+ };
6
+ import { StackLayoutProps } from './StackLayoutProps';
7
+ /**
8
+ * @hidden
9
+ */
10
+ export interface StackLayoutData {
11
+ }
12
+ /**
13
+ * @hidden
14
+ */
15
+ export interface StackLayoutState {
16
+ v3: boolean;
17
+ }
18
+ /**
19
+ * @hidden
20
+ */
21
+ export interface StackLayoutMethods {
22
+ [key: string]: any;
23
+ }
24
+ /**
25
+ * @hidden
26
+ */
27
+ export interface StackLayoutComputed {
28
+ [key: string]: any;
29
+ }
30
+ /**
31
+ * @hidden
32
+ */
33
+ export interface StackLayoutAll extends Vue2type, StackLayoutMethods, StackLayoutState, StackLayoutData, StackLayoutComputed {
34
+ }
35
+ /**
36
+ * @hidden
37
+ */
38
+ declare let StackLayoutVue2: ComponentOptions<StackLayoutAll, DefaultData<StackLayoutData>, DefaultMethods<StackLayoutAll>, StackLayoutComputed, RecordPropsDefinition<StackLayoutProps>>;
39
+ /**
40
+ * Represents the [Kendo UI for Vue StackLayout component]({% slug overview_stacklayout %}).
41
+ * Arranges its inner elements horizontally, or vertically in a stack. Nesting stack layouts is supported to build more complex layouts.
42
+ */
43
+ declare const StackLayout: DefineComponent<StackLayoutProps, any, StackLayoutData, StackLayoutComputed, StackLayoutMethods, {}, {}, {}, string, StackLayoutProps, StackLayoutProps, {}>;
44
+ export { StackLayout, StackLayoutVue2 };
@@ -0,0 +1,93 @@
1
+ // @ts-ignore
2
+ import * as Vue from 'vue';
3
+ var allVue = Vue;
4
+ var gh = allVue.h;
5
+ var isV3 = allVue.version && allVue.version[0] === '3';
6
+ import { validatePackage } from '@progress/kendo-licensing';
7
+ import { packageMetadata } from '../package-metadata';
8
+ import { getDefaultSlots, guid } from '@progress/kendo-vue-common';
9
+ /**
10
+ * @hidden
11
+ */
12
+ var StackLayoutVue2 = {
13
+ name: 'KendoStackLayout',
14
+ props: {
15
+ id: String,
16
+ orientation: {
17
+ type: String,
18
+ default: 'horizontal',
19
+ validator: function validator(value) {
20
+ return ['horizontal', 'vertical'].includes(value);
21
+ }
22
+ },
23
+ gap: {
24
+ type: [String, Number]
25
+ },
26
+ align: {
27
+ type: Object,
28
+ validator: function validator(value) {
29
+ return ['top', 'middle', 'bottom', 'stretch'].includes(value.vertical) && ['start', 'center', 'end', 'stretch'].includes(value.horizontal);
30
+ }
31
+ }
32
+ },
33
+ created: function created() {
34
+ validatePackage(packageMetadata);
35
+ this.layoutId = guid();
36
+ },
37
+ computed: {
38
+ hAlign: function hAlign() {
39
+ return this.$props.align && this.$props.align.horizontal ? this.$props.align.horizontal : 'stretch';
40
+ },
41
+ vAlign: function vAlign() {
42
+ return this.$props.align && this.$props.align.vertical ? this.$props.align.vertical : 'stretch';
43
+ },
44
+ stackLayoutClasses: function stackLayoutClasses() {
45
+ var orientation = this.$props.orientation;
46
+ var isHorizontal = orientation === 'horizontal';
47
+ return {
48
+ 'k-stack-layout': true,
49
+ 'k-hstack': orientation === 'horizontal',
50
+ 'k-vstack': orientation === 'vertical',
51
+ 'k-justify-content-start': isHorizontal && this.hAlign === 'start' || !isHorizontal && this.vAlign === 'top',
52
+ 'k-justify-content-center': isHorizontal && this.hAlign === 'center' || !isHorizontal && this.vAlign === 'middle',
53
+ 'k-justify-content-end': isHorizontal && this.hAlign === 'end' || !isHorizontal && this.vAlign === 'bottom',
54
+ 'k-justify-content-stretch': isHorizontal && this.hAlign === 'stretch' || !isHorizontal && this.vAlign === 'stretch',
55
+ 'k-align-items-start': !isHorizontal && this.hAlign === 'start' || isHorizontal && this.vAlign === 'top',
56
+ 'k-align-items-center': !isHorizontal && this.hAlign === 'center' || isHorizontal && this.vAlign === 'middle',
57
+ 'k-align-items-end': !isHorizontal && this.hAlign === 'end' || isHorizontal && this.vAlign === 'bottom',
58
+ 'k-align-items-stretch': !isHorizontal && this.hAlign === 'stretch' || isHorizontal && this.vAlign === 'stretch'
59
+ };
60
+ },
61
+ stackLayoutStyles: function stackLayoutStyles() {
62
+ return {
63
+ gap: "".concat(typeof this.$props.gap === 'number' ? this.$props.gap + 'px' : this.$props.gap)
64
+ };
65
+ }
66
+ },
67
+ // @ts-ignore
68
+ setup: !isV3 ? undefined : function () {
69
+ var v3 = !!isV3;
70
+ return {
71
+ v3: v3
72
+ };
73
+ },
74
+ render: function render(createElement) {
75
+ var h = gh || createElement;
76
+ var defaultSlot = getDefaultSlots(this);
77
+ var id = this.$props.id;
78
+ return h("div", {
79
+ "class": this.stackLayoutClasses,
80
+ style: this.stackLayoutStyles,
81
+ id: id || this.layoutId,
82
+ attrs: this.v3 ? undefined : {
83
+ id: id || this.layoutId
84
+ }
85
+ }, [defaultSlot]);
86
+ }
87
+ };
88
+ /**
89
+ * Represents the [Kendo UI for Vue StackLayout component]({% slug overview_stacklayout %}).
90
+ * Arranges its inner elements horizontally, or vertically in a stack. Nesting stack layouts is supported to build more complex layouts.
91
+ */
92
+ var StackLayout = StackLayoutVue2;
93
+ export { StackLayout, StackLayoutVue2 };