From f22aad7bae42fe0c516bd59e3999be07cef292b5 Mon Sep 17 00:00:00 2001 From: Rizwan Memon Date: Sun, 14 Mar 2021 17:40:55 +0530 Subject: [PATCH 1/2] Removed errors from development console --- .storybook/main.js | 13 +++++-------- .storybook/preview.js | 3 +-- README.md | 2 +- src/pages/CoursePageViewWithVideo/index.js | 6 +----- src/theme/index.js | 5 +++-- 5 files changed, 11 insertions(+), 18 deletions(-) diff --git a/.storybook/main.js b/.storybook/main.js index cd747593..e6d12c29 100644 --- a/.storybook/main.js +++ b/.storybook/main.js @@ -1,11 +1,8 @@ module.exports = { - "stories": [ - "../src/**/*.stories.mdx", - "../src/**/*.stories.@(js|jsx|ts|tsx)" - ], - "addons": [ + stories: ["../src/**/*.stories.mdx", "../src/**/*.stories.@(js|jsx|ts|tsx)"], + addons: [ "@storybook/addon-links", "@storybook/addon-essentials", - "@storybook/preset-create-react-app" - ] -} \ No newline at end of file + "@storybook/preset-create-react-app", + ], +}; diff --git a/.storybook/preview.js b/.storybook/preview.js index 5d00c021..57887cd3 100644 --- a/.storybook/preview.js +++ b/.storybook/preview.js @@ -1,4 +1,3 @@ - export const parameters = { actions: { argTypesRegex: "^on[A-Z].*" }, -} \ No newline at end of file +}; diff --git a/README.md b/README.md index d930cd7a..c09a10f0 100644 --- a/README.md +++ b/README.md @@ -144,8 +144,8 @@ Skip the yarn part and proceed to the Pushing the changes section [here](#-pushi Your app is ready to be deployed! 5. See the section about [deployment](https://facebook.github.io/create-react-app/docs/deployment) for more information. - ### 🚩 Running storybook : + 1. Run the command `npm run storybook` 2. wait on `localhost:6000` 3. write stories for component in `stories` folder under `src` folder. diff --git a/src/pages/CoursePageViewWithVideo/index.js b/src/pages/CoursePageViewWithVideo/index.js index 5a62301b..1951e80c 100644 --- a/src/pages/CoursePageViewWithVideo/index.js +++ b/src/pages/CoursePageViewWithVideo/index.js @@ -108,11 +108,7 @@ function TabPanel(props) { aria-labelledby={`full-width-tab-${index}`} {...other} > - {value === index && ( - - {children} - - )} + {value === index && {children}} ); } diff --git a/src/theme/index.js b/src/theme/index.js index 8ee16fdf..f25e8ba9 100644 --- a/src/theme/index.js +++ b/src/theme/index.js @@ -1,7 +1,8 @@ import _ from "lodash"; import { colors, createMuiTheme, responsiveFontSizes } from "@material-ui/core"; import typography from "./typography"; -import { softShadows } from "./shadows"; +//! Adds a error Material-UI: This elevation `4` is not implemented. +// import { softShadows } from "./shadows"; const baseConfig = { direction: "ltr", @@ -60,7 +61,7 @@ const themeConfig = { secondary: colors.blueGrey[600], }, }, - shadows: softShadows, + // shadows: softShadows, }; const createTheme = () => { From b61bf03a60c6c1f2153a67407c7e74f2b37b3d62 Mon Sep 17 00:00:00 2001 From: Rizwan Memon Date: Mon, 15 Mar 2021 17:08:04 +0530 Subject: [PATCH 2/2] Revert: Shadow applied again --- src/theme/index.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/theme/index.js b/src/theme/index.js index f25e8ba9..8ee16fdf 100644 --- a/src/theme/index.js +++ b/src/theme/index.js @@ -1,8 +1,7 @@ import _ from "lodash"; import { colors, createMuiTheme, responsiveFontSizes } from "@material-ui/core"; import typography from "./typography"; -//! Adds a error Material-UI: This elevation `4` is not implemented. -// import { softShadows } from "./shadows"; +import { softShadows } from "./shadows"; const baseConfig = { direction: "ltr", @@ -61,7 +60,7 @@ const themeConfig = { secondary: colors.blueGrey[600], }, }, - // shadows: softShadows, + shadows: softShadows, }; const createTheme = () => {