Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
Element
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
CI / CD Analytics
Repository Analytics
Value Stream Analytics
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
林焕东
Element
Commits
f274f3e3
Commit
f274f3e3
authored
Jan 31, 2018
by
杨奕
Committed by
GitHub
Jan 31, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Dropdown: remove transition delay when trigger is click (#9573)
parent
40e815f1
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
8 additions
and
8 deletions
+8
-8
examples/docs/en-US/dropdown.md
examples/docs/en-US/dropdown.md
+2
-2
examples/docs/es/dropdown.md
examples/docs/es/dropdown.md
+2
-2
examples/docs/zh-CN/dropdown.md
examples/docs/zh-CN/dropdown.md
+2
-2
packages/dropdown/src/dropdown.vue
packages/dropdown/src/dropdown.vue
+2
-2
No files found.
examples/docs/en-US/dropdown.md
View file @
f274f3e3
...
@@ -328,8 +328,8 @@ Besides default size, Dropdown component provides three additional sizes for you
...
@@ -328,8 +328,8 @@ Besides default size, Dropdown component provides three additional sizes for you
| placement | placement of pop menu | string | top/top-start/top-end/bottom/bottom-start/bottom-end | bottom-end |
| placement | placement of pop menu | string | top/top-start/top-end/bottom/bottom-start/bottom-end | bottom-end |
| trigger | how to trigger | string | hover/click | hover |
| trigger | how to trigger | string | hover/click | hover |
| hide-on-click | whether to hide menu after clicking menu-item | boolean | — | true |
| hide-on-click | whether to hide menu after clicking menu-item | boolean | — | true |
| show-timeout | Delay time before show a dropdown
| number
| — | 250 |
| show-timeout | Delay time before show a dropdown
(only works when trigger is
`hover`
) | number
| — | 250 |
| hide-timeout | Delay time before hide a dropdown
| number
| — | 150 |
| hide-timeout | Delay time before hide a dropdown
(only works when trigger is
`hover`
) | number
| — | 150 |
### Dropdown Events
### Dropdown Events
| Event Name | Description | Parameters |
| Event Name | Description | Parameters |
...
...
examples/docs/es/dropdown.md
View file @
f274f3e3
...
@@ -330,8 +330,8 @@ Además del tamaño predeterminado, el componente Dropdown proporciona tres tama
...
@@ -330,8 +330,8 @@ Además del tamaño predeterminado, el componente Dropdown proporciona tres tama
| placement | colocación del menú | string | top/top-start/top-end/bottom/bottom-start/bottom-end | bottom-end |
| placement | colocación del menú | string | top/top-start/top-end/bottom/bottom-start/bottom-end | bottom-end |
| trigger | cómo detonar | string | hover/click | hover |
| trigger | cómo detonar | string | hover/click | hover |
| hide-on-click | si se oculta el menú después de hacer clic en el elemento | boolean | — | true |
| hide-on-click | si se oculta el menú después de hacer clic en el elemento | boolean | — | true |
| show-timeout | Tiempo de retardo antes de mostrar un dropdown | number | — | 250 |
| show-timeout | Tiempo de retardo antes de mostrar un dropdown
(only works when trigger is
`hover`
)
| number | — | 250 |
| hide-timeout | Tiempo de retardo antes de ocultar un dropdown | number | — | 150 |
| hide-timeout | Tiempo de retardo antes de ocultar un dropdown
(only works when trigger is
`hover`
)
| number | — | 150 |
### Dropdown Eventos
### Dropdown Eventos
| Nombre | Descripción | Parametros |
| Nombre | Descripción | Parametros |
...
...
examples/docs/zh-CN/dropdown.md
View file @
f274f3e3
...
@@ -334,8 +334,8 @@ Dropdown 组件提供除了默认值以外的三种尺寸,可以在不同场
...
@@ -334,8 +334,8 @@ Dropdown 组件提供除了默认值以外的三种尺寸,可以在不同场
| placement | 菜单弹出位置 | string | top/top-start/top-end/bottom/bottom-start/bottom-end | bottom-end |
| placement | 菜单弹出位置 | string | top/top-start/top-end/bottom/bottom-start/bottom-end | bottom-end |
| trigger | 触发下拉的行为 | string | hover, click | hover |
| trigger | 触发下拉的行为 | string | hover, click | hover |
| hide-on-click | 是否在点击菜单项后隐藏菜单 | boolean | — | true |
| hide-on-click | 是否在点击菜单项后隐藏菜单 | boolean | — | true |
| show-timeout | 展开下拉菜单的延时
| number | — | 250 |
| show-timeout | 展开下拉菜单的延时
(仅在 trigger 为 hover 时有效)
| number | — | 250 |
| hide-timeout | 收起下拉菜单的延时
| number | — | 150 |
| hide-timeout | 收起下拉菜单的延时
(仅在 trigger 为 hover 时有效)
| number | — | 150 |
### Dropdown Events
### Dropdown Events
| 事件名称 | 说明 | 回调参数 |
| 事件名称 | 说明 | 回调参数 |
...
...
packages/dropdown/src/dropdown.vue
View file @
f274f3e3
...
@@ -115,7 +115,7 @@
...
@@ -115,7 +115,7 @@
clearTimeout
(
this
.
timeout
);
clearTimeout
(
this
.
timeout
);
this
.
timeout
=
setTimeout
(()
=>
{
this
.
timeout
=
setTimeout
(()
=>
{
this
.
visible
=
true
;
this
.
visible
=
true
;
},
this
.
showTimeout
);
},
this
.
trigger
===
'
click
'
?
0
:
this
.
showTimeout
);
},
},
hide
()
{
hide
()
{
if
(
this
.
triggerElm
.
disabled
)
return
;
if
(
this
.
triggerElm
.
disabled
)
return
;
...
@@ -124,7 +124,7 @@
...
@@ -124,7 +124,7 @@
clearTimeout
(
this
.
timeout
);
clearTimeout
(
this
.
timeout
);
this
.
timeout
=
setTimeout
(()
=>
{
this
.
timeout
=
setTimeout
(()
=>
{
this
.
visible
=
false
;
this
.
visible
=
false
;
},
this
.
hideTimeout
);
},
this
.
trigger
===
'
click
'
?
0
:
this
.
hideTimeout
);
},
},
handleClick
()
{
handleClick
()
{
if
(
this
.
triggerElm
.
disabled
)
return
;
if
(
this
.
triggerElm
.
disabled
)
return
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment