live 0.17.0 → 0.18.1
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
- checksums.yaml.gz.sig +0 -0
- data/lib/live/element.rb +2 -2
- data/lib/live/version.rb +2 -2
- data/lib/live/view.rb +6 -2
- data/license.md +1 -1
- data/readme.md +37 -0
- data/releases.md +8 -0
- data.tar.gz.sig +0 -0
- metadata +5 -9
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: e03f037493e99c9b309201c8f658f3f4bdd1dfc2516498a13202f157e7f73211
|
|
4
|
+
data.tar.gz: 37b81f8c41e3115724de8bb4e836ff4b8dcd26741920ec8cee4c0e7331781b8a
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 356991404963632fb53677321ab6b3b89395891916cc6485106bc8f8c8de42fe1be56d2c69dddb441cb94943ac19b1fe3d3382ee8ebb0a5c50c9cc57a3778858
|
|
7
|
+
data.tar.gz: 7a04b36d8ef732f273b3f41e6df786a405697b9866a1e97ad2c28c2ac8f0f92fea807d12364d5a686bf0dfaaa0b9ee2d7036330a003bedd855b6033f60d0deef
|
checksums.yaml.gz.sig
CHANGED
|
Binary file
|
data/lib/live/element.rb
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
3
|
# Released under the MIT License.
|
|
4
|
-
# Copyright, 2021-
|
|
4
|
+
# Copyright, 2021-2026, by Samuel Williams.
|
|
5
5
|
|
|
6
6
|
require "json"
|
|
7
7
|
require "securerandom"
|
|
@@ -145,7 +145,7 @@ module Live
|
|
|
145
145
|
end
|
|
146
146
|
|
|
147
147
|
def dispatch_event(selector, type, **options)
|
|
148
|
-
rpc(:dispatch_event, selector,
|
|
148
|
+
rpc(:dispatch_event, selector, type, options)
|
|
149
149
|
end
|
|
150
150
|
|
|
151
151
|
# Render the element.
|
data/lib/live/version.rb
CHANGED
data/lib/live/view.rb
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
3
|
# Released under the MIT License.
|
|
4
|
-
# Copyright, 2021-
|
|
4
|
+
# Copyright, 2021-2026, by Samuel Williams.
|
|
5
5
|
|
|
6
6
|
require_relative "element"
|
|
7
7
|
require "xrb/builder"
|
|
@@ -9,9 +9,13 @@ require "xrb/builder"
|
|
|
9
9
|
module Live
|
|
10
10
|
# Represents a single division of content on the page an provides helpers for rendering the content.
|
|
11
11
|
class View < Element
|
|
12
|
+
def tag_name
|
|
13
|
+
"live-view"
|
|
14
|
+
end
|
|
15
|
+
|
|
12
16
|
# @returns [Object] The generated HTML.
|
|
13
17
|
def build_markup(builder)
|
|
14
|
-
builder.inline_tag
|
|
18
|
+
builder.inline_tag self.tag_name, id: @id, data: @data do
|
|
15
19
|
render(builder)
|
|
16
20
|
end
|
|
17
21
|
end
|
data/license.md
CHANGED
data/readme.md
CHANGED
|
@@ -28,6 +28,32 @@ We welcome contributions to this project.
|
|
|
28
28
|
4. Push to the branch (`git push origin my-new-feature`).
|
|
29
29
|
5. Create new Pull Request.
|
|
30
30
|
|
|
31
|
+
### Running Tests
|
|
32
|
+
|
|
33
|
+
To run the test suite:
|
|
34
|
+
|
|
35
|
+
``` shell
|
|
36
|
+
bundle exec sus
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
### Making Releases
|
|
40
|
+
|
|
41
|
+
Please see the [project releases](https://socketry.github.io/live/releases/index) for all releases.
|
|
42
|
+
|
|
43
|
+
### v0.18.0
|
|
44
|
+
|
|
45
|
+
- **Breaking Change**: Live now uses Web Components for managing life-cycle events instead of observers. You will need to use `live-js` v0.16.0 or later with this version of `live`, which emits `<live-view>` elements (instead of `<div>` elements).
|
|
46
|
+
- Using older versions of `live-js` with this version of `live` may result in unexpected behavior or errors.
|
|
47
|
+
- Using older versions of `live` with `live-js` v0.16.0 or later may also result in unexpected behavior or errors.
|
|
48
|
+
- Updating both `live` and `live-js` to their latest versions is recommended to ensure compatibility, and requires no changes to application code.
|
|
49
|
+
|
|
50
|
+
### v0.18.0
|
|
51
|
+
|
|
52
|
+
- **Breaking Change**: Live now uses Web Components for managing life-cycle events instead of observers. You will need to use `live-js` v0.16.0 or later with this version of `live`, which emits `<live-view>` elements (instead of `<div>` elements).
|
|
53
|
+
- Using older versions of `live-js` with this version of `live` may result in unexpected behavior or errors.
|
|
54
|
+
- Using older versions of `live` with `live-js` v0.16.0 or later may also result in unexpected behavior or errors.
|
|
55
|
+
- Updating both `live` and `live-js` to their latest versions is recommended to ensure compatibility, and requires no changes to application code.
|
|
56
|
+
|
|
31
57
|
### Developer Certificate of Origin
|
|
32
58
|
|
|
33
59
|
In order to protect users of this project, we require all contributors to comply with the [Developer Certificate of Origin](https://developercertificate.org/). This ensures that all contributions are properly licensed and attributed.
|
|
@@ -36,6 +62,17 @@ In order to protect users of this project, we require all contributors to comply
|
|
|
36
62
|
|
|
37
63
|
This project is best served by a collaborative and respectful environment. Treat each other professionally, respect differing viewpoints, and engage constructively. Harassment, discrimination, or harmful behavior is not tolerated. Communicate clearly, listen actively, and support one another. If any issues arise, please inform the project maintainers.
|
|
38
64
|
|
|
65
|
+
## Releases
|
|
66
|
+
|
|
67
|
+
Please see the [project releases](https://socketry.github.io/live/releases/index) for all releases.
|
|
68
|
+
|
|
69
|
+
### v0.18.0
|
|
70
|
+
|
|
71
|
+
- **Breaking Change**: Live now uses Web Components for managing life-cycle events instead of observers. You will need to use `live-js` v0.16.0 or later with this version of `live`, which emits `<live-view>` elements (instead of `<div>` elements).
|
|
72
|
+
- Using older versions of `live-js` with this version of `live` may result in unexpected behavior or errors.
|
|
73
|
+
- Using older versions of `live` with `live-js` v0.16.0 or later may also result in unexpected behavior or errors.
|
|
74
|
+
- Updating both `live` and `live-js` to their latest versions is recommended to ensure compatibility, and requires no changes to application code.
|
|
75
|
+
|
|
39
76
|
## See Also
|
|
40
77
|
|
|
41
78
|
- [live-js](https://github.com/socketry/live-js) – The client-side JavaScript library.
|
data/releases.md
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
# Releases
|
|
2
|
+
|
|
3
|
+
## v0.18.0
|
|
4
|
+
|
|
5
|
+
- **Breaking Change**: Live now uses Web Components for managing life-cycle events instead of observers. You will need to use `live-js` v0.16.0 or later with this version of `live`, which emits `<live-view>` elements (instead of `<div>` elements).
|
|
6
|
+
- Using older versions of `live-js` with this version of `live` may result in unexpected behavior or errors.
|
|
7
|
+
- Using older versions of `live` with `live-js` v0.16.0 or later may also result in unexpected behavior or errors.
|
|
8
|
+
- Updating both `live` and `live-js` to their latest versions is recommended to ensure compatibility, and requires no changes to application code.
|
data.tar.gz.sig
CHANGED
|
Binary file
|
metadata
CHANGED
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: live
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.18.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Samuel Williams
|
|
8
8
|
- Olle Jonsson
|
|
9
9
|
- Tatsuhiro Ujihisa
|
|
10
|
-
autorequire:
|
|
11
10
|
bindir: bin
|
|
12
11
|
cert_chain:
|
|
13
12
|
- |
|
|
@@ -39,7 +38,7 @@ cert_chain:
|
|
|
39
38
|
Q2K9NVun/S785AP05vKkXZEFYxqG6EW012U4oLcFl5MySFajYXRYbuUpH6AY+HP8
|
|
40
39
|
voD0MPg1DssDLKwXyt1eKD/+Fq0bFWhwVM/1XiAXL7lyYUyOq24KHgQ2Csg=
|
|
41
40
|
-----END CERTIFICATE-----
|
|
42
|
-
date:
|
|
41
|
+
date: 1980-01-02 00:00:00.000000000 Z
|
|
43
42
|
dependencies:
|
|
44
43
|
- !ruby/object:Gem::Dependency
|
|
45
44
|
name: async-websocket
|
|
@@ -83,8 +82,6 @@ dependencies:
|
|
|
83
82
|
- - "~>"
|
|
84
83
|
- !ruby/object:Gem::Version
|
|
85
84
|
version: '0.10'
|
|
86
|
-
description:
|
|
87
|
-
email:
|
|
88
85
|
executables: []
|
|
89
86
|
extensions: []
|
|
90
87
|
extra_rdoc_files: []
|
|
@@ -97,13 +94,13 @@ files:
|
|
|
97
94
|
- lib/live/view.rb
|
|
98
95
|
- license.md
|
|
99
96
|
- readme.md
|
|
97
|
+
- releases.md
|
|
100
98
|
homepage: https://github.com/socketry/live
|
|
101
99
|
licenses:
|
|
102
100
|
- MIT
|
|
103
101
|
metadata:
|
|
104
102
|
documentation_uri: https://socketry.github.io/live/
|
|
105
103
|
source_code_uri: https://github.com/socketry/live.git
|
|
106
|
-
post_install_message:
|
|
107
104
|
rdoc_options: []
|
|
108
105
|
require_paths:
|
|
109
106
|
- lib
|
|
@@ -111,15 +108,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
111
108
|
requirements:
|
|
112
109
|
- - ">="
|
|
113
110
|
- !ruby/object:Gem::Version
|
|
114
|
-
version: '3.
|
|
111
|
+
version: '3.3'
|
|
115
112
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
116
113
|
requirements:
|
|
117
114
|
- - ">="
|
|
118
115
|
- !ruby/object:Gem::Version
|
|
119
116
|
version: '0'
|
|
120
117
|
requirements: []
|
|
121
|
-
rubygems_version:
|
|
122
|
-
signing_key:
|
|
118
|
+
rubygems_version: 4.0.6
|
|
123
119
|
specification_version: 4
|
|
124
120
|
summary: Live HTML tags updated via a WebSocket.
|
|
125
121
|
test_files: []
|
metadata.gz.sig
CHANGED
|
Binary file
|