To set your own look-and-feel options, use the style
section in the Ozliveness.open
method. Here is what you can change:
faceFrame
– the color of the frame around a face:
faceReady
– the frame color when the face is correctly placed within the frame;
faceNotReady
– the frame color when the face is placed improperly and can't be analyzed.
centerHint
– the text of the hint that is displayed in the center.
textSize
– the size of the text;
color
– the color of the text;
yPosition
– the vertical position measured from top;
letterSpacing
– the spacing between letters;
fontStyle
– the style of font (bold, italic, etc.).
closeButton
– the button that closes the plugin:
image
– the button image, can be an image in PNG or dataURL in base64.
backgroundOutsideFrame
– the color of the overlay filling (outside the frame):
color
– the fill color.
Example:
To set your own look-and-feel options, use the style
section in the Ozliveness.open
method. The options are listed below the example.
Main color settings.
Main font settings.
Title font settings.
Buttons’ settings.
Toolbar settings.
Center hint settings.
Hint animation settings.
Face frame settings.
Document capture frame settings.
Background settings.
Scam protection settings: the antiscam message warns user about their actions being recorded.
SDK version text settings.
3D mask settings. The mask has been implemented in 1.2.1.
Table of parameters' correspondence:
Parameter
Description
textColorPrimary
Main text color
backgroundColorPrimary
Main background color
textColorSecondary
Secondary text color
backgroundColorSecondary
Secondary background color
iconColor
Icons’ color
Parameter
Description
textFont
Font
textSize
Font size
textWeight
Font weight
textStyle
Font style
Parameter
Description
textFont
Font
textSize
Font size
textWeight
Font weight
textStyle
Font style
Parameter
Description
textFont
Font
textSize
Font size
textWeight
Font weight
textStyle
Font style
textColorPrimary
Main text color
backgroundColorPrimary
Main background color
textColorSecondary
Secondary text color
backgroundColorSecondary
Secondary background color
cornerRadius
Button corner radius
Parameter
Description
closeButtonIcon
Close button icon
iconColor
Close button icon color
Parameter
Description
textFont
Font
textSize
Font size
textWeight
Font weight
textStyle
Font style
textColor
Text color
backgroundColor
Background color
backgroundOpacity
Background opacity
backgroundCornerRadius
Frame corner radius
verticalPosition
Vertical position
Parameter
Description
hideAnimation
Disable animation
hintGradientColor
Gradient color
hintGradientOpacity
Gradient opacity
animationIconSize
Animation icon size
Parameter
Description
geometryType
Frame shape: rectangle or oval
cornersRadius
Frame corner radius (for rectangle)
strokeDefaultColor
Frame color when a face is not aligned properly
strokeFaceInFrameColor
Frame color when a face is aligned properly
strokeOpacity
Stroke opacity
strokeWidth
Stroke width
strokePadding
Padding from stroke
Parameter
Description
cornersRadius
Frame corner radius
templateColor
Document template color
templateOpacity
Document template opacity
Parameter
Description
backgroundColor
Background color
backgroundOpacity
Background opacity
Parameter
Description
textMessage
Antiscam message text
textFont
Font
textSize
Font size
textWeight
Font weight
textStyle
Font style
textColor
Text color
textOpacity
Text opacity
backgroundColor
Background color
backgroundOpacity
Background opacity
backgroundCornerRadius
Frame corner radius
flashColor
Flashing indicator color
Parameter
Description
textFont
Font
textSize
Font size
textWeight
Font weight
textStyle
Font style
textColor
Text color
textOpacity
Text opacity
Parameter
Description
maskColor
The color of the mask itself
glowColor
The color of the glowing mask shape
minAlpha
Minimum mask transparency level. Implemented in 1.3.1
maxAlpha
Maximum mask transparency level. Implemented in 1.3.1
Previous design
New design
doc_color
-
face_color_success
faceFrame.faceReady
faceFrameCustomization.strokeFaceInFrameColor
face_color_fail
faceFrame.faceNotReady
faceFrameCustomization.strokeDefaultColor
centerHint.textSize
centerHintCustomization.textSize
centerHint.color
centerHintCustomization.textColor
centerHint.yPosition
centerHintCustomization.verticalPosition
centerHint.letterSpacing
-
centerHint.fontStyle
centerHintCustomization.textStyle
closeButton.image
-
backgroundOutsideFrame.color
backgroundCustomization.backgroundColor