font_awesome_file_icons 0.1.0 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 2f236224f2cda5d3c6d245a892924260d1cadd68
4
- data.tar.gz: d49ff95ba3f4382bd0a3eed3238728398e299670
3
+ metadata.gz: 1023936219bfec9d4b66175f106316a30b1b44a2
4
+ data.tar.gz: 307a10527ba74e7cccbae8b35bbcef7e19848677
5
5
  SHA512:
6
- metadata.gz: 4c49d10a8cc9be5fba6cc6023f0d149d5f5670d3a17ba1753310339b16d4e95f8e055a89c884b80dd00541f5e7d807030ba0d0217027676b294e2f57348a51ea
7
- data.tar.gz: 7b64f6e2db691ad7a15adbf6699697ef22bb18e2e6039619a9606666efcb38bb3805f5c3b058e32661da690ae1ce18f27a736bbac71994a8ae13beace34a943d
6
+ metadata.gz: 49d0053320b70933f070204e37989235c013793cc93cd74224599dfdb2a09d31e679f295f2e0502ec3a7f35e92a9404dbf25194731a03f22643ef48c294c65f1
7
+ data.tar.gz: 726cdcea490be4d4b8240d9b959d1f2ba6653ffed4494f467436f40b7f2bbaec4fe7aca19b53de081b4f1b4d506d08e0416222ef049f5018c19e0ea9576a84e1
data/README.md CHANGED
@@ -8,6 +8,17 @@ This gem is doing this for you, so you can focus on more important things.
8
8
 
9
9
  Gem is adding method-wrapper `fa_file_icon` which behaves very similar to `fa_icon` and can receive same arguments as `fa_icon`.
10
10
 
11
+ ```erb
12
+ <p><%= fa_file_icon 'file.pdf', text: 'download' %></p>
13
+ <p><%= fa_file_icon 'movie.avi' %></p>
14
+ <p><%= fa_file_icon 'attachment.zip' %></p>
15
+ <p><%= fa_file_icon user.avatar.file.filename, text: user.avatar.file.filename %></p>
16
+
17
+ <p><%= fa_file_stacked_icon 'index.mov', text: 'mov' %></p>
18
+ <p><%= fa_file_stacked_icon 'index.jpg', text: 'jpg' %></p>
19
+ <p><%= fa_file_stacked_icon 'index.bmp', text: 'bmp', class: "fa-5x" %></p>
20
+ ```
21
+
11
22
  ## Installation
12
23
  Add this line to your application's Gemfile:
13
24
 
@@ -1,3 +1,3 @@
1
1
  module FontAwesomeFileIcons
2
- VERSION = '0.1.0'
2
+ VERSION = '0.1.1'
3
3
  end
@@ -52,6 +52,11 @@ module FontAwesomeFileIcons
52
52
  fa_icon(icon, *options)
53
53
  end
54
54
 
55
+ def fa_file_stacked_icon(filename, *options)
56
+ icon = get_icon(filename)
57
+ fa_stacked_icon(icon, *options)
58
+ end
59
+
55
60
  private
56
61
 
57
62
  def get_icon(filename)
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: font_awesome_file_icons
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Igor Kasyanchuk
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-09-05 00:00:00.000000000 Z
11
+ date: 2018-09-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails