proscenium 0.19.0.beta10-aarch64-linux → 0.19.0.beta12-aarch64-linux
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/README.md +0 -44
- data/lib/proscenium/bundled_gems.rb +1 -1
- data/lib/proscenium/css_module.rb +0 -5
- data/lib/proscenium/ext/proscenium +0 -0
- data/lib/proscenium/middleware.rb +0 -6
- data/lib/proscenium/monkey.rb +2 -9
- data/lib/proscenium/phlex.rb +0 -6
- data/lib/proscenium/railtie.rb +0 -25
- data/lib/proscenium/react_componentable.rb +1 -1
- data/lib/proscenium/resolver.rb +0 -9
- data/lib/proscenium/version.rb +1 -1
- data/lib/proscenium.rb +6 -34
- metadata +24 -136
- data/lib/proscenium/registry/bundled_package.rb +0 -29
- data/lib/proscenium/registry/package.rb +0 -95
- data/lib/proscenium/registry/ruby_gem_package.rb +0 -30
- data/lib/proscenium/registry.rb +0 -29
- data/lib/proscenium/ruby_gems.rb +0 -67
- data/lib/proscenium/ui/breadcrumbs/component.module.css +0 -14
- data/lib/proscenium/ui/breadcrumbs/component.rb +0 -71
- data/lib/proscenium/ui/breadcrumbs/computed_element.rb +0 -69
- data/lib/proscenium/ui/breadcrumbs/control.rb +0 -95
- data/lib/proscenium/ui/breadcrumbs/mixins.css +0 -83
- data/lib/proscenium/ui/breadcrumbs.rb +0 -72
- data/lib/proscenium/ui/component.rb +0 -7
- data/lib/proscenium/ui/custom_element.js +0 -54
- data/lib/proscenium/ui/flash/bun.lock +0 -19
- data/lib/proscenium/ui/flash/index.css +0 -1
- data/lib/proscenium/ui/flash/index.js +0 -77
- data/lib/proscenium/ui/flash/node_modules/dom-mutations/index.d.ts +0 -33
- data/lib/proscenium/ui/flash/node_modules/dom-mutations/index.js +0 -44
- data/lib/proscenium/ui/flash/node_modules/dom-mutations/license +0 -9
- data/lib/proscenium/ui/flash/node_modules/dom-mutations/package.json +0 -59
- data/lib/proscenium/ui/flash/node_modules/dom-mutations/readme.md +0 -125
- data/lib/proscenium/ui/flash/node_modules/sourdough-toast/LICENSE +0 -20
- data/lib/proscenium/ui/flash/node_modules/sourdough-toast/README.md +0 -11
- data/lib/proscenium/ui/flash/node_modules/sourdough-toast/package.json +0 -44
- data/lib/proscenium/ui/flash/node_modules/sourdough-toast/src/sourdough-toast.css +0 -697
- data/lib/proscenium/ui/flash/node_modules/sourdough-toast/src/sourdough-toast.js +0 -537
- data/lib/proscenium/ui/flash/package.json +0 -11
- data/lib/proscenium/ui/flash.rb +0 -15
- data/lib/proscenium/ui/form/field_methods.rb +0 -88
- data/lib/proscenium/ui/form/fields/base.rb +0 -188
- data/lib/proscenium/ui/form/fields/checkbox/index.jsx +0 -48
- data/lib/proscenium/ui/form/fields/checkbox/index.module.css +0 -9
- data/lib/proscenium/ui/form/fields/checkbox/previews/basic.jsx +0 -8
- data/lib/proscenium/ui/form/fields/checkbox.rb +0 -32
- data/lib/proscenium/ui/form/fields/date.module.css +0 -27
- data/lib/proscenium/ui/form/fields/datetime.rb +0 -15
- data/lib/proscenium/ui/form/fields/hidden.rb +0 -9
- data/lib/proscenium/ui/form/fields/input/index.jsx +0 -71
- data/lib/proscenium/ui/form/fields/input/index.module.css +0 -13
- data/lib/proscenium/ui/form/fields/input/previews/basic.jsx +0 -8
- data/lib/proscenium/ui/form/fields/input.rb +0 -14
- data/lib/proscenium/ui/form/fields/radio_group.rb +0 -173
- data/lib/proscenium/ui/form/fields/radio_input/index.jsx +0 -44
- data/lib/proscenium/ui/form/fields/radio_input/index.module.css +0 -13
- data/lib/proscenium/ui/form/fields/radio_input/previews/basic.jsx +0 -8
- data/lib/proscenium/ui/form/fields/radio_input.rb +0 -17
- data/lib/proscenium/ui/form/fields/rich_textarea.css +0 -23
- data/lib/proscenium/ui/form/fields/rich_textarea.js +0 -6
- data/lib/proscenium/ui/form/fields/rich_textarea.rb +0 -18
- data/lib/proscenium/ui/form/fields/select.jsx +0 -47
- data/lib/proscenium/ui/form/fields/select.module.css +0 -46
- data/lib/proscenium/ui/form/fields/select.rb +0 -300
- data/lib/proscenium/ui/form/fields/tel.css +0 -297
- data/lib/proscenium/ui/form/fields/tel.js +0 -83
- data/lib/proscenium/ui/form/fields/tel.rb +0 -54
- data/lib/proscenium/ui/form/fields/textarea/index.jsx +0 -50
- data/lib/proscenium/ui/form/fields/textarea/index.module.css +0 -13
- data/lib/proscenium/ui/form/fields/textarea/previews/basic.jsx +0 -8
- data/lib/proscenium/ui/form/fields/textarea.rb +0 -18
- data/lib/proscenium/ui/form/translation.rb +0 -71
- data/lib/proscenium/ui/form.css +0 -52
- data/lib/proscenium/ui/form.rb +0 -211
- data/lib/proscenium/ui/props.css +0 -7
- data/lib/proscenium/ui/stimulus-loading.js +0 -65
- data/lib/proscenium/ui/test.js +0 -1
- data/lib/proscenium/ui/ujs/class.js +0 -15
- data/lib/proscenium/ui/ujs/data_confirm.js +0 -23
- data/lib/proscenium/ui/ujs/data_disable_with.js +0 -68
- data/lib/proscenium/ui/ujs/index.js +0 -9
- data/lib/proscenium/ui.rb +0 -11
- data/lib/proscenium/view_component/css_modules.rb +0 -11
- data/lib/proscenium/view_component/react_component.rb +0 -22
- data/lib/proscenium/view_component/sideload.rb +0 -4
- data/lib/proscenium/view_component.rb +0 -36
- /data/lib/proscenium/{ui/react-manager → react-manager}/index.jsx +0 -0
- /data/lib/proscenium/{ui/react-manager → react-manager}/react.js +0 -0
    
        checksums.yaml
    CHANGED
    
    | @@ -1,7 +1,7 @@ | |
