heartml 1.0.0.beta15 → 1.0.0.beta16
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/Gemfile.lock +1 -1
- data/lib/heartml/bridgetown_renderer.rb +6 -3
- data/lib/heartml/version.rb +1 -1
- data/lib/heartml.rb +4 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 33b3883d286639fd0120ce59444d69f5a69a77fff208d5fcc057338210bcde4d
|
4
|
+
data.tar.gz: a385e62cf6d4232ba5ede351c4a0c6e885bd7260ea35afff78ee35eaf7449fee
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4da9a2ac04771a7f7024caf8f2db678f6459a54f7090513a2a00402e6ec65626ed61a90abdf314219ace4a310d6d87eaafb65f97a6c1994b0fdf5861897bb051
|
7
|
+
data.tar.gz: d19f2e2285950719c5456087e6eff9f27577da175257ec8ec58cecd0188ee57690934d0e3f06c2156f1dc5e4828857284d0fdf0b0ab051c2af9441c89cbc6de0
|
data/CHANGELOG.md
CHANGED
data/Gemfile.lock
CHANGED
@@ -2,6 +2,12 @@
|
|
2
2
|
|
3
3
|
module Heartml
|
4
4
|
class BridgetownRenderer < Bridgetown::Builder
|
5
|
+
# Called when a `Bridgetown::Component` includes `Heartml`, so we can bypass Bridgetown's
|
6
|
+
# normal component template handling
|
7
|
+
def self.component_overrides(klass)
|
8
|
+
klass.define_method(:template) { call }
|
9
|
+
end
|
10
|
+
|
5
11
|
def build
|
6
12
|
render_heart_modules
|
7
13
|
end
|
@@ -18,9 +24,6 @@ module Heartml
|
|
18
24
|
end
|
19
25
|
|
20
26
|
Bridgetown.initializer :heartml do |config|
|
21
|
-
# TODO: maybe we can ditch this once we're off ActiveSupport in Bridgetown
|
22
|
-
Bridgetown::Component.extend ActiveSupport::DescendantsTracker
|
23
|
-
|
24
27
|
Heartml.module_eval do
|
25
28
|
def render_in(view_context, rendering_mode: :string, &block)
|
26
29
|
self.rendering_mode = rendering_mode
|
data/lib/heartml/version.rb
CHANGED
data/lib/heartml.rb
CHANGED
@@ -66,6 +66,10 @@ module Heartml
|
|
66
66
|
klass.include ContentMethod unless has_content_method
|
67
67
|
|
68
68
|
ServerEffects.included_extras(klass)
|
69
|
+
|
70
|
+
return unless defined?(Bridgetown) && klass < Bridgetown::Component
|
71
|
+
|
72
|
+
BridgetownRenderer.component_overrides(klass)
|
69
73
|
end
|
70
74
|
|
71
75
|
# Extends the component class
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: heartml
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.0.
|
4
|
+
version: 1.0.0.beta16
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jared White
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-10-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: concurrent-ruby
|