vault-development / react-native-svg-uri

Render SVG images in React Native from an URL or static file
849 stars 334 forks source link

linearGradient fill broken #96

Open bpettijohn opened 6 years ago

bpettijohn commented 6 years ago

linearGradient fill shows as black instead of gradient. Works correctly in react-native-svg. Please advise.

<svg
  preserveAspectRatio="xMidYMid meet"
  style="23"
  viewBox="0 20 100 100"
  xmlns="http://www.w3.org/2000/svg"
>
  <defs>
    <linearGradient
      id="teallove"
      x1="0%"
      x2="100%"
      y1="0%"
      y2="0%"
    >
      <stop
        offset="0%"
        stop-color="#AAFFA9"
        stop-opacity="1"
      />
      <stop
        offset="100%"
        stop-color="#11FFBD"
        stop-opacity="1"
      />
    </linearGradient>
  </defs>
  <circle
    cx="10.394578215119932"
    cy="24.772700195838926"
    fill="url(#teallove)"
    r="5"
  />
  <circle
    cx="11.446977704934008"
    cy="35.09144111470587"
    fill="url(#teallove)"
    r="5"
  />
</svg>
ddyakovenko commented 6 years ago

why don't you write that in linearGradient issues or in react-native-svg issues?

iqqmuT commented 5 years ago

This refers most probably to issue #141 There is a fix in pull request #145