@progress/kendo-angular-pivotgrid 0.2.0-dev.202208181233 → 0.2.0-dev.202208250747
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/bundles/kendo-angular-pivotgrid.umd.js +1 -1
- package/configurator/configurator.component.d.ts +96 -0
- package/configurator/configurator.service.d.ts +17 -0
- package/configurator/draggable.directive.d.ts +32 -0
- package/configurator/drop-cue.service.d.ts +22 -0
- package/configurator/drop-target.directive.d.ts +32 -0
- package/data-binding/base-binding-directive.d.ts +33 -5
- package/data-binding/local-binding.directive.d.ts +8 -1
- package/data-binding/olap-binding.directive.d.ts +13 -1
- package/data-binding/pivotgrid-data.service.d.ts +8 -3
- package/esm2015/configurator/configurator.component.js +500 -0
- package/esm2015/configurator/configurator.service.js +38 -0
- package/esm2015/configurator/draggable.directive.js +94 -0
- package/esm2015/configurator/drop-cue.service.js +64 -0
- package/esm2015/configurator/drop-target.directive.js +82 -0
- package/esm2015/data-binding/base-binding-directive.js +82 -9
- package/esm2015/data-binding/local-binding.directive.js +20 -8
- package/esm2015/data-binding/olap-binding.directive.js +131 -6
- package/esm2015/data-binding/pivotgrid-data.service.js +9 -1
- package/esm2015/localization/custom-messages.component.js +41 -0
- package/esm2015/localization/localized-messages.directive.js +36 -0
- package/esm2015/localization/messages.js +77 -0
- package/esm2015/main.js +8 -0
- package/esm2015/models/configuration-change-event.js +18 -0
- package/esm2015/models/configurator-settings.js +14 -0
- package/esm2015/models/data-row-item.js +6 -0
- package/esm2015/models/expanded-change-event.js +18 -0
- package/esm2015/package-metadata.js +1 -1
- package/esm2015/pivotgrid.component.js +355 -63
- package/esm2015/pivotgrid.module.js +43 -16
- package/esm2015/util.js +59 -0
- package/fesm2015/kendo-angular-pivotgrid.js +1593 -106
- package/localization/custom-messages.component.d.ts +18 -0
- package/localization/localized-messages.directive.d.ts +16 -0
- package/localization/messages.d.ts +172 -0
- package/main.d.ts +7 -0
- package/models/configuration-change-event.d.ts +36 -0
- package/models/configurator-settings.d.ts +32 -0
- package/models/data-row-item.d.ts +18 -0
- package/models/expanded-change-event.d.ts +27 -0
- package/package.json +7 -1
- package/pivotgrid.component.d.ts +27 -3
- package/pivotgrid.module.d.ts +15 -7
- package/rendering/pivotgrid-table.component.d.ts +2 -2
- package/util.d.ts +23 -0
package/esm2015/util.js
CHANGED
|
@@ -64,6 +64,54 @@ export const syncWheel = (event, tables, prop, axis) => {
|
|
|
64
64
|
tables[1][prop] += delta;
|
|
65
65
|
}
|
|
66
66
|
};
|
|
67
|
+
/**
|
|
68
|
+
* @hidden
|
|
69
|
+
*/
|
|
70
|
+
export function cloneTo(obj, result) {
|
|
71
|
+
for (let field in obj) {
|
|
72
|
+
if (obj.hasOwnProperty(field)) {
|
|
73
|
+
const value = obj[field];
|
|
74
|
+
if (Array.isArray(value)) {
|
|
75
|
+
result[field] = value.slice(0);
|
|
76
|
+
}
|
|
77
|
+
else if (value && typeof value === 'object' && !(value instanceof Date)) {
|
|
78
|
+
result[field] = result[field] || {};
|
|
79
|
+
cloneTo(value, result[field]);
|
|
80
|
+
}
|
|
81
|
+
else {
|
|
82
|
+
result[field] = value;
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
/**
|
|
88
|
+
* @hidden
|
|
89
|
+
*/
|
|
90
|
+
export function clone(obj) {
|
|
91
|
+
const result = {};
|
|
92
|
+
cloneTo(obj, result);
|
|
93
|
+
return result;
|
|
94
|
+
}
|
|
95
|
+
/**
|
|
96
|
+
* @hidden
|
|
97
|
+
*/
|
|
98
|
+
const getDocument = element => element.ownerDocument.documentElement;
|
|
99
|
+
/**
|
|
100
|
+
* @hidden
|
|
101
|
+
*/
|
|
102
|
+
const getWindow = element => element.ownerDocument.defaultView;
|
|
103
|
+
/**
|
|
104
|
+
* @hidden
|
|
105
|
+
*/
|
|
106
|
+
export const offset = element => {
|
|
107
|
+
const { clientTop, clientLeft } = getDocument(element);
|
|
108
|
+
const { pageYOffset, pageXOffset } = getWindow(element);
|
|
109
|
+
const { top, left } = element.getBoundingClientRect();
|
|
110
|
+
return {
|
|
111
|
+
top: top + pageYOffset - clientTop,
|
|
112
|
+
left: left + pageXOffset - clientLeft
|
|
113
|
+
};
|
|
114
|
+
};
|
|
67
115
|
/**
|
|
68
116
|
* @hidden
|
|
69
117
|
*/
|
|
@@ -87,6 +135,17 @@ export const matchAriaAttributes = (wrapper) => {
|
|
|
87
135
|
cell.setAttribute('aria-describedby', colHeaderCellsIds.join(' '));
|
|
88
136
|
});
|
|
89
137
|
};
|
|
138
|
+
/**
|
|
139
|
+
* @hidden
|
|
140
|
+
*/
|
|
141
|
+
export const position = (target, before) => {
|
|
142
|
+
const targetRect = offset(target);
|
|
143
|
+
const { offsetWidth, offsetHeight } = target;
|
|
144
|
+
const left = targetRect.left + (before ? 0 : offsetWidth);
|
|
145
|
+
const top = targetRect.top + offsetHeight / 2;
|
|
146
|
+
const height = offsetHeight;
|
|
147
|
+
return { left, top, height };
|
|
148
|
+
};
|
|
90
149
|
/**
|
|
91
150
|
* @hidden
|
|
92
151
|
*/
|