feat: update to upstream v0.522.0 (#102)

Co-authored-by: rust-for-web[bot] <191031261+rust-for-web[bot]@users.noreply.github.com>
This commit is contained in:
rust-for-web[bot] 2025-06-26 09:12:03 +02:00 committed by GitHub
parent fb3634b18d
commit 190f09e88e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
13 changed files with 153 additions and 7 deletions

View file

@ -5426,6 +5426,12 @@ pub fn IconsL1() -> Element {
},
"Lightbulb Off",
),
(
rsx! {
LineSquiggle {}
},
"Line Squiggle",
),
(
rsx! {
Link {}

View file

@ -1139,6 +1139,7 @@ pub fn IconsL() -> impl IntoView {
(view! { <Ligature /> }.into_any(), "Ligature"),
(view! { <Lightbulb /> }.into_any(), "Lightbulb"),
(view! { <LightbulbOff /> }.into_any(), "Lightbulb Off"),
(view! { <LineSquiggle /> }.into_any(), "Line Squiggle"),
(view! { <Link /> }.into_any(), "Link"),
(view! { <Link2 /> }.into_any(), "Link 2"),
(view! { <Link2Off /> }.into_any(), "Link 2 Off"),

View file

@ -1165,6 +1165,7 @@ pub fn IconsL() -> Html {
(html! { <Ligature /> }, "Ligature"),
(html! { <Lightbulb /> }, "Lightbulb"),
(html! { <LightbulbOff /> }, "Lightbulb Off"),
(html! { <LineSquiggle /> }, "Line Squiggle"),
(html! { <Link /> }, "Link"),
(html! { <Link2 /> }, "Link 2"),
(html! { <Link2Off /> }, "Link 2 Off"),

View file

@ -2105,6 +2105,8 @@ mod ligature;
mod lightbulb;
#[cfg(feature = "photography")]
mod lightbulb_off;
#[cfg(any(feature = "shapes", feature = "math", feature = "design"))]
mod line_squiggle;
#[cfg(any(feature = "text", feature = "account"))]
mod link;
#[cfg(any(feature = "text", feature = "account"))]
@ -6185,6 +6187,8 @@ pub use ligature::*;
pub use lightbulb::*;
#[cfg(feature = "photography")]
pub use lightbulb_off::*;
#[cfg(any(feature = "shapes", feature = "math", feature = "design"))]
pub use line_squiggle::*;
#[cfg(any(feature = "text", feature = "account"))]
pub use link::*;
#[cfg(any(feature = "text", feature = "account"))]

View file

@ -0,0 +1,40 @@
use dioxus::prelude::*;
#[derive(Clone, PartialEq, Props)]
pub struct LineSquiggleProps {
#[props(default = 24)]
pub size: usize,
#[props(default = "currentColor".to_owned())]
pub color: String,
#[props(default = "none".to_owned())]
pub fill: String,
#[props(default = 2)]
pub stroke_width: usize,
#[props(default = false)]
pub absolute_stroke_width: bool,
pub class: Option<String>,
pub style: Option<String>,
}
#[component]
pub fn LineSquiggle(props: LineSquiggleProps) -> Element {
let stroke_width = if props.absolute_stroke_width {
props.stroke_width * 24 / props.size
} else {
props.stroke_width
};
rsx! {
svg {
"xmlns": "http://www.w3.org/2000/svg",
"class": if let Some(class) = props.class { "{class}" },
"style": if let Some(style) = props.style { "{style}" },
"width": "{props.size}",
"height": "{props.size}",
"viewBox": "0 0 24 24",
"fill": "{props.fill}",
"stroke": "{props.color}",
"stroke-width": "{stroke_width}",
"stroke-linecap": "round",
"stroke-linejoin": "round",
path { "d": "M7 3.5c5-2 7 2.5 3 4C1.5 10 2 15 5 16c5 2 9-10 14-7s.5 13.5-4 12c-5-2.5.5-11 6-2" }
}
}
}

View file

@ -34,9 +34,9 @@ pub fn ShoppingBag(props: ShoppingBagProps) -> Element {
"stroke-width": "{stroke_width}",
"stroke-linecap": "round",
"stroke-linejoin": "round",
path { "d": "M6 2 3 6v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V6l-3-4Z" }
path { "d": "M3 6h18" }
path { "d": "M16 10a4 4 0 0 1-8 0" }
path { "d": "M3.103 6.034h17.794" }
path { "d": "M3.4 5.467a2 2 0 0 0-.4 1.2V20a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V6.667a2 2 0 0 0-.4-1.2l-2-2.667A2 2 0 0 0 17 2H7a2 2 0 0 0-1.6.8z" }
}
}
}

View file

@ -2105,6 +2105,8 @@ mod ligature;
mod lightbulb;
#[cfg(feature = "photography")]
mod lightbulb_off;
#[cfg(any(feature = "shapes", feature = "math", feature = "design"))]
mod line_squiggle;
#[cfg(any(feature = "text", feature = "account"))]
mod link;
#[cfg(any(feature = "text", feature = "account"))]
@ -6185,6 +6187,8 @@ pub use ligature::*;
pub use lightbulb::*;
#[cfg(feature = "photography")]
pub use lightbulb_off::*;
#[cfg(any(feature = "shapes", feature = "math", feature = "design"))]
pub use line_squiggle::*;
#[cfg(any(feature = "text", feature = "account"))]
pub use link::*;
#[cfg(any(feature = "text", feature = "account"))]

View file

@ -0,0 +1,35 @@
use leptos::{prelude::*, svg::Svg};
#[component]
pub fn LineSquiggle(
#[prop(default = 24.into(), into)] size: Signal<usize>,
#[prop(default = "currentColor".into(), into)] color: Signal<String>,
#[prop(default = "none".into(), into)] fill: Signal<String>,
#[prop(default = 2.into(), into)] stroke_width: Signal<usize>,
#[prop(default = false.into(), into)] absolute_stroke_width: Signal<bool>,
#[prop(optional)] node_ref: NodeRef<Svg>,
) -> impl IntoView {
let stroke_width = Signal::derive(move || {
if absolute_stroke_width.get() {
stroke_width.get() * 24 / size.get()
} else {
stroke_width.get()
}
});
view! {
<svg
node_ref=node_ref
class:lucide=true
xmlns="http://www.w3.org/2000/svg"
width=size
height=size
viewBox="0 0 24 24"
fill=fill
stroke=color
stroke-width=stroke_width
stroke-linecap="round"
stroke-linejoin="round"
>
<path d="M7 3.5c5-2 7 2.5 3 4C1.5 10 2 15 5 16c5 2 9-10 14-7s.5 13.5-4 12c-5-2.5.5-11 6-2" />
</svg>
}
}

View file

@ -29,9 +29,9 @@ pub fn ShoppingBag(
stroke-linecap="round"
stroke-linejoin="round"
>
<path d="M6 2 3 6v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V6l-3-4Z" />
<path d="M3 6h18" />
<path d="M16 10a4 4 0 0 1-8 0" />
<path d="M3.103 6.034h17.794" />
<path d="M3.4 5.467a2 2 0 0 0-.4 1.2V20a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V6.667a2 2 0 0 0-.4-1.2l-2-2.667A2 2 0 0 0 17 2H7a2 2 0 0 0-1.6.8z" />
</svg>
}
}

View file

@ -2107,6 +2107,8 @@ mod ligature;
mod lightbulb;
#[cfg(feature = "photography")]
mod lightbulb_off;
#[cfg(any(feature = "shapes", feature = "math", feature = "design"))]
mod line_squiggle;
#[cfg(any(feature = "text", feature = "account"))]
mod link;
#[cfg(any(feature = "text", feature = "account"))]
@ -6187,6 +6189,8 @@ pub use ligature::*;
pub use lightbulb::*;
#[cfg(feature = "photography")]
pub use lightbulb_off::*;
#[cfg(any(feature = "shapes", feature = "math", feature = "design"))]
pub use line_squiggle::*;
#[cfg(any(feature = "text", feature = "account"))]
pub use link::*;
#[cfg(any(feature = "text", feature = "account"))]

View file

@ -0,0 +1,49 @@
use yew::prelude::*;
#[derive(PartialEq, Properties)]
pub struct LineSquiggleProps {
#[prop_or(24)]
pub size: usize,
#[prop_or(AttrValue::from("currentColor"))]
pub color: AttrValue,
#[prop_or(AttrValue::from("none"))]
pub fill: AttrValue,
#[prop_or(2)]
pub stroke_width: usize,
#[prop_or(false)]
pub absolute_stroke_width: bool,
#[prop_or_default]
pub class: Classes,
#[prop_or_default]
pub style: std::option::Option<AttrValue>,
#[prop_or_default]
pub node_ref: NodeRef,
}
#[function_component]
pub fn LineSquiggle(props: &LineSquiggleProps) -> Html {
let stroke_width = if props.absolute_stroke_width {
props.stroke_width * 24 / props.size
} else {
props.stroke_width
};
html! {
<svg
ref={props.node_ref.clone()}
class={classes!("lucide", props.class
.clone())}
style={props.style.clone()}
xmlns="http://www.w3.org/2000/svg"
width={props.size.to_string()}
height={props.size.to_string()}
viewBox="0 0 24 24"
fill={& props.fill}
stroke={& props.color}
stroke-width={stroke_width.to_string()}
stroke-linecap="round"
stroke-linejoin="round"
>
<path
d="M7 3.5c5-2 7 2.5 3 4C1.5 10 2 15 5 16c5 2 9-10 14-7s.5 13.5-4 12c-5-2.5.5-11 6-2"
/>
</svg>
}
}

View file

@ -41,9 +41,11 @@ pub fn ShoppingBag(props: &ShoppingBagProps) -> Html {
stroke-linecap="round"
stroke-linejoin="round"
>
<path d="M6 2 3 6v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V6l-3-4Z" />
<path d="M3 6h18" />
<path d="M16 10a4 4 0 0 1-8 0" />
<path d="M3.103 6.034h17.794" />
<path
d="M3.4 5.467a2 2 0 0 0-.4 1.2V20a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V6.667a2 2 0 0 0-.4-1.2l-2-2.667A2 2 0 0 0 17 2H7a2 2 0 0 0-1.6.8z"
/>
</svg>
}
}

View file

@ -11,5 +11,5 @@ pub const GITHUB_OWNER: &str = "RustForWeb";
pub const GITHUB_REPO: &str = "lucide";
pub const UPSTREAM_GIT_URL: &str = "https://github.com/lucide-icons/lucide.git";
pub const UPSTREAM_GIT_REF: &str = "0.521.0";
pub const UPSTREAM_GIT_REF: &str = "0.522.0";
pub const UPSTREAM_GITHUB_URL: &str = "https://github.com/lucide-icons/lucide";