|
@@ -11,6 +11,8 @@ var $input = $('#search-input input'); |
|
@@ -11,6 +11,8 @@ var $input = $('#search-input input'); |
11
|
|
11
|
|
12
|
var $clear = $('#search-input .clear-input');
|
12
|
var $clear = $('#search-input .clear-input');
|
13
|
|
13
|
|
|
|
14
|
+var $icon = $('.search-icon');
|
|
|
15
|
+
|
14
|
var $form = $('#search-form');
|
16
|
var $form = $('#search-form');
|
15
|
|
17
|
|
16
|
var $history = $('.history');
|
18
|
var $history = $('.history');
|
|
@@ -32,8 +34,10 @@ chHammer.on('tap', function() { |
|
@@ -32,8 +34,10 @@ chHammer.on('tap', function() { |
32
|
|
34
|
|
33
|
$input.on('input', function() {
|
35
|
$input.on('input', function() {
|
34
|
if ($input.val() === '') {
|
36
|
if ($input.val() === '') {
|
|
|
37
|
+ $icon.css('color','#b2b2b2');
|
35
|
$clear.addClass('hide');
|
38
|
$clear.addClass('hide');
|
36
|
} else {
|
39
|
} else {
|
|
|
40
|
+ $icon.css('color','#000');
|
37
|
$clear.removeClass('hide');
|
41
|
$clear.removeClass('hide');
|
38
|
}
|
42
|
}
|
39
|
});
|
43
|
});
|