mirror of
				https://github.com/LadybirdBrowser/ladybird.git
				synced 2025-10-31 21:30:58 +00:00 
			
		
		
		
	LibWeb: Unify will_validate for form associated elements
We had the same implementation in quiet a few places. With this change we unify them in a single place
This commit is contained in:
		
							parent
							
								
									af88a43e9a
								
							
						
					
					
						commit
						8ab568bc76
					
				
				
				Notes:
				
					github-actions[bot]
				
				2025-08-29 18:28:58 +00:00 
				
			
			Author: https://github.com/tete17
Commit: 8ab568bc76
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/6024
Reviewed-by: https://github.com/tcl3 ✅
			
					 16 changed files with 11 additions and 75 deletions
				
			
		|  | @ -110,15 +110,4 @@ void HTMLOutputElement::clear_algorithm() | |||
|     string_replace_all({}); | ||||
| } | ||||
| 
 | ||||
| // https://html.spec.whatwg.org/multipage/form-control-infrastructure.html#dom-cva-willvalidate
 | ||||
| bool HTMLOutputElement::will_validate() | ||||
| { | ||||
|     // The willValidate attribute's getter must return true, if this element is a candidate for constraint validation,
 | ||||
|     // and false otherwise (i.e., false if any conditions are barring it from constraint validation).
 | ||||
|     // A submittable element is a candidate for constraint validation
 | ||||
|     // https://html.spec.whatwg.org/multipage/forms.html#category-submit
 | ||||
|     // Submittable elements: button, input, select, textarea, form-associated custom elements [but not output]
 | ||||
|     return false; | ||||
| } | ||||
| 
 | ||||
| } | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Tete17
						Tete17