[pdm-devel] [PATCH yew-comp 7/8] meter label: add option to align the icon on the right

Dominik Csapak d.csapak at proxmox.com
Tue Sep 23 11:51:10 CEST 2025


like in `StatusRow`

Signed-off-by: Dominik Csapak <d.csapak at proxmox.com>
---
 src/meter_label.rs | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/src/meter_label.rs b/src/meter_label.rs
index 14ef8a4..e7d421b 100644
--- a/src/meter_label.rs
+++ b/src/meter_label.rs
@@ -70,6 +70,11 @@ pub struct MeterLabel {
     #[prop_or_default]
     #[builder]
     pub animated: bool,
+
+    /// If set to `true`, places the icon on the right side instead of the left
+    #[prop_or_default]
+    #[builder]
+    pub icon_right: bool,
 }
 
 impl MeterLabel {
@@ -127,7 +132,8 @@ impl Component for ProxmoxMeterLabel {
         let text_row = StatusRow::new(props.title.clone())
             .class(AlignItems::Baseline)
             .status(status)
-            .icon_class(props.icon_class.clone());
+            .icon_class(props.icon_class.clone())
+            .icon_right(props.icon_right);
 
         Container::new()
             .with_std_props(&props.std_props)
-- 
2.47.3





More information about the pdm-devel mailing list