import React, { createContext, useContext } from 'react';
const SuggestionsContext = createContext(null);
export const SuggestionsProvider = ({ children, onOfferClicked, }) => {
    return (React.createElement(SuggestionsContext.Provider, { value: { onOfferClicked } }, children));
};
export const useSuggestionsContext = () => {
    const context = useContext(SuggestionsContext);
    if (!context) {
        throw new Error('useSuggestionsContext must be used within a SuggestionsProvider. ' +
            'Make sure SuggestionCtaWrapper is used inside the Suggestions component.');
    }
    return context;
};
//# sourceMappingURL=SuggestionsContext.js.map