graph_starter 0.7.1 → 0.7.2

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: 21d031a4253a61a52a7dcfaddc51ec6b46dc2b57
4
- data.tar.gz: 386b277a5dae33517077ea490051860dcfdbd03f
3
+ metadata.gz: 2ba39a8bf4b8f837b968c093923dca37474fa52d
4
+ data.tar.gz: 9d5467ecf2e9dd763aa582ed4c772b6d30ca4ad9
5
5
  SHA512:
6
- metadata.gz: ab450ee9ac34d7e4fad55443149b87ef2a6f580e8283006bcc2a31101c3ace1c83ceb07ee0e32fb428b36bb0fe9d6229837f98627bdd856d858a07975384a1db
7
- data.tar.gz: 184827ed38d957d70901a2424951f39890f87e7c29abece1ac127b64ff6c06774c46a964c3d14c52807da56d3060cc68bfc21721b43d11da6b8cc180a6e6a539
6
+ metadata.gz: a5a2117422be0c98f4474ff04e55ee1ab725be9232c1df9d18a5977062dc8088c63b2f9ec7963fdacaf6cc07e46ee467aaab94e0898b46517ab49f1cdf04714b
7
+ data.tar.gz: 7acdf172f6e9bebafe591ded966bcdab595be6303b10ca76ff6e219089b99eee3e11ba4e3f305fb1e2b903d894fa476a80f56ab7a5df5b39bfc73e373253e980
@@ -35,7 +35,7 @@ module GraphStarter
35
35
  associations = []
36
36
  associations << model_class.image_association
37
37
  associations << model_class.category_association
38
- associations.compact
38
+ associations.compact!
39
39
 
40
40
  scope = model_class_scope(var)
41
41
  scope = yield scope if block_given?
@@ -48,9 +48,7 @@ module GraphStarter
48
48
  scope
49
49
  end
50
50
 
51
- if asset_scope_filter
52
- asset_scope_filter.call(scope)
53
- end
51
+ asset_scope_filter ? asset_scope_filter.call(scope) : scope
54
52
  end
55
53
 
56
54
  def show
@@ -1,7 +1,7 @@
1
1
  module GraphStarter
2
2
  module ApplicationHelper
3
3
  def asset_path(asset)
4
- super(id: asset, model_slug: asset.class.model_slug)
4
+ graph_starter.asset_path(id: asset, model_slug: asset.class.model_slug)
5
5
  end
6
6
 
7
7
  def engine_view(&b)
@@ -25,7 +25,10 @@
25
25
  .content
26
26
  - categories[0,2].each do |category|
27
27
  .extra.content
28
- i class="#{category.class.icon_class || 'folder'} icon"
28
+ - if (category.class.has_images? || category.class.has_image?) && category.first_image_source_url.present?
29
+ = image_tag category.first_image_source_url, class: 'ui avatar image'
30
+ - else
31
+ i class="#{category.class.icon_class || 'folder'} icon"
29
32
  = link_to category.name, asset_path(category)
30
33
  - if categories.size > 2
31
34
  .extra.content
@@ -1,3 +1,3 @@
1
1
  module GraphStarter
2
- VERSION = "0.7.1"
2
+ VERSION = "0.7.2"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: graph_starter
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.1
4
+ version: 0.7.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brian Underwood