Skip to content

Commit

Permalink
Merge branch 'main' into dependabot/github_actions/errata-ai/vale-act…
Browse files Browse the repository at this point in the history
…ion-2.1.1
  • Loading branch information
joelhawksley authored Oct 29, 2024
2 parents 185810b + d80b121 commit cb2bda5
Show file tree
Hide file tree
Showing 15 changed files with 101 additions and 92 deletions.
130 changes: 64 additions & 66 deletions Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,75 +1,75 @@
PATH
remote: .
specs:
view_component (3.18.0)
activesupport (>= 5.2.0, < 8.0)
view_component (3.19.0)
activesupport (>= 5.2.0, < 8.1)
concurrent-ruby (~> 1.0)
method_source (~> 1.0)

GEM
remote: https://rubygems.org/
specs:
actioncable (7.0.8.5)
actionpack (= 7.0.8.5)
activesupport (= 7.0.8.5)
actioncable (7.0.8.6)
actionpack (= 7.0.8.6)
activesupport (= 7.0.8.6)
nio4r (~> 2.0)
websocket-driver (>= 0.6.1)
actionmailbox (7.0.8.5)
actionpack (= 7.0.8.5)
activejob (= 7.0.8.5)
activerecord (= 7.0.8.5)
activestorage (= 7.0.8.5)
activesupport (= 7.0.8.5)
actionmailbox (7.0.8.6)
actionpack (= 7.0.8.6)
activejob (= 7.0.8.6)
activerecord (= 7.0.8.6)
activestorage (= 7.0.8.6)
activesupport (= 7.0.8.6)
mail (>= 2.7.1)
net-imap
net-pop
net-smtp
actionmailer (7.0.8.5)
actionpack (= 7.0.8.5)
actionview (= 7.0.8.5)
activejob (= 7.0.8.5)
activesupport (= 7.0.8.5)
actionmailer (7.0.8.6)
actionpack (= 7.0.8.6)
actionview (= 7.0.8.6)
activejob (= 7.0.8.6)
activesupport (= 7.0.8.6)
mail (~> 2.5, >= 2.5.4)
net-imap
net-pop
net-smtp
rails-dom-testing (~> 2.0)
actionpack (7.0.8.5)
actionview (= 7.0.8.5)
activesupport (= 7.0.8.5)
actionpack (7.0.8.6)
actionview (= 7.0.8.6)
activesupport (= 7.0.8.6)
rack (~> 2.0, >= 2.2.4)
rack-test (>= 0.6.3)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.0, >= 1.2.0)
actiontext (7.0.8.5)
actionpack (= 7.0.8.5)
activerecord (= 7.0.8.5)
activestorage (= 7.0.8.5)
activesupport (= 7.0.8.5)
actiontext (7.0.8.6)
actionpack (= 7.0.8.6)
activerecord (= 7.0.8.6)
activestorage (= 7.0.8.6)
activesupport (= 7.0.8.6)
globalid (>= 0.6.0)
nokogiri (>= 1.8.5)
actionview (7.0.8.5)
activesupport (= 7.0.8.5)
actionview (7.0.8.6)
activesupport (= 7.0.8.6)
builder (~> 3.1)
erubi (~> 1.4)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.1, >= 1.2.0)
activejob (7.0.8.5)
activesupport (= 7.0.8.5)
activejob (7.0.8.6)
activesupport (= 7.0.8.6)
globalid (>= 0.3.6)
activemodel (7.0.8.5)
activesupport (= 7.0.8.5)
activerecord (7.0.8.5)
activemodel (= 7.0.8.5)
activesupport (= 7.0.8.5)
activestorage (7.0.8.5)
actionpack (= 7.0.8.5)
activejob (= 7.0.8.5)
activerecord (= 7.0.8.5)
activesupport (= 7.0.8.5)
activemodel (7.0.8.6)
activesupport (= 7.0.8.6)
activerecord (7.0.8.6)
activemodel (= 7.0.8.6)
activesupport (= 7.0.8.6)
activestorage (7.0.8.6)
actionpack (= 7.0.8.6)
activejob (= 7.0.8.6)
activerecord (= 7.0.8.6)
activesupport (= 7.0.8.6)
marcel (~> 1.0)
mini_mime (>= 1.1.0)
activesupport (7.0.8.5)
activesupport (7.0.8.6)
concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (>= 1.6, < 2)
minitest (>= 5.1)
Expand Down Expand Up @@ -144,10 +144,10 @@ GEM
jbuilder (2.13.0)
actionview (>= 5.0.0)
activesupport (>= 5.0.0)
json (2.7.2)
json (2.7.4)
language_server-protocol (3.17.0.3)
lint_roller (1.1.0)
loofah (2.22.0)
loofah (2.23.1)
crass (~> 1.0.2)
nokogiri (>= 1.12.0)
m (1.6.2)
Expand All @@ -165,7 +165,7 @@ GEM
mini_portile2 (2.8.7)
minitest (5.25.1)
mutex_m (0.2.0)
net-imap (0.4.17)
net-imap (0.5.0)
date
net-protocol
net-pop (0.1.2)
Expand All @@ -174,11 +174,10 @@ GEM
timeout
net-smtp (0.5.0)
net-protocol
nio4r (2.7.3)
nio4r (2.7.4)
nokogiri (1.16.7)
mini_portile2 (~> 2.8.2)
racc (~> 1.4)
ostruct (0.6.0)
parallel (1.26.3)
parser (3.3.5.0)
ast (~> 2.4.1)
Expand All @@ -195,30 +194,30 @@ GEM
rack (2.2.10)
rack-test (2.1.0)
rack (>= 1.3)
rails (7.0.8.5)
actioncable (= 7.0.8.5)
actionmailbox (= 7.0.8.5)
actionmailer (= 7.0.8.5)
actionpack (= 7.0.8.5)
actiontext (= 7.0.8.5)
actionview (= 7.0.8.5)
activejob (= 7.0.8.5)
activemodel (= 7.0.8.5)
activerecord (= 7.0.8.5)
activestorage (= 7.0.8.5)
activesupport (= 7.0.8.5)
rails (7.0.8.6)
actioncable (= 7.0.8.6)
actionmailbox (= 7.0.8.6)
actionmailer (= 7.0.8.6)
actionpack (= 7.0.8.6)
actiontext (= 7.0.8.6)
actionview (= 7.0.8.6)
activejob (= 7.0.8.6)
activemodel (= 7.0.8.6)
activerecord (= 7.0.8.6)
activestorage (= 7.0.8.6)
activesupport (= 7.0.8.6)
bundler (>= 1.15.0)
railties (= 7.0.8.5)
railties (= 7.0.8.6)
rails-dom-testing (2.2.0)
activesupport (>= 5.0.0)
minitest
nokogiri (>= 1.6)
rails-html-sanitizer (1.6.0)
loofah (~> 2.21)
nokogiri (~> 1.14)
railties (7.0.8.5)
actionpack (= 7.0.8.5)
activesupport (= 7.0.8.5)
railties (7.0.8.6)
actionpack (= 7.0.8.6)
activesupport (= 7.0.8.6)
method_source
rake (>= 12.2)
thor (~> 1.0)
Expand All @@ -230,8 +229,8 @@ GEM
regexp_parser (2.9.2)
reline (0.5.10)
io-console (~> 0.5)
rexml (3.3.8)
rspec-core (3.13.1)
rexml (3.3.9)
rspec-core (3.13.2)
rspec-support (~> 3.13.0)
rspec-expectations (3.13.3)
diff-lcs (>= 1.2.0, < 2.0)
Expand Down Expand Up @@ -260,7 +259,7 @@ GEM
unicode-display_width (>= 2.4.0, < 3.0)
rubocop-ast (1.32.3)
parser (>= 3.3.1.0)
rubocop-md (1.2.3)
rubocop-md (1.2.4)
rubocop (>= 1.45)
rubocop-performance (1.22.1)
rubocop (>= 1.48.1, < 2.0)
Expand Down Expand Up @@ -292,7 +291,7 @@ GEM
actionpack (>= 5.2)
activesupport (>= 5.2)
sprockets (>= 3.0.0)
standard (1.41.0)
standard (1.41.1)
language_server-protocol (~> 3.17.0.2)
lint_roller (~> 1.0)
rubocop (~> 1.66.0)
Expand Down Expand Up @@ -329,7 +328,7 @@ GEM
yard (0.9.37)
yard-activesupport-concern (0.0.1)
yard (>= 0.8)
zeitwerk (2.7.0)
zeitwerk (2.7.1)

PLATFORMS
ruby
Expand All @@ -355,7 +354,6 @@ DEPENDENCIES
net-imap
net-pop
net-smtp
ostruct
pry (~> 0.13)
puma (~> 6)
rails (~> 7.0.0)
Expand Down
10 changes: 10 additions & 0 deletions docs/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,16 @@ nav_order: 5

## main

* Remove OpenStruct from codebase.

*Oleksii Vasyliev*

## 3.19.0

* Relax Active Support version constraint in gemspec.

*Simon Fish*

## 3.18.0

* Enable components to use `@request` and `request` methods/ivars.
Expand Down
2 changes: 1 addition & 1 deletion docs/Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,7 @@ GEM
rb-fsevent (0.11.2)
rb-inotify (0.11.1)
ffi (~> 1.0)
rexml (3.3.8)
rexml (3.3.9)
rouge (3.30.0)
rubyzip (2.3.2)
safe_yaml (1.0.5)
Expand Down
2 changes: 1 addition & 1 deletion docs/_data/library.yml
Original file line number Diff line number Diff line change
@@ -1 +1 @@
version: 3.18.0
version: 3.19.0
2 changes: 1 addition & 1 deletion lib/view_component/version.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
module ViewComponent
module VERSION
MAJOR = 3
MINOR = 18
MINOR = 19
PATCH = 0
PRE = nil

