Gentleface › Design › color-switch
color-switch icon
color-switchColor switch: swap colors, swap foreground background. Drawn on the 16 px grid. Free SVG, PNG and code, MIT licensed.
Code line-round
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16" fill="currentColor" aria-hidden="true"><path d="M2.556 12.4C2.079 11.81 1.708 11.16 1.443 10.45C1.191 9.775 1.046 9.078 1.009 8.359C0.963 7.457 1.087 6.578 1.381 5.723C1.701 4.793 2.195 3.967 2.863 3.244C3.532 2.522 4.318 1.966 5.221 1.575C6.051 1.216 6.917 1.025 7.82 1.002C8.584 0.983 9.33 1.085 10.06 1.31C10.833 1.548 11.544 1.909 12.192 2.394C12.84 2.879 13.388 3.458 13.835 4.133C14.257 4.77 14.566 5.457 14.763 6.194C14.799 6.33 14.784 6.457 14.715 6.575C14.647 6.693 14.545 6.77 14.409 6.806C14.399 6.809 14.39 6.811 14.38 6.813C14.199 6.702 14.011 6.601 13.816 6.511C13.809 6.492 13.802 6.473 13.797 6.452C13.628 5.82 13.363 5.231 13.001 4.686C12.618 4.107 12.149 3.61 11.593 3.195C11.038 2.779 10.428 2.47 9.765 2.266C9.14 2.073 8.5 1.985 7.846 2.002C7.072 2.022 6.329 2.186 5.618 2.493C4.844 2.828 4.17 3.305 3.597 3.924C3.024 4.543 2.6 5.251 2.326 6.049C2.074 6.781 1.968 7.534 2.008 8.308C2.04 8.924 2.163 9.522 2.38 10.1C2.607 10.709 2.925 11.266 3.334 11.771C3.742 12.277 4.22 12.705 4.768 13.055C5.288 13.387 5.846 13.634 6.442 13.794C6.466 13.801 6.49 13.809 6.512 13.818C6.6 14.007 6.697 14.19 6.805 14.366C6.802 14.38 6.799 14.393 6.795 14.407C6.759 14.54 6.682 14.641 6.562 14.71C6.442 14.779 6.316 14.796 6.183 14.76C5.487 14.573 4.836 14.285 4.229 13.897C3.59 13.489 3.032 12.99 2.556 12.4ZM8.707 3.293C8.902 3.488 9 3.724 9 4C9 4.276 8.902 4.512 8.707 4.707C8.512 4.902 8.276 5 8 5C7.724 5 7.488 4.902 7.293 4.707C7.098 4.512 7 4.276 7 4C7 3.724 7.098 3.488 7.293 3.293C7.488 3.098 7.724 3 8 3C8.276 3 8.512 3.098 8.707 3.293ZM4.293 5.293C4.488 5.098 4.724 5 5 5C5.276 5 5.512 5.098 5.707 5.293C5.902 5.488 6 5.724 6 6C6 6.276 5.902 6.512 5.707 6.707C5.512 6.902 5.276 7 5 7C4.724 7 4.488 6.902 4.293 6.707C4.098 6.512 4 6.276 4 6C4 5.724 4.098 5.488 4.293 5.293ZM13.156 7.316C13.734 7.545 14.243 7.879 14.682 8.318C15.121 8.757 15.455 9.266 15.684 9.844C15.895 10.376 16 10.928 16 11.5C16 12.072 15.895 12.624 15.684 13.156C15.455 13.734 15.121 14.243 14.682 14.682C14.243 15.121 13.734 15.455 13.156 15.684C12.624 15.895 12.072 16 11.5 16C10.928 16 10.376 15.895 9.844 15.684C9.266 15.455 8.757 15.121 8.318 14.682C7.879 14.243 7.545 13.734 7.316 13.156C7.105 12.624 7 12.072 7 11.5C7 10.928 7.105 10.376 7.316 9.844C7.545 9.266 7.879 8.757 8.318 8.318C8.757 7.879 9.266 7.545 9.844 7.316C10.376 7.105 10.928 7 11.5 7C12.072 7 12.624 7.105 13.156 7.316ZM9 10.5C9 10.776 9.224 11 9.5 11L13.5 11C13.776 11 14 10.776 14 10.5C14 10.367 13.947 10.24 13.854 10.146L11.854 8.146C11.658 7.951 11.342 7.951 11.146 8.146C10.951 8.342 10.951 8.658 11.146 8.854L12.293 10L9.5 10C9.224 10 9 10.224 9 10.5ZM4.293 9.293C4.488 9.098 4.724 9 5 9C5.276 9 5.512 9.098 5.707 9.293C5.902 9.488 6 9.724 6 10C6 10.276 5.902 10.512 5.707 10.707C5.512 10.902 5.276 11 5 11C4.724 11 4.488 10.902 4.293 10.707C4.098 10.512 4 10.276 4 10C4 9.724 4.098 9.488 4.293 9.293ZM13.5 13C13.776 13 14 12.776 14 12.5C14 12.224 13.776 12 13.5 12L9.5 12C9.224 12 9 12.224 9 12.5C9 12.633 9.053 12.76 9.146 12.854L11.146 14.854C11.342 15.049 11.658 15.049 11.854 14.854C12.049 14.658 12.049 14.342 11.854 14.146L10.707 13L13.5 13Z"/></svg>
// Gentleface "color-switch" (line-round), MIT. https://gentleface.com/icons/color-switch
import type { SVGProps } from 'react';
export function ColorSwitchIcon(props: SVGProps<SVGSVGElement>) {
return (
<svg xmlns="http://www.w3.org/2000/svg" width={16} height={16} viewBox="0 0 16 16" fill="currentColor" aria-hidden="true" {...props}>
<path d="M2.556 12.4C2.079 11.81 1.708 11.16 1.443 10.45C1.191 9.775 1.046 9.078 1.009 8.359C0.963 7.457 1.087 6.578 1.381 5.723C1.701 4.793 2.195 3.967 2.863 3.244C3.532 2.522 4.318 1.966 5.221 1.575C6.051 1.216 6.917 1.025 7.82 1.002C8.584 0.983 9.33 1.085 10.06 1.31C10.833 1.548 11.544 1.909 12.192 2.394C12.84 2.879 13.388 3.458 13.835 4.133C14.257 4.77 14.566 5.457 14.763 6.194C14.799 6.33 14.784 6.457 14.715 6.575C14.647 6.693 14.545 6.77 14.409 6.806C14.399 6.809 14.39 6.811 14.38 6.813C14.199 6.702 14.011 6.601 13.816 6.511C13.809 6.492 13.802 6.473 13.797 6.452C13.628 5.82 13.363 5.231 13.001 4.686C12.618 4.107 12.149 3.61 11.593 3.195C11.038 2.779 10.428 2.47 9.765 2.266C9.14 2.073 8.5 1.985 7.846 2.002C7.072 2.022 6.329 2.186 5.618 2.493C4.844 2.828 4.17 3.305 3.597 3.924C3.024 4.543 2.6 5.251 2.326 6.049C2.074 6.781 1.968 7.534 2.008 8.308C2.04 8.924 2.163 9.522 2.38 10.1C2.607 10.709 2.925 11.266 3.334 11.771C3.742 12.277 4.22 12.705 4.768 13.055C5.288 13.387 5.846 13.634 6.442 13.794C6.466 13.801 6.49 13.809 6.512 13.818C6.6 14.007 6.697 14.19 6.805 14.366C6.802 14.38 6.799 14.393 6.795 14.407C6.759 14.54 6.682 14.641 6.562 14.71C6.442 14.779 6.316 14.796 6.183 14.76C5.487 14.573 4.836 14.285 4.229 13.897C3.59 13.489 3.032 12.99 2.556 12.4ZM8.707 3.293C8.902 3.488 9 3.724 9 4C9 4.276 8.902 4.512 8.707 4.707C8.512 4.902 8.276 5 8 5C7.724 5 7.488 4.902 7.293 4.707C7.098 4.512 7 4.276 7 4C7 3.724 7.098 3.488 7.293 3.293C7.488 3.098 7.724 3 8 3C8.276 3 8.512 3.098 8.707 3.293ZM4.293 5.293C4.488 5.098 4.724 5 5 5C5.276 5 5.512 5.098 5.707 5.293C5.902 5.488 6 5.724 6 6C6 6.276 5.902 6.512 5.707 6.707C5.512 6.902 5.276 7 5 7C4.724 7 4.488 6.902 4.293 6.707C4.098 6.512 4 6.276 4 6C4 5.724 4.098 5.488 4.293 5.293ZM13.156 7.316C13.734 7.545 14.243 7.879 14.682 8.318C15.121 8.757 15.455 9.266 15.684 9.844C15.895 10.376 16 10.928 16 11.5C16 12.072 15.895 12.624 15.684 13.156C15.455 13.734 15.121 14.243 14.682 14.682C14.243 15.121 13.734 15.455 13.156 15.684C12.624 15.895 12.072 16 11.5 16C10.928 16 10.376 15.895 9.844 15.684C9.266 15.455 8.757 15.121 8.318 14.682C7.879 14.243 7.545 13.734 7.316 13.156C7.105 12.624 7 12.072 7 11.5C7 10.928 7.105 10.376 7.316 9.844C7.545 9.266 7.879 8.757 8.318 8.318C8.757 7.879 9.266 7.545 9.844 7.316C10.376 7.105 10.928 7 11.5 7C12.072 7 12.624 7.105 13.156 7.316ZM9 10.5C9 10.776 9.224 11 9.5 11L13.5 11C13.776 11 14 10.776 14 10.5C14 10.367 13.947 10.24 13.854 10.146L11.854 8.146C11.658 7.951 11.342 7.951 11.146 8.146C10.951 8.342 10.951 8.658 11.146 8.854L12.293 10L9.5 10C9.224 10 9 10.224 9 10.5ZM4.293 9.293C4.488 9.098 4.724 9 5 9C5.276 9 5.512 9.098 5.707 9.293C5.902 9.488 6 9.724 6 10C6 10.276 5.902 10.512 5.707 10.707C5.512 10.902 5.276 11 5 11C4.724 11 4.488 10.902 4.293 10.707C4.098 10.512 4 10.276 4 10C4 9.724 4.098 9.488 4.293 9.293ZM13.5 13C13.776 13 14 12.776 14 12.5C14 12.224 13.776 12 13.5 12L9.5 12C9.224 12 9 12.224 9 12.5C9 12.633 9.053 12.76 9.146 12.854L11.146 14.854C11.342 15.049 11.658 15.049 11.854 14.854C12.049 14.658 12.049 14.342 11.854 14.146L10.707 13L13.5 13Z" />
</svg>
);
}Vue: see /icons/color-switch.md
Svelte: see /icons/color-switch.md
HTML img: see /icons/color-switch.md
CSS: see /icons/color-switch.md
Data URL: see /icons/color-switch.md
Sprite: see /icons/color-switch.md
SwiftUI: see /icons/color-switch.md
Compose: see /icons/color-switch.md
Android XML: see /icons/color-switch.md
Flutter: see /icons/color-switch.md
Each icon is drawn on the 16 px grid, and most also on the 20 and 24 px grids (at 24 in three weights: light 1 px, regular 1.5 px, bold 2 px). Show the drawing made for your size, or an exact multiple of it, on whole pixels: 16 for 16 and 32 px, 20 for 20 and 40, 24 for 24 and 48. A size in between or a fractional position blurs it. The code on each icon page is the 16 px drawing, an SVG with fill="currentColor"; the icon page's downloads follow its Grid switch, and npm has the 20 and 24 px drawings too. The snippets are decorative (aria-hidden). For an icon that carries meaning on its own, such as an icon-only button, label the button, or give the SVG role="img" and an aria-label. More in how to use.
Meaning
Family 2
More design icons
align-horizontal-center align-objects-bottom align-objects-bottom-three align-objects-left align-objects-left-three align-objects-right align-objects-right-three align-objects-top align-objects-top-three align-vertical-center angle animation animation-off auto-layout-horizontal auto-layout-vertical auto-layout-wrap · all design icons
For agents
Metadata: /icons/color-switch.json · Markdown: /icons/color-switch.md · SVG: https://gentleface.com/svg/{style}/16/color-switch.svg · PNG: https://gentleface.com/png/{style}/{16|32|48}/color-switch.png