Security News
Maven Central Adds Sigstore Signature Validation
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.
makeup-keyboard-trap
Advanced tools
A vanilla JavaScript port of jquery-keyboard-trap.
This module restricts keyboard tabindex to a single subtree in the DOM. This behaviour is useful when implementing a modal interface (e.g. a modal dialog).
It will ignore programmatically focusable items with a tabindex of -1
.
This module is still in an experimental state, until it reaches v1.0.0 you must consider all minor releases as breaking changes. Patch releases may introduce new features, but will be backwards compatible.
const keyboardTrap = require('makeup-keyboard-trap');
// trap an element
keyboardTrap.trap(document.querySelector('el'));
// untrap the current trapped element
keyboardTrap.untrap();
// via npm
npm install makeup-keyboard-trap
// via yarn
yarn add makeup-keyboard-trap
npm start
npm test
npm run lint
npm run fix
npm run build
npm run clean
The following hooks exist, and do not need to be invoked manually:
npm prepublish
cleans, lints, tests and builds on every npm publish
commandpre-commit
cleans, lints, tests and builds on every git commit
commandEach test run will generate the following reports:
/reports/coverage
contains Istanbul code coverage report/reports/html
contains HTML test reporthttps://travis-ci.org/makeup-js/makeup-keyboard-trap
FAQs
Restricts keyboard tabindex to a single subtree in the DOM
The npm package makeup-keyboard-trap receives a total of 48 weekly downloads. As such, makeup-keyboard-trap popularity was classified as not popular.
We found that makeup-keyboard-trap demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.
Security News
CISOs are racing to adopt AI for cybersecurity, but hurdles in budgets and governance may leave some falling behind in the fight against cyber threats.
Research
Security News
Socket researchers uncovered a backdoored typosquat of BoltDB in the Go ecosystem, exploiting Go Module Proxy caching to persist undetected for years.