Skip to content

Commit

Permalink
💄 微调模板样式
Browse files Browse the repository at this point in the history
  • Loading branch information
KomoriDev committed Jul 31, 2024
1 parent 7bcd374 commit 442a9dc
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 5 deletions.
2 changes: 1 addition & 1 deletion nonebot_plugin_wakatime/render_pic.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ async def render(data: WakaTime) -> bytes:
"all_time_since_today": data["all_time_since_today"],
},
pages={
"viewport": {"width": 550, "height": 800},
"viewport": {"width": 550, "height": 10},
"base_url": f"file://{TEMPLATES_DIR}",
},
)
13 changes: 12 additions & 1 deletion nonebot_plugin_wakatime/resources/templates/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -557,7 +557,6 @@ video {
.background {
--tw-bg-opacity: 0.1;
background-size: cover;
background-attachment: fixed;
background-position: center;
background-repeat: no-repeat;
}
Expand Down Expand Up @@ -676,6 +675,10 @@ video {
margin-top: 1.5rem;
}

.mt-10 {
margin-top: 2.5rem;
}

.block {
display: block;
}
Expand Down Expand Up @@ -910,6 +913,14 @@ video {
padding-bottom: 5rem;
}

.pt-20 {
padding-top: 5rem;
}

.pb-10 {
padding-bottom: 2.5rem;
}

.text-center {
text-align: center;
}
Expand Down
6 changes: 3 additions & 3 deletions nonebot_plugin_wakatime/resources/templates/profile.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<link rel="stylesheet" href="./index.css" />
</head>

<body class="background px-10 py-20" style="background-image: url({{background_image}});">
<body class="background px-10 pt-20 pb-10" style="background-image: url({{background_image}});">

<!-- Profile -->
<header class="frosted-glass relative w-auto">
Expand Down Expand Up @@ -85,7 +85,7 @@ <h1 class="text-xl text-white font-semibold">@{{ user["username"] }}</h1>
</svg>
</div>
<div>
<div class="text-white text-sm font-thin">{{ editor["name"] }}</div>
<div class="text-white text-sm font-light">{{ editor["name"] }}</div>
<div class="text-white">{{ editor["text"] }}</div>
</div>
</div>
Expand Down Expand Up @@ -115,5 +115,5 @@ <h1 class="text-xl text-white font-semibold">@{{ user["username"] }}</h1>
{% endfor %}
</section>
{% endif %}
<footer class="fixed bottom-5 left-0 w-full text-white text-center font-light">Generated by nonebot-plugin-wakatime</footer>
<footer class="mt-10 text-sm text-white text-center font-normal">Generated by nonebot-plugin-wakatime</footer>
</body>

0 comments on commit 442a9dc

Please sign in to comment.