Skip to content

Conversation

@coliff
Copy link
Contributor

@coliff coliff commented Jan 5, 2026

Copilot AI review requested due to automatic review settings January 5, 2026 14:54
@github-actions
Copy link
Contributor

github-actions bot commented Jan 5, 2026

Thanks for the PR!

This section of the codebase is owned by @madskristensen and @hyperupcall - if they write a comment saying "LGTM" then it will be merged.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the HTMLHint schema to allow two rules (attr-lowercase and attr-value-no-duplication) to accept either boolean or array types, matching their actual behavior in HTMLHint.

  • Changed attr-lowercase and attr-value-no-duplication from boolean-only to accepting boolean or array types using anyOf
  • This aligns the schema with HTMLHint's actual API where these rules can accept arrays of attribute names
Comments suppressed due to low confidence (1)

src/schemas/json/htmlhint.json:43

  • The array type definition is incomplete. According to the HTMLHint documentation, the array should contain attribute names as strings. Add an items schema to specify that array elements should be strings.
    "attr-value-not-empty": {
      "description": "Attribute must set value.",
      "type": "boolean",
      "default": false

Comment on lines +12 to 15
"anyOf": [{ "type": "boolean" }, { "type": "array" }],
"default": false
},
"attr-no-duplication": {
Copy link

Copilot AI Jan 5, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The array type definition is incomplete. According to the HTMLHint documentation, the array should contain attribute names as strings. Add an items schema to specify that array elements should be strings.

Copilot uses AI. Check for mistakes.
Comment on lines +12 to 15
"anyOf": [{ "type": "boolean" }, { "type": "array" }],
"default": false
},
"attr-no-duplication": {
Copy link

Copilot AI Jan 5, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Test coverage should be added for the new array type functionality. The existing test file only covers boolean values. Add test cases showing the array usage for both attr-lowercase and attr-value-no-duplication rules.

Copilot uses AI. Check for mistakes.
@madskristensen
Copy link
Contributor

@coliff is this ready to merge?

@coliff
Copy link
Contributor Author

coliff commented Jan 7, 2026

Yes, I believe so. Thanks

@madskristensen madskristensen merged commit cbd6303 into SchemaStore:master Jan 8, 2026
5 checks passed
@madskristensen
Copy link
Contributor

Thanks

@coliff coliff deleted the patch-1 branch January 8, 2026 16:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants