💅 noLabelWithoutControl
should allow labeling button
tags
#4511
Labels
A-Linter
Area: linter
good first issue
Good for newcomers
L-JavaScript
Language: JavaScript and super languages
S-Bug-confirmed
Status: report has been confirmed as a valid bug
Environment information
Rule name
noLabelWithoutControl
Playground link
https://biomejs.dev/playground/?code=ZQB4AHAAbwByAHQAIABjAG8AbgBzAHQAIABNAGUAbgB1ACAAPQAgACgAKQAgAD0APgAgAHsACgAgACAALwAvACAAYwBvAG4AcwB0ACAAaQBzAEgAeQBkAHIAYQB0AGUAZAAgAD0AIAB1AHMAZQBIAHkAZAByAGEAdABpAG8AbgBDAG8AbgB0AGUAeAB0ACgAKQA7AAoAIAAgAGMAbwBuAHMAdAAgAGkAcwBEAGUAcwBrAHQAbwBwACAAPQAgAHUAcwBlAE0AZQBkAGkAYQBRAHUAZQByAHkAKAAnACgAbQBpAG4ALQB3AGkAZAB0AGgAOgAgADEANAA0ADAAcAB4ACkAJwApADsACgAgACAAYwBvAG4AcwB0ACAAWwBpAHMATwBwAGUAbgBNAGUAbgB1ACwAIABzAGUAdABJAHMATwBwAGUAbgBNAGUAbgB1AF0AIAA9ACAAdQBzAGUAUQB1AGUAcgB5AFMAdABhAHQAZQAoAAoAIAAgACAAIAAnAGkAcwBPAHAAZQBuAE0AZQBuAHUAJwAsAAoAIAAgACAAIABwAGEAcgBzAGUAQQBzAEIAbwBvAGwAZQBhAG4ALgB3AGkAdABoAEQAZQBmAGEAdQBsAHQAKABmAGEAbABzAGUAKQAsAAoAIAAgACkAOwAKAAoAIAAgAGMAbwBuAHMAdAAgAGMAbABvAHMAZQBNAGUAbgB1ACAAPQAgAHUAcwBlAEMAYQBsAGwAYgBhAGMAawAoACgAKQAgAD0APgAgAHMAZQB0AEkAcwBPAHAAZQBuAE0AZQBuAHUAKABmAGEAbABzAGUAKQAsACAAWwBzAGUAdABJAHMATwBwAGUAbgBNAGUAbgB1AF0AKQA7AAoACgAgACAALwAvACAAZABpAHMAYQBiAGwAZQAgAHMAYwByAG8Ab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iAGUAbAAKACAAIAAgACAAIAAgACAAIAAgACAAaAB0AG0AbABGAG8AcgA9ACIAYgB1AHIAZwBlAHIAIgAKACAAIAAgACAAIAAgACAAIAAgACAAYwBsAGEAcwBzAE4AYQBtAGUAPQAiAGEAYgBzAG8AbAB1AHQAZQAgAHoALQAwACAAcwBpAHoAZQAtAGYAdQBsAGwAIABiAGcALQBiAGwAYQBjAGsALwA1ADAAIABtAGQAOgBoAGkAZABkAGUAbgAiAAoAIAAgACAAIAAgACAAIAAgAC8APgAKACAAIAAgACAAIAAgADwALwBkAGkAdgA%2BAAoAIAAgACAAIAA8AC8APgAKACAAIAApADsACgB9ADsACgA%3D
Expected result
Label should not have been highlighted, as this is not against W3C rules:
label works the same way on the button
https://validator.w3.org/nu/#textarea
Code of Conduct
The text was updated successfully, but these errors were encountered: