node-projects / web-component-designer

A Designer for HTML Components or Pages in a WebComponent
https://node-projects.github.io/web-component-designer-demo/index.html
MIT License
136 stars 16 forks source link

3D Transforms not respected correctly #407

Open jogibear9988 opened 7 months ago

jogibear9988 commented 7 months ago

use following html:

      <div style="position:absolute;left:107px;top:191px;width:220px;height:134px;">
          <button style="width:80px;height:30px;position:absolute;left:58px;top:50px;">Button</button>
      </div>

and css:

    button {

        transform: translateZ(50px);
    }
    div {
        perspective: 180px;
        transform-style: preserve-3d;
    }
image
jogibear9988 commented 7 months ago

https://css-tricks.com/how-css-perspective-works/

jogibear9988 commented 7 months ago

https://stackoverflow.com/questions/35654828/javascript-matrix-operations-for-css-transform-perspective