@progress/telerik-angular-report-viewer 27.25.1001 → 28.25.1119
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/README.md +1 -1
- package/dist/cjs/telerik-report-viewer.component.js +1 -1
- package/dist/cjs/telerik-report-viewer.component.js.map +1 -1
- package/dist/cjs/telerik-reporting.module.d.ts +0 -25
- package/dist/cjs/telerik-reporting.module.js +2 -27
- package/dist/cjs/telerik-reporting.module.js.map +1 -1
- package/dist/dependencies/telerikReportViewer.js +629 -365
- package/dist/dependencies/telerikReportViewerTemplate.html +3 -3
- package/dist/es/telerik-report-viewer.component.js +1 -1
- package/dist/es/telerik-report-viewer.component.js.map +1 -1
- package/dist/es/telerik-reporting.module.d.ts +0 -25
- package/dist/es/telerik-reporting.module.js +2 -27
- package/dist/es/telerik-reporting.module.js.map +1 -1
- package/package.json +9 -5
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
var $ = require("jquery");
|
|
2
2
|
/*
|
|
3
|
-
* TelerikReporting v19.
|
|
3
|
+
* TelerikReporting v19.3.25.1119 (https://www.telerik.com/products/reporting.aspx)
|
|
4
4
|
* Copyright 2025 Progress Software EAD. All rights reserved.
|
|
5
5
|
*
|
|
6
6
|
* Telerik Reporting commercial licenses may be obtained at
|
|
@@ -1378,8 +1378,8 @@ var telerikReportViewer = (function (exports) {
|
|
|
1378
1378
|
function i(e2) {
|
|
1379
1379
|
return e2 && "object" == typeof e2 && "default" in e2 ? e2 : { default: e2 };
|
|
1380
1380
|
}
|
|
1381
|
-
var n = i(t);
|
|
1382
|
-
function
|
|
1381
|
+
var n, r = i(t);
|
|
1382
|
+
function s(e2, t2, i2, n2) {
|
|
1383
1383
|
return new (i2 || (i2 = Promise))(function(r2, s2) {
|
|
1384
1384
|
function o2(e3) {
|
|
1385
1385
|
try {
|
|
@@ -1404,37 +1404,62 @@ var telerikReportViewer = (function (exports) {
|
|
|
1404
1404
|
l2((n2 = n2.apply(e2, t2 || [])).next());
|
|
1405
1405
|
});
|
|
1406
1406
|
}
|
|
1407
|
-
class
|
|
1407
|
+
class o {
|
|
1408
1408
|
constructor() {
|
|
1409
1409
|
this.BasePath = "", this.ImmediatePrint = false, this.ContentOnly = false, this.UseSVG = false, this.enableSearch = false, this.enableAccessibility = false, this.contentTabIndex = 0;
|
|
1410
1410
|
}
|
|
1411
1411
|
}
|
|
1412
|
-
class
|
|
1412
|
+
class a {
|
|
1413
1413
|
constructor() {
|
|
1414
1414
|
this.from = "", this.to = "", this.cc = "", this.subject = "", this.format = "", this.body = "";
|
|
1415
1415
|
}
|
|
1416
1416
|
}
|
|
1417
|
-
class
|
|
1417
|
+
class l {
|
|
1418
1418
|
constructor(e2, t2) {
|
|
1419
1419
|
this.cancel = false, this.element = e2, this.action = t2;
|
|
1420
1420
|
}
|
|
1421
1421
|
}
|
|
1422
|
-
class
|
|
1422
|
+
class h {
|
|
1423
1423
|
constructor(e2, t2) {
|
|
1424
1424
|
this.id = "", this.type = "", this.id = e2, this.type = t2;
|
|
1425
1425
|
}
|
|
1426
1426
|
}
|
|
1427
|
-
class
|
|
1427
|
+
class c {
|
|
1428
1428
|
constructor(e2, t2) {
|
|
1429
1429
|
this.isCancelled = false, this.format = "", this.deviceInfo = e2, this.format = t2;
|
|
1430
1430
|
}
|
|
1431
1431
|
}
|
|
1432
|
-
class
|
|
1432
|
+
class d {
|
|
1433
|
+
constructor(e2, t2) {
|
|
1434
|
+
this.handled = false, this.deviceInfo = e2, this.format = t2;
|
|
1435
|
+
}
|
|
1436
|
+
}
|
|
1437
|
+
class u {
|
|
1433
1438
|
constructor(e2, t2, i2) {
|
|
1434
1439
|
this.handled = false, this.url = e2, this.format = t2, this.windowOpenTarget = i2;
|
|
1435
1440
|
}
|
|
1436
1441
|
}
|
|
1437
|
-
class
|
|
1442
|
+
class p {
|
|
1443
|
+
constructor(e2) {
|
|
1444
|
+
this.handled = false, this.deviceInfo = e2;
|
|
1445
|
+
}
|
|
1446
|
+
}
|
|
1447
|
+
class g {
|
|
1448
|
+
constructor(e2) {
|
|
1449
|
+
this.handled = false, this.url = e2;
|
|
1450
|
+
}
|
|
1451
|
+
}
|
|
1452
|
+
class m {
|
|
1453
|
+
constructor(e2, t2) {
|
|
1454
|
+
this.page = e2, this.reportDocumentId = t2;
|
|
1455
|
+
}
|
|
1456
|
+
}
|
|
1457
|
+
class f {
|
|
1458
|
+
constructor(e2, t2, i2, n2 = null) {
|
|
1459
|
+
this.element = e2, this.text = t2, this.title = i2, this.eventArgs = n2;
|
|
1460
|
+
}
|
|
1461
|
+
}
|
|
1462
|
+
class v {
|
|
1438
1463
|
constructor(e2, t2) {
|
|
1439
1464
|
this._responseText = e2, this._error = t2;
|
|
1440
1465
|
try {
|
|
@@ -1457,14 +1482,14 @@ var telerikReportViewer = (function (exports) {
|
|
|
1457
1482
|
return (null === (e2 = this.responseJSON) || void 0 === e2 ? void 0 : e2.exceptionMessage) || (null === (t2 = this.responseJSON) || void 0 === t2 ? void 0 : t2.ExceptionMessage);
|
|
1458
1483
|
}
|
|
1459
1484
|
}
|
|
1460
|
-
function
|
|
1485
|
+
function P(e2, t2 = false, i2 = false) {
|
|
1461
1486
|
let n2 = { Accept: "application/json, text/javascript, */*; q=0.01" };
|
|
1462
1487
|
return t2 && (n2["Content-Type"] = i2 ? "application/x-www-form-urlencoded; charset=UTF-8" : "application/json; charset=UTF-8"), e2 && (n2.authorization = "Bearer " + e2), n2;
|
|
1463
1488
|
}
|
|
1464
|
-
function
|
|
1465
|
-
return
|
|
1489
|
+
function C(e2) {
|
|
1490
|
+
return s(this, void 0, void 0, function* () {
|
|
1466
1491
|
if (!e2.ok) {
|
|
1467
|
-
let t2 = yield e2.text(), i2 = new
|
|
1492
|
+
let t2 = yield e2.text(), i2 = new v(t2, e2.statusText);
|
|
1468
1493
|
return Promise.reject(i2);
|
|
1469
1494
|
}
|
|
1470
1495
|
if (204 == e2.status)
|
|
@@ -1472,23 +1497,75 @@ var telerikReportViewer = (function (exports) {
|
|
|
1472
1497
|
return (e2.headers.get("content-type") || "").includes("application/json") ? e2.json() : e2.text();
|
|
1473
1498
|
});
|
|
1474
1499
|
}
|
|
1475
|
-
function
|
|
1476
|
-
return fetch(e2, { method: "POST", headers:
|
|
1500
|
+
function y(e2, t2 = {}, i2 = "", n2 = false) {
|
|
1501
|
+
return fetch(e2, { method: "POST", headers: P(i2, true, n2), body: n2 ? t2 : JSON.stringify(t2) }).then(C);
|
|
1502
|
+
}
|
|
1503
|
+
class S {
|
|
1504
|
+
authenticatePromise() {
|
|
1505
|
+
return Promise.resolve("");
|
|
1506
|
+
}
|
|
1507
|
+
}
|
|
1508
|
+
class I {
|
|
1509
|
+
constructor(e2) {
|
|
1510
|
+
this.connectionConfig = e2;
|
|
1511
|
+
}
|
|
1512
|
+
authenticatePromise() {
|
|
1513
|
+
var e2, t2;
|
|
1514
|
+
if (this.connectionConfig && this.connectionConfig.tokenUrl && (this.connectionConfig.username || this.connectionConfig.password)) {
|
|
1515
|
+
let i2 = `grant_type=password&username=${encodeURIComponent((null === (e2 = this.connectionConfig) || void 0 === e2 ? void 0 : e2.username) || "")}&password=${encodeURIComponent((null === (t2 = this.connectionConfig) || void 0 === t2 ? void 0 : t2.password) || "")}`;
|
|
1516
|
+
return y(this.connectionConfig.tokenUrl, i2, "", true).then((e3) => (e3.expiresAt = Date.now() + 1e3 * e3.expiresIn, e3));
|
|
1517
|
+
}
|
|
1518
|
+
return Promise.reject("Failed to connect to Report Server with user credentials. Are you missing the reportServer.url, reportServer.username or reportServer.password values?");
|
|
1519
|
+
}
|
|
1520
|
+
}
|
|
1521
|
+
class b {
|
|
1522
|
+
constructor(e2) {
|
|
1523
|
+
this.connectionConfig = e2;
|
|
1524
|
+
}
|
|
1525
|
+
authenticatePromise(e2, t2) {
|
|
1526
|
+
return e2 ? y(this.connectionConfig.refreshTokenUrl, { RefreshToken: t2 }).then((e3) => (e3.expiresAt = Date.now() + 1e3 * e3.expiresIn, e3)) : this.connectionConfig && this.connectionConfig.personalTokenUrl && this.connectionConfig.getPersonalAccessToken ? this.connectionConfig.getPersonalAccessToken().then((e3) => y(this.connectionConfig.personalTokenUrl, e3).then((e4) => (e4.expiresAt = Date.now() + 1e3 * e4.expiresIn, e4))) : Promise.reject("Failed to connect to Report Server with personal access token. Are you missing the reportServer.url or reportServer.getPersonalAccessToken values?");
|
|
1527
|
+
}
|
|
1477
1528
|
}
|
|
1478
|
-
|
|
1529
|
+
e.AuthType = void 0, (n = e.AuthType || (e.AuthType = {}))[n.None = 0] = "None", n[n.Basic = 1] = "Basic", n[n.PersonalToken = 2] = "PersonalToken";
|
|
1530
|
+
class w {
|
|
1531
|
+
constructor(e2) {
|
|
1532
|
+
this.baseUrl = null == e2 ? void 0 : e2.replace(/\/$/, "");
|
|
1533
|
+
}
|
|
1479
1534
|
}
|
|
1480
|
-
|
|
1481
|
-
|
|
1535
|
+
class T extends w {
|
|
1536
|
+
constructor(t2) {
|
|
1537
|
+
super(t2), this.authType = e.AuthType.None, this.serviceUrl = this.baseUrl;
|
|
1538
|
+
}
|
|
1482
1539
|
}
|
|
1483
|
-
|
|
1484
|
-
|
|
1540
|
+
class A extends w {
|
|
1541
|
+
constructor(t2) {
|
|
1542
|
+
super(t2), this.authType = e.AuthType.None, this.serviceUrl = this.baseUrl + "/api/reports";
|
|
1543
|
+
}
|
|
1544
|
+
}
|
|
1545
|
+
class R extends A {
|
|
1546
|
+
constructor(t2, i2, n2) {
|
|
1547
|
+
super(t2), this.authType = e.AuthType.Basic, this.username = i2, this.password = n2, this.tokenUrl = this.baseUrl + "/Token";
|
|
1548
|
+
}
|
|
1549
|
+
}
|
|
1550
|
+
class E extends A {
|
|
1551
|
+
constructor(t2, i2) {
|
|
1552
|
+
super(t2), this.authType = e.AuthType.PersonalToken, this.getPersonalAccessToken = i2, this.personalTokenUrl = this.baseUrl + "/PersonalToken", this.refreshTokenUrl = this.baseUrl + "/refresh";
|
|
1553
|
+
}
|
|
1485
1554
|
}
|
|
1486
|
-
function
|
|
1555
|
+
function M() {
|
|
1556
|
+
}
|
|
1557
|
+
function x() {
|
|
1558
|
+
x.init.call(this);
|
|
1559
|
+
}
|
|
1560
|
+
function k(e2) {
|
|
1561
|
+
return void 0 === e2._maxListeners ? x.defaultMaxListeners : e2._maxListeners;
|
|
1562
|
+
}
|
|
1563
|
+
function L(e2, t2, i2, n2) {
|
|
1487
1564
|
var r2, s2, o2, a2;
|
|
1488
1565
|
if ("function" != typeof i2)
|
|
1489
1566
|
throw new TypeError('"listener" argument must be a function');
|
|
1490
|
-
if ((s2 = e2._events) ? (s2.newListener && (e2.emit("newListener", t2, i2.listener ? i2.listener : i2), s2 = e2._events), o2 = s2[t2]) : (s2 = e2._events = new
|
|
1491
|
-
if ("function" == typeof o2 ? o2 = s2[t2] = n2 ? [i2, o2] : [o2, i2] : n2 ? o2.unshift(i2) : o2.push(i2), !o2.warned && (r2 =
|
|
1567
|
+
if ((s2 = e2._events) ? (s2.newListener && (e2.emit("newListener", t2, i2.listener ? i2.listener : i2), s2 = e2._events), o2 = s2[t2]) : (s2 = e2._events = new M(), e2._eventsCount = 0), o2) {
|
|
1568
|
+
if ("function" == typeof o2 ? o2 = s2[t2] = n2 ? [i2, o2] : [o2, i2] : n2 ? o2.unshift(i2) : o2.push(i2), !o2.warned && (r2 = k(e2)) && r2 > 0 && o2.length > r2) {
|
|
1492
1569
|
o2.warned = true;
|
|
1493
1570
|
var l2 = new Error("Possible EventEmitter memory leak detected. " + o2.length + " " + t2 + " listeners added. Use emitter.setMaxListeners() to increase limit");
|
|
1494
1571
|
l2.name = "MaxListenersExceededWarning", l2.emitter = e2, l2.type = t2, l2.count = o2.length, a2 = l2, "function" == typeof console.warn ? console.warn(a2) : console.log(a2);
|
|
@@ -1497,14 +1574,14 @@ var telerikReportViewer = (function (exports) {
|
|
|
1497
1574
|
o2 = s2[t2] = i2, ++e2._eventsCount;
|
|
1498
1575
|
return e2;
|
|
1499
1576
|
}
|
|
1500
|
-
function
|
|
1577
|
+
function D(e2, t2, i2) {
|
|
1501
1578
|
var n2 = false;
|
|
1502
1579
|
function r2() {
|
|
1503
1580
|
e2.removeListener(t2, r2), n2 || (n2 = true, i2.apply(e2, arguments));
|
|
1504
1581
|
}
|
|
1505
1582
|
return r2.listener = i2, r2;
|
|
1506
1583
|
}
|
|
1507
|
-
function
|
|
1584
|
+
function N(e2) {
|
|
1508
1585
|
var t2 = this._events;
|
|
1509
1586
|
if (t2) {
|
|
1510
1587
|
var i2 = t2[e2];
|
|
@@ -1515,20 +1592,20 @@ var telerikReportViewer = (function (exports) {
|
|
|
1515
1592
|
}
|
|
1516
1593
|
return 0;
|
|
1517
1594
|
}
|
|
1518
|
-
function
|
|
1595
|
+
function F(e2, t2) {
|
|
1519
1596
|
for (var i2 = new Array(t2); t2--; )
|
|
1520
1597
|
i2[t2] = e2[t2];
|
|
1521
1598
|
return i2;
|
|
1522
1599
|
}
|
|
1523
|
-
|
|
1524
|
-
this.domain = null,
|
|
1525
|
-
},
|
|
1600
|
+
M.prototype = /* @__PURE__ */ Object.create(null), x.EventEmitter = x, x.usingDomains = false, x.prototype.domain = void 0, x.prototype._events = void 0, x.prototype._maxListeners = void 0, x.defaultMaxListeners = 10, x.init = function() {
|
|
1601
|
+
this.domain = null, x.usingDomains && (void 0).active, this._events && this._events !== Object.getPrototypeOf(this)._events || (this._events = new M(), this._eventsCount = 0), this._maxListeners = this._maxListeners || void 0;
|
|
1602
|
+
}, x.prototype.setMaxListeners = function(e2) {
|
|
1526
1603
|
if ("number" != typeof e2 || e2 < 0 || isNaN(e2))
|
|
1527
1604
|
throw new TypeError('"n" argument must be a positive number');
|
|
1528
1605
|
return this._maxListeners = e2, this;
|
|
1529
|
-
},
|
|
1530
|
-
return
|
|
1531
|
-
},
|
|
1606
|
+
}, x.prototype.getMaxListeners = function() {
|
|
1607
|
+
return k(this);
|
|
1608
|
+
}, x.prototype.emit = function(e2) {
|
|
1532
1609
|
var t2, i2, n2, r2, s2, o2, a2, l2 = "error" === e2;
|
|
1533
1610
|
if (o2 = this._events)
|
|
1534
1611
|
l2 = l2 && null == o2.error;
|
|
@@ -1552,7 +1629,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
1552
1629
|
if (t3)
|
|
1553
1630
|
e3.call(i3);
|
|
1554
1631
|
else
|
|
1555
|
-
for (var n3 = e3.length, r3 =
|
|
1632
|
+
for (var n3 = e3.length, r3 = F(e3, n3), s3 = 0; s3 < n3; ++s3)
|
|
1556
1633
|
r3[s3].call(i3);
|
|
1557
1634
|
}(i2, c2, this);
|
|
1558
1635
|
break;
|
|
@@ -1561,7 +1638,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
1561
1638
|
if (t3)
|
|
1562
1639
|
e3.call(i3, n3);
|
|
1563
1640
|
else
|
|
1564
|
-
for (var r3 = e3.length, s3 =
|
|
1641
|
+
for (var r3 = e3.length, s3 = F(e3, r3), o3 = 0; o3 < r3; ++o3)
|
|
1565
1642
|
s3[o3].call(i3, n3);
|
|
1566
1643
|
}(i2, c2, this, arguments[1]);
|
|
1567
1644
|
break;
|
|
@@ -1570,7 +1647,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
1570
1647
|
if (t3)
|
|
1571
1648
|
e3.call(i3, n3, r3);
|
|
1572
1649
|
else
|
|
1573
|
-
for (var s3 = e3.length, o3 =
|
|
1650
|
+
for (var s3 = e3.length, o3 = F(e3, s3), a3 = 0; a3 < s3; ++a3)
|
|
1574
1651
|
o3[a3].call(i3, n3, r3);
|
|
1575
1652
|
}(i2, c2, this, arguments[1], arguments[2]);
|
|
1576
1653
|
break;
|
|
@@ -1579,7 +1656,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
1579
1656
|
if (t3)
|
|
1580
1657
|
e3.call(i3, n3, r3, s3);
|
|
1581
1658
|
else
|
|
1582
|
-
for (var o3 = e3.length, a3 =
|
|
1659
|
+
for (var o3 = e3.length, a3 = F(e3, o3), l3 = 0; l3 < o3; ++l3)
|
|
1583
1660
|
a3[l3].call(i3, n3, r3, s3);
|
|
1584
1661
|
}(i2, c2, this, arguments[1], arguments[2], arguments[3]);
|
|
1585
1662
|
break;
|
|
@@ -1590,24 +1667,24 @@ var telerikReportViewer = (function (exports) {
|
|
|
1590
1667
|
if (t3)
|
|
1591
1668
|
e3.apply(i3, n3);
|
|
1592
1669
|
else
|
|
1593
|
-
for (var r3 = e3.length, s3 =
|
|
1670
|
+
for (var r3 = e3.length, s3 = F(e3, r3), o3 = 0; o3 < r3; ++o3)
|
|
1594
1671
|
s3[o3].apply(i3, n3);
|
|
1595
1672
|
}(i2, c2, this, r2);
|
|
1596
1673
|
}
|
|
1597
1674
|
return true;
|
|
1598
|
-
},
|
|
1599
|
-
return
|
|
1600
|
-
},
|
|
1601
|
-
return
|
|
1602
|
-
},
|
|
1675
|
+
}, x.prototype.addListener = function(e2, t2) {
|
|
1676
|
+
return L(this, e2, t2, false);
|
|
1677
|
+
}, x.prototype.on = x.prototype.addListener, x.prototype.prependListener = function(e2, t2) {
|
|
1678
|
+
return L(this, e2, t2, true);
|
|
1679
|
+
}, x.prototype.once = function(e2, t2) {
|
|
1603
1680
|
if ("function" != typeof t2)
|
|
1604
1681
|
throw new TypeError('"listener" argument must be a function');
|
|
1605
|
-
return this.on(e2,
|
|
1606
|
-
},
|
|
1682
|
+
return this.on(e2, D(this, e2, t2)), this;
|
|
1683
|
+
}, x.prototype.prependOnceListener = function(e2, t2) {
|
|
1607
1684
|
if ("function" != typeof t2)
|
|
1608
1685
|
throw new TypeError('"listener" argument must be a function');
|
|
1609
|
-
return this.prependListener(e2,
|
|
1610
|
-
},
|
|
1686
|
+
return this.prependListener(e2, D(this, e2, t2)), this;
|
|
1687
|
+
}, x.prototype.removeListener = function(e2, t2) {
|
|
1611
1688
|
var i2, n2, r2, s2, o2;
|
|
1612
1689
|
if ("function" != typeof t2)
|
|
1613
1690
|
throw new TypeError('"listener" argument must be a function');
|
|
@@ -1616,7 +1693,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
1616
1693
|
if (!(i2 = n2[e2]))
|
|
1617
1694
|
return this;
|
|
1618
1695
|
if (i2 === t2 || i2.listener && i2.listener === t2)
|
|
1619
|
-
0 == --this._eventsCount ? this._events = new
|
|
1696
|
+
0 == --this._eventsCount ? this._events = new M() : (delete n2[e2], n2.removeListener && this.emit("removeListener", e2, i2.listener || t2));
|
|
1620
1697
|
else if ("function" != typeof i2) {
|
|
1621
1698
|
for (r2 = -1, s2 = i2.length; s2-- > 0; )
|
|
1622
1699
|
if (i2[s2] === t2 || i2[s2].listener && i2[s2].listener === t2) {
|
|
@@ -1627,7 +1704,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
1627
1704
|
return this;
|
|
1628
1705
|
if (1 === i2.length) {
|
|
1629
1706
|
if (i2[0] = void 0, 0 == --this._eventsCount)
|
|
1630
|
-
return this._events = new
|
|
1707
|
+
return this._events = new M(), this;
|
|
1631
1708
|
delete n2[e2];
|
|
1632
1709
|
} else
|
|
1633
1710
|
!function(e3, t3) {
|
|
@@ -1638,18 +1715,18 @@ var telerikReportViewer = (function (exports) {
|
|
|
1638
1715
|
n2.removeListener && this.emit("removeListener", e2, o2 || t2);
|
|
1639
1716
|
}
|
|
1640
1717
|
return this;
|
|
1641
|
-
},
|
|
1718
|
+
}, x.prototype.off = function(e2, t2) {
|
|
1642
1719
|
return this.removeListener(e2, t2);
|
|
1643
|
-
},
|
|
1720
|
+
}, x.prototype.removeAllListeners = function(e2) {
|
|
1644
1721
|
var t2, i2;
|
|
1645
1722
|
if (!(i2 = this._events))
|
|
1646
1723
|
return this;
|
|
1647
1724
|
if (!i2.removeListener)
|
|
1648
|
-
return 0 === arguments.length ? (this._events = new
|
|
1725
|
+
return 0 === arguments.length ? (this._events = new M(), this._eventsCount = 0) : i2[e2] && (0 == --this._eventsCount ? this._events = new M() : delete i2[e2]), this;
|
|
1649
1726
|
if (0 === arguments.length) {
|
|
1650
1727
|
for (var n2, r2 = Object.keys(i2), s2 = 0; s2 < r2.length; ++s2)
|
|
1651
1728
|
"removeListener" !== (n2 = r2[s2]) && this.removeAllListeners(n2);
|
|
1652
|
-
return this.removeAllListeners("removeListener"), this._events = new
|
|
1729
|
+
return this.removeAllListeners("removeListener"), this._events = new M(), this._eventsCount = 0, this;
|
|
1653
1730
|
}
|
|
1654
1731
|
if ("function" == typeof (t2 = i2[e2]))
|
|
1655
1732
|
this.removeListener(e2, t2);
|
|
@@ -1658,34 +1735,34 @@ var telerikReportViewer = (function (exports) {
|
|
|
1658
1735
|
this.removeListener(e2, t2[t2.length - 1]);
|
|
1659
1736
|
} while (t2[0]);
|
|
1660
1737
|
return this;
|
|
1661
|
-
},
|
|
1738
|
+
}, x.prototype.listeners = function(e2) {
|
|
1662
1739
|
var t2, i2 = this._events;
|
|
1663
1740
|
return i2 && (t2 = i2[e2]) ? "function" == typeof t2 ? [t2.listener || t2] : function(e3) {
|
|
1664
1741
|
for (var t3 = new Array(e3.length), i3 = 0; i3 < t3.length; ++i3)
|
|
1665
1742
|
t3[i3] = e3[i3].listener || e3[i3];
|
|
1666
1743
|
return t3;
|
|
1667
1744
|
}(t2) : [];
|
|
1668
|
-
},
|
|
1669
|
-
return "function" == typeof e2.listenerCount ? e2.listenerCount(t2) :
|
|
1670
|
-
},
|
|
1745
|
+
}, x.listenerCount = function(e2, t2) {
|
|
1746
|
+
return "function" == typeof e2.listenerCount ? e2.listenerCount(t2) : N.call(e2, t2);
|
|
1747
|
+
}, x.prototype.listenerCount = N, x.prototype.eventNames = function() {
|
|
1671
1748
|
return this._eventsCount > 0 ? Reflect.ownKeys(this._events) : [];
|
|
1672
1749
|
};
|
|
1673
|
-
const
|
|
1674
|
-
function
|
|
1750
|
+
const O = "function" == typeof Symbol ? Symbol.for("--[[await-event-emitter]]--") : "--[[await-event-emitter]]--";
|
|
1751
|
+
function V(e2) {
|
|
1675
1752
|
if ("string" != typeof e2 && "symbol" != typeof e2)
|
|
1676
1753
|
throw new TypeError("type is not type of string or symbol!");
|
|
1677
1754
|
}
|
|
1678
|
-
function
|
|
1755
|
+
function z(e2) {
|
|
1679
1756
|
if ("function" != typeof e2)
|
|
1680
1757
|
throw new TypeError("fn is not type of Function!");
|
|
1681
1758
|
}
|
|
1682
|
-
function
|
|
1683
|
-
return { [
|
|
1759
|
+
function _(e2) {
|
|
1760
|
+
return { [O]: "always", fn: e2 };
|
|
1684
1761
|
}
|
|
1685
|
-
function
|
|
1686
|
-
return { [
|
|
1762
|
+
function U(e2) {
|
|
1763
|
+
return { [O]: "once", fn: e2 };
|
|
1687
1764
|
}
|
|
1688
|
-
class
|
|
1765
|
+
class $ {
|
|
1689
1766
|
constructor() {
|
|
1690
1767
|
this._events = {};
|
|
1691
1768
|
}
|
|
@@ -1693,25 +1770,25 @@ var telerikReportViewer = (function (exports) {
|
|
|
1693
1770
|
return this.on(e2, t2);
|
|
1694
1771
|
}
|
|
1695
1772
|
on(e2, t2) {
|
|
1696
|
-
return
|
|
1773
|
+
return V(e2), z(t2), this._events[e2] = this._events[e2] || [], this._events[e2].push(_(t2)), this;
|
|
1697
1774
|
}
|
|
1698
1775
|
prependListener(e2, t2) {
|
|
1699
1776
|
return this.prepend(e2, t2);
|
|
1700
1777
|
}
|
|
1701
1778
|
prepend(e2, t2) {
|
|
1702
|
-
return
|
|
1779
|
+
return V(e2), z(t2), this._events[e2] = this._events[e2] || [], this._events[e2].unshift(_(t2)), this;
|
|
1703
1780
|
}
|
|
1704
1781
|
prependOnceListener(e2, t2) {
|
|
1705
1782
|
return this.prependOnce(e2, t2);
|
|
1706
1783
|
}
|
|
1707
1784
|
prependOnce(e2, t2) {
|
|
1708
|
-
return
|
|
1785
|
+
return V(e2), z(t2), this._events[e2] = this._events[e2] || [], this._events[e2].unshift(U(t2)), this;
|
|
1709
1786
|
}
|
|
1710
1787
|
listeners(e2) {
|
|
1711
1788
|
return (this._events[e2] || []).map((e3) => e3.fn);
|
|
1712
1789
|
}
|
|
1713
1790
|
once(e2, t2) {
|
|
1714
|
-
return
|
|
1791
|
+
return V(e2), z(t2), this._events[e2] = this._events[e2] || [], this._events[e2].push(U(t2)), this;
|
|
1715
1792
|
}
|
|
1716
1793
|
removeAllListeners() {
|
|
1717
1794
|
this._events = {};
|
|
@@ -1720,7 +1797,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
1720
1797
|
return this.removeListener(e2, t2);
|
|
1721
1798
|
}
|
|
1722
1799
|
removeListener(e2, t2) {
|
|
1723
|
-
|
|
1800
|
+
V(e2);
|
|
1724
1801
|
const i2 = this.listeners(e2);
|
|
1725
1802
|
if ("function" == typeof t2) {
|
|
1726
1803
|
let n2 = -1, r2 = false;
|
|
@@ -1731,13 +1808,13 @@ var telerikReportViewer = (function (exports) {
|
|
|
1731
1808
|
return delete this._events[e2];
|
|
1732
1809
|
}
|
|
1733
1810
|
emit(e2, ...t2) {
|
|
1734
|
-
return
|
|
1735
|
-
|
|
1811
|
+
return s(this, void 0, void 0, function* () {
|
|
1812
|
+
V(e2);
|
|
1736
1813
|
const i2 = this.listeners(e2), n2 = [];
|
|
1737
1814
|
if (i2 && i2.length) {
|
|
1738
1815
|
for (let r2 = 0; r2 < i2.length; r2++) {
|
|
1739
1816
|
const s2 = i2[r2], o2 = s2.apply(this, t2);
|
|
1740
|
-
o2 instanceof Promise && (yield o2), this._events[e2] && this._events[e2][r2] && "once" === this._events[e2][r2][
|
|
1817
|
+
o2 instanceof Promise && (yield o2), this._events[e2] && this._events[e2][r2] && "once" === this._events[e2][r2][O] && n2.push(s2);
|
|
1741
1818
|
}
|
|
1742
1819
|
return n2.forEach((t3) => this.removeListener(e2, t3)), true;
|
|
1743
1820
|
}
|
|
@@ -1745,21 +1822,21 @@ var telerikReportViewer = (function (exports) {
|
|
|
1745
1822
|
});
|
|
1746
1823
|
}
|
|
1747
1824
|
emitSync(e2, ...t2) {
|
|
1748
|
-
|
|
1825
|
+
V(e2);
|
|
1749
1826
|
const i2 = this.listeners(e2), n2 = [];
|
|
1750
1827
|
if (i2 && i2.length) {
|
|
1751
1828
|
for (let r2 = 0; r2 < i2.length; r2++) {
|
|
1752
1829
|
const s2 = i2[r2];
|
|
1753
|
-
s2.apply(this, t2), this._events[e2] && this._events[e2][r2] && "once" === this._events[e2][r2][
|
|
1830
|
+
s2.apply(this, t2), this._events[e2] && this._events[e2][r2] && "once" === this._events[e2][r2][O] && n2.push(s2);
|
|
1754
1831
|
}
|
|
1755
1832
|
return n2.forEach((t3) => this.removeListener(e2, t3)), true;
|
|
1756
1833
|
}
|
|
1757
1834
|
return false;
|
|
1758
1835
|
}
|
|
1759
1836
|
}
|
|
1760
|
-
class
|
|
1837
|
+
class H {
|
|
1761
1838
|
constructor() {
|
|
1762
|
-
this.eventEmitter = new
|
|
1839
|
+
this.eventEmitter = new x(), this.awaitEventEmitter = new $();
|
|
1763
1840
|
}
|
|
1764
1841
|
on(e2, t2) {
|
|
1765
1842
|
return this.eventEmitter.on(e2, t2), this;
|
|
@@ -1771,12 +1848,12 @@ var telerikReportViewer = (function (exports) {
|
|
|
1771
1848
|
return this.awaitEventEmitter.on(e2, t2), this;
|
|
1772
1849
|
}
|
|
1773
1850
|
emitAsync(e2, ...t2) {
|
|
1774
|
-
return
|
|
1851
|
+
return s(this, void 0, void 0, function* () {
|
|
1775
1852
|
yield this.awaitEventEmitter.emit(e2, ...t2);
|
|
1776
1853
|
});
|
|
1777
1854
|
}
|
|
1778
1855
|
}
|
|
1779
|
-
class
|
|
1856
|
+
class B {
|
|
1780
1857
|
hasPdfPlugin() {
|
|
1781
1858
|
let e2 = ["AcroPDF.PDF.1", "PDF.PdfCtrl.6", "PDF.PdfCtrl.5"];
|
|
1782
1859
|
for (let t2 of e2)
|
|
@@ -1789,7 +1866,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
1789
1866
|
return false;
|
|
1790
1867
|
}
|
|
1791
1868
|
}
|
|
1792
|
-
class
|
|
1869
|
+
class q {
|
|
1793
1870
|
hasPdfPlugin() {
|
|
1794
1871
|
let e2 = /Firefox[/\s](\d+\.\d+)/.exec(navigator.userAgent);
|
|
1795
1872
|
if (null !== e2 && e2.length > 1) {
|
|
@@ -1804,7 +1881,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
1804
1881
|
return false;
|
|
1805
1882
|
}
|
|
1806
1883
|
}
|
|
1807
|
-
class
|
|
1884
|
+
class W {
|
|
1808
1885
|
constructor(e2) {
|
|
1809
1886
|
this.defaultPlugin = e2;
|
|
1810
1887
|
}
|
|
@@ -1815,22 +1892,22 @@ var telerikReportViewer = (function (exports) {
|
|
|
1815
1892
|
return false;
|
|
1816
1893
|
}
|
|
1817
1894
|
}
|
|
1818
|
-
class
|
|
1895
|
+
class j {
|
|
1819
1896
|
hasPdfPlugin() {
|
|
1820
1897
|
return false;
|
|
1821
1898
|
}
|
|
1822
1899
|
}
|
|
1823
|
-
function
|
|
1900
|
+
function J() {
|
|
1824
1901
|
return window.navigator && window.navigator.msSaveOrOpenBlob;
|
|
1825
1902
|
}
|
|
1826
|
-
class
|
|
1903
|
+
class G {
|
|
1827
1904
|
constructor() {
|
|
1828
1905
|
this.hasPdfPlugin = false, this.iframe = null, this.hasPdfPlugin = function() {
|
|
1829
1906
|
if (window.navigator) {
|
|
1830
1907
|
let e2 = window.navigator.userAgent.toLowerCase();
|
|
1831
|
-
return e2.indexOf("msie") > -1 || e2.indexOf("mozilla") > -1 && e2.indexOf("trident") > -1 ? new
|
|
1908
|
+
return e2.indexOf("msie") > -1 || e2.indexOf("mozilla") > -1 && e2.indexOf("trident") > -1 ? new B() : e2.indexOf("firefox") > -1 ? new q() : e2.indexOf("edg/") > -1 ? new W("Microsoft Edge PDF Plugin") : e2.indexOf("chrome") > -1 ? new W("Chrome PDF Viewer") : e2.indexOf("safari") > -1 ? new W("WebKit built-in PDF") : new j();
|
|
1832
1909
|
}
|
|
1833
|
-
return new
|
|
1910
|
+
return new j();
|
|
1834
1911
|
}().hasPdfPlugin(), this.isMobile = /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent);
|
|
1835
1912
|
}
|
|
1836
1913
|
destroy() {
|
|
@@ -1848,13 +1925,13 @@ var telerikReportViewer = (function (exports) {
|
|
|
1848
1925
|
}), function(e3) {
|
|
1849
1926
|
let t3 = window.location, i3 = document.createElement("a");
|
|
1850
1927
|
return i3.setAttribute("href", e3), "" == i3.host && (i3.href = i3.href), t3.hostname === i3.hostname && t3.protocol === i3.protocol && t3.port === i3.port;
|
|
1851
|
-
}(e2) &&
|
|
1928
|
+
}(e2) && J())
|
|
1852
1929
|
return this.iframe.src = e2, void document.body.appendChild(this.iframe);
|
|
1853
1930
|
let i2 = new XMLHttpRequest(), n2 = this;
|
|
1854
1931
|
i2.open("GET", e2, true), i2.responseType = "arraybuffer", i2.onload = function() {
|
|
1855
1932
|
if (200 === this.status) {
|
|
1856
1933
|
let e3 = new Blob([this.response], { type: "application/pdf" });
|
|
1857
|
-
|
|
1934
|
+
J() ? window.navigator.msSaveOrOpenBlob(e3) : (t2 = (window.URL || window.webkitURL).createObjectURL(e3), null != n2.iframe && (n2.iframe.src = t2, document.body.appendChild(n2.iframe)));
|
|
1858
1935
|
} else
|
|
1859
1936
|
console.log("Could not retrieve remote PDF document.");
|
|
1860
1937
|
}, i2.send();
|
|
@@ -1869,10 +1946,10 @@ var telerikReportViewer = (function (exports) {
|
|
|
1869
1946
|
return this.hasPdfPlugin;
|
|
1870
1947
|
}
|
|
1871
1948
|
}
|
|
1872
|
-
function
|
|
1949
|
+
function Z(e2) {
|
|
1873
1950
|
return 1e3 * e2;
|
|
1874
1951
|
}
|
|
1875
|
-
class
|
|
1952
|
+
class K {
|
|
1876
1953
|
constructor(e2, t2, i2) {
|
|
1877
1954
|
if (this.pingMilliseconds = 0, !e2)
|
|
1878
1955
|
throw "Error";
|
|
@@ -1881,7 +1958,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
1881
1958
|
initSessionTimeout(e2) {
|
|
1882
1959
|
if (!isFinite(e2))
|
|
1883
1960
|
throw "sessionTimeoutSeconds must be finite";
|
|
1884
|
-
this.pingMilliseconds = e2 <= 120 ?
|
|
1961
|
+
this.pingMilliseconds = e2 <= 120 ? Z(e2) / 2 : Z(e2 - 60);
|
|
1885
1962
|
}
|
|
1886
1963
|
start() {
|
|
1887
1964
|
this.pingMilliseconds <= 0 || (this.interval = setInterval(() => {
|
|
@@ -1892,33 +1969,33 @@ var telerikReportViewer = (function (exports) {
|
|
|
1892
1969
|
this.interval && (clearInterval(this.interval), this.interval = null);
|
|
1893
1970
|
}
|
|
1894
1971
|
}
|
|
1895
|
-
var
|
|
1896
|
-
function
|
|
1972
|
+
var X, Y, Q, ee, te;
|
|
1973
|
+
function ie(e2, t2 = "", i2 = "") {
|
|
1897
1974
|
let n2 = document.createElement(e2);
|
|
1898
|
-
return t2 && (n2.id = t2),
|
|
1975
|
+
return t2 && (n2.id = t2), ne(n2, i2), n2;
|
|
1899
1976
|
}
|
|
1900
|
-
function
|
|
1977
|
+
function ne(e2, t2) {
|
|
1901
1978
|
if ("" === t2 || !e2)
|
|
1902
1979
|
return;
|
|
1903
1980
|
let i2 = t2.trim().split(" ");
|
|
1904
1981
|
i2 = i2.filter((e3) => "" !== e3.trim()), e2.classList.add(...i2);
|
|
1905
1982
|
}
|
|
1906
|
-
function
|
|
1983
|
+
function re(e2, t2) {
|
|
1907
1984
|
if ("" === t2 || !e2)
|
|
1908
1985
|
return;
|
|
1909
1986
|
let i2 = t2.trim().split(" ");
|
|
1910
1987
|
i2 = i2.filter((e3) => "" !== e3.trim()), e2.classList.remove(...i2);
|
|
1911
1988
|
}
|
|
1912
|
-
function
|
|
1989
|
+
function se(e2, t2) {
|
|
1913
1990
|
return e2.classList.contains(t2);
|
|
1914
1991
|
}
|
|
1915
|
-
function
|
|
1992
|
+
function oe(e2) {
|
|
1916
1993
|
return e2.offsetParent;
|
|
1917
1994
|
}
|
|
1918
|
-
function
|
|
1995
|
+
function ae(e2) {
|
|
1919
1996
|
return parseInt(e2, 10) || 0;
|
|
1920
1997
|
}
|
|
1921
|
-
function
|
|
1998
|
+
function le(e2, t2, i2, n2 = 0, r2 = 0) {
|
|
1922
1999
|
let s2 = `${n2 = n2 || 0} ${r2 = r2 || 0}`;
|
|
1923
2000
|
!function(e3, t3) {
|
|
1924
2001
|
e3.style.setProperty("transform", t3), e3.style.setProperty("-moz-transform", t3), e3.style.setProperty("-ms-transform", t3), e3.style.setProperty("-webkit-transform", t3), e3.style.setProperty("-o-transform", t3);
|
|
@@ -1926,11 +2003,11 @@ var telerikReportViewer = (function (exports) {
|
|
|
1926
2003
|
e3.style.setProperty("transform-origin", t3), e3.style.setProperty("-moz-transform-origin", t3), e3.style.setProperty("-ms-transform-origin", t3), e3.style.setProperty("-webkit-transform-origin", t3), e3.style.setProperty("-o-transform-origin", t3);
|
|
1927
2004
|
}(e2, s2);
|
|
1928
2005
|
}
|
|
1929
|
-
function
|
|
1930
|
-
let t2 =
|
|
2006
|
+
function he(e2) {
|
|
2007
|
+
let t2 = ie("div");
|
|
1931
2008
|
return t2.textContent = e2, t2.innerHTML;
|
|
1932
2009
|
}
|
|
1933
|
-
function
|
|
2010
|
+
function ce(e2) {
|
|
1934
2011
|
if (e2 && e2.length < 6) {
|
|
1935
2012
|
let t3 = 1, i2 = e2.split("");
|
|
1936
2013
|
for ("#" !== i2[0] && (t3 = 0); t3 < i2.length; t3++)
|
|
@@ -1940,16 +2017,16 @@ var telerikReportViewer = (function (exports) {
|
|
|
1940
2017
|
let t2 = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(e2);
|
|
1941
2018
|
return t2 ? parseInt(t2[1], 16) + ", " + parseInt(t2[2], 16) + ", " + parseInt(t2[3], 16) : null;
|
|
1942
2019
|
}
|
|
1943
|
-
function
|
|
2020
|
+
function de(e2) {
|
|
1944
2021
|
return !!e2 && e2.indexOf(",") > -1;
|
|
1945
2022
|
}
|
|
1946
|
-
function
|
|
2023
|
+
function ue(e2) {
|
|
1947
2024
|
if ("transparent" === e2.toLowerCase())
|
|
1948
2025
|
return 0;
|
|
1949
|
-
if (!
|
|
2026
|
+
if (!de(e2))
|
|
1950
2027
|
return 1;
|
|
1951
2028
|
if (-1 !== e2.indexOf("#")) {
|
|
1952
|
-
let t3 =
|
|
2029
|
+
let t3 = ce(e2);
|
|
1953
2030
|
if (null === t3)
|
|
1954
2031
|
return 1;
|
|
1955
2032
|
e2 = t3;
|
|
@@ -1959,34 +2036,34 @@ var telerikReportViewer = (function (exports) {
|
|
|
1959
2036
|
});
|
|
1960
2037
|
return 4 === t2.length ? parseFloat((parseFloat(t2[3].replace(/[()]/g, "")) / 255).toFixed(2)) : 1;
|
|
1961
2038
|
}
|
|
1962
|
-
function
|
|
1963
|
-
let i2 =
|
|
2039
|
+
function pe(e2, t2) {
|
|
2040
|
+
let i2 = ie("div");
|
|
1964
2041
|
for (i2.innerHTML = t2; i2.childNodes.length; )
|
|
1965
2042
|
e2.appendChild(i2.childNodes[0]);
|
|
1966
2043
|
}
|
|
1967
|
-
function
|
|
1968
|
-
let i2 =
|
|
2044
|
+
function ge(e2, t2) {
|
|
2045
|
+
let i2 = ie("div");
|
|
1969
2046
|
for (i2.innerHTML = t2; i2.childNodes.length; )
|
|
1970
2047
|
e2.prepend(i2.childNodes[i2.childNodes.length - 1]);
|
|
1971
2048
|
}
|
|
1972
|
-
function
|
|
1973
|
-
return
|
|
2049
|
+
function me(e2, t2) {
|
|
2050
|
+
return e2 ? e2.querySelector(t2) : null;
|
|
1974
2051
|
}
|
|
1975
|
-
function
|
|
2052
|
+
function fe(e2, t2) {
|
|
1976
2053
|
var i2;
|
|
1977
2054
|
return e2 && e2.attributes && (null === (i2 = e2.attributes[t2]) || void 0 === i2 ? void 0 : i2.value) || "";
|
|
1978
2055
|
}
|
|
1979
|
-
function
|
|
2056
|
+
function ve(e2) {
|
|
1980
2057
|
let t2 = e2.parentElement;
|
|
1981
|
-
return t2 ? t2.clientHeight != t2.scrollHeight ? t2 :
|
|
2058
|
+
return t2 ? t2.clientHeight != t2.scrollHeight ? t2 : ve(t2) : null;
|
|
1982
2059
|
}
|
|
1983
|
-
function
|
|
2060
|
+
function Pe(e2, t2 = 300) {
|
|
1984
2061
|
let i2;
|
|
1985
2062
|
return function(...n2) {
|
|
1986
2063
|
clearTimeout(i2), i2 = setTimeout(() => e2.apply(this, n2), t2);
|
|
1987
2064
|
};
|
|
1988
2065
|
}
|
|
1989
|
-
function
|
|
2066
|
+
function Ce(e2, t2) {
|
|
1990
2067
|
let i2 = null;
|
|
1991
2068
|
return function(n2, ...r2) {
|
|
1992
2069
|
i2 || (i2 = setTimeout(function() {
|
|
@@ -1994,24 +2071,24 @@ var telerikReportViewer = (function (exports) {
|
|
|
1994
2071
|
}, t2));
|
|
1995
2072
|
};
|
|
1996
2073
|
}
|
|
1997
|
-
function
|
|
2074
|
+
function ye(e2, t2) {
|
|
1998
2075
|
return !!e2.responseJSON && e2.responseJSON.exceptionType === t2;
|
|
1999
2076
|
}
|
|
2000
|
-
function
|
|
2001
|
-
return
|
|
2077
|
+
function Se(e2) {
|
|
2078
|
+
return ye(e2, "Telerik.Reporting.Services.Engine.InvalidClientException");
|
|
2002
2079
|
}
|
|
2003
|
-
function
|
|
2004
|
-
return
|
|
2080
|
+
function Ie(e2) {
|
|
2081
|
+
return ye(e2, "Telerik.Reporting.Services.Engine.InvalidParameterException");
|
|
2005
2082
|
}
|
|
2006
|
-
function
|
|
2083
|
+
function be(e2) {
|
|
2007
2084
|
return !!e2 && "internalservererror" === e2.split(" ").join("").toLowerCase();
|
|
2008
2085
|
}
|
|
2009
|
-
function
|
|
2086
|
+
function we(e2, ...t2) {
|
|
2010
2087
|
return e2.replace(/{(\d+)}/g, (e3, i2) => t2[i2] || "");
|
|
2011
2088
|
}
|
|
2012
|
-
function
|
|
2089
|
+
function Te(e2, t2) {
|
|
2013
2090
|
let i2, n2;
|
|
2014
|
-
if (
|
|
2091
|
+
if (Ae(e2))
|
|
2015
2092
|
for (i2 = e2.length, n2 = 0; n2 < i2 && false !== t2.call(e2[n2], n2, e2[n2]); n2++)
|
|
2016
2093
|
;
|
|
2017
2094
|
else
|
|
@@ -2020,55 +2097,40 @@ var telerikReportViewer = (function (exports) {
|
|
|
2020
2097
|
break;
|
|
2021
2098
|
return e2;
|
|
2022
2099
|
}
|
|
2023
|
-
function
|
|
2100
|
+
function Ae(e2) {
|
|
2024
2101
|
if (Array.isArray(e2))
|
|
2025
2102
|
return true;
|
|
2026
2103
|
return "number" == typeof (!!e2 && "length" in e2 && e2.length);
|
|
2027
2104
|
}
|
|
2028
|
-
function
|
|
2105
|
+
function Re(e2) {
|
|
2029
2106
|
return /^(\-|\+)?([0-9]+)$/.test(e2) ? Number(e2) : NaN;
|
|
2030
2107
|
}
|
|
2031
|
-
function
|
|
2108
|
+
function Ee(e2) {
|
|
2032
2109
|
return /^(\-|\+)?([0-9]+(\.[0-9]+)?)$/.test(e2) ? Number(e2) : NaN;
|
|
2033
2110
|
}
|
|
2034
|
-
function
|
|
2111
|
+
function Me(e2) {
|
|
2035
2112
|
return e2 instanceof Date ? e2 : (/Z|[\+\-]\d\d:?\d\d/i.test(e2) || (e2 += "Z"), new Date(e2));
|
|
2036
2113
|
}
|
|
2037
|
-
e.PageMode = void 0, (
|
|
2038
|
-
class
|
|
2039
|
-
constructor(e2) {
|
|
2040
|
-
this.handled = false, this.deviceInfo = e2;
|
|
2041
|
-
}
|
|
2042
|
-
}
|
|
2043
|
-
class ve {
|
|
2044
|
-
constructor(e2) {
|
|
2045
|
-
this.handled = false, this.url = e2;
|
|
2046
|
-
}
|
|
2047
|
-
}
|
|
2048
|
-
class Pe {
|
|
2049
|
-
constructor(e2, t2) {
|
|
2050
|
-
this.handled = false, this.deviceInfo = e2, this.format = t2;
|
|
2051
|
-
}
|
|
2052
|
-
}
|
|
2053
|
-
class ye {
|
|
2114
|
+
e.PageMode = void 0, (X = e.PageMode || (e.PageMode = {}))[X.ContinuousScroll = 0] = "ContinuousScroll", X[X.SinglePage = 1] = "SinglePage", e.PrintMode = void 0, (Y = e.PrintMode || (e.PrintMode = {}))[Y.AutoSelect = 0] = "AutoSelect", Y[Y.ForcePDFPlugin = 1] = "ForcePDFPlugin", Y[Y.ForcePDFFile = 2] = "ForcePDFFile", e.ScaleMode = void 0, (Q = e.ScaleMode || (e.ScaleMode = {}))[Q.FitPageWidth = 0] = "FitPageWidth", Q[Q.FitPage = 1] = "FitPage", Q[Q.Specific = 2] = "Specific", e.ServiceType = void 0, (ee = e.ServiceType || (e.ServiceType = {}))[ee.REST = 0] = "REST", ee[ee.ReportServer = 1] = "ReportServer", e.ViewMode = void 0, (te = e.ViewMode || (e.ViewMode = {}))[te.Interactive = 0] = "Interactive", te[te.PrintPreview = 1] = "PrintPreview";
|
|
2115
|
+
class xe {
|
|
2054
2116
|
constructor(e2, t2) {
|
|
2055
2117
|
this.handled = false, this.deviceInfo = e2, this.format = t2;
|
|
2056
2118
|
}
|
|
2057
2119
|
}
|
|
2058
|
-
class
|
|
2120
|
+
class ke extends a {
|
|
2059
2121
|
constructor(e2, t2, i2) {
|
|
2060
2122
|
super(), this.handled = false, this.body = e2.body, this.cc = e2.cc, this.format = e2.format, this.from = e2.from, this.subject = e2.subject, this.to = e2.to, this.deviceInfo = t2, this.url = i2;
|
|
2061
2123
|
}
|
|
2062
2124
|
}
|
|
2063
|
-
const
|
|
2064
|
-
var
|
|
2125
|
+
const Le = "System.Int64", De = "System.Double", Ne = "System.String", Fe = "System.DateTime", Oe = "System.Boolean";
|
|
2126
|
+
var Ve = function() {
|
|
2065
2127
|
var e2 = {};
|
|
2066
2128
|
function t2(e3, t3, i3, n2) {
|
|
2067
2129
|
var r2 = [].concat(t3).map(function(t4) {
|
|
2068
2130
|
return function(e4, t5, i4) {
|
|
2069
2131
|
if (e4.availableValues) {
|
|
2070
2132
|
var n3 = false;
|
|
2071
|
-
if (
|
|
2133
|
+
if (Te(e4.availableValues, function(e5, r3) {
|
|
2072
2134
|
return !(n3 = i4(t5, r3.value));
|
|
2073
2135
|
}), !n3) {
|
|
2074
2136
|
if (e4.allowNull && !t5)
|
|
@@ -2092,7 +2154,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
2092
2154
|
function i2(e3, t3) {
|
|
2093
2155
|
return e3.allowNull && -1 != [null, "", void 0].indexOf(t3);
|
|
2094
2156
|
}
|
|
2095
|
-
return e2[
|
|
2157
|
+
return e2[Ne] = { validate: function(e3, i3) {
|
|
2096
2158
|
return t2(e3, i3, function(t3) {
|
|
2097
2159
|
if (!t3) {
|
|
2098
2160
|
if (e3.allowNull)
|
|
@@ -2105,9 +2167,9 @@ var telerikReportViewer = (function (exports) {
|
|
|
2105
2167
|
}, function(e4, t3) {
|
|
2106
2168
|
return e4 == t3;
|
|
2107
2169
|
});
|
|
2108
|
-
} }, e2[
|
|
2170
|
+
} }, e2[De] = { validate: function(e3, n2) {
|
|
2109
2171
|
return t2(e3, n2, function(t3) {
|
|
2110
|
-
var n3 =
|
|
2172
|
+
var n3 = Ee(t3);
|
|
2111
2173
|
if (isNaN(n3)) {
|
|
2112
2174
|
if (i2(e3, t3))
|
|
2113
2175
|
return null;
|
|
@@ -2115,11 +2177,11 @@ var telerikReportViewer = (function (exports) {
|
|
|
2115
2177
|
}
|
|
2116
2178
|
return n3;
|
|
2117
2179
|
}, function(e4, t3) {
|
|
2118
|
-
return
|
|
2180
|
+
return Ee(e4) == Ee(t3);
|
|
2119
2181
|
});
|
|
2120
|
-
} }, e2[
|
|
2182
|
+
} }, e2[Le] = { validate: function(e3, n2) {
|
|
2121
2183
|
return t2(e3, n2, function(t3) {
|
|
2122
|
-
var n3 =
|
|
2184
|
+
var n3 = Re(t3);
|
|
2123
2185
|
if (isNaN(n3)) {
|
|
2124
2186
|
if (i2(e3, t3))
|
|
2125
2187
|
return null;
|
|
@@ -2127,19 +2189,19 @@ var telerikReportViewer = (function (exports) {
|
|
|
2127
2189
|
}
|
|
2128
2190
|
return n3;
|
|
2129
2191
|
}, function(e4, t3) {
|
|
2130
|
-
return
|
|
2192
|
+
return Re(e4) == Ee(t3);
|
|
2131
2193
|
});
|
|
2132
|
-
} }, e2[
|
|
2194
|
+
} }, e2[Fe] = { validate: function(e3, i3) {
|
|
2133
2195
|
return t2(e3, i3, function(t3) {
|
|
2134
2196
|
if (e3.allowNull && (null === t3 || "" === t3 || void 0 === t3))
|
|
2135
2197
|
return null;
|
|
2136
2198
|
if (!isNaN(Date.parse(t3)))
|
|
2137
|
-
return e3.availableValues ? t3 :
|
|
2199
|
+
return e3.availableValues ? t3 : Me(t3);
|
|
2138
2200
|
throw "Please input a valid date.";
|
|
2139
2201
|
}, function(e4, t3) {
|
|
2140
|
-
return e4 =
|
|
2202
|
+
return e4 = Me(e4), t3 = Me(t3), e4.getTime() == t3.getTime();
|
|
2141
2203
|
});
|
|
2142
|
-
} }, e2[
|
|
2204
|
+
} }, e2[Oe] = { validate: function(e3, n2) {
|
|
2143
2205
|
return t2(e3, n2, function(t3) {
|
|
2144
2206
|
if (-1 != ["true", "false"].indexOf(String(t3).toLowerCase()))
|
|
2145
2207
|
return Boolean(t3);
|
|
@@ -2152,37 +2214,35 @@ var telerikReportViewer = (function (exports) {
|
|
|
2152
2214
|
} }, { validate: function(t3, i3) {
|
|
2153
2215
|
var n2 = e2[t3.type];
|
|
2154
2216
|
if (!n2)
|
|
2155
|
-
throw
|
|
2217
|
+
throw we("Cannot validate parameter of type {type}.", t3);
|
|
2156
2218
|
return n2.validate(t3, i3);
|
|
2157
2219
|
} };
|
|
2158
2220
|
}();
|
|
2159
|
-
function
|
|
2221
|
+
function ze(e2, t2, i2) {
|
|
2160
2222
|
try {
|
|
2161
2223
|
const n2 = e2.availableValues.find((e3) => e3.value === t2);
|
|
2162
|
-
if (!n2)
|
|
2224
|
+
if (!n2) {
|
|
2225
|
+
if (e2.allowNull && null === t2)
|
|
2226
|
+
return { valueMember: null, displayMember: null };
|
|
2163
2227
|
throw new Error(`The available values of parameter ${i2} do not contain Value property that equals ${t2}`);
|
|
2228
|
+
}
|
|
2164
2229
|
return { valueMember: t2, displayMember: n2.name };
|
|
2165
2230
|
} catch (e3) {
|
|
2166
2231
|
return;
|
|
2167
2232
|
}
|
|
2168
2233
|
}
|
|
2169
|
-
function
|
|
2234
|
+
function _e(e2, t2, i2) {
|
|
2170
2235
|
const n2 = [];
|
|
2171
2236
|
for (let r2 in t2)
|
|
2172
|
-
n2.push(
|
|
2237
|
+
n2.push(ze(e2, t2[r2], i2));
|
|
2173
2238
|
return n2;
|
|
2174
2239
|
}
|
|
2175
|
-
class
|
|
2240
|
+
class Ue {
|
|
2176
2241
|
constructor(e2 = "", t2 = {}) {
|
|
2177
2242
|
this.report = e2, this.parameters = t2;
|
|
2178
2243
|
}
|
|
2179
2244
|
}
|
|
2180
|
-
class
|
|
2181
|
-
constructor(e2, t2, i2, n2 = null) {
|
|
2182
|
-
this.element = e2, this.text = t2, this.title = i2, this.eventArgs = n2;
|
|
2183
|
-
}
|
|
2184
|
-
}
|
|
2185
|
-
class xe extends A {
|
|
2245
|
+
class $e extends H {
|
|
2186
2246
|
constructor(e2) {
|
|
2187
2247
|
super(), this.resizeObserver = null, this.element = e2, this.initResizeObserver();
|
|
2188
2248
|
}
|
|
@@ -2190,7 +2250,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
2190
2250
|
this.destroyResizeObserver();
|
|
2191
2251
|
}
|
|
2192
2252
|
initResizeObserver() {
|
|
2193
|
-
this.debounceResize =
|
|
2253
|
+
this.debounceResize = Pe(this.onResize.bind(this), 50), this.resizeObserver = new ResizeObserver(this.debounceResize), this.resizeObserver.observe(this.element);
|
|
2194
2254
|
}
|
|
2195
2255
|
destroyResizeObserver() {
|
|
2196
2256
|
this.resizeObserver && this.resizeObserver.unobserve(this.element), this.resizeObserver = this.debounceResize = null;
|
|
@@ -2199,8 +2259,8 @@ var telerikReportViewer = (function (exports) {
|
|
|
2199
2259
|
e2[0].target === this.element && this.emit("resize");
|
|
2200
2260
|
}
|
|
2201
2261
|
}
|
|
2202
|
-
const
|
|
2203
|
-
class
|
|
2262
|
+
const He = '<div class="trv-report-page trv-skeleton-page trv-skeleton-{0}" style="{1}" data-page="{0}"><div class="trv-skeleton-wrapper" style="{2}"></div></div>';
|
|
2263
|
+
class Be {
|
|
2204
2264
|
constructor(t2, i2, n2) {
|
|
2205
2265
|
this.enabled = false, this.viewMode = e.ViewMode.Interactive, this.scrollInProgress = false, this.additionalTopOffset = 130, this.onClickHandler = null, this.debounceScroll = null, this.throttleScroll = null, this.oldScrollTopPosition = 0, this.lastLoadedPage = null, this.placeholder = t2, this.pageContainer = t2.querySelector(".trv-page-container"), this.pageWrapper = t2.querySelector(".trv-page-wrapper"), this.contentArea = i2, this.controller = n2, this.controller.getPageMode() === e.PageMode.ContinuousScroll && this.enable(), this.controller.on("loadedReportChange", this.disable.bind(this)).on("viewModeChanged", this.disable.bind(this)).on("scaleChanged", this.onScaleChanged.bind(this)).on("interactiveActionExecuting", this.onInteractiveActionExecuting.bind(this)).on("pageLoaded", this.onPageLoaded.bind(this));
|
|
2206
2266
|
}
|
|
@@ -2222,10 +2282,10 @@ var telerikReportViewer = (function (exports) {
|
|
|
2222
2282
|
return this.enabled;
|
|
2223
2283
|
}
|
|
2224
2284
|
enable() {
|
|
2225
|
-
this.enabled = true,
|
|
2285
|
+
this.enabled = true, ne(this.placeholder, "scrollable"), this.initEvents();
|
|
2226
2286
|
}
|
|
2227
2287
|
disable() {
|
|
2228
|
-
this.enabled && (this.lastLoadedPage = null, this.pageWrapper.innerHTML = "", this.enabled = false,
|
|
2288
|
+
this.enabled && (this.lastLoadedPage = null, this.pageWrapper.innerHTML = "", this.enabled = false, re(this.placeholder, "scrollable"), this.unbind());
|
|
2229
2289
|
}
|
|
2230
2290
|
renderPage(e2) {
|
|
2231
2291
|
let t2 = this.controller.getViewMode(), i2 = this.findPageElement(e2.pageNumber);
|
|
@@ -2240,7 +2300,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
2240
2300
|
this.enabled && this.currentPageNumber() > 0 && this.keepCurrentPageInToView();
|
|
2241
2301
|
}
|
|
2242
2302
|
setCurrentPage(e2) {
|
|
2243
|
-
e2 !== this.currentPageNumber() && this.controller.setCurrentPageNumber(e2), this.controller.getPageCount() > 1 && (
|
|
2303
|
+
e2 !== this.currentPageNumber() && this.controller.setCurrentPageNumber(e2), this.controller.getPageCount() > 1 && (re(this.findElement(".k-state-default"), "k-state-default"), ne(this.findPageElement(e2), "k-state-default")), this.loadNextPreviousPage(e2);
|
|
2244
2304
|
}
|
|
2245
2305
|
updatePageArea(e2) {
|
|
2246
2306
|
var t2;
|
|
@@ -2265,18 +2325,18 @@ var telerikReportViewer = (function (exports) {
|
|
|
2265
2325
|
return this.controller.getCurrentPageNumber();
|
|
2266
2326
|
}
|
|
2267
2327
|
isSkeletonScreen(e2, t2) {
|
|
2268
|
-
return !(!e2 && !(e2 = this.findPageElement(t2))) &&
|
|
2328
|
+
return !(!e2 && !(e2 = this.findPageElement(t2))) && se(e2, "trv-skeleton-" + t2);
|
|
2269
2329
|
}
|
|
2270
2330
|
addSkeletonScreen(e2, t2) {
|
|
2271
|
-
let i2 = e2 + (t2 ? 1 : -1), n2 = this.findPageElement(i2), r2 =
|
|
2272
|
-
t2 ?
|
|
2331
|
+
let i2 = e2 + (t2 ? 1 : -1), n2 = this.findPageElement(i2), r2 = fe(n2, "style"), s2 = fe(null == n2 ? void 0 : n2.querySelector("sheet"), "style"), o2 = we(He, e2, r2, s2);
|
|
2332
|
+
t2 ? ge(this.pageWrapper, o2) : pe(this.pageWrapper, o2);
|
|
2273
2333
|
}
|
|
2274
2334
|
generateSkeletonScreens(e2) {
|
|
2275
2335
|
var t2;
|
|
2276
|
-
let i2 = "", n2 = this.findPageElement(1), r2 =
|
|
2336
|
+
let i2 = "", n2 = this.findPageElement(1), r2 = fe(n2, "style"), s2 = fe(null == n2 ? void 0 : n2.querySelector("sheet"), "style"), o2 = null === (t2 = this.findLastElement(".trv-report-page")) || void 0 === t2 ? void 0 : t2.dataset.page, a2 = o2 ? parseInt(o2) + 1 : 1;
|
|
2277
2337
|
for (; a2 < e2; a2++)
|
|
2278
|
-
i2 +=
|
|
2279
|
-
|
|
2338
|
+
i2 += we(He, a2, r2, s2);
|
|
2339
|
+
pe(this.pageWrapper, i2);
|
|
2280
2340
|
}
|
|
2281
2341
|
loadMorePages() {
|
|
2282
2342
|
var e2;
|
|
@@ -2327,10 +2387,10 @@ var telerikReportViewer = (function (exports) {
|
|
|
2327
2387
|
}
|
|
2328
2388
|
}
|
|
2329
2389
|
initEvents() {
|
|
2330
|
-
this.onClickHandler = this.clickPage.bind(this), this.debounceScroll =
|
|
2390
|
+
this.onClickHandler = this.clickPage.bind(this), this.debounceScroll = Pe(() => {
|
|
2331
2391
|
let e2 = this.placeholder.querySelectorAll(".trv-report-page"), t2 = Math.round(this.pageContainer.scrollTop + this.pageContainer.offsetHeight);
|
|
2332
2392
|
!this.scrollInProgress && e2.length && this.oldScrollTopPosition !== t2 && this.advanceCurrentPage(Array.from(e2));
|
|
2333
|
-
}, 250), this.throttleScroll =
|
|
2393
|
+
}, 250), this.throttleScroll = Ce(() => {
|
|
2334
2394
|
let e2 = this.placeholder.querySelectorAll(".trv-report-page"), t2 = Math.round(this.pageContainer.scrollTop + this.pageContainer.offsetHeight);
|
|
2335
2395
|
this.scrollInProgress || this.oldScrollTopPosition === t2 || (this.oldScrollTopPosition > t2 ? this.scrollUp(Array.from(e2)) : this.scrollDown(Array.from(e2), t2)), this.oldScrollTopPosition = t2;
|
|
2336
2396
|
}, 250), this.pageContainer.addEventListener("click", this.onClickHandler), this.pageContainer.addEventListener("scroll", this.debounceScroll), this.pageContainer.addEventListener("scroll", this.throttleScroll);
|
|
@@ -2425,7 +2485,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
2425
2485
|
return i2 && i2.length ? i2[i2.length - 1] : null;
|
|
2426
2486
|
}
|
|
2427
2487
|
}
|
|
2428
|
-
class
|
|
2488
|
+
class qe {
|
|
2429
2489
|
constructor() {
|
|
2430
2490
|
this.scaleFactor = 0, this.placeholder = null, this.scrollableContainer = null, this.itemsInitialState = {}, this.xFrozenAreasBounds = {}, this.yFrozenAreasBounds = {}, this.freezeMaxZIndex = {}, this.freezeBGColor = {}, this.currentlyFrozenContainer = { vertical: {}, horizontal: {} }, this.zIndex = 1;
|
|
2431
2491
|
}
|
|
@@ -2433,7 +2493,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
2433
2493
|
this.reset(e2), this.attachToScrollEvent();
|
|
2434
2494
|
}
|
|
2435
2495
|
reset(e2) {
|
|
2436
|
-
this.placeholder = e2, this.scrollableContainer =
|
|
2496
|
+
this.placeholder = e2, this.scrollableContainer = me(e2, ".trv-page-container"), this.itemsInitialState = {}, this.xFrozenAreasBounds = {}, this.yFrozenAreasBounds = {}, this.currentlyFrozenContainer = { vertical: {}, horizontal: {} };
|
|
2437
2497
|
}
|
|
2438
2498
|
setScaleFactor(e2) {
|
|
2439
2499
|
this.scaleFactor = e2;
|
|
@@ -2456,7 +2516,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
2456
2516
|
saveFreezeItemsInitialState(e2) {
|
|
2457
2517
|
var t2, i2, n2;
|
|
2458
2518
|
let r2 = null === (t2 = this.placeholder) || void 0 === t2 ? void 0 : t2.querySelectorAll("[data-sticky-direction][data-sticky-id='" + e2 + "']"), s2 = null === (i2 = this.placeholder) || void 0 === i2 ? void 0 : i2.querySelectorAll("[data-reporting-action][data-sticky-id='" + e2 + "']"), o2 = null, a2 = null, l2 = null, h2 = null;
|
|
2459
|
-
this.itemsInitialState[e2] = {}, this.freezeBGColor[e2] = (null === (n2 =
|
|
2519
|
+
this.itemsInitialState[e2] = {}, this.freezeBGColor[e2] = (null === (n2 = me(this.placeholder, "[data-id='" + e2 + "']")) || void 0 === n2 ? void 0 : n2.dataset.stickyBgColor) || "", r2.forEach((t3) => {
|
|
2460
2520
|
var i3;
|
|
2461
2521
|
let n3 = t3.dataset.stickyDirection, r3 = (null === (i3 = t3.dataset.id) || void 0 === i3 ? void 0 : i3.toString()) || "", s3 = t3.offsetLeft / this.scaleFactor, c2 = t3.offsetLeft + t3.offsetWidth * this.scaleFactor, d2 = t3.offsetTop / this.scaleFactor, u2 = t3.offsetTop + t3.offsetHeight * this.scaleFactor, p2 = (e3, t4) => null === e3 || t4 < e3 ? t4 : e3, g2 = (e3, t4) => null === e3 || t4 > e3 ? t4 : e3;
|
|
2462
2522
|
switch (n3) {
|
|
@@ -2478,7 +2538,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
2478
2538
|
}
|
|
2479
2539
|
updateFreezeItemsOnScroll(e2, t2, i2) {
|
|
2480
2540
|
var n2, r2;
|
|
2481
|
-
let s2 =
|
|
2541
|
+
let s2 = me(this.placeholder, "div[data-id='" + e2 + "']");
|
|
2482
2542
|
if (!s2)
|
|
2483
2543
|
return;
|
|
2484
2544
|
let o2 = null === (n2 = this.placeholder) || void 0 === n2 ? void 0 : n2.querySelectorAll("[data-sticky-direction*='Horizontal'][data-sticky-id='" + e2 + "']"), a2 = null === (r2 = this.placeholder) || void 0 === r2 ? void 0 : r2.querySelectorAll("[data-sticky-direction*='Vertical'][data-sticky-id='" + e2 + "']");
|
|
@@ -2503,7 +2563,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
2503
2563
|
"IMG" !== e2.tagName && (t2 && this.isFrozen(r2) && !i2 ? e2.style.backgroundColor = this.freezeBGColor[r2] : e2.style.backgroundColor = n2 ? this.freezeBGColor[r2] : "initial");
|
|
2504
2564
|
}
|
|
2505
2565
|
hasSetBgColor(e2) {
|
|
2506
|
-
return
|
|
2566
|
+
return ue(e2) > 0;
|
|
2507
2567
|
}
|
|
2508
2568
|
isFrozen(e2) {
|
|
2509
2569
|
return this.currentlyFrozenContainer.horizontal[e2] || this.currentlyFrozenContainer.vertical[e2];
|
|
@@ -2523,21 +2583,21 @@ var telerikReportViewer = (function (exports) {
|
|
|
2523
2583
|
return e2.top > t2.scrollTop - n2 && e2.top < t2.scrollTop + n2 + i2.height;
|
|
2524
2584
|
}
|
|
2525
2585
|
}
|
|
2526
|
-
const
|
|
2527
|
-
function
|
|
2586
|
+
const We = /{(\w+?)}/g, je = "trv-initial-image-styles";
|
|
2587
|
+
function Je(e2, t2) {
|
|
2528
2588
|
let i2 = Array.isArray(t2);
|
|
2529
|
-
return e2 ? e2.replace(
|
|
2589
|
+
return e2 ? e2.replace(We, function(e3, n2) {
|
|
2530
2590
|
return t2[i2 ? parseInt(n2) : n2];
|
|
2531
2591
|
}) : "";
|
|
2532
2592
|
}
|
|
2533
|
-
const
|
|
2534
|
-
e.BookmarkNode = class {
|
|
2593
|
+
const Ge = "trv-search-dialog-shaded-result", Ze = "trv-search-dialog-highlighted-result";
|
|
2594
|
+
e.BasicAuth = I, e.BookmarkNode = class {
|
|
2535
2595
|
constructor() {
|
|
2536
2596
|
this.id = "", this.text = "", this.page = 0, this.items = null;
|
|
2537
2597
|
}
|
|
2538
|
-
}, e.ContentArea = class {
|
|
2598
|
+
}, e.ConnectionConfig = w, e.ConnectionConfigNoAuth = T, e.ConnectionConfigServerCredentials = R, e.ConnectionConfigServerNoAuth = A, e.ConnectionConfigServerToken = E, e.ContentArea = class {
|
|
2539
2599
|
constructor(e2, t2, i2, n2 = {}) {
|
|
2540
|
-
this.actions = [], this.pendingElement = null, this.documentReady = true, this.reportPageIsLoaded = false, this.navigateToPageOnDocReady = 0, this.navigateToElementOnDocReady = null, this.onClickHandler = null, this.onMouseEnterHandler = null, this.onMouseLeaveHandler = null, this.isNewReportSource = false, this.uiFreezeCoordinator = null, this.initialPageAreaImageUrl = "", this.showPageAreaImage = false, this.placeholder = e2.querySelector(".trv-pages-pane, .trv-pages-area"), this.pageContainer = e2.querySelector(".trv-page-container"), this.pageWrapper = e2.querySelector(".trv-page-wrapper"), this.parametersContainer = e2.querySelector(".trv-parameters-area"), this.notification = e2.querySelector(".trv-notification, .trv-error-pane"), this.scrollManager = new
|
|
2600
|
+
this.actions = [], this.pendingElement = null, this.documentReady = true, this.reportPageIsLoaded = false, this.navigateToPageOnDocReady = 0, this.navigateToElementOnDocReady = null, this.onClickHandler = null, this.onMouseEnterHandler = null, this.onMouseLeaveHandler = null, this.isNewReportSource = false, this.uiFreezeCoordinator = null, this.initialPageAreaImageUrl = "", this.showPageAreaImage = false, this.placeholder = e2.querySelector(".trv-pages-pane, .trv-pages-area"), this.pageContainer = e2.querySelector(".trv-page-container"), this.pageWrapper = e2.querySelector(".trv-page-wrapper"), this.parametersContainer = e2.querySelector(".trv-parameters-area"), this.notification = e2.querySelector(".trv-notification, .trv-error-pane"), this.scrollManager = new Be(this.placeholder, this, t2), this.resizeService = new $e(this.pageContainer), this.resizeService.on("resize", this.onResize.bind(this)), this.controller = t2, this.controller.on("pageReady", this.onPageReady.bind(this)).on("navigateToPage", this.navigateToPage.bind(this)).on("serverActionStarted", this.onServerActionStarted.bind(this)).on("reportSourceChanged", this.onReportSourceChanged.bind(this)).on("scaleChanged", this.updatePageDimensions.bind(this)).on("scaleModeChanged", this.updatePageDimensions.bind(this)).on("printStarted", this.onPrintStarted.bind(this)).on("printDocumentReady", this.onPrintDocumentReady.bind(this)).on("exportStarted", this.onExportStarted.bind(this)).on("exportDocumentReady", this.onExportDocumentReady.bind(this)).onAsync("beforeLoadReport", this.onBeforeLoadReport.bind(this)).on("beginLoadReport", this.onBeginLoadReport.bind(this)).on("reportLoadProgress", this.onReportLoadProgress.bind(this)).onAsync("reportLoadComplete", this.onReportLoadComplete.bind(this)).onAsync("reportAutoRunOff", this.onReportAutoRunOff.bind(this)).on("renderingStopped", this.onRenderingStopped.bind(this)).on("missingOrInvalidParameters", this.onMissingOrInvalidParameters.bind(this)).on("noReport", this.onNoReport.bind(this)).on("error", this.onError.bind(this)), this.messages = i2, this.enableAccessibility = n2.enableAccessibility || false, this.initialPageAreaImageUrl = n2.initialPageAreaImageUrl || "";
|
|
2541
2601
|
}
|
|
2542
2602
|
destroy() {
|
|
2543
2603
|
this.resizeService && this.resizeService.destroy();
|
|
@@ -2564,10 +2624,10 @@ var telerikReportViewer = (function (exports) {
|
|
|
2564
2624
|
this.documentReady = true, this.invalidateCurrentlyLoadedPage();
|
|
2565
2625
|
}
|
|
2566
2626
|
onReportLoadProgress(e2) {
|
|
2567
|
-
this.navigateWhenPageAvailable(this.navigateToPageOnDocReady, e2.pageCount), this.showNotification(
|
|
2627
|
+
this.navigateWhenPageAvailable(this.navigateToPageOnDocReady, e2.pageCount), this.showNotification(Je(this.messages.ReportViewer_LoadingReportPagesInProgress, [e2.pageCount]));
|
|
2568
2628
|
}
|
|
2569
2629
|
onReportLoadComplete(t2) {
|
|
2570
|
-
0 === t2.pageCount ? (this.clearPage(), this.showNotification(this.messages.ReportViewer_NoPageToDisplay)) : (this.navigateOnLoadComplete(this.navigateToPageOnDocReady, t2.pageCount), this.showNotification(
|
|
2630
|
+
0 === t2.pageCount ? (this.clearPage(), this.showNotification(this.messages.ReportViewer_NoPageToDisplay)) : (this.navigateOnLoadComplete(this.navigateToPageOnDocReady, t2.pageCount), this.showNotification(Je(this.messages.ReportViewer_LoadedReportPagesComplete, [t2.pageCount])), this.showNotificationTimeoutId = window.setTimeout(this.hideNotification.bind(this), 2e3), this.disableParametersArea(false), this.enableInteractivity()), t2.containsFrozenContent && null === this.uiFreezeCoordinator && (this.uiFreezeCoordinator = new qe(), this.controller.getViewMode() === e.ViewMode.Interactive && this.uiFreezeCoordinator.init(this.placeholder));
|
|
2571
2631
|
}
|
|
2572
2632
|
onReportAutoRunOff() {
|
|
2573
2633
|
this.disableParametersArea(false), this.showNotification(this.messages.ReportViewer_AutoRunDisabled || "Please validate the report parameter values and press Preview to generate the report.");
|
|
@@ -2661,14 +2721,14 @@ var telerikReportViewer = (function (exports) {
|
|
|
2661
2721
|
}
|
|
2662
2722
|
let e3 = 0, i3 = 0;
|
|
2663
2723
|
for (; n2 && n2 !== this.pageContainer; ) {
|
|
2664
|
-
if (
|
|
2724
|
+
if (se(n2, "trv-page-wrapper")) {
|
|
2665
2725
|
let t3 = n2.dataset.pageScale;
|
|
2666
2726
|
if ("string" == typeof t3) {
|
|
2667
2727
|
let n3 = parseFloat(t3);
|
|
2668
2728
|
e3 *= n3, i3 *= n3;
|
|
2669
2729
|
}
|
|
2670
2730
|
}
|
|
2671
|
-
e3 += n2.offsetTop, i3 += n2.offsetLeft, n2 =
|
|
2731
|
+
e3 += n2.offsetTop, i3 += n2.offsetLeft, n2 = oe(n2);
|
|
2672
2732
|
}
|
|
2673
2733
|
this.scrollManager.getEnabled() && t2 ? this.scrollManager.navigateToElement(e3, t2) : (this.pageContainer.scrollTop = e3, this.pageContainer.scrollLeft = i3);
|
|
2674
2734
|
} else
|
|
@@ -2682,7 +2742,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
2682
2742
|
return !isNaN(t2) && t2 > -1 ? e2 : this.findNextFocusableElement(e2.nextElementSibling);
|
|
2683
2743
|
}
|
|
2684
2744
|
disablePagesArea(e2) {
|
|
2685
|
-
e2 ?
|
|
2745
|
+
e2 ? ne(this.placeholder, "trv-loading") : re(this.placeholder, "trv-loading");
|
|
2686
2746
|
}
|
|
2687
2747
|
disableParametersArea(e2) {
|
|
2688
2748
|
var t2, i2;
|
|
@@ -2692,13 +2752,14 @@ var telerikReportViewer = (function (exports) {
|
|
|
2692
2752
|
this.showNotification(e2, "error");
|
|
2693
2753
|
}
|
|
2694
2754
|
showNotification(e2 = "", t2 = "info") {
|
|
2695
|
-
this.notification.dataset.type
|
|
2696
|
-
|
|
2697
|
-
|
|
2755
|
+
let i2 = this.notification.dataset.type;
|
|
2756
|
+
i2 && re(this.notification, `k-notification-${i2}`), this.notification.dataset.type = t2;
|
|
2757
|
+
let n2 = this.notification.querySelector(".k-notification-content, .trv-error-message"), r2 = null == e2 ? void 0 : e2.split(/\r?\n/);
|
|
2758
|
+
n2.innerHTML = r2 && r2.length ? `${r2.join("<br>")}` : "Notification message not found.", ne(this.notification, `k-notification-${t2}`), re(this.notification, "k-hidden");
|
|
2698
2759
|
}
|
|
2699
2760
|
hideNotification() {
|
|
2700
2761
|
let e2 = String(this.notification.dataset.type);
|
|
2701
|
-
delete this.notification.dataset.type,
|
|
2762
|
+
delete this.notification.dataset.type, re(this.notification, `k-notification-${e2}`), ne(this.notification, "k-hidden");
|
|
2702
2763
|
}
|
|
2703
2764
|
pageNo(e2) {
|
|
2704
2765
|
var t2;
|
|
@@ -2721,7 +2782,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
2721
2782
|
r2 = JSON.parse(n2.dataset.box);
|
|
2722
2783
|
else {
|
|
2723
2784
|
let e2 = getComputedStyle(n2), i3 = getComputedStyle(t2);
|
|
2724
|
-
r2 = { padLeft:
|
|
2785
|
+
r2 = { padLeft: ae(i3.marginLeft) + ae(e2.borderLeftWidth) + ae(e2.paddingLeft), padRight: ae(i3.marginRight) + ae(e2.borderRightWidth) + ae(e2.paddingRight), padTop: ae(i3.marginTop) + ae(e2.borderTopWidth) + ae(e2.paddingTop), padBottom: ae(i3.marginBottom) + ae(e2.borderBottomWidth) + ae(e2.paddingBottom) }, n2.dataset.box = JSON.stringify(r2);
|
|
2725
2786
|
}
|
|
2726
2787
|
let a2 = s2.offsetWidth, l2 = s2.offsetHeight;
|
|
2727
2788
|
if (0 === a2) {
|
|
@@ -2730,7 +2791,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
2730
2791
|
}
|
|
2731
2792
|
const h2 = this.controller.getScaleMode(), c2 = l2 > a2 && h2 === e.ScaleMode.FitPageWidth ? 20 : 0, d2 = (this.pageContainer.clientWidth - c2 - r2.padLeft - r2.padRight) / a2, u2 = (this.pageContainer.clientHeight - 1 - r2.padTop - r2.padBottom) / l2;
|
|
2732
2793
|
let p2 = this.controller.getScale();
|
|
2733
|
-
h2 === e.ScaleMode.FitPageWidth ? p2 = d2 : p2 && h2 !== e.ScaleMode.FitPage || (p2 = Math.min(d2, u2)), null !== this.uiFreezeCoordinator && this.uiFreezeCoordinator.setScaleFactor(p2), t2.dataset.pageScale = p2.toString(), n2.dataset.pageScale = p2.toString(), o2 ||
|
|
2794
|
+
h2 === e.ScaleMode.FitPageWidth ? p2 = d2 : p2 && h2 !== e.ScaleMode.FitPage || (p2 = Math.min(d2, u2)), null !== this.uiFreezeCoordinator && this.uiFreezeCoordinator.setScaleFactor(p2), t2.dataset.pageScale = p2.toString(), n2.dataset.pageScale = p2.toString(), o2 || le(s2, p2, p2), n2.style.height = p2 * l2 + "px", n2.style.width = p2 * a2 + "px", this.controller.setScale(p2, true);
|
|
2734
2795
|
}
|
|
2735
2796
|
enableInteractivity() {
|
|
2736
2797
|
this.onClickHandler = this.onClick.bind(this), this.onMouseEnterHandler = this.onMouseEnter.bind(this), this.onMouseLeaveHandler = this.onMouseLeave.bind(this), this.pageContainer.addEventListener("click", this.onClickHandler), this.pageContainer.addEventListener("mouseenter", this.onMouseEnterHandler, true), this.pageContainer.addEventListener("mouseleave", this.onMouseLeaveHandler, true);
|
|
@@ -2753,24 +2814,24 @@ var telerikReportViewer = (function (exports) {
|
|
|
2753
2814
|
onInteractiveItemClick(e2, t2) {
|
|
2754
2815
|
var i2;
|
|
2755
2816
|
let n2 = (null === (i2 = e2.dataset.reportingAction) || void 0 === i2 ? void 0 : i2.toString()) || "", r2 = this.getAction(n2);
|
|
2756
|
-
r2 && (this.navigateToPageOnDocReady = this.getNavigateToPageOnDocReady(t2, r2.Type), this.controller.executeReportAction(new
|
|
2817
|
+
r2 && (this.navigateToPageOnDocReady = this.getNavigateToPageOnDocReady(t2, r2.Type), this.controller.executeReportAction(new l(e2, r2))), t2.stopPropagation();
|
|
2757
2818
|
}
|
|
2758
2819
|
onInteractiveItemEnter(e2) {
|
|
2759
2820
|
var t2;
|
|
2760
2821
|
let i2 = (null === (t2 = e2.dataset.reportingAction) || void 0 === t2 ? void 0 : t2.toString()) || "", n2 = this.getAction(i2);
|
|
2761
|
-
n2 && this.controller.reportActionEnter(new
|
|
2822
|
+
n2 && this.controller.reportActionEnter(new l(e2, n2));
|
|
2762
2823
|
}
|
|
2763
2824
|
onInteractiveItemLeave(e2) {
|
|
2764
2825
|
var t2;
|
|
2765
2826
|
let i2 = (null === (t2 = e2.dataset.reportingAction) || void 0 === t2 ? void 0 : t2.toString()) || "", n2 = this.getAction(i2);
|
|
2766
|
-
n2 && this.controller.reportActionLeave(new
|
|
2827
|
+
n2 && this.controller.reportActionLeave(new l(e2, n2));
|
|
2767
2828
|
}
|
|
2768
2829
|
onToolTipItemEnter(e2, t2) {
|
|
2769
2830
|
let i2 = e2.dataset.tooltipTitle, n2 = e2.dataset.tooltipText;
|
|
2770
|
-
(i2 || n2) && this.controller.reportTooltipOpening(new
|
|
2831
|
+
(i2 || n2) && this.controller.reportTooltipOpening(new f(e2, n2 || "", i2 || "", t2));
|
|
2771
2832
|
}
|
|
2772
2833
|
onToolTipItemLeave(e2) {
|
|
2773
|
-
this.controller.reportTooltipClosing(new
|
|
2834
|
+
this.controller.reportTooltipClosing(new f(e2, "", "", null));
|
|
2774
2835
|
}
|
|
2775
2836
|
getNavigateToPageOnDocReady(e2, t2) {
|
|
2776
2837
|
var i2;
|
|
@@ -2788,7 +2849,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
2788
2849
|
var t2;
|
|
2789
2850
|
let i2 = "trv-" + this.controller.getClientId() + "-styles";
|
|
2790
2851
|
null === (t2 = document.getElementById(i2)) || void 0 === t2 || t2.remove();
|
|
2791
|
-
let n2 =
|
|
2852
|
+
let n2 = ie("style", i2);
|
|
2792
2853
|
n2.innerHTML = e2.pageStyles, document.head.appendChild(n2);
|
|
2793
2854
|
}
|
|
2794
2855
|
setPageContent(e2) {
|
|
@@ -2800,26 +2861,26 @@ var telerikReportViewer = (function (exports) {
|
|
|
2800
2861
|
this.actions && this.actions.length ? this.actions = this.actions.concat(t2.pageActions) : this.actions = t2.pageActions, this.applyPlaceholderViewModeClass(), this.setPageDimensions(e2, t2.pageNumber);
|
|
2801
2862
|
}
|
|
2802
2863
|
renderPageElement(e2) {
|
|
2803
|
-
let t2 =
|
|
2864
|
+
let t2 = ie("div");
|
|
2804
2865
|
t2.innerHTML = e2.pageContent;
|
|
2805
2866
|
let i2 = t2.querySelector("div.sheet");
|
|
2806
2867
|
i2.style.margin = "0";
|
|
2807
|
-
let n2 =
|
|
2808
|
-
return n2.dataset.page = e2.pageNumber.toString(), n2.append(i2), n2.append(
|
|
2868
|
+
let n2 = ie("div", "", "trv-report-page");
|
|
2869
|
+
return n2.dataset.page = e2.pageNumber.toString(), n2.append(i2), n2.append(ie("div", "", "k-overlay trv-overlay trv-page-overlay")), n2;
|
|
2809
2870
|
}
|
|
2810
2871
|
applyPlaceholderViewModeClass() {
|
|
2811
|
-
this.controller.getViewMode() === e.ViewMode.Interactive ? (
|
|
2872
|
+
this.controller.getViewMode() === e.ViewMode.Interactive ? (re(this.placeholder, "printpreview"), ne(this.placeholder, "interactive")) : (re(this.placeholder, "interactive"), ne(this.placeholder, "printpreview"));
|
|
2812
2873
|
}
|
|
2813
2874
|
setPageAreaImage() {
|
|
2814
2875
|
this.clearPageAreaImage();
|
|
2815
|
-
let e2 =
|
|
2816
|
-
e2.innerHTML =
|
|
2876
|
+
let e2 = ie("style", je);
|
|
2877
|
+
e2.innerHTML = Je('.trv-page-container {background: #ffffff url("{0}") no-repeat center 50px}', [this.initialPageAreaImageUrl]), document.head.appendChild(e2), this.showPageAreaImage = true;
|
|
2817
2878
|
}
|
|
2818
2879
|
clearPageAreaImage() {
|
|
2819
2880
|
var e2;
|
|
2820
|
-
null === (e2 = document.getElementById(
|
|
2881
|
+
null === (e2 = document.getElementById(je)) || void 0 === e2 || e2.remove();
|
|
2821
2882
|
}
|
|
2822
|
-
}, e.DeviceInfo =
|
|
2883
|
+
}, e.CurrentPageChangedEventArgs = m, e.DeviceInfo = o, e.DocumentInfo = class {
|
|
2823
2884
|
constructor() {
|
|
2824
2885
|
this.documentReady = false, this.documentMapAvailable = false, this.containsFrozenContent = false, this.pageCount = 0, this.documentMapNodes = [], this.bookmarkNodes = [], this.renderingExtensions = [], this.autoRunEnabled = true;
|
|
2825
2886
|
}
|
|
@@ -2827,29 +2888,29 @@ var telerikReportViewer = (function (exports) {
|
|
|
2827
2888
|
constructor() {
|
|
2828
2889
|
this.id = "", this.isExpanded = false, this.label = "", this.text = "", this.page = 0, this.items = [];
|
|
2829
2890
|
}
|
|
2830
|
-
}, e.EmailInfo =
|
|
2891
|
+
}, e.EmailInfo = a, e.ExportDocumentReadyEventArgs = u, e.ExportStartEventArgs = c, e.ExportStartedEventArgs = d, e.KeepClientAliveSentinel = K, e.NoAuth = S, e.PageAction = class {
|
|
2831
2892
|
constructor() {
|
|
2832
2893
|
this.Id = "", this.ReportItemName = "", this.Type = "", this.Value = {};
|
|
2833
2894
|
}
|
|
2834
|
-
}, e.PageActionEventArgs =
|
|
2895
|
+
}, e.PageActionEventArgs = l, e.PageInfo = class {
|
|
2835
2896
|
constructor() {
|
|
2836
2897
|
this.pageNumber = 0, this.pageReady = false, this.pageStyles = "", this.pageContent = "", this.pageActions = [];
|
|
2837
2898
|
}
|
|
2838
|
-
}, e.PageTargetElement =
|
|
2899
|
+
}, e.PageTargetElement = h, e.ParameterInfo = class {
|
|
2839
2900
|
constructor() {
|
|
2840
2901
|
this.name = "", this.type = "", this.text = "", this.multivalue = false, this.allowNull = false, this.allowBlank = false, this.isVisible = false, this.autoRefresh = false, this.hasChildParameters = false, this.childParameters = [], this.availableValues = [], this.value = "", this.id = "", this.label = "";
|
|
2841
2902
|
}
|
|
2842
|
-
}, e.ParameterValidators =
|
|
2903
|
+
}, e.ParameterValidators = Ve, e.ParameterValue = class {
|
|
2843
2904
|
constructor() {
|
|
2844
2905
|
this.name = "", this.value = null;
|
|
2845
2906
|
}
|
|
2846
|
-
}, e.RenderingExtension = class {
|
|
2907
|
+
}, e.PersonalTokenAuth = b, e.PrintDocumentReadyEventArgs = g, e.PrintStartedEventArgs = p, e.RenderingExtension = class {
|
|
2847
2908
|
constructor() {
|
|
2848
2909
|
this.name = "", this.localizedName = "";
|
|
2849
2910
|
}
|
|
2850
|
-
}, e.ReportController = class extends
|
|
2911
|
+
}, e.ReportController = class extends H {
|
|
2851
2912
|
constructor(e2, t2) {
|
|
2852
|
-
super(), this.configurationInfo = null, this.keepClientAliveSentinel = null, this.registerClientPromise = null, this.registerInstancePromise = null, this.documentFormatsPromise = null, this.clientId = "", this.reportInstanceId = "", this.documentId = "", this.threadId = "", this.parameterValues = {}, this.bookmarkNodes = [], this.renderingExtensions = null, this.pageCount = 0, this.currentPageNumber = 0, this.clientHasExpired = false, this.cancelLoad = false, this.searchInitiated = false, this.aiPromptInitiated = false, this.contentTabIndex = 0, this.respectAutoRun = true, this.processedParameterValues = {}, this.options = t2, t2.reportSource && this.setParameters(t2.reportSource.parameters), this.printManager = new
|
|
2913
|
+
super(), this.configurationInfo = null, this.keepClientAliveSentinel = null, this.registerClientPromise = null, this.registerInstancePromise = null, this.documentFormatsPromise = null, this.clientId = "", this.reportInstanceId = "", this.documentId = "", this.threadId = "", this.parameterValues = {}, this.bookmarkNodes = [], this.renderingExtensions = null, this.pageCount = 0, this.currentPageNumber = 0, this.clientHasExpired = false, this.cancelLoad = false, this.searchInitiated = false, this.aiPromptInitiated = false, this.contentTabIndex = 0, this.respectAutoRun = true, this.processedParameterValues = {}, this.options = t2, t2.reportSource && this.setParameters(t2.reportSource.parameters), this.printManager = new G(), this.serviceClient = e2, t2.authenticationToken && this.serviceClient.setAccessToken(t2.authenticationToken);
|
|
2853
2914
|
}
|
|
2854
2915
|
get autoRunEnabled() {
|
|
2855
2916
|
var e2 = !this.parameterValues || !("trv_AutoRun" in this.parameterValues) || this.parameterValues.trv_AutoRun;
|
|
@@ -2892,7 +2953,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
2892
2953
|
let n2 = {}, r2 = [], s2 = false;
|
|
2893
2954
|
for (let t3 of e2)
|
|
2894
2955
|
try {
|
|
2895
|
-
let e3 =
|
|
2956
|
+
let e3 = Ve.validate(t3, t3.value);
|
|
2896
2957
|
n2[t3.id] = e3;
|
|
2897
2958
|
} catch (e3) {
|
|
2898
2959
|
s2 = true, r2.push(t3);
|
|
@@ -2902,7 +2963,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
2902
2963
|
hasInvalidParameter(e2) {
|
|
2903
2964
|
for (const t2 of e2)
|
|
2904
2965
|
try {
|
|
2905
|
-
|
|
2966
|
+
Ve.validate(t2, t2.value);
|
|
2906
2967
|
} catch (e3) {
|
|
2907
2968
|
return true;
|
|
2908
2969
|
}
|
|
@@ -2934,7 +2995,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
2934
2995
|
}
|
|
2935
2996
|
getReportSource() {
|
|
2936
2997
|
var e2;
|
|
2937
|
-
return new
|
|
2998
|
+
return new Ue(null === (e2 = this.options.reportSource) || void 0 === e2 ? void 0 : e2.report, this.parameterValues);
|
|
2938
2999
|
}
|
|
2939
3000
|
setReportSource(e2) {
|
|
2940
3001
|
this.options.reportSource = e2, this.setParameters(this.options.reportSource.parameters), this.emit("reportSourceChanged", e2);
|
|
@@ -2979,7 +3040,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
2979
3040
|
return this.currentPageNumber;
|
|
2980
3041
|
}
|
|
2981
3042
|
setCurrentPageNumber(e2) {
|
|
2982
|
-
this.currentPageNumber !== e2 && (this.currentPageNumber = e2, this.emit("currentPageChanged", e2));
|
|
3043
|
+
this.currentPageNumber !== e2 && (this.currentPageNumber = e2, this.emit("currentPageChanged", new m(e2, this.documentId)));
|
|
2983
3044
|
}
|
|
2984
3045
|
getPageCount() {
|
|
2985
3046
|
return this.pageCount;
|
|
@@ -2994,9 +3055,9 @@ var telerikReportViewer = (function (exports) {
|
|
|
2994
3055
|
if ("navigateToReport" === t2.Type) {
|
|
2995
3056
|
this.emit("serverActionStarted");
|
|
2996
3057
|
let e3 = t2.Value, i2 = this.fixDataContractJsonSerializer(e3.ParameterValues);
|
|
2997
|
-
this.respectAutoRun = true, this.emit("navigateToReport",
|
|
3058
|
+
this.respectAutoRun = true, this.emit("navigateToReport", new Ue(e3.Report, i2));
|
|
2998
3059
|
} else if ("navigateToBookmark" === t2.Type) {
|
|
2999
|
-
let e3 = this.getPageForBookmark(this.bookmarkNodes, t2.Value), i2 = new
|
|
3060
|
+
let e3 = this.getPageForBookmark(this.bookmarkNodes, t2.Value), i2 = new h(t2.Value, "bookmark");
|
|
3000
3061
|
this.navigateToPage(e3, i2);
|
|
3001
3062
|
} else if ("sorting" === t2.Type)
|
|
3002
3063
|
this.execServerAction(t2.Id);
|
|
@@ -3022,40 +3083,40 @@ var telerikReportViewer = (function (exports) {
|
|
|
3022
3083
|
this.emit("toolTipClosing", e2);
|
|
3023
3084
|
}
|
|
3024
3085
|
printReport() {
|
|
3025
|
-
return
|
|
3086
|
+
return s(this, void 0, void 0, function* () {
|
|
3026
3087
|
let e2 = this.createDeviceInfo();
|
|
3027
3088
|
e2.ImmediatePrint = true;
|
|
3028
|
-
let t2 = new
|
|
3089
|
+
let t2 = new p(e2);
|
|
3029
3090
|
this.emit("printStarted", t2), t2.handled || (this.setUIState("PrintInProgress", true), this.exportAsync("PDF", e2).then((e3) => {
|
|
3030
3091
|
let t3 = this.serviceClient.getDocumentUrl(this.clientId, this.reportInstanceId, e3);
|
|
3031
3092
|
t3 += `?${"response-content-disposition=" + (this.getCanUsePlugin() ? "inline" : "attachment")}`;
|
|
3032
|
-
let i2 = new
|
|
3093
|
+
let i2 = new g(t3);
|
|
3033
3094
|
this.emit("printDocumentReady", i2), this.setUIState("PrintInProgress", false), i2.handled || this.printManager.print(t3);
|
|
3034
3095
|
}));
|
|
3035
3096
|
});
|
|
3036
3097
|
}
|
|
3037
3098
|
exportReport(e2) {
|
|
3038
|
-
return
|
|
3039
|
-
let t2 = this.createDeviceInfo(), i2 = new
|
|
3099
|
+
return s(this, void 0, void 0, function* () {
|
|
3100
|
+
let t2 = this.createDeviceInfo(), i2 = new c(t2, e2);
|
|
3040
3101
|
if (yield this.emitAsync("exportStart", i2), !i2.isCancelled) {
|
|
3041
|
-
let n2 = new
|
|
3102
|
+
let n2 = new d(t2, e2);
|
|
3042
3103
|
if (this.emit("exportStarted", n2), n2.handled)
|
|
3043
3104
|
return;
|
|
3044
|
-
this.setUIState("ExportInProgress", true), this.exportAsync(e2, i2.deviceInfo).then((t3) =>
|
|
3105
|
+
this.setUIState("ExportInProgress", true), this.exportAsync(e2, i2.deviceInfo).then((t3) => s(this, void 0, void 0, function* () {
|
|
3045
3106
|
let i3 = this.serviceClient.getDocumentUrl(this.clientId, this.reportInstanceId, t3);
|
|
3046
3107
|
i3 += "?response-content-disposition=attachment";
|
|
3047
|
-
let n3 = new
|
|
3108
|
+
let n3 = new u(i3, e2, "_self");
|
|
3048
3109
|
yield this.emitAsync("exportEnd", n3), this.emit("exportDocumentReady", n3), this.setUIState("ExportInProgress", false), n3.handled || window.open(i3, n3.windowOpenTarget);
|
|
3049
3110
|
}));
|
|
3050
3111
|
}
|
|
3051
3112
|
});
|
|
3052
3113
|
}
|
|
3053
3114
|
sendReport(e2) {
|
|
3054
|
-
let t2 = this.createDeviceInfo(), i2 = new
|
|
3115
|
+
let t2 = this.createDeviceInfo(), i2 = new xe(t2, e2.format);
|
|
3055
3116
|
this.emit("sendEmailStarted", i2), i2.handled || this.exportAsync(e2.format, t2).then((i3) => {
|
|
3056
3117
|
let n2 = this.serviceClient.getDocumentUrl(this.clientId, this.reportInstanceId, i3);
|
|
3057
3118
|
n2 += "?response-content-disposition=attachment";
|
|
3058
|
-
let r2 = new
|
|
3119
|
+
let r2 = new ke(e2, t2, n2);
|
|
3059
3120
|
this.emit("sendEmailDocumentReady", r2), r2.handled || this.sendDocumentAsync(i3, e2);
|
|
3060
3121
|
});
|
|
3061
3122
|
}
|
|
@@ -3064,9 +3125,9 @@ var telerikReportViewer = (function (exports) {
|
|
|
3064
3125
|
}
|
|
3065
3126
|
createAIThread() {
|
|
3066
3127
|
return this.serviceClient.createAIThread(this.clientId, this.reportInstanceId, this.getReport(), this.parameterValues).catch((e2) => this.raiseError(e2.exceptionMessage, false)).then((e2) => {
|
|
3067
|
-
if (this.threadId = (null == e2 ? void 0 : e2.threadId) || "", e2.consentMessage && (e2.consentMessage =
|
|
3128
|
+
if (this.threadId = (null == e2 ? void 0 : e2.threadId) || "", e2.consentMessage && (e2.consentMessage = r.default.sanitize(e2.consentMessage, { USE_PROFILES: { html: true } }), r.default.removed && r.default.removed.length > 0 && console.warn("The AI-Powered Insights consent message was sanitized as it contained potentially malicious HTML elements or attributes.")), e2.predefinedPrompts)
|
|
3068
3129
|
for (let t2 = 0; t2 < e2.predefinedPrompts.length; t2++)
|
|
3069
|
-
e2.predefinedPrompts[t2] =
|
|
3130
|
+
e2.predefinedPrompts[t2] = r.default.sanitize(e2.predefinedPrompts[t2], { USE_PROFILES: { html: true } }), r.default.removed && r.default.removed.length > 0 && console.warn("An AI-Powered Insights predefined prompt was sanitized as it contained potentially malicious HTML elements or attributes.");
|
|
3070
3131
|
return e2;
|
|
3071
3132
|
});
|
|
3072
3133
|
}
|
|
@@ -3074,13 +3135,13 @@ var telerikReportViewer = (function (exports) {
|
|
|
3074
3135
|
return this.serviceClient.getAIResponse(this.clientId, this.reportInstanceId, this.documentId, this.threadId, e2).then((e3) => e3 || "");
|
|
3075
3136
|
}
|
|
3076
3137
|
exportAsync(e2, t2) {
|
|
3077
|
-
return this.initializeClient().then(this.registerInstance.bind(this)).then(() => this.registerDocumentAsync(e2, t2, false, this.documentId)).then((e3) =>
|
|
3138
|
+
return this.initializeClient().then(this.registerInstance.bind(this)).then(() => this.registerDocumentAsync(e2, t2, false, this.documentId)).then((e3) => s(this, void 0, void 0, function* () {
|
|
3078
3139
|
return yield this.getDocumentInfo(false, e3).catch((e4) => this.raiseError(e4)), e3;
|
|
3079
3140
|
}));
|
|
3080
3141
|
}
|
|
3081
3142
|
sendDocumentAsync(e2, t2) {
|
|
3082
3143
|
return this.serviceClient.sendDocument(this.clientId, this.reportInstanceId, e2, t2).catch((e3) => {
|
|
3083
|
-
this.handleRequestError(e3,
|
|
3144
|
+
this.handleRequestError(e3, we(this.options.messages.ReportViewer_ErrorSendingDocument, he(this.getReport())));
|
|
3084
3145
|
});
|
|
3085
3146
|
}
|
|
3086
3147
|
loadParameters(e2 = void 0) {
|
|
@@ -3093,7 +3154,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
3093
3154
|
}
|
|
3094
3155
|
initializeAndStartSentinel() {
|
|
3095
3156
|
this.options.keepClientAlive && this.clientId && this.serviceClient.getClientsSessionTimeoutSeconds().then((e2) => {
|
|
3096
|
-
this.keepClientAliveSentinel = new
|
|
3157
|
+
this.keepClientAliveSentinel = new K(this.serviceClient, this.clientId, e2), this.keepClientAliveSentinel.start();
|
|
3097
3158
|
});
|
|
3098
3159
|
}
|
|
3099
3160
|
stopSentinel() {
|
|
@@ -3118,7 +3179,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
3118
3179
|
this.pageCount = 0, this.currentPageNumber = 0;
|
|
3119
3180
|
}
|
|
3120
3181
|
handleSearchRequestError(e2) {
|
|
3121
|
-
if (!
|
|
3182
|
+
if (!ye(e2, "System.ArgumentException"))
|
|
3122
3183
|
throw this.handleRequestError(e2, "", true), null;
|
|
3123
3184
|
this.throwPromiseError(e2);
|
|
3124
3185
|
}
|
|
@@ -3126,21 +3187,23 @@ var telerikReportViewer = (function (exports) {
|
|
|
3126
3187
|
throw e2.exceptionMessage ? e2.exceptionMessage : this.options.messages.ReportViewer_PromisesChainStopError;
|
|
3127
3188
|
}
|
|
3128
3189
|
handleRequestError(e2, t2 = "", i2 = false) {
|
|
3129
|
-
|
|
3130
|
-
let n2 =
|
|
3190
|
+
Se(e2) && this.onClientExpired();
|
|
3191
|
+
let n2 = be(e2.error) ? "" : e2.error, r2 = this.formatRequestError(e2, n2, t2);
|
|
3131
3192
|
this.raiseError(r2), i2 || this.throwPromiseError(e2);
|
|
3132
3193
|
}
|
|
3133
3194
|
formatRequestError(e2, t2, i2) {
|
|
3134
3195
|
let n2 = e2.responseJSON, r2 = "";
|
|
3135
3196
|
if (n2) {
|
|
3136
|
-
if (
|
|
3197
|
+
if (401 == n2.status || 403 == n2.status)
|
|
3198
|
+
return this.options.messages.ReportViewer_ErrorUnauthorizedOrForbidden || "You don't have permission to access this report document.";
|
|
3199
|
+
if (Ie(e2))
|
|
3137
3200
|
return this.options.messages.ReportViewer_MissingOrInvalidParameter;
|
|
3138
|
-
r2 =
|
|
3139
|
-
let t3 =
|
|
3201
|
+
r2 = he(n2.message);
|
|
3202
|
+
let t3 = he(n2.exceptionMessage || n2.ExceptionMessage || n2.error_description);
|
|
3140
3203
|
t3 && (r2 ? r2 += " " + t3 : r2 = t3);
|
|
3141
3204
|
} else
|
|
3142
|
-
r2 =
|
|
3143
|
-
return (i2 || t2) && (r2 && (r2 = " " + r2), r2 =
|
|
3205
|
+
r2 = he(e2.responseText);
|
|
3206
|
+
return (i2 || t2) && (r2 && (r2 = " " + r2), r2 = he(i2 || t2) + r2), Se(e2) && (r2 += "<br />" + this.options.messages.ReportViewer_ClientExpired), r2;
|
|
3144
3207
|
}
|
|
3145
3208
|
raiseError(e2, t2 = true) {
|
|
3146
3209
|
this.emit("error", e2, t2);
|
|
@@ -3150,17 +3213,17 @@ var telerikReportViewer = (function (exports) {
|
|
|
3150
3213
|
}
|
|
3151
3214
|
initializeClient() {
|
|
3152
3215
|
return this.registerClientPromise || (this.registerClientPromise = this.serviceClient.registerClient().catch((e2) => {
|
|
3153
|
-
const t2 =
|
|
3216
|
+
const t2 = we(this.options.messages.ReportViewer_ErrorServiceUrl, [this.serviceClient.getServiceUrl()]);
|
|
3154
3217
|
this.handleRequestError(e2, t2);
|
|
3155
3218
|
}).then(this.setClientId.bind(this)).catch(this.clearClientId.bind(this))), this.registerClientPromise;
|
|
3156
3219
|
}
|
|
3157
3220
|
registerInstance() {
|
|
3158
3221
|
return this.registerInstancePromise || (this.registerInstancePromise = this.serviceClient.createReportInstance(this.clientId, this.getReport(), this.parameterValues).then(this.setReportInstanceId.bind(this)).catch(this.clearReportInstanceId.bind(this))), this.registerInstancePromise;
|
|
3159
3222
|
}
|
|
3160
|
-
registerDocumentAsync(e2, t2, i2, n2 = "",
|
|
3161
|
-
return
|
|
3162
|
-
return (yield this.serviceClient.createReportDocument(this.clientId, this.reportInstanceId, e2, t2, !i2, n2,
|
|
3163
|
-
this.handleRequestError(t3,
|
|
3223
|
+
registerDocumentAsync(e2, t2, i2, n2 = "", r2 = "") {
|
|
3224
|
+
return s(this, void 0, void 0, function* () {
|
|
3225
|
+
return (yield this.serviceClient.createReportDocument(this.clientId, this.reportInstanceId, e2, t2, !i2, n2, r2).catch((t3) => {
|
|
3226
|
+
this.handleRequestError(t3, we(this.options.messages.ReportViewer_ErrorCreatingReportDocument, he(this.getReport()), he(e2)));
|
|
3164
3227
|
})) || "";
|
|
3165
3228
|
});
|
|
3166
3229
|
}
|
|
@@ -3182,7 +3245,7 @@ var telerikReportViewer = (function (exports) {
|
|
|
3182
3245
|
return e2.ContentOnly = true, e2.UseSVG = true, e2;
|
|
3183
3246
|
}
|
|
3184
3247
|
createDeviceInfo() {
|
|
3185
|
-
let e2 = new
|
|
3248
|
+
let e2 = new o();
|
|
3186
3249
|
this.options.enableAccessibility && (e2.enableAccessibility = true, e2.contentTabIndex = this.getContentTabIndex());
|
|
3187
3250
|
let t2 = this.getSearchInitiated(), i2 = this.options.searchMetadataOnDemand;
|
|
3188
3251
|
return e2.enableSearch = !i2 || t2, e2;
|
|
@@ -3193,10 +3256,12 @@ var telerikReportViewer = (function (exports) {
|
|
|
3193
3256
|
});
|
|
3194
3257
|
}
|
|
3195
3258
|
getReportParameters() {
|
|
3259
|
+
if (!this.parameterValues)
|
|
3260
|
+
return {};
|
|
3196
3261
|
const e2 = {}, t2 = this.getProcessedParameterValues();
|
|
3197
3262
|
for (let i2 in t2) {
|
|
3198
3263
|
const n2 = t2[i2], r2 = this.parameterValues[i2];
|
|
3199
|
-
n2 && n2.availableValues ? n2.multivalue ? e2[i2] =
|
|
3264
|
+
n2 && n2.availableValues ? n2.multivalue ? e2[i2] = _e(n2, r2, i2) : e2[i2] = ze(n2, r2, i2) : e2[i2] = r2;
|
|
3200
3265
|
}
|
|
3201
3266
|
return e2;
|
|
3202
3267
|
}
|
|
@@ -3207,9 +3272,9 @@ var telerikReportViewer = (function (exports) {
|
|
|
3207
3272
|
return this.processedParameterValues;
|
|
3208
3273
|
}
|
|
3209
3274
|
getDocumentInfo(t2, i2) {
|
|
3210
|
-
return t2 && this.emit("beginLoadReport"), new Promise((n2,
|
|
3211
|
-
let o2 = () =>
|
|
3212
|
-
this.cancelLoad ?
|
|
3275
|
+
return t2 && this.emit("beginLoadReport"), new Promise((n2, r2) => {
|
|
3276
|
+
let o2 = () => s(this, void 0, void 0, function* () {
|
|
3277
|
+
this.cancelLoad ? r2(this.options.messages.ReportViewer_RenderingCancelled) : (yield this.registerInstancePromise, this.serviceClient.getDocumentInfo(this.clientId, this.reportInstanceId, i2).then((i3) => {
|
|
3213
3278
|
i3 && i3.documentReady ? n2(i3) : (t2 && (this.getPageMode() === e.PageMode.ContinuousScroll && i3.pageCount > this.pageCount && this.emit("pageLoaded"), this.pageCount = i3.pageCount, this.emit("reportLoadProgress", i3)), window.setTimeout(o2, 500));
|
|
3214
3279
|
}).catch((e2) => {
|
|
3215
3280
|
"InvalidDocumentException" !== e2.responseJSON.exceptionType ? this.handleRequestError(e2, "", true) : console.warn("getDocumentInfo failed or was canceled by the user: " + e2.exceptionMessage);
|
|
@@ -3334,13 +3399,17 @@ ${e3.text} (${e3.id})`;
|
|
|
3334
3399
|
constructor(e2, t2, i2) {
|
|
3335
3400
|
this.url = e2, this.username = t2, this.password = i2;
|
|
3336
3401
|
}
|
|
3337
|
-
}, e.
|
|
3402
|
+
}, e.ReportServerTokenSettings = class {
|
|
3403
|
+
constructor(e2, t2) {
|
|
3404
|
+
this.url = e2, this.getPersonalAccessToken = t2;
|
|
3405
|
+
}
|
|
3406
|
+
}, e.ReportSourceOptions = Ue, e.RequestError = v, e.SearchInfo = class {
|
|
3338
3407
|
constructor() {
|
|
3339
3408
|
this.searchToken = "", this.matchCase = false, this.matchWholeWord = false, this.useRegularExpressions = false;
|
|
3340
3409
|
}
|
|
3341
|
-
}, e.SearchManager = class extends
|
|
3410
|
+
}, e.SearchManager = class extends H {
|
|
3342
3411
|
constructor(e2, t2) {
|
|
3343
|
-
super(), this.searchResults = [], this.pendingHighlightItem = null, this.highlightedElements = [], this.currentHighlightedElement = null, this.isActive = false, this.controller = t2, this.pageContainer =
|
|
3412
|
+
super(), this.searchResults = [], this.pendingHighlightItem = null, this.highlightedElements = [], this.currentHighlightedElement = null, this.isActive = false, this.controller = t2, this.pageContainer = me(e2, ".trv-page-container"), this.controller.on("applySearchColors", this.applySearchColors.bind(this)).on("pageReady", this.applySearchColors.bind(this));
|
|
3344
3413
|
}
|
|
3345
3414
|
search(e2) {
|
|
3346
3415
|
this.isActive = true, this.clearColoredItems(), this.searchResults = [], e2.searchToken && "" !== e2.searchToken ? this.controller.getSearchResults(e2).then(this.onSearchComplete.bind(this)) : this.onSearchComplete([]);
|
|
@@ -3349,15 +3418,15 @@ ${e3.text} (${e3.id})`;
|
|
|
3349
3418
|
this.isActive = false, this.clearColoredItems(), this.searchResults = [];
|
|
3350
3419
|
}
|
|
3351
3420
|
highlightSearchItem(t2) {
|
|
3352
|
-
t2 && (this.currentHighlightedElement && (
|
|
3421
|
+
t2 && (this.currentHighlightedElement && (re(this.currentHighlightedElement, Ze), ne(this.currentHighlightedElement, Ge)), t2.page === this.controller.getCurrentPageNumber() ? this.highlightItem(t2) : this.controller.getPageMode() === e.PageMode.SinglePage ? this.clearColoredItems() : this.highlightItem(t2), this.pendingHighlightItem = t2, this.navigateToPage(t2));
|
|
3353
3422
|
}
|
|
3354
3423
|
navigateToPage(e2) {
|
|
3355
|
-
this.controller.navigateToPage(e2.page, new
|
|
3424
|
+
this.controller.navigateToPage(e2.page, new h(e2.id, "search"));
|
|
3356
3425
|
}
|
|
3357
3426
|
colorPageElements(e2) {
|
|
3358
3427
|
e2 && 0 !== e2.length && (e2.forEach((e3) => {
|
|
3359
|
-
let t2 =
|
|
3360
|
-
t2 && (
|
|
3428
|
+
let t2 = me(this.pageContainer, "[data-search-id=" + e3.id + "]");
|
|
3429
|
+
t2 && (ne(t2, Ge), this.highlightedElements.push(t2));
|
|
3361
3430
|
}), this.highlightItem(this.pendingHighlightItem));
|
|
3362
3431
|
}
|
|
3363
3432
|
highlightItem(e2) {
|
|
@@ -3365,13 +3434,13 @@ ${e3.text} (${e3.id})`;
|
|
|
3365
3434
|
let t2 = this.highlightedElements.find(function(t3) {
|
|
3366
3435
|
return t3.dataset.searchId === e2.id;
|
|
3367
3436
|
});
|
|
3368
|
-
t2 && (this.currentHighlightedElement = t2,
|
|
3437
|
+
t2 && (this.currentHighlightedElement = t2, re(t2, Ge), ne(t2, Ze));
|
|
3369
3438
|
}
|
|
3370
3439
|
}
|
|
3371
3440
|
clearColoredItems() {
|
|
3372
3441
|
this.highlightedElements && this.highlightedElements.length > 0 && this.highlightedElements.forEach((e2) => {
|
|
3373
|
-
|
|
3374
|
-
}), this.currentHighlightedElement &&
|
|
3442
|
+
re(e2, Ge);
|
|
3443
|
+
}), this.currentHighlightedElement && re(this.currentHighlightedElement, Ze), this.highlightedElements = [], this.currentHighlightedElement = null;
|
|
3375
3444
|
}
|
|
3376
3445
|
applySearchColors() {
|
|
3377
3446
|
this.isActive && this.colorPageElements(this.searchResults);
|
|
@@ -3385,137 +3454,130 @@ ${e3.text} (${e3.id})`;
|
|
|
3385
3454
|
}
|
|
3386
3455
|
}, e.ServiceClient = class {
|
|
3387
3456
|
constructor(e2) {
|
|
3388
|
-
this.
|
|
3457
|
+
this.connectionConfig = this.getConnectionConfig(e2), this.authStrategy = this.getAuthStrategy(this.connectionConfig);
|
|
3458
|
+
}
|
|
3459
|
+
getConnectionConfig(e2) {
|
|
3460
|
+
return e2.reportServer && e2.reportServer.url && e2.reportServer.username && e2.reportServer.password ? new R(e2.reportServer.url, e2.reportServer.username, e2.reportServer.password) : e2.reportServer && e2.reportServer.url && e2.reportServer.getPersonalAccessToken ? new E(e2.reportServer.url, e2.reportServer.getPersonalAccessToken) : e2.reportServer && e2.reportServer.url ? new A(e2.reportServer.url) : e2.serverPreview && e2.serverShareToken ? new E("", () => Promise.resolve(e2.serverShareToken)) : new T(e2.serviceUrl);
|
|
3461
|
+
}
|
|
3462
|
+
getAuthStrategy(t2) {
|
|
3463
|
+
switch (t2.authType) {
|
|
3464
|
+
case e.AuthType.None:
|
|
3465
|
+
return new S();
|
|
3466
|
+
case e.AuthType.Basic:
|
|
3467
|
+
return new I(t2);
|
|
3468
|
+
case e.AuthType.PersonalToken:
|
|
3469
|
+
return new b(t2);
|
|
3470
|
+
default:
|
|
3471
|
+
return new S();
|
|
3472
|
+
}
|
|
3389
3473
|
}
|
|
3390
3474
|
validateClientID(e2) {
|
|
3391
3475
|
if (!e2)
|
|
3392
3476
|
throw "Invalid ClientId";
|
|
3393
3477
|
}
|
|
3394
3478
|
authenticatedGet(e2) {
|
|
3395
|
-
return this.login().then(
|
|
3396
|
-
return
|
|
3397
|
-
|
|
3398
|
-
}(e2, t2);
|
|
3399
|
-
});
|
|
3479
|
+
return this.login().then((t2) => (null == t2 ? void 0 : t2.expiresAt) < Date.now() ? (this.loginPromise = this.authStrategy.authenticatePromise(true, t2.refreshToken), this.authenticatedGet(e2)) : function(e3, t3) {
|
|
3480
|
+
return fetch(e3, { headers: P(t3) }).then(C);
|
|
3481
|
+
}(e2, t2.access_token || t2.accessToken));
|
|
3400
3482
|
}
|
|
3401
3483
|
authenticatedPost(e2, t2) {
|
|
3402
|
-
return this.login().then(
|
|
3403
|
-
return g(e2, t2, i2);
|
|
3404
|
-
});
|
|
3484
|
+
return this.login().then((i2) => (null == i2 ? void 0 : i2.expiresAt) < Date.now() ? (this.loginPromise = this.authStrategy.authenticatePromise(true, i2.refreshToken), this.authenticatedPost(e2, t2)) : y(e2, t2, i2.access_token || i2.accessToken));
|
|
3405
3485
|
}
|
|
3406
3486
|
authenticatedDelete(e2) {
|
|
3407
|
-
return this.login().then(
|
|
3408
|
-
return
|
|
3409
|
-
|
|
3410
|
-
}(e2, t2);
|
|
3411
|
-
});
|
|
3487
|
+
return this.login().then((t2) => t2.expiresAt < Date.now() ? (this.loginPromise = this.authStrategy.authenticatePromise(true, t2.refreshToken), this.authenticatedDelete(e2)) : function(e3, t3) {
|
|
3488
|
+
return fetch(e3, { method: "DELETE", headers: P(t3) }).then(C);
|
|
3489
|
+
}(e2, t2.access_token || t2.accessToken));
|
|
3412
3490
|
}
|
|
3413
3491
|
login() {
|
|
3414
|
-
return this.loginPromise || (this.loginPromise = this.
|
|
3415
|
-
}
|
|
3416
|
-
createLoginPromise() {
|
|
3417
|
-
let e2 = this.options.loginInfo;
|
|
3418
|
-
if (e2 && e2.url && (e2.username || e2.password)) {
|
|
3419
|
-
let t2 = `grant_type=password&username=${encodeURIComponent((null == e2 ? void 0 : e2.username) || "")}&password=${encodeURIComponent((null == e2 ? void 0 : e2.password) || "")}`;
|
|
3420
|
-
return g(e2.url, t2, "", true).then((e3) => e3.access_token);
|
|
3421
|
-
}
|
|
3422
|
-
return Promise.resolve("");
|
|
3492
|
+
return this.loginPromise || (this.loginPromise = this.authStrategy.authenticatePromise(false, null)), this.loginPromise;
|
|
3423
3493
|
}
|
|
3424
3494
|
get(e2) {
|
|
3425
3495
|
return fetch(e2).then((e3) => e3.text());
|
|
3426
3496
|
}
|
|
3427
3497
|
setAccessToken(e2) {
|
|
3428
|
-
this.loginPromise = Promise.resolve(e2);
|
|
3498
|
+
this.loginPromise = Promise.resolve({ accessToken: e2 });
|
|
3429
3499
|
}
|
|
3430
3500
|
registerClient() {
|
|
3431
|
-
return this.authenticatedPost(`${this.
|
|
3501
|
+
return this.authenticatedPost(`${this.connectionConfig.serviceUrl}/clients`, { timeStamp: Date.now() }).then((e2) => e2.clientId);
|
|
3432
3502
|
}
|
|
3433
3503
|
unregisterClient(e2) {
|
|
3434
|
-
return this.validateClientID(e2), this.authenticatedDelete(`${this.
|
|
3504
|
+
return this.validateClientID(e2), this.authenticatedDelete(`${this.connectionConfig.serviceUrl}/clients/${e2}`);
|
|
3435
3505
|
}
|
|
3436
3506
|
getParameters(e2, t2, i2) {
|
|
3437
|
-
return this.validateClientID(e2), this.authenticatedPost(`${this.
|
|
3507
|
+
return this.validateClientID(e2), this.authenticatedPost(`${this.connectionConfig.serviceUrl}/clients/${e2}/parameters`, { report: t2, parameterValues: i2 || {} }).then((e3) => e3);
|
|
3438
3508
|
}
|
|
3439
3509
|
createReportInstance(e2, t2, i2) {
|
|
3440
|
-
return this.validateClientID(e2), this.authenticatedPost(`${this.
|
|
3510
|
+
return this.validateClientID(e2), this.authenticatedPost(`${this.connectionConfig.serviceUrl}/clients/${e2}/instances`, { report: t2, parameterValues: i2 }).then((e3) => e3.instanceId);
|
|
3441
3511
|
}
|
|
3442
3512
|
deleteReportInstance(e2, t2) {
|
|
3443
|
-
return this.validateClientID(e2), this.authenticatedDelete(`${this.
|
|
3513
|
+
return this.validateClientID(e2), this.authenticatedDelete(`${this.connectionConfig.serviceUrl}/clients/${e2}/instances/${t2}`);
|
|
3444
3514
|
}
|
|
3445
3515
|
createReportDocument(e2, t2, i2, n2, r2, s2, o2) {
|
|
3446
|
-
return this.validateClientID(e2), n2.BasePath = this.
|
|
3516
|
+
return this.validateClientID(e2), n2.BasePath = this.connectionConfig.serviceUrl, this.authenticatedPost(`${this.connectionConfig.serviceUrl}/clients/${e2}/instances/${t2}/documents`, { format: i2, deviceInfo: n2, useCache: r2, baseDocumentID: s2, actionID: o2 }).then((e3) => e3.documentId);
|
|
3447
3517
|
}
|
|
3448
3518
|
sendDocument(e2, t2, i2, n2) {
|
|
3449
|
-
return this.validateClientID(e2), this.authenticatedPost(`${this.
|
|
3519
|
+
return this.validateClientID(e2), this.authenticatedPost(`${this.connectionConfig.serviceUrl}/clients/${e2}/instances/${t2}/documents/${i2}/send`, n2);
|
|
3450
3520
|
}
|
|
3451
3521
|
deleteReportDocument(e2, t2, i2) {
|
|
3452
|
-
return this.validateClientID(e2), this.authenticatedDelete(`${this.
|
|
3522
|
+
return this.validateClientID(e2), this.authenticatedDelete(`${this.connectionConfig.serviceUrl}/clients/${e2}/instances/${t2}/documents/${i2}`);
|
|
3453
3523
|
}
|
|
3454
3524
|
getDocumentUrl(e2, t2, i2) {
|
|
3455
|
-
return `${this.
|
|
3525
|
+
return `${this.connectionConfig.serviceUrl}/clients/${e2}/instances/${t2}/documents/${i2}`;
|
|
3456
3526
|
}
|
|
3457
3527
|
getDocumentInfo(e2, t2, i2) {
|
|
3458
|
-
return this.validateClientID(e2), this.authenticatedGet(`${this.
|
|
3528
|
+
return this.validateClientID(e2), this.authenticatedGet(`${this.connectionConfig.serviceUrl}/clients/${e2}/instances/${t2}/documents/${i2}/info`).then((e3) => e3);
|
|
3459
3529
|
}
|
|
3460
3530
|
getPage(e2, t2, i2, n2) {
|
|
3461
|
-
return this.validateClientID(e2), this.authenticatedGet(`${this.
|
|
3531
|
+
return this.validateClientID(e2), this.authenticatedGet(`${this.connectionConfig.serviceUrl}/clients/${e2}/instances/${t2}/documents/${i2}/pages/${n2}`).then((e3) => {
|
|
3462
3532
|
let t3 = e3;
|
|
3463
3533
|
return t3.pageActions = JSON.parse(e3.pageActions), t3;
|
|
3464
3534
|
});
|
|
3465
3535
|
}
|
|
3466
3536
|
getDocumentFormats() {
|
|
3467
|
-
return this.authenticatedGet(`${this.
|
|
3537
|
+
return this.authenticatedGet(`${this.connectionConfig.serviceUrl}/formats`).then((e2) => e2 || []);
|
|
3468
3538
|
}
|
|
3469
3539
|
getServiceVersion() {
|
|
3470
|
-
return this.authenticatedGet(`${this.
|
|
3540
|
+
return this.authenticatedGet(`${this.connectionConfig.serviceUrl}/version`).then((e2) => e2.toString());
|
|
3471
3541
|
}
|
|
3472
3542
|
getServiceConfiguration() {
|
|
3473
|
-
return this.authenticatedGet(`${this.
|
|
3543
|
+
return this.authenticatedGet(`${this.connectionConfig.serviceUrl}/configuration`).then((e2) => e2);
|
|
3474
3544
|
}
|
|
3475
3545
|
getResource(e2, t2, i2, n2) {
|
|
3476
|
-
return this.validateClientID(e2), this.authenticatedGet(`${this.
|
|
3546
|
+
return this.validateClientID(e2), this.authenticatedGet(`${this.connectionConfig.serviceUrl}/clients/${e2}/instances/${t2}/documents/${i2}/resources/${n2}`);
|
|
3477
3547
|
}
|
|
3478
3548
|
getSearchResults(e2, t2, i2, n2) {
|
|
3479
|
-
return this.validateClientID(e2), this.authenticatedPost(`${this.
|
|
3549
|
+
return this.validateClientID(e2), this.authenticatedPost(`${this.connectionConfig.serviceUrl}/clients/${e2}/instances/${t2}/documents/${i2}/search`, n2).then(function(e3) {
|
|
3480
3550
|
return e3 || [];
|
|
3481
3551
|
});
|
|
3482
3552
|
}
|
|
3483
3553
|
createAIThread(e2, t2, i2, n2) {
|
|
3484
|
-
return this.validateClientID(e2), this.authenticatedPost(`${this.
|
|
3554
|
+
return this.validateClientID(e2), this.authenticatedPost(`${this.connectionConfig.serviceUrl}/clients/${e2}/instances/${t2}/ai`, { report: i2, parameterValues: n2 }).then((e3) => e3);
|
|
3485
3555
|
}
|
|
3486
3556
|
getAIResponse(e2, t2, i2, n2, r2) {
|
|
3487
|
-
return this.validateClientID(e2), this.authenticatedPost(`${this.
|
|
3557
|
+
return this.validateClientID(e2), this.authenticatedPost(`${this.connectionConfig.serviceUrl}/clients/${e2}/instances/${t2}/documents/${i2}/ai/${n2}/query`, { query: r2 }).then(function(e3) {
|
|
3488
3558
|
return e3 || "";
|
|
3489
3559
|
});
|
|
3490
3560
|
}
|
|
3491
3561
|
getServiceUrl() {
|
|
3492
|
-
return this.
|
|
3562
|
+
return this.connectionConfig.serviceUrl;
|
|
3493
3563
|
}
|
|
3494
3564
|
keepClientAlive(e2) {
|
|
3495
|
-
return this.authenticatedPost(`${this.
|
|
3565
|
+
return this.authenticatedPost(`${this.connectionConfig.serviceUrl}/clients/keepAlive/${e2}`, {});
|
|
3496
3566
|
}
|
|
3497
3567
|
getClientsSessionTimeoutSeconds() {
|
|
3498
|
-
return this.authenticatedGet(`${this.
|
|
3568
|
+
return this.authenticatedGet(`${this.connectionConfig.serviceUrl}/clients/sessionTimeout`).then(function(e2) {
|
|
3499
3569
|
return e2.clientSessionTimeout;
|
|
3500
3570
|
});
|
|
3501
3571
|
}
|
|
3502
|
-
}, e.
|
|
3503
|
-
constructor(e2, t2, i2) {
|
|
3504
|
-
this.url = e2, this.username = t2, this.password = i2;
|
|
3505
|
-
}
|
|
3506
|
-
}, e.ServiceClientOptions = class {
|
|
3507
|
-
constructor(e2, t2 = null) {
|
|
3508
|
-
this.serviceUrl = "", this.serviceUrl = e2.replace(/\/+$/, ""), this.loginInfo = t2;
|
|
3509
|
-
}
|
|
3510
|
-
}, e.addClass = B, e.appendHtml = Y, e.createElement = H, e.debounce = re, e.each = de, e.escapeHtml = Z, e.findElement = te, e.getColorAlphaValue = Q, e.getElementAttributeValue = ie, e.getElementScrollParent = ne, e.getOffsetParent = j, e.hasClass = W, e.isArray = ue, e.isExceptionOfType = oe, e.isInternalServerError = he, e.isInvalidClientException = ae, e.isInvalidParameterException = le, e.isRgbColor = X, e.keepElementInView = function(e2) {
|
|
3572
|
+
}, e.TooltipEventArgs = f, e.addClass = ne, e.appendHtml = pe, e.createElement = ie, e.debounce = Pe, e.each = Te, e.escapeHtml = he, e.findElement = me, e.getColorAlphaValue = ue, e.getElementAttributeValue = fe, e.getElementScrollParent = ve, e.getOffsetParent = oe, e.hasClass = se, e.isArray = Ae, e.isExceptionOfType = ye, e.isInternalServerError = be, e.isInvalidClientException = Se, e.isInvalidParameterException = Ie, e.isRgbColor = de, e.keepElementInView = function(e2) {
|
|
3511
3573
|
if (!e2)
|
|
3512
3574
|
return;
|
|
3513
|
-
let t2 =
|
|
3575
|
+
let t2 = ve(e2);
|
|
3514
3576
|
if (!t2)
|
|
3515
3577
|
return;
|
|
3516
3578
|
let i2 = e2.offsetTop, n2 = i2 + e2.offsetHeight, r2 = t2.scrollTop + t2.offsetHeight;
|
|
3517
3579
|
i2 < t2.scrollTop ? t2.scrollTop = i2 : n2 > r2 && (t2.scrollTop += n2 - r2);
|
|
3518
|
-
}, e.parseToLocalDate =
|
|
3580
|
+
}, e.parseToLocalDate = Me, e.prependHtml = ge, e.removeClass = re, e.reportSourcesAreEqual = function(e2) {
|
|
3519
3581
|
const t2 = e2.firstReportSource, i2 = e2.secondReportSource;
|
|
3520
3582
|
if (t2 && i2 && t2.report === i2.report) {
|
|
3521
3583
|
let e3 = "";
|
|
@@ -3524,7 +3586,7 @@ ${e3.text} (${e3.id})`;
|
|
|
3524
3586
|
return i2.parameters && (n2 = JSON.stringify(i2.parameters)), e3 === n2;
|
|
3525
3587
|
}
|
|
3526
3588
|
return false;
|
|
3527
|
-
}, e.scaleElement =
|
|
3589
|
+
}, e.scaleElement = le, e.stringFormat = we, e.throttle = Ce, e.toPixel = ae, e.toRgbColor = ce, e.tryParseFloat = Ee, e.tryParseInt = Re, Object.defineProperty(e, "__esModule", { value: true });
|
|
3528
3590
|
});
|
|
3529
3591
|
})(dist, dist.exports);
|
|
3530
3592
|
var distExports = dist.exports;
|
|
@@ -4504,6 +4566,7 @@ ${e3.text} (${e3.id})`;
|
|
|
4504
4566
|
errorCreatingReportInstance: "Error creating report instance (Report = '{0}').",
|
|
4505
4567
|
errorCreatingReportDocument: "Error creating report document (Report = '{0}'; Format = '{1}').",
|
|
4506
4568
|
unableToGetReportParameters: "Unable to get report parameters.",
|
|
4569
|
+
errorUnauthorizedOrForbidden: "You don't have permission to access this report document.",
|
|
4507
4570
|
errorObtainingAuthenticationToken: "Error obtaining authentication token.",
|
|
4508
4571
|
clientExpired: "Click 'Refresh' to restore client session.",
|
|
4509
4572
|
promisesChainStopError: "Error shown. Throwing promises chain stop error.",
|
|
@@ -6539,7 +6602,7 @@ ${e3.text} (${e3.id})`;
|
|
|
6539
6602
|
parameter.Error = stringResources.invalidParameter;
|
|
6540
6603
|
}
|
|
6541
6604
|
if (parameter.availableValues) {
|
|
6542
|
-
this.processedParameterValues[parameter.id] = { valueMember: parameter.value, displayMember: parameter.label, availableValues: parameter.availableValues, multivalue: parameter.multivalue };
|
|
6605
|
+
this.processedParameterValues[parameter.id] = { valueMember: parameter.value, displayMember: parameter.label, availableValues: parameter.availableValues, multivalue: parameter.multivalue, allowNull: parameter.allowNull };
|
|
6543
6606
|
} else {
|
|
6544
6607
|
this.processedParameterValues[parameter.id] = parameter.value;
|
|
6545
6608
|
}
|
|
@@ -8820,14 +8883,12 @@ ${e3.text} (${e3.id})`;
|
|
|
8820
8883
|
var history = {};
|
|
8821
8884
|
var commands = {};
|
|
8822
8885
|
var viewer = {};
|
|
8823
|
-
var serviceClientOptions = {};
|
|
8824
|
-
var reportServerUrl = "";
|
|
8825
8886
|
options.viewerSelector = "reportViewer-" + generateGuidString();
|
|
8826
8887
|
$placeholder.attr("data-selector", options.viewerSelector);
|
|
8827
8888
|
if (!validateOptions(options)) {
|
|
8828
8889
|
return;
|
|
8829
8890
|
}
|
|
8830
|
-
var version = "19.
|
|
8891
|
+
var version = "19.3.25.1119";
|
|
8831
8892
|
options = $.extend({}, getDefaultOptions(svcApiUrl, version), options);
|
|
8832
8893
|
settings = new ReportViewerSettings(
|
|
8833
8894
|
persistanceKey,
|
|
@@ -8847,20 +8908,7 @@ ${e3.text} (${e3.id})`;
|
|
|
8847
8908
|
}
|
|
8848
8909
|
);
|
|
8849
8910
|
notificationService = new NotificationService();
|
|
8850
|
-
|
|
8851
|
-
reportServerUrl = rTrim(options.reportServer.url, "\\/");
|
|
8852
|
-
var serviceUrl = reportServerUrl + "/api/reports";
|
|
8853
|
-
var tokenUrl = reportServerUrl + "/Token";
|
|
8854
|
-
var loginInfo = new distExports.ServiceClientLoginInfo(
|
|
8855
|
-
tokenUrl,
|
|
8856
|
-
options.reportServer.username,
|
|
8857
|
-
options.reportServer.password
|
|
8858
|
-
);
|
|
8859
|
-
serviceClientOptions = new distExports.ServiceClientOptions(serviceUrl, loginInfo);
|
|
8860
|
-
} else {
|
|
8861
|
-
serviceClientOptions = new distExports.ServiceClientOptions(options.serviceUrl);
|
|
8862
|
-
}
|
|
8863
|
-
client = new distExports.ServiceClient(serviceClientOptions);
|
|
8911
|
+
client = new distExports.ServiceClient(options);
|
|
8864
8912
|
controller = new distExports.ReportController(
|
|
8865
8913
|
client,
|
|
8866
8914
|
new distExports.ReportControllerOptions(
|
|
@@ -8893,7 +8941,25 @@ ${e3.text} (${e3.id})`;
|
|
|
8893
8941
|
commands
|
|
8894
8942
|
});
|
|
8895
8943
|
viewer = {
|
|
8944
|
+
/**
|
|
8945
|
+
* String resources used by the viewer for localization and UI text.
|
|
8946
|
+
* Contains key-value pairs for all UI strings, supporting localization and customization.
|
|
8947
|
+
* @type {Object.<string, string>}
|
|
8948
|
+
*/
|
|
8896
8949
|
stringResources,
|
|
8950
|
+
/**
|
|
8951
|
+
* Refreshes the currently loaded report.
|
|
8952
|
+
* Forces the viewer to reload the report from the server. Optionally ignores the cache.
|
|
8953
|
+
* @function
|
|
8954
|
+
* @param {boolean} [ignoreCache=true] - If true, the report is reloaded from the server, bypassing any cached data.
|
|
8955
|
+
* @returns {ReportViewerInstance} Returns the viewer instance for chaining.
|
|
8956
|
+
* @example // Refresh the report, ignoring cache (default)
|
|
8957
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
8958
|
+
* viewer.refreshReport();
|
|
8959
|
+
* @example // Refresh the report, using cache if available
|
|
8960
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
8961
|
+
* viewer.refreshReport(false);
|
|
8962
|
+
*/
|
|
8897
8963
|
refreshReport: (ignoreCache) => {
|
|
8898
8964
|
if (arguments.length === 0) {
|
|
8899
8965
|
ignoreCache = true;
|
|
@@ -8901,6 +8967,26 @@ ${e3.text} (${e3.id})`;
|
|
|
8901
8967
|
controller.refreshReport(ignoreCache, "", true);
|
|
8902
8968
|
return viewer;
|
|
8903
8969
|
},
|
|
8970
|
+
/**
|
|
8971
|
+
* Gets or sets the report source for the viewer.
|
|
8972
|
+
* When called with an argument, sets the report source
|
|
8973
|
+
* When called without arguments, gets the current report source - report and parameters. The viewer's report source is updated dynamically as the users navigate between reports and change parameter values.
|
|
8974
|
+
* @function
|
|
8975
|
+
* @param {ReportSource|null} [rs] - The report source object to set, or null to clear. If omitted, acts as a getter.
|
|
8976
|
+
* @returns {ReportSource} Returns the viewer instance for chaining when setting, or the current report source when getting.
|
|
8977
|
+
* @example // Get the current report source
|
|
8978
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
8979
|
+
* var currentSource = viewer.reportSource();
|
|
8980
|
+
* @example // Set a new report source
|
|
8981
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
8982
|
+
* viewer.reportSource({
|
|
8983
|
+
* report: "MyReport",
|
|
8984
|
+
* parameters: { StartDate: "2024-01-01", EndDate: "2024-12-31" }
|
|
8985
|
+
* });
|
|
8986
|
+
* @example // Clear the report source
|
|
8987
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
8988
|
+
* viewer.reportSource(null);
|
|
8989
|
+
*/
|
|
8904
8990
|
reportSource: (rs) => {
|
|
8905
8991
|
if (rs || rs === null) {
|
|
8906
8992
|
controller.setReportSource(rs);
|
|
@@ -8909,10 +8995,31 @@ ${e3.text} (${e3.id})`;
|
|
|
8909
8995
|
}
|
|
8910
8996
|
return controller.getReportSource();
|
|
8911
8997
|
},
|
|
8998
|
+
/**
|
|
8999
|
+
* Clears the current reportSource from the viewer's internal state and its persisted session in the browser.
|
|
9000
|
+
* Called in order to force the viewer to respect the newly set reportSource on a server postback.
|
|
9001
|
+
* @function
|
|
9002
|
+
* @returns {ReportViewerInstance} Returns the viewer instance for chaining.
|
|
9003
|
+
* @example // Clear the report source and force the viewer to respect a new reportSource on postback
|
|
9004
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
9005
|
+
* viewer.clearReportSource();
|
|
9006
|
+
*/
|
|
8912
9007
|
clearReportSource: () => {
|
|
8913
9008
|
controller.setReportSource(new distExports.ReportSourceOptions());
|
|
8914
9009
|
return viewer;
|
|
8915
9010
|
},
|
|
9011
|
+
/**
|
|
9012
|
+
* Gets or sets the view mode of the viewer (e.g., Interactive or Print Preview).
|
|
9013
|
+
* @function
|
|
9014
|
+
* @param {ViewModes} [vm] - The view mode to set. If omitted, returns the current view mode.
|
|
9015
|
+
* @returns {string} Returns the viewer instance for chaining when setting, or the current view mode string when getting.
|
|
9016
|
+
* @example // Get the current view mode
|
|
9017
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
9018
|
+
* var mode = viewer.viewMode();
|
|
9019
|
+
* @example // Set the view mode to Print Preview
|
|
9020
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
9021
|
+
* viewer.viewMode(telerikReportViewer.ViewModes.PRINT_PREVIEW);
|
|
9022
|
+
*/
|
|
8916
9023
|
viewMode: (vm) => {
|
|
8917
9024
|
if (vm) {
|
|
8918
9025
|
controller.setViewMode(viewModeMap[vm]);
|
|
@@ -8920,6 +9027,18 @@ ${e3.text} (${e3.id})`;
|
|
|
8920
9027
|
}
|
|
8921
9028
|
return viewModeReverseMap[controller.getViewMode()];
|
|
8922
9029
|
},
|
|
9030
|
+
/**
|
|
9031
|
+
* Gets or sets the page mode (e.g., Single Page or Continuous Scroll).
|
|
9032
|
+
* @function
|
|
9033
|
+
* @param {PageModes} [psm] - The page mode to set. If omitted, returns the current page mode.
|
|
9034
|
+
* @returns {string} Returns the viewer instance for chaining when setting, or the current page mode string when getting.
|
|
9035
|
+
* @example // Get the current page mode
|
|
9036
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
9037
|
+
* var pageMode = viewer.pageMode();
|
|
9038
|
+
* @example // Set the page mode to Single Page
|
|
9039
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
9040
|
+
* viewer.pageMode(telerikReportViewer.PageModes.SINGLE_PAGE);
|
|
9041
|
+
*/
|
|
8923
9042
|
pageMode: (psm) => {
|
|
8924
9043
|
if (psm) {
|
|
8925
9044
|
controller.setPageMode(pageModeMap[psm]);
|
|
@@ -8927,6 +9046,18 @@ ${e3.text} (${e3.id})`;
|
|
|
8927
9046
|
}
|
|
8928
9047
|
return pageModeReverseMap[controller.getPageMode()];
|
|
8929
9048
|
},
|
|
9049
|
+
/**
|
|
9050
|
+
* Gets or sets the print mode for the viewer.
|
|
9051
|
+
* @function
|
|
9052
|
+
* @param {PrintModes} [pm] - The print mode to set. If omitted, returns the current print mode.
|
|
9053
|
+
* @returns {string} Returns the viewer instance for chaining when setting, or the current print mode string when getting.
|
|
9054
|
+
* @example // Get the current print mode
|
|
9055
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
9056
|
+
* var printMode = viewer.printMode();
|
|
9057
|
+
* @example // Set the print mode to Force PDF File
|
|
9058
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
9059
|
+
* viewer.printMode(telerikReportViewer.PrintModes.FORCE_PDF_FILE);
|
|
9060
|
+
*/
|
|
8930
9061
|
printMode: (pm) => {
|
|
8931
9062
|
if (pm) {
|
|
8932
9063
|
controller.setPrintMode(printModeMap[pm]);
|
|
@@ -8934,6 +9065,20 @@ ${e3.text} (${e3.id})`;
|
|
|
8934
9065
|
}
|
|
8935
9066
|
return printModeReverseMap[controller.getPrintMode()];
|
|
8936
9067
|
},
|
|
9068
|
+
/**
|
|
9069
|
+
* Gets or sets the scale and scale mode for the viewer.
|
|
9070
|
+
* @function
|
|
9071
|
+
* @param {Object} [args] - The scale settings to apply. Should contain 'scale' (number) and 'scaleMode' (string).
|
|
9072
|
+
* @param {number} [args.scale] - The zoom scale (e.g., 1.0 for 100%).
|
|
9073
|
+
* @param {ScaleModes} [args.scaleMode] - The scale mode (e.g., 'FIT_PAGE', 'FIT_PAGE_WIDTH', 'SPECIFIC').
|
|
9074
|
+
* @returns {Object} Returns the viewer instance for chaining when setting, or an object with current scale and scaleMode when getting.
|
|
9075
|
+
* @example // Get the current scale and scale mode
|
|
9076
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
9077
|
+
* var scaleInfo = viewer.scale();
|
|
9078
|
+
* @example // Set scale to 1.2 and scale mode to FIT_PAGE_WIDTH
|
|
9079
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
9080
|
+
* viewer.scale({ scale: 1.2, scaleMode: telerikReportViewer.ScaleModes.FIT_PAGE_WIDTH });
|
|
9081
|
+
*/
|
|
8937
9082
|
scale: (args) => {
|
|
8938
9083
|
if (args) {
|
|
8939
9084
|
controller.setScale(args.scale);
|
|
@@ -8945,33 +9090,135 @@ ${e3.text} (${e3.id})`;
|
|
|
8945
9090
|
scaleMode: scaleModeReverseMap[controller.getScaleMode()]
|
|
8946
9091
|
};
|
|
8947
9092
|
},
|
|
9093
|
+
/**
|
|
9094
|
+
* Gets the viewer’s current page that is displayed.
|
|
9095
|
+
* @function
|
|
9096
|
+
* @returns {number} The current page number (1-based).
|
|
9097
|
+
* @example // Get the current page number
|
|
9098
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
9099
|
+
* var page = viewer.currentPage();
|
|
9100
|
+
*/
|
|
8948
9101
|
currentPage: () => {
|
|
8949
9102
|
return controller.getCurrentPageNumber();
|
|
8950
9103
|
},
|
|
9104
|
+
/**
|
|
9105
|
+
* Gets the total page count of the viewer’s currently displayed report.
|
|
9106
|
+
* @function
|
|
9107
|
+
* @returns {number} The total page count.
|
|
9108
|
+
* @example // Get the total number of pages in the current report
|
|
9109
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
9110
|
+
* var totalPages = viewer.pageCount();
|
|
9111
|
+
*/
|
|
8951
9112
|
pageCount: () => {
|
|
8952
9113
|
return controller.getPageCount();
|
|
8953
9114
|
},
|
|
9115
|
+
/**
|
|
9116
|
+
* Shows or hides the parameters area in the viewer UI.
|
|
9117
|
+
* @function
|
|
9118
|
+
* @param {boolean} visible - True to show, false to hide the parameters area.
|
|
9119
|
+
* @returns {void}
|
|
9120
|
+
* @example // Show the parameters area
|
|
9121
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
9122
|
+
* viewer.parametersAreaVisible(true);
|
|
9123
|
+
* @example // Hide the parameters area
|
|
9124
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
9125
|
+
* viewer.parametersAreaVisible(false);
|
|
9126
|
+
*/
|
|
8954
9127
|
parametersAreaVisible: (visible) => {
|
|
8955
9128
|
notificationService.setParametersAreaVisible({ visible });
|
|
8956
9129
|
},
|
|
9130
|
+
/**
|
|
9131
|
+
* Returns an object with properties, the names of which are the report parameters’ IDs, and values - the report parameters’ values. The values of multivalue parameters include their display and value members.
|
|
9132
|
+
* @function
|
|
9133
|
+
* @returns {Array<Object>} An array of report parameter objects.
|
|
9134
|
+
* @example // Get all report parameters and log them
|
|
9135
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
9136
|
+
* var parameters = viewer.getReportParameters();
|
|
9137
|
+
* console.log(parameters);
|
|
9138
|
+
*/
|
|
8957
9139
|
getReportParameters: () => {
|
|
8958
9140
|
return controller.getReportParameters();
|
|
8959
9141
|
},
|
|
9142
|
+
/**
|
|
9143
|
+
* Returns whether auto-run is enabled for the report (i.e., whether the report runs automatically when parameters change).
|
|
9144
|
+
* @function
|
|
9145
|
+
* @returns {boolean} True if auto-run is enabled, false otherwise.
|
|
9146
|
+
* @example // Check if auto-run is enabled for the report
|
|
9147
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
9148
|
+
* var isReportAutoRun = viewer.isReportAutoRun();
|
|
9149
|
+
*/
|
|
8960
9150
|
isReportAutoRun: () => {
|
|
8961
9151
|
return controller.autoRunEnabled;
|
|
8962
9152
|
},
|
|
9153
|
+
/**
|
|
9154
|
+
* Sets the authentication token. Used for service requests.
|
|
9155
|
+
* @function
|
|
9156
|
+
* @param {string} [token] - The authentication token to set.
|
|
9157
|
+
* @returns {ReportViewerInstance} Returns the viewer instance for chaining.
|
|
9158
|
+
* @example // Set the authentication token for the viewer
|
|
9159
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
9160
|
+
* viewer.authenticationToken("YOUR_AUTH_TOKEN");
|
|
9161
|
+
*/
|
|
8963
9162
|
authenticationToken: (token) => {
|
|
8964
9163
|
if (token) {
|
|
8965
9164
|
controller.setAuthenticationToken(token);
|
|
8966
9165
|
}
|
|
8967
9166
|
return viewer;
|
|
8968
9167
|
},
|
|
9168
|
+
/**
|
|
9169
|
+
* Binds event handlers to the specified event.
|
|
9170
|
+
* @function
|
|
9171
|
+
* @param {string} eventName - The name of the event to bind to (see Events constants).
|
|
9172
|
+
* @param {function} eventHandler - The handler function to invoke when the event occurs.
|
|
9173
|
+
* @returns {void}
|
|
9174
|
+
* @example // Bind to the 'pageReady' event
|
|
9175
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
9176
|
+
* viewer.bind(telerikReportViewer.Events.PAGE_READY, function(e, args) {
|
|
9177
|
+
* console.log("Page is ready!", args);
|
|
9178
|
+
* });
|
|
9179
|
+
* @example // Bind to the 'error' event
|
|
9180
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
9181
|
+
* viewer.bind(telerikReportViewer.Events.ERROR, function(e, args) {
|
|
9182
|
+
* alert("An error occurred: " + args);
|
|
9183
|
+
* });
|
|
9184
|
+
*/
|
|
8969
9185
|
bind: (eventName, eventHandler) => {
|
|
8970
9186
|
eventBinder(eventName, eventHandler, true);
|
|
8971
9187
|
},
|
|
9188
|
+
/**
|
|
9189
|
+
* Unbinds an event handler from a viewer event.
|
|
9190
|
+
* @function
|
|
9191
|
+
* @param {string} eventName - The name of the event to unbind from.
|
|
9192
|
+
* @param {function} [eventHandler] - The handler function to remove. If omitted, all handlers for the event are removed.
|
|
9193
|
+
* @returns {void}
|
|
9194
|
+
* @example // Unbind all handlers from the 'error' event
|
|
9195
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
9196
|
+
* viewer.unbind(telerikReportViewer.Events.ERROR);
|
|
9197
|
+
*/
|
|
8972
9198
|
unbind: (eventName, eventHandler) => {
|
|
8973
9199
|
eventBinder(eventName, eventHandler, false);
|
|
8974
9200
|
},
|
|
9201
|
+
/**
|
|
9202
|
+
* Gets or sets the accessibility key map for keyboard navigation.
|
|
9203
|
+
* Allows customization of keyboard shortcuts for accessibility features.
|
|
9204
|
+
* @function
|
|
9205
|
+
* @param {Object} [keyMap] - The key map object to set. If omitted, acts as a getter.
|
|
9206
|
+
* @returns {Object} Returns the viewer instance for chaining when setting, the current key map when getting, or undefined if accessibility is not enabled.
|
|
9207
|
+
* @example // Get the current accessibility key map
|
|
9208
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
9209
|
+
* var keyMap = viewer.accessibilityKeyMap();
|
|
9210
|
+
*
|
|
9211
|
+
* @example // Set a custom accessibility key map
|
|
9212
|
+
* var reportViewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
9213
|
+
* reportViewer.accessibilityKeyMap(
|
|
9214
|
+
* {
|
|
9215
|
+
* CONFIRM_KEY: 32,
|
|
9216
|
+
* CONTENT_AREA_KEY: 82, //R
|
|
9217
|
+
* DOCUMENT_MAP_AREA_KEY: 77, //M
|
|
9218
|
+
* MENU_AREA_KEY: 85, //U
|
|
9219
|
+
* PARAMETERS_AREA_KEY: 80 //P
|
|
9220
|
+
* });
|
|
9221
|
+
*/
|
|
8975
9222
|
accessibilityKeyMap: (keyMap) => {
|
|
8976
9223
|
if (accessibility) {
|
|
8977
9224
|
if (keyMap) {
|
|
@@ -8982,12 +9229,27 @@ ${e3.text} (${e3.id})`;
|
|
|
8982
9229
|
}
|
|
8983
9230
|
return void 0;
|
|
8984
9231
|
},
|
|
9232
|
+
/**
|
|
9233
|
+
* The command set for the viewer, providing programmatic access to built-in commands (e.g., navigation, export).
|
|
9234
|
+
* @type {ReportViewerCommands}
|
|
9235
|
+
*/
|
|
8985
9236
|
commands,
|
|
9237
|
+
/**
|
|
9238
|
+
* Disposes the viewer instance, cleaning up resources and event handlers.
|
|
9239
|
+
* After calling this method, the viewer instance should not be used.
|
|
9240
|
+
* Stops sending keep alive requests to the server, if keep client alive was enabled.
|
|
9241
|
+
* @function
|
|
9242
|
+
* @returns {void}
|
|
9243
|
+
* @example
|
|
9244
|
+
* // Dispose the viewer instance when it is no longer needed
|
|
9245
|
+
* var viewer = $("#reportViewer1").data("telerik_ReportViewer");
|
|
9246
|
+
* viewer.dispose();
|
|
9247
|
+
*/
|
|
8986
9248
|
dispose: () => {
|
|
8987
9249
|
clearTooltipTimeout();
|
|
8988
9250
|
controller.disposeSentinel();
|
|
8989
9251
|
controller.destroy();
|
|
8990
|
-
if (perspectiveManager) {
|
|
9252
|
+
if (perspectiveManager && typeof perspectiveManager.dispose === "function") {
|
|
8991
9253
|
perspectiveManager.dispose();
|
|
8992
9254
|
}
|
|
8993
9255
|
}
|
|
@@ -9123,6 +9385,9 @@ ${e3.text} (${e3.id})`;
|
|
|
9123
9385
|
function enableTouch(dom2) {
|
|
9124
9386
|
var allowSwipeLeft;
|
|
9125
9387
|
var allowSwipeRight;
|
|
9388
|
+
function isMobileDevice() {
|
|
9389
|
+
return /Mobile|Android|webOS|iPhone|iPad|iPod|BlackBerry|Opera Mini|Windows Phone/i.test(navigator.userAgent) || /Macintosh/i.test(navigator.userAgent) && navigator.maxTouchPoints && navigator.maxTouchPoints > 0;
|
|
9390
|
+
}
|
|
9126
9391
|
TouchBehavior(
|
|
9127
9392
|
dom2,
|
|
9128
9393
|
{
|
|
@@ -9145,7 +9410,9 @@ ${e3.text} (${e3.id})`;
|
|
|
9145
9410
|
controller.setScale(scale * f);
|
|
9146
9411
|
},
|
|
9147
9412
|
doubletap: function() {
|
|
9148
|
-
|
|
9413
|
+
if (isMobileDevice()) {
|
|
9414
|
+
commands.toggleZoomMode.exec();
|
|
9415
|
+
}
|
|
9149
9416
|
},
|
|
9150
9417
|
touchstart: function() {
|
|
9151
9418
|
var el = dom2.find(".trv-page-wrapper")[0];
|
|
@@ -9274,8 +9541,8 @@ ${e3.text} (${e3.id})`;
|
|
|
9274
9541
|
settings.setScale(scale);
|
|
9275
9542
|
}).on("clientIdChanged", (clientId) => {
|
|
9276
9543
|
settings.setClientId(clientId);
|
|
9277
|
-
}).on("currentPageChanged", (
|
|
9278
|
-
settings.setPageNumber(page);
|
|
9544
|
+
}).on("currentPageChanged", (args) => {
|
|
9545
|
+
settings.setPageNumber(args.page);
|
|
9279
9546
|
}).on("reportSourceChanged", (rs) => {
|
|
9280
9547
|
settings.setReportSource(rs);
|
|
9281
9548
|
});
|
|
@@ -9348,10 +9615,7 @@ ${e3.text} (${e3.id})`;
|
|
|
9348
9615
|
notificationService.setDocumentMapVisible({ visible: false });
|
|
9349
9616
|
}
|
|
9350
9617
|
}).on("navigateToReport", (args) => {
|
|
9351
|
-
controller.setReportSource(
|
|
9352
|
-
report: args.Report,
|
|
9353
|
-
parameters: args.Parameters
|
|
9354
|
-
});
|
|
9618
|
+
controller.setReportSource(args);
|
|
9355
9619
|
controller.refreshReport(false);
|
|
9356
9620
|
}).on("toolTipOpening", (args) => {
|
|
9357
9621
|
showTooltip(args);
|