require("./chunk-9hOWP6kD.cjs");
let react = require("react");
//#region ../core/src/pay-api-context.ts
const PayApiContext = (0, react.createContext)(null);
const PayApiProvider = PayApiContext.Provider;
function usePayApi() {
	const api = (0, react.useContext)(PayApiContext);
	if (!api) throw new Error("usePayApi must be used within a PayApiProvider");
	return api;
}
//#endregion
//#region ../../platform/address-autocomplete/src/api-context.ts
const AddressAutocompleteApiContext = (0, react.createContext)(null);
const AddressAutocompleteApiProvider = AddressAutocompleteApiContext.Provider;
function useAddressAutocompleteApi() {
	const api = (0, react.useContext)(AddressAutocompleteApiContext);
	if (!api) throw new Error("useAddressAutocompleteApi must be used within an AddressAutocompleteApiProvider");
	return api;
}
//#endregion
Object.defineProperty(exports, "AddressAutocompleteApiProvider", {
	enumerable: true,
	get: function() {
		return AddressAutocompleteApiProvider;
	}
});
Object.defineProperty(exports, "PayApiProvider", {
	enumerable: true,
	get: function() {
		return PayApiProvider;
	}
});
Object.defineProperty(exports, "useAddressAutocompleteApi", {
	enumerable: true,
	get: function() {
		return useAddressAutocompleteApi;
	}
});
Object.defineProperty(exports, "usePayApi", {
	enumerable: true,
	get: function() {
		return usePayApi;
	}
});

//# sourceMappingURL=api-context-BkBvyFVK.cjs.map