mirror of
https://github.com/sergi0g/cup.git
synced 2025-11-12 15:13:49 -05:00
Compare commits
3 Commits
v1.1.2
...
v1.1.3-nig
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
cec178c4cd | ||
|
|
698061e8c8 | ||
|
|
0a01c667da |
2
Cargo.lock
generated
2
Cargo.lock
generated
@@ -350,7 +350,7 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "cup"
|
name = "cup"
|
||||||
version = "1.1.2"
|
version = "1.1.3"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"bollard",
|
"bollard",
|
||||||
"clap",
|
"clap",
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
[package]
|
[package]
|
||||||
name = "cup"
|
name = "cup"
|
||||||
version = "1.1.2"
|
version = "1.1.3"
|
||||||
edition = "2021"
|
edition = "2021"
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
|
|||||||
@@ -160,7 +160,7 @@ Here are some ideas to get you started:
|
|||||||
|
|
||||||
To contribute, fork the repository, make your changes and the submit a pull request.
|
To contribute, fork the repository, make your changes and the submit a pull request.
|
||||||
|
|
||||||
Note: If you update the UI, please make sure to recompile the CSS with `tailwindcss -mo src/index.css`. You need to have the Tailwind CSS CLI installed ([instructions here](https://tailwindcss.com/docs/installation))
|
Note: If you update the UI, please make sure to recompile the CSS with `tailwindcss -mo src/static/index.css`. You need to have the Tailwind CSS CLI installed ([instructions here](https://tailwindcss.com/docs/installation))
|
||||||
|
|
||||||
## Support
|
## Support
|
||||||
|
|
||||||
|
|||||||
@@ -18,7 +18,6 @@ const FAVICON_SVG: &[u8] = include_bytes!("static/favicon.svg");
|
|||||||
const APPLE_TOUCH_ICON: &[u8] = include_bytes!("static/apple-touch-icon.png");
|
const APPLE_TOUCH_ICON: &[u8] = include_bytes!("static/apple-touch-icon.png");
|
||||||
|
|
||||||
pub async fn serve(port: &u16, updates: &[(String, Option<bool>)]) -> std::io::Result<()> {
|
pub async fn serve(port: &u16, updates: &[(String, Option<bool>)]) -> std::io::Result<()> {
|
||||||
println!("Serving on http://0.0.0.0:{}", port);
|
|
||||||
App::new()
|
App::new()
|
||||||
.with_state(updates.to_owned())
|
.with_state(updates.to_owned())
|
||||||
.at("/", get(handler_service(home)))
|
.at("/", get(handler_service(home)))
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
@@ -5,6 +5,7 @@
|
|||||||
<meta name="theme-color" content="#ffffff">
|
<meta name="theme-color" content="#ffffff">
|
||||||
<link rel="icon" href="favicon.svg">
|
<link rel="icon" href="favicon.svg">
|
||||||
<link rel="apple-touch-icon" href="apple-touch-icon.png">
|
<link rel="apple-touch-icon" href="apple-touch-icon.png">
|
||||||
|
<meta name="viewport" content="width=device-width,initial-scale=1.0" />
|
||||||
<style>
|
<style>
|
||||||
{{ style }}
|
{{ style }}
|
||||||
</style>
|
</style>
|
||||||
@@ -19,14 +20,14 @@
|
|||||||
.gi::after {
|
.gi::after {
|
||||||
content: '';
|
content: '';
|
||||||
position: absolute;
|
position: absolute;
|
||||||
background-color: #e5e7eb;
|
background-color: #e5e5e5;
|
||||||
z-index: 1;
|
z-index: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
@media (prefers-color-scheme: dark) {
|
@media (prefers-color-scheme: dark) {
|
||||||
.gi::before,
|
.gi::before,
|
||||||
.gi::after {
|
.gi::after {
|
||||||
background-color: #1f2937;
|
background-color: #262626;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -70,7 +71,7 @@
|
|||||||
</style>
|
</style>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<div class="flex justify-center items-center min-h-screen bg-gray-50 dark:bg-gray-950">
|
<div class="flex justify-center items-center min-h-screen bg-neutral-50 dark:bg-neutral-950">
|
||||||
<div class="lg:px-8 sm:px-6 px-4 max-w-[80rem] mx-auto h-full w-full">
|
<div class="lg:px-8 sm:px-6 px-4 max-w-[80rem] mx-auto h-full w-full">
|
||||||
<div class="max-w-[48rem] mx-auto h-full my-8">
|
<div class="max-w-[48rem] mx-auto h-full my-8">
|
||||||
<div class="flex items-center gap-1">
|
<div class="flex items-center gap-1">
|
||||||
@@ -113,12 +114,12 @@
|
|||||||
</g>
|
</g>
|
||||||
</svg>
|
</svg>
|
||||||
</div>
|
</div>
|
||||||
<div class="shadow-sm bg-white dark:bg-gray-900 rounded-md my-8">
|
<div class="shadow-sm bg-white dark:bg-neutral-900 rounded-md my-8">
|
||||||
<dl class="lg:grid-cols-4 md:grid-cols-2 gap-1 grid-cols-1 grid overflow-hidden *:relative">
|
<dl class="lg:grid-cols-4 md:grid-cols-2 gap-1 grid-cols-1 grid overflow-hidden *:relative">
|
||||||
{% for metric in metrics %}
|
{% for metric in metrics %}
|
||||||
<div class="gi">
|
<div class="gi">
|
||||||
<div class="xl:px-8 px-6 py-4 gap-y-2 gap-x-4 justify-between align-baseline flex flex-col h-full">
|
<div class="xl:px-8 px-6 py-4 gap-y-2 gap-x-4 justify-between align-baseline flex flex-col h-full">
|
||||||
<dt class="text-gray-500 dark:text-gray-400 leading-6 font-medium">{{ metric.name }}</dt>
|
<dt class="text-neutral-500 dark:text-neutral-400 leading-6 font-medium">{{ metric.name }}</dt>
|
||||||
<dd class="text-black dark:text-white tracking-tight leading-10 font-medium text-3xl flex-none w-full">
|
<dd class="text-black dark:text-white tracking-tight leading-10 font-medium text-3xl flex-none w-full">
|
||||||
{{ metric.value }}
|
{{ metric.value }}
|
||||||
</dd>
|
</dd>
|
||||||
@@ -127,8 +128,8 @@
|
|||||||
{% endfor %}
|
{% endfor %}
|
||||||
</dl>
|
</dl>
|
||||||
</div>
|
</div>
|
||||||
<div class="shadow-sm bg-white dark:bg-gray-900 rounded-md my-8">
|
<div class="shadow-sm bg-white dark:bg-neutral-900 rounded-md my-8">
|
||||||
<ul class="*:py-4 *:px-6 *:flex *:items-center *:gap-3 dark:divide-gray-800 divide-y dark:text-white">
|
<ul class="*:py-4 *:px-6 *:flex *:items-center *:gap-3 dark:divide-neutral-800 divide-y dark:text-white">
|
||||||
{% for image in images %}
|
{% for image in images %}
|
||||||
<li>
|
<li>
|
||||||
<svg
|
<svg
|
||||||
@@ -180,7 +181,7 @@
|
|||||||
height="24"
|
height="24"
|
||||||
viewBox="0 0 24 24"
|
viewBox="0 0 24 24"
|
||||||
fill="currentColor"
|
fill="currentColor"
|
||||||
class="text-gray-500 ml-auto"
|
class="text-neutral-500 ml-auto"
|
||||||
>
|
>
|
||||||
<path stroke="none" d="M0 0h24v24H0z" fill="none" />
|
<path stroke="none" d="M0 0h24v24H0z" fill="none" />
|
||||||
<path d="M12 2c5.523 0 10 4.477 10 10a10 10 0 0 1 -19.995 .324l-.005 -.324l.004 -.28c.148 -5.393 4.566 -9.72 9.996 -9.72zm0 13a1 1 0 0 0 -.993 .883l-.007 .117l.007 .127a1 1 0 0 0 1.986 0l.007 -.117l-.007 -.127a1 1 0 0 0 -.993 -.883zm1.368 -6.673a2.98 2.98 0 0 0 -3.631 .728a1 1 0 0 0 1.44 1.383l.171 -.18a.98 .98 0 0 1 1.11 -.15a1 1 0 0 1 -.34 1.886l-.232 .012a1 1 0 0 0 .111 1.994a3 3 0 0 0 1.371 -5.673z" />
|
<path d="M12 2c5.523 0 10 4.477 10 10a10 10 0 0 1 -19.995 .324l-.005 -.324l.004 -.28c.148 -5.393 4.566 -9.72 9.996 -9.72zm0 13a1 1 0 0 0 -.993 .883l-.007 .117l.007 .127a1 1 0 0 0 1.986 0l.007 -.117l-.007 -.127a1 1 0 0 0 -.993 -.883zm1.368 -6.673a2.98 2.98 0 0 0 -3.631 .728a1 1 0 0 0 1.44 1.383l.171 -.18a.98 .98 0 0 1 1.11 -.15a1 1 0 0 1 -.34 1.886l-.232 .012a1 1 0 0 0 .111 1.994a3 3 0 0 0 1.371 -5.673z" />
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
/** @type {import('tailwindcss').Config} */
|
/** @type {import('tailwindcss').Config} */
|
||||||
module.exports = {
|
module.exports = {
|
||||||
content: [
|
content: [
|
||||||
"src/template.liquid"
|
"src/static/template.liquid"
|
||||||
],
|
],
|
||||||
theme: {
|
theme: {
|
||||||
extend: {},
|
extend: {},
|
||||||
|
|||||||
Reference in New Issue
Block a user