summary refs log tree commit diff
path: root/src/components/editor/mod.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/components/editor/mod.rs')
-rw-r--r--src/components/editor/mod.rs25
1 files changed, 15 insertions, 10 deletions
diff --git a/src/components/editor/mod.rs b/src/components/editor/mod.rs
index 05e45d3..4d38c69 100644
--- a/src/components/editor/mod.rs
+++ b/src/components/editor/mod.rs
@@ -1,13 +1,18 @@
-use leptos::prelude::*;
-use leptos::{island, view, IntoView};
+use std::path::PathBuf;
+use morgana::{morx, Component, RenderNode};
 
-#[island]
-pub fn WikiEditor(
-    url_path: String,
-) -> impl IntoView {
-    view! {
-        <h1>Article (Editing)</h1>
-        <p>Page render</p>
-        <pre>{url_path}</pre>
+stylance::import_crate_style!(styles, "src/components/layout/layout.module.css");
+
+pub struct Editor {
+    page_path: PathBuf,
+}
+
+impl Component for Editor {
+    fn render(self: Box<Self>) -> RenderNode {
+        morx! {
+            h1= "Article (Editing)"
+            p= "Page render"
+            pre= {self.page_path.to_string_lossy()}
+        }
     }
 }