From df8bcefaaa601574292539eea03719dbc7d1e7b9 Mon Sep 17 00:00:00 2001 From: Floyd Wang Date: Thu, 2 Oct 2025 14:07:07 +0800 Subject: [PATCH] tag: Implement styled for custom style (#1319) --- crates/ui/src/tag.rs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/crates/ui/src/tag.rs b/crates/ui/src/tag.rs index c68cea6a..eeab64ba 100644 --- a/crates/ui/src/tag.rs +++ b/crates/ui/src/tag.rs @@ -215,11 +215,19 @@ impl Sizable for Tag { self } } + impl ParentElement for Tag { fn extend(&mut self, elements: impl IntoIterator) { self.children.extend(elements); } } + +impl Styled for Tag { + fn style(&mut self) -> &mut StyleRefinement { + &mut self.style + } +} + impl RenderOnce for Tag { fn render(self, _window: &mut Window, cx: &mut App) -> impl IntoElement { let bg = if self.outline {