proscenium 0.19.0.beta18-aarch64-linux → 0.19.0.beta19-aarch64-linux

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: 3ae7f89e0dab7d390edc106ddaa83a5a72a518a7a77d15d6c3bad0586fbb9941
4
- data.tar.gz: 6f80084455efd4849898b5de58169668f8d534fab6da9a0756d9c0c0a7c38f42
3
+ metadata.gz: 8098624bde7392672b71f99677e3c35996e7ce48a2811481940aec58eab57715
4
+ data.tar.gz: 715fc04339a57e201c42155733ce443cba52e4a644472dadee8519e3d1f83bd0
5
5
  SHA512:
6
- metadata.gz: 9401fdb202c9795fcc5860ae4cf1ba14f9874fef0727b84bc7b0ef9390dd59220e834fdba5f2ba27471f588556cacc40d8ff449239d7824a1ac46c2398005ec6
7
- data.tar.gz: 94930c1114382e96335d13f9097cd8a672f83903a01be85e54a1e3b7972e3c8638bed6be5ee9646c32c06a21d321aa1ce5681ead3a8af6a768e3486d263681d8
6
+ metadata.gz: 9f41b419f377a4ed15dcc8d08271fad601feb066dc6b8fdf557ae4bf775110b04c6b9c033ca1cb2dc32b7fc013b2225e072802d9486183f03860b248f893f69c
7
+ data.tar.gz: 8853d4ff3d38676211d2ee0a652b902f5b8f399cef66692bedb6fb89e6998bbd4906701fc76dcbf1401a0450e59a7908056b1dd61bc312987a8f47380743a558
@@ -16,6 +16,27 @@ module Proscenium::CssModule
16
16
  end
17
17
  end
18
18
 
19
+ module ClassMethods
20
+ def css_module(*names, path: nil)
21
+ path ||= respond_to?(:css_module_path) ? css_module_path : path
22
+
23
+ cssm = Transformer.new(path)
24
+ cssm.class_names(*names, require_prefix: false).map { |name, _| name }.join(' ')
25
+ end
26
+
27
+ def class_names(*names, path: nil)
28
+ path ||= respond_to?(:css_module_path) ? css_module_path : path
29
+ names = names.flatten.compact
30
+
31
+ cssm = Transformer.new(path)
32
+ cssm.class_names(*names).map { |name, _| name }.join(' ') unless names.empty?
33
+ end
34
+ end
35
+
36
+ def self.included(base)
37
+ base.extend ClassMethods
38
+ end
39
+
19
40
  # Accepts one or more CSS class names, and transforms them into CSS module names.
20
41
  #
21
42
  # @param name [String,Symbol,Array<String,Symbol>]
Binary file
@@ -2,8 +2,6 @@
2
2
 
3
3
  module Proscenium
4
4
  module Phlex::CssModules
5
- include Proscenium::CssModule
6
-
7
5
  def self.included(base)
8
6
  base.extend CssModule::Path
9
7
  base.extend ClassMethods
@@ -11,6 +11,7 @@ module Proscenium
11
11
  autoload :AssetInclusions
12
12
 
13
13
  include Proscenium::SourcePath
14
+ include Proscenium::CssModule
14
15
  include CssModules
15
16
  include AssetInclusions
16
17
 
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Proscenium
4
- VERSION = '0.19.0.beta18'
4
+ VERSION = '0.19.0.beta19'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: proscenium
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.19.0.beta18
4
+ version: 0.19.0.beta19
5
5
  platform: aarch64-linux
6
6
  authors:
7
7
  - Joel Moss
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2025-04-30 00:00:00.000000000 Z
11
+ date: 2025-05-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: ffi