import { createContext, useContext, ReactNode } from 'react';

interface LayoutSubheaderContextValue {
  setSubheader: (node: ReactNode) => void;
}

export const LayoutSubheaderContext = createContext<LayoutSubheaderContextValue>({
  setSubheader: () => {},
});

export function useSubheader() {
  return useContext(LayoutSubheaderContext);
}
