import { Country, CustomerUpdateInput } from '@jetshop/core/types'; import { FormikProps } from 'formik'; import { DocumentNode } from 'graphql'; import React, { ReactNode } from 'react'; import { EnhancedCustomerField } from './signup-context'; export interface CustomerUpdateFormRenderPropsField { inputProps: { [key in keyof EnhancedCustomerField]: any; }; } export type CustomerUpdateFormRenderProps = FormikProps & { billingAddressFields: CustomerUpdateFormRenderPropsField[]; deliveryAddressFields: CustomerUpdateFormRenderPropsField[]; setCountryCode: (countryCode: string) => void; countries: Country[]; pidField: { [key in keyof EnhancedCustomerField]: any; }; }; export interface CustomerUpdateFormProps { deliveryAddressId: number; onSubmitSuccess?: () => void; onSubmit?: () => void; render: (props: CustomerUpdateFormRenderProps) => ReactNode; /** * The query that will be used for fetching the updated customer fields, once * the mutation succeeds */ customerProfileQuery: DocumentNode; } export declare function getBillingAddressFieldsToRender(fields: EnhancedCustomerField[]): CustomerUpdateFormRenderPropsField[]; export declare function getDeliveryAddressFieldsToRender(fields: EnhancedCustomerField[], index: number): CustomerUpdateFormRenderPropsField[]; export declare const CustomerUpdateFormProvider: React.FunctionComponent;