@gravitee/ui-particles-angular 7.21.0 → 7.21.1-apim-1416-disable-formly-array-btns-2afb99e
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/esm2020/lib/gio-form-json-schema/type-component/array-type.component.mjs +9 -5
- package/esm2020/lib/gio-form-json-schema/type-component/multischema-type.component.mjs +21 -3
- package/fesm2015/gravitee-ui-particles-angular.mjs +26 -6
- package/fesm2015/gravitee-ui-particles-angular.mjs.map +1 -1
- package/fesm2020/gravitee-ui-particles-angular.mjs +26 -6
- package/fesm2020/gravitee-ui-particles-angular.mjs.map +1 -1
- package/lib/gio-form-json-schema/type-component/multischema-type.component.d.ts +6 -2
- package/package.json +3 -3
|
@@ -4094,14 +4094,16 @@ GioFjsArrayTypeComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0
|
|
|
4094
4094
|
<div *ngFor="let field of field.fieldGroup; let i = index" class="wrapper__rows__row">
|
|
4095
4095
|
<formly-field class="wrapper__rows__row__field" [field]="field"></formly-field>
|
|
4096
4096
|
<div class="wrapper__rows__row__remove">
|
|
4097
|
-
<button type="button" mat-icon-button aria-label="Remove" (click)="remove(i)">
|
|
4097
|
+
<button type="button" mat-icon-button aria-label="Remove" [disabled]="this.form?.disabled ?? false" (click)="remove(i)">
|
|
4098
4098
|
<mat-icon svgIcon="gio:cancel"></mat-icon>
|
|
4099
4099
|
</button>
|
|
4100
4100
|
</div>
|
|
4101
4101
|
</div>
|
|
4102
4102
|
|
|
4103
4103
|
<div>
|
|
4104
|
-
<button type="button" mat-stroked-button aria-label="Add" (click)="add()"
|
|
4104
|
+
<button type="button" mat-stroked-button aria-label="Add" [disabled]="this.form?.disabled ?? false" (click)="add()">
|
|
4105
|
+
<mat-icon svgIcon="gio:plus"></mat-icon> Add
|
|
4106
|
+
</button>
|
|
4105
4107
|
</div>
|
|
4106
4108
|
</div>
|
|
4107
4109
|
</div>
|
|
@@ -4130,14 +4132,16 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
4130
4132
|
<div *ngFor="let field of field.fieldGroup; let i = index" class="wrapper__rows__row">
|
|
4131
4133
|
<formly-field class="wrapper__rows__row__field" [field]="field"></formly-field>
|
|
4132
4134
|
<div class="wrapper__rows__row__remove">
|
|
4133
|
-
<button type="button" mat-icon-button aria-label="Remove" (click)="remove(i)">
|
|
4135
|
+
<button type="button" mat-icon-button aria-label="Remove" [disabled]="this.form?.disabled ?? false" (click)="remove(i)">
|
|
4134
4136
|
<mat-icon svgIcon="gio:cancel"></mat-icon>
|
|
4135
4137
|
</button>
|
|
4136
4138
|
</div>
|
|
4137
4139
|
</div>
|
|
4138
4140
|
|
|
4139
4141
|
<div>
|
|
4140
|
-
<button type="button" mat-stroked-button aria-label="Add" (click)="add()"
|
|
4142
|
+
<button type="button" mat-stroked-button aria-label="Add" [disabled]="this.form?.disabled ?? false" (click)="add()">
|
|
4143
|
+
<mat-icon svgIcon="gio:plus"></mat-icon> Add
|
|
4144
|
+
</button>
|
|
4141
4145
|
</div>
|
|
4142
4146
|
</div>
|
|
4143
4147
|
</div>
|
|
@@ -4228,12 +4232,28 @@ function bannerExtension(field) {
|
|
|
4228
4232
|
* limitations under the License.
|
|
4229
4233
|
*/
|
|
4230
4234
|
class GioFjsMultiSchemaTypeComponent extends FieldType {
|
|
4235
|
+
constructor(cdr) {
|
|
4236
|
+
super();
|
|
4237
|
+
this.cdr = cdr;
|
|
4238
|
+
this.unsubscribe$ = new Subject();
|
|
4239
|
+
}
|
|
4240
|
+
ngOnDestroy() {
|
|
4241
|
+
this.unsubscribe$.next();
|
|
4242
|
+
this.unsubscribe$.unsubscribe();
|
|
4243
|
+
}
|
|
4231
4244
|
ngOnInit() {
|
|
4232
4245
|
set(this.field, 'fieldGroup[0].props.appearance', 'fill');
|
|
4233
4246
|
set(this.field, 'fieldGroup[0].props.label', 'Select option');
|
|
4247
|
+
set(this.field, 'fieldGroup[0].props.disabled', this.form.disabled);
|
|
4248
|
+
this.form.valueChanges
|
|
4249
|
+
.pipe(tap(() => {
|
|
4250
|
+
set(this.field, 'fieldGroup[0].props.disabled', this.form.disabled);
|
|
4251
|
+
this.cdr.detectChanges();
|
|
4252
|
+
}), takeUntil(this.unsubscribe$))
|
|
4253
|
+
.subscribe();
|
|
4234
4254
|
}
|
|
4235
4255
|
}
|
|
4236
|
-
GioFjsMultiSchemaTypeComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: GioFjsMultiSchemaTypeComponent, deps:
|
|
4256
|
+
GioFjsMultiSchemaTypeComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: GioFjsMultiSchemaTypeComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
4237
4257
|
GioFjsMultiSchemaTypeComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: GioFjsMultiSchemaTypeComponent, selector: "gio-fjs-multi-schema-type", usesInheritance: true, ngImport: i0, template: `
|
|
4238
4258
|
<div class="wrapper">
|
|
4239
4259
|
<div class="wrapper__title" *ngIf="props.label">{{ props.label }}</div>
|
|
@@ -4256,7 +4276,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
4256
4276
|
<formly-field *ngFor="let f of field.fieldGroup" [field]="f"></formly-field>
|
|
4257
4277
|
</div>
|
|
4258
4278
|
`, styles: [".wrapper__title{font-size:16px;font-weight:500;line-height:24px;font:600 14px/20px Golos UI,Roboto,Helvetica Neue,sans-serif;letter-spacing:.4px;margin-bottom:4px}.wrapper:empty{display:none}.wrapper__error{font:400 12px/16px Golos UI,Roboto,Helvetica Neue,sans-serif;letter-spacing:normal;color:#ec4899}\n"] }]
|
|
4259
|
-
}] });
|
|
4279
|
+
}], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }]; } });
|
|
4260
4280
|
|
|
4261
4281
|
/*
|
|
4262
4282
|
* Copyright (C) 2023 The Gravitee team (http://gravitee.io)
|