Skip to content

Commit 818c595

Browse files
committed
break word on a and code tags in mdx, fix horizontal scroll in chrome
1 parent 7776c16 commit 818c595

File tree

3 files changed

+10
-3
lines changed

3 files changed

+10
-3
lines changed

package.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,8 @@
2525
"docker:build:push:arm": "docker buildx build -f ./docker/Dockerfile -t nemanjamitic/nemanjam.github.io --build-arg ARG_SITE_URL_ARM64='https://nmc-docker.arm1.nemanjamitic.com' --build-arg ARG_PLAUSIBLE_SCRIPT_URL='https://plausible.arm1.nemanjamitic.com/js/script.js' --build-arg ARG_PLAUSIBLE_DOMAIN='nemanjamitic.com' --platform linux/arm64 --progress=plain --push .",
2626
"docker:build:push:x86": "docker buildx build -f ./docker/Dockerfile -t nemanjamitic/nemanjam.github.io --build-arg ARG_SITE_URL_AMD64='https://nmc-docker.local.nemanjamitic.com' --build-arg ARG_PLAUSIBLE_SCRIPT_URL='https://plausible.arm1.nemanjamitic.com/js/script.js' --build-arg ARG_PLAUSIBLE_DOMAIN='nemanjamitic.com' --platform linux/amd64 --push --progress=plain .",
2727
"docker:push": "docker push nemanjamitic/nemanjam.github.io",
28+
"pi": "yarn build:nginx:pi && yarn deploy:nginx:pi",
29+
"nginx": "yarn build:nginx && yarn deploy:nginx",
2830
"dc:up": "docker compose up --build --force-recreate -d"
2931
},
3032
"dependencies": {

src/content/post/2025/04-02-astro-react-gallery/index.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@ heroAlt: Finished gallery, desktop view.
88
tags:
99
- astro
1010
- react
11-
category: tutorial
11+
category: tutorials
1212
toc: true
13-
draft: true
13+
draft: false
1414
---
1515

1616
import { Image } from 'astro:assets';

src/styles/base/my-prose.css

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,12 @@
1414
@apply prose-h1:font-bold;
1515

1616
/* a */
17-
@apply prose-a:link;
17+
@apply prose-a:link prose-a:break-words;
18+
19+
/* break-words in <a /> and <code /> prevents overflow and horizontal scroll on <body /> in mdx */
20+
21+
/* code */
22+
@apply prose-code:break-words;
1823

1924
/* image */
2025
@apply prose-img:rounded-button;

0 commit comments

Comments
 (0)