- Newest
- Most votes
- Most comments
Hello,
You can add onsubmit validation and show an error message.
This code sample shows how to do it for <crowd-keypoint> https://github.com/aws-samples/amazon-a2i-sample-task-uis/blob/master/images/keypoint-additional-answer-validation.liquid.html
It should be straightforward to re-use that code for <crowd-bounding-box> but please let me know if you get stuck.
Thanks,
Sam
Thanks for the response. Your link was really helpful, this is the javascript code I ended up using to achieve what I wanted. I just check if one and only one label is being submitted, otherwise i return an error to the user and prevent them from submitting the hit.
For anyone looking to do this, you also need to add <div id="errorBox"></div> to the top of the crowd-form.
https://gist.github.com/SamBahrami/c1bfbbd85b5fb87befca553c3d18d7cb
Relevant content
- asked 3 years ago
- AWS OFFICIALUpdated 2 years ago
- AWS OFFICIALUpdated a year ago
- AWS OFFICIALUpdated 9 months ago
- AWS OFFICIALUpdated 3 years ago