| 1 1 | 
             
            ---
         | 
| 2 2 | 
             
            SHA256:
         | 
| 3 | 
            -
              metadata.gz:  | 
| 4 | 
            -
              data.tar.gz:  | 
| 3 | 
            +
              metadata.gz: 5ae2bdd7e417b8d8067e66758ede7bbfd2ca83dd391bfe8d7f04e78de09cb7c5
         | 
| 4 | 
            +
              data.tar.gz: 1f48c9358ff22a916a054d90b42a507f4695b7eb3cc2257f1d1054013872898b
         | 
| 5 5 | 
             
            SHA512:
         | 
| 6 | 
            -
              metadata.gz:  | 
| 7 | 
            -
              data.tar.gz:  | 
| 6 | 
            +
              metadata.gz: 19a9acbfb66940b3f82bbc15ced94730a49d93b0df5ce6ca133b222e9f66caaf883231b4b137e593715462f27650b73868ac1459b056fa6d4d5dea740b585540
         | 
| 7 | 
            +
              data.tar.gz: '033778e877ec3b35f21cdcec619e3a9453ec2fb6b33c3dca69c89524220d3c8a978580e97df0a3c3fc312b660ae8eab326ee8781f4a4b96420409788353c36ef'
         | 
    
        data/README.md
    CHANGED
    
    | @@ -49,7 +49,6 @@ | |
