solid_objects 0.4.0 → 0.4.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 557108141818714af50bfee19acda22c9243482e976b50329e5e234aed6d9adb
4
- data.tar.gz: fe525288022e4bb0630e60bc7ec949e2f61d1ad152fadcaccaeaa41bd1a0376e
3
+ metadata.gz: dbdb5026eeec1282e210ade64d2ca36277fca65cf6cc2928bdcc32ff5ebabf44
4
+ data.tar.gz: 5695cf4b7bf4740e894ea5b6e417587e593ff5309836d1732d0b98b763eef563
5
5
  SHA512:
6
- metadata.gz: e4414b1f2e0d47f95f9307fec6140894bcd8ebcab6dbdc20f54155c332dea76de2728ca7b0bf71bc13c978f2494e059f2099986757c3b933296d460a2bec7a65
7
- data.tar.gz: 6e807551d58c7d87465bc55b460386f5b9617e36021ddbdfdcbfd25aac31d9c48a7166a818f5a39be3f52eb6a7cb63efd74223a0512fb7a53dce7c55a2c23ca8
6
+ metadata.gz: db4b8a1ba379ba645aff1325e54b66dbd5c1313d9cfe9b99b578f59e86173444a638d07d3650ec63bd3c0756c7f795498e936342ac0d255cc00a6b782f601192
7
+ data.tar.gz: 30eaa6707bb3ca94a9cd09d94f2e2a382afc95ea5127b8f118458f6a8bcd4c3e00875d7fdca0b83da68b86b43793e76b24012ef4814cd63081fa3b43cbfbf7ec
data/CHANGELOG.md CHANGED
@@ -1,5 +1,10 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.4.1 - 2026-08-07
4
+
5
+ - Load `SolidObjects::ActorChannel` with the gem and pass stream and component
6
+ subscription tokens through Turbo-compatible `data-*` attributes.
7
+
3
8
  ## 0.4.0 - 2026-08-06
4
9
 
5
10
  - Add dependency-driven live ERB components with request-time authorization,
@@ -10,19 +10,19 @@ module SolidObjects
10
10
  authorization_context:
11
11
  )
12
12
  content = capture(actor, &block)
13
- subscription_attributes = {
14
- channel: "SolidObjects::ActorChannel",
13
+ subscription_data = {
15
14
  token: StreamToken.generate(
16
15
  reference,
17
16
  observables: actor.scalar_observable_names
18
17
  )
19
18
  }
20
19
  if actor.component_tokens.any?
21
- subscription_attributes[:data] = {
22
- components: JSON.generate(actor.component_tokens)
23
- }
20
+ subscription_data[:components] = JSON.generate(actor.component_tokens)
24
21
  end
25
- subscription = tag.turbo_cable_stream_source(**subscription_attributes)
22
+ subscription = tag.turbo_cable_stream_source(
23
+ channel: "SolidObjects::ActorChannel",
24
+ data: subscription_data
25
+ )
26
26
 
27
27
  content_tag(
28
28
  :div,
@@ -1,6 +1,6 @@
1
1
  # rbs_inline: enabled
2
2
 
3
- require "action_cable/channel/base"
3
+ require "action_cable"
4
4
 
5
5
  module SolidObjects
6
6
  class ActorChannel < ActionCable::Channel::Base
@@ -1,5 +1,5 @@
1
1
  # rbs_inline: enabled
2
2
 
3
3
  module SolidObjects
4
- VERSION = "0.4.0"
4
+ VERSION = "0.4.1"
5
5
  end
data/lib/solid_objects.rb CHANGED
@@ -42,6 +42,7 @@ require "solid_objects/component_view"
42
42
  require "solid_objects/component_renderer"
43
43
  require "solid_objects/state_snapshot"
44
44
  require "solid_objects/actor_view"
45
+ require "solid_objects/actor_channel"
45
46
  require "solid_objects/action_cable_broadcast_adapter"
46
47
  require "solid_objects/wake_up"
47
48
  require "solid_objects/effect_registry"
metadata CHANGED
@@ -1,13 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: solid_objects
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.0
4
+ version: 0.4.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Lucas Carlson
8
+ autorequire:
8
9
  bindir: exe
9
10
  cert_chain: []
10
- date: 1980-01-02 00:00:00.000000000 Z
11
+ date: 2026-08-07 00:00:00.000000000 Z
11
12
  dependencies:
12
13
  - !ruby/object:Gem::Dependency
13
14
  name: actioncable
@@ -251,6 +252,7 @@ description: 'The Cloudflare Durable Objects programming model for Rails: addres
251
252
  objects with durable state, ordered mailboxes, fenced activation, per-object alarms,
252
253
  transactional effects, and reactive ERB. It runs on MySQL, PostgreSQL, and SQLite
253
254
  without requiring Redis.'
255
+ email:
254
256
  executables:
255
257
  - solid_objects
256
258
  extensions: []
@@ -487,6 +489,7 @@ metadata:
487
489
  homepage_uri: https://solidobjects.dev
488
490
  rubygems_mfa_required: 'true'
489
491
  source_code_uri: https://github.com/cardmagic/solid_objects
492
+ post_install_message:
490
493
  rdoc_options: []
491
494
  require_paths:
492
495
  - lib
@@ -501,7 +504,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
501
504
  - !ruby/object:Gem::Version
502
505
  version: '0'
503
506
  requirements: []
504
- rubygems_version: 4.0.10
507
+ rubygems_version: 3.5.22
508
+ signing_key:
505
509
  specification_version: 4
506
510
  summary: Cloudflare Durable Objects, ported to Rails
507
511
  test_files: []