{"adoption": {"forks": 123, "observed_at": "2026-08-28T04:05:04.173141+00:00", "stars": 1564}, "canonical_url": "https://ross.abutalabs.com/products/focus-trap", "card": {"archived": false, "artifact_type": "library", "description": "Trap focus within a DOM node.", "domain": ["web-development", "frontend", "accessibility"], "enriched": true, "function": ["ui-components", "accessibility"], "health_score": 99, "homepage": "http://focus-trap.github.io/focus-trap/", "language": "JavaScript", "license": "MIT", "license_family": "permissive", "maturity": "stable", "member_repos": ["focus-trap/focus-trap"], "name": "focus-trap/focus-trap", "platform": ["browser"], "pushed_at": "2026-08-26T13:44:49+00:00", "repo": "focus-trap/focus-trap", "stars": 1564, "tags": ["focus-management", "keyboard-navigation", "modal-dialog", "vanilla-js", "a11y", "nodejs"], "topics": ["dependabot"], "urls": [], "use_cases": ["trap focus inside an accessible modal dialog", "keep Tab key cycling within a dropdown menu or drawer", "return focus to the trigger element when a dialog closes", "block clicks outside an open popover", "build accessible keyboard navigation for custom widgets"], "what_it_is": "A small vanilla JavaScript library that traps keyboard focus within a DOM node, cycling Tab/Shift+Tab among its focusable elements and blocking outside clicks. It is designed for building accessible modals and dialogs, with framework wrappers like focus-trap-react available.", "when_to_avoid": ["you use React and prefer a ready-made wrapper (use focus-trap-react instead)", "you need full dialog styling, animations, or overlay behavior (this only manages focus)", "your project does not involve keyboard/focus accessibility concerns"], "when_to_choose": ["you need WAI-ARIA-compliant focus containment for modals or menus in vanilla JS or any framework", "you want a small, modular library with pause/resume and nested trap support", "you need broad browser support and a UMD build"]}, "data_as_of": "2026-08-30T08:39:29.467469+00:00", "members": [{"path": "/products/focus-trap", "repo": "focus-trap/focus-trap", "role": "main", "score": 92}], "provenance": {"archived": {"kind": "observed", "observed_at": "2026-08-28T04:05:04.173141+00:00", "source": "github"}, "artifact_type": {"confidence": null, "enriched_at": "2026-08-30T04:00:13.281304+00:00", "kind": "inferred", "prompt_version": 1, "sources": [{"content_hash": "e6095d50006669b644e71fda4239b149cadbee56d097aa008f57eae809118327", "fetched_at": "2026-08-28T04:05:04.173141+00:00", "kind": "readme", "missing": false, "url": "https://github.com/focus-trap/focus-trap"}, {"content_hash": "219b2a68b482a67e82cbe275dada2af0be59673fdd351927922649dd5fbd0938", "fetched_at": "2026-08-29T11:29:06.077446+00:00", "kind": "homepage", "missing": false, "url": "http://focus-trap.github.io/focus-trap/"}, {"content_hash": "487f2dc766a8949a044f4e44bf65c7317159a849fc502f8968b60f712dfbd8ad", "fetched_at": "2026-08-29T11:29:06.087054+00:00", "kind": "registry_npm", "missing": false, "url": "https://registry.npmjs.org/focus-trap"}], "taxonomy_version": 1}, "description": {"kind": "observed", "observed_at": "2026-08-28T04:05:04.173141+00:00", "source": "github"}, "domain": {"confidence": null, "enriched_at": "2026-08-30T04:00:13.281304+00:00", "kind": "inferred", "prompt_version": 1, "sources": [{"content_hash": "e6095d50006669b644e71fda4239b149cadbee56d097aa008f57eae809118327", "fetched_at": "2026-08-28T04:05:04.173141+00:00", "kind": "readme", "missing": false, "url": "https://github.com/focus-trap/focus-trap"}, {"content_hash": "219b2a68b482a67e82cbe275dada2af0be59673fdd351927922649dd5fbd0938", "fetched_at": "2026-08-29T11:29:06.077446+00:00", "kind": "homepage", "missing": false, "url": "http://focus-trap.github.io/focus-trap/"}, {"content_hash": "487f2dc766a8949a044f4e44bf65c7317159a849fc502f8968b60f712dfbd8ad", "fetched_at": "2026-08-29T11:29:06.087054+00:00", "kind": "registry_npm", "missing": false, "url": "https://registry.npmjs.org/focus-trap"}], "taxonomy_version": 1}, "enriched": {"inputs": [], "kind": "computed", "method": "enrichment_status"}, "function": {"confidence": null, "enriched_at": "2026-08-30T04:00:13.281304+00:00", "kind": "inferred", "prompt_version": 1, "sources": [{"content_hash": "e6095d50006669b644e71fda4239b149cadbee56d097aa008f57eae809118327", "fetched_at": "2026-08-28T04:05:04.173141+00:00", "kind": "readme", "missing": false, "url": "https://github.com/focus-trap/focus-trap"}, {"content_hash": "219b2a68b482a67e82cbe275dada2af0be59673fdd351927922649dd5fbd0938", "fetched_at": "2026-08-29T11:29:06.077446+00:00", "kind": "homepage", "missing": false, "url": "http://focus-trap.github.io/focus-trap/"}, {"content_hash": "487f2dc766a8949a044f4e44bf65c7317159a849fc502f8968b60f712dfbd8ad", "fetched_at": "2026-08-29T11:29:06.087054+00:00", "kind": "registry_npm", "missing": false, "url": "https://registry.npmjs.org/focus-trap"}], "taxonomy_version": 1}, "health_score": {"inputs": ["days_since_push", "days_since_release", "archived"], "kind": "computed", "method": "health_v1"}, "homepage": {"kind": "observed", "observed_at": "2026-08-28T04:05:04.173141+00:00", "source": "github"}, "language": {"kind": "observed", "observed_at": "2026-08-28T04:05:04.173141+00:00", "source": "github"}, "license": {"kind": "observed", "observed_at": "2026-08-28T04:05:04.173141+00:00", "source": "github"}, "license_family": {"inputs": ["license"], "kind": "computed", "method": "license_family"}, "maturity": {"confidence": null, "enriched_at": "2026-08-30T04:00:13.281304+00:00", "kind": "inferred", "prompt_version": 1, "sources": [{"content_hash": "e6095d50006669b644e71fda4239b149cadbee56d097aa008f57eae809118327", "fetched_at": "2026-08-28T04:05:04.173141+00:00", "kind": "readme", "missing": false, "url": "https://github.com/focus-trap/focus-trap"}, {"content_hash": "219b2a68b482a67e82cbe275dada2af0be59673fdd351927922649dd5fbd0938", "fetched_at": "2026-08-29T11:29:06.077446+00:00", "kind": "homepage", "missing": false, "url": "http://focus-trap.github.io/focus-trap/"}, {"content_hash": "487f2dc766a8949a044f4e44bf65c7317159a849fc502f8968b60f712dfbd8ad", "fetched_at": "2026-08-29T11:29:06.087054+00:00", "kind": "registry_npm", "missing": false, "url": "https://registry.npmjs.org/focus-trap"}], "taxonomy_version": 1}, "member_repos": {"kind": "observed", "observed_at": "2026-08-28T04:05:04.173141+00:00", "source": "github"}, "name": {"kind": "observed", "observed_at": "2026-08-28T04:05:04.173141+00:00", "source": "github"}, "platform": {"confidence": null, "enriched_at": "2026-08-30T04:00:13.281304+00:00", "kind": "inferred", "prompt_version": 1, "sources": [{"content_hash": "e6095d50006669b644e71fda4239b149cadbee56d097aa008f57eae809118327", "fetched_at": "2026-08-28T04:05:04.173141+00:00", "kind": "readme", "missing": false, "url": "https://github.com/focus-trap/focus-trap"}, {"content_hash": "219b2a68b482a67e82cbe275dada2af0be59673fdd351927922649dd5fbd0938", "fetched_at": "2026-08-29T11:29:06.077446+00:00", "kind": "homepage", "missing": false, "url": "http://focus-trap.github.io/focus-trap/"}, {"content_hash": "487f2dc766a8949a044f4e44bf65c7317159a849fc502f8968b60f712dfbd8ad", "fetched_at": "2026-08-29T11:29:06.087054+00:00", "kind": "registry_npm", "missing": false, "url": "https://registry.npmjs.org/focus-trap"}], "taxonomy_version": 1}, "pushed_at": {"kind": "observed", "observed_at": "2026-08-28T04:05:04.173141+00:00", "source": "github"}, "repo": {"kind": "observed", "observed_at": "2026-08-28T04:05:04.173141+00:00", "source": "github"}, "stars": {"kind": "observed", "observed_at": "2026-08-28T04:05:04.173141+00:00", "source": "github"}, "tags": {"confidence": null, "enriched_at": "2026-08-30T04:00:13.281304+00:00", "kind": "inferred", "prompt_version": 1, "sources": [{"content_hash": "e6095d50006669b644e71fda4239b149cadbee56d097aa008f57eae809118327", "fetched_at": "2026-08-28T04:05:04.173141+00:00", "kind": "readme", "missing": false, "url": "https://github.com/focus-trap/focus-trap"}, {"content_hash": "219b2a68b482a67e82cbe275dada2af0be59673fdd351927922649dd5fbd0938", "fetched_at": "2026-08-29T11:29:06.077446+00:00", "kind": "homepage", "missing": false, "url": "http://focus-trap.github.io/focus-trap/"}, {"content_hash": "487f2dc766a8949a044f4e44bf65c7317159a849fc502f8968b60f712dfbd8ad", "fetched_at": "2026-08-29T11:29:06.087054+00:00", "kind": "registry_npm", "missing": false, "url": "https://registry.npmjs.org/focus-trap"}], "taxonomy_version": 1}, "topics": {"kind": "observed", "observed_at": "2026-08-28T04:05:04.173141+00:00", "source": "github"}, "urls": {"kind": "observed", "observed_at": "2026-08-28T04:05:04.173141+00:00", "source": "github"}, "use_cases": {"confidence": null, "enriched_at": "2026-08-30T04:00:13.281304+00:00", "kind": "inferred", "prompt_version": 1, "sources": [{"content_hash": "e6095d50006669b644e71fda4239b149cadbee56d097aa008f57eae809118327", "fetched_at": "2026-08-28T04:05:04.173141+00:00", "kind": "readme", "missing": false, "url": "https://github.com/focus-trap/focus-trap"}, {"content_hash": "219b2a68b482a67e82cbe275dada2af0be59673fdd351927922649dd5fbd0938", "fetched_at": "2026-08-29T11:29:06.077446+00:00", "kind": "homepage", "missing": false, "url": "http://focus-trap.github.io/focus-trap/"}, {"content_hash": "487f2dc766a8949a044f4e44bf65c7317159a849fc502f8968b60f712dfbd8ad", "fetched_at": "2026-08-29T11:29:06.087054+00:00", "kind": "registry_npm", "missing": false, "url": "https://registry.npmjs.org/focus-trap"}], "taxonomy_version": 1}, "what_it_is": {"confidence": null, "enriched_at": "2026-08-30T04:00:13.281304+00:00", "kind": "inferred", "prompt_version": 1, "sources": [{"content_hash": "e6095d50006669b644e71fda4239b149cadbee56d097aa008f57eae809118327", "fetched_at": "2026-08-28T04:05:04.173141+00:00", "kind": "readme", "missing": false, "url": "https://github.com/focus-trap/focus-trap"}, {"content_hash": "219b2a68b482a67e82cbe275dada2af0be59673fdd351927922649dd5fbd0938", "fetched_at": "2026-08-29T11:29:06.077446+00:00", "kind": "homepage", "missing": false, "url": "http://focus-trap.github.io/focus-trap/"}, {"content_hash": "487f2dc766a8949a044f4e44bf65c7317159a849fc502f8968b60f712dfbd8ad", "fetched_at": "2026-08-29T11:29:06.087054+00:00", "kind": "registry_npm", "missing": false, "url": "https://registry.npmjs.org/focus-trap"}], "taxonomy_version": 1}, "when_to_avoid": {"confidence": null, "enriched_at": "2026-08-30T04:00:13.281304+00:00", "kind": "inferred", "prompt_version": 1, "sources": [{"content_hash": "e6095d50006669b644e71fda4239b149cadbee56d097aa008f57eae809118327", "fetched_at": "2026-08-28T04:05:04.173141+00:00", "kind": "readme", "missing": false, "url": "https://github.com/focus-trap/focus-trap"}, {"content_hash": "219b2a68b482a67e82cbe275dada2af0be59673fdd351927922649dd5fbd0938", "fetched_at": "2026-08-29T11:29:06.077446+00:00", "kind": "homepage", "missing": false, "url": "http://focus-trap.github.io/focus-trap/"}, {"content_hash": "487f2dc766a8949a044f4e44bf65c7317159a849fc502f8968b60f712dfbd8ad", "fetched_at": "2026-08-29T11:29:06.087054+00:00", "kind": "registry_npm", "missing": false, "url": "https://registry.npmjs.org/focus-trap"}], "taxonomy_version": 1}, "when_to_choose": {"confidence": null, "enriched_at": "2026-08-30T04:00:13.281304+00:00", "kind": "inferred", "prompt_version": 1, "sources": [{"content_hash": "e6095d50006669b644e71fda4239b149cadbee56d097aa008f57eae809118327", "fetched_at": "2026-08-28T04:05:04.173141+00:00", "kind": "readme", "missing": false, "url": "https://github.com/focus-trap/focus-trap"}, {"content_hash": "219b2a68b482a67e82cbe275dada2af0be59673fdd351927922649dd5fbd0938", "fetched_at": "2026-08-29T11:29:06.077446+00:00", "kind": "homepage", "missing": false, "url": "http://focus-trap.github.io/focus-trap/"}, {"content_hash": "487f2dc766a8949a044f4e44bf65c7317159a849fc502f8968b60f712dfbd8ad", "fetched_at": "2026-08-29T11:29:06.087054+00:00", "kind": "registry_npm", "missing": false, "url": "https://registry.npmjs.org/focus-trap"}], "taxonomy_version": 1}}, "score": {"components": {"activity": 99, "longevity": 100, "rhythm": 77}, "computed_at": "2026-09-03T02:20:16.233290+00:00", "flags": [], "formula": "round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)", "inputs": {"age_days": 4035, "days_push": 7, "days_rel": 73, "gap_med": 33, "n_releases_24m": 16}, "score": 92, "version": 2}, "staleness": {"enrichment_outdated": false, "low_confidence": false, "scrape_days": 9, "stale_scrape": false}}