2
I have the following HTML:
$(".membrosClick").click(function() {
$(".membrosClick").css("width", "766px");
$(this).children().fadeToggle();
$(".listagemEsc").css("margin-left", "383px");
});
<li class="membrosClick">
<div name="Listagem de Membros" style="background-image: url('./imagens/EDGAR-GUERRA.png'); width:383px; height:849px">
<div class="editable subir">
<h2>Edgar</h2>
<h3>Guerra</h3>
<div class="bandaBarra bandaBarraBranca margin-left-65 margin-top-10 barraNone"></div>
</div>
</div>
<div class="listagemEsc p-relative">
<div class="membrosFechar"></div>
<span>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum. Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo.</span>
</div>
</li>
<li class="membrosClick">
<div name="Listagem de Membros" style="background-image: url('./imagens/ANTONIO-GUERRA.png'); width:383px; height:849px">
<div class="editable subir">
<h2>Antônio</h2>
<h3>Guerra</h3>
<div class="bandaBarra bandaBarraBranca margin-left-65 margin-top-10 barraNone"></div>
</div>
</div>
<div class="listagemEsc p-relative">
<div class="membrosFechar"></div>
<span>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum. Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo.</span>
</div>
</li>
When I click on li
he has to expand her to width: 766px
and send the div listagemEsc
for margin-left:383px
. He’s expanding to 766px only he does it at all li
, and not just the one I clicked on. I couldn’t test the rest.
Ever tried to use
$(this).css("width", "766px");
?– Luis Henrique