lokap-presenter 0.0.1 → 0.0.2

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.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +6 -2
  3. data/lib/lokap/presenter.rb +2 -2
  4. metadata +6 -5
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 1309d832f67f5f6647903f2cf3a98a2c7e8ab5335229faa243cd54bd9cbbc977
4
- data.tar.gz: 114a5bd96c592e832664df4c60749943fbfa9ae47f944d5b812913210c69a73f
3
+ metadata.gz: 0f5ae7ff0910a585eb20957cc329b4258e1e0f244df3d8ec9434496c10d9b0e0
4
+ data.tar.gz: 421331a6bbdf43b541c2455d0f299811f96dd9e7da3b558e9a9a80e32c9b5f2c
5
5
  SHA512:
6
- metadata.gz: 2afa4a16cfccd59e8f250488123a15c801b3fda63fb6675510e92f056da514104f3801a20feb67be681d53b15397f3fcc2e948d7a769005e1f236668e5ef28e6
7
- data.tar.gz: a4ae06040ad7ac85a795fb41e929b8fd4b50ca5fc2db84a79280262c172f704c78ebe2990b16ade950ffdfc665a28a6d52babb720fc71c8e20cbcc942c1f25f9
6
+ metadata.gz: c734f32a88ec9c3d0639cfad0d4337e54d63bcdbb8d3ce93441d606ccff6312a338f746bd415160bad7a1b2f2218bb3ecb39dc7196def86e7bd6ac3f319c707f
7
+ data.tar.gz: 1ac2c1571aeb300bb09d66b8c7b9222ae83761ae8a3f34f324328f8ee8042d54945bb3e73ebea4db990385cdc4d1cf58d8bfbb44522b6c7cf877ba83a895a5a5
data/README.md CHANGED
@@ -1,4 +1,4 @@
1
- A simple Rails view presenter for those with discerning taste.
1
+ A simple Rails view presenter for those with discerning taste.
2
2
  _From the Library of Knowledge and Power_
3
3
 
4
4
  ## Installation
@@ -9,6 +9,10 @@ Add this line to your application's Gemfile:
9
9
  gem 'lokap-presenter'
10
10
  ```
11
11
 
12
+ ## Documentation
13
+
14
+ See https://rubydoc.info/github/adambair/lokap-presenter
15
+
12
16
  ## Usage
13
17
 
14
18
  Call the presenter within your view using the `present` helper:
@@ -55,7 +59,7 @@ p.show_emotion
55
59
 
56
60
  ### The Presenter Class
57
61
 
58
- The class has full access to the view... and view helpers, etc.
62
+ The class has full access to the view... and view helpers, etc.
59
63
  _Think of this as a helper on steroids (but less angry)_
60
64
 
61
65
  ```ruby
@@ -78,14 +78,14 @@ module Lokap
78
78
  # @return [String] Full path to the template's partial
79
79
  def template_path(partial=nil)
80
80
  template = partial || default_template
81
- "/presenters/#{class_path}/#{template}".downcase
81
+ "#{class_path}/#{template}".downcase
82
82
  end
83
83
 
84
84
  # Generates the name for the class segment of the path
85
85
  # @note Removes `_presenter` from the resulting string if present
86
86
  # @return [String] Path for the subclassed presenter
87
87
  def class_path
88
- self.class.name.underscore.gsub('_presenter', '')
88
+ self.class.name.underscore.gsub('_presenter', '').gsub('/presenter', '')
89
89
  end
90
90
 
91
91
  # Generates the default partial path when a template is not found or specified
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lokap-presenter
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Adam Bair
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-07-07 00:00:00.000000000 Z
11
+ date: 2024-07-16 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description:
14
14
  email:
@@ -31,8 +31,9 @@ licenses:
31
31
  metadata:
32
32
  allowed_push_host: https://rubygems.org/
33
33
  homepage_uri: https://github.com/adambair/lokap-presenter
34
- source_code_uri: https://github.com/adambair/lokap-presenter
35
- changelog_uri: https://github.com/adambair/lokap-presenter
34
+ source_code_uri: https://github.com/adambair/lokap-presenter/
35
+ changelog_uri: https://github.com/adambair/lokap-presenter/blob/master/CHANGELOG.md
36
+ bug_tracker_uri: https://github.com/adambair/lokap-presenter/issues
36
37
  post_install_message:
37
38
  rdoc_options: []
38
39
  require_paths:
@@ -48,7 +49,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
48
49
  - !ruby/object:Gem::Version
49
50
  version: '0'
50
51
  requirements: []
51
- rubygems_version: 3.3.14
52
+ rubygems_version: 3.4.5
52
53
  signing_key:
53
54
  specification_version: 4
54
55
  summary: A view presenter for those with discerning taste