diff --git a/docs/example/Dropdown/index.md b/docs/example/Dropdown/index.md
index e99a71a4..d7000c4d 100644
--- a/docs/example/Dropdown/index.md
+++ b/docs/example/Dropdown/index.md
@@ -23,13 +23,13 @@ demo:
## 属性 - Attributes & Properties
-| 属性 | 说明 | 类型 | 默认值 |
-| --------------- | ------------------------------------------------------------------- | ----------------------------------------------------------------------------- | ------------ |
-| placement | 弹出方向 | `bottomLeft` \| `bottom` \| `bottomRight` \| `topLeft` \| `top` \| `topRight` | `bottomLeft` |
-| margin | trigger 与下拉内容的间距,单位是`px` | `number` | 4 |
-| mouseEnterDelay | hover 模式下,鼠标移入 trigger 多久后展示下拉菜单的内容,单位是`ms` | `number` | 100 |
-| mouseLeaveDelay | hover 模式下,鼠标移出下拉菜单多久后隐藏下拉菜单的内容,单位是`ms` | `number` | 100 |
-| triggerAction | 触发下拉菜单的方式 | `click` \| `hover` | `hover` |
+| 属性 | 说明 | 类型 | 默认值 |
+| ----------------------------------------- | ------------------------------------------------------------------- | ----------------------------------------------------------------------------- | ------------ |
+| placement | 弹出方向 | `bottomLeft` \| `bottom` \| `bottomRight` \| `topLeft` \| `top` \| `topRight` | `bottomLeft` |
+| margin | trigger 与下拉内容的间距,单位是`px` | `number` | 4 |
+| mouseEnterDelay
(mouse-enter-delay) | hover 模式下,鼠标移入 trigger 多久后展示下拉菜单的内容,单位是`ms` | `number` | 100 |
+| mouseLeaveDelay
(mouse-leave-delay) | hover 模式下,鼠标移出下拉菜单多久后隐藏下拉菜单的内容,单位是`ms` | `number` | 100 |
+| triggerAction
(trigger-action) | 触发下拉菜单的方式 | `click` \| `hover` | `hover` |
## 事件 - Events
diff --git a/package.json b/package.json
index bbf2e187..8557ddc5 100644
--- a/package.json
+++ b/package.json
@@ -12,15 +12,16 @@
"scripts": {
"build": "pnpm build:all",
"build:all": "cd packages/banana && pnpm run build && cd ../banana-react && pnpm run build",
- "dev": "npm run dev:all",
- "dev:all": "cd packages/banana && npm run dev & cd packages/banana-react && npm run dev & dumi dev",
+ "dev": "pnpm run dev:all",
+ "dev:all": "cd packages/banana && pnpm run dev & cd packages/banana-react && pnpm run dev & dumi dev",
"dev:dumi": "dumi dev",
"docs:build": "dumi build",
"docs:deploy": "gh-pages -d docs-dist",
- "lint": "npm run lint:es",
+ "lint": "pnpm run lint:es",
"lint:es": "eslint \"packages/**/{src,styles,bin}/**/*.{js,jsx,ts,tsx}\"",
"prepare": "husky install && dumi setup",
- "start": "npm run dev"
+ "start": "pnpm run dev",
+ "test": "cd packages/banana && pnpm run test"
},
"commitlint": {
"extends": [
diff --git a/packages/banana/src/dropdown/index.test.ts b/packages/banana/src/dropdown/index.test.ts
index 8226a370..1dae1570 100644
--- a/packages/banana/src/dropdown/index.test.ts
+++ b/packages/banana/src/dropdown/index.test.ts
@@ -21,7 +21,7 @@ describe('b-dropdown', () => {
it('should open the dropdown when mouse enter the trigger after mouseEnterDelay', async () => {
const element = await fixture(html`
-
+
Banana
Option 1
@@ -47,7 +47,7 @@ describe('b-dropdown', () => {
it('should close the dropdown when mouse leave the dropdown content after mouseLeaveDelay', async () => {
const element = await fixture(html`
-
+
Banana
Option 1
@@ -78,7 +78,7 @@ describe('b-dropdown', () => {
describe('when triggerAction is click', () => {
it('should open the dropdown when click the trigger', async () => {
const element = await fixture(html`
-
+
Banana
Option 1
@@ -116,7 +116,7 @@ describe('b-dropdown', () => {
it('should doing nothing when mouse enter the trigger', async () => {
const element = await fixture(html`
-
+
Banana
Option 1
@@ -149,7 +149,7 @@ describe('b-dropdown', () => {
describe('when keydown', () => {
it('should open the dropdown when press Enter', async () => {
const element = await fixture(html`
-
+
Banana
Option 1
@@ -175,7 +175,7 @@ describe('b-dropdown', () => {
it('should close the dropdown when press Escape', async () => {
const element = await fixture(html`
-
+
Banana
Option 1
@@ -204,7 +204,7 @@ describe('b-dropdown', () => {
it('should open or close the dropdown when press Space', async () => {
const element = await fixture(html`
-
+
Banana
Option 1