fix: restore Trunk link tag for Cargo.toml to resolve SyntaxError in browser
Some checks failed
Build MIPS Binary / build (push) Has been cancelled
Some checks failed
Build MIPS Binary / build (push) Has been cancelled
This commit is contained in:
@@ -20,7 +20,7 @@
|
||||
<link rel="apple-touch-icon" sizes="512x512" href="icon-512.png" />
|
||||
|
||||
<!-- Trunk Assets -->
|
||||
<script data-trunk rel="rust" src="Cargo.toml" data-wasm-opt="0" data-preload="false"></script>
|
||||
<link data-trunk rel="rust" href="Cargo.toml" data-wasm-opt="0" data-preload="false" />
|
||||
<link data-trunk rel="css" href="public/tailwind.css" />
|
||||
<link data-trunk rel="copy-file" href="manifest.json" />
|
||||
<link data-trunk rel="copy-file" href="icon-192.png" />
|
||||
|
||||
26
frontend/src/components/ui/progress.rs
Normal file
26
frontend/src/components/ui/progress.rs
Normal file
@@ -0,0 +1,26 @@
|
||||
use leptos::prelude::*;
|
||||
use tailwind_fuse::tw_merge;
|
||||
|
||||
#[component]
|
||||
pub fn Progress(
|
||||
#[prop(into)] value: Signal<f64>,
|
||||
#[prop(optional, into)] class: String,
|
||||
) -> impl IntoView {
|
||||
let progress_style = move || format!("transform: translateX(-{}%);", 100.0 - value.get().clamp(0.0, 100.0));
|
||||
|
||||
view! {
|
||||
<div
|
||||
data-name="Progress"
|
||||
class=tw_merge!(
|
||||
"relative h-2 w-full overflow-hidden rounded-full bg-primary/20",
|
||||
class
|
||||
)
|
||||
>
|
||||
<div
|
||||
data-name="ProgressIndicator"
|
||||
class="h-full w-full flex-1 bg-primary transition-all duration-500 ease-in-out"
|
||||
style=progress_style
|
||||
/>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user