@schneideress/dashboardframework 0.0.152 → 0.0.154
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 +36 -42
- package/bundles/schneideress-dashboardframework.umd.js.map +1 -1
- package/bundles/schneideress-dashboardframework.umd.min.js +11 -11
- package/bundles/schneideress-dashboardframework.umd.min.js.map +1 -1
- package/esm2015/lib/ra-dashboard-area/ra.dashboard.area.js +27 -28
- package/esm5/lib/ra-dashboard-area/ra.dashboard.area.js +26 -27
- package/fesm2015/schneideress-dashboardframework.js +26 -27
- package/fesm2015/schneideress-dashboardframework.js.map +1 -1
- package/fesm5/schneideress-dashboardframework.js +25 -26
- package/fesm5/schneideress-dashboardframework.js.map +1 -1
- package/package.json +1 -1
|
@@ -5,18 +5,18 @@
|
|
|
5
5
|
}(this, (function (exports, core, rxjs, raCommon, operators, ngxUiLoader, angularNotifier, widgetframework, platformBrowser, http, common, userControls, commonControls) { 'use strict';
|
|
6
6
|
|
|
7
7
|
/*! *****************************************************************************
|
|
8
|
-
Copyright (c) Microsoft Corporation.
|
|
8
|
+
Copyright (c) Microsoft Corporation. All rights reserved.
|
|
9
|
+
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
|
|
10
|
+
this file except in compliance with the License. You may obtain a copy of the
|
|
11
|
+
License at http://www.apache.org/licenses/LICENSE-2.0
|
|
9
12
|
|
|
10
|
-
|
|
11
|
-
|
|
13
|
+
THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
14
|
+
KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
|
|
15
|
+
WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
|
|
16
|
+
MERCHANTABLITY OR NON-INFRINGEMENT.
|
|
12
17
|
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
16
|
-
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
17
|
-
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
18
|
-
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
19
|
-
PERFORMANCE OF THIS SOFTWARE.
|
|
18
|
+
See the Apache Version 2.0 License for specific language governing permissions
|
|
19
|
+
and limitations under the License.
|
|
20
20
|
***************************************************************************** */
|
|
21
21
|
/* global Reflect, Promise */
|
|
22
22
|
|
|
@@ -109,13 +109,8 @@
|
|
|
109
109
|
}
|
|
110
110
|
}
|
|
111
111
|
|
|
112
|
-
function __createBinding(o, m, k, k2) {
|
|
113
|
-
if (k2 === undefined) k2 = k;
|
|
114
|
-
o[k2] = m[k];
|
|
115
|
-
}
|
|
116
|
-
|
|
117
112
|
function __exportStar(m, exports) {
|
|
118
|
-
for (var p in m) if (
|
|
113
|
+
for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p];
|
|
119
114
|
}
|
|
120
115
|
|
|
121
116
|
function __values(o) {
|
|
@@ -1422,22 +1417,6 @@
|
|
|
1422
1417
|
* @return {?}
|
|
1423
1418
|
*/
|
|
1424
1419
|
function (widgets) {
|
|
1425
|
-
//sorting the widgets y, x
|
|
1426
|
-
widgets = widgets.sort((/**
|
|
1427
|
-
* @param {?} a
|
|
1428
|
-
* @param {?} b
|
|
1429
|
-
* @return {?}
|
|
1430
|
-
*/
|
|
1431
|
-
function (a, b) {
|
|
1432
|
-
if (a['position_y'] > b['position_y'])
|
|
1433
|
-
return 1;
|
|
1434
|
-
if (a['position_y'] < b['position_y'])
|
|
1435
|
-
return -1;
|
|
1436
|
-
if (a['position_x'] > b['position_x'])
|
|
1437
|
-
return 1;
|
|
1438
|
-
if (a['position_x'] < b['position_x'])
|
|
1439
|
-
return -1;
|
|
1440
|
-
}));
|
|
1441
1420
|
_this.userWidgets = widgets;
|
|
1442
1421
|
if (widgets && widgets.length > 0) {
|
|
1443
1422
|
_this.widgetList = _this.mapObjectListToGridsterItemList(widgets);
|
|
@@ -1516,18 +1495,29 @@
|
|
|
1516
1495
|
function (widgetInstanceId, isalertDisabled) {
|
|
1517
1496
|
if (isalertDisabled === void 0) { isalertDisabled = false; }
|
|
1518
1497
|
/** @type {?} */
|
|
1519
|
-
var
|
|
1498
|
+
var gridsterItem = this.widgetList.filter((/**
|
|
1520
1499
|
* @param {?} item
|
|
1521
1500
|
* @return {?}
|
|
1522
1501
|
*/
|
|
1523
1502
|
function (item) {
|
|
1524
1503
|
return item.widgetInfo.widgetInstanceId === widgetInstanceId;
|
|
1525
1504
|
}));
|
|
1526
|
-
if (
|
|
1527
|
-
|
|
1505
|
+
if (gridsterItem.length > 0) {
|
|
1506
|
+
/** @type {?} */
|
|
1507
|
+
var widget = this.userWidgets.filter((/**
|
|
1508
|
+
* @param {?} item
|
|
1509
|
+
* @return {?}
|
|
1510
|
+
*/
|
|
1511
|
+
function (item) {
|
|
1512
|
+
return item.widgetInstanceId === widgetInstanceId;
|
|
1513
|
+
}));
|
|
1514
|
+
if (widget.length > 0) {
|
|
1515
|
+
this.userWidgets.splice(this.userWidgets.indexOf(widget[0]), 1);
|
|
1516
|
+
}
|
|
1517
|
+
this.widgetList.splice(this.widgetList.indexOf(gridsterItem[0]), 1);
|
|
1528
1518
|
this.setAreaHeight();
|
|
1529
1519
|
if (!isalertDisabled) {
|
|
1530
|
-
this.notifier.notify('success', " " + this.translateService.translate('Common.Widgettext') + " " +
|
|
1520
|
+
this.notifier.notify('success', " " + this.translateService.translate('Common.Widgettext') + " " + gridsterItem[0].widgetInfo.widgetTitle + " " + this.translateService.translate('Common.deletedSuccesfully') + " ");
|
|
1531
1521
|
}
|
|
1532
1522
|
}
|
|
1533
1523
|
};
|
|
@@ -1575,6 +1565,7 @@
|
|
|
1575
1565
|
* @return {?}
|
|
1576
1566
|
*/
|
|
1577
1567
|
function (widget) {
|
|
1568
|
+
_this.userWidgets.push(widget);
|
|
1578
1569
|
/** @type {?} */
|
|
1579
1570
|
var gridsterItem = _this.responsiveService.getGridsterItem(widget);
|
|
1580
1571
|
_this.widgetList.push(gridsterItem);
|
|
@@ -1592,12 +1583,14 @@
|
|
|
1592
1583
|
if (widget && widget.widgetInstanceId) {
|
|
1593
1584
|
widgetInstanceId = widget.widgetInstanceId;
|
|
1594
1585
|
/**To save added widget position in db */
|
|
1595
|
-
|
|
1596
|
-
|
|
1597
|
-
|
|
1598
|
-
|
|
1599
|
-
|
|
1600
|
-
|
|
1586
|
+
if (_this.responsiveService.IsDesktopView) {
|
|
1587
|
+
setTimeout((/**
|
|
1588
|
+
* @return {?}
|
|
1589
|
+
*/
|
|
1590
|
+
function () {
|
|
1591
|
+
_this.updateWidgetPosition(widgetInstanceId);
|
|
1592
|
+
}));
|
|
1593
|
+
}
|
|
1601
1594
|
}
|
|
1602
1595
|
_this.raDashboardEventBus.publish(RAEvent.WidgetAdded, widget);
|
|
1603
1596
|
}));
|
|
@@ -1651,6 +1644,7 @@
|
|
|
1651
1644
|
function (widgets) {
|
|
1652
1645
|
}));
|
|
1653
1646
|
}
|
|
1647
|
+
this.userWidgets.push(data);
|
|
1654
1648
|
/** @type {?} */
|
|
1655
1649
|
var gridsterItem = this.responsiveService.getGridsterItem(data);
|
|
1656
1650
|
this.widgetList.push(gridsterItem);
|