@uxland/primary-shell 7.47.4 → 7.47.6
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/{component-CY-RSUBM.js → component-CQxI1o5p.js} +2 -2
- package/dist/{component-CY-RSUBM.js.map → component-CQxI1o5p.js.map} +1 -1
- package/dist/{index-BaVXV730.js → index-DSO8ViDu.js} +555 -506
- package/dist/index-DSO8ViDu.js.map +1 -0
- package/dist/index.js +1 -1
- package/dist/index.umd.cjs +8 -8
- package/dist/index.umd.cjs.map +1 -1
- package/dist/{plugin-DpQd-ZC5.js → plugin-DohFiwSH.js} +2 -2
- package/dist/{plugin-DpQd-ZC5.js.map → plugin-DohFiwSH.js.map} +1 -1
- package/dist/primary/shell/src/api/region-manager/region-manager.d.ts +4 -3
- package/dist/primary/shell/src/api/region-manager/remove-view-idempotency.test.d.ts +1 -0
- package/dist/primary/shell/src/disposer.d.ts +1 -1
- package/dist/primary/shell/src/features/bootstrapper.d.ts +1 -1
- package/dist/primary/shell/src/features/exit/handler.d.ts +12 -0
- package/package.json +1 -1
- package/src/UI/components/primaria-shell/primaria-shell.ts +3 -1
- package/src/api/region-manager/region-manager.test.ts +57 -2
- package/src/api/region-manager/region-manager.ts +39 -7
- package/src/api/region-manager/remove-view-idempotency.test.ts +98 -0
- package/src/disposer.ts +2 -2
- package/src/features/bootstrapper.ts +2 -2
- package/src/features/exit/handler.test.ts +60 -0
- package/src/features/exit/handler.ts +18 -2
- package/dist/index-BaVXV730.js.map +0 -1
|
@@ -70,7 +70,7 @@ function require_Reflect() {
|
|
|
70
70
|
}
|
|
71
71
|
}, he = Object.getPrototypeOf(Function), ge = typeof Map == "function" && typeof Map.prototype.entries == "function" ? Map : Xt(), ve = typeof Set == "function" && typeof Set.prototype.entries == "function" ? Set : As(), me = typeof WeakMap == "function" ? WeakMap : is(), _e = re ? Symbol.for("@reflect-metadata:registry") : void 0, ye = Ft(), Ae = Ut(ye);
|
|
72
72
|
function Ce(ot, gt, yt, Ct) {
|
|
73
|
-
if (
|
|
73
|
+
if (Ve(yt)) {
|
|
74
74
|
if (!Pt(ot))
|
|
75
75
|
throw new TypeError();
|
|
76
76
|
if (!Ht(gt))
|
|
@@ -79,9 +79,9 @@ function require_Reflect() {
|
|
|
79
79
|
} else {
|
|
80
80
|
if (!Pt(ot))
|
|
81
81
|
throw new TypeError();
|
|
82
|
-
if (!
|
|
82
|
+
if (!Be(gt))
|
|
83
83
|
throw new TypeError();
|
|
84
|
-
if (!
|
|
84
|
+
if (!Be(Ct) && !Ve(Ct) && !Qe(Ct))
|
|
85
85
|
throw new TypeError();
|
|
86
86
|
return Qe(Ct) && (Ct = void 0), yt = St(yt), He(ot, gt, yt, Ct);
|
|
87
87
|
}
|
|
@@ -89,9 +89,9 @@ function require_Reflect() {
|
|
|
89
89
|
te("decorate", Ce);
|
|
90
90
|
function we(ot, gt) {
|
|
91
91
|
function yt(Ct, Mt) {
|
|
92
|
-
if (!
|
|
92
|
+
if (!Be(Ct))
|
|
93
93
|
throw new TypeError();
|
|
94
|
-
if (!
|
|
94
|
+
if (!Ve(Mt) && !jt(Mt))
|
|
95
95
|
throw new TypeError();
|
|
96
96
|
Xe(ot, gt, Ct, Mt);
|
|
97
97
|
}
|
|
@@ -99,66 +99,66 @@ function require_Reflect() {
|
|
|
99
99
|
}
|
|
100
100
|
te("metadata", we);
|
|
101
101
|
function Se(ot, gt, yt, Ct) {
|
|
102
|
-
if (!
|
|
102
|
+
if (!Be(yt))
|
|
103
103
|
throw new TypeError();
|
|
104
|
-
return
|
|
104
|
+
return Ve(Ct) || (Ct = St(Ct)), Xe(ot, gt, yt, Ct);
|
|
105
105
|
}
|
|
106
106
|
te("defineMetadata", Se);
|
|
107
107
|
function Me(ot, gt, yt) {
|
|
108
|
-
if (!
|
|
108
|
+
if (!Be(gt))
|
|
109
109
|
throw new TypeError();
|
|
110
|
-
return
|
|
110
|
+
return Ve(yt) || (yt = St(yt)), Ge(ot, gt, yt);
|
|
111
111
|
}
|
|
112
112
|
te("hasMetadata", Me);
|
|
113
113
|
function Ie(ot, gt, yt) {
|
|
114
|
-
if (!
|
|
114
|
+
if (!Be(gt))
|
|
115
115
|
throw new TypeError();
|
|
116
|
-
return
|
|
116
|
+
return Ve(yt) || (yt = St(yt)), Ze(ot, gt, yt);
|
|
117
117
|
}
|
|
118
118
|
te("hasOwnMetadata", Ie);
|
|
119
119
|
function ze(ot, gt, yt) {
|
|
120
|
-
if (!
|
|
120
|
+
if (!Be(gt))
|
|
121
121
|
throw new TypeError();
|
|
122
|
-
return
|
|
122
|
+
return Ve(yt) || (yt = St(yt)), Ye(ot, gt, yt);
|
|
123
123
|
}
|
|
124
124
|
te("getMetadata", ze);
|
|
125
125
|
function Ue(ot, gt, yt) {
|
|
126
|
-
if (!
|
|
126
|
+
if (!Be(gt))
|
|
127
127
|
throw new TypeError();
|
|
128
|
-
return
|
|
128
|
+
return Ve(yt) || (yt = St(yt)), bt(ot, gt, yt);
|
|
129
129
|
}
|
|
130
130
|
te("getOwnMetadata", Ue);
|
|
131
131
|
function Le(ot, gt) {
|
|
132
|
-
if (!
|
|
132
|
+
if (!Be(ot))
|
|
133
133
|
throw new TypeError();
|
|
134
|
-
return
|
|
134
|
+
return Ve(gt) || (gt = St(gt)), Ke(ot, gt);
|
|
135
135
|
}
|
|
136
136
|
te("getMetadataKeys", Le);
|
|
137
137
|
function Oe(ot, gt) {
|
|
138
|
-
if (!
|
|
138
|
+
if (!Be(ot))
|
|
139
139
|
throw new TypeError();
|
|
140
|
-
return
|
|
140
|
+
return Ve(gt) || (gt = St(gt)), Fe(ot, gt);
|
|
141
141
|
}
|
|
142
142
|
te("getOwnMetadataKeys", Oe);
|
|
143
143
|
function qe(ot, gt, yt) {
|
|
144
|
-
if (!
|
|
144
|
+
if (!Be(gt))
|
|
145
145
|
throw new TypeError();
|
|
146
|
-
if (
|
|
146
|
+
if (Ve(yt) || (yt = St(yt)), !Be(gt))
|
|
147
147
|
throw new TypeError();
|
|
148
|
-
|
|
148
|
+
Ve(yt) || (yt = St(yt));
|
|
149
149
|
var Ct = cs(
|
|
150
150
|
gt,
|
|
151
151
|
yt,
|
|
152
152
|
/*Create*/
|
|
153
153
|
!1
|
|
154
154
|
);
|
|
155
|
-
return
|
|
155
|
+
return Ve(Ct) ? !1 : Ct.OrdinaryDeleteMetadata(ot, gt, yt);
|
|
156
156
|
}
|
|
157
157
|
te("deleteMetadata", qe);
|
|
158
158
|
function Pe(ot, gt) {
|
|
159
159
|
for (var yt = ot.length - 1; yt >= 0; --yt) {
|
|
160
160
|
var Ct = ot[yt], Mt = Ct(gt);
|
|
161
|
-
if (!
|
|
161
|
+
if (!Ve(Mt) && !Qe(Mt)) {
|
|
162
162
|
if (!Ht(Mt))
|
|
163
163
|
throw new TypeError();
|
|
164
164
|
gt = Mt;
|
|
@@ -169,8 +169,8 @@ function require_Reflect() {
|
|
|
169
169
|
function He(ot, gt, yt, Ct) {
|
|
170
170
|
for (var Mt = ot.length - 1; Mt >= 0; --Mt) {
|
|
171
171
|
var rs = ot[Mt], ds = rs(gt, yt, Ct);
|
|
172
|
-
if (!
|
|
173
|
-
if (!
|
|
172
|
+
if (!Ve(ds) && !Qe(ds)) {
|
|
173
|
+
if (!Be(ds))
|
|
174
174
|
throw new TypeError();
|
|
175
175
|
Ct = ds;
|
|
176
176
|
}
|
|
@@ -191,7 +191,7 @@ function require_Reflect() {
|
|
|
191
191
|
/*Create*/
|
|
192
192
|
!1
|
|
193
193
|
);
|
|
194
|
-
return
|
|
194
|
+
return Ve(Ct) ? !1 : ft(Ct.OrdinaryHasOwnMetadata(ot, gt, yt));
|
|
195
195
|
}
|
|
196
196
|
function Ye(ot, gt, yt) {
|
|
197
197
|
var Ct = Ze(ot, gt, yt);
|
|
@@ -208,7 +208,7 @@ function require_Reflect() {
|
|
|
208
208
|
/*Create*/
|
|
209
209
|
!1
|
|
210
210
|
);
|
|
211
|
-
if (!
|
|
211
|
+
if (!Ve(Ct))
|
|
212
212
|
return Ct.OrdinaryGetOwnMetadata(ot, gt, yt);
|
|
213
213
|
}
|
|
214
214
|
function Xe(ot, gt, yt, Ct) {
|
|
@@ -229,12 +229,12 @@ function require_Reflect() {
|
|
|
229
229
|
return yt;
|
|
230
230
|
if (yt.length <= 0)
|
|
231
231
|
return Mt;
|
|
232
|
-
for (var rs = new ve(), ds = [],
|
|
233
|
-
var Dt = Ot[
|
|
232
|
+
for (var rs = new ve(), ds = [], Bt = 0, Ot = yt; Bt < Ot.length; Bt++) {
|
|
233
|
+
var Dt = Ot[Bt], Lt = rs.has(Dt);
|
|
234
234
|
Lt || (rs.add(Dt), ds.push(Dt));
|
|
235
235
|
}
|
|
236
|
-
for (var qt = 0,
|
|
237
|
-
var Dt =
|
|
236
|
+
for (var qt = 0, Vt = Mt; qt < Vt.length; qt++) {
|
|
237
|
+
var Dt = Vt[qt], Lt = rs.has(Dt);
|
|
238
238
|
Lt || (rs.add(Dt), ds.push(Dt));
|
|
239
239
|
}
|
|
240
240
|
return ds;
|
|
@@ -268,7 +268,7 @@ function require_Reflect() {
|
|
|
268
268
|
return 6;
|
|
269
269
|
}
|
|
270
270
|
}
|
|
271
|
-
function
|
|
271
|
+
function Ve(ot) {
|
|
272
272
|
return ot === void 0;
|
|
273
273
|
}
|
|
274
274
|
function Qe(ot) {
|
|
@@ -277,7 +277,7 @@ function require_Reflect() {
|
|
|
277
277
|
function tt(ot) {
|
|
278
278
|
return typeof ot == "symbol";
|
|
279
279
|
}
|
|
280
|
-
function
|
|
280
|
+
function Be(ot) {
|
|
281
281
|
return typeof ot == "object" ? ot !== null : typeof ot == "function";
|
|
282
282
|
}
|
|
283
283
|
function Je(ot, gt) {
|
|
@@ -298,7 +298,7 @@ function require_Reflect() {
|
|
|
298
298
|
var yt = "string", Ct = es(ot, de);
|
|
299
299
|
if (Ct !== void 0) {
|
|
300
300
|
var Mt = Ct.call(ot, yt);
|
|
301
|
-
if (
|
|
301
|
+
if (Be(Mt))
|
|
302
302
|
throw new TypeError();
|
|
303
303
|
return Mt;
|
|
304
304
|
}
|
|
@@ -310,13 +310,13 @@ function require_Reflect() {
|
|
|
310
310
|
var rs = ot.toString;
|
|
311
311
|
if (It(rs)) {
|
|
312
312
|
var Ct = rs.call(ot);
|
|
313
|
-
if (!
|
|
313
|
+
if (!Be(Ct))
|
|
314
314
|
return Ct;
|
|
315
315
|
}
|
|
316
316
|
var yt = ot.valueOf;
|
|
317
317
|
if (It(yt)) {
|
|
318
318
|
var Ct = yt.call(ot);
|
|
319
|
-
if (!
|
|
319
|
+
if (!Be(Ct))
|
|
320
320
|
return Ct;
|
|
321
321
|
}
|
|
322
322
|
}
|
|
@@ -367,7 +367,7 @@ function require_Reflect() {
|
|
|
367
367
|
if (!It(gt))
|
|
368
368
|
throw new TypeError();
|
|
369
369
|
var yt = gt.call(ot);
|
|
370
|
-
if (!
|
|
370
|
+
if (!Be(yt))
|
|
371
371
|
throw new TypeError();
|
|
372
372
|
return yt;
|
|
373
373
|
}
|
|
@@ -394,7 +394,7 @@ function require_Reflect() {
|
|
|
394
394
|
}
|
|
395
395
|
function Nt() {
|
|
396
396
|
var ot;
|
|
397
|
-
!
|
|
397
|
+
!Ve(_e) && typeof oe.Reflect < "u" && !(_e in oe.Reflect) && typeof oe.Reflect.defineMetadata == "function" && (ot = us(oe.Reflect));
|
|
398
398
|
var gt, yt, Ct, Mt = new me(), rs = {
|
|
399
399
|
registerProvider: ds,
|
|
400
400
|
getProvider: Ot,
|
|
@@ -407,12 +407,12 @@ function require_Reflect() {
|
|
|
407
407
|
switch (!0) {
|
|
408
408
|
case ot === qt:
|
|
409
409
|
break;
|
|
410
|
-
case
|
|
410
|
+
case Ve(gt):
|
|
411
411
|
gt = qt;
|
|
412
412
|
break;
|
|
413
413
|
case gt === qt:
|
|
414
414
|
break;
|
|
415
|
-
case
|
|
415
|
+
case Ve(yt):
|
|
416
416
|
yt = qt;
|
|
417
417
|
break;
|
|
418
418
|
case yt === qt:
|
|
@@ -422,52 +422,52 @@ function require_Reflect() {
|
|
|
422
422
|
break;
|
|
423
423
|
}
|
|
424
424
|
}
|
|
425
|
-
function
|
|
426
|
-
if (!
|
|
427
|
-
if (gt.isProviderFor(qt,
|
|
425
|
+
function Bt(qt, Vt) {
|
|
426
|
+
if (!Ve(gt)) {
|
|
427
|
+
if (gt.isProviderFor(qt, Vt))
|
|
428
428
|
return gt;
|
|
429
|
-
if (!
|
|
430
|
-
if (yt.isProviderFor(qt,
|
|
429
|
+
if (!Ve(yt)) {
|
|
430
|
+
if (yt.isProviderFor(qt, Vt))
|
|
431
431
|
return gt;
|
|
432
|
-
if (!
|
|
432
|
+
if (!Ve(Ct))
|
|
433
433
|
for (var ts = vt(Ct); ; ) {
|
|
434
434
|
var as = At(ts);
|
|
435
435
|
if (!as)
|
|
436
436
|
return;
|
|
437
437
|
var fs = _t(as);
|
|
438
|
-
if (fs.isProviderFor(qt,
|
|
438
|
+
if (fs.isProviderFor(qt, Vt))
|
|
439
439
|
return Et(ts), fs;
|
|
440
440
|
}
|
|
441
441
|
}
|
|
442
442
|
}
|
|
443
|
-
if (!
|
|
443
|
+
if (!Ve(ot) && ot.isProviderFor(qt, Vt))
|
|
444
444
|
return ot;
|
|
445
445
|
}
|
|
446
|
-
function Ot(qt,
|
|
446
|
+
function Ot(qt, Vt) {
|
|
447
447
|
var ts = Mt.get(qt), as;
|
|
448
|
-
return
|
|
448
|
+
return Ve(ts) || (as = ts.get(Vt)), Ve(as) && (as = Bt(qt, Vt), Ve(as) || (Ve(ts) && (ts = new ge(), Mt.set(qt, ts)), ts.set(Vt, as))), as;
|
|
449
449
|
}
|
|
450
450
|
function Dt(qt) {
|
|
451
|
-
if (
|
|
451
|
+
if (Ve(qt))
|
|
452
452
|
throw new TypeError();
|
|
453
|
-
return gt === qt || yt === qt || !
|
|
453
|
+
return gt === qt || yt === qt || !Ve(Ct) && Ct.has(qt);
|
|
454
454
|
}
|
|
455
|
-
function Lt(qt,
|
|
455
|
+
function Lt(qt, Vt, ts) {
|
|
456
456
|
if (!Dt(ts))
|
|
457
457
|
throw new Error("Metadata provider not registered.");
|
|
458
|
-
var as = Ot(qt,
|
|
458
|
+
var as = Ot(qt, Vt);
|
|
459
459
|
if (as !== ts) {
|
|
460
|
-
if (!
|
|
460
|
+
if (!Ve(as))
|
|
461
461
|
return !1;
|
|
462
462
|
var fs = Mt.get(qt);
|
|
463
|
-
|
|
463
|
+
Ve(fs) && (fs = new ge(), Mt.set(qt, fs)), fs.set(Vt, ts);
|
|
464
464
|
}
|
|
465
465
|
return !0;
|
|
466
466
|
}
|
|
467
467
|
}
|
|
468
468
|
function Ft() {
|
|
469
469
|
var ot;
|
|
470
|
-
return !
|
|
470
|
+
return !Ve(_e) && Be(oe.Reflect) && Object.isExtensible(oe.Reflect) && (ot = oe.Reflect[_e]), Ve(ot) && (ot = Nt()), !Ve(_e) && Be(oe.Reflect) && Object.isExtensible(oe.Reflect) && Object.defineProperty(oe.Reflect, _e, {
|
|
471
471
|
enumerable: !1,
|
|
472
472
|
configurable: !1,
|
|
473
473
|
writable: !1,
|
|
@@ -478,69 +478,69 @@ function require_Reflect() {
|
|
|
478
478
|
var gt = new me(), yt = {
|
|
479
479
|
isProviderFor: function(Dt, Lt) {
|
|
480
480
|
var qt = gt.get(Dt);
|
|
481
|
-
return
|
|
481
|
+
return Ve(qt) ? !1 : qt.has(Lt);
|
|
482
482
|
},
|
|
483
483
|
OrdinaryDefineOwnMetadata: ds,
|
|
484
484
|
OrdinaryHasOwnMetadata: Mt,
|
|
485
485
|
OrdinaryGetOwnMetadata: rs,
|
|
486
|
-
OrdinaryOwnMetadataKeys:
|
|
486
|
+
OrdinaryOwnMetadataKeys: Bt,
|
|
487
487
|
OrdinaryDeleteMetadata: Ot
|
|
488
488
|
};
|
|
489
489
|
return ye.registerProvider(yt), yt;
|
|
490
490
|
function Ct(Dt, Lt, qt) {
|
|
491
|
-
var
|
|
492
|
-
if (
|
|
491
|
+
var Vt = gt.get(Dt), ts = !1;
|
|
492
|
+
if (Ve(Vt)) {
|
|
493
493
|
if (!qt)
|
|
494
494
|
return;
|
|
495
|
-
|
|
495
|
+
Vt = new ge(), gt.set(Dt, Vt), ts = !0;
|
|
496
496
|
}
|
|
497
|
-
var as =
|
|
498
|
-
if (
|
|
497
|
+
var as = Vt.get(Lt);
|
|
498
|
+
if (Ve(as)) {
|
|
499
499
|
if (!qt)
|
|
500
500
|
return;
|
|
501
|
-
if (as = new ge(),
|
|
502
|
-
throw
|
|
501
|
+
if (as = new ge(), Vt.set(Lt, as), !ot.setProvider(Dt, Lt, yt))
|
|
502
|
+
throw Vt.delete(Lt), ts && gt.delete(Dt), new Error("Wrong provider for target.");
|
|
503
503
|
}
|
|
504
504
|
return as;
|
|
505
505
|
}
|
|
506
506
|
function Mt(Dt, Lt, qt) {
|
|
507
|
-
var
|
|
507
|
+
var Vt = Ct(
|
|
508
508
|
Lt,
|
|
509
509
|
qt,
|
|
510
510
|
/*Create*/
|
|
511
511
|
!1
|
|
512
512
|
);
|
|
513
|
-
return
|
|
513
|
+
return Ve(Vt) ? !1 : ft(Vt.has(Dt));
|
|
514
514
|
}
|
|
515
515
|
function rs(Dt, Lt, qt) {
|
|
516
|
-
var
|
|
516
|
+
var Vt = Ct(
|
|
517
517
|
Lt,
|
|
518
518
|
qt,
|
|
519
519
|
/*Create*/
|
|
520
520
|
!1
|
|
521
521
|
);
|
|
522
|
-
if (!
|
|
523
|
-
return
|
|
522
|
+
if (!Ve(Vt))
|
|
523
|
+
return Vt.get(Dt);
|
|
524
524
|
}
|
|
525
|
-
function ds(Dt, Lt, qt,
|
|
525
|
+
function ds(Dt, Lt, qt, Vt) {
|
|
526
526
|
var ts = Ct(
|
|
527
527
|
qt,
|
|
528
|
-
|
|
528
|
+
Vt,
|
|
529
529
|
/*Create*/
|
|
530
530
|
!0
|
|
531
531
|
);
|
|
532
532
|
ts.set(Dt, Lt);
|
|
533
533
|
}
|
|
534
|
-
function
|
|
535
|
-
var qt = [],
|
|
534
|
+
function Bt(Dt, Lt) {
|
|
535
|
+
var qt = [], Vt = Ct(
|
|
536
536
|
Dt,
|
|
537
537
|
Lt,
|
|
538
538
|
/*Create*/
|
|
539
539
|
!1
|
|
540
540
|
);
|
|
541
|
-
if (
|
|
541
|
+
if (Ve(Vt))
|
|
542
542
|
return qt;
|
|
543
|
-
for (var ts =
|
|
543
|
+
for (var ts = Vt.keys(), as = vt(ts), fs = 0; ; ) {
|
|
544
544
|
var Cs = At(as);
|
|
545
545
|
if (!Cs)
|
|
546
546
|
return qt.length = fs, qt;
|
|
@@ -558,26 +558,26 @@ function require_Reflect() {
|
|
|
558
558
|
}
|
|
559
559
|
}
|
|
560
560
|
function Ot(Dt, Lt, qt) {
|
|
561
|
-
var
|
|
561
|
+
var Vt = Ct(
|
|
562
562
|
Lt,
|
|
563
563
|
qt,
|
|
564
564
|
/*Create*/
|
|
565
565
|
!1
|
|
566
566
|
);
|
|
567
|
-
if (
|
|
567
|
+
if (Ve(Vt) || !Vt.delete(Dt))
|
|
568
568
|
return !1;
|
|
569
|
-
if (
|
|
569
|
+
if (Vt.size === 0) {
|
|
570
570
|
var ts = gt.get(Lt);
|
|
571
|
-
|
|
571
|
+
Ve(ts) || (ts.delete(qt), ts.size === 0 && gt.delete(ts));
|
|
572
572
|
}
|
|
573
573
|
return !0;
|
|
574
574
|
}
|
|
575
575
|
}
|
|
576
576
|
function us(ot) {
|
|
577
|
-
var gt = ot.defineMetadata, yt = ot.hasOwnMetadata, Ct = ot.getOwnMetadata, Mt = ot.getOwnMetadataKeys, rs = ot.deleteMetadata, ds = new me(),
|
|
577
|
+
var gt = ot.defineMetadata, yt = ot.hasOwnMetadata, Ct = ot.getOwnMetadata, Mt = ot.getOwnMetadataKeys, rs = ot.deleteMetadata, ds = new me(), Bt = {
|
|
578
578
|
isProviderFor: function(Ot, Dt) {
|
|
579
579
|
var Lt = ds.get(Ot);
|
|
580
|
-
return !
|
|
580
|
+
return !Ve(Lt) && Lt.has(Dt) ? !0 : Mt(Ot, Dt).length ? (Ve(Lt) && (Lt = new ve(), ds.set(Ot, Lt)), Lt.add(Dt), !0) : !1;
|
|
581
581
|
},
|
|
582
582
|
OrdinaryDefineOwnMetadata: gt,
|
|
583
583
|
OrdinaryHasOwnMetadata: yt,
|
|
@@ -585,11 +585,11 @@ function require_Reflect() {
|
|
|
585
585
|
OrdinaryOwnMetadataKeys: Mt,
|
|
586
586
|
OrdinaryDeleteMetadata: rs
|
|
587
587
|
};
|
|
588
|
-
return
|
|
588
|
+
return Bt;
|
|
589
589
|
}
|
|
590
590
|
function cs(ot, gt, yt) {
|
|
591
591
|
var Ct = ye.getProvider(ot, gt);
|
|
592
|
-
if (!
|
|
592
|
+
if (!Ve(Ct))
|
|
593
593
|
return Ct;
|
|
594
594
|
if (yt) {
|
|
595
595
|
if (ye.setProvider(ot, gt, Ae))
|
|
@@ -601,59 +601,59 @@ function require_Reflect() {
|
|
|
601
601
|
var ot = {}, gt = [], yt = (
|
|
602
602
|
/** @class */
|
|
603
603
|
(function() {
|
|
604
|
-
function
|
|
604
|
+
function Bt(Ot, Dt, Lt) {
|
|
605
605
|
this._index = 0, this._keys = Ot, this._values = Dt, this._selector = Lt;
|
|
606
606
|
}
|
|
607
|
-
return
|
|
607
|
+
return Bt.prototype["@@iterator"] = function() {
|
|
608
608
|
return this;
|
|
609
|
-
},
|
|
609
|
+
}, Bt.prototype[ce] = function() {
|
|
610
610
|
return this;
|
|
611
|
-
},
|
|
611
|
+
}, Bt.prototype.next = function() {
|
|
612
612
|
var Ot = this._index;
|
|
613
613
|
if (Ot >= 0 && Ot < this._keys.length) {
|
|
614
614
|
var Dt = this._selector(this._keys[Ot], this._values[Ot]);
|
|
615
615
|
return Ot + 1 >= this._keys.length ? (this._index = -1, this._keys = gt, this._values = gt) : this._index++, { value: Dt, done: !1 };
|
|
616
616
|
}
|
|
617
617
|
return { value: void 0, done: !0 };
|
|
618
|
-
},
|
|
618
|
+
}, Bt.prototype.throw = function(Ot) {
|
|
619
619
|
throw this._index >= 0 && (this._index = -1, this._keys = gt, this._values = gt), Ot;
|
|
620
|
-
},
|
|
620
|
+
}, Bt.prototype.return = function(Ot) {
|
|
621
621
|
return this._index >= 0 && (this._index = -1, this._keys = gt, this._values = gt), { value: Ot, done: !0 };
|
|
622
|
-
},
|
|
622
|
+
}, Bt;
|
|
623
623
|
})()
|
|
624
624
|
), Ct = (
|
|
625
625
|
/** @class */
|
|
626
626
|
(function() {
|
|
627
|
-
function
|
|
627
|
+
function Bt() {
|
|
628
628
|
this._keys = [], this._values = [], this._cacheKey = ot, this._cacheIndex = -2;
|
|
629
629
|
}
|
|
630
|
-
return Object.defineProperty(
|
|
630
|
+
return Object.defineProperty(Bt.prototype, "size", {
|
|
631
631
|
get: function() {
|
|
632
632
|
return this._keys.length;
|
|
633
633
|
},
|
|
634
634
|
enumerable: !0,
|
|
635
635
|
configurable: !0
|
|
636
|
-
}),
|
|
636
|
+
}), Bt.prototype.has = function(Ot) {
|
|
637
637
|
return this._find(
|
|
638
638
|
Ot,
|
|
639
639
|
/*insert*/
|
|
640
640
|
!1
|
|
641
641
|
) >= 0;
|
|
642
|
-
},
|
|
642
|
+
}, Bt.prototype.get = function(Ot) {
|
|
643
643
|
var Dt = this._find(
|
|
644
644
|
Ot,
|
|
645
645
|
/*insert*/
|
|
646
646
|
!1
|
|
647
647
|
);
|
|
648
648
|
return Dt >= 0 ? this._values[Dt] : void 0;
|
|
649
|
-
},
|
|
649
|
+
}, Bt.prototype.set = function(Ot, Dt) {
|
|
650
650
|
var Lt = this._find(
|
|
651
651
|
Ot,
|
|
652
652
|
/*insert*/
|
|
653
653
|
!0
|
|
654
654
|
);
|
|
655
655
|
return this._values[Lt] = Dt, this;
|
|
656
|
-
},
|
|
656
|
+
}, Bt.prototype.delete = function(Ot) {
|
|
657
657
|
var Dt = this._find(
|
|
658
658
|
Ot,
|
|
659
659
|
/*insert*/
|
|
@@ -665,19 +665,19 @@ function require_Reflect() {
|
|
|
665
665
|
return this._keys.length--, this._values.length--, ns(Ot, this._cacheKey) && (this._cacheKey = ot, this._cacheIndex = -2), !0;
|
|
666
666
|
}
|
|
667
667
|
return !1;
|
|
668
|
-
},
|
|
668
|
+
}, Bt.prototype.clear = function() {
|
|
669
669
|
this._keys.length = 0, this._values.length = 0, this._cacheKey = ot, this._cacheIndex = -2;
|
|
670
|
-
},
|
|
670
|
+
}, Bt.prototype.keys = function() {
|
|
671
671
|
return new yt(this._keys, this._values, Mt);
|
|
672
|
-
},
|
|
672
|
+
}, Bt.prototype.values = function() {
|
|
673
673
|
return new yt(this._keys, this._values, rs);
|
|
674
|
-
},
|
|
674
|
+
}, Bt.prototype.entries = function() {
|
|
675
675
|
return new yt(this._keys, this._values, ds);
|
|
676
|
-
},
|
|
676
|
+
}, Bt.prototype["@@iterator"] = function() {
|
|
677
677
|
return this.entries();
|
|
678
|
-
},
|
|
678
|
+
}, Bt.prototype[ce] = function() {
|
|
679
679
|
return this.entries();
|
|
680
|
-
},
|
|
680
|
+
}, Bt.prototype._find = function(Ot, Dt) {
|
|
681
681
|
if (!ns(this._cacheKey, Ot)) {
|
|
682
682
|
this._cacheIndex = -1;
|
|
683
683
|
for (var Lt = 0; Lt < this._keys.length; Lt++)
|
|
@@ -687,18 +687,18 @@ function require_Reflect() {
|
|
|
687
687
|
}
|
|
688
688
|
}
|
|
689
689
|
return this._cacheIndex < 0 && Dt && (this._cacheIndex = this._keys.length, this._keys.push(Ot), this._values.push(void 0)), this._cacheIndex;
|
|
690
|
-
},
|
|
690
|
+
}, Bt;
|
|
691
691
|
})()
|
|
692
692
|
);
|
|
693
693
|
return Ct;
|
|
694
|
-
function Mt(
|
|
695
|
-
return
|
|
694
|
+
function Mt(Bt, Ot) {
|
|
695
|
+
return Bt;
|
|
696
696
|
}
|
|
697
|
-
function rs(
|
|
697
|
+
function rs(Bt, Ot) {
|
|
698
698
|
return Ot;
|
|
699
699
|
}
|
|
700
|
-
function ds(
|
|
701
|
-
return [
|
|
700
|
+
function ds(Bt, Ot) {
|
|
701
|
+
return [Bt, Ot];
|
|
702
702
|
}
|
|
703
703
|
}
|
|
704
704
|
function As() {
|
|
@@ -781,7 +781,7 @@ function require_Reflect() {
|
|
|
781
781
|
function Ct() {
|
|
782
782
|
var Ot;
|
|
783
783
|
do
|
|
784
|
-
Ot = "@@WeakMap@@" +
|
|
784
|
+
Ot = "@@WeakMap@@" + Bt();
|
|
785
785
|
while (be.has(gt, Ot));
|
|
786
786
|
return gt[Ot] = !0, Ot;
|
|
787
787
|
}
|
|
@@ -805,7 +805,7 @@ function require_Reflect() {
|
|
|
805
805
|
}
|
|
806
806
|
return rs(new Array(Ot), Ot);
|
|
807
807
|
}
|
|
808
|
-
function
|
|
808
|
+
function Bt() {
|
|
809
809
|
var Ot = ds(ot);
|
|
810
810
|
Ot[6] = Ot[6] & 79 | 64, Ot[8] = Ot[8] & 191 | 128;
|
|
811
811
|
for (var Dt = "", Lt = 0; Lt < ot; ++Lt) {
|
|
@@ -1485,7 +1485,7 @@ let o$13 = class extends l$w {
|
|
|
1485
1485
|
this.host[this.selectedProperty] === W.viewKey && (this.host[this.selectedProperty] = null, await super.deactivateView(W));
|
|
1486
1486
|
}
|
|
1487
1487
|
};
|
|
1488
|
-
const d$
|
|
1488
|
+
const d$y = (X, W) => new o$12(W), a$w = (X, W) => {
|
|
1489
1489
|
if (X = typeof X == "function" ? X() : X, !X) throw new Error(W);
|
|
1490
1490
|
}, o$11 = (X) => typeof HTMLElement == "object" ? X instanceof HTMLElement : X && typeof X == "object" && X != null && X.nodeType === 1 && typeof X.nodeName == "string", f$t = (X) => {
|
|
1491
1491
|
if (!X.htmlTag && !X.element && !X.factory) throw new Error("One of properties htmlTag, factory or element must be set");
|
|
@@ -1494,7 +1494,7 @@ const d$z = (X, W) => new o$12(W), a$w = (X, W) => {
|
|
|
1494
1494
|
let oe;
|
|
1495
1495
|
return X.element ? oe = X.element : X.factory ? oe = await X.factory() : X.htmlTag && (X.htmlUrl && await import(X.htmlUrl), oe = window.document.createElement(X.htmlTag)), oe.view = X, oe.region = W, oe.viewKey = te, oe;
|
|
1496
1496
|
};
|
|
1497
|
-
let y$
|
|
1497
|
+
let y$l = class {
|
|
1498
1498
|
constructor(W, te, oe, ne, re) {
|
|
1499
1499
|
this.name = W, this.regionManager = te, this.host = oe, this.adapter = ne, this.definition = re, this.views = {}, this.activeViews = [], this.components = /* @__PURE__ */ new WeakMap(), this.host.uxlRegion = this;
|
|
1500
1500
|
}
|
|
@@ -1572,7 +1572,7 @@ let y$k = class {
|
|
|
1572
1572
|
}
|
|
1573
1573
|
};
|
|
1574
1574
|
const e$X = "default", r$N = "dynamic";
|
|
1575
|
-
let y$
|
|
1575
|
+
let y$k = class {
|
|
1576
1576
|
constructor() {
|
|
1577
1577
|
this.adapterRegistry = /* @__PURE__ */ new Map(), this.adapterRegistry.set(r$N, []);
|
|
1578
1578
|
}
|
|
@@ -1595,7 +1595,7 @@ let y$j = class {
|
|
|
1595
1595
|
this.adapterRegistry.set(e$X, W);
|
|
1596
1596
|
}
|
|
1597
1597
|
};
|
|
1598
|
-
const p$g = new y$
|
|
1598
|
+
const p$g = new y$k(), o$10 = "__uxl_regions__", s$H = (X) => (W, te) => {
|
|
1599
1599
|
W.constructor[o$10] = { ...W.constructor[o$10], [te]: X };
|
|
1600
1600
|
}, p$f = (X, W, te) => {
|
|
1601
1601
|
const oe = te.getAdapterFactory(W);
|
|
@@ -1606,7 +1606,7 @@ const p$g = new y$j(), o$10 = "__uxl_regions__", s$H = (X) => (W, te) => {
|
|
|
1606
1606
|
if (ne) {
|
|
1607
1607
|
const re = X.adapterFactory ? X.adapterFactory(X, ne) : p$f(X, ne, oe);
|
|
1608
1608
|
a$w(re, "No region adapter found for the host");
|
|
1609
|
-
const de = X.scoped ? te.createRegionManager() : te, ce = new y$
|
|
1609
|
+
const de = X.scoped ? te.createRegionManager() : te, ce = new y$l(X.name, de, ne, re, X);
|
|
1610
1610
|
return de.add(X.name, ce), ce;
|
|
1611
1611
|
} else console.warn(`region host with id ${X.targetId} not found for region named ${X.name}`);
|
|
1612
1612
|
};
|
|
@@ -1651,7 +1651,7 @@ function r$M(X, W) {
|
|
|
1651
1651
|
}
|
|
1652
1652
|
return !1;
|
|
1653
1653
|
}
|
|
1654
|
-
function d$
|
|
1654
|
+
function d$x(X) {
|
|
1655
1655
|
return (W) => {
|
|
1656
1656
|
if (r$M(X, W)) return W;
|
|
1657
1657
|
const te = X(W);
|
|
@@ -1705,7 +1705,7 @@ const r$L = (X) => new n$D(typeof X == "string" ? X : X + "", void 0, s$G), i$R
|
|
|
1705
1705
|
* Copyright 2017 Google LLC
|
|
1706
1706
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
1707
1707
|
*/
|
|
1708
|
-
const { is: i$Q, defineProperty: e$V, getOwnPropertyDescriptor: r$K, getOwnPropertyNames: h$p, getOwnPropertySymbols: o$_, getPrototypeOf: n$C } = Object, a$v = globalThis, c$q = a$v.trustedTypes, l$v = c$q ? c$q.emptyScript : "", p$e = a$v.reactiveElementPolyfillSupport, d$
|
|
1708
|
+
const { is: i$Q, defineProperty: e$V, getOwnPropertyDescriptor: r$K, getOwnPropertyNames: h$p, getOwnPropertySymbols: o$_, getPrototypeOf: n$C } = Object, a$v = globalThis, c$q = a$v.trustedTypes, l$v = c$q ? c$q.emptyScript : "", p$e = a$v.reactiveElementPolyfillSupport, d$w = (X, W) => X, u$u = { toAttribute(X, W) {
|
|
1709
1709
|
switch (W) {
|
|
1710
1710
|
case Boolean:
|
|
1711
1711
|
X = X ? l$v : null;
|
|
@@ -1733,7 +1733,7 @@ const { is: i$Q, defineProperty: e$V, getOwnPropertyDescriptor: r$K, getOwnPrope
|
|
|
1733
1733
|
}
|
|
1734
1734
|
}
|
|
1735
1735
|
return te;
|
|
1736
|
-
} }, f$r = (X, W) => !i$Q(X, W), y$
|
|
1736
|
+
} }, f$r = (X, W) => !i$Q(X, W), y$j = { attribute: !0, type: String, converter: u$u, reflect: !1, hasChanged: f$r };
|
|
1737
1737
|
Symbol.metadata ??= Symbol("metadata"), a$v.litPropertyMetadata ??= /* @__PURE__ */ new WeakMap();
|
|
1738
1738
|
let b$m = class extends HTMLElement {
|
|
1739
1739
|
static addInitializer(W) {
|
|
@@ -1742,7 +1742,7 @@ let b$m = class extends HTMLElement {
|
|
|
1742
1742
|
static get observedAttributes() {
|
|
1743
1743
|
return this.finalize(), this._$Eh && [...this._$Eh.keys()];
|
|
1744
1744
|
}
|
|
1745
|
-
static createProperty(W, te = y$
|
|
1745
|
+
static createProperty(W, te = y$j) {
|
|
1746
1746
|
if (te.state && (te.attribute = !1), this._$Ei(), this.elementProperties.set(W, te), !te.noAccessor) {
|
|
1747
1747
|
const oe = Symbol(), ne = this.getPropertyDescriptor(W, oe, te);
|
|
1748
1748
|
ne !== void 0 && e$V(this.prototype, W, ne);
|
|
@@ -1762,16 +1762,16 @@ let b$m = class extends HTMLElement {
|
|
|
1762
1762
|
}, configurable: !0, enumerable: !0 };
|
|
1763
1763
|
}
|
|
1764
1764
|
static getPropertyOptions(W) {
|
|
1765
|
-
return this.elementProperties.get(W) ?? y$
|
|
1765
|
+
return this.elementProperties.get(W) ?? y$j;
|
|
1766
1766
|
}
|
|
1767
1767
|
static _$Ei() {
|
|
1768
|
-
if (this.hasOwnProperty(d$
|
|
1768
|
+
if (this.hasOwnProperty(d$w("elementProperties"))) return;
|
|
1769
1769
|
const W = n$C(this);
|
|
1770
1770
|
W.finalize(), W.l !== void 0 && (this.l = [...W.l]), this.elementProperties = new Map(W.elementProperties);
|
|
1771
1771
|
}
|
|
1772
1772
|
static finalize() {
|
|
1773
|
-
if (this.hasOwnProperty(d$
|
|
1774
|
-
if (this.finalized = !0, this._$Ei(), this.hasOwnProperty(d$
|
|
1773
|
+
if (this.hasOwnProperty(d$w("finalized"))) return;
|
|
1774
|
+
if (this.finalized = !0, this._$Ei(), this.hasOwnProperty(d$w("properties"))) {
|
|
1775
1775
|
const te = this.properties, oe = [...h$p(te), ...o$_(te)];
|
|
1776
1776
|
for (const ne of oe) this.createProperty(ne, te[ne]);
|
|
1777
1777
|
}
|
|
@@ -1912,7 +1912,7 @@ let b$m = class extends HTMLElement {
|
|
|
1912
1912
|
firstUpdated(W) {
|
|
1913
1913
|
}
|
|
1914
1914
|
};
|
|
1915
|
-
b$m.elementStyles = [], b$m.shadowRootOptions = { mode: "open" }, b$m[d$
|
|
1915
|
+
b$m.elementStyles = [], b$m.shadowRootOptions = { mode: "open" }, b$m[d$w("elementProperties")] = /* @__PURE__ */ new Map(), b$m[d$w("finalized")] = /* @__PURE__ */ new Map(), p$e?.({ ReactiveElement: b$m }), (a$v.reactiveElementVersions ??= []).push("2.0.4");
|
|
1916
1916
|
/**
|
|
1917
1917
|
* @license
|
|
1918
1918
|
* Copyright 2017 Google LLC
|
|
@@ -2175,7 +2175,7 @@ f$p?.({ LitElement: h$n });
|
|
|
2175
2175
|
var defaultTo = /* @__PURE__ */ _curry2(function(W, te) {
|
|
2176
2176
|
return te == null || te !== te ? W : te;
|
|
2177
2177
|
});
|
|
2178
|
-
const u$t = (X, W) => W.constructor._classProperties ? W.constructor._classProperties.get(X).hasChanged : void 0, a$u = pipe(u$t, defaultTo(f$r)), l$u = d$
|
|
2178
|
+
const u$t = (X, W) => W.constructor._classProperties ? W.constructor._classProperties.get(X).hasChanged : void 0, a$u = pipe(u$t, defaultTo(f$r)), l$u = d$x((X) => {
|
|
2179
2179
|
class W extends X {
|
|
2180
2180
|
requestUpdate(oe, ne) {
|
|
2181
2181
|
const re = super.requestUpdate ? super.requestUpdate(oe, ne) : Promise.resolve(null);
|
|
@@ -2305,7 +2305,7 @@ const v$o = new w$7(), u$s = (X) => (W) => pipe(prop(W.key), isNil)(X), q$3 = (X
|
|
|
2305
2305
|
}).catch(always(void 0)), L$7 = (X) => pipe(keys, map((W) => ({ key: W, definition: X[W] })))(X), l$t = (X) => X.constructor[o$10] || {}, H$3 = (X, W, te) => {
|
|
2306
2306
|
const oe = u$s(X), ne = q$3(X), re = T$4(X), de = w$6(X, W, te);
|
|
2307
2307
|
return (ce) => cond([[oe, de], [ne, re], [T$5, always(Promise.resolve(void 0))]])(ce);
|
|
2308
|
-
}, j$2 = (X, W) => d$
|
|
2308
|
+
}, j$2 = (X, W) => d$x((te) => {
|
|
2309
2309
|
class oe extends te {
|
|
2310
2310
|
constructor(...re) {
|
|
2311
2311
|
super(), this.enqueuer = new i$S(this.runRegionCreation.bind(this));
|
|
@@ -2426,7 +2426,7 @@ var l$s = Object.defineProperty, s$F = (X, W, te, oe) => {
|
|
|
2426
2426
|
for (var ne = void 0, re = X.length - 1, de; re >= 0; re--) (de = X[re]) && (ne = de(W, te, ne) || ne);
|
|
2427
2427
|
return ne && l$s(W, te, ne), ne;
|
|
2428
2428
|
};
|
|
2429
|
-
const d$
|
|
2429
|
+
const d$v = d$x((X) => {
|
|
2430
2430
|
class W extends l$u(X) {
|
|
2431
2431
|
activeChanged(oe, ne) {
|
|
2432
2432
|
}
|
|
@@ -2436,10 +2436,10 @@ const d$w = d$y((X) => {
|
|
|
2436
2436
|
return s$F([n$A({ type: Boolean })], W.prototype, "active"), s$F([n$A()], W.prototype, "regionContext"), W;
|
|
2437
2437
|
});
|
|
2438
2438
|
function k$6(X) {
|
|
2439
|
-
return d$
|
|
2439
|
+
return d$v(X);
|
|
2440
2440
|
}
|
|
2441
|
-
const
|
|
2442
|
-
let
|
|
2441
|
+
const f$o = (X) => j$2(X, p$g);
|
|
2442
|
+
let c$o = class {
|
|
2443
2443
|
constructor() {
|
|
2444
2444
|
this.viewsByRegion = {}, this.regions = {};
|
|
2445
2445
|
}
|
|
@@ -2478,9 +2478,7 @@ let l$r = class {
|
|
|
2478
2478
|
if (oe) {
|
|
2479
2479
|
const ne = oe.host, re = te.host;
|
|
2480
2480
|
if (ne && re && ne === re)
|
|
2481
|
-
throw ne.uxlRegion = oe, new Error(
|
|
2482
|
-
`RegionManager.add: region "${W}" already exists for the same host (idempotent rejection)`
|
|
2483
|
-
);
|
|
2481
|
+
throw ne.uxlRegion = oe, new Error(`RegionManager.add: region "${W}" already exists for the same host (idempotent rejection)`);
|
|
2484
2482
|
const de = ne;
|
|
2485
2483
|
if (de)
|
|
2486
2484
|
for (; de.firstChild; )
|
|
@@ -2516,36 +2514,47 @@ let l$r = class {
|
|
|
2516
2514
|
getRegisteredViews(W) {
|
|
2517
2515
|
return this._viewRegistry.getRegisteredViews(W);
|
|
2518
2516
|
}
|
|
2519
|
-
|
|
2520
|
-
|
|
2521
|
-
|
|
2522
|
-
|
|
2517
|
+
/**
|
|
2518
|
+
* Treu totes les vistes de totes les regions.
|
|
2519
|
+
*
|
|
2520
|
+
* Espera cada `removeView`: son asincrons, i qui crida `clear()` normalment ho fa perque vol
|
|
2521
|
+
* que les vistes estiguin desmuntades abans de continuar. Amb un `forEach` sense esperar,
|
|
2522
|
+
* `clear()` resolia abans que cap component s'hagues desmuntat, i els cleanups dels seus
|
|
2523
|
+
* `useEffect` corrien despres del que hi hagues al darrere.
|
|
2524
|
+
*/
|
|
2525
|
+
async clear() {
|
|
2526
|
+
for (const W of Object.values(this._viewRegistry.regions)) {
|
|
2527
|
+
const te = W?.[0];
|
|
2528
|
+
if (te)
|
|
2529
|
+
for (const oe of Object.keys(te.views))
|
|
2530
|
+
await te.removeView(oe);
|
|
2531
|
+
}
|
|
2532
|
+
return this;
|
|
2523
2533
|
}
|
|
2524
|
-
|
|
2525
|
-
|
|
2526
|
-
|
|
2527
|
-
), this._regions = {}, this;
|
|
2534
|
+
/** Igual que `clear()`, pero a mes treu les regions. Espera el desmuntatge abans de fer-ho. */
|
|
2535
|
+
async destroy() {
|
|
2536
|
+
return await this.clear(), Object.values(this._viewRegistry.regions).forEach((W) => this.remove(W[0])), this._regions = {}, this;
|
|
2528
2537
|
}
|
|
2529
2538
|
createRegionManager() {
|
|
2530
2539
|
return new Ai(this._viewRegistry);
|
|
2531
2540
|
}
|
|
2532
2541
|
}, w$5 = class extends g$o {
|
|
2533
2542
|
constructor(W) {
|
|
2534
|
-
const te = new
|
|
2543
|
+
const te = new c$o();
|
|
2535
2544
|
super(te), this._name = W;
|
|
2536
2545
|
}
|
|
2537
|
-
clear() {
|
|
2538
|
-
return super.clear(), this._viewRegistry.clear(), this;
|
|
2546
|
+
async clear() {
|
|
2547
|
+
return await super.clear(), this._viewRegistry.clear(), this;
|
|
2539
2548
|
}
|
|
2540
|
-
destroy() {
|
|
2541
|
-
return super.destroy(), this._viewRegistry.destroy(), this;
|
|
2549
|
+
async destroy() {
|
|
2550
|
+
return await super.destroy(), this._viewRegistry.destroy(), this;
|
|
2542
2551
|
}
|
|
2543
2552
|
};
|
|
2544
|
-
const
|
|
2553
|
+
const v$n = (X) => new w$5(X), l$r = (X) => X.importer(), R$5 = async (X, W, te) => {
|
|
2545
2554
|
try {
|
|
2546
|
-
const oe = await
|
|
2555
|
+
const oe = await l$r(X), ne = W(X);
|
|
2547
2556
|
return await te(ne, oe), {
|
|
2548
|
-
dispose: () =>
|
|
2557
|
+
dispose: () => y$i(ne, oe),
|
|
2549
2558
|
importedPlugin: oe,
|
|
2550
2559
|
apiInstance: ne
|
|
2551
2560
|
};
|
|
@@ -2554,7 +2563,7 @@ const f$o = (X) => new w$5(X), c$o = (X) => X.importer(), R$5 = async (X, W, te)
|
|
|
2554
2563
|
}
|
|
2555
2564
|
}, u$r = async (X, W) => {
|
|
2556
2565
|
await W.initialize(X);
|
|
2557
|
-
},
|
|
2566
|
+
}, y$i = (X, W) => W.dispose(X), p$d = async (X, W) => {
|
|
2558
2567
|
if (!X?.length) throw new Error("No plugins to bootstrap");
|
|
2559
2568
|
return (await Promise.allSettled(X.map((te) => R$5(te, W, u$r)))).map((te) => te.status === "fulfilled" ? te.value : null);
|
|
2560
2569
|
}, primariaShellId = "primaria-shell", BROKER_EVENTS = {
|
|
@@ -3983,11 +3992,11 @@ const resolveConfig = (X) => {
|
|
|
3983
3992
|
duplex: "half"
|
|
3984
3993
|
}), je;
|
|
3985
3994
|
if (utils$1.isFormData(ye) && (je = Fe.headers.get("content-type")) && ze.setContentType(je), Fe.body) {
|
|
3986
|
-
const [
|
|
3995
|
+
const [Ve, Qe] = progressEventDecorator(
|
|
3987
3996
|
Ge,
|
|
3988
3997
|
progressEventReducer(asyncDecorator(Me))
|
|
3989
3998
|
);
|
|
3990
|
-
ye = trackStream(Fe.body, DEFAULT_CHUNK_SIZE,
|
|
3999
|
+
ye = trackStream(Fe.body, DEFAULT_CHUNK_SIZE, Ve, Qe);
|
|
3991
4000
|
}
|
|
3992
4001
|
}
|
|
3993
4002
|
utils$1.isString(Ue) || (Ue = Ue ? "include" : "omit");
|
|
@@ -4008,12 +4017,12 @@ const resolveConfig = (X) => {
|
|
|
4008
4017
|
["status", "statusText", "headers"].forEach((tt) => {
|
|
4009
4018
|
Fe[tt] = bt[tt];
|
|
4010
4019
|
});
|
|
4011
|
-
const je = utils$1.toFiniteNumber(bt.headers.get("content-length")), [
|
|
4020
|
+
const je = utils$1.toFiniteNumber(bt.headers.get("content-length")), [Ve, Qe] = Se && progressEventDecorator(
|
|
4012
4021
|
je,
|
|
4013
4022
|
progressEventReducer(asyncDecorator(Se), !0)
|
|
4014
4023
|
) || [];
|
|
4015
4024
|
bt = new oe(
|
|
4016
|
-
trackStream(bt.body, DEFAULT_CHUNK_SIZE,
|
|
4025
|
+
trackStream(bt.body, DEFAULT_CHUNK_SIZE, Ve, () => {
|
|
4017
4026
|
Qe && Qe(), He && He();
|
|
4018
4027
|
}),
|
|
4019
4028
|
Fe
|
|
@@ -5165,7 +5174,7 @@ function peg$parse(X, W) {
|
|
|
5165
5174
|
return _s.pop(), De.replace(/\s*$/, "");
|
|
5166
5175
|
}, Ze = ",", Ye = hs(",", !1), bt = "number", Xe = hs("number", !1), Ke = function(De, We, it) {
|
|
5167
5176
|
return __assign$4({ type: We === "number" ? TYPE.number : We === "date" ? TYPE.date : TYPE.time, style: it && it[2], value: De }, ys());
|
|
5168
|
-
}, Fe = "'", je = hs("'", !1),
|
|
5177
|
+
}, Fe = "'", je = hs("'", !1), Ve = /^[^']/, Qe = ws(["'"], !0, !1), tt = /^[^a-zA-Z'{}]/, Be = ws([["a", "z"], ["A", "Z"], "'", "{", "}"], !0, !1), Je = /^[a-zA-Z]/, nt = ws([["a", "z"], ["A", "Z"]], !1, !1), ft = function(De) {
|
|
5169
5178
|
return __assign$4({ type: 1, pattern: De }, ys());
|
|
5170
5179
|
}, $t = function() {
|
|
5171
5180
|
return _s.push("dateOrTimeArgStyle"), !0;
|
|
@@ -5199,9 +5208,9 @@ function peg$parse(X, W) {
|
|
|
5199
5208
|
id: De,
|
|
5200
5209
|
value: We
|
|
5201
5210
|
}, ys());
|
|
5202
|
-
}, ps = gs("whitespace"), ot = /^[\t-\r \x85\xA0\u1680\u2000-\u200A\u2028\u2029\u202F\u205F\u3000]/, gt = ws([[" ", "\r"], " ", "
", " ", " ", [" ", " "], "\u2028", "\u2029", " ", " ", " "], !1, !1), yt = gs("syntax pattern"), Ct = /^[!-\/:-@[-\^`{-~\xA1-\xA7\xA9\xAB\xAC\xAE\xB0\xB1\xB6\xBB\xBF\xD7\xF7\u2010-\u2027\u2030-\u203E\u2041-\u2053\u2055-\u205E\u2190-\u245F\u2500-\u2775\u2794-\u2BFF\u2E00-\u2E7F\u3001-\u3003\u3008-\u3020\u3030\uFD3E\uFD3F\uFE45\uFE46]/, Mt = ws([["!", "/"], [":", "@"], ["[", "^"], "`", ["{", "~"], ["¡", "§"], "©", "«", "¬", "®", "°", "±", "¶", "»", "¿", "×", "÷", ["‐", "‧"], ["‰", "‾"], ["⁁", "⁓"], ["⁕", "⁞"], ["←", ""], ["─", "❵"], ["➔", "⯿"], ["⸀", ""], ["、", "〃"], ["〈", "〠"], "〰", "﴾", "﴿", "﹅", "﹆"], !1, !1), rs = gs("optional whitespace"), ds = gs("number"),
|
|
5211
|
+
}, ps = gs("whitespace"), ot = /^[\t-\r \x85\xA0\u1680\u2000-\u200A\u2028\u2029\u202F\u205F\u3000]/, gt = ws([[" ", "\r"], " ", "
", " ", " ", [" ", " "], "\u2028", "\u2029", " ", " ", " "], !1, !1), yt = gs("syntax pattern"), Ct = /^[!-\/:-@[-\^`{-~\xA1-\xA7\xA9\xAB\xAC\xAE\xB0\xB1\xB6\xBB\xBF\xD7\xF7\u2010-\u2027\u2030-\u203E\u2041-\u2053\u2055-\u205E\u2190-\u245F\u2500-\u2775\u2794-\u2BFF\u2E00-\u2E7F\u3001-\u3003\u3008-\u3020\u3030\uFD3E\uFD3F\uFE45\uFE46]/, Mt = ws([["!", "/"], [":", "@"], ["[", "^"], "`", ["{", "~"], ["¡", "§"], "©", "«", "¬", "®", "°", "±", "¶", "»", "¿", "×", "÷", ["‐", "‧"], ["‰", "‾"], ["⁁", "⁓"], ["⁕", "⁞"], ["←", ""], ["─", "❵"], ["➔", "⯿"], ["⸀", ""], ["、", "〃"], ["〈", "〠"], "〰", "﴾", "﴿", "﹅", "﹆"], !1, !1), rs = gs("optional whitespace"), ds = gs("number"), Bt = "-", Ot = hs("-", !1), Dt = function(De, We) {
|
|
5203
5212
|
return We ? De ? -We : We : 0;
|
|
5204
|
-
}, Lt = gs("double apostrophes"), qt = "''",
|
|
5213
|
+
}, Lt = gs("double apostrophes"), qt = "''", Vt = hs("''", !1), ts = function() {
|
|
5205
5214
|
return "'";
|
|
5206
5215
|
}, as = function(De, We) {
|
|
5207
5216
|
return De + We.replace("''", "'");
|
|
@@ -5343,7 +5352,7 @@ function peg$parse(X, W) {
|
|
|
5343
5352
|
Ne = De, De = te;
|
|
5344
5353
|
return wt--, De === te && (We = te, wt === 0 && Tt(ze)), De;
|
|
5345
5354
|
}
|
|
5346
|
-
function
|
|
5355
|
+
function Vi() {
|
|
5347
5356
|
var De, We, it;
|
|
5348
5357
|
if (De = Ne, We = [], it = ui(), it !== te)
|
|
5349
5358
|
for (; it !== te; )
|
|
@@ -5352,29 +5361,29 @@ function peg$parse(X, W) {
|
|
|
5352
5361
|
We = te;
|
|
5353
5362
|
return We !== te && (Kt = De, We = Le(We)), De = We, De;
|
|
5354
5363
|
}
|
|
5355
|
-
function
|
|
5364
|
+
function Bi() {
|
|
5356
5365
|
var De, We, it;
|
|
5357
|
-
return De = Ne, X.substr(Ne, 2) === Oe ? (We = Oe, Ne += 2) : (We = te, wt === 0 && Tt(qe)), We !== te ? (it =
|
|
5366
|
+
return De = Ne, X.substr(Ne, 2) === Oe ? (We = Oe, Ne += 2) : (We = te, wt === 0 && Tt(qe)), We !== te ? (it = Vi(), it !== te ? (Kt = De, We = Pe(it), De = We) : (Ne = De, De = te)) : (Ne = De, De = te), De === te && (De = Ne, Kt = Ne, We = He(), We ? We = void 0 : We = te, We !== te ? (it = Ps(), it !== te ? (Kt = De, We = Ge(it), De = We) : (Ne = De, De = te)) : (Ne = De, De = te)), De;
|
|
5358
5367
|
}
|
|
5359
5368
|
function ji() {
|
|
5360
5369
|
var De, We, it, mt, kt, zt, ss, Wt, bs, Zt, ls, Yt, os;
|
|
5361
|
-
return De = Ne, X.charCodeAt(Ne) === 123 ? (We = be, Ne++) : (We = te, wt === 0 && Tt(he)), We !== te ? (it = Gt(), it !== te ? (mt = Ss(), mt !== te ? (kt = Gt(), kt !== te ? (X.charCodeAt(Ne) === 44 ? (zt = Ze, Ne++) : (zt = te, wt === 0 && Tt(Ye)), zt !== te ? (ss = Gt(), ss !== te ? (X.substr(Ne, 6) === bt ? (Wt = bt, Ne += 6) : (Wt = te, wt === 0 && Tt(Xe)), Wt !== te ? (bs = Gt(), bs !== te ? (Zt = Ne, X.charCodeAt(Ne) === 44 ? (ls = Ze, Ne++) : (ls = te, wt === 0 && Tt(Ye)), ls !== te ? (Yt = Gt(), Yt !== te ? (os =
|
|
5370
|
+
return De = Ne, X.charCodeAt(Ne) === 123 ? (We = be, Ne++) : (We = te, wt === 0 && Tt(he)), We !== te ? (it = Gt(), it !== te ? (mt = Ss(), mt !== te ? (kt = Gt(), kt !== te ? (X.charCodeAt(Ne) === 44 ? (zt = Ze, Ne++) : (zt = te, wt === 0 && Tt(Ye)), zt !== te ? (ss = Gt(), ss !== te ? (X.substr(Ne, 6) === bt ? (Wt = bt, Ne += 6) : (Wt = te, wt === 0 && Tt(Xe)), Wt !== te ? (bs = Gt(), bs !== te ? (Zt = Ne, X.charCodeAt(Ne) === 44 ? (ls = Ze, Ne++) : (ls = te, wt === 0 && Tt(Ye)), ls !== te ? (Yt = Gt(), Yt !== te ? (os = Bi(), os !== te ? (ls = [ls, Yt, os], Zt = ls) : (Ne = Zt, Zt = te)) : (Ne = Zt, Zt = te)) : (Ne = Zt, Zt = te), Zt === te && (Zt = null), Zt !== te ? (ls = Gt(), ls !== te ? (X.charCodeAt(Ne) === 125 ? (Yt = ge, Ne++) : (Yt = te, wt === 0 && Tt(ve)), Yt !== te ? (Kt = De, We = Ke(mt, Wt, Zt), De = We) : (Ne = De, De = te)) : (Ne = De, De = te)) : (Ne = De, De = te)) : (Ne = De, De = te)) : (Ne = De, De = te)) : (Ne = De, De = te)) : (Ne = De, De = te)) : (Ne = De, De = te)) : (Ne = De, De = te)) : (Ne = De, De = te)) : (Ne = De, De = te), De;
|
|
5362
5371
|
}
|
|
5363
5372
|
function hi() {
|
|
5364
5373
|
var De, We, it, mt;
|
|
5365
5374
|
if (De = Ne, X.charCodeAt(Ne) === 39 ? (We = Fe, Ne++) : (We = te, wt === 0 && Tt(je)), We !== te) {
|
|
5366
|
-
if (it = [], mt = ks(), mt === te && (
|
|
5375
|
+
if (it = [], mt = ks(), mt === te && (Ve.test(X.charAt(Ne)) ? (mt = X.charAt(Ne), Ne++) : (mt = te, wt === 0 && Tt(Qe))), mt !== te)
|
|
5367
5376
|
for (; mt !== te; )
|
|
5368
|
-
it.push(mt), mt = ks(), mt === te && (
|
|
5377
|
+
it.push(mt), mt = ks(), mt === te && (Ve.test(X.charAt(Ne)) ? (mt = X.charAt(Ne), Ne++) : (mt = te, wt === 0 && Tt(Qe)));
|
|
5369
5378
|
else
|
|
5370
5379
|
it = te;
|
|
5371
5380
|
it !== te ? (X.charCodeAt(Ne) === 39 ? (mt = Fe, Ne++) : (mt = te, wt === 0 && Tt(je)), mt !== te ? (We = [We, it, mt], De = We) : (Ne = De, De = te)) : (Ne = De, De = te);
|
|
5372
5381
|
} else
|
|
5373
5382
|
Ne = De, De = te;
|
|
5374
5383
|
if (De === te)
|
|
5375
|
-
if (De = [], We = ks(), We === te && (tt.test(X.charAt(Ne)) ? (We = X.charAt(Ne), Ne++) : (We = te, wt === 0 && Tt(
|
|
5384
|
+
if (De = [], We = ks(), We === te && (tt.test(X.charAt(Ne)) ? (We = X.charAt(Ne), Ne++) : (We = te, wt === 0 && Tt(Be))), We !== te)
|
|
5376
5385
|
for (; We !== te; )
|
|
5377
|
-
De.push(We), We = ks(), We === te && (tt.test(X.charAt(Ne)) ? (We = X.charAt(Ne), Ne++) : (We = te, wt === 0 && Tt(
|
|
5386
|
+
De.push(We), We = ks(), We === te && (tt.test(X.charAt(Ne)) ? (We = X.charAt(Ne), Ne++) : (We = te, wt === 0 && Tt(Be)));
|
|
5378
5387
|
else
|
|
5379
5388
|
De = te;
|
|
5380
5389
|
return De;
|
|
@@ -5523,18 +5532,18 @@ function peg$parse(X, W) {
|
|
|
5523
5532
|
}
|
|
5524
5533
|
function mi() {
|
|
5525
5534
|
var De, We, it;
|
|
5526
|
-
return wt++, De = Ne, X.charCodeAt(Ne) === 45 ? (We =
|
|
5535
|
+
return wt++, De = Ne, X.charCodeAt(Ne) === 45 ? (We = Bt, Ne++) : (We = te, wt === 0 && Tt(Ot)), We === te && (We = null), We !== te ? (it = yi(), it !== te ? (Kt = De, We = Dt(We, it), De = We) : (Ne = De, De = te)) : (Ne = De, De = te), wt--, De === te && (We = te, wt === 0 && Tt(ds)), De;
|
|
5527
5536
|
}
|
|
5528
5537
|
function ks() {
|
|
5529
5538
|
var De, We;
|
|
5530
|
-
return wt++, De = Ne, X.substr(Ne, 2) === qt ? (We = qt, Ne += 2) : (We = te, wt === 0 && Tt(
|
|
5539
|
+
return wt++, De = Ne, X.substr(Ne, 2) === qt ? (We = qt, Ne += 2) : (We = te, wt === 0 && Tt(Vt)), We !== te && (Kt = De, We = ts()), De = We, wt--, De === te && (We = te, wt === 0 && Tt(Lt)), De;
|
|
5531
5540
|
}
|
|
5532
5541
|
function vi() {
|
|
5533
5542
|
var De, We, it, mt, kt, zt;
|
|
5534
5543
|
if (De = Ne, X.charCodeAt(Ne) === 39 ? (We = Fe, Ne++) : (We = te, wt === 0 && Tt(je)), We !== te)
|
|
5535
5544
|
if (it = Qi(), it !== te) {
|
|
5536
|
-
for (mt = Ne, kt = [], X.substr(Ne, 2) === qt ? (zt = qt, Ne += 2) : (zt = te, wt === 0 && Tt(
|
|
5537
|
-
kt.push(zt), X.substr(Ne, 2) === qt ? (zt = qt, Ne += 2) : (zt = te, wt === 0 && Tt(
|
|
5545
|
+
for (mt = Ne, kt = [], X.substr(Ne, 2) === qt ? (zt = qt, Ne += 2) : (zt = te, wt === 0 && Tt(Vt)), zt === te && (Ve.test(X.charAt(Ne)) ? (zt = X.charAt(Ne), Ne++) : (zt = te, wt === 0 && Tt(Qe))); zt !== te; )
|
|
5546
|
+
kt.push(zt), X.substr(Ne, 2) === qt ? (zt = qt, Ne += 2) : (zt = te, wt === 0 && Tt(Vt)), zt === te && (Ve.test(X.charAt(Ne)) ? (zt = X.charAt(Ne), Ne++) : (zt = te, wt === 0 && Tt(Qe)));
|
|
5538
5547
|
kt !== te ? mt = X.substring(mt, Ne) : mt = kt, mt !== te ? (X.charCodeAt(Ne) === 39 ? (kt = Fe, Ne++) : (kt = te, wt === 0 && Tt(je)), kt === te && (kt = null), kt !== te ? (Kt = De, We = as(it, mt), De = We) : (Ne = De, De = te)) : (Ne = De, De = te);
|
|
5539
5548
|
} else
|
|
5540
5549
|
Ne = De, De = te;
|
|
@@ -8743,7 +8752,12 @@ const shellRegions = {
|
|
|
8743
8752
|
widgets: "administrative-management-widgets-region",
|
|
8744
8753
|
tabs: "administrative-management-tabs-region",
|
|
8745
8754
|
detail: "administrative-management-detail-region"
|
|
8746
|
-
}
|
|
8755
|
+
}, ALL_REGION_NAMES = [
|
|
8756
|
+
...Object.values(shellRegions),
|
|
8757
|
+
...Object.values(clinicalMonitoringRegions),
|
|
8758
|
+
...Object.values(activityHistoryRegions),
|
|
8759
|
+
...Object.values(administrativeManagementRegions)
|
|
8760
|
+
];
|
|
8747
8761
|
class RegionManagerProxy {
|
|
8748
8762
|
constructor(W, te, oe) {
|
|
8749
8763
|
this.pluginInfo = W, this.regionManager = te, this.broker = oe, this.regions = {
|
|
@@ -8880,8 +8894,29 @@ class RegionManagerProxy {
|
|
|
8880
8894
|
_notifyMainViewChanged(W) {
|
|
8881
8895
|
this.broker.publish(BROKER_EVENTS.shell.mainViewChanged, { viewId: W });
|
|
8882
8896
|
}
|
|
8883
|
-
|
|
8884
|
-
|
|
8897
|
+
/**
|
|
8898
|
+
* Desmunta totes les vistes de totes les regions, i espera que acabin.
|
|
8899
|
+
*
|
|
8900
|
+
* Es crida en tancar, ABANS de fer el `dispose` dels plugins: els cleanups dels `useEffect` que
|
|
8901
|
+
* s'executen en desmuntar-se poden enviar comandes pel broker, i han de trobar el handler encara
|
|
8902
|
+
* registrat. Cada plugin ja ho fa pel seu compte al `dispose`, però això només cobreix els
|
|
8903
|
+
* plugins d'aquest repositori; els de tercers (econsulta, allergies…) no els controlem.
|
|
8904
|
+
*
|
|
8905
|
+
* Fa servir `unregisterViewFromRegion` i no `destroy()`/`clear()` del regionManager perquè
|
|
8906
|
+
* aquests fan `forEach` amb crides asíncrones sense esperar-les, així que retornen abans que les
|
|
8907
|
+
* vistes s'hagin desmuntat de debò.
|
|
8908
|
+
*
|
|
8909
|
+
* És idempotent: desregistrar una vista que ja no hi és no fa res.
|
|
8910
|
+
*/
|
|
8911
|
+
async _removeAllViews() {
|
|
8912
|
+
for (const W of ALL_REGION_NAMES) {
|
|
8913
|
+
const te = this.regionManager.getRegisteredViews(W) ?? [];
|
|
8914
|
+
for (const { key: oe } of [...te])
|
|
8915
|
+
await this.regionManager.unregisterViewFromRegion(W, oe);
|
|
8916
|
+
}
|
|
8917
|
+
}
|
|
8918
|
+
async _destroy() {
|
|
8919
|
+
await this.regionManager.destroy();
|
|
8885
8920
|
}
|
|
8886
8921
|
}
|
|
8887
8922
|
const createRegionManagerProxy = (X, W, te) => new RegionManagerProxy(X, W, te);
|
|
@@ -8943,7 +8978,7 @@ class ImportDataManagerImpl {
|
|
|
8943
8978
|
async import(W, te) {
|
|
8944
8979
|
this.currentImporterId = W, this.currentImportParams = te, this.selectedItems = {}, this.pluginTexts = {};
|
|
8945
8980
|
try {
|
|
8946
|
-
const { ImportDataManagerModal: oe } = await import("./component-
|
|
8981
|
+
const { ImportDataManagerModal: oe } = await import("./component-CQxI1o5p.js"), { confirmed: ne } = await this.interactionService.confirm(
|
|
8947
8982
|
void 0,
|
|
8948
8983
|
{ component: oe },
|
|
8949
8984
|
{
|
|
@@ -9006,7 +9041,7 @@ class PrimariaContextManagerImpl {
|
|
|
9006
9041
|
}
|
|
9007
9042
|
}
|
|
9008
9043
|
let contextManager$1;
|
|
9009
|
-
const createContextManager = () => contextManager$1 || (contextManager$1 = new PrimariaContextManagerImpl(), contextManager$1), broker = createBroker(), regionManager =
|
|
9044
|
+
const createContextManager = () => contextManager$1 || (contextManager$1 = new PrimariaContextManagerImpl(), contextManager$1), broker = createBroker(), regionManager = v$n("primaria"), PrimariaRegionHost = f$o(regionManager), tokenManager = createTokenManager(broker), userManager = createUserManager(tokenManager), activityMonitor = createActivityMonitor(), sessionRefreshTimer = createSessionRefreshTimer(tokenManager, activityMonitor), globalStateManager = createGlobalStateManager(broker), contextManager = createContextManager(), pluginBusyManager = new PluginBusyManagerImpl(), exitGuardManager = new ExitGuardManagerImpl(), quickActionBusyManager = new QuickActionBusyManagerImpl(broker), interactionService = new ParimariaInteractionServiceImpl(), notificationService = new PrimariaNotificationServiceImpl(), ecapEventManager = createEcapEventManager(globalStateManager), pdfViewerManager = createPdfViewerManager(broker, notificationService), importDataManager = new ImportDataManagerImpl(interactionService), primariaApiFactory = (X) => {
|
|
9010
9045
|
const W = createRegionManagerProxy(X, regionManager, broker);
|
|
9011
9046
|
return {
|
|
9012
9047
|
pluginInfo: X,
|
|
@@ -9046,7 +9081,7 @@ const createContextManager = () => contextManager$1 || (contextManager$1 = new P
|
|
|
9046
9081
|
let bootstrappedPlugins = [];
|
|
9047
9082
|
const CORE_FIRST_ID = "activity-history", bundledActivityHistory = {
|
|
9048
9083
|
pluginId: CORE_FIRST_ID,
|
|
9049
|
-
importer: () => import("./plugin-
|
|
9084
|
+
importer: () => import("./plugin-DohFiwSH.js")
|
|
9050
9085
|
}, bootstrapPlugins = async (X, W) => {
|
|
9051
9086
|
const te = X ?? [], oe = te.filter((ue) => ue.pluginId === CORE_FIRST_ID), ne = te.filter((ue) => ue.pluginId !== CORE_FIRST_ID), re = oe.length ? oe : [bundledActivityHistory], de = await p$d(
|
|
9052
9087
|
re,
|
|
@@ -9080,15 +9115,29 @@ let ExitShellHandler = class {
|
|
|
9080
9115
|
if (!ne) return;
|
|
9081
9116
|
}
|
|
9082
9117
|
await Promise.race([
|
|
9083
|
-
|
|
9118
|
+
this.unmountViewsAndDisposePlugins(),
|
|
9084
9119
|
// S'intenta executar un dispose normal
|
|
9085
9120
|
this.timeout(1e4)
|
|
9086
9121
|
// Si passen 5s, es segueix amb l'execució
|
|
9087
|
-
]), disposeShell(), this.emitClose(W);
|
|
9122
|
+
]), await disposeShell(), this.emitClose(W);
|
|
9088
9123
|
} catch {
|
|
9089
9124
|
this.api.notificationService.error(translate("errors.exit")), this.emitClose(W);
|
|
9090
9125
|
}
|
|
9091
9126
|
}
|
|
9127
|
+
/**
|
|
9128
|
+
* Desmunta les vistes de tots els plugins abans de fer-los el `dispose`.
|
|
9129
|
+
*
|
|
9130
|
+
* Els cleanups dels `useEffect` s'executen en desmuntar-se el component i poden enviar comandes
|
|
9131
|
+
* pel broker (p. ex. `ClearTransportDetail` a petitioner). Si el `dispose` s'executa primer, el
|
|
9132
|
+
* handler ja no hi és i el `send` rebutja. Cada plugin d'aquest repositori ja desmunta les seves
|
|
9133
|
+
* vistes primer, però els de tercers no els controlem: fer-ho aquí els cobreix tots.
|
|
9134
|
+
*
|
|
9135
|
+
* Va dins del mateix `Promise.race` que el `dispose`, així que el límit de temps del tancament
|
|
9136
|
+
* no canvia.
|
|
9137
|
+
*/
|
|
9138
|
+
async unmountViewsAndDisposePlugins() {
|
|
9139
|
+
await this.api.regionManager._removeAllViews(), await disposePlugins();
|
|
9140
|
+
}
|
|
9092
9141
|
timeout(X) {
|
|
9093
9142
|
return new Promise((W) => setTimeout(W, X));
|
|
9094
9143
|
}
|
|
@@ -9190,10 +9239,10 @@ const useGetUserInfo = (X) => {
|
|
|
9190
9239
|
request?.dispose(), unregisterDep(GetUserInfoBackendAdapter);
|
|
9191
9240
|
}, useFeatures = (X) => {
|
|
9192
9241
|
container.bind(TYPES.primaryApi).toConstantValue(X), useGetUserInfo(X), useExitShell(X), X.broker.send(new GetUserInfo());
|
|
9193
|
-
}, disposeFeatures = (X) => {
|
|
9194
|
-
disposeGetUserInfo(), disposeExitShell(), container.unbindAll(), X.regionManager._destroy(), X.broker._clear();
|
|
9195
|
-
}, disposeShell = () => {
|
|
9196
|
-
disposeFeatures(shellApi), shellApi.interactionService.dispose(), sessionRefreshTimer.stop(), activityMonitor.stop();
|
|
9242
|
+
}, disposeFeatures = async (X) => {
|
|
9243
|
+
disposeGetUserInfo(), disposeExitShell(), container.unbindAll(), await X.regionManager._destroy(), X.broker._clear();
|
|
9244
|
+
}, disposeShell = async () => {
|
|
9245
|
+
await disposeFeatures(shellApi), shellApi.interactionService.dispose(), sessionRefreshTimer.stop(), activityMonitor.stop();
|
|
9197
9246
|
}, raiseCloseEvent = () => {
|
|
9198
9247
|
shellApi.ecapEventManager.publish("CLOSE_FORM", "", {});
|
|
9199
9248
|
}, raiseCustomCloseEvent = (X) => {
|
|
@@ -10723,18 +10772,18 @@ function flip(X) {
|
|
|
10723
10772
|
}
|
|
10724
10773
|
if (ze)
|
|
10725
10774
|
for (var Ke = ve ? 3 : 1, Fe = function(tt) {
|
|
10726
|
-
var
|
|
10775
|
+
var Be = we.find(function(Je) {
|
|
10727
10776
|
var nt = Ie.get(Je);
|
|
10728
10777
|
if (nt)
|
|
10729
10778
|
return nt.slice(0, tt).every(function(ft) {
|
|
10730
10779
|
return ft;
|
|
10731
10780
|
});
|
|
10732
10781
|
});
|
|
10733
|
-
if (
|
|
10734
|
-
return Ue =
|
|
10782
|
+
if (Be)
|
|
10783
|
+
return Ue = Be, "break";
|
|
10735
10784
|
}, je = Ke; je > 0; je--) {
|
|
10736
|
-
var
|
|
10737
|
-
if (
|
|
10785
|
+
var Ve = Fe(je);
|
|
10786
|
+
if (Ve === "break") break;
|
|
10738
10787
|
}
|
|
10739
10788
|
W.placement !== Ue && (W.modifiersData[oe]._skip = !0, W.placement = Ue, W.reset = !0);
|
|
10740
10789
|
}
|
|
@@ -10851,10 +10900,10 @@ function preventOverflow(X) {
|
|
|
10851
10900
|
};
|
|
10852
10901
|
if (Me) {
|
|
10853
10902
|
if (re) {
|
|
10854
|
-
var Pe, He = we === "y" ? top : left, Ge = we === "y" ? bottom : right, Ze = we === "y" ? "height" : "width", Ye = Me[we], bt = Ye + _e[He], Xe = Ye - _e[Ge], Ke = ge ? -ze[Ze] / 2 : 0, Fe = Ae === start ? Ie[Ze] : ze[Ze], je = Ae === start ? -ze[Ze] : -Ie[Ze],
|
|
10903
|
+
var Pe, He = we === "y" ? top : left, Ge = we === "y" ? bottom : right, Ze = we === "y" ? "height" : "width", Ye = Me[we], bt = Ye + _e[He], Xe = Ye - _e[Ge], Ke = ge ? -ze[Ze] / 2 : 0, Fe = Ae === start ? Ie[Ze] : ze[Ze], je = Ae === start ? -ze[Ze] : -Ie[Ze], Ve = W.elements.arrow, Qe = ge && Ve ? getLayoutRect(Ve) : {
|
|
10855
10904
|
width: 0,
|
|
10856
10905
|
height: 0
|
|
10857
|
-
}, tt = W.modifiersData["arrow#persistent"] ? W.modifiersData["arrow#persistent"].padding : getFreshSideObject(),
|
|
10906
|
+
}, tt = W.modifiersData["arrow#persistent"] ? W.modifiersData["arrow#persistent"].padding : getFreshSideObject(), Be = tt[He], Je = tt[Ge], nt = within(0, Ie[Ze], Qe[Ze]), ft = Ce ? Ie[Ze] / 2 - Ke - nt - Be - Le.mainAxis : Fe - nt - Be - Le.mainAxis, $t = Ce ? -Ie[Ze] / 2 + Ke + nt + Je + Le.mainAxis : je + nt + Je + Le.mainAxis, St = W.elements.arrow && getOffsetParent(W.elements.arrow), Pt = St ? we === "y" ? St.clientTop || 0 : St.clientLeft || 0 : 0, It = (Pe = Oe?.[we]) != null ? Pe : 0, Ht = Ye + ft - It - Pt, jt = Ye + $t - It, ns = within(ge ? min(bt, Ht) : bt, Ye, ge ? max(Xe, jt) : Xe);
|
|
10858
10907
|
Me[we] = ns, qe[we] = ns - Ye;
|
|
10859
10908
|
}
|
|
10860
10909
|
if (ce) {
|
|
@@ -36344,15 +36393,15 @@ var __defProp$e = Object.defineProperty, __decorateClass$e = (X, W, te, oe) => {
|
|
|
36344
36393
|
(de = X[re]) && (ne = de(W, te, ne) || ne);
|
|
36345
36394
|
return ne && __defProp$e(W, te, ne), ne;
|
|
36346
36395
|
};
|
|
36347
|
-
const
|
|
36396
|
+
const Vs = class Vs extends h$n {
|
|
36348
36397
|
render() {
|
|
36349
36398
|
return ke$1`${template$9(this)}`;
|
|
36350
36399
|
}
|
|
36351
36400
|
};
|
|
36352
|
-
|
|
36401
|
+
Vs.styles = i$R`
|
|
36353
36402
|
${r$L(styles$8)}
|
|
36354
36403
|
`;
|
|
36355
|
-
let PrimariaErrorView =
|
|
36404
|
+
let PrimariaErrorView = Vs;
|
|
36356
36405
|
__decorateClass$e([
|
|
36357
36406
|
n$A()
|
|
36358
36407
|
], PrimariaErrorView.prototype, "error");
|
|
@@ -36429,7 +36478,7 @@ var __defProp$d = Object.defineProperty, __decorateClass$d = (X, W, te, oe) => {
|
|
|
36429
36478
|
(de = X[re]) && (ne = de(W, te, ne) || ne);
|
|
36430
36479
|
return ne && __defProp$d(W, te, ne), ne;
|
|
36431
36480
|
};
|
|
36432
|
-
const
|
|
36481
|
+
const Bs = class Bs extends PrimariaRegionHost(h$n) {
|
|
36433
36482
|
constructor() {
|
|
36434
36483
|
super(...arguments), this.menuOpened = !1;
|
|
36435
36484
|
}
|
|
@@ -36463,10 +36512,10 @@ const Vs = class Vs extends PrimariaRegionHost(h$n) {
|
|
|
36463
36512
|
te = new MutationObserver(oe), te.observe(W, { childList: !0 });
|
|
36464
36513
|
}
|
|
36465
36514
|
};
|
|
36466
|
-
|
|
36515
|
+
Bs.styles = i$R`
|
|
36467
36516
|
${r$L(styles$7)}
|
|
36468
36517
|
`;
|
|
36469
|
-
let PrimariaShellHeader =
|
|
36518
|
+
let PrimariaShellHeader = Bs;
|
|
36470
36519
|
__decorateClass$d([
|
|
36471
36520
|
s$H({ targetId: "header-region-container", name: shellApi.regionManager.regions.shell.header })
|
|
36472
36521
|
], PrimariaShellHeader.prototype, "headerRegion");
|
|
@@ -37486,15 +37535,15 @@ function requireQuill() {
|
|
|
37486
37535
|
return Xe && typeof Symbol == "function" && Xe.constructor === Symbol && Xe !== Symbol.prototype ? "symbol" : typeof Xe;
|
|
37487
37536
|
}, de = /* @__PURE__ */ (function() {
|
|
37488
37537
|
function Xe(Ke, Fe) {
|
|
37489
|
-
var je = [],
|
|
37538
|
+
var je = [], Ve = !0, Qe = !1, tt = void 0;
|
|
37490
37539
|
try {
|
|
37491
|
-
for (var
|
|
37540
|
+
for (var Be = Ke[Symbol.iterator](), Je; !(Ve = (Je = Be.next()).done) && (je.push(Je.value), !(Fe && je.length === Fe)); Ve = !0)
|
|
37492
37541
|
;
|
|
37493
37542
|
} catch (nt) {
|
|
37494
37543
|
Qe = !0, tt = nt;
|
|
37495
37544
|
} finally {
|
|
37496
37545
|
try {
|
|
37497
|
-
!
|
|
37546
|
+
!Ve && Be.return && Be.return();
|
|
37498
37547
|
} finally {
|
|
37499
37548
|
if (Qe) throw tt;
|
|
37500
37549
|
}
|
|
@@ -37511,8 +37560,8 @@ function requireQuill() {
|
|
|
37511
37560
|
})(), ce = /* @__PURE__ */ (function() {
|
|
37512
37561
|
function Xe(Ke, Fe) {
|
|
37513
37562
|
for (var je = 0; je < Fe.length; je++) {
|
|
37514
|
-
var
|
|
37515
|
-
|
|
37563
|
+
var Ve = Fe[je];
|
|
37564
|
+
Ve.enumerable = Ve.enumerable || !1, Ve.configurable = !0, "value" in Ve && (Ve.writable = !0), Object.defineProperty(Ke, Ve.key, Ve);
|
|
37516
37565
|
}
|
|
37517
37566
|
}
|
|
37518
37567
|
return function(Ke, Fe, je) {
|
|
@@ -37550,11 +37599,11 @@ function requireQuill() {
|
|
|
37550
37599
|
}, {
|
|
37551
37600
|
key: "register",
|
|
37552
37601
|
value: function(Fe, je) {
|
|
37553
|
-
var
|
|
37602
|
+
var Ve = this, Qe = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : !1;
|
|
37554
37603
|
if (typeof Fe != "string") {
|
|
37555
37604
|
var tt = Fe.attrName || Fe.blotName;
|
|
37556
|
-
typeof tt == "string" ? this.register("formats/" + tt, Fe, je) : Object.keys(Fe).forEach(function(
|
|
37557
|
-
|
|
37605
|
+
typeof tt == "string" ? this.register("formats/" + tt, Fe, je) : Object.keys(Fe).forEach(function(Be) {
|
|
37606
|
+
Ve.register(Be, Fe[Be], je);
|
|
37558
37607
|
});
|
|
37559
37608
|
} else
|
|
37560
37609
|
this.imports[Fe] != null && !Qe && Pe.warn("Overwriting " + Fe + " with", je), this.imports[Fe] = je, (Fe.startsWith("blots/") || Fe.startsWith("formats/")) && je.blotName !== "abstract" ? ye.default.register(je) : Fe.startsWith("modules") && typeof je.register == "function" && je.register();
|
|
@@ -37565,19 +37614,19 @@ function requireQuill() {
|
|
|
37565
37614
|
if (qe(this, Xe), this.options = Ge(Ke, je), this.container = this.options.container, this.container == null)
|
|
37566
37615
|
return Pe.error("Invalid Quill container", Ke);
|
|
37567
37616
|
this.options.debug && Xe.debug(this.options.debug);
|
|
37568
|
-
var
|
|
37617
|
+
var Ve = this.container.innerHTML.trim();
|
|
37569
37618
|
this.container.classList.add("ql-container"), this.container.innerHTML = "", this.container.__quill = this, this.root = this.addContainer("ql-editor"), this.root.classList.add("ql-blank"), this.root.setAttribute("data-gramm", !1), this.scrollingContainer = this.options.scrollingContainer || this.root, this.emitter = new ge.default(), this.scroll = ye.default.create(this.root, {
|
|
37570
37619
|
emitter: this.emitter,
|
|
37571
37620
|
whitelist: this.options.formats
|
|
37572
37621
|
}), this.editor = new be.default(this.scroll), this.selection = new Ce.default(this.scroll, this.emitter), this.theme = new this.options.theme(this, this.options), this.keyboard = this.theme.addModule("keyboard"), this.clipboard = this.theme.addModule("clipboard"), this.history = this.theme.addModule("history"), this.theme.init(), this.emitter.on(ge.default.events.EDITOR_CHANGE, function(tt) {
|
|
37573
37622
|
tt === ge.default.events.TEXT_CHANGE && Fe.root.classList.toggle("ql-blank", Fe.editor.isBlank());
|
|
37574
|
-
}), this.emitter.on(ge.default.events.SCROLL_UPDATE, function(tt,
|
|
37623
|
+
}), this.emitter.on(ge.default.events.SCROLL_UPDATE, function(tt, Be) {
|
|
37575
37624
|
var Je = Fe.selection.lastRange, nt = Je && Je.length === 0 ? Je.index : void 0;
|
|
37576
37625
|
Ze.call(Fe, function() {
|
|
37577
|
-
return Fe.editor.update(null,
|
|
37626
|
+
return Fe.editor.update(null, Be, nt);
|
|
37578
37627
|
}, tt);
|
|
37579
37628
|
});
|
|
37580
|
-
var Qe = this.clipboard.convert(`<div class='ql-editor' style="white-space: normal;">` +
|
|
37629
|
+
var Qe = this.clipboard.convert(`<div class='ql-editor' style="white-space: normal;">` + Ve + "<p><br></p></div>");
|
|
37581
37630
|
this.setContents(Qe), this.history.clear(), this.options.placeholder && this.root.setAttribute("data-placeholder", this.options.placeholder), this.options.readOnly && this.disable();
|
|
37582
37631
|
}
|
|
37583
37632
|
return ce(Xe, [{
|
|
@@ -37585,8 +37634,8 @@ function requireQuill() {
|
|
|
37585
37634
|
value: function(Fe) {
|
|
37586
37635
|
var je = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : null;
|
|
37587
37636
|
if (typeof Fe == "string") {
|
|
37588
|
-
var
|
|
37589
|
-
Fe = document.createElement("div"), Fe.classList.add(
|
|
37637
|
+
var Ve = Fe;
|
|
37638
|
+
Fe = document.createElement("div"), Fe.classList.add(Ve);
|
|
37590
37639
|
}
|
|
37591
37640
|
return this.container.insertBefore(Fe, je), Fe;
|
|
37592
37641
|
}
|
|
@@ -37597,11 +37646,11 @@ function requireQuill() {
|
|
|
37597
37646
|
}
|
|
37598
37647
|
}, {
|
|
37599
37648
|
key: "deleteText",
|
|
37600
|
-
value: function(Fe, je,
|
|
37601
|
-
var Qe = this, tt = Ye(Fe, je,
|
|
37602
|
-
return Fe =
|
|
37649
|
+
value: function(Fe, je, Ve) {
|
|
37650
|
+
var Qe = this, tt = Ye(Fe, je, Ve), Be = de(tt, 4);
|
|
37651
|
+
return Fe = Be[0], je = Be[1], Ve = Be[3], Ze.call(this, function() {
|
|
37603
37652
|
return Qe.editor.deleteText(Fe, je);
|
|
37604
|
-
},
|
|
37653
|
+
}, Ve, Fe, -1 * je);
|
|
37605
37654
|
}
|
|
37606
37655
|
}, {
|
|
37607
37656
|
key: "disable",
|
|
@@ -37623,56 +37672,56 @@ function requireQuill() {
|
|
|
37623
37672
|
}, {
|
|
37624
37673
|
key: "format",
|
|
37625
37674
|
value: function(Fe, je) {
|
|
37626
|
-
var
|
|
37675
|
+
var Ve = this, Qe = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : ge.default.sources.API;
|
|
37627
37676
|
return Ze.call(this, function() {
|
|
37628
|
-
var tt =
|
|
37677
|
+
var tt = Ve.getSelection(!0), Be = new fe.default();
|
|
37629
37678
|
if (tt == null)
|
|
37630
|
-
return
|
|
37679
|
+
return Be;
|
|
37631
37680
|
if (ye.default.query(Fe, ye.default.Scope.BLOCK))
|
|
37632
|
-
|
|
37681
|
+
Be = Ve.editor.formatLine(tt.index, tt.length, Oe({}, Fe, je));
|
|
37633
37682
|
else {
|
|
37634
37683
|
if (tt.length === 0)
|
|
37635
|
-
return
|
|
37636
|
-
|
|
37684
|
+
return Ve.selection.format(Fe, je), Be;
|
|
37685
|
+
Be = Ve.editor.formatText(tt.index, tt.length, Oe({}, Fe, je));
|
|
37637
37686
|
}
|
|
37638
|
-
return
|
|
37687
|
+
return Ve.setSelection(tt, ge.default.sources.SILENT), Be;
|
|
37639
37688
|
}, Qe);
|
|
37640
37689
|
}
|
|
37641
37690
|
}, {
|
|
37642
37691
|
key: "formatLine",
|
|
37643
|
-
value: function(Fe, je,
|
|
37644
|
-
var
|
|
37692
|
+
value: function(Fe, je, Ve, Qe, tt) {
|
|
37693
|
+
var Be = this, Je = void 0, nt = Ye(Fe, je, Ve, Qe, tt), ft = de(nt, 4);
|
|
37645
37694
|
return Fe = ft[0], je = ft[1], Je = ft[2], tt = ft[3], Ze.call(this, function() {
|
|
37646
|
-
return
|
|
37695
|
+
return Be.editor.formatLine(Fe, je, Je);
|
|
37647
37696
|
}, tt, Fe, 0);
|
|
37648
37697
|
}
|
|
37649
37698
|
}, {
|
|
37650
37699
|
key: "formatText",
|
|
37651
|
-
value: function(Fe, je,
|
|
37652
|
-
var
|
|
37700
|
+
value: function(Fe, je, Ve, Qe, tt) {
|
|
37701
|
+
var Be = this, Je = void 0, nt = Ye(Fe, je, Ve, Qe, tt), ft = de(nt, 4);
|
|
37653
37702
|
return Fe = ft[0], je = ft[1], Je = ft[2], tt = ft[3], Ze.call(this, function() {
|
|
37654
|
-
return
|
|
37703
|
+
return Be.editor.formatText(Fe, je, Je);
|
|
37655
37704
|
}, tt, Fe, 0);
|
|
37656
37705
|
}
|
|
37657
37706
|
}, {
|
|
37658
37707
|
key: "getBounds",
|
|
37659
37708
|
value: function(Fe) {
|
|
37660
|
-
var je = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0,
|
|
37661
|
-
typeof Fe == "number" ?
|
|
37709
|
+
var je = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0, Ve = void 0;
|
|
37710
|
+
typeof Fe == "number" ? Ve = this.selection.getBounds(Fe, je) : Ve = this.selection.getBounds(Fe.index, Fe.length);
|
|
37662
37711
|
var Qe = this.container.getBoundingClientRect();
|
|
37663
37712
|
return {
|
|
37664
|
-
bottom:
|
|
37665
|
-
height:
|
|
37666
|
-
left:
|
|
37667
|
-
right:
|
|
37668
|
-
top:
|
|
37669
|
-
width:
|
|
37713
|
+
bottom: Ve.bottom - Qe.top,
|
|
37714
|
+
height: Ve.height,
|
|
37715
|
+
left: Ve.left - Qe.left,
|
|
37716
|
+
right: Ve.right - Qe.left,
|
|
37717
|
+
top: Ve.top - Qe.top,
|
|
37718
|
+
width: Ve.width
|
|
37670
37719
|
};
|
|
37671
37720
|
}
|
|
37672
37721
|
}, {
|
|
37673
37722
|
key: "getContents",
|
|
37674
37723
|
value: function() {
|
|
37675
|
-
var Fe = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 0, je = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : this.getLength() - Fe,
|
|
37724
|
+
var Fe = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 0, je = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : this.getLength() - Fe, Ve = Ye(Fe, je), Qe = de(Ve, 2);
|
|
37676
37725
|
return Fe = Qe[0], je = Qe[1], this.editor.getContents(Fe, je);
|
|
37677
37726
|
}
|
|
37678
37727
|
}, {
|
|
@@ -37721,7 +37770,7 @@ function requireQuill() {
|
|
|
37721
37770
|
}, {
|
|
37722
37771
|
key: "getText",
|
|
37723
37772
|
value: function() {
|
|
37724
|
-
var Fe = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 0, je = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : this.getLength() - Fe,
|
|
37773
|
+
var Fe = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 0, je = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : this.getLength() - Fe, Ve = Ye(Fe, je), Qe = de(Ve, 2);
|
|
37725
37774
|
return Fe = Qe[0], je = Qe[1], this.editor.getText(Fe, je);
|
|
37726
37775
|
}
|
|
37727
37776
|
}, {
|
|
@@ -37731,18 +37780,18 @@ function requireQuill() {
|
|
|
37731
37780
|
}
|
|
37732
37781
|
}, {
|
|
37733
37782
|
key: "insertEmbed",
|
|
37734
|
-
value: function(Fe, je,
|
|
37783
|
+
value: function(Fe, je, Ve) {
|
|
37735
37784
|
var Qe = this, tt = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : Xe.sources.API;
|
|
37736
37785
|
return Ze.call(this, function() {
|
|
37737
|
-
return Qe.editor.insertEmbed(Fe, je,
|
|
37786
|
+
return Qe.editor.insertEmbed(Fe, je, Ve);
|
|
37738
37787
|
}, tt, Fe);
|
|
37739
37788
|
}
|
|
37740
37789
|
}, {
|
|
37741
37790
|
key: "insertText",
|
|
37742
|
-
value: function(Fe, je,
|
|
37743
|
-
var
|
|
37791
|
+
value: function(Fe, je, Ve, Qe, tt) {
|
|
37792
|
+
var Be = this, Je = void 0, nt = Ye(Fe, 0, Ve, Qe, tt), ft = de(nt, 4);
|
|
37744
37793
|
return Fe = ft[0], Je = ft[2], tt = ft[3], Ze.call(this, function() {
|
|
37745
|
-
return
|
|
37794
|
+
return Be.editor.insertText(Fe, je, Je);
|
|
37746
37795
|
}, tt, Fe, je.length);
|
|
37747
37796
|
}
|
|
37748
37797
|
}, {
|
|
@@ -37767,16 +37816,16 @@ function requireQuill() {
|
|
|
37767
37816
|
}
|
|
37768
37817
|
}, {
|
|
37769
37818
|
key: "pasteHTML",
|
|
37770
|
-
value: function(Fe, je,
|
|
37771
|
-
this.clipboard.dangerouslyPasteHTML(Fe, je,
|
|
37819
|
+
value: function(Fe, je, Ve) {
|
|
37820
|
+
this.clipboard.dangerouslyPasteHTML(Fe, je, Ve);
|
|
37772
37821
|
}
|
|
37773
37822
|
}, {
|
|
37774
37823
|
key: "removeFormat",
|
|
37775
|
-
value: function(Fe, je,
|
|
37776
|
-
var Qe = this, tt = Ye(Fe, je,
|
|
37777
|
-
return Fe =
|
|
37824
|
+
value: function(Fe, je, Ve) {
|
|
37825
|
+
var Qe = this, tt = Ye(Fe, je, Ve), Be = de(tt, 4);
|
|
37826
|
+
return Fe = Be[0], je = Be[1], Ve = Be[3], Ze.call(this, function() {
|
|
37778
37827
|
return Qe.editor.removeFormat(Fe, je);
|
|
37779
|
-
},
|
|
37828
|
+
}, Ve, Fe);
|
|
37780
37829
|
}
|
|
37781
37830
|
}, {
|
|
37782
37831
|
key: "scrollIntoView",
|
|
@@ -37786,31 +37835,31 @@ function requireQuill() {
|
|
|
37786
37835
|
}, {
|
|
37787
37836
|
key: "setContents",
|
|
37788
37837
|
value: function(Fe) {
|
|
37789
|
-
var je = this,
|
|
37838
|
+
var je = this, Ve = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : ge.default.sources.API;
|
|
37790
37839
|
return Ze.call(this, function() {
|
|
37791
37840
|
Fe = new fe.default(Fe);
|
|
37792
|
-
var Qe = je.getLength(), tt = je.editor.deleteText(0, Qe),
|
|
37841
|
+
var Qe = je.getLength(), tt = je.editor.deleteText(0, Qe), Be = je.editor.applyDelta(Fe), Je = Be.ops[Be.ops.length - 1];
|
|
37793
37842
|
Je != null && typeof Je.insert == "string" && Je.insert[Je.insert.length - 1] === `
|
|
37794
|
-
` && (je.editor.deleteText(je.getLength() - 1, 1),
|
|
37795
|
-
var nt = tt.compose(
|
|
37843
|
+
` && (je.editor.deleteText(je.getLength() - 1, 1), Be.delete(1));
|
|
37844
|
+
var nt = tt.compose(Be);
|
|
37796
37845
|
return nt;
|
|
37797
|
-
},
|
|
37846
|
+
}, Ve);
|
|
37798
37847
|
}
|
|
37799
37848
|
}, {
|
|
37800
37849
|
key: "setSelection",
|
|
37801
|
-
value: function(Fe, je,
|
|
37850
|
+
value: function(Fe, je, Ve) {
|
|
37802
37851
|
if (Fe == null)
|
|
37803
37852
|
this.selection.setRange(null, je || Xe.sources.API);
|
|
37804
37853
|
else {
|
|
37805
|
-
var Qe = Ye(Fe, je,
|
|
37806
|
-
Fe = tt[0], je = tt[1],
|
|
37854
|
+
var Qe = Ye(Fe, je, Ve), tt = de(Qe, 4);
|
|
37855
|
+
Fe = tt[0], je = tt[1], Ve = tt[3], this.selection.setRange(new Ae.Range(Fe, je), Ve), Ve !== ge.default.sources.SILENT && this.selection.scrollIntoView(this.scrollingContainer);
|
|
37807
37856
|
}
|
|
37808
37857
|
}
|
|
37809
37858
|
}, {
|
|
37810
37859
|
key: "setText",
|
|
37811
37860
|
value: function(Fe) {
|
|
37812
|
-
var je = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : ge.default.sources.API,
|
|
37813
|
-
return this.setContents(
|
|
37861
|
+
var je = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : ge.default.sources.API, Ve = new fe.default().insert(Fe);
|
|
37862
|
+
return this.setContents(Ve, je);
|
|
37814
37863
|
}
|
|
37815
37864
|
}, {
|
|
37816
37865
|
key: "update",
|
|
@@ -37821,10 +37870,10 @@ function requireQuill() {
|
|
|
37821
37870
|
}, {
|
|
37822
37871
|
key: "updateContents",
|
|
37823
37872
|
value: function(Fe) {
|
|
37824
|
-
var je = this,
|
|
37873
|
+
var je = this, Ve = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : ge.default.sources.API;
|
|
37825
37874
|
return Ze.call(this, function() {
|
|
37826
|
-
return Fe = new fe.default(Fe), je.editor.applyDelta(Fe,
|
|
37827
|
-
},
|
|
37875
|
+
return Fe = new fe.default(Fe), je.editor.applyDelta(Fe, Ve);
|
|
37876
|
+
}, Ve, !0);
|
|
37828
37877
|
}
|
|
37829
37878
|
}]), Xe;
|
|
37830
37879
|
})();
|
|
@@ -37861,13 +37910,13 @@ function requireQuill() {
|
|
|
37861
37910
|
Qe.modules[tt] === !0 && (Qe.modules[tt] = {});
|
|
37862
37911
|
});
|
|
37863
37912
|
});
|
|
37864
|
-
var je = Object.keys(Fe.modules).concat(Object.keys(Ke.modules)),
|
|
37865
|
-
var
|
|
37866
|
-
return
|
|
37913
|
+
var je = Object.keys(Fe.modules).concat(Object.keys(Ke.modules)), Ve = je.reduce(function(Qe, tt) {
|
|
37914
|
+
var Be = He.import("modules/" + tt);
|
|
37915
|
+
return Be == null ? Pe.error("Cannot load " + tt + " module. Are you sure you registered it?") : Qe[tt] = Be.DEFAULTS || {}, Qe;
|
|
37867
37916
|
}, {});
|
|
37868
37917
|
return Ke.modules != null && Ke.modules.toolbar && Ke.modules.toolbar.constructor !== Object && (Ke.modules.toolbar = {
|
|
37869
37918
|
container: Ke.modules.toolbar
|
|
37870
|
-
}), Ke = (0, Se.default)(!0, {}, He.DEFAULTS, { modules:
|
|
37919
|
+
}), Ke = (0, Se.default)(!0, {}, He.DEFAULTS, { modules: Ve }, Fe, Ke), ["bounds", "container", "scrollingContainer"].forEach(function(Qe) {
|
|
37871
37920
|
typeof Ke[Qe] == "string" && (Ke[Qe] = document.querySelector(Ke[Qe]));
|
|
37872
37921
|
}), Ke.modules = Object.keys(Ke.modules).reduce(function(Qe, tt) {
|
|
37873
37922
|
return Ke.modules[tt] && (Qe[tt] = Ke.modules[tt]), Qe;
|
|
@@ -37876,35 +37925,35 @@ function requireQuill() {
|
|
|
37876
37925
|
function Ze(Xe, Ke, Fe, je) {
|
|
37877
37926
|
if (this.options.strict && !this.isEnabled() && Ke === ge.default.sources.USER)
|
|
37878
37927
|
return new fe.default();
|
|
37879
|
-
var
|
|
37880
|
-
if (
|
|
37881
|
-
var
|
|
37882
|
-
if ((
|
|
37928
|
+
var Ve = Fe == null ? null : this.getSelection(), Qe = this.editor.delta, tt = Xe();
|
|
37929
|
+
if (Ve != null && (Fe === !0 && (Fe = Ve.index), je == null ? Ve = bt(Ve, tt, Ke) : je !== 0 && (Ve = bt(Ve, Fe, je, Ke)), this.setSelection(Ve, ge.default.sources.SILENT)), tt.length() > 0) {
|
|
37930
|
+
var Be, Je = [ge.default.events.TEXT_CHANGE, tt, Qe, Ke];
|
|
37931
|
+
if ((Be = this.emitter).emit.apply(Be, [ge.default.events.EDITOR_CHANGE].concat(Je)), Ke !== ge.default.sources.SILENT) {
|
|
37883
37932
|
var nt;
|
|
37884
37933
|
(nt = this.emitter).emit.apply(nt, Je);
|
|
37885
37934
|
}
|
|
37886
37935
|
}
|
|
37887
37936
|
return tt;
|
|
37888
37937
|
}
|
|
37889
|
-
function Ye(Xe, Ke, Fe, je,
|
|
37938
|
+
function Ye(Xe, Ke, Fe, je, Ve) {
|
|
37890
37939
|
var Qe = {};
|
|
37891
|
-
return typeof Xe.index == "number" && typeof Xe.length == "number" ? typeof Ke != "number" ? (
|
|
37940
|
+
return typeof Xe.index == "number" && typeof Xe.length == "number" ? typeof Ke != "number" ? (Ve = je, je = Fe, Fe = Ke, Ke = Xe.length, Xe = Xe.index) : (Ke = Xe.length, Xe = Xe.index) : typeof Ke != "number" && (Ve = je, je = Fe, Fe = Ke, Ke = 0), (typeof Fe > "u" ? "undefined" : re(Fe)) === "object" ? (Qe = Fe, Ve = je) : typeof Fe == "string" && (je != null ? Qe[Fe] = je : Ve = Fe), Ve = Ve || ge.default.sources.API, [Xe, Ke, Qe, Ve];
|
|
37892
37941
|
}
|
|
37893
37942
|
function bt(Xe, Ke, Fe, je) {
|
|
37894
37943
|
if (Xe == null) return null;
|
|
37895
|
-
var
|
|
37944
|
+
var Ve = void 0, Qe = void 0;
|
|
37896
37945
|
if (Ke instanceof fe.default) {
|
|
37897
37946
|
var tt = [Xe.index, Xe.index + Xe.length].map(function(ft) {
|
|
37898
37947
|
return Ke.transformPosition(ft, je !== ge.default.sources.USER);
|
|
37899
|
-
}),
|
|
37900
|
-
|
|
37948
|
+
}), Be = de(tt, 2);
|
|
37949
|
+
Ve = Be[0], Qe = Be[1];
|
|
37901
37950
|
} else {
|
|
37902
37951
|
var Je = [Xe.index, Xe.index + Xe.length].map(function(ft) {
|
|
37903
37952
|
return ft < Ke || ft === Ke && je === ge.default.sources.USER ? ft : Fe >= 0 ? ft + Fe : Math.max(Ke, ft + Fe);
|
|
37904
37953
|
}), nt = de(Je, 2);
|
|
37905
|
-
|
|
37954
|
+
Ve = nt[0], Qe = nt[1];
|
|
37906
37955
|
}
|
|
37907
|
-
return new Ae.Range(
|
|
37956
|
+
return new Ae.Range(Ve, Qe - Ve);
|
|
37908
37957
|
}
|
|
37909
37958
|
oe.expandConfig = Ge, oe.overload = Ye, oe.default = He;
|
|
37910
37959
|
}),
|
|
@@ -38431,15 +38480,15 @@ function requireQuill() {
|
|
|
38431
38480
|
return Xe && typeof Symbol == "function" && Xe.constructor === Symbol && Xe !== Symbol.prototype ? "symbol" : typeof Xe;
|
|
38432
38481
|
}, de = /* @__PURE__ */ (function() {
|
|
38433
38482
|
function Xe(Ke, Fe) {
|
|
38434
|
-
var je = [],
|
|
38483
|
+
var je = [], Ve = !0, Qe = !1, tt = void 0;
|
|
38435
38484
|
try {
|
|
38436
|
-
for (var
|
|
38485
|
+
for (var Be = Ke[Symbol.iterator](), Je; !(Ve = (Je = Be.next()).done) && (je.push(Je.value), !(Fe && je.length === Fe)); Ve = !0)
|
|
38437
38486
|
;
|
|
38438
38487
|
} catch (nt) {
|
|
38439
38488
|
Qe = !0, tt = nt;
|
|
38440
38489
|
} finally {
|
|
38441
38490
|
try {
|
|
38442
|
-
!
|
|
38491
|
+
!Ve && Be.return && Be.return();
|
|
38443
38492
|
} finally {
|
|
38444
38493
|
if (Qe) throw tt;
|
|
38445
38494
|
}
|
|
@@ -38456,8 +38505,8 @@ function requireQuill() {
|
|
|
38456
38505
|
})(), ce = /* @__PURE__ */ (function() {
|
|
38457
38506
|
function Xe(Ke, Fe) {
|
|
38458
38507
|
for (var je = 0; je < Fe.length; je++) {
|
|
38459
|
-
var
|
|
38460
|
-
|
|
38508
|
+
var Ve = Fe[je];
|
|
38509
|
+
Ve.enumerable = Ve.enumerable || !1, Ve.configurable = !0, "value" in Ve && (Ve.writable = !0), Object.defineProperty(Ke, Ve.key, Ve);
|
|
38461
38510
|
}
|
|
38462
38511
|
}
|
|
38463
38512
|
return function(Ke, Fe, je) {
|
|
@@ -38481,35 +38530,35 @@ function requireQuill() {
|
|
|
38481
38530
|
return ce(Xe, [{
|
|
38482
38531
|
key: "applyDelta",
|
|
38483
38532
|
value: function(Fe) {
|
|
38484
|
-
var je = this,
|
|
38533
|
+
var je = this, Ve = !1;
|
|
38485
38534
|
this.scroll.update();
|
|
38486
38535
|
var Qe = this.scroll.length();
|
|
38487
|
-
return this.scroll.batchStart(), Fe = bt(Fe), Fe.reduce(function(tt,
|
|
38488
|
-
var Je =
|
|
38489
|
-
if (
|
|
38490
|
-
if (typeof
|
|
38491
|
-
var ft =
|
|
38536
|
+
return this.scroll.batchStart(), Fe = bt(Fe), Fe.reduce(function(tt, Be) {
|
|
38537
|
+
var Je = Be.retain || Be.delete || Be.insert.length || 1, nt = Be.attributes || {};
|
|
38538
|
+
if (Be.insert != null) {
|
|
38539
|
+
if (typeof Be.insert == "string") {
|
|
38540
|
+
var ft = Be.insert;
|
|
38492
38541
|
ft.endsWith(`
|
|
38493
|
-
`) &&
|
|
38494
|
-
`) && (
|
|
38542
|
+
`) && Ve && (Ve = !1, ft = ft.slice(0, -1)), tt >= Qe && !ft.endsWith(`
|
|
38543
|
+
`) && (Ve = !0), je.scroll.insertAt(tt, ft);
|
|
38495
38544
|
var $t = je.scroll.line(tt), St = de($t, 2), Pt = St[0], It = St[1], Ht = (0, Oe.default)({}, (0, Ae.bubbleFormats)(Pt));
|
|
38496
38545
|
if (Pt instanceof Ce.default) {
|
|
38497
38546
|
var jt = Pt.descendant(ge.default.Leaf, It), ns = de(jt, 1), es = ns[0];
|
|
38498
38547
|
Ht = (0, Oe.default)(Ht, (0, Ae.bubbleFormats)(es));
|
|
38499
38548
|
}
|
|
38500
38549
|
nt = be.default.attributes.diff(Ht, nt) || {};
|
|
38501
|
-
} else if (re(
|
|
38502
|
-
var vt = Object.keys(
|
|
38550
|
+
} else if (re(Be.insert) === "object") {
|
|
38551
|
+
var vt = Object.keys(Be.insert)[0];
|
|
38503
38552
|
if (vt == null) return tt;
|
|
38504
|
-
je.scroll.insertAt(tt, vt,
|
|
38553
|
+
je.scroll.insertAt(tt, vt, Be.insert[vt]);
|
|
38505
38554
|
}
|
|
38506
38555
|
Qe += Je;
|
|
38507
38556
|
}
|
|
38508
38557
|
return Object.keys(nt).forEach(function(_t) {
|
|
38509
38558
|
je.scroll.formatAt(tt, Je, _t, nt[_t]);
|
|
38510
38559
|
}), tt + Je;
|
|
38511
|
-
}, 0), Fe.reduce(function(tt,
|
|
38512
|
-
return typeof
|
|
38560
|
+
}, 0), Fe.reduce(function(tt, Be) {
|
|
38561
|
+
return typeof Be.delete == "number" ? (je.scroll.deleteAt(tt, Be.delete), tt) : tt + (Be.retain || Be.insert.length || 1);
|
|
38513
38562
|
}, 0), this.scroll.batchEnd(), this.update(Fe);
|
|
38514
38563
|
}
|
|
38515
38564
|
}, {
|
|
@@ -38520,16 +38569,16 @@ function requireQuill() {
|
|
|
38520
38569
|
}, {
|
|
38521
38570
|
key: "formatLine",
|
|
38522
38571
|
value: function(Fe, je) {
|
|
38523
|
-
var
|
|
38572
|
+
var Ve = this, Qe = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {};
|
|
38524
38573
|
return this.scroll.update(), Object.keys(Qe).forEach(function(tt) {
|
|
38525
|
-
if (!(
|
|
38526
|
-
var
|
|
38527
|
-
|
|
38574
|
+
if (!(Ve.scroll.whitelist != null && !Ve.scroll.whitelist[tt])) {
|
|
38575
|
+
var Be = Ve.scroll.lines(Fe, Math.max(je, 1)), Je = je;
|
|
38576
|
+
Be.forEach(function(nt) {
|
|
38528
38577
|
var ft = nt.length();
|
|
38529
38578
|
if (!(nt instanceof me.default))
|
|
38530
38579
|
nt.format(tt, Qe[tt]);
|
|
38531
38580
|
else {
|
|
38532
|
-
var $t = Fe - nt.offset(
|
|
38581
|
+
var $t = Fe - nt.offset(Ve.scroll), St = nt.newlineIndex($t + Je) - $t + 1;
|
|
38533
38582
|
nt.formatAt($t, St, tt, Qe[tt]);
|
|
38534
38583
|
}
|
|
38535
38584
|
Je -= ft;
|
|
@@ -38540,9 +38589,9 @@ function requireQuill() {
|
|
|
38540
38589
|
}, {
|
|
38541
38590
|
key: "formatText",
|
|
38542
38591
|
value: function(Fe, je) {
|
|
38543
|
-
var
|
|
38592
|
+
var Ve = this, Qe = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {};
|
|
38544
38593
|
return Object.keys(Qe).forEach(function(tt) {
|
|
38545
|
-
|
|
38594
|
+
Ve.scroll.formatAt(Fe, je, tt, Qe[tt]);
|
|
38546
38595
|
}), this.update(new fe.default().retain(Fe).retain(je, (0, Ie.default)(Qe)));
|
|
38547
38596
|
}
|
|
38548
38597
|
}, {
|
|
@@ -38560,15 +38609,15 @@ function requireQuill() {
|
|
|
38560
38609
|
}, {
|
|
38561
38610
|
key: "getFormat",
|
|
38562
38611
|
value: function(Fe) {
|
|
38563
|
-
var je = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0,
|
|
38564
|
-
je === 0 ? this.scroll.path(Fe).forEach(function(
|
|
38565
|
-
var Je = de(
|
|
38566
|
-
nt instanceof Ce.default ?
|
|
38567
|
-
}) : (
|
|
38568
|
-
var tt = [
|
|
38569
|
-
if (
|
|
38570
|
-
for (var Je = (0, Ae.bubbleFormats)(
|
|
38571
|
-
var nt =
|
|
38612
|
+
var je = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0, Ve = [], Qe = [];
|
|
38613
|
+
je === 0 ? this.scroll.path(Fe).forEach(function(Be) {
|
|
38614
|
+
var Je = de(Be, 1), nt = Je[0];
|
|
38615
|
+
nt instanceof Ce.default ? Ve.push(nt) : nt instanceof ge.default.Leaf && Qe.push(nt);
|
|
38616
|
+
}) : (Ve = this.scroll.lines(Fe, je), Qe = this.scroll.descendants(ge.default.Leaf, Fe, je));
|
|
38617
|
+
var tt = [Ve, Qe].map(function(Be) {
|
|
38618
|
+
if (Be.length === 0) return {};
|
|
38619
|
+
for (var Je = (0, Ae.bubbleFormats)(Be.shift()); Object.keys(Je).length > 0; ) {
|
|
38620
|
+
var nt = Be.shift();
|
|
38572
38621
|
if (nt == null) return Je;
|
|
38573
38622
|
Je = Ye((0, Ae.bubbleFormats)(nt), Je);
|
|
38574
38623
|
}
|
|
@@ -38579,25 +38628,25 @@ function requireQuill() {
|
|
|
38579
38628
|
}, {
|
|
38580
38629
|
key: "getText",
|
|
38581
38630
|
value: function(Fe, je) {
|
|
38582
|
-
return this.getContents(Fe, je).filter(function(
|
|
38583
|
-
return typeof
|
|
38584
|
-
}).map(function(
|
|
38585
|
-
return
|
|
38631
|
+
return this.getContents(Fe, je).filter(function(Ve) {
|
|
38632
|
+
return typeof Ve.insert == "string";
|
|
38633
|
+
}).map(function(Ve) {
|
|
38634
|
+
return Ve.insert;
|
|
38586
38635
|
}).join("");
|
|
38587
38636
|
}
|
|
38588
38637
|
}, {
|
|
38589
38638
|
key: "insertEmbed",
|
|
38590
|
-
value: function(Fe, je,
|
|
38591
|
-
return this.scroll.insertAt(Fe, je,
|
|
38639
|
+
value: function(Fe, je, Ve) {
|
|
38640
|
+
return this.scroll.insertAt(Fe, je, Ve), this.update(new fe.default().retain(Fe).insert(Pe({}, je, Ve)));
|
|
38592
38641
|
}
|
|
38593
38642
|
}, {
|
|
38594
38643
|
key: "insertText",
|
|
38595
38644
|
value: function(Fe, je) {
|
|
38596
|
-
var
|
|
38645
|
+
var Ve = this, Qe = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {};
|
|
38597
38646
|
return je = je.replace(/\r\n/g, `
|
|
38598
38647
|
`).replace(/\r/g, `
|
|
38599
38648
|
`), this.scroll.insertAt(Fe, je), Object.keys(Qe).forEach(function(tt) {
|
|
38600
|
-
|
|
38649
|
+
Ve.scroll.formatAt(Fe, je.length, tt, Qe[tt]);
|
|
38601
38650
|
}), this.update(new fe.default().retain(Fe).insert(je, (0, Ie.default)(Qe)));
|
|
38602
38651
|
}
|
|
38603
38652
|
}, {
|
|
@@ -38611,23 +38660,23 @@ function requireQuill() {
|
|
|
38611
38660
|
}, {
|
|
38612
38661
|
key: "removeFormat",
|
|
38613
38662
|
value: function(Fe, je) {
|
|
38614
|
-
var
|
|
38615
|
-
|
|
38663
|
+
var Ve = this.getText(Fe, je), Qe = this.scroll.line(Fe + je), tt = de(Qe, 2), Be = tt[0], Je = tt[1], nt = 0, ft = new fe.default();
|
|
38664
|
+
Be != null && (Be instanceof me.default ? nt = Be.newlineIndex(Je) - Je + 1 : nt = Be.length() - Je, ft = Be.delta().slice(Je, Je + nt - 1).insert(`
|
|
38616
38665
|
`));
|
|
38617
|
-
var $t = this.getContents(Fe, je + nt), St = $t.diff(new fe.default().insert(
|
|
38666
|
+
var $t = this.getContents(Fe, je + nt), St = $t.diff(new fe.default().insert(Ve).concat(ft)), Pt = new fe.default().retain(Fe).concat(St);
|
|
38618
38667
|
return this.applyDelta(Pt);
|
|
38619
38668
|
}
|
|
38620
38669
|
}, {
|
|
38621
38670
|
key: "update",
|
|
38622
38671
|
value: function(Fe) {
|
|
38623
|
-
var je = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : [],
|
|
38672
|
+
var je = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : [], Ve = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : void 0, Qe = this.delta;
|
|
38624
38673
|
if (je.length === 1 && je[0].type === "characterData" && je[0].target.data.match(Ge) && ge.default.find(je[0].target)) {
|
|
38625
|
-
var tt = ge.default.find(je[0].target),
|
|
38674
|
+
var tt = ge.default.find(je[0].target), Be = (0, Ae.bubbleFormats)(tt), Je = tt.offset(this.scroll), nt = je[0].oldValue.replace(ye.default.CONTENTS, ""), ft = new fe.default().insert(nt), $t = new fe.default().insert(tt.value()), St = new fe.default().retain(Je).concat(ft.diff($t, Ve));
|
|
38626
38675
|
Fe = St.reduce(function(Pt, It) {
|
|
38627
|
-
return It.insert ? Pt.insert(It.insert,
|
|
38676
|
+
return It.insert ? Pt.insert(It.insert, Be) : Pt.push(It);
|
|
38628
38677
|
}, new fe.default()), this.delta = Qe.compose(Fe);
|
|
38629
38678
|
} else
|
|
38630
|
-
this.delta = this.getDelta(), (!Fe || !(0, Ue.default)(Qe.compose(Fe), this.delta)) && (Fe = Qe.diff(this.delta,
|
|
38679
|
+
this.delta = this.getDelta(), (!Fe || !(0, Ue.default)(Qe.compose(Fe), this.delta)) && (Fe = Qe.diff(this.delta, Ve));
|
|
38631
38680
|
return Fe;
|
|
38632
38681
|
}
|
|
38633
38682
|
}]), Xe;
|
|
@@ -38644,10 +38693,10 @@ function requireQuill() {
|
|
|
38644
38693
|
return delete je.image, Ke.insert({ image: Fe.attributes.image }, je);
|
|
38645
38694
|
}
|
|
38646
38695
|
if (Fe.attributes != null && (Fe.attributes.list === !0 || Fe.attributes.bullet === !0) && (Fe = (0, Ie.default)(Fe), Fe.attributes.list ? Fe.attributes.list = "ordered" : (Fe.attributes.list = "bullet", delete Fe.attributes.bullet)), typeof Fe.insert == "string") {
|
|
38647
|
-
var
|
|
38696
|
+
var Ve = Fe.insert.replace(/\r\n/g, `
|
|
38648
38697
|
`).replace(/\r/g, `
|
|
38649
38698
|
`);
|
|
38650
|
-
return Ke.insert(
|
|
38699
|
+
return Ke.insert(Ve, Fe.attributes);
|
|
38651
38700
|
}
|
|
38652
38701
|
return Ke.push(Fe);
|
|
38653
38702
|
}, new fe.default());
|
|
@@ -38801,17 +38850,17 @@ function requireQuill() {
|
|
|
38801
38850
|
var Fe = document.createRange();
|
|
38802
38851
|
if (qe > 0) {
|
|
38803
38852
|
Fe.setStart(He, bt);
|
|
38804
|
-
var je = this.scroll.leaf(Oe + qe),
|
|
38805
|
-
if (Ye =
|
|
38853
|
+
var je = this.scroll.leaf(Oe + qe), Ve = re(je, 2);
|
|
38854
|
+
if (Ye = Ve[0], bt = Ve[1], Ye == null) return null;
|
|
38806
38855
|
var Qe = Ye.position(bt, !0), tt = re(Qe, 2);
|
|
38807
38856
|
return He = tt[0], bt = tt[1], Fe.setEnd(He, bt), Fe.getBoundingClientRect();
|
|
38808
38857
|
} else {
|
|
38809
|
-
var
|
|
38810
|
-
return He instanceof Text ? (bt < He.data.length ? (Fe.setStart(He, bt), Fe.setEnd(He, bt + 1)) : (Fe.setStart(He, bt - 1), Fe.setEnd(He, bt),
|
|
38858
|
+
var Be = "left", Je = void 0;
|
|
38859
|
+
return He instanceof Text ? (bt < He.data.length ? (Fe.setStart(He, bt), Fe.setEnd(He, bt + 1)) : (Fe.setStart(He, bt - 1), Fe.setEnd(He, bt), Be = "right"), Je = Fe.getBoundingClientRect()) : (Je = Ye.domNode.getBoundingClientRect(), bt > 0 && (Be = "right")), {
|
|
38811
38860
|
bottom: Je.top + Je.height,
|
|
38812
38861
|
height: Je.height,
|
|
38813
|
-
left: Je[
|
|
38814
|
-
right: Je[
|
|
38862
|
+
left: Je[Be],
|
|
38863
|
+
right: Je[Be],
|
|
38815
38864
|
top: Je.top,
|
|
38816
38865
|
width: 0
|
|
38817
38866
|
};
|
|
@@ -38876,7 +38925,7 @@ function requireQuill() {
|
|
|
38876
38925
|
var qe = this, Pe = Oe.collapsed ? [Oe.index] : [Oe.index, Oe.index + Oe.length], He = [], Ge = this.scroll.length();
|
|
38877
38926
|
return Pe.forEach(function(Ze, Ye) {
|
|
38878
38927
|
Ze = Math.min(Ge - 1, Ze);
|
|
38879
|
-
var bt = void 0, Xe = qe.scroll.leaf(Ze), Ke = re(Xe, 2), Fe = Ke[0], je = Ke[1],
|
|
38928
|
+
var bt = void 0, Xe = qe.scroll.leaf(Ze), Ke = re(Xe, 2), Fe = Ke[0], je = Ke[1], Ve = Fe.position(je, Ye !== 0), Qe = re(Ve, 2);
|
|
38880
38929
|
bt = Qe[0], je = Qe[1], He.push(bt, je);
|
|
38881
38930
|
}), He.length < 2 && (He = He.concat(He)), He;
|
|
38882
38931
|
}
|
|
@@ -39417,8 +39466,8 @@ function requireQuill() {
|
|
|
39417
39466
|
we.push(ze), Se.push(Le);
|
|
39418
39467
|
}
|
|
39419
39468
|
re(ze, de) && ze.forEach(function(Ke, Fe) {
|
|
39420
|
-
var je = Ie(Fe, Ue - 1),
|
|
39421
|
-
Le.set(je,
|
|
39469
|
+
var je = Ie(Fe, Ue - 1), Ve = Ie(Ke, Ue - 1);
|
|
39470
|
+
Le.set(je, Ve);
|
|
39422
39471
|
}), re(ze, ce) && ze.forEach(function(Ke) {
|
|
39423
39472
|
var Fe = Ie(Ke, Ue - 1);
|
|
39424
39473
|
Le.add(Fe);
|
|
@@ -39585,8 +39634,8 @@ function requireQuill() {
|
|
|
39585
39634
|
return;
|
|
39586
39635
|
}
|
|
39587
39636
|
} else if (Fe instanceof ye.default) {
|
|
39588
|
-
var
|
|
39589
|
-
|
|
39637
|
+
var Ve = Fe.newlineIndex(0);
|
|
39638
|
+
Ve > -1 && Fe.split(Ve + 1);
|
|
39590
39639
|
}
|
|
39591
39640
|
var Qe = Fe.children.head instanceof me.default ? null : Fe.children.head;
|
|
39592
39641
|
Ye.moveChildren(Fe, Qe), Ye.remove();
|
|
@@ -39646,8 +39695,8 @@ function requireQuill() {
|
|
|
39646
39695
|
value: function() {
|
|
39647
39696
|
var Pe = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 0, He = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : Number.MAX_VALUE, Ge = function Ze(Ye, bt, Xe) {
|
|
39648
39697
|
var Ke = [], Fe = Xe;
|
|
39649
|
-
return Ye.children.forEachAt(bt, Xe, function(je,
|
|
39650
|
-
ze(je) ? Ke.push(je) : je instanceof fe.default.Container && (Ke = Ke.concat(Ze(je,
|
|
39698
|
+
return Ye.children.forEachAt(bt, Xe, function(je, Ve, Qe) {
|
|
39699
|
+
ze(je) ? Ke.push(je) : je instanceof fe.default.Container && (Ke = Ke.concat(Ze(je, Ve, Fe))), Fe -= Qe;
|
|
39651
39700
|
}), Ke;
|
|
39652
39701
|
};
|
|
39653
39702
|
return Ge(this, Pe, He);
|
|
@@ -39681,12 +39730,12 @@ function requireQuill() {
|
|
|
39681
39730
|
Object.defineProperty(oe, "__esModule", {
|
|
39682
39731
|
value: !0
|
|
39683
39732
|
}), oe.SHORTKEY = oe.default = void 0;
|
|
39684
|
-
var re = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(
|
|
39685
|
-
return typeof
|
|
39686
|
-
} : function(
|
|
39687
|
-
return
|
|
39733
|
+
var re = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(Be) {
|
|
39734
|
+
return typeof Be;
|
|
39735
|
+
} : function(Be) {
|
|
39736
|
+
return Be && typeof Symbol == "function" && Be.constructor === Symbol && Be !== Symbol.prototype ? "symbol" : typeof Be;
|
|
39688
39737
|
}, de = /* @__PURE__ */ (function() {
|
|
39689
|
-
function
|
|
39738
|
+
function Be(Je, nt) {
|
|
39690
39739
|
var ft = [], $t = !0, St = !1, Pt = void 0;
|
|
39691
39740
|
try {
|
|
39692
39741
|
for (var It = Je[Symbol.iterator](), Ht; !($t = (Ht = It.next()).done) && (ft.push(Ht.value), !(nt && ft.length === nt)); $t = !0)
|
|
@@ -39706,42 +39755,42 @@ function requireQuill() {
|
|
|
39706
39755
|
if (Array.isArray(Je))
|
|
39707
39756
|
return Je;
|
|
39708
39757
|
if (Symbol.iterator in Object(Je))
|
|
39709
|
-
return
|
|
39758
|
+
return Be(Je, nt);
|
|
39710
39759
|
throw new TypeError("Invalid attempt to destructure non-iterable instance");
|
|
39711
39760
|
};
|
|
39712
39761
|
})(), ce = /* @__PURE__ */ (function() {
|
|
39713
|
-
function
|
|
39762
|
+
function Be(Je, nt) {
|
|
39714
39763
|
for (var ft = 0; ft < nt.length; ft++) {
|
|
39715
39764
|
var $t = nt[ft];
|
|
39716
39765
|
$t.enumerable = $t.enumerable || !1, $t.configurable = !0, "value" in $t && ($t.writable = !0), Object.defineProperty(Je, $t.key, $t);
|
|
39717
39766
|
}
|
|
39718
39767
|
}
|
|
39719
39768
|
return function(Je, nt, ft) {
|
|
39720
|
-
return nt &&
|
|
39769
|
+
return nt && Be(Je.prototype, nt), ft && Be(Je, ft), Je;
|
|
39721
39770
|
};
|
|
39722
39771
|
})(), ue = ne(21), fe = Le(ue), pe = ne(11), be = Le(pe), he = ne(3), ge = Le(he), ve = ne(2), me = Le(ve), _e = ne(20), ye = Le(_e), Ae = ne(0), Ce = Le(Ae), we = ne(5), Se = Le(we), Me = ne(10), Ie = Le(Me), ze = ne(9), Ue = Le(ze);
|
|
39723
|
-
function Le(
|
|
39724
|
-
return
|
|
39772
|
+
function Le(Be) {
|
|
39773
|
+
return Be && Be.__esModule ? Be : { default: Be };
|
|
39725
39774
|
}
|
|
39726
|
-
function Oe(
|
|
39727
|
-
return Je in
|
|
39775
|
+
function Oe(Be, Je, nt) {
|
|
39776
|
+
return Je in Be ? Object.defineProperty(Be, Je, { value: nt, enumerable: !0, configurable: !0, writable: !0 }) : Be[Je] = nt, Be;
|
|
39728
39777
|
}
|
|
39729
|
-
function qe(
|
|
39730
|
-
if (!(
|
|
39778
|
+
function qe(Be, Je) {
|
|
39779
|
+
if (!(Be instanceof Je))
|
|
39731
39780
|
throw new TypeError("Cannot call a class as a function");
|
|
39732
39781
|
}
|
|
39733
|
-
function Pe(
|
|
39734
|
-
if (!
|
|
39782
|
+
function Pe(Be, Je) {
|
|
39783
|
+
if (!Be)
|
|
39735
39784
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
39736
|
-
return Je && (typeof Je == "object" || typeof Je == "function") ? Je :
|
|
39785
|
+
return Je && (typeof Je == "object" || typeof Je == "function") ? Je : Be;
|
|
39737
39786
|
}
|
|
39738
|
-
function He(
|
|
39787
|
+
function He(Be, Je) {
|
|
39739
39788
|
if (typeof Je != "function" && Je !== null)
|
|
39740
39789
|
throw new TypeError("Super expression must either be null or a function, not " + typeof Je);
|
|
39741
|
-
|
|
39790
|
+
Be.prototype = Object.create(Je && Je.prototype, { constructor: { value: Be, enumerable: !1, writable: !0, configurable: !0 } }), Je && (Object.setPrototypeOf ? Object.setPrototypeOf(Be, Je) : Be.__proto__ = Je);
|
|
39742
39791
|
}
|
|
39743
|
-
var Ge = (0, Ie.default)("quill:keyboard"), Ze = /Mac/i.test(navigator.platform) ? "metaKey" : "ctrlKey", Ye = (function(
|
|
39744
|
-
He(Je,
|
|
39792
|
+
var Ge = (0, Ie.default)("quill:keyboard"), Ze = /Mac/i.test(navigator.platform) ? "metaKey" : "ctrlKey", Ye = (function(Be) {
|
|
39793
|
+
He(Je, Be), ce(Je, null, [{
|
|
39745
39794
|
key: "match",
|
|
39746
39795
|
value: function(ft, $t) {
|
|
39747
39796
|
return $t = tt($t), ["altKey", "ctrlKey", "metaKey", "shiftKey"].some(function(St) {
|
|
@@ -39852,8 +39901,8 @@ function requireQuill() {
|
|
|
39852
39901
|
nt.format.indent != null ? this.quill.format("indent", "-1", Se.default.sources.USER) : nt.format.list != null && this.quill.format("list", !1, Se.default.sources.USER);
|
|
39853
39902
|
}
|
|
39854
39903
|
},
|
|
39855
|
-
"indent code-block":
|
|
39856
|
-
"outdent code-block":
|
|
39904
|
+
"indent code-block": Ve(!0),
|
|
39905
|
+
"outdent code-block": Ve(!1),
|
|
39857
39906
|
"remove tab": {
|
|
39858
39907
|
key: Ye.keys.TAB,
|
|
39859
39908
|
shiftKey: !0,
|
|
@@ -39947,70 +39996,70 @@ function requireQuill() {
|
|
|
39947
39996
|
"embed right shift": bt(Ye.keys.RIGHT, !0)
|
|
39948
39997
|
}
|
|
39949
39998
|
};
|
|
39950
|
-
function bt(
|
|
39951
|
-
var nt, ft =
|
|
39999
|
+
function bt(Be, Je) {
|
|
40000
|
+
var nt, ft = Be === Ye.keys.LEFT ? "prefix" : "suffix";
|
|
39952
40001
|
return nt = {
|
|
39953
|
-
key:
|
|
40002
|
+
key: Be,
|
|
39954
40003
|
shiftKey: Je,
|
|
39955
40004
|
altKey: null
|
|
39956
40005
|
}, Oe(nt, ft, /^$/), Oe(nt, "handler", function(St) {
|
|
39957
40006
|
var Pt = St.index;
|
|
39958
|
-
|
|
40007
|
+
Be === Ye.keys.RIGHT && (Pt += St.length + 1);
|
|
39959
40008
|
var It = this.quill.getLeaf(Pt), Ht = de(It, 1), jt = Ht[0];
|
|
39960
|
-
return jt instanceof Ce.default.Embed ? (
|
|
40009
|
+
return jt instanceof Ce.default.Embed ? (Be === Ye.keys.LEFT ? Je ? this.quill.setSelection(St.index - 1, St.length + 1, Se.default.sources.USER) : this.quill.setSelection(St.index - 1, Se.default.sources.USER) : Je ? this.quill.setSelection(St.index, St.length + 1, Se.default.sources.USER) : this.quill.setSelection(St.index + St.length + 1, Se.default.sources.USER), !1) : !0;
|
|
39961
40010
|
}), nt;
|
|
39962
40011
|
}
|
|
39963
|
-
function Xe(
|
|
39964
|
-
if (!(
|
|
39965
|
-
var nt = this.quill.getLine(
|
|
40012
|
+
function Xe(Be, Je) {
|
|
40013
|
+
if (!(Be.index === 0 || this.quill.getLength() <= 1)) {
|
|
40014
|
+
var nt = this.quill.getLine(Be.index), ft = de(nt, 1), $t = ft[0], St = {};
|
|
39966
40015
|
if (Je.offset === 0) {
|
|
39967
|
-
var Pt = this.quill.getLine(
|
|
40016
|
+
var Pt = this.quill.getLine(Be.index - 1), It = de(Pt, 1), Ht = It[0];
|
|
39968
40017
|
if (Ht != null && Ht.length() > 1) {
|
|
39969
|
-
var jt = $t.formats(), ns = this.quill.getFormat(
|
|
40018
|
+
var jt = $t.formats(), ns = this.quill.getFormat(Be.index - 1, 1);
|
|
39970
40019
|
St = ye.default.attributes.diff(jt, ns) || {};
|
|
39971
40020
|
}
|
|
39972
40021
|
}
|
|
39973
40022
|
var es = /[\uD800-\uDBFF][\uDC00-\uDFFF]$/.test(Je.prefix) ? 2 : 1;
|
|
39974
|
-
this.quill.deleteText(
|
|
40023
|
+
this.quill.deleteText(Be.index - es, es, Se.default.sources.USER), Object.keys(St).length > 0 && this.quill.formatLine(Be.index - es, es, St, Se.default.sources.USER), this.quill.focus();
|
|
39975
40024
|
}
|
|
39976
40025
|
}
|
|
39977
|
-
function Ke(
|
|
40026
|
+
function Ke(Be, Je) {
|
|
39978
40027
|
var nt = /^[\uD800-\uDBFF][\uDC00-\uDFFF]/.test(Je.suffix) ? 2 : 1;
|
|
39979
|
-
if (!(
|
|
39980
|
-
var ft = {}, $t = 0, St = this.quill.getLine(
|
|
40028
|
+
if (!(Be.index >= this.quill.getLength() - nt)) {
|
|
40029
|
+
var ft = {}, $t = 0, St = this.quill.getLine(Be.index), Pt = de(St, 1), It = Pt[0];
|
|
39981
40030
|
if (Je.offset >= It.length() - 1) {
|
|
39982
|
-
var Ht = this.quill.getLine(
|
|
40031
|
+
var Ht = this.quill.getLine(Be.index + 1), jt = de(Ht, 1), ns = jt[0];
|
|
39983
40032
|
if (ns) {
|
|
39984
|
-
var es = It.formats(), vt = this.quill.getFormat(
|
|
40033
|
+
var es = It.formats(), vt = this.quill.getFormat(Be.index, 1);
|
|
39985
40034
|
ft = ye.default.attributes.diff(es, vt) || {}, $t = ns.length();
|
|
39986
40035
|
}
|
|
39987
40036
|
}
|
|
39988
|
-
this.quill.deleteText(
|
|
40037
|
+
this.quill.deleteText(Be.index, nt, Se.default.sources.USER), Object.keys(ft).length > 0 && this.quill.formatLine(Be.index + $t - 1, nt, ft, Se.default.sources.USER);
|
|
39989
40038
|
}
|
|
39990
40039
|
}
|
|
39991
|
-
function Fe(
|
|
39992
|
-
var Je = this.quill.getLines(
|
|
40040
|
+
function Fe(Be) {
|
|
40041
|
+
var Je = this.quill.getLines(Be), nt = {};
|
|
39993
40042
|
if (Je.length > 1) {
|
|
39994
40043
|
var ft = Je[0].formats(), $t = Je[Je.length - 1].formats();
|
|
39995
40044
|
nt = ye.default.attributes.diff($t, ft) || {};
|
|
39996
40045
|
}
|
|
39997
|
-
this.quill.deleteText(
|
|
40046
|
+
this.quill.deleteText(Be, Se.default.sources.USER), Object.keys(nt).length > 0 && this.quill.formatLine(Be.index, 1, nt, Se.default.sources.USER), this.quill.setSelection(Be.index, Se.default.sources.SILENT), this.quill.focus();
|
|
39998
40047
|
}
|
|
39999
|
-
function je(
|
|
40048
|
+
function je(Be, Je) {
|
|
40000
40049
|
var nt = this;
|
|
40001
|
-
|
|
40050
|
+
Be.length > 0 && this.quill.scroll.deleteAt(Be.index, Be.length);
|
|
40002
40051
|
var ft = Object.keys(Je.format).reduce(function($t, St) {
|
|
40003
40052
|
return Ce.default.query(St, Ce.default.Scope.BLOCK) && !Array.isArray(Je.format[St]) && ($t[St] = Je.format[St]), $t;
|
|
40004
40053
|
}, {});
|
|
40005
|
-
this.quill.insertText(
|
|
40006
|
-
`, ft, Se.default.sources.USER), this.quill.setSelection(
|
|
40054
|
+
this.quill.insertText(Be.index, `
|
|
40055
|
+
`, ft, Se.default.sources.USER), this.quill.setSelection(Be.index + 1, Se.default.sources.SILENT), this.quill.focus(), Object.keys(Je.format).forEach(function($t) {
|
|
40007
40056
|
ft[$t] == null && (Array.isArray(Je.format[$t]) || $t !== "link" && nt.quill.format($t, Je.format[$t], Se.default.sources.USER));
|
|
40008
40057
|
});
|
|
40009
40058
|
}
|
|
40010
|
-
function Be
|
|
40059
|
+
function Ve(Be) {
|
|
40011
40060
|
return {
|
|
40012
40061
|
key: Ye.keys.TAB,
|
|
40013
|
-
shiftKey: !
|
|
40062
|
+
shiftKey: !Be,
|
|
40014
40063
|
format: { "code-block": !0 },
|
|
40015
40064
|
handler: function(nt) {
|
|
40016
40065
|
var ft = Ce.default.query("code-block"), $t = nt.index, St = nt.length, Pt = this.quill.scroll.descendant(ft, $t), It = de(Pt, 2), Ht = It[0], jt = It[1];
|
|
@@ -40018,32 +40067,32 @@ function requireQuill() {
|
|
|
40018
40067
|
var ns = this.quill.getIndex(Ht), es = Ht.newlineIndex(jt, !0) + 1, vt = Ht.newlineIndex(ns + jt + St), _t = Ht.domNode.textContent.slice(es, vt).split(`
|
|
40019
40068
|
`);
|
|
40020
40069
|
jt = 0, _t.forEach(function(At, Et) {
|
|
40021
|
-
|
|
40070
|
+
Be ? (Ht.insertAt(es + jt, ft.TAB), jt += ft.TAB.length, Et === 0 ? $t += ft.TAB.length : St += ft.TAB.length) : At.startsWith(ft.TAB) && (Ht.deleteAt(es + jt, ft.TAB.length), jt -= ft.TAB.length, Et === 0 ? $t -= ft.TAB.length : St -= ft.TAB.length), jt += At.length + 1;
|
|
40022
40071
|
}), this.quill.update(Se.default.sources.USER), this.quill.setSelection($t, St, Se.default.sources.SILENT);
|
|
40023
40072
|
}
|
|
40024
40073
|
}
|
|
40025
40074
|
};
|
|
40026
40075
|
}
|
|
40027
|
-
function Qe(
|
|
40076
|
+
function Qe(Be) {
|
|
40028
40077
|
return {
|
|
40029
|
-
key:
|
|
40078
|
+
key: Be[0].toUpperCase(),
|
|
40030
40079
|
shortKey: !0,
|
|
40031
40080
|
handler: function(nt, ft) {
|
|
40032
|
-
this.quill.format(
|
|
40081
|
+
this.quill.format(Be, !ft.format[Be], Se.default.sources.USER);
|
|
40033
40082
|
}
|
|
40034
40083
|
};
|
|
40035
40084
|
}
|
|
40036
|
-
function tt(
|
|
40037
|
-
if (typeof
|
|
40038
|
-
return tt({ key:
|
|
40039
|
-
if ((typeof
|
|
40040
|
-
if (Ye.keys[
|
|
40041
|
-
|
|
40042
|
-
else if (
|
|
40043
|
-
|
|
40085
|
+
function tt(Be) {
|
|
40086
|
+
if (typeof Be == "string" || typeof Be == "number")
|
|
40087
|
+
return tt({ key: Be });
|
|
40088
|
+
if ((typeof Be > "u" ? "undefined" : re(Be)) === "object" && (Be = (0, fe.default)(Be, !1)), typeof Be.key == "string")
|
|
40089
|
+
if (Ye.keys[Be.key.toUpperCase()] != null)
|
|
40090
|
+
Be.key = Ye.keys[Be.key.toUpperCase()];
|
|
40091
|
+
else if (Be.key.length === 1)
|
|
40092
|
+
Be.key = Be.key.toUpperCase().charCodeAt(0);
|
|
40044
40093
|
else
|
|
40045
40094
|
return null;
|
|
40046
|
-
return
|
|
40095
|
+
return Be.shortKey && (Be[Ze] = Be.shortKey, delete Be.shortKey), Be;
|
|
40047
40096
|
}
|
|
40048
40097
|
oe.default = Ye, oe.SHORTKEY = Ze;
|
|
40049
40098
|
}),
|
|
@@ -40904,8 +40953,8 @@ function requireQuill() {
|
|
|
40904
40953
|
throw new TypeError("unexpected type: " + qe.type);
|
|
40905
40954
|
return Oe.setStart(Ze, 0), Oe.setEnd(Ye, Ye.length), { range: Oe, mode: "all" };
|
|
40906
40955
|
}
|
|
40907
|
-
var Ke = Ge(), Fe = void 0, je = void 0,
|
|
40908
|
-
return bt ? (qe.extend(Ze, 0), Fe = Ge() + we(Ze), qe.extend(Ye,
|
|
40956
|
+
var Ke = Ge(), Fe = void 0, je = void 0, Ve = Ye.length - Se(Ye);
|
|
40957
|
+
return bt ? (qe.extend(Ze, 0), Fe = Ge() + we(Ze), qe.extend(Ye, Ve), je = Ve - (Ge() - Ke), qe.extend(Ye, je)) : (qe.extend(Ye, Ve), je = Ve - Ge(), qe.extend(Ze, 0), Fe = Ge() - Ke + we(Ze), qe.extend(Ze, Fe)), Oe.setStart(Ze, Fe), Oe.setEnd(Ye, je), {
|
|
40909
40958
|
mode: bt ? "right" : "left",
|
|
40910
40959
|
range: Oe
|
|
40911
40960
|
};
|
|
@@ -41370,92 +41419,92 @@ function requireQuill() {
|
|
|
41370
41419
|
value: !0
|
|
41371
41420
|
}), oe.default = oe.BaseTooltip = void 0;
|
|
41372
41421
|
var re = /* @__PURE__ */ (function() {
|
|
41373
|
-
function je(
|
|
41422
|
+
function je(Ve, Qe) {
|
|
41374
41423
|
for (var tt = 0; tt < Qe.length; tt++) {
|
|
41375
|
-
var
|
|
41376
|
-
|
|
41424
|
+
var Be = Qe[tt];
|
|
41425
|
+
Be.enumerable = Be.enumerable || !1, Be.configurable = !0, "value" in Be && (Be.writable = !0), Object.defineProperty(Ve, Be.key, Be);
|
|
41377
41426
|
}
|
|
41378
41427
|
}
|
|
41379
|
-
return function(
|
|
41380
|
-
return Qe && je(
|
|
41428
|
+
return function(Ve, Qe, tt) {
|
|
41429
|
+
return Qe && je(Ve.prototype, Qe), tt && je(Ve, tt), Ve;
|
|
41381
41430
|
};
|
|
41382
|
-
})(), de = function je(
|
|
41383
|
-
|
|
41384
|
-
var
|
|
41385
|
-
if (
|
|
41386
|
-
var Je = Object.getPrototypeOf(
|
|
41431
|
+
})(), de = function je(Ve, Qe, tt) {
|
|
41432
|
+
Ve === null && (Ve = Function.prototype);
|
|
41433
|
+
var Be = Object.getOwnPropertyDescriptor(Ve, Qe);
|
|
41434
|
+
if (Be === void 0) {
|
|
41435
|
+
var Je = Object.getPrototypeOf(Ve);
|
|
41387
41436
|
return Je === null ? void 0 : je(Je, Qe, tt);
|
|
41388
41437
|
} else {
|
|
41389
|
-
if ("value" in
|
|
41390
|
-
return
|
|
41391
|
-
var nt =
|
|
41438
|
+
if ("value" in Be)
|
|
41439
|
+
return Be.value;
|
|
41440
|
+
var nt = Be.get;
|
|
41392
41441
|
return nt === void 0 ? void 0 : nt.call(tt);
|
|
41393
41442
|
}
|
|
41394
41443
|
}, ce = ne(3), ue = Ue(ce), fe = ne(2), pe = Ue(fe), be = ne(8), he = Ue(be), ge = ne(23), ve = Ue(ge), me = ne(35), _e = Ue(me), ye = ne(60), Ae = Ue(ye), Ce = ne(61), we = Ue(Ce), Se = ne(28), Me = Ue(Se), Ie = ne(62), ze = Ue(Ie);
|
|
41395
41444
|
function Ue(je) {
|
|
41396
41445
|
return je && je.__esModule ? je : { default: je };
|
|
41397
41446
|
}
|
|
41398
|
-
function Le(je,
|
|
41399
|
-
if (!(je instanceof
|
|
41447
|
+
function Le(je, Ve) {
|
|
41448
|
+
if (!(je instanceof Ve))
|
|
41400
41449
|
throw new TypeError("Cannot call a class as a function");
|
|
41401
41450
|
}
|
|
41402
|
-
function Oe(je,
|
|
41451
|
+
function Oe(je, Ve) {
|
|
41403
41452
|
if (!je)
|
|
41404
41453
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
41405
|
-
return
|
|
41454
|
+
return Ve && (typeof Ve == "object" || typeof Ve == "function") ? Ve : je;
|
|
41406
41455
|
}
|
|
41407
|
-
function qe(je,
|
|
41408
|
-
if (typeof
|
|
41409
|
-
throw new TypeError("Super expression must either be null or a function, not " + typeof
|
|
41410
|
-
je.prototype = Object.create(
|
|
41456
|
+
function qe(je, Ve) {
|
|
41457
|
+
if (typeof Ve != "function" && Ve !== null)
|
|
41458
|
+
throw new TypeError("Super expression must either be null or a function, not " + typeof Ve);
|
|
41459
|
+
je.prototype = Object.create(Ve && Ve.prototype, { constructor: { value: je, enumerable: !1, writable: !0, configurable: !0 } }), Ve && (Object.setPrototypeOf ? Object.setPrototypeOf(je, Ve) : je.__proto__ = Ve);
|
|
41411
41460
|
}
|
|
41412
41461
|
var Pe = [!1, "center", "right", "justify"], He = ["#000000", "#e60000", "#ff9900", "#ffff00", "#008a00", "#0066cc", "#9933ff", "#ffffff", "#facccc", "#ffebcc", "#ffffcc", "#cce8cc", "#cce0f5", "#ebd6ff", "#bbbbbb", "#f06666", "#ffc266", "#ffff66", "#66b966", "#66a3e0", "#c285ff", "#888888", "#a10000", "#b26b00", "#b2b200", "#006100", "#0047b2", "#6b24b2", "#444444", "#5c0000", "#663d00", "#666600", "#003700", "#002966", "#3d1466"], Ge = [!1, "serif", "monospace"], Ze = ["1", "2", "3", !1], Ye = ["petita", !1, "gran", "enorme"], bt = (function(je) {
|
|
41413
|
-
qe(
|
|
41414
|
-
function
|
|
41415
|
-
Le(this,
|
|
41416
|
-
var
|
|
41462
|
+
qe(Ve, je);
|
|
41463
|
+
function Ve(Qe, tt) {
|
|
41464
|
+
Le(this, Ve);
|
|
41465
|
+
var Be = Oe(this, (Ve.__proto__ || Object.getPrototypeOf(Ve)).call(this, Qe, tt)), Je = function nt(ft) {
|
|
41417
41466
|
if (!document.body.contains(Qe.root))
|
|
41418
41467
|
return document.body.removeEventListener("click", nt);
|
|
41419
|
-
|
|
41468
|
+
Be.tooltip != null && !Be.tooltip.root.contains(ft.target) && document.activeElement !== Be.tooltip.textbox && !Be.quill.hasFocus() && Be.tooltip.hide(), Be.pickers != null && Be.pickers.forEach(function($t) {
|
|
41420
41469
|
$t.container.contains(ft.target) || $t.close();
|
|
41421
41470
|
});
|
|
41422
41471
|
};
|
|
41423
|
-
return Qe.emitter.listenDOM("click", document.body, Je),
|
|
41472
|
+
return Qe.emitter.listenDOM("click", document.body, Je), Be;
|
|
41424
41473
|
}
|
|
41425
|
-
return re(
|
|
41474
|
+
return re(Ve, [{
|
|
41426
41475
|
key: "addModule",
|
|
41427
41476
|
value: function(tt) {
|
|
41428
|
-
var
|
|
41429
|
-
return tt === "toolbar" && this.extendToolbar(
|
|
41477
|
+
var Be = de(Ve.prototype.__proto__ || Object.getPrototypeOf(Ve.prototype), "addModule", this).call(this, tt);
|
|
41478
|
+
return tt === "toolbar" && this.extendToolbar(Be), Be;
|
|
41430
41479
|
}
|
|
41431
41480
|
}, {
|
|
41432
41481
|
key: "buildButtons",
|
|
41433
|
-
value: function(tt,
|
|
41482
|
+
value: function(tt, Be) {
|
|
41434
41483
|
tt.forEach(function(Je) {
|
|
41435
41484
|
var nt = Je.getAttribute("class") || "";
|
|
41436
41485
|
nt.split(/\s+/).forEach(function(ft) {
|
|
41437
|
-
if (ft.startsWith("ql-") && (ft = ft.slice(3),
|
|
41486
|
+
if (ft.startsWith("ql-") && (ft = ft.slice(3), Be[ft] != null))
|
|
41438
41487
|
if (ft === "direction")
|
|
41439
|
-
Je.innerHTML =
|
|
41440
|
-
else if (typeof
|
|
41441
|
-
Je.innerHTML =
|
|
41488
|
+
Je.innerHTML = Be[ft][""] + Be[ft].rtl;
|
|
41489
|
+
else if (typeof Be[ft] == "string")
|
|
41490
|
+
Je.innerHTML = Be[ft];
|
|
41442
41491
|
else {
|
|
41443
41492
|
var $t = Je.value || "";
|
|
41444
|
-
$t != null &&
|
|
41493
|
+
$t != null && Be[ft][$t] && (Je.innerHTML = Be[ft][$t]);
|
|
41445
41494
|
}
|
|
41446
41495
|
});
|
|
41447
41496
|
});
|
|
41448
41497
|
}
|
|
41449
41498
|
}, {
|
|
41450
41499
|
key: "buildPickers",
|
|
41451
|
-
value: function(tt,
|
|
41500
|
+
value: function(tt, Be) {
|
|
41452
41501
|
var Je = this;
|
|
41453
41502
|
this.pickers = tt.map(function(ft) {
|
|
41454
41503
|
if (ft.classList.contains("ql-align"))
|
|
41455
|
-
return ft.querySelector("option") == null && Fe(ft, Pe), new we.default(ft,
|
|
41504
|
+
return ft.querySelector("option") == null && Fe(ft, Pe), new we.default(ft, Be.align);
|
|
41456
41505
|
if (ft.classList.contains("ql-background") || ft.classList.contains("ql-color")) {
|
|
41457
41506
|
var $t = ft.classList.contains("ql-background") ? "background" : "color";
|
|
41458
|
-
return ft.querySelector("option") == null && Fe(ft, He, $t === "background" ? "#ffffff" : "#000000"), new Ae.default(ft,
|
|
41507
|
+
return ft.querySelector("option") == null && Fe(ft, He, $t === "background" ? "#ffffff" : "#000000"), new Ae.default(ft, Be[$t]);
|
|
41459
41508
|
} else
|
|
41460
41509
|
return ft.querySelector("option") == null && (ft.classList.contains("ql-font") ? Fe(ft, Ge) : ft.classList.contains("ql-header") ? Fe(ft, Ze) : ft.classList.contains("ql-size") && Fe(ft, Ye)), new Me.default(ft);
|
|
41461
41510
|
});
|
|
@@ -41466,7 +41515,7 @@ function requireQuill() {
|
|
|
41466
41515
|
};
|
|
41467
41516
|
this.quill.on(he.default.events.EDITOR_CHANGE, nt);
|
|
41468
41517
|
}
|
|
41469
|
-
}]),
|
|
41518
|
+
}]), Ve;
|
|
41470
41519
|
})(_e.default);
|
|
41471
41520
|
bt.DEFAULTS = (0, ue.default)(!0, {}, _e.default.DEFAULTS, {
|
|
41472
41521
|
modules: {
|
|
@@ -41476,13 +41525,13 @@ function requireQuill() {
|
|
|
41476
41525
|
this.quill.theme.tooltip.edit("formula");
|
|
41477
41526
|
},
|
|
41478
41527
|
image: function() {
|
|
41479
|
-
var
|
|
41528
|
+
var Ve = this, Qe = this.container.querySelector("input.ql-image[type=file]");
|
|
41480
41529
|
Qe == null && (Qe = document.createElement("input"), Qe.setAttribute("type", "file"), Qe.setAttribute("accept", "image/png, image/gif, image/jpeg, image/bmp, image/x-icon"), Qe.classList.add("ql-image"), Qe.addEventListener("change", function() {
|
|
41481
41530
|
if (Qe.files != null && Qe.files[0] != null) {
|
|
41482
41531
|
var tt = new FileReader();
|
|
41483
|
-
tt.onload = function(
|
|
41484
|
-
var Je =
|
|
41485
|
-
|
|
41532
|
+
tt.onload = function(Be) {
|
|
41533
|
+
var Je = Ve.quill.getSelection(!0);
|
|
41534
|
+
Ve.quill.updateContents(new pe.default().retain(Je.index).delete(Je.length).insert({ image: Be.target.result }), he.default.sources.USER), Ve.quill.setSelection(Je.index + 1, he.default.sources.SILENT), Qe.value = "";
|
|
41486
41535
|
}, tt.readAsDataURL(Qe.files[0]);
|
|
41487
41536
|
}
|
|
41488
41537
|
}), this.container.appendChild(Qe)), Qe.click();
|
|
@@ -41495,18 +41544,18 @@ function requireQuill() {
|
|
|
41495
41544
|
}
|
|
41496
41545
|
});
|
|
41497
41546
|
var Xe = (function(je) {
|
|
41498
|
-
qe(
|
|
41499
|
-
function
|
|
41500
|
-
Le(this,
|
|
41501
|
-
var
|
|
41502
|
-
return
|
|
41547
|
+
qe(Ve, je);
|
|
41548
|
+
function Ve(Qe, tt) {
|
|
41549
|
+
Le(this, Ve);
|
|
41550
|
+
var Be = Oe(this, (Ve.__proto__ || Object.getPrototypeOf(Ve)).call(this, Qe, tt));
|
|
41551
|
+
return Be.textbox = Be.root.querySelector('input[type="text"]'), Be.listen(), Be;
|
|
41503
41552
|
}
|
|
41504
|
-
return re(
|
|
41553
|
+
return re(Ve, [{
|
|
41505
41554
|
key: "listen",
|
|
41506
41555
|
value: function() {
|
|
41507
41556
|
var tt = this;
|
|
41508
|
-
this.textbox.addEventListener("keydown", function(
|
|
41509
|
-
ve.default.match(
|
|
41557
|
+
this.textbox.addEventListener("keydown", function(Be) {
|
|
41558
|
+
ve.default.match(Be, "enter") ? (tt.save(), Be.preventDefault()) : ve.default.match(Be, "escape") && (tt.cancel(), Be.preventDefault());
|
|
41510
41559
|
});
|
|
41511
41560
|
}
|
|
41512
41561
|
}, {
|
|
@@ -41517,8 +41566,8 @@ function requireQuill() {
|
|
|
41517
41566
|
}, {
|
|
41518
41567
|
key: "edit",
|
|
41519
41568
|
value: function() {
|
|
41520
|
-
var tt = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : "link",
|
|
41521
|
-
this.root.classList.remove("ql-hidden"), this.root.classList.add("ql-editing"),
|
|
41569
|
+
var tt = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : "link", Be = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : null;
|
|
41570
|
+
this.root.classList.remove("ql-hidden"), this.root.classList.add("ql-editing"), Be != null ? this.textbox.value = Be : tt !== this.root.getAttribute("data-mode") && (this.textbox.value = ""), this.position(this.quill.getBounds(this.quill.selection.savedRange)), this.textbox.select(), this.textbox.setAttribute("placeholder", this.textbox.getAttribute("data-" + tt) || ""), this.root.setAttribute("data-mode", tt);
|
|
41522
41571
|
}
|
|
41523
41572
|
}, {
|
|
41524
41573
|
key: "restoreFocus",
|
|
@@ -41532,8 +41581,8 @@ function requireQuill() {
|
|
|
41532
41581
|
var tt = this.textbox.value;
|
|
41533
41582
|
switch (this.root.getAttribute("data-mode")) {
|
|
41534
41583
|
case "link": {
|
|
41535
|
-
var
|
|
41536
|
-
this.linkRange ? (this.quill.formatText(this.linkRange, "link", tt, he.default.sources.USER), delete this.linkRange) : (this.restoreFocus(), this.quill.format("link", tt, he.default.sources.USER)), this.quill.root.scrollTop =
|
|
41584
|
+
var Be = this.quill.root.scrollTop;
|
|
41585
|
+
this.linkRange ? (this.quill.formatText(this.linkRange, "link", tt, he.default.sources.USER), delete this.linkRange) : (this.restoreFocus(), this.quill.format("link", tt, he.default.sources.USER)), this.quill.root.scrollTop = Be;
|
|
41537
41586
|
break;
|
|
41538
41587
|
}
|
|
41539
41588
|
case "video":
|
|
@@ -41551,17 +41600,17 @@ function requireQuill() {
|
|
|
41551
41600
|
}
|
|
41552
41601
|
this.textbox.value = "", this.hide();
|
|
41553
41602
|
}
|
|
41554
|
-
}]),
|
|
41603
|
+
}]), Ve;
|
|
41555
41604
|
})(ze.default);
|
|
41556
41605
|
function Ke(je) {
|
|
41557
|
-
var
|
|
41558
|
-
return
|
|
41606
|
+
var Ve = je.match(/^(?:(https?):\/\/)?(?:(?:www|m)\.)?youtube\.com\/watch.*v=([a-zA-Z0-9_-]+)/) || je.match(/^(?:(https?):\/\/)?(?:(?:www|m)\.)?youtu\.be\/([a-zA-Z0-9_-]+)/);
|
|
41607
|
+
return Ve ? (Ve[1] || "https") + "://www.youtube.com/embed/" + Ve[2] + "?showinfo=0" : (Ve = je.match(/^(?:(https?):\/\/)?(?:www\.)?vimeo\.com\/(\d+)/)) ? (Ve[1] || "https") + "://player.vimeo.com/video/" + Ve[2] + "/" : je;
|
|
41559
41608
|
}
|
|
41560
|
-
function Fe(je,
|
|
41609
|
+
function Fe(je, Ve) {
|
|
41561
41610
|
var Qe = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : !1;
|
|
41562
|
-
|
|
41563
|
-
var
|
|
41564
|
-
tt === Qe ?
|
|
41611
|
+
Ve.forEach(function(tt) {
|
|
41612
|
+
var Be = document.createElement("option");
|
|
41613
|
+
tt === Qe ? Be.setAttribute("selected", "selected") : Be.setAttribute("value", tt), je.appendChild(Be);
|
|
41565
41614
|
});
|
|
41566
41615
|
}
|
|
41567
41616
|
oe.BaseTooltip = Xe, oe.default = bt;
|
|
@@ -41997,38 +42046,38 @@ function requireQuill() {
|
|
|
41997
42046
|
Oe[Ue + 1] = 0, qe[Ue + 1] = 0;
|
|
41998
42047
|
for (var He = Me - Ie, Ge = He % 2 != 0, Ze = 0, Ye = 0, bt = 0, Xe = 0, Ke = 0; Ke < ze; Ke++) {
|
|
41999
42048
|
for (var Fe = -Ke + Ze; Fe <= Ke - Ye; Fe += 2) {
|
|
42000
|
-
var je = Ue + Fe,
|
|
42001
|
-
Fe == -Ke || Fe != Ke && Oe[je - 1] < Oe[je + 1] ?
|
|
42002
|
-
for (var Qe =
|
|
42003
|
-
|
|
42004
|
-
if (Oe[je] =
|
|
42049
|
+
var je = Ue + Fe, Ve;
|
|
42050
|
+
Fe == -Ke || Fe != Ke && Oe[je - 1] < Oe[je + 1] ? Ve = Oe[je + 1] : Ve = Oe[je - 1] + 1;
|
|
42051
|
+
for (var Qe = Ve - Fe; Ve < Me && Qe < Ie && we.charAt(Ve) == Se.charAt(Qe); )
|
|
42052
|
+
Ve++, Qe++;
|
|
42053
|
+
if (Oe[je] = Ve, Ve > Me)
|
|
42005
42054
|
Ye += 2;
|
|
42006
42055
|
else if (Qe > Ie)
|
|
42007
42056
|
Ze += 2;
|
|
42008
42057
|
else if (Ge) {
|
|
42009
42058
|
var tt = Ue + He - Fe;
|
|
42010
42059
|
if (tt >= 0 && tt < Le && qe[tt] != -1) {
|
|
42011
|
-
var
|
|
42012
|
-
if (
|
|
42013
|
-
return pe(we, Se,
|
|
42060
|
+
var Be = Me - qe[tt];
|
|
42061
|
+
if (Ve >= Be)
|
|
42062
|
+
return pe(we, Se, Ve, Qe);
|
|
42014
42063
|
}
|
|
42015
42064
|
}
|
|
42016
42065
|
}
|
|
42017
42066
|
for (var Je = -Ke + bt; Je <= Ke - Xe; Je += 2) {
|
|
42018
|
-
var tt = Ue + Je,
|
|
42019
|
-
Je == -Ke || Je != Ke && qe[tt - 1] < qe[tt + 1] ?
|
|
42020
|
-
for (var nt =
|
|
42021
|
-
|
|
42022
|
-
if (qe[tt] =
|
|
42067
|
+
var tt = Ue + Je, Be;
|
|
42068
|
+
Je == -Ke || Je != Ke && qe[tt - 1] < qe[tt + 1] ? Be = qe[tt + 1] : Be = qe[tt - 1] + 1;
|
|
42069
|
+
for (var nt = Be - Je; Be < Me && nt < Ie && we.charAt(Me - Be - 1) == Se.charAt(Ie - nt - 1); )
|
|
42070
|
+
Be++, nt++;
|
|
42071
|
+
if (qe[tt] = Be, Be > Me)
|
|
42023
42072
|
Xe += 2;
|
|
42024
42073
|
else if (nt > Ie)
|
|
42025
42074
|
bt += 2;
|
|
42026
42075
|
else if (!Ge) {
|
|
42027
42076
|
var je = Ue + He - Je;
|
|
42028
42077
|
if (je >= 0 && je < Le && Oe[je] != -1) {
|
|
42029
|
-
var
|
|
42030
|
-
if (
|
|
42031
|
-
return pe(we, Se,
|
|
42078
|
+
var Ve = Oe[je], Qe = Ue + Ve - je;
|
|
42079
|
+
if (Be = Me - Be, Ve >= Be)
|
|
42080
|
+
return pe(we, Se, Ve, Qe);
|
|
42032
42081
|
}
|
|
42033
42082
|
}
|
|
42034
42083
|
}
|
|
@@ -42058,7 +42107,7 @@ function requireQuill() {
|
|
|
42058
42107
|
if (Me.length < 4 || Ie.length * 2 < Me.length)
|
|
42059
42108
|
return null;
|
|
42060
42109
|
function ze(Ye, bt, Xe) {
|
|
42061
|
-
for (var Ke = Ye.substring(Xe, Xe + Math.floor(Ye.length / 4)), Fe = -1, je = "",
|
|
42110
|
+
for (var Ke = Ye.substring(Xe, Xe + Math.floor(Ye.length / 4)), Fe = -1, je = "", Ve, Qe, tt, Be; (Fe = bt.indexOf(Ke, Fe + 1)) != -1; ) {
|
|
42062
42111
|
var Je = be(
|
|
42063
42112
|
Ye.substring(Xe),
|
|
42064
42113
|
bt.substring(Fe)
|
|
@@ -42066,13 +42115,13 @@ function requireQuill() {
|
|
|
42066
42115
|
Ye.substring(0, Xe),
|
|
42067
42116
|
bt.substring(0, Fe)
|
|
42068
42117
|
);
|
|
42069
|
-
je.length < nt + Je && (je = bt.substring(Fe - nt, Fe) + bt.substring(Fe, Fe + Je),
|
|
42118
|
+
je.length < nt + Je && (je = bt.substring(Fe - nt, Fe) + bt.substring(Fe, Fe + Je), Ve = Ye.substring(0, Xe - nt), Qe = Ye.substring(Xe + Je), tt = bt.substring(0, Fe - nt), Be = bt.substring(Fe + Je));
|
|
42070
42119
|
}
|
|
42071
42120
|
return je.length * 2 >= Ye.length ? [
|
|
42072
|
-
|
|
42121
|
+
Ve,
|
|
42073
42122
|
Qe,
|
|
42074
42123
|
tt,
|
|
42075
|
-
|
|
42124
|
+
Be,
|
|
42076
42125
|
je
|
|
42077
42126
|
] : null;
|
|
42078
42127
|
}
|
|
@@ -42458,9 +42507,9 @@ function requireQuill() {
|
|
|
42458
42507
|
matchers: [],
|
|
42459
42508
|
matchVisual: !0
|
|
42460
42509
|
};
|
|
42461
|
-
function
|
|
42510
|
+
function Ve(vt, _t, At) {
|
|
42462
42511
|
return (typeof _t > "u" ? "undefined" : re(_t)) === "object" ? Object.keys(_t).reduce(function(Et, xt) {
|
|
42463
|
-
return
|
|
42512
|
+
return Ve(Et, xt, _t[xt]);
|
|
42464
42513
|
}, vt) : vt.reduce(function(Et, xt) {
|
|
42465
42514
|
return xt.attributes && xt.attributes[_t] ? Et.push(xt) : Et.insert(xt.insert, (0, fe.default)({}, Pe({}, _t, At), xt.attributes));
|
|
42466
42515
|
}, new be.default());
|
|
@@ -42478,7 +42527,7 @@ function requireQuill() {
|
|
|
42478
42527
|
}
|
|
42479
42528
|
return At.slice(-1 * _t.length) === _t;
|
|
42480
42529
|
}
|
|
42481
|
-
function
|
|
42530
|
+
function Be(vt) {
|
|
42482
42531
|
if (vt.childNodes.length === 0) return !1;
|
|
42483
42532
|
var _t = Qe(vt);
|
|
42484
42533
|
return ["block", "list-item"].indexOf(_t.display) > -1;
|
|
@@ -42496,14 +42545,14 @@ function requireQuill() {
|
|
|
42496
42545
|
}, new be.default()) : new be.default();
|
|
42497
42546
|
}
|
|
42498
42547
|
function nt(vt, _t, At) {
|
|
42499
|
-
return
|
|
42548
|
+
return Ve(At, vt, !0);
|
|
42500
42549
|
}
|
|
42501
42550
|
function ft(vt, _t) {
|
|
42502
42551
|
var At = ge.default.Attributor.Attribute.keys(vt), Et = ge.default.Attributor.Class.keys(vt), xt = ge.default.Attributor.Style.keys(vt), Nt = {};
|
|
42503
42552
|
return At.concat(Et).concat(xt).forEach(function(Ft) {
|
|
42504
42553
|
var Ut = ge.default.query(Ft, ge.default.Scope.ATTRIBUTE);
|
|
42505
42554
|
Ut != null && (Nt[Ut.attrName] = Ut.value(vt), Nt[Ut.attrName]) || (Ut = Ke[Ft], Ut != null && (Ut.attrName === Ft || Ut.keyName === Ft) && (Nt[Ut.attrName] = Ut.value(vt) || void 0), Ut = Fe[Ft], Ut != null && (Ut.attrName === Ft || Ut.keyName === Ft) && (Ut = Fe[Ft], Nt[Ut.attrName] = Ut.value(vt) || void 0));
|
|
42506
|
-
}), Object.keys(Nt).length > 0 && (_t =
|
|
42555
|
+
}), Object.keys(Nt).length > 0 && (_t = Ve(_t, Nt)), _t;
|
|
42507
42556
|
}
|
|
42508
42557
|
function $t(vt, _t) {
|
|
42509
42558
|
var At = ge.default.query(vt);
|
|
@@ -42511,7 +42560,7 @@ function requireQuill() {
|
|
|
42511
42560
|
if (At.prototype instanceof ge.default.Embed) {
|
|
42512
42561
|
var Et = {}, xt = At.value(vt);
|
|
42513
42562
|
xt != null && (Et[At.blotName] = xt, _t = new be.default().insert(Et, At.formats(vt)));
|
|
42514
|
-
} else typeof At.formats == "function" && (_t =
|
|
42563
|
+
} else typeof At.formats == "function" && (_t = Ve(_t, At.blotName, At.formats(vt)));
|
|
42515
42564
|
return _t;
|
|
42516
42565
|
}
|
|
42517
42566
|
function St(vt, _t) {
|
|
@@ -42533,11 +42582,11 @@ function requireQuill() {
|
|
|
42533
42582
|
}
|
|
42534
42583
|
function Ht(vt, _t) {
|
|
42535
42584
|
return tt(_t, `
|
|
42536
|
-
`) || (
|
|
42585
|
+
`) || (Be(vt) || _t.length() > 0 && vt.nextSibling && Be(vt.nextSibling)) && _t.insert(`
|
|
42537
42586
|
`), _t;
|
|
42538
42587
|
}
|
|
42539
42588
|
function jt(vt, _t) {
|
|
42540
|
-
if (
|
|
42589
|
+
if (Be(vt) && vt.nextElementSibling != null && !tt(_t, `
|
|
42541
42590
|
|
|
42542
42591
|
`)) {
|
|
42543
42592
|
var At = vt.offsetHeight + parseFloat(Qe(vt).marginTop) + parseFloat(Qe(vt).marginBottom);
|
|
@@ -42548,7 +42597,7 @@ function requireQuill() {
|
|
|
42548
42597
|
}
|
|
42549
42598
|
function ns(vt, _t) {
|
|
42550
42599
|
var At = {}, Et = vt.style || {};
|
|
42551
|
-
return Et.fontStyle && Qe(vt).fontStyle === "italic" && (At.italic = !0), Et.fontWeight && (Qe(vt).fontWeight.startsWith("bold") || parseInt(Qe(vt).fontWeight) >= 700) && (At.bold = !0), Object.keys(At).length > 0 && (_t =
|
|
42600
|
+
return Et.fontStyle && Qe(vt).fontStyle === "italic" && (At.italic = !0), Et.fontWeight && (Qe(vt).fontWeight.startsWith("bold") || parseInt(Qe(vt).fontWeight) >= 700) && (At.bold = !0), Object.keys(At).length > 0 && (_t = Ve(_t, At)), parseFloat(Et.textIndent || 0) > 0 && (_t = new be.default().insert(" ").concat(_t)), _t;
|
|
42552
42601
|
}
|
|
42553
42602
|
function es(vt, _t) {
|
|
42554
42603
|
var At = vt.data;
|
|
@@ -42560,7 +42609,7 @@ function requireQuill() {
|
|
|
42560
42609
|
var Et = function(Nt, Ft) {
|
|
42561
42610
|
return Ft = Ft.replace(/[^\u00a0]/g, ""), Ft.length < 1 && Nt ? " " : Ft;
|
|
42562
42611
|
};
|
|
42563
|
-
At = At.replace(/\r\n/g, " ").replace(/\n/g, " "), At = At.replace(/\s\s+/g, Et.bind(Et, !0)), (vt.previousSibling == null &&
|
|
42612
|
+
At = At.replace(/\r\n/g, " ").replace(/\n/g, " "), At = At.replace(/\s\s+/g, Et.bind(Et, !0)), (vt.previousSibling == null && Be(vt.parentNode) || vt.previousSibling != null && Be(vt.previousSibling)) && (At = At.replace(/^\s+/, Et.bind(Et, !1))), (vt.nextSibling == null && Be(vt.parentNode) || vt.nextSibling != null && Be(vt.nextSibling)) && (At = At.replace(/\s+$/, Et.bind(Et, !1)));
|
|
42564
42613
|
}
|
|
42565
42614
|
return _t.insert(At);
|
|
42566
42615
|
}
|
|
@@ -42757,7 +42806,7 @@ function requireQuill() {
|
|
|
42757
42806
|
} else
|
|
42758
42807
|
Ge.classList.contains("ql-active") ? Ke = !1 : Ke = Ge.value || !Ge.hasAttribute("value"), Xe.preventDefault();
|
|
42759
42808
|
Ze.quill.focus();
|
|
42760
|
-
var je = Ze.quill.selection.getRange(),
|
|
42809
|
+
var je = Ze.quill.selection.getRange(), Ve = re(je, 1), Qe = Ve[0];
|
|
42761
42810
|
if (Ze.handlers[Ye] != null)
|
|
42762
42811
|
Ze.handlers[Ye].call(Ze, Ke);
|
|
42763
42812
|
else if (pe.default.query(Ye).prototype instanceof pe.default.Embed) {
|
|
@@ -42789,8 +42838,8 @@ function requireQuill() {
|
|
|
42789
42838
|
} else if (Ge == null)
|
|
42790
42839
|
Ke.classList.remove("ql-active");
|
|
42791
42840
|
else if (Ke.hasAttribute("value")) {
|
|
42792
|
-
var
|
|
42793
|
-
Ke.classList.toggle("ql-active",
|
|
42841
|
+
var Ve = Ze[Xe] === Ke.getAttribute("value") || Ze[Xe] != null && Ze[Xe].toString() === Ke.getAttribute("value") || Ze[Xe] == null && !Ke.getAttribute("value");
|
|
42842
|
+
Ke.classList.toggle("ql-active", Ve);
|
|
42794
42843
|
} else
|
|
42795
42844
|
Ke.classList.toggle("ql-active", Ze[Xe] != null);
|
|
42796
42845
|
});
|
|
@@ -43207,7 +43256,7 @@ function requireQuill() {
|
|
|
43207
43256
|
Object.defineProperty(oe, "__esModule", {
|
|
43208
43257
|
value: !0
|
|
43209
43258
|
});
|
|
43210
|
-
var re = ne(29), de = xt(re), ce = ne(37), ue = ne(39), fe = ne(65), pe = ne(66), be = xt(pe), he = ne(67), ge = xt(he), ve = ne(68), me = xt(ve), _e = ne(38), ye = ne(26), Ae = ne(40), Ce = ne(41), we = ne(57), Se = xt(we), Me = ne(69), Ie = xt(Me), ze = ne(27), Ue = xt(ze), Le = ne(70), Oe = xt(Le), qe = ne(71), Pe = xt(qe), He = ne(72), Ge = xt(He), Ze = ne(73), Ye = xt(Ze), bt = ne(74), Xe = xt(bt), Ke = ne(13), Fe = xt(Ke), je = ne(75),
|
|
43259
|
+
var re = ne(29), de = xt(re), ce = ne(37), ue = ne(39), fe = ne(65), pe = ne(66), be = xt(pe), he = ne(67), ge = xt(he), ve = ne(68), me = xt(ve), _e = ne(38), ye = ne(26), Ae = ne(40), Ce = ne(41), we = ne(57), Se = xt(we), Me = ne(69), Ie = xt(Me), ze = ne(27), Ue = xt(ze), Le = ne(70), Oe = xt(Le), qe = ne(71), Pe = xt(qe), He = ne(72), Ge = xt(He), Ze = ne(73), Ye = xt(Ze), bt = ne(74), Xe = xt(bt), Ke = ne(13), Fe = xt(Ke), je = ne(75), Ve = xt(je), Qe = ne(76), tt = xt(Qe), Be = ne(58), Je = xt(Be), nt = ne(42), ft = xt(nt), $t = ne(28), St = xt($t), Pt = ne(60), It = xt(Pt), Ht = ne(61), jt = xt(Ht), ns = ne(62), es = xt(ns), vt = ne(109), _t = xt(vt), At = ne(63), Et = xt(At);
|
|
43211
43260
|
function xt(Nt) {
|
|
43212
43261
|
return Nt && Nt.__esModule ? Nt : { default: Nt };
|
|
43213
43262
|
}
|
|
@@ -43247,7 +43296,7 @@ function requireQuill() {
|
|
|
43247
43296
|
"formats/image": Ye.default,
|
|
43248
43297
|
"formats/video": Xe.default,
|
|
43249
43298
|
"formats/list/item": ve.ListItem,
|
|
43250
|
-
"modules/formula":
|
|
43299
|
+
"modules/formula": Ve.default,
|
|
43251
43300
|
"modules/syntax": tt.default,
|
|
43252
43301
|
"modules/toolbar": Je.default,
|
|
43253
43302
|
"themes/bubble": _t.default,
|
|
@@ -45472,7 +45521,7 @@ const commonNavMenuItems = [
|
|
|
45472
45521
|
}, useUI = () => {
|
|
45473
45522
|
p$g.registerAdapterFactory(
|
|
45474
45523
|
"primaria-content-switcher",
|
|
45475
|
-
d$
|
|
45524
|
+
d$y
|
|
45476
45525
|
), useSharedUI(), useComponents(), useInternalViews();
|
|
45477
45526
|
}, initializeShell = (X, W) => {
|
|
45478
45527
|
W && shellApi.contextManager.initializeContext(W), activityMonitor.start(), sessionRefreshTimer.start(), useLocalization(shellApi), useUI(), useFeatures(shellApi);
|
|
@@ -45550,4 +45599,4 @@ export {
|
|
|
45550
45599
|
createEcapEventManager as y,
|
|
45551
45600
|
ExitShell as z
|
|
45552
45601
|
};
|
|
45553
|
-
//# sourceMappingURL=index-
|
|
45602
|
+
//# sourceMappingURL=index-DSO8ViDu.js.map
|