htmx 3.1.0 → 3.3.0

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: c376d0c349acf221e100c49b04dd952944b2eb9e2e1def45897fbce020a5498a
4
- data.tar.gz: 4c8ef28f9dc9ab3fbc9091b0b79dfe8679c42b51d5b568d8ddcd8ac6912893ca
3
+ metadata.gz: 28115f83adf78c0ed1bbe634ab80d285859757595507610b5f39b10cd5280e9d
4
+ data.tar.gz: 3e53ba954560c33e2067871cac00e9bbda41448f4f0fee881dc83309498fbeb6
5
5
  SHA512:
6
- metadata.gz: 74a5ce01c02f622d12e2e3c8d9c984251b17aa0ad831f40874125d79492fa93b5e91a37b81039a36be0aa4e74d46722b656a294b37152c5d24b2099de7519cd2
7
- data.tar.gz: 075a7a50b354d330cb7cdedfad37a8be90d7f7a96ae67452b620d6b4a65adb2b62629be0b971ac0cba6f026c4967e27e9aae3da0fc834dcfc3c124167f023f2d
6
+ metadata.gz: 541aa7f34eb8d3c213d389f51393f584ee5f4ac0a91f7e2dd23a95c6789fbef69353533eb55c655b55d4175d69ad05a0a76f994322f18eda890906134ff20fe0
7
+ data.tar.gz: 5c45ef55e4f449829676084bba0d0439dfa94db341f071fec883ac8490c9f662694e3d594287a9b20acde820075bfa65858d8b584bed2acd9fc26d9a8ed81e3b
checksums.yaml.gz.sig CHANGED
Binary file
data/README.adoc CHANGED
@@ -2,12 +2,13 @@
2
2
  :toclevels: 5
3
3
  :figure-caption!:
4
4
 
5
+ :data_link: link:https://alchemists.io/articles/ruby_data[Data]
6
+ :hanami_link: link:https://hanamirb.org[Hanami]
7
+ :hanami_views_link: link:https://alchemists.io/articles/hanami_views[Hanami Views]
8
+ :hanamismith_link: link:https://alchemists.io/projects/hanamismith[Hanamismith]
5
9
  :htmx_link: link:https://htmx.org[htmx]
6
10
  :hypermedia_systems_link: link:https://hypermedia.systems[Hypermedia Systems]
7
- :hanami_link: link:https://hanamirb.org[Hanami]
8
11
  :roda_link: link:http://roda.jeremyevans.net[Roda]
9
- :data_link: link:https://alchemists.io/articles/ruby_data[Data]
10
- :hanamismith_link: link:https://alchemists.io/projects/hanamismith[Hanamismith]
11
12
 
12
13
  = HTMX
13
14
 
@@ -28,7 +29,7 @@ ____
28
29
 
29
30
  This gem provides native Ruby support for the {htmx_link} JavaScript library so you can build sophisticated web applications using pure Hypermedia REST APIs while avoiding unnecessary bloat and complexity common with the JavaScript ecosystem. By building upon the original foundations of Hypermedia REST APIs, you can build rich web applications with no additional JavaScript!
30
31
 
31
- 💡 This is used with the {hanamismith_link} gem when building {hanami_link} applications. Even better, you can play with the link:https://github.com/bkuhlmann/hemo[Hanami demo application] to learn more. Enjoy!
32
+ 💡 This is used with the {hanamismith_link} gem when building {hanami_link} applications.
32
33
 
33
34
  toc::[]
34
35
 
@@ -78,7 +79,7 @@ require "htmx"
78
79
 
79
80
  == Usage
80
81
 
81
- One of the first tasks you'll want to tackle, when working with the {htmx_link} library, is building htmx specific HTML attributes. This can be accomplished by using the `.[]` method. For example, when implementing a {hanami_link} view part, you could use the following:
82
+ One of the first tasks to tackle, when working with the {htmx_link} library, is building htmx specific HTML attributes. This can be accomplished by using the `.[]` method. For example, when implementing a {hanami_views_link} part, you could use the following:
82
83
 
83
84
  [source,ruby]
84
85
  ----
@@ -117,7 +118,7 @@ tag.button(
117
118
  )
118
119
  ----
119
120
 
120
- This would then produce the following HTML code:
121
+ This will produce the following HTML code:
121
122
 
122
123
  [source,html]
123
124
  ----
@@ -139,9 +140,7 @@ HTMX::Prefixer.new.call delete: "/tasks/1"
139
140
  HTMX::Prefixer.new("hx").call delete: "/tasks/1"
140
141
  ----
141
142
 
142
- All three of the above will produce the same output which means you'll most likely want to use the `.[]` method since it has the shortest syntax.
143
-
144
- If you attempt to use an unsupported prefix, you'll get an error:
143
+ All three of the above will produce the same output which means you'll most likely want to use the `.[]` method since it has the shortest syntax. If you attempt to use an unsupported prefix, you'll get an error:
145
144
 
146
145
  [source,ruby]
147
146
  ----
data/htmx.gemspec CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |spec|
4
4
  spec.name = "htmx"
5
- spec.version = "3.1.0"
5
+ spec.version = "3.3.0"
6
6
  spec.authors = ["Brooke Kuhlmann"]
7
7
  spec.email = ["brooke@alchemists.io"]
8
8
  spec.homepage = "https://alchemists.io/projects/htmx"
@@ -25,7 +25,7 @@ Gem::Specification.new do |spec|
25
25
  spec.required_ruby_version = ">= 4.0"
