Skip to content

Commit

Permalink
Merge pull request #1 from South-Paw/dev
Browse files Browse the repository at this point in the history
Publish package on npm
  • Loading branch information
South-Paw authored Oct 5, 2019
2 parents 385ea34 + 1e3e3a5 commit 26561c9
Show file tree
Hide file tree
Showing 11 changed files with 192 additions and 344 deletions.
14 changes: 14 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -1,3 +1,17 @@
The MIT License (MIT)

Copyright (c) 2015 Alex Gabites

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
Expand Down
66 changes: 55 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,25 +1,69 @@
# Minecraft Webfont and Colors
# typeface-minecraft

A Minecraft webfont kit provided with base game colors as CSS classes.
The CSS and web font files for the Minecraft typeface and colors

## Install

## How to use
`npm install --save @south-paw/typeface-minecraft`

To use this font, simply put the folders in the root directory of your project, and link the CSS as follows:
or

```html
<link rel="stylesheet" type="text/css" media="screen" href="css/minecraft-webfont.css" />
`yarn add @south-paw/typeface-minecraft`

## Use

This project assumes that you're using webpack to process CSS and files.

The package includes the necessary font files (woff2, woff) and a CSS file with font-face declarations pointing at these files.

You will need to have webpack setup to load css and font files.

Many tools built with Webpack will work out of the box with this package such as [Gatsby](https://github.com/gatsbyjs/gatsby) and [Create React App](https://github.com/facebook/create-react-app).

To use, simply require the package in your project's entry file:

```js
// Load Minecraft typeface
require("@south-paw/typeface-minecraft");
```

Then call the Minecraft font in your CSS with:
and then apply the font family via CSS:

```css
font-family: 'Minecraft';
body {
font-family: "Minecraft";
}
```

Note: changing the `font-weight` will blur the font.
The package also adds some global CSS classes for matching Minecraft colors:

```css
.minecraft-black
.minecraft-dark-blue
.minecraft-dark-green
.minecraft-dark-aqua
.minecraft-dark-red
.minecraft-dark-purple
.minecraft-gold
.minecraft-gray
.minecraft-dark-gray
.minecraft-blue
.minecraft-green
.minecraft-aqua
.minecraft-red
.minecraft-light-purple
.minecraft-yellow
.minecraft-white
```

Any of these can be applied to an element e.g.

```html
<div class="minecraft-blue">Minecraft</div>
```

## Source

## Authors
Colors are from the [Minecraft wiki](https://minecraft.gamepedia.com/Formatting_codes).

Colors used in the CSS classes are from the [Minecraft wiki](http://minecraft.gamepedia.com/Formatting_codes).
Package is inspired by the [typefaces project](https://github.com/KyleAMathews/typefaces).
89 changes: 0 additions & 89 deletions css/minecraft-webfont.css

This file was deleted.

Binary file added files/minecraft.woff
Binary file not shown.
Binary file added files/minecraft.woff2
Binary file not shown.
Binary file removed font/minecraft_font.eot
Binary file not shown.
Loading

0 comments on commit 26561c9

Please sign in to comment.