Add hardcoded exceptions to preventing enter keypresses in workflow form (#2674)
Fixes https://github.com/webrecorder/browsertrix/issues/2675
This commit is contained in:
		
							parent
							
								
									dde23426b2
								
							
						
					
					
						commit
						30e1224e8b
					
				| @ -2306,7 +2306,9 @@ https://archiveweb.page/images/${"logo.svg"}`} | ||||
| 
 | ||||
|     if ( | ||||
|       key === "Enter" && | ||||
|       this.progressState!.activeTab !== STEPS[STEPS.length - 1] | ||||
|       this.progressState!.activeTab !== STEPS[STEPS.length - 1] && | ||||
|       // Prevent places where Enter is valid from being stopped
 | ||||
|       !["TEXTAREA", "SL-TEXTAREA"].includes(el.tagName) | ||||
|     ) { | ||||
|       // Prevent submission by "Enter" keypress if not on last tab
 | ||||
|       event.preventDefault(); | ||||
|  | ||||
		Loading…
	
		Reference in New Issue
	
	Block a user