code
code copied to clipboard
[Web/css/figma] Figma autolayout stretch with padding, the padding should not effect the final size. while `flex: 1`
Origin design
source: https://www.figma.com/file/HSozKEVWhh8saZa2vr1Nxd/code.grida.co-(design-to-code)?node-id=734%3A11411
Generated

The problem when using padding
on
off

Reference
https://stackoverflow.com/questions/37785345/how-to-get-flexbox-to-include-padding-in-calculations