import { EventEmitter, OnInit } from '@angular/core'; import { FormControl } from '@angular/forms'; import { RequestTypeConfig } from '../../../services/requests/types'; import { ButtonMetadata, InputOption, InputType } from '../../types'; import { EmptyStateMetadata } from '../../molecules/empty-state/types'; import { SurveyResponseMetadata, SurveyResponseSubmitEvent } from './types'; import { FormMetadata, FormSubmit } from '../../types'; import * as i0 from "@angular/core"; /** * val-survey-response * * Toma una encuesta (`RequestTypeConfig` con `Type: "survey:"`, ADR-092) * y la presenta como formulario de respuesta — el organism que un visitante * ve al abrir el link de una encuesta. Self-contained, igual que * `val-content-reaction`/`val-access-request-view`: lee el tipo, arma el * formulario, envía la respuesta, sin que el consumer tenga que orquestar * nada de eso. * * Solo lee tipos `visibility: 'PUBLIC'` (vía `getPublicRequestType`, sin * auth) — es el caso de uso que describe el ADR (link enviado a compradores, * que pueden no tener cuenta). Encuestas AUTHENTICATED/ORG/INTERNAL están * fuera de alcance de este componente por ahora. * * Cada pregunta se renderiza mediante `val-form`, que conoce el catálogo * respondible de encuestas: texto, opciones, booleanos, fecha, rating y number * picker. Este componente solo decide el flujo público, identidad opcional, * pasos por sección y envío de respuestas. */ export declare class SurveyResponseComponent implements OnInit { props: SurveyResponseMetadata; readonly submitted: EventEmitter; private formComponent?; private readonly i18n; private readonly auth; private readonly requests; private readonly errors; private readonly formSchemas; readonly emojiType = "EMOJI_RATING"; readonly selectType = InputType.SELECT; readonly loading: import("@angular/core").WritableSignal; readonly loadError: import("@angular/core").WritableSignal; readonly sent: import("@angular/core").WritableSignal; readonly sending: import("@angular/core").WritableSignal; readonly typeConfig: import("@angular/core").WritableSignal; readonly alreadyAnswered: import("@angular/core").WritableSignal; readonly responseStep: import("@angular/core").WritableSignal; readonly responseValues: import("@angular/core").WritableSignal>; readonly nameControl: FormControl; readonly emailControl: FormControl; private form; constructor(); ngOnInit(): Promise; private configureIdentity; private buildCompatibilityForm; readonly formProps: import("@angular/core").Signal; readonly responseSections: import("@angular/core").Signal; /** Preguntas ordenadas, expuestas para tests/hosts que inspeccionan el schema resuelto. */ readonly questions: import("@angular/core").Signal; hasResponseSteps(): boolean; private sectionWithStoredValues; questionControl(name: string): FormControl; optionsOf(q: { options?: { id: string; name: string; order?: number; }[]; }): InputOption[]; inputTypeOf(type: string): 'text' | 'email' | 'number' | 'tel'; private surveySchemaForForm; /** Puede responder sin sesión si el tipo lo permite; si no, hace falta login. */ readonly canRespond: import("@angular/core").Signal; /** * El tipo puede seguir exigiendo identidad al anónimo (`skipSubmitterIdentity` * ausente o false): es el caso de las solicitudes de Chesed/Okhelia, donde * saber quién pidió ES el punto. Una encuesta pone el flag en true y entonces * no se pide nada — si la organización necesita el correo de quien responde, * lo agrega como una PREGUNTA de tipo Correo. Eso es configuración de la * encuesta; el formulario no cobra peaje por su cuenta. */ needsIdentity(): boolean; private needsIdentityFor; readonly submitState: import("@angular/core").Signal<"ENABLED" | "WORKING">; readonly multiSelectError: import("@angular/core").WritableSignal; private readonly optionControlMemo; optionControl(name: string, optionId: string): FormControl; markInvalid(): void; submit(event?: FormSubmit): Promise; nextResponseStep(): void; previousResponseStep(): void; responseBackProps(): ButtonMetadata; responseNextProps(): ButtonMetadata; responseSubmitProps(): ButtonMetadata; private hasMissingRequiredMultiSelect; readonly alreadyAnsweredState: import("@angular/core").Signal; readonly sentState: import("@angular/core").Signal; readonly successPresentation: import("@angular/core").Signal<{ title: string; message: string; imageUrl: string; closeNote: string; }>; readonly loadErrorState: import("@angular/core").Signal; readonly loginRequiredState: import("@angular/core").Signal; t(key: string): string; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; }