<%= render_component_header title: "Dialog", description: "A window overlaid on either the primary window or another dialog window, rendering the content underneath inert." %> <% content_for :preview, flush: true do %>
<%= render_code_preview('dialog') %>
<% end %> <% content_for :code, flush: true do %> <%= code_partial("dialog/preview", :erb) %> <% end %> <%= render_preview %>

Installation

<%= code_sample(language: "sh") do %> rails generate shadcn_ui dialog <% end %>

Usage

<%= code_partial("dialog/usage", :erb) %> <%= render_usage("dialog") %>

Examples

<% content_for :examples, flush: true do %>
<%= render_dialog do %> <%= dialog_trigger do %> <%= render_button("Open Notifications", variant: :outline) %> <% end %> <%= dialog_content do %>

Notifications

Choose what you want to be notified about.

Everything

Email digest, mentions & all activity.

Available

Only mentions and comments.

Ignoring

Turn off all notifications.

<% end %> <% end %>
<% end %> <% content_for :code, flush: true do %> <%= code_partial("dialog/notifications", :erb) %> <% end %> <%= render_example %> <% content_for :examples, flush: true do %>
<%= render_dialog do %> <%= dialog_trigger do %> <%= render_button("Dialog with Form", variant: :outline) %> <% end %> <%= dialog_content do %>

Edit profile

Make changes to your profile here. Click save when you're done.

<% end %> <% end %>
<% end %> <% content_for :code, flush: true do %> <%= code_partial("dialog/form", :erb) %> <% end %> <%= render_example %>