import Filter from './filter'; import {FC, useEffect} from 'react'; import {context, pIdContext, pageContext, useContextReducer, usePIdContextState} from './context'; import TableList from './table'; import {ChildrenFC} from '@utils'; import {PageProvider} from '@components'; type Props = { id: string, onClose: () => void, }; const MenuProvider: ChildrenFC> = function({children, onClose}) { const state = useContextReducer(onClose); const {Provider} = context; return {children}; }; const PIdProvider: ChildrenFC> = function({children, id}) { const state = usePIdContextState(id); const {Provider} = pIdContext; const dispatch = state[1]; useEffect(function() { dispatch(id); }, [dispatch, id]); return {children}; }; const ChildMenu: FC = function({id, onClose}) { return (
); }; export default ChildMenu;