Vectorized Rect Framing
Using 4-sliced SVG
Resize the window to see the effect.
The frame is made of 4-sliced SVG polygons. Each polygon point is anchored to a corner of the container. Polygon points are calculated by JavaScript based on the original points and the container size.