For the complete documentation index, see llms.txt. This page is also available as Markdown.

trackStatus

Internal state change during capture.

Details

It is emitted after user actions or state changes during the capture Flow.

Event: trackStatus

Type: FacephiSelphidWidgetCustomEvent<TrackStatusEvent> | CustomEvent<TrackStatusEvent>

Syntax

selphid.addEventListener('trackStatus', onTrackStatus);

Received object

The useful payload is of type SelphidTrackStatusDetail and is in event.detail.detail:

  • eventType (string): Type of event emitted.

  • currentState (string) | tapButton (string) | retriesConsumed (number) | documentPresent (boolean): Dynamic key with the state, action, or capture metadata (only those present in each emission).

Values currentState:

Value
Description

initializing

The SelphID engine is initializing.

initEngine

Engine Initialization in progress.

ready

SelphID has loaded and is ready.

analyzing

The current image is being analyzed.

previewImage

The capture preview is shown.

resetting

The internal engine is restarting.

finish

The capture has finished.

error

An error has occurred in the Flow.

end

The extraction has finished.

Values tapButton:

Value
Description

tutorial

Tutorial button pressed.

exit

Close button pressed.

repeatExtraction

Retry capture.

continueExtraction

Continue extraction.

finishExtraction

Finish extraction.

retryExtraction

Retry extraction.

switchCamera

Camera switched.

back

Go back.

Description

Allows tracking user actions and the Widget's internal state changes.

Considerations

The useful payload is in event.detail.detail (see event format).


Example

Last updated