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

fix(blog): sharing icons should inherit the color #431

Merged
merged 1 commit into from
Aug 12, 2024
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
3 changes: 2 additions & 1 deletion src/components/Blog/ContentsTable/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import { useMemo } from 'react'
import { scrollToElement } from '@/lib/scrollSmooth'
import { Typography } from '@mui/material'
import Link from 'next/link'
import css from '../styles.module.css'

const ContentsTable = ({ content }: { content: ContentfulDocument }) => {
const handleContentTableClick = (e: React.MouseEvent<HTMLAnchorElement>, target: string) => {
Expand All @@ -25,7 +26,7 @@ const ContentsTable = ({ content }: { content: ContentfulDocument }) => {
)

return (
<ul>
<ul className={css.contentsTable}>
{headings.map((heading) => {
const headingKey = kebabCase(heading.id)

Expand Down
5 changes: 4 additions & 1 deletion src/components/Blog/Post/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,9 @@ const BlogPost = ({ blogPost }: { blogPost: BlogPostEntry }) => {

<Sidebar content={content} title={title} authors={authorsList} isPressRelease={isPressRelease} showInXs />

<RichText {...content} />
<div className={css.postBody}>
<RichText {...content} />
</div>
</Grid>
</Grid>

Expand Down Expand Up @@ -111,6 +113,7 @@ const Sidebar = ({
<Grid item xs={12} md={4} className={showInXs ? css.showInXs : css.showInMd}>
<aside className={css.sidebar}>
<ContentsTable content={content} />

<Socials title={title} authors={authors} />

{isPressRelease ? (
Expand Down
6 changes: 4 additions & 2 deletions src/components/Blog/styles.module.css
Original file line number Diff line number Diff line change
Expand Up @@ -77,11 +77,13 @@
font-weight: bold;
}

.content a {
.postBody a,
.contentsTable a {
color: var(--mui-palette-primary-main);
}

.content a:hover {
.postBody a:hover,
.contentsTable a:hover {
text-decoration: underline;
}

Expand Down
Loading