VARIANT show selected option

In my variant picker, I want it to not only underline the selected option (alrdy done) but also say it above the buttons.

here is my edited code:

<legend class="form__label" style="font-size: 10px; text-transform: uppercase;">
            {{ option.name }}: <b>{{ option.selected_value }}</b>
</legend>

this makes it show the first selected value but it doesn’t update whenever u select another.

here is a screenshot of how it looks so you can understand the desired outcome:

Hi, @designedbymg

After selecting a new size, you should update the value above.

how do i update the value above??

Find the place to switch size in the code and update it with JavaScript.

If you will unable to implement it then I’m happy to do this for you, let me know.