@github/details-menu-element
Advanced tools
Comparing version 1.0.1 to 1.0.2
@@ -193,3 +193,9 @@ class DetailsMenuElement extends HTMLElement { | ||
const input = el.querySelector('input[type="radio"], input[type="checkbox"]'); | ||
el.setAttribute('aria-checked', (input instanceof HTMLInputElement ? input.checked : el === selected).toString()); | ||
let checkState = el === selected; | ||
if (input instanceof HTMLInputElement) { | ||
checkState = input.indeterminate ? 'mixed' : input.checked; | ||
} | ||
el.setAttribute('aria-checked', checkState.toString()); | ||
} | ||
@@ -196,0 +202,0 @@ } |
@@ -213,3 +213,9 @@ (function (global, factory) { | ||
const input = el.querySelector('input[type="radio"], input[type="checkbox"]'); | ||
el.setAttribute('aria-checked', (input instanceof HTMLInputElement ? input.checked : el === selected).toString()); | ||
let checkState = el === selected; | ||
if (input instanceof HTMLInputElement) { | ||
checkState = input.indeterminate ? 'mixed' : input.checked; | ||
} | ||
el.setAttribute('aria-checked', checkState.toString()); | ||
} | ||
@@ -216,0 +222,0 @@ } |
{ | ||
"name": "@github/details-menu-element", | ||
"version": "1.0.1", | ||
"version": "1.0.2", | ||
"description": "A menu opened with a <details> button.", | ||
@@ -28,10 +28,10 @@ "main": "dist/index.umd.js", | ||
"devDependencies": { | ||
"@babel/cli": "^7.4.4", | ||
"@babel/core": "^7.4.4", | ||
"@babel/cli": "^7.5.0", | ||
"@babel/core": "^7.5.0", | ||
"@babel/plugin-transform-modules-umd": "^7.2.0", | ||
"babel-preset-github": "^3.2.0", | ||
"chai": "^4.2.0", | ||
"eslint": "^5.16.0", | ||
"eslint-plugin-github": "^2.0.0", | ||
"flow-bin": "^0.98.1", | ||
"eslint": "^6.0.1", | ||
"eslint-plugin-github": "^3.0.0", | ||
"flow-bin": "^0.102.0", | ||
"karma": "^4.1.0", | ||
@@ -38,0 +38,0 @@ "karma-chai": "^0.1.0", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
26088
590