ngx-t-forms 3.1.0 → 3.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/fesm2022/ngx-t-forms-api-endpoint-config.component-CZm3Z_7B.mjs +411 -0
- package/fesm2022/ngx-t-forms-api-endpoint-config.component-CZm3Z_7B.mjs.map +1 -0
- package/fesm2022/{ngx-t-forms-auto-complete-input-element.component-FhUHTsUF.mjs → ngx-t-forms-auto-complete-input-element.component-IciY6hb3.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-auto-complete-input-element.component-FhUHTsUF.mjs.map → ngx-t-forms-auto-complete-input-element.component-IciY6hb3.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-basic-input-input-element.component-BJKe9wIA.mjs → ngx-t-forms-basic-input-input-element.component-CykKxWu0.mjs} +3 -3
- package/fesm2022/{ngx-t-forms-basic-input-input-element.component-BJKe9wIA.mjs.map → ngx-t-forms-basic-input-input-element.component-CykKxWu0.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-calculated-field-rules.component-FQLTI7CX.mjs → ngx-t-forms-calculated-field-rules.component-CwI-WEX7.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-calculated-field-rules.component-FQLTI7CX.mjs.map → ngx-t-forms-calculated-field-rules.component-CwI-WEX7.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-chip-options-creator-editor.component-CJtbprXS.mjs → ngx-t-forms-chip-options-creator-editor.component-CO_3EQ_v.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-chip-options-creator-editor.component-CJtbprXS.mjs.map → ngx-t-forms-chip-options-creator-editor.component-CO_3EQ_v.mjs.map} +1 -1
- package/fesm2022/ngx-t-forms-conditional-display-config.component-Cmf7gDfO.mjs +513 -0
- package/fesm2022/ngx-t-forms-conditional-display-config.component-Cmf7gDfO.mjs.map +1 -0
- package/fesm2022/{ngx-t-forms-config-mscoa-additional-inputs.component-CU6R5h-x.mjs → ngx-t-forms-config-mscoa-additional-inputs.component-BHiOEQe4.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-config-mscoa-additional-inputs.component-CU6R5h-x.mjs.map → ngx-t-forms-config-mscoa-additional-inputs.component-BHiOEQe4.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-data-source-picker.component-C8MBbnfz.mjs → ngx-t-forms-data-source-picker.component-CN51SdCK.mjs} +6 -6
- package/fesm2022/{ngx-t-forms-data-source-picker.component-C8MBbnfz.mjs.map → ngx-t-forms-data-source-picker.component-CN51SdCK.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-date-picker-input-element.component-Dux6uy66.mjs → ngx-t-forms-date-picker-input-element.component-c3OSDXWw.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-date-picker-input-element.component-Dux6uy66.mjs.map → ngx-t-forms-date-picker-input-element.component-c3OSDXWw.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-date-range-picker-input-element.component-SMWrTm5X.mjs → ngx-t-forms-date-range-picker-input-element.component-C-4fqOF0.mjs} +11 -2
- package/fesm2022/ngx-t-forms-date-range-picker-input-element.component-C-4fqOF0.mjs.map +1 -0
- package/fesm2022/{ngx-t-forms-document-list-label-config-editor.component-uGM93dvc.mjs → ngx-t-forms-document-list-label-config-editor.component-DLzba2AQ.mjs} +3 -3
- package/fesm2022/{ngx-t-forms-document-list-label-config-editor.component-uGM93dvc.mjs.map → ngx-t-forms-document-list-label-config-editor.component-DLzba2AQ.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-document-picker.component-DIqaaBSl.mjs → ngx-t-forms-document-picker.component-9clYsOcl.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-document-picker.component-DIqaaBSl.mjs.map → ngx-t-forms-document-picker.component-9clYsOcl.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-editor-input-element.component-CIELjDty.mjs → ngx-t-forms-editor-input-element.component-BGdZ4evj.mjs} +3 -3
- package/fesm2022/{ngx-t-forms-editor-input-element.component-CIELjDty.mjs.map → ngx-t-forms-editor-input-element.component-BGdZ4evj.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-editor-js-input.component-C1dI_7rU.mjs → ngx-t-forms-editor-js-input.component-02HnmInT.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-editor-js-input.component-C1dI_7rU.mjs.map → ngx-t-forms-editor-js-input.component-02HnmInT.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-file-upload-input-element.component-CQsKz87N.mjs → ngx-t-forms-file-upload-input-element.component-BF7KbSPb.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-file-upload-input-element.component-CQsKz87N.mjs.map → ngx-t-forms-file-upload-input-element.component-BF7KbSPb.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-form-input-selector.component-Dj0jvBdm.mjs → ngx-t-forms-form-input-selector.component-vCj2SCxs.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-form-input-selector.component-Dj0jvBdm.mjs.map → ngx-t-forms-form-input-selector.component-vCj2SCxs.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-form-json-view.component-DzJKFl4c.mjs → ngx-t-forms-form-json-view.component-Cmw1hHGZ.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-form-json-view.component-DzJKFl4c.mjs.map → ngx-t-forms-form-json-view.component-Cmw1hHGZ.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-form-section-stepper.component-DOvVtJGB.mjs → ngx-t-forms-form-section-stepper.component-CFdwgxRl.mjs} +4 -4
- package/fesm2022/{ngx-t-forms-form-section-stepper.component-DOvVtJGB.mjs.map → ngx-t-forms-form-section-stepper.component-CFdwgxRl.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-forms-builder-menu.component-CcqyQLf5.mjs → ngx-t-forms-forms-builder-menu.component-DisrOv5x.mjs} +4 -4
- package/fesm2022/{ngx-t-forms-forms-builder-menu.component-CcqyQLf5.mjs.map → ngx-t-forms-forms-builder-menu.component-DisrOv5x.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-geo-location.component-Bj_qIEqi.mjs → ngx-t-forms-geo-location.component-D-BhLdx6.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-geo-location.component-Bj_qIEqi.mjs.map → ngx-t-forms-geo-location.component-D-BhLdx6.mjs.map} +1 -1
- package/fesm2022/ngx-t-forms-header-template-editor.component-Z5frEhho.mjs +159 -0
- package/fesm2022/ngx-t-forms-header-template-editor.component-Z5frEhho.mjs.map +1 -0
- package/fesm2022/{ngx-t-forms-image-capture-input-element.component-lwp3IcDt.mjs → ngx-t-forms-image-capture-input-element.component-CoJTXMbL.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-image-capture-input-element.component-lwp3IcDt.mjs.map → ngx-t-forms-image-capture-input-element.component-CoJTXMbL.mjs.map} +1 -1
- package/fesm2022/ngx-t-forms-index-D8xr_Sxp.mjs +2 -0
- package/fesm2022/ngx-t-forms-index-D8xr_Sxp.mjs.map +1 -0
- package/fesm2022/{ngx-t-forms-input-custom.component-DiciFhSS.mjs → ngx-t-forms-input-custom.component-s1ryJQy4.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-input-custom.component-DiciFhSS.mjs.map → ngx-t-forms-input-custom.component-s1ryJQy4.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-input-editor.component-D12hrHOc.mjs → ngx-t-forms-input-editor.component-oIzCTmbx.mjs} +3 -3
- package/fesm2022/{ngx-t-forms-input-editor.component-D12hrHOc.mjs.map → ngx-t-forms-input-editor.component-oIzCTmbx.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-map-mat-options-keys-C2JpMTEc.mjs → ngx-t-forms-map-mat-options-keys-C1kxlZS_.mjs} +2 -3
- package/fesm2022/ngx-t-forms-map-mat-options-keys-C1kxlZS_.mjs.map +1 -0
- package/fesm2022/{ngx-t-forms-mat-chip-list-editor.component-C1Qrze7K.mjs → ngx-t-forms-mat-chip-list-editor.component-wskkKr4y.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-mat-chip-list-editor.component-C1Qrze7K.mjs.map → ngx-t-forms-mat-chip-list-editor.component-wskkKr4y.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-missing-form-configs.component-BaTR_jzc.mjs → ngx-t-forms-missing-form-configs.component-C1XuXRdn.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-missing-form-configs.component-BaTR_jzc.mjs.map → ngx-t-forms-missing-form-configs.component-C1XuXRdn.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-mscoa-chart-toolbar.component-Dni_bv_G.mjs → ngx-t-forms-mscoa-chart-toolbar.component-BJrOTRuQ.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-mscoa-chart-toolbar.component-Dni_bv_G.mjs.map → ngx-t-forms-mscoa-chart-toolbar.component-BJrOTRuQ.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-mscoa-segment-config.component-BPQuzR5k.mjs → ngx-t-forms-mscoa-segment-config.component-GyKF31Ve.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-mscoa-segment-config.component-BPQuzR5k.mjs.map → ngx-t-forms-mscoa-segment-config.component-GyKF31Ve.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-multiple-input-input-element.component-hXWMRFjl.mjs → ngx-t-forms-multiple-input-input-element.component-BrPJPR2R.mjs} +4 -4
- package/fesm2022/{ngx-t-forms-multiple-input-input-element.component-hXWMRFjl.mjs.map → ngx-t-forms-multiple-input-input-element.component-BrPJPR2R.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-ngx-t-forms-tQEbZK_e.mjs → ngx-t-forms-ngx-t-forms-DqAcUfN4.mjs} +1807 -717
- package/fesm2022/ngx-t-forms-ngx-t-forms-DqAcUfN4.mjs.map +1 -0
- package/fesm2022/{ngx-t-forms-paginated-selection-table-pYY2sWAb.mjs → ngx-t-forms-paginated-selection-table-Bk77dBo9.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-paginated-selection-table-pYY2sWAb.mjs.map → ngx-t-forms-paginated-selection-table-Bk77dBo9.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-payload-template-editor.component-DGCUsTYx.mjs → ngx-t-forms-payload-template-editor.component-CVzOTLYE.mjs} +11 -5
- package/fesm2022/ngx-t-forms-payload-template-editor.component-CVzOTLYE.mjs.map +1 -0
- package/fesm2022/{ngx-t-forms-pipeline-generator.component-D2stBXXC.mjs → ngx-t-forms-pipeline-generator.component-7Vfwaqnx.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-pipeline-generator.component-D2stBXXC.mjs.map → ngx-t-forms-pipeline-generator.component-7Vfwaqnx.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-record-list-manager.component-CtCOIpai.mjs → ngx-t-forms-record-list-manager.component-CfZdqKhY.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-record-list-manager.component-CtCOIpai.mjs.map → ngx-t-forms-record-list-manager.component-CfZdqKhY.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-required-inputs.component-D9wIdOhg.mjs → ngx-t-forms-required-inputs.component-CK7NIhbq.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-required-inputs.component-D9wIdOhg.mjs.map → ngx-t-forms-required-inputs.component-CK7NIhbq.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-rest-api-call-setup.component-Gy7Rtmue.mjs → ngx-t-forms-rest-api-call-setup.component-YChv7Arm.mjs} +249 -25
- package/fesm2022/ngx-t-forms-rest-api-call-setup.component-YChv7Arm.mjs.map +1 -0
- package/fesm2022/{ngx-t-forms-section-report.component-U9uQ_Ow9.mjs → ngx-t-forms-section-report.component-DhSaf85h.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-section-report.component-U9uQ_Ow9.mjs.map → ngx-t-forms-section-report.component-DhSaf85h.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-select-input-element.component-CxYTmuvV.mjs → ngx-t-forms-select-input-element.component-D5HFzh35.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-select-input-element.component-CxYTmuvV.mjs.map → ngx-t-forms-select-input-element.component-D5HFzh35.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-selection-options-editor.component-BLLejOLG.mjs → ngx-t-forms-selection-options-editor.component-BhmmJOco.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-selection-options-editor.component-BLLejOLG.mjs.map → ngx-t-forms-selection-options-editor.component-BhmmJOco.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-textarea-input-element.component-75VdPc6z.mjs → ngx-t-forms-textarea-input-element.component-DWEADTsz.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-textarea-input-element.component-75VdPc6z.mjs.map → ngx-t-forms-textarea-input-element.component-DWEADTsz.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-toggle-input-element.component-DQGvEJN-.mjs → ngx-t-forms-toggle-input-element.component-XZi6kPnL.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-toggle-input-element.component-DQGvEJN-.mjs.map → ngx-t-forms-toggle-input-element.component-XZi6kPnL.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-validators-config.component-EM7RSWIz.mjs → ngx-t-forms-validators-config.component-0_Y6bvtE.mjs} +2 -2
- package/fesm2022/{ngx-t-forms-validators-config.component-EM7RSWIz.mjs.map → ngx-t-forms-validators-config.component-0_Y6bvtE.mjs.map} +1 -1
- package/fesm2022/{ngx-t-forms-workflow-adjudication.component-C1Em-g9e.mjs → ngx-t-forms-workflow-adjudication.component-Gkimmw-X.mjs} +3 -3
- package/fesm2022/{ngx-t-forms-workflow-adjudication.component-C1Em-g9e.mjs.map → ngx-t-forms-workflow-adjudication.component-Gkimmw-X.mjs.map} +1 -1
- package/fesm2022/ngx-t-forms.mjs +1 -1
- package/package.json +2 -2
- package/types/ngx-t-forms.d.ts +103 -4
- package/fesm2022/ngx-t-forms-date-range-picker-input-element.component-SMWrTm5X.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-header-template-editor.component-DLldVmcN.mjs +0 -129
- package/fesm2022/ngx-t-forms-header-template-editor.component-DLldVmcN.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-index-C8NtLE16.mjs +0 -2
- package/fesm2022/ngx-t-forms-index-C8NtLE16.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-map-mat-options-keys-C2JpMTEc.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-ngx-t-forms-tQEbZK_e.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-payload-template-editor.component-DGCUsTYx.mjs.map +0 -1
- package/fesm2022/ngx-t-forms-rest-api-call-setup.component-Gy7Rtmue.mjs.map +0 -1
|
@@ -0,0 +1,411 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { inject, DestroyRef, computed, linkedSignal, signal, ViewEncapsulation, ChangeDetectionStrategy, Component, input, output } from '@angular/core';
|
|
3
|
+
import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
|
4
|
+
import * as i2 from '@angular/material/button';
|
|
5
|
+
import { MatButtonModule } from '@angular/material/button';
|
|
6
|
+
import * as i1 from '@angular/material/dialog';
|
|
7
|
+
import { MAT_DIALOG_DATA, MatDialogModule, MatDialog } from '@angular/material/dialog';
|
|
8
|
+
import * as i3 from '@angular/material/icon';
|
|
9
|
+
import { MatIconModule } from '@angular/material/icon';
|
|
10
|
+
import * as i5$1 from '@angular/material/tooltip';
|
|
11
|
+
import { MatTooltipModule } from '@angular/material/tooltip';
|
|
12
|
+
import { N as NGX_T_FORMS_CONFIG_TOKEN, A as ApiValueAccessRulesComponent, E as EmptyStateComponent, l as ErrorListComponent } from './ngx-t-forms-ngx-t-forms-DqAcUfN4.mjs';
|
|
13
|
+
import * as i4 from '@angular/material/progress-spinner';
|
|
14
|
+
import { MatProgressSpinnerModule } from '@angular/material/progress-spinner';
|
|
15
|
+
import * as i5 from '@angular/material/tabs';
|
|
16
|
+
import { MatTabsModule } from '@angular/material/tabs';
|
|
17
|
+
import { take } from 'rxjs';
|
|
18
|
+
import { HeaderTemplateEditorComponent } from './ngx-t-forms-header-template-editor.component-Z5frEhho.mjs';
|
|
19
|
+
import { PayloadTemplateEditorComponent } from './ngx-t-forms-payload-template-editor.component-CVzOTLYE.mjs';
|
|
20
|
+
import { RequiredInputsComponent } from './ngx-t-forms-required-inputs.component-CK7NIhbq.mjs';
|
|
21
|
+
import { m as methodColorOf, s as sendsBody, b as bodyModeOf, p as paramCountOf, h as headerCountOf, a as payloadDefaultOf, c as minInputsOf, r as readinessOf, w as waitsForLabels, d as deriveConfiguredRequest, e as dependencyLabels, R as RestApiCallSetupComponent } from './ngx-t-forms-rest-api-call-setup.component-YChv7Arm.mjs';
|
|
22
|
+
|
|
23
|
+
/**
|
|
24
|
+
* Full-screen editor for one `matOptions.fetch.<slot>` API configuration,
|
|
25
|
+
* arranged the way request tools like Postman arrange theirs so the mental
|
|
26
|
+
* model transfers: a method + URL bar on top, then Params · Headers · Body ·
|
|
27
|
+
* Response tabs, with a readiness rail in the footer.
|
|
28
|
+
*
|
|
29
|
+
* Opened by {@link ApiEndpointConfigComponent}, which passes an
|
|
30
|
+
* {@link ApiEndpointDialogContext} and remains the single owner of every
|
|
31
|
+
* mutation — this dialog only renders state and forwards edits. First-time
|
|
32
|
+
* users land on a three-step guide and the Endpoint tab; picking an endpoint
|
|
33
|
+
* advances to the next step that needs them — Body for a body-bearing method,
|
|
34
|
+
* otherwise straight to the response mapping.
|
|
35
|
+
*
|
|
36
|
+
* Internal editor; not part of the public API.
|
|
37
|
+
*/
|
|
38
|
+
class ApiEndpointConfigDialogComponent {
|
|
39
|
+
constructor() {
|
|
40
|
+
/** The opener-supplied context; see {@link ApiEndpointDialogContext}. */
|
|
41
|
+
this.data = inject(MAT_DIALOG_DATA);
|
|
42
|
+
this.#formsConfig = inject(NGX_T_FORMS_CONFIG_TOKEN);
|
|
43
|
+
this.#destroyRef = inject(DestroyRef);
|
|
44
|
+
/** The live configuration, read through the opener's signal. */
|
|
45
|
+
this.config = computed(() => this.data.config(), ...(ngDevMode ? [{ debugName: "config" }] : /* istanbul ignore next */ []));
|
|
46
|
+
/** True once the slot carries a usable endpoint. */
|
|
47
|
+
this.hasEndpoint = computed(() => Boolean(this.config()?.httpEndPoint), ...(ngDevMode ? [{ debugName: "hasEndpoint" }] : /* istanbul ignore next */ []));
|
|
48
|
+
/** Token colour for the request bar's method badge. */
|
|
49
|
+
this.methodColor = computed(() => methodColorOf(this.config()), ...(ngDevMode ? [{ debugName: "methodColor" }] : /* istanbul ignore next */ []));
|
|
50
|
+
/** POST/PUT carry a body; the Body tab is disabled otherwise. */
|
|
51
|
+
this.sendsBody = computed(() => sendsBody(this.config()), ...(ngDevMode ? [{ debugName: "sendsBody" }] : /* istanbul ignore next */ []));
|
|
52
|
+
/** Active body mechanism — unset means mapped inputs (runtime parity). */
|
|
53
|
+
this.bodyMode = computed(() => bodyModeOf(this.config()), ...(ngDevMode ? [{ debugName: "bodyMode" }] : /* istanbul ignore next */ []));
|
|
54
|
+
/** Query parameter count for the Params tab badge. */
|
|
55
|
+
this.paramCount = computed(() => paramCountOf(this.config()), ...(ngDevMode ? [{ debugName: "paramCount" }] : /* istanbul ignore next */ []));
|
|
56
|
+
/** Header count for the Headers tab badge. */
|
|
57
|
+
this.headerCount = computed(() => headerCountOf(this.config()), ...(ngDevMode ? [{ debugName: "headerCount" }] : /* istanbul ignore next */ []));
|
|
58
|
+
/** Editor default for the query panel: the endpoint's captured params. */
|
|
59
|
+
this.queryDefault = computed(() => nonEmpty(this.config()?.capturedQuery), ...(ngDevMode ? [{ debugName: "queryDefault" }] : /* istanbul ignore next */ []));
|
|
60
|
+
/** Editor default for the header panel: the endpoint's captured headers. */
|
|
61
|
+
this.headerDefault = computed(() => nonEmpty(this.config()?.capturedHeaders), ...(ngDevMode ? [{ debugName: "headerDefault" }] : /* istanbul ignore next */ []));
|
|
62
|
+
/** Editor default for template mode, derived from the captured body/mapping. */
|
|
63
|
+
this.payloadDefault = computed(() => payloadDefaultOf(this.config()), ...(ngDevMode ? [{ debugName: "payloadDefault" }] : /* istanbul ignore next */ []));
|
|
64
|
+
/** The configured minimum-input mapping. */
|
|
65
|
+
this.minInputs = computed(() => minInputsOf(this.config()), ...(ngDevMode ? [{ debugName: "minInputs" }] : /* istanbul ignore next */ []));
|
|
66
|
+
/** The readiness rail shown in the footer. */
|
|
67
|
+
this.readiness = computed(() => readinessOf(this.config(), this.data.kind), ...(ngDevMode ? [{ debugName: "readiness" }] : /* istanbul ignore next */ []));
|
|
68
|
+
/** Friendly labels of the live fields the fetch waits for at fill time. */
|
|
69
|
+
this.waitsFor = computed(() => waitsForLabels(this.config(), this.data.formInputs()), ...(ngDevMode ? [{ debugName: "waitsFor" }] : /* istanbul ignore next */ []));
|
|
70
|
+
/** Copy for the header subtitle, per slot kind. */
|
|
71
|
+
this.kindLabel = computed(() => this.data.kind === 'options' ? 'Options data source' : 'Field value data source', ...(ngDevMode ? [{ debugName: "kindLabel" }] : /* istanbul ignore next */ []));
|
|
72
|
+
/** Label of the last tab — mapping copy differs per slot kind. */
|
|
73
|
+
this.responseLabel = computed(() => this.data.kind === 'options' ? 'Options mapping' : 'Response', ...(ngDevMode ? [{ debugName: "responseLabel" }] : /* istanbul ignore next */ []));
|
|
74
|
+
/**
|
|
75
|
+
* The endpoint's Postman documentation, verbatim (whitespace preserved).
|
|
76
|
+
* The Docs tab exists only when the request actually carries a description.
|
|
77
|
+
*/
|
|
78
|
+
this.docs = computed(() => {
|
|
79
|
+
const captured = this.config()?.capturedDocs;
|
|
80
|
+
return captured?.trim() ? captured : undefined;
|
|
81
|
+
}, ...(ngDevMode ? [{ debugName: "docs" }] : /* istanbul ignore next */ []));
|
|
82
|
+
/**
|
|
83
|
+
* Active tab index. A `linkedSignal` (per the library decision tree — follows
|
|
84
|
+
* a source, the user overrides locally): the user's tab choice sticks while
|
|
85
|
+
* an endpoint exists, and losing the endpoint (cleared while the dialog is
|
|
86
|
+
* open) snaps the selection back to the Endpoint tab — every other tab is
|
|
87
|
+
* disabled then, so nothing else is honest to show. No `effect()` writes.
|
|
88
|
+
*/
|
|
89
|
+
this.selectedTab = linkedSignal({ ...(ngDevMode ? { debugName: "selectedTab" } : /* istanbul ignore next */ {}), source: this.hasEndpoint,
|
|
90
|
+
computation: (has, previous) => has ? previous?.value ?? 0 /* ApiDialogTab.Endpoint */ : 0 /* ApiDialogTab.Endpoint */ });
|
|
91
|
+
/** Exposes the enum to the template. */
|
|
92
|
+
this.Tab = {
|
|
93
|
+
Endpoint: 0 /* ApiDialogTab.Endpoint */,
|
|
94
|
+
Params: 1 /* ApiDialogTab.Params */,
|
|
95
|
+
Headers: 2 /* ApiDialogTab.Headers */,
|
|
96
|
+
Body: 3 /* ApiDialogTab.Body */,
|
|
97
|
+
Response: 4 /* ApiDialogTab.Response */,
|
|
98
|
+
};
|
|
99
|
+
// ── Run API call — refresh the sample response from the CONFIGURED request ──
|
|
100
|
+
this.#running = signal(false, ...(ngDevMode ? [{ debugName: "#running" }] : /* istanbul ignore next */ []));
|
|
101
|
+
this.#liveResponse = signal(undefined, ...(ngDevMode ? [{ debugName: "#liveResponse" }] : /* istanbul ignore next */ []));
|
|
102
|
+
this.#lastRunTime = signal(undefined, ...(ngDevMode ? [{ debugName: "#lastRunTime" }] : /* istanbul ignore next */ []));
|
|
103
|
+
this.#runError = signal(undefined, ...(ngDevMode ? [{ debugName: "#runError" }] : /* istanbul ignore next */ []));
|
|
104
|
+
/** True while a test run is in flight. */
|
|
105
|
+
this.running = this.#running.asReadonly();
|
|
106
|
+
/** The last run's response — overrides the Postman sample in the Response tab. */
|
|
107
|
+
this.liveResponse = this.#liveResponse.asReadonly();
|
|
108
|
+
/** Wall-clock label of the last successful run (freshness note). */
|
|
109
|
+
this.lastRunTime = this.#lastRunTime.asReadonly();
|
|
110
|
+
/** Human-readable failure of the last run, if any. */
|
|
111
|
+
this.runError = this.#runError.asReadonly();
|
|
112
|
+
/** Labels of live-bound values a run sends empty (named, never silent). */
|
|
113
|
+
this.runUnresolved = computed(() => {
|
|
114
|
+
const request = deriveConfiguredRequest(this.config());
|
|
115
|
+
return request ? dependencyLabels(this.data.formInputs(), request.unresolved) : [];
|
|
116
|
+
}, ...(ngDevMode ? [{ debugName: "runUnresolved" }] : /* istanbul ignore next */ []));
|
|
117
|
+
/** Tooltip: what Run does, and exactly what it cannot know at build time. */
|
|
118
|
+
this.runTooltip = computed(() => {
|
|
119
|
+
const base = 'Sends this request exactly as configured — URL, params, headers and body — and refreshes the sample response.';
|
|
120
|
+
const unresolved = this.runUnresolved();
|
|
121
|
+
return unresolved.length > 0
|
|
122
|
+
? `${base} Values bound to live fields (${unresolved.join(', ')}) are sent empty.`
|
|
123
|
+
: base;
|
|
124
|
+
}, ...(ngDevMode ? [{ debugName: "runTooltip" }] : /* istanbul ignore next */ []));
|
|
125
|
+
}
|
|
126
|
+
#formsConfig;
|
|
127
|
+
#destroyRef;
|
|
128
|
+
/**
|
|
129
|
+
* Forwards an endpoint selection (or clear) to the opener and, on a fresh
|
|
130
|
+
* pick, advances to the next step that actually needs the author:
|
|
131
|
+
* - a body-bearing endpoint (POST/PUT) lands on **Body** — the one thing
|
|
132
|
+
* that must be configured before the fetch is meaningful;
|
|
133
|
+
* - anything else (GET) skips straight to the **Response / Options mapping**
|
|
134
|
+
* tab, since params/headers arrive pre-captured from Postman.
|
|
135
|
+
*/
|
|
136
|
+
onEndpointChanged(cfg) {
|
|
137
|
+
this.data.endpointChanged(cfg);
|
|
138
|
+
if (!cfg?.httpEndPoint)
|
|
139
|
+
return;
|
|
140
|
+
this.selectedTab.set(sendsBody(cfg) ? 3 /* ApiDialogTab.Body */ : 4 /* ApiDialogTab.Response */);
|
|
141
|
+
}
|
|
142
|
+
/** Body-mode chip handler — forwards to the opener, discards nothing. */
|
|
143
|
+
setBodyMode(mode) {
|
|
144
|
+
if (this.bodyMode() === mode)
|
|
145
|
+
return;
|
|
146
|
+
this.data.bodyModeChanged(mode);
|
|
147
|
+
}
|
|
148
|
+
// ── Run API call — refresh the sample response from the CONFIGURED request ──
|
|
149
|
+
#running;
|
|
150
|
+
#liveResponse;
|
|
151
|
+
#lastRunTime;
|
|
152
|
+
#runError;
|
|
153
|
+
/**
|
|
154
|
+
* Runs the CONFIGURED request now and replaces the sample response with the
|
|
155
|
+
* live result. This is the whole point of the old "Data Sync" mode, made
|
|
156
|
+
* honest: the saved Postman example can be stale or payload-dependent, and
|
|
157
|
+
* the request sent here is the one this dialog's tabs describe — no separate
|
|
158
|
+
* hand-authored payload. Values bound to live form fields cannot be known at
|
|
159
|
+
* build time; they are sent empty and named in the freshness note.
|
|
160
|
+
*/
|
|
161
|
+
runApiCall() {
|
|
162
|
+
if (this.#running())
|
|
163
|
+
return;
|
|
164
|
+
const request = deriveConfiguredRequest(this.config());
|
|
165
|
+
if (!request)
|
|
166
|
+
return;
|
|
167
|
+
const fb = this.#formsConfig.formBuilder;
|
|
168
|
+
const req$ = request.method === 'GET'
|
|
169
|
+
? fb.httpGetDataFunction(request.url, request.options)
|
|
170
|
+
: request.method === 'PUT' && fb.httpPutDataFunction
|
|
171
|
+
? fb.httpPutDataFunction(request.url, request.body, request.options)
|
|
172
|
+
: fb.httpPostDataFunction(request.url, request.body, request.options);
|
|
173
|
+
this.#running.set(true);
|
|
174
|
+
this.#runError.set(undefined);
|
|
175
|
+
req$.pipe(take(1), takeUntilDestroyed(this.#destroyRef)).subscribe({
|
|
176
|
+
next: (response) => {
|
|
177
|
+
this.#liveResponse.set((response ?? {}));
|
|
178
|
+
this.#lastRunTime.set(new Date().toLocaleTimeString([], { hour: '2-digit', minute: '2-digit' }));
|
|
179
|
+
this.#running.set(false);
|
|
180
|
+
// The point of the run is the fresh response — land where it shows.
|
|
181
|
+
this.selectedTab.set(4 /* ApiDialogTab.Response */);
|
|
182
|
+
},
|
|
183
|
+
error: (err) => {
|
|
184
|
+
this.#running.set(false);
|
|
185
|
+
const detail = typeof err?.error === 'string' ? err.error : err?.error?.message;
|
|
186
|
+
this.#runError.set(detail || err?.message || 'The request failed.');
|
|
187
|
+
},
|
|
188
|
+
});
|
|
189
|
+
}
|
|
190
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.12", ngImport: i0, type: ApiEndpointConfigDialogComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
191
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.12", type: ApiEndpointConfigDialogComponent, isStandalone: true, selector: "lib-api-endpoint-config-dialog", host: { classAttribute: "lib-api-endpoint-config-dialog" }, ngImport: i0, template: "<header class=\"aed__header\">\n <div class=\"aed__heading\">\n <h2 class=\"aed__title\">API call setup</h2>\n <p class=\"aed__subtitle\">{{ kindLabel() }}</p>\n </div>\n <button\n mat-icon-button\n mat-dialog-close\n class=\"aed__close\"\n aria-label=\"Close API call setup\">\n <mat-icon aria-hidden=\"true\">close</mat-icon>\n </button>\n</header>\n\n@if (hasEndpoint()) {\n <!-- Request bar \u2014 the Postman-style anchor: method, endpoint, change affordance. -->\n <div class=\"aed__request-bar\">\n <span class=\"aed__method\" [style.color]=\"methodColor()\">{{ config()?.httpMethod }}</span>\n <div class=\"aed__request-id\">\n <span class=\"aed__request-name\">{{ config()?.name }}</span>\n <span class=\"aed__request-url\" [matTooltip]=\"config()?.httpEndPoint ?? ''\">\n {{ config()?.httpEndPoint }}\n </span>\n </div>\n <button\n mat-stroked-button\n class=\"aed__change\"\n [disabled]=\"data.disabled()\"\n (click)=\"selectedTab.set(Tab.Endpoint)\">\n <mat-icon aria-hidden=\"true\">swap_horiz</mat-icon>\n Change endpoint\n </button>\n </div>\n} @else {\n <!-- First-run guide: the whole flow in one glance. -->\n <ol class=\"aed__steps\" aria-label=\"Setup steps\">\n <li class=\"aed__step aed__step--active\"><span class=\"aed__step-n\">1</span>Pick an endpoint</li>\n <li class=\"aed__step\"><span class=\"aed__step-n\">2</span>Bind request inputs</li>\n <li class=\"aed__step\"><span class=\"aed__step-n\">3</span>Map the response</li>\n </ol>\n}\n\n<mat-dialog-content class=\"aed__content\">\n <div class=\"aed__tabs-shell\">\n <mat-tab-group\n class=\"aed__tabs\"\n [mat-stretch-tabs]=\"false\"\n animationDuration=\"150ms\"\n [selectedIndex]=\"selectedTab()\"\n (selectedIndexChange)=\"selectedTab.set($event)\">\n\n <mat-tab label=\"Endpoint\">\n <section class=\"aed__pane\">\n <p class=\"aed__hint\">\n Choose which API this field calls. Endpoints come from your organisation's Postman\n collection \u2014 pick one and its method, URL, parameters and headers are captured for you.\n </p>\n <lib-rest-api-call-setup\n [postmanCollectionConfig]=\"data.postmanCollectionConfig()\"\n [httpGetDataFunction]=\"data.httpGetDataFunction()\"\n [disabled]=\"data.disabled()\"\n [value]=\"config()\"\n [errors]=\"data.errors() || []\"\n (valueChanged)=\"onEndpointChanged($event)\" />\n </section>\n </mat-tab>\n\n <mat-tab [disabled]=\"!hasEndpoint()\">\n <ng-template mat-tab-label>\n Params\n @if (paramCount() > 0) {\n <span class=\"aed__count\">{{ paramCount() }}</span>\n }\n </ng-template>\n <section class=\"aed__pane\">\n <p class=\"aed__hint\">\n Query parameters sent on the URL \u2014 one <code>\"name\": \"value\"</code> pair each. Type\n <code>$</code> to bind a value to a live form field; the request then waits for that\n field at fill time. Everything else is sent as a fixed value.\n </p>\n <lib-header-template-editor\n kind=\"query\"\n [value]=\"config()?.queryTemplate\"\n [defaultTemplate]=\"queryDefault()\"\n [formInputs]=\"data.formInputs()\"\n [disabled]=\"data.disabled()\"\n [showHint]=\"false\"\n (valueChanged)=\"data.queryChanged($event)\" />\n </section>\n </mat-tab>\n\n <mat-tab [disabled]=\"!hasEndpoint()\">\n <ng-template mat-tab-label>\n Headers\n @if (headerCount() > 0) {\n <span class=\"aed__count\">{{ headerCount() }}</span>\n }\n </ng-template>\n <section class=\"aed__pane\">\n <p class=\"aed__hint\">\n Headers sent with the request \u2014 the endpoint's own headers are prefilled. Type\n <code>$</code> to swap any value for a live form field; everything else is sent as a\n fixed value.\n </p>\n <lib-header-template-editor\n [value]=\"config()?.headerTemplate\"\n [defaultTemplate]=\"headerDefault()\"\n [formInputs]=\"data.formInputs()\"\n [disabled]=\"data.disabled()\"\n [showHint]=\"false\"\n (valueChanged)=\"data.headersChanged($event)\" />\n </section>\n </mat-tab>\n\n <mat-tab [disabled]=\"!hasEndpoint() || !sendsBody()\">\n <ng-template mat-tab-label>\n Body\n @if (hasEndpoint() && !sendsBody()) {\n <span class=\"aed__na\">n/a</span>\n }\n </ng-template>\n <section class=\"aed__pane\">\n <p class=\"aed__hint\">\n The request body, built from live form values. Map fields one by one, or author a JSON\n template when the payload is nested (type <code>$</code> to insert a field) \u2014\n switching modes never discards the other. <strong>Run API call</strong> sends exactly\n this body, with defaults filled in.\n </p>\n <div class=\"aed__mode\" role=\"group\" aria-label=\"Request body mechanism\">\n <button\n type=\"button\"\n class=\"aed__mode-chip\"\n [class.aed__mode-chip--active]=\"bodyMode() === 'mappedInputs'\"\n [disabled]=\"data.disabled()\"\n (click)=\"setBodyMode('mappedInputs')\">\n Map inputs\n </button>\n <button\n type=\"button\"\n class=\"aed__mode-chip\"\n [class.aed__mode-chip--active]=\"bodyMode() === 'template'\"\n [disabled]=\"data.disabled()\"\n (click)=\"setBodyMode('template')\">\n JSON template\n </button>\n </div>\n\n @if (bodyMode() === 'template') {\n <lib-payload-template-editor\n [value]=\"config()?.backEndConfig?.payloadTemplate\"\n [defaultTemplate]=\"payloadDefault()\"\n [formInputs]=\"data.formInputs()\"\n [disabled]=\"data.disabled()\"\n [showHint]=\"false\"\n (valueChanged)=\"data.payloadChanged($event)\" />\n } @else {\n <lib-required-inputs\n [value]=\"minInputs()\"\n [formInputs]=\"data.formInputs()\"\n [disabled]=\"data.disabled()\"\n (valueChanged)=\"data.minInputsChanged($event)\" />\n }\n </section>\n </mat-tab>\n\n <mat-tab [disabled]=\"!hasEndpoint()\">\n <ng-template mat-tab-label>{{ responseLabel() }}</ng-template>\n <section class=\"aed__pane\">\n <p class=\"aed__hint\">\n Where in the response the data lives. Walk the sample below and pick the values this\n field should read. The sample starts as the endpoint's saved Postman example \u2014 press\n <strong>Run API call</strong> (top right) to replace it with a live response built from\n this configuration.\n </p>\n <lib-api-value-access-rules\n [value]=\"$any(config()?.valueAccessRules) || []\"\n [formInputs]=\"$any(data.formInputs())\"\n [mapToData]=\"config()?._id\"\n [postmanCollectionConfig]=\"data.postmanCollectionConfig()\"\n [liveResponse]=\"liveResponse()\"\n [showSync]=\"false\"\n [disabled]=\"data.disabled()\"\n (valueChanged)=\"data.rulesChanged($event)\" />\n </section>\n </mat-tab>\n\n @if (docs(); as documentation) {\n <!-- Last tab, conditionally present \u2014 earlier tab indices stay stable. -->\n <mat-tab label=\"Docs\" [disabled]=\"!hasEndpoint()\">\n <section class=\"aed__pane\">\n <p class=\"aed__hint\">\n The endpoint's documentation, exactly as written in your organisation's Postman\n collection.\n </p>\n <pre class=\"aed__docs\">{{ documentation }}</pre>\n </section>\n </mat-tab>\n }\n\n </mat-tab-group>\n\n @if (hasEndpoint()) {\n <!-- Postman's Send, for the builder: runs the CONFIGURED request to\n refresh the sample response the mapping tree walks. Rendered AFTER the\n tab group so it stacks above Material's tab header and stays clickable. -->\n <button\n mat-flat-button\n class=\"aed__run\"\n [disabled]=\"running()\"\n [matTooltip]=\"runTooltip()\"\n [attr.aria-busy]=\"running()\"\n (click)=\"runApiCall()\">\n @if (running()) {\n <mat-spinner diameter=\"16\" />\n } @else {\n <mat-icon aria-hidden=\"true\">play_arrow</mat-icon>\n }\n {{ running() ? 'Running\u2026' : 'Run API call' }}\n </button>\n }\n </div>\n</mat-dialog-content>\n\n<footer class=\"aed__footer\">\n <div class=\"aed__status\">\n <div class=\"aed__chips\">\n @for (item of readiness(); track item.label) {\n <span class=\"aed__chip\" [attr.data-state]=\"item.state\">\n <!-- Glyph + colour + border style: state is never colour-only. -->\n {{ item.state === 'done' ? '\u2713 ' : item.state === 'pending' ? '\u2022 ' : '' }}{{ item.label }}\n </span>\n }\n </div>\n @if (hasEndpoint()) {\n @if (waitsFor().length > 0) {\n <p class=\"aed__waits\">\n Waits for {{ waitsFor().join(', ') }} before fetching \u2014 the same gate the form applies\n at fill time.\n </p>\n } @else {\n <p class=\"aed__waits\">Fetches as soon as the form loads \u2014 no live fields are bound.</p>\n }\n @if (runError(); as err) {\n <p class=\"aed__run-note aed__run-note--error\">Run failed: {{ err }}</p>\n } @else if (lastRunTime(); as time) {\n <p class=\"aed__run-note\">\n Fresh response \u00B7 {{ time }}@if (runUnresolved().length > 0) {\n \u2014 sent without live values: {{ runUnresolved().join(', ') }}\n }\n </p>\n }\n }\n </div>\n <button mat-flat-button mat-dialog-close class=\"aed__done\">Done</button>\n</footer>\n", styles: [":host{display:flex;flex-direction:column;min-height:0;height:100%}.aed__header{display:flex;align-items:flex-start;gap:1rem;padding:1.25rem 1.5rem .75rem}.aed__heading{flex:1;min-width:0}.aed__title{margin:0;font-size:1.125rem;font-weight:600;letter-spacing:-.01em;color:var(--mat-sys-on-surface)}.aed__subtitle{margin:.125rem 0 0;font-size:.6875rem;font-weight:600;letter-spacing:.12em;text-transform:uppercase;color:var(--mat-sys-primary)}.aed__close{flex-shrink:0}.aed__request-bar{display:flex;align-items:center;gap:.875rem;margin:0 1.5rem .75rem;padding:.625rem .875rem;border:1px solid color-mix(in srgb,var(--mat-sys-on-surface) 12%,transparent);border-radius:10px;background:color-mix(in srgb,var(--mat-sys-on-surface) 3%,transparent)}.aed__method{flex-shrink:0;font-size:.75rem;font-weight:800;letter-spacing:.06em}.aed__request-id{flex:1;min-width:0;display:flex;flex-direction:column;gap:.125rem}.aed__request-name{font-size:.875rem;font-weight:600;color:var(--mat-sys-on-surface);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.aed__request-url{font-family:monospace;font-size:.75rem;color:var(--mat-sys-on-surface-variant);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.aed__change{flex-shrink:0}.aed__steps{display:flex;flex-wrap:wrap;gap:1.5rem;margin:0 1.5rem .75rem;padding:.75rem .875rem;list-style:none;border:1px dashed color-mix(in srgb,var(--mat-sys-on-surface) 25%,transparent);border-radius:10px}.aed__step{display:flex;align-items:center;gap:.5rem;font-size:.8125rem;color:var(--mat-sys-on-surface-variant)}.aed__step--active{color:var(--mat-sys-on-surface);font-weight:600}.aed__step-n{display:inline-flex;align-items:center;justify-content:center;width:1.375rem;height:1.375rem;border-radius:999px;font-size:.6875rem;font-weight:700;color:var(--mat-sys-on-surface-variant);background:color-mix(in srgb,var(--mat-sys-on-surface) 8%,transparent)}.aed__step--active .aed__step-n{color:var(--mat-sys-on-primary);background:var(--mat-sys-primary)}.aed__content{flex:1;min-height:0;padding:0 1.5rem}.aed__tabs-shell{position:relative}.aed__run{position:absolute;top:.3rem;right:0;z-index:10}.aed__run:active:not(:disabled){transform:scale(.97);transition-duration:0s}.aed__run-note{margin:0;font-size:.75rem;color:var(--mat-sys-primary)}.aed__run-note--error{color:var(--mat-sys-error)}.aed__tabs{min-height:min(42vh,28rem)}.aed__pane{display:flex;flex-direction:column;gap:1rem;padding:1rem .25rem 1.25rem}.aed__hint{margin:0;font-size:.8125rem;line-height:1.5;color:var(--mat-sys-on-surface-variant);max-width:72ch}.aed__count{display:inline-flex;align-items:center;justify-content:center;min-width:1.125rem;height:1.125rem;margin-left:.375rem;padding:0 .25rem;border-radius:999px;font-size:.625rem;font-weight:700;color:var(--mat-sys-primary);background:color-mix(in srgb,var(--mat-sys-primary) 14%,transparent)}.aed__na{margin-left:.375rem;font-size:.5625rem;font-weight:700;letter-spacing:.08em;text-transform:uppercase;color:var(--mat-sys-on-surface-variant)}.aed__mode{display:flex;gap:.5rem}.aed__mode-chip{border:none;border-radius:6px;padding:.35rem .9rem;font:inherit;font-size:.8125rem;color:var(--mat-sys-on-surface-variant);background:color-mix(in srgb,var(--mat-sys-on-surface) 6%,transparent);cursor:pointer;transition:background .3s cubic-bezier(.16,1,.3,1),color .3s cubic-bezier(.16,1,.3,1)}.aed__mode-chip:focus-visible{outline:2px solid var(--mat-sys-primary);outline-offset:2px}.aed__mode-chip:disabled{cursor:default;opacity:.5}.aed__mode-chip--active{color:var(--mat-sys-primary);background:color-mix(in srgb,var(--mat-sys-primary) 12%,transparent);font-weight:600}.aed__footer{display:flex;align-items:center;gap:1rem;padding:.875rem 1.5rem 1.25rem;border-top:1px solid color-mix(in srgb,var(--mat-sys-on-surface) 10%,transparent)}.aed__status{flex:1;min-width:0;display:flex;flex-direction:column;gap:.375rem}.aed__chips{display:flex;flex-wrap:wrap;gap:.5rem}.aed__chip{border-radius:6px;padding:.2rem .6rem;font-size:.5625rem;font-weight:700;letter-spacing:.08em;text-transform:uppercase}.aed__chip[data-state=done]{color:var(--mat-sys-primary);background:color-mix(in srgb,var(--mat-sys-primary) 12%,transparent)}.aed__chip[data-state=pending]{color:var(--mat-sys-on-surface-variant);background:color-mix(in srgb,var(--mat-sys-on-surface) 8%,transparent)}.aed__chip[data-state=skip]{color:var(--mat-sys-on-surface-variant);background:transparent;border:1px dashed color-mix(in srgb,var(--mat-sys-on-surface) 25%,transparent)}.aed__waits{margin:0;font-size:.75rem;color:var(--mat-sys-on-surface-variant)}.aed__done{flex-shrink:0}.aed__docs{margin:0;font:inherit;font-size:.8438rem;line-height:1.6;color:var(--mat-sys-on-surface);white-space:pre-wrap;overflow-wrap:anywhere;max-width:76ch}@media(prefers-reduced-motion:reduce){.aed__mode-chip,.aed__run{transition:none}.aed__run:active:not(:disabled){transform:none}}\n"], dependencies: [{ kind: "ngmodule", type: MatDialogModule }, { kind: "directive", type: i1.MatDialogClose, selector: "[mat-dialog-close], [matDialogClose]", inputs: ["aria-label", "type", "mat-dialog-close", "matDialogClose"], exportAs: ["matDialogClose"] }, { kind: "directive", type: i1.MatDialogContent, selector: "[mat-dialog-content], mat-dialog-content, [matDialogContent]" }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i2.MatButton, selector: " button[matButton], a[matButton], button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button], a[mat-button], a[mat-raised-button], a[mat-flat-button], a[mat-stroked-button] ", inputs: ["matButton"], exportAs: ["matButton", "matAnchor"] }, { kind: "component", type: i2.MatIconButton, selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]", exportAs: ["matButton", "matAnchor"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatProgressSpinnerModule }, { kind: "component", type: i4.MatProgressSpinner, selector: "mat-progress-spinner, mat-spinner", inputs: ["color", "mode", "value", "diameter", "strokeWidth"], exportAs: ["matProgressSpinner"] }, { kind: "ngmodule", type: MatTabsModule }, { kind: "directive", type: i5.MatTabLabel, selector: "[mat-tab-label], [matTabLabel]" }, { kind: "component", type: i5.MatTab, selector: "mat-tab", inputs: ["disabled", "label", "aria-label", "aria-labelledby", "labelClass", "bodyClass", "id"], exportAs: ["matTab"] }, { kind: "component", type: i5.MatTabGroup, selector: "mat-tab-group", inputs: ["color", "fitInkBarToContent", "mat-stretch-tabs", "mat-align-tabs", "dynamicHeight", "selectedIndex", "headerPosition", "animationDuration", "contentTabIndex", "disablePagination", "disableRipple", "preserveContent", "backgroundColor", "aria-label", "aria-labelledby"], outputs: ["selectedIndexChange", "focusChange", "animationDone", "selectedTabChange"], exportAs: ["matTabGroup"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i5$1.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "component", type: ApiValueAccessRulesComponent, selector: "lib-api-value-access-rules", inputs: ["disabled", "multipleBind", "errors", "value", "formInputs", "mapToData", "postmanCollectionConfig", "liveResponse", "showSync"], outputs: ["valueChanged", "reload"] }, { kind: "component", type: HeaderTemplateEditorComponent, selector: "lib-header-template-editor", inputs: ["kind", "value", "defaultTemplate", "formInputs", "disabled", "showHint", "errors", "id"], outputs: ["valueChanged"] }, { kind: "component", type: PayloadTemplateEditorComponent, selector: "lib-payload-template-editor", inputs: ["value", "defaultTemplate", "formInputs", "disabled", "showHint", "errors", "id"], outputs: ["valueChanged"] }, { kind: "component", type: RequiredInputsComponent, selector: "lib-required-inputs", inputs: ["value", "formInputs", "disabled", "errors", "id"], outputs: ["valueChanged"] }, { kind: "component", type: RestApiCallSetupComponent, selector: "lib-rest-api-call-setup", inputs: ["id", "postmanCollectionConfig", "httpGetDataFunction", "disabled", "value", "errors"], outputs: ["valueChanged"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
192
|
+
}
|
|
193
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.12", ngImport: i0, type: ApiEndpointConfigDialogComponent, decorators: [{
|
|
194
|
+
type: Component,
|
|
195
|
+
args: [{ selector: 'lib-api-endpoint-config-dialog', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.Emulated, host: { class: 'lib-api-endpoint-config-dialog' }, imports: [
|
|
196
|
+
MatDialogModule,
|
|
197
|
+
MatButtonModule,
|
|
198
|
+
MatIconModule,
|
|
199
|
+
MatProgressSpinnerModule,
|
|
200
|
+
MatTabsModule,
|
|
201
|
+
MatTooltipModule,
|
|
202
|
+
ApiValueAccessRulesComponent,
|
|
203
|
+
HeaderTemplateEditorComponent,
|
|
204
|
+
PayloadTemplateEditorComponent,
|
|
205
|
+
RequiredInputsComponent,
|
|
206
|
+
RestApiCallSetupComponent,
|
|
207
|
+
], template: "<header class=\"aed__header\">\n <div class=\"aed__heading\">\n <h2 class=\"aed__title\">API call setup</h2>\n <p class=\"aed__subtitle\">{{ kindLabel() }}</p>\n </div>\n <button\n mat-icon-button\n mat-dialog-close\n class=\"aed__close\"\n aria-label=\"Close API call setup\">\n <mat-icon aria-hidden=\"true\">close</mat-icon>\n </button>\n</header>\n\n@if (hasEndpoint()) {\n <!-- Request bar \u2014 the Postman-style anchor: method, endpoint, change affordance. -->\n <div class=\"aed__request-bar\">\n <span class=\"aed__method\" [style.color]=\"methodColor()\">{{ config()?.httpMethod }}</span>\n <div class=\"aed__request-id\">\n <span class=\"aed__request-name\">{{ config()?.name }}</span>\n <span class=\"aed__request-url\" [matTooltip]=\"config()?.httpEndPoint ?? ''\">\n {{ config()?.httpEndPoint }}\n </span>\n </div>\n <button\n mat-stroked-button\n class=\"aed__change\"\n [disabled]=\"data.disabled()\"\n (click)=\"selectedTab.set(Tab.Endpoint)\">\n <mat-icon aria-hidden=\"true\">swap_horiz</mat-icon>\n Change endpoint\n </button>\n </div>\n} @else {\n <!-- First-run guide: the whole flow in one glance. -->\n <ol class=\"aed__steps\" aria-label=\"Setup steps\">\n <li class=\"aed__step aed__step--active\"><span class=\"aed__step-n\">1</span>Pick an endpoint</li>\n <li class=\"aed__step\"><span class=\"aed__step-n\">2</span>Bind request inputs</li>\n <li class=\"aed__step\"><span class=\"aed__step-n\">3</span>Map the response</li>\n </ol>\n}\n\n<mat-dialog-content class=\"aed__content\">\n <div class=\"aed__tabs-shell\">\n <mat-tab-group\n class=\"aed__tabs\"\n [mat-stretch-tabs]=\"false\"\n animationDuration=\"150ms\"\n [selectedIndex]=\"selectedTab()\"\n (selectedIndexChange)=\"selectedTab.set($event)\">\n\n <mat-tab label=\"Endpoint\">\n <section class=\"aed__pane\">\n <p class=\"aed__hint\">\n Choose which API this field calls. Endpoints come from your organisation's Postman\n collection \u2014 pick one and its method, URL, parameters and headers are captured for you.\n </p>\n <lib-rest-api-call-setup\n [postmanCollectionConfig]=\"data.postmanCollectionConfig()\"\n [httpGetDataFunction]=\"data.httpGetDataFunction()\"\n [disabled]=\"data.disabled()\"\n [value]=\"config()\"\n [errors]=\"data.errors() || []\"\n (valueChanged)=\"onEndpointChanged($event)\" />\n </section>\n </mat-tab>\n\n <mat-tab [disabled]=\"!hasEndpoint()\">\n <ng-template mat-tab-label>\n Params\n @if (paramCount() > 0) {\n <span class=\"aed__count\">{{ paramCount() }}</span>\n }\n </ng-template>\n <section class=\"aed__pane\">\n <p class=\"aed__hint\">\n Query parameters sent on the URL \u2014 one <code>\"name\": \"value\"</code> pair each. Type\n <code>$</code> to bind a value to a live form field; the request then waits for that\n field at fill time. Everything else is sent as a fixed value.\n </p>\n <lib-header-template-editor\n kind=\"query\"\n [value]=\"config()?.queryTemplate\"\n [defaultTemplate]=\"queryDefault()\"\n [formInputs]=\"data.formInputs()\"\n [disabled]=\"data.disabled()\"\n [showHint]=\"false\"\n (valueChanged)=\"data.queryChanged($event)\" />\n </section>\n </mat-tab>\n\n <mat-tab [disabled]=\"!hasEndpoint()\">\n <ng-template mat-tab-label>\n Headers\n @if (headerCount() > 0) {\n <span class=\"aed__count\">{{ headerCount() }}</span>\n }\n </ng-template>\n <section class=\"aed__pane\">\n <p class=\"aed__hint\">\n Headers sent with the request \u2014 the endpoint's own headers are prefilled. Type\n <code>$</code> to swap any value for a live form field; everything else is sent as a\n fixed value.\n </p>\n <lib-header-template-editor\n [value]=\"config()?.headerTemplate\"\n [defaultTemplate]=\"headerDefault()\"\n [formInputs]=\"data.formInputs()\"\n [disabled]=\"data.disabled()\"\n [showHint]=\"false\"\n (valueChanged)=\"data.headersChanged($event)\" />\n </section>\n </mat-tab>\n\n <mat-tab [disabled]=\"!hasEndpoint() || !sendsBody()\">\n <ng-template mat-tab-label>\n Body\n @if (hasEndpoint() && !sendsBody()) {\n <span class=\"aed__na\">n/a</span>\n }\n </ng-template>\n <section class=\"aed__pane\">\n <p class=\"aed__hint\">\n The request body, built from live form values. Map fields one by one, or author a JSON\n template when the payload is nested (type <code>$</code> to insert a field) \u2014\n switching modes never discards the other. <strong>Run API call</strong> sends exactly\n this body, with defaults filled in.\n </p>\n <div class=\"aed__mode\" role=\"group\" aria-label=\"Request body mechanism\">\n <button\n type=\"button\"\n class=\"aed__mode-chip\"\n [class.aed__mode-chip--active]=\"bodyMode() === 'mappedInputs'\"\n [disabled]=\"data.disabled()\"\n (click)=\"setBodyMode('mappedInputs')\">\n Map inputs\n </button>\n <button\n type=\"button\"\n class=\"aed__mode-chip\"\n [class.aed__mode-chip--active]=\"bodyMode() === 'template'\"\n [disabled]=\"data.disabled()\"\n (click)=\"setBodyMode('template')\">\n JSON template\n </button>\n </div>\n\n @if (bodyMode() === 'template') {\n <lib-payload-template-editor\n [value]=\"config()?.backEndConfig?.payloadTemplate\"\n [defaultTemplate]=\"payloadDefault()\"\n [formInputs]=\"data.formInputs()\"\n [disabled]=\"data.disabled()\"\n [showHint]=\"false\"\n (valueChanged)=\"data.payloadChanged($event)\" />\n } @else {\n <lib-required-inputs\n [value]=\"minInputs()\"\n [formInputs]=\"data.formInputs()\"\n [disabled]=\"data.disabled()\"\n (valueChanged)=\"data.minInputsChanged($event)\" />\n }\n </section>\n </mat-tab>\n\n <mat-tab [disabled]=\"!hasEndpoint()\">\n <ng-template mat-tab-label>{{ responseLabel() }}</ng-template>\n <section class=\"aed__pane\">\n <p class=\"aed__hint\">\n Where in the response the data lives. Walk the sample below and pick the values this\n field should read. The sample starts as the endpoint's saved Postman example \u2014 press\n <strong>Run API call</strong> (top right) to replace it with a live response built from\n this configuration.\n </p>\n <lib-api-value-access-rules\n [value]=\"$any(config()?.valueAccessRules) || []\"\n [formInputs]=\"$any(data.formInputs())\"\n [mapToData]=\"config()?._id\"\n [postmanCollectionConfig]=\"data.postmanCollectionConfig()\"\n [liveResponse]=\"liveResponse()\"\n [showSync]=\"false\"\n [disabled]=\"data.disabled()\"\n (valueChanged)=\"data.rulesChanged($event)\" />\n </section>\n </mat-tab>\n\n @if (docs(); as documentation) {\n <!-- Last tab, conditionally present \u2014 earlier tab indices stay stable. -->\n <mat-tab label=\"Docs\" [disabled]=\"!hasEndpoint()\">\n <section class=\"aed__pane\">\n <p class=\"aed__hint\">\n The endpoint's documentation, exactly as written in your organisation's Postman\n collection.\n </p>\n <pre class=\"aed__docs\">{{ documentation }}</pre>\n </section>\n </mat-tab>\n }\n\n </mat-tab-group>\n\n @if (hasEndpoint()) {\n <!-- Postman's Send, for the builder: runs the CONFIGURED request to\n refresh the sample response the mapping tree walks. Rendered AFTER the\n tab group so it stacks above Material's tab header and stays clickable. -->\n <button\n mat-flat-button\n class=\"aed__run\"\n [disabled]=\"running()\"\n [matTooltip]=\"runTooltip()\"\n [attr.aria-busy]=\"running()\"\n (click)=\"runApiCall()\">\n @if (running()) {\n <mat-spinner diameter=\"16\" />\n } @else {\n <mat-icon aria-hidden=\"true\">play_arrow</mat-icon>\n }\n {{ running() ? 'Running\u2026' : 'Run API call' }}\n </button>\n }\n </div>\n</mat-dialog-content>\n\n<footer class=\"aed__footer\">\n <div class=\"aed__status\">\n <div class=\"aed__chips\">\n @for (item of readiness(); track item.label) {\n <span class=\"aed__chip\" [attr.data-state]=\"item.state\">\n <!-- Glyph + colour + border style: state is never colour-only. -->\n {{ item.state === 'done' ? '\u2713 ' : item.state === 'pending' ? '\u2022 ' : '' }}{{ item.label }}\n </span>\n }\n </div>\n @if (hasEndpoint()) {\n @if (waitsFor().length > 0) {\n <p class=\"aed__waits\">\n Waits for {{ waitsFor().join(', ') }} before fetching \u2014 the same gate the form applies\n at fill time.\n </p>\n } @else {\n <p class=\"aed__waits\">Fetches as soon as the form loads \u2014 no live fields are bound.</p>\n }\n @if (runError(); as err) {\n <p class=\"aed__run-note aed__run-note--error\">Run failed: {{ err }}</p>\n } @else if (lastRunTime(); as time) {\n <p class=\"aed__run-note\">\n Fresh response \u00B7 {{ time }}@if (runUnresolved().length > 0) {\n \u2014 sent without live values: {{ runUnresolved().join(', ') }}\n }\n </p>\n }\n }\n </div>\n <button mat-flat-button mat-dialog-close class=\"aed__done\">Done</button>\n</footer>\n", styles: [":host{display:flex;flex-direction:column;min-height:0;height:100%}.aed__header{display:flex;align-items:flex-start;gap:1rem;padding:1.25rem 1.5rem .75rem}.aed__heading{flex:1;min-width:0}.aed__title{margin:0;font-size:1.125rem;font-weight:600;letter-spacing:-.01em;color:var(--mat-sys-on-surface)}.aed__subtitle{margin:.125rem 0 0;font-size:.6875rem;font-weight:600;letter-spacing:.12em;text-transform:uppercase;color:var(--mat-sys-primary)}.aed__close{flex-shrink:0}.aed__request-bar{display:flex;align-items:center;gap:.875rem;margin:0 1.5rem .75rem;padding:.625rem .875rem;border:1px solid color-mix(in srgb,var(--mat-sys-on-surface) 12%,transparent);border-radius:10px;background:color-mix(in srgb,var(--mat-sys-on-surface) 3%,transparent)}.aed__method{flex-shrink:0;font-size:.75rem;font-weight:800;letter-spacing:.06em}.aed__request-id{flex:1;min-width:0;display:flex;flex-direction:column;gap:.125rem}.aed__request-name{font-size:.875rem;font-weight:600;color:var(--mat-sys-on-surface);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.aed__request-url{font-family:monospace;font-size:.75rem;color:var(--mat-sys-on-surface-variant);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.aed__change{flex-shrink:0}.aed__steps{display:flex;flex-wrap:wrap;gap:1.5rem;margin:0 1.5rem .75rem;padding:.75rem .875rem;list-style:none;border:1px dashed color-mix(in srgb,var(--mat-sys-on-surface) 25%,transparent);border-radius:10px}.aed__step{display:flex;align-items:center;gap:.5rem;font-size:.8125rem;color:var(--mat-sys-on-surface-variant)}.aed__step--active{color:var(--mat-sys-on-surface);font-weight:600}.aed__step-n{display:inline-flex;align-items:center;justify-content:center;width:1.375rem;height:1.375rem;border-radius:999px;font-size:.6875rem;font-weight:700;color:var(--mat-sys-on-surface-variant);background:color-mix(in srgb,var(--mat-sys-on-surface) 8%,transparent)}.aed__step--active .aed__step-n{color:var(--mat-sys-on-primary);background:var(--mat-sys-primary)}.aed__content{flex:1;min-height:0;padding:0 1.5rem}.aed__tabs-shell{position:relative}.aed__run{position:absolute;top:.3rem;right:0;z-index:10}.aed__run:active:not(:disabled){transform:scale(.97);transition-duration:0s}.aed__run-note{margin:0;font-size:.75rem;color:var(--mat-sys-primary)}.aed__run-note--error{color:var(--mat-sys-error)}.aed__tabs{min-height:min(42vh,28rem)}.aed__pane{display:flex;flex-direction:column;gap:1rem;padding:1rem .25rem 1.25rem}.aed__hint{margin:0;font-size:.8125rem;line-height:1.5;color:var(--mat-sys-on-surface-variant);max-width:72ch}.aed__count{display:inline-flex;align-items:center;justify-content:center;min-width:1.125rem;height:1.125rem;margin-left:.375rem;padding:0 .25rem;border-radius:999px;font-size:.625rem;font-weight:700;color:var(--mat-sys-primary);background:color-mix(in srgb,var(--mat-sys-primary) 14%,transparent)}.aed__na{margin-left:.375rem;font-size:.5625rem;font-weight:700;letter-spacing:.08em;text-transform:uppercase;color:var(--mat-sys-on-surface-variant)}.aed__mode{display:flex;gap:.5rem}.aed__mode-chip{border:none;border-radius:6px;padding:.35rem .9rem;font:inherit;font-size:.8125rem;color:var(--mat-sys-on-surface-variant);background:color-mix(in srgb,var(--mat-sys-on-surface) 6%,transparent);cursor:pointer;transition:background .3s cubic-bezier(.16,1,.3,1),color .3s cubic-bezier(.16,1,.3,1)}.aed__mode-chip:focus-visible{outline:2px solid var(--mat-sys-primary);outline-offset:2px}.aed__mode-chip:disabled{cursor:default;opacity:.5}.aed__mode-chip--active{color:var(--mat-sys-primary);background:color-mix(in srgb,var(--mat-sys-primary) 12%,transparent);font-weight:600}.aed__footer{display:flex;align-items:center;gap:1rem;padding:.875rem 1.5rem 1.25rem;border-top:1px solid color-mix(in srgb,var(--mat-sys-on-surface) 10%,transparent)}.aed__status{flex:1;min-width:0;display:flex;flex-direction:column;gap:.375rem}.aed__chips{display:flex;flex-wrap:wrap;gap:.5rem}.aed__chip{border-radius:6px;padding:.2rem .6rem;font-size:.5625rem;font-weight:700;letter-spacing:.08em;text-transform:uppercase}.aed__chip[data-state=done]{color:var(--mat-sys-primary);background:color-mix(in srgb,var(--mat-sys-primary) 12%,transparent)}.aed__chip[data-state=pending]{color:var(--mat-sys-on-surface-variant);background:color-mix(in srgb,var(--mat-sys-on-surface) 8%,transparent)}.aed__chip[data-state=skip]{color:var(--mat-sys-on-surface-variant);background:transparent;border:1px dashed color-mix(in srgb,var(--mat-sys-on-surface) 25%,transparent)}.aed__waits{margin:0;font-size:.75rem;color:var(--mat-sys-on-surface-variant)}.aed__done{flex-shrink:0}.aed__docs{margin:0;font:inherit;font-size:.8438rem;line-height:1.6;color:var(--mat-sys-on-surface);white-space:pre-wrap;overflow-wrap:anywhere;max-width:76ch}@media(prefers-reduced-motion:reduce){.aed__mode-chip,.aed__run{transition:none}.aed__run:active:not(:disabled){transform:none}}\n"] }]
|
|
208
|
+
}] });
|
|
209
|
+
/** The map itself when it carries entries; `undefined` otherwise. */
|
|
210
|
+
function nonEmpty(map) {
|
|
211
|
+
return map && Object.keys(map).length > 0 ? map : undefined;
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
/**
|
|
215
|
+
* Entry point for a whole `matOptions.fetch.<slot>` API configuration.
|
|
216
|
+
*
|
|
217
|
+
* The element editor's sidebar is too narrow to author a request in, so this
|
|
218
|
+
* component renders only the CURRENT STATE — an invitation card before an
|
|
219
|
+
* endpoint is picked, a summary card (method, endpoint, per-area status chips,
|
|
220
|
+
* the waits-for line) after — and opens the Postman-style
|
|
221
|
+
* {@link ApiEndpointConfigDialogComponent} for the actual editing. It remains
|
|
222
|
+
* the single owner of every mutation: the dialog reads live state through
|
|
223
|
+
* signals and forwards edits back into the patch methods here, so autoSave
|
|
224
|
+
* merge-back behaves exactly as it did when the editors were inline.
|
|
225
|
+
*
|
|
226
|
+
* Emits the COMPLETE fetch config on every change. Selecting a new endpoint
|
|
227
|
+
* REPLACES the slot (the legacy per-row `clearOnChange` semantics); editing a
|
|
228
|
+
* slice merges over the current value.
|
|
229
|
+
*
|
|
230
|
+
* Internal editor consumed by `t-dynamic-data-edit`; not part of the public API.
|
|
231
|
+
*
|
|
232
|
+
* @example
|
|
233
|
+
* <lib-api-endpoint-config [value]="fetchConfig()" [formInputs]="inputs()"
|
|
234
|
+
* [postmanCollectionConfig]="postman()" (valueChanged)="onConfig($event)" />
|
|
235
|
+
*/
|
|
236
|
+
class ApiEndpointConfigComponent {
|
|
237
|
+
#dialog;
|
|
238
|
+
#destroyRef;
|
|
239
|
+
/** The open editor dialog, if any — guards against double-opening. */
|
|
240
|
+
#dialogRef;
|
|
241
|
+
constructor() {
|
|
242
|
+
this.#dialog = inject(MatDialog);
|
|
243
|
+
this.#destroyRef = inject(DestroyRef);
|
|
244
|
+
/** Current fetch-slot configuration (`undefined` until an endpoint is picked). */
|
|
245
|
+
this.value = input(undefined, ...(ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ []));
|
|
246
|
+
/** Which slot is being configured — copy only; behaviour is identical. */
|
|
247
|
+
this.kind = input('value', ...(ngDevMode ? [{ debugName: "kind" }] : /* istanbul ignore next */ []));
|
|
248
|
+
/** All form inputs, offered as bindings by the hosted editors. */
|
|
249
|
+
this.formInputs = input([], ...(ngDevMode ? [{ debugName: "formInputs" }] : /* istanbul ignore next */ []));
|
|
250
|
+
/** Postman collection behind the endpoint picker + response mapping. */
|
|
251
|
+
this.postmanCollectionConfig = input(undefined, ...(ngDevMode ? [{ debugName: "postmanCollectionConfig" }] : /* istanbul ignore next */ []));
|
|
252
|
+
/** Optional HTTP GET hook, forwarded to the endpoint picker (parity). */
|
|
253
|
+
this.httpGetDataFunction = input(undefined, ...(ngDevMode ? [{ debugName: "httpGetDataFunction" }] : /* istanbul ignore next */ []));
|
|
254
|
+
/** Disables editing; the dialog stays openable for read-only review. */
|
|
255
|
+
this.disabled = input(false, ...(ngDevMode ? [{ debugName: "disabled" }] : /* istanbul ignore next */ []));
|
|
256
|
+
/** Validation errors surfaced by the parent editor. */
|
|
257
|
+
this.errors = input([], ...(ngDevMode ? [{ debugName: "errors" }] : /* istanbul ignore next */ []));
|
|
258
|
+
/** Optional id supplied by the parent editor. */
|
|
259
|
+
this.id = input(undefined, ...(ngDevMode ? [{ debugName: "id" }] : /* istanbul ignore next */ []));
|
|
260
|
+
/** Emits the complete fetch config on every change (`undefined` on clear). */
|
|
261
|
+
this.valueChanged = output();
|
|
262
|
+
/**
|
|
263
|
+
* The configuration being edited: follows the parent `value`, and local
|
|
264
|
+
* patches override it until the parent hands a new value down (autoSave
|
|
265
|
+
* merge-back). `linkedSignal` per the library decision tree — a source the
|
|
266
|
+
* user can override locally.
|
|
267
|
+
*/
|
|
268
|
+
this.config = linkedSignal(() => this.value(), ...(ngDevMode ? [{ debugName: "config" }] : /* istanbul ignore next */ []));
|
|
269
|
+
/** True once the slot carries a usable endpoint. */
|
|
270
|
+
this.hasEndpoint = computed(() => Boolean(this.config()?.httpEndPoint), ...(ngDevMode ? [{ debugName: "hasEndpoint" }] : /* istanbul ignore next */ []));
|
|
271
|
+
/** Token colour for the summary card's method badge. */
|
|
272
|
+
this.methodColor = computed(() => methodColorOf(this.config()), ...(ngDevMode ? [{ debugName: "methodColor" }] : /* istanbul ignore next */ []));
|
|
273
|
+
/**
|
|
274
|
+
* Summary chips: request-area counts (Params, Headers) followed by the
|
|
275
|
+
* readiness rail's Body / mapping entries — one glance answers "what is
|
|
276
|
+
* configured, what still needs me".
|
|
277
|
+
*/
|
|
278
|
+
this.summaryChips = computed(() => {
|
|
279
|
+
const cfg = this.config();
|
|
280
|
+
const params = paramCountOf(cfg);
|
|
281
|
+
const headers = headerCountOf(cfg);
|
|
282
|
+
const chips = [
|
|
283
|
+
{ label: params > 0 ? `Params · ${params}` : 'Params', state: params > 0 ? 'done' : 'skip' },
|
|
284
|
+
{ label: headers > 0 ? `Headers · ${headers}` : 'Headers', state: headers > 0 ? 'done' : 'skip' },
|
|
285
|
+
];
|
|
286
|
+
for (const item of readinessOf(cfg, this.kind())) {
|
|
287
|
+
if (item.label !== 'Endpoint')
|
|
288
|
+
chips.push(item);
|
|
289
|
+
}
|
|
290
|
+
return chips;
|
|
291
|
+
}, ...(ngDevMode ? [{ debugName: "summaryChips" }] : /* istanbul ignore next */ []));
|
|
292
|
+
/** Friendly labels of the live fields the fetch waits for at fill time. */
|
|
293
|
+
this.waitsFor = computed(() => waitsForLabels(this.config(), this.formInputs()), ...(ngDevMode ? [{ debugName: "waitsFor" }] : /* istanbul ignore next */ []));
|
|
294
|
+
/** Invitation copy, adapted to whether a Postman collection is available. */
|
|
295
|
+
this.inviteMessage = computed(() => this.postmanCollectionConfig()
|
|
296
|
+
? 'No API connected yet. Pick an endpoint, bind its request to live form fields, and map the response — all in one guided setup.'
|
|
297
|
+
: 'No Postman collection configured. Add a collection id and API key to pick an endpoint.', ...(ngDevMode ? [{ debugName: "inviteMessage" }] : /* istanbul ignore next */ []));
|
|
298
|
+
/** The open editor dialog, if any — guards against double-opening. */
|
|
299
|
+
this.#dialogRef = null;
|
|
300
|
+
this.#destroyRef.onDestroy(() => this.#dialogRef?.close());
|
|
301
|
+
}
|
|
302
|
+
/**
|
|
303
|
+
* Opens the Postman-style editor dialog. The dialog reads live state through
|
|
304
|
+
* the context's signals and forwards every edit back into this component's
|
|
305
|
+
* patch methods, so the emit semantics are identical to the old inline
|
|
306
|
+
* editors. Opening while `disabled` is allowed — the hosted editors render
|
|
307
|
+
* read-only, which is how a locked configuration is reviewed.
|
|
308
|
+
*/
|
|
309
|
+
openDialog() {
|
|
310
|
+
if (this.#dialogRef)
|
|
311
|
+
return;
|
|
312
|
+
const context = {
|
|
313
|
+
kind: this.kind(),
|
|
314
|
+
config: this.config.asReadonly(),
|
|
315
|
+
formInputs: this.formInputs,
|
|
316
|
+
postmanCollectionConfig: this.postmanCollectionConfig,
|
|
317
|
+
httpGetDataFunction: this.httpGetDataFunction,
|
|
318
|
+
disabled: this.disabled,
|
|
319
|
+
errors: this.errors,
|
|
320
|
+
endpointChanged: (cfg) => this.onEndpointChanged(cfg),
|
|
321
|
+
queryChanged: (template) => this.onQueryChanged(template),
|
|
322
|
+
headersChanged: (template) => this.onHeadersChanged(template),
|
|
323
|
+
bodyModeChanged: (mode) => this.setBodyMode(mode),
|
|
324
|
+
minInputsChanged: (minInputs) => this.onMinInputsChanged(minInputs),
|
|
325
|
+
payloadChanged: (template) => this.onPayloadChanged(template),
|
|
326
|
+
rulesChanged: (rules) => this.onRulesChanged(rules),
|
|
327
|
+
};
|
|
328
|
+
this.#dialogRef = this.#dialog.open(ApiEndpointConfigDialogComponent, {
|
|
329
|
+
data: context,
|
|
330
|
+
width: 'min(1080px, 96vw)',
|
|
331
|
+
maxWidth: '96vw',
|
|
332
|
+
maxHeight: '92vh',
|
|
333
|
+
autoFocus: 'first-tabbable',
|
|
334
|
+
panelClass: 'lib-api-endpoint-dialog-panel',
|
|
335
|
+
});
|
|
336
|
+
this.#dialogRef
|
|
337
|
+
.afterClosed()
|
|
338
|
+
.pipe(takeUntilDestroyed(this.#destroyRef))
|
|
339
|
+
.subscribe(() => (this.#dialogRef = null));
|
|
340
|
+
}
|
|
341
|
+
/** Clears the configured endpoint (and with it the whole slot). */
|
|
342
|
+
clearConfig() {
|
|
343
|
+
this.onEndpointChanged(undefined);
|
|
344
|
+
}
|
|
345
|
+
/**
|
|
346
|
+
* A fresh endpoint selection (or a clear) REPLACES the whole slot — sub-config
|
|
347
|
+
* authored against the previous endpoint must not survive the switch, which is
|
|
348
|
+
* exactly what the legacy `ApiCall` row's `clearOnChange` guaranteed.
|
|
349
|
+
*/
|
|
350
|
+
onEndpointChanged(cfg) {
|
|
351
|
+
this.config.set(cfg);
|
|
352
|
+
this.valueChanged.emit(cfg);
|
|
353
|
+
}
|
|
354
|
+
onQueryChanged(template) {
|
|
355
|
+
this.#patch({ queryTemplate: template });
|
|
356
|
+
}
|
|
357
|
+
onHeadersChanged(template) {
|
|
358
|
+
this.#patch({ headerTemplate: template });
|
|
359
|
+
}
|
|
360
|
+
/**
|
|
361
|
+
* Mode toggles never discard either body configuration — `requestBodyMode`
|
|
362
|
+
* alone decides which one the runtime uses (the historical clear-on-toggle
|
|
363
|
+
* destroyed authored work; see the runtime contract on RequestBodyMode).
|
|
364
|
+
*/
|
|
365
|
+
setBodyMode(mode) {
|
|
366
|
+
if ((this.config()?.backEndConfig?.requestBodyMode === 'template' ? 'template' : 'mappedInputs') === mode) {
|
|
367
|
+
return;
|
|
368
|
+
}
|
|
369
|
+
this.#patchBackEnd({ requestBodyMode: mode });
|
|
370
|
+
}
|
|
371
|
+
onMinInputsChanged(minInputs) {
|
|
372
|
+
this.#patchBackEnd({ minimumInputRequired: minInputs });
|
|
373
|
+
}
|
|
374
|
+
onPayloadChanged(template) {
|
|
375
|
+
this.#patchBackEnd({ payloadTemplate: template });
|
|
376
|
+
}
|
|
377
|
+
onRulesChanged(rules) {
|
|
378
|
+
this.#patch({
|
|
379
|
+
valueAccessRules: rules,
|
|
380
|
+
});
|
|
381
|
+
}
|
|
382
|
+
#patch(partial) {
|
|
383
|
+
const current = this.config();
|
|
384
|
+
if (!current)
|
|
385
|
+
return;
|
|
386
|
+
const next = { ...current, ...partial };
|
|
387
|
+
this.config.set(next);
|
|
388
|
+
this.valueChanged.emit(next);
|
|
389
|
+
}
|
|
390
|
+
#patchBackEnd(partial) {
|
|
391
|
+
const current = this.config();
|
|
392
|
+
if (!current)
|
|
393
|
+
return;
|
|
394
|
+
this.#patch({ backEndConfig: { ...current.backEndConfig, ...partial } });
|
|
395
|
+
}
|
|
396
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.12", ngImport: i0, type: ApiEndpointConfigComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
397
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.12", type: ApiEndpointConfigComponent, isStandalone: true, selector: "lib-api-endpoint-config", inputs: { value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, kind: { classPropertyName: "kind", publicName: "kind", isSignal: true, isRequired: false, transformFunction: null }, formInputs: { classPropertyName: "formInputs", publicName: "formInputs", isSignal: true, isRequired: false, transformFunction: null }, postmanCollectionConfig: { classPropertyName: "postmanCollectionConfig", publicName: "postmanCollectionConfig", isSignal: true, isRequired: false, transformFunction: null }, httpGetDataFunction: { classPropertyName: "httpGetDataFunction", publicName: "httpGetDataFunction", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, errors: { classPropertyName: "errors", publicName: "errors", isSignal: true, isRequired: false, transformFunction: null }, id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { valueChanged: "valueChanged" }, host: { classAttribute: "lib-api-endpoint-config" }, ngImport: i0, template: "<div class=\"aec\">\n @if (!hasEndpoint()) {\n <!-- INVITE \u2014 nothing configured yet; the dialog is where setup happens. -->\n <div class=\"aec-invite\">\n <lib-empty-state icon=\"cloud_sync\" [message]=\"inviteMessage()\" />\n <button\n mat-flat-button\n class=\"aec-invite__cta\"\n [disabled]=\"!postmanCollectionConfig() || disabled()\"\n [matTooltip]=\"postmanCollectionConfig() ? '' : 'Configure a Postman collection first'\"\n (click)=\"openDialog()\">\n <mat-icon aria-hidden=\"true\">cloud_sync</mat-icon>\n Set up API call\n </button>\n </div>\n } @else {\n <!-- SUMMARY \u2014 what is configured, at a glance; editing happens in the dialog. -->\n <div class=\"aec-summary\">\n <div class=\"aec-summary__endpoint\">\n <span class=\"aec-summary__method\" [style.color]=\"methodColor()\">\n {{ config()?.httpMethod }}\n </span>\n <div class=\"aec-summary__id\">\n <p class=\"aec-summary__name\">{{ config()?.name }}</p>\n <p class=\"aec-summary__url\" [matTooltip]=\"config()?.httpEndPoint ?? ''\">\n {{ config()?.httpEndPoint }}\n </p>\n </div>\n </div>\n\n <div class=\"aec__chips\">\n @for (item of summaryChips(); track item.label) {\n <span class=\"aec__chip\" [attr.data-state]=\"item.state\">\n <!-- Glyph + colour + border style: state is never colour-only. -->\n {{ item.state === 'done' ? '\u2713 ' : item.state === 'pending' ? '\u2022 ' : '' }}{{ item.label }}\n </span>\n }\n </div>\n\n @if (waitsFor().length > 0) {\n <p class=\"aec__waits\">\n Waits for {{ waitsFor().join(', ') }} before fetching \u2014 the same gate the\n form applies at fill time.\n </p>\n } @else {\n <p class=\"aec__waits\">Fetches as soon as the form loads \u2014 no live fields are bound.</p>\n }\n\n <div class=\"aec-summary__actions\">\n <button mat-flat-button (click)=\"openDialog()\">\n <mat-icon aria-hidden=\"true\">tune</mat-icon>\n {{ disabled() ? 'View setup' : 'Configure' }}\n </button>\n <button\n mat-button\n [disabled]=\"disabled()\"\n matTooltip=\"Remove this API call and start over\"\n (click)=\"clearConfig()\">\n Clear\n </button>\n </div>\n </div>\n }\n\n <lib-error-list [errors]=\"errors() || []\" />\n</div>\n", styles: [".aec{display:flex;flex-direction:column;gap:1rem}.aec-invite{display:flex;flex-direction:column;align-items:flex-start;gap:.75rem}.aec-invite__cta{align-self:stretch}.aec-summary{display:flex;flex-direction:column;gap:.875rem;padding:.875rem 1rem;border:1px solid color-mix(in srgb,var(--mat-sys-on-surface) 12%,transparent);border-radius:10px;background:color-mix(in srgb,var(--mat-sys-on-surface) 3%,transparent)}.aec-summary__endpoint{display:flex;align-items:center;gap:.75rem;min-width:0}.aec-summary__method{flex-shrink:0;font-size:.75rem;font-weight:800;letter-spacing:.06em}.aec-summary__id{flex:1;min-width:0}.aec-summary__name{margin:0;font-size:.875rem;font-weight:600;color:var(--mat-sys-on-surface);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.aec-summary__url{margin:.125rem 0 0;font-family:monospace;font-size:.6875rem;color:var(--mat-sys-on-surface-variant);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.aec-summary__actions{display:flex;align-items:center;gap:.5rem}.aec__chips{display:flex;flex-wrap:wrap;gap:.5rem}.aec__chip{border-radius:6px;padding:.2rem .6rem;font-size:.5625rem;font-weight:700;letter-spacing:.08em;text-transform:uppercase}.aec__chip[data-state=done]{color:var(--mat-sys-primary);background:color-mix(in srgb,var(--mat-sys-primary) 12%,transparent)}.aec__chip[data-state=pending]{color:var(--mat-sys-on-surface-variant);background:color-mix(in srgb,var(--mat-sys-on-surface) 8%,transparent)}.aec__chip[data-state=skip]{color:var(--mat-sys-on-surface-variant);background:transparent;border:1px dashed color-mix(in srgb,var(--mat-sys-on-surface) 25%,transparent)}.aec__waits{margin:0;font-size:.75rem;color:var(--mat-sys-on-surface-variant);max-width:60ch}\n"], dependencies: [{ kind: "component", type: EmptyStateComponent, selector: "lib-empty-state", inputs: ["icon", "message"] }, { kind: "component", type: ErrorListComponent, selector: "lib-error-list", inputs: ["errors"] }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i2.MatButton, selector: " button[matButton], a[matButton], button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button], a[mat-button], a[mat-raised-button], a[mat-flat-button], a[mat-stroked-button] ", inputs: ["matButton"], exportAs: ["matButton", "matAnchor"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i5$1.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
398
|
+
}
|
|
399
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.12", ngImport: i0, type: ApiEndpointConfigComponent, decorators: [{
|
|
400
|
+
type: Component,
|
|
401
|
+
args: [{ selector: 'lib-api-endpoint-config', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.Emulated, host: { class: 'lib-api-endpoint-config' }, imports: [
|
|
402
|
+
EmptyStateComponent,
|
|
403
|
+
ErrorListComponent,
|
|
404
|
+
MatButtonModule,
|
|
405
|
+
MatIconModule,
|
|
406
|
+
MatTooltipModule,
|
|
407
|
+
], template: "<div class=\"aec\">\n @if (!hasEndpoint()) {\n <!-- INVITE \u2014 nothing configured yet; the dialog is where setup happens. -->\n <div class=\"aec-invite\">\n <lib-empty-state icon=\"cloud_sync\" [message]=\"inviteMessage()\" />\n <button\n mat-flat-button\n class=\"aec-invite__cta\"\n [disabled]=\"!postmanCollectionConfig() || disabled()\"\n [matTooltip]=\"postmanCollectionConfig() ? '' : 'Configure a Postman collection first'\"\n (click)=\"openDialog()\">\n <mat-icon aria-hidden=\"true\">cloud_sync</mat-icon>\n Set up API call\n </button>\n </div>\n } @else {\n <!-- SUMMARY \u2014 what is configured, at a glance; editing happens in the dialog. -->\n <div class=\"aec-summary\">\n <div class=\"aec-summary__endpoint\">\n <span class=\"aec-summary__method\" [style.color]=\"methodColor()\">\n {{ config()?.httpMethod }}\n </span>\n <div class=\"aec-summary__id\">\n <p class=\"aec-summary__name\">{{ config()?.name }}</p>\n <p class=\"aec-summary__url\" [matTooltip]=\"config()?.httpEndPoint ?? ''\">\n {{ config()?.httpEndPoint }}\n </p>\n </div>\n </div>\n\n <div class=\"aec__chips\">\n @for (item of summaryChips(); track item.label) {\n <span class=\"aec__chip\" [attr.data-state]=\"item.state\">\n <!-- Glyph + colour + border style: state is never colour-only. -->\n {{ item.state === 'done' ? '\u2713 ' : item.state === 'pending' ? '\u2022 ' : '' }}{{ item.label }}\n </span>\n }\n </div>\n\n @if (waitsFor().length > 0) {\n <p class=\"aec__waits\">\n Waits for {{ waitsFor().join(', ') }} before fetching \u2014 the same gate the\n form applies at fill time.\n </p>\n } @else {\n <p class=\"aec__waits\">Fetches as soon as the form loads \u2014 no live fields are bound.</p>\n }\n\n <div class=\"aec-summary__actions\">\n <button mat-flat-button (click)=\"openDialog()\">\n <mat-icon aria-hidden=\"true\">tune</mat-icon>\n {{ disabled() ? 'View setup' : 'Configure' }}\n </button>\n <button\n mat-button\n [disabled]=\"disabled()\"\n matTooltip=\"Remove this API call and start over\"\n (click)=\"clearConfig()\">\n Clear\n </button>\n </div>\n </div>\n }\n\n <lib-error-list [errors]=\"errors() || []\" />\n</div>\n", styles: [".aec{display:flex;flex-direction:column;gap:1rem}.aec-invite{display:flex;flex-direction:column;align-items:flex-start;gap:.75rem}.aec-invite__cta{align-self:stretch}.aec-summary{display:flex;flex-direction:column;gap:.875rem;padding:.875rem 1rem;border:1px solid color-mix(in srgb,var(--mat-sys-on-surface) 12%,transparent);border-radius:10px;background:color-mix(in srgb,var(--mat-sys-on-surface) 3%,transparent)}.aec-summary__endpoint{display:flex;align-items:center;gap:.75rem;min-width:0}.aec-summary__method{flex-shrink:0;font-size:.75rem;font-weight:800;letter-spacing:.06em}.aec-summary__id{flex:1;min-width:0}.aec-summary__name{margin:0;font-size:.875rem;font-weight:600;color:var(--mat-sys-on-surface);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.aec-summary__url{margin:.125rem 0 0;font-family:monospace;font-size:.6875rem;color:var(--mat-sys-on-surface-variant);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.aec-summary__actions{display:flex;align-items:center;gap:.5rem}.aec__chips{display:flex;flex-wrap:wrap;gap:.5rem}.aec__chip{border-radius:6px;padding:.2rem .6rem;font-size:.5625rem;font-weight:700;letter-spacing:.08em;text-transform:uppercase}.aec__chip[data-state=done]{color:var(--mat-sys-primary);background:color-mix(in srgb,var(--mat-sys-primary) 12%,transparent)}.aec__chip[data-state=pending]{color:var(--mat-sys-on-surface-variant);background:color-mix(in srgb,var(--mat-sys-on-surface) 8%,transparent)}.aec__chip[data-state=skip]{color:var(--mat-sys-on-surface-variant);background:transparent;border:1px dashed color-mix(in srgb,var(--mat-sys-on-surface) 25%,transparent)}.aec__waits{margin:0;font-size:.75rem;color:var(--mat-sys-on-surface-variant);max-width:60ch}\n"] }]
|
|
408
|
+
}], ctorParameters: () => [], propDecorators: { value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }], kind: [{ type: i0.Input, args: [{ isSignal: true, alias: "kind", required: false }] }], formInputs: [{ type: i0.Input, args: [{ isSignal: true, alias: "formInputs", required: false }] }], postmanCollectionConfig: [{ type: i0.Input, args: [{ isSignal: true, alias: "postmanCollectionConfig", required: false }] }], httpGetDataFunction: [{ type: i0.Input, args: [{ isSignal: true, alias: "httpGetDataFunction", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], errors: [{ type: i0.Input, args: [{ isSignal: true, alias: "errors", required: false }] }], id: [{ type: i0.Input, args: [{ isSignal: true, alias: "id", required: false }] }], valueChanged: [{ type: i0.Output, args: ["valueChanged"] }] } });
|
|
409
|
+
|
|
410
|
+
export { ApiEndpointConfigComponent };
|
|
411
|
+
//# sourceMappingURL=ngx-t-forms-api-endpoint-config.component-CZm3Z_7B.mjs.map
|