window.addEventListener('load', () => {
 menuArrow();
})
function menuArrow(){
    var liczba=0;
    document.querySelectorAll('.container-menu ul li ').forEach(items1 => {
          liczba++;
          items1.setAttribute("id","li"+liczba);
    })
    document.querySelectorAll('.menugornear ul li ').forEach(items1 => {
        liczba++;
        items1.setAttribute("id","li"+liczba);
  })
    
   

    document.querySelectorAll('.container-menu ul li ').forEach(items => {
             if(items.innerHTML.includes('<ul')){
                document.querySelector('#'+items.getAttribute('id')+' a').innerHTML=document.querySelector('#'+items.getAttribute('id')+' a').innerHTML+'<img style="width:10px !important;height:10px !important;margin-left:4px" src="/images/stronaGlowna/Chevron_Right.png"/>';
           //     items.innerHTML=items.innerHTML+'<img style="width:10px !important;height:10px !important;margin-left:4px" src="/images/stronaGlowna/Chevron_Right.png"/>';
             }
    })
  
  
  
    document.querySelectorAll('ul li ul li ').forEach(items => {
      if(items.innerHTML.includes('<ul')){
        items.innerHTML=items.innerHTML.replaceAll('/ul>','/ul><div class="amo"></div>');
   //   items.innerHTML=items.innerHTML+'<img style="width:10px !important;height:10px !important;margin-left:4px" src="/images/stronaGlowna/Chevron_Right.png"/>';
      }
})


  

  
  

    document.querySelectorAll('.menugornear:first-child ul li ').forEach(items => {
             if(items.innerHTML.includes('<ul')){
                document.querySelector('#'+items.getAttribute('id')+' a').innerHTML=document.querySelector('#'+items.getAttribute('id')+' a').innerHTML+'<img style="width:10px !important;height:10px !important;margin-left:4px;filter: invert(1);" src="/images/stronaGlowna/Chevron_Right.png"/>';
           //     items.innerHTML=items.innerHTML+'<img style="width:10px !important;height:10px !important;margin-left:4px;filter: invert(1);" src="/images/stronaGlowna/Chevron_Right.png"/>';
             }
    })

    document.querySelectorAll('.menu-instytut ul:first-child  li ').forEach(items => {
      if(items.innerHTML.includes('<ul')){
         items.innerHTML=items.innerHTML+'<img style="width:10px !important;height:10px !important;margin-left:4px;filter: invert(1);" src="/images/stronaGlowna/Chevron_Right.png"/>';
    //     items.innerHTML=items.innerHTML+'<img style="width:10px !important;height:10px !important;margin-left:4px;filter: invert(1);" src="/images/stronaGlowna/Chevron_Right.png"/>';
      }
})


document.querySelectorAll('.mobilemenuck-item-text  ').forEach(items => {
  if(items.innerHTML.includes('<ul')){
     document.querySelector('#'+items.getAttribute('id')+' a').innerHTML=document.querySelector('#'+items.getAttribute('id')+' a').innerHTML+'<img style="width:10px !important;height:10px !important;margin-left:4px" src="/images/stronaGlowna/Chevron_Right.png"/>';
//     items.innerHTML=items.innerHTML+'<img style="width:10px !important;height:10px !important;margin-left:4px" src="/images/stronaGlowna/Chevron_Right.png"/>';
  }
})








}