Skip to content

Latest commit

 

History

History
49 lines (35 loc) · 1.29 KB

README.md

File metadata and controls

49 lines (35 loc) · 1.29 KB

CSS Image Sprite of country flags

CSS Image sprite of country Flags with Pirates with different image sizes:

Example usage

First copy the set you want to you to your local html project

Next edit the CSS filename and make sure the image url is correct for your project:

.flag.flag-24 {
  // ...
  background-image: url('sprite-flags-24x24.png'); 
  // ...
}

Next include the appropriate CSS file in the head of your HTML. E.g. if you want to use 24x24 and the filename is sprite-flags-24x24.css in your project

<link
  rel="stylesheet"
  type="text/css"
  href="sprite-flags-24x24.css"
/>

Next start rendering some flags!

<i class="flag flag-16 flag-nl"></i>
<i class="flag flag-24 flag-nl"></i>
<i class="flag flag-32 flag-nl"></i>
<i class="flag flag-48 flag-nl"></i>
<i class="flag flag-64 flag-nl"></i>