Skip to content

Commit

Permalink
updates for master
Browse files Browse the repository at this point in the history
  • Loading branch information
tmanundercover committed Dec 4, 2023
1 parent a0f664e commit 678014b
Show file tree
Hide file tree
Showing 11 changed files with 46 additions and 113 deletions.
67 changes: 4 additions & 63 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
"@mui/icons-material": "^5.14.18",
"@mui/material": "^5.14.18",
"@mui/styles": "^5.14.18",
"@react-google-maps/api": "^2.19.2",
"@storybook/addon-mdx-gfm": "^7.4.6",
"@storybook/react-webpack5": "^7.4.6",
"@tanstack/react-query": "^4.36.1",
Expand Down
7 changes: 1 addition & 6 deletions sanityIo/schemas/mui/MuiColorPalatte.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
// {value: "DARK_GRAY", title: "Dark Gray"},
// {value: "LIGHTER_GRAY", title: "Lighter Gray"},
// ]

import {ColorListing} from "./ColorListing";

export default {
Expand Down Expand Up @@ -63,12 +64,6 @@ export default {
type: 'string',
options: {list: ColorListing}
},
{
name: 'buttonOutlineColor',
title: 'Button Outline Color',
type: 'string',
options: {list: listing}
},
{
name: 'secondaryTextColor',
title: 'Secondary Text Color',
Expand Down
2 changes: 1 addition & 1 deletion src/components/BusinessCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -324,7 +324,7 @@ const BusinessCard: FunctionComponent<MainMenuProps> = ({anchor, homePage}) => {

</Grid>
<Grid item>
<Typography color='secondary' variant='button'>Contact Info</Typography>
<Typography color='textSecondary' variant='button'>Contact Info</Typography>

</Grid>
</Grid>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,16 +23,15 @@ const FooterMenuContainer: FunctionComponent<IProps> = (props: IProps) => {
const theme = useTheme()

const pageContext = useContext(PageContext)
const customizedThemeContext = useTheme()
const useStyles = makeStyles(({
root: {
color: customizedThemeContext.palette.text.secondary,
color: theme.palette.text.secondary,
}
}))
const classes = useStyles(customizedThemeContext)
const classes = useStyles(theme)

const mdDown = useMediaQuery(customizedThemeContext.breakpoints.down('md'))
const mdUp = useMediaQuery(customizedThemeContext.breakpoints.up('md'))
const mdDown = useMediaQuery(theme.breakpoints.down('md'))
const mdUp = useMediaQuery(theme.breakpoints.up('md'))
return (
<Grid container item className={classes.root}

Expand All @@ -42,15 +41,15 @@ const FooterMenuContainer: FunctionComponent<IProps> = (props: IProps) => {
paddingLeft: "16px",
paddingTop: "16px",
paddingBottom: "16px",
borderLeft: `4px solid ${customizedThemeContext.palette.primary.main}`,
borderLeft: `4px solid ${theme.palette.primary.main}`,
backgroundColor: COLORS.TRANSPARENTERWHITE,
borderRight: `4px solid ${customizedThemeContext.palette.primary.main}`,
} : {}}
borderRight: `4px solid ${theme.palette.primary.main}`,
} : { }}
>
{
props.pageFooterMenu?.subMenus?.map((menuGroup: any, index: number) => {
return (
<Grid key={index} item xs={12} container justifyContent={mdUp?'flex-start':'center'}>
<Grid key={index} item xs={6} sm={12} md={6} container justifyContent={mdUp?'flex-start':'center'}>
<Grid item><FooterMenuGroup menuGroup={menuGroup}/></Grid>
</Grid>
)
Expand Down Expand Up @@ -109,7 +108,7 @@ const FooterMenuContainer: FunctionComponent<IProps> = (props: IProps) => {
<Grid container item xs={12} md={12} sx={{
paddingTop: "4px !important",
marginTop: mdDown ? 4 : 0,
borderTop: "1px solid " + theme.palette.primary.main
borderTop: props.isSocialMediaBlock?"1px solid " + theme.palette.primary.main:"0px solid transparent"
}}>
{mdDown &&
props.isSocialMediaBlock &&
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ export const useStyles = makeStyles((theme: Theme) => ({
interface IProps {
isAppBar?: boolean,
children: any
isEnhanced?: boolean
}

const AppBarWrapper: FunctionComponent<PropsWithChildren<IProps>> = (props: IProps) => {
Expand All @@ -33,7 +34,7 @@ const AppBarWrapper: FunctionComponent<PropsWithChildren<IProps>> = (props: IPro

return (
props.isAppBar ? <AppBar style={{
backgroundColor: `${props.isAppBar ? "black" : "white"}`,
backgroundColor: `${props.isAppBar && props.isEnhanced ? "black" : "white"}`,
}} className={classes.root}>
{props.children}
</AppBar> : <>{props.children}</>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ const EnhancedHeader: FunctionComponent<EnhancedHeaderProps> = (props) => {
borderRadius: 4,
backgroundColor: "black"
}}>
<Header isSearch={props.pageHeader.isSearch} pageHeader={props.pageHeader.headerMenuRef}/>
<Header isSearch={props.pageHeader.isSearch} pageHeader={props.pageHeader.headerMenuRef} isEnhanced={true}/>
</Grid>
</Grid></Grid>
: <></>
Expand Down
3 changes: 2 additions & 1 deletion src/components/templates/mackenzies-mind/header/Header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ export type HeaderProps = {
isAppBar?: boolean
isSearch?: boolean
updateIsLoading?: (value: boolean) => void
isEnhanced?: boolean
}

const Header: FunctionComponent<HeaderProps> = (props) => {
Expand All @@ -21,7 +22,7 @@ const Header: FunctionComponent<HeaderProps> = (props) => {
const mdDown = useMediaQuery(customizedTheme.breakpoints.down('md'))
const [isSearchOpen, setIsSearchOpen] = React.useState<boolean>(false)

return (<AppBarWrapper isAppBar={props.isAppBar}>
return (<AppBarWrapper isAppBar={props.isAppBar} isEnhanced={props.isEnhanced}>
{props.pageHeader?.title ?
<Grid item container
alignContent='center' alignItems='center' style={{height:"100%",paddingLeft:"8px"}}>
Expand Down
4 changes: 2 additions & 2 deletions src/components/templates/mackenzies-mind/header/MainMenu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -104,9 +104,9 @@ const MainMenu: FunctionComponent<MainMenuProps> = ({menu, anchor}) => {
paddingRight: theme.spacing(6),
}}>

<Grid item xs={3}>
<Grid item xs={11}>

<Logo logoImageSrc={menu.logoImageSrc} logoText={'Chow Works'}/>
<Logo logoImageSrc={menu.logoImageSrc} logoText={'James Terrell Singleton'}/>
</Grid>
<Grid item xs={1}><Button onClick={() => {
setIsDrawerOpen(false)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,10 @@ const ResumeBioSection: FunctionComponent<IProps> = (props: IProps) => {
<Grid item xs={9}><Typography noWrap gutterBottom
variant='body1'>{props.homePage.businessContact?.address}</Typography></Grid>
</Grid>
<Grid container item xs={11} sm={12}>
<Grid container item xs={11} sm={12} justifyContent={'center'}>
<SocialMediaBlock
iconColor={theme.palette.primary.main}
isCentered={true}
facebook={props.homePage.businessContact?.facebook}
twitter={props.homePage.businessContact?.twitter}
instagram={props.homePage.businessContact?.instagram}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import React, {FunctionComponent, useContext} from 'react'
import makeStyles from '@mui/styles/makeStyles';
import {Grid, IconButton, PropTypes, ThemeProvider} from '@mui/material';
import {Grid, IconButton, PropTypes, ThemeProvider, useTheme} from '@mui/material';
import {Facebook, GitHub, Instagram, LinkedIn, Twitter} from "@mui/icons-material";
import clsx from "clsx";
import {GridSpacing} from "@mui/material/Grid/Grid";
Expand All @@ -16,6 +16,7 @@ interface IProps {
instagram?: string
linkedIn?: string
github?: string
isCentered?: boolean
color?: PropTypes.Color
bgColor?: boolean
theBackgroundColor?: string
Expand All @@ -25,58 +26,50 @@ interface IProps {

const SocialMediaBlock: FunctionComponent<IProps> = (props: IProps) => {
const customizedThemeContext = useContext(CustomizedThemeContext)
const theme = useTheme()
const useStyles = makeStyles(({
buttonBackground: {
backgroundColor: props.bgColor ? props.theBackgroundColor:customizedThemeContext.customizedTheme.palette.primary.main,
backgroundColor: props.bgColor ? props.theBackgroundColor:theme.palette.primary.main,
borderRadius: 40,
// padding: customizedThemeContext.customizedTheme.spacing(1),
color: props.iconColor ?? customizedThemeContext.customizedTheme.palette.primary.main
// padding: theme.spacing(1),
color: `${props.iconColor ?? theme.palette.primary.main} !important`
},
}))

console.log(props.iconColor)
const classes = useStyles()
return (
<Grid data-testid='social-media-block' item xs={12} container alignItems='center' justifyContent='flex-end'
spacing={props.spacing ? props.spacing : 0} wrap={'nowrap'} >
<Grid data-testid='social-media-block' item xs={12} container alignItems='center' justifyContent={props.isCentered?'center':'flex-end'}
spacing={props.spacing ? props.spacing : 0} wrap={'nowrap'}>
{props.facebook && <Grid item>
<Grid item className={clsx({[classes.buttonBackground]: props.bgColor})}>
<IconButton

color={'inherit'}
className={clsx({[classes.buttonBackground]: props.bgColor})}
href={`https://facebook.com/${props.facebook}`}
size="small"><Facebook/></IconButton>
</Grid>
size="small"><Facebook color={'inherit'}/></IconButton>
</Grid>}
{props.twitter && <Grid item>
<Grid item className={clsx({[classes.buttonBackground]: props.bgColor})}>
<IconButton
color={'inherit'}
className={clsx({[classes.buttonBackground]: props.bgColor})}
href={`https://twitter.com/${props.twitter}`}
size="small"><Twitter/></IconButton>
</Grid>
size="small"><Twitter color={'inherit'}/></IconButton>
</Grid>}
{props.instagram && <Grid item>
<Grid item className={clsx({[classes.buttonBackground]: props.bgColor})}>
<IconButton
color={'inherit'}
className={clsx({[classes.buttonBackground]: props.bgColor})}
href={`https://instagram.com/${props.instagram}`}
size="small"><Instagram/></IconButton>
</Grid>
size="small"><Instagram color={'inherit'}/></IconButton>
</Grid>}
{props.linkedIn && <Grid item>
<Grid item className={clsx({[classes.buttonBackground]: props.bgColor})}>
<IconButton
color={'inherit'}
className={clsx({[classes.buttonBackground]: props.bgColor})}
href={`https://linkedIn.com/in/${props.linkedIn}`}
size="small"><LinkedIn/></IconButton>
</Grid>
size="small"><LinkedIn color={'inherit'}/></IconButton>
</Grid>}
{props.github && <Grid item>
<Grid item className={clsx({[classes.buttonBackground]: props.bgColor})}>
<IconButton
color={'inherit'}
className={clsx({[classes.buttonBackground]: props.bgColor})}
href={`https://github.com/${props.github}`}
size="small"><GitHub/></IconButton>
</Grid>
size="small"><GitHub color={'inherit'}/></IconButton>
</Grid>}
</Grid>

Expand Down

0 comments on commit 678014b

Please sign in to comment.