Skip to content

Commit

Permalink
Merge pull request #1046 from basedosdados/chore/blog-ajusts
Browse files Browse the repository at this point in the history
Chore/blog ajusts
  • Loading branch information
AldemirLucas authored Dec 9, 2024
2 parents 1736169 + 85f0000 commit b2d957d
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 4 deletions.
7 changes: 5 additions & 2 deletions next/components/organisms/Blog/Slug.js
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ function CodeBlock({ children }) {
: { value: code };

return (
<Box marginY={"1rem"} borderRadius={"8px"} backgroundColor={"#282b2e"}>
<Box marginY={"1rem"} borderRadius={"8px"} backgroundColor="#252A32">
<Box display={"flex"} alignItems={"center"} padding={"0 0.5rem"}>
{language ? (
<Text
Expand Down Expand Up @@ -275,7 +275,10 @@ export function Toc({ headings }) {
href={`#${id}`}
fontFamily="Roboto"
display="block"
_hover={{ textDecoration: "none" }}
_hover={{
textDecoration: "none",
opacity: 0.8
}}
fontWeight="500"
fontSize="14px"
lineHeight="20px"
Expand Down
26 changes: 24 additions & 2 deletions next/pages/blog/[slug].js
Original file line number Diff line number Diff line change
Expand Up @@ -126,9 +126,29 @@ export default function Post({ slug, mdxSource, headings }) {
padding="24px 0 48px"
gap="8px"
>
{t("blog")} <Text color="#71757A">/</Text>
<Link
href="/blog"
fontSize="14px"
fontWeight="400"
lineHeight="20px"
color="#0068C5"
_hover={{
color: "#0057A4"
}}
>{t("blog")}</Link> <Text color="#71757A">/</Text>
{frontmatter.categories.map((elm) => {
return <Text>{categories?.[elm] || t(elm)}</Text>
return (
<Link
href={`/blog?category=${elm}`}
fontSize="14px"
fontWeight="400"
lineHeight="20px"
color="#0068C5"
_hover={{
color: "#0057A4"
}}
>{categories?.[elm] || t(elm)}</Link>
)
})}
</Text>

Expand Down Expand Up @@ -165,6 +185,7 @@ export default function Post({ slug, mdxSource, headings }) {
fontWeight="400"
lineHeight="24px"
color="#252A32"
marginTop="24px"
>{t("noticedSomething")} </Text>
<Link
href={`https://github.com/basedosdados/website/edit/main/next/blog/${slug}.md`}
Expand All @@ -177,6 +198,7 @@ export default function Post({ slug, mdxSource, headings }) {
color: "#0057A4"
}}
>{t("contributeToBD")}</Link>
<Box id="hotjarSurveyBlog"/>
</Box>
</Box>
<Box
Expand Down

0 comments on commit b2d957d

Please sign in to comment.