enhance codeblock look
This commit is contained in:
parent
0fdfbe1dae
commit
f99eca0e47
@ -74,6 +74,11 @@ button {
|
|||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.ovfl-bw {
|
||||||
|
overflow-wrap: break-word;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
#post-text, button {
|
#post-text, button {
|
||||||
color: var(--text-color);
|
color: var(--text-color);
|
||||||
border-radius: 5px;
|
border-radius: 5px;
|
||||||
|
@ -43,7 +43,8 @@ function filterPost(text){
|
|||||||
if(cdblregex.test(match)) {
|
if(cdblregex.test(match)) {
|
||||||
let paddlen = 3
|
let paddlen = 3
|
||||||
out = out.substring(paddlen,out.length-paddlen).trim()+"\n"
|
out = out.substring(paddlen,out.length-paddlen).trim()+"\n"
|
||||||
return `<pre><code>${out}</code></pre>`
|
out = newlineify(out)
|
||||||
|
return `<code class="ovfl-bw">${out}</code>`
|
||||||
}
|
}
|
||||||
|
|
||||||
out = newlineify(out)
|
out = newlineify(out)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user