<div id="octagon"></div>
#octagon {
width: 300px;
height: 100px;
background: red;
position: relative;
}
#octagon:before {
content: "";
position: absolute;
top: 0;
left: 0;
border-bottom: 29px solid red;
border-left: 29px solid #eee;
border-right: 29px solid #eee;
width: 242px;
height: 0;
}
#octagon:after {
content: "";
position: absolute;
bottom: 0;
left: 0;
border-top: 29px solid red;
border-left: 29px solid #eee;
border-right: 29px solid #eee;
width: 242px;
height: 0;
}
let status = document.getElementsByClassName('option');
console.log(status);
for (var i = 0; i < status.length; i++) {
if ("Новый" == status[i].innerText){
status[i].setAttribute('selected', '');
console.log(status[i].innerText);
}
}
let src = document.getElementsByTagName('img')[0].src;
let button = document.getElementsByTagName('button')[0];
button.onclick = function(e) {
let box = document.querySelector('.text-box');
let box2 = document.querySelector('.box2');
box.style.background = `url(${src}) no-repeat`;
box2.innerText = src
}
}