alexk111 / SVG-Morpheus

JavaScript library enabling SVG icons to morph from one to the other. It implements Material Design's Delightful Details transitions. (THIS PROJECT IS NOT MAINTAINED ANYMORE)
MIT License
2.7k stars 241 forks source link

callback can't excute #32

Open yursile opened 7 years ago

yursile commented 7 years ago

`<svg version="1.1" id="icon" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="0 0 90 90" style="enable-background:new 0 0 90 90;" xml:space="preserve">

      <g id="share2">
          <ellipse class="share1" cx="44.667" cy="33.167" rx="6" ry="5.833"/>
          <circle class="share2" cx="49.333" cy="56" r="6"/>
          <circle class="share3" cx="33.208" cy="46.792" r="5.875"/>
          <path class="share4" style="fill:none;stroke:#000000;stroke-width:4;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:10;" d="M46.595,30.333 35.667,46.333 50.083,57"/>
      </g>

`

js: var svgMorpheus = new SVGMorpheus('#icon'); svgMorpheus.to("#share1", {duration: 1000},function(){ alert("fuck") });

the morph can run correctly, but callback just can not excute

please help!