import { ContactForm } from "../../../../storefront-models/src"; /** * Initializes the contact form with default field states for first name, last name, email, phone, and message, including localized labels and placeholders. * * @ai-category ContactForm, Form, Validation * @ai-related setContactFormFirstName, setContactFormLastName, setContactFormEmail, setContactFormPhone, setContactFormMessage, submitContactForm * * @param contactForm - The ContactForm instance to initialize. * @returns void * * @example * ```typescript * import { initContactForm } from "@ikas/bp-storefront"; * initContactForm(contactForm); * ``` */ export declare function initContactForm(contactForm: ContactForm): void; /** * Sets the first name field on the contact form and re-validates if the form has already been submitted. * * @ai-category ContactForm, Form * @ai-related setContactFormLastName, setContactFormEmail, setContactFormPhone, setContactFormMessage, initContactForm, submitContactForm * * @param contactForm - The ContactForm instance to update. * @param value - The new first name value. * @returns void * * @example * ```typescript * import { setContactFormFirstName } from "@ikas/bp-storefront"; * setContactFormFirstName(contactForm, "Jane"); * ``` */ export declare function setContactFormFirstName(contactForm: ContactForm, value: string): void; /** * Sets the last name field on the contact form and re-validates if the form has already been submitted. * * @ai-category ContactForm, Form * @ai-related setContactFormFirstName, setContactFormEmail, setContactFormPhone, setContactFormMessage, initContactForm, submitContactForm * * @param contactForm - The ContactForm instance to update. * @param value - The new last name value. * @returns void * * @example * ```typescript * import { setContactFormLastName } from "@ikas/bp-storefront"; * setContactFormLastName(contactForm, "Doe"); * ``` */ export declare function setContactFormLastName(contactForm: ContactForm, value: string): void; /** * Sets the email field on the contact form and re-validates if the form has already been submitted. * * @ai-category ContactForm, Form * @ai-related setContactFormFirstName, setContactFormLastName, setContactFormPhone, setContactFormMessage, initContactForm, submitContactForm * * @param contactForm - The ContactForm instance to update. * @param value - The new email value. * @returns void * * @example * ```typescript * import { setContactFormEmail } from "@ikas/bp-storefront"; * setContactFormEmail(contactForm, "user@example.com"); * ``` */ export declare function setContactFormEmail(contactForm: ContactForm, value: string): void; /** * Sets the phone field on the contact form and re-validates if the form has already been submitted. * * @ai-category ContactForm, Form * @ai-related setContactFormFirstName, setContactFormLastName, setContactFormEmail, setContactFormMessage, initContactForm, submitContactForm * * @param contactForm - The ContactForm instance to update. * @param value - The new phone number value. * @returns void * * @example * ```typescript * import { setContactFormPhone } from "@ikas/bp-storefront"; * setContactFormPhone(contactForm, "+1234567890"); * ``` */ export declare function setContactFormPhone(contactForm: ContactForm, value: string): void; /** * Sets the message field on the contact form and re-validates if the form has already been submitted. * * @ai-category ContactForm, Form * @ai-related setContactFormFirstName, setContactFormLastName, setContactFormEmail, setContactFormPhone, initContactForm, submitContactForm * * @param contactForm - The ContactForm instance to update. * @param value - The new message value. * @returns void * * @example * ```typescript * import { setContactFormMessage } from "@ikas/bp-storefront"; * setContactFormMessage(contactForm, "I have a question about my order."); * ``` */ export declare function setContactFormMessage(contactForm: ContactForm, value: string): void; /** * Validates and submits the contact form, sending the first name, last name, email, phone, message, and current page URL to the server. * * @ai-category ContactForm, Form, Validation * @ai-related initContactForm, setContactFormFirstName, setContactFormLastName, setContactFormEmail, setContactFormPhone, setContactFormMessage * * @param contactForm - The ContactForm instance to validate and submit. * @returns A promise that resolves to `true` if the submission succeeded, or `false` if validation failed or the save request failed. * * @example * ```typescript * import { submitContactForm } from "@ikas/bp-storefront"; * const success = await submitContactForm(contactForm); * if (success) { * console.log("Contact form submitted successfully."); * } * ``` */ export declare function submitContactForm(contactForm: ContactForm): Promise;