gentleface

Gentleface › Development › diff

diff icon

Diff: diff, patch, view diff. Drawn on the 16 px grid. Free SVG, PNG and code, MIT licensed.

Code line-round

SVG
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16" fill="currentColor" aria-hidden="true"><path d="M12.5 6C12.641 6 12.759 6.048 12.856 6.144C12.952 6.241 13 6.359 13 6.5C13 6.641 12.952 6.759 12.856 6.856C12.759 6.952 12.641 7 12.5 7L8 7L8 11.5C8 11.641 7.952 11.759 7.856 11.856C7.759 11.952 7.641 12 7.5 12C7.359 12 7.241 11.952 7.144 11.856C7.048 11.759 7 11.641 7 11.5L7 7L2.5 7C2.359 7 2.241 6.952 2.144 6.856C2.048 6.759 2 6.641 2 6.5C2 6.359 2.048 6.241 2.144 6.144C2.241 6.048 2.359 6 2.5 6L7 6L7 1.5C7 1.359 7.048 1.241 7.144 1.144C7.241 1.048 7.359 1 7.5 1C7.641 1 7.759 1.048 7.856 1.144C7.952 1.241 8 1.359 8 1.5L8 6L12.5 6ZM2 14.5C2 14.359 2.048 14.241 2.144 14.144C2.241 14.048 2.359 14 2.5 14L12.5 14C12.641 14 12.759 14.048 12.856 14.144C12.952 14.241 13 14.359 13 14.5C13 14.641 12.952 14.759 12.856 14.856C12.759 14.952 12.641 15 12.5 15L2.5 15C2.359 15 2.241 14.952 2.144 14.856C2.048 14.759 2 14.641 2 14.5Z"/></svg>
React
// Gentleface "diff" (line-round), MIT. https://gentleface.com/icons/diff
import type { SVGProps } from 'react';

export function DiffIcon(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="M12.5 6C12.641 6 12.759 6.048 12.856 6.144C12.952 6.241 13 6.359 13 6.5C13 6.641 12.952 6.759 12.856 6.856C12.759 6.952 12.641 7 12.5 7L8 7L8 11.5C8 11.641 7.952 11.759 7.856 11.856C7.759 11.952 7.641 12 7.5 12C7.359 12 7.241 11.952 7.144 11.856C7.048 11.759 7 11.641 7 11.5L7 7L2.5 7C2.359 7 2.241 6.952 2.144 6.856C2.048 6.759 2 6.641 2 6.5C2 6.359 2.048 6.241 2.144 6.144C2.241 6.048 2.359 6 2.5 6L7 6L7 1.5C7 1.359 7.048 1.241 7.144 1.144C7.241 1.048 7.359 1 7.5 1C7.641 1 7.759 1.048 7.856 1.144C7.952 1.241 8 1.359 8 1.5L8 6L12.5 6ZM2 14.5C2 14.359 2.048 14.241 2.144 14.144C2.241 14.048 2.359 14 2.5 14L12.5 14C12.641 14 12.759 14.048 12.856 14.144C12.952 14.241 13 14.359 13 14.5C13 14.641 12.952 14.759 12.856 14.856C12.759 14.952 12.641 15 12.5 15L2.5 15C2.359 15 2.241 14.952 2.144 14.856C2.048 14.759 2 14.641 2 14.5Z" />
    </svg>
  );
}
Vue
Vue: see /icons/diff.md
Svelte
Svelte: see /icons/diff.md
HTML img
HTML img: see /icons/diff.md
CSS
CSS: see /icons/diff.md
Data URL
Data URL: see /icons/diff.md
Sprite
Sprite: see /icons/diff.md
SwiftUI
SwiftUI: see /icons/diff.md
Compose
Compose: see /icons/diff.md
Android XML
Android XML: see /icons/diff.md
Flutter
Flutter: see /icons/diff.md

Each SVG is 16 × 16 with fill="currentColor". Keep it at 16 px or an exact multiple (32, 48) on whole pixels: a fractional size or position blurs it. 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

Use it for
diff, patch, view diff
Alternatives
  • file-diff: a diff or patch file (patch-file)
  • git-compare: compare two branches (compare-branches)
  • compare: compare two items side by side (compare)
Don’t confuse with
Also fits
  • compare: the changes between two texts or files
  • compare branches: the changes themselves (diff)
  • file diff: a diff or patch without the file (diff)
Tags
diff, patch, changes, plus-minus, compare, additions, deletions, version-control, developer
Category
Development
Component name
DiffIcon
History
  • added

Family 17

More development icons

For agents

Metadata: /icons/diff.json · Markdown: /icons/diff.md · SVG: https://gentleface.com/svg/{style}/16/diff.svg · PNG: https://gentleface.com/png/{style}/{16|32|48}/diff.png

Feedback