No media files provided.
We want to create the following 3D cube rotation effect.
See the Pen 3D Cube Rotation by Thomas Seng Hin Mak (@makzan) on CodePen.
Given the following HTML:
<div class='box-scene'>
    <div class='box'>
        <div class='front face'>
            <img src='http://placehold.it/180x180/' alt=''>
        </div>
        <div class="side face">
            <p>This is back</p>
        </div>
    </div>
</div>
<div class='box-scene'>
    <div class='box'>
        <div class='front face'>
            <img src='http://placehold.it/180x180/' alt=''>
        </div>
        <div class="side face">
            <p>This is back</p>
        </div>
    </div>
</div>
        Hints: You canβt use percentage value in transform-origin Z axis.
You may find the source code here: