Files
growstuff/app/views/posts/_actions.html.haml
Daniel O'Connor 7d63234841 Upgrade to bootstrap 5 (#3605)
* Upgrade boostrap

* Remove deprecated bootstrap toggles

* Migrate other details

* Avoid accidentally including bootstrap twice

* Avoid accidentally including bootstrap twice

* Avoid accidentally including bootstrap twice

* Fix spec

* Fix spec, where the size of the screen has gone to a partial breakpoint/you can't click on your own name in tablet view

* Fix spec

* Cleanup

* Cleanup
2024-03-10 11:49:22 +10:30

14 lines
677 B
Plaintext

- if can? :edit, post
.dropdown.float-right
%button#post-edit-button.btn.dropdown-toggle{"aria-expanded" => "false", "aria-haspopup" => "true", "data-bs-toggle" => "dropdown", :type => "button"} Actions
.dropdown-menu.dropdown-menu-xs{"aria-labelledby" => "post-edit-button"}
- if can? :edit, post
= link_to edit_post_path(post), class: 'dropdown-item' do
= edit_icon
Edit
= add_photo_button(post, classes: "dropdown-item")
.dropdown-divider
- if can? :delete, post
= link_to post_path(post), class: 'dropdown-item text-danger', data: { confirm: 'Are you sure?' } do
= delete_icon
Delete