Modal
A native
dialog
driven by the
app-theme-modal
custom element. Clicking the trigger slot opens it.
Default
= app_theme_modal do |modal|
- modal.with_trigger do
= app_theme_button "Open modal", variant: :primary
- modal.with_header do
Confirm changes
- modal.with_body do
%p Saving will republish the page immediately. This can't be undone.
- modal.with_footer do
= app_theme_button "Save changes", variant: :primarySizes
.demo-row
- %i[lg xl].each do |size|
= app_theme_modal(size: size) do |modal|
- modal.with_trigger do
= app_theme_button "Open #{size} modal", variant: :secondary
- modal.with_header do
= "A #{size} modal"
- modal.with_body do
%p Wider container for dense content.