I need to change the color of a specific part of a graphicImage when a button is clicked. I am using JSF, Primefaces, and CSS.
I positioned the image using:
<h:graphicImage url="/resources/imgs/img.png" style="margin-top: 15%; width: 100%;"/>
I tried to put a primefaces p:panel inside the graphicImage:
<h:graphicImage url="/resources/imgs/img.png" style="margin-top: 15%; width: 100%;" >
<p:panel style="background-color: red;"/>
</h:graphicImage>
But it does not show up inside the image. Is it possible to put something "inside" the image? Using this, when the page is resized, the component should resize within the image.