Skip to content

Commit

Permalink
🐛 fix code page
Browse files Browse the repository at this point in the history
  • Loading branch information
songquanpeng committed Dec 18, 2022
1 parent bd7eb98 commit 11b8b9f
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 17 deletions.
15 changes: 0 additions & 15 deletions themes/bulma/code.ejs
Original file line number Diff line number Diff line change
@@ -1,20 +1,5 @@
<%- include('./partials/header') %>

<div class="container article-container">
<article class="shadow-box" style="padding: 16px">
<%- include('./partials/page-info') %>
<div class="control-panel">
<button class="button is-light" id="darkBtn" onclick="changeBackground()">Focus</button>
<button class="button is-light" onclick="copyCode()">Copy</button>
</div>
<pre>
<code id="code-display"><%=page.content%></code>
</pre>
</article>
<%- include('./partials/prev-next') %>
<%- include('./partials/comment') %>
</div>

<div class="code-page">
<%- include('./partials/page-info') %>
<div class="control-panel">
Expand Down
13 changes: 11 additions & 2 deletions themes/bulma/static/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -298,6 +298,10 @@ article li + li {
margin-top: 0.25em;
}

code {
font-family: "JetBrains Mono", "Cascadia Code", Consolas, Microsoft YaHei, monospace;
}

article code {
color: #24292f;
background-color: rgb(175 184 193 / 20%);
Expand Down Expand Up @@ -325,13 +329,14 @@ article .copyright {

/* Code Page Style*/
.code-page {
margin-top: 16px;
margin-top: 32px;
padding-left: 16px;
padding-right: 16px;
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans", Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji";
}

.code-page code {
font-size: 18px;
font-size: 16px;
width: 100%;
height: 100%;
}
Expand All @@ -348,6 +353,10 @@ article .copyright {
width: 100%;
}

#code-display {
padding: 16px 24px;
}

.discuss h1 {
font-size: 24px;
line-height: 36px;
Expand Down

0 comments on commit 11b8b9f

Please sign in to comment.