Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve styles #1241

Merged
merged 4 commits into from
Sep 14, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
108 changes: 54 additions & 54 deletions frontend/components/NewLayout/Common/CTAButton.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -43,16 +43,16 @@ const EnhancedMUIButton = styled(ButtonBase)(
justify-content: center;
max-width: 328px;
padding: 13px 16px;

.text {
${fontSize(16, 18)}
letter-spacing: -0.3px;
}

.link-icon {
display: flex;
margin-left: 8px;

svg {
height: 16px;
width: 16px;
Expand All @@ -64,12 +64,12 @@ const EnhancedMUIButton = styled(ButtonBase)(
background-color: ${theme.palette.common.brand.dark};
border: 4px solid ${theme.palette.common.grayscale.white};
color: ${theme.palette.common.grayscale.white};

.link-icon svg {
background-color: ${theme.palette.common.brand.dark};
fill: ${theme.palette.common.grayscale.white};
}

.text {
color: ${theme.palette.common.grayscale.white};
}
Expand All @@ -79,12 +79,12 @@ const EnhancedMUIButton = styled(ButtonBase)(
background-color: ${theme.palette.common.grayscale.white};
border: 4px solid ${theme.palette.common.grayscale.black};
color: ${theme.palette.common.grayscale.black};

.link-icon svg {
background-color: ${theme.palette.common.grayscale.white};
fill: ${theme.palette.common.grayscale.black};
}

.text {
color: ${theme.palette.common.grayscale.black};
}
Expand All @@ -94,205 +94,205 @@ const EnhancedMUIButton = styled(ButtonBase)(
background-color: ${theme.palette.common.grayscale.black};
border: 4px solid ${theme.palette.common.grayscale.white};
color: ${theme.palette.common.grayscale.white};

.link-icon svg {
background-color: ${theme.palette.common.grayscale.black};
fill: ${theme.palette.common.grayscale.white};
}

.text {
color: ${theme.palette.common.grayscale.white};
}

&:hover {
background-color: ${theme.palette.common.brand.active};

.link-icon svg {
background-color: ${theme.palette.common.brand.active};
}
}

&:focus {
background-color: ${theme.palette.common.brand.main};

.link-icon svg {
background-color: ${theme.palette.common.brand.main};
}
}
}

&.blue-background {
background-color: ${theme.palette.common.brand.light};
border: 4px solid ${theme.palette.common.grayscale.white};
color: ${theme.palette.common.grayscale.white};

.link-icon svg {
background-color: ${theme.palette.common.brand.light};
fill: ${theme.palette.common.grayscale.white};
}

.text {
color: ${theme.palette.common.grayscale.white};
}

&:hover {
background-color: ${theme.palette.common.brand.main};

.link-icon svg {
background-color: ${theme.palette.common.brand.main};
}
}

&:focus {
background-color: ${theme.palette.common.brand.active};

.link-icon svg {
background-color: ${theme.palette.common.brand.active};
}
}
}

&.white-background {
background-color: ${theme.palette.common.grayscale.white};
border: 4px solid ${theme.palette.common.brand.light};
color: ${theme.palette.common.brand.light};

.link-icon svg {
background-color: ${theme.palette.common.grayscale.white};
fill: ${theme.palette.common.brand.light};
}

.text {
color: ${theme.palette.common.brand.light};
}

&:hover {
border-color: ${theme.palette.common.brand.active};

.text {
color: ${theme.palette.common.brand.active};
}

.link-icon svg {
fill: ${theme.palette.common.brand.active};
}
}

&:focus {
border-color: ${theme.palette.common.brand.active};

.text {
color: ${theme.palette.common.brand.active};
}

.link-icon svg {
fill: ${theme.palette.common.brand.active};
}
}
}

&.hero-white {
background-color: ${theme.palette.common.brand.light};
color: ${theme.palette.common.grayscale.white};

.link-icon svg {
background-color: ${theme.palette.common.brand.light};
fill: ${theme.palette.common.grayscale.white};
}

.text {
color: ${theme.palette.common.grayscale.white};
}

&:hover {
background-color: ${theme.palette.common.brand.active};

.link-icon svg {
background-color: ${theme.palette.common.brand.active};
}
}

&:focus {
background-color: ${theme.palette.common.brand.active};

.link-icon svg {
background-color: ${theme.palette.common.brand.active};
}
}
}

&.hero-black {
background-color: ${theme.palette.common.grayscale.black};
border: 4px solid ${theme.palette.common.grayscale.white};
color: ${theme.palette.common.grayscale.white};

.link-icon svg {
background-color: ${theme.palette.common.grayscale.black};
fill: ${theme.palette.common.grayscale.white};
}

.text {
color: ${theme.palette.common.grayscale.white};
}

&:hover {
border-color: ${theme.palette.common.brand.soft};

.text {
color: ${theme.palette.common.brand.soft};
}

.link-icon svg {
fill: ${theme.palette.common.brand.soft};
}
}

&:focus {
border-color: ${theme.palette.common.brand.soft};

.text {
color: ${theme.palette.common.brand.soft};
}

.link-icon svg {
fill: ${theme.palette.common.brand.soft};
}
}
}

&.hero-blue {
background-color: ${theme.palette.common.brand.main};
border: 4px solid ${theme.palette.common.grayscale.white};
color: ${theme.palette.common.grayscale.white};

.link-icon svg {
background-color: ${theme.palette.common.brand.main};
fill: ${theme.palette.common.grayscale.white};
}

.text {
color: ${theme.palette.common.grayscale.white};
}

&:hover {
border-color: ${theme.palette.common.brand.soft};

.text {
color: ${theme.palette.common.brand.soft};
}

.link-icon svg {
fill: ${theme.palette.common.brand.soft};
}
}

&:focus {
border-color: ${theme.palette.common.brand.soft};

.text {
color: ${theme.palette.common.brand.soft};
}

.link-icon svg {
fill: ${theme.palette.common.brand.soft};
}
Expand Down
15 changes: 9 additions & 6 deletions frontend/components/NewLayout/Common/Hero.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ const HeroRoot = styled("section")(
content: "";
margin: 0 auto;
display: block;

${theme.breakpoints.up("md")} {
position: absolute;
left: 0;
Expand Down Expand Up @@ -73,7 +73,7 @@ const HeroRoot = styled("section")(
const HeroContainer = styled("div")(
({ theme }) => `
position: relative;

${theme.breakpoints.up("md")} {
display: grid;
position: relative;
Expand Down Expand Up @@ -123,7 +123,7 @@ const HeroImageContainer = styled("div")(
margin: 0;
padding: 0;
position: relative;

figure {
margin: 0;
}
Expand Down Expand Up @@ -154,7 +154,7 @@ const HeroContentContainer = styled("div")(
padding: 24px 1rem 40px;
margin: 0 auto;
width: 100%;

${theme.breakpoints.up("xs")} {
padding: 40px 2rem;
}
Expand Down Expand Up @@ -186,7 +186,7 @@ const HeroContentContainer = styled("div")(
width: 100%;

${theme.breakpoints.up("xs")} {
padding: 24px 2rem 40px;
padding: 24px 2rem 40px;
}
${theme.breakpoints.up("md")} {
order: 2;
Expand Down Expand Up @@ -236,6 +236,9 @@ const HeroContentContainer = styled("div")(
${theme.breakpoints.up(1920)} {
min-height: 675px;
}
${theme.breakpoints.up(7680)} {
min-height: 2700px;
}
}
`,
)
Expand Down Expand Up @@ -299,7 +302,7 @@ const HeroSpacer = styled("div")(

const HeroTitle = styled(Typography)(
({ theme }) => `
hyphens: auto;
hyphens: none;
display: flex;
flex-grow: 1;
flex-shrink: 0;
Expand Down
10 changes: 0 additions & 10 deletions frontend/components/NewLayout/Courses/CourseGrid.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -133,16 +133,6 @@ const ResetFiltersButton = styled(Button)<EnhancedButtonProps>`
font-weight: bold;
border-width: 0.15rem;
max-height: 2.5rem;
/*color: ${({ variant }) =>
variant === "contained" ? "#F5F6F7" : "#378170"};
background-color: ${({ variant }) =>
variant === "contained" ? "#378170" : "#F5F6F7"};

&:hover {
border-width: 0.15rem;
background-color: ${({ variant }) =>
variant === "contained" ? "#378170" : "#F5F6F7"};
}*/
`

const DynamicTagSelectButtons = dynamic(() => import("./TagSelectButtons"), {
Expand Down
Loading