Skip to content

Commit

Permalink
Update glossarie's heading style
Browse files Browse the repository at this point in the history
  • Loading branch information
RodrigoEC committed Aug 26, 2024
1 parent 5d5ed60 commit 40d3016
Showing 1 changed file with 6 additions and 10 deletions.
16 changes: 6 additions & 10 deletions sections/Glossary/GlossaryPost.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -34,17 +34,16 @@ interface Props {
disclaimer?: Disclaimer;
}

const PARAGRAPH_STYLES = "[&_p]:leading-[150%] [&_*]:mb-4 text-white";
const PARAGRAPH_STYLES = "[&_p]:leading-[150%] [&_*]:mb-4 text-[#cdcdcd]";
const HEADING_STYLES =
"[&>h1]:text-4xl [&>h1]:my-6 [&>h1]:font-bold [&>h2]:text-3xl [&>h2]:my-6 [&>h2]:font-bold [&>h1]:text-2xl [&>h1]:my-6 [&>h1]:font-bold [&>h4]:text-xl [&>h4]:my-6 [&>h4]:font-bold [&>h5]:text-lg [&>h5]:my-6 [&>h5]:font-bold [&>h6]:text-white [&>h6]:my-6 [&>h6]:font-bold";
"[&>h1]:text-white [&>h1]:text-4xl [&>h1]:my-6 [&>h1]:font-bold [&>h2]:text-white [&>h2]:text-3xl [&>h2]:my-6 [&>h2]:font-bold [&>h1]:text-2xl [&>h1]:my-6 [&>h1]:font-bold [&>h3]:text-white [&>h3]:text-2xl [&>h3]:font-bold [&>h4]:text-xl [&>h4]:text-white [&>h4]:my-6 [&>h4]:font-bold [&>h5]:text-lg [&>h5]:text-white [&>h5]:my-6 [&>h5]:font-bold [&>h6]:text-white [&>h6]:my-6 [&>h6]:font-bold";
const CODE_BLOCK_STYLES =
"[&>pre]:bg-gray-100 [&>pre]:text-white [&>pre]:p-4 [&>pre]:font-mono [&>pre]:text-sm [&>pre]:border [&>pre]:rounded-md [&>pre]:overflow-x-auto [&>code]:block [&>code]:w-full";
const IMAGE_STYLES = "[&_img]:rounded-2xl [&_img]:w-full [&_img]:my-12";
const BLOCKQUOTE_STYLES =
"[&>blockquote]:my-6 [&>blockquote]:border-l-2 [&>blockquote]:border-black [&>blockquote]:text-xl [&>blockquote]:italic [&>blockquote]:pl-6";

const CONTENT_STYLES =
` ${PARAGRAPH_STYLES} ${HEADING_STYLES} ${CODE_BLOCK_STYLES} ${IMAGE_STYLES} ${BLOCKQUOTE_STYLES}`;
const CONTENT_STYLES = ` ${PARAGRAPH_STYLES} ${HEADING_STYLES} ${CODE_BLOCK_STYLES} ${IMAGE_STYLES} ${BLOCKQUOTE_STYLES}`;

const DEFAULT_AVATAR =
"https://ozksgdmyrqcxcwhnbepg.supabase.co/storage/v1/object/public/assets/1527/7286de42-e9c5-4fcb-ae8b-b992eea4b78e";
Expand Down Expand Up @@ -93,9 +92,7 @@ export function NextPost({
return (
<a
href={`/glossary/${href}`}
class={`group flex gap-2 md:gap-6 flex-col-reverse ${
styles[type].container
} md:items-center`}
class={`group flex gap-2 md:gap-6 flex-col-reverse ${styles[type].container} md:items-center`}
>
<div class="p-4 rounded-lg text-white border border-[#162121] group-hover:border-[#FFFFFF40] bg-[#0D1717] transition duration-300">
<Icon id="ArrowRight" size={16} class={`${styles[type].icon}`} />
Expand Down Expand Up @@ -139,7 +136,7 @@ function Menu({
{/* <Search /> */}
{posts
?.filter(
(post) => getFirstLetter(post?.title) === getFirstLetter(title),
(post) => getFirstLetter(post?.title) === getFirstLetter(title)
)
.map((post) => (
<GlossaryItem
Expand Down Expand Up @@ -249,8 +246,7 @@ export default function GlossaryPost({ slug, posts, CTA, disclaimer }: Props) {
dangerouslySetInnerHTML={{
__html: content,
}}
>
</div>
></div>

<div class="flex flex-col gap-2 w-full border border-[#162121] bg-[#0D1717] rounded-xl text-white font-semibold p-6">
<span class="text-xl">{disclaimer?.title}</span>
Expand Down

0 comments on commit 40d3016

Please sign in to comment.