1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
//! `InputOtp` builder struct — one-time passcode digit input. /// An OTP input: individual digit boxes in a row. #[must_use] pub struct InputOtp { pub(crate) length: usize, } impl InputOtp { pub fn new(length: usize) -> Self { Self { length: length.max(1), } } }