| 49 49 | 
             
            - [JSX](#jsx)
         | 
| 50 50 | 
             
            - [JSON](#json)
         | 
| 51 51 | 
             
            - [Phlex Support](#phlex-support)
         | 
| 52 | 
            -
            - [ViewComponent Support](#viewcomponent-support)
         | 
| 53 52 | 
             
            - [Cache Busting](#cache-busting)
         | 
| 54 53 | 
             
            - [rjs is back!](#rjs-is-back)
         | 
| 55 54 | 
             
            - [Resolution](#resolution)
         | 
| @@ -769,49 +768,6 @@ end | |
| 769 768 | 
             
            <h1 class="user_name-ABCD1234 title">Joel Moss</h1>
         | 
| 770 769 | 
             
            ```
         | 
| 771 770 |  | 
| 772 | 
            -
            ## ViewComponent Support
         | 
| 773 | 
            -
             | 
| 774 | 
            -
            [ViewComponent](https://viewcomponent.org/) iA framework for creating reusable, testable & encapsulated view components, built to integrate seamlessly with Ruby on Rails. Proscenium works perfectly with ViewComponent, with support for side-loading, CSS modules, and more. Simply write your ViewComponent classes and inherit from `Proscenium::ViewComponent`.
         | 
| 775 | 
            -
             | 
| 776 | 
            -
            ```ruby
         | 
| 777 | 
            -
            class MyView < Proscenium::ViewComponent
         | 
| 778 | 
            -
              def call
         | 
| 779 | 
            -
                tag.h1 'Hello World'
         | 
| 780 | 
            -
              end
         | 
| 781 | 
            -
            end
         | 
| 782 | 
            -
            ```
         | 
| 783 | 
            -
             | 
| 784 | 
            -
            ### Side-loading
         | 
| 785 | 
            -
             | 
| 786 | 
            -
            Any ViewComponent class that inherits `Proscenium::ViewComponent` will automatically be [side-loaded](#side-loading).
         | 
| 787 | 
            -
             | 
| 788 | 
            -
            ### CSS Modules
         | 
| 789 | 
            -
             | 
| 790 | 
            -
            [CSS Modules](#css-modules) are fully supported in ViewComponent classes, with access to the [`css_module` helper](#in-your-views) if you need it.
         | 
| 791 | 
            -
             | 
| 792 | 
            -
            ```ruby
         | 
| 793 | 
            -
            # /app/components/user_component.rb
         | 
| 794 | 
            -
            class UserComponent < Proscenium::ViewComponent
         | 
| 795 | 
            -
              def view_template
         | 
| 796 | 
            -
                div.h1 @user.name, class: css_module(:user_name)
         | 
| 797 | 
            -
              end
         | 
| 798 | 
            -
            end
         | 
| 799 | 
            -
            ```
         | 
| 800 | 
            -
             | 
| 801 | 
            -
            ```css
         | 
| 802 | 
            -
            /* # /app/components/user_component.module.css */
         | 
| 803 | 
            -
            .userName {
         | 
| 804 | 
            -
              color: red;
         | 
| 805 | 
            -
              font-size: 50px;
         | 
| 806 | 
            -
            }
         | 
| 807 | 
            -
            ```
         | 
| 808 | 
            -
             | 
| 809 | 
            -
            The view above will be rendered something like this:
         | 
| 810 | 
            -
             | 
| 811 | 
            -
            ```html
         | 
| 812 | 
            -
            <h1 class="user_name-ABCD1234">Joel Moss</h1>
         | 
| 813 | 
            -
            ```
         | 
| 814 | 
            -
             | 
| 815 771 | 
             
            ## Cache Busting
         | 
| 816 772 |  | 
| 817 773 | 
             
            > _COMING SOON_
         | 
| @@ -1,11 +1,6 @@ | |
| 1 1 | 
             
            # frozen_string_literal: true
         | 
| 2 2 |  | 
| 3 3 | 
             
            module Proscenium::CssModule
         | 
| 4 | 
            -
              extend ActiveSupport::Autoload
         | 
| 5 | 
            -
             | 
| 6 | 
            -
              autoload :Path
         | 
| 7 | 
            -
              autoload :Transformer
         | 
| 8 | 
            -
             | 
| 9 4 | 
             
              class TransformError < StandardError
         | 
| 10 5 | 
             
                def initialize(name, additional_msg = nil)
         | 
| 11 6 | 
             
                  msg = "Failed to transform CSS module `#{name}`"
         | 
| Binary file | 
| @@ -2,15 +2,9 @@ | |
| 2 2 |  | 
| 3 3 | 
             
            module Proscenium
         | 
| 4 4 | 
             
              class Middleware
         | 
| 5 | 
            -
                extend ActiveSupport::Autoload
         | 
| 6 | 
            -
             | 
| 7 5 | 
             
                # Error when the build command fails.
         | 
| 8 6 | 
             
                class BuildError < StandardError; end
         | 
| 9 7 |  | 
| 10 | 
            -
                autoload :Base
         | 
| 11 | 
            -
                autoload :Esbuild
         | 
| 12 | 
            -
                autoload :RubyGems
         | 
| 13 | 
            -
             | 
| 14 8 | 
             
                def initialize(app)
         | 
| 15 9 | 
             
                  @app = app
         | 
| 16 10 |  | 
    
        data/lib/proscenium/monkey.rb
    CHANGED
    
    | @@ -9,15 +9,8 @@ module Proscenium | |
| 9 9 | 
             
                    result = super
         | 
| 10 10 | 
             
                    return result if !view.controller || !Proscenium.config.side_load
         | 
| 11 11 |  | 
| 12 | 
            -
                     | 
| 13 | 
            -
             | 
| 14 | 
            -
                    to_sideload = if Object.const_defined?(:ViewComponent) &&
         | 
| 15 | 
            -
                                     template.is_a?(ActionView::Template::Renderable) &&
         | 
| 16 | 
            -
                                     renderable.class < ::ViewComponent::Base &&
         | 
| 17 | 
            -
                                     renderable.class.format == :html
         | 
| 18 | 
            -
                                    renderable
         | 
| 19 | 
            -
                                  elsif template.respond_to?(:virtual_path) &&
         | 
| 20 | 
            -
                                        template.respond_to?(:type) && template.type == :html
         | 
| 12 | 
            +
                    to_sideload = if template.respond_to?(:virtual_path) &&
         | 
| 13 | 
            +
                                     template.respond_to?(:type) && template.type == :html
         | 
| 21 14 | 
             
                                    template
         | 
| 22 15 | 
             
                                  end
         | 
| 23 16 | 
             
                    if to_sideload
         | 
    
        data/lib/proscenium/phlex.rb
    CHANGED
    
    | @@ -4,12 +4,6 @@ require 'phlex-rails' | |
| 4 4 |  | 
| 5 5 | 
             
            module Proscenium
         | 
| 6 6 | 
             
              class Phlex < ::Phlex::HTML
         | 
| 7 | 
            -
                extend ActiveSupport::Autoload
         | 
| 8 | 
            -
             | 
| 9 | 
            -
                autoload :CssModules
         | 
| 10 | 
            -
                autoload :ReactComponent
         | 
| 11 | 
            -
                autoload :AssetInclusions
         | 
| 12 | 
            -
             | 
| 13 7 | 
             
                include Proscenium::SourcePath
         | 
| 14 8 | 
             
                include CssModules
         | 
| 15 9 | 
             
                include AssetInclusions
         | 
    
        data/lib/proscenium/railtie.rb
    CHANGED
    
    | @@ -14,9 +14,7 @@ module Proscenium | |
| 14 14 | 
             
                config.proscenium.bundle = true
         | 
| 15 15 | 
             
                config.proscenium.side_load = true
         | 
| 16 16 | 
             
                config.proscenium.code_splitting = true
         | 
| 17 | 
            -
             | 
| 18 17 | 
             
                config.proscenium.ensure_loaded = :raise
         | 
| 19 | 
            -
             | 
| 20 18 | 
             
                config.proscenium.cache_query_string = Rails.env.production? && ENV.fetch('REVISION', nil)
         | 
| 21 19 | 
             
                config.proscenium.cache_max_age = 2_592_000 # 30 days
         | 
| 22 20 |  | 
| @@ -35,19 +33,6 @@ module Proscenium | |
| 35 33 | 
             
                  end
         | 
| 36 34 | 
             
                end
         | 
| 37 35 |  | 
| 38 | 
            -
                initializer 'proscenium.ui' do
         | 
| 39 | 
            -
                  ActiveSupport::Inflector.inflections(:en) do |inflect|
         | 
| 40 | 
            -
                    inflect.acronym 'UI'
         | 
| 41 | 
            -
                  end
         | 
| 42 | 
            -
                end
         | 
| 43 | 
            -
             | 
| 44 | 
            -
                initializer 'proscenium.debugging' do
         | 
| 45 | 
            -
                  if Rails.gem_version >= Gem::Version.new('7.1.0')
         | 
| 46 | 
            -
                    tpl_path = root.join('lib', 'proscenium', 'templates').to_s
         | 
| 47 | 
            -
                    ActionDispatch::DebugView::RESCUES_TEMPLATE_PATHS << tpl_path
         | 
| 48 | 
            -
                  end
         | 
| 49 | 
            -
                end
         | 
| 50 | 
            -
             | 
| 51 36 | 
             
                initializer 'proscenium.middleware' do |app|
         | 
| 52 37 | 
             
                  app.middleware.insert_after ActionDispatch::Static, Proscenium::Middleware
         | 
| 53 38 | 
             
                end
         | 
| @@ -65,15 +50,5 @@ module Proscenium | |
| 65 50 | 
             
                    ActionView::PartialRenderer.prepend Monkey::PartialRenderer
         | 
| 66 51 | 
             
                  end
         | 
| 67 52 | 
             
                end
         | 
| 68 | 
            -
             | 
| 69 | 
            -
                initializer 'proscenium.public_path' do |app|
         | 
| 70 | 
            -
                  if app.config.public_file_server.enabled
         | 
| 71 | 
            -
                    headers = app.config.public_file_server.headers || {}
         | 
| 72 | 
            -
                    index = app.config.public_file_server.index_name || 'index'
         | 
| 73 | 
            -
             | 
| 74 | 
            -
                    app.middleware.insert_after(ActionDispatch::Static, ActionDispatch::Static,
         | 
| 75 | 
            -
                                                root.join('public').to_s, index:, headers:)
         | 
| 76 | 
            -
                  end
         | 
| 77 | 
            -
                end
         | 
| 78 53 | 
             
              end
         | 
| 79 54 | 
             
            end
         | 
| @@ -11,7 +11,7 @@ module Proscenium | |
| 11 11 | 
             
                  # The HTML tag to use as the wrapping element for the component. You can reassign this in your
         | 
| 12 12 | 
             
                  # component class to use a different tag:
         | 
| 13 13 | 
             
                  #
         | 
| 14 | 
            -
                  #   class MyComponent < Proscenium:: | 
| 14 | 
            +
                  #   class MyComponent < Proscenium::Phlex::ReactComponent
         | 
| 15 15 | 
             
                  #     self.root_tag = :span
         | 
| 16 16 | 
             
                  #   end
         | 
| 17 17 | 
             
                  #
         | 
    
        data/lib/proscenium/resolver.rb
    CHANGED
    
    | @@ -19,16 +19,7 @@ module Proscenium | |
| 19 19 | 
             
                  end
         | 
| 20 20 |  | 
| 21 21 | 
             
                  self.resolved[path] ||= if (gem = BundledGems.paths.find { |_, v| path.start_with? "#{v}/" })
         | 
| 22 | 
            -
                                            # If the path is a rubygem, and it is installed with npm via the
         | 
| 23 | 
            -
                                            # @rubygems scope, then resolve the path to the symlinked location
         | 
| 24 | 
            -
                                            # in node_modules.
         | 
| 25 | 
            -
                                            # npm_path = Rails.root.join("node_modules/@rubygems/#{gem.first}")
         | 
| 26 | 
            -
                                            # if npm_path.symlink?
         | 
| 27 | 
            -
                                            #   npm_path.realpath.join(path.sub(/^#{gem.last}/, '.')).to_s
         | 
| 28 | 
            -
                                            #           .delete_prefix(Rails.root.to_s)
         | 
| 29 | 
            -
                                            # else
         | 
| 30 22 | 
             
                                            path.sub(/^#{gem.last}/, "/node_modules/@rubygems/#{gem.first}")
         | 
| 31 | 
            -
                                            # end
         | 
| 32 23 | 
             
                                          elsif path.start_with?("#{Rails.root}/")
         | 
| 33 24 | 
             
                                            path.delete_prefix Rails.root.to_s
         | 
| 34 25 | 
             
                                          else
         | 
    
        data/lib/proscenium/version.rb
    CHANGED
    
    
    
        data/lib/proscenium.rb
    CHANGED
    
    | @@ -1,12 +1,13 @@ | |
| 1 1 | 
             
            # frozen_string_literal: true
         | 
| 2 2 |  | 
| 3 | 
            -
            require ' | 
| 4 | 
            -
            require ' | 
| 5 | 
            -
            require 'literal'
         | 
| 3 | 
            +
            require 'zeitwerk'
         | 
| 4 | 
            +
            require 'proscenium/railtie'
         | 
| 6 5 |  | 
| 7 | 
            -
             | 
| 8 | 
            -
             | 
| 6 | 
            +
            loader = Zeitwerk::Loader.for_gem
         | 
| 7 | 
            +
            loader.ignore "#{__dir__}/proscenium/core_ext/object/css_module_ivars.rb"
         | 
| 8 | 
            +
            loader.setup
         | 
| 9 9 |  | 
| 10 | 
            +
            module Proscenium
         | 
| 10 11 | 
             
              FILE_EXTENSIONS = ['js', 'mjs', 'ts', 'jsx', 'tsx', 'css', 'js.map', 'mjs.map', 'jsx.map',
         | 
| 11 12 | 
             
                                 'ts.map', 'tsx.map', 'css.map'].freeze
         | 
| 12 13 |  | 
| @@ -22,25 +23,6 @@ module Proscenium | |
| 22 23 | 
             
              # Environment variables that should always be passed to the builder.
         | 
| 23 24 | 
             
              DEFAULT_ENV_VARS = Set['RAILS_ENV', 'NODE_ENV'].freeze
         | 
| 24 25 |  | 
| 25 | 
            -
              autoload :SourcePath
         | 
| 26 | 
            -
              autoload :Utils
         | 
| 27 | 
            -
              autoload :Monkey
         | 
| 28 | 
            -
              autoload :Middleware
         | 
| 29 | 
            -
              autoload :EnsureLoaded
         | 
| 30 | 
            -
              autoload :SideLoad
         | 
| 31 | 
            -
              autoload :CssModule
         | 
| 32 | 
            -
              autoload :ReactComponentable
         | 
| 33 | 
            -
              autoload :ViewComponent
         | 
| 34 | 
            -
              autoload :Phlex
         | 
| 35 | 
            -
              autoload :Helper
         | 
| 36 | 
            -
              autoload :Builder
         | 
| 37 | 
            -
              autoload :Importer
         | 
| 38 | 
            -
              autoload :Resolver
         | 
| 39 | 
            -
              autoload :BundledGems
         | 
| 40 | 
            -
              autoload :RubyGems
         | 
| 41 | 
            -
              autoload :Registry
         | 
| 42 | 
            -
              autoload :UI
         | 
| 43 | 
            -
             | 
| 44 26 | 
             
              class Deprecator
         | 
| 45 27 | 
             
                def deprecation_warning(name, message, _caller_backtrace = nil)
         | 
| 46 28 | 
             
                  msg = "`#{name}` is deprecated and will be removed in a near future release of Proscenium"
         | 
| @@ -65,18 +47,8 @@ module Proscenium | |
| 65 47 | 
             
                  @config ||= Railtie.config.proscenium
         | 
| 66 48 | 
             
                end
         | 
| 67 49 |  | 
| 68 | 
            -
                def ui_path
         | 
| 69 | 
            -
                  @ui_path ||= Railtie.root.join('lib', 'proscenium', 'ui')
         | 
| 70 | 
            -
                end
         | 
| 71 | 
            -
             | 
| 72 | 
            -
                def ui_path_regex
         | 
| 73 | 
            -
                  @ui_path_regex ||= Regexp.new("^#{Proscenium.ui_path}/")
         | 
| 74 | 
            -
                end
         | 
| 75 | 
            -
             | 
| 76 50 | 
             
                def root
         | 
| 77 51 | 
             
                  Railtie.root
         | 
| 78 52 | 
             
                end
         | 
| 79 53 | 
             
              end
         | 
| 80 54 | 
             
            end
         | 
| 81 | 
            -
             | 
| 82 | 
            -
            require 'proscenium/railtie'
         | 
    
        metadata
    CHANGED
    
    | @@ -1,28 +1,15 @@ | |
| 1 1 | 
             
            --- !ruby/object:Gem::Specification
         | 
| 2 2 | 
             
            name: proscenium
         | 
| 3 3 | 
             
            version: !ruby/object:Gem::Version
         | 
| 4 | 
            -
              version: 0.19.0. | 
| 4 | 
            +
              version: 0.19.0.beta12
         | 
| 5 5 | 
             
            platform: aarch64-linux
         | 
| 6 6 | 
             
            authors:
         | 
| 7 7 | 
             
            - Joel Moss
         | 
| 8 | 
            +
            autorequire:
         | 
| 8 9 | 
             
            bindir: bin
         | 
| 9 10 | 
             
            cert_chain: []
         | 
| 10 | 
            -
            date:  | 
| 11 | 
            +
            date: 2025-04-22 00:00:00.000000000 Z
         | 
| 11 12 | 
             
            dependencies:
         | 
| 12 | 
            -
            - !ruby/object:Gem::Dependency
         | 
| 13 | 
            -
              name: countries
         | 
| 14 | 
            -
              requirement: !ruby/object:Gem::Requirement
         | 
| 15 | 
            -
                requirements:
         | 
| 16 | 
            -
                - - "~>"
         | 
| 17 | 
            -
                  - !ruby/object:Gem::Version
         | 
| 18 | 
            -
                    version: 7.1.0
         | 
| 19 | 
            -
              type: :runtime
         | 
| 20 | 
            -
              prerelease: false
         | 
| 21 | 
            -
              version_requirements: !ruby/object:Gem::Requirement
         | 
| 22 | 
            -
                requirements:
         | 
| 23 | 
            -
                - - "~>"
         | 
| 24 | 
            -
                  - !ruby/object:Gem::Version
         | 
| 25 | 
            -
                    version: 7.1.0
         | 
| 26 13 | 
             
            - !ruby/object:Gem::Dependency
         | 
| 27 14 | 
             
              name: ffi
         | 
| 28 15 | 
             
              requirement: !ruby/object:Gem::Requirement
         | 
| @@ -37,34 +24,6 @@ dependencies: | |
| 37 24 | 
             
                - - "~>"
         | 
| 38 25 | 
             
                  - !ruby/object:Gem::Version
         | 
| 39 26 | 
             
                    version: 1.17.0
         | 
| 40 | 
            -
            - !ruby/object:Gem::Dependency
         | 
| 41 | 
            -
              name: gems
         | 
| 42 | 
            -
              requirement: !ruby/object:Gem::Requirement
         | 
| 43 | 
            -
                requirements:
         | 
| 44 | 
            -
                - - "~>"
         | 
| 45 | 
            -
                  - !ruby/object:Gem::Version
         | 
| 46 | 
            -
                    version: 1.3.0
         | 
| 47 | 
            -
              type: :runtime
         | 
| 48 | 
            -
              prerelease: false
         | 
| 49 | 
            -
              version_requirements: !ruby/object:Gem::Requirement
         | 
| 50 | 
            -
                requirements:
         | 
| 51 | 
            -
                - - "~>"
         | 
| 52 | 
            -
                  - !ruby/object:Gem::Version
         | 
| 53 | 
            -
                    version: 1.3.0
         | 
| 54 | 
            -
            - !ruby/object:Gem::Dependency
         | 
| 55 | 
            -
              name: literal
         | 
| 56 | 
            -
              requirement: !ruby/object:Gem::Requirement
         | 
| 57 | 
            -
                requirements:
         | 
| 58 | 
            -
                - - "~>"
         | 
| 59 | 
            -
                  - !ruby/object:Gem::Version
         | 
| 60 | 
            -
                    version: '1.0'
         | 
| 61 | 
            -
              type: :runtime
         | 
| 62 | 
            -
              prerelease: false
         | 
| 63 | 
            -
              version_requirements: !ruby/object:Gem::Requirement
         | 
| 64 | 
            -
                requirements:
         | 
| 65 | 
            -
                - - "~>"
         | 
| 66 | 
            -
                  - !ruby/object:Gem::Version
         | 
| 67 | 
            -
                    version: '1.0'
         | 
| 68 27 | 
             
            - !ruby/object:Gem::Dependency
         | 
| 69 28 | 
             
              name: phlex-rails
         | 
| 70 29 | 
             
              requirement: !ruby/object:Gem::Requirement
         | 
| @@ -79,20 +38,6 @@ dependencies: | |
| 79 38 | 
             
                - - "~>"
         | 
| 80 39 | 
             
                  - !ruby/object:Gem::Version
         | 
| 81 40 | 
             
                    version: '1.2'
         | 
| 82 | 
            -
            - !ruby/object:Gem::Dependency
         | 
| 83 | 
            -
              name: phonelib
         | 
| 84 | 
            -
              requirement: !ruby/object:Gem::Requirement
         | 
| 85 | 
            -
                requirements:
         | 
| 86 | 
            -
                - - "~>"
         | 
| 87 | 
            -
                  - !ruby/object:Gem::Version
         | 
| 88 | 
            -
                    version: 0.10.3
         | 
| 89 | 
            -
              type: :runtime
         | 
| 90 | 
            -
              prerelease: false
         | 
| 91 | 
            -
              version_requirements: !ruby/object:Gem::Requirement
         | 
| 92 | 
            -
                requirements:
         | 
| 93 | 
            -
                - - "~>"
         | 
| 94 | 
            -
                  - !ruby/object:Gem::Version
         | 
| 95 | 
            -
                    version: 0.10.3
         | 
| 96 41 | 
             
            - !ruby/object:Gem::Dependency
         | 
| 97 42 | 
             
              name: rails
         | 
| 98 43 | 
             
              requirement: !ruby/object:Gem::Requirement
         | 
| @@ -127,6 +72,21 @@ dependencies: | |
| 127 72 | 
             
                - - "~>"
         | 
| 128 73 | 
             
                  - !ruby/object:Gem::Version
         | 
| 129 74 | 
             
                    version: 1.1.1
         | 
| 75 | 
            +
            - !ruby/object:Gem::Dependency
         | 
| 76 | 
            +
              name: zeitwerk
         | 
| 77 | 
            +
              requirement: !ruby/object:Gem::Requirement
         | 
| 78 | 
            +
                requirements:
         | 
| 79 | 
            +
                - - "~>"
         | 
| 80 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 81 | 
            +
                    version: 2.7.2
         | 
| 82 | 
            +
              type: :runtime
         | 
| 83 | 
            +
              prerelease: false
         | 
| 84 | 
            +
              version_requirements: !ruby/object:Gem::Requirement
         | 
| 85 | 
            +
                requirements:
         | 
| 86 | 
            +
                - - "~>"
         | 
| 87 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 88 | 
            +
                    version: 2.7.2
         | 
| 89 | 
            +
            description:
         | 
| 130 90 | 
             
            email:
         | 
| 131 91 | 
             
            - joel@developwithstyle.com
         | 
| 132 92 | 
             
            executables: []
         | 
| @@ -160,89 +120,15 @@ files: | |
| 160 120 | 
             
            - lib/proscenium/phlex/css_modules.rb
         | 
| 161 121 | 
             
            - lib/proscenium/phlex/react_component.rb
         | 
| 162 122 | 
             
            - lib/proscenium/railtie.rb
         | 
| 123 | 
            +
            - lib/proscenium/react-manager/index.jsx
         | 
| 124 | 
            +
            - lib/proscenium/react-manager/react.js
         | 
| 163 125 | 
             
            - lib/proscenium/react_componentable.rb
         | 
| 164 | 
            -
            - lib/proscenium/registry.rb
         | 
| 165 | 
            -
            - lib/proscenium/registry/bundled_package.rb
         | 
| 166 | 
            -
            - lib/proscenium/registry/package.rb
         | 
| 167 | 
            -
            - lib/proscenium/registry/ruby_gem_package.rb
         | 
| 168 126 | 
             
            - lib/proscenium/resolver.rb
         | 
| 169 | 
            -
            - lib/proscenium/ruby_gems.rb
         | 
| 170 127 | 
             
            - lib/proscenium/side_load.rb
         | 
| 171 128 | 
             
            - lib/proscenium/source_path.rb
         | 
| 172 129 | 
             
            - lib/proscenium/templates/rescues/build_error.html.erb
         | 
| 173 | 
            -
            - lib/proscenium/ui.rb
         | 
| 174 | 
            -
            - lib/proscenium/ui/breadcrumbs.rb
         | 
| 175 | 
            -
            - lib/proscenium/ui/breadcrumbs/component.module.css
         | 
| 176 | 
            -
            - lib/proscenium/ui/breadcrumbs/component.rb
         | 
| 177 | 
            -
            - lib/proscenium/ui/breadcrumbs/computed_element.rb
         | 
| 178 | 
            -
            - lib/proscenium/ui/breadcrumbs/control.rb
         | 
| 179 | 
            -
            - lib/proscenium/ui/breadcrumbs/mixins.css
         | 
| 180 | 
            -
            - lib/proscenium/ui/component.rb
         | 
| 181 | 
            -
            - lib/proscenium/ui/custom_element.js
         | 
| 182 | 
            -
            - lib/proscenium/ui/flash.rb
         | 
| 183 | 
            -
            - lib/proscenium/ui/flash/bun.lock
         | 
| 184 | 
            -
            - lib/proscenium/ui/flash/index.css
         | 
| 185 | 
            -
            - lib/proscenium/ui/flash/index.js
         | 
| 186 | 
            -
            - lib/proscenium/ui/flash/node_modules/dom-mutations/index.d.ts
         | 
| 187 | 
            -
            - lib/proscenium/ui/flash/node_modules/dom-mutations/index.js
         | 
| 188 | 
            -
            - lib/proscenium/ui/flash/node_modules/dom-mutations/license
         | 
| 189 | 
            -
            - lib/proscenium/ui/flash/node_modules/dom-mutations/package.json
         | 
| 190 | 
            -
            - lib/proscenium/ui/flash/node_modules/dom-mutations/readme.md
         | 
| 191 | 
            -
            - lib/proscenium/ui/flash/node_modules/sourdough-toast/LICENSE
         | 
| 192 | 
            -
            - lib/proscenium/ui/flash/node_modules/sourdough-toast/README.md
         | 
| 193 | 
            -
            - lib/proscenium/ui/flash/node_modules/sourdough-toast/package.json
         | 
| 194 | 
            -
            - lib/proscenium/ui/flash/node_modules/sourdough-toast/src/sourdough-toast.css
         | 
| 195 | 
            -
            - lib/proscenium/ui/flash/node_modules/sourdough-toast/src/sourdough-toast.js
         | 
| 196 | 
            -
            - lib/proscenium/ui/flash/package.json
         | 
| 197 | 
            -
            - lib/proscenium/ui/form.css
         | 
| 198 | 
            -
            - lib/proscenium/ui/form.rb
         | 
| 199 | 
            -
            - lib/proscenium/ui/form/field_methods.rb
         | 
| 200 | 
            -
            - lib/proscenium/ui/form/fields/base.rb
         | 
| 201 | 
            -
            - lib/proscenium/ui/form/fields/checkbox.rb
         | 
| 202 | 
            -
            - lib/proscenium/ui/form/fields/checkbox/index.jsx
         | 
| 203 | 
            -
            - lib/proscenium/ui/form/fields/checkbox/index.module.css
         | 
| 204 | 
            -
            - lib/proscenium/ui/form/fields/checkbox/previews/basic.jsx
         | 
| 205 | 
            -
            - lib/proscenium/ui/form/fields/date.module.css
         | 
| 206 | 
            -
            - lib/proscenium/ui/form/fields/datetime.rb
         | 
| 207 | 
            -
            - lib/proscenium/ui/form/fields/hidden.rb
         | 
| 208 | 
            -
            - lib/proscenium/ui/form/fields/input.rb
         | 
| 209 | 
            -
            - lib/proscenium/ui/form/fields/input/index.jsx
         | 
| 210 | 
            -
            - lib/proscenium/ui/form/fields/input/index.module.css
         | 
| 211 | 
            -
            - lib/proscenium/ui/form/fields/input/previews/basic.jsx
         | 
| 212 | 
            -
            - lib/proscenium/ui/form/fields/radio_group.rb
         | 
| 213 | 
            -
            - lib/proscenium/ui/form/fields/radio_input.rb
         | 
| 214 | 
            -
            - lib/proscenium/ui/form/fields/radio_input/index.jsx
         | 
| 215 | 
            -
            - lib/proscenium/ui/form/fields/radio_input/index.module.css
         | 
| 216 | 
            -
            - lib/proscenium/ui/form/fields/radio_input/previews/basic.jsx
         | 
| 217 | 
            -
            - lib/proscenium/ui/form/fields/rich_textarea.css
         | 
| 218 | 
            -
            - lib/proscenium/ui/form/fields/rich_textarea.js
         | 
| 219 | 
            -
            - lib/proscenium/ui/form/fields/rich_textarea.rb
         | 
| 220 | 
            -
            - lib/proscenium/ui/form/fields/select.jsx
         | 
| 221 | 
            -
            - lib/proscenium/ui/form/fields/select.module.css
         | 
| 222 | 
            -
            - lib/proscenium/ui/form/fields/select.rb
         | 
| 223 | 
            -
            - lib/proscenium/ui/form/fields/tel.css
         | 
| 224 | 
            -
            - lib/proscenium/ui/form/fields/tel.js
         | 
| 225 | 
            -
            - lib/proscenium/ui/form/fields/tel.rb
         | 
| 226 | 
            -
            - lib/proscenium/ui/form/fields/textarea.rb
         | 
| 227 | 
            -
            - lib/proscenium/ui/form/fields/textarea/index.jsx
         | 
| 228 | 
            -
            - lib/proscenium/ui/form/fields/textarea/index.module.css
         | 
| 229 | 
            -
            - lib/proscenium/ui/form/fields/textarea/previews/basic.jsx
         | 
| 230 | 
            -
            - lib/proscenium/ui/form/translation.rb
         | 
| 231 | 
            -
            - lib/proscenium/ui/props.css
         | 
| 232 | 
            -
            - lib/proscenium/ui/react-manager/index.jsx
         | 
| 233 | 
            -
            - lib/proscenium/ui/react-manager/react.js
         | 
| 234 | 
            -
            - lib/proscenium/ui/stimulus-loading.js
         | 
| 235 | 
            -
            - lib/proscenium/ui/test.js
         | 
| 236 | 
            -
            - lib/proscenium/ui/ujs/class.js
         | 
| 237 | 
            -
            - lib/proscenium/ui/ujs/data_confirm.js
         | 
| 238 | 
            -
            - lib/proscenium/ui/ujs/data_disable_with.js
         | 
| 239 | 
            -
            - lib/proscenium/ui/ujs/index.js
         | 
| 240 130 | 
             
            - lib/proscenium/utils.rb
         | 
| 241 131 | 
             
            - lib/proscenium/version.rb
         | 
| 242 | 
            -
            - lib/proscenium/view_component.rb
         | 
| 243 | 
            -
            - lib/proscenium/view_component/css_modules.rb
         | 
| 244 | 
            -
            - lib/proscenium/view_component/react_component.rb
         | 
| 245 | 
            -
            - lib/proscenium/view_component/sideload.rb
         | 
| 246 132 | 
             
            homepage: https://github.com/joelmoss/proscenium
         | 
| 247 133 | 
             
            licenses:
         | 
| 248 134 | 
             
            - MIT
         | 
| @@ -251,6 +137,7 @@ metadata: | |
| 251 137 | 
             
              source_code_uri: https://github.com/joelmoss/proscenium
         | 
| 252 138 | 
             
              changelog_uri: https://github.com/joelmoss/proscenium/releases
         | 
| 253 139 | 
             
              rubygems_mfa_required: 'true'
         | 
| 140 | 
            +
            post_install_message:
         | 
| 254 141 | 
             
            rdoc_options: []
         | 
| 255 142 | 
             
            require_paths:
         | 
| 256 143 | 
             
            - lib
         | 
| @@ -258,14 +145,15 @@ required_ruby_version: !ruby/object:Gem::Requirement | |
| 258 145 | 
             
              requirements:
         | 
| 259 146 | 
             
              - - ">="
         | 
| 260 147 | 
             
                - !ruby/object:Gem::Version
         | 
| 261 | 
            -
                  version: 3. | 
| 148 | 
            +
                  version: 3.3.0
         | 
| 262 149 | 
             
            required_rubygems_version: !ruby/object:Gem::Requirement
         | 
| 263 150 | 
             
              requirements:
         | 
| 264 151 | 
             
              - - ">="
         | 
| 265 152 | 
             
                - !ruby/object:Gem::Version
         | 
| 266 153 | 
             
                  version: '0'
         | 
| 267 154 | 
             
            requirements: []
         | 
| 268 | 
            -
            rubygems_version: 3. | 
| 155 | 
            +
            rubygems_version: 3.5.22
         | 
| 156 | 
            +
            signing_key:
         | 
| 269 157 | 
             
            specification_version: 4
         | 
| 270 158 | 
             
            summary: The engine powering your Rails frontend
         | 
| 271 159 | 
             
            test_files: []
         | 
| @@ -1,29 +0,0 @@ | |
| 1 | 
            -
            # frozen_string_literal: true
         | 
| 2 | 
            -
             | 
| 3 | 
            -
            require 'rubygems/package'
         | 
| 4 | 
            -
             | 
| 5 | 
            -
            class Proscenium::Registry
         | 
| 6 | 
            -
              class BundledPackage < Package
         | 
| 7 | 
            -
                def version = @version ||= spec.version.to_s
         | 
| 8 | 
            -
             | 
| 9 | 
            -
                private
         | 
| 10 | 
            -
             | 
| 11 | 
            -
                def package_json
         | 
| 12 | 
            -
                  @package_json ||= begin
         | 
| 13 | 
            -
                    unless (gem_path = Proscenium::BundledGems.pathname_for(gem_name))
         | 
| 14 | 
            -
                      raise PackageNotInstalledError, name
         | 
| 15 | 
            -
                    end
         | 
| 16 | 
            -
             | 
| 17 | 
            -
                    if (package_path = gem_path.join('package.json')).exist?
         | 
| 18 | 
            -
                      JSON.parse(package_path.read)
         | 
| 19 | 
            -
                    else
         | 
| 20 | 
            -
                      default_package_json
         | 
| 21 | 
            -
                    end
         | 
| 22 | 
            -
                  end
         | 
| 23 | 
            -
                end
         | 
| 24 | 
            -
             | 
| 25 | 
            -
                def spec
         | 
| 26 | 
            -
                  @spec ||= Bundler.load.specs[gem_name].first
         | 
| 27 | 
            -
                end
         | 
| 28 | 
            -
              end
         | 
| 29 | 
            -
            end
         | 
| @@ -1,95 +0,0 @@ | |
| 1 | 
            -
            # frozen_string_literal: true
         | 
| 2 | 
            -
             | 
| 3 | 
            -
            class Proscenium::Registry
         | 
| 4 | 
            -
              # 1. Fetch the gem metadata from RubyGems API.
         | 
| 5 | 
            -
              # 2. Extract any package.json from the gem, and populate the response with it.
         | 
| 6 | 
            -
              # 3. Create a tarball containing the fetched package.json. This will be downloaded by the npm
         | 
| 7 | 
            -
              #    client, and unpacked into node_modules. Proscenium ignores this, as it will pull contents
         | 
| 8 | 
            -
              #    directly from location of the installed gem.
         | 
| 9 | 
            -
              # 4. Return a valid npm response listing package details, tarball location, and its dependencies.
         | 
| 10 | 
            -
              #
         | 
| 11 | 
            -
              # See https://wiki.commonjs.org/wiki/Packages/Registry
         | 
| 12 | 
            -
              class Package
         | 
| 13 | 
            -
                extend Literal::Properties
         | 
| 14 | 
            -
             | 
| 15 | 
            -
                prop :name, String, :positional, reader: :private
         | 
| 16 | 
            -
                prop :version, _String?
         | 
| 17 | 
            -
                prop :host, String
         | 
| 18 | 
            -
             | 
| 19 | 
            -
                def as_json
         | 
| 20 | 
            -
                  {
         | 
| 21 | 
            -
                    name:,
         | 
| 22 | 
            -
                    'dist-tags': {
         | 
| 23 | 
            -
                      latest: version
         | 
| 24 | 
            -
                    },
         | 
| 25 | 
            -
                    versions: {
         | 
| 26 | 
            -
                      version => {
         | 
| 27 | 
            -
                        name:,
         | 
| 28 | 
            -
                        version:,
         | 
| 29 | 
            -
                        dependencies: package_json['dependencies'] || {},
         | 
| 30 | 
            -
                        dist: {
         | 
| 31 | 
            -
                          tarball:,
         | 
| 32 | 
            -
                          integrity:,
         | 
| 33 | 
            -
                          shasum:
         | 
| 34 | 
            -
                        }
         | 
| 35 | 
            -
                      }
         | 
| 36 | 
            -
                    }
         | 
| 37 | 
            -
                  }
         | 
| 38 | 
            -
                end
         | 
| 39 | 
            -
             | 
| 40 | 
            -
                def validate!
         | 
| 41 | 
            -
                  return self if name.start_with?('@rubygems/')
         | 
| 42 | 
            -
             | 
| 43 | 
            -
                  raise PackageUnsupportedError, name
         | 
| 44 | 
            -
                end
         | 
| 45 | 
            -
             | 
| 46 | 
            -
                def gem_name = @gem_name ||= name.gsub('@rubygems/', '')
         | 
| 47 | 
            -
                def version = @version # rubocop:disable Style/TrivialAccessors
         | 
| 48 | 
            -
                def shasum = Digest::SHA1.file(tarball_path).hexdigest
         | 
| 49 | 
            -
                def integrity = "sha512-#{Digest::SHA512.file(tarball_path).base64digest}"
         | 
| 50 | 
            -
             | 
| 51 | 
            -
                private
         | 
| 52 | 
            -
             | 
| 53 | 
            -
                def tarball
         | 
| 54 | 
            -
                  create_tarball unless tarball_path.exist?
         | 
| 55 | 
            -
             | 
| 56 | 
            -
                  "#{@host}/#{tarball_path.relative_path_from(Rails.public_path)}"
         | 
| 57 | 
            -
                end
         | 
| 58 | 
            -
             | 
| 59 | 
            -
                def tarball_name
         | 
| 60 | 
            -
                  @tarball_name ||= "#{gem_name}-#{version}"
         | 
| 61 | 
            -
                end
         | 
| 62 | 
            -
             | 
| 63 | 
            -
                def tarball_path
         | 
| 64 | 
            -
                  @tarball_path ||= Rails.public_path.join('proscenium_registry_tarballs')
         | 
| 65 | 
            -
                                         .join("@rubygems/#{gem_name}/#{tarball_name}.tgz")
         | 
| 66 | 
            -
                end
         | 
| 67 | 
            -
             | 
| 68 | 
            -
                def create_tarball
         | 
| 69 | 
            -
                  FileUtils.mkdir_p(File.dirname(tarball_path))
         | 
| 70 | 
            -
             | 
| 71 | 
            -
                  File.open(tarball_path, 'wb') do |file|
         | 
| 72 | 
            -
                    Zlib::GzipWriter.wrap(file) do |gz|
         | 
| 73 | 
            -
                      Gem::Package::TarWriter.new(gz) do |tar|
         | 
| 74 | 
            -
                        contents = package_json.to_json
         | 
| 75 | 
            -
                        tar.add_file_simple('package/package.json', 0o444, contents.length) do |io|
         | 
| 76 | 
            -
                          io.write contents
         | 
| 77 | 
            -
                        end
         | 
| 78 | 
            -
                      end
         | 
| 79 | 
            -
                    end
         | 
| 80 | 
            -
                  end
         | 
| 81 | 
            -
                end
         | 
| 82 | 
            -
             | 
| 83 | 
            -
                def package_json
         | 
| 84 | 
            -
                  @package_json ||= default_package_json
         | 
| 85 | 
            -
                end
         | 
| 86 | 
            -
             | 
| 87 | 
            -
                def default_package_json
         | 
| 88 | 
            -
                  {
         | 
| 89 | 
            -
                    name:,
         | 
| 90 | 
            -
                    version:,
         | 
| 91 | 
            -
                    dependencies: {}
         | 
| 92 | 
            -
                  }
         | 
| 93 | 
            -
                end
         | 
| 94 | 
            -
              end
         | 
| 95 | 
            -
            end
         | 
| @@ -1,30 +0,0 @@ | |
| 1 | 
            -
            # frozen_string_literal: true
         | 
| 2 | 
            -
             | 
| 3 | 
            -
            require 'gems'
         | 
| 4 | 
            -
             | 
| 5 | 
            -
            class Proscenium::Registry
         | 
| 6 | 
            -
              class RubyGemPackage < Package
         | 
| 7 | 
            -
                def version = spec['version']
         | 
| 8 | 
            -
             | 
| 9 | 
            -
                private
         | 
| 10 | 
            -
             | 
| 11 | 
            -
                def package_json
         | 
| 12 | 
            -
                  @package_json ||= begin
         | 
| 13 | 
            -
                    package_path = Proscenium::RubyGems.path_for(gem_name, version).join('package.json')
         | 
| 14 | 
            -
                    if package_path.exist?
         | 
| 15 | 
            -
                      JSON.parse path.read
         | 
| 16 | 
            -
                    else
         | 
| 17 | 
            -
                      default_package_json
         | 
| 18 | 
            -
                    end
         | 
| 19 | 
            -
                  end
         | 
| 20 | 
            -
                end
         | 
| 21 | 
            -
             | 
| 22 | 
            -
                def spec
         | 
| 23 | 
            -
                  @spec ||= if @version.present?
         | 
| 24 | 
            -
                              Gems::V2.info gem_name, @version
         | 
| 25 | 
            -
                            else
         | 
| 26 | 
            -
                              Gems.info(gem_name)
         | 
| 27 | 
            -
                            end
         | 
| 28 | 
            -
                end
         | 
| 29 | 
            -
              end
         | 
| 30 | 
            -
            end
         |