window.addEventListener('load' ,() =>{
    checkdenandrep();
    checkdenandrep1();
})
function checkdenandrep(){
    liczba=0;
    document.querySelectorAll('.grid-dendrocontent .dendro-art .blog-items .item-content p,.grid-dendrocontent .dendro-art .blog-items .item-content div').forEach(dn => {
        liczba++;     
        dn.id='gx'+liczba;
        dn.classList.add('dpol');
    })
}
function checkdenandrep1(){
    document.querySelectorAll('.grid-dendrocontent  .dendro-art .blog-items .item-content p,.grid-dendrocontent  .dendro-art .blog-items .item-content div').forEach(dn => {
        if(dn.innerHTML.includes('Dendrob') && dn.innerHTML.includes('vol')){

          var id=  dn.id.replace('gx','');
          document.querySelector('#gx'+id).classList.add('grutx');
          var id1=id-1;
          document.querySelector('#gx'+id1).classList.add('grut');
            
          

        }
    })
    document.querySelectorAll('.dpol').forEach(dpols => {
           var poles= dpols.innerHTML;
           if(poles.includes('Dendro') && poles.includes('Full')){
             dpols.innerHTML=dpols.innerHTML.replace('Full','<p>Full').replace('f)','f)</p>').replaceAll('span','p');
           }


    })
  
    
}