completed project, base structure to create more templates

This commit is contained in:
Amruth Pillai
2020-03-25 16:38:36 +05:30
parent d5dcd38edb
commit 7bec7b5d49
7 changed files with 54 additions and 20 deletions

View File

@ -14,8 +14,8 @@ const RightSidebar = () => {
const { state, dispatch } = context;
const { data, theme } = state;
const [currentTab, setCurrentTab] = useState('Actions');
const onChange = (key, value) =>
const [currentTab, setCurrentTab] = useState('Layout');
const onChange = (key, value) => {
dispatch({
type: 'on_input',
payload: {
@ -24,6 +24,9 @@ const RightSidebar = () => {
},
});
dispatch({ type: 'save_data' });
};
const renderTabs = () => {
switch (currentTab) {
case 'Layout':