Shadow on ADD SVGs is built-in.

Created on 18 April 2024, about 1 year ago

Problem/Motivation

I have been trying to find where to override the drop shadow on the SVG ADD buttons within CSS but cannot find it.

With our white page background the shadow just looks a bit messy.

The recent addition of the ability to choose the backed edit colour clearly extends to the SVG ADD buttons and that's a super feature but I don't think the module should impose any kind of decorative styling, especially built into the SVGs themselves.

Potential SVG lines

Could it be that it's been built into the SVG itself via the lines which read...

...
  <feFlood flood-opacity="0" result="BackgroundImageFix"></feFlood>
      <feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0"
        result="hardAlpha"></feColorMatrix>
      <feOffset></feOffset>
      <feGaussianBlur stdDeviation="2.5"></feGaussianBlur>
      <feComposite in2="hardAlpha" operator="out"></feComposite>
...
<feBlend mode="normal" in2="BackgroundImageFix" result="effect1_dropShadow_21_2236"></feBlend>
      <feBlend mode="normal" in="SourceGraphic" in2="effect1_dropShadow_21_2236" result="shape"></feBlend>
...

If my theory is correct then I should like to suggest removing all of the this hard-coded blurring and blending.

The full SVG

<svg width="50" height="50" viewBox="0 0 50 50" fill="none" xmlns="http://www.w3.org/2000/svg">
  <g filter="url(#filter0_d_21_2236)">
    <circle cx="25" cy="25" r="20" fill="currentColor"></circle>
  </g>
  <path d="M25 17V33" stroke="white" stroke-width="2" stroke-linecap="round"></path>
  <path d="M33 25L17 25" stroke="white" stroke-width="2" stroke-linecap="round"></path>
  <defs>
    <filter id="filter0_d_21_2236" x="0" y="0" width="50" height="50" filterUnits="userSpaceOnUse"
      color-interpolation-filters="sRGB">
      <feFlood flood-opacity="0" result="BackgroundImageFix"></feFlood>
      <feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0"
        result="hardAlpha"></feColorMatrix>
      <feOffset></feOffset>
      <feGaussianBlur stdDeviation="2.5"></feGaussianBlur>
      <feComposite in2="hardAlpha" operator="out"></feComposite>
      <feColorMatrix type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.25 0"></feColorMatrix>
      <feBlend mode="normal" in2="BackgroundImageFix" result="effect1_dropShadow_21_2236"></feBlend>
      <feBlend mode="normal" in="SourceGraphic" in2="effect1_dropShadow_21_2236" result="shape"></feBlend>
    </filter>
  </defs>
</svg>
✨ Feature request
Status

Active

Version

1.6

Component

Code

Created by

🇬🇧United Kingdom SirClickALot Somerset

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024