@gravitee/ui-policy-studio-angular 7.17.3 → 7.18.0
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/components/flows-menu/gio-ps-flows-menu.component.mjs +5 -5
- package/esm2020/lib/components/step-form/gio-ps-step-form.component.mjs +3 -3
- package/esm2020/lib/gio-policy-studio.component.mjs +2 -2
- package/esm2020/lib/gio-policy-studio.module.mjs +6 -2
- package/esm2020/lib/gio-policy-studio.service.mjs +1 -1
- package/esm2020/lib/models/PolicySchemaFetcher.mjs +1 -1
- package/esm2020/testing/lib/components/step-form/gio-ps-step-form.harness.mjs +5 -1
- package/esm2020/testing/lib/models/PolicySchemaFetcher.mjs +1 -1
- package/fesm2015/gravitee-ui-policy-studio-angular-testing.mjs +6 -0
- package/fesm2015/gravitee-ui-policy-studio-angular-testing.mjs.map +1 -1
- package/fesm2015/gravitee-ui-policy-studio-angular.mjs +13 -10
- package/fesm2015/gravitee-ui-policy-studio-angular.mjs.map +1 -1
- package/fesm2020/gravitee-ui-policy-studio-angular-testing.mjs +4 -0
- package/fesm2020/gravitee-ui-policy-studio-angular-testing.mjs.map +1 -1
- package/fesm2020/gravitee-ui-policy-studio-angular.mjs +13 -10
- package/fesm2020/gravitee-ui-policy-studio-angular.mjs.map +1 -1
- package/lib/components/flows-menu/gio-ps-flows-menu.component.d.ts +1 -1
- package/lib/components/step-form/gio-ps-step-form.component.d.ts +1 -1
- package/lib/gio-policy-studio.module.d.ts +1 -1
- package/lib/gio-policy-studio.service.d.ts +3 -3
- package/lib/models/PolicySchemaFetcher.d.ts +1 -1
- package/package.json +1 -1
- package/testing/lib/components/step-form/gio-ps-step-form.harness.d.ts +1 -0
- package/testing/lib/models/PolicySchemaFetcher.d.ts +1 -1
|
@@ -3,7 +3,7 @@ import { Component, Inject, Input, EventEmitter, Output, Pipe, NgModule } from '
|
|
|
3
3
|
import * as i2 from '@angular/material/button';
|
|
4
4
|
import { MatButtonModule } from '@angular/material/button';
|
|
5
5
|
import * as i4$1 from '@gravitee/ui-particles-angular';
|
|
6
|
-
import { GioIconsModule, GioFormSlideToggleModule, GioFormTagsInputModule, GioBannerModule, GioFormJsonSchemaModule } from '@gravitee/ui-particles-angular';
|
|
6
|
+
import { GioIconsModule, GioFormSlideToggleModule, GioFormTagsInputModule, GioBannerModule, GioFormJsonSchemaModule, GioAsciidoctorModule } from '@gravitee/ui-particles-angular';
|
|
7
7
|
import * as i5$1 from '@angular/common';
|
|
8
8
|
import { CommonModule } from '@angular/common';
|
|
9
9
|
import * as i7 from '@angular/material/tooltip';
|
|
@@ -24,7 +24,7 @@ import * as i8$1 from '@angular/material/slide-toggle';
|
|
|
24
24
|
import { MatSlideToggleModule } from '@angular/material/slide-toggle';
|
|
25
25
|
import * as i4$2 from '@angular/material/menu';
|
|
26
26
|
import { MatMenuModule } from '@angular/material/menu';
|
|
27
|
-
import { cloneDeep, uniqueId, isEmpty, filter,
|
|
27
|
+
import { cloneDeep, uniqueId, isEmpty, filter, flatten, isEqual, differenceBy, omit, unionBy } from 'lodash';
|
|
28
28
|
import * as i3 from '@angular/material/icon';
|
|
29
29
|
import * as i6 from '@angular/material/core';
|
|
30
30
|
import { shareReplay, takeUntil, tap } from 'rxjs/operators';
|
|
@@ -546,10 +546,10 @@ class GioPolicyStudioStepFormComponent {
|
|
|
546
546
|
}
|
|
547
547
|
}
|
|
548
548
|
GioPolicyStudioStepFormComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: GioPolicyStudioStepFormComponent, deps: [{ token: GioPolicyStudioService }], target: i0.ɵɵFactoryTarget.Component });
|
|
549
|
-
GioPolicyStudioStepFormComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: GioPolicyStudioStepFormComponent, selector: "gio-ps-step-form", inputs: { step: "step", policy: "policy" }, outputs: { stepChange: "stepChange", isValid: "isValid" }, usesOnChanges: true, ngImport: i0, template: "<!--\n\n Copyright (C) 2023 The Gravitee team (http://gravitee.io)\n \n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n \n http://www.apache.org/licenses/LICENSE-2.0\n \n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License.\n\n-->\n\n<div class=\"settings\">\n <div class=\"settings__header\">Settings</div>\n\n <ng-container *ngIf=\"policySchema$ | async as policySchema\">\n <div *ngIf=\"stepForm\" class=\"settings__content\" [formGroup]=\"stepForm\">\n <mat-form-field>\n <mat-label>Description</mat-label>\n <input matInput formControlName=\"description\" cdkFocusInitial />\n <mat-hint>Describe how your policy works.</mat-hint>\n </mat-form-field>\n\n <gio-form-json-schema [jsonSchema]=\"$any(policySchema)\" formControlName=\"configuration\"></gio-form-json-schema>\n </div>\n </ng-container>\n</div>\n\n<div class=\"documentation\">\n <div class=\"documentation__header\">Documentation</div>\n\n <div class=\"documentation__content\"
|
|
549
|
+
GioPolicyStudioStepFormComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: GioPolicyStudioStepFormComponent, selector: "gio-ps-step-form", inputs: { step: "step", policy: "policy" }, outputs: { stepChange: "stepChange", isValid: "isValid" }, usesOnChanges: true, ngImport: i0, template: "<!--\n\n Copyright (C) 2023 The Gravitee team (http://gravitee.io)\n \n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n \n http://www.apache.org/licenses/LICENSE-2.0\n \n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License.\n\n-->\n\n<div class=\"settings\">\n <div class=\"settings__header\">Settings</div>\n\n <ng-container *ngIf=\"policySchema$ | async as policySchema\">\n <div *ngIf=\"stepForm\" class=\"settings__content\" [formGroup]=\"stepForm\">\n <mat-form-field>\n <mat-label>Description</mat-label>\n <input matInput formControlName=\"description\" cdkFocusInitial />\n <mat-hint>Describe how your policy works.</mat-hint>\n </mat-form-field>\n\n <gio-form-json-schema [jsonSchema]=\"$any(policySchema)\" formControlName=\"configuration\"></gio-form-json-schema>\n </div>\n </ng-container>\n</div>\n\n<div class=\"documentation\">\n <div class=\"documentation__header\">Documentation</div>\n\n <div class=\"documentation__content\" *ngIf=\"policyDocumentation$ | async as policyDocumentation\">\n <gio-asciidoctor [content]=\"policyDocumentation\"></gio-asciidoctor>\n </div>\n</div>\n", styles: [":host{display:flex;flex-direction:row;border:1px solid #d3d5dc;border-radius:8px}.settings{display:flex;flex:0 0 50%;flex-direction:column}.settings__header{border-right:1px solid #d3d5dc}.settings__content{display:flex;flex:1 1 auto;flex-direction:column;padding:16px;border-right:1px solid #d3d5dc}.documentation{display:flex;overflow:auto;flex:0 0 50%;flex-direction:column}.documentation__content{flex:1 1 auto;padding:16px}.settings__header,.documentation__header{padding:16px;border-bottom:1px solid #d3d5dc;font:600 14px/20px Golos UI,Roboto,Helvetica Neue,sans-serif;letter-spacing:.4px}\n"], components: [{ type: i4.MatFormField, selector: "mat-form-field", inputs: ["color", "appearance", "hideRequiredMarker", "hintLabel", "floatLabel"], exportAs: ["matFormField"] }, { type: i4$1.GioFormJsonSchemaComponent, selector: "gio-form-json-schema", inputs: ["jsonSchema", "options"] }, { type: i4$1.GioAsciidoctorComponent, selector: "gio-asciidoctor", inputs: ["content", "src"] }], directives: [{ type: i5$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i8.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i8.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i4.MatLabel, selector: "mat-label" }, { type: i9.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { type: i8.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i8.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i8.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { type: i4.MatHint, selector: "mat-hint", inputs: ["align", "id"] }], pipes: { "async": i5$1.AsyncPipe } });
|
|
550
550
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: GioPolicyStudioStepFormComponent, decorators: [{
|
|
551
551
|
type: Component,
|
|
552
|
-
args: [{ selector: 'gio-ps-step-form', template: "<!--\n\n Copyright (C) 2023 The Gravitee team (http://gravitee.io)\n \n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n \n http://www.apache.org/licenses/LICENSE-2.0\n \n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License.\n\n-->\n\n<div class=\"settings\">\n <div class=\"settings__header\">Settings</div>\n\n <ng-container *ngIf=\"policySchema$ | async as policySchema\">\n <div *ngIf=\"stepForm\" class=\"settings__content\" [formGroup]=\"stepForm\">\n <mat-form-field>\n <mat-label>Description</mat-label>\n <input matInput formControlName=\"description\" cdkFocusInitial />\n <mat-hint>Describe how your policy works.</mat-hint>\n </mat-form-field>\n\n <gio-form-json-schema [jsonSchema]=\"$any(policySchema)\" formControlName=\"configuration\"></gio-form-json-schema>\n </div>\n </ng-container>\n</div>\n\n<div class=\"documentation\">\n <div class=\"documentation__header\">Documentation</div>\n\n <div class=\"documentation__content\"
|
|
552
|
+
args: [{ selector: 'gio-ps-step-form', template: "<!--\n\n Copyright (C) 2023 The Gravitee team (http://gravitee.io)\n \n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n \n http://www.apache.org/licenses/LICENSE-2.0\n \n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License.\n\n-->\n\n<div class=\"settings\">\n <div class=\"settings__header\">Settings</div>\n\n <ng-container *ngIf=\"policySchema$ | async as policySchema\">\n <div *ngIf=\"stepForm\" class=\"settings__content\" [formGroup]=\"stepForm\">\n <mat-form-field>\n <mat-label>Description</mat-label>\n <input matInput formControlName=\"description\" cdkFocusInitial />\n <mat-hint>Describe how your policy works.</mat-hint>\n </mat-form-field>\n\n <gio-form-json-schema [jsonSchema]=\"$any(policySchema)\" formControlName=\"configuration\"></gio-form-json-schema>\n </div>\n </ng-container>\n</div>\n\n<div class=\"documentation\">\n <div class=\"documentation__header\">Documentation</div>\n\n <div class=\"documentation__content\" *ngIf=\"policyDocumentation$ | async as policyDocumentation\">\n <gio-asciidoctor [content]=\"policyDocumentation\"></gio-asciidoctor>\n </div>\n</div>\n", styles: [":host{display:flex;flex-direction:row;border:1px solid #d3d5dc;border-radius:8px}.settings{display:flex;flex:0 0 50%;flex-direction:column}.settings__header{border-right:1px solid #d3d5dc}.settings__content{display:flex;flex:1 1 auto;flex-direction:column;padding:16px;border-right:1px solid #d3d5dc}.documentation{display:flex;overflow:auto;flex:0 0 50%;flex-direction:column}.documentation__content{flex:1 1 auto;padding:16px}.settings__header,.documentation__header{padding:16px;border-bottom:1px solid #d3d5dc;font:600 14px/20px Golos UI,Roboto,Helvetica Neue,sans-serif;letter-spacing:.4px}\n"] }]
|
|
553
553
|
}], ctorParameters: function () { return [{ type: GioPolicyStudioService }]; }, propDecorators: { step: [{
|
|
554
554
|
type: Input
|
|
555
555
|
}], policy: [{
|
|
@@ -1044,11 +1044,11 @@ class GioPolicyStudioFlowsMenuComponent {
|
|
|
1044
1044
|
this.selectedFlowChange = new EventEmitter();
|
|
1045
1045
|
this.flowsGroupsChange = new EventEmitter();
|
|
1046
1046
|
this.flowExecutionChange = new EventEmitter();
|
|
1047
|
-
this.
|
|
1047
|
+
this.flowGroupMenuItems = [];
|
|
1048
1048
|
}
|
|
1049
1049
|
ngOnChanges(changes) {
|
|
1050
1050
|
if (changes.flowsGroups || changes.selectedFlow) {
|
|
1051
|
-
this.
|
|
1051
|
+
this.flowGroupMenuItems = cloneDeep(this.flowsGroups).map(flowGroup => {
|
|
1052
1052
|
return {
|
|
1053
1053
|
...flowGroup,
|
|
1054
1054
|
flows: flowGroup.flows.map(flow => {
|
|
@@ -1166,10 +1166,10 @@ class GioPolicyStudioFlowsMenuComponent {
|
|
|
1166
1166
|
}
|
|
1167
1167
|
}
|
|
1168
1168
|
GioPolicyStudioFlowsMenuComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: GioPolicyStudioFlowsMenuComponent, deps: [{ token: i1.MatDialog }], target: i0.ɵɵFactoryTarget.Component });
|
|
1169
|
-
GioPolicyStudioFlowsMenuComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: GioPolicyStudioFlowsMenuComponent, selector: "gio-ps-flows-menu", inputs: { apiType: "apiType", flowExecution: "flowExecution", flowsGroups: "flowsGroups", selectedFlow: "selectedFlow", entrypoints: "entrypoints" }, outputs: { selectedFlowChange: "selectedFlowChange", flowsGroupsChange: "flowsGroupsChange", flowExecutionChange: "flowExecutionChange" }, usesOnChanges: true, ngImport: i0, template: "<!--\n\n Copyright (C) 2023 The Gravitee team (http://gravitee.io)\n \n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n \n http://www.apache.org/licenses/LICENSE-2.0\n \n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License.\n\n-->\n\n<div class=\"header\">\n <div class=\"header__label\">\n Flows <mat-icon svgIcon=\"gio:info\" matTooltip=\"Flows allow you to apply different policies on your API event phases\"></mat-icon>\n </div>\n <div class=\"header__configBtn\">\n <button class=\"header__configBtn_edit\" mat-stroked-button mat-icon-button (click)=\"onConfigureExecution(flowExecution)\">\n <mat-icon svgIcon=\"gio:settings\"></mat-icon>\n </button>\n </div>\n</div>\n\n<div class=\"list\">\n <div *ngFor=\"let flowsGroup of
|
|
1169
|
+
GioPolicyStudioFlowsMenuComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: GioPolicyStudioFlowsMenuComponent, selector: "gio-ps-flows-menu", inputs: { apiType: "apiType", flowExecution: "flowExecution", flowsGroups: "flowsGroups", selectedFlow: "selectedFlow", entrypoints: "entrypoints" }, outputs: { selectedFlowChange: "selectedFlowChange", flowsGroupsChange: "flowsGroupsChange", flowExecutionChange: "flowExecutionChange" }, usesOnChanges: true, ngImport: i0, template: "<!--\n\n Copyright (C) 2023 The Gravitee team (http://gravitee.io)\n \n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n \n http://www.apache.org/licenses/LICENSE-2.0\n \n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License.\n\n-->\n\n<div class=\"header\">\n <div class=\"header__label\">\n Flows <mat-icon svgIcon=\"gio:info\" matTooltip=\"Flows allow you to apply different policies on your API event phases\"></mat-icon>\n </div>\n <div class=\"header__configBtn\">\n <button class=\"header__configBtn_edit\" mat-stroked-button mat-icon-button (click)=\"onConfigureExecution(flowExecution)\">\n <mat-icon svgIcon=\"gio:settings\"></mat-icon>\n </button>\n </div>\n</div>\n\n<div class=\"list\">\n <div *ngFor=\"let flowsGroup of flowGroupMenuItems\" class=\"list__flowsGroup\">\n <div class=\"list__flowsGroup__header\">\n <div class=\"list__flowsGroup__header__label\">\n <mat-icon *ngIf=\"flowsGroup._icon\" [svgIcon]=\"flowsGroup._icon\"></mat-icon>\n <span>{{ flowsGroup.name }}</span>\n </div>\n <div class=\"list__flowsGroup__header__addBtn\">\n <button mat-icon-button (click)=\"onAddFlow(flowsGroup)\"><mat-icon svgIcon=\"gio:plus\" matTooltip=\"New flow\"></mat-icon></button>\n </div>\n </div>\n\n <div\n *ngFor=\"let flow of flowsGroup.flows\"\n class=\"list__flowsGroup__flow\"\n [class.selected]=\"flow.selected\"\n (click)=\"selectFlow(flowsGroup._id, flow._id)\"\n (mouseout)=\"flow.mouseOver = false\"\n (mouseover)=\"flow.mouseOver = true\"\n >\n <div *ngIf=\"flow.name\" class=\"list__flowsGroup__flow__name\" [attr.title]=\"flow.name\">\n {{ flow.name }}\n </div>\n <div class=\"list__flowsGroup__flow__infos\">\n <div class=\"list__flowsGroup__flow__infos__badges\">\n <span *ngFor=\"let badge of flow.badges\" class=\"list__flowsGroup__flow__infos__badges__badge\" [ngClass]=\"badge.class\">{{\n badge.label\n }}</span>\n </div>\n <div class=\"list__flowsGroup__flow__infos__pathOrChannelLabel\">{{ flow.pathOrChannelLabel }}</div>\n </div>\n </div>\n </div>\n</div>\n", styles: [":host{display:flex;max-height:100%;flex-direction:column;padding-top:16px}.header{display:flex;align-items:center;padding:0 16px;margin-bottom:16px}.header__label{font:600 16px/24px Golos UI,Roboto,Helvetica Neue,sans-serif;letter-spacing:.4px;display:flex;flex:1 1 auto;align-items:center;margin-bottom:0;gap:8px}.header__configBtn{margin-left:8px}.list{padding:0 16px;overflow-y:overlay}.list__flowsGroup{display:flex;flex-direction:column;padding-bottom:8px;gap:8px}.list__flowsGroup__header{display:flex;align-items:center;padding:8px 8px 8px 10px;border-radius:8px;background-color:#cdc5f7}.list__flowsGroup__header__label{font:600 14px/20px Golos UI,Roboto,Helvetica Neue,sans-serif;letter-spacing:.4px;display:flex;flex:1 1 auto;align-items:center;gap:8px}.list__flowsGroup__header__label>mat-icon{width:22px;height:22px;flex:0 0 auto}.list__flowsGroup__header__label>span{display:-webkit-box;overflow:hidden;flex:1 1 auto;-webkit-box-orient:vertical;-webkit-line-clamp:2}.list__flowsGroup__header__addBtn{margin-left:8px}.list__flowsGroup__flow{display:flex;height:68px;flex-direction:column;justify-content:center;padding:7px;border:1px solid #d3d5dc;border-radius:8px;gap:8px}.list__flowsGroup__flow:hover,.list__flowsGroup__flow.selected{padding:6px;border:2px solid #876fec;cursor:pointer}.list__flowsGroup__flow__name{overflow:hidden;padding-left:4px;text-overflow:ellipsis;white-space:nowrap}.list__flowsGroup__flow__infos{display:flex;align-items:center}.list__flowsGroup__flow__infos__badges{flex:0 0 auto}.list__flowsGroup__flow__infos__badges__badge{width:auto}.list__flowsGroup__flow__infos__pathOrChannelLabel{flex:1 1 auto}\n"], components: [{ type: i3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i2.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }], directives: [{ type: i7.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }, { type: i5$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i5$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i5$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] });
|
|
1170
1170
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: GioPolicyStudioFlowsMenuComponent, decorators: [{
|
|
1171
1171
|
type: Component,
|
|
1172
|
-
args: [{ selector: 'gio-ps-flows-menu', template: "<!--\n\n Copyright (C) 2023 The Gravitee team (http://gravitee.io)\n \n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n \n http://www.apache.org/licenses/LICENSE-2.0\n \n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License.\n\n-->\n\n<div class=\"header\">\n <div class=\"header__label\">\n Flows <mat-icon svgIcon=\"gio:info\" matTooltip=\"Flows allow you to apply different policies on your API event phases\"></mat-icon>\n </div>\n <div class=\"header__configBtn\">\n <button class=\"header__configBtn_edit\" mat-stroked-button mat-icon-button (click)=\"onConfigureExecution(flowExecution)\">\n <mat-icon svgIcon=\"gio:settings\"></mat-icon>\n </button>\n </div>\n</div>\n\n<div class=\"list\">\n <div *ngFor=\"let flowsGroup of
|
|
1172
|
+
args: [{ selector: 'gio-ps-flows-menu', template: "<!--\n\n Copyright (C) 2023 The Gravitee team (http://gravitee.io)\n \n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n \n http://www.apache.org/licenses/LICENSE-2.0\n \n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License.\n\n-->\n\n<div class=\"header\">\n <div class=\"header__label\">\n Flows <mat-icon svgIcon=\"gio:info\" matTooltip=\"Flows allow you to apply different policies on your API event phases\"></mat-icon>\n </div>\n <div class=\"header__configBtn\">\n <button class=\"header__configBtn_edit\" mat-stroked-button mat-icon-button (click)=\"onConfigureExecution(flowExecution)\">\n <mat-icon svgIcon=\"gio:settings\"></mat-icon>\n </button>\n </div>\n</div>\n\n<div class=\"list\">\n <div *ngFor=\"let flowsGroup of flowGroupMenuItems\" class=\"list__flowsGroup\">\n <div class=\"list__flowsGroup__header\">\n <div class=\"list__flowsGroup__header__label\">\n <mat-icon *ngIf=\"flowsGroup._icon\" [svgIcon]=\"flowsGroup._icon\"></mat-icon>\n <span>{{ flowsGroup.name }}</span>\n </div>\n <div class=\"list__flowsGroup__header__addBtn\">\n <button mat-icon-button (click)=\"onAddFlow(flowsGroup)\"><mat-icon svgIcon=\"gio:plus\" matTooltip=\"New flow\"></mat-icon></button>\n </div>\n </div>\n\n <div\n *ngFor=\"let flow of flowsGroup.flows\"\n class=\"list__flowsGroup__flow\"\n [class.selected]=\"flow.selected\"\n (click)=\"selectFlow(flowsGroup._id, flow._id)\"\n (mouseout)=\"flow.mouseOver = false\"\n (mouseover)=\"flow.mouseOver = true\"\n >\n <div *ngIf=\"flow.name\" class=\"list__flowsGroup__flow__name\" [attr.title]=\"flow.name\">\n {{ flow.name }}\n </div>\n <div class=\"list__flowsGroup__flow__infos\">\n <div class=\"list__flowsGroup__flow__infos__badges\">\n <span *ngFor=\"let badge of flow.badges\" class=\"list__flowsGroup__flow__infos__badges__badge\" [ngClass]=\"badge.class\">{{\n badge.label\n }}</span>\n </div>\n <div class=\"list__flowsGroup__flow__infos__pathOrChannelLabel\">{{ flow.pathOrChannelLabel }}</div>\n </div>\n </div>\n </div>\n</div>\n", styles: [":host{display:flex;max-height:100%;flex-direction:column;padding-top:16px}.header{display:flex;align-items:center;padding:0 16px;margin-bottom:16px}.header__label{font:600 16px/24px Golos UI,Roboto,Helvetica Neue,sans-serif;letter-spacing:.4px;display:flex;flex:1 1 auto;align-items:center;margin-bottom:0;gap:8px}.header__configBtn{margin-left:8px}.list{padding:0 16px;overflow-y:overlay}.list__flowsGroup{display:flex;flex-direction:column;padding-bottom:8px;gap:8px}.list__flowsGroup__header{display:flex;align-items:center;padding:8px 8px 8px 10px;border-radius:8px;background-color:#cdc5f7}.list__flowsGroup__header__label{font:600 14px/20px Golos UI,Roboto,Helvetica Neue,sans-serif;letter-spacing:.4px;display:flex;flex:1 1 auto;align-items:center;gap:8px}.list__flowsGroup__header__label>mat-icon{width:22px;height:22px;flex:0 0 auto}.list__flowsGroup__header__label>span{display:-webkit-box;overflow:hidden;flex:1 1 auto;-webkit-box-orient:vertical;-webkit-line-clamp:2}.list__flowsGroup__header__addBtn{margin-left:8px}.list__flowsGroup__flow{display:flex;height:68px;flex-direction:column;justify-content:center;padding:7px;border:1px solid #d3d5dc;border-radius:8px;gap:8px}.list__flowsGroup__flow:hover,.list__flowsGroup__flow.selected{padding:6px;border:2px solid #876fec;cursor:pointer}.list__flowsGroup__flow__name{overflow:hidden;padding-left:4px;text-overflow:ellipsis;white-space:nowrap}.list__flowsGroup__flow__infos{display:flex;align-items:center}.list__flowsGroup__flow__infos__badges{flex:0 0 auto}.list__flowsGroup__flow__infos__badges__badge{width:auto}.list__flowsGroup__flow__infos__pathOrChannelLabel{flex:1 1 auto}\n"] }]
|
|
1173
1173
|
}], ctorParameters: function () { return [{ type: i1.MatDialog }]; }, propDecorators: { apiType: [{
|
|
1174
1174
|
type: Input
|
|
1175
1175
|
}], flowExecution: [{
|
|
@@ -1259,7 +1259,7 @@ class GioPolicyStudioComponent {
|
|
|
1259
1259
|
this.flowsGroups = getFlowsGroups(this.commonFlows, this.plans);
|
|
1260
1260
|
this.initialFlowsGroups = cloneDeep(this.flowsGroups);
|
|
1261
1261
|
// Select first flow by default on first load
|
|
1262
|
-
this.selectedFlow = this.flowsGroups
|
|
1262
|
+
this.selectedFlow = flatten(this.flowsGroups.map(flowGroup => flowGroup.flows))[0];
|
|
1263
1263
|
}
|
|
1264
1264
|
if (changes.policySchemaFetcher) {
|
|
1265
1265
|
this.policyStudioService.setPolicySchemaFetcher(this.policySchemaFetcher);
|
|
@@ -1433,7 +1433,8 @@ GioPolicyStudioModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", v
|
|
|
1433
1433
|
GioFormSlideToggleModule,
|
|
1434
1434
|
GioFormTagsInputModule,
|
|
1435
1435
|
GioBannerModule,
|
|
1436
|
-
GioFormJsonSchemaModule
|
|
1436
|
+
GioFormJsonSchemaModule,
|
|
1437
|
+
GioAsciidoctorModule], exports: [GioPolicyStudioComponent] });
|
|
1437
1438
|
GioPolicyStudioModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: GioPolicyStudioModule, providers: [GioPolicyStudioService], imports: [[
|
|
1438
1439
|
CommonModule,
|
|
1439
1440
|
ReactiveFormsModule,
|
|
@@ -1451,6 +1452,7 @@ GioPolicyStudioModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", v
|
|
|
1451
1452
|
GioFormTagsInputModule,
|
|
1452
1453
|
GioBannerModule,
|
|
1453
1454
|
GioFormJsonSchemaModule,
|
|
1455
|
+
GioAsciidoctorModule,
|
|
1454
1456
|
]] });
|
|
1455
1457
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: GioPolicyStudioModule, decorators: [{
|
|
1456
1458
|
type: NgModule,
|
|
@@ -1487,6 +1489,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
1487
1489
|
GioFormTagsInputModule,
|
|
1488
1490
|
GioBannerModule,
|
|
1489
1491
|
GioFormJsonSchemaModule,
|
|
1492
|
+
GioAsciidoctorModule,
|
|
1490
1493
|
],
|
|
1491
1494
|
exports: [GioPolicyStudioComponent],
|
|
1492
1495
|
providers: [GioPolicyStudioService],
|