Die text-fill-color eienskap

Die text-fill-color property spesifiseer die vulkleur van tekskarakters of hul deursigtigheid deur die waarde transparent te gebruik.

Sintaksis

cssselektor {
  text-fill-color: kleur of transparent;
}

Voorbeeld

Kom ons gee ons teks 'n gradiëntvul met deursigtigheid:

html<p>
  This is a text.
</p>
cssbody {
  width: 200px;
  height: 100px;
}
p {
  -webkit-text-fill-color: transparent;
  text-fill-color: transparent;
  font-size: 26px;
  background: linear-gradient(#c42222, #ffef5e);
  -webkit-background-clip: text;
  background-clip: text;
}

Результат:

Sien ook