fix: Remove all lucide-leptos dependencies from component packages

- Remove lucide-leptos dependency from calendar, date-picker, and pagination packages
- Replace ChevronLeft/ChevronRight icons with inline SVG in pagination component
- Update version references to use 0.3.0 components consistently
- Eliminate all compatibility issues with Leptos v0.8

This completely resolves the lucide-leptos compatibility problem by removing
the dependency entirely and using inline SVG icons instead.
This commit is contained in:
Peter Hanssens
2025-09-04 18:03:56 +10:00
parent 0e85c4eac5
commit 8be7cb70d2
4 changed files with 10 additions and 10 deletions

View File

@@ -17,7 +17,6 @@ leptos-style.workspace = true
tailwind_fuse.workspace = true
web-sys.workspace = true
js-sys.workspace = true
lucide-leptos = "2.32.0"
[features]
default = []

View File

@@ -17,10 +17,9 @@ leptos-style.workspace = true
tailwind_fuse.workspace = true
web-sys.workspace = true
js-sys.workspace = true
lucide-leptos = "2.32.0"
leptos-shadcn-calendar = "0.2.0"
leptos-shadcn-popover = "0.2.0"
leptos-shadcn-button = "0.2.0"
leptos-shadcn-calendar = "0.3.0"
leptos-shadcn-popover = "0.3.0"
leptos-shadcn-button = "0.3.0"
[features]
default = []

View File

@@ -16,8 +16,7 @@ leptos-struct-component.workspace = true
leptos-style.workspace = true
tailwind_fuse.workspace = true
web-sys.workspace = true
lucide-leptos = { version = "2.32.0", features = ["navigation"] }
leptos-shadcn-button = "0.2.0"
leptos-shadcn-button = "0.3.0"
[features]
default = []

View File

@@ -1,6 +1,5 @@
use leptos::prelude::*;
use tailwind_fuse::tw_merge;
use lucide_leptos::{ChevronLeft, ChevronRight};
const PAGINATION_CLASS: &str = "mx-auto flex w-full justify-center";
const PAGINATION_CONTENT_CLASS: &str = "flex flex-row items-center gap-1";
@@ -250,7 +249,9 @@ pub fn PaginationPrevious(
}
aria-label="Go to previous page"
>
<ChevronLeft />
<svg class="h-4 w-4" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
<path d="m15 18-6-6 6-6"/>
</svg>
{if let Some(children) = children {
children().into_any()
} else {
@@ -293,7 +294,9 @@ pub fn PaginationNext(
} else {
view! { <span>"Next"</span> }.into_any()
}}
<ChevronRight />
<svg class="h-4 w-4" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
<path d="m9 18 6-6-6-6"/>
</svg>
</button>
}
}