@openziti/ziti-console-lib 0.8.1 → 0.9.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/assets/scripts/model/tags.js +4 -24
- package/assets/templates/header.htm +0 -1
- package/esm2022/lib/features/projectable-forms/config-type/config-type-form.component.mjs +257 -0
- package/esm2022/lib/features/projectable-forms/config-type/config-type-form.service.mjs +94 -0
- package/esm2022/lib/features/projectable-forms/service/simple-service/simple-service.component.mjs +3 -3
- package/esm2022/lib/models/config-type.mjs +10 -0
- package/esm2022/lib/pages/config-types/config-types-page.component.mjs +129 -0
- package/esm2022/lib/pages/config-types/config-types-page.service.mjs +134 -0
- package/esm2022/lib/pages/configurations/configurations-page.component.mjs +2 -2
- package/esm2022/lib/services/login-service.class.mjs +2 -1
- package/esm2022/lib/services/validation.service.mjs +10 -1
- package/esm2022/lib/shared/list-page-component.class.mjs +7 -2
- package/esm2022/lib/shared/list-page-service.class.mjs +7 -7
- package/esm2022/lib/version.mjs +2 -2
- package/esm2022/lib/ziti-console-lib.module.mjs +11 -1
- package/esm2022/public-api.mjs +3 -1
- package/fesm2022/openziti-ziti-console-lib.mjs +594 -12
- package/fesm2022/openziti-ziti-console-lib.mjs.map +1 -1
- package/lib/features/projectable-forms/config-type/config-type-form.component.d.ts +64 -0
- package/lib/features/projectable-forms/config-type/config-type-form.component.d.ts.map +1 -0
- package/lib/features/projectable-forms/config-type/config-type-form.service.d.ts +27 -0
- package/lib/features/projectable-forms/config-type/config-type-form.service.d.ts.map +1 -0
- package/lib/models/config-type.d.ts +7 -0
- package/lib/models/config-type.d.ts.map +1 -0
- package/lib/pages/config-types/config-types-page.component.d.ts +31 -0
- package/lib/pages/config-types/config-types-page.component.d.ts.map +1 -0
- package/lib/pages/config-types/config-types-page.service.d.ts +29 -0
- package/lib/pages/config-types/config-types-page.service.d.ts.map +1 -0
- package/lib/services/login-service.class.d.ts +1 -0
- package/lib/services/login-service.class.d.ts.map +1 -1
- package/lib/services/validation.service.d.ts +1 -0
- package/lib/services/validation.service.d.ts.map +1 -1
- package/lib/shared/list-page-component.class.d.ts +1 -0
- package/lib/shared/list-page-component.class.d.ts.map +1 -1
- package/lib/shared/list-page-service.class.d.ts +1 -3
- package/lib/shared/list-page-service.class.d.ts.map +1 -1
- package/lib/ziti-console-lib.module.d.ts +82 -80
- package/lib/ziti-console-lib.module.d.ts.map +1 -1
- package/package.json +1 -1
- package/public-api.d.ts +2 -0
- package/public-api.d.ts.map +1 -1
- package/assets/scripts/components/uploader.js +0 -74
|
@@ -748,6 +748,15 @@ class ValidationService {
|
|
|
748
748
|
return false;
|
|
749
749
|
}
|
|
750
750
|
}
|
|
751
|
+
isValidJSON(val) {
|
|
752
|
+
try {
|
|
753
|
+
const jsonString = JSON.stringify(val);
|
|
754
|
+
return typeof jsonString === 'string' && jsonString !== '';
|
|
755
|
+
}
|
|
756
|
+
catch (e) {
|
|
757
|
+
return false;
|
|
758
|
+
}
|
|
759
|
+
}
|
|
751
760
|
redefineObject(obj) {
|
|
752
761
|
for (let prop in obj) {
|
|
753
762
|
if (Array.isArray(obj[prop]) && obj[prop].length == 0) {
|
|
@@ -871,6 +880,7 @@ let LoginServiceClass = class LoginServiceClass {
|
|
|
871
880
|
this.settingsService = settingsService;
|
|
872
881
|
this.router = router;
|
|
873
882
|
this.growlerService = growlerService;
|
|
883
|
+
this.checkingControllerOrigin = false;
|
|
874
884
|
this.loginDialogOpen = false;
|
|
875
885
|
this.isCertBasedAuth = false;
|
|
876
886
|
this.serviceUrl = '';
|
|
@@ -2887,20 +2897,20 @@ let ListPageServiceClass = class ListPageServiceClass {
|
|
|
2887
2897
|
this.filterService.filtering.next(false);
|
|
2888
2898
|
});
|
|
2889
2899
|
}
|
|
2890
|
-
|
|
2891
|
-
const
|
|
2900
|
+
checkForAssociatedEntities(items, type, associatedType) {
|
|
2901
|
+
const itemsWithAssociations = [];
|
|
2892
2902
|
const promises = [];
|
|
2893
|
-
|
|
2894
|
-
const prom = this.dataService.getSubdata(
|
|
2903
|
+
items.forEach((config) => {
|
|
2904
|
+
const prom = this.dataService.getSubdata(type, config.id, associatedType).then((result) => {
|
|
2895
2905
|
const services = result.data || [];
|
|
2896
2906
|
if (services.length > 0) {
|
|
2897
|
-
|
|
2907
|
+
itemsWithAssociations.push(config);
|
|
2898
2908
|
}
|
|
2899
2909
|
});
|
|
2900
2910
|
promises.push(prom);
|
|
2901
2911
|
});
|
|
2902
2912
|
return Promise.all(promises).then(() => {
|
|
2903
|
-
return
|
|
2913
|
+
return itemsWithAssociations;
|
|
2904
2914
|
});
|
|
2905
2915
|
}
|
|
2906
2916
|
removeItems(ids) {
|
|
@@ -2958,6 +2968,7 @@ class ListPageComponent {
|
|
|
2958
2968
|
this.selectedItems = [];
|
|
2959
2969
|
this.columnDefs = [];
|
|
2960
2970
|
this.rowData = [];
|
|
2971
|
+
this.reservedNames = [];
|
|
2961
2972
|
this.filterApplied = false;
|
|
2962
2973
|
this.modalOpen = false;
|
|
2963
2974
|
this.gridObj = {};
|
|
@@ -2996,7 +3007,11 @@ class ListPageComponent {
|
|
|
2996
3007
|
let itemSelected = false;
|
|
2997
3008
|
this.selectedItems = [];
|
|
2998
3009
|
this.rowData.forEach((item) => {
|
|
2999
|
-
|
|
3010
|
+
const reserved = this.reservedNames?.includes(item.name);
|
|
3011
|
+
if (reserved) {
|
|
3012
|
+
item.selected = false;
|
|
3013
|
+
}
|
|
3014
|
+
else if (toggledItem?.id && toggledItem?.id === item?.id) {
|
|
3000
3015
|
item.selected = toggledItem.selected;
|
|
3001
3016
|
}
|
|
3002
3017
|
if (item.selected) {
|
|
@@ -8132,7 +8147,7 @@ class ConfigurationsPageComponent extends ListPageComponent {
|
|
|
8132
8147
|
const selectedItems = this.rowData.filter((row) => {
|
|
8133
8148
|
return row.selected;
|
|
8134
8149
|
});
|
|
8135
|
-
this.svc.
|
|
8150
|
+
this.svc.checkForAssociatedEntities(selectedItems, 'configs', 'services').then((configsWithAssociations) => {
|
|
8136
8151
|
const label = selectedItems.length > 1 ? 'configurations' : 'configuration';
|
|
8137
8152
|
if (configsWithAssociations.length > 0) {
|
|
8138
8153
|
this.confirmAssociatedDelete(configsWithAssociations, selectedItems, label);
|
|
@@ -17967,11 +17982,11 @@ class SimpleServiceComponent extends ProjectableForm {
|
|
|
17967
17982
|
clear() {
|
|
17968
17983
|
}
|
|
17969
17984
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: SimpleServiceComponent, deps: [{ token: SETTINGS_SERVICE }, { token: ServiceFormService }, { token: ZITI_DATA_SERVICE }, { token: GrowlerService }, { token: SERVICE_EXTENSION_SERVICE }, { token: i3$2.MatDialog }, { token: ValidationService }, { token: ServicesPageService }, { token: i4.Router }, { token: i4.ActivatedRoute }, { token: i1$4.Location }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
17970
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: SimpleServiceComponent, selector: "lib-simple-service", inputs: { serviceRoleAttributes: "serviceRoleAttributes", identityRoleAttributes: "identityRoleAttributes", identityNamedAttributes: "identityNamedAttributes" }, outputs: { close: "close", selected: "selected" }, usesInheritance: true, ngImport: i0, template: "<div class=\"projectable-form-wrapper simple-service-wrapper\"\n (keyup.enter)=\"save($event)\"\n (keyup.escape)=\"closeModal(true, false, 'cards', $event)\"\n tabindex=\"0\"\n>\n <lib-form-header\n [data]=\"formData\"\n [title]=\"showForm ? 'Create a Simple Service' : 'Service Creation Summary'\"\n [actionButtonText]=\"'Save'\"\n (actionRequested)=\"headerActionRequested($event)\"\n [(formView)]=\"formView\"\n ></lib-form-header>\n <div class=\"simple-service-form-container projectable-form-container\">\n <div class=\"form-group-column three-fifths\" *ngIf=\"showForm\">\n <div id=\"InlineServiceArea\" class=\"anyadd\">\n <div class=\"simple-service-inputs\">\n <lib-form-field-container [title]=\"'Service Details'\">\n <div class=\"form-field-input-group service-group\">\n <div class=\"form-field-sub-group\">\n <div class=\"config-title-row\">\n <span class=\"form-field-title\">Service Name</span>\n </div>\n <input\n class=\"form-field-input\"\n placeholder=\"Name this service\"\n autofocus\n #nameFieldInput\n [ngClass]=\"{error: errors.name}\"\n [(ngModel)]=\"serviceApiData.name\"\n (keyup)=\"serviceNameChanged($event)\"\n (change)=\"validateServiceName()\"\n />\n </div>\n <div class=\"form-field-sub-group\">\n <div class=\"config-title-row\">\n <span class=\"form-field-title\">SELECT OR CREATE SERVICE ATTRIBUTES</span>\n </div>\n <lib-tag-selector\n [(selectedRoleAttributes)]=\"serviceApiData.roleAttributes\"\n [availableRoleAttributes]=\"serviceRoleAttributes\"\n [placeholder]=\"'Add attributes to group services'\"\n ></lib-tag-selector>\n </div>\n </div>\n </lib-form-field-container>\n </div>\n </div>\n </div>\n <div class=\"simple-service-center-content\" *ngIf=\"showForm\">\n <div class=\"form-group-row\">\n <lib-form-field-container\n [title]=\"'ACCESSING CONFIGURATION'\"\n [contentStyle]=\"'z-index: 10001'\"\n [helpText]=\"'How will client applications use this service? Specify a hostname/IP and port, or use the "SDK Only" toggle for an application embedded configuration.'\"\n >\n <div class=\"form-field-input-group accessing-group\">\n <div class=\"form-field-sub-group\">\n <div class=\"config-title-row\">\n <span class=\"form-field-title\">What identities can access this service?</span>\n </div>\n <lib-tag-selector\n [(selectedNamedAttributes)]=\"dialPolicyNamedAttributes\"\n [(selectedRoleAttributes)]=\"dialPolicyRoleAttributes\"\n [availableNamedAttributes]=\"identityNamedAttributes\"\n [availableRoleAttributes]=\"identityRoleAttributes\"\n [placeholder]=\"'Select identity attributes to grant access'\"\n [hasError]=\"errors.dialIdentities\"\n (selectedNamedAttributesChange)=\"validateDialIdentities()\"\n (selectedRoleAttributesChange)=\"validateDialIdentities()\"\n (filterChange)=\"getIdentityNamedAttributes($event)\"\n ></lib-tag-selector>\n </div>\n <div class=\"form-field-sub-group\">\n <div class=\"config-title-row\">\n <span class=\"form-field-title\">How will the service be accessed?</span>\n </div>\n <div class=\"grid addressPort\">\n <div class=\"config-item-container\">\n <span class=\"config-item-label\">SDK ONLY</span>\n <div\n class=\"sdk-toggle form-field-toggle\"\n >\n <div class=\"switchGrid\">\n <div>\n <div\n (click)=\"toggleSdkOnlyDial()\"\n [ngClass]=\"{ on: sdkOnlyDial }\"\n class=\"toggle\"\n >\n <span [hidden]=\"!sdkOnlyDial\" class=\"on-label\">YES</span>\n <span [hidden]=\"sdkOnlyDial\" class=\"off-label\">NO</span>\n <div class=\"switch\"></div>\n </div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"config-item-container\" [ngClass]=\"{disabled: sdkOnlyDial}\">\n <div class=\"config-hostname-label\">\n <span class=\"config-item-label\">HOSTNAME / IP</span>\n <div\n class=\"form-field-info infoicon\"\n matTooltip=\"Accessing hostnames must include a '.'\"\n matTooltipPosition=\"above\"\n ></div>\n <span *ngIf=\"errors.interceptAddressFormat\" class=\"error-label\">Accessing hostnames must include a '.'</span>\n </div>\n <input id=\"HowTo\" type=\"text\" maxlength=\"100\" data-i18n=\"EgHost\" (change)=\"validateInterceptAddress()\" [ngClass]=\"{error: errors.interceptAddress}\" [placeholder]=\"sdkOnlyDial ? '' : 'e.g. myservice.ziti'\" [(ngModel)]=\"sdkOnlyDial ? '' : interceptConfigApiData.data.addresses[0]\">\n </div>\n <div class=\"config-item-container\" [ngClass]=\"{disabled: sdkOnlyDial}\">\n <span class=\"config-item-label\">PORT</span>\n <input id=\"HowToPort\" type=\"number\" maxlength=\"10\" (change)=\"validateInterceptPort()\" [ngClass]=\"{error: errors.interceptPort}\" [placeholder]=\"sdkOnlyDial ? '' : 443\" (keyup)=\"interceptPortChanged($event)\" [(ngModel)]=\"sdkOnlyDial ? '' : interceptPort\">\n </div>\n </div>\n </div>\n </div>\n </lib-form-field-container>\n <lib-form-field-container\n [title]=\"'HOSTING CONFIGURATION'\"\n [contentStyle]=\"'z-index: 10000'\"\n [helpText]=\"'Where should traffic for this service be sent? Specify a protocol, hostname/IP, and port, or use the "SDK Only" toggle for an application embedded configuration.'\"\n\n >\n <div class=\"form-field-input-group hosting-group\">\n <div class=\"form-field-sub-group\">\n <div class=\"config-title-row\">\n <span class=\"form-field-title\">What identities can host this service?</span>\n </div>\n <lib-tag-selector\n [(selectedNamedAttributes)]=\"bindPolicyNamedAttributes\"\n [(selectedRoleAttributes)]=\"bindPolicyRoleAttributes\"\n [availableNamedAttributes]=\"identityNamedAttributes\"\n [availableRoleAttributes]=\"identityRoleAttributes\"\n [placeholder]=\"'Select identity attributes'\"\n [hasError]=\"errors.bindIdentities\"\n (selectedNamedAttributesChange)=\"validateBindIdentities()\"\n (selectedRoleAttributesChange)=\"validateBindIdentities()\"\n ></lib-tag-selector>\n </div>\n <div class=\"form-field-sub-group\">\n <div class=\"config-title-row\">\n <span class=\"form-field-title\">Where should traffic be sent?</span>\n </div>\n <div class=\"grid addressFull\">\n <div class=\"config-item-container\">\n <span class=\"config-item-label\">SDK ONLY</span>\n <div\n class=\"sdk-toggle form-field-toggle\"\n >\n <div class=\"switchGrid\">\n <div>\n <div\n (click)=\"toggleSdkOnlyBind()\"\n [ngClass]=\"{ on: sdkOnlyBind }\"\n class=\"toggle\"\n >\n <span [hidden]=\"!sdkOnlyBind\" class=\"on-label\">YES</span>\n <span [hidden]=\"sdkOnlyBind\" class=\"off-label\">NO</span>\n <div class=\"switch\"></div>\n </div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"config-item-container\" [ngClass]=\"{disabled: sdkOnlyBind}\">\n <span class=\"config-item-label\">PROTOCOL</span>\n <select id=\"HostedProtocol\" (change)=\"hostProtocolsChanged($event)\" [(ngModel)]=\"sdkOnlyBind ? '' : hostProtocol\">\n <option value=\"tcp\">TCP</option>\n <option value=\"udp\" >UDP</option>\n <option value=\"both\" >TCP/UDP</option>\n </select>\n </div>\n <div class=\"config-item-container\" [ngClass]=\"{disabled: sdkOnlyBind}\">\n <span class=\"config-item-label\">HOSTNAME / IP</span>\n <input id=\"HostedHost\" type=\"text\" maxlength=\"100\" data-i18n=\"EgHost\" (change)=\"validateHostAddress()\" [ngClass]=\"{error: errors.hostAddress}\" [placeholder]=\"sdkOnlyBind ? '' : 'e.g. myservice.ziti'\" [(ngModel)]=\"sdkOnlyBind ? '' : hostConfigApiData.data.address\">\n </div>\n <div class=\"config-item-container\" [ngClass]=\"{disabled: sdkOnlyBind}\">\n <span class=\"config-item-label\">PORT</span>\n <input id=\"HostedPort\" type=\"number\" maxlength=\"10\" (change)=\"validateHostPort()\" [ngClass]=\"{error: errors.hostPort}\" [placeholder]=\"sdkOnlyBind ? '' : 443\" [(ngModel)]=\"sdkOnlyBind ? '' : hostConfigApiData.data.port\">\n </div>\n </div>\n </div>\n </div>\n </lib-form-field-container>\n </div>\n </div>\n </div>\n</div>", styles: [".ziti-entity-header-container{display:flex;flex-direction:row;justify-content:space-between;align-items:center}.simple-service-wrapper .simple-service-form-container .form-group-column{height:-moz-fit-content;height:fit-content;max-width:40.625rem;width:100%;transition:var(--transition);flex-grow:0;padding-bottom:0}.simple-service-wrapper .simple-service-form-container .simple-service-center-content lib-form-field-container{min-width:23.4375rem}.simple-service-wrapper .simple-service-form-container .simple-service-center-content .form-field-input-group{display:flex;flex-direction:column;gap:.9375rem}.simple-service-wrapper .grid.addressFull{grid-template-columns:4.375rem 5.9375rem auto 4.0625rem}.simple-service-wrapper .grid.addressPort{grid-template-columns:4.375rem auto 4.0625rem}.simple-service-wrapper input:disabled{opacity:.5!important}.simple-service-wrapper .addressPort .config-item-container.disabled,.simple-service-wrapper .addressFull .config-item-container.disabled{opacity:.3;pointer-events:none}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle{color:var(--white);display:flex;justify-content:space-between;height:var(--defaultInputHeight);align-items:center;margin-bottom:0}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .label,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .label{display:flex;font-size:.875rem;font-weight:600;text-transform:uppercase}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .toggle,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .toggle{margin:0;display:flex;align-items:center;width:3.75rem;height:1.75rem;font-size:.875rem;line-height:1.5625rem;font-weight:800;font-family:Open Sans,Arial,sans-serif;background-color:var(--icon);color:var(--white);text-align:center;cursor:pointer;position:relative;float:left;border-radius:.8125rem}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .toggle.on,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .toggle.on{background-color:var(--green)}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .toggle .switch,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .toggle .switch{width:1.25rem;height:1.25rem;border-radius:.625rem;background-color:var(--white);transition:var(--transition);position:absolute;top:.25rem;z-index:10}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .toggle .switch.on,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .toggle .switch.on{left:2.1875rem}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .toggle .on-label,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .toggle .on-label{margin-left:.4375rem}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .toggle .off-label,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .toggle .off-label{margin-left:2rem}.simple-service-wrapper .addressPort .config-item-container .config-hostname-label,.simple-service-wrapper .addressFull .config-item-container .config-hostname-label{display:flex;flex-direction:row;justify-content:flex-start;white-space:nowrap}.simple-service-wrapper .addressPort .config-item-container .config-hostname-label .form-field-info,.simple-service-wrapper .addressFull .config-item-container .config-hostname-label .form-field-info{margin-top:.0625rem}.simple-service-wrapper .addressPort .config-item-container .config-hostname-label .error-label,.simple-service-wrapper .addressFull .config-item-container .config-hostname-label .error-label{margin-left:.3125rem}.simple-service-wrapper .form-field-input-group.service-group{gap:.625rem;display:flex;flex-direction:column}.simple-service-wrapper .form-field-input-group.accessing-group{gap:.9375rem;display:flex;flex-direction:column}.simple-service-wrapper .form-field-input-group .form-field-sub-group{display:flex;flex-direction:column;gap:.3125rem}.simple-service-wrapper .form-field-input-group .form-field-sub-group .config-title-row{height:.875rem}.simple-service-wrapper .form-field-input-group .form-field-sub-group .addressFull,.simple-service-wrapper .form-field-input-group .form-field-sub-group .addressPort{gap:.625rem}.simple-service-wrapper .form-field-input-group .form-field-sub-group .addressFull select{height:var(--defaultInputHeight)}.simple-service-wrapper .simple-service-center-content{display:flex;flex-direction:column;width:100%;align-items:center;justify-content:center}.simple-service-wrapper .simple-service-center-content .form-group-row{flex-wrap:wrap;gap:.9375rem;max-width:40.625rem;justify-content:center;padding:0}.config-item-label{color:#a9abaf;font-weight:600;margin-bottom:.3125rem;position:relative;display:flex}.simple-service-inputs{display:flex;flex-direction:column;gap:.9375rem}.form-field-input-group .form-field-title{color:var(--offWhite);margin-bottom:.625rem}.config-item .config-container.encryption-pod{background-color:#222f3e;background-image:linear-gradient(90deg,#232f3e,#f6f7fb);background-image:-ms-linear-gradient(90deg,rgb(35,47,62) 0%,rgb(246,247,251) 100%);border-radius:var(--inputBorderRadius)}.config-item .config-container .config-container-label{color:#fff}::ng-deep .simple-service-wrapper input{max-height:var(--defaultInputHeight);min-height:0rem;height:var(--defaultInputHeight)}::ng-deep .simple-service-wrapper .select2-search__field{height:100%;min-height:2.5rem;max-height:2.5rem}::ng-deep .simple-service-wrapper .select2-selection__rendered{padding:0;max-height:7.1875rem!important;overflow:auto}::ng-deep .simple-service-wrapper .form-header-container{align-items:center}::ng-deep .simple-service-wrapper .form-header-container .form-header-group{width:40.625rem!important}::ng-deep .simple-service-wrapper .form-header-container .header-actions-container{min-width:0rem}::ng-deep .simple-service-wrapper .form-header-container .form-header-toggle-container{display:none}\n"], dependencies: [{ kind: "directive", type: i1$4.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i5.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i5.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i5.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: i5.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }, { kind: "directive", type: i5.SelectControlValueAccessor, selector: "select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]", inputs: ["compareWith"] }, { kind: "directive", type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i5.MaxLengthValidator, selector: "[maxlength][formControlName],[maxlength][formControl],[maxlength][ngModel]", inputs: ["maxlength"] }, { kind: "directive", type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i3.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }, { kind: "component", type: FormHeaderComponent, selector: "lib-form-header", inputs: ["data", "badges", "title", "moreActions", "formView", "saveDisabled", "saveTooltip", "actionButtonText", "moreActionsText", "showHeaderToggle", "showHeaderButton"], outputs: ["formViewChange", "actionRequested"] }, { kind: "component", type: FormFieldContainerComponent, selector: "lib-form-field-container", inputs: ["title", "title2", "titleIcon", "layout", "helpText", "helpText2", "label", "count", "action", "actionLabel", "class", "contentStyle", "showHeader", "showToggle", "headerActions", "headerToggle"], outputs: ["actionRequested", "headerToggleChange"] }, { kind: "component", type: TagSelectorComponent, selector: "lib-tag-selector", inputs: ["placeholder", "disableField", "disableCreate", "hideOption", "isLoading", "errorMessage", "focusOnInit", "selectedRoleAttributes", "selectedNamedAttributes", "hasError", "availableRoleAttributes", "availableNamedAttributes"], outputs: ["addRoleAttribute", "addNamedAttribute", "roleAttributeRemoved", "namedAttributeRemoved", "selectedRoleAttributesChange", "selectedNamedAttributesChange", "filterChange"] }] }); }
|
|
17985
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: SimpleServiceComponent, selector: "lib-simple-service", inputs: { serviceRoleAttributes: "serviceRoleAttributes", identityRoleAttributes: "identityRoleAttributes", identityNamedAttributes: "identityNamedAttributes" }, outputs: { close: "close", selected: "selected" }, usesInheritance: true, ngImport: i0, template: "<div class=\"projectable-form-wrapper simple-service-wrapper\"\n (keyup.enter)=\"save($event)\"\n (keyup.escape)=\"closeModal(true, false, 'cards', $event)\"\n tabindex=\"0\"\n>\n <lib-form-header\n [data]=\"formData\"\n [title]=\"showForm ? 'Create a Simple Service' : 'Service Creation Summary'\"\n [actionButtonText]=\"'Save'\"\n (actionRequested)=\"headerActionRequested($event)\"\n [(formView)]=\"formView\"\n ></lib-form-header>\n <div class=\"simple-service-form-container projectable-form-container\">\n <div class=\"form-group-column three-fifths\" *ngIf=\"showForm\">\n <div id=\"InlineServiceArea\" class=\"anyadd\">\n <div class=\"simple-service-inputs\">\n <lib-form-field-container [title]=\"'Service Details'\">\n <div class=\"form-field-input-group service-group\">\n <div class=\"form-field-sub-group\">\n <div class=\"config-title-row\">\n <span class=\"form-field-title\">Service Name</span>\n </div>\n <input\n class=\"form-field-input\"\n placeholder=\"Name this service\"\n autofocus\n #nameFieldInput\n [ngClass]=\"{error: errors.name}\"\n [(ngModel)]=\"serviceApiData.name\"\n (keyup)=\"serviceNameChanged($event)\"\n (change)=\"validateServiceName()\"\n />\n </div>\n <div class=\"form-field-sub-group\">\n <div class=\"config-title-row\">\n <span class=\"form-field-title\">SELECT OR CREATE SERVICE ATTRIBUTES</span>\n </div>\n <lib-tag-selector\n [(selectedRoleAttributes)]=\"serviceApiData.roleAttributes\"\n [availableRoleAttributes]=\"serviceRoleAttributes\"\n [placeholder]=\"'Add attributes to group services'\"\n ></lib-tag-selector>\n </div>\n </div>\n </lib-form-field-container>\n </div>\n </div>\n </div>\n <div class=\"simple-service-center-content\" *ngIf=\"showForm\">\n <div class=\"form-group-row\">\n <lib-form-field-container\n [title]=\"'ACCESSING CONFIGURATION'\"\n [contentStyle]=\"'z-index: 10001'\"\n [helpText]=\"'How will client applications use this service? Specify a hostname/IP and port, or use the "SDK Only" toggle for an application embedded configuration.'\"\n >\n <div class=\"form-field-input-group accessing-group\">\n <div class=\"form-field-sub-group\">\n <div class=\"config-title-row\">\n <span class=\"form-field-title\">What identities can access this service?</span>\n </div>\n <lib-tag-selector\n [(selectedNamedAttributes)]=\"dialPolicyNamedAttributes\"\n [(selectedRoleAttributes)]=\"dialPolicyRoleAttributes\"\n [availableNamedAttributes]=\"identityNamedAttributes\"\n [availableRoleAttributes]=\"identityRoleAttributes\"\n [placeholder]=\"'Select identity attributes to grant access'\"\n [hasError]=\"errors.dialIdentities\"\n (selectedNamedAttributesChange)=\"validateDialIdentities()\"\n (selectedRoleAttributesChange)=\"validateDialIdentities()\"\n (filterChange)=\"getIdentityNamedAttributes($event)\"\n ></lib-tag-selector>\n </div>\n <div class=\"form-field-sub-group\">\n <div class=\"config-title-row\">\n <span class=\"form-field-title\">How will the service be accessed?</span>\n </div>\n <div class=\"grid addressPort\">\n <div class=\"config-item-container\">\n <span class=\"config-item-label\">SDK ONLY</span>\n <div\n class=\"sdk-toggle form-field-toggle\"\n >\n <div class=\"switchGrid\">\n <div>\n <div\n (click)=\"toggleSdkOnlyDial()\"\n [ngClass]=\"{ on: sdkOnlyDial }\"\n class=\"toggle\"\n >\n <span [hidden]=\"!sdkOnlyDial\" class=\"on-label\">YES</span>\n <span [hidden]=\"sdkOnlyDial\" class=\"off-label\">NO</span>\n <div class=\"switch\"></div>\n </div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"config-item-container\" [ngClass]=\"{disabled: sdkOnlyDial}\">\n <div class=\"config-hostname-label\">\n <span class=\"config-item-label\">HOSTNAME / IP</span>\n <div\n class=\"form-field-info infoicon\"\n matTooltip=\"Accessing hostnames must include a '.'\"\n matTooltipPosition=\"above\"\n ></div>\n <span *ngIf=\"errors.interceptAddressFormat\" class=\"error-label\">Accessing hostnames must include a '.'</span>\n </div>\n <input id=\"HowTo\" type=\"text\" maxlength=\"100\" data-i18n=\"EgHost\" (change)=\"validateInterceptAddress()\" [ngClass]=\"{error: errors.interceptAddress}\" [placeholder]=\"sdkOnlyDial ? '' : 'e.g. myservice.ziti'\" [(ngModel)]=\"sdkOnlyDial ? '' : interceptConfigApiData.data.addresses[0]\">\n </div>\n <div class=\"config-item-container\" [ngClass]=\"{disabled: sdkOnlyDial}\">\n <span class=\"config-item-label\">PORT</span>\n <input id=\"HowToPort\" type=\"number\" maxlength=\"10\" (change)=\"validateInterceptPort()\" [ngClass]=\"{error: errors.interceptPort}\" [placeholder]=\"sdkOnlyDial ? '' : 443\" (keyup)=\"interceptPortChanged($event)\" [(ngModel)]=\"sdkOnlyDial ? '' : interceptPort\">\n </div>\n </div>\n </div>\n </div>\n </lib-form-field-container>\n <lib-form-field-container\n [title]=\"'HOSTING CONFIGURATION'\"\n [contentStyle]=\"'z-index: 10000'\"\n [helpText]=\"'Where should traffic for this service be sent? Specify a protocol, hostname/IP, and port, or use the "SDK Only" toggle for an application embedded configuration.'\"\n\n >\n <div class=\"form-field-input-group hosting-group\">\n <div class=\"form-field-sub-group\">\n <div class=\"config-title-row\">\n <span class=\"form-field-title\">What identities can host this service?</span>\n </div>\n <lib-tag-selector\n [(selectedNamedAttributes)]=\"bindPolicyNamedAttributes\"\n [(selectedRoleAttributes)]=\"bindPolicyRoleAttributes\"\n [availableNamedAttributes]=\"identityNamedAttributes\"\n [availableRoleAttributes]=\"identityRoleAttributes\"\n [placeholder]=\"'Select identity attributes'\"\n [hasError]=\"errors.bindIdentities\"\n (selectedNamedAttributesChange)=\"validateBindIdentities()\"\n (selectedRoleAttributesChange)=\"validateBindIdentities()\"\n (filterChange)=\"getIdentityNamedAttributes($event)\"\n ></lib-tag-selector>\n </div>\n <div class=\"form-field-sub-group\">\n <div class=\"config-title-row\">\n <span class=\"form-field-title\">Where should traffic be sent?</span>\n </div>\n <div class=\"grid addressFull\">\n <div class=\"config-item-container\">\n <span class=\"config-item-label\">SDK ONLY</span>\n <div\n class=\"sdk-toggle form-field-toggle\"\n >\n <div class=\"switchGrid\">\n <div>\n <div\n (click)=\"toggleSdkOnlyBind()\"\n [ngClass]=\"{ on: sdkOnlyBind }\"\n class=\"toggle\"\n >\n <span [hidden]=\"!sdkOnlyBind\" class=\"on-label\">YES</span>\n <span [hidden]=\"sdkOnlyBind\" class=\"off-label\">NO</span>\n <div class=\"switch\"></div>\n </div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"config-item-container\" [ngClass]=\"{disabled: sdkOnlyBind}\">\n <span class=\"config-item-label\">PROTOCOL</span>\n <select id=\"HostedProtocol\" (change)=\"hostProtocolsChanged($event)\" [(ngModel)]=\"sdkOnlyBind ? '' : hostProtocol\">\n <option value=\"tcp\">TCP</option>\n <option value=\"udp\" >UDP</option>\n <option value=\"both\" >TCP/UDP</option>\n </select>\n </div>\n <div class=\"config-item-container\" [ngClass]=\"{disabled: sdkOnlyBind}\">\n <span class=\"config-item-label\">HOSTNAME / IP</span>\n <input id=\"HostedHost\" type=\"text\" maxlength=\"100\" data-i18n=\"EgHost\" (change)=\"validateHostAddress()\" [ngClass]=\"{error: errors.hostAddress}\" [placeholder]=\"sdkOnlyBind ? '' : 'e.g. myservice.ziti'\" [(ngModel)]=\"sdkOnlyBind ? '' : hostConfigApiData.data.address\">\n </div>\n <div class=\"config-item-container\" [ngClass]=\"{disabled: sdkOnlyBind}\">\n <span class=\"config-item-label\">PORT</span>\n <input id=\"HostedPort\" type=\"number\" maxlength=\"10\" (change)=\"validateHostPort()\" [ngClass]=\"{error: errors.hostPort}\" [placeholder]=\"sdkOnlyBind ? '' : 443\" [(ngModel)]=\"sdkOnlyBind ? '' : hostConfigApiData.data.port\">\n </div>\n </div>\n </div>\n </div>\n </lib-form-field-container>\n </div>\n </div>\n </div>\n</div>", styles: [".ziti-entity-header-container{display:flex;flex-direction:row;justify-content:space-between;align-items:center}.simple-service-wrapper .simple-service-form-container .form-group-column{height:-moz-fit-content;height:fit-content;max-width:40.625rem;width:100%;transition:var(--transition);flex-grow:0;padding-bottom:0}.simple-service-wrapper .simple-service-form-container .simple-service-center-content lib-form-field-container{min-width:23.4375rem}.simple-service-wrapper .simple-service-form-container .simple-service-center-content .form-field-input-group{display:flex;flex-direction:column;gap:.9375rem}.simple-service-wrapper .grid.addressFull{grid-template-columns:4.375rem 5.9375rem auto 4.0625rem}.simple-service-wrapper .grid.addressPort{grid-template-columns:4.375rem auto 4.0625rem}.simple-service-wrapper input:disabled{opacity:.5!important}.simple-service-wrapper .addressPort .config-item-container.disabled,.simple-service-wrapper .addressFull .config-item-container.disabled{opacity:.3;pointer-events:none}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle{color:var(--white);display:flex;justify-content:space-between;height:var(--defaultInputHeight);align-items:center;margin-bottom:0}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .label,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .label{display:flex;font-size:.875rem;font-weight:600;text-transform:uppercase}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .toggle,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .toggle{margin:0;display:flex;align-items:center;width:3.75rem;height:1.75rem;font-size:.875rem;line-height:1.5625rem;font-weight:800;font-family:Open Sans,Arial,sans-serif;background-color:var(--icon);color:var(--white);text-align:center;cursor:pointer;position:relative;float:left;border-radius:.8125rem}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .toggle.on,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .toggle.on{background-color:var(--green)}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .toggle .switch,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .toggle .switch{width:1.25rem;height:1.25rem;border-radius:.625rem;background-color:var(--white);transition:var(--transition);position:absolute;top:.25rem;z-index:10}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .toggle .switch.on,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .toggle .switch.on{left:2.1875rem}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .toggle .on-label,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .toggle .on-label{margin-left:.4375rem}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .toggle .off-label,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .toggle .off-label{margin-left:2rem}.simple-service-wrapper .addressPort .config-item-container .config-hostname-label,.simple-service-wrapper .addressFull .config-item-container .config-hostname-label{display:flex;flex-direction:row;justify-content:flex-start;white-space:nowrap}.simple-service-wrapper .addressPort .config-item-container .config-hostname-label .form-field-info,.simple-service-wrapper .addressFull .config-item-container .config-hostname-label .form-field-info{margin-top:.0625rem}.simple-service-wrapper .addressPort .config-item-container .config-hostname-label .error-label,.simple-service-wrapper .addressFull .config-item-container .config-hostname-label .error-label{margin-left:.3125rem}.simple-service-wrapper .form-field-input-group.service-group{gap:.625rem;display:flex;flex-direction:column}.simple-service-wrapper .form-field-input-group.accessing-group{gap:.9375rem;display:flex;flex-direction:column}.simple-service-wrapper .form-field-input-group .form-field-sub-group{display:flex;flex-direction:column;gap:.3125rem}.simple-service-wrapper .form-field-input-group .form-field-sub-group .config-title-row{height:.875rem}.simple-service-wrapper .form-field-input-group .form-field-sub-group .addressFull,.simple-service-wrapper .form-field-input-group .form-field-sub-group .addressPort{gap:.625rem}.simple-service-wrapper .form-field-input-group .form-field-sub-group .addressFull select{height:var(--defaultInputHeight)}.simple-service-wrapper .simple-service-center-content{display:flex;flex-direction:column;width:100%;align-items:center;justify-content:center}.simple-service-wrapper .simple-service-center-content .form-group-row{flex-wrap:wrap;gap:.9375rem;max-width:40.625rem;justify-content:center;padding:0}.config-item-label{color:#a9abaf;font-weight:600;margin-bottom:.3125rem;position:relative;display:flex}.simple-service-inputs{display:flex;flex-direction:column;gap:.9375rem}.form-field-input-group .form-field-title{color:var(--offWhite);margin-bottom:.625rem}.config-item .config-container.encryption-pod{background-color:#222f3e;background-image:linear-gradient(90deg,#232f3e,#f6f7fb);background-image:-ms-linear-gradient(90deg,rgb(35,47,62) 0%,rgb(246,247,251) 100%);border-radius:var(--inputBorderRadius)}.config-item .config-container .config-container-label{color:#fff}::ng-deep .simple-service-wrapper input{max-height:var(--defaultInputHeight);min-height:0rem;height:var(--defaultInputHeight)}::ng-deep .simple-service-wrapper .select2-search__field{height:100%;min-height:2.5rem;max-height:2.5rem}::ng-deep .simple-service-wrapper .select2-selection__rendered{padding:0;max-height:7.1875rem!important;overflow:auto}::ng-deep .simple-service-wrapper .form-header-container{align-items:center}::ng-deep .simple-service-wrapper .form-header-container .form-header-group{width:40.625rem!important}::ng-deep .simple-service-wrapper .form-header-container .header-actions-container{min-width:0rem}::ng-deep .simple-service-wrapper .form-header-container .form-header-toggle-container{display:none}\n"], dependencies: [{ kind: "directive", type: i1$4.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i5.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i5.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i5.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: i5.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }, { kind: "directive", type: i5.SelectControlValueAccessor, selector: "select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]", inputs: ["compareWith"] }, { kind: "directive", type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i5.MaxLengthValidator, selector: "[maxlength][formControlName],[maxlength][formControl],[maxlength][ngModel]", inputs: ["maxlength"] }, { kind: "directive", type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i3.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }, { kind: "component", type: FormHeaderComponent, selector: "lib-form-header", inputs: ["data", "badges", "title", "moreActions", "formView", "saveDisabled", "saveTooltip", "actionButtonText", "moreActionsText", "showHeaderToggle", "showHeaderButton"], outputs: ["formViewChange", "actionRequested"] }, { kind: "component", type: FormFieldContainerComponent, selector: "lib-form-field-container", inputs: ["title", "title2", "titleIcon", "layout", "helpText", "helpText2", "label", "count", "action", "actionLabel", "class", "contentStyle", "showHeader", "showToggle", "headerActions", "headerToggle"], outputs: ["actionRequested", "headerToggleChange"] }, { kind: "component", type: TagSelectorComponent, selector: "lib-tag-selector", inputs: ["placeholder", "disableField", "disableCreate", "hideOption", "isLoading", "errorMessage", "focusOnInit", "selectedRoleAttributes", "selectedNamedAttributes", "hasError", "availableRoleAttributes", "availableNamedAttributes"], outputs: ["addRoleAttribute", "addNamedAttribute", "roleAttributeRemoved", "namedAttributeRemoved", "selectedRoleAttributesChange", "selectedNamedAttributesChange", "filterChange"] }] }); }
|
|
17971
17986
|
}
|
|
17972
17987
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: SimpleServiceComponent, decorators: [{
|
|
17973
17988
|
type: Component,
|
|
17974
|
-
args: [{ selector: 'lib-simple-service', template: "<div class=\"projectable-form-wrapper simple-service-wrapper\"\n (keyup.enter)=\"save($event)\"\n (keyup.escape)=\"closeModal(true, false, 'cards', $event)\"\n tabindex=\"0\"\n>\n <lib-form-header\n [data]=\"formData\"\n [title]=\"showForm ? 'Create a Simple Service' : 'Service Creation Summary'\"\n [actionButtonText]=\"'Save'\"\n (actionRequested)=\"headerActionRequested($event)\"\n [(formView)]=\"formView\"\n ></lib-form-header>\n <div class=\"simple-service-form-container projectable-form-container\">\n <div class=\"form-group-column three-fifths\" *ngIf=\"showForm\">\n <div id=\"InlineServiceArea\" class=\"anyadd\">\n <div class=\"simple-service-inputs\">\n <lib-form-field-container [title]=\"'Service Details'\">\n <div class=\"form-field-input-group service-group\">\n <div class=\"form-field-sub-group\">\n <div class=\"config-title-row\">\n <span class=\"form-field-title\">Service Name</span>\n </div>\n <input\n class=\"form-field-input\"\n placeholder=\"Name this service\"\n autofocus\n #nameFieldInput\n [ngClass]=\"{error: errors.name}\"\n [(ngModel)]=\"serviceApiData.name\"\n (keyup)=\"serviceNameChanged($event)\"\n (change)=\"validateServiceName()\"\n />\n </div>\n <div class=\"form-field-sub-group\">\n <div class=\"config-title-row\">\n <span class=\"form-field-title\">SELECT OR CREATE SERVICE ATTRIBUTES</span>\n </div>\n <lib-tag-selector\n [(selectedRoleAttributes)]=\"serviceApiData.roleAttributes\"\n [availableRoleAttributes]=\"serviceRoleAttributes\"\n [placeholder]=\"'Add attributes to group services'\"\n ></lib-tag-selector>\n </div>\n </div>\n </lib-form-field-container>\n </div>\n </div>\n </div>\n <div class=\"simple-service-center-content\" *ngIf=\"showForm\">\n <div class=\"form-group-row\">\n <lib-form-field-container\n [title]=\"'ACCESSING CONFIGURATION'\"\n [contentStyle]=\"'z-index: 10001'\"\n [helpText]=\"'How will client applications use this service? Specify a hostname/IP and port, or use the "SDK Only" toggle for an application embedded configuration.'\"\n >\n <div class=\"form-field-input-group accessing-group\">\n <div class=\"form-field-sub-group\">\n <div class=\"config-title-row\">\n <span class=\"form-field-title\">What identities can access this service?</span>\n </div>\n <lib-tag-selector\n [(selectedNamedAttributes)]=\"dialPolicyNamedAttributes\"\n [(selectedRoleAttributes)]=\"dialPolicyRoleAttributes\"\n [availableNamedAttributes]=\"identityNamedAttributes\"\n [availableRoleAttributes]=\"identityRoleAttributes\"\n [placeholder]=\"'Select identity attributes to grant access'\"\n [hasError]=\"errors.dialIdentities\"\n (selectedNamedAttributesChange)=\"validateDialIdentities()\"\n (selectedRoleAttributesChange)=\"validateDialIdentities()\"\n (filterChange)=\"getIdentityNamedAttributes($event)\"\n ></lib-tag-selector>\n </div>\n <div class=\"form-field-sub-group\">\n <div class=\"config-title-row\">\n <span class=\"form-field-title\">How will the service be accessed?</span>\n </div>\n <div class=\"grid addressPort\">\n <div class=\"config-item-container\">\n <span class=\"config-item-label\">SDK ONLY</span>\n <div\n class=\"sdk-toggle form-field-toggle\"\n >\n <div class=\"switchGrid\">\n <div>\n <div\n (click)=\"toggleSdkOnlyDial()\"\n [ngClass]=\"{ on: sdkOnlyDial }\"\n class=\"toggle\"\n >\n <span [hidden]=\"!sdkOnlyDial\" class=\"on-label\">YES</span>\n <span [hidden]=\"sdkOnlyDial\" class=\"off-label\">NO</span>\n <div class=\"switch\"></div>\n </div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"config-item-container\" [ngClass]=\"{disabled: sdkOnlyDial}\">\n <div class=\"config-hostname-label\">\n <span class=\"config-item-label\">HOSTNAME / IP</span>\n <div\n class=\"form-field-info infoicon\"\n matTooltip=\"Accessing hostnames must include a '.'\"\n matTooltipPosition=\"above\"\n ></div>\n <span *ngIf=\"errors.interceptAddressFormat\" class=\"error-label\">Accessing hostnames must include a '.'</span>\n </div>\n <input id=\"HowTo\" type=\"text\" maxlength=\"100\" data-i18n=\"EgHost\" (change)=\"validateInterceptAddress()\" [ngClass]=\"{error: errors.interceptAddress}\" [placeholder]=\"sdkOnlyDial ? '' : 'e.g. myservice.ziti'\" [(ngModel)]=\"sdkOnlyDial ? '' : interceptConfigApiData.data.addresses[0]\">\n </div>\n <div class=\"config-item-container\" [ngClass]=\"{disabled: sdkOnlyDial}\">\n <span class=\"config-item-label\">PORT</span>\n <input id=\"HowToPort\" type=\"number\" maxlength=\"10\" (change)=\"validateInterceptPort()\" [ngClass]=\"{error: errors.interceptPort}\" [placeholder]=\"sdkOnlyDial ? '' : 443\" (keyup)=\"interceptPortChanged($event)\" [(ngModel)]=\"sdkOnlyDial ? '' : interceptPort\">\n </div>\n </div>\n </div>\n </div>\n </lib-form-field-container>\n <lib-form-field-container\n [title]=\"'HOSTING CONFIGURATION'\"\n [contentStyle]=\"'z-index: 10000'\"\n [helpText]=\"'Where should traffic for this service be sent? Specify a protocol, hostname/IP, and port, or use the "SDK Only" toggle for an application embedded configuration.'\"\n\n >\n <div class=\"form-field-input-group hosting-group\">\n <div class=\"form-field-sub-group\">\n <div class=\"config-title-row\">\n <span class=\"form-field-title\">What identities can host this service?</span>\n </div>\n <lib-tag-selector\n [(selectedNamedAttributes)]=\"bindPolicyNamedAttributes\"\n [(selectedRoleAttributes)]=\"bindPolicyRoleAttributes\"\n [availableNamedAttributes]=\"identityNamedAttributes\"\n [availableRoleAttributes]=\"identityRoleAttributes\"\n [placeholder]=\"'Select identity attributes'\"\n [hasError]=\"errors.bindIdentities\"\n (selectedNamedAttributesChange)=\"validateBindIdentities()\"\n (selectedRoleAttributesChange)=\"validateBindIdentities()\"\n ></lib-tag-selector>\n </div>\n <div class=\"form-field-sub-group\">\n <div class=\"config-title-row\">\n <span class=\"form-field-title\">Where should traffic be sent?</span>\n </div>\n <div class=\"grid addressFull\">\n <div class=\"config-item-container\">\n <span class=\"config-item-label\">SDK ONLY</span>\n <div\n class=\"sdk-toggle form-field-toggle\"\n >\n <div class=\"switchGrid\">\n <div>\n <div\n (click)=\"toggleSdkOnlyBind()\"\n [ngClass]=\"{ on: sdkOnlyBind }\"\n class=\"toggle\"\n >\n <span [hidden]=\"!sdkOnlyBind\" class=\"on-label\">YES</span>\n <span [hidden]=\"sdkOnlyBind\" class=\"off-label\">NO</span>\n <div class=\"switch\"></div>\n </div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"config-item-container\" [ngClass]=\"{disabled: sdkOnlyBind}\">\n <span class=\"config-item-label\">PROTOCOL</span>\n <select id=\"HostedProtocol\" (change)=\"hostProtocolsChanged($event)\" [(ngModel)]=\"sdkOnlyBind ? '' : hostProtocol\">\n <option value=\"tcp\">TCP</option>\n <option value=\"udp\" >UDP</option>\n <option value=\"both\" >TCP/UDP</option>\n </select>\n </div>\n <div class=\"config-item-container\" [ngClass]=\"{disabled: sdkOnlyBind}\">\n <span class=\"config-item-label\">HOSTNAME / IP</span>\n <input id=\"HostedHost\" type=\"text\" maxlength=\"100\" data-i18n=\"EgHost\" (change)=\"validateHostAddress()\" [ngClass]=\"{error: errors.hostAddress}\" [placeholder]=\"sdkOnlyBind ? '' : 'e.g. myservice.ziti'\" [(ngModel)]=\"sdkOnlyBind ? '' : hostConfigApiData.data.address\">\n </div>\n <div class=\"config-item-container\" [ngClass]=\"{disabled: sdkOnlyBind}\">\n <span class=\"config-item-label\">PORT</span>\n <input id=\"HostedPort\" type=\"number\" maxlength=\"10\" (change)=\"validateHostPort()\" [ngClass]=\"{error: errors.hostPort}\" [placeholder]=\"sdkOnlyBind ? '' : 443\" [(ngModel)]=\"sdkOnlyBind ? '' : hostConfigApiData.data.port\">\n </div>\n </div>\n </div>\n </div>\n </lib-form-field-container>\n </div>\n </div>\n </div>\n</div>", styles: [".ziti-entity-header-container{display:flex;flex-direction:row;justify-content:space-between;align-items:center}.simple-service-wrapper .simple-service-form-container .form-group-column{height:-moz-fit-content;height:fit-content;max-width:40.625rem;width:100%;transition:var(--transition);flex-grow:0;padding-bottom:0}.simple-service-wrapper .simple-service-form-container .simple-service-center-content lib-form-field-container{min-width:23.4375rem}.simple-service-wrapper .simple-service-form-container .simple-service-center-content .form-field-input-group{display:flex;flex-direction:column;gap:.9375rem}.simple-service-wrapper .grid.addressFull{grid-template-columns:4.375rem 5.9375rem auto 4.0625rem}.simple-service-wrapper .grid.addressPort{grid-template-columns:4.375rem auto 4.0625rem}.simple-service-wrapper input:disabled{opacity:.5!important}.simple-service-wrapper .addressPort .config-item-container.disabled,.simple-service-wrapper .addressFull .config-item-container.disabled{opacity:.3;pointer-events:none}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle{color:var(--white);display:flex;justify-content:space-between;height:var(--defaultInputHeight);align-items:center;margin-bottom:0}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .label,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .label{display:flex;font-size:.875rem;font-weight:600;text-transform:uppercase}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .toggle,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .toggle{margin:0;display:flex;align-items:center;width:3.75rem;height:1.75rem;font-size:.875rem;line-height:1.5625rem;font-weight:800;font-family:Open Sans,Arial,sans-serif;background-color:var(--icon);color:var(--white);text-align:center;cursor:pointer;position:relative;float:left;border-radius:.8125rem}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .toggle.on,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .toggle.on{background-color:var(--green)}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .toggle .switch,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .toggle .switch{width:1.25rem;height:1.25rem;border-radius:.625rem;background-color:var(--white);transition:var(--transition);position:absolute;top:.25rem;z-index:10}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .toggle .switch.on,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .toggle .switch.on{left:2.1875rem}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .toggle .on-label,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .toggle .on-label{margin-left:.4375rem}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .toggle .off-label,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .toggle .off-label{margin-left:2rem}.simple-service-wrapper .addressPort .config-item-container .config-hostname-label,.simple-service-wrapper .addressFull .config-item-container .config-hostname-label{display:flex;flex-direction:row;justify-content:flex-start;white-space:nowrap}.simple-service-wrapper .addressPort .config-item-container .config-hostname-label .form-field-info,.simple-service-wrapper .addressFull .config-item-container .config-hostname-label .form-field-info{margin-top:.0625rem}.simple-service-wrapper .addressPort .config-item-container .config-hostname-label .error-label,.simple-service-wrapper .addressFull .config-item-container .config-hostname-label .error-label{margin-left:.3125rem}.simple-service-wrapper .form-field-input-group.service-group{gap:.625rem;display:flex;flex-direction:column}.simple-service-wrapper .form-field-input-group.accessing-group{gap:.9375rem;display:flex;flex-direction:column}.simple-service-wrapper .form-field-input-group .form-field-sub-group{display:flex;flex-direction:column;gap:.3125rem}.simple-service-wrapper .form-field-input-group .form-field-sub-group .config-title-row{height:.875rem}.simple-service-wrapper .form-field-input-group .form-field-sub-group .addressFull,.simple-service-wrapper .form-field-input-group .form-field-sub-group .addressPort{gap:.625rem}.simple-service-wrapper .form-field-input-group .form-field-sub-group .addressFull select{height:var(--defaultInputHeight)}.simple-service-wrapper .simple-service-center-content{display:flex;flex-direction:column;width:100%;align-items:center;justify-content:center}.simple-service-wrapper .simple-service-center-content .form-group-row{flex-wrap:wrap;gap:.9375rem;max-width:40.625rem;justify-content:center;padding:0}.config-item-label{color:#a9abaf;font-weight:600;margin-bottom:.3125rem;position:relative;display:flex}.simple-service-inputs{display:flex;flex-direction:column;gap:.9375rem}.form-field-input-group .form-field-title{color:var(--offWhite);margin-bottom:.625rem}.config-item .config-container.encryption-pod{background-color:#222f3e;background-image:linear-gradient(90deg,#232f3e,#f6f7fb);background-image:-ms-linear-gradient(90deg,rgb(35,47,62) 0%,rgb(246,247,251) 100%);border-radius:var(--inputBorderRadius)}.config-item .config-container .config-container-label{color:#fff}::ng-deep .simple-service-wrapper input{max-height:var(--defaultInputHeight);min-height:0rem;height:var(--defaultInputHeight)}::ng-deep .simple-service-wrapper .select2-search__field{height:100%;min-height:2.5rem;max-height:2.5rem}::ng-deep .simple-service-wrapper .select2-selection__rendered{padding:0;max-height:7.1875rem!important;overflow:auto}::ng-deep .simple-service-wrapper .form-header-container{align-items:center}::ng-deep .simple-service-wrapper .form-header-container .form-header-group{width:40.625rem!important}::ng-deep .simple-service-wrapper .form-header-container .header-actions-container{min-width:0rem}::ng-deep .simple-service-wrapper .form-header-container .form-header-toggle-container{display:none}\n"] }]
|
|
17989
|
+
args: [{ selector: 'lib-simple-service', template: "<div class=\"projectable-form-wrapper simple-service-wrapper\"\n (keyup.enter)=\"save($event)\"\n (keyup.escape)=\"closeModal(true, false, 'cards', $event)\"\n tabindex=\"0\"\n>\n <lib-form-header\n [data]=\"formData\"\n [title]=\"showForm ? 'Create a Simple Service' : 'Service Creation Summary'\"\n [actionButtonText]=\"'Save'\"\n (actionRequested)=\"headerActionRequested($event)\"\n [(formView)]=\"formView\"\n ></lib-form-header>\n <div class=\"simple-service-form-container projectable-form-container\">\n <div class=\"form-group-column three-fifths\" *ngIf=\"showForm\">\n <div id=\"InlineServiceArea\" class=\"anyadd\">\n <div class=\"simple-service-inputs\">\n <lib-form-field-container [title]=\"'Service Details'\">\n <div class=\"form-field-input-group service-group\">\n <div class=\"form-field-sub-group\">\n <div class=\"config-title-row\">\n <span class=\"form-field-title\">Service Name</span>\n </div>\n <input\n class=\"form-field-input\"\n placeholder=\"Name this service\"\n autofocus\n #nameFieldInput\n [ngClass]=\"{error: errors.name}\"\n [(ngModel)]=\"serviceApiData.name\"\n (keyup)=\"serviceNameChanged($event)\"\n (change)=\"validateServiceName()\"\n />\n </div>\n <div class=\"form-field-sub-group\">\n <div class=\"config-title-row\">\n <span class=\"form-field-title\">SELECT OR CREATE SERVICE ATTRIBUTES</span>\n </div>\n <lib-tag-selector\n [(selectedRoleAttributes)]=\"serviceApiData.roleAttributes\"\n [availableRoleAttributes]=\"serviceRoleAttributes\"\n [placeholder]=\"'Add attributes to group services'\"\n ></lib-tag-selector>\n </div>\n </div>\n </lib-form-field-container>\n </div>\n </div>\n </div>\n <div class=\"simple-service-center-content\" *ngIf=\"showForm\">\n <div class=\"form-group-row\">\n <lib-form-field-container\n [title]=\"'ACCESSING CONFIGURATION'\"\n [contentStyle]=\"'z-index: 10001'\"\n [helpText]=\"'How will client applications use this service? Specify a hostname/IP and port, or use the "SDK Only" toggle for an application embedded configuration.'\"\n >\n <div class=\"form-field-input-group accessing-group\">\n <div class=\"form-field-sub-group\">\n <div class=\"config-title-row\">\n <span class=\"form-field-title\">What identities can access this service?</span>\n </div>\n <lib-tag-selector\n [(selectedNamedAttributes)]=\"dialPolicyNamedAttributes\"\n [(selectedRoleAttributes)]=\"dialPolicyRoleAttributes\"\n [availableNamedAttributes]=\"identityNamedAttributes\"\n [availableRoleAttributes]=\"identityRoleAttributes\"\n [placeholder]=\"'Select identity attributes to grant access'\"\n [hasError]=\"errors.dialIdentities\"\n (selectedNamedAttributesChange)=\"validateDialIdentities()\"\n (selectedRoleAttributesChange)=\"validateDialIdentities()\"\n (filterChange)=\"getIdentityNamedAttributes($event)\"\n ></lib-tag-selector>\n </div>\n <div class=\"form-field-sub-group\">\n <div class=\"config-title-row\">\n <span class=\"form-field-title\">How will the service be accessed?</span>\n </div>\n <div class=\"grid addressPort\">\n <div class=\"config-item-container\">\n <span class=\"config-item-label\">SDK ONLY</span>\n <div\n class=\"sdk-toggle form-field-toggle\"\n >\n <div class=\"switchGrid\">\n <div>\n <div\n (click)=\"toggleSdkOnlyDial()\"\n [ngClass]=\"{ on: sdkOnlyDial }\"\n class=\"toggle\"\n >\n <span [hidden]=\"!sdkOnlyDial\" class=\"on-label\">YES</span>\n <span [hidden]=\"sdkOnlyDial\" class=\"off-label\">NO</span>\n <div class=\"switch\"></div>\n </div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"config-item-container\" [ngClass]=\"{disabled: sdkOnlyDial}\">\n <div class=\"config-hostname-label\">\n <span class=\"config-item-label\">HOSTNAME / IP</span>\n <div\n class=\"form-field-info infoicon\"\n matTooltip=\"Accessing hostnames must include a '.'\"\n matTooltipPosition=\"above\"\n ></div>\n <span *ngIf=\"errors.interceptAddressFormat\" class=\"error-label\">Accessing hostnames must include a '.'</span>\n </div>\n <input id=\"HowTo\" type=\"text\" maxlength=\"100\" data-i18n=\"EgHost\" (change)=\"validateInterceptAddress()\" [ngClass]=\"{error: errors.interceptAddress}\" [placeholder]=\"sdkOnlyDial ? '' : 'e.g. myservice.ziti'\" [(ngModel)]=\"sdkOnlyDial ? '' : interceptConfigApiData.data.addresses[0]\">\n </div>\n <div class=\"config-item-container\" [ngClass]=\"{disabled: sdkOnlyDial}\">\n <span class=\"config-item-label\">PORT</span>\n <input id=\"HowToPort\" type=\"number\" maxlength=\"10\" (change)=\"validateInterceptPort()\" [ngClass]=\"{error: errors.interceptPort}\" [placeholder]=\"sdkOnlyDial ? '' : 443\" (keyup)=\"interceptPortChanged($event)\" [(ngModel)]=\"sdkOnlyDial ? '' : interceptPort\">\n </div>\n </div>\n </div>\n </div>\n </lib-form-field-container>\n <lib-form-field-container\n [title]=\"'HOSTING CONFIGURATION'\"\n [contentStyle]=\"'z-index: 10000'\"\n [helpText]=\"'Where should traffic for this service be sent? Specify a protocol, hostname/IP, and port, or use the "SDK Only" toggle for an application embedded configuration.'\"\n\n >\n <div class=\"form-field-input-group hosting-group\">\n <div class=\"form-field-sub-group\">\n <div class=\"config-title-row\">\n <span class=\"form-field-title\">What identities can host this service?</span>\n </div>\n <lib-tag-selector\n [(selectedNamedAttributes)]=\"bindPolicyNamedAttributes\"\n [(selectedRoleAttributes)]=\"bindPolicyRoleAttributes\"\n [availableNamedAttributes]=\"identityNamedAttributes\"\n [availableRoleAttributes]=\"identityRoleAttributes\"\n [placeholder]=\"'Select identity attributes'\"\n [hasError]=\"errors.bindIdentities\"\n (selectedNamedAttributesChange)=\"validateBindIdentities()\"\n (selectedRoleAttributesChange)=\"validateBindIdentities()\"\n (filterChange)=\"getIdentityNamedAttributes($event)\"\n ></lib-tag-selector>\n </div>\n <div class=\"form-field-sub-group\">\n <div class=\"config-title-row\">\n <span class=\"form-field-title\">Where should traffic be sent?</span>\n </div>\n <div class=\"grid addressFull\">\n <div class=\"config-item-container\">\n <span class=\"config-item-label\">SDK ONLY</span>\n <div\n class=\"sdk-toggle form-field-toggle\"\n >\n <div class=\"switchGrid\">\n <div>\n <div\n (click)=\"toggleSdkOnlyBind()\"\n [ngClass]=\"{ on: sdkOnlyBind }\"\n class=\"toggle\"\n >\n <span [hidden]=\"!sdkOnlyBind\" class=\"on-label\">YES</span>\n <span [hidden]=\"sdkOnlyBind\" class=\"off-label\">NO</span>\n <div class=\"switch\"></div>\n </div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"config-item-container\" [ngClass]=\"{disabled: sdkOnlyBind}\">\n <span class=\"config-item-label\">PROTOCOL</span>\n <select id=\"HostedProtocol\" (change)=\"hostProtocolsChanged($event)\" [(ngModel)]=\"sdkOnlyBind ? '' : hostProtocol\">\n <option value=\"tcp\">TCP</option>\n <option value=\"udp\" >UDP</option>\n <option value=\"both\" >TCP/UDP</option>\n </select>\n </div>\n <div class=\"config-item-container\" [ngClass]=\"{disabled: sdkOnlyBind}\">\n <span class=\"config-item-label\">HOSTNAME / IP</span>\n <input id=\"HostedHost\" type=\"text\" maxlength=\"100\" data-i18n=\"EgHost\" (change)=\"validateHostAddress()\" [ngClass]=\"{error: errors.hostAddress}\" [placeholder]=\"sdkOnlyBind ? '' : 'e.g. myservice.ziti'\" [(ngModel)]=\"sdkOnlyBind ? '' : hostConfigApiData.data.address\">\n </div>\n <div class=\"config-item-container\" [ngClass]=\"{disabled: sdkOnlyBind}\">\n <span class=\"config-item-label\">PORT</span>\n <input id=\"HostedPort\" type=\"number\" maxlength=\"10\" (change)=\"validateHostPort()\" [ngClass]=\"{error: errors.hostPort}\" [placeholder]=\"sdkOnlyBind ? '' : 443\" [(ngModel)]=\"sdkOnlyBind ? '' : hostConfigApiData.data.port\">\n </div>\n </div>\n </div>\n </div>\n </lib-form-field-container>\n </div>\n </div>\n </div>\n</div>", styles: [".ziti-entity-header-container{display:flex;flex-direction:row;justify-content:space-between;align-items:center}.simple-service-wrapper .simple-service-form-container .form-group-column{height:-moz-fit-content;height:fit-content;max-width:40.625rem;width:100%;transition:var(--transition);flex-grow:0;padding-bottom:0}.simple-service-wrapper .simple-service-form-container .simple-service-center-content lib-form-field-container{min-width:23.4375rem}.simple-service-wrapper .simple-service-form-container .simple-service-center-content .form-field-input-group{display:flex;flex-direction:column;gap:.9375rem}.simple-service-wrapper .grid.addressFull{grid-template-columns:4.375rem 5.9375rem auto 4.0625rem}.simple-service-wrapper .grid.addressPort{grid-template-columns:4.375rem auto 4.0625rem}.simple-service-wrapper input:disabled{opacity:.5!important}.simple-service-wrapper .addressPort .config-item-container.disabled,.simple-service-wrapper .addressFull .config-item-container.disabled{opacity:.3;pointer-events:none}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle{color:var(--white);display:flex;justify-content:space-between;height:var(--defaultInputHeight);align-items:center;margin-bottom:0}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .label,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .label{display:flex;font-size:.875rem;font-weight:600;text-transform:uppercase}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .toggle,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .toggle{margin:0;display:flex;align-items:center;width:3.75rem;height:1.75rem;font-size:.875rem;line-height:1.5625rem;font-weight:800;font-family:Open Sans,Arial,sans-serif;background-color:var(--icon);color:var(--white);text-align:center;cursor:pointer;position:relative;float:left;border-radius:.8125rem}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .toggle.on,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .toggle.on{background-color:var(--green)}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .toggle .switch,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .toggle .switch{width:1.25rem;height:1.25rem;border-radius:.625rem;background-color:var(--white);transition:var(--transition);position:absolute;top:.25rem;z-index:10}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .toggle .switch.on,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .toggle .switch.on{left:2.1875rem}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .toggle .on-label,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .toggle .on-label{margin-left:.4375rem}.simple-service-wrapper .addressPort .config-item-container .sdk-toggle .toggle .off-label,.simple-service-wrapper .addressFull .config-item-container .sdk-toggle .toggle .off-label{margin-left:2rem}.simple-service-wrapper .addressPort .config-item-container .config-hostname-label,.simple-service-wrapper .addressFull .config-item-container .config-hostname-label{display:flex;flex-direction:row;justify-content:flex-start;white-space:nowrap}.simple-service-wrapper .addressPort .config-item-container .config-hostname-label .form-field-info,.simple-service-wrapper .addressFull .config-item-container .config-hostname-label .form-field-info{margin-top:.0625rem}.simple-service-wrapper .addressPort .config-item-container .config-hostname-label .error-label,.simple-service-wrapper .addressFull .config-item-container .config-hostname-label .error-label{margin-left:.3125rem}.simple-service-wrapper .form-field-input-group.service-group{gap:.625rem;display:flex;flex-direction:column}.simple-service-wrapper .form-field-input-group.accessing-group{gap:.9375rem;display:flex;flex-direction:column}.simple-service-wrapper .form-field-input-group .form-field-sub-group{display:flex;flex-direction:column;gap:.3125rem}.simple-service-wrapper .form-field-input-group .form-field-sub-group .config-title-row{height:.875rem}.simple-service-wrapper .form-field-input-group .form-field-sub-group .addressFull,.simple-service-wrapper .form-field-input-group .form-field-sub-group .addressPort{gap:.625rem}.simple-service-wrapper .form-field-input-group .form-field-sub-group .addressFull select{height:var(--defaultInputHeight)}.simple-service-wrapper .simple-service-center-content{display:flex;flex-direction:column;width:100%;align-items:center;justify-content:center}.simple-service-wrapper .simple-service-center-content .form-group-row{flex-wrap:wrap;gap:.9375rem;max-width:40.625rem;justify-content:center;padding:0}.config-item-label{color:#a9abaf;font-weight:600;margin-bottom:.3125rem;position:relative;display:flex}.simple-service-inputs{display:flex;flex-direction:column;gap:.9375rem}.form-field-input-group .form-field-title{color:var(--offWhite);margin-bottom:.625rem}.config-item .config-container.encryption-pod{background-color:#222f3e;background-image:linear-gradient(90deg,#232f3e,#f6f7fb);background-image:-ms-linear-gradient(90deg,rgb(35,47,62) 0%,rgb(246,247,251) 100%);border-radius:var(--inputBorderRadius)}.config-item .config-container .config-container-label{color:#fff}::ng-deep .simple-service-wrapper input{max-height:var(--defaultInputHeight);min-height:0rem;height:var(--defaultInputHeight)}::ng-deep .simple-service-wrapper .select2-search__field{height:100%;min-height:2.5rem;max-height:2.5rem}::ng-deep .simple-service-wrapper .select2-selection__rendered{padding:0;max-height:7.1875rem!important;overflow:auto}::ng-deep .simple-service-wrapper .form-header-container{align-items:center}::ng-deep .simple-service-wrapper .form-header-container .form-header-group{width:40.625rem!important}::ng-deep .simple-service-wrapper .form-header-container .header-actions-container{min-width:0rem}::ng-deep .simple-service-wrapper .form-header-container .form-header-toggle-container{display:none}\n"] }]
|
|
17975
17990
|
}], ctorParameters: function () { return [{ type: SettingsService, decorators: [{
|
|
17976
17991
|
type: Inject,
|
|
17977
17992
|
args: [SETTINGS_SERVICE]
|
|
@@ -23863,6 +23878,565 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImpo
|
|
|
23863
23878
|
args: [MAT_DIALOG_DATA]
|
|
23864
23879
|
}] }, { type: i4.Router }, { type: i3$2.MatDialogRef }]; } });
|
|
23865
23880
|
|
|
23881
|
+
/*
|
|
23882
|
+
Copyright NetFoundry Inc.
|
|
23883
|
+
|
|
23884
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
23885
|
+
you may not use this file except in compliance with the License.
|
|
23886
|
+
You may obtain a copy of the License at
|
|
23887
|
+
|
|
23888
|
+
https://www.apache.org/licenses/LICENSE-2.0
|
|
23889
|
+
|
|
23890
|
+
Unless required by applicable law or agreed to in writing, software
|
|
23891
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
23892
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
23893
|
+
See the License for the specific language governing permissions and
|
|
23894
|
+
limitations under the License.
|
|
23895
|
+
*/
|
|
23896
|
+
class ConfigTypesPageService extends ListPageServiceClass {
|
|
23897
|
+
constructor(schemaSvc, settings, filterService, csvDownloadService, extService, router) {
|
|
23898
|
+
super(settings, filterService, csvDownloadService, extService, router);
|
|
23899
|
+
this.schemaSvc = schemaSvc;
|
|
23900
|
+
this.router = router;
|
|
23901
|
+
this.paging = this.DEFAULT_PAGING;
|
|
23902
|
+
this.resourceType = 'config-types';
|
|
23903
|
+
this.selectedConfig = {};
|
|
23904
|
+
this.modalType = '';
|
|
23905
|
+
this.menuItems = [
|
|
23906
|
+
{ name: 'Edit', action: 'update' },
|
|
23907
|
+
{ name: 'Delete', action: 'delete' },
|
|
23908
|
+
];
|
|
23909
|
+
}
|
|
23910
|
+
initTableColumns() {
|
|
23911
|
+
const createdAtHeaderComponentParams = {
|
|
23912
|
+
filterType: 'DATETIME',
|
|
23913
|
+
};
|
|
23914
|
+
return [
|
|
23915
|
+
{
|
|
23916
|
+
colId: 'name',
|
|
23917
|
+
field: 'name',
|
|
23918
|
+
headerName: 'Name',
|
|
23919
|
+
headerComponent: TableColumnDefaultComponent,
|
|
23920
|
+
headerComponentParams: this.headerComponentParams,
|
|
23921
|
+
cellRenderer: TableCellNameComponent,
|
|
23922
|
+
cellRendererParams: { pathRoot: this.basePath },
|
|
23923
|
+
onCellClicked: (data) => {
|
|
23924
|
+
if (this.hasSelectedText()) {
|
|
23925
|
+
return;
|
|
23926
|
+
}
|
|
23927
|
+
this.openEditForm(data?.data?.id);
|
|
23928
|
+
},
|
|
23929
|
+
resizable: true,
|
|
23930
|
+
cellClass: 'nf-cell-vert-align tCol',
|
|
23931
|
+
sortable: true,
|
|
23932
|
+
filter: true,
|
|
23933
|
+
sortColumn: this.sort.bind(this),
|
|
23934
|
+
},
|
|
23935
|
+
{
|
|
23936
|
+
colId: 'createdAt',
|
|
23937
|
+
field: 'createdAt',
|
|
23938
|
+
headerName: 'Created At',
|
|
23939
|
+
headerComponent: TableColumnDefaultComponent,
|
|
23940
|
+
headerComponentParams: createdAtHeaderComponentParams,
|
|
23941
|
+
valueFormatter: this.createdAtFormatter,
|
|
23942
|
+
resizable: true,
|
|
23943
|
+
cellClass: 'nf-cell-vert-align tCol',
|
|
23944
|
+
width: this.remToPx(10),
|
|
23945
|
+
}
|
|
23946
|
+
];
|
|
23947
|
+
}
|
|
23948
|
+
getData(filters, sort) {
|
|
23949
|
+
// we can customize filters or sorting here before moving on...
|
|
23950
|
+
return super.getTableData('config-types', this.paging, filters, sort)
|
|
23951
|
+
.then((results) => {
|
|
23952
|
+
return this.processData(results);
|
|
23953
|
+
});
|
|
23954
|
+
}
|
|
23955
|
+
processData(results) {
|
|
23956
|
+
if (!isEmpty(results?.data)) {
|
|
23957
|
+
//pre-process data before rendering
|
|
23958
|
+
results.data = this.addActionsPerRow(results);
|
|
23959
|
+
}
|
|
23960
|
+
return results;
|
|
23961
|
+
}
|
|
23962
|
+
addActionsPerRow(results) {
|
|
23963
|
+
const reservedConfigTypes = ['host.v1', 'host.v2', 'intercept.v1', 'ziti-tunneler-client.v1', 'ziti-tunneler-server.v1'];
|
|
23964
|
+
return results.data.map((row) => {
|
|
23965
|
+
row.actionList = ['update', 'delete'];
|
|
23966
|
+
if (reservedConfigTypes.includes(row.name)) {
|
|
23967
|
+
row.reserved = true;
|
|
23968
|
+
}
|
|
23969
|
+
return row;
|
|
23970
|
+
});
|
|
23971
|
+
}
|
|
23972
|
+
openUpdate(item) {
|
|
23973
|
+
this.modalType = 'config';
|
|
23974
|
+
if (item) {
|
|
23975
|
+
this.selectedConfig = item;
|
|
23976
|
+
this.selectedConfig.badges = [];
|
|
23977
|
+
unset(this.selectedConfig, '_links');
|
|
23978
|
+
}
|
|
23979
|
+
else {
|
|
23980
|
+
this.selectedConfig = new Service$1();
|
|
23981
|
+
}
|
|
23982
|
+
this.sideModalOpen = true;
|
|
23983
|
+
}
|
|
23984
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ConfigTypesPageService, deps: [{ token: SchemaService }, { token: SETTINGS_SERVICE }, { token: DataTableFilterService }, { token: CsvDownloadService }, { token: SHAREDZ_EXTENSION }, { token: i4.Router }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
23985
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ConfigTypesPageService, providedIn: 'root' }); }
|
|
23986
|
+
}
|
|
23987
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ConfigTypesPageService, decorators: [{
|
|
23988
|
+
type: Injectable,
|
|
23989
|
+
args: [{
|
|
23990
|
+
providedIn: 'root'
|
|
23991
|
+
}]
|
|
23992
|
+
}], ctorParameters: function () { return [{ type: SchemaService }, { type: SettingsService, decorators: [{
|
|
23993
|
+
type: Inject,
|
|
23994
|
+
args: [SETTINGS_SERVICE]
|
|
23995
|
+
}] }, { type: DataTableFilterService }, { type: CsvDownloadService }, { type: undefined, decorators: [{
|
|
23996
|
+
type: Inject,
|
|
23997
|
+
args: [SHAREDZ_EXTENSION]
|
|
23998
|
+
}] }, { type: i4.Router }]; } });
|
|
23999
|
+
|
|
24000
|
+
/*
|
|
24001
|
+
Copyright NetFoundry Inc.
|
|
24002
|
+
|
|
24003
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
24004
|
+
you may not use this file except in compliance with the License.
|
|
24005
|
+
You may obtain a copy of the License at
|
|
24006
|
+
|
|
24007
|
+
https://www.apache.org/licenses/LICENSE-2.0
|
|
24008
|
+
|
|
24009
|
+
Unless required by applicable law or agreed to in writing, software
|
|
24010
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
24011
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
24012
|
+
See the License for the specific language governing permissions and
|
|
24013
|
+
limitations under the License.
|
|
24014
|
+
*/
|
|
24015
|
+
class ConfigTypesPageComponent extends ListPageComponent {
|
|
24016
|
+
constructor(svc, filterService, tabNames, consoleEvents, dialogForm) {
|
|
24017
|
+
super(filterService, svc, consoleEvents, dialogForm);
|
|
24018
|
+
this.svc = svc;
|
|
24019
|
+
this.tabNames = tabNames;
|
|
24020
|
+
this.title = 'Config Types';
|
|
24021
|
+
this.formDataChanged = false;
|
|
24022
|
+
this.reservedNames = ['host.v1', 'host.v2', 'intercept.v1', 'ziti-tunneler-client.v1', 'ziti-tunneler-server.v1'];
|
|
24023
|
+
}
|
|
24024
|
+
ngOnInit() {
|
|
24025
|
+
this.tabs = this.tabNames.getTabs('services');
|
|
24026
|
+
this.svc.refreshData = this.refreshData;
|
|
24027
|
+
super.ngOnInit();
|
|
24028
|
+
}
|
|
24029
|
+
headerActionClicked(action) {
|
|
24030
|
+
switch (action) {
|
|
24031
|
+
case 'add':
|
|
24032
|
+
this.svc.openEditForm();
|
|
24033
|
+
break;
|
|
24034
|
+
case 'edit':
|
|
24035
|
+
this.svc.openEditForm();
|
|
24036
|
+
break;
|
|
24037
|
+
case 'delete':
|
|
24038
|
+
const selectedItems = this.rowData.filter((row) => {
|
|
24039
|
+
return row.selected;
|
|
24040
|
+
});
|
|
24041
|
+
const label = selectedItems.length > 1 ? 'config types' : 'config type';
|
|
24042
|
+
this.openBulkDelete(selectedItems, label);
|
|
24043
|
+
break;
|
|
24044
|
+
default:
|
|
24045
|
+
}
|
|
24046
|
+
}
|
|
24047
|
+
tableAction(event) {
|
|
24048
|
+
switch (event?.action) {
|
|
24049
|
+
case 'toggleAll':
|
|
24050
|
+
case 'toggleItem':
|
|
24051
|
+
this.itemToggled(event.item);
|
|
24052
|
+
break;
|
|
24053
|
+
case 'update':
|
|
24054
|
+
this.svc.openEditForm(event.item?.id);
|
|
24055
|
+
break;
|
|
24056
|
+
case 'create':
|
|
24057
|
+
this.svc.openEditForm();
|
|
24058
|
+
break;
|
|
24059
|
+
case 'delete':
|
|
24060
|
+
this.deleteItem(event.item);
|
|
24061
|
+
break;
|
|
24062
|
+
case 'download-all':
|
|
24063
|
+
this.downloadAllItems();
|
|
24064
|
+
break;
|
|
24065
|
+
case 'download-selected':
|
|
24066
|
+
this.svc.downloadItems(this.selectedItems);
|
|
24067
|
+
break;
|
|
24068
|
+
default:
|
|
24069
|
+
break;
|
|
24070
|
+
}
|
|
24071
|
+
}
|
|
24072
|
+
deleteItem(item) {
|
|
24073
|
+
this.openBulkDelete([item], 'config type');
|
|
24074
|
+
}
|
|
24075
|
+
closeModal(event) {
|
|
24076
|
+
this.svc.sideModalOpen = false;
|
|
24077
|
+
if (event?.refresh) {
|
|
24078
|
+
this.refreshData();
|
|
24079
|
+
}
|
|
24080
|
+
}
|
|
24081
|
+
dataChanged(event) {
|
|
24082
|
+
this.formDataChanged = event;
|
|
24083
|
+
}
|
|
24084
|
+
confirmAssociatedDelete(configsWithAssociations, selectedItems, label) {
|
|
24085
|
+
const configNames = configsWithAssociations.map((item) => {
|
|
24086
|
+
return item.name;
|
|
24087
|
+
});
|
|
24088
|
+
const data = {
|
|
24089
|
+
appendId: 'DeleteConfigTypesWithAssociations',
|
|
24090
|
+
title: 'Config Type In Use',
|
|
24091
|
+
message: `The following config types are still in use by a service:`,
|
|
24092
|
+
submessage: 'Deleting these config types may cause disruption to those services. Would you still like to continue?',
|
|
24093
|
+
bulletList: configNames,
|
|
24094
|
+
confirmLabel: 'Yes',
|
|
24095
|
+
cancelLabel: 'Oops, no get me out of here',
|
|
24096
|
+
imageUrl: '../../assets/svgs/Growl_Warning.svg',
|
|
24097
|
+
showCancelLink: true
|
|
24098
|
+
};
|
|
24099
|
+
this.dialogRef = this.dialogForm.open(ConfirmComponent, {
|
|
24100
|
+
data: data,
|
|
24101
|
+
autoFocus: false,
|
|
24102
|
+
});
|
|
24103
|
+
this.dialogRef.afterClosed().subscribe((result) => {
|
|
24104
|
+
if (result?.confirmed) {
|
|
24105
|
+
this.openBulkDelete(selectedItems, label);
|
|
24106
|
+
}
|
|
24107
|
+
});
|
|
24108
|
+
}
|
|
24109
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ConfigTypesPageComponent, deps: [{ token: ConfigTypesPageService }, { token: DataTableFilterService }, { token: TabNameService }, { token: ConsoleEventsService }, { token: i3$2.MatDialog }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
24110
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: ConfigTypesPageComponent, selector: "lib-configurations", usesInheritance: true, ngImport: i0, template: "<div class=\"ziti-page-container ziti-config-types-container\">\n <lib-list-page-header [title]=\"title\"\n [tabs]=\"tabs\"\n [showAdd]=\"!itemsSelected\"\n (actionClicked)=\"headerActionClicked($event)\"></lib-list-page-header>\n\n <lib-data-table [tableId]=\"'config-types'\"\n [rowData]=\"rowData\"\n [columnDefinitions]=\"columnDefs\"\n (actionRequested)=\"tableAction($event)\"\n [startCount]=\"startCount\"\n [endCount]=\"endCount\"\n [totalCount]=\"totalCount\"\n [emptyMsg]=\"'No Config Types defined, Click the plus to add a Configuration.'\"\n [filterApplied]=\"filterApplied\"\n [menuItems]=\"svc.menuItems\"\n (gridReady)=\"gridReady($event)\"\n >\n </lib-data-table>\n</div>\n", styles: [".ziti-config-types-container{width:100%;height:100%;display:flex;flex-direction:column;position:relative;flex:1 1 auto}\n"], dependencies: [{ kind: "component", type: ListPageHeaderComponent, selector: "lib-list-page-header", inputs: ["title", "tabs", "showAdd", "hideAction"], outputs: ["actionClicked"] }, { kind: "component", type: DataTableComponent, selector: "lib-data-table", inputs: ["rowData", "expandRowData", "collapseRowData", "rowValidation", "isTimeSearchAvailable", "isLoading", "tableId", "options", "validateService", "rowsToggled", "tableRefreshCount", "view", "serverSideDataSource", "allowDownload", "startCount", "endCount", "totalCount", "emptyMsg", "filterApplied", "menuItems", "headerActions", "noItemsClass", "entityTypeName", "showNoItemsAdd", "currentPage", "noItemsImage", "rowHeight", "filterName", "filterColumn", "columnDefinitions", "refreshCount"], outputs: ["actionRequested", "gridReady", "dragStart", "dragLeave", "pageChanged"] }] }); }
|
|
24111
|
+
}
|
|
24112
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ConfigTypesPageComponent, decorators: [{
|
|
24113
|
+
type: Component,
|
|
24114
|
+
args: [{ selector: 'lib-configurations', template: "<div class=\"ziti-page-container ziti-config-types-container\">\n <lib-list-page-header [title]=\"title\"\n [tabs]=\"tabs\"\n [showAdd]=\"!itemsSelected\"\n (actionClicked)=\"headerActionClicked($event)\"></lib-list-page-header>\n\n <lib-data-table [tableId]=\"'config-types'\"\n [rowData]=\"rowData\"\n [columnDefinitions]=\"columnDefs\"\n (actionRequested)=\"tableAction($event)\"\n [startCount]=\"startCount\"\n [endCount]=\"endCount\"\n [totalCount]=\"totalCount\"\n [emptyMsg]=\"'No Config Types defined, Click the plus to add a Configuration.'\"\n [filterApplied]=\"filterApplied\"\n [menuItems]=\"svc.menuItems\"\n (gridReady)=\"gridReady($event)\"\n >\n </lib-data-table>\n</div>\n", styles: [".ziti-config-types-container{width:100%;height:100%;display:flex;flex-direction:column;position:relative;flex:1 1 auto}\n"] }]
|
|
24115
|
+
}], ctorParameters: function () { return [{ type: ConfigTypesPageService }, { type: DataTableFilterService }, { type: TabNameService }, { type: ConsoleEventsService }, { type: i3$2.MatDialog }]; } });
|
|
24116
|
+
|
|
24117
|
+
class ConfigType {
|
|
24118
|
+
constructor() {
|
|
24119
|
+
this.name = '';
|
|
24120
|
+
this.id = '';
|
|
24121
|
+
this.schema = {};
|
|
24122
|
+
this.tags = {};
|
|
24123
|
+
}
|
|
24124
|
+
}
|
|
24125
|
+
;
|
|
24126
|
+
|
|
24127
|
+
class ConfigTypeFormService {
|
|
24128
|
+
constructor(dataService, extService, schemaSvc, growlerService, validationService) {
|
|
24129
|
+
this.dataService = dataService;
|
|
24130
|
+
this.extService = extService;
|
|
24131
|
+
this.schemaSvc = schemaSvc;
|
|
24132
|
+
this.growlerService = growlerService;
|
|
24133
|
+
this.validationService = validationService;
|
|
24134
|
+
this.configTypes = [];
|
|
24135
|
+
this.items = [];
|
|
24136
|
+
this.errors = [];
|
|
24137
|
+
this.saveDisabled = false;
|
|
24138
|
+
this.configJsonView = false;
|
|
24139
|
+
this.configDataLabel = 'Config Type Form';
|
|
24140
|
+
}
|
|
24141
|
+
async getSchema(schemaType) {
|
|
24142
|
+
if (!schemaType)
|
|
24143
|
+
return Promise.resolve();
|
|
24144
|
+
for (let idx = 0; idx < this.configTypes.length; idx++) {
|
|
24145
|
+
if (this.configTypes[idx].id === schemaType)
|
|
24146
|
+
return this.configTypes[idx].schema;
|
|
24147
|
+
}
|
|
24148
|
+
}
|
|
24149
|
+
save(formData) {
|
|
24150
|
+
const isUpdate = !isEmpty(formData.id);
|
|
24151
|
+
const data = this.getConfigDataModel(formData, isUpdate);
|
|
24152
|
+
let prom;
|
|
24153
|
+
if (isUpdate) {
|
|
24154
|
+
prom = this.dataService.patch('config-types', data, formData.id, true);
|
|
24155
|
+
}
|
|
24156
|
+
else {
|
|
24157
|
+
prom = this.dataService.post('config-types', data, true);
|
|
24158
|
+
}
|
|
24159
|
+
return prom.then(async (result) => {
|
|
24160
|
+
const id = isUpdate ? formData.id : (result?.data?.id || result?.id);
|
|
24161
|
+
let config = await this.dataService.getSubdata('config-types', id, '').then((svcData) => {
|
|
24162
|
+
return svcData.data;
|
|
24163
|
+
});
|
|
24164
|
+
return this.extService.formDataSaved(config).then((formSavedResult) => {
|
|
24165
|
+
if (!formSavedResult) {
|
|
24166
|
+
return config;
|
|
24167
|
+
}
|
|
24168
|
+
const growlerData = new GrowlerModel('success', 'Success', `Config Type ${isUpdate ? 'Updated' : 'Created'}`, `Successfully ${isUpdate ? 'updated' : 'created'} Config Type: ${formData.name}`);
|
|
24169
|
+
this.growlerService.show(growlerData);
|
|
24170
|
+
return config;
|
|
24171
|
+
}).catch((result) => {
|
|
24172
|
+
return false;
|
|
24173
|
+
});
|
|
24174
|
+
}).catch((resp) => {
|
|
24175
|
+
const errorMessage = this.dataService.getErrorMessage(resp);
|
|
24176
|
+
const growlerData = new GrowlerModel('error', 'Error', `Error ${isUpdate ? 'Updating' : 'Creating'} Config Type`, errorMessage);
|
|
24177
|
+
this.growlerService.show(growlerData);
|
|
24178
|
+
throw resp;
|
|
24179
|
+
});
|
|
24180
|
+
}
|
|
24181
|
+
getConfigDataModel(formData, isUpdate) {
|
|
24182
|
+
const saveModel = new Config();
|
|
24183
|
+
const modelProperties = keys(saveModel);
|
|
24184
|
+
modelProperties.forEach((prop) => {
|
|
24185
|
+
switch (prop) {
|
|
24186
|
+
default:
|
|
24187
|
+
saveModel[prop] = formData[prop];
|
|
24188
|
+
}
|
|
24189
|
+
});
|
|
24190
|
+
saveModel.data = this.validationService.redefineObject(saveModel.data);
|
|
24191
|
+
return saveModel;
|
|
24192
|
+
}
|
|
24193
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ConfigTypeFormService, deps: [{ token: ZITI_DATA_SERVICE }, { token: SHAREDZ_EXTENSION }, { token: SchemaService }, { token: GrowlerService }, { token: ValidationService }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
24194
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ConfigTypeFormService, providedIn: 'root' }); }
|
|
24195
|
+
}
|
|
24196
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ConfigTypeFormService, decorators: [{
|
|
24197
|
+
type: Injectable,
|
|
24198
|
+
args: [{
|
|
24199
|
+
providedIn: 'root'
|
|
24200
|
+
}]
|
|
24201
|
+
}], ctorParameters: function () { return [{ type: ZitiDataService, decorators: [{
|
|
24202
|
+
type: Inject,
|
|
24203
|
+
args: [ZITI_DATA_SERVICE]
|
|
24204
|
+
}] }, { type: undefined, decorators: [{
|
|
24205
|
+
type: Inject,
|
|
24206
|
+
args: [SHAREDZ_EXTENSION]
|
|
24207
|
+
}] }, { type: SchemaService }, { type: GrowlerService }, { type: ValidationService }]; } });
|
|
24208
|
+
|
|
24209
|
+
/*
|
|
24210
|
+
Copyright NetFoundry Inc.
|
|
24211
|
+
|
|
24212
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
24213
|
+
you may not use this file except in compliance with the License.
|
|
24214
|
+
You may obtain a copy of the License at
|
|
24215
|
+
|
|
24216
|
+
https://www.apache.org/licenses/LICENSE-2.0
|
|
24217
|
+
|
|
24218
|
+
Unless required by applicable law or agreed to in writing, software
|
|
24219
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
24220
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
24221
|
+
See the License for the specific language governing permissions and
|
|
24222
|
+
limitations under the License.
|
|
24223
|
+
*/
|
|
24224
|
+
class ConfigTypeFormComponent extends ProjectableForm {
|
|
24225
|
+
constructor(svc, schemaSvc, growlerService, extService, settingsService, zitiService, router, route, location, validationService) {
|
|
24226
|
+
super(growlerService, extService, zitiService, router, route, location, settingsService);
|
|
24227
|
+
this.svc = svc;
|
|
24228
|
+
this.schemaSvc = schemaSvc;
|
|
24229
|
+
this.settingsService = settingsService;
|
|
24230
|
+
this.zitiService = zitiService;
|
|
24231
|
+
this.router = router;
|
|
24232
|
+
this.route = route;
|
|
24233
|
+
this.validationService = validationService;
|
|
24234
|
+
this.formData = {};
|
|
24235
|
+
this.errors = {};
|
|
24236
|
+
this.close = new EventEmitter();
|
|
24237
|
+
this.options = [];
|
|
24238
|
+
this.isEditing = !isEmpty(this.formData.id);
|
|
24239
|
+
this.formView = 'simple';
|
|
24240
|
+
this.formDataInvalid = false;
|
|
24241
|
+
this.editMode = false;
|
|
24242
|
+
this.items = [];
|
|
24243
|
+
this.selectedSchema = '';
|
|
24244
|
+
this.associatedServices = [];
|
|
24245
|
+
this.associatedServiceNames = [];
|
|
24246
|
+
this.servicesLoading = false;
|
|
24247
|
+
this.settings = {};
|
|
24248
|
+
this.selectedConfigTypeId = '';
|
|
24249
|
+
this.entityType = 'config-types';
|
|
24250
|
+
this.entityClass = ConfigType;
|
|
24251
|
+
this._apiData = {};
|
|
24252
|
+
}
|
|
24253
|
+
ngOnInit() {
|
|
24254
|
+
super.ngOnInit();
|
|
24255
|
+
this.settingsService.settingsChange.subscribe((results) => {
|
|
24256
|
+
this.settings = results;
|
|
24257
|
+
});
|
|
24258
|
+
}
|
|
24259
|
+
entityUpdated() {
|
|
24260
|
+
if (isEmpty(this.formData?.data)) {
|
|
24261
|
+
this.formData.data = {};
|
|
24262
|
+
}
|
|
24263
|
+
if (isEmpty(this.formData?.configTypeId)) {
|
|
24264
|
+
this.formData.configTypeId = '';
|
|
24265
|
+
}
|
|
24266
|
+
this.selectedConfigTypeId = this.formData.configTypeId;
|
|
24267
|
+
this.initData = cloneDeep(this.formData);
|
|
24268
|
+
this.isEditing = !isEmpty(this.formData.id);
|
|
24269
|
+
if (this.configTypeEmpty) {
|
|
24270
|
+
this.formData.configTypeId = '';
|
|
24271
|
+
}
|
|
24272
|
+
}
|
|
24273
|
+
ngOnDestroy() {
|
|
24274
|
+
this.clearForm();
|
|
24275
|
+
}
|
|
24276
|
+
get configTypeEmpty() {
|
|
24277
|
+
return isEmpty(this.formData.configTypeId);
|
|
24278
|
+
}
|
|
24279
|
+
headerActionRequested(event) {
|
|
24280
|
+
switch (event.name) {
|
|
24281
|
+
case 'save':
|
|
24282
|
+
this.save(event);
|
|
24283
|
+
break;
|
|
24284
|
+
case 'close':
|
|
24285
|
+
this.returnToListPage();
|
|
24286
|
+
break;
|
|
24287
|
+
case 'toggle-view':
|
|
24288
|
+
this.formView = event.data;
|
|
24289
|
+
break;
|
|
24290
|
+
}
|
|
24291
|
+
}
|
|
24292
|
+
apiActionRequested(action) {
|
|
24293
|
+
switch (action.id) {
|
|
24294
|
+
case 'cli':
|
|
24295
|
+
this.copyCLICommand();
|
|
24296
|
+
break;
|
|
24297
|
+
case 'curl':
|
|
24298
|
+
this.copyCURLCommand();
|
|
24299
|
+
break;
|
|
24300
|
+
}
|
|
24301
|
+
}
|
|
24302
|
+
copyCLICommand() {
|
|
24303
|
+
const command = `ziti edge ${this.formData.id ? 'update' : 'create'} config-type ${this.formData.id ? `'${this.formData.id}'` : ''} ${this.formData.id ? '--name' : ''} '${this.formData.name}' --schema '${JSON.stringify(this.formData.schema)}' --tags-json '${JSON.stringify(this.formData.tags)}'`;
|
|
24304
|
+
navigator.clipboard.writeText(command);
|
|
24305
|
+
const growlerData = new GrowlerModel('success', 'Success', `Text Copied`, `CLI command copied to clipboard`);
|
|
24306
|
+
this.growlerService.show(growlerData);
|
|
24307
|
+
}
|
|
24308
|
+
copyCURLCommand() {
|
|
24309
|
+
const command = `curl '${this.apiCallURL}' \\
|
|
24310
|
+
${this.formData.id ? '--request PATCH \\' : '\\'}
|
|
24311
|
+
-H 'accept: application/json' \\
|
|
24312
|
+
-H 'content-type: application/json' \\
|
|
24313
|
+
-H 'zt-session: ${this.settings.session.id}' \\
|
|
24314
|
+
--data-raw '${JSON.stringify(this.apiData)}'`;
|
|
24315
|
+
navigator.clipboard.writeText(command);
|
|
24316
|
+
const growlerData = new GrowlerModel('success', 'Success', `Text Copied`, `CURL command copied to clipboard`);
|
|
24317
|
+
this.growlerService.show(growlerData);
|
|
24318
|
+
}
|
|
24319
|
+
clear() {
|
|
24320
|
+
this.formData.configTypeId = '';
|
|
24321
|
+
this.clearForm();
|
|
24322
|
+
}
|
|
24323
|
+
clearForm() {
|
|
24324
|
+
this.items.forEach((item) => {
|
|
24325
|
+
if (item?.component)
|
|
24326
|
+
item.component.destroy();
|
|
24327
|
+
});
|
|
24328
|
+
this.errors = {};
|
|
24329
|
+
this.items = [];
|
|
24330
|
+
this.formData = {};
|
|
24331
|
+
if (this.subscription)
|
|
24332
|
+
this.subscription.unsubscribe();
|
|
24333
|
+
}
|
|
24334
|
+
async save(event) {
|
|
24335
|
+
this.errors = {};
|
|
24336
|
+
if (isEmpty(this.formData.status)) {
|
|
24337
|
+
this.formData.status = {};
|
|
24338
|
+
}
|
|
24339
|
+
if (!this.validate()) {
|
|
24340
|
+
this.isLoading = false;
|
|
24341
|
+
return;
|
|
24342
|
+
}
|
|
24343
|
+
const configId = await this.svc.save(this.formData).then((result) => {
|
|
24344
|
+
if (!isEmpty(result?.id)) {
|
|
24345
|
+
this.formData = result;
|
|
24346
|
+
this.initData = this.formData;
|
|
24347
|
+
}
|
|
24348
|
+
return result?.id;
|
|
24349
|
+
}).finally(() => {
|
|
24350
|
+
this.isLoading = false;
|
|
24351
|
+
});
|
|
24352
|
+
if (configId) {
|
|
24353
|
+
this.initData = this.formData;
|
|
24354
|
+
this._dataChange = false;
|
|
24355
|
+
if (this.isModal) {
|
|
24356
|
+
this.closeModal(true, true);
|
|
24357
|
+
}
|
|
24358
|
+
else {
|
|
24359
|
+
this.returnToListPage();
|
|
24360
|
+
}
|
|
24361
|
+
}
|
|
24362
|
+
;
|
|
24363
|
+
}
|
|
24364
|
+
validate() {
|
|
24365
|
+
this.errors = {};
|
|
24366
|
+
const labels = [];
|
|
24367
|
+
if (isEmpty(this.formData.name)) {
|
|
24368
|
+
this.errors['name'] = true;
|
|
24369
|
+
labels.push('Name');
|
|
24370
|
+
}
|
|
24371
|
+
if (!this.validationService.isValidJSON(this.formData.schema)) {
|
|
24372
|
+
this.errors['schema'] = true;
|
|
24373
|
+
labels.push('Schema');
|
|
24374
|
+
}
|
|
24375
|
+
if (!isEmpty(this.errors)) {
|
|
24376
|
+
let errorLabels = '';
|
|
24377
|
+
labels.forEach((label, index) => {
|
|
24378
|
+
errorLabels += `<li>${label}</li>`;
|
|
24379
|
+
});
|
|
24380
|
+
errorLabels = `<ul>${errorLabels}</ul>`;
|
|
24381
|
+
const growler = new GrowlerModel('error', 'Invalid', `Invalid Form Data`, `Please correct the highlighted fields: ${errorLabels}`);
|
|
24382
|
+
this.growlerService.show(growler);
|
|
24383
|
+
}
|
|
24384
|
+
return isEmpty(this.errors);
|
|
24385
|
+
}
|
|
24386
|
+
get apiCallURL() {
|
|
24387
|
+
return this.settings.selectedEdgeController + '/edge/management/v1/config-types' + (this.formData.id ? `/${this.formData.id}` : '');
|
|
24388
|
+
}
|
|
24389
|
+
get apiData() {
|
|
24390
|
+
const data = {
|
|
24391
|
+
name: this.formData?.name || '',
|
|
24392
|
+
schema: this.formData?.schema || {},
|
|
24393
|
+
tags: this.formData?.tags
|
|
24394
|
+
};
|
|
24395
|
+
this._apiData = data;
|
|
24396
|
+
return this._apiData;
|
|
24397
|
+
}
|
|
24398
|
+
set apiData(data) {
|
|
24399
|
+
this._apiData = data;
|
|
24400
|
+
}
|
|
24401
|
+
dataChanged(event) {
|
|
24402
|
+
this._apiData = cloneDeep(this.apiData);
|
|
24403
|
+
}
|
|
24404
|
+
get saveDisabled() {
|
|
24405
|
+
const reservedConfigTypes = ['host.v1', 'host.v2', 'intercept.v1', 'ziti-tunneler-client.v1', 'ziti-tunneler-server.v1'];
|
|
24406
|
+
return reservedConfigTypes.includes(this.formData.name);
|
|
24407
|
+
}
|
|
24408
|
+
get saveButtonTooltip() {
|
|
24409
|
+
if (this.saveDisabled) {
|
|
24410
|
+
return 'Can not edit this system config type';
|
|
24411
|
+
}
|
|
24412
|
+
return '';
|
|
24413
|
+
}
|
|
24414
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ConfigTypeFormComponent, deps: [{ token: ConfigTypeFormService }, { token: SchemaService }, { token: GrowlerService }, { token: SHAREDZ_EXTENSION }, { token: SETTINGS_SERVICE }, { token: ZITI_DATA_SERVICE }, { token: i4.Router }, { token: i4.ActivatedRoute }, { token: i1$4.Location }, { token: ValidationService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
24415
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: ConfigTypeFormComponent, selector: "lib-configuration", inputs: { formData: "formData", errors: "errors" }, outputs: { close: "close" }, viewQueries: [{ propertyName: "configEditor", first: true, predicate: ["configEditor"], descendants: true, read: ConfigEditorComponent }], usesInheritance: true, ngImport: i0, template: "<div class=\"config-type-form-container projectable-form-wrapper\"\n (keyup.enter)=\"save($event)\"\n (keyup.escape)=\"closeModal(false)\"\n tabindex=\"0\"\n>\n <lib-form-header\n [data]=\"formData\"\n [title]=\"(formData.id ? 'Edit Config Type' : 'Create Config Type')\"\n [moreActions]=\"formData.moreActions\"\n (actionRequested)=\"headerActionRequested($event)\"\n [(formView)]=\"formView\"configJsonView\n [saveDisabled]=\"saveDisabled\"\n [saveTooltip]=\"saveButtonTooltip\"\n ></lib-form-header>\n <div class=\"config-form-container projectable-form-container\">\n <div class=\"projectable-form-main-column form-group-row\" [hidden]=\"formView !== 'simple'\">\n <div class=\"form-group-column three-fifths\">\n <lib-form-field-container [title]=\"'Config Name'\" [label]=\"'Required'\">\n <input\n id=\"ConfigName\"\n type=\"text\"\n maxlength=\"500\"\n placeholder=\"Name this config\"\n [ngClass]=\"{error: errors['name']}\"\n [(ngModel)]=\"formData.name\"\n >\n </lib-form-field-container>\n <lib-form-field-container [title]=\"'Schema'\" [label]=\"'Required'\" class=\"schema-json-editor\">\n <lib-json-view [(data)]=\"formData.schema\" [jsonInvalid]=\"errors['schema']\"></lib-json-view>\n </lib-form-field-container>\n <lib-form-field-toggle [(toggleOn)]=\"showMore\" (toggleOnChange)=\"showMoreChanged($event)\" style=\"margin: 0px 10px\"></lib-form-field-toggle>\n <div [hidden]=\"!showMore\" class=\"form-group-column\">\n <lib-form-field-container\n [title]=\"'Custom Tags'\"\n [label]=\"'OPTIONAL'\"\n class=\"form-field-advanced\"\n *ngIf=\"!hideTags\"\n >\n <lib-custom-tags [(tags)]=\"formData.tags\"></lib-custom-tags>\n </lib-form-field-container>\n </div>\n </div>\n <div class=\"form-group-column two-fifths\">\n <lib-form-field-container\n [title]=\"'API Calls'\"\n [label]=\"''\"\n [headerActions]=\"apiOptions\"\n (actionRequested)=\"apiActionRequested($event)\"\n >\n <div class=\"form-row\">\n <input class=\"form-field-input\" [value]=\"apiCallURL\" readonly/>\n <div class=\"url-copy icon-copy copy\" (click)=\"copyToClipboard(apiCallURL)\"></div>\n </div>\n <lib-json-view *ngIf=\"formData\" [(data)]=\"apiData\" [readOnly]=\"true\" [showCopy]=\"true\"></lib-json-view>\n </lib-form-field-container>\n </div>\n </div>\n <div class=\"form-group-column\" *ngIf=\"formView === 'raw'\">\n <lib-json-view *ngIf=\"formData\" [(data)]=\"formData\"></lib-json-view>\n </div>\n </div>\n</div>\n<lib-loading-indicator *ngIf=\"isLoading\" [isLoading]=\"isLoading\"></lib-loading-indicator>\n", styles: [".config-type-form-container{display:flex;flex-direction:column;height:100%;width:100%;align-items:center;gap:var(--gapXL)}.config-type-select.disabled{opacity:.7;pointer-events:none}.form-group-column.three-fifths{width:calc(60% - .9375rem);min-width:34.375rem;max-width:43.75rem}.form-group-column.two-fifths{max-width:43.75rem}::ng-deep #jsoneditor{max-height:32rem;overflow:hidden}\n"], dependencies: [{ kind: "directive", type: i1$4.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i5.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: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i5.MaxLengthValidator, selector: "[maxlength][formControlName],[maxlength][formControl],[maxlength][ngModel]", inputs: ["maxlength"] }, { kind: "directive", type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: FormHeaderComponent, selector: "lib-form-header", inputs: ["data", "badges", "title", "moreActions", "formView", "saveDisabled", "saveTooltip", "actionButtonText", "moreActionsText", "showHeaderToggle", "showHeaderButton"], outputs: ["formViewChange", "actionRequested"] }, { kind: "component", type: FormFieldContainerComponent, selector: "lib-form-field-container", inputs: ["title", "title2", "titleIcon", "layout", "helpText", "helpText2", "label", "count", "action", "actionLabel", "class", "contentStyle", "showHeader", "showToggle", "headerActions", "headerToggle"], outputs: ["actionRequested", "headerToggleChange"] }, { kind: "component", type: LoadingIndicatorComponent, selector: "lib-loading-indicator", inputs: ["isLoading"] }, { kind: "component", type: FormFieldToggleComponent, selector: "lib-form-field-toggle", inputs: ["label", "orientation", "labelOn", "labelOff", "toggleOn"], outputs: ["toggleOnChange"] }, { kind: "component", type: JsonViewComponent, selector: "lib-json-view", inputs: ["data", "schema", "readOnly", "jsonInvalid", "showCopy"], outputs: ["dataChange", "jsonChange", "jsonInvalidChange"] }, { kind: "component", type: CustomTagsComponent, selector: "lib-custom-tags", inputs: ["tags"], outputs: ["tagsChange"] }] }); }
|
|
24416
|
+
}
|
|
24417
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ConfigTypeFormComponent, decorators: [{
|
|
24418
|
+
type: Component,
|
|
24419
|
+
args: [{ selector: 'lib-configuration', template: "<div class=\"config-type-form-container projectable-form-wrapper\"\n (keyup.enter)=\"save($event)\"\n (keyup.escape)=\"closeModal(false)\"\n tabindex=\"0\"\n>\n <lib-form-header\n [data]=\"formData\"\n [title]=\"(formData.id ? 'Edit Config Type' : 'Create Config Type')\"\n [moreActions]=\"formData.moreActions\"\n (actionRequested)=\"headerActionRequested($event)\"\n [(formView)]=\"formView\"configJsonView\n [saveDisabled]=\"saveDisabled\"\n [saveTooltip]=\"saveButtonTooltip\"\n ></lib-form-header>\n <div class=\"config-form-container projectable-form-container\">\n <div class=\"projectable-form-main-column form-group-row\" [hidden]=\"formView !== 'simple'\">\n <div class=\"form-group-column three-fifths\">\n <lib-form-field-container [title]=\"'Config Name'\" [label]=\"'Required'\">\n <input\n id=\"ConfigName\"\n type=\"text\"\n maxlength=\"500\"\n placeholder=\"Name this config\"\n [ngClass]=\"{error: errors['name']}\"\n [(ngModel)]=\"formData.name\"\n >\n </lib-form-field-container>\n <lib-form-field-container [title]=\"'Schema'\" [label]=\"'Required'\" class=\"schema-json-editor\">\n <lib-json-view [(data)]=\"formData.schema\" [jsonInvalid]=\"errors['schema']\"></lib-json-view>\n </lib-form-field-container>\n <lib-form-field-toggle [(toggleOn)]=\"showMore\" (toggleOnChange)=\"showMoreChanged($event)\" style=\"margin: 0px 10px\"></lib-form-field-toggle>\n <div [hidden]=\"!showMore\" class=\"form-group-column\">\n <lib-form-field-container\n [title]=\"'Custom Tags'\"\n [label]=\"'OPTIONAL'\"\n class=\"form-field-advanced\"\n *ngIf=\"!hideTags\"\n >\n <lib-custom-tags [(tags)]=\"formData.tags\"></lib-custom-tags>\n </lib-form-field-container>\n </div>\n </div>\n <div class=\"form-group-column two-fifths\">\n <lib-form-field-container\n [title]=\"'API Calls'\"\n [label]=\"''\"\n [headerActions]=\"apiOptions\"\n (actionRequested)=\"apiActionRequested($event)\"\n >\n <div class=\"form-row\">\n <input class=\"form-field-input\" [value]=\"apiCallURL\" readonly/>\n <div class=\"url-copy icon-copy copy\" (click)=\"copyToClipboard(apiCallURL)\"></div>\n </div>\n <lib-json-view *ngIf=\"formData\" [(data)]=\"apiData\" [readOnly]=\"true\" [showCopy]=\"true\"></lib-json-view>\n </lib-form-field-container>\n </div>\n </div>\n <div class=\"form-group-column\" *ngIf=\"formView === 'raw'\">\n <lib-json-view *ngIf=\"formData\" [(data)]=\"formData\"></lib-json-view>\n </div>\n </div>\n</div>\n<lib-loading-indicator *ngIf=\"isLoading\" [isLoading]=\"isLoading\"></lib-loading-indicator>\n", styles: [".config-type-form-container{display:flex;flex-direction:column;height:100%;width:100%;align-items:center;gap:var(--gapXL)}.config-type-select.disabled{opacity:.7;pointer-events:none}.form-group-column.three-fifths{width:calc(60% - .9375rem);min-width:34.375rem;max-width:43.75rem}.form-group-column.two-fifths{max-width:43.75rem}::ng-deep #jsoneditor{max-height:32rem;overflow:hidden}\n"] }]
|
|
24420
|
+
}], ctorParameters: function () { return [{ type: ConfigTypeFormService }, { type: SchemaService }, { type: GrowlerService }, { type: undefined, decorators: [{
|
|
24421
|
+
type: Inject,
|
|
24422
|
+
args: [SHAREDZ_EXTENSION]
|
|
24423
|
+
}] }, { type: SettingsService, decorators: [{
|
|
24424
|
+
type: Inject,
|
|
24425
|
+
args: [SETTINGS_SERVICE]
|
|
24426
|
+
}] }, { type: ZitiDataService, decorators: [{
|
|
24427
|
+
type: Inject,
|
|
24428
|
+
args: [ZITI_DATA_SERVICE]
|
|
24429
|
+
}] }, { type: i4.Router }, { type: i4.ActivatedRoute }, { type: i1$4.Location }, { type: ValidationService }]; }, propDecorators: { formData: [{
|
|
24430
|
+
type: Input
|
|
24431
|
+
}], errors: [{
|
|
24432
|
+
type: Input
|
|
24433
|
+
}], close: [{
|
|
24434
|
+
type: Output
|
|
24435
|
+
}], configEditor: [{
|
|
24436
|
+
type: ViewChild,
|
|
24437
|
+
args: ["configEditor", { read: ConfigEditorComponent }]
|
|
24438
|
+
}] } });
|
|
24439
|
+
|
|
23866
24440
|
/*
|
|
23867
24441
|
Copyright NetFoundry Inc.
|
|
23868
24442
|
|
|
@@ -23900,6 +24474,8 @@ class OpenZitiConsoleLibModule {
|
|
|
23900
24474
|
PasswordInputComponent,
|
|
23901
24475
|
TerminatorFormComponent,
|
|
23902
24476
|
ConfigurationsPageComponent,
|
|
24477
|
+
ConfigTypesPageComponent,
|
|
24478
|
+
ConfigTypeFormComponent,
|
|
23903
24479
|
ListPageHeaderComponent,
|
|
23904
24480
|
FilterBarComponent,
|
|
23905
24481
|
ListPageFormComponent,
|
|
@@ -23995,6 +24571,8 @@ class OpenZitiConsoleLibModule {
|
|
|
23995
24571
|
ProtocolAddressPortInputComponent,
|
|
23996
24572
|
ConfigurationsPageComponent,
|
|
23997
24573
|
ConfigurationFormComponent,
|
|
24574
|
+
ConfigTypesPageComponent,
|
|
24575
|
+
ConfigTypeFormComponent,
|
|
23998
24576
|
EdgeRouterFormComponent,
|
|
23999
24577
|
IdentitiesPageComponent,
|
|
24000
24578
|
EdgeRoutersPageComponent,
|
|
@@ -24065,6 +24643,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImpo
|
|
|
24065
24643
|
PasswordInputComponent,
|
|
24066
24644
|
TerminatorFormComponent,
|
|
24067
24645
|
ConfigurationsPageComponent,
|
|
24646
|
+
ConfigTypesPageComponent,
|
|
24647
|
+
ConfigTypeFormComponent,
|
|
24068
24648
|
ListPageHeaderComponent,
|
|
24069
24649
|
FilterBarComponent,
|
|
24070
24650
|
ListPageFormComponent,
|
|
@@ -24168,6 +24748,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImpo
|
|
|
24168
24748
|
ProtocolAddressPortInputComponent,
|
|
24169
24749
|
ConfigurationsPageComponent,
|
|
24170
24750
|
ConfigurationFormComponent,
|
|
24751
|
+
ConfigTypesPageComponent,
|
|
24752
|
+
ConfigTypeFormComponent,
|
|
24171
24753
|
EdgeRouterFormComponent,
|
|
24172
24754
|
IdentitiesPageComponent,
|
|
24173
24755
|
EdgeRoutersPageComponent,
|
|
@@ -24205,7 +24787,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImpo
|
|
|
24205
24787
|
}] });
|
|
24206
24788
|
|
|
24207
24789
|
const VERSION = {
|
|
24208
|
-
"version": "3.
|
|
24790
|
+
"version": "3.9.0"
|
|
24209
24791
|
};
|
|
24210
24792
|
|
|
24211
24793
|
/*
|
|
@@ -25849,5 +26431,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImpo
|
|
|
25849
26431
|
* Generated bundle index. Do not edit.
|
|
25850
26432
|
*/
|
|
25851
26433
|
|
|
25852
|
-
export { AuthPoliciesPageComponent, AuthPoliciesPageService, AuthPolicyFormComponent, AuthPolicyFormService, BooleanToggleInputComponent, COMPONENTS, CardListComponent, CertificateAuthoritiesPageComponent, CertificateAuthoritiesPageService, CertificateAuthorityFormComponent, CertificateAuthorityFormService, CheckboxListInputComponent, ConfigurationFormComponent, ConfigurationService, ConfigurationsPageComponent, CsvDownloadService, DEACTIVATE_GUARD, DataTableFilterService, DeactivateGuardService, EDGE_ROUTER_EXTENSION_SERVICE, EDGE_ROUTER_POLICY_EXTENSION_SERVICE, EdgeRouter, EdgeRouterFormComponent, EdgeRouterFormService, EdgeRouterPoliciesPageComponent, EdgeRouterPoliciesPageService, EdgeRouterPolicyFormComponent, EdgeRouterPolicyFormService, EdgeRoutersPageComponent, EdgeRoutersPageService, Entity, ExtendableComponent, ExtensionsNoopService, FormFieldContainerComponent, FormFieldToggleComponent, FormHeaderComponent, GrowlerComponent, GrowlerModel, GrowlerModule, GrowlerService, IDENTITY_EXTENSION_SERVICE, IdentitiesPageComponent, IdentitiesPageService, Identity$1 as Identity, IdentityFormComponent, IdentityFormService, IdentityServicePathComponent, JwtSignerFormComponent, JwtSignerFormService, JwtSignersPageComponent, JwtSignersPageService, KEY_CODES, ListPageComponent, ListPageServiceClass, LoadingIndicatorComponent, LoggerService, LoginDialogComponent, LoginServiceClass, NetworkVisualizerComponent, NodeDataService, NodeWrapperService, NoopLoginService, NoopTabInterceptorService, NumberInputComponent, ObjectComponent, OpenZitiConsoleLibModule, PasswordInputComponent, ProjectableForm, ProtocolAddressPortInputComponent, ResetEnrollmentService, SERVICE_EDGE_ROUTER_POLICY_EXTENSION_SERVICE, SERVICE_EXTENSION_SERVICE, SERVICE_POLICY_EXTENSION_SERVICE, SETTINGS_SERVICE, SHAREDZ_EXTENSION, SelectorInputComponent, ServiceEdgeRouterPoliciesPageComponent, ServiceEdgeRouterPoliciesPageService, ServiceEdgeRouterPolicyFormComponent, ServiceEdgeRouterPolicyFormService, ServiceFormComponent, ServiceFormService, ServicePoliciesPageComponent, ServicePoliciesPageService, ServicePolicyFormComponent, ServicePolicyFormService, ServicesPageComponent, ServicesPageService, SettingsService, SettingsServiceClass, SideBannerComponent, SideModalComponent, SideNavbarComponent, SideToolbarComponent, SimpleServiceComponent, StringInputComponent, TabNameService, TerminatorFormComponent, TerminatorFormService, TerminatorsPageComponent, TerminatorsPageService, TextListInputComponent, VERSION, VerifyCertificateComponent, VisualizerServiceClass, ZAC_LOGIN_SERVICE, ZAC_WRAPPER_SERVICE, ZITI_DATA_SERVICE, ZITI_DOMAIN_CONTROLLER, ZITI_NAVIGATOR, ZITI_TAB_OVERRIDES, ZITI_URLS, ZacRoutingModule, ZacWrapperComponent, ZacWrapperService, ZacWrapperServiceClass, ZitiControllerDataService, ZitiDataService, playerFactory };
|
|
26434
|
+
export { AuthPoliciesPageComponent, AuthPoliciesPageService, AuthPolicyFormComponent, AuthPolicyFormService, BooleanToggleInputComponent, COMPONENTS, CardListComponent, CertificateAuthoritiesPageComponent, CertificateAuthoritiesPageService, CertificateAuthorityFormComponent, CertificateAuthorityFormService, CheckboxListInputComponent, ConfigTypeFormComponent, ConfigTypesPageComponent, ConfigurationFormComponent, ConfigurationService, ConfigurationsPageComponent, CsvDownloadService, DEACTIVATE_GUARD, DataTableFilterService, DeactivateGuardService, EDGE_ROUTER_EXTENSION_SERVICE, EDGE_ROUTER_POLICY_EXTENSION_SERVICE, EdgeRouter, EdgeRouterFormComponent, EdgeRouterFormService, EdgeRouterPoliciesPageComponent, EdgeRouterPoliciesPageService, EdgeRouterPolicyFormComponent, EdgeRouterPolicyFormService, EdgeRoutersPageComponent, EdgeRoutersPageService, Entity, ExtendableComponent, ExtensionsNoopService, FormFieldContainerComponent, FormFieldToggleComponent, FormHeaderComponent, GrowlerComponent, GrowlerModel, GrowlerModule, GrowlerService, IDENTITY_EXTENSION_SERVICE, IdentitiesPageComponent, IdentitiesPageService, Identity$1 as Identity, IdentityFormComponent, IdentityFormService, IdentityServicePathComponent, JwtSignerFormComponent, JwtSignerFormService, JwtSignersPageComponent, JwtSignersPageService, KEY_CODES, ListPageComponent, ListPageServiceClass, LoadingIndicatorComponent, LoggerService, LoginDialogComponent, LoginServiceClass, NetworkVisualizerComponent, NodeDataService, NodeWrapperService, NoopLoginService, NoopTabInterceptorService, NumberInputComponent, ObjectComponent, OpenZitiConsoleLibModule, PasswordInputComponent, ProjectableForm, ProtocolAddressPortInputComponent, ResetEnrollmentService, SERVICE_EDGE_ROUTER_POLICY_EXTENSION_SERVICE, SERVICE_EXTENSION_SERVICE, SERVICE_POLICY_EXTENSION_SERVICE, SETTINGS_SERVICE, SHAREDZ_EXTENSION, SelectorInputComponent, ServiceEdgeRouterPoliciesPageComponent, ServiceEdgeRouterPoliciesPageService, ServiceEdgeRouterPolicyFormComponent, ServiceEdgeRouterPolicyFormService, ServiceFormComponent, ServiceFormService, ServicePoliciesPageComponent, ServicePoliciesPageService, ServicePolicyFormComponent, ServicePolicyFormService, ServicesPageComponent, ServicesPageService, SettingsService, SettingsServiceClass, SideBannerComponent, SideModalComponent, SideNavbarComponent, SideToolbarComponent, SimpleServiceComponent, StringInputComponent, TabNameService, TerminatorFormComponent, TerminatorFormService, TerminatorsPageComponent, TerminatorsPageService, TextListInputComponent, VERSION, VerifyCertificateComponent, VisualizerServiceClass, ZAC_LOGIN_SERVICE, ZAC_WRAPPER_SERVICE, ZITI_DATA_SERVICE, ZITI_DOMAIN_CONTROLLER, ZITI_NAVIGATOR, ZITI_TAB_OVERRIDES, ZITI_URLS, ZacRoutingModule, ZacWrapperComponent, ZacWrapperService, ZacWrapperServiceClass, ZitiControllerDataService, ZitiDataService, playerFactory };
|
|
25853
26435
|
//# sourceMappingURL=openziti-ziti-console-lib.mjs.map
|