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
This commit is contained in:
@ -68,8 +68,10 @@ class IconPickerMenu extends React.PureComponent {
|
||||
if (!c) return;
|
||||
|
||||
// Nice and dirty hack to display the icons
|
||||
c.querySelectorAll('button.emoji-mart-emoji > span').forEach(elem => {
|
||||
elem.innerHTML = `<i class="fa fa-${elem.parentNode.getAttribute('title')}"></i>`;
|
||||
c.querySelectorAll('button.emoji-mart-emoji > img').forEach(elem => {
|
||||
const newIcon = document.createElement('span');
|
||||
newIcon.innerHTML = `<i class="fa fa-${elem.parentNode.getAttribute('title')} fa-hack"></i>`;
|
||||
elem.parentNode.replaceChild(newIcon, elem);
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@ -344,4 +344,8 @@
|
||||
height: 22px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.fa-hack {
|
||||
margin: 0 auto;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user