sforkowany z mirror/soapbox
				
			AutosuggestInput/AutosuggestTextarea: fix RTL detection with placeholder
							rodzic
							
								
									c4270a0512
								
							
						
					
					
						commit
						bedd181f4c
					
				|  | @ -269,7 +269,7 @@ export default class AutosuggestInput extends ImmutablePureComponent<IAutosugges | |||
|     const visible = !suggestionsHidden && (!suggestions.isEmpty() || (menu && value)); | ||||
| 
 | ||||
|     // TODO: convert to functional component and use `useLocale()` hook instead of checking placeholder text.
 | ||||
|     if (isRtl(value) || (placeholder && isRtl(placeholder))) { | ||||
|     if (isRtl(value) || (placeholder && isRtl(placeholder) && !value)) { | ||||
|       style.direction = 'rtl'; | ||||
|     } | ||||
| 
 | ||||
|  |  | |||
|  | @ -230,7 +230,7 @@ class AutosuggestTextarea extends ImmutablePureComponent<IAutosuggesteTextarea> | |||
|     const style = { direction: 'ltr', minRows: 10 }; | ||||
| 
 | ||||
|     // TODO: convert to functional component and use `useLocale()` hook instead of checking placeholder text.
 | ||||
|     if (isRtl(value) || (placeholder && isRtl(placeholder))) { | ||||
|     if (isRtl(value) || (placeholder && isRtl(placeholder) && !value)) { | ||||
|       style.direction = 'rtl'; | ||||
|     } | ||||
| 
 | ||||
|  |  | |||
		Ładowanie…
	
		Reference in New Issue
	
	 Alex Gleason
						Alex Gleason