classy-yaml 0.7.0 → 0.8.0

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
  SHA256:
3
- metadata.gz: e550c3f72e3974d27db9f90ce7ff91b76e717373fd3965e2e3621442b7cbbd16
4
- data.tar.gz: 4bb718adfce915e86a357e91c8497de69a08e7e79ad6b14169d8f81ad0bcea4e
3
+ metadata.gz: c2bed093a5bc06fe6254b29ad1fa7bc10e0b23a790a009ab9f5efca6e4d21432
4
+ data.tar.gz: 321eb805f8a536ef82117e444c909036d006ede18acbb63b872451cb09588868
5
5
  SHA512:
6
- metadata.gz: ae98344136a170b10ffc6c507518832d60583d0e7555cf536333998270ad04e6be83b82d3b555969271787bfebb71eb21988fe2b5a48c6924bd80725fd7f8167
7
- data.tar.gz: 9277260199b1d3b84b13739f72b28ae1f4d93bb2c45b7e3fe330ed4fcffe15fac9ca9f6b338b4953ac259b464735e7f13e18b0a929b5a0668ab83714448ca57a
6
+ metadata.gz: 151b2cc8b260fa4c6546128929b6dae28cbf932bb8540360bf5214db785c1c001506bcd685fc32db3e99f2462eb739ce029c2301eb676b1230b4b505b239dd5f
7
+ data.tar.gz: cc0b8fa3e737040917f2e05121f5600df4746565883b5d5783e0136519c783b6b97bcdbe702a6cd9d508b49fe34fb174cd74dc2ea1ded77694c1f83a0d289f71
data/README.md CHANGED
@@ -46,7 +46,7 @@ btn:
46
46
 
47
47
  # app/components/example_component/example_component.html.erb
48
48
 
49
- <button class="<%=sass(btn: :purple)%>">Classy Button</button>
49
+ <button class="<%=yass(btn: :purple)%>">Classy Button</button>
50
50
 
51
51
  # will add the classes "px-3 py-2 text-purple-200 bg-blue-500"
52
52
  ```
@@ -68,7 +68,7 @@ btn:
68
68
 
69
69
  # app/components/example_component/example_component.html.erb
70
70
 
71
- <button class="<%=sass(btn: :purple)%>">Classy Button</button>
71
+ <button class="<%=yass(btn: :purple)%>">Classy Button</button>
72
72
 
73
73
  # will add the classes "px-3 py-2 text-blue-50"
74
74
  ```
@@ -2,8 +2,8 @@ module Classy
2
2
  module Yaml
3
3
  module ComponentHelpers
4
4
  def yass(*args)
5
- component_name = caller.first.split("/").last.split(".").first
6
- calling_path = caller.first.split("/")[0...-1].join("/")
5
+ component_name = self.class.source_location.split("/").last.split(".").first
6
+ calling_path = self.class.source_location.split("/")[0...-1].join("/")
7
7
  classy_file = if Dir.exist?("#{calling_path}/#{component_name}")
8
8
  "#{calling_path}/#{component_name}/#{component_name}.yml"
9
9
  else
@@ -1,5 +1,5 @@
1
1
  module Classy
2
2
  module Yaml
3
- VERSION = '0.7.0'
3
+ VERSION = '0.8.0'
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: classy-yaml
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.0
4
+ version: 0.8.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tonksthebear
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-12-16 00:00:00.000000000 Z
11
+ date: 2022-01-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -120,7 +120,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
120
120
  - !ruby/object:Gem::Version
121
121
  version: '0'
122
122
  requirements: []
123
- rubygems_version: 3.1.2
123
+ rubygems_version: 3.2.26
124
124
  signing_key:
125
125
  specification_version: 4
126
126
  summary: Rails helper to allow yaml configuration of utility css classes