HI
Can we point out the field when it is required in editor screen ,Similar to Facebook.
Is it possible to achieve in Cuba.
HI
Can we point out the field when it is required in editor screen ,Similar to Facebook.
Is it possible to achieve in Cuba.
Hi,
There is a Vaadin add-on that can be used in your cuba application - Product Tour Product Tour Add-on - Vaadin Add-on Directory
First of all, create a web toolkit module and create theme extension using CUBA Studio.
Then, add org.vaadin.addons:product-tour:0.2.2
dependency to the web module in Project properties - Advanced.
In order to show custom validation notifications you can override the showValidationErrors
method in your window controller:
@Override
public void showValidationErrors(ValidationErrors errors) {
super.showValidationErrors(errors);
cancelActiveTour();
activeTour = new Tour();
activeTour.addStep(new StepBuilder()
.withAttachTo(titleField.unwrap(AbstractComponent.class))
.withTitle("Required fields")
.withText("Title is required")
.build());
activeTour.start();
}
The result will look something like this:
I’ve created a small demo: GitHub - cuba-labs/rich-validation-messages: How to use Product Tour Vaadin add-on