1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2025-03-05 09:46:07 +00:00

fix(ui/model_r): adjust model_r confirm_properties

- change the button text based on `hold`
- make it abortable
This commit is contained in:
obrusvit 2024-10-04 17:09:27 +02:00 committed by Vít Obrusník
parent 20e408d7df
commit a3aacb7f13

View File

@ -382,12 +382,17 @@ extern "C" fn new_confirm_properties(n_args: usize, args: *const Obj, kwargs: *m
paragraphs.add(Paragraph::new(style, value)); paragraphs.add(Paragraph::new(style, value));
} }
} }
let button_text = if hold {
TR::buttons__hold_to_confirm.into()
} else {
TR::buttons__confirm.into()
};
content_in_button_page( content_in_button_page(
title, title,
paragraphs.into_paragraphs(), paragraphs.into_paragraphs(),
TR::buttons__confirm.into(), button_text,
None, Some("".into()),
hold, hold,
) )
}; };