middleman-favicon-maker 4.0.4 → 4.0.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +47 -26
- data/lib/middleman-favicon-maker/extension.rb +1 -1
- data/lib/middleman-favicon-maker/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 57b0433e183c68686843e2d41299fdbe27cdb378
|
4
|
+
data.tar.gz: 40bc39f57dc5b71b30513e703b28ac84c1777e13
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2f3d2a2d8436950b1dd5f0f1013c28d5ab01c666bcfda9c7135f901cf78b1ebd48692224aa4f4e517466ce88daed06da783263bfb0e032d627ea488df29e8168
|
7
|
+
data.tar.gz: ccca9560b23183d8770473189cd2595ce19fb498789072baf4262590300b416a389e7ab96aef61c01e1ab8a8e9df0d0ad7e472da34fc17828f4e35aa47b371c5
|
data/README.md
CHANGED
@@ -1,4 +1,5 @@
|
|
1
1
|
# middleman-favicon-maker
|
2
|
+
|
2
3
|
[![Gem Version](https://badge.fury.io/rb/middleman-favicon-maker.svg)](http://badge.fury.io/rb/middleman-favicon-maker)
|
3
4
|
[![Code Climate](https://codeclimate.com/github/follmann/middleman-favicon-maker.png)](https://codeclimate.com/github/follmann/middleman-favicon-maker)
|
4
5
|
|
@@ -8,28 +9,31 @@
|
|
8
9
|
|
9
10
|
### Dependencies
|
10
11
|
|
11
|
-
Before you can use FaviconMaker, you need to install [ImageMagick](http://www.imagemagick.org/script/index.php). On
|
12
|
+
Before you can use FaviconMaker, you need to install [ImageMagick](http://www.imagemagick.org/script/index.php). On macOS, the easiest way to do this is to run:
|
12
13
|
|
13
|
-
```
|
14
|
+
```shell
|
14
15
|
brew install imagemagick
|
15
16
|
```
|
16
17
|
|
17
18
|
### Using Bundler
|
18
19
|
|
19
|
-
```
|
20
|
+
```ruby
|
20
21
|
gem "middleman-favicon-maker", "~> 4.0"
|
21
22
|
```
|
22
23
|
|
23
24
|
If you're using Middleman version 2.x, use version 0.0.6 of middleman-favicon-maker.
|
24
25
|
|
25
26
|
## Integrating with Middleman
|
27
|
+
|
26
28
|
### Templates
|
29
|
+
|
27
30
|
Create an image e.g. named `_favicon_template.png` and place it in your source directory. The leading underscore prevents it from being copied into the build directory. Ideally, this image's dimensions would be 152 x 152 or have multiple templates for different ranges (small, medium, big). In your config.rb, extend the `configure :build` block. The image formats used for templates should be either PNG or SVG (since v3.6).
|
28
31
|
|
29
32
|
### Simple config
|
33
|
+
|
30
34
|
This config assumes that a PNG file named `_favicon_template.png` lives in the source folder. The generated icons are stored in the build folder root.
|
31
35
|
|
32
|
-
```
|
36
|
+
```ruby
|
33
37
|
configure :build do
|
34
38
|
...
|
35
39
|
activate :favicon_maker, :icons => {
|
@@ -44,9 +48,10 @@ end
|
|
44
48
|
```
|
45
49
|
|
46
50
|
### Advanced config
|
51
|
+
|
47
52
|
Using all configuration options. The `template_dir` and `output_dir` point to source and build dir if not set, you can use absolute or relative paths. You can use multiple template files that suit the different resolutions better. `format` and `size` are optional and only required when the size of the icon and/or the file format is not encoded in the filename. Multiple resolutions in one file is only supported for the .ico format.
|
48
53
|
|
49
|
-
```
|
54
|
+
```ruby
|
50
55
|
configure :build do
|
51
56
|
...
|
52
57
|
activate :favicon_maker do |f|
|
@@ -69,9 +74,10 @@ end
|
|
69
74
|
```
|
70
75
|
|
71
76
|
### List of icons you might be interested in
|
77
|
+
|
72
78
|
This is a moving target. Feel free to extend it and submit the change.
|
73
79
|
|
74
|
-
```
|
80
|
+
```ruby
|
75
81
|
[
|
76
82
|
{ icon: "apple-touch-icon-180x180-precomposed.png" }, # Same as apple-touch-icon-57x57.png, for iPhone 6 Plus with @3× display
|
77
83
|
{ icon: "apple-touch-icon-152x152-precomposed.png" }, # Same as apple-touch-icon-57x57.png, for retina iPad with iOS7.
|
@@ -105,30 +111,45 @@ Specifying meta links is only necessary if you want to support non-iOS devices.
|
|
105
111
|
|
106
112
|
### HTML
|
107
113
|
|
108
|
-
```
|
109
|
-
<link rel="apple-touch-icon
|
110
|
-
<link rel="apple-touch-icon
|
111
|
-
<link rel="apple-touch-icon
|
112
|
-
<link rel="apple-touch-icon
|
113
|
-
<link rel="apple-touch-icon
|
114
|
-
<link rel="apple-touch-icon
|
115
|
-
<link rel="shortcut icon" href="favicon.png"
|
116
|
-
<link rel="icon" type="image/ico" href="favicon.ico"
|
114
|
+
```html
|
115
|
+
<link rel="apple-touch-icon" sizes="180x180" href="apple-touch-icon-180x180-precomposed.png">
|
116
|
+
<link rel="apple-touch-icon" sizes="152x152" href="apple-touch-icon-152x152-precomposed.png">
|
117
|
+
<link rel="apple-touch-icon" sizes="144x144" href="apple-touch-icon-144x144-precomposed.png">
|
118
|
+
<link rel="apple-touch-icon" sizes="114x114" href="apple-touch-icon-114x114-precomposed.png">
|
119
|
+
<link rel="apple-touch-icon" sizes="72x72" href="apple-touch-icon-72x72-precomposed.png">
|
120
|
+
<link rel="apple-touch-icon" href="apple-touch-icon-precomposed.png">
|
121
|
+
<link rel="shortcut icon" href="favicon.png">
|
122
|
+
<link rel="icon" type="image/ico" href="favicon.ico">
|
123
|
+
```
|
124
|
+
|
125
|
+
### Haml
|
126
|
+
|
127
|
+
```haml
|
128
|
+
%link{rel: "apple-touch-icon", sizes: "180x180", href: "apple-touch-icon-180x180-precomposed.png"}
|
129
|
+
%link{rel: "apple-touch-icon", sizes: "152x152", href: "apple-touch-icon-152x152-precomposed.png"}
|
130
|
+
%link{rel: "apple-touch-icon", sizes: "144x144", href: "apple-touch-icon-144x144-precomposed.png"}
|
131
|
+
%link{rel: "apple-touch-icon", sizes: "114x114", href: "apple-touch-icon-114x114-precomposed.png"}
|
132
|
+
%link{rel: "apple-touch-icon", sizes: "72x72", href: "apple-touch-icon-72x72-precomposed.png"}
|
133
|
+
%link{rel: "apple-touch-icon", href: "apple-touch-icon-precomposed.png"}
|
134
|
+
%link{rel: "shortcut icon", href: "favicon.png"}
|
135
|
+
%link{rel: "icon", type: "image/ico", href: "favicon.ico"}
|
117
136
|
```
|
118
137
|
|
119
|
-
###
|
120
|
-
|
121
|
-
```
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
138
|
+
### Slim
|
139
|
+
|
140
|
+
```slim
|
141
|
+
link href="apple-touch-icon-180x180-precomposed.png" rel="apple-touch-icon" sizes="180x180" /
|
142
|
+
link href="apple-touch-icon-152x152-precomposed.png" rel="apple-touch-icon" sizes="152x152" /
|
143
|
+
link href="apple-touch-icon-144x144-precomposed.png" rel="apple-touch-icon" sizes="144x144" /
|
144
|
+
link href="apple-touch-icon-114x114-precomposed.png" rel="apple-touch-icon" sizes="114x114" /
|
145
|
+
link href="apple-touch-icon-72x72-precomposed.png" rel="apple-touch-icon" sizes="72x72" /
|
146
|
+
link href="apple-touch-icon-precomposed.png" rel="apple-touch-icon" /
|
147
|
+
link href="favicon.png" rel=("shortcut icon") /
|
148
|
+
link href="favicon.ico" rel="icon" type="image/ico" /
|
130
149
|
```
|
150
|
+
|
131
151
|
## Contributing
|
152
|
+
|
132
153
|
1. Fork it
|
133
154
|
2. Create your feature branch (`git checkout -b my-new-feature`)
|
134
155
|
3. Commit your changes (`git commit -am 'Add some feature'`)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: middleman-favicon-maker
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.0.
|
4
|
+
version: 4.0.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Andreas Follmann
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2017-08-19 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: middleman-core
|