Fix: Code block line numbers styling issue (#820)
- Resolved the issue where enabling line numbers in code blocks caused the content to escape the code block border.
- Added necessary CSS to ensure the code block border doe not extends to contain the entire content when line numbers are enabled.
- Tested with reproduction steps to confirm the fix works across various scenarios.
- additionally fixed long string overflow that causes mobile version stretch
Fixes #820
| | |
| | | @media only screen and (max-width: 768px) { |
| | | margin: 1.5rem 0 1.5rem 0; |
| | | } |
| | | white-space: pre-wrap; |
| | | white-space: -moz-pre-wrap; |
| | | white-space: -pre-wrap; |
| | | white-space: -o-pre-wrap; |
| | | word-wrap: break-word; |
| | | } |
| | | |
| | | h1, |
| | |
| | | margin: 2rem 0 2rem; |
| | | padding: 1rem; |
| | | border-radius: 1rem; |
| | | overflow-x: auto; |
| | | } |
| | | } |
| | | |
| | |
| | | |
| | | .fas { |
| | | font-weight: 900; |
| | | } |
| | | } |