-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor dialog to have form and footer divided correctly
- Loading branch information
1 parent
cec6cb7
commit cd57025
Showing
4 changed files
with
11 additions
and
23 deletions.
There are no files selected for viewing
6 changes: 6 additions & 0 deletions
6
modules/costs/app/components/time_entries/entry_dialog_component.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 |
---|---|---|
@@ -1,4 +1,10 @@ | ||
<%= render(Primer::Alpha::Dialog.new(title: 'Log Time', size: :large, id: MODAL_ID, data: { "controller" => "time-entry", "application-target" => "dynamic" })) do |d| %> | ||
<% d.with_header(variant: :large, mb: 3) %> | ||
<% d.with_body do %> | ||
<%= render(TimeEntries::TimeEntryFormComponent.new(time_entry: time_entry)) %> | ||
<% end %> | ||
<% d.with_footer(variant: :large) do %> | ||
<%= render(Primer::ButtonComponent.new(data: { 'close-dialog-id': "time-entry-dialog" })) { I18n.t("button_cancel") } %> | ||
<%= render(Primer::ButtonComponent.new(scheme: :primary, type: :submit, test_selector: "create-time-entry-button", form: 'time-entry-form')) { "Create Time Entry" } %> | ||
<% 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
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