mirror of https://github.com/ElemeFE/element
				
				
				
			Select: add blur method
							parent
							
								
									7ae2662b7c
								
							
						
					
					
						commit
						46b70a5b89
					
				|  | @ -713,3 +713,4 @@ If the binding value of Select is an object, make sure to assign `value-key` as | |||
| | Method | Description | Parameters | | ||||
| |------|--------|-------| | ||||
| | focus | focus the Input component | - | | ||||
| | blur | blur the Input component, and hide the dropdown | - | | ||||
|  |  | |||
|  | @ -719,3 +719,4 @@ Si el valor de encuadernación de Select es un objeto, asegúrese de asignar `va | |||
| | Metodo | Descripción                 | Parametros | | ||||
| | ------ | --------------------------- | ---------- | | ||||
| | focus  | Foco en el componente input | -          | | ||||
| | blur   | blur the Input component, and hide the dropdown | - | | ||||
|  |  | |||
|  | @ -708,3 +708,4 @@ | |||
| | 方法名 | 说明 | 参数 | | ||||
| | ---- | ---- | ---- | | ||||
| | focus | 使 input 获取焦点 | - | | ||||
| | blur | 使 input 失去焦点,并隐藏下拉框 | - | | ||||
|  |  | |||
|  | @ -537,6 +537,11 @@ | |||
|         } | ||||
|       }, | ||||
| 
 | ||||
|       blur() { | ||||
|         this.visible = false; | ||||
|         this.$refs.reference.blur(); | ||||
|       }, | ||||
| 
 | ||||
|       handleBlur(event) { | ||||
|         this.$emit('blur', event); | ||||
|       }, | ||||
|  |  | |||
|  | @ -73,4 +73,9 @@ export declare class ElSelect extends ElementUIComponent { | |||
|    * Focus the Input component | ||||
|    */ | ||||
|   focus (): void | ||||
| 
 | ||||
|   /** | ||||
|    * Blur the Input component, and hide the dropdown | ||||
|    */ | ||||
|   blur (): void | ||||
| } | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue
	
	 Leopoldthecoder
						Leopoldthecoder