File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ group :development, :test do
2727 gem "method_source" , "~> 1"
2828 gem "minitest" , "~> 6"
2929 gem "minitest-mock"
30- gem "nokogiri" , "1.19.1 "
30+ gem "nokogiri" , "1.19.2 "
3131 gem "propshaft" , "~> 1"
3232 gem "puma" , ">= 6"
3333 gem "rake" , "~> 13"
Load Diff Large diffs are not rendered by default.
Original file line number Diff line number Diff line change @@ -14,6 +14,14 @@ nav_order: 6
1414
1515 * GitHub Copilot*
1616
17+ * Replace deprecated ` require_dependency ` with ` require ` in preview loading.
18+
19+ * GitHub Copilot*
20+
21+ * Return ` html_safe ` empty string from ` render_in ` when ` render? ` is false.
22+
23+ * Copilot*
24+
1725## 4.5.0
1826
1927* Fix initialization ordering issue causing missing asset errors in Sprockets.
Original file line number Diff line number Diff line change 11GEM
22 remote: https://rubygems.org/
33 specs:
4- activesupport (8.0.2 )
4+ activesupport (8.0.4.1 )
55 base64
66 benchmark (>= 0.3 )
77 bigdecimal
1010 drb
1111 i18n (>= 1.6 , < 2 )
1212 logger (>= 1.4.2 )
13- minitest (>= 5.1 )
13+ minitest (>= 5.1 , < 6 )
1414 securerandom (>= 0.3 )
1515 tzinfo (~> 2.0 , >= 2.0.5 )
1616 uri (>= 0.13.1 )
1717 addressable (2.8.7 )
1818 public_suffix (>= 2.0.2 , < 7.0 )
19- base64 (0.2 .0 )
20- benchmark (0.4.1 )
21- bigdecimal (3.2.2 )
19+ base64 (0.3 .0 )
20+ benchmark (0.5.0 )
21+ bigdecimal (4.0.1 )
2222 coffee-script (2.4.1 )
2323 coffee-script-source
2424 execjs
2525 coffee-script-source (1.12.2 )
2626 colorator (1.1.0 )
2727 commonmarker (0.23.11 )
28- concurrent-ruby (1.3.5 )
29- connection_pool (2.5.3 )
28+ concurrent-ruby (1.3.6 )
29+ connection_pool (3.0.2 )
3030 csv (3.3.5 )
3131 dnsruby (1.73.1 )
3232 base64 (>= 0.2 )
106106 activesupport (>= 2 )
107107 nokogiri (>= 1.4 )
108108 http_parser.rb (0.8.0 )
109- i18n (1.14.7 )
109+ i18n (1.14.8 )
110110 concurrent-ruby (~> 1.0 )
111111 jekyll (3.10.0 )
112112 addressable (~> 2.4 )
218218 gemoji (>= 3 , < 5 )
219219 html-pipeline (~> 2.2 )
220220 jekyll (>= 3.0 , < 5.0 )
221- json (2.18.1 )
221+ json (2.19.2 )
222222 kramdown (2.4.0 )
223223 rexml
224224 kramdown-parser-gfm (1.1.0 )
234234 jekyll (>= 3.5 , < 5.0 )
235235 jekyll-feed (~> 0.9 )
236236 jekyll-seo-tag (~> 2.1 )
237- minitest (5.25.5 )
237+ minitest (5.27.0 )
238238 net-http (0.9.1 )
239239 uri (>= 0.11.1 )
240240 nokogiri (1.19.1 )
Original file line number Diff line number Diff line change @@ -160,7 +160,7 @@ def render_in(view_context, &block)
160160
161161 value
162162 else
163- ""
163+ "" . html_safe
164164 end
165165 ensure
166166 view_context . instance_variable_set ( :@virtual_path , @old_virtual_path )
Original file line number Diff line number Diff line change @@ -95,7 +95,7 @@ def preview_example_template_path(example)
9595 # @private
9696 def __vc_load_previews
9797 Array ( preview_paths ) . each do |preview_path |
98- Dir [ "#{ preview_path } /**/*preview.rb" ] . sort . each { |file | require_dependency file }
98+ Dir [ "#{ preview_path } /**/*preview.rb" ] . sort . each { |file | require file }
9999 end
100100 end
101101
Original file line number Diff line number Diff line change @@ -877,6 +877,12 @@ def test_does_not_render_passed_in_content_if_render_is_false
877877 assert total < 1
878878 end
879879
880+ def test_render_in_returns_html_safe_string_when_render_is_false
881+ render_inline ( ConditionalRenderComponent . new ( should_render : false ) )
882+
883+ assert_predicate @rendered_content , :html_safe?
884+ end
885+
880886 def test_collection_parameter_does_not_require_compile
881887 dynamic_component =
882888 Class . new ( ViewComponent ::Base ) do
You can’t perform that action at this time.
0 commit comments