This is a follow up to [38065] to ensure that `wp.html.string()` always converts empty `alt` attributes to `alt=""` rather than returning HTML using empty attribute notation, like `alt`. This allows screen readers to ignore images with empty `alt` attributes, rather than reading out the URL string. Additionally this completely removes the logic in `wp.html.string()` for converting blank attributes to empty attribute notation since empty attribute notation is generally meant to denote a boolean value, e.g., `checked` == `checked="checked"`, which doesn't apply in this context because boolean attributes must be omitted in order to represent a `false` value. See: https://www.w3.org/TR/html5/infrastructure.html#boolean-attributes Props adamsilverstein, afineman, joemcgill. Fixes #36735. git-svn-id: https://develop.svn.wordpress.org/trunk@38116 602fd350-edb4-49c9-b593-d223f7449a82 |
||
---|---|---|
src | ||
tests | ||
tools/i18n | ||
.editorconfig | ||
.gitignore | ||
.jshintrc | ||
.travis.yml | ||
Gruntfile.js | ||
package.json | ||
phpunit.xml.dist | ||
wp-cli.yml | ||
wp-config-sample.php | ||
wp-tests-config-sample.php |