title: How to use regular expressions to match and replace more complex html tag？
body: <p>How can I use regular expressions to match all tags with a style attribute and a color value, then extract their color value and replace the tag with &lt;color=colorValue&gt;content, please help me, thank you</p>
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-js lang-js prettyprint-override"><code>//original tag
  // &lt;p style="color:#ffffff;"&gt;content&lt;/p&gt;
  // &lt;span style="color:#ffffff;"&gt;content&lt;/span&gt;
  // &lt;i style="color:#ffffff;"&gt;content&lt;/i&gt;
  //...
  
  
  // expect replace tag
  //&lt;color=#ffffff&gt;content&lt;/color&gt;</code></pre>
  </div>
  </div>
  </p>