@schneideress/dashboardframework 0.0.99 → 0.0.100
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/schneideress-dashboardframework.umd.js +55 -12
- package/bundles/schneideress-dashboardframework.umd.js.map +1 -1
- package/bundles/schneideress-dashboardframework.umd.min.js +1 -1
- package/bundles/schneideress-dashboardframework.umd.min.js.map +1 -1
- package/esm2015/lib/ra-dashboard-area/ra.dashboard.area.js +12 -3
- package/esm2015/lib/ra-widget-container/ra.widget.container.component.js +26 -10
- package/esm5/lib/ra-dashboard-area/ra.dashboard.area.js +24 -4
- package/esm5/lib/ra-widget-container/ra.widget.container.component.js +33 -10
- package/fesm2015/schneideress-dashboardframework.js +36 -11
- package/fesm2015/schneideress-dashboardframework.js.map +1 -1
- package/fesm5/schneideress-dashboardframework.js +55 -12
- package/fesm5/schneideress-dashboardframework.js.map +1 -1
- package/lib/ra-dashboard-area/ra.dashboard.area.d.ts +1 -0
- package/lib/ra-widget-container/ra.widget.container.component.d.ts +3 -0
- package/package.json +1 -1
- package/schneideress-dashboardframework.metadata.json +1 -1
|
@@ -698,6 +698,7 @@ var RADashboardArea = /** @class */ (function () {
|
|
|
698
698
|
this.widgetList = Array();
|
|
699
699
|
this.gridheight = 300;
|
|
700
700
|
this.isWidgetLoaded = false;
|
|
701
|
+
this.domResized = false;
|
|
701
702
|
this.widgetHeight = 3;
|
|
702
703
|
this.widgetWidth = 5;
|
|
703
704
|
}
|
|
@@ -717,6 +718,7 @@ var RADashboardArea = /** @class */ (function () {
|
|
|
717
718
|
*/
|
|
718
719
|
function () {
|
|
719
720
|
areaContext.setAreaHeight();
|
|
721
|
+
areaContext.domResized = !areaContext.domResized;
|
|
720
722
|
}), 1000);
|
|
721
723
|
};
|
|
722
724
|
/**
|
|
@@ -745,12 +747,28 @@ var RADashboardArea = /** @class */ (function () {
|
|
|
745
747
|
this.inititateEventBusSubscritions();
|
|
746
748
|
}
|
|
747
749
|
};
|
|
750
|
+
// public invokeResizeEvent() {
|
|
751
|
+
// this.widgetContainers.forEach(function(container,i){
|
|
752
|
+
// container.invokeWidgetResizedEvent();
|
|
753
|
+
// });
|
|
754
|
+
// }
|
|
748
755
|
/**To set GridsterConfig */
|
|
756
|
+
// public invokeResizeEvent() {
|
|
757
|
+
// this.widgetContainers.forEach(function(container,i){
|
|
758
|
+
// container.invokeWidgetResizedEvent();
|
|
759
|
+
// });
|
|
760
|
+
// }
|
|
749
761
|
/**
|
|
750
762
|
* To set GridsterConfig
|
|
751
763
|
* @return {?}
|
|
752
764
|
*/
|
|
753
|
-
RADashboardArea.prototype.initiateGridsterConfig =
|
|
765
|
+
RADashboardArea.prototype.initiateGridsterConfig =
|
|
766
|
+
// public invokeResizeEvent() {
|
|
767
|
+
// this.widgetContainers.forEach(function(container,i){
|
|
768
|
+
// container.invokeWidgetResizedEvent();
|
|
769
|
+
// });
|
|
770
|
+
// }
|
|
771
|
+
/**
|
|
754
772
|
* To set GridsterConfig
|
|
755
773
|
* @return {?}
|
|
756
774
|
*/
|
|
@@ -997,7 +1015,7 @@ var RADashboardArea = /** @class */ (function () {
|
|
|
997
1015
|
areaHeight = 600;
|
|
998
1016
|
}
|
|
999
1017
|
this.gridheight = areaHeight;
|
|
1000
|
-
console.log('area height
|
|
1018
|
+
console.log('area height adjusted1');
|
|
1001
1019
|
};
|
|
1002
1020
|
/** To remove a widget instance from dashboard and to save info in database */
|
|
1003
1021
|
/**
|
|
@@ -1195,7 +1213,7 @@ var RADashboardArea = /** @class */ (function () {
|
|
|
1195
1213
|
RADashboardArea.decorators = [
|
|
1196
1214
|
{ type: Component, args: [{
|
|
1197
1215
|
selector: 'ra-dashboard-area',
|
|
1198
|
-
template: "<div #gridWrapper class=\"wrap gridster\" [style.height.px]=\"gridheight\" >\r\n<!-- <div #gridWrapper class=\"wrap gridster\"> -->\r\n <gridster [options]=\"options\" style=\"height:100%;\">\r\n <gridster-item [item]=\"item\" *ngFor=\"let item of widgetList\">\r\n <ra-widget-container [app-config]=\"appConfig\" [event-bus]=\"raDashboardEventBus\" (widgetDeleted)=\"deleteWidget($event)\" [data]=\"item\"\r\n [global-filter]=\"globalFilter\" [grid-cell-height]=\"item.widgetInfo.rowHeight\" [widget-width]=\"item.cols\" [widget-height]=\"item.rows\" [widget-instance-id]=\"item.widgetInstanceId\"></ra-widget-container>\r\n </gridster-item>\r\n </gridster>\r\n <notifier-container></notifier-container>\r\n</div>\r\n\r\n",
|
|
1216
|
+
template: "<div #gridWrapper class=\"wrap gridster\" [style.height.px]=\"gridheight\" >\r\n<!-- <div #gridWrapper class=\"wrap gridster\"> -->\r\n <gridster [options]=\"options\" style=\"height:100%;\">\r\n <gridster-item [item]=\"item\" *ngFor=\"let item of widgetList\">\r\n <ra-widget-container [app-config]=\"appConfig\" [event-bus]=\"raDashboardEventBus\" (widgetDeleted)=\"deleteWidget($event)\" [data]=\"item\"\r\n [global-filter]=\"globalFilter\" [grid-cell-height]=\"item.widgetInfo.rowHeight\" [widget-width]=\"item.cols\" [widget-height]=\"item.rows\" [widget-instance-id]=\"item.widgetInstanceId\" [dom-resized]=\"domResized\"></ra-widget-container>\r\n </gridster-item>\r\n </gridster>\r\n <notifier-container></notifier-container>\r\n</div>\r\n\r\n",
|
|
1199
1217
|
styles: ["gridster{width:inherit;resize:height;display:flex;background-color:#ededed;overflow-y:hidden!important}.dvheader{width:100%;height:35px;background:#000;color:#fff;padding:7px 3px 5px 6px;text-transform:uppercase}gridster-item{box-sizing:border-box;z-index:1;position:absolute;overflow:hidden;transition:.3s;display:none;background:#fff;-webkit-user-select:text;-moz-user-select:text;-ms-user-select:text;user-select:text;box-shadow:0 1px 10px rgba(0,0,0,.05)}gridster-item:hover{box-shadow:0 1px 10px rgba(0,0,0,.15)}"]
|
|
1200
1218
|
}] }
|
|
1201
1219
|
];
|
|
@@ -1253,6 +1271,8 @@ if (false) {
|
|
|
1253
1271
|
*/
|
|
1254
1272
|
RADashboardArea.prototype.isWidgetLoaded;
|
|
1255
1273
|
/** @type {?} */
|
|
1274
|
+
RADashboardArea.prototype.domResized;
|
|
1275
|
+
/** @type {?} */
|
|
1256
1276
|
RADashboardArea.prototype.userDashboardId;
|
|
1257
1277
|
/** @type {?} */
|
|
1258
1278
|
RADashboardArea.prototype.areaKey;
|
|
@@ -1340,6 +1360,17 @@ var RAWidgetContainer = /** @class */ (function () {
|
|
|
1340
1360
|
}
|
|
1341
1361
|
}));
|
|
1342
1362
|
}
|
|
1363
|
+
Object.defineProperty(RAWidgetContainer.prototype, "setResized", {
|
|
1364
|
+
set: /**
|
|
1365
|
+
* @param {?} resized
|
|
1366
|
+
* @return {?}
|
|
1367
|
+
*/
|
|
1368
|
+
function (resized) {
|
|
1369
|
+
this.invokeWidgetResizedEvent();
|
|
1370
|
+
},
|
|
1371
|
+
enumerable: true,
|
|
1372
|
+
configurable: true
|
|
1373
|
+
});
|
|
1343
1374
|
/**
|
|
1344
1375
|
* @param {?} changes
|
|
1345
1376
|
* @return {?}
|
|
@@ -1369,14 +1400,23 @@ var RAWidgetContainer = /** @class */ (function () {
|
|
|
1369
1400
|
}
|
|
1370
1401
|
if (changes.width && changes.width.currentValue != changes.width.previousValue ||
|
|
1371
1402
|
(changes.height && changes.height.currentValue != changes.height.previousValue)) {
|
|
1372
|
-
|
|
1373
|
-
|
|
1374
|
-
|
|
1375
|
-
|
|
1376
|
-
|
|
1377
|
-
|
|
1378
|
-
|
|
1379
|
-
|
|
1403
|
+
this.invokeWidgetResizedEvent();
|
|
1404
|
+
}
|
|
1405
|
+
};
|
|
1406
|
+
/**
|
|
1407
|
+
* @return {?}
|
|
1408
|
+
*/
|
|
1409
|
+
RAWidgetContainer.prototype.invokeWidgetResizedEvent = /**
|
|
1410
|
+
* @return {?}
|
|
1411
|
+
*/
|
|
1412
|
+
function () {
|
|
1413
|
+
if (this.widgetElement) {
|
|
1414
|
+
/** @type {?} */
|
|
1415
|
+
var size = {};
|
|
1416
|
+
size.height = this.height;
|
|
1417
|
+
size.width = this.width;
|
|
1418
|
+
size.cellHeight = this.gridCellHeight;
|
|
1419
|
+
this.widgetElement.widgetResized(size);
|
|
1380
1420
|
}
|
|
1381
1421
|
};
|
|
1382
1422
|
/**
|
|
@@ -1803,7 +1843,8 @@ var RAWidgetContainer = /** @class */ (function () {
|
|
|
1803
1843
|
width: [{ type: Input, args: ['widget-width',] }],
|
|
1804
1844
|
height: [{ type: Input, args: ['widget-height',] }],
|
|
1805
1845
|
gridCellHeight: [{ type: Input, args: ['grid-cell-height',] }],
|
|
1806
|
-
widgetDeleted: [{ type: Output }]
|
|
1846
|
+
widgetDeleted: [{ type: Output }],
|
|
1847
|
+
setResized: [{ type: Input, args: ['dom-resized',] }]
|
|
1807
1848
|
};
|
|
1808
1849
|
return RAWidgetContainer;
|
|
1809
1850
|
}());
|
|
@@ -1878,6 +1919,8 @@ if (false) {
|
|
|
1878
1919
|
RAWidgetContainer.prototype.widgetDeleted;
|
|
1879
1920
|
/** @type {?} */
|
|
1880
1921
|
RAWidgetContainer.prototype.lockTitle;
|
|
1922
|
+
/** @type {?} */
|
|
1923
|
+
RAWidgetContainer.prototype.domResized;
|
|
1881
1924
|
/**
|
|
1882
1925
|
* @type {?}
|
|
1883
1926
|
* @private
|