chore(tests,eckhart): confirm_output menus
What changed, and why it matters
This commit is a test-only/internal UI change for the Trezor firmware. It adds a flag called has_flow_menu to a screen component and marks three screens in the confirm_output flow with that flag. The flag is only used to expose menu state to automated tests/debuglink, and does not change user-facing behavior or fix any security issue.
No security action needed. Treat as normal test infrastructure/maintenance change.
Security signals we found
No strong security signals were identified.
Evidence from the diff
The patch adds a has_flow_menu boolean field to the Eckhart layout TextScreen Rust struct, initializes it to false, provides a with_flow_menu() builder method, and serializes it via debuglink. It then calls .with_flow_menu() on three TextScreen instances in new_confirm_output(). The commit message labels it as a chore(tests,eckhart) and explicitly says [no changelog]. The TODO comment states the flag is temporary scaffolding for old-style swipe-flow menus until they are replaced with new external menus.
Changed components
core/embed/rust/src/ui/layout_eckhart/firmware/text_screen.rscore/embed/rust/src/ui/layout_eckhart/flow/confirm_output.rsInspect captured patch +18 / −0
diff --git a/core/embed/rust/src/ui/layout_eckhart/firmware/text_screen.rs b/core/embed/rust/src/ui/layout_eckhart/firmware/text_screen.rs
index ed75b5bd..91f93567 100644
--- a/core/embed/rust/src/ui/layout_eckhart/firmware/text_screen.rs
+++ b/core/embed/rust/src/ui/layout_eckhart/firmware/text_screen.rs
@@ -41,9 +41,12 @@ pub struct TextScreen<T> {
action_bar: Option<ActionBar>,
page_limit: Option<u16>,
background: Option<ScreenBackground>,
+
// runtime visibility flags
show_action_bar: bool,
show_page_counter: bool,
+
+ has_flow_menu: bool,
// TODO: swipe handling
// TODO: animations
}
@@ -71,6 +74,7 @@ where
background: None,
show_action_bar: false,
show_page_counter: false,
+ has_flow_menu: false,
}
}
@@ -106,6 +110,16 @@ where
self
}
+ // TODO: currently used to traverse old style (aka non-"external" menus)
+ // which are implemented as part of swipe flows.
+ // Once we have eventually replaced all these with new style "external menu",
+ // we should get rid of this flag and the related debuglink code.
+ pub fn with_flow_menu(mut self) -> Self {
+ // Allow visiting this menu automatically by tests
+ self.has_flow_menu = true;
+ self
+ }
+
fn update_page(&mut self, page_idx: u16) {
self.content.change_page(page_idx);
let pager = self.content_pager();
@@ -368,5 +382,6 @@ where
t.int("page_limit", page_limit as i64);
}
t.int("page_count", self.content.pager().total() as i64);
+ t.bool("has_flow_menu", self.has_flow_menu);
}
}
diff --git a/core/embed/rust/src/ui/layout_eckhart/flow/confirm_output.rs b/core/embed/rust/src/ui/layout_eckhart/flow/confirm_output.rs
index d28729d3..3d277ca0 100644
--- a/core/embed/rust/src/ui/layout_eckhart/flow/confirm_output.rs
+++ b/core/embed/rust/src/ui/layout_eckhart/flow/confirm_output.rs
@@ -283,6 +283,7 @@ pub fn new_confirm_output(
TextScreen::new(main_paragraphs.into_paragraphs().with_placement(
LinearPlacement::vertical().with_spacing(theme::TEXT_VERTICAL_SPACING),
))
+ .with_flow_menu()
.with_header(Header::new(title.unwrap_or(TString::empty())).with_menu_button())
.with_subtitle(subtitle.unwrap_or(TString::empty()))
.with_hint(Hint::new_page_counter())
@@ -320,6 +321,7 @@ pub fn new_confirm_output(
.into_paragraphs()
.with_placement(LinearPlacement::vertical()),
)
+ .with_flow_menu()
.with_header(Header::new(TR::words__send.into()).with_menu_button())
.with_action_bar(ActionBar::new_double(
Button::with_icon(theme::ICON_CHEVRON_UP),
@@ -385,6 +387,7 @@ pub fn new_confirm_output(
.into_paragraphs()
.with_placement(LinearPlacement::vertical()),
)
+ .with_flow_menu()
.with_header(
Header::new(summary_title.unwrap_or(TR::words__title_summary.into()))
.with_menu_button(),
Why this scored 15/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.