add queryselectorall for second condition