26
26
 
27
27
  spec.add_dependency "refinements", "~> 14.0"
28
- spec.add_dependency "zeitwerk", "~> 2.7"
28
+ spec.add_dependency "zeitwerk", "~> 2.8"
29
29
 
30
30
  spec.extra_rdoc_files = Dir["README*", "LICENSE*"]
31
31
  spec.files = Dir["*.gemspec", "lib/**/*"]
@@ -8,7 +8,7 @@ module HTMX
8
8
  Request = Data.define(*REQUEST_MAP.keys) do
9
9
  using Refinements::String
10
10
 
11
- def self.for(key_map: REQUEST_MAP.invert, **attributes)
11
+ def self.for key_map: REQUEST_MAP.invert, **attributes
12
12
  new(**attributes.slice(*key_map.keys).transform_keys!(key_map))
13
13
  end
14
14
 
@@ -4,7 +4,7 @@ module HTMX
4
4
  module Headers
5
5
  # Models the supported HTMX response headers.
6
6
  Response = Data.define(*RESPONSE_MAP.keys) do
7
- def self.for(key_map: RESPONSE_MAP.invert, **attributes)
7
+ def self.for key_map: RESPONSE_MAP.invert, **attributes
8
8
  new(**attributes.slice(*key_map.keys).transform_keys!(key_map))
9
9
  end
10
10
 
data/lib/htmx.rb CHANGED
@@ -52,7 +52,7 @@ module HTMX
52
52
 
53
53
  def self.response(**) = Headers::Response.for(**)
54
54
 
55
- def self.response!(headers, **attributes)
55
+ def self.response! headers, **attributes
56
56
  headers.merge! attributes.transform_keys!(RESPONSE_MAP)
57
57
  end
58
58
 
data.tar.gz.sig CHANGED
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: htmx
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.1.0
4
+ version: 3.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brooke Kuhlmann
@@ -9,9 +9,9 @@ bindir: bin
9
9
  cert_chain:
10
10
  - |
11
11
  -----BEGIN CERTIFICATE-----
12
- MIIENjCCAp6gAwIBAgIBAjANBgkqhkiG9w0BAQsFADBBMQ8wDQYDVQQDDAZicm9v
12
+ MIIENjCCAp6gAwIBAgIBAzANBgkqhkiG9w0BAQsFADBBMQ8wDQYDVQQDDAZicm9v
13
13
  a2UxGjAYBgoJkiaJk/IsZAEZFgphbGNoZW1pc3RzMRIwEAYKCZImiZPyLGQBGRYC
14
- aW8wHhcNMjUwMzIyMTQ1NDE3WhcNMjYwMzIyMTQ1NDE3WjBBMQ8wDQYDVQQDDAZi
14
+ aW8wHhcNMjYwMzI1MTI0OTEyWhcNMjcwMzI1MTI0OTEyWjBBMQ8wDQYDVQQDDAZi
15
15
  cm9va2UxGjAYBgoJkiaJk/IsZAEZFgphbGNoZW1pc3RzMRIwEAYKCZImiZPyLGQB
16
16
  GRYCaW8wggGiMA0GCSqGSIb3DQEBAQUAA4IBjwAwggGKAoIBgQCro8tj5/E1Hg88
17
17
  f4qfiwPVd2zJQHvdYt4GHVvuHRRgx4HGhJuNp+4BId08RBn7V6V1MW6MY3kezRBs
@@ -23,15 +23,15 @@ cert_chain:
23
23
  GUHU9MyIXbFOsnp3K3ADrAVjPWop8EZkmUR3MV/CUm00w2cZHCSGiXl1KMpiVKvk
24
24
  Ywr1gd2ZME4QLSo+EXUtLxDUa/W3xnBS8dBOuMMz02FPWYr3PN8CAwEAAaM5MDcw
25
25
  CQYDVR0TBAIwADALBgNVHQ8EBAMCBLAwHQYDVR0OBBYEFAFgmv0tYMZnItuPycSM
26
- F5wykJEVMA0GCSqGSIb3DQEBCwUAA4IBgQBlzRfyAYx/fC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RrCZYDjfguyLmMjR
34
+ KR9w4/Fjvqy87kCHmxMWa6IL2Vzt1Clm2cA=
35
35
  -----END CERTIFICATE-----
36
36
  date: 1980-01-02 00:00:00.000000000 Z
37
37
  dependencies:
@@ -55,14 +55,14 @@ dependencies:
55
55
  requirements:
56
56
  - - "~>"
57
57
  - !ruby/object:Gem::Version
58
- version: '2.7'
58
+ version: '2.8'
59
59
  type: :runtime
60
60
  prerelease: false
61
61
  version_requirements: !ruby/object:Gem::Requirement
62
62
  requirements:
63
63
  - - "~>"
64
64
  - !ruby/object:Gem::Version
65
- version: '2.7'
65
+ version: '2.8'
66
66
  email:
67
67
  - brooke@alchemists.io
68
68
  executables: []
@@ -104,7 +104,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
104
104
  - !ruby/object:Gem::Version
105
105
  version: '0'
106
106
  requirements: []
107
- rubygems_version: 4.0.4
107
+ rubygems_version: 4.0.15
108
108
  specification_version: 4
109
109
  summary: An augmenter and companion to the HTMX JavaScript library.
110
110
  test_files: []
metadata.gz.sig CHANGED
Binary file