dash-frontend: Use native <Button>s, children support

This commit is contained in:
Aleksander
2025-09-13 12:49:36 +02:00
parent c2628c0a15
commit 9efe298f65
13 changed files with 117 additions and 82 deletions

View File

@@ -3,7 +3,7 @@ use glam::Vec2;
use wgui::{
event::EventListenerCollection,
globals::WguiGlobals,
layout::Layout,
layout::{Layout, LayoutParams},
parser::{ParseDocumentParams, ParserState},
};
@@ -27,6 +27,7 @@ impl TestbedAny {
path: &path,
extra: Default::default(),
},
&LayoutParams::default(),
)?;
Ok(Self { layout, state })
}

View File

@@ -12,7 +12,7 @@ use wgui::{
event::EventListenerCollection,
globals::WguiGlobals,
i18n::Translation,
layout::{Layout, Widget},
layout::{Layout, LayoutParams, Widget},
parser::{ParseDocumentExtra, ParseDocumentParams, ParserState},
widget::{label::WidgetLabel, rectangle::WidgetRectangle},
};
@@ -81,6 +81,9 @@ impl TestbedGeneric {
path: XML_PATH,
extra,
},
&LayoutParams {
resize_to_parent: true,
},
)?;
let label_cur_option = state.fetch_widget(&layout.state, "label_current_option")?;