{"id":24135044,"url":"https://github.com/informatix8/access-modal","last_synced_at":"2025-07-16T05:39:20.624Z","repository":{"id":57118647,"uuid":"188442848","full_name":"informatix8/access-modal","owner":"informatix8","description":"A modal service with accessibility considerations","archived":false,"fork":false,"pushed_at":"2019-07-08T20:20:17.000Z","size":75,"stargazers_count":1,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-07-07T08:01:56.744Z","etag":null,"topics":["a11y","accessible","modal","vanilla-javascript"],"latest_commit_sha":null,"homepage":"https://access-modal.com/","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/informatix8.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-05-24T15:09:50.000Z","updated_at":"2019-07-22T17:04:59.000Z","dependencies_parsed_at":"2022-08-23T07:50:53.954Z","dependency_job_id":null,"html_url":"https://github.com/informatix8/access-modal","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/informatix8/access-modal","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/informatix8%2Faccess-modal","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/informatix8%2Faccess-modal/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/informatix8%2Faccess-modal/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/informatix8%2Faccess-modal/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/informatix8","download_url":"https://codeload.github.com/informatix8/access-modal/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/informatix8%2Faccess-modal/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265485180,"owners_count":23774443,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["a11y","accessible","modal","vanilla-javascript"],"created_at":"2025-01-12T01:19:16.147Z","updated_at":"2025-07-16T05:39:20.594Z","avatar_url":"https://github.com/informatix8.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Access Modal\n\nA modal service with accessibility considerations.\n\nExamples and the API are in the [documentation](https://access-modal.com)\n\n## Features\n- \u003ckbd\u003eEsc\u003c/kbd\u003e closes the modal\n- \u003ckbd\u003eShift\u003c/kbd\u003e + \u003ckbd\u003eTab\u003c/kbd\u003e brings focus to the browser chrome once modal is open, i.e. it is the first element in the DOM\n    - *Note:* tabbing should move focus within the DOM in a loop - the only way out to the browser is with **Shift+Tab** when you’re at the first focusable element in the DOM.\n- **Role** on the chrome must be `dialog` or `alertdialog` where `alertdialog` signifies more importance\n- **Role=document** on the modal content so screen readers begin reading it. Optional, but on by default.\n- Demonstrate **aria-labelledby** to point to the modal title bar\n- Demonstrate **aria-describedby** to tell the user where the beginning of the modal content is\n- Demonstrate a good **aria-label** and on the close button along with a good description linked with **aria-describedby**\n- Disallow focus to reach outside the modal content\n- Remember last focused element before opening and return focus there upon closing\n- Disallow screen readers to read outside the modal content - achieved with an all encompassing wrapper and applying **aria-hidden**\n- Set proper **tabindex** on the modal chrome and content: per W3C specification: the modal chrome (AKA backdrop or overlay) is inoperable, therefore tabindex=\"-1\"\n- Focus the modal content upon open\n\n### Other Features\n- Support for modal within a modal\n- User defined callbacks for pre/post open and close events\n\n## Usage\n\n### Install\n\n```shell\nnpm install @informatix8/access-modal --save-dev\n```\n\n### CDN\n\n```html\n\u003cscript src=\"https://unpkg.com/@informatix8/access-modal/dist/access-modal.all.umd.js\"\u003e\u003c/script\u003e\n```\n\n## Development\n\n```shell\nnpm run dev\n```\n\n## Build\n\n```shell\nnpm run build\n```\n\n## Release\n\n```shell\nnpm run build\ngit tag -a vX.Y.Z\ngit push origin master\ngit push origin --tags\nnpm publish --access=public .\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Finformatix8%2Faccess-modal","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Finformatix8%2Faccess-modal","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Finformatix8%2Faccess-modal/lists"}