@acorex/layout 16.20.14 → 16.22.2
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/fesm2022/acorex-layout.mjs +1571 -1206
- package/fesm2022/acorex-layout.mjs.map +1 -1
- package/package.json +10 -5
- package/types/acorex-layout.d.ts +289 -0
- package/index.d.ts +0 -243
|
@@ -1,1207 +1,1572 @@
|
|
|
1
|
-
import { __decorate, __metadata } from
|
|
2
|
-
import * as i0 from
|
|
3
|
-
import {
|
|
4
|
-
import * as i1 from
|
|
5
|
-
import {
|
|
6
|
-
import * as
|
|
7
|
-
import {
|
|
8
|
-
import { Subject } from
|
|
9
|
-
import { debounceTime } from
|
|
10
|
-
import { CommonModule } from
|
|
11
|
-
import * as i1
|
|
12
|
-
import { RouterModule } from
|
|
13
|
-
import { FormsModule } from
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
|
|
846
|
-
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
|
|
874
|
-
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
|
|
903
|
-
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
|
|
921
|
-
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
|
|
935
|
-
|
|
936
|
-
|
|
937
|
-
|
|
938
|
-
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
|
|
946
|
-
|
|
947
|
-
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
|
|
962
|
-
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
|
|
971
|
-
|
|
972
|
-
|
|
973
|
-
|
|
974
|
-
|
|
975
|
-
|
|
976
|
-
|
|
977
|
-
|
|
978
|
-
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
|
|
983
|
-
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
|
|
987
|
-
|
|
988
|
-
|
|
989
|
-
|
|
990
|
-
|
|
991
|
-
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
|
|
1002
|
-
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
|
|
1024
|
-
|
|
1025
|
-
|
|
1026
|
-
|
|
1027
|
-
|
|
1028
|
-
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
|
|
1033
|
-
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1037
|
-
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
|
|
1053
|
-
|
|
1054
|
-
|
|
1055
|
-
|
|
1056
|
-
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
1067
|
-
|
|
1068
|
-
|
|
1069
|
-
|
|
1070
|
-
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
|
|
1085
|
-
|
|
1086
|
-
|
|
1087
|
-
|
|
1088
|
-
|
|
1089
|
-
|
|
1090
|
-
|
|
1091
|
-
|
|
1092
|
-
|
|
1093
|
-
|
|
1094
|
-
|
|
1095
|
-
|
|
1096
|
-
|
|
1097
|
-
|
|
1098
|
-
|
|
1099
|
-
|
|
1100
|
-
|
|
1101
|
-
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
|
|
1107
|
-
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
|
-
|
|
1118
|
-
|
|
1119
|
-
|
|
1120
|
-
|
|
1121
|
-
|
|
1122
|
-
|
|
1123
|
-
|
|
1124
|
-
|
|
1125
|
-
|
|
1126
|
-
|
|
1127
|
-
|
|
1128
|
-
|
|
1129
|
-
|
|
1130
|
-
|
|
1131
|
-
|
|
1132
|
-
|
|
1133
|
-
|
|
1134
|
-
|
|
1135
|
-
|
|
1136
|
-
|
|
1137
|
-
|
|
1138
|
-
|
|
1139
|
-
|
|
1140
|
-
|
|
1141
|
-
|
|
1142
|
-
|
|
1143
|
-
|
|
1144
|
-
|
|
1145
|
-
|
|
1146
|
-
|
|
1147
|
-
|
|
1148
|
-
|
|
1149
|
-
|
|
1150
|
-
|
|
1151
|
-
|
|
1152
|
-
|
|
1153
|
-
|
|
1154
|
-
|
|
1155
|
-
|
|
1156
|
-
|
|
1157
|
-
|
|
1158
|
-
|
|
1159
|
-
|
|
1160
|
-
|
|
1161
|
-
|
|
1162
|
-
|
|
1163
|
-
|
|
1164
|
-
|
|
1165
|
-
|
|
1166
|
-
|
|
1167
|
-
|
|
1168
|
-
|
|
1169
|
-
|
|
1170
|
-
|
|
1171
|
-
|
|
1172
|
-
|
|
1173
|
-
|
|
1174
|
-
|
|
1175
|
-
|
|
1176
|
-
|
|
1177
|
-
|
|
1178
|
-
|
|
1179
|
-
|
|
1180
|
-
|
|
1181
|
-
|
|
1182
|
-
|
|
1183
|
-
|
|
1184
|
-
|
|
1185
|
-
|
|
1186
|
-
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
|
|
1194
|
-
|
|
1195
|
-
|
|
1196
|
-
|
|
1197
|
-
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
|
|
1
|
+
import { __decorate, __metadata } from "tslib";
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
import { ChangeDetectionStrategy, Component, EventEmitter, HostBinding, Injectable, Input, NO_ERRORS_SCHEMA, NgModule, Output, ViewChild, ViewChildren, ViewContainerRef, ViewEncapsulation } from "@angular/core";
|
|
4
|
+
import * as i1$1 from "@acorex/components";
|
|
5
|
+
import { AXBasePopupPageComponent, AXCheckBoxModule, AXFieldsetModule, AXFormGroupModule, AXLabelModule, AXLoadingModule, AXMenuModule, AXNumberBoxModule, AXPageModule, AXPropertyDecorators, AXProperyEditorComponent, AXProppertyEditorModule, AXSearchBoxModule, AXTabStripModule, AXTextAreaModule, AXTextBoxModule, AXToolbarModule, AXValidationFormComponent, AXValidationModule, propertyEditor } from "@acorex/components";
|
|
6
|
+
import * as i2 from "@acorex/core";
|
|
7
|
+
import { AXClientRec, AXHtmlUtil, AXObjectUtil, AXTranslator, AXTranslatorModule } from "@acorex/core";
|
|
8
|
+
import { Subject } from "rxjs";
|
|
9
|
+
import { debounceTime } from "rxjs/operators";
|
|
10
|
+
import { CommonModule } from "@angular/common";
|
|
11
|
+
import * as i1 from "@angular/router";
|
|
12
|
+
import { RouterModule } from "@angular/router";
|
|
13
|
+
import { FormsModule } from "@angular/forms";
|
|
14
|
+
var AXWidgetComponent = class AXWidgetComponent {
|
|
15
|
+
uid = AXHtmlUtil.getUID();
|
|
16
|
+
provideValue;
|
|
17
|
+
onBusyChanged = new EventEmitter();
|
|
18
|
+
_isBusy = true;
|
|
19
|
+
get isBusy() {
|
|
20
|
+
return this._isBusy;
|
|
21
|
+
}
|
|
22
|
+
set isBusy(v) {
|
|
23
|
+
if (v !== this._isBusy) {
|
|
24
|
+
const eventData = {
|
|
25
|
+
component: this,
|
|
26
|
+
oldValue: this._isBusy,
|
|
27
|
+
value: v
|
|
28
|
+
};
|
|
29
|
+
this._isBusy = v;
|
|
30
|
+
this.onBusyChanged.emit(eventData);
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
widgetSize;
|
|
34
|
+
refreshRate = [{
|
|
35
|
+
id: 3e5,
|
|
36
|
+
text: AXTranslator.get("dateTime.duration.format_minute").replace("{0}", "5")
|
|
37
|
+
}];
|
|
38
|
+
getRefreshRate() {
|
|
39
|
+
return Array.isArray(this.refreshRate) && this.refreshRate.length ? this.refreshRate[0].id : this.refreshRate;
|
|
40
|
+
}
|
|
41
|
+
intervalId;
|
|
42
|
+
constructor() {
|
|
43
|
+
this.onConfiguredChanged.subscribe(() => {
|
|
44
|
+
if (this.isConfigured === true && this.getRefreshRate()) this.restartRefreshTimer();
|
|
45
|
+
else this.stopRefreshTimer();
|
|
46
|
+
});
|
|
47
|
+
}
|
|
48
|
+
startRefreshTimer() {
|
|
49
|
+
this.intervalId = window.setInterval(this.refresh.bind(this), this.getRefreshRate());
|
|
50
|
+
}
|
|
51
|
+
stopRefreshTimer() {
|
|
52
|
+
window.clearInterval(this.intervalId);
|
|
53
|
+
}
|
|
54
|
+
restartRefreshTimer() {
|
|
55
|
+
this.stopRefreshTimer();
|
|
56
|
+
this.startRefreshTimer();
|
|
57
|
+
}
|
|
58
|
+
ngOnDestroy() {
|
|
59
|
+
this.stopRefreshTimer();
|
|
60
|
+
}
|
|
61
|
+
redraw() {}
|
|
62
|
+
refresh() {
|
|
63
|
+
this.restartRefreshTimer();
|
|
64
|
+
}
|
|
65
|
+
onConfiguredChanged = new EventEmitter();
|
|
66
|
+
get isConfigured() {
|
|
67
|
+
return true;
|
|
68
|
+
}
|
|
69
|
+
setValue(name, value) {
|
|
70
|
+
this[name] = value;
|
|
71
|
+
this.onConfiguredChanged.emit();
|
|
72
|
+
}
|
|
73
|
+
getValue(name) {
|
|
74
|
+
const val = this[name];
|
|
75
|
+
const config = this["__meta__"].config;
|
|
76
|
+
if (config.props[name]?.runtime && this.provideValue) {
|
|
77
|
+
const res = this.provideValue({
|
|
78
|
+
name,
|
|
79
|
+
value: val,
|
|
80
|
+
uniqueName: config.uniqueName,
|
|
81
|
+
options: config.options
|
|
82
|
+
});
|
|
83
|
+
if (this.provideValue instanceof Promise) return res;
|
|
84
|
+
else return Promise.resolve(res);
|
|
85
|
+
}
|
|
86
|
+
return Promise.resolve(val);
|
|
87
|
+
}
|
|
88
|
+
static ɵfac = i0.ɵɵngDeclareFactory({
|
|
89
|
+
minVersion: "12.0.0",
|
|
90
|
+
version: "22.2.0",
|
|
91
|
+
ngImport: i0,
|
|
92
|
+
type: AXWidgetComponent,
|
|
93
|
+
deps: [],
|
|
94
|
+
target: i0.ɵɵFactoryTarget.Injectable
|
|
95
|
+
});
|
|
96
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({
|
|
97
|
+
minVersion: "12.0.0",
|
|
98
|
+
version: "22.2.0",
|
|
99
|
+
ngImport: i0,
|
|
100
|
+
type: AXWidgetComponent
|
|
101
|
+
});
|
|
102
|
+
};
|
|
103
|
+
__decorate([propertyEditor({
|
|
104
|
+
editorClass: "ax/editors/widget-size",
|
|
105
|
+
title: "common.size",
|
|
106
|
+
visible: false,
|
|
107
|
+
order: -99
|
|
108
|
+
}), __metadata("design:type", Array)], AXWidgetComponent.prototype, "widgetSize", void 0);
|
|
109
|
+
__decorate([propertyEditor({
|
|
110
|
+
editorClass: "ax/editors/select",
|
|
111
|
+
title: "common.refresh-rate",
|
|
112
|
+
visible: true,
|
|
113
|
+
order: -98,
|
|
114
|
+
editorOptions: {
|
|
115
|
+
items: () => {
|
|
116
|
+
return [
|
|
117
|
+
"بدون مقدار",
|
|
118
|
+
1,
|
|
119
|
+
2,
|
|
120
|
+
3,
|
|
121
|
+
5,
|
|
122
|
+
10,
|
|
123
|
+
20,
|
|
124
|
+
30,
|
|
125
|
+
60
|
|
126
|
+
].map((c) => ({
|
|
127
|
+
id: typeof c === "number" ? 6e4 * c : 0,
|
|
128
|
+
text: typeof c === "number" ? AXTranslator.get("dateTime.duration.format_minute").replace("{0}", c.toString()) : c
|
|
129
|
+
}));
|
|
130
|
+
},
|
|
131
|
+
allowNull: false,
|
|
132
|
+
allowSearch: false,
|
|
133
|
+
selectionDataMode: "value",
|
|
134
|
+
selectionMode: "single",
|
|
135
|
+
valueField: "id"
|
|
136
|
+
}
|
|
137
|
+
}), __metadata("design:type", Object)], AXWidgetComponent.prototype, "refreshRate", void 0);
|
|
138
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
139
|
+
minVersion: "12.0.0",
|
|
140
|
+
version: "22.2.0",
|
|
141
|
+
ngImport: i0,
|
|
142
|
+
type: AXWidgetComponent,
|
|
143
|
+
decorators: [{ type: Injectable }],
|
|
144
|
+
ctorParameters: () => [],
|
|
145
|
+
propDecorators: {
|
|
146
|
+
widgetSize: [],
|
|
147
|
+
refreshRate: []
|
|
148
|
+
}
|
|
149
|
+
});
|
|
150
|
+
var AXWidgetConfigComponent = class AXWidgetConfigComponent extends AXBasePopupPageComponent {
|
|
151
|
+
cdr;
|
|
152
|
+
form;
|
|
153
|
+
constructor(cdr) {
|
|
154
|
+
super();
|
|
155
|
+
this.cdr = cdr;
|
|
156
|
+
}
|
|
157
|
+
widget;
|
|
158
|
+
props = [];
|
|
159
|
+
displayProps = [];
|
|
160
|
+
changes = [];
|
|
161
|
+
context = {};
|
|
162
|
+
getFooterButtons() {
|
|
163
|
+
return [{
|
|
164
|
+
name: "okay",
|
|
165
|
+
submitBehavior: true,
|
|
166
|
+
text: AXTranslator.get("common.confirm"),
|
|
167
|
+
style: "success"
|
|
168
|
+
}, {
|
|
169
|
+
name: "cancel",
|
|
170
|
+
cancelBehavior: true,
|
|
171
|
+
text: AXTranslator.get("common.cancel"),
|
|
172
|
+
style: "danger blank"
|
|
173
|
+
}];
|
|
174
|
+
}
|
|
175
|
+
onFooterButtonClick(e) {
|
|
176
|
+
if (e.name === "cancel") this.close();
|
|
177
|
+
if (e.name === "okay") this.form.validate().then((c) => {
|
|
178
|
+
if (c.result) this.close(this.changes);
|
|
179
|
+
});
|
|
180
|
+
}
|
|
181
|
+
handleValueChange(e) {
|
|
182
|
+
const prop = this.changes.find((c) => c.property.name === e.property.name);
|
|
183
|
+
if (prop) prop.value = e.value;
|
|
184
|
+
else this.changes.push({
|
|
185
|
+
property: e.property,
|
|
186
|
+
value: e.value
|
|
187
|
+
});
|
|
188
|
+
this.updateContext();
|
|
189
|
+
}
|
|
190
|
+
ngOnInit() {
|
|
191
|
+
this.displayProps = this.props.filter((c) => c.property.visible !== false).sort((a, b) => a.property.order - b.property.order);
|
|
192
|
+
this.updateContext();
|
|
193
|
+
}
|
|
194
|
+
updateContext() {
|
|
195
|
+
const ctx = {};
|
|
196
|
+
this.props.forEach((p) => {
|
|
197
|
+
ctx[p.property.name] = p.value;
|
|
198
|
+
});
|
|
199
|
+
this.changes.forEach((p) => {
|
|
200
|
+
ctx[p.property.name] = p.value;
|
|
201
|
+
});
|
|
202
|
+
this.context = ctx;
|
|
203
|
+
}
|
|
204
|
+
identify(index, item) {
|
|
205
|
+
return item.property.name;
|
|
206
|
+
}
|
|
207
|
+
static ɵfac = i0.ɵɵngDeclareFactory({
|
|
208
|
+
minVersion: "12.0.0",
|
|
209
|
+
version: "22.2.0",
|
|
210
|
+
ngImport: i0,
|
|
211
|
+
type: AXWidgetConfigComponent,
|
|
212
|
+
deps: [{ token: i0.ChangeDetectorRef }],
|
|
213
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
214
|
+
});
|
|
215
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({
|
|
216
|
+
minVersion: "17.0.0",
|
|
217
|
+
version: "22.2.0",
|
|
218
|
+
type: AXWidgetConfigComponent,
|
|
219
|
+
isStandalone: false,
|
|
220
|
+
selector: "ng-component",
|
|
221
|
+
viewQueries: [{
|
|
222
|
+
propertyName: "form",
|
|
223
|
+
first: true,
|
|
224
|
+
predicate: AXValidationFormComponent,
|
|
225
|
+
descendants: true
|
|
226
|
+
}],
|
|
227
|
+
usesInheritance: true,
|
|
228
|
+
ngImport: i0,
|
|
229
|
+
template: "<ax-page>\n <ax-page-content>\n <div class=\"container\">\n <ax-validation-form #form>\n @for (p of displayProps; track identify($index, p)) {\n <div class=\"row\">\n <div class=\"col-12\">\n <ax-label>{{p.property.title | trans}}</ax-label>\n <ng-container ax-property-editor-renderer [property]=\"p\" [context]=\"context\" [host]=\"widget\" [validationForm]=\"form\"\n (onValueChange)=\"handleValueChange($event)\">\n </ng-container>\n </div>\n </div>\n }\n </ax-validation-form>\n </div>\n </ax-page-content>\n</ax-page>",
|
|
230
|
+
dependencies: [
|
|
231
|
+
{
|
|
232
|
+
kind: "directive",
|
|
233
|
+
type: i1$1.AXPropertyEditorRendererDirective,
|
|
234
|
+
selector: "[ax-property-editor-renderer]",
|
|
235
|
+
inputs: [
|
|
236
|
+
"property",
|
|
237
|
+
"validationForm",
|
|
238
|
+
"context",
|
|
239
|
+
"host",
|
|
240
|
+
"groupId"
|
|
241
|
+
],
|
|
242
|
+
outputs: ["onValueChange"]
|
|
243
|
+
},
|
|
244
|
+
{
|
|
245
|
+
kind: "component",
|
|
246
|
+
type: i1$1.AXPageContentComponent,
|
|
247
|
+
selector: "ax-page-content"
|
|
248
|
+
},
|
|
249
|
+
{
|
|
250
|
+
kind: "component",
|
|
251
|
+
type: i1$1.AXPageComponent,
|
|
252
|
+
selector: "ax-page"
|
|
253
|
+
},
|
|
254
|
+
{
|
|
255
|
+
kind: "component",
|
|
256
|
+
type: i1$1.AXLabelComponent,
|
|
257
|
+
selector: "ax-label",
|
|
258
|
+
inputs: ["size"],
|
|
259
|
+
outputs: ["clickLabel"]
|
|
260
|
+
},
|
|
261
|
+
{
|
|
262
|
+
kind: "component",
|
|
263
|
+
type: i1$1.AXValidationFormComponent,
|
|
264
|
+
selector: "ax-validation-form",
|
|
265
|
+
inputs: ["validateOn"],
|
|
266
|
+
outputs: ["onInit"]
|
|
267
|
+
},
|
|
268
|
+
{
|
|
269
|
+
kind: "pipe",
|
|
270
|
+
type: i2.AXTranslatorPipe,
|
|
271
|
+
name: "trans"
|
|
272
|
+
}
|
|
273
|
+
],
|
|
274
|
+
changeDetection: i0.ChangeDetectionStrategy.OnPush,
|
|
275
|
+
encapsulation: i0.ViewEncapsulation.None
|
|
276
|
+
});
|
|
277
|
+
};
|
|
278
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
279
|
+
minVersion: "12.0.0",
|
|
280
|
+
version: "22.2.0",
|
|
281
|
+
ngImport: i0,
|
|
282
|
+
type: AXWidgetConfigComponent,
|
|
283
|
+
decorators: [{
|
|
284
|
+
type: Component,
|
|
285
|
+
args: [{
|
|
286
|
+
encapsulation: ViewEncapsulation.None,
|
|
287
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
288
|
+
standalone: false,
|
|
289
|
+
template: "<ax-page>\n <ax-page-content>\n <div class=\"container\">\n <ax-validation-form #form>\n @for (p of displayProps; track identify($index, p)) {\n <div class=\"row\">\n <div class=\"col-12\">\n <ax-label>{{p.property.title | trans}}</ax-label>\n <ng-container ax-property-editor-renderer [property]=\"p\" [context]=\"context\" [host]=\"widget\" [validationForm]=\"form\"\n (onValueChange)=\"handleValueChange($event)\">\n </ng-container>\n </div>\n </div>\n }\n </ax-validation-form>\n </div>\n </ax-page-content>\n</ax-page>"
|
|
290
|
+
}]
|
|
291
|
+
}],
|
|
292
|
+
ctorParameters: () => [{ type: i0.ChangeDetectorRef }],
|
|
293
|
+
propDecorators: { form: [{
|
|
294
|
+
type: ViewChild,
|
|
295
|
+
args: [AXValidationFormComponent]
|
|
296
|
+
}] }
|
|
297
|
+
});
|
|
298
|
+
var AXWidgetSaveComponent = class AXWidgetSaveComponent extends AXBasePopupPageComponent {
|
|
299
|
+
config;
|
|
300
|
+
props = [];
|
|
301
|
+
displayProps;
|
|
302
|
+
data;
|
|
303
|
+
getFooterButtons() {
|
|
304
|
+
return [{
|
|
305
|
+
name: "okay",
|
|
306
|
+
submitBehavior: true,
|
|
307
|
+
text: AXTranslator.get("common.confirm"),
|
|
308
|
+
style: "ax success"
|
|
309
|
+
}, {
|
|
310
|
+
name: "cancel",
|
|
311
|
+
cancelBehavior: true,
|
|
312
|
+
text: AXTranslator.get("common.cancel"),
|
|
313
|
+
style: "ax light"
|
|
314
|
+
}];
|
|
315
|
+
}
|
|
316
|
+
ngOnInit() {
|
|
317
|
+
const title = this.props.find((c) => c.property.name === "title" || c.property.name === "name")?.value || this.config.title;
|
|
318
|
+
const pp = {};
|
|
319
|
+
this.props?.forEach((c) => {
|
|
320
|
+
pp[c.property.name] = c.property;
|
|
321
|
+
});
|
|
322
|
+
this.data = {
|
|
323
|
+
component: this.config.component,
|
|
324
|
+
title,
|
|
325
|
+
uniqueName: `${this.config.uniqueName}-${AXHtmlUtil.getUID()}`,
|
|
326
|
+
options: AXObjectUtil.deepJSONClone(this.config.options),
|
|
327
|
+
props: AXObjectUtil.deepJSONClone(pp)
|
|
328
|
+
};
|
|
329
|
+
this.displayProps = this.props.filter((c) => c.property.visible !== false).sort((a, b) => a.property.order - b.property.order).map((c) => ({
|
|
330
|
+
name: c.property.name,
|
|
331
|
+
title: c.property.title,
|
|
332
|
+
allow: true
|
|
333
|
+
}));
|
|
334
|
+
}
|
|
335
|
+
onFooterButtonClick(e) {
|
|
336
|
+
if (e.name === "cancel") this.close();
|
|
337
|
+
if (e.name === "okay") {
|
|
338
|
+
this.props.forEach((p) => {
|
|
339
|
+
const pp = this.displayProps.find((c) => c.name === p.property.name);
|
|
340
|
+
if (pp == null || !pp.allow) {
|
|
341
|
+
let ppp = this.data.props[p.property.name];
|
|
342
|
+
if (ppp) ppp.visible = false;
|
|
343
|
+
else ppp = { visible: false };
|
|
344
|
+
}
|
|
345
|
+
});
|
|
346
|
+
this.close(this.data);
|
|
347
|
+
}
|
|
348
|
+
}
|
|
349
|
+
static ɵfac = i0.ɵɵngDeclareFactory({
|
|
350
|
+
minVersion: "12.0.0",
|
|
351
|
+
version: "22.2.0",
|
|
352
|
+
ngImport: i0,
|
|
353
|
+
type: AXWidgetSaveComponent,
|
|
354
|
+
deps: null,
|
|
355
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
356
|
+
});
|
|
357
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({
|
|
358
|
+
minVersion: "17.0.0",
|
|
359
|
+
version: "22.2.0",
|
|
360
|
+
type: AXWidgetSaveComponent,
|
|
361
|
+
isStandalone: false,
|
|
362
|
+
selector: "ng-component",
|
|
363
|
+
usesInheritance: true,
|
|
364
|
+
ngImport: i0,
|
|
365
|
+
template: "<ax-page>\n <ax-page-content>\n <div class=\"container\">\n <div class=\"row\">\n <div class=\"col-12\">\n <ax-form-group>\n <ax-label>{{'common.title' | trans}}</ax-label>\n <ax-text-box [(value)]=\"data.title\"></ax-text-box>\n </ax-form-group>\n </div>\n </div>\n <div class=\"row\">\n <div class=\"col-12\">\n <ax-form-group>\n <ax-label>{{'common.description' | trans}}</ax-label>\n <ax-text-area [(value)]=\"data.description\"></ax-text-area>\n </ax-form-group>\n </div>\n </div>\n <!-- <div class=\"row\">\n <div class=\"col-12\">\n <ax-form-group>\n <ax-label>{{'common.uniquename' | trans}}</ax-label>\n <ax-text-box></ax-text-box>\n </ax-form-group>\n </div>\n </div> -->\n <div class=\"row\" style=\"margin-block-end: var(--ax-size-md);margin-block-start: var(--ax-size-md);\">\n <div class=\"col-12\">\n <ax-fieldset caption=\"{{'widget-board.configurable-props' | trans}}\">\n @for (prop of displayProps; track prop) {\n <div class=\"row\">\n <div class=\"col-12\" style=\"margin-block-end: var(--ax-size-sm)\">\n <ax-check-box [(value)]=\"prop.allow\" label=\"{{ prop.title | trans }}\">\n </ax-check-box>\n </div>\n </div>\n }\n </ax-fieldset>\n </div>\n </div>\n </div>\n</ax-page-content>\n</ax-page>",
|
|
366
|
+
dependencies: [
|
|
367
|
+
{
|
|
368
|
+
kind: "component",
|
|
369
|
+
type: i1$1.AXPageContentComponent,
|
|
370
|
+
selector: "ax-page-content"
|
|
371
|
+
},
|
|
372
|
+
{
|
|
373
|
+
kind: "component",
|
|
374
|
+
type: i1$1.AXPageComponent,
|
|
375
|
+
selector: "ax-page"
|
|
376
|
+
},
|
|
377
|
+
{
|
|
378
|
+
kind: "component",
|
|
379
|
+
type: i1$1.AXLabelComponent,
|
|
380
|
+
selector: "ax-label",
|
|
381
|
+
inputs: ["size"],
|
|
382
|
+
outputs: ["clickLabel"]
|
|
383
|
+
},
|
|
384
|
+
{
|
|
385
|
+
kind: "component",
|
|
386
|
+
type: i1$1.AXTextAreaComponent,
|
|
387
|
+
selector: "ax-text-area",
|
|
388
|
+
inputs: [
|
|
389
|
+
"rows",
|
|
390
|
+
"cols",
|
|
391
|
+
"maxLength"
|
|
392
|
+
],
|
|
393
|
+
outputs: ["onBlur", "onFocus"]
|
|
394
|
+
},
|
|
395
|
+
{
|
|
396
|
+
kind: "component",
|
|
397
|
+
type: i1$1.AXFieldsetComponent,
|
|
398
|
+
selector: "ax-fieldset",
|
|
399
|
+
inputs: [
|
|
400
|
+
"size",
|
|
401
|
+
"caption",
|
|
402
|
+
"allowCollapse"
|
|
403
|
+
]
|
|
404
|
+
},
|
|
405
|
+
{
|
|
406
|
+
kind: "component",
|
|
407
|
+
type: i1$1.AXTextBoxComponent,
|
|
408
|
+
selector: "ax-text-box",
|
|
409
|
+
inputs: [
|
|
410
|
+
"mask",
|
|
411
|
+
"showMask",
|
|
412
|
+
"type",
|
|
413
|
+
"maxLength",
|
|
414
|
+
"maskGuid",
|
|
415
|
+
"maskPlaceholder",
|
|
416
|
+
"maskKeepCharPositions",
|
|
417
|
+
"leadZeroDateTime"
|
|
418
|
+
]
|
|
419
|
+
},
|
|
420
|
+
{
|
|
421
|
+
kind: "component",
|
|
422
|
+
type: i1$1.AXFormGroupComponent,
|
|
423
|
+
selector: "ax-form-group",
|
|
424
|
+
inputs: ["size", "labelMode"],
|
|
425
|
+
outputs: ["labelModeChange"]
|
|
426
|
+
},
|
|
427
|
+
{
|
|
428
|
+
kind: "component",
|
|
429
|
+
type: i1$1.AXCheckBoxComponent,
|
|
430
|
+
selector: "ax-check-box",
|
|
431
|
+
inputs: [
|
|
432
|
+
"readonly",
|
|
433
|
+
"disabled",
|
|
434
|
+
"size",
|
|
435
|
+
"label",
|
|
436
|
+
"tabIndex",
|
|
437
|
+
"indeterminate",
|
|
438
|
+
"value"
|
|
439
|
+
],
|
|
440
|
+
outputs: [
|
|
441
|
+
"onValueChanged",
|
|
442
|
+
"valueChange",
|
|
443
|
+
"onClick"
|
|
444
|
+
]
|
|
445
|
+
},
|
|
446
|
+
{
|
|
447
|
+
kind: "pipe",
|
|
448
|
+
type: i2.AXTranslatorPipe,
|
|
449
|
+
name: "trans"
|
|
450
|
+
}
|
|
451
|
+
],
|
|
452
|
+
changeDetection: i0.ChangeDetectionStrategy.OnPush,
|
|
453
|
+
encapsulation: i0.ViewEncapsulation.None
|
|
454
|
+
});
|
|
455
|
+
};
|
|
456
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
457
|
+
minVersion: "12.0.0",
|
|
458
|
+
version: "22.2.0",
|
|
459
|
+
ngImport: i0,
|
|
460
|
+
type: AXWidgetSaveComponent,
|
|
461
|
+
decorators: [{
|
|
462
|
+
type: Component,
|
|
463
|
+
args: [{
|
|
464
|
+
encapsulation: ViewEncapsulation.None,
|
|
465
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
466
|
+
standalone: false,
|
|
467
|
+
template: "<ax-page>\n <ax-page-content>\n <div class=\"container\">\n <div class=\"row\">\n <div class=\"col-12\">\n <ax-form-group>\n <ax-label>{{'common.title' | trans}}</ax-label>\n <ax-text-box [(value)]=\"data.title\"></ax-text-box>\n </ax-form-group>\n </div>\n </div>\n <div class=\"row\">\n <div class=\"col-12\">\n <ax-form-group>\n <ax-label>{{'common.description' | trans}}</ax-label>\n <ax-text-area [(value)]=\"data.description\"></ax-text-area>\n </ax-form-group>\n </div>\n </div>\n <!-- <div class=\"row\">\n <div class=\"col-12\">\n <ax-form-group>\n <ax-label>{{'common.uniquename' | trans}}</ax-label>\n <ax-text-box></ax-text-box>\n </ax-form-group>\n </div>\n </div> -->\n <div class=\"row\" style=\"margin-block-end: var(--ax-size-md);margin-block-start: var(--ax-size-md);\">\n <div class=\"col-12\">\n <ax-fieldset caption=\"{{'widget-board.configurable-props' | trans}}\">\n @for (prop of displayProps; track prop) {\n <div class=\"row\">\n <div class=\"col-12\" style=\"margin-block-end: var(--ax-size-sm)\">\n <ax-check-box [(value)]=\"prop.allow\" label=\"{{ prop.title | trans }}\">\n </ax-check-box>\n </div>\n </div>\n }\n </ax-fieldset>\n </div>\n </div>\n </div>\n</ax-page-content>\n</ax-page>"
|
|
468
|
+
}]
|
|
469
|
+
}]
|
|
470
|
+
});
|
|
471
|
+
var AXWidgetHostComponent = class AXWidgetHostComponent {
|
|
472
|
+
ref;
|
|
473
|
+
rendererService;
|
|
474
|
+
cdr;
|
|
475
|
+
popup;
|
|
476
|
+
loadingService;
|
|
477
|
+
_widget;
|
|
478
|
+
get widget() {
|
|
479
|
+
return this._widget;
|
|
480
|
+
}
|
|
481
|
+
_hasProps = false;
|
|
482
|
+
_hasMenu = false;
|
|
483
|
+
provideValue;
|
|
484
|
+
get element() {
|
|
485
|
+
return this.ref.nativeElement;
|
|
486
|
+
}
|
|
487
|
+
configMenuItem = [{
|
|
488
|
+
icon: "far fa-ellipsis-h",
|
|
489
|
+
items: []
|
|
490
|
+
}];
|
|
491
|
+
onRemove = new EventEmitter();
|
|
492
|
+
onConfigChanged = new EventEmitter();
|
|
493
|
+
onResized = new EventEmitter();
|
|
494
|
+
onSave = new EventEmitter();
|
|
495
|
+
config;
|
|
496
|
+
vc;
|
|
497
|
+
readonly = false;
|
|
498
|
+
componentRef;
|
|
499
|
+
_loadingId;
|
|
500
|
+
_isLoading = false;
|
|
501
|
+
get isLoading() {
|
|
502
|
+
return this._isLoading;
|
|
503
|
+
}
|
|
504
|
+
set isLoading(v) {
|
|
505
|
+
this._isLoading = v;
|
|
506
|
+
if (this._loadingId && !v) {
|
|
507
|
+
this.loadingService.hide(this._loadingId);
|
|
508
|
+
this._loadingId = null;
|
|
509
|
+
}
|
|
510
|
+
if (v) {}
|
|
511
|
+
}
|
|
512
|
+
get isConfigured() {
|
|
513
|
+
return this._widget?.isConfigured || false;
|
|
514
|
+
}
|
|
515
|
+
constructor(ref, rendererService, cdr, popup, loadingService) {
|
|
516
|
+
this.ref = ref;
|
|
517
|
+
this.rendererService = rendererService;
|
|
518
|
+
this.cdr = cdr;
|
|
519
|
+
this.popup = popup;
|
|
520
|
+
this.loadingService = loadingService;
|
|
521
|
+
}
|
|
522
|
+
ngOnInit() {}
|
|
523
|
+
async ngAfterViewInit() {
|
|
524
|
+
let component;
|
|
525
|
+
if (typeof this.config.component === "string") component = (await this.rendererService.findLoadedComponentByRoute(this.config.component, 20))?.component;
|
|
526
|
+
else if (typeof this.config.component === "function") component = this.config.component;
|
|
527
|
+
if (component == null) {
|
|
528
|
+
console.error(`Invalid Widget Component!`, this.config);
|
|
529
|
+
this.onRemove.emit(this);
|
|
530
|
+
return;
|
|
531
|
+
}
|
|
532
|
+
this.componentRef = this.vc.createComponent(component);
|
|
533
|
+
this._widget = this.componentRef.instance;
|
|
534
|
+
this._widget.provideValue = this.provideValue;
|
|
535
|
+
if (this._widget.onBusyChanged) this._widget.onBusyChanged.subscribe((d) => {
|
|
536
|
+
if (!this._widget.widgetSize) this._widget.setValue("widgetSize", [this.sizeX, this.sizeY]);
|
|
537
|
+
else this.setSizeFromOptions();
|
|
538
|
+
this.cdr.detectChanges();
|
|
539
|
+
});
|
|
540
|
+
if (this._widget.onConfiguredChanged) this._widget.onConfiguredChanged.subscribe(() => {
|
|
541
|
+
this.setSizeFromOptions();
|
|
542
|
+
});
|
|
543
|
+
if (this.config.options) Object.assign(this._widget, this.config.options);
|
|
544
|
+
this._hasProps = AXPropertyDecorators.getProperties(this._widget).length > 0;
|
|
545
|
+
this.isLoading = false;
|
|
546
|
+
this.config["__meta__"].instance = this;
|
|
547
|
+
this._widget["__meta__"] = {};
|
|
548
|
+
this._widget["__meta__"].config = this.config;
|
|
549
|
+
this.configMenuItem[0].items.push({
|
|
550
|
+
name: "refresh",
|
|
551
|
+
icon: "far fa-undo",
|
|
552
|
+
text: AXTranslator.get("common.refresh"),
|
|
553
|
+
onClick: () => {
|
|
554
|
+
this?.widget?.refresh();
|
|
555
|
+
}
|
|
556
|
+
});
|
|
557
|
+
if (this._hasProps) this.configMenuItem[0].items.push({
|
|
558
|
+
name: "configs",
|
|
559
|
+
icon: "far fa-cogs",
|
|
560
|
+
text: AXTranslator.get("common.configs"),
|
|
561
|
+
onClick: () => {
|
|
562
|
+
this.openConfigDialog();
|
|
563
|
+
}
|
|
564
|
+
});
|
|
565
|
+
this.configMenuItem[0].items.push({
|
|
566
|
+
name: "save",
|
|
567
|
+
icon: "far fa-save",
|
|
568
|
+
text: AXTranslator.get("common.save-as"),
|
|
569
|
+
onClick: () => {
|
|
570
|
+
this.openSaveDialog();
|
|
571
|
+
}
|
|
572
|
+
});
|
|
573
|
+
this.configMenuItem[0].items.push({
|
|
574
|
+
name: "remove",
|
|
575
|
+
icon: "far fa-times",
|
|
576
|
+
style: "ax danger blank",
|
|
577
|
+
text: AXTranslator.get("common.remove"),
|
|
578
|
+
onClick: () => {
|
|
579
|
+
this.onRemove.emit(this);
|
|
580
|
+
}
|
|
581
|
+
});
|
|
582
|
+
this._hasMenu = this.configMenuItem[0].items.length > 0;
|
|
583
|
+
this.cdr.detectChanges();
|
|
584
|
+
}
|
|
585
|
+
sizeX = 1;
|
|
586
|
+
sizeY = 1;
|
|
587
|
+
col = 1;
|
|
588
|
+
row = 1;
|
|
589
|
+
setSizeFromOptions() {
|
|
590
|
+
this._widget.getValue("widgetSize").then((c) => {
|
|
591
|
+
const oldSizeX = this.sizeX;
|
|
592
|
+
const oldSizeY = this.sizeY;
|
|
593
|
+
if (c && Array.isArray(c) && (oldSizeX !== c[0] || oldSizeY !== c[1])) {
|
|
594
|
+
this.config.sizeX = this.sizeX = c[0];
|
|
595
|
+
this.config.sizeY = this.sizeY = c[1];
|
|
596
|
+
this.onResized.emit({
|
|
597
|
+
component: this._widget,
|
|
598
|
+
config: this.config
|
|
599
|
+
});
|
|
600
|
+
}
|
|
601
|
+
this.cdr.detectChanges();
|
|
602
|
+
});
|
|
603
|
+
}
|
|
604
|
+
remove(e) {
|
|
605
|
+
e.preventDefault();
|
|
606
|
+
e.stopPropagation();
|
|
607
|
+
if (!this.readonly) this.onRemove.emit(this);
|
|
608
|
+
return false;
|
|
609
|
+
}
|
|
610
|
+
handleConfig(e) {
|
|
611
|
+
e.preventDefault();
|
|
612
|
+
e.stopPropagation();
|
|
613
|
+
if (!this.readonly) this.openConfigDialog();
|
|
614
|
+
return false;
|
|
615
|
+
}
|
|
616
|
+
openConfigDialog() {
|
|
617
|
+
const ppp = this.getMergedProps();
|
|
618
|
+
this.popup.open(AXWidgetConfigComponent, {
|
|
619
|
+
title: AXTranslator.get("common.configs"),
|
|
620
|
+
size: "sm",
|
|
621
|
+
data: {
|
|
622
|
+
props: ppp.map((c) => ({
|
|
623
|
+
property: c.options,
|
|
624
|
+
value: this._widget[c.options.name]
|
|
625
|
+
})),
|
|
626
|
+
widget: this.widget
|
|
627
|
+
}
|
|
628
|
+
}).then((c) => {
|
|
629
|
+
if (c.data) {
|
|
630
|
+
if (!this.config.options) this.config.options = {};
|
|
631
|
+
c.data.forEach((p) => {
|
|
632
|
+
this._widget.setValue(p.property.name, p.value);
|
|
633
|
+
this.config.options[p.property.name] = p.value;
|
|
634
|
+
});
|
|
635
|
+
this.emitConfigChanged();
|
|
636
|
+
this._widget.redraw();
|
|
637
|
+
this.cdr.detectChanges();
|
|
638
|
+
}
|
|
639
|
+
});
|
|
640
|
+
}
|
|
641
|
+
openSaveDialog() {
|
|
642
|
+
const ppp = this.getMergedProps();
|
|
643
|
+
this.popup.open(AXWidgetSaveComponent, {
|
|
644
|
+
title: AXTranslator.get("common.save-as"),
|
|
645
|
+
size: "sm",
|
|
646
|
+
data: {
|
|
647
|
+
config: this.config,
|
|
648
|
+
props: ppp.map((c) => ({
|
|
649
|
+
property: c.options,
|
|
650
|
+
value: this._widget[c.options.name]
|
|
651
|
+
}))
|
|
652
|
+
}
|
|
653
|
+
}).then((c) => {
|
|
654
|
+
if (c.data) this.onSave.emit({
|
|
655
|
+
component: this._widget,
|
|
656
|
+
data: c.data
|
|
657
|
+
});
|
|
658
|
+
});
|
|
659
|
+
}
|
|
660
|
+
handleOptionClick(e) {
|
|
661
|
+
e.preventDefault();
|
|
662
|
+
e.stopPropagation();
|
|
663
|
+
this.openConfigDialog();
|
|
664
|
+
return false;
|
|
665
|
+
}
|
|
666
|
+
ngOnDestroy() {
|
|
667
|
+
this.vc.clear();
|
|
668
|
+
if (this.componentRef) this.componentRef.destroy();
|
|
669
|
+
}
|
|
670
|
+
getMergedProps() {
|
|
671
|
+
const ppp = AXObjectUtil.deepCopy(AXPropertyDecorators.getProperties(this._widget));
|
|
672
|
+
for (const key in this.config.props) if (Object.prototype.hasOwnProperty.call(this.config.props, key)) {
|
|
673
|
+
const newP = this.config.props[key];
|
|
674
|
+
const existPropDec = ppp.find((p) => p.property === key);
|
|
675
|
+
if (existPropDec) Object.assign(existPropDec.options, newP);
|
|
676
|
+
}
|
|
677
|
+
return ppp;
|
|
678
|
+
}
|
|
679
|
+
emitConfigChanged() {
|
|
680
|
+
this.onConfigChanged.emit({
|
|
681
|
+
component: this._widget,
|
|
682
|
+
config: this.config
|
|
683
|
+
});
|
|
684
|
+
}
|
|
685
|
+
static ɵfac = i0.ɵɵngDeclareFactory({
|
|
686
|
+
minVersion: "12.0.0",
|
|
687
|
+
version: "22.2.0",
|
|
688
|
+
ngImport: i0,
|
|
689
|
+
type: AXWidgetHostComponent,
|
|
690
|
+
deps: [
|
|
691
|
+
{ token: i0.ElementRef },
|
|
692
|
+
{ token: i2.AXRenderService },
|
|
693
|
+
{ token: i0.ChangeDetectorRef },
|
|
694
|
+
{ token: i1$1.AXPopupService },
|
|
695
|
+
{ token: i1$1.AXLoadingService }
|
|
696
|
+
],
|
|
697
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
698
|
+
});
|
|
699
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({
|
|
700
|
+
minVersion: "17.0.0",
|
|
701
|
+
version: "22.2.0",
|
|
702
|
+
type: AXWidgetHostComponent,
|
|
703
|
+
isStandalone: false,
|
|
704
|
+
selector: "ax-widget-host",
|
|
705
|
+
inputs: {
|
|
706
|
+
provideValue: "provideValue",
|
|
707
|
+
config: "config",
|
|
708
|
+
readonly: "readonly",
|
|
709
|
+
sizeX: "sizeX",
|
|
710
|
+
sizeY: "sizeY",
|
|
711
|
+
col: "col",
|
|
712
|
+
row: "row"
|
|
713
|
+
},
|
|
714
|
+
outputs: {
|
|
715
|
+
onRemove: "onRemove",
|
|
716
|
+
onConfigChanged: "onConfigChanged",
|
|
717
|
+
onResized: "onResized",
|
|
718
|
+
onSave: "onSave"
|
|
719
|
+
},
|
|
720
|
+
host: {
|
|
721
|
+
attributes: { "tabindex": "0" },
|
|
722
|
+
properties: {
|
|
723
|
+
"attr.data-size-x": "this.sizeX",
|
|
724
|
+
"attr.data-size-y": "this.sizeY",
|
|
725
|
+
"attr.data-col": "this.col",
|
|
726
|
+
"attr.data-row": "this.row"
|
|
727
|
+
},
|
|
728
|
+
classAttribute: "ax widget-host"
|
|
729
|
+
},
|
|
730
|
+
viewQueries: [{
|
|
731
|
+
propertyName: "vc",
|
|
732
|
+
first: true,
|
|
733
|
+
predicate: ["vc"],
|
|
734
|
+
descendants: true,
|
|
735
|
+
read: ViewContainerRef
|
|
736
|
+
}],
|
|
737
|
+
ngImport: i0,
|
|
738
|
+
template: "<div class='widget-container'>\n @if (!isConfigured) {\n <div class=\"widget-config-overlay\" (click)=\"handleConfig($event)\">\n <div class=\"widget-title\">{{config.title}}</div>\n <div class=\"widget-config-box\">\n <div class=\"config-title\">{{ 'widget-board.configure' | trans}}</div>\n @if (!readonly) {\n <div class=\"config-icon\"><i class=\"fas fa-cogs fa-5x\" aria-hidden=\"true\"></i></div>\n }\n </div>\n </div>\n }\n <div class='widget-edit-overlay' >\n <div class='widget-edit-menu'>\n @if (_hasProps) {\n <button class=\"widget-edit-menu-button\" (click)=\"handleConfig($event)\"\n (mousedown)=\"$event.stopPropagation()\" (mouseup)=\"$event.stopPropagation()\">\n <i class=\"far fa-cogs\" aria-hidden=\"true\"></i>\n </button>\n }\n <button class=\"widget-edit-menu-button\" (click)=\"remove($event)\" (mousedown)=\"$event.stopPropagation()\"\n (mouseup)=\"$event.stopPropagation()\">\n <i class=\"far fa-times\" aria-hidden=\"true\"></i>\n </button>\n </div>\n\n </div>\n @if (_hasMenu && !readonly) {\n <div class=\"widget-options-menu\" >\n <ax-menu [items]='configMenuItem' direction=\"horizontal\"></ax-menu>\n </div>\n }\n <!-- <ax-loading-panel [visible]=\"isBusy\">\n</ax-loading-panel> -->\n<div class=\"widget-content\">\n <ng-container #vc></ng-container>\n</div>\n</div>",
|
|
739
|
+
dependencies: [{
|
|
740
|
+
kind: "component",
|
|
741
|
+
type: i1$1.AXMenuComponent,
|
|
742
|
+
selector: "ax-menu",
|
|
743
|
+
inputs: [
|
|
744
|
+
"menuTemplate",
|
|
745
|
+
"rtl",
|
|
746
|
+
"size",
|
|
747
|
+
"selection",
|
|
748
|
+
"mode",
|
|
749
|
+
"target",
|
|
750
|
+
"floatAlignment",
|
|
751
|
+
"floatPlacemnet",
|
|
752
|
+
"direction",
|
|
753
|
+
"items"
|
|
754
|
+
],
|
|
755
|
+
outputs: ["onItemClick"]
|
|
756
|
+
}, {
|
|
757
|
+
kind: "pipe",
|
|
758
|
+
type: i2.AXTranslatorPipe,
|
|
759
|
+
name: "trans"
|
|
760
|
+
}],
|
|
761
|
+
changeDetection: i0.ChangeDetectionStrategy.OnPush,
|
|
762
|
+
encapsulation: i0.ViewEncapsulation.None
|
|
763
|
+
});
|
|
764
|
+
};
|
|
765
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
766
|
+
minVersion: "12.0.0",
|
|
767
|
+
version: "22.2.0",
|
|
768
|
+
ngImport: i0,
|
|
769
|
+
type: AXWidgetHostComponent,
|
|
770
|
+
decorators: [{
|
|
771
|
+
type: Component,
|
|
772
|
+
args: [{
|
|
773
|
+
selector: "ax-widget-host",
|
|
774
|
+
host: {
|
|
775
|
+
class: "ax widget-host",
|
|
776
|
+
tabindex: "0"
|
|
777
|
+
},
|
|
778
|
+
encapsulation: ViewEncapsulation.None,
|
|
779
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
780
|
+
standalone: false,
|
|
781
|
+
template: "<div class='widget-container'>\n @if (!isConfigured) {\n <div class=\"widget-config-overlay\" (click)=\"handleConfig($event)\">\n <div class=\"widget-title\">{{config.title}}</div>\n <div class=\"widget-config-box\">\n <div class=\"config-title\">{{ 'widget-board.configure' | trans}}</div>\n @if (!readonly) {\n <div class=\"config-icon\"><i class=\"fas fa-cogs fa-5x\" aria-hidden=\"true\"></i></div>\n }\n </div>\n </div>\n }\n <div class='widget-edit-overlay' >\n <div class='widget-edit-menu'>\n @if (_hasProps) {\n <button class=\"widget-edit-menu-button\" (click)=\"handleConfig($event)\"\n (mousedown)=\"$event.stopPropagation()\" (mouseup)=\"$event.stopPropagation()\">\n <i class=\"far fa-cogs\" aria-hidden=\"true\"></i>\n </button>\n }\n <button class=\"widget-edit-menu-button\" (click)=\"remove($event)\" (mousedown)=\"$event.stopPropagation()\"\n (mouseup)=\"$event.stopPropagation()\">\n <i class=\"far fa-times\" aria-hidden=\"true\"></i>\n </button>\n </div>\n\n </div>\n @if (_hasMenu && !readonly) {\n <div class=\"widget-options-menu\" >\n <ax-menu [items]='configMenuItem' direction=\"horizontal\"></ax-menu>\n </div>\n }\n <!-- <ax-loading-panel [visible]=\"isBusy\">\n</ax-loading-panel> -->\n<div class=\"widget-content\">\n <ng-container #vc></ng-container>\n</div>\n</div>"
|
|
782
|
+
}]
|
|
783
|
+
}],
|
|
784
|
+
ctorParameters: () => [
|
|
785
|
+
{ type: i0.ElementRef },
|
|
786
|
+
{ type: i2.AXRenderService },
|
|
787
|
+
{ type: i0.ChangeDetectorRef },
|
|
788
|
+
{ type: i1$1.AXPopupService },
|
|
789
|
+
{ type: i1$1.AXLoadingService }
|
|
790
|
+
],
|
|
791
|
+
propDecorators: {
|
|
792
|
+
provideValue: [{ type: Input }],
|
|
793
|
+
onRemove: [{ type: Output }],
|
|
794
|
+
onConfigChanged: [{ type: Output }],
|
|
795
|
+
onResized: [{ type: Output }],
|
|
796
|
+
onSave: [{ type: Output }],
|
|
797
|
+
config: [{ type: Input }],
|
|
798
|
+
vc: [{
|
|
799
|
+
type: ViewChild,
|
|
800
|
+
args: ["vc", { read: ViewContainerRef }]
|
|
801
|
+
}],
|
|
802
|
+
readonly: [{ type: Input }],
|
|
803
|
+
sizeX: [{
|
|
804
|
+
type: HostBinding,
|
|
805
|
+
args: ["attr.data-size-x"]
|
|
806
|
+
}, { type: Input }],
|
|
807
|
+
sizeY: [{
|
|
808
|
+
type: HostBinding,
|
|
809
|
+
args: ["attr.data-size-y"]
|
|
810
|
+
}, { type: Input }],
|
|
811
|
+
col: [{
|
|
812
|
+
type: HostBinding,
|
|
813
|
+
args: ["attr.data-col"]
|
|
814
|
+
}, { type: Input }],
|
|
815
|
+
row: [{
|
|
816
|
+
type: HostBinding,
|
|
817
|
+
args: ["attr.data-row"]
|
|
818
|
+
}, { type: Input }]
|
|
819
|
+
}
|
|
820
|
+
});
|
|
821
|
+
var AXWidgetBoardComponent = class AXWidgetBoardComponent {
|
|
822
|
+
ref;
|
|
823
|
+
zone;
|
|
824
|
+
cdr;
|
|
825
|
+
container;
|
|
826
|
+
widgetHosts;
|
|
827
|
+
widgets = [];
|
|
828
|
+
galleryItems = [];
|
|
829
|
+
tileSize = 80;
|
|
830
|
+
gapSize = 5;
|
|
831
|
+
readonly = false;
|
|
832
|
+
newWidget = null;
|
|
833
|
+
rtl;
|
|
834
|
+
_isInEditing = false;
|
|
835
|
+
isInEditing() {
|
|
836
|
+
return this._isInEditing;
|
|
837
|
+
}
|
|
838
|
+
isDragging = false;
|
|
839
|
+
dragItem;
|
|
840
|
+
saveSubject = new Subject();
|
|
841
|
+
provideValue;
|
|
842
|
+
DATA_COL = "data-col";
|
|
843
|
+
DATA_ROW = "data-row";
|
|
844
|
+
DATA_SIZE_X = "data-size-x";
|
|
845
|
+
DATA_SIZE_Y = "data-size-y";
|
|
846
|
+
DATA_OLD_COL = "data-old-col";
|
|
847
|
+
DATA_OLD_ROW = "data-old-row";
|
|
848
|
+
onConfigChanged = new EventEmitter();
|
|
849
|
+
onWidgetSave = new EventEmitter();
|
|
850
|
+
constructor(ref, zone, cdr) {
|
|
851
|
+
this.ref = ref;
|
|
852
|
+
this.zone = zone;
|
|
853
|
+
this.cdr = cdr;
|
|
854
|
+
}
|
|
855
|
+
ngOnInit() {
|
|
856
|
+
if (this.rtl == null) this.rtl = window.getComputedStyle(this.ref.nativeElement, null).getPropertyValue("direction") === "rtl";
|
|
857
|
+
this.saveSubject.pipe(debounceTime(750)).subscribe((value) => {
|
|
858
|
+
this.emitConfigChanged(value);
|
|
859
|
+
});
|
|
860
|
+
}
|
|
861
|
+
ngOnDestroy() {
|
|
862
|
+
this.saveSubject?.unsubscribe();
|
|
863
|
+
}
|
|
864
|
+
ngAfterViewInit() {
|
|
865
|
+
this.zone.runOutsideAngular((c) => {
|
|
866
|
+
const style = document.createElement("style");
|
|
867
|
+
style.type = "text/css";
|
|
868
|
+
this.ref.nativeElement.appendChild(style);
|
|
869
|
+
for (let i = 1; i <= 50; i++) {
|
|
870
|
+
style.innerHTML += `[${this.DATA_COL}="${i}"] { ${this.rtl ? "right" : "left"}: ${(i - 1) * (this.tileSize + this.gapSize)}px; }`;
|
|
871
|
+
style.innerHTML += `[${this.DATA_ROW}="${i}"] { top: ${(i - 1) * (this.tileSize + this.gapSize)}px; }`;
|
|
872
|
+
style.innerHTML += `[${this.DATA_SIZE_X}="${i}"] { width: ${i * this.tileSize + (i - 1) * this.gapSize}px; }`;
|
|
873
|
+
style.innerHTML += `[${this.DATA_SIZE_Y}="${i}"] { height: ${i * this.tileSize + (i - 1) * this.gapSize}px; }`;
|
|
874
|
+
}
|
|
875
|
+
});
|
|
876
|
+
}
|
|
877
|
+
calcGridSize() {
|
|
878
|
+
this.zone.runOutsideAngular(() => {
|
|
879
|
+
const width = Math.max(...this.widgets.map((c) => c.col + c.sizeX - 1)) * (this.tileSize + this.gapSize);
|
|
880
|
+
const height = Math.max(...this.widgets.map((c) => c.row + c.sizeY - 1)) * (this.tileSize + this.gapSize);
|
|
881
|
+
this.container.nativeElement.style.width = width + "px";
|
|
882
|
+
this.container.nativeElement.style.height = height + "px";
|
|
883
|
+
});
|
|
884
|
+
}
|
|
885
|
+
toggleEdit() {
|
|
886
|
+
this._isInEditing ? this.finishEdit() : this.startEdit();
|
|
887
|
+
}
|
|
888
|
+
dragStart(e) {
|
|
889
|
+
e.preventDefault();
|
|
890
|
+
e.stopPropagation();
|
|
891
|
+
this.zone.runOutsideAngular(() => {
|
|
892
|
+
if (this._isInEditing && e.which === 1) {
|
|
893
|
+
this.dragItem = e.currentTarget;
|
|
894
|
+
this.dragItem.setAttribute("data-x-offset", (this.dragItem.offsetLeft - e.clientX).toString());
|
|
895
|
+
this.dragItem.setAttribute("data-y-offset", (this.dragItem.offsetTop - e.clientY).toString());
|
|
896
|
+
this.dragItem.classList.add("widget-dragging");
|
|
897
|
+
this.dragItem.classList.remove("animate__animated", "animate__pulse");
|
|
898
|
+
}
|
|
899
|
+
});
|
|
900
|
+
return false;
|
|
901
|
+
}
|
|
902
|
+
removePositionData() {
|
|
903
|
+
this.zone.runOutsideAngular(() => {
|
|
904
|
+
if (this.dragItem && this._isInEditing && this.dragItem.getAttribute(this.DATA_OLD_COL) == null) {
|
|
905
|
+
this.dragItem.setAttribute(this.DATA_OLD_COL, this.dragItem.getAttribute(this.DATA_COL));
|
|
906
|
+
this.dragItem.setAttribute(this.DATA_OLD_ROW, this.dragItem.getAttribute(this.DATA_ROW));
|
|
907
|
+
this.dragItem.removeAttribute(this.DATA_COL);
|
|
908
|
+
this.dragItem.removeAttribute(this.DATA_ROW);
|
|
909
|
+
}
|
|
910
|
+
});
|
|
911
|
+
}
|
|
912
|
+
resetPositionData() {
|
|
913
|
+
this.zone.runOutsideAngular(() => {
|
|
914
|
+
if (this.dragItem && this._isInEditing) this.setPosition(this.dragItem, this.dragItem.getAttribute(this.DATA_OLD_COL), this.dragItem.getAttribute(this.DATA_OLD_ROW));
|
|
915
|
+
});
|
|
916
|
+
}
|
|
917
|
+
setPosition(element, col, row) {
|
|
918
|
+
this.zone.runOutsideAngular(() => {
|
|
919
|
+
element.setAttribute(this.DATA_COL, col);
|
|
920
|
+
element.setAttribute(this.DATA_ROW, row);
|
|
921
|
+
element.removeAttribute(this.DATA_OLD_COL);
|
|
922
|
+
element.removeAttribute(this.DATA_OLD_ROW);
|
|
923
|
+
element.style.removeProperty("top");
|
|
924
|
+
element.style.removeProperty("left");
|
|
925
|
+
const widget = this.widgets.find((c) => c["__meta__"].instance.element === element);
|
|
926
|
+
widget.col = Number(col);
|
|
927
|
+
widget.row = Number(row);
|
|
928
|
+
});
|
|
929
|
+
}
|
|
930
|
+
drag(e) {
|
|
931
|
+
e.preventDefault();
|
|
932
|
+
e.stopPropagation();
|
|
933
|
+
this.zone.runOutsideAngular(() => {
|
|
934
|
+
if (this.dragItem && this._isInEditing) {
|
|
935
|
+
this.isDragging = true;
|
|
936
|
+
this.addPlaceholder();
|
|
937
|
+
const xOffset = Number(this.dragItem.getAttribute("data-x-offset"));
|
|
938
|
+
const yOffset = Number(this.dragItem.getAttribute("data-y-offset"));
|
|
939
|
+
this.dragItem.style.left = e.clientX + xOffset + "px";
|
|
940
|
+
this.dragItem.style.top = e.clientY + yOffset + "px";
|
|
941
|
+
this.detectBestPlacement();
|
|
942
|
+
this.removePositionData();
|
|
943
|
+
}
|
|
944
|
+
});
|
|
945
|
+
return false;
|
|
946
|
+
}
|
|
947
|
+
dragEnd(e) {
|
|
948
|
+
this.zone.runOutsideAngular(() => {
|
|
949
|
+
if (this.dragItem && this._isInEditing && this.isDragging) {
|
|
950
|
+
this.dragItem.classList.remove("widget-dragging");
|
|
951
|
+
this.dragItem.classList.add("animate__animated", "animate__pulse");
|
|
952
|
+
const p = this.container.nativeElement.querySelector(".widget-blank-placeholder");
|
|
953
|
+
if (this.newWidget) {
|
|
954
|
+
const w = {
|
|
955
|
+
uniqueName: this.newWidget.uniqueName,
|
|
956
|
+
component: this.newWidget.component,
|
|
957
|
+
title: this.newWidget.title,
|
|
958
|
+
options: this.newWidget.options,
|
|
959
|
+
sizeX: this.newWidget.sizeX,
|
|
960
|
+
sizeY: this.newWidget.sizeY,
|
|
961
|
+
col: Number(p.getAttribute(this.DATA_COL)),
|
|
962
|
+
row: Number(p.getAttribute(this.DATA_ROW))
|
|
963
|
+
};
|
|
964
|
+
this.widgets.push(w);
|
|
965
|
+
this.newWidget = null;
|
|
966
|
+
this.container.nativeElement.removeChild(this.dragItem);
|
|
967
|
+
this.zone.run(() => {
|
|
968
|
+
this.cdr.detectChanges();
|
|
969
|
+
this.calcGridSize();
|
|
970
|
+
setTimeout(() => {
|
|
971
|
+
w["__meta__"].instance.element.addEventListener("mousedown", this.dragStart.bind(this), false);
|
|
972
|
+
}, 1e3);
|
|
973
|
+
});
|
|
974
|
+
} else if (p) this.setPosition(this.dragItem, p.getAttribute(this.DATA_COL), p.getAttribute(this.DATA_ROW));
|
|
975
|
+
else this.setPosition(this.dragItem, this.dragItem.getAttribute(this.DATA_OLD_COL), this.dragItem.getAttribute(this.DATA_OLD_ROW));
|
|
976
|
+
this.removePlaceholder();
|
|
977
|
+
this.dragItem = null;
|
|
978
|
+
this.calcGridSize();
|
|
979
|
+
this.saveSubject.next("config");
|
|
980
|
+
}
|
|
981
|
+
this.isDragging = false;
|
|
982
|
+
});
|
|
983
|
+
}
|
|
984
|
+
detectFirstEmptySlot(w) {
|
|
985
|
+
const xTile = Math.floor(this.ref.nativeElement.parentElement.offsetWidth / this.tileSize);
|
|
986
|
+
for (let j = 1; j <= 100; j++) for (let i = 1; i <= xTile - w.sizeX; i++) {
|
|
987
|
+
const rec = new AXClientRec({
|
|
988
|
+
left: i,
|
|
989
|
+
top: j,
|
|
990
|
+
width: w.sizeX,
|
|
991
|
+
height: w.sizeY
|
|
992
|
+
});
|
|
993
|
+
if (this.widgets.filter((c) => c !== w).find((c) => rec.intersect({
|
|
994
|
+
left: c.col,
|
|
995
|
+
top: c.row,
|
|
996
|
+
width: c.sizeX,
|
|
997
|
+
height: c.sizeY
|
|
998
|
+
})) == null) {
|
|
999
|
+
w.col = i;
|
|
1000
|
+
w.row = j;
|
|
1001
|
+
return;
|
|
1002
|
+
}
|
|
1003
|
+
}
|
|
1004
|
+
}
|
|
1005
|
+
detectBestPlacement() {
|
|
1006
|
+
this.zone.runOutsideAngular(() => {
|
|
1007
|
+
const p = this.container.nativeElement.querySelector(".widget-blank-placeholder");
|
|
1008
|
+
let col = Math.ceil(this.dragItem.offsetLeft / this.tileSize);
|
|
1009
|
+
if (this.rtl) col = Math.ceil((this.container.nativeElement.clientWidth - (this.dragItem.offsetLeft + this.dragItem.clientWidth)) / this.tileSize);
|
|
1010
|
+
let row = Math.ceil(this.dragItem.offsetTop / this.tileSize);
|
|
1011
|
+
if (col < 1) col = 1;
|
|
1012
|
+
if (row < 1) row = 1;
|
|
1013
|
+
const widgets = Array.from(this.ref.nativeElement.querySelectorAll(".widget-host")).map((c) => c);
|
|
1014
|
+
p.setAttribute(this.DATA_COL, col.toString());
|
|
1015
|
+
p.setAttribute(this.DATA_ROW, row.toString());
|
|
1016
|
+
if (widgets.filter((c) => c !== this.dragItem).some((c) => AXHtmlUtil.collision(c, this.dragItem))) this.removePlaceholder();
|
|
1017
|
+
});
|
|
1018
|
+
}
|
|
1019
|
+
addPlaceholder() {
|
|
1020
|
+
this.zone.runOutsideAngular(() => {
|
|
1021
|
+
this.removePlaceholder();
|
|
1022
|
+
if (this.dragItem) {
|
|
1023
|
+
const p = document.createElement("div");
|
|
1024
|
+
p.classList.add("widget-blank-placeholder");
|
|
1025
|
+
p.setAttribute(this.DATA_COL, this.dragItem.getAttribute(this.DATA_COL));
|
|
1026
|
+
p.setAttribute(this.DATA_ROW, this.dragItem.getAttribute(this.DATA_ROW));
|
|
1027
|
+
p.setAttribute(this.DATA_SIZE_X, this.dragItem.getAttribute(this.DATA_SIZE_X));
|
|
1028
|
+
p.setAttribute(this.DATA_SIZE_Y, this.dragItem.getAttribute(this.DATA_SIZE_Y));
|
|
1029
|
+
this.container.nativeElement.appendChild(p);
|
|
1030
|
+
}
|
|
1031
|
+
});
|
|
1032
|
+
}
|
|
1033
|
+
removePlaceholder() {
|
|
1034
|
+
this.container.nativeElement.querySelector(".widget-blank-placeholder")?.remove();
|
|
1035
|
+
}
|
|
1036
|
+
startEdit() {
|
|
1037
|
+
this._isInEditing = true;
|
|
1038
|
+
this.calcGridSize();
|
|
1039
|
+
this.ref.nativeElement.classList.add("grid-background");
|
|
1040
|
+
const bg = this.ref.nativeElement;
|
|
1041
|
+
bg.style.setProperty("background-position", `${this.rtl ? "right" : "left"} top`);
|
|
1042
|
+
const pattern = `url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="${this.tileSize + this.gapSize}" height="${this.tileSize + this.gapSize}"> <rect style="fill: %23dadada" x="${this.rtl ? this.gapSize : 0}" width="${this.tileSize}" height="${this.tileSize}" y="0"></rect></svg>')`;
|
|
1043
|
+
bg.style.setProperty("background-image", pattern);
|
|
1044
|
+
Array.from(this.ref.nativeElement.querySelectorAll(".widget-host")).forEach((w) => {
|
|
1045
|
+
w.addEventListener("mousedown", this.dragStart.bind(this), false);
|
|
1046
|
+
});
|
|
1047
|
+
this.ref.nativeElement.addEventListener("mousemove", this.drag.bind(this), false);
|
|
1048
|
+
this.ref.nativeElement.addEventListener("mouseup", this.dragEnd.bind(this), false);
|
|
1049
|
+
}
|
|
1050
|
+
finishEdit() {
|
|
1051
|
+
this.ref.nativeElement.classList.remove("grid-background");
|
|
1052
|
+
this.ref.nativeElement.style.removeProperty("background-image");
|
|
1053
|
+
this._isInEditing = false;
|
|
1054
|
+
Array.from(this.ref.nativeElement.querySelectorAll(".widget-host")).forEach((w) => {
|
|
1055
|
+
w.removeEventListener("mousedown", this.dragStart.bind(this), false);
|
|
1056
|
+
});
|
|
1057
|
+
this.ref.nativeElement.removeEventListener("mousemove", this.drag.bind(this), false);
|
|
1058
|
+
this.ref.nativeElement.removeEventListener("mouseup", this.dragEnd.bind(this), false);
|
|
1059
|
+
this.saveSubject.next("config");
|
|
1060
|
+
}
|
|
1061
|
+
addWidget(widget) {
|
|
1062
|
+
this.zone.runOutsideAngular(() => {
|
|
1063
|
+
this.newWidget = {
|
|
1064
|
+
uniqueName: widget.uniqueName,
|
|
1065
|
+
component: widget.component,
|
|
1066
|
+
title: widget.title,
|
|
1067
|
+
col: 1,
|
|
1068
|
+
row: 1,
|
|
1069
|
+
sizeX: widget.sizeX,
|
|
1070
|
+
sizeY: widget.sizeY,
|
|
1071
|
+
options: widget.options,
|
|
1072
|
+
props: widget.props
|
|
1073
|
+
};
|
|
1074
|
+
this.detectFirstEmptySlot(this.newWidget);
|
|
1075
|
+
const w = {
|
|
1076
|
+
uniqueName: this.newWidget.uniqueName,
|
|
1077
|
+
component: this.newWidget.component,
|
|
1078
|
+
title: this.newWidget.title,
|
|
1079
|
+
options: this.newWidget.options,
|
|
1080
|
+
props: this.newWidget.props,
|
|
1081
|
+
sizeX: this.newWidget.sizeX,
|
|
1082
|
+
sizeY: this.newWidget.sizeY,
|
|
1083
|
+
col: this.newWidget.col,
|
|
1084
|
+
row: this.newWidget.row
|
|
1085
|
+
};
|
|
1086
|
+
this.widgets.push(w);
|
|
1087
|
+
this.newWidget = null;
|
|
1088
|
+
this.zone.run(() => {
|
|
1089
|
+
this.cdr.detectChanges();
|
|
1090
|
+
this.calcGridSize();
|
|
1091
|
+
this.emitConfigChanged("add");
|
|
1092
|
+
setTimeout(() => {
|
|
1093
|
+
w["__meta__"].instance.element.addEventListener("mousedown", this.dragStart.bind(this), false);
|
|
1094
|
+
}, 1e3);
|
|
1095
|
+
});
|
|
1096
|
+
});
|
|
1097
|
+
}
|
|
1098
|
+
handleOnRemove(w) {
|
|
1099
|
+
w.element.classList.add("animate__animated", "animate__zoomOut");
|
|
1100
|
+
w.element.addEventListener("animationend", () => {
|
|
1101
|
+
this.widgets = this.widgets.filter((c) => c.__meta__.id !== w.config.__meta__.id);
|
|
1102
|
+
this.cdr.detectChanges();
|
|
1103
|
+
this.calcGridSize();
|
|
1104
|
+
this.emitConfigChanged("remove");
|
|
1105
|
+
});
|
|
1106
|
+
}
|
|
1107
|
+
handleOnSave(e) {
|
|
1108
|
+
this.onWidgetSave.emit(e);
|
|
1109
|
+
}
|
|
1110
|
+
trackByFn(index, item) {
|
|
1111
|
+
if (!item["__meta__"]?.id) {
|
|
1112
|
+
item["__meta__"] = {};
|
|
1113
|
+
item["__meta__"].id = AXHtmlUtil.getUID();
|
|
1114
|
+
}
|
|
1115
|
+
return item["__meta__"]?.id;
|
|
1116
|
+
}
|
|
1117
|
+
load(widgets) {
|
|
1118
|
+
this.clear();
|
|
1119
|
+
return new Promise((resolve, reject) => {
|
|
1120
|
+
if (widgets) {
|
|
1121
|
+
const loadedWidgets = [];
|
|
1122
|
+
if (typeof widgets === "string") try {
|
|
1123
|
+
loadedWidgets.push(...JSON.parse(widgets));
|
|
1124
|
+
this.emitConfigChanged("load");
|
|
1125
|
+
} catch (error) {
|
|
1126
|
+
reject("Invalid widget json data!");
|
|
1127
|
+
}
|
|
1128
|
+
else {
|
|
1129
|
+
loadedWidgets.push(...widgets);
|
|
1130
|
+
this.emitConfigChanged("load");
|
|
1131
|
+
}
|
|
1132
|
+
let intervalId = -1;
|
|
1133
|
+
const loadFunc = () => {
|
|
1134
|
+
if (this.galleryItems && this.galleryItems.length > 0) {
|
|
1135
|
+
loadedWidgets.forEach((w) => {
|
|
1136
|
+
const gitem = this.galleryItems.find((c) => c.uniqueName === w.uniqueName);
|
|
1137
|
+
if (gitem) {
|
|
1138
|
+
w.component = gitem.component;
|
|
1139
|
+
if (gitem.props) w.props = JSON.parse(JSON.stringify(gitem.props));
|
|
1140
|
+
}
|
|
1141
|
+
});
|
|
1142
|
+
this.widgets.push(...loadedWidgets);
|
|
1143
|
+
this.emitConfigChanged("load");
|
|
1144
|
+
window.clearInterval(intervalId);
|
|
1145
|
+
this.cdr.detectChanges();
|
|
1146
|
+
resolve();
|
|
1147
|
+
}
|
|
1148
|
+
};
|
|
1149
|
+
intervalId = window.setInterval(loadFunc, 200);
|
|
1150
|
+
} else resolve();
|
|
1151
|
+
});
|
|
1152
|
+
}
|
|
1153
|
+
clear() {
|
|
1154
|
+
if (this.widgets.length) {
|
|
1155
|
+
this.widgets = [];
|
|
1156
|
+
this.cdr.detectChanges();
|
|
1157
|
+
this.saveSubject.next("clear");
|
|
1158
|
+
}
|
|
1159
|
+
}
|
|
1160
|
+
save() {
|
|
1161
|
+
const obj = this.widgets.map((c) => ({
|
|
1162
|
+
uniqueName: c.uniqueName,
|
|
1163
|
+
component: c.component,
|
|
1164
|
+
title: c.title,
|
|
1165
|
+
sizeX: c.sizeX,
|
|
1166
|
+
sizeY: c.sizeY,
|
|
1167
|
+
col: c.col,
|
|
1168
|
+
row: c.row,
|
|
1169
|
+
options: c.options,
|
|
1170
|
+
props: c.props
|
|
1171
|
+
}));
|
|
1172
|
+
return Promise.resolve(JSON.stringify(obj));
|
|
1173
|
+
}
|
|
1174
|
+
refresh() {
|
|
1175
|
+
this.widgetHosts.forEach((host) => {
|
|
1176
|
+
host.widget.refresh();
|
|
1177
|
+
});
|
|
1178
|
+
}
|
|
1179
|
+
handleOnConfigChanged(e) {
|
|
1180
|
+
this.cdr.detectChanges();
|
|
1181
|
+
this.saveSubject.next("config");
|
|
1182
|
+
}
|
|
1183
|
+
handleOnResizedChanged(e) {
|
|
1184
|
+
this.detectFirstEmptySlot(e.config);
|
|
1185
|
+
this.cdr.detectChanges();
|
|
1186
|
+
this.saveSubject.next("config");
|
|
1187
|
+
}
|
|
1188
|
+
emitConfigChanged(mode) {
|
|
1189
|
+
this.onConfigChanged.emit({
|
|
1190
|
+
component: this,
|
|
1191
|
+
mode
|
|
1192
|
+
});
|
|
1193
|
+
}
|
|
1194
|
+
static ɵfac = i0.ɵɵngDeclareFactory({
|
|
1195
|
+
minVersion: "12.0.0",
|
|
1196
|
+
version: "22.2.0",
|
|
1197
|
+
ngImport: i0,
|
|
1198
|
+
type: AXWidgetBoardComponent,
|
|
1199
|
+
deps: [
|
|
1200
|
+
{ token: i0.ElementRef },
|
|
1201
|
+
{ token: i0.NgZone },
|
|
1202
|
+
{ token: i0.ChangeDetectorRef }
|
|
1203
|
+
],
|
|
1204
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
1205
|
+
});
|
|
1206
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({
|
|
1207
|
+
minVersion: "17.0.0",
|
|
1208
|
+
version: "22.2.0",
|
|
1209
|
+
type: AXWidgetBoardComponent,
|
|
1210
|
+
isStandalone: false,
|
|
1211
|
+
selector: "ax-widget-board",
|
|
1212
|
+
inputs: {
|
|
1213
|
+
galleryItems: "galleryItems",
|
|
1214
|
+
tileSize: "tileSize",
|
|
1215
|
+
gapSize: "gapSize",
|
|
1216
|
+
readonly: "readonly",
|
|
1217
|
+
provideValue: "provideValue"
|
|
1218
|
+
},
|
|
1219
|
+
outputs: {
|
|
1220
|
+
onConfigChanged: "onConfigChanged",
|
|
1221
|
+
onWidgetSave: "onWidgetSave"
|
|
1222
|
+
},
|
|
1223
|
+
host: { classAttribute: "ax widget-board" },
|
|
1224
|
+
viewQueries: [{
|
|
1225
|
+
propertyName: "container",
|
|
1226
|
+
first: true,
|
|
1227
|
+
predicate: ["container"],
|
|
1228
|
+
descendants: true
|
|
1229
|
+
}, {
|
|
1230
|
+
propertyName: "widgetHosts",
|
|
1231
|
+
predicate: AXWidgetHostComponent,
|
|
1232
|
+
descendants: true
|
|
1233
|
+
}],
|
|
1234
|
+
ngImport: i0,
|
|
1235
|
+
template: "<div class=\"widgets-container\" [class.rtl]=\"rtl\" #container>\n @for (w of widgets; track trackByFn($index, w)) {\n <ax-widget-host [config]='w' [sizeX]=\"w.sizeX\" [readonly]=\"readonly || w.readonly\"\n [sizeY]=\"w.sizeY\" [col]=\"w.col\" [row]=\"w.row\" (onRemove)=\"handleOnRemove($event)\" (onSave)=\"handleOnSave($event)\"\n (onConfigChanged)=\"handleOnConfigChanged($event)\" (onResized)=\"handleOnResizedChanged($event)\"\n [provideValue]=\"provideValue\">\n </ax-widget-host>\n }\n</div>\n",
|
|
1236
|
+
styles: [".widget-board{overflow:scroll;scrollbar-width:thin;display:inline-block;margin:15px 20px;min-width:calc(100% - 18px);min-height:calc(100% - 18px);--animate-duration: .5s;background-repeat:no-repeat}.widget-board.grid-background{background-repeat:repeat!important}.widget-board.grid-background .widgets-container .widget-host{touch-action:none}.widget-board.grid-background .widgets-container .widget-host .widget-edit-overlay{display:block;cursor:move}.widget-board.grid-background .widgets-container .widget-host.widget-dragging{z-index:1000}.widget-board.grid-background .widgets-container .widget-host:focus{outline-width:1px;outline-style:solid;outline-color:var(--ax-primary-color)}.widget-board.grid-background .widgets-container .widget-host{touch-action:none;-webkit-user-select:none;user-select:none}.widget-board.grid-background .widget-blank-placeholder{background:var(--ax-primary-trans-light-color);position:absolute}.widget-board .widgets-container{position:relative;touch-action:none}.widget-board .widgets-container.rtl .widget-host .widget-options-menu{right:unset!important;left:0!important}.widget-board .widgets-container .widget-host{position:absolute;background:#fff;box-shadow:2px 2px 3px #dadada}.widget-board .widgets-container .widget-host .widget-content{width:100%;height:100%;display:flex;flex-direction:column}.widget-board .widgets-container .widget-host .widget-content .widget-title{padding:var(--ax-size-md);text-align:start;font-size:1.5em;position:absolute}.widget-board .widgets-container .widget-host .widget-edit-loading{display:none;background:#ffffffd9;position:absolute;width:100%;height:100%;top:0;left:0;z-index:2;display:flex}.widget-board .widgets-container .widget-host .widget-config-overlay{position:absolute;background:#fff;width:100%;height:100%;top:0;left:0;z-index:1;padding:var(--ax-size-md);cursor:pointer}.widget-board .widgets-container .widget-host .widget-config-overlay:hover .widget-title{text-decoration:underline}.widget-board .widgets-container .widget-host .widget-config-overlay .widget-title{text-align:start;font-size:1.5em}.widget-board .widgets-container .widget-host .widget-config-overlay .widget-config-box{align-self:center;text-align:center;position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);color:var(--ax-gray-dark-color)}.widget-board .widgets-container .widget-host .widget-config-overlay .widget-config-box .config-title{font-size:1.2em;margin-bottom:var(--ax-size-md)}.widget-board .widgets-container .widget-host .widget-edit-overlay{display:none;background:#ffffff80;position:absolute;width:100%;height:100%;top:0;left:0;z-index:10}.widget-board .widgets-container .widget-host .widget-edit-overlay .widget-edit-menu{margin:6px;text-align:end;float:inline-end;opacity:1;transition:opacity 1s ease}.widget-board .widgets-container .widget-host .widget-edit-overlay .widget-edit-menu .widget-edit-menu-button{display:inline-block;background-color:#f0f0f0;border-radius:1px;border:2px solid #fff;box-sizing:border-box;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;padding:0;height:32px;width:32px;cursor:pointer;color:#666}.widget-board .widgets-container .widget-host .widget-edit-overlay .widget-edit-menu .widget-edit-menu-button:hover{border-color:#a6a6a6;background-color:#c8c8c8}.widget-board .widgets-container .widget-host .widget-options-menu{display:none;position:absolute;top:0;right:0;z-index:2;cursor:pointer;padding:2px 5px}.widget-board .widgets-container .widget-host .widget-options-menu:hover{background-color:#f0f0f0}.widget-board .widgets-container .widget-host .widget-container{padding:1px;height:100%}.widget-board .widgets-container .widget-host .widget-container:hover .widget-options-menu{display:block}\n"],
|
|
1237
|
+
dependencies: [{
|
|
1238
|
+
kind: "component",
|
|
1239
|
+
type: AXWidgetHostComponent,
|
|
1240
|
+
selector: "ax-widget-host",
|
|
1241
|
+
inputs: [
|
|
1242
|
+
"provideValue",
|
|
1243
|
+
"config",
|
|
1244
|
+
"readonly",
|
|
1245
|
+
"sizeX",
|
|
1246
|
+
"sizeY",
|
|
1247
|
+
"col",
|
|
1248
|
+
"row"
|
|
1249
|
+
],
|
|
1250
|
+
outputs: [
|
|
1251
|
+
"onRemove",
|
|
1252
|
+
"onConfigChanged",
|
|
1253
|
+
"onResized",
|
|
1254
|
+
"onSave"
|
|
1255
|
+
]
|
|
1256
|
+
}],
|
|
1257
|
+
changeDetection: i0.ChangeDetectionStrategy.OnPush,
|
|
1258
|
+
encapsulation: i0.ViewEncapsulation.None
|
|
1259
|
+
});
|
|
1260
|
+
};
|
|
1261
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
1262
|
+
minVersion: "12.0.0",
|
|
1263
|
+
version: "22.2.0",
|
|
1264
|
+
ngImport: i0,
|
|
1265
|
+
type: AXWidgetBoardComponent,
|
|
1266
|
+
decorators: [{
|
|
1267
|
+
type: Component,
|
|
1268
|
+
args: [{
|
|
1269
|
+
selector: "ax-widget-board",
|
|
1270
|
+
host: { class: "ax widget-board" },
|
|
1271
|
+
encapsulation: ViewEncapsulation.None,
|
|
1272
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
1273
|
+
standalone: false,
|
|
1274
|
+
template: "<div class=\"widgets-container\" [class.rtl]=\"rtl\" #container>\n @for (w of widgets; track trackByFn($index, w)) {\n <ax-widget-host [config]='w' [sizeX]=\"w.sizeX\" [readonly]=\"readonly || w.readonly\"\n [sizeY]=\"w.sizeY\" [col]=\"w.col\" [row]=\"w.row\" (onRemove)=\"handleOnRemove($event)\" (onSave)=\"handleOnSave($event)\"\n (onConfigChanged)=\"handleOnConfigChanged($event)\" (onResized)=\"handleOnResizedChanged($event)\"\n [provideValue]=\"provideValue\">\n </ax-widget-host>\n }\n</div>\n",
|
|
1275
|
+
styles: [".widget-board{overflow:scroll;scrollbar-width:thin;display:inline-block;margin:15px 20px;min-width:calc(100% - 18px);min-height:calc(100% - 18px);--animate-duration: .5s;background-repeat:no-repeat}.widget-board.grid-background{background-repeat:repeat!important}.widget-board.grid-background .widgets-container .widget-host{touch-action:none}.widget-board.grid-background .widgets-container .widget-host .widget-edit-overlay{display:block;cursor:move}.widget-board.grid-background .widgets-container .widget-host.widget-dragging{z-index:1000}.widget-board.grid-background .widgets-container .widget-host:focus{outline-width:1px;outline-style:solid;outline-color:var(--ax-primary-color)}.widget-board.grid-background .widgets-container .widget-host{touch-action:none;-webkit-user-select:none;user-select:none}.widget-board.grid-background .widget-blank-placeholder{background:var(--ax-primary-trans-light-color);position:absolute}.widget-board .widgets-container{position:relative;touch-action:none}.widget-board .widgets-container.rtl .widget-host .widget-options-menu{right:unset!important;left:0!important}.widget-board .widgets-container .widget-host{position:absolute;background:#fff;box-shadow:2px 2px 3px #dadada}.widget-board .widgets-container .widget-host .widget-content{width:100%;height:100%;display:flex;flex-direction:column}.widget-board .widgets-container .widget-host .widget-content .widget-title{padding:var(--ax-size-md);text-align:start;font-size:1.5em;position:absolute}.widget-board .widgets-container .widget-host .widget-edit-loading{display:none;background:#ffffffd9;position:absolute;width:100%;height:100%;top:0;left:0;z-index:2;display:flex}.widget-board .widgets-container .widget-host .widget-config-overlay{position:absolute;background:#fff;width:100%;height:100%;top:0;left:0;z-index:1;padding:var(--ax-size-md);cursor:pointer}.widget-board .widgets-container .widget-host .widget-config-overlay:hover .widget-title{text-decoration:underline}.widget-board .widgets-container .widget-host .widget-config-overlay .widget-title{text-align:start;font-size:1.5em}.widget-board .widgets-container .widget-host .widget-config-overlay .widget-config-box{align-self:center;text-align:center;position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);color:var(--ax-gray-dark-color)}.widget-board .widgets-container .widget-host .widget-config-overlay .widget-config-box .config-title{font-size:1.2em;margin-bottom:var(--ax-size-md)}.widget-board .widgets-container .widget-host .widget-edit-overlay{display:none;background:#ffffff80;position:absolute;width:100%;height:100%;top:0;left:0;z-index:10}.widget-board .widgets-container .widget-host .widget-edit-overlay .widget-edit-menu{margin:6px;text-align:end;float:inline-end;opacity:1;transition:opacity 1s ease}.widget-board .widgets-container .widget-host .widget-edit-overlay .widget-edit-menu .widget-edit-menu-button{display:inline-block;background-color:#f0f0f0;border-radius:1px;border:2px solid #fff;box-sizing:border-box;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;padding:0;height:32px;width:32px;cursor:pointer;color:#666}.widget-board .widgets-container .widget-host .widget-edit-overlay .widget-edit-menu .widget-edit-menu-button:hover{border-color:#a6a6a6;background-color:#c8c8c8}.widget-board .widgets-container .widget-host .widget-options-menu{display:none;position:absolute;top:0;right:0;z-index:2;cursor:pointer;padding:2px 5px}.widget-board .widgets-container .widget-host .widget-options-menu:hover{background-color:#f0f0f0}.widget-board .widgets-container .widget-host .widget-container{padding:1px;height:100%}.widget-board .widgets-container .widget-host .widget-container:hover .widget-options-menu{display:block}\n"]
|
|
1276
|
+
}]
|
|
1277
|
+
}],
|
|
1278
|
+
ctorParameters: () => [
|
|
1279
|
+
{ type: i0.ElementRef },
|
|
1280
|
+
{ type: i0.NgZone },
|
|
1281
|
+
{ type: i0.ChangeDetectorRef }
|
|
1282
|
+
],
|
|
1283
|
+
propDecorators: {
|
|
1284
|
+
container: [{
|
|
1285
|
+
type: ViewChild,
|
|
1286
|
+
args: ["container"]
|
|
1287
|
+
}],
|
|
1288
|
+
widgetHosts: [{
|
|
1289
|
+
type: ViewChildren,
|
|
1290
|
+
args: [AXWidgetHostComponent]
|
|
1291
|
+
}],
|
|
1292
|
+
galleryItems: [{ type: Input }],
|
|
1293
|
+
tileSize: [{ type: Input }],
|
|
1294
|
+
gapSize: [{ type: Input }],
|
|
1295
|
+
readonly: [{ type: Input }],
|
|
1296
|
+
provideValue: [{ type: Input }],
|
|
1297
|
+
onConfigChanged: [{ type: Output }],
|
|
1298
|
+
onWidgetSave: [{ type: Output }]
|
|
1299
|
+
}
|
|
1300
|
+
});
|
|
1301
|
+
var AXWidgetSizePropertyEditorComponent = class AXWidgetSizePropertyEditorComponent extends AXProperyEditorComponent {
|
|
1302
|
+
cdr;
|
|
1303
|
+
sizeX;
|
|
1304
|
+
sizeY;
|
|
1305
|
+
minX = 1;
|
|
1306
|
+
maxX = 20;
|
|
1307
|
+
minY = 1;
|
|
1308
|
+
maxY = 20;
|
|
1309
|
+
constructor(cdr) {
|
|
1310
|
+
super(cdr);
|
|
1311
|
+
this.cdr = cdr;
|
|
1312
|
+
}
|
|
1313
|
+
ngOnInit() {
|
|
1314
|
+
if (Array.isArray(this.value)) {
|
|
1315
|
+
this.sizeX = this.value[0];
|
|
1316
|
+
this.sizeY = this.value[1];
|
|
1317
|
+
} else {
|
|
1318
|
+
this.sizeX = 2;
|
|
1319
|
+
this.sizeY = 2;
|
|
1320
|
+
}
|
|
1321
|
+
}
|
|
1322
|
+
handleMinValueChange(e) {
|
|
1323
|
+
this.sizeX = e.value;
|
|
1324
|
+
if (this.sizeY > 0) super.handleValueChange([this.sizeX, this.sizeY]);
|
|
1325
|
+
}
|
|
1326
|
+
handleMaxValueChange(e) {
|
|
1327
|
+
this.sizeY = e.value;
|
|
1328
|
+
if (this.sizeX > 0) super.handleValueChange([this.sizeX, this.sizeY]);
|
|
1329
|
+
}
|
|
1330
|
+
ngAfterViewInit() {
|
|
1331
|
+
this.onRenderCompleted.emit();
|
|
1332
|
+
}
|
|
1333
|
+
static ɵfac = i0.ɵɵngDeclareFactory({
|
|
1334
|
+
minVersion: "12.0.0",
|
|
1335
|
+
version: "22.2.0",
|
|
1336
|
+
ngImport: i0,
|
|
1337
|
+
type: AXWidgetSizePropertyEditorComponent,
|
|
1338
|
+
deps: [{ token: i0.ChangeDetectorRef }],
|
|
1339
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
1340
|
+
});
|
|
1341
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({
|
|
1342
|
+
minVersion: "14.0.0",
|
|
1343
|
+
version: "22.2.0",
|
|
1344
|
+
type: AXWidgetSizePropertyEditorComponent,
|
|
1345
|
+
isStandalone: false,
|
|
1346
|
+
selector: "ng-component",
|
|
1347
|
+
usesInheritance: true,
|
|
1348
|
+
ngImport: i0,
|
|
1349
|
+
template: "<div style=\"display: grid;grid-gap: 2%; grid-template-columns: 49% 49%;\">\n <ax-number-box (onValueChanged)=\"handleMinValueChange($event)\" [value]=\"sizeX\" [min]=\"minX\" [max]=\"maxX\">\n </ax-number-box>\n <ax-number-box (onValueChanged)=\"handleMaxValueChange($event)\" [value]=\"sizeY\" [min]=\"minY\" [max]=\"maxY\">\n </ax-number-box>\n</div>",
|
|
1350
|
+
dependencies: [{
|
|
1351
|
+
kind: "component",
|
|
1352
|
+
type: i1$1.AXNumberBoxComponent,
|
|
1353
|
+
selector: "ax-number-box",
|
|
1354
|
+
inputs: [
|
|
1355
|
+
"min",
|
|
1356
|
+
"max",
|
|
1357
|
+
"showSeparator",
|
|
1358
|
+
"showCurrency",
|
|
1359
|
+
"showCounter",
|
|
1360
|
+
"scrollWeel",
|
|
1361
|
+
"showDoubleCounter",
|
|
1362
|
+
"maxLength",
|
|
1363
|
+
"intStep",
|
|
1364
|
+
"decimalNumber",
|
|
1365
|
+
"customStep"
|
|
1366
|
+
]
|
|
1367
|
+
}],
|
|
1368
|
+
changeDetection: i0.ChangeDetectionStrategy.Eager
|
|
1369
|
+
});
|
|
1370
|
+
};
|
|
1371
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
1372
|
+
minVersion: "12.0.0",
|
|
1373
|
+
version: "22.2.0",
|
|
1374
|
+
ngImport: i0,
|
|
1375
|
+
type: AXWidgetSizePropertyEditorComponent,
|
|
1376
|
+
decorators: [{
|
|
1377
|
+
type: Component,
|
|
1378
|
+
args: [{
|
|
1379
|
+
changeDetection: ChangeDetectionStrategy.Eager,
|
|
1380
|
+
standalone: false,
|
|
1381
|
+
template: "<div style=\"display: grid;grid-gap: 2%; grid-template-columns: 49% 49%;\">\n <ax-number-box (onValueChanged)=\"handleMinValueChange($event)\" [value]=\"sizeX\" [min]=\"minX\" [max]=\"maxX\">\n </ax-number-box>\n <ax-number-box (onValueChanged)=\"handleMaxValueChange($event)\" [value]=\"sizeY\" [min]=\"minY\" [max]=\"maxY\">\n </ax-number-box>\n</div>"
|
|
1382
|
+
}]
|
|
1383
|
+
}],
|
|
1384
|
+
ctorParameters: () => [{ type: i0.ChangeDetectorRef }]
|
|
1385
|
+
});
|
|
1386
|
+
var AXWidgetBoardModule = class AXWidgetBoardModule {
|
|
1387
|
+
constructor() {
|
|
1388
|
+
AXTranslator.load("en", { "widget-board": {
|
|
1389
|
+
"configurable-props": "Configurable Properties",
|
|
1390
|
+
configure: "Configure Widget"
|
|
1391
|
+
} });
|
|
1392
|
+
AXTranslator.load("fa", { "widget-board": {
|
|
1393
|
+
"configurable-props": "ویژگی های قابل تنظیم",
|
|
1394
|
+
configure: "پیکر بندی ابزارک"
|
|
1395
|
+
} });
|
|
1396
|
+
}
|
|
1397
|
+
static ɵfac = i0.ɵɵngDeclareFactory({
|
|
1398
|
+
minVersion: "12.0.0",
|
|
1399
|
+
version: "22.2.0",
|
|
1400
|
+
ngImport: i0,
|
|
1401
|
+
type: AXWidgetBoardModule,
|
|
1402
|
+
deps: [],
|
|
1403
|
+
target: i0.ɵɵFactoryTarget.NgModule
|
|
1404
|
+
});
|
|
1405
|
+
static ɵmod = i0.ɵɵngDeclareNgModule({
|
|
1406
|
+
minVersion: "14.0.0",
|
|
1407
|
+
version: "22.2.0",
|
|
1408
|
+
ngImport: i0,
|
|
1409
|
+
type: AXWidgetBoardModule,
|
|
1410
|
+
declarations: [
|
|
1411
|
+
AXWidgetBoardComponent,
|
|
1412
|
+
AXWidgetHostComponent,
|
|
1413
|
+
AXWidgetConfigComponent,
|
|
1414
|
+
AXWidgetSaveComponent
|
|
1415
|
+
],
|
|
1416
|
+
imports: [
|
|
1417
|
+
CommonModule,
|
|
1418
|
+
AXSearchBoxModule,
|
|
1419
|
+
AXLoadingModule,
|
|
1420
|
+
RouterModule,
|
|
1421
|
+
AXProppertyEditorModule,
|
|
1422
|
+
AXPageModule,
|
|
1423
|
+
AXToolbarModule,
|
|
1424
|
+
AXTranslatorModule,
|
|
1425
|
+
AXLabelModule,
|
|
1426
|
+
AXTextAreaModule,
|
|
1427
|
+
AXFieldsetModule,
|
|
1428
|
+
AXTextBoxModule,
|
|
1429
|
+
AXFormGroupModule,
|
|
1430
|
+
AXTabStripModule,
|
|
1431
|
+
AXCheckBoxModule,
|
|
1432
|
+
AXMenuModule,
|
|
1433
|
+
AXTranslatorModule,
|
|
1434
|
+
AXValidationModule,
|
|
1435
|
+
i1.RouterModule
|
|
1436
|
+
],
|
|
1437
|
+
exports: [AXWidgetBoardComponent, AXProppertyEditorModule]
|
|
1438
|
+
});
|
|
1439
|
+
static ɵinj = i0.ɵɵngDeclareInjector({
|
|
1440
|
+
minVersion: "12.0.0",
|
|
1441
|
+
version: "22.2.0",
|
|
1442
|
+
ngImport: i0,
|
|
1443
|
+
type: AXWidgetBoardModule,
|
|
1444
|
+
imports: [
|
|
1445
|
+
CommonModule,
|
|
1446
|
+
AXSearchBoxModule,
|
|
1447
|
+
AXLoadingModule,
|
|
1448
|
+
RouterModule,
|
|
1449
|
+
AXProppertyEditorModule,
|
|
1450
|
+
AXPageModule,
|
|
1451
|
+
AXToolbarModule,
|
|
1452
|
+
AXTranslatorModule,
|
|
1453
|
+
AXLabelModule,
|
|
1454
|
+
AXTextAreaModule,
|
|
1455
|
+
AXFieldsetModule,
|
|
1456
|
+
AXTextBoxModule,
|
|
1457
|
+
AXFormGroupModule,
|
|
1458
|
+
AXTabStripModule,
|
|
1459
|
+
AXCheckBoxModule,
|
|
1460
|
+
AXMenuModule,
|
|
1461
|
+
AXTranslatorModule,
|
|
1462
|
+
AXValidationModule,
|
|
1463
|
+
RouterModule.forChild([{
|
|
1464
|
+
component: AXWidgetSizePropertyEditorComponent,
|
|
1465
|
+
path: "ax/editors/widget-size"
|
|
1466
|
+
}]),
|
|
1467
|
+
AXProppertyEditorModule
|
|
1468
|
+
]
|
|
1469
|
+
});
|
|
1470
|
+
};
|
|
1471
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
1472
|
+
minVersion: "12.0.0",
|
|
1473
|
+
version: "22.2.0",
|
|
1474
|
+
ngImport: i0,
|
|
1475
|
+
type: AXWidgetBoardModule,
|
|
1476
|
+
decorators: [{
|
|
1477
|
+
type: NgModule,
|
|
1478
|
+
args: [{
|
|
1479
|
+
imports: [
|
|
1480
|
+
CommonModule,
|
|
1481
|
+
AXSearchBoxModule,
|
|
1482
|
+
AXLoadingModule,
|
|
1483
|
+
RouterModule,
|
|
1484
|
+
AXProppertyEditorModule,
|
|
1485
|
+
AXPageModule,
|
|
1486
|
+
AXToolbarModule,
|
|
1487
|
+
AXTranslatorModule,
|
|
1488
|
+
AXLabelModule,
|
|
1489
|
+
AXTextAreaModule,
|
|
1490
|
+
AXFieldsetModule,
|
|
1491
|
+
AXTextBoxModule,
|
|
1492
|
+
AXFormGroupModule,
|
|
1493
|
+
AXTabStripModule,
|
|
1494
|
+
AXCheckBoxModule,
|
|
1495
|
+
AXMenuModule,
|
|
1496
|
+
AXTranslatorModule,
|
|
1497
|
+
AXValidationModule,
|
|
1498
|
+
RouterModule.forChild([{
|
|
1499
|
+
component: AXWidgetSizePropertyEditorComponent,
|
|
1500
|
+
path: "ax/editors/widget-size"
|
|
1501
|
+
}])
|
|
1502
|
+
],
|
|
1503
|
+
exports: [AXWidgetBoardComponent, AXProppertyEditorModule],
|
|
1504
|
+
declarations: [
|
|
1505
|
+
AXWidgetBoardComponent,
|
|
1506
|
+
AXWidgetHostComponent,
|
|
1507
|
+
AXWidgetConfigComponent,
|
|
1508
|
+
AXWidgetSaveComponent
|
|
1509
|
+
],
|
|
1510
|
+
providers: [],
|
|
1511
|
+
schemas: [NO_ERRORS_SCHEMA]
|
|
1512
|
+
}]
|
|
1513
|
+
}],
|
|
1514
|
+
ctorParameters: () => []
|
|
1515
|
+
});
|
|
1516
|
+
var AXWidgetSizePropertyEditorModule = class AXWidgetSizePropertyEditorModule {
|
|
1517
|
+
static ɵfac = i0.ɵɵngDeclareFactory({
|
|
1518
|
+
minVersion: "12.0.0",
|
|
1519
|
+
version: "22.2.0",
|
|
1520
|
+
ngImport: i0,
|
|
1521
|
+
type: AXWidgetSizePropertyEditorModule,
|
|
1522
|
+
deps: [],
|
|
1523
|
+
target: i0.ɵɵFactoryTarget.NgModule
|
|
1524
|
+
});
|
|
1525
|
+
static ɵmod = i0.ɵɵngDeclareNgModule({
|
|
1526
|
+
minVersion: "14.0.0",
|
|
1527
|
+
version: "22.2.0",
|
|
1528
|
+
ngImport: i0,
|
|
1529
|
+
type: AXWidgetSizePropertyEditorModule,
|
|
1530
|
+
declarations: [AXWidgetSizePropertyEditorComponent],
|
|
1531
|
+
imports: [
|
|
1532
|
+
CommonModule,
|
|
1533
|
+
FormsModule,
|
|
1534
|
+
AXNumberBoxModule
|
|
1535
|
+
],
|
|
1536
|
+
exports: [AXWidgetSizePropertyEditorComponent]
|
|
1537
|
+
});
|
|
1538
|
+
static ɵinj = i0.ɵɵngDeclareInjector({
|
|
1539
|
+
minVersion: "12.0.0",
|
|
1540
|
+
version: "22.2.0",
|
|
1541
|
+
ngImport: i0,
|
|
1542
|
+
type: AXWidgetSizePropertyEditorModule,
|
|
1543
|
+
imports: [
|
|
1544
|
+
CommonModule,
|
|
1545
|
+
FormsModule,
|
|
1546
|
+
AXNumberBoxModule
|
|
1547
|
+
]
|
|
1548
|
+
});
|
|
1549
|
+
};
|
|
1550
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
1551
|
+
minVersion: "12.0.0",
|
|
1552
|
+
version: "22.2.0",
|
|
1553
|
+
ngImport: i0,
|
|
1554
|
+
type: AXWidgetSizePropertyEditorModule,
|
|
1555
|
+
decorators: [{
|
|
1556
|
+
type: NgModule,
|
|
1557
|
+
args: [{
|
|
1558
|
+
declarations: [AXWidgetSizePropertyEditorComponent],
|
|
1559
|
+
imports: [
|
|
1560
|
+
CommonModule,
|
|
1561
|
+
FormsModule,
|
|
1562
|
+
AXNumberBoxModule
|
|
1563
|
+
],
|
|
1564
|
+
exports: [AXWidgetSizePropertyEditorComponent],
|
|
1565
|
+
providers: [],
|
|
1566
|
+
schemas: [NO_ERRORS_SCHEMA]
|
|
1567
|
+
}]
|
|
1568
|
+
}]
|
|
1569
|
+
});
|
|
1206
1570
|
export { AXWidgetBoardComponent, AXWidgetBoardModule, AXWidgetComponent, AXWidgetHostComponent, AXWidgetSizePropertyEditorComponent, AXWidgetSizePropertyEditorModule };
|
|
1207
|
-
|
|
1571
|
+
|
|
1572
|
+
//# sourceMappingURL=acorex-layout.mjs.map
|