hi,
I try a click event in vaadin 14 . when I click the button.
it will also trigger the layout click.
Can I make it only trigger the button click ?
thanks
@Route(value = “test” , layout = MainView.class )
public class testView extends VerticalLayout {
public testView() {
Button btn = new Button();
btn.getElement().addEventListener("click",e->{
System.out.println("button Click");
});
this.getElement().addEventListener("click",e->{
System.out.println("layout Click");
});
this.add(btn);
}
}