Expand Down
2 changes: 1 addition & 1 deletion test/sandbox/app/components/partial_component.html.erb
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
<%= render partial: "test_partial" %>
<%= render "test_partial" %>
<%= render OpenStruct.new(to_partial_path: "test_partial") %>
<%= render PartialModel.new(to_partial_path: "test_partial") %>
2 changes: 0 additions & 2 deletions test/sandbox/app/controllers/application_controller.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
# frozen_string_literal: true

require "ostruct"

class ApplicationController < ActionController::Base
end
Original file line number Diff line number Diff line change
Expand Up @@ -43,11 +43,11 @@ def controller_to_string_render_component
end

def products
@products = [OpenStruct.new(name: "Radio clock"), OpenStruct.new(name: "Mints")]
@products = [Product.new(name: "Radio clock"), Product.new(name: "Mints")]
end

def inline_products
products = [OpenStruct.new(name: "Radio clock"), OpenStruct.new(name: "Mints")]
products = [Product.new(name: "Radio clock"), Product.new(name: "Mints")]

render(ProductComponent.with_collection(products, notice: "Today only"))
end
Expand Down
1 change: 1 addition & 0 deletions test/sandbox/app/models/coupon.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Coupon = Struct.new(:percent_off, keyword_init: true)
1 change: 1 addition & 0 deletions test/sandbox/app/models/partial_model.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
PartialModel = Struct.new(:to_partial_path, keyword_init: true)
1 change: 1 addition & 0 deletions test/sandbox/app/models/photo.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Photo = Struct.new(:title, :caption, :url, keyword_init: true)
1 change: 1 addition & 0 deletions test/sandbox/app/models/product.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Product = Struct.new(:name, keyword_init: true)
2 changes: 1 addition & 1 deletion test/sandbox/test/collection_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ def call
end

def setup
@products = [OpenStruct.new(name: "Radio clock"), OpenStruct.new(name: "Mints")]
@products = [Product.new(name: "Radio clock"), Product.new(name: "Mints")]
@collection = ProductComponent.with_collection(@products, notice: "secondhand")
end

Expand Down
Loading

0 comments on commit cb2bda5

Please sign in to comment.