NO BUG: Icon element: using SVG stretches height of container div

Browser: Chrome 114.0.5735.90 (Official Build) (64-bit)
OS: Linux Mint 21.1
URL: Bricks SVG Testing • Bestattungen Jeckel •
Video: Bricks 1.8 beta3: strange container div size issues with SVG icon element - YouTube
Bricks Version: 1.8 beta3

Steps to Reproduce:

  1. Start a new page
  2. Add section
  3. Add div inside section > container
  4. Add icon inside div
  5. In Libraries dropdown, select SVG
  6. Pick an SVG

The SVG’s parent div has strange height issues. It has some white space above the SVG and a larger white space at the bottom. The larger you make the svg, the smaller the top “padding” / white space gets until it’s 0.

Hey @mr.matt.eastwood,

thanks for your report.

Please set your icon’s display property to block and you should be good to go. By default the SVG is an inline element and the space you see is coming from the inherited line-height.

Best,

André

Cripes. Thanks! Sorry for wasting your time o.O :slight_smile: