
import { createContext, useState, useContext } from '@wordpress/element';

const ResponsiveTabContext = createContext();

export const ResponsiveTabProvider = ({ children }) => {
  const [activeTab, setActiveTab] = useState('pc');

  return (
    <ResponsiveTabContext.Provider value={{ activeTab, setActiveTab }}>
      {children}
    </ResponsiveTabContext.Provider>
  );
};

export const useResponsiveTab = () => useContext(ResponsiveTabContext);