roda-phlex 0.3.0 → 1.0.0.beta1
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 +4 -4
- data/.standard.yml +1 -1
- data/CHANGELOG.md +4 -18
- data/lib/roda/phlex.rb +1 -1
- data/lib/roda/plugins/phlex.rb +3 -12
- metadata +6 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ab83be491f6ff213f1097afe81e6f3af4fba92b87cce26826deae0f2814df623
|
4
|
+
data.tar.gz: e874de74010cf0c913df896d356337fc8ed59434a435e037e404de0e650f8268
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e9b359e8a1c34db8c4f1817358bf3b423c63186515455bef90daad7e3135f014c967d70d0086c5a51af3253796a69da3d8ee0399d57c49237991d9323af0d53c
|
7
|
+
data.tar.gz: 6f284a8c8ef79ab27ecc5f3ab370381eb1f4396c727907a49494681317b7db70a11bc797fada70af76f03502660e87835df7568fff8eccb29f95f9a72c57e5d4
|
data/.standard.yml
CHANGED
data/CHANGELOG.md
CHANGED
@@ -4,25 +4,11 @@ All notable changes to this project will be documented in this file.
|
|
4
4
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/)
|
6
6
|
|
7
|
-
## [
|
7
|
+
## [1.0.0.beta1] - 2025-01-06
|
8
8
|
|
9
9
|
### Added
|
10
10
|
|
11
|
-
|
12
|
-
|
13
|
-
### Deprecated
|
14
|
-
|
15
|
-
### Removed
|
16
|
-
|
17
|
-
### Fixed
|
18
|
-
|
19
|
-
### Security
|
20
|
-
|
21
|
-
## [0.3.0] - 2025-01-27
|
22
|
-
|
23
|
-
### Added
|
24
|
-
|
25
|
-
- Support for Phlex Component context. (`HelloWorld.new.call(context: {some: :data})`).
|
11
|
+
- Support for Phlex 2.0 Component context. (`HelloWorld.new.call(context: {some: :data})`).
|
26
12
|
+ Like layout options, the `:context` plugin option can be used to set a default context.
|
27
13
|
The value will be`dup`ed on first use.
|
28
14
|
+ `#phlex_context` method to access the context.
|
@@ -34,6 +20,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/)
|
|
34
20
|
|
35
21
|
### Changed
|
36
22
|
|
23
|
+
- Update to phlex 2.0.
|
37
24
|
- `#phlex_layout`, `#phlex_layout_opts`, `#phlex_layout_handler` no longer accept a value to set their value.
|
38
25
|
Use their corresponding `#set_*` methods instead.
|
39
26
|
|
@@ -72,8 +59,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/)
|
|
72
59
|
|
73
60
|
________________________________________________________________________________
|
74
61
|
|
75
|
-
[Unreleased]: https://github.com/fnordfish/roda-phlex/compare/v0.
|
76
|
-
[0.3.0]: https://github.com/fnordfish/roda-phlex/releases/tag/v0.3.0
|
62
|
+
[Unreleased]: https://github.com/fnordfish/roda-phlex/compare/v0.2.0...main
|
77
63
|
[0.2.0]: https://github.com/fnordfish/roda-phlex/releases/tag/v0.2.0
|
78
64
|
[0.1.0]: https://github.com/fnordfish/roda-phlex/releases/tag/v0.1.0
|
79
65
|
|
data/lib/roda/phlex.rb
CHANGED
data/lib/roda/plugins/phlex.rb
CHANGED
@@ -78,7 +78,7 @@ class Roda
|
|
78
78
|
delegate_mod = Module.new do
|
79
79
|
class_eval <<~RUBY, __FILE__, __LINE__ + 1
|
80
80
|
def #{delegate_name}
|
81
|
-
@
|
81
|
+
@_context.view_context
|
82
82
|
end
|
83
83
|
RUBY
|
84
84
|
|
@@ -195,21 +195,12 @@ class Roda
|
|
195
195
|
obj
|
196
196
|
end
|
197
197
|
|
198
|
-
opts = {view_context: self}
|
199
|
-
if context
|
200
|
-
opts[:context] = if context.is_a?(::Phlex::Context)
|
201
|
-
context
|
202
|
-
else
|
203
|
-
::Phlex::Context.new(context)
|
204
|
-
end
|
205
|
-
end
|
206
|
-
|
207
198
|
if stream
|
208
199
|
self.stream do |out|
|
209
|
-
renderer.call(out,
|
200
|
+
renderer.call(out, context: context, view_context: self)
|
210
201
|
end
|
211
202
|
else
|
212
|
-
renderer.call(
|
203
|
+
renderer.call(context: context, view_context: self)
|
213
204
|
end
|
214
205
|
end
|
215
206
|
end
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: roda-phlex
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 1.0.0.beta1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Robert Schulze
|
8
8
|
bindir: exe
|
9
9
|
cert_chain: []
|
10
|
-
date: 2025-01-
|
10
|
+
date: 2025-01-06 00:00:00.000000000 Z
|
11
11
|
dependencies:
|
12
12
|
- !ruby/object:Gem::Dependency
|
13
13
|
name: phlex
|
@@ -15,20 +15,20 @@ dependencies:
|
|
15
15
|
requirements:
|
16
16
|
- - ">="
|
17
17
|
- !ruby/object:Gem::Version
|
18
|
-
version:
|
18
|
+
version: 2.0.0.rc1
|
19
19
|
- - "<"
|
20
20
|
- !ruby/object:Gem::Version
|
21
|
-
version: '
|
21
|
+
version: '3'
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
24
|
version_requirements: !ruby/object:Gem::Requirement
|
25
25
|
requirements:
|
26
26
|
- - ">="
|
27
27
|
- !ruby/object:Gem::Version
|
28
|
-
version:
|
28
|
+
version: 2.0.0.rc1
|
29
29
|
- - "<"
|
30
30
|
- !ruby/object:Gem::Version
|
31
|
-
version: '
|
31
|
+
version: '3'
|
32
32
|
- !ruby/object:Gem::Dependency
|
33
33
|
name: roda
|
34
34
|
requirement: !ruby/object:Gem::Requirement
|