HTML/CSS: External Link Icons

Based on https://www.svgrepo.com/svg/510970/external-link. Adjust the stroke attribute to set the icon's color.

001  <!-- external-link.svg -->
002  <?xml version="1.0" encoding="utf-8"?>
003  <!-- Uploaded to: SVG Repo, www.svgrepo.com, Generator: SVG Repo Mixer Tools -->
004  <svg class="external-link-icon" width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
005  <g id="Interface / External_Link">
006  <path id="Vector" d="M10.0002 5H8.2002C7.08009 5 6.51962 5 6.0918 5.21799C5.71547 5.40973 5.40973 5.71547 5.21799 6.0918C5 6.51962 5 7.08009 5 8.2002V15.8002C5 16.9203 5 17.4801 5.21799 17.9079C5.40973 18.2842 5.71547 18.5905 6.0918 18.7822C6.5192 19 7.07899 19 8.19691 19H15.8031C16.921 19 17.48 19 17.9074 18.7822C18.2837 18.5905 18.5905 18.2839 18.7822 17.9076C19 17.4802 19 16.921 19 15.8031V14M20 9V4M20 4H15M20 4L13 11" stroke="#f7f7f7" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
007  </g>
008  </svg>

Add the icon using CSS:

001  a[href^="http"] {
002    background-image: url(/assets/external-link.svg);
003    background-position: center right;
004    background-repeat: no-repeat;
005    background-size: 1em;
006    padding-right: 1.2em;
007  }
008  a[href^="http"].suppress-icon {
009    background-image: none;
010    padding-right: 0;
011  }