e => e[1].toUpperCase()
function(e) { return e[1].toUpperCase(); }
const star = `
<span>
<svg width="15" height="13" viewBox="0 0 15 13" fill="none" xmlns="http://www.w3.org/2000/svg">
<path
d="M7.49777 0L9.60005 4.23718L14.2772 4.92164L10.8875 8.22991L11.6861 12.8908L7.49777 10.6907L3.30949 12.8908L4.10802 8.22991L0.718262 4.92164L5.41176 4.23718L7.49777 0Z"
fill="#FFCD1D"
/>
</svg>
</span>`;
const createStars = (num) => star.repeat(num);
document.querySelector('.cards').addEventListener(
'click',
(e) => {
if (!e.target.matches('.card')) {
return;
}
document.querySelectorAll('.card.active').forEach(
(c) => c.classList.remove('active')
);
if (e.target.previousElementSibling) {
e.target.previousElementSibling.classList.add('active');
}
if (e.target.nextElementSibling) {
e.target.nextElementSibling.classList.add('active');
}
},
);
new Date('0001-01-01 00:00:00');
// Date Mon Jan 01 0001 00:00:00 GMT+0230 (Москва, стандартное время)
new Date('0001-01-01 00:00:00Z');
// Date Mon Jan 01 0001 02:30:17 GMT+0230 (Москва, стандартное время)