Skip to content

Commit

Permalink
FIX: adaptes acceptance tests for new dropdown-menu (#570)
Browse files Browse the repository at this point in the history
  • Loading branch information
jjaffeux authored May 8, 2024
1 parent 5e75baa commit 6c22928
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 deletions.
11 changes: 8 additions & 3 deletions assets/javascripts/discourse/components/assigned-to-post.gjs
Original file line number Diff line number Diff line change
Expand Up @@ -39,22 +39,27 @@ export default class AssignedToPost extends Component {
{{/if}}
</a>

<DMenu @icon="ellipsis-h" class="btn-flat more-button" @autofocus={{true}}>
<DMenu
@identifier="post-assign-menu"
@icon="ellipsis-h"
class="btn-flat more-button"
@autofocus={{true}}
>
<DropdownMenu as |dropdown|>
<dropdown.item>
<DButton
@action={{this.unassign}}
@icon="user-plus"
@label="discourse_assign.unassign.title"
class="btn-transparent"
class="btn-transparent unassign-btn"
/>
</dropdown.item>
<dropdown.item>
<DButton
@action={{this.editAssignment}}
@icon="group-plus"
@label="discourse_assign.reassign.title_w_ellipsis"
class="btn-transparent"
class="btn-transparent edit-assignment-btn"
/>
</dropdown.item>
</DropdownMenu>
Expand Down
4 changes: 2 additions & 2 deletions test/javascripts/acceptance/post-popup-menu-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ const selectors = {
assignedTo: ".post-stream article#post_2 .assigned-to",
moreButton: ".post-stream .topic-post .more-button",
popupMenu: {
unassign: ".popup-menu .popup-menu-btn svg.d-icon-user-plus",
editAssignment: ".popup-menu .popup-menu-btn svg.d-icon-group-plus",
unassign: ".post-assign-menu-content .unassign-btn",
editAssignment: ".post-assign-menu-content .edit-assignment-btn",
},
modal: {
assignee: ".modal-container .select-kit-header-wrapper",
Expand Down

0 comments on commit 6c22928

Please sign in to comment.