condition.distance

This component checks whether the sent coordinates match the ones that you specified.

For example, you want a Toloker to take a photo of a specific place. The condition.distance component checks whether the photo was taken at the location that you specified.

The device coordinates are sent using the data.location component. You can use it without the condition.distance component if you need to read a Toloker's device coordinates without comparing them to the specified ones.

View example
Components used in the example

Component properties

NameTypeDescription
type*"@toloka/condition.distance"Set component type.
fromstringThe coordinates that will be compared to the coordinates from the to property.
hintstringValidation error message that a Toloker will see.
maxnumberThe distance in meters by which the specified and sent coordinates may differ.
tostringThe coordinates that will be compared to the coordinates from the from property.
Contact support

Last updated: July 6, 2023

Introduction
Getting started
Important tips
Useful recommendations
Working with Toloka
Projects
Pools
Tasks
Results
Project analysis
Toloka settings
Task interface
Template Builder
HTML/CSS/JS editor
Help and support
FAQTroubleshootingSupportGlossary