@@ -3,6 +3,8 @@ use iced::widget;
33use super :: PADDING ;
44use super :: { HeadingLevel , heading} ;
55
6+ const ICON_SIZE : f32 = 32.0 ;
7+
68// pub struct ResultList<Message> {
79// selected_index: usize,
810// rows: Vec<ListRow<Message>>,
@@ -93,18 +95,20 @@ where
9395 . into ( )
9496 } )
9597 . width ( iced:: Shrink )
96- . height ( iced:: Length :: Fixed ( 32.0 ) ) ; // i dont like this
98+ . height ( iced:: Length :: Fixed ( ICON_SIZE ) ) ; // i dont like this
9799
98100 row_widget = row_widget. push ( icon_widget) ;
99101 row_widget = row_widget. push ( widget:: space ( ) . width ( iced:: Length :: Fixed ( PADDING ) ) ) ;
100102
101- let text_widget = widget:: container (
103+ let mut text_area = widget:: column ( vec ! [ ] ) ;
104+
105+ let main_name = widget:: container (
102106 heading ( HeadingLevel :: H3 , value. text , None )
103107 . align_x ( iced:: Left )
104108 . align_y ( iced:: Alignment :: Center )
105109 . width ( iced:: Fill ) ,
106110 ) ;
107- row_widget = row_widget . push ( text_widget ) ;
111+ text_area = text_area . push ( main_name ) ;
108112
109113 let subtext_widget = widget:: container (
110114 heading (
@@ -115,7 +119,9 @@ where
115119 . align_x ( iced:: Right )
116120 . align_y ( iced:: Alignment :: Center ) ,
117121 ) ;
118- row_widget = row_widget. push ( subtext_widget) ;
122+ text_area = text_area. push ( subtext_widget) ;
123+
124+ row_widget = row_widget. push ( text_area) ;
119125
120126 widget:: container (
121127 widget:: button ( row_widget)
@@ -130,7 +136,7 @@ where
130136 match status {
131137 widget:: button:: Status :: Hovered => {
132138 button_style =
133- button_style. with_background ( ext_pallet. primary . weak . color ) ;
139+ button_style. with_background ( ext_pallet. secondary . weak . color ) ;
134140 }
135141 widget:: button:: Status :: Active | widget:: button:: Status :: Pressed => {
136142 button_style = button_style. with_background ( iced:: color!( 0 , 0 , 0 , 0.0 ) ) ;
0 commit comments