trailguide 0.1.25 → 0.1.26

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e49f646c2c6f0d1569668bb7d048c432015d016d3e966944473a3d707dade3fd
4
- data.tar.gz: ffb7c2aceb3ab087b6d89ece4e7583f8cd9dbefa63ca87debb8001818f450ed1
3
+ metadata.gz: bfff07475d5980342dfc27deaaa3eec31b566d29dd1abe67414cc4433de77a84
4
+ data.tar.gz: 4ef6d17f8725d12525d5f6413daeaa32c5188dd4dbacf46cdc5e4d68544e97cf
5
5
  SHA512:
6
- metadata.gz: 52116e5ead0d802542cf849a6a1f19c73a4e8ae9e2c515b8469891e1c6721bef456a4a272de7348e5db309d67e39b28448897731b1e828ffbd3108d89dcaea5b
7
- data.tar.gz: b1a31d51d471e638fc1148f64725d94014d5f4b259cfd6c31796fb60f8d3b1af12837b7000c040f25705ee8f21164720191063701203a3f26d2682bd37a1b9fb
6
+ metadata.gz: b1a66d9ac92279faf9929973999cf9f07d219aa2f16d6b03b1bbe66b4644bc4afbaa238b48a34144ed3c37732dd73af10168d49bf3358e95a7dabc9c730523f0
7
+ data.tar.gz: 67f8534807574f2e95e53ddac24a651260efe82be49f816f0551424ff007a901e5a60702afaf178e5582c0e31330f2a8fcac497b3420ebe61f12b56d9eb14cca
@@ -135,10 +135,10 @@ module TrailGuide
135
135
  end
136
136
  end
137
137
 
138
- def render!(prefix: nil, templates: nil, **opts)
138
+ def render!(prefix: nil, templates: nil, locals: {}, **opts)
139
139
  raise UnsupportedContextError, "The current context (#{context}) does not support rendering. Rendering is only available in controllers and views." unless context.respond_to?(:render, true)
140
140
  choose!(**opts) do |variant, metadata|
141
- locals = { variant: variant, metadata: variant.metadata }
141
+ locals = { variant: variant, metadata: variant.metadata }.merge(locals)
142
142
  locals = { locals: locals } if context_type == :controller
143
143
 
144
144
  template = templates[variant.name] if templates
@@ -2,7 +2,7 @@ module TrailGuide
2
2
  module Version
3
3
  MAJOR = 0
4
4
  MINOR = 1
5
- PATCH = 25
5
+ PATCH = 26
6
6
  VERSION = "#{MAJOR}.#{MINOR}.#{PATCH}"
7
7
 
8
8
  class << self
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: trailguide
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.25
4
+ version: 0.1.26
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mark Rebec
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-03-19 00:00:00.000000000 Z
11
+ date: 2019-03-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails