This is trigger action for taking biometric authentication. Both iOS and Android is using Fingerprint/Touch ID or Face Recognition/Face ID sensor depending on what sensor are available on the device. You need to add a reference to "Fuse.Auth" in your project file to use this feature.

Example

The following example shows how to use it:

    <JavaScript>
        var Observable = require('FuseJS/Observable');
        var status = Observable();
        var statusMessage = Observable();

        module.exports = {
            status,
            statusMessage
            resultHandler: function(data) {
                status.value = data.result; // bool value indicating whether true value when it succeed or false value if it failed
                statusMessage.value = data.message;
            }
        };
    </JavaScript>
    <Panel>
        <Button Text="Sign In" Alignment="Center">
            <Clicked>
                <Authenticate PromptMessage="We need your biometric data for Sign In" Handler="{resultHandler}" />
            </Clicked>
        </Button>
    </Panel>

When Using FaceID on iOS, it is mandatory to add description about why you need authentication using FaceID. You can add the description by adding this config on your unoproj file

    "iOS": {
        "PList": {
            "NSFaceIDUsageDescription": "Require access to FaceID for authenticating"
        }
    }

Location

Namespace
Fuse
Package
Fuse.Auth 2.9.1
Show Uno properties and methods

Interface of Authenticate

PromptMessage : string ux

String message to inform user on why you need biometric data. This message only applicable for fingerprint scan

Inherited from TriggerAction

AtProgress : float ux

A value between 0 and 1 for when the action should be performed. Alternative to Delay.

Delay : float ux

The number of seconds after the start of the trigger that the action should be performed.

TargetNode : Node ux

The node that the action targets. If not specified then the enclsoing Trigger will be used. Several triggers can look for a target starting from this point. Some triggers require a Target to be specified.

Unroot uno

Called when the owner of this object is unrooted. This gives an action to cleanup resources or cancel pending actions.

Inherited from PropertyObject

Inherited from object

Attached UX Attributes

GlobalKey (attached by Resource) : string ux

The ux:Global attribute creates a global resource that is accessible everywhere in UX markup.

Implemented Interfaces