import{createStore}from"@stencil/store";import{checkoutMachine}from"../../../src/components/providers/form-state-provider/checkout-machine";import{__}from"@wordpress/i18n";import{getSerializedState}from"../utils";const{form:form}=getSerializedState(),{state:state,onChange:onChange,on:on,set:set,get:get,dispose:dispose}=createStore({formState:checkoutMachine.initialState,text:{loading:{finalizing:__("Submitting...","surecart"),paying:__("Processing...","surecart"),confirming:__("Finalizing...","surecart"),confirmed:__("Success!","surecart"),redirecting:__("Success! Redirecting...","surecart")},success:{title:__("Thank you!","surecart"),description:__("Your payment was successful. A receipt is on its way to your inbox.","surecart"),button:__("Continue","surecart")}},...form},((e,t,r)=>"formState"===r?e.value!==t.value:JSON.stringify(e)!==JSON.stringify(t)));export default state;export{state,onChange,on,set,get,dispose};