Merge branch 'goldendemise-develop-patch-71514' into 'develop'

Allow icon picker to work properly for promo panel items:  patch 71514

See merge request soapbox-pub/soapbox-fe!1027
improve-ci
Alex Gleason 2022-02-04 17:53:52 +00:00
commit a229f77f5d
2 zmienionych plików z 8 dodań i 2 usunięć

Wyświetl plik

@ -68,8 +68,10 @@ class IconPickerMenu extends React.PureComponent {
if (!c) return; if (!c) return;
// Nice and dirty hack to display the icons // Nice and dirty hack to display the icons
c.querySelectorAll('button.emoji-mart-emoji > span').forEach(elem => { c.querySelectorAll('button.emoji-mart-emoji > img').forEach(elem => {
elem.innerHTML = `<i class="fa fa-${elem.parentNode.getAttribute('title')}"></i>`; const newIcon = document.createElement('span');
newIcon.innerHTML = `<i class="fa fa-${elem.parentNode.getAttribute('title')} fa-hack"></i>`;
elem.parentNode.replaceChild(newIcon, elem);
}); });
} }

Wyświetl plik

@ -344,4 +344,8 @@
height: 22px; height: 22px;
text-align: center; text-align: center;
} }
.fa-hack {
margin: 0 auto;
}
} }