Skip to content

Commit d53b794

Browse files
fix(a11y)-11: wrap RestartMultipleButton in MenuList to satisfy ARIA required parent
Signed-off-by: Sagar Choudhary <sagar6203620715@gmail.com>
1 parent b228929 commit d53b794

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

frontend/src/components/common/Resource/RestartMultipleButton.stories.tsx

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@
1414
* limitations under the License.
1515
*/
1616

17+
import MenuList from '@mui/material/MenuList';
18+
import Paper from '@mui/material/Paper';
1719
import { Meta, StoryFn } from '@storybook/react';
1820
import { getTestDate } from '../../../helpers/testHelpers';
1921
import { TestContext } from '../../../test';
@@ -54,7 +56,15 @@ AfterConfirmCallback.args = {
5456
},
5557
};
5658

57-
export const MenuButtonStyle = Template.bind({});
59+
const MenuTemplate: StoryFn<typeof RestartMultipleButton> = args => (
60+
<Paper>
61+
<MenuList>
62+
<RestartMultipleButton {...args} />
63+
</MenuList>
64+
</Paper>
65+
);
66+
67+
export const MenuButtonStyle = MenuTemplate.bind({});
5868
MenuButtonStyle.args = {
5969
items: [
6070
{ metadata: { uid: '1', name: 'Resource 1', creationTimestamp: getTestDate().toISOString() } },

0 commit comments

Comments
 (0)