Files
owlibou_tavern/src/pages/import.rs
google-labs-jules[bot] 195e0f4f8f feat: Implement Dioxus fullstack application
This commit introduces a full-stack Dioxus application with a web frontend to manage TTRPG data from a SQLite database.

The application is built using a Server-Side Rendering (SSR) architecture with Axum for the web server and Dioxus for templating. This approach was chosen for its simplicity and robustness, avoiding client-side build complexities.

Features include:
- A web server powered by Axum.
- Server-side rendered pages for Home, Creatures, Edit Creature, Import, and Changelog.
- Database integration with `sqlx` to view a list of creatures and details for a single creature.
- A modular structure with components, pages, and database logic separated into modules.
- A navigation bar for easy access to all pages.
- Placeholder pages for data import and editing functionality.
2025-08-21 02:36:52 +00:00

27 lines
731 B
Rust

use dioxus::prelude::*;
#[component]
pub fn ImportPage() -> Element {
rsx! {
div {
h2 { "Import Data" }
p { "This page will be used to import data from files." }
form {
prevent_default: "onsubmit",
onsubmit: move |_| {
// Placeholder for form submission logic
log::info!("Form submitted for file import.");
},
input {
r#type: "file",
accept: ".json,.csv", // Example file types
}
button {
r#type: "submit",
"Import"
}
}
}
}
}