diff --git a/Cargo.toml b/Cargo.toml
index c7ad785..6b26d6c 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -13,10 +13,10 @@ license = "MIT"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]
-leptos = { version = "0.4.8", features = ["csr"] }
+leptos = { version = "0.5.0-beta2", features = ["csr"] }
stylers = { git = "https://github.com/abishekatp/stylers", rev = "4bfd2df" }
web-sys = { version = "0.3.62", features = ["DomRect"] }
-leptos_dom = { version = "0.4.0" }
+leptos_dom = { version = "0.5.0-beta2" }
wasm-bindgen = "0.2.85"
icondata = { version = "0.0.7", features = [
"AiCloseOutlined",
@@ -25,4 +25,4 @@ icondata = { version = "0.0.7", features = [
] }
[workspace]
-members = ["examples/basic", "gh-pages"]
+members = ["gh-pages"]
diff --git a/examples/basic/Cargo.toml b/examples/basic/Cargo.toml
deleted file mode 100644
index 003b630..0000000
--- a/examples/basic/Cargo.toml
+++ /dev/null
@@ -1,16 +0,0 @@
-[package]
-name = "basic"
-version = "0.1.0"
-edition = "2021"
-
-# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
-
-[dependencies]
-leptos = { version = "0.4.0", features = ["csr"] }
-melt-ui = { path = "../../" }
-icondata = { version = "0.0.7", features = [
- "AiCloseOutlined",
- "AiCheckOutlined",
-] }
-leptos_router = { version = "0.4.0", features = ["csr"] }
-regex = "1.8.2"
diff --git a/examples/basic/Trunk.toml b/examples/basic/Trunk.toml
deleted file mode 100644
index 7cf59cc..0000000
--- a/examples/basic/Trunk.toml
+++ /dev/null
@@ -1,13 +0,0 @@
-[build]
-target = "index.html"
-
-[watch]
-watch = [
- "../../src",
- "./src"
-]
-
-[serve]
-address = "127.0.0.1"
-port = 6421
-open = false
diff --git a/examples/basic/index.html b/examples/basic/index.html
deleted file mode 100644
index 7dd8246..0000000
--- a/examples/basic/index.html
+++ /dev/null
@@ -1,13 +0,0 @@
-
-
-
-
-
-
- Document
-
-
-
-
-
-
\ No newline at end of file
diff --git a/examples/basic/src/app.rs b/examples/basic/src/app.rs
deleted file mode 100644
index ce29b04..0000000
--- a/examples/basic/src/app.rs
+++ /dev/null
@@ -1,61 +0,0 @@
-use crate::pages::*;
-use leptos::*;
-use leptos_router::*;
-
-#[component]
-pub fn App(cx: Scope) -> impl IntoView {
- view! { cx,
-
-
-
- } />
-
- } />
-
- } />
-
- } >
-
- } />
-
- } />
-
- } />
-
- } />
-
- } />
-
- } />
-
- } />
-
- } />
-
- } />
-
-
-
-
- } />
-
- } />
-
-
- }
-}
diff --git a/examples/basic/src/assets/css/index.css b/examples/basic/src/assets/css/index.css
deleted file mode 100644
index edc5940..0000000
--- a/examples/basic/src/assets/css/index.css
+++ /dev/null
@@ -1,16 +0,0 @@
-body {
- margin: 0;
-}
-
-
-.components-page-box {
- display: flex;
-}
-
-.components-page-box aside {
- width: 260px;
-}
-
-.components-page-box main {
- flex: 1;
-}
\ No newline at end of file
diff --git a/examples/basic/src/main.rs b/examples/basic/src/main.rs
deleted file mode 100644
index 38ab1fd..0000000
--- a/examples/basic/src/main.rs
+++ /dev/null
@@ -1,9 +0,0 @@
-mod app;
-mod pages;
-
-use app::*;
-use leptos::*;
-
-fn main() {
- mount_to_body(|cx| view! { cx, })
-}
diff --git a/examples/basic/src/pages/button/mod.rs b/examples/basic/src/pages/button/mod.rs
deleted file mode 100644
index a181112..0000000
--- a/examples/basic/src/pages/button/mod.rs
+++ /dev/null
@@ -1,43 +0,0 @@
-use leptos::*;
-use melt_ui::*;
-
-#[component]
-pub fn ButtonPage(cx: Scope) -> impl IntoView {
- view! {cx,
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- }
-}
\ No newline at end of file
diff --git a/examples/basic/src/pages/checkbox/mod.rs b/examples/basic/src/pages/checkbox/mod.rs
deleted file mode 100644
index 7d63d87..0000000
--- a/examples/basic/src/pages/checkbox/mod.rs
+++ /dev/null
@@ -1,14 +0,0 @@
-use leptos::*;
-use melt_ui::*;
-
-#[component]
-pub fn CheckboxPage(cx: Scope) -> impl IntoView {
- let checked = create_rw_signal(cx, false);
- view! {cx,
-
-
- "Click"
-
-
- }
-}
diff --git a/examples/basic/src/pages/components.rs b/examples/basic/src/pages/components.rs
deleted file mode 100644
index 4e7db06..0000000
--- a/examples/basic/src/pages/components.rs
+++ /dev/null
@@ -1,52 +0,0 @@
-use leptos::*;
-use leptos_router::{use_location, use_navigate, Outlet};
-use melt_ui::*;
-use regex::Regex;
-
-#[component]
-pub fn ComponentsPage(cx: Scope) -> impl IntoView {
- let loaction = use_location(cx);
- let navigate = use_navigate(cx);
- let selected = create_rw_signal(cx, String::from(""));
- create_effect(cx, move |_| {
- let pathname = loaction.pathname.get();
-
- let re = Regex::new(r"^/components/(.+)$").unwrap();
- let Some(caps) = re.captures(&pathname) else {
- return;
- };
- let Some(path) = caps.get(1) else {
- return;
- };
- let path = path.as_str().to_string();
- selected.set(path);
- });
-
- create_effect(cx, move |value| {
- let selected = selected.get();
- if value.is_some() {
- _ = navigate(&format!("/components/{selected}"), Default::default());
- }
- selected
- });
- view! {cx,
-
- }
-}
diff --git a/examples/basic/src/pages/home.rs b/examples/basic/src/pages/home.rs
deleted file mode 100644
index 8d41b0c..0000000
--- a/examples/basic/src/pages/home.rs
+++ /dev/null
@@ -1,40 +0,0 @@
-use leptos::*;
-use leptos_router::use_navigate;
-use melt_ui::*;
-
-#[component]
-pub fn Home(cx: Scope) -> impl IntoView {
- let (theme, set_theme) = create_signal(cx, Theme::light());
- provide_context(cx, theme);
- let (count, set_count) = create_signal(cx, 0.0);
- let (button_type, set_button_type) = create_signal(cx, ButtonType::TEXT);
- view! { cx,
-
-
-
-
-
-
- {move || count.get()}
-
-
- }
-}
diff --git a/examples/basic/src/pages/image/mod.rs b/examples/basic/src/pages/image/mod.rs
deleted file mode 100644
index f98e30a..0000000
--- a/examples/basic/src/pages/image/mod.rs
+++ /dev/null
@@ -1,12 +0,0 @@
-use leptos::*;
-use melt_ui::*;
-
-#[component]
-pub fn ImagePage(cx: Scope) -> impl IntoView {
- view! { cx,
- <>
-
-
- >
- }
-}
\ No newline at end of file
diff --git a/examples/basic/src/pages/input/mod.rs b/examples/basic/src/pages/input/mod.rs
deleted file mode 100644
index 1a50d84..0000000
--- a/examples/basic/src/pages/input/mod.rs
+++ /dev/null
@@ -1,14 +0,0 @@
-use leptos::*;
-use melt_ui::*;
-
-#[component]
-pub fn InputPage(cx: Scope) -> impl IntoView {
- let value = create_rw_signal(cx, String::from("o"));
- view! { cx,
- <>
- {move || value.get()}
-
-
- >
- }
-}
\ No newline at end of file
diff --git a/examples/basic/src/pages/menu/mod.rs b/examples/basic/src/pages/menu/mod.rs
deleted file mode 100644
index 2e13f97..0000000
--- a/examples/basic/src/pages/menu/mod.rs
+++ /dev/null
@@ -1,16 +0,0 @@
-use leptos::*;
-use melt_ui::*;
-
-#[component]
-pub fn MenuPage(cx: Scope) -> impl IntoView {
- let selected = create_rw_signal(cx, String::from("o"));
- view! { cx,
- <>
- { move || selected.get() }
-
- >
- }
-}
diff --git a/examples/basic/src/pages/mobile.rs b/examples/basic/src/pages/mobile.rs
deleted file mode 100644
index ba52df9..0000000
--- a/examples/basic/src/pages/mobile.rs
+++ /dev/null
@@ -1,10 +0,0 @@
-use leptos::*;
-
-#[component]
-pub fn MobilePage(cx: Scope, path: &'static str) -> impl IntoView {
- view! { cx,
-
-
-
- }
-}
diff --git a/examples/basic/src/pages/mod.rs b/examples/basic/src/pages/mod.rs
deleted file mode 100644
index 54f95c8..0000000
--- a/examples/basic/src/pages/mod.rs
+++ /dev/null
@@ -1,25 +0,0 @@
-mod button;
-mod checkbox;
-mod components;
-mod home;
-mod image;
-mod input;
-mod menu;
-mod mobile;
-mod modal;
-mod nav_bar;
-mod slider;
-mod tabbar;
-
-pub use button::*;
-pub use checkbox::*;
-pub use components::*;
-pub use home::*;
-pub use image::*;
-pub use input::*;
-pub use menu::*;
-pub use mobile::*;
-pub use modal::*;
-pub use nav_bar::*;
-pub use slider::*;
-pub use tabbar::*;
diff --git a/examples/basic/src/pages/modal/mod.rs b/examples/basic/src/pages/modal/mod.rs
deleted file mode 100644
index 4004cdf..0000000
--- a/examples/basic/src/pages/modal/mod.rs
+++ /dev/null
@@ -1,15 +0,0 @@
-use leptos::*;
-use melt_ui::*;
-
-#[component]
-pub fn ModalPage(cx: Scope) -> impl IntoView {
- let show = create_rw_signal(cx, false);
- view! { cx,
-
-
- "sd"
-
- }
-}
\ No newline at end of file
diff --git a/examples/basic/src/pages/nav_bar/mod.rs b/examples/basic/src/pages/nav_bar/mod.rs
deleted file mode 100644
index 2e42643..0000000
--- a/examples/basic/src/pages/nav_bar/mod.rs
+++ /dev/null
@@ -1,24 +0,0 @@
-use leptos::*;
-use melt_ui::mobile::NavBar;
-
-#[component]
-pub fn NavBarPage(cx: Scope) -> impl IntoView {
- let click_text = create_rw_signal(cx, String::from("none"));
-
- let click_left = SignalSetter::map(cx, move |_| {
- click_text.set("left".to_string())
- });
-
- let click_right = SignalSetter::map(cx, move |_| {
- click_text.set("right".to_string())
- });
-
- view! { cx,
-
-
-
- { move || click_text.get() }
-
-
- }
-}
\ No newline at end of file
diff --git a/examples/basic/src/pages/slider/mod.rs b/examples/basic/src/pages/slider/mod.rs
deleted file mode 100644
index 8155abb..0000000
--- a/examples/basic/src/pages/slider/mod.rs
+++ /dev/null
@@ -1,11 +0,0 @@
-use leptos::*;
-use melt_ui::*;
-
-#[component]
-pub fn SliderPage(cx: Scope) -> impl IntoView {
- let value = create_rw_signal(cx, 0.0);
-
- view! { cx,
-
- }
-}
diff --git a/examples/basic/src/pages/tabbar/mod.rs b/examples/basic/src/pages/tabbar/mod.rs
deleted file mode 100644
index 2be5b9e..0000000
--- a/examples/basic/src/pages/tabbar/mod.rs
+++ /dev/null
@@ -1,23 +0,0 @@
-use leptos::*;
-use melt_ui::mobile::*;
-
-#[component]
-pub fn TabbarPage(cx: Scope) -> impl IntoView {
- let selected = create_rw_signal(cx, String::from("o"));
- view! { cx,
-
- { move || selected.get() }
-
-
- "and"
-
-
- "if"
-
-
- "or"
-
-
-
- }
-}
diff --git a/gh-pages/Cargo.toml b/gh-pages/Cargo.toml
index f043704..8ce4aa6 100644
--- a/gh-pages/Cargo.toml
+++ b/gh-pages/Cargo.toml
@@ -6,12 +6,12 @@ edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]
-leptos = { version = "0.4.8", features = ["csr"] }
+leptos = { version = "0.5.0-beta2", features = ["csr"] }
melt-ui = { path = "../" }
icondata = { version = "0.0.7", features = [
"AiCloseOutlined",
"AiCheckOutlined",
] }
-leptos_router = { version = "0.4.0", features = ["csr"] }
+leptos_router = { version = "0.5.0-beta2", features = ["csr"] }
indoc = "2.0.1"
regex = "1.8.2"
diff --git a/gh-pages/README.md b/gh-pages/README.md
new file mode 100644
index 0000000..51063f2
--- /dev/null
+++ b/gh-pages/README.md
@@ -0,0 +1,3 @@
+## Used
+
+Run the `trunk serve` command and then open the `http://127.0.0.1:6421/melt-ui` URL
diff --git a/gh-pages/Trunk.toml b/gh-pages/Trunk.toml
index e45af6e..bb3d0da 100644
--- a/gh-pages/Trunk.toml
+++ b/gh-pages/Trunk.toml
@@ -2,7 +2,7 @@
target = "index.html"
public_url = "/melt-ui/"
dist = "../docs"
-release = true
+# release = true
[watch]
watch = [
diff --git a/gh-pages/src/app.rs b/gh-pages/src/app.rs
index ad46258..fe249f7 100644
--- a/gh-pages/src/app.rs
+++ b/gh-pages/src/app.rs
@@ -3,70 +3,34 @@ use leptos::*;
use leptos_router::*;
#[component]
-pub fn App(cx: Scope) -> impl IntoView {
- view! { cx,
+pub fn App() -> impl IntoView {
+ view! {
-
- } />
-
- } />
-
- } />
-
- } >
-
- } />
-
- } />
-
+
+
+
+
} />
-
} />
-
- } />
-
- } />
-
- } />
-
- } />
-
- } />
-
+
+
+
+
+
} />
-
- } />
-
- } />
+
+
-
-
-
- } />
-
- } />
-
- } />
+
+
+
}
diff --git a/gh-pages/src/components/site_header.rs b/gh-pages/src/components/site_header.rs
index 193d54c..e94e22d 100644
--- a/gh-pages/src/components/site_header.rs
+++ b/gh-pages/src/components/site_header.rs
@@ -3,14 +3,14 @@ use leptos_router::use_navigate;
use melt_ui::*;
#[component]
-pub fn SiteHeader(cx: Scope) -> impl IntoView {
- view! { cx,
+pub fn SiteHeader() -> impl IntoView {
+ view! {
"Melt UI"
diff --git a/gh-pages/src/main.rs b/gh-pages/src/main.rs
index 23e4aca..e533a1a 100644
--- a/gh-pages/src/main.rs
+++ b/gh-pages/src/main.rs
@@ -6,5 +6,5 @@ use app::*;
use leptos::*;
fn main() {
- mount_to_body(|cx| view! { cx, })
+ mount_to_body(App)
}
diff --git a/gh-pages/src/pages/button/mod.rs b/gh-pages/src/pages/button/mod.rs
index 703b334..c0c4cb6 100644
--- a/gh-pages/src/pages/button/mod.rs
+++ b/gh-pages/src/pages/button/mod.rs
@@ -2,8 +2,8 @@ use leptos::*;
use melt_ui::*;
#[component]
-pub fn ButtonPage(cx: Scope) -> impl IntoView {
- view! {cx,
+pub fn ButtonPage() -> impl IntoView {
+ view! {