md: add max-w to paragraphs
This commit is contained in:
1 parent
5129cb36ae
commit
0bd9631fc0
3 files changed
+16
-2
No files matched your search
@@ -92,6 +92,9 @@
|
|||||||
|
|
||||||
export let source: string = ''
|
export let source: string = ''
|
||||||
export let inline: boolean = false
|
export let inline: boolean = false
|
||||||
|
|
||||||
|
options.inline = inline
|
||||||
|
|
||||||
export let noStyle: boolean = false
|
export let noStyle: boolean = false
|
||||||
|
|
||||||
$: tokens = marked.lexer(source)
|
$: tokens = marked.lexer(source)
|
||||||
|
|||||||
@@ -1,3 +1,13 @@
|
|||||||
<p class="leading-[1.5]">
|
<script>
|
||||||
|
import { options } from '../Markdown.svelte'
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<p class="leading-[1.5] {options.inline ? '' : 'max-w'}">
|
||||||
<slot />
|
<slot />
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
|
<style>
|
||||||
|
.max-w {
|
||||||
|
max-width: 80ch;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@@ -186,7 +186,8 @@
|
|||||||
"routes": {
|
"routes": {
|
||||||
"frontpage": {
|
"frontpage": {
|
||||||
"title": "Frontpage",
|
"title": "Frontpage",
|
||||||
"footer": "{{users:number}} active {{users; 1:user; default:users;}}"
|
"footer": "{{users:number}} active {{users; 1:user; default:users;}}",
|
||||||
|
"endFeed": "You have reached the end of {{community_name; undefined:the feed.; default:{{community_name}}.}}"
|
||||||
},
|
},
|
||||||
"modlog": "Modlog",
|
"modlog": "Modlog",
|
||||||
"instances": "Instances",
|
"instances": "Instances",
|
||||||
|
|||||||
Reference in new issue
Block a user