Hello friends
I found a nice code block style with a serial number on the left, and an extra nice beautification style, how do I apply it to TiddlyWiki?
Python逆向网易有道翻译练习代码 | 雨园博客 (gaoyuanqi.cn)
This is the full stylesheet for reviewing code blocks
element.style {
}
figure.highlight {
overflow: auto;
position: relative;
}
figure.highlight, pre {
line-height: 1.6;
margin: 0 auto 20px;
}
code, kbd, figure.highlight, pre {
background: var(--highlight-background);
color: var(--highlight-foreground);
}
figure.highlight {
border-radius: 5px;
box-shadow: 0 10px 30px 0 rgba(0, 0, 0, 0.4);
padding-top: 30px;
}
用户代理样式表
figure {
display: block;
margin-block-start: 1em;
margin-block-end: 1em;
margin-inline-start: 40px;
margin-inline-end: 40px;
unicode-bidi: isolate;
}
.use-motion .animated {
animation-fill-mode: none;
visibility: inherit;
}
.use-motion .post-body {
visibility: hidden;
}
@media (min-width: 992px) {
.post-body {
text-align: justify;
}
}
@media (min-width: 1200px) {
.post-body {
font-size: 1.125em;
}
}
.post-body {
font-family: Lato, 'PingFang SC', 'Microsoft YaHei', sans-serif;
overflow-wrap: break-word;
}
.use-motion .post-block, .use-motion .pagination, .use-motion .comments {
visibility: hidden;
}
body {
background: var(--body-bg-color);
box-sizing: border-box;
color: var(--text-color);
font-family: Lato, 'PingFang SC', 'Microsoft YaHei', sans-serif;
font-size: 1em;
line-height: 2;
min-height: 100%;
position: relative;
transition: padding 0.2s ease-in-out;
}
:host, :root {
--fa-style-family-classic: "Font Awesome 6 Free";
--fa-font-solid: normal 900 1em / 1 "Font Awesome 6 Free";
}
:host, :root {
--fa-font-regular: normal 400 1em / 1 "Font Awesome 6 Free";
}
:host, :root {
--fa-style-family-brands: "Font Awesome 6 Brands";
--fa-font-brands: normal 400 1em / 1 "Font Awesome 6 Brands";
}
:root {
--body-bg-color: #f5f7f9;
--content-bg-color: #fff;
--card-bg-color: #f5f5f5;
--text-color: #555;
--blockquote-color: #666;
--link-color: #555;
--link-hover-color: #222;
--brand-color: #fff;
--brand-hover-color: #fff;
--table-row-odd-bg-color: #f9f9f9;
--table-row-hover-bg-color: #f5f5f5;
--menu-item-bg-color: #f5f5f5;
--theme-color: #222;
--btn-default-bg: #fff;
--btn-default-color: #555;
--btn-default-border-color: #555;
--btn-default-hover-bg: #222;
--btn-default-hover-color: #fff;
--btn-default-hover-border-color: #222;
--highlight-background: #f7f9fb;
--highlight-foreground: #405c79;
--highlight-gutter-background: #e4e9ee;
--highlight-gutter-foreground: #526b86;
color-scheme: light;
}
html {
line-height: 1.15;
-webkit-text-size-adjust: 100%;
}
figure.highlight::before {
background: #fc625d;
box-shadow: 20px 0 #fdbc40, 40px 0 #35cd4b;
left: 12px;
margin-top: -20px;
position: absolute;
border-radius: 50%;
content: ' ';
height: 12px;
width: 12px;
}
::selection {
background: #262a30;
color: #eee;
}
I want the style to work directly on the code block
```
```
Any answer would be greatly appreciated