mirror of
https://github.com/maybe-finance/maybe.git
synced 2025-08-09 15:35:22 +02:00
Improve form field submit buttons to match normal buttons a bit more
This commit is contained in:
parent
f70780c93a
commit
a1910580a8
3 changed files with 8 additions and 7 deletions
|
@ -656,7 +656,8 @@
|
|||
}
|
||||
|
||||
.form-field__submit {
|
||||
@apply cursor-pointer rounded-lg bg-surface p-3 text-center text-white hover:bg-surface-hover;
|
||||
@apply inline-flex items-center gap-2 px-3 py-2 rounded-lg text-sm font-medium cursor-pointer disabled:cursor-not-allowed focus:outline-gray-500;
|
||||
@apply transition-all duration-300;
|
||||
}
|
||||
|
||||
/* Checkboxes */
|
||||
|
|
|
@ -4,8 +4,8 @@
|
|||
data: {
|
||||
turbo: false,
|
||||
controller: "deletion",
|
||||
deletion_dangerous_action_class: "form-field__submit bg-container text-red-600 border hover:bg-red-50",
|
||||
deletion_safe_action_class: "form-field__submit border border-transparent",
|
||||
deletion_dangerous_action_class: "form-field__submit bg-btn text-white",
|
||||
deletion_safe_action_class: "form-field__submit bg-success text-white",
|
||||
deletion_submit_text_when_not_replacing_value: t(".delete_and_leave_uncategorized", category_name: @category.name),
|
||||
deletion_submit_text_when_replacing_value: t(".delete_and_recategorize", category_name: @category.name) } do |f| %>
|
||||
<%= f.collection_select :replacement_category_id,
|
||||
|
@ -15,7 +15,7 @@
|
|||
{ data: { deletion_target: "replacementField", action: "deletion#updateSubmitButton" } } %>
|
||||
|
||||
<%= f.submit t(".delete_and_leave_uncategorized", category_name: @category.name),
|
||||
class: "form-field__submit bg-container text-red-600 border hover:bg-red-50",
|
||||
class: "form-field__submit bg-destructive text-white",
|
||||
data: { deletion_target: "submitButton" } %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
|
|
|
@ -4,8 +4,8 @@
|
|||
data: {
|
||||
turbo: false,
|
||||
controller: "deletion",
|
||||
deletion_dangerous_action_class: "form-field__submit bg-container text-red-600 border hover:bg-red-50",
|
||||
deletion_safe_action_class: "form-field__submit border border-transparent",
|
||||
deletion_dangerous_action_class: "form-field__submit bg-btn text-white",
|
||||
deletion_safe_action_class: "form-field__submit bg-success text-white",
|
||||
deletion_submit_text_when_not_replacing_value: t(".delete_and_leave_uncategorized", tag_name: @tag.name),
|
||||
deletion_submit_text_when_replacing_value: t(".delete_and_recategorize", tag_name: @tag.name) } do |f| %>
|
||||
<%= f.collection_select :replacement_tag_id,
|
||||
|
@ -15,7 +15,7 @@
|
|||
{ data: { deletion_target: "replacementField", action: "deletion#updateSubmitButton" } } %>
|
||||
|
||||
<%= f.submit t(".delete_and_leave_uncategorized", tag_name: @tag.name),
|
||||
class: "form-field__submit bg-container text-red-600 border hover:bg-red-50",
|
||||
class: "form-field__submit bg-destructive text-white",
|
||||
data: { deletion_target: "submitButton" } %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue