From 08243e94c72fd39df0ad11714d0678efaf69a823 Mon Sep 17 00:00:00 2001 From: Naman Garg <155433377+naman-crabnebula@users.noreply.github.com> Date: Wed, 10 Jul 2024 05:48:38 +0530 Subject: [PATCH] feat(biometrics): Improve Rust API docs (#1532) * Improve Rust API docs * Add changes file --- .changes/biometric-auth-options-docs.md | 5 +++++ plugins/biometric/src/models.rs | 13 +++++++------ 2 files changed, 12 insertions(+), 6 deletions(-) create mode 100644 .changes/biometric-auth-options-docs.md diff --git a/.changes/biometric-auth-options-docs.md b/.changes/biometric-auth-options-docs.md new file mode 100644 index 00000000..51d5fc73 --- /dev/null +++ b/.changes/biometric-auth-options-docs.md @@ -0,0 +1,5 @@ +--- +"biometric": patch +--- + +Provide more context to the `AuthOptions` in the Biometric Plugin for Rust API documentation. diff --git a/plugins/biometric/src/models.rs b/plugins/biometric/src/models.rs index e4fceedc..49c84300 100644 --- a/plugins/biometric/src/models.rs +++ b/plugins/biometric/src/models.rs @@ -7,16 +7,17 @@ use serde::{Deserialize, Serialize}; #[derive(Debug, Default, Serialize)] #[serde(rename_all = "camelCase")] pub struct AuthOptions { + /// Enables authentication using the device's password. This feature is available on both Android and iOS. pub allow_device_credential: bool, - /// iOS only. - pub fallback_title: Option, - /// iOS only. + /// Label for the Cancel button. This feature is available on both Android and iOS. pub cancel_title: Option, - /// Android only. + /// Specifies the text displayed on the fallback button if biometric authentication fails. This feature is available iOS only. + pub fallback_title: Option, + /// Title indicating the purpose of biometric verification. This feature is available Android only. pub title: Option, - /// Android only. + /// SubTitle providing contextual information of biometric verification. This feature is available Android only. pub subtitle: Option, - /// Android only. + /// Specifies whether additional user confirmation is required, such as pressing a button after successful biometric authentication. This feature is available Android only. pub confirmation_required: Option, }