@dignite-ng/expand.ck-editor 3.0.0-rc.3 → 3.0.0-rc.5
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/esm2022/lib/dynamic-form/ck-editor/ck-editor-config.component.mjs +10 -6
- package/esm2022/lib/dynamic-form/ck-editor/ck-editor-config.mjs +3 -1
- package/esm2022/lib/dynamic-form/ck-editor/ck-editor-control.component.mjs +23 -8
- package/esm2022/lib/enums/ck-editor-mode.enum.mjs +8 -0
- package/esm2022/lib/object/ck-editor-object.mjs +341 -340
- package/esm2022/lib/services/set-ck-editor-configs.service.mjs +5 -3
- package/esm2022/public-api.mjs +2 -1
- package/fesm2022/dignite-ng-expand.ck-editor.mjs +384 -357
- package/fesm2022/dignite-ng-expand.ck-editor.mjs.map +1 -1
- package/lib/dynamic-form/ck-editor/ck-editor-config.component.d.ts +3 -0
- package/lib/dynamic-form/ck-editor/ck-editor-config.d.ts +2 -0
- package/lib/dynamic-form/ck-editor/ck-editor-control.component.d.ts +2 -0
- package/lib/enums/ck-editor-mode.enum.d.ts +5 -0
- package/lib/object/ck-editor-object.d.ts +4 -8
- package/package.json +1 -1
- package/public-api.d.ts +1 -0
|
@@ -2,14 +2,14 @@ import * as i0 from '@angular/core';
|
|
|
2
2
|
import { NgModule, inject, ChangeDetectorRef, Component, Input, ViewChild, Injectable } from '@angular/core';
|
|
3
3
|
import * as i1 from '@angular/router';
|
|
4
4
|
import { RouterModule } from '@angular/router';
|
|
5
|
-
import * as
|
|
6
|
-
import { ConfigStateService, RestService, LazyLoadService, SubscriptionService, LOADING_STRATEGY, CoreModule } from '@abp/ng.core';
|
|
5
|
+
import * as i3 from '@abp/ng.core';
|
|
6
|
+
import { mapEnumToOptions, ConfigStateService, RestService, LazyLoadService, SubscriptionService, LOADING_STRATEGY, CoreModule } from '@abp/ng.core';
|
|
7
7
|
import { ThemeSharedModule } from '@abp/ng.theme.shared';
|
|
8
8
|
import * as i1$1 from '@angular/forms';
|
|
9
9
|
import { FormBuilder, Validators } from '@angular/forms';
|
|
10
|
-
import * as
|
|
11
|
-
import * as
|
|
12
|
-
import * as i4 from '@ckeditor/ckeditor5-angular';
|
|
10
|
+
import * as i2 from '@angular/common';
|
|
11
|
+
import * as i4 from '@ngx-validate/core';
|
|
12
|
+
import * as i4$1 from '@ckeditor/ckeditor5-angular';
|
|
13
13
|
import { CKEditorModule } from '@ckeditor/ckeditor5-angular';
|
|
14
14
|
|
|
15
15
|
const routes = [];
|
|
@@ -28,6 +28,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.5", ngImpor
|
|
|
28
28
|
|
|
29
29
|
class CkEditorConfig {
|
|
30
30
|
constructor(data) {
|
|
31
|
+
/**类型 */
|
|
32
|
+
this['Ckeditor.Mode'] = ['', []];
|
|
31
33
|
/**文件容器名称 */
|
|
32
34
|
// placeholder: any = new FormControl('', Validators.required);
|
|
33
35
|
this['Ckeditor.ImagesContainerName'] = ['', []];
|
|
@@ -44,9 +46,18 @@ class CkEditorConfig {
|
|
|
44
46
|
}
|
|
45
47
|
}
|
|
46
48
|
|
|
49
|
+
var CkEditorModeEnum;
|
|
50
|
+
(function (CkEditorModeEnum) {
|
|
51
|
+
CkEditorModeEnum[CkEditorModeEnum["Simple"] = 0] = "Simple";
|
|
52
|
+
CkEditorModeEnum[CkEditorModeEnum["Classic"] = 1] = "Classic";
|
|
53
|
+
})(CkEditorModeEnum || (CkEditorModeEnum = {}));
|
|
54
|
+
const CkEditorModeEnumOptions = mapEnumToOptions(CkEditorModeEnum);
|
|
55
|
+
|
|
47
56
|
class CkEditorConfigComponent {
|
|
48
57
|
constructor(fb) {
|
|
49
58
|
this.fb = fb;
|
|
59
|
+
this.CkEditorModeEnum = CkEditorModeEnum;
|
|
60
|
+
this.CkEditorModeEnumOptions = CkEditorModeEnumOptions;
|
|
50
61
|
this.cdr = inject(ChangeDetectorRef);
|
|
51
62
|
}
|
|
52
63
|
set Entity(v) {
|
|
@@ -61,7 +72,7 @@ class CkEditorConfigComponent {
|
|
|
61
72
|
this._type = v;
|
|
62
73
|
// this.dataLoaded()
|
|
63
74
|
}
|
|
64
|
-
//
|
|
75
|
+
//
|
|
65
76
|
get formConfiguration() {
|
|
66
77
|
return this._Entity.get('formConfiguration');
|
|
67
78
|
}
|
|
@@ -84,11 +95,11 @@ class CkEditorConfigComponent {
|
|
|
84
95
|
});
|
|
85
96
|
}
|
|
86
97
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: CkEditorConfigComponent, deps: [{ token: i1$1.FormBuilder }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
87
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.1.5", type: CkEditorConfigComponent, selector: "ck-editor-config", inputs: { Entity: "Entity", selected: "selected", type: "type" }, viewQueries: [{ propertyName: "submitclick", first: true, predicate: ["submitclick"], descendants: true, static: true }], ngImport: i0, template: "<form [formGroup]=\"_Entity\">\n <div formGroupName=\"formConfiguration\">\n <div class=\"mb-3\">\n <label class=\"form-label\">{{'DigniteAbpDynamicFormsCkEditor::ImagesContainerName' | abpLocalization}}</label>\n <input type=\"text\" class=\"form-control\" formControlName=\"Ckeditor.ImagesContainerName\">\n </div>\n <div class=\"mb-3\">\n <label class=\"form-label\">{{'DigniteAbpDynamicFormsCkEditor::InitialContent' | abpLocalization}}</label>\n <input type=\"text\" class=\"form-control\" formControlName=\"Ckeditor.InitialContent\">\n </div>\n <button type=\"submit\" (abpInit)=\"submitclick?.nativeElement?.click()\" style=\"display: none;\"\n #submitclick></button>\n </div>\n</form>", styles: [""], dependencies: [{ kind: "directive", type: i1$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i1$1.FormGroupName, selector: "[formGroupName]", inputs: ["formGroupName"] }, { kind: "directive", type:
|
|
98
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.1.5", type: CkEditorConfigComponent, selector: "ck-editor-config", inputs: { Entity: "Entity", selected: "selected", type: "type" }, viewQueries: [{ propertyName: "submitclick", first: true, predicate: ["submitclick"], descendants: true, static: true }], ngImport: i0, template: "<form [formGroup]=\"_Entity\">\n <div formGroupName=\"formConfiguration\">\n <div class=\"mb-3\">\n <label class=\"form-label\">{{'DigniteAbpDynamicFormsCkEditor::EditorMode' | abpLocalization}}</label>\n <!-- <input type=\"text\" class=\"form-control\" formControlName=\"Ckeditor.Mode\"> -->\n <select class=\"form-select\" formControlName=\"Ckeditor.Mode\" >\n <ng-container *ngFor=\"let item of CkEditorModeEnumOptions\">\n <option [value]=\"item.value\">{{'DigniteAbpDynamicFormsCkEditor::EditorMode.' + item.key|abpLocalization}}</option>\n </ng-container>\n </select>\n </div>\n <div class=\"mb-3\">\n <label class=\"form-label\">{{'DigniteAbpDynamicFormsCkEditor::ImagesContainerName' | abpLocalization}}</label>\n <input type=\"text\" class=\"form-control\" formControlName=\"Ckeditor.ImagesContainerName\">\n </div>\n <div class=\"mb-3\">\n <label class=\"form-label\">{{'DigniteAbpDynamicFormsCkEditor::InitialContent' | abpLocalization}}</label>\n <input type=\"text\" class=\"form-control\" formControlName=\"Ckeditor.InitialContent\">\n </div>\n <button type=\"submit\" (abpInit)=\"submitclick?.nativeElement?.click()\" style=\"display: none;\"\n #submitclick></button>\n </div>\n</form>", styles: [""], dependencies: [{ kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$1.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1$1.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.SelectControlValueAccessor, selector: "select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]", inputs: ["compareWith"] }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i1$1.FormGroupName, selector: "[formGroupName]", inputs: ["formGroupName"] }, { kind: "directive", type: i3.InitDirective, selector: "[abpInit]", outputs: ["abpInit"] }, { kind: "directive", type: i4.ValidationGroupDirective, selector: "[formGroup],[formGroupName]", exportAs: ["validationGroup"] }, { kind: "directive", type: i4.ValidationDirective, selector: "[formControl],[formControlName]", exportAs: ["validationDirective"] }, { kind: "pipe", type: i3.LocalizationPipe, name: "abpLocalization" }] }); }
|
|
88
99
|
}
|
|
89
100
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: CkEditorConfigComponent, decorators: [{
|
|
90
101
|
type: Component,
|
|
91
|
-
args: [{ selector: 'ck-editor-config', template: "<form [formGroup]=\"_Entity\">\n <div formGroupName=\"formConfiguration\">\n <div class=\"mb-3\">\n <label class=\"form-label\">{{'DigniteAbpDynamicFormsCkEditor::ImagesContainerName' | abpLocalization}}</label>\n <input type=\"text\" class=\"form-control\" formControlName=\"Ckeditor.ImagesContainerName\">\n </div>\n <div class=\"mb-3\">\n <label class=\"form-label\">{{'DigniteAbpDynamicFormsCkEditor::InitialContent' | abpLocalization}}</label>\n <input type=\"text\" class=\"form-control\" formControlName=\"Ckeditor.InitialContent\">\n </div>\n <button type=\"submit\" (abpInit)=\"submitclick?.nativeElement?.click()\" style=\"display: none;\"\n #submitclick></button>\n </div>\n</form>" }]
|
|
102
|
+
args: [{ selector: 'ck-editor-config', template: "<form [formGroup]=\"_Entity\">\n <div formGroupName=\"formConfiguration\">\n <div class=\"mb-3\">\n <label class=\"form-label\">{{'DigniteAbpDynamicFormsCkEditor::EditorMode' | abpLocalization}}</label>\n <!-- <input type=\"text\" class=\"form-control\" formControlName=\"Ckeditor.Mode\"> -->\n <select class=\"form-select\" formControlName=\"Ckeditor.Mode\" >\n <ng-container *ngFor=\"let item of CkEditorModeEnumOptions\">\n <option [value]=\"item.value\">{{'DigniteAbpDynamicFormsCkEditor::EditorMode.' + item.key|abpLocalization}}</option>\n </ng-container>\n </select>\n </div>\n <div class=\"mb-3\">\n <label class=\"form-label\">{{'DigniteAbpDynamicFormsCkEditor::ImagesContainerName' | abpLocalization}}</label>\n <input type=\"text\" class=\"form-control\" formControlName=\"Ckeditor.ImagesContainerName\">\n </div>\n <div class=\"mb-3\">\n <label class=\"form-label\">{{'DigniteAbpDynamicFormsCkEditor::InitialContent' | abpLocalization}}</label>\n <input type=\"text\" class=\"form-control\" formControlName=\"Ckeditor.InitialContent\">\n </div>\n <button type=\"submit\" (abpInit)=\"submitclick?.nativeElement?.click()\" style=\"display: none;\"\n #submitclick></button>\n </div>\n</form>" }]
|
|
92
103
|
}], ctorParameters: () => [{ type: i1$1.FormBuilder }], propDecorators: { Entity: [{
|
|
93
104
|
type: Input
|
|
94
105
|
}], selected: [{
|
|
@@ -151,7 +162,7 @@ let isBase64UploadAdapter$1 = class isBase64UploadAdapter {
|
|
|
151
162
|
}
|
|
152
163
|
};
|
|
153
164
|
|
|
154
|
-
var
|
|
165
|
+
var Simple = {
|
|
155
166
|
toolbar: {
|
|
156
167
|
items: [
|
|
157
168
|
'undo',
|
|
@@ -163,6 +174,7 @@ var easy = {
|
|
|
163
174
|
'bold',
|
|
164
175
|
'italic',
|
|
165
176
|
'underline',
|
|
177
|
+
'insertImage'
|
|
166
178
|
],
|
|
167
179
|
shouldNotGroupWhenFull: false,
|
|
168
180
|
},
|
|
@@ -226,340 +238,340 @@ var easy = {
|
|
|
226
238
|
},
|
|
227
239
|
},
|
|
228
240
|
};
|
|
229
|
-
var defaults = {
|
|
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
|
-
var standard = {
|
|
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
|
-
var
|
|
241
|
+
// export var defaults: any= {
|
|
242
|
+
// toolbar: {
|
|
243
|
+
// items: [
|
|
244
|
+
// 'undo',
|
|
245
|
+
// 'redo',
|
|
246
|
+
// '|',
|
|
247
|
+
// 'heading',
|
|
248
|
+
// '|',
|
|
249
|
+
// 'fontSize',
|
|
250
|
+
// 'fontFamily',
|
|
251
|
+
// 'fontColor',
|
|
252
|
+
// 'fontBackgroundColor',
|
|
253
|
+
// 'link',
|
|
254
|
+
// '|',
|
|
255
|
+
// 'bold',
|
|
256
|
+
// 'italic',
|
|
257
|
+
// 'underline',
|
|
258
|
+
// '|',
|
|
259
|
+
// 'insertImage',
|
|
260
|
+
// ],
|
|
261
|
+
// shouldNotGroupWhenFull: false,
|
|
262
|
+
// },
|
|
263
|
+
// plugins: [],
|
|
264
|
+
// heading: {
|
|
265
|
+
// options: [
|
|
266
|
+
// {
|
|
267
|
+
// model: 'paragraph',
|
|
268
|
+
// title: 'Paragraph',
|
|
269
|
+
// class: 'ck-heading_paragraph',
|
|
270
|
+
// },
|
|
271
|
+
// {
|
|
272
|
+
// model: 'heading1',
|
|
273
|
+
// view: 'h1',
|
|
274
|
+
// title: 'Heading 1',
|
|
275
|
+
// class: 'ck-heading_heading1',
|
|
276
|
+
// },
|
|
277
|
+
// {
|
|
278
|
+
// model: 'heading2',
|
|
279
|
+
// view: 'h2',
|
|
280
|
+
// title: 'Heading 2',
|
|
281
|
+
// class: 'ck-heading_heading2',
|
|
282
|
+
// },
|
|
283
|
+
// {
|
|
284
|
+
// model: 'heading3',
|
|
285
|
+
// view: 'h3',
|
|
286
|
+
// title: 'Heading 3',
|
|
287
|
+
// class: 'ck-heading_heading3',
|
|
288
|
+
// },
|
|
289
|
+
// {
|
|
290
|
+
// model: 'heading4',
|
|
291
|
+
// view: 'h4',
|
|
292
|
+
// title: 'Heading 4',
|
|
293
|
+
// class: 'ck-heading_heading4',
|
|
294
|
+
// },
|
|
295
|
+
// {
|
|
296
|
+
// model: 'heading5',
|
|
297
|
+
// view: 'h5',
|
|
298
|
+
// title: 'Heading 5',
|
|
299
|
+
// class: 'ck-heading_heading5',
|
|
300
|
+
// },
|
|
301
|
+
// {
|
|
302
|
+
// model: 'heading6',
|
|
303
|
+
// view: 'h6',
|
|
304
|
+
// title: 'Heading 6',
|
|
305
|
+
// class: 'ck-heading_heading6',
|
|
306
|
+
// },
|
|
307
|
+
// ],
|
|
308
|
+
// },
|
|
309
|
+
// fontSize: {
|
|
310
|
+
// options: [10, 12, 14, 'default', 18, 20, 22, 24, 26, 28, 30, 32],
|
|
311
|
+
// },
|
|
312
|
+
// link: {
|
|
313
|
+
// addTargetToExternalLinks: true,
|
|
314
|
+
// defaultProtocol: 'https://',
|
|
315
|
+
// decorators: {
|
|
316
|
+
// toggleDownloadable: {
|
|
317
|
+
// mode: 'manual',
|
|
318
|
+
// label: 'Downloadable',
|
|
319
|
+
// attributes: {
|
|
320
|
+
// download: 'file',
|
|
321
|
+
// },
|
|
322
|
+
// },
|
|
323
|
+
// },
|
|
324
|
+
// },
|
|
325
|
+
// image: {
|
|
326
|
+
// toolbar: [
|
|
327
|
+
// 'toggleImageCaption',
|
|
328
|
+
// 'imageTextAlternative',
|
|
329
|
+
// '|',
|
|
330
|
+
// 'imageStyle:inline',
|
|
331
|
+
// 'imageStyle:wrapText',
|
|
332
|
+
// 'imageStyle:breakText',
|
|
333
|
+
// '|',
|
|
334
|
+
// 'resizeImage',
|
|
335
|
+
// ],
|
|
336
|
+
// styles: {
|
|
337
|
+
// options: [
|
|
338
|
+
// 'inline', 'alignLeft', 'alignRight',
|
|
339
|
+
// 'alignCenter', 'alignBlockLeft', 'alignBlockRight',
|
|
340
|
+
// 'block', 'side'
|
|
341
|
+
// ]
|
|
342
|
+
// },
|
|
343
|
+
// resizeOptions: [{
|
|
344
|
+
// name: 'resizeImage:original',
|
|
345
|
+
// label: 'Original',
|
|
346
|
+
// value: null
|
|
347
|
+
// },
|
|
348
|
+
// {
|
|
349
|
+
// name: 'resizeImage:25',
|
|
350
|
+
// label: '25%',
|
|
351
|
+
// value: '25'
|
|
352
|
+
// },
|
|
353
|
+
// {
|
|
354
|
+
// name: 'resizeImage:50',
|
|
355
|
+
// label: '50%',
|
|
356
|
+
// value: '50'
|
|
357
|
+
// },
|
|
358
|
+
// {
|
|
359
|
+
// name: 'resizeImage:75',
|
|
360
|
+
// label: '75%',
|
|
361
|
+
// value: '75'
|
|
362
|
+
// }
|
|
363
|
+
// ],
|
|
364
|
+
// },
|
|
365
|
+
// }
|
|
366
|
+
// export var standard: any= {
|
|
367
|
+
// toolbar: {
|
|
368
|
+
// items: [
|
|
369
|
+
// 'undo',
|
|
370
|
+
// 'redo',
|
|
371
|
+
// '|',
|
|
372
|
+
// 'heading',
|
|
373
|
+
// '|',
|
|
374
|
+
// 'fontSize',
|
|
375
|
+
// 'fontFamily',
|
|
376
|
+
// 'fontColor',
|
|
377
|
+
// 'fontBackgroundColor',
|
|
378
|
+
// '|',
|
|
379
|
+
// 'bold',
|
|
380
|
+
// 'italic',
|
|
381
|
+
// 'underline',
|
|
382
|
+
// 'strikethrough',
|
|
383
|
+
// '|',
|
|
384
|
+
// 'link',
|
|
385
|
+
// 'insertImage',
|
|
386
|
+
// 'insertTable',
|
|
387
|
+
// '|',
|
|
388
|
+
// 'alignment',
|
|
389
|
+
// '|',
|
|
390
|
+
// 'bulletedList',
|
|
391
|
+
// 'numberedList',
|
|
392
|
+
// ],
|
|
393
|
+
// shouldNotGroupWhenFull: false,
|
|
394
|
+
// },
|
|
395
|
+
// plugins: [],
|
|
396
|
+
// fontSize: {
|
|
397
|
+
// options: [10, 12, 14, 'default', 18, 20, 22, 24, 26, 28, 30, 32],
|
|
398
|
+
// supportAllValues: true,
|
|
399
|
+
// },
|
|
400
|
+
// heading: {
|
|
401
|
+
// options: [
|
|
402
|
+
// {
|
|
403
|
+
// model: 'paragraph',
|
|
404
|
+
// title: 'Paragraph',
|
|
405
|
+
// class: 'ck-heading_paragraph',
|
|
406
|
+
// },
|
|
407
|
+
// {
|
|
408
|
+
// model: 'heading1',
|
|
409
|
+
// view: 'h1',
|
|
410
|
+
// title: 'Heading 1',
|
|
411
|
+
// class: 'ck-heading_heading1',
|
|
412
|
+
// },
|
|
413
|
+
// {
|
|
414
|
+
// model: 'heading2',
|
|
415
|
+
// view: 'h2',
|
|
416
|
+
// title: 'Heading 2',
|
|
417
|
+
// class: 'ck-heading_heading2',
|
|
418
|
+
// },
|
|
419
|
+
// {
|
|
420
|
+
// model: 'heading3',
|
|
421
|
+
// view: 'h3',
|
|
422
|
+
// title: 'Heading 3',
|
|
423
|
+
// class: 'ck-heading_heading3',
|
|
424
|
+
// },
|
|
425
|
+
// {
|
|
426
|
+
// model: 'heading4',
|
|
427
|
+
// view: 'h4',
|
|
428
|
+
// title: 'Heading 4',
|
|
429
|
+
// class: 'ck-heading_heading4',
|
|
430
|
+
// },
|
|
431
|
+
// {
|
|
432
|
+
// model: 'heading5',
|
|
433
|
+
// view: 'h5',
|
|
434
|
+
// title: 'Heading 5',
|
|
435
|
+
// class: 'ck-heading_heading5',
|
|
436
|
+
// },
|
|
437
|
+
// {
|
|
438
|
+
// model: 'heading6',
|
|
439
|
+
// view: 'h6',
|
|
440
|
+
// title: 'Heading 6',
|
|
441
|
+
// class: 'ck-heading_heading6',
|
|
442
|
+
// },
|
|
443
|
+
// ],
|
|
444
|
+
// },
|
|
445
|
+
// htmlSupport: {
|
|
446
|
+
// allow: [
|
|
447
|
+
// {
|
|
448
|
+
// name: /^.*$/,
|
|
449
|
+
// styles: true,
|
|
450
|
+
// attributes: true,
|
|
451
|
+
// classes: true,
|
|
452
|
+
// },
|
|
453
|
+
// ],
|
|
454
|
+
// },
|
|
455
|
+
// image: {
|
|
456
|
+
// toolbar: [
|
|
457
|
+
// 'toggleImageCaption',
|
|
458
|
+
// 'imageTextAlternative',
|
|
459
|
+
// '|',
|
|
460
|
+
// 'imageStyle:inline',
|
|
461
|
+
// 'imageStyle:wrapText',
|
|
462
|
+
// 'imageStyle:breakText',
|
|
463
|
+
// '|',
|
|
464
|
+
// 'resizeImage',
|
|
465
|
+
// ],
|
|
466
|
+
// styles: {
|
|
467
|
+
// options: [
|
|
468
|
+
// 'inline', 'alignLeft', 'alignRight',
|
|
469
|
+
// 'alignCenter', 'alignBlockLeft', 'alignBlockRight',
|
|
470
|
+
// 'block', 'side'
|
|
471
|
+
// ]
|
|
472
|
+
// },
|
|
473
|
+
// resizeOptions: [{
|
|
474
|
+
// name: 'resizeImage:original',
|
|
475
|
+
// label: 'Original',
|
|
476
|
+
// value: null
|
|
477
|
+
// },
|
|
478
|
+
// {
|
|
479
|
+
// name: 'resizeImage:25',
|
|
480
|
+
// label: '25%',
|
|
481
|
+
// value: '25'
|
|
482
|
+
// },
|
|
483
|
+
// {
|
|
484
|
+
// name: 'resizeImage:50',
|
|
485
|
+
// label: '50%',
|
|
486
|
+
// value: '50'
|
|
487
|
+
// },
|
|
488
|
+
// {
|
|
489
|
+
// name: 'resizeImage:75',
|
|
490
|
+
// label: '75%',
|
|
491
|
+
// value: '75'
|
|
492
|
+
// }
|
|
493
|
+
// ],
|
|
494
|
+
// },
|
|
495
|
+
// link: {
|
|
496
|
+
// addTargetToExternalLinks: true,
|
|
497
|
+
// defaultProtocol: 'https://',
|
|
498
|
+
// decorators: {
|
|
499
|
+
// toggleDownloadable: {
|
|
500
|
+
// mode: 'manual',
|
|
501
|
+
// label: 'Downloadable',
|
|
502
|
+
// attributes: {
|
|
503
|
+
// download: 'file',
|
|
504
|
+
// },
|
|
505
|
+
// },
|
|
506
|
+
// },
|
|
507
|
+
// },
|
|
508
|
+
// list: {
|
|
509
|
+
// properties: {
|
|
510
|
+
// styles: true,
|
|
511
|
+
// startIndex: true,
|
|
512
|
+
// reversed: true,
|
|
513
|
+
// },
|
|
514
|
+
// },
|
|
515
|
+
// style: {
|
|
516
|
+
// definitions: [
|
|
517
|
+
// {
|
|
518
|
+
// name: 'Article category',
|
|
519
|
+
// element: 'h3',
|
|
520
|
+
// classes: ['category'],
|
|
521
|
+
// },
|
|
522
|
+
// {
|
|
523
|
+
// name: 'Title',
|
|
524
|
+
// element: 'h2',
|
|
525
|
+
// classes: ['document-title'],
|
|
526
|
+
// },
|
|
527
|
+
// {
|
|
528
|
+
// name: 'Subtitle',
|
|
529
|
+
// element: 'h3',
|
|
530
|
+
// classes: ['document-subtitle'],
|
|
531
|
+
// },
|
|
532
|
+
// {
|
|
533
|
+
// name: 'Info box',
|
|
534
|
+
// element: 'p',
|
|
535
|
+
// classes: ['info-box'],
|
|
536
|
+
// },
|
|
537
|
+
// {
|
|
538
|
+
// name: 'Side quote',
|
|
539
|
+
// element: 'blockquote',
|
|
540
|
+
// classes: ['side-quote'],
|
|
541
|
+
// },
|
|
542
|
+
// {
|
|
543
|
+
// name: 'Marker',
|
|
544
|
+
// element: 'span',
|
|
545
|
+
// classes: ['marker'],
|
|
546
|
+
// },
|
|
547
|
+
// {
|
|
548
|
+
// name: 'Spoiler',
|
|
549
|
+
// element: 'span',
|
|
550
|
+
// classes: ['spoiler'],
|
|
551
|
+
// },
|
|
552
|
+
// {
|
|
553
|
+
// name: 'Code (dark)',
|
|
554
|
+
// element: 'pre',
|
|
555
|
+
// classes: ['fancy-code', 'fancy-code-dark'],
|
|
556
|
+
// },
|
|
557
|
+
// {
|
|
558
|
+
// name: 'Code (bright)',
|
|
559
|
+
// element: 'pre',
|
|
560
|
+
// classes: ['fancy-code', 'fancy-code-bright'],
|
|
561
|
+
// },
|
|
562
|
+
// ],
|
|
563
|
+
// },
|
|
564
|
+
// table: {
|
|
565
|
+
// contentToolbar: [
|
|
566
|
+
// 'tableColumn',
|
|
567
|
+
// 'tableRow',
|
|
568
|
+
// 'mergeTableCells',
|
|
569
|
+
// 'tableProperties',
|
|
570
|
+
// 'tableCellProperties',
|
|
571
|
+
// ],
|
|
572
|
+
// },
|
|
573
|
+
// }
|
|
574
|
+
var Classic = {
|
|
563
575
|
toolbar: {
|
|
564
576
|
items: [
|
|
565
577
|
'undo',
|
|
@@ -782,10 +794,10 @@ var full = {
|
|
|
782
794
|
},
|
|
783
795
|
};
|
|
784
796
|
var CkEditorTypesObject = {
|
|
785
|
-
default: defaults,
|
|
786
|
-
|
|
787
|
-
standard: standard,
|
|
788
|
-
|
|
797
|
+
// default: defaults,
|
|
798
|
+
Simple: Simple,
|
|
799
|
+
// standard: standard,
|
|
800
|
+
Classic: Classic
|
|
789
801
|
};
|
|
790
802
|
|
|
791
803
|
var LanguagesMap;
|
|
@@ -810,12 +822,13 @@ var LanguagesMap;
|
|
|
810
822
|
LanguagesMap["vi"] = "vi";
|
|
811
823
|
})(LanguagesMap || (LanguagesMap = {}));
|
|
812
824
|
|
|
825
|
+
// import { CkEditorModeEnum } from '../enums/ck-editor-mode-enum';
|
|
813
826
|
class SetCkEditorConfigsService {
|
|
814
827
|
constructor() { }
|
|
815
828
|
async get(input) {
|
|
816
|
-
let { language } = input;
|
|
829
|
+
let { language, type } = input;
|
|
817
830
|
return new Promise(async (resolve, rejects) => {
|
|
818
|
-
let configs = CkEditorTypesObject[
|
|
831
|
+
let configs = CkEditorTypesObject[CkEditorModeEnum[type]];
|
|
819
832
|
let { AccessibilityHelp, Highlight, Alignment, Autoformat, AutoImage, Autosave, Base64UploadAdapter, BlockQuote, Bold, CloudServices, Code, Essentials, FontBackgroundColor, FontColor, FontFamily, FontSize, GeneralHtmlSupport, Heading, HorizontalLine, ImageBlock, ImageCaption, ImageInline, ImageInsert, ImageInsertViaUrl, ImageResize, ImageStyle, ImageTextAlternative, ImageToolbar, ImageUpload, Indent, IndentBlock, Italic, Link, LinkImage, List, ListProperties, MediaEmbed, Paragraph, PasteFromOffice, RemoveFormat, SelectAll, SpecialCharacters, SpecialCharactersArrows, SpecialCharactersCurrency, SpecialCharactersEssentials, SpecialCharactersLatin, SpecialCharactersMathematical, SpecialCharactersText, Strikethrough, Style, Subscript, Superscript, Table, TableCaption, TableCellProperties, TableColumnResize, TableProperties, TableToolbar, TextTransformation, TodoList, Underline, Undo } = await import('ckeditor5');
|
|
820
833
|
configs.plugins = [AccessibilityHelp, Highlight, Alignment, Autoformat, AutoImage, Autosave, Base64UploadAdapter, BlockQuote, Bold, CloudServices, Code, Essentials, FontBackgroundColor, FontColor, FontFamily, FontSize, GeneralHtmlSupport, Heading, HorizontalLine, ImageBlock, ImageCaption, ImageInline, ImageInsert, ImageInsertViaUrl, ImageResize, ImageStyle, ImageTextAlternative, ImageToolbar, ImageUpload, Indent, IndentBlock, Italic, Link, LinkImage, List, ListProperties, MediaEmbed, Paragraph, PasteFromOffice, RemoveFormat, SelectAll, SpecialCharacters, SpecialCharactersArrows, SpecialCharactersCurrency, SpecialCharactersEssentials, SpecialCharactersLatin, SpecialCharactersMathematical, SpecialCharactersText, Strikethrough, Style, Subscript, Superscript, Table, TableCaption, TableCellProperties, TableColumnResize, TableProperties, TableToolbar, TextTransformation, TodoList, Underline, Undo];
|
|
821
834
|
configs.language = LanguagesMap[language];
|
|
@@ -841,6 +854,7 @@ class CkEditorControlComponent {
|
|
|
841
854
|
this.ckEditorValue = '';
|
|
842
855
|
/**系统语言 */
|
|
843
856
|
this.currentCulture = this.config.getOne('localization')?.currentCulture?.name;
|
|
857
|
+
this.CkEditorModeEnum = CkEditorModeEnum;
|
|
844
858
|
this.fb = inject(FormBuilder);
|
|
845
859
|
/**字段配置列表 */
|
|
846
860
|
this._fields = '';
|
|
@@ -851,7 +865,6 @@ class CkEditorControlComponent {
|
|
|
851
865
|
this.invalidfeedback = false;
|
|
852
866
|
/**图片容器名称 */
|
|
853
867
|
this.imagesContainerName = '';
|
|
854
|
-
this.loadckeditor();
|
|
855
868
|
}
|
|
856
869
|
onReady(editor) {
|
|
857
870
|
let _this = this;
|
|
@@ -890,18 +903,35 @@ class CkEditorControlComponent {
|
|
|
890
903
|
this._selected || this._fields.field.formConfiguration['Ckeditor.InitialContent'];
|
|
891
904
|
this.setckeditorInput(this.ckEditorValue);
|
|
892
905
|
this.cdr.detectChanges(); // 手动触发变更检测
|
|
906
|
+
await this.loadckeditor();
|
|
893
907
|
this.submitclick?.nativeElement?.click();
|
|
894
908
|
}
|
|
895
909
|
}
|
|
896
910
|
loadckeditor() {
|
|
897
911
|
let _that = this;
|
|
912
|
+
let formConfiguration = this._fields.field.formConfiguration;
|
|
898
913
|
return new Promise(async (resolve) => {
|
|
899
914
|
await import('ckeditor5').then(async (res) => {
|
|
900
915
|
this.loadStyle();
|
|
901
|
-
|
|
916
|
+
if (formConfiguration['Ckeditor.Mode'] == CkEditorModeEnum.Simple) {
|
|
917
|
+
_that.Editor = res.InlineEditor;
|
|
918
|
+
}
|
|
919
|
+
else if (formConfiguration['Ckeditor.Mode'] == CkEditorModeEnum.Classic) {
|
|
920
|
+
_that.Editor = res.ClassicEditor;
|
|
921
|
+
}
|
|
922
|
+
else {
|
|
923
|
+
formConfiguration['Ckeditor.Mode'] = CkEditorModeEnum.Simple;
|
|
924
|
+
_that.Editor = res.InlineEditor;
|
|
925
|
+
}
|
|
902
926
|
let configs = await _that._SetCkEditorConfigsService.get({
|
|
903
927
|
language: _that.currentCulture,
|
|
928
|
+
type: formConfiguration['Ckeditor.Mode']
|
|
904
929
|
});
|
|
930
|
+
if (!this.imagesContainerName) {
|
|
931
|
+
if (configs?.toolbar?.items?.indexOf('insertImage') != -1) {
|
|
932
|
+
configs?.toolbar?.items?.splice(configs?.toolbar?.items?.indexOf('insertImage'), 1);
|
|
933
|
+
}
|
|
934
|
+
}
|
|
905
935
|
_that.ckOptions = configs;
|
|
906
936
|
});
|
|
907
937
|
resolve(true);
|
|
@@ -928,18 +958,15 @@ class CkEditorControlComponent {
|
|
|
928
958
|
this.extraProperties.setControl(this._fields.field.name, newControl);
|
|
929
959
|
this.imagesContainerName =
|
|
930
960
|
this._fields.field.formConfiguration['Ckeditor.ImagesContainerName'];
|
|
931
|
-
if (!this.imagesContainerName) {
|
|
932
|
-
this.ckOptions?.toolbar?.items?.splice(this.ckOptions?.toolbar?.items?.indexOf('insertImage'), 1);
|
|
933
|
-
}
|
|
934
961
|
resolve(true);
|
|
935
962
|
});
|
|
936
963
|
}
|
|
937
964
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: CkEditorControlComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
938
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.1.5", type: CkEditorControlComponent, selector: "ck-editor-control", inputs: { fields: "fields", parentFiledName: "parentFiledName", selected: "selected", entity: "entity" }, viewQueries: [{ propertyName: "submitclick", first: true, predicate: ["submitclick"], descendants: true, static: true }], ngImport: i0, template: "<form [formGroup]=\"_entity\">\n <div formGroupName=\"extraProperties\">\n <div class=\"mb-3\">\n <label class=\"form-label\" *ngIf=\"_fields.displayName\">{{ _fields.displayName }}</label>\n <ng-container *ngIf=\"ckOptions\">\n
|
|
965
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.1.5", type: CkEditorControlComponent, selector: "ck-editor-control", inputs: { fields: "fields", parentFiledName: "parentFiledName", selected: "selected", entity: "entity" }, viewQueries: [{ propertyName: "submitclick", first: true, predicate: ["submitclick"], descendants: true, static: true }], ngImport: i0, template: "<form [formGroup]=\"_entity\">\n <div formGroupName=\"extraProperties\">\n <div class=\"mb-3\">\n <label class=\"form-label\" *ngIf=\"_fields.displayName\">{{ _fields.displayName }}</label>\n <ng-container *ngIf=\"ckOptions\">\n <ckeditor class=\"form-textarea\" [editor]=\"Editor\" *ngIf=\"Editor\" [config]=\"ckOptions\" (ready)=\"onReady($event)\"\n [formControlName]=\"_fields.field.name\">\n </ckeditor>\n </ng-container>\n <small class=\"form-text text-muted d-block\"\n *ngIf=\"_fields.field.description\">{{_fields.field.description}}</small>\n </div>\n </div>\n <button type=\"submit\" style=\"display: none;\" #submitclick></button>\n</form>", styles: ["@charset \"UTF-8\";:root .ck.ck-editor__editable_inline{min-height:160px!important}.ck.ck-editor__main>.ck-editor__editable{background:var(--bs-body-bg)!important}.ck.ck-toolbar,.ck.ck-button.ck-list-item-button,.ck.ck-button.ck-list-item-button.ck-on,.ck.ck-dropdown__panel{background:var(--bs-body-bg)!important}.ck.ck-editor__editable_inline{border-color:var(--ck-color-base-border)!important}\n"], dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i1$1.FormGroupName, selector: "[formGroupName]", inputs: ["formGroupName"] }, { kind: "directive", type: i4.ValidationGroupDirective, selector: "[formGroup],[formGroupName]", exportAs: ["validationGroup"] }, { kind: "directive", type: i4.ValidationDirective, selector: "[formControl],[formControlName]", exportAs: ["validationDirective"] }, { kind: "component", type: i4$1.CKEditorComponent, selector: "ckeditor", inputs: ["editor", "config", "data", "tagName", "watchdog", "editorWatchdogConfig", "disableTwoWayDataBinding", "disabled"], outputs: ["ready", "change", "blur", "focus", "error"] }] }); }
|
|
939
966
|
}
|
|
940
967
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: CkEditorControlComponent, decorators: [{
|
|
941
968
|
type: Component,
|
|
942
|
-
args: [{ selector: 'ck-editor-control', template: "<form [formGroup]=\"_entity\">\n <div formGroupName=\"extraProperties\">\n <div class=\"mb-3\">\n <label class=\"form-label\" *ngIf=\"_fields.displayName\">{{ _fields.displayName }}</label>\n <ng-container *ngIf=\"ckOptions\">\n
|
|
969
|
+
args: [{ selector: 'ck-editor-control', template: "<form [formGroup]=\"_entity\">\n <div formGroupName=\"extraProperties\">\n <div class=\"mb-3\">\n <label class=\"form-label\" *ngIf=\"_fields.displayName\">{{ _fields.displayName }}</label>\n <ng-container *ngIf=\"ckOptions\">\n <ckeditor class=\"form-textarea\" [editor]=\"Editor\" *ngIf=\"Editor\" [config]=\"ckOptions\" (ready)=\"onReady($event)\"\n [formControlName]=\"_fields.field.name\">\n </ckeditor>\n </ng-container>\n <small class=\"form-text text-muted d-block\"\n *ngIf=\"_fields.field.description\">{{_fields.field.description}}</small>\n </div>\n </div>\n <button type=\"submit\" style=\"display: none;\" #submitclick></button>\n</form>", styles: ["@charset \"UTF-8\";:root .ck.ck-editor__editable_inline{min-height:160px!important}.ck.ck-editor__main>.ck-editor__editable{background:var(--bs-body-bg)!important}.ck.ck-toolbar,.ck.ck-button.ck-list-item-button,.ck.ck-button.ck-list-item-button.ck-on,.ck.ck-dropdown__panel{background:var(--bs-body-bg)!important}.ck.ck-editor__editable_inline{border-color:var(--ck-color-base-border)!important}\n"] }]
|
|
943
970
|
}], ctorParameters: () => [], propDecorators: { fields: [{
|
|
944
971
|
type: Input
|
|
945
972
|
}], parentFiledName: [{
|
|
@@ -1070,5 +1097,5 @@ class isBase64UploadAdapter {
|
|
|
1070
1097
|
* Generated bundle index. Do not edit.
|
|
1071
1098
|
*/
|
|
1072
1099
|
|
|
1073
|
-
export { AddFieldControlGroup, CkEditorModule, SetCkEditorConfigsService, ckEditorFieldControlGroup, getExcludeAssignControl, isBase64UploadAdapter };
|
|
1100
|
+
export { AddFieldControlGroup, CkEditorModeEnum, CkEditorModeEnumOptions, CkEditorModule, SetCkEditorConfigsService, ckEditorFieldControlGroup, getExcludeAssignControl, isBase64UploadAdapter };
|
|
1074
1101
|
//# sourceMappingURL=dignite-ng-expand.ck-editor.mjs.map
|