Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

dom-accessibility-api

Package Overview
Dependencies
Maintainers
1
Versions
34
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

dom-accessibility-api - npm Package Versions

134

0.5.11

Diff

Changelog

Source

0.5.11

Patch Changes

eps1lon
published 0.5.10 •

Changelog

Source

0.5.10

Patch Changes

  • #770 7066180 Thanks @eps1lon! - Allow computing name for inaccessible elements

    This is mainly targetted at integration with @testing-library/dom. But it can also be used as a general performance boost when used in a JSDOM environment. The rationale is that most elements are part of the a11y tree. In those cases computing a11y tree exclusion is wasted. Since it's expensive, we can disable it. The recommendation is to only ignore a11y tree inclusion locally and specifically enable it for the tests where you do know that a11y tree inclusion will play a role.

eps1lon
published 0.5.9 •

Changelog

Source

0.5.9

Patch Changes

  • #762 b3e4a17 Thanks @eps1lon! - Compute name from author for menu role.

    Previously we wouldn't compute any name for menu to pass some web-platform-tests that covered an exotic use case. Now we correctly respect name from author (e.g. aria-label or aria-labelledby).

eps1lon
published 0.5.8 •

Changelog

Source

0.5.8

Patch Changes

  • #343 3d755c2 Thanks @eps1lon! - Add isInaccessible and isSubtreeInaccessible.

    isInaccessible implements https://www.w3.org/TR/wai-aria-1.2/#tree_exclusion. isSubtreeInaccessible can be used to inject a memoized version of that function into isInaccessible.

eps1lon
published 0.5.7 •

Changelog

Source

0.5.7

Patch Changes

eps1lon
published 0.5.6 •

Changelog

Source

0.5.6

Patch Changes

  • #666 26ee73d Thanks @eps1lon! - Consider <label /> when computing the accessible name of <output />

    Given

    <label for="outputid">Output Label</label> <output id="outputid"></output>
    

    Previously the accessible name of the <output /> would ignore the <label />. However, an <output /> is labelable and therefore the accessible name is now computed using <label /> elements if they exists. In this example the accessible name is "Output Label".

eps1lon
published 0.5.5 •

Changelog

Source

0.5.5

Patch Changes

  • #627 0485441 Thanks @eps1lon! - Ensure certain babel helpers aren't required

    Source:

    -const [item] = list;
    +const item = list[0];
    

    Transpiled:

    -var _trim$split = list.trim().split(" "),
    -_trim$split2 = _slicedToArray(_trim$split, 1),
    -item = _trim$split2[0]
    +var item = list[0];
    
  • #629 383bdb6 Thanks @eps1lon! - Use label attribute for naming of <optgroup> elements.

    Given

    <select>
    	<optgroup label="foo">
    		<option value="1">bar</option>
    	</optgroup>
    </select>
    

    Previously the <optgroup /> would not have an accessible name. Though 2D in accname 1.2 could be interpreted to use the label attribute:

    Otherwise, if the current node's native markup provides an attribute (e.g. title) or element (e.g. HTML label) that defines a text alternative, return that alternative [...]

    This was confirmed in NVDA + FireFox.

eps1lon
published 0.5.4 •

Changelog

Source

0.5.4

Patch Changes

  • 3866289 #442 Thanks @geoffrich! - Correctly determine accessible name when element contains a slot.

    Previously, computing the accessible name would only examine child nodes. However, content placed in a slot is is an assigned node, not a child node.

    If you have a custom element custom-button with a slot:

    <button><slot></slot></button>
    
    <!-- accname of inner <button> is 'Custom name' (previously '') -->
    <custom-button>Custom name</custom-button>
    

    If you have a custom element custom-button-default with default content in the slot:

    <button><slot>Default name</slot></button>
    
    <!-- accname of inner <button> is 'Custom name' (previously 'Default name') -->
    <custom-button-default>Custom name</custom-button-default>
    
    <!-- accname of inner <button> is 'Default name' (previously 'Default name') -->
    <custom-button-default></custom-button-default>
    

    This is not currently defined in the accname spec but reflects current browser behavior.

eps1lon
published 0.5.3 •

Changelog

Source

0.5.3

Patch Changes

  • 76e8f93 #430 Thanks @ckundo! - Maintain img role for img with missing alt attribute.

    Previously <img /> would be treated the same as <img alt />. <img /> is now treated as role="img" as specified.

  • 96d4438 #436 Thanks @eps1lon! - Resolve presentational role conflicts when global WAI-ARIA states or properties (ARIA attributes) are used.

    <img alt="" /> used to have no role. By spec it should have role="presentation" with no ARIA attributes or role="img" otherwise.

eps1lon
published 0.5.2 •

Changelog

Source

0.5.2

Patch Changes

  • 03273b7 #406 Thanks @eps1lon! - Fix various issues for input types submit, reset and image

    Prefer input value when type is reset or submit:

    <input type="submit" value="Submit values">
    -// accessible name: "Submit"
    +// accessible name: "Submit values"
    <input type="reset" value="Reset form">
    -// accessible name: "Reset"
    +// accessible name: "Reset form"
    

    For input type image consider alt attribute or fall back to "Submit query".

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc