Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
96 changes: 90 additions & 6 deletions book-examples/dioxus/src/icons.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4063,6 +4063,12 @@ pub fn IconsF1() -> Element {
},
"Fishing Hook",
),
(
rsx! {
FishingRod {}
},
"Fishing Rod",
),
(
rsx! {
Flag {}
Expand Down Expand Up @@ -4231,12 +4237,6 @@ pub fn IconsF1() -> Element {
},
"Folder Git",
),
(
rsx! {
FolderGit2 {}
},
"Folder Git 2",
),
];
rsx! {
for (icon , name) in icons {
Expand All @@ -4252,6 +4252,12 @@ pub fn IconsF1() -> Element {
#[component]
pub fn IconsF2() -> Element {
let icons = [
(
rsx! {
FolderGit2 {}
},
"Folder Git 2",
),
(
rsx! {
FolderHeart {}
Expand Down Expand Up @@ -10685,6 +10691,84 @@ pub fn IconsZ1() -> Element {
},
"Zap Off",
),
(
rsx! {
ZodiacAquarius {}
},
"Zodiac Aquarius",
),
(
rsx! {
ZodiacAries {}
},
"Zodiac Aries",
),
(
rsx! {
ZodiacCancer {}
},
"Zodiac Cancer",
),
(
rsx! {
ZodiacCapricorn {}
},
"Zodiac Capricorn",
),
(
rsx! {
ZodiacGemini {}
},
"Zodiac Gemini",
),
(
rsx! {
ZodiacLeo {}
},
"Zodiac Leo",
),
(
rsx! {
ZodiacLibra {}
},
"Zodiac Libra",
),
(
rsx! {
ZodiacOphiuchus {}
},
"Zodiac Ophiuchus",
),
(
rsx! {
ZodiacPisces {}
},
"Zodiac Pisces",
),
(
rsx! {
ZodiacSagittarius {}
},
"Zodiac Sagittarius",
),
(
rsx! {
ZodiacScorpio {}
},
"Zodiac Scorpio",
),
(
rsx! {
ZodiacTaurus {}
},
"Zodiac Taurus",
),
(
rsx! {
ZodiacVirgo {}
},
"Zodiac Virgo",
),
(
rsx! {
ZoomIn {}
Expand Down
16 changes: 15 additions & 1 deletion book-examples/leptos/src/icons.rs
Original file line number Diff line number Diff line change
Expand Up @@ -902,6 +902,7 @@ pub fn IconsF1() -> impl IntoView {
(view! { <FishOff /> }.into_any(), "Fish Off"),
(view! { <FishSymbol /> }.into_any(), "Fish Symbol"),
(view! { <FishingHook /> }.into_any(), "Fishing Hook"),
(view! { <FishingRod /> }.into_any(), "Fishing Rod"),
(view! { <Flag /> }.into_any(), "Flag"),
(view! { <FlagOff /> }.into_any(), "Flag Off"),
(view! { <FlagTriangleLeft /> }.into_any(), "Flag Triangle Left"),
Expand Down Expand Up @@ -930,7 +931,6 @@ pub fn IconsF1() -> impl IntoView {
(view! { <FolderDot /> }.into_any(), "Folder Dot"),
(view! { <FolderDown /> }.into_any(), "Folder Down"),
(view! { <FolderGit /> }.into_any(), "Folder Git"),
(view! { <FolderGit2 /> }.into_any(), "Folder Git 2"),
]
key=|icon| icon.1
children=move |(icon, name)| {
Expand All @@ -948,6 +948,7 @@ pub fn IconsF2() -> impl IntoView {
view! {
<For
each=move || [
(view! { <FolderGit2 /> }.into_any(), "Folder Git 2"),
(view! { <FolderHeart /> }.into_any(), "Folder Heart"),
(view! { <FolderInput /> }.into_any(), "Folder Input"),
(view! { <FolderKanban /> }.into_any(), "Folder Kanban"),
Expand Down Expand Up @@ -2396,6 +2397,19 @@ pub fn IconsZ1() -> impl IntoView {
each=move || [
(view! { <Zap /> }.into_any(), "Zap"),
(view! { <ZapOff /> }.into_any(), "Zap Off"),
(view! { <ZodiacAquarius /> }.into_any(), "Zodiac Aquarius"),
(view! { <ZodiacAries /> }.into_any(), "Zodiac Aries"),
(view! { <ZodiacCancer /> }.into_any(), "Zodiac Cancer"),
(view! { <ZodiacCapricorn /> }.into_any(), "Zodiac Capricorn"),
(view! { <ZodiacGemini /> }.into_any(), "Zodiac Gemini"),
(view! { <ZodiacLeo /> }.into_any(), "Zodiac Leo"),
(view! { <ZodiacLibra /> }.into_any(), "Zodiac Libra"),
(view! { <ZodiacOphiuchus /> }.into_any(), "Zodiac Ophiuchus"),
(view! { <ZodiacPisces /> }.into_any(), "Zodiac Pisces"),
(view! { <ZodiacSagittarius /> }.into_any(), "Zodiac Sagittarius"),
(view! { <ZodiacScorpio /> }.into_any(), "Zodiac Scorpio"),
(view! { <ZodiacTaurus /> }.into_any(), "Zodiac Taurus"),
(view! { <ZodiacVirgo /> }.into_any(), "Zodiac Virgo"),
(view! { <ZoomIn /> }.into_any(), "Zoom In"),
(view! { <ZoomOut /> }.into_any(), "Zoom Out"),
]
Expand Down
14 changes: 14 additions & 0 deletions book-examples/yew/src/icons.rs
Original file line number Diff line number Diff line change
Expand Up @@ -850,6 +850,7 @@ pub fn IconsF() -> Html {
(html! { <FishOff /> }, "Fish Off"),
(html! { <FishSymbol /> }, "Fish Symbol"),
(html! { <FishingHook /> }, "Fishing Hook"),
(html! { <FishingRod /> }, "Fishing Rod"),
(html! { <Flag /> }, "Flag"),
(html! { <FlagOff /> }, "Flag Off"),
(html! { <FlagTriangleLeft /> }, "Flag Triangle Left"),
Expand Down Expand Up @@ -2270,6 +2271,19 @@ pub fn IconsZ() -> Html {
let icons = [
(html! { <Zap /> }, "Zap"),
(html! { <ZapOff /> }, "Zap Off"),
(html! { <ZodiacAquarius /> }, "Zodiac Aquarius"),
(html! { <ZodiacAries /> }, "Zodiac Aries"),
(html! { <ZodiacCancer /> }, "Zodiac Cancer"),
(html! { <ZodiacCapricorn /> }, "Zodiac Capricorn"),
(html! { <ZodiacGemini /> }, "Zodiac Gemini"),
(html! { <ZodiacLeo /> }, "Zodiac Leo"),
(html! { <ZodiacLibra /> }, "Zodiac Libra"),
(html! { <ZodiacOphiuchus /> }, "Zodiac Ophiuchus"),
(html! { <ZodiacPisces /> }, "Zodiac Pisces"),
(html! { <ZodiacSagittarius /> }, "Zodiac Sagittarius"),
(html! { <ZodiacScorpio /> }, "Zodiac Scorpio"),
(html! { <ZodiacTaurus /> }, "Zodiac Taurus"),
(html! { <ZodiacVirgo /> }, "Zodiac Virgo"),
(html! { <ZoomIn /> }, "Zoom In"),
(html! { <ZoomOut /> }, "Zoom Out"),
];
Expand Down
6 changes: 3 additions & 3 deletions packages/dioxus/src/cuboid.rs
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@ pub fn Cuboid(props: CuboidProps) -> Element {
"stroke-width": "{stroke_width}",
"stroke-linecap": "round",
"stroke-linejoin": "round",
path { "d": "m21.12 6.4-6.05-4.06a2 2 0 0 0-2.17-.05L2.95 8.41a2 2 0 0 0-.95 1.7v5.82a2 2 0 0 0 .88 1.66l6.05 4.07a2 2 0 0 0 2.17.05l9.95-6.12a2 2 0 0 0 .95-1.7V8.06a2 2 0 0 0-.88-1.66Z" }
path { "d": "M10 22v-8L2.25 9.15" }
path { "d": "m10 14 11.77-6.87" }
path { "d": "M10 22v-8" }
path { "d": "M2.336 8.89 10 14l11.715-7.029" }
path { "d": "M22 14a2 2 0 0 1-.971 1.715l-10 6a2 2 0 0 1-2.138-.05l-6-4A2 2 0 0 1 2 16v-6a2 2 0 0 1 .971-1.715l10-6a2 2 0 0 1 2.138.05l6 4A2 2 0 0 1 22 8z" }
}
}
}
42 changes: 42 additions & 0 deletions packages/dioxus/src/fishing_rod.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
use dioxus::prelude::*;
#[derive(Clone, PartialEq, Props)]
pub struct FishingRodProps {
#[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 FishingRod(props: FishingRodProps) -> 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": "M4 11h1" }
path { "d": "M8 15a2 2 0 0 1-4 0V3a1 1 0 0 1 1-1h.5C14 2 20 9 20 18v4" }
circle { "cx": "18", "cy": "18", "r": "2" }
}
}
}
60 changes: 58 additions & 2 deletions packages/dioxus/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1137,7 +1137,7 @@ mod cross;
mod crosshair;
#[cfg(feature = "gaming")]
mod crown;
#[cfg(any(feature = "shapes", feature = "math", feature = "buildings"))]
#[cfg(any(feature = "shapes", feature = "math", feature = "food-beverage"))]
mod cuboid;
#[cfg(feature = "food-beverage")]
mod cup_soda;
Expand Down Expand Up @@ -1505,6 +1505,8 @@ mod fish_off;
mod fish_symbol;
#[cfg(any(feature = "sports", feature = "travel"))]
mod fishing_hook;
#[cfg(any(feature = "sports", feature = "travel"))]
mod fishing_rod;
#[cfg(any(feature = "account", feature = "social"))]
mod flag;
#[cfg(any(feature = "account", feature = "social"))]
Expand Down Expand Up @@ -4247,6 +4249,32 @@ mod zap;
feature = "weather"
))]
mod zap_off;
#[cfg(any(feature = "social", feature = "emoji"))]
mod zodiac_aquarius;
#[cfg(any(feature = "social", feature = "emoji"))]
mod zodiac_aries;
#[cfg(any(feature = "social", feature = "emoji"))]
mod zodiac_cancer;
#[cfg(any(feature = "social", feature = "emoji"))]
mod zodiac_capricorn;
#[cfg(any(feature = "social", feature = "emoji"))]
mod zodiac_gemini;
#[cfg(any(feature = "social", feature = "emoji"))]
mod zodiac_leo;
#[cfg(any(feature = "social", feature = "emoji"))]
mod zodiac_libra;
#[cfg(any(feature = "social", feature = "emoji"))]
mod zodiac_ophiuchus;
#[cfg(any(feature = "social", feature = "emoji"))]
mod zodiac_pisces;
#[cfg(any(feature = "social", feature = "emoji"))]
mod zodiac_sagittarius;
#[cfg(any(feature = "social", feature = "emoji"))]
mod zodiac_scorpio;
#[cfg(any(feature = "social", feature = "emoji"))]
mod zodiac_taurus;
#[cfg(any(feature = "social", feature = "emoji"))]
mod zodiac_virgo;
#[cfg(any(
feature = "accessibility",
feature = "layout",
Expand Down Expand Up @@ -5397,7 +5425,7 @@ pub use cross::*;
pub use crosshair::*;
#[cfg(feature = "gaming")]
pub use crown::*;
#[cfg(any(feature = "shapes", feature = "math", feature = "buildings"))]
#[cfg(any(feature = "shapes", feature = "math", feature = "food-beverage"))]
pub use cuboid::*;
#[cfg(feature = "food-beverage")]
pub use cup_soda::*;
Expand Down Expand Up @@ -5765,6 +5793,8 @@ pub use fish_off::*;
pub use fish_symbol::*;
#[cfg(any(feature = "sports", feature = "travel"))]
pub use fishing_hook::*;
#[cfg(any(feature = "sports", feature = "travel"))]
pub use fishing_rod::*;
#[cfg(any(feature = "account", feature = "social"))]
pub use flag::*;
#[cfg(any(feature = "account", feature = "social"))]
Expand Down Expand Up @@ -8507,6 +8537,32 @@ pub use zap::*;
feature = "weather"
))]
pub use zap_off::*;
#[cfg(any(feature = "social", feature = "emoji"))]
pub use zodiac_aquarius::*;
#[cfg(any(feature = "social", feature = "emoji"))]
pub use zodiac_aries::*;
#[cfg(any(feature = "social", feature = "emoji"))]
pub use zodiac_cancer::*;
#[cfg(any(feature = "social", feature = "emoji"))]
pub use zodiac_capricorn::*;
#[cfg(any(feature = "social", feature = "emoji"))]
pub use zodiac_gemini::*;
#[cfg(any(feature = "social", feature = "emoji"))]
pub use zodiac_leo::*;
#[cfg(any(feature = "social", feature = "emoji"))]
pub use zodiac_libra::*;
#[cfg(any(feature = "social", feature = "emoji"))]
pub use zodiac_ophiuchus::*;
#[cfg(any(feature = "social", feature = "emoji"))]
pub use zodiac_pisces::*;
#[cfg(any(feature = "social", feature = "emoji"))]
pub use zodiac_sagittarius::*;
#[cfg(any(feature = "social", feature = "emoji"))]
pub use zodiac_scorpio::*;
#[cfg(any(feature = "social", feature = "emoji"))]
pub use zodiac_taurus::*;
#[cfg(any(feature = "social", feature = "emoji"))]
pub use zodiac_virgo::*;
#[cfg(any(
feature = "accessibility",
feature = "layout",
Expand Down
15 changes: 5 additions & 10 deletions packages/dioxus/src/package_check.rs
Original file line number Diff line number Diff line change
Expand Up @@ -34,16 +34,11 @@ pub fn PackageCheck(props: PackageCheckProps) -> Element {
"stroke-width": "{stroke_width}",
"stroke-linecap": "round",
"stroke-linejoin": "round",
path { "d": "m16 16 2 2 4-4" }
path { "d": "M21 10V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l2-1.14" }
path { "d": "m7.5 4.27 9 5.15" }
polyline { "points": "3.29 7 12 12 20.71 7" }
line {
"x1": "12",
"x2": "12",
"y1": "22",
"y2": "12",
}
path { "d": "M12 22V12" }
path { "d": "m16 17 2 2 4-4" }
path { "d": "M21 11.127V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.729l7 4a2 2 0 0 0 2 .001l1.32-.753" }
path { "d": "M3.29 7 12 12l8.71-5" }
path { "d": "m7.5 4.27 8.997 5.148" }
}
}
}
15 changes: 5 additions & 10 deletions packages/dioxus/src/package_minus.rs
Original file line number Diff line number Diff line change
Expand Up @@ -34,16 +34,11 @@ pub fn PackageMinus(props: PackageMinusProps) -> Element {
"stroke-width": "{stroke_width}",
"stroke-linecap": "round",
"stroke-linejoin": "round",
path { "d": "M16 16h6" }
path { "d": "M21 10V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l2-1.14" }
path { "d": "m7.5 4.27 9 5.15" }
polyline { "points": "3.29 7 12 12 20.71 7" }
line {
"x1": "12",
"x2": "12",
"y1": "22",
"y2": "12",
}
path { "d": "M12 22V12" }
path { "d": "M16 17h6" }
path { "d": "M21 13V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.729l7 4a2 2 0 0 0 2 .001l1.675-.955" }
path { "d": "M3.29 7 12 12l8.71-5" }
path { "d": "m7.5 4.27 8.997 5.148" }
}
}
}
Loading