Skip to main content
Pete_Norris
February 22, 2024
Question

Creating a 'layered' shadow that responds to auto layout

  • February 22, 2024
  • 4 replies
  • 1044 views

Hi All,
Trying to create a drop shadow that has a fill AND a stroke.
Drop shadow doesn’t support this as far as I can see, so was thinking about a background layer. BUT… It would need to resize when the top layer resizes (top layer uses auto-layout).
Prefer a native way to do this, but fine to use plugin if needed.

Top image below is default, and the bottom image shows what I don’t want happening when the content changes.

Thanks

This topic has been closed for replies.

4 replies

Pete_Norris
February 22, 2024

Nailed in (Kinda)

  • Make the auto-layout frame ‘clip content’
  • Use 2 shadow (with no blur)
  • on the background use spread to make bigger

A bit of tweaking and the desired effect is there.

dennsi
Active Member
February 22, 2024

Wrap two Auto Layout frames inside an Auto Layout Component. The background layer uses absolute position. Most important part is to link the text layers with the Text property so the change has an effect on the background layer.

Feel free to duplicate this file to your draft to take a closer look:

Figma – 22 Feb 24

tank666
February 22, 2024
Auto Layout Frame
  Auto Layout Frame (with fill and stroke)
    Text
  Rectangle (with fill and stroke, in absolute position, with top and bottom and left and right constraints)
UX/UI designer. Figma expert. Creator and developer of plugins and widgets for Figma and FigJam. Check out my resources in Figma Community: figma.com/@tank
Pete_Norris
February 22, 2024

Really appreciate you reaching out, although not entirely sure what you mean by linking the text layers with the text property to affect bg layer.

My solution using a drop shadow appreciate not as versatile, but doing what I need