@netless/app-slide 0.3.0-canary.16 → 0.3.0-canary.17
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/dist/main.iife.js +2 -2
- package/dist/main.iife.js.map +1 -1
- package/dist/main.js +2 -2
- package/dist/main.js.map +1 -1
- package/dist/main.mjs +227 -213
- package/dist/main.mjs.map +1 -1
- package/package.json +2 -2
- package/src/connect.ts +1 -1
package/dist/main.mjs
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import { Slide as ue } from "@netless/slide";
|
|
2
|
-
import { Slide as
|
|
3
|
-
const _t = "!#%()*+,-./:;=?@[]^_`{|}~ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789", yt = 87, kt = 20,
|
|
2
|
+
import { Slide as hr } from "@netless/slide";
|
|
3
|
+
const _t = "!#%()*+,-./:;=?@[]^_`{|}~ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789", yt = 87, kt = 20, Ae = [], St = () => {
|
|
4
4
|
for (let e = 0; e < kt; e++)
|
|
5
|
-
|
|
6
|
-
return
|
|
5
|
+
Ae[e] = _t.charAt(Math.random() * yt);
|
|
6
|
+
return Ae.join("");
|
|
7
7
|
};
|
|
8
|
-
function
|
|
8
|
+
function Pe(e) {
|
|
9
9
|
try {
|
|
10
10
|
return e();
|
|
11
11
|
} catch (t) {
|
|
12
12
|
console.error(t);
|
|
13
13
|
}
|
|
14
14
|
}
|
|
15
|
-
class
|
|
15
|
+
class De {
|
|
16
16
|
constructor() {
|
|
17
17
|
this.push = this.addDisposer, this.disposers = /* @__PURE__ */ new Map();
|
|
18
18
|
}
|
|
@@ -45,7 +45,7 @@ class Te {
|
|
|
45
45
|
s && s();
|
|
46
46
|
}
|
|
47
47
|
flushAll() {
|
|
48
|
-
this.disposers.forEach(
|
|
48
|
+
this.disposers.forEach(Pe), this.disposers.clear();
|
|
49
49
|
}
|
|
50
50
|
genUID() {
|
|
51
51
|
let t;
|
|
@@ -56,9 +56,9 @@ class Te {
|
|
|
56
56
|
}
|
|
57
57
|
}
|
|
58
58
|
function xt(e) {
|
|
59
|
-
return () => e.forEach(
|
|
59
|
+
return () => e.forEach(Pe);
|
|
60
60
|
}
|
|
61
|
-
const O = "netless-app-slide",
|
|
61
|
+
const O = "netless-app-slide", Fe = "https://convertcdn.netless.link/dynamicConvert";
|
|
62
62
|
class Et {
|
|
63
63
|
constructor() {
|
|
64
64
|
this.threshold = 2, this._map = /* @__PURE__ */ new Map(), this._box = /* @__PURE__ */ new Map(), this._queue = [];
|
|
@@ -82,13 +82,13 @@ class Et {
|
|
|
82
82
|
const n = ((o = this._box.get(s)) == null ? void 0 : o.zIndex) ?? 0, i = ((a = this._box.get(r)) == null ? void 0 : a.zIndex) ?? 0;
|
|
83
83
|
return -(n - i);
|
|
84
84
|
}), this._queue.forEach((s, r) => {
|
|
85
|
-
|
|
85
|
+
(t = this._map.get(s)) && (r < this.threshold ? t.unfreeze() : t.freeze());
|
|
86
86
|
});
|
|
87
87
|
}
|
|
88
88
|
}
|
|
89
|
-
const
|
|
89
|
+
const Re = new Et(), ir = function(t) {
|
|
90
90
|
t.on("focus", (s) => {
|
|
91
|
-
|
|
91
|
+
Re.focus(s.appId);
|
|
92
92
|
});
|
|
93
93
|
};
|
|
94
94
|
class Ct {
|
|
@@ -181,7 +181,14 @@ class Ct {
|
|
|
181
181
|
this.b.clear();
|
|
182
182
|
}
|
|
183
183
|
}
|
|
184
|
-
var
|
|
184
|
+
var pe = {}, At = {
|
|
185
|
+
get exports() {
|
|
186
|
+
return pe;
|
|
187
|
+
},
|
|
188
|
+
set exports(e) {
|
|
189
|
+
pe = e;
|
|
190
|
+
}
|
|
191
|
+
}, It = {
|
|
185
192
|
aliceblue: [240, 248, 255],
|
|
186
193
|
antiquewhite: [250, 235, 215],
|
|
187
194
|
aqua: [0, 255, 255],
|
|
@@ -330,24 +337,31 @@ var Fe = { exports: {} }, At = {
|
|
|
330
337
|
whitesmoke: [245, 245, 245],
|
|
331
338
|
yellow: [255, 255, 0],
|
|
332
339
|
yellowgreen: [154, 205, 50]
|
|
333
|
-
},
|
|
340
|
+
}, he = {}, zt = {
|
|
341
|
+
get exports() {
|
|
342
|
+
return he;
|
|
343
|
+
},
|
|
344
|
+
set exports(e) {
|
|
345
|
+
he = e;
|
|
346
|
+
}
|
|
347
|
+
}, Lt = function(t) {
|
|
334
348
|
return !t || typeof t == "string" ? !1 : t instanceof Array || Array.isArray(t) || t.length >= 0 && (t.splice instanceof Function || Object.getOwnPropertyDescriptor(t, t.length - 1) && t.constructor.name !== "String");
|
|
335
|
-
},
|
|
349
|
+
}, $t = Lt, Mt = Array.prototype.concat, Nt = Array.prototype.slice, Ie = zt.exports = function(t) {
|
|
336
350
|
for (var s = [], r = 0, n = t.length; r < n; r++) {
|
|
337
351
|
var i = t[r];
|
|
338
|
-
|
|
352
|
+
$t(i) ? s = Mt.call(s, Nt.call(i)) : s.push(i);
|
|
339
353
|
}
|
|
340
354
|
return s;
|
|
341
355
|
};
|
|
342
|
-
|
|
356
|
+
Ie.wrap = function(e) {
|
|
343
357
|
return function() {
|
|
344
|
-
return e(
|
|
358
|
+
return e(Ie(arguments));
|
|
345
359
|
};
|
|
346
360
|
};
|
|
347
|
-
var X =
|
|
361
|
+
var X = It, Z = he, Ve = Object.hasOwnProperty, Ue = /* @__PURE__ */ Object.create(null);
|
|
348
362
|
for (var de in X)
|
|
349
363
|
Ve.call(X, de) && (Ue[X[de]] = de);
|
|
350
|
-
var A =
|
|
364
|
+
var A = At.exports = {
|
|
351
365
|
to: {},
|
|
352
366
|
get: {}
|
|
353
367
|
};
|
|
@@ -451,7 +465,7 @@ function re(e) {
|
|
|
451
465
|
}
|
|
452
466
|
function m(e, t) {
|
|
453
467
|
const s = re(e);
|
|
454
|
-
return
|
|
468
|
+
return Ot(s, t), s;
|
|
455
469
|
}
|
|
456
470
|
function B(e, t) {
|
|
457
471
|
return e.appendChild(t);
|
|
@@ -459,23 +473,23 @@ function B(e, t) {
|
|
|
459
473
|
function v(e) {
|
|
460
474
|
return `${O}-${e}`;
|
|
461
475
|
}
|
|
462
|
-
function
|
|
476
|
+
function Ot(e, t) {
|
|
463
477
|
e.className = v(t);
|
|
464
478
|
}
|
|
465
|
-
function
|
|
479
|
+
function Tt(e) {
|
|
466
480
|
return e.endsWith("/") ? e.slice(0, -1) : e;
|
|
467
481
|
}
|
|
468
|
-
function
|
|
482
|
+
function ze(e, t) {
|
|
469
483
|
if (typeof e == "object" && e !== null)
|
|
470
484
|
return e[t];
|
|
471
485
|
}
|
|
472
|
-
function
|
|
486
|
+
function Le() {
|
|
473
487
|
let e;
|
|
474
488
|
return [new Promise((s) => {
|
|
475
489
|
e = s;
|
|
476
490
|
}), e];
|
|
477
491
|
}
|
|
478
|
-
function
|
|
492
|
+
function Pt(e) {
|
|
479
493
|
const t = e.room, s = e.displayer;
|
|
480
494
|
return t ? () => t.calibrationTimestamp : s ? () => s.beginTimestamp + s.progressTime : () => Date.now();
|
|
481
495
|
}
|
|
@@ -483,15 +497,15 @@ function Be(e) {
|
|
|
483
497
|
try {
|
|
484
498
|
let t = window.getComputedStyle(e).backgroundColor;
|
|
485
499
|
if (t !== "rgba(0, 0, 0, 0)" && t !== "transparent")
|
|
486
|
-
return t =
|
|
500
|
+
return t = Dt(t), console.log("[Slide] guess bg color:", t), t;
|
|
487
501
|
if (e.parentElement)
|
|
488
502
|
return Be(e.parentElement);
|
|
489
503
|
} catch {
|
|
490
504
|
}
|
|
491
505
|
return "#ffffff";
|
|
492
506
|
}
|
|
493
|
-
function
|
|
494
|
-
const t =
|
|
507
|
+
function Dt(e) {
|
|
508
|
+
const t = pe.get(e);
|
|
495
509
|
if (t && t.model === "rgb") {
|
|
496
510
|
const s = t.value, n = (((Math.round(s[0]) & 255) << 16) + ((Math.round(s[1]) & 255) << 8) + (Math.round(s[2]) & 255)).toString(16);
|
|
497
511
|
return "#" + "000000".substring(n.length) + n;
|
|
@@ -499,25 +513,25 @@ function Tt(e) {
|
|
|
499
513
|
return e;
|
|
500
514
|
}
|
|
501
515
|
function He(e, t) {
|
|
502
|
-
return `${
|
|
516
|
+
return `${Tt(t || Fe)}/${e}`;
|
|
503
517
|
}
|
|
504
|
-
async function
|
|
518
|
+
async function Ft({ taskId: e, url: t }) {
|
|
505
519
|
const s = He(e, t), r = `${s}/preview/1.png`, n = `${s}/jsonOutput/slide-1.json`, i = new Promise((a) => {
|
|
506
520
|
const l = new Image();
|
|
507
521
|
l.onload = () => a(l), l.onerror = () => a(null), l.src = r;
|
|
508
522
|
}), o = fetch(n).then((a) => a.json());
|
|
509
523
|
return { preview: await i, slide: await o };
|
|
510
524
|
}
|
|
511
|
-
function
|
|
525
|
+
function Rt(e) {
|
|
512
526
|
if (typeof document < "u") {
|
|
513
527
|
const t = () => e(document.visibilityState === "visible");
|
|
514
528
|
return document.addEventListener("visibilitychange", t), () => document.removeEventListener("visibilitychange", t);
|
|
515
529
|
}
|
|
516
530
|
return j;
|
|
517
531
|
}
|
|
518
|
-
const
|
|
532
|
+
const Vt = `.netless-app-slide-tele-fancy-scrollbar{overscroll-behavior:contain;overflow:auto;overflow-y:scroll;overflow-y:overlay;-webkit-overflow-scrolling:touch;-ms-overflow-style:-ms-autohiding-scrollbar;scrollbar-width:auto}.netless-app-slide-tele-fancy-scrollbar::-webkit-scrollbar{height:8px;width:8px}.netless-app-slide-tele-fancy-scrollbar::-webkit-scrollbar-track{background-color:transparent}.netless-app-slide-tele-fancy-scrollbar::-webkit-scrollbar-thumb{background-color:#444e601a;background-color:transparent;border-radius:4px;transition:background-color .4s}.netless-app-slide-tele-fancy-scrollbar:hover::-webkit-scrollbar-thumb{background-color:#444e601a}.netless-app-slide-tele-fancy-scrollbar::-webkit-scrollbar-thumb:hover{background-color:#444e6033}.netless-app-slide-tele-fancy-scrollbar::-webkit-scrollbar-thumb:active{background-color:#444e6033}.netless-app-slide-tele-fancy-scrollbar::-webkit-scrollbar-thumb:vertical{min-height:50px}.netless-app-slide-tele-fancy-scrollbar::-webkit-scrollbar-thumb:horizontal{min-width:50px}.netless-app-slide-content{position:relative;height:100%;overflow:hidden}.netless-app-slide-slide{width:100%;height:100%;-webkit-touch-callout:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.netless-app-slide-preview-mask{display:none;position:absolute;z-index:10200;top:0;left:0;width:100%;height:100%}.netless-app-slide-preview{display:flex;flex-direction:column;align-items:center;position:absolute;z-index:10300;top:0;left:0;width:33%;max-width:200px;height:100%;padding-top:10px;transform:translate(-100%);background:rgba(237,237,240,.9);box-shadow:inset -1px 0 #0000001c;transition:transform .4s;-webkit-touch-callout:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.netless-app-slide-preview-active .netless-app-slide-preview-mask{display:block}.netless-app-slide-preview-active .netless-app-slide-preview{transform:translate(0)}.netless-app-slide-preview-page{position:relative;display:block;width:55%;margin-bottom:10px;font-size:0;color:transparent;outline:none;border:7px solid transparent;border-radius:4px;transition:border-color .3s;-webkit-touch-callout:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.netless-app-slide-preview-page:hover,.netless-app-slide-preview-page.netless-app-slide-preview-page-active{border-color:#444e601a}.netless-app-slide-preview-page>img{width:100%;height:auto;box-sizing:border-box;border:1px solid rgba(0,0,0,.5);border-radius:1px;background-color:#fff;box-shadow:0 2px 8px #0000004d}.netless-app-slide-preview-page-name{position:absolute;top:1px;left:-10px;transform:translate(-100%);text-align:right;font-size:12px;color:#5f5f5f;-webkit-touch-callout:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.netless-app-slide-overlay{display:flex;align-items:center;justify-content:center;position:absolute;z-index:10100;top:0;left:0;width:100%;height:100%;background:rgba(255,0,0,.25);transition:opacity .3s;opacity:0;pointer-events:none}.netless-app-slide-footer{box-sizing:border-box;height:26px;display:flex;align-items:center;padding:0 16px;border-top:1px solid #eeeef7;font-family:system-ui,-apple-system,Segoe UI,Roboto,Ubuntu,Cantarell,Noto Sans,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji"}.netless-app-slide-float-footer{width:100%;min-height:26px;position:absolute;left:0;bottom:0;z-index:2000;background:rgba(249,249,252,.9);transition:opacity .4s}.netless-app-slide-footer-btn{box-sizing:border-box;width:26px;height:26px;font-size:0;margin:0;padding:3px;border:none;border-radius:1px;outline:none;color:currentColor;background:transparent;transition:background .4s;cursor:pointer;-webkit-touch-callout:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;-webkit-tap-highlight-color:rgba(0,0,0,0)}.netless-app-slide-footer-btn:hover{background:rgba(237,237,240,.9)}@media (hover: none){.netless-app-slide-footer-btn:hover{background:transparent!important}}.netless-app-slide-footer-btn>svg{width:100%;height:100%}.netless-app-slide-footer-btn>svg:nth-of-type(2){display:none}.netless-app-slide-footer-btn.netless-app-slide-footer-btn-playing>svg:nth-of-type(1){display:none}.netless-app-slide-footer-btn.netless-app-slide-footer-btn-playing>svg:nth-of-type(2){display:initial}.netless-app-slide-footer-btn~.netless-app-slide-footer-btn{margin-left:15px}.netless-app-slide-page-jumps{flex:1;display:flex;justify-content:center;align-items:center}.netless-app-slide-page-number{display:flex;align-items:center;height:26px;margin-left:auto;font-size:13px;-webkit-touch-callout:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;white-space:nowrap;word-break:keep-all;font-variant-numeric:tabular-nums}.netless-app-slide-page-number-input{border:none;outline:none;width:3em;margin:0;padding:0 .5em 0 2px;text-align:right;font-size:13px;line-height:1;font-weight:400;font-family:inherit;border-radius:2px;color:currentColor;font-family:system-ui,-apple-system,Segoe UI,Roboto,Ubuntu,Cantarell,Noto Sans,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";background:transparent;transition:background .4s;font-variant-numeric:tabular-nums;-webkit-tap-highlight-color:rgba(0,0,0,0)}.netless-app-slide-page-number-input:hover,.netless-app-slide-page-number-input:focus,.netless-app-slide-page-number-input:active{user-select:text;background:#fff;box-shadow:#63636333 0 2px 8px}.netless-app-slide-readonly .netless-app-slide-footer-btn{cursor:not-allowed}.netless-app-slide-readonly .netless-app-slide-footer-btn:hover{background:transparent}.netless-app-slide-readonly .netless-app-slide-page-number-input{cursor:not-allowed}.netless-app-slide-readonly .netless-app-slide-page-number-input:hover,.netless-app-slide-readonly .netless-app-slide-page-number-input:focus,.netless-app-slide-readonly .netless-app-slide-page-number-input:active{background:transparent;box-shadow:none}.netless-app-slide-readonly .netless-app-slide-page-number-input:disabled{color:inherit}.netless-app-slide-readonly.netless-app-slide-float-footer{display:none}.telebox-color-scheme-dark .netless-app-slide-page-number-input:active,.telebox-color-scheme-dark .netless-app-slide-page-number-input:focus,.telebox-color-scheme-dark .netless-app-slide-page-number-input:hover{color:currentColor;background:#25282e}.telebox-color-scheme-dark .netless-app-slide-footer{border-top:none}.telebox-color-scheme-dark .netless-app-slide-footer-btn:hover{background:#212126}.telebox-color-scheme-dark .netless-app-slide-preview{background:rgba(50,50,50,.9)}.netless-app-slide-preview-wrapper{width:100%;height:100%;overflow:hidden;display:flex;flex-flow:column nowrap}.netless-app-slide-preview-wrapper .netless-app-slide-content{flex:1}.netless-app-slide-preview-wrapper .netless-app-slide-footer{flex-shrink:0}
|
|
519
533
|
`;
|
|
520
|
-
function
|
|
534
|
+
function Ut(e) {
|
|
521
535
|
const t = "http://www.w3.org/2000/svg", s = document.createElementNS(t, "svg");
|
|
522
536
|
s.setAttribute("class", `${e}-footer-icon-sidebar`), s.setAttribute("viewBox", "0 0 64 64");
|
|
523
537
|
const r = document.createElementNS(t, "path");
|
|
@@ -526,7 +540,7 @@ function Rt(e) {
|
|
|
526
540
|
"M50 8H14c-3.309 0-6 2.691-6 6v36c0 3.309 2.691 6 6 6h36c3.309 0 6-2.691 6-6V14c0-3.309-2.691-6-6-6zM12 50V14c0-1.103.897-2 2-2h8v40h-8c-1.103 0-2-.897-2-2zm40 0c0 1.103-.897 2-2 2H26V12h24c1.103 0 2 .897 2 2z"
|
|
527
541
|
), s.appendChild(r), s;
|
|
528
542
|
}
|
|
529
|
-
function
|
|
543
|
+
function Bt(e) {
|
|
530
544
|
const t = "http://www.w3.org/2000/svg", s = document.createElementNS(t, "svg");
|
|
531
545
|
s.setAttribute("class", `${e}-footer-icon-arrow-left`), s.setAttribute("viewBox", "0 0 500 500");
|
|
532
546
|
const r = document.createElementNS(t, "path");
|
|
@@ -535,7 +549,7 @@ function Vt(e) {
|
|
|
535
549
|
"M177.81 249.959L337.473 90.295c2.722-2.865 2.651-7.378-.143-10.1-2.793-2.65-7.163-2.65-9.956 0l-164.75 164.75c-2.793 2.793-2.793 7.306 0 10.1l164.75 164.75c2.865 2.722 7.378 2.65 10.099-.143 2.651-2.794 2.651-7.163 0-9.957L177.809 249.959z"
|
|
536
550
|
), s.appendChild(r), s;
|
|
537
551
|
}
|
|
538
|
-
function
|
|
552
|
+
function Ht(e) {
|
|
539
553
|
const t = "http://www.w3.org/2000/svg", s = document.createElementNS(t, "svg");
|
|
540
554
|
s.setAttribute("class", `${e}-footer-icon-play`), s.setAttribute("viewBox", "0 0 500 500");
|
|
541
555
|
const r = document.createElementNS(t, "path");
|
|
@@ -544,7 +558,7 @@ function Ut(e) {
|
|
|
544
558
|
"M418.158 257.419L174.663 413.33c-6.017 3.919-15.708 3.772-21.291-.29-2.791-2.018-4.295-4.483-4.295-7.084V94.109c0-5.65 6.883-10.289 15.271-10.289 4.298 0 8.391 1.307 11.181 3.332l242.629 155.484c6.016 3.917 6.451 10.292.649 14.491-.216.154-.432.154-.649.292zM170.621 391.288l223.116-141.301L170.71 107.753l-.089 283.535z"
|
|
545
559
|
), s.appendChild(r), s;
|
|
546
560
|
}
|
|
547
|
-
function
|
|
561
|
+
function qt(e) {
|
|
548
562
|
const t = "http://www.w3.org/2000/svg", s = document.createElementNS(t, "svg");
|
|
549
563
|
s.setAttribute("class", `${e}-footer-icon-pause`), s.setAttribute("viewBox", "0 0 500 500");
|
|
550
564
|
const r = document.createElementNS(t, "path");
|
|
@@ -553,7 +567,7 @@ function Bt(e) {
|
|
|
553
567
|
"M312.491 78.261c0-6.159 4.893-11.213 11.04-11.213 6.158 0 11.211 5.054 11.211 11.213v343.478c0 6.159-5.053 11.213-11.211 11.213-6.147 0-11.04-5.054-11.04-11.213V78.261zM165.257 78.261c0-6.159 4.893-11.213 11.04-11.213 6.158 0 11.211 5.054 11.211 11.213v343.478c0 6.159-5.053 11.213-11.211 11.213-6.147 0-11.04-5.054-11.04-11.213V78.261z"
|
|
554
568
|
), s.appendChild(r), s;
|
|
555
569
|
}
|
|
556
|
-
function
|
|
570
|
+
function jt(e) {
|
|
557
571
|
const t = "http://www.w3.org/2000/svg", s = document.createElementNS(t, "svg");
|
|
558
572
|
s.setAttribute("class", `${e}-footer-icon-arrow-right`), s.setAttribute("viewBox", "0 0 500 500");
|
|
559
573
|
const r = document.createElementNS(t, "path");
|
|
@@ -562,7 +576,7 @@ function Ht(e) {
|
|
|
562
576
|
"M322.19 250.041L162.527 409.705c-2.722 2.865-2.651 7.378.143 10.1 2.793 2.65 7.163 2.65 9.956 0l164.75-164.75c2.793-2.793 2.793-7.306 0-10.1l-164.75-164.75c-2.865-2.722-7.378-2.65-10.099.143-2.651 2.794-2.651 7.163 0 9.957l159.664 159.736z"
|
|
563
577
|
), s.appendChild(r), s;
|
|
564
578
|
}
|
|
565
|
-
function
|
|
579
|
+
function Gt(e) {
|
|
566
580
|
const t = "http://www.w3.org/2000/svg", s = document.createElementNS(t, "svg");
|
|
567
581
|
s.setAttribute("class", `${e}-footer-icon-save`), s.setAttribute("viewBox", "0 0 448 512");
|
|
568
582
|
const r = document.createElementNS(t, "path");
|
|
@@ -571,7 +585,7 @@ function qt(e) {
|
|
|
571
585
|
"M224 256c-35.2 0-64 28.8-64 64c0 35.2 28.8 64 64 64c35.2 0 64-28.8 64-64C288 284.8 259.2 256 224 256zM433.1 129.1l-83.9-83.9C341.1 37.06 328.8 32 316.1 32H64C28.65 32 0 60.65 0 96v320c0 35.35 28.65 64 64 64h320c35.35 0 64-28.65 64-64V163.9C448 151.2 442.9 138.9 433.1 129.1zM128 80h144V160H128V80zM400 416c0 8.836-7.164 16-16 16H64c-8.836 0-16-7.164-16-16V96c0-8.838 7.164-16 16-16h16v104c0 13.25 10.75 24 24 24h192C309.3 208 320 197.3 320 184V83.88l78.25 78.25C399.4 163.2 400 164.8 400 166.3V416z"
|
|
572
586
|
), s.appendChild(r), s;
|
|
573
587
|
}
|
|
574
|
-
function
|
|
588
|
+
function Wt(e) {
|
|
575
589
|
const t = "http://www.w3.org/2000/svg", s = document.createElementNS(t, "svg");
|
|
576
590
|
s.setAttribute("class", `${e}-footer-icon-spinner`), s.setAttribute("viewBox", "0 0 512 512");
|
|
577
591
|
const r = document.createElementNS(t, "path");
|
|
@@ -584,7 +598,7 @@ function jt(e) {
|
|
|
584
598
|
const i = document.createElementNS(t, "text");
|
|
585
599
|
return i.setAttribute("x", "125"), i.setAttribute("y", "345"), i.setAttribute("data-id", "progress"), i.style.fontSize = "246px", i.textContent = "20", s.appendChild(i), s.appendChild(r), s;
|
|
586
600
|
}
|
|
587
|
-
function
|
|
601
|
+
function Jt() {
|
|
588
602
|
let e = j;
|
|
589
603
|
const t = (p) => {
|
|
590
604
|
e = p;
|
|
@@ -599,15 +613,15 @@ function Gt() {
|
|
|
599
613
|
};
|
|
600
614
|
let o = !1, a = !1, l = 0, h = 0;
|
|
601
615
|
const c = m("div", "footer"), d = m("button", "btn-sidebar");
|
|
602
|
-
d.classList.add(v("footer-btn")), d.appendChild(
|
|
616
|
+
d.classList.add(v("footer-btn")), d.appendChild(Ut(O)), d.onclick = function() {
|
|
603
617
|
o || s();
|
|
604
618
|
}, d.style.display = "none", c.appendChild(d);
|
|
605
619
|
const f = m("div", "page-jumps"), b = m("button", "btn-page-back");
|
|
606
|
-
b.classList.add(v("footer-btn")), b.appendChild(
|
|
620
|
+
b.classList.add(v("footer-btn")), b.appendChild(Bt(O)), b.onclick = function() {
|
|
607
621
|
o || e(l - 1);
|
|
608
622
|
}, f.appendChild(b);
|
|
609
623
|
const u = m("button", "btn-page-play");
|
|
610
|
-
u.classList.add(v("footer-btn")), u.appendChild(
|
|
624
|
+
u.classList.add(v("footer-btn")), u.appendChild(Ht(O)), u.appendChild(qt(O));
|
|
611
625
|
let E = 0;
|
|
612
626
|
u.onclick = function() {
|
|
613
627
|
o || (u.classList.add(v("footer-btn-playing")), n(), clearTimeout(E), E = window.setTimeout(() => {
|
|
@@ -615,7 +629,7 @@ function Gt() {
|
|
|
615
629
|
}, 500));
|
|
616
630
|
}, f.appendChild(u);
|
|
617
631
|
const k = m("button", "btn-page-next");
|
|
618
|
-
k.classList.add(v("footer-btn")), k.appendChild(
|
|
632
|
+
k.classList.add(v("footer-btn")), k.appendChild(jt(O)), k.onclick = function() {
|
|
619
633
|
o || e(l + 1);
|
|
620
634
|
}, f.appendChild(k);
|
|
621
635
|
const V = m("div", "page-number"), I = m("input", "page-number-input");
|
|
@@ -635,7 +649,7 @@ function Gt() {
|
|
|
635
649
|
te && (te.textContent = p.toString().padStart(2, "0"));
|
|
636
650
|
} else
|
|
637
651
|
_.style.display = "none", S.style.display = "block";
|
|
638
|
-
}, S =
|
|
652
|
+
}, S = Gt(O), _ = Wt(O);
|
|
639
653
|
_.style.display = "none";
|
|
640
654
|
const $ = m("button", "footer-btn");
|
|
641
655
|
$.appendChild(S), $.onclick = function() {
|
|
@@ -666,7 +680,7 @@ function Gt() {
|
|
|
666
680
|
on_save_to_pdf: L
|
|
667
681
|
};
|
|
668
682
|
}
|
|
669
|
-
const F = typeof window < "u", qe = F && !("onscroll" in window) || typeof navigator < "u" && /(gle|ing|ro)bot|crawl|spider/i.test(navigator.userAgent), je = F && "IntersectionObserver" in window, Ge = F && "classList" in document.createElement("p"), We = F && window.devicePixelRatio > 1,
|
|
683
|
+
const F = typeof window < "u", qe = F && !("onscroll" in window) || typeof navigator < "u" && /(gle|ing|ro)bot|crawl|spider/i.test(navigator.userAgent), je = F && "IntersectionObserver" in window, Ge = F && "classList" in document.createElement("p"), We = F && window.devicePixelRatio > 1, Xt = {
|
|
670
684
|
elements_selector: ".lazy",
|
|
671
685
|
container: qe || F ? document : null,
|
|
672
686
|
threshold: 300,
|
|
@@ -699,7 +713,7 @@ const F = typeof window < "u", qe = F && !("onscroll" in window) || typeof navig
|
|
|
699
713
|
callback_cancel: null,
|
|
700
714
|
use_native: !1,
|
|
701
715
|
restore_on_error: !1
|
|
702
|
-
}, Je = (e) => Object.assign({},
|
|
716
|
+
}, Je = (e) => Object.assign({}, Xt, e), $e = function(e, t) {
|
|
703
717
|
let s;
|
|
704
718
|
const r = "LazyLoad::Initialized", n = new e(t);
|
|
705
719
|
try {
|
|
@@ -708,22 +722,22 @@ const F = typeof window < "u", qe = F && !("onscroll" in window) || typeof navig
|
|
|
708
722
|
s = document.createEvent("CustomEvent"), s.initCustomEvent(r, !1, !1, { instance: n });
|
|
709
723
|
}
|
|
710
724
|
window.dispatchEvent(s);
|
|
711
|
-
},
|
|
712
|
-
if (
|
|
725
|
+
}, Yt = (e, t) => {
|
|
726
|
+
if (t)
|
|
713
727
|
if (!t.length)
|
|
714
|
-
|
|
728
|
+
$e(e, t);
|
|
715
729
|
else
|
|
716
730
|
for (let s = 0, r; r = t[s]; s += 1)
|
|
717
|
-
|
|
718
|
-
}, N = "src",
|
|
731
|
+
$e(e, r);
|
|
732
|
+
}, N = "src", ge = "srcset", be = "sizes", Xe = "poster", K = "llOriginalAttrs", Ye = "data", me = "loading", Ze = "loaded", Ke = "applied", Zt = "entered", ve = "error", Qe = "native", et = "data-", tt = "ll-status", x = (e, t) => e.getAttribute(et + t), Kt = (e, t, s) => {
|
|
719
733
|
var r = et + t;
|
|
720
734
|
if (s === null) {
|
|
721
735
|
e.removeAttribute(r);
|
|
722
736
|
return;
|
|
723
737
|
}
|
|
724
738
|
e.setAttribute(r, s);
|
|
725
|
-
}, Q = (e) => x(e, tt), q = (e, t) =>
|
|
726
|
-
if (
|
|
739
|
+
}, Q = (e) => x(e, tt), q = (e, t) => Kt(e, tt, t), ne = (e) => q(e, null), we = (e) => Q(e) === null, Qt = (e) => Q(e) === me, es = (e) => Q(e) === ve, _e = (e) => Q(e) === Qe, ts = [me, Ze, Ke, ve], ss = (e) => ts.indexOf(Q(e)) >= 0, R = (e, t, s, r) => {
|
|
740
|
+
if (e) {
|
|
727
741
|
if (r !== void 0) {
|
|
728
742
|
e(t, s, r);
|
|
729
743
|
return;
|
|
@@ -746,47 +760,47 @@ const F = typeof window < "u", qe = F && !("onscroll" in window) || typeof navig
|
|
|
746
760
|
return;
|
|
747
761
|
}
|
|
748
762
|
e.className = e.className.replace(new RegExp("(^|\\s+)" + t + "(\\s+|$)"), " ").replace(/^\s+/, "").replace(/\s+$/, "");
|
|
749
|
-
},
|
|
763
|
+
}, rs = (e) => {
|
|
750
764
|
e.llTempImage = document.createElement("IMG");
|
|
751
|
-
},
|
|
765
|
+
}, os = (e) => {
|
|
752
766
|
delete e.llTempImage;
|
|
753
767
|
}, st = (e) => e.llTempImage, ie = (e, t) => {
|
|
754
768
|
if (!t)
|
|
755
769
|
return;
|
|
756
770
|
const s = t._observer;
|
|
757
|
-
|
|
758
|
-
},
|
|
771
|
+
s && s.unobserve(e);
|
|
772
|
+
}, ns = (e) => {
|
|
759
773
|
e.disconnect();
|
|
760
|
-
},
|
|
774
|
+
}, is = (e, t, s) => {
|
|
761
775
|
t.unobserve_entered && ie(e, s);
|
|
762
|
-
},
|
|
763
|
-
|
|
764
|
-
},
|
|
765
|
-
|
|
776
|
+
}, ye = (e, t) => {
|
|
777
|
+
e && (e.loadingCount += t);
|
|
778
|
+
}, as = (e) => {
|
|
779
|
+
e && (e.toLoadCount -= 1);
|
|
766
780
|
}, rt = (e, t) => {
|
|
767
|
-
|
|
768
|
-
},
|
|
781
|
+
e && (e.toLoadCount = t);
|
|
782
|
+
}, ls = (e) => e.loadingCount > 0, cs = (e) => e.toLoadCount > 0, ot = (e) => {
|
|
769
783
|
let t = [];
|
|
770
784
|
for (let s = 0, r; r = e.children[s]; s += 1)
|
|
771
785
|
r.tagName === "SOURCE" && t.push(r);
|
|
772
786
|
return t;
|
|
773
|
-
},
|
|
787
|
+
}, ke = (e, t) => {
|
|
774
788
|
const s = e.parentNode;
|
|
775
789
|
if (!s || s.tagName !== "PICTURE")
|
|
776
790
|
return;
|
|
777
791
|
ot(s).forEach(t);
|
|
778
792
|
}, nt = (e, t) => {
|
|
779
793
|
ot(e).forEach(t);
|
|
780
|
-
}, ae = [N], it = [N, Xe], Y = [N,
|
|
794
|
+
}, ae = [N], it = [N, Xe], Y = [N, ge, be], at = [Ye], le = (e) => !!e[K], lt = (e) => e[K], ct = (e) => delete e[K], G = (e, t) => {
|
|
781
795
|
if (le(e))
|
|
782
796
|
return;
|
|
783
797
|
const s = {};
|
|
784
798
|
t.forEach((r) => {
|
|
785
799
|
s[r] = e.getAttribute(r);
|
|
786
800
|
}), e[K] = s;
|
|
787
|
-
},
|
|
801
|
+
}, ds = (e) => {
|
|
788
802
|
le(e) || (e[K] = { backgroundImage: e.style.backgroundImage });
|
|
789
|
-
},
|
|
803
|
+
}, us = (e, t, s) => {
|
|
790
804
|
if (!s) {
|
|
791
805
|
e.removeAttribute(t);
|
|
792
806
|
return;
|
|
@@ -797,9 +811,9 @@ const F = typeof window < "u", qe = F && !("onscroll" in window) || typeof navig
|
|
|
797
811
|
return;
|
|
798
812
|
const s = lt(e);
|
|
799
813
|
t.forEach((r) => {
|
|
800
|
-
|
|
814
|
+
us(e, r, s[r]);
|
|
801
815
|
});
|
|
802
|
-
},
|
|
816
|
+
}, ps = (e) => {
|
|
803
817
|
if (!le(e))
|
|
804
818
|
return;
|
|
805
819
|
const t = lt(e);
|
|
@@ -807,30 +821,30 @@ const F = typeof window < "u", qe = F && !("onscroll" in window) || typeof navig
|
|
|
807
821
|
}, dt = (e, t, s) => {
|
|
808
822
|
J(e, t.class_applied), q(e, Ke), s && (t.unobserve_completed && ie(e, t), R(t.callback_applied, e, s));
|
|
809
823
|
}, ut = (e, t, s) => {
|
|
810
|
-
J(e, t.class_loading), q(e,
|
|
824
|
+
J(e, t.class_loading), q(e, me), s && (ye(s, 1), R(t.callback_loading, e, s));
|
|
811
825
|
}, D = (e, t, s) => {
|
|
812
|
-
|
|
813
|
-
},
|
|
814
|
-
D(e,
|
|
815
|
-
}, us = (e, t) => {
|
|
816
|
-
_e(e, (s) => {
|
|
817
|
-
G(s, Y), Le(s, t);
|
|
818
|
-
}), G(e, Y), Le(e, t);
|
|
819
|
-
}, ps = (e, t) => {
|
|
820
|
-
G(e, ae), D(e, N, x(e, t.data_src));
|
|
826
|
+
s && e.setAttribute(t, s);
|
|
827
|
+
}, Me = (e, t) => {
|
|
828
|
+
D(e, be, x(e, t.data_sizes)), D(e, ge, x(e, t.data_srcset)), D(e, N, x(e, t.data_src));
|
|
821
829
|
}, hs = (e, t) => {
|
|
830
|
+
ke(e, (s) => {
|
|
831
|
+
G(s, Y), Me(s, t);
|
|
832
|
+
}), G(e, Y), Me(e, t);
|
|
833
|
+
}, fs = (e, t) => {
|
|
834
|
+
G(e, ae), D(e, N, x(e, t.data_src));
|
|
835
|
+
}, gs = (e, t) => {
|
|
822
836
|
nt(e, (s) => {
|
|
823
837
|
G(s, ae), D(s, N, x(s, t.data_src));
|
|
824
838
|
}), G(e, it), D(e, Xe, x(e, t.data_poster)), D(e, N, x(e, t.data_src)), e.load();
|
|
825
|
-
},
|
|
839
|
+
}, bs = (e, t) => {
|
|
826
840
|
G(e, at), D(e, Ye, x(e, t.data_src));
|
|
827
|
-
},
|
|
841
|
+
}, ms = (e, t, s) => {
|
|
828
842
|
const r = x(e, t.data_bg), n = x(e, t.data_bg_hidpi), i = We && n ? n : r;
|
|
829
|
-
|
|
830
|
-
},
|
|
843
|
+
i && (e.style.backgroundImage = `url("${i}")`, st(e).setAttribute(N, i), ut(e, t, s));
|
|
844
|
+
}, vs = (e, t, s) => {
|
|
831
845
|
const r = x(e, t.data_bg_multi), n = x(e, t.data_bg_multi_hidpi), i = We && n ? n : r;
|
|
832
|
-
|
|
833
|
-
},
|
|
846
|
+
i && (e.style.backgroundImage = i, dt(e, t, s));
|
|
847
|
+
}, ws = (e, t, s) => {
|
|
834
848
|
const r = x(e, t.data_bg_set);
|
|
835
849
|
if (!r)
|
|
836
850
|
return;
|
|
@@ -838,176 +852,176 @@ const F = typeof window < "u", qe = F && !("onscroll" in window) || typeof navig
|
|
|
838
852
|
let i = n.map((o) => `image-set(${o})`);
|
|
839
853
|
e.style.backgroundImage = i.join(), e.style.backgroundImage === "" && (i = n.map((o) => `-webkit-image-set(${o})`), e.style.backgroundImage = i.join()), dt(e, t, s);
|
|
840
854
|
}, pt = {
|
|
841
|
-
IMG:
|
|
842
|
-
IFRAME:
|
|
843
|
-
VIDEO:
|
|
844
|
-
OBJECT:
|
|
845
|
-
},
|
|
855
|
+
IMG: hs,
|
|
856
|
+
IFRAME: fs,
|
|
857
|
+
VIDEO: gs,
|
|
858
|
+
OBJECT: bs
|
|
859
|
+
}, _s = (e, t) => {
|
|
846
860
|
const s = pt[e.tagName];
|
|
847
|
-
|
|
848
|
-
},
|
|
861
|
+
s && s(e, t);
|
|
862
|
+
}, ys = (e, t, s) => {
|
|
849
863
|
const r = pt[e.tagName];
|
|
850
|
-
|
|
851
|
-
},
|
|
852
|
-
t && !
|
|
853
|
-
},
|
|
864
|
+
r && (r(e, t), ut(e, t, s));
|
|
865
|
+
}, ks = ["IMG", "IFRAME", "VIDEO", "OBJECT"], Ss = (e) => ks.indexOf(e.tagName) > -1, ht = (e, t) => {
|
|
866
|
+
t && !ls(t) && !cs(t) && R(e.callback_finish, t);
|
|
867
|
+
}, Ne = (e, t, s) => {
|
|
854
868
|
e.addEventListener(t, s), e.llEvLisnrs[t] = s;
|
|
855
|
-
},
|
|
869
|
+
}, xs = (e, t, s) => {
|
|
856
870
|
e.removeEventListener(t, s);
|
|
857
|
-
},
|
|
858
|
-
|
|
871
|
+
}, Se = (e) => !!e.llEvLisnrs, Es = (e, t, s) => {
|
|
872
|
+
Se(e) || (e.llEvLisnrs = {});
|
|
859
873
|
const r = e.tagName === "VIDEO" ? "loadeddata" : "load";
|
|
860
|
-
|
|
861
|
-
},
|
|
862
|
-
if (!
|
|
874
|
+
Ne(e, r, t), Ne(e, "error", s);
|
|
875
|
+
}, fe = (e) => {
|
|
876
|
+
if (!Se(e))
|
|
863
877
|
return;
|
|
864
878
|
const t = e.llEvLisnrs;
|
|
865
879
|
for (let s in t) {
|
|
866
880
|
const r = t[s];
|
|
867
|
-
|
|
881
|
+
xs(e, s, r);
|
|
868
882
|
}
|
|
869
883
|
delete e.llEvLisnrs;
|
|
870
884
|
}, ft = (e, t, s) => {
|
|
871
|
-
|
|
872
|
-
},
|
|
873
|
-
const n =
|
|
885
|
+
os(e), ye(s, -1), as(s), M(e, t.class_loading), t.unobserve_completed && ie(e, s);
|
|
886
|
+
}, Cs = (e, t, s, r) => {
|
|
887
|
+
const n = _e(t);
|
|
874
888
|
ft(t, s, r), J(t, s.class_loaded), q(t, Ze), R(s.callback_loaded, t, r), n || ht(s, r);
|
|
875
|
-
},
|
|
876
|
-
const n =
|
|
877
|
-
ft(t, s, r), J(t, s.class_error), q(t,
|
|
878
|
-
},
|
|
889
|
+
}, As = (e, t, s, r) => {
|
|
890
|
+
const n = _e(t);
|
|
891
|
+
ft(t, s, r), J(t, s.class_error), q(t, ve), R(s.callback_error, t, r), s.restore_on_error && H(t, Y), n || ht(s, r);
|
|
892
|
+
}, xe = (e, t, s) => {
|
|
879
893
|
const r = st(e) || e;
|
|
880
|
-
if (
|
|
894
|
+
if (Se(r))
|
|
881
895
|
return;
|
|
882
|
-
|
|
883
|
-
|
|
896
|
+
Es(r, (o) => {
|
|
897
|
+
Cs(o, e, t, s), fe(r);
|
|
884
898
|
}, (o) => {
|
|
885
|
-
|
|
899
|
+
As(o, e, t, s), fe(r);
|
|
886
900
|
});
|
|
887
|
-
}, Cs = (e, t, s) => {
|
|
888
|
-
ts(e), ke(e, t, s), ls(e), gs(e, t, s), bs(e, t, s), ms(e, t, s);
|
|
889
|
-
}, As = (e, t, s) => {
|
|
890
|
-
ke(e, t, s), ws(e, t, s);
|
|
891
|
-
}, Se = (e, t, s) => {
|
|
892
|
-
ys(e) ? As(e, t, s) : Cs(e, t, s);
|
|
893
901
|
}, Is = (e, t, s) => {
|
|
894
|
-
e
|
|
895
|
-
},
|
|
896
|
-
e
|
|
897
|
-
},
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
|
|
902
|
+
rs(e), xe(e, t, s), ds(e), ms(e, t, s), vs(e, t, s), ws(e, t, s);
|
|
903
|
+
}, zs = (e, t, s) => {
|
|
904
|
+
xe(e, t, s), ys(e, t, s);
|
|
905
|
+
}, Ee = (e, t, s) => {
|
|
906
|
+
Ss(e) ? zs(e, t, s) : Is(e, t, s);
|
|
907
|
+
}, Ls = (e, t, s) => {
|
|
908
|
+
e.setAttribute("loading", "lazy"), xe(e, t, s), _s(e, t), q(e, Qe);
|
|
909
|
+
}, Oe = (e) => {
|
|
910
|
+
e.removeAttribute(N), e.removeAttribute(ge), e.removeAttribute(be);
|
|
911
|
+
}, $s = (e) => {
|
|
912
|
+
ke(e, (t) => {
|
|
913
|
+
Oe(t);
|
|
914
|
+
}), Oe(e);
|
|
901
915
|
}, gt = (e) => {
|
|
902
|
-
|
|
916
|
+
ke(e, (t) => {
|
|
903
917
|
H(t, Y);
|
|
904
918
|
}), H(e, Y);
|
|
905
|
-
},
|
|
919
|
+
}, Ms = (e) => {
|
|
906
920
|
nt(e, (t) => {
|
|
907
921
|
H(t, ae);
|
|
908
922
|
}), H(e, it), e.load();
|
|
909
|
-
},
|
|
923
|
+
}, Ns = (e) => {
|
|
910
924
|
H(e, ae);
|
|
911
|
-
},
|
|
925
|
+
}, Os = (e) => {
|
|
912
926
|
H(e, at);
|
|
913
|
-
},
|
|
927
|
+
}, Ts = {
|
|
914
928
|
IMG: gt,
|
|
915
|
-
IFRAME:
|
|
916
|
-
VIDEO:
|
|
917
|
-
OBJECT:
|
|
918
|
-
},
|
|
919
|
-
const t =
|
|
929
|
+
IFRAME: Ns,
|
|
930
|
+
VIDEO: Ms,
|
|
931
|
+
OBJECT: Os
|
|
932
|
+
}, Ps = (e) => {
|
|
933
|
+
const t = Ts[e.tagName];
|
|
920
934
|
if (!t) {
|
|
921
|
-
|
|
935
|
+
ps(e);
|
|
922
936
|
return;
|
|
923
937
|
}
|
|
924
938
|
t(e);
|
|
925
|
-
},
|
|
926
|
-
|
|
927
|
-
},
|
|
928
|
-
|
|
929
|
-
}, Ds = (e, t, s, r) => {
|
|
930
|
-
!s.cancel_on_exit || !Zt(e) || e.tagName === "IMG" && (pe(e), zs(e), gt(e), M(e, s.class_loading), we(r, -1), ne(e), R(s.callback_cancel, e, t, r));
|
|
931
|
-
}, Fs = (e, t, s, r) => {
|
|
932
|
-
const n = es(e);
|
|
933
|
-
q(e, Xt), J(e, s.class_entered), M(e, s.class_exited), os(e, s, r), R(s.callback_enter, e, t, r), !n && Se(e, s, r);
|
|
939
|
+
}, Ds = (e, t) => {
|
|
940
|
+
we(e) || _e(e) || (M(e, t.class_entered), M(e, t.class_exited), M(e, t.class_applied), M(e, t.class_loading), M(e, t.class_loaded), M(e, t.class_error));
|
|
941
|
+
}, Fs = (e, t) => {
|
|
942
|
+
Ps(e), Ds(e, t), ne(e), ct(e);
|
|
934
943
|
}, Rs = (e, t, s, r) => {
|
|
935
|
-
|
|
936
|
-
}, Vs =
|
|
944
|
+
s.cancel_on_exit && Qt(e) && e.tagName === "IMG" && (fe(e), $s(e), gt(e), M(e, s.class_loading), ye(r, -1), ne(e), R(s.callback_cancel, e, t, r));
|
|
945
|
+
}, Vs = (e, t, s, r) => {
|
|
946
|
+
const n = ss(e);
|
|
947
|
+
q(e, Zt), J(e, s.class_entered), M(e, s.class_exited), is(e, s, r), R(s.callback_enter, e, t, r), !n && Ee(e, s, r);
|
|
948
|
+
}, Us = (e, t, s, r) => {
|
|
949
|
+
we(e) || (J(e, s.class_exited), Rs(e, t, s, r), R(s.callback_exit, e, t, r));
|
|
950
|
+
}, Bs = ["IMG", "IFRAME", "VIDEO"], bt = (e) => e.use_native && "loading" in HTMLImageElement.prototype, Hs = (e, t, s) => {
|
|
937
951
|
e.forEach((r) => {
|
|
938
|
-
|
|
952
|
+
Bs.indexOf(r.tagName) !== -1 && Ls(r, t, s);
|
|
939
953
|
}), rt(s, 0);
|
|
940
|
-
},
|
|
954
|
+
}, qs = (e) => e.isIntersecting || e.intersectionRatio > 0, js = (e) => ({
|
|
941
955
|
root: e.container === document ? null : e.container,
|
|
942
956
|
rootMargin: e.thresholds || e.threshold + "px"
|
|
943
|
-
}),
|
|
957
|
+
}), Gs = (e, t, s) => {
|
|
944
958
|
e.forEach(
|
|
945
|
-
(r) =>
|
|
959
|
+
(r) => qs(r) ? Vs(r.target, r, t, s) : Us(r.target, r, t, s)
|
|
946
960
|
);
|
|
947
|
-
},
|
|
961
|
+
}, Ws = (e, t) => {
|
|
948
962
|
t.forEach((s) => {
|
|
949
963
|
e.observe(s);
|
|
950
964
|
});
|
|
951
|
-
},
|
|
952
|
-
|
|
953
|
-
},
|
|
965
|
+
}, Js = (e, t) => {
|
|
966
|
+
ns(e), Ws(e, t);
|
|
967
|
+
}, Xs = (e, t) => {
|
|
954
968
|
!je || bt(e) || (t._observer = new IntersectionObserver((s) => {
|
|
955
|
-
|
|
956
|
-
},
|
|
957
|
-
}, mt = (e) => Array.prototype.slice.call(e), oe = (e) => e.container.querySelectorAll(e.elements_selector),
|
|
958
|
-
|
|
969
|
+
Gs(s, e, t);
|
|
970
|
+
}, js(e)));
|
|
971
|
+
}, mt = (e) => Array.prototype.slice.call(e), oe = (e) => e.container.querySelectorAll(e.elements_selector), Ys = (e) => mt(e).filter(we), Zs = (e) => es(e), Ks = (e) => mt(e).filter(Zs), Te = (e, t) => Ys(e || oe(t)), Qs = (e, t) => {
|
|
972
|
+
Ks(oe(e)).forEach((r) => {
|
|
959
973
|
M(r, e.class_error), ne(r);
|
|
960
974
|
}), t.update();
|
|
961
|
-
},
|
|
962
|
-
|
|
963
|
-
|
|
975
|
+
}, er = (e, t) => {
|
|
976
|
+
F && (t._onlineHandler = () => {
|
|
977
|
+
Qs(e, t);
|
|
964
978
|
}, window.addEventListener("online", t._onlineHandler));
|
|
965
|
-
},
|
|
966
|
-
|
|
979
|
+
}, tr = (e) => {
|
|
980
|
+
F && window.removeEventListener("online", e._onlineHandler);
|
|
967
981
|
}, ee = function(e, t) {
|
|
968
982
|
const s = Je(e);
|
|
969
|
-
this._settings = s, this.loadingCount = 0,
|
|
983
|
+
this._settings = s, this.loadingCount = 0, Xs(s, this), er(s, this), this.update(t);
|
|
970
984
|
};
|
|
971
985
|
ee.prototype = {
|
|
972
986
|
update: function(e) {
|
|
973
|
-
const t = this._settings, s =
|
|
987
|
+
const t = this._settings, s = Te(e, t);
|
|
974
988
|
if (rt(this, s.length), qe || !je) {
|
|
975
989
|
this.loadAll(s);
|
|
976
990
|
return;
|
|
977
991
|
}
|
|
978
992
|
if (bt(t)) {
|
|
979
|
-
|
|
993
|
+
Hs(s, t, this);
|
|
980
994
|
return;
|
|
981
995
|
}
|
|
982
|
-
|
|
996
|
+
Js(this._observer, s);
|
|
983
997
|
},
|
|
984
998
|
destroy: function() {
|
|
985
|
-
this._observer && this._observer.disconnect(),
|
|
999
|
+
this._observer && this._observer.disconnect(), tr(this), oe(this._settings).forEach((e) => {
|
|
986
1000
|
ct(e);
|
|
987
1001
|
}), delete this._observer, delete this._settings, delete this._onlineHandler, delete this.loadingCount, delete this.toLoadCount;
|
|
988
1002
|
},
|
|
989
1003
|
loadAll: function(e) {
|
|
990
1004
|
const t = this._settings;
|
|
991
|
-
|
|
992
|
-
ie(r, this),
|
|
1005
|
+
Te(e, t).forEach((r) => {
|
|
1006
|
+
ie(r, this), Ee(r, t, this);
|
|
993
1007
|
});
|
|
994
1008
|
},
|
|
995
1009
|
restoreAll: function() {
|
|
996
1010
|
const e = this._settings;
|
|
997
1011
|
oe(e).forEach((t) => {
|
|
998
|
-
|
|
1012
|
+
Fs(t, e);
|
|
999
1013
|
});
|
|
1000
1014
|
}
|
|
1001
1015
|
};
|
|
1002
1016
|
ee.load = (e, t) => {
|
|
1003
1017
|
const s = Je(t);
|
|
1004
|
-
|
|
1018
|
+
Ee(e, s);
|
|
1005
1019
|
};
|
|
1006
1020
|
ee.resetStatus = (e) => {
|
|
1007
1021
|
ne(e);
|
|
1008
1022
|
};
|
|
1009
|
-
F &&
|
|
1010
|
-
function
|
|
1023
|
+
F && Yt(ee, window.lazyLoadOptions);
|
|
1024
|
+
function sr() {
|
|
1011
1025
|
let e = j;
|
|
1012
1026
|
const t = (g) => {
|
|
1013
1027
|
e = g;
|
|
@@ -1078,7 +1092,7 @@ function er() {
|
|
|
1078
1092
|
}
|
|
1079
1093
|
const vt = class {
|
|
1080
1094
|
constructor(e) {
|
|
1081
|
-
this.sideEffect = new
|
|
1095
|
+
this.sideEffect = new De(), this.events = new Ct(), this.$slide = m("div", "slide"), this.$overlay = m("div", "overlay"), this.sidebar = sr(), this.footer = Jt(), this._getWhiteSnapshot = null, this._slideTitle = "", this._ready = !1, this._slideCount = 0, this._destroyed = !1, this._isFrozen = !1, this._cachedIsFrozen = !1, this.onPlay = () => {
|
|
1082
1096
|
this.slide.nextStep();
|
|
1083
1097
|
}, this.onNewPageIndex = (o) => {
|
|
1084
1098
|
this._ready && o >= 0 && o < this._slideCount ? this.slide.renderSlide(o + 1) : this.setPage(this.slide.slideState.currentSlideIndex);
|
|
@@ -1118,11 +1132,11 @@ const vt = class {
|
|
|
1118
1132
|
}, this.$content = this.sidebar.$content, this.$footer = this.footer.$footer, B(this.$content, this.$slide), B(this.$content, this.$overlay), this.sidebar.on_new_page_index(this.onNewPageIndex), this.footer.on_new_page_index(this.onNewPageIndex), this.footer.on_toggle_preview(this.onTogglePreview), this.footer.on_play(this.onPlay), this.footer.on_save_to_pdf(this.toPdf), this.sideEffect.push(this.sidebar.destroy), this.sideEffect.push(() => this.slide.destroy()), this.sideEffect.push(() => {
|
|
1119
1133
|
this.$content.parentElement && this.$content.remove(), this.$footer.parentElement && this.$footer.remove(), this.$slide.parentElement && this.$slide.remove();
|
|
1120
1134
|
}), this.sideEffect.push(
|
|
1121
|
-
|
|
1135
|
+
Rt((o) => {
|
|
1122
1136
|
this._destroyed || (o ? this._cachedIsFrozen || this.unfreeze() : (this._cachedIsFrozen = this._isFrozen, this.freeze()));
|
|
1123
1137
|
})
|
|
1124
1138
|
);
|
|
1125
|
-
const [t, s] =
|
|
1139
|
+
const [t, s] = Le();
|
|
1126
1140
|
this._infoPromise = t, vt.fetchSlideInfo(e).then(({ preview: o, slide: a }) => {
|
|
1127
1141
|
if (!this._destroyed) {
|
|
1128
1142
|
if (this._slideCount = a.slideCount, o) {
|
|
@@ -1138,7 +1152,7 @@ const vt = class {
|
|
|
1138
1152
|
}).catch((o) => {
|
|
1139
1153
|
console.log("[Slide] fetch slide info error"), console.error(o), this.events.emit("prepareError", o);
|
|
1140
1154
|
});
|
|
1141
|
-
const [n, i] =
|
|
1155
|
+
const [n, i] = Le();
|
|
1142
1156
|
this._readyPromise = n, this.slide = new ue({
|
|
1143
1157
|
anchor: this.$slide,
|
|
1144
1158
|
mode: "local",
|
|
@@ -1146,7 +1160,7 @@ const vt = class {
|
|
|
1146
1160
|
enableGlobalClick: !0,
|
|
1147
1161
|
useLocalCache: !0,
|
|
1148
1162
|
...e
|
|
1149
|
-
}), this.slide.setResource(e.taskId, e.url ||
|
|
1163
|
+
}), this.slide.setResource(e.taskId, e.url || Fe), this.slide.on("slideChange", (o) => {
|
|
1150
1164
|
this._destroyed || this.setPage(o);
|
|
1151
1165
|
}), this.slide.on("renderEnd", () => {
|
|
1152
1166
|
this._ready ? this.$overlay.style.opacity = "" : setTimeout(() => {
|
|
@@ -1187,25 +1201,25 @@ const vt = class {
|
|
|
1187
1201
|
}
|
|
1188
1202
|
};
|
|
1189
1203
|
let W = vt;
|
|
1190
|
-
W.styles =
|
|
1191
|
-
W.fetchSlideInfo =
|
|
1192
|
-
function
|
|
1204
|
+
W.styles = Vt;
|
|
1205
|
+
W.fetchSlideInfo = Ft;
|
|
1206
|
+
function rr(e) {
|
|
1193
1207
|
return e.displayer.logger;
|
|
1194
1208
|
}
|
|
1195
1209
|
const T = class {
|
|
1196
1210
|
constructor(e) {
|
|
1197
1211
|
this.context = e, this.info = (t) => {
|
|
1198
1212
|
T.roomLogger && this.context ? T.roomLogger.info(t + ` (${this.context.appId})`) : this.context ? console.debug(t + ` (${this.context.appId})`) : console.debug(t);
|
|
1199
|
-
}, e && (T.active.add(e.appId), T.roomLogger =
|
|
1213
|
+
}, e && (T.active.add(e.appId), T.roomLogger = rr(e));
|
|
1200
1214
|
}
|
|
1201
1215
|
destroy() {
|
|
1202
1216
|
this.context && T.active.delete(this.context.appId), T.active.size === 0 && (T.roomLogger = null);
|
|
1203
1217
|
}
|
|
1204
1218
|
};
|
|
1205
|
-
let
|
|
1206
|
-
|
|
1207
|
-
|
|
1208
|
-
function
|
|
1219
|
+
let Ce = T;
|
|
1220
|
+
Ce.active = /* @__PURE__ */ new Set();
|
|
1221
|
+
Ce.roomLogger = null;
|
|
1222
|
+
function or({ context: e, storage: t, viewer: s, sideEffect: r, logger: n }) {
|
|
1209
1223
|
const i = n.info.bind(n);
|
|
1210
1224
|
let o = null;
|
|
1211
1225
|
s.prepare(({ width: c, height: d, slideCount: f }) => {
|
|
@@ -1252,14 +1266,14 @@ function sr({ context: e, storage: t, viewer: s, sideEffect: r, logger: n }) {
|
|
|
1252
1266
|
}
|
|
1253
1267
|
}
|
|
1254
1268
|
a.on("stateChange", () => {
|
|
1255
|
-
|
|
1269
|
+
t.isWritable && t.setState({ state: a.slideState });
|
|
1256
1270
|
}), a.on("syncDispatch", (c) => {
|
|
1257
|
-
e.isWritable && (i("[Slide] dispatch " + l(
|
|
1271
|
+
e.isWritable && (i("[Slide] dispatch " + l(ze(c, "uuid"))), e.dispatchMagixEvent("syncDispatch", c));
|
|
1258
1272
|
}), r.push(
|
|
1259
1273
|
e.addMagixEventListener(
|
|
1260
1274
|
"syncDispatch",
|
|
1261
1275
|
({ payload: c }) => {
|
|
1262
|
-
i("[Slide] receive " + l(
|
|
1276
|
+
i("[Slide] receive " + l(ze(c, "uuid"))), a.emit("syncReceive", c);
|
|
1263
1277
|
},
|
|
1264
1278
|
{ fireSelfEventAfterCommit: !0 }
|
|
1265
1279
|
)
|
|
@@ -1273,22 +1287,22 @@ function sr({ context: e, storage: t, viewer: s, sideEffect: r, logger: n }) {
|
|
|
1273
1287
|
e.box.focus && ((c.key === "ArrowUp" || c.key === "ArrowLeft") && s.slide.prevStep(), (c.key === "ArrowRight" || c.key === "ArrowDown") && s.slide.nextStep());
|
|
1274
1288
|
});
|
|
1275
1289
|
}
|
|
1276
|
-
function
|
|
1290
|
+
function ar(e) {
|
|
1277
1291
|
const { container: t, ...s } = e, r = m("div", "preview-wrapper"), n = new W(s);
|
|
1278
1292
|
return r.appendChild(document.createElement("style")).textContent = W.styles, r.appendChild(n.$content), r.appendChild(n.$footer), t.appendChild(r), n.prepare(() => n.slide.renderSlide(1)), n;
|
|
1279
1293
|
}
|
|
1280
|
-
const
|
|
1294
|
+
const lr = /* @__PURE__ */ ue.usePlugin.bind(ue), cr = "0.3.0-canary.17", dr = {
|
|
1281
1295
|
kind: "Slide",
|
|
1282
1296
|
setup(e) {
|
|
1283
|
-
console.log("[Slide] setup @ 0.3.0-canary.
|
|
1284
|
-
const t = new
|
|
1285
|
-
if (t.info("[Slide] setup @ 0.3.0-canary.
|
|
1297
|
+
console.log("[Slide] setup @ 0.3.0-canary.17 (" + e.appId + ")");
|
|
1298
|
+
const t = new Ce(e);
|
|
1299
|
+
if (t.info("[Slide] setup @ 0.3.0-canary.17"), !e.attributes.taskId)
|
|
1286
1300
|
throw new Error("[Slide] no taskId");
|
|
1287
|
-
const s = e.createStorage("slide", e.attributes), r = e.getAppOptions() || {}, n = r.renderOptions || {}, i = new
|
|
1301
|
+
const s = e.createStorage("slide", e.attributes), r = e.getAppOptions() || {}, n = r.renderOptions || {}, i = new De(), o = new W({
|
|
1288
1302
|
interactive: !0,
|
|
1289
1303
|
mode: "interactive",
|
|
1290
1304
|
enableGlobalClick: !0,
|
|
1291
|
-
timestamp:
|
|
1305
|
+
timestamp: Pt(e),
|
|
1292
1306
|
logger: r.logger || t,
|
|
1293
1307
|
renderOptions: {
|
|
1294
1308
|
minFPS: n.minFPS || 25,
|
|
@@ -1308,7 +1322,7 @@ const ir = /* @__PURE__ */ ue.usePlugin.bind(ue), ar = "0.3.0-canary.16", lr = {
|
|
|
1308
1322
|
taskId: s.state.taskId,
|
|
1309
1323
|
url: s.state.url
|
|
1310
1324
|
});
|
|
1311
|
-
return Object.assign(o, { context: e, logger: t }), i.push(
|
|
1325
|
+
return Object.assign(o, { context: e, logger: t }), i.push(Re.set(e.appId, o, e.box)), i.push(o.events.on("freeze", () => t.info("[Slide] freeze"))), i.push(o.events.on("unfreeze", () => t.info("[Slide] unfreeze"))), i.push(
|
|
1312
1326
|
o.events.on(
|
|
1313
1327
|
"prepareError",
|
|
1314
1328
|
(a) => t.info("[Slide] fetch slide info failed: " + a.message)
|
|
@@ -1318,20 +1332,20 @@ const ir = /* @__PURE__ */ ue.usePlugin.bind(ue), ar = "0.3.0-canary.16", lr = {
|
|
|
1318
1332
|
"renderError",
|
|
1319
1333
|
({ error: a, index: l }) => t.info(`[Slide] render failed [${l}]: ${a.message}`)
|
|
1320
1334
|
)
|
|
1321
|
-
), e.box.mountStyles(W.styles), e.box.mountStage(o.$slide), e.box.mountFooter(o.$footer), e.box.mountContent(o.$content), i.push(() => o.destroy()),
|
|
1335
|
+
), e.box.mountStyles(W.styles), e.box.mountStage(o.$slide), e.box.mountFooter(o.$footer), e.box.mountContent(o.$content), i.push(() => o.destroy()), or({ context: e, storage: s, viewer: o, sideEffect: i, logger: t }), e.emitter.on("destroy", () => {
|
|
1322
1336
|
t.info("[Slide] destroy"), t.destroy(), i.flushAll();
|
|
1323
1337
|
}), o;
|
|
1324
1338
|
}
|
|
1325
1339
|
};
|
|
1326
1340
|
export {
|
|
1327
|
-
|
|
1328
|
-
|
|
1341
|
+
Fe as DefaultUrl,
|
|
1342
|
+
hr as Slide,
|
|
1329
1343
|
W as SlideViewer,
|
|
1330
|
-
|
|
1331
|
-
|
|
1332
|
-
|
|
1333
|
-
|
|
1334
|
-
|
|
1335
|
-
|
|
1344
|
+
ir as addHooks,
|
|
1345
|
+
dr as default,
|
|
1346
|
+
ar as previewSlide,
|
|
1347
|
+
Re as refrigerator,
|
|
1348
|
+
lr as usePlugin,
|
|
1349
|
+
cr as version
|
|
1336
1350
|
};
|
|
1337
1351
|
//# sourceMappingURL=main.mjs.map
|