Skip to content

Commit

Permalink
chore(picker): add story to test the background click
Browse files Browse the repository at this point in the history
  • Loading branch information
TarunAdobe committed Feb 3, 2025
1 parent 272fc0b commit a413ae8
Showing 1 changed file with 26 additions and 0 deletions.
26 changes: 26 additions & 0 deletions packages/picker/stories/picker.stories.ts
Original file line number Diff line number Diff line change
Expand Up @@ -694,3 +694,29 @@ custom.args = {
open: true,
};
custom.decorators = [isOverlayOpen];

export const BackgroundClickTest = (): TemplateResult => {
return html`
<div style="display: flex; flex-direction: column;">
<sp-picker size="l">
<sp-menu-item value="option-1">Deselect</sp-menu-item>
<sp-menu-item value="option-2">Select Inverse</sp-menu-item>
</sp-picker>
<div style="position: absolute; bottom: 50px;">
<sp-button
@click=${() => {
console.log(
'this button should not have been clicked...'
);
}}
size="l"
>
I shall not be clicked
</sp-button>
</div>
</div>
`;
};
BackgroundClickTest.swc_vrt = {
skip: true,
};

0 comments on commit a413ae8

Please sign in to comment.