proscenium-phlex 0.6.2 → 0.8.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 +4 -4
- data/.rubocop.yml +1 -1
- data/AGENTS.md +15 -0
- data/Appraisals +10 -0
- data/README.md +46 -11
- data/docs/agents/domain.md +51 -0
- data/docs/agents/issue-tracker.md +45 -0
- data/docs/agents/triage-labels.md +15 -0
- data/gemfiles/phlex1_rails7.gemfile +1 -1
- data/gemfiles/phlex1_rails7.gemfile.lock +160 -160
- data/gemfiles/phlex1_rails8.gemfile +1 -1
- data/gemfiles/phlex1_rails8.gemfile.lock +167 -165
- data/gemfiles/phlex1_rails81.gemfile +26 -0
- data/gemfiles/phlex1_rails81.gemfile.lock +540 -0
- data/gemfiles/phlex2_rails7.gemfile +1 -1
- data/gemfiles/phlex2_rails7.gemfile.lock +160 -160
- data/gemfiles/phlex2_rails8.gemfile +1 -1
- data/gemfiles/phlex2_rails8.gemfile.lock +167 -165
- data/gemfiles/phlex2_rails81.gemfile +26 -0
- data/gemfiles/phlex2_rails81.gemfile.lock +547 -0
- data/lib/proscenium/phlex/sideload.rb +6 -2
- data/lib/proscenium/phlex/version.rb +1 -1
- data/lib/proscenium/phlex.rb +0 -1
- metadata +15 -8
- data/lib/proscenium/phlex/react.rb +0 -32
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
module Proscenium::Phlex
|
|
4
|
-
# Renders a <div> for use with React components, with data attributes specifying the component
|
|
5
|
-
# path and props.
|
|
6
|
-
#
|
|
7
|
-
# If a block is given, it will be yielded within the div, allowing for a custom "loading" UI. If
|
|
8
|
-
# no block is given, then a "loading..." text will be rendered. It is intended that the component
|
|
9
|
-
# is mounted to this div, and the loading UI will then be replaced with the component's rendered
|
|
10
|
-
# output.
|
|
11
|
-
#
|
|
12
|
-
# You can pass props to the component in the `:props` keyword argument.
|
|
13
|
-
module React
|
|
14
|
-
extend ActiveSupport::Concern
|
|
15
|
-
include Sideload
|
|
16
|
-
include Proscenium::ReactComponentable
|
|
17
|
-
|
|
18
|
-
# Override this to provide your own loading UI.
|
|
19
|
-
#
|
|
20
|
-
# @example
|
|
21
|
-
# def view_template(**attributes, &block)
|
|
22
|
-
# super do
|
|
23
|
-
# 'Look at me! I am loading now...'
|
|
24
|
-
# end
|
|
25
|
-
# end
|
|
26
|
-
#
|
|
27
|
-
# @yield the given block to a `div` within the top level component div.
|
|
28
|
-
def view_template(**attributes, &)
|
|
29
|
-
send(root_tag, **{ data: data_attributes }.deep_merge(attributes), &)
|
|
30
|
-
end
|
|
31
|
-
end
|
|
32
|
-
end
|