Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

updating slot use in BorderBox examples to the '.with_#{slot_name}' syntax #1290

Merged
merged 2 commits into from
Aug 9, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/ninety-feet-melt.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@primer/view-components': patch
---

updating BorderBox slot use to the new `.with_#{slot_name}` syntax
26 changes: 13 additions & 13 deletions app/components/primer/beta/border_box.rb
Original file line number Diff line number Diff line change
Expand Up @@ -72,55 +72,55 @@ class BorderBox < Primer::Component

# @example Header with title, body, rows, and footer
# <%= render(Primer::Beta::BorderBox.new) do |component| %>
# <% component.header do |h| %>
# <% component.with_header do |h| %>
# <% h.title(tag: :h2) do %>
# Header
# <% end %>
# <% end %>
# <% component.body do %>
# <% component.with_body do %>
# Body
# <% end %>
# <% component.row do %>
# <% component.with_row do %>
# <% if true %>
# Row one
# <% end %>
# <% end %>
# <% component.row do %>
# <% component.with_row do %>
# Row two
# <% end %>
# <% component.footer do %>
# <% component.with_footer do %>
# Footer
# <% end %>
# <% end %>
#
# @example Padding density
# <%= render(Primer::Beta::BorderBox.new(padding: :condensed)) do |component| %>
# <% component.header do %>
# <% component.with_header do %>
# Header
# <% end %>
# <% component.body do %>
# <% component.with_body do %>
# Body
# <% end %>
# <% component.row do %>
# <% component.with_row do %>
# Row two
# <% end %>
# <% component.footer do %>
# <% component.with_footer do %>
# Footer
# <% end %>
# <% end %>
#
# @example Row colors
# <%= render(Primer::Beta::BorderBox.new) do |component| %>
# <% component.row do %>
# <% component.with_row do %>
# Default
# <% end %>
# <% component.row(scheme: :neutral) do %>
# <% component.with_row(scheme: :neutral) do %>
# Neutral
# <% end %>
# <% component.row(scheme: :info) do %>
# <% component.with_row(scheme: :info) do %>
# Info
# <% end %>
# <% component.row(scheme: :warning) do %>
# <% component.with_row(scheme: :warning) do %>
# Warning
# <% end %>
# <% end %>
Expand Down