I am trying to complete this (easy) task but I can't figure it out. It's easy in my head.
This is the div with icon, input and label:
<div id="datefromto" class="field text-field @if(isset($value)){{ 'active' }}@endif @if(isset($readonly)){{ 'readonly' }}@endif">
<label>{{ $label }} From:</label>
<i class="material-icons calendar-icon">access_time</i>
<input name="{{ $name }}" type="text" class="datetime" @if(isset($value))value="{{ $value }}"@endif>
</div>
I tryied this but it's no good:
$('#datefromto input[type=text]')(function(){
if ($(this).val()){
$('.calendar-icon').css("display", "none");
}
});