# Image rendering issue under custom CSS

**URL:** <https://meta.discourse.org/t/image-rendering-issue-under-custom-css/366000>\
**Category:** Product Support\
**Created:** [May 13, 2025, 9:59pm UTC](https://meta.discourse.org/t/image-rendering-issue-under-custom-css/366000 "2025-05-13T21:59:20Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

**Author:** ![robbie.morrison](https://avatars.discourse-cdn.com/v4/letter/r/c5a1d2/32.png) [@robbie.morrison](https://meta.discourse.org/u/robbie.morrison)\
**Post date:** [May 13, 2025, 9:59pm UTC](https://meta.discourse.org/t/image-rendering-issue-under-custom-css/366000/1 "2025-05-13T21:59:20Z")

</div>

Following on from the topic below (I would have continued there but that topic is now closed):

> [@Add border to image](https://meta.discourse.org/t/add-border-to-image/363471):
>
> Hello all Can I add a thin border to a JPG image without resorting to a theme component? I want to keep this simple and avoid, for instance, this component: I have tried every variation of the img tag that I can think of. The only thing that worked was to embed the image in a kbd tag, but that is a bit odd. This is really what I want to write: \<img src="upload://jIMXtLgb7enbLUiahXVT1Jz14n4.jpeg" alt="photo showing derelict medium voltage power pole" width="75%" style="border: 1px …

The rendering of a&nbsp;custom CSS‑styled image file seems to have a small bug&nbsp;— namely the **right‑side** 1px black solid border is not displayed. Shrinking the image to 95% fixes the problem. The custom CSS is `border : 1px solid black`. The editing preview renders correctly&nbsp;— but the live version does not. An example can be found [here](https://forum.openmod.org/t/3102/6). As I&nbsp;said, this is a&nbsp;small bug, but one probably worth fixing. TIA.

I&nbsp;can avoid this problem by also setting `width : 98%` but I&nbsp;don’t think I should have to do that? Any thoughts?

---

_[View the full topic](https://meta.discourse.org/t/image-rendering-issue-under-custom-css/366000)._
