import { LoopReducer , Loop } from 'redux-loop' ; import { collectBirthCertificateFormSection , collectDeathCertificateFormSection } from '@client/forms/certificate/fieldDefinitions/collectorSection' ; import { Action } from 'redux' ; import { IFormSection } from '@client/forms' ; import { paymentFormSection } from '@client/forms/certificate/fieldDefinitions/payment-section' ; import { certificatePreview } from '@client/forms/certificate/fieldDefinitions/preview-section' ; const initialState = { collectBirthCertificateForm : collectBirthCertificateFormSection , collectDeathCertificateForm : collectDeathCertificateFormSection , paymentForm : paymentFormSection , certificatePreviewForm : certificatePreview } ; export interface IPrintFormState { collectBirthCertificateForm : IFormSection ; collectDeathCertificateForm : IFormSection ; paymentForm : IFormSection ; certificatePreviewForm : IFormSection ; } export const printReducer = ( state = initialState , action ) : IPrintFormState | Loop < IPrintFormState , Action > => { switch ( action . type ) { default : return state ; } } ;