Skip to content

Commit dbb6ea0

Browse files
authored
Fix the dropdown component styling in the preview (#135)
1 parent 468b37d commit dbb6ea0

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

playwright/dropdown-menu.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ test('test', async ({ page }) => {
3939
await menuElement.click();
4040
await expect(menuElement).toHaveAttribute('data-state', 'open');
4141
// Clicking outside the menu should close it
42-
await page.click('body');
42+
await page.locator('body').click({ position: { x: 0, y: 0 } });
4343
await expect(menuElement).toHaveAttribute('data-state', 'closed');
4444

4545
// Reopen the menu

preview/src/components/dropdown_menu/variants/main/mod.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
use dioxus::prelude::*;
2-
use dioxus_primitives::dropdown_menu::{
1+
use super::super::component::{
32
DropdownMenu, DropdownMenuContent, DropdownMenuItem, DropdownMenuTrigger,
43
};
4+
use dioxus::prelude::*;
55
use strum::IntoEnumIterator;
66

77
#[derive(Clone, Copy, strum::Display, strum::EnumIter, PartialEq)]

0 commit comments

Comments
 (0)