An opaque black shape can make the artwork disappear when you use it as an SVG mask. The default luminance mode uses the mask's brightness and opacity together. Set mask-type="alpha" if the shape's opacity alone should determine what shows through.
Run the same swatches through both modes
Open the editable SVG. Both rows use the same white, gray, black, and transparent swatches to mask the same yellow strip. The checkerboard shows where the strip is hidden.
| Mask swatch | Luminance | Alpha |
|---|---|---|
| Opaque white | Fully visible | Fully visible |
| Opaque gray | Partly visible | Fully visible |
| Opaque black | Hidden | Fully visible |
| Fully transparent | Hidden | Hidden |
Set the mode on the mask
Save this snippet as an SVG. With alpha, the yellow circle appears. Change only the mask type to luminance and it disappears.
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 64 64">
<defs>
<mask id="shape" mask-type="alpha">
<circle cx="32" cy="32" r="24" fill="black"/>
</mask>
</defs>
<rect width="64" height="64" fill="#ffca55" mask="url(#shape)"/>
</svg>
Keep luminance if gray in the existing mask is supposed to produce a fade. Changing it to alpha makes opaque gray reveal the artwork fully. If changing mask-type has no effect on the website, inspect the masked element for a CSS mask-mode override and reopen the exported SVG by itself. W3C mask type and overrides.