mirror of
https://github.com/YGGverse/mb.git
synced 2026-03-31 17:15:28 +00:00
update template adaptivity
This commit is contained in:
parent
a2c658ae7b
commit
03fcfe38a4
2 changed files with 51 additions and 20 deletions
|
|
@ -27,8 +27,10 @@
|
|||
body {
|
||||
background: var(--background);
|
||||
color: var(--default);
|
||||
display: grid;
|
||||
font-family: var(--font-family);
|
||||
font-size: 14px;
|
||||
grid-template-columns: 40em 25em;
|
||||
}
|
||||
|
||||
a,
|
||||
|
|
@ -51,14 +53,16 @@ h1, h2 {
|
|||
}
|
||||
|
||||
body > * {
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
max-width: 580px;
|
||||
overflow: hidden;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
header {
|
||||
grid-column: 3 / 4;
|
||||
grid-row: 1;
|
||||
margin: 16px auto;
|
||||
text-align: center;
|
||||
position: sticky;
|
||||
}
|
||||
|
||||
header > a,
|
||||
|
|
@ -73,6 +77,11 @@ header::first-letter {
|
|||
color: var(--accent);
|
||||
}
|
||||
|
||||
header > p {
|
||||
font-size: small;
|
||||
margin-top: 3px;
|
||||
}
|
||||
|
||||
header > div {
|
||||
font-size: small;
|
||||
margin-top: 12px;
|
||||
|
|
@ -84,7 +93,8 @@ header > div > code:not(:last-child)::after {
|
|||
}
|
||||
|
||||
header > form {
|
||||
margin-top: 20px;
|
||||
border-top: 1px solid var(--item);
|
||||
margin-top: 16px;
|
||||
}
|
||||
|
||||
header > form > input {
|
||||
|
|
@ -94,6 +104,7 @@ header > form > input {
|
|||
border-style: solid;
|
||||
border-width: 1px;
|
||||
color: var(--default);
|
||||
margin-top: 16px;
|
||||
opacity: 0.9;
|
||||
}
|
||||
|
||||
|
|
@ -114,15 +125,22 @@ header > form > input[type="submit"] {
|
|||
padding: 8px 16px;
|
||||
}
|
||||
|
||||
header > div {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
main {
|
||||
margin: 0 auto;
|
||||
grid-column: 1 / 4;
|
||||
grid-row: 1;
|
||||
margin: 16px auto;
|
||||
}
|
||||
|
||||
main > form {
|
||||
border-bottom: 1px solid var(--item);
|
||||
border-top: 1px solid var(--item);
|
||||
background-color: #554840;
|
||||
border-radius: 3px;
|
||||
margin-bottom: 8px;
|
||||
overflow: hidden;
|
||||
padding-bottom: 8px;
|
||||
padding: 0 8px 8px;
|
||||
}
|
||||
|
||||
main > form > textarea {
|
||||
|
|
@ -132,12 +150,14 @@ main > form > textarea {
|
|||
border-style: solid;
|
||||
border-width: 1px;
|
||||
color: var(--default);
|
||||
font-family: var(--font-family);
|
||||
font-size: 14px;
|
||||
margin: 8px 0;
|
||||
max-width: 100%;
|
||||
min-width: 100%;
|
||||
opacity: 0.9;
|
||||
padding: 16px;
|
||||
padding: 8px;
|
||||
width: 100%;
|
||||
font-family: var(--font-family);
|
||||
}
|
||||
|
||||
main > form > input {
|
||||
|
|
@ -172,7 +192,7 @@ main > a {
|
|||
main > div {
|
||||
background-color: var(--item);
|
||||
border-radius: 3px;
|
||||
margin: 8px 0;
|
||||
margin-bottom: 8px;
|
||||
padding: 16px;
|
||||
}
|
||||
|
||||
|
|
@ -258,8 +278,19 @@ main > span {
|
|||
padding: 8px 4px;
|
||||
}
|
||||
|
||||
footer {
|
||||
font-size: small;
|
||||
margin: 16px auto 36px;
|
||||
text-align: center;
|
||||
@media (max-width: 1240px) {
|
||||
body {
|
||||
display: unset;
|
||||
}
|
||||
header, main {
|
||||
padding: 0 8px;
|
||||
}
|
||||
header > form {
|
||||
padding-right: 96px;
|
||||
}
|
||||
header > div {
|
||||
bottom: 8px;
|
||||
position: absolute;
|
||||
right: 8px;
|
||||
}
|
||||
}
|
||||
|
|
@ -11,19 +11,19 @@
|
|||
<body>
|
||||
<header>
|
||||
<a href="{{ home }}">{{ title }}</a>
|
||||
{% if description %}<div>{{ description }}</div>{% endif %}
|
||||
{% if description %}<p>{{ description }}</p>{% endif %}
|
||||
<form action="/" method="GET">
|
||||
{% if token %}<input type="hidden" name="token" value="{{ token }}" />{% endif %}
|
||||
<input type="text" name="search" value="{% if search %}{{ search }}{% endif %}" placeholder="Search..." />
|
||||
<input type="submit" value="Search" />
|
||||
</form>
|
||||
<div>
|
||||
<a href="/rss">RSS</a> |
|
||||
<a href="https://github.com/yggverse/mb" title="v{{ version }}">GitHub</a>
|
||||
</div>
|
||||
</header>
|
||||
<main>
|
||||
{% block content %}{% endblock content %}
|
||||
</main>
|
||||
<footer>
|
||||
<a href="/rss">RSS</a> |
|
||||
<a href="https://github.com/yggverse/mb" title="v{{ version }}">GitHub</a>
|
||||
</footer>
|
||||
</body>
|
||||
</html>
|
||||
Loading…
Add table
Add a link
Reference in a new issue