imagemin.optipng(),
imagemin.svgo({
plugins: [
- { cleanupIDs: { preservePrefixes: ['symbol-', 'view-'] } },
+ { cleanupIDs: { preservePrefixes: ['icon-', 'view-'] } },
{ removeViewBox: false },
{ removeDesc: false },
],
--- /dev/null
+<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16">
+ <title>Octicons (16px subset)</title>
+ <desc>Octicons v11.2.0 by GitHub - https://primer.style/octicons/ - License: MIT</desc>
+ <metadata
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
+ <rdf:RDF>
+ <cc:Work rdf:about="">
+ <dc:title>@primer/octicons</dc:title>
+ <dc:identifier>11.2.0</dc:identifier>
+ <dc:description>A scalable set of icons handcrafted with <3 by GitHub</dc:description>
+ <dc:format>image/svg+xml</dc:format>
+ <dc:creator>
+ <cc:Agent>
+ <dc:title>GitHub</dc:title>
+ </cc:Agent>
+ </dc:creator>
+ <dc:rights>
+ <cc:Agent>
+ <dc:title>Copyright (c) 2020 GitHub Inc.</dc:title>
+ </cc:Agent>
+ </dc:rights>
+ <cc:license rdf:resource="https://opensource.org/licenses/MIT" />
+ <dc:relation>https://primer.style/octicons/</dc:relation>
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <symbol id="icon-clippy" viewBox="0 0 16 16">
+ <path
+ fill-rule="evenodd"
+ d="M5.75 1a.75.75 0 00-.75.75v3c0 .414.336.75.75.75h4.5a.75.75 0 00.75-.75v-3a.75.75 0 00-.75-.75h-4.5zm.75 3V2.5h3V4h-3zm-2.874-.467a.75.75 0 00-.752-1.298A1.75 1.75 0 002 3.75v9.5c0 .966.784 1.75 1.75 1.75h8.5A1.75 1.75 0 0014 13.25v-9.5a1.75 1.75 0 00-.874-1.515.75.75 0 10-.752 1.298.25.25 0 01.126.217v9.5a.25.25 0 01-.25.25h-8.5a.25.25 0 01-.25-.25v-9.5a.25.25 0 01.126-.217z" />
+ </symbol>
+ <use href="#icon-clippy" width="16" height="16" x="0" y="0" />
+ <view id="view-clippy" viewBox="0 0 16 16" />
+</svg>
+++ /dev/null
-<svg xmlns="http://www.w3.org/2000/svg">
- <title>Octicons (subset)</title>
- <desc>Octicons v11.2.0 by GitHub - https://primer.style/octicons/ - License: MIT</desc>
- <metadata
- xmlns:dc="http://purl.org/dc/elements/1.1/"
- xmlns:cc="http://creativecommons.org/ns#"
- xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
- <rdf:RDF>
- <cc:Work rdf:about="">
- <dc:title>@primer/octicons</dc:title>
- <dc:identifier>11.2.0</dc:identifier>
- <dc:description>A scalable set of icons handcrafted with <3 by GitHub</dc:description>
- <dc:format>image/svg+xml</dc:format>
- <dc:creator>
- <cc:Agent>
- <dc:title>GitHub</dc:title>
- </cc:Agent>
- </dc:creator>
- <dc:rights>
- <cc:Agent>
- <dc:title>Copyright (c) 2020 GitHub Inc.</dc:title>
- </cc:Agent>
- </dc:rights>
- <cc:license rdf:resource="https://opensource.org/licenses/MIT" />
- <dc:relation>https://primer.style/octicons/</dc:relation>
- </cc:Work>
- </rdf:RDF>
- </metadata>
- <symbol id="symbol-clippy-16" viewBox="0 0 16 16">
- <path
- fill-rule="evenodd"
- d="M5.75 1a.75.75 0 00-.75.75v3c0 .414.336.75.75.75h4.5a.75.75 0 00.75-.75v-3a.75.75 0 00-.75-.75h-4.5zm.75 3V2.5h3V4h-3zm-2.874-.467a.75.75 0 00-.752-1.298A1.75 1.75 0 002 3.75v9.5c0 .966.784 1.75 1.75 1.75h8.5A1.75 1.75 0 0014 13.25v-9.5a1.75 1.75 0 00-.874-1.515.75.75 0 10-.752 1.298.25.25 0 01.126.217v9.5a.25.25 0 01-.25.25h-8.5a.25.25 0 01-.25-.25v-9.5a.25.25 0 01.126-.217z" />
- </symbol>
- <use href="#symbol-clippy-16" width="16" height="16" x="0" y="0" />
- <view id="view-clippy-16" viewBox="0 0 16 16" />
-</svg>
svg.setAttribute('aria-hidden', 'true')
svg.setAttribute('class', 'copy-icon')
var use = document.createElementNS('http://www.w3.org/2000/svg', 'use')
- use.setAttribute('href', window.uiRootPath + '/img/octicons.svg#symbol-clippy-16')
+ use.setAttribute('href', window.uiRootPath + '/img/octicons-16.svg#icon-clippy')
svg.appendChild(use)
copy.appendChild(svg)
;(toast = document.createElement('span')).className = 'copy-toast'