-
Notifications
You must be signed in to change notification settings - Fork 115
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add a filter slot to the dialog header (#2804)
- Loading branch information
Showing
6 changed files
with
51 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@primer/view-components": minor | ||
--- | ||
|
||
Add a filter slot to the dialog header |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
19 changes: 19 additions & 0 deletions
19
previews/primer/alpha/dialog_preview/with_header_filter.html.erb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
<%= render(Primer::Alpha::Dialog.new(open: true, title: "Dialog")) do |dialog| %> | ||
<% dialog.with_show_button { "Open" } %> | ||
<% dialog.with_header do |header| %> | ||
<% header.with_filter(pr: 3, pl: 3) do %> | ||
<%= render Primer::Alpha::TextField.new( | ||
autofocus: true, | ||
visually_hide_label: true, | ||
name: "filter", | ||
label: "Filter dialog", | ||
) %> | ||
<% end %> | ||
<% end %> | ||
<% dialog.with_body do %> | ||
Body | ||
<% end %> | ||
<% dialog.with_footer do %> | ||
Footer | ||
<% end %> | ||
<% end %> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters