Skip to content

Fix label/ID detection — support JSX expression literals, identifier refs and multi-id aria values #150

@sidhsharma1992

Description

@sidhsharma1992

Corrects id/identifier handling and improves aria-labelledby/aria-describedby detection so rules correctly recognize labels referenced via:
quoted literals: id="x"
JSX expression-literals: id={"x"} / aria-labelledby={"x"}
Identifier expressions: id={someId} / aria-labelledby={someId}
Space-separated aria lists: aria-labelledby="a b" (now checks each id independently)

Address below TO DO

'

<Label id={"my-label"}>Best pet<Combobox aria-labelledby={"my-label"} placeholder="Select an animal" {...props}>{"Cat"}
', // TODO: modify regular expression

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions