Fixed Editor / Smilies Problem

Bryan

Active member
Affected version
2.0
Here's the problem:

problem.webp

These smilies are made up from sprites, the next smilie is just starting to show at the bottom. This only happens in the editor and only on certain smilies, once posted they display correctly as per image:

posted.webp

This appears to be the offending css:

Code:
.fr-view img.fr-draggable, .fr-view .bbImage {
    max-width: 100%;
    height: auto;
}

Removing the automatic height seems to fix it.
 
I'm not seeing this here on our own smilies, and our smilies are essentially a massive single column of sprites, so if it were to happen then it certainly probably would happen here.

Can you show us exactly how one of the affected smilies is set up?
 
Can you show us exactly how one of the affected smilies is set up?

Here is the entry for the smilie used in the images above:

smilie.webp

This is not a new set of smilies added, they were originally used in XF1 and had no errors there.

I can confirm that both the sprite positions and dimensions are correct.

As said previously, they display in every other area (admin panel, help page and posts) perfectly, it is only in the editor where this problem arises, disabling the auto height has cured it for me and appears to have no adverse effects with any other smilies.
 
The height is defined correctly in .smilie--sprite.smilie--sprite232 but then cancelled out by the height:auto, removing the height:auto forces it to revert back to the correctly defined height and fixes the problem.

If you are having problems reproducing this, I could send you the sprite image, you have the settings for it already.
 
It's ok, I've made a small tweak for the next release which should prevent that code from overriding the smilie height value.
 
Back
Top Bottom