27 lines
917 B
HTML
27 lines
917 B
HTML
@use crate::templates::{button_js, file_js};
|
|
@use crate::{templates::layouts::home, nav::NavState};
|
|
@use hyaenidae_toolkit::{templates::{button_group, card, card_body, card_title, file_input}, Button, Card, FileInput};
|
|
|
|
@(file: &FileInput, error: Option<String>, nav_state: &NavState)
|
|
|
|
@:home("Create Submission", "Upload a file", nav_state, {
|
|
@:button_js()
|
|
@:file_js()
|
|
}, {
|
|
@:card(&Card::full_width().dark(nav_state.dark()), {
|
|
<form method="POST" action="/submissions/create" enctype="multipart/form-data">
|
|
@:card_title({ Select a file to post })
|
|
@if let Some(error) = error {
|
|
@:card_body({ @error })
|
|
}
|
|
@:card_body({
|
|
@:file_input(file)
|
|
})
|
|
@:card_body({
|
|
@:button_group(&[
|
|
Button::primary("Next"),
|
|
])
|
|
})
|
|
</form>
|
|
})
|
|
})
|