0

I have a component with ui:inputDate when the changes
I'm trying to validate that there is a value and add error border.

dateInputReference.set("v.errors",[{message:'missing data'}]);
$A.util.addClass(dateInputReference, "sld-has-error");

This adds the error message to the date input and the styling to the html element. To get the red border I need to add the styling to the enclosing div. How can I do it?

1
  • 1
    I think the class name is slds-has-error not sld-has-error Commented Oct 24, 2017 at 10:58

1 Answer 1

-1

You can do something like below :-

<div style="{!v.errors != null ? 'border-style: solid;
    border-color:red': ''"> 

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .