Fix width of pre element
This commit is contained in:
@@ -901,7 +901,7 @@ export const toHtml = (markdown: string, assetDirectory: string): string => {
|
|||||||
// .filter((s) => !(s instanceof JustALineBreak))
|
// .filter((s) => !(s instanceof JustALineBreak))
|
||||||
.map((s) => s.render())
|
.map((s) => s.render())
|
||||||
.join("");
|
.join("");
|
||||||
return `<div>${html}</div>`;
|
return `<div class="content">${html}</div>`;
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -23,12 +23,16 @@
|
|||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
flex: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
pre {
|
pre {
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
border: 1px solid #00FFFF;
|
border: 1px solid #00FFFF;
|
||||||
padding: 1rem;
|
padding: 1rem;
|
||||||
|
width: fit-content;
|
||||||
|
max-width: 100%;
|
||||||
|
white-space: normal;
|
||||||
}
|
}
|
||||||
|
|
||||||
img {
|
img {
|
||||||
@@ -121,6 +125,12 @@
|
|||||||
a {
|
a {
|
||||||
color: #00FFFF;
|
color: #00FFFF;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.content {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
flex: 1;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user