Skip to content

Commit

Permalink
item actions menu fix
Browse files Browse the repository at this point in the history
  • Loading branch information
dzonidoo committed Jan 15, 2025
1 parent ec7dba0 commit ab5c9c6
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -59,11 +59,18 @@ export class AuthoringActionsMenu extends React.PureComponent<IProps, IState> {

return (
<div>
<Menu items={menuItems}>
<Menu items={menuItems} data-test-id='actions-list'>

Check failure on line 62 in scripts/apps/authoring-react/subcomponents/authoring-actions-menu.tsx

View workflow job for this annotation

GitHub Actions / test

Unexpected usage of singlequote

Check failure on line 62 in scripts/apps/authoring-react/subcomponents/authoring-actions-menu.tsx

View workflow job for this annotation

GitHub Actions / test

Unexpected usage of singlequote

Check failure on line 62 in scripts/apps/authoring-react/subcomponents/authoring-actions-menu.tsx

View workflow job for this annotation

GitHub Actions / test

Unexpected usage of singlequote
{(toggle) => (
<MoreActionsButton
aria-label={gettext('Actions menu')}
onClick={toggle}
buttonRef={(el) => {
if (el != null) {
setTimeout(() => {
el.click();
});
}
}}
/>
)}
</Menu>
Expand Down
4 changes: 2 additions & 2 deletions scripts/core/ui/components/MoreActionsButton.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import * as React from 'react';

interface IProps {
'aria-label': string;
ref?(event): void;
buttonRef?(event): void;
onClick(event: React.MouseEvent): void;
}

Expand All @@ -12,7 +12,7 @@ export class MoreActionsButton extends React.PureComponent<IProps> {
<button
className="sd-navbtn"
aria-label={this.props['aria-label']}
ref={this.props.ref}
ref={this.props.buttonRef}
onClick={this.props.onClick}
>
<i className="icon-dots-vertical" />
Expand Down

0 comments on commit ab5c9c6

Please sign in to comment.