mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-15 04:10:32 +00:00
17 lines
379 B
JavaScript
17 lines
379 B
JavaScript
import React, { createContext, useContext } from 'react';
|
|
|
|
const DrawerContext = createContext();
|
|
|
|
/**
|
|
* Account form provider.
|
|
*/
|
|
function DrawerProvider({ ...props }) {
|
|
const provider = { ...props };
|
|
|
|
return <DrawerContext.Provider value={provider} {...props} />;
|
|
}
|
|
|
|
const useDrawerContext = () => useContext(DrawerContext);
|
|
|
|
export { DrawerProvider, useDrawerContext };
|