There is a html code
<div class="choose-ral"></div> <div class="option option-image"> <ul> <li data-value="1366" class=""></li> <li data-value="1368" class=""></li> <li data-value="1369" class="selected"></li> </ul> </div>
When you click on any of the elements $ ('. Option-image ul li'). Click to hide the block $ ('. Choose-ral'). Hide ('slow'); but hide only if it is not <li data-value="1369" class="selected">
I tried this code
$('.option-image ul li').click(function() { if ($('li[data-value=1386]').not('.selected')) { $('.choose-ral').hide('slow'); } });
The element is hidden, but when you click on any of the li in that isle and .select