Skip to content

Commit

Permalink
StoryBook updates
Browse files Browse the repository at this point in the history
  • Loading branch information
tmanundercover committed Oct 2, 2023
1 parent 2bdc6c5 commit 94be48a
Show file tree
Hide file tree
Showing 67 changed files with 6,893 additions and 818 deletions.
3 changes: 2 additions & 1 deletion .storybook/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@ const config: StorybookConfig = {
"@storybook/addon-essentials",
"@storybook/preset-create-react-app",
'storybook-addon-material-ui',
"@storybook/addon-mdx-gfm"
"@storybook/addon-mdx-gfm",
'@storybook/addon-styling'
],
};

Expand Down
60 changes: 44 additions & 16 deletions .storybook/preview.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,23 @@
import {muiTheme} from "storybook-addon-material-ui";
import MackenziesMindTheme from "../src/theme/DigitalResumeTheme";
import DigitalResumeTheme from "../src/theme/DigitalResumeTheme";
import {QueryClient, QueryClientProvider} from "react-query";
import {BrowserRouter} from "react-router-dom";
import {BrowserRouter, Navigate, Route, Routes} from "react-router-dom";
import React from 'react';

import {Preview} from '@storybook/react';
import {CssBaseline, Grid, MuiThemeProvider} from "@material-ui/core";
import WebDevSiteTheme from "../src/theme/WebDevSiteTheme";
import TransformHWTheme from "../src/theme/TransformHWTheme";
import {withThemeFromJSXProvider} from "@storybook/addon-styling";
import PageProvider from "../src/components/page-context/PageProvider";
import HomePageResumeData from "../src/stories/data/HomePageData";
import ModalProvider from "../src/components/snackbar-context/ModalProvider";
import SnackbarProvider
from "../src/components/modal-context/SnackbarProvider";
import MediaQueriesProvider from "../src/components/media-queries-context/MediaQueriesProvider";
import AmenityProvider from "../src/components/amenity-context/AmenityProvider";
import PageMux from "../src/components/mackenzies-mind/pages/PageMux";
import FourOhFour from "../src/components/transform-hw/pages/error-page/FourOhFour";
import {RoutesEnum} from "../src/App";
//
// export const parameters = {
// actions: {argTypesRegex: "^on[A-Z].*"},
Expand Down Expand Up @@ -31,23 +47,35 @@ const mockedQueryClient = new QueryClient({
// muiTheme([MackenziesMindTheme]),
// ];


import React from 'react';

import { Preview } from '@storybook/react';
import {MuiThemeProvider} from "@material-ui/core";
import DigitalResumeTheme from "../src/theme/DigitalResumeTheme";

const preview: Preview = {
decorators: [
(Story) => (
<QueryClientProvider client={mockedQueryClient}>
<BrowserRouter>
<MuiThemeProvider theme={DigitalResumeTheme}><Story/></MuiThemeProvider>
</BrowserRouter>
</QueryClientProvider>
<BrowserRouter>
<QueryClientProvider client={mockedQueryClient}>
<SnackbarProvider>
<MediaQueriesProvider>
<ModalProvider>
<PageProvider page={HomePageResumeData}>
<AmenityProvider>
<Story />
</AmenityProvider>
</PageProvider>
</ModalProvider>
</MediaQueriesProvider>
</SnackbarProvider>
</QueryClientProvider>
</BrowserRouter>
),

withThemeFromJSXProvider({
themes: {
webDev: WebDevSiteTheme,
resume: DigitalResumeTheme,
thw: TransformHWTheme
},
Provider: MuiThemeProvider,
GlobalStyles: CssBaseline,
})
// muiTheme([DigitalResumeTheme, WebDevSiteTheme, TransformHWTheme])
],
};

Expand Down
1 change: 1 addition & 0 deletions functions/src/groqQueries.ts
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,7 @@ const HOMEPAGE = `_type,
${SERVICE}
},
"serviceAmenities": serviceAmenities[]->,
"prosList": prosList[]->,
"skillsets": skillsets[]{
...,
"skills": skills[]->{
Expand Down
Loading

0 comments on commit 94be48a

Please sign in to comment.