Answered
04 Apr 2018
in reply to
Missing user
Link to this post
Hi Eva!
I've actually come across something similar to this requirement whilst using TPC.
You will need to modify the img tag inside the figure tag, as shown below:
<figure>
<img width="100%" height="@Model.ImageDisplayHeight" data-tpc-role="image-view" data-tpc-readonly-value="@("data:image/png;base64," + Model.Value)" src="@("data:image/png;base64," + Model.Value)">
<figcaption>@Model.ImageCaption</figcaption>
</figure>
Notice the change in the width property to "100%" instead of the default. This should set the width of the image to be 100% of whatever container it is in.
You can also update this in the template for both the LabelPosition of Left and Top (if required).
Just a word of warning - the images, when uploaded, get compressed to a 144x144 size. If you span the width 100%, it will look blurry/pixelated potentially.
I hope this helps!
Thanks!
Matt
Last modified on 04 Apr 2018 16:04 by Missing user