{"id":15542071,"url":"https://github.com/lifeart/ember-click-outside-modifier","last_synced_at":"2025-04-23T17:11:08.797Z","repository":{"id":36939819,"uuid":"231980458","full_name":"lifeart/ember-click-outside-modifier","owner":"lifeart","description":"Ember modifier to react on clicks outside an element without stopping the event propagation","archived":false,"fork":false,"pushed_at":"2025-03-22T13:18:42.000Z","size":1066,"stargazers_count":16,"open_issues_count":2,"forks_count":3,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-23T01:37:28.064Z","etag":null,"topics":["ember","ember-addon","ember-modifier"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lifeart.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-01-05T21:48:14.000Z","updated_at":"2025-04-09T10:15:15.000Z","dependencies_parsed_at":"2024-06-18T22:54:23.584Z","dependency_job_id":null,"html_url":"https://github.com/lifeart/ember-click-outside-modifier","commit_stats":{"total_commits":65,"total_committers":9,"mean_commits":7.222222222222222,"dds":0.676923076923077,"last_synced_commit":"b343bd183dbdb74a539b6708b56a3eeb5ebcb80a"},"previous_names":[],"tags_count":11,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lifeart%2Fember-click-outside-modifier","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lifeart%2Fember-click-outside-modifier/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lifeart%2Fember-click-outside-modifier/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lifeart%2Fember-click-outside-modifier/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lifeart","download_url":"https://codeload.github.com/lifeart/ember-click-outside-modifier/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250477812,"owners_count":21437049,"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":["ember","ember-addon","ember-modifier"],"created_at":"2024-10-02T12:20:36.009Z","updated_at":"2025-04-23T17:11:08.792Z","avatar_url":"https://github.com/lifeart.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ember-click-outside-modifier\n\nEmber modifier to react on clicks outside an element without stopping the event propagation. Great for closing dialogues, menus among other things.\n\nIf you need more control on click outside - take a look at [ember-click-outside](https://github.com/zeppelin/ember-click-outside)\n\nInspired by [v-click-outside](https://github.com/ndelvalle/v-click-outside)\n\n## Compatibility\n\n* Ember.js v3.20 or above\n- Embroider or ember-auto-import v2 (this is [v2 addon](https://emberjs.github.io/rfcs/0507-embroider-v2-package-format.html))\n\n## Installation\n\n```\nember install ember-click-outside-modifier\n```\n\n## Usage\n\n```hbs\n\u003cdiv {{click-outside this.onClickOutside}}\u003e\u003c/div\u003e\n```\n\nYou can also provide specific events that you want to bind to with the `event` or `events` named arguments.\n\n```hbs\n\u003cdiv {{click-outside this.onClickOutside event='mouseup'}}\u003e\u003c/div\u003e\n\u003cdiv {{click-outside this.onClickOutside events=(array 'click' 'mouseup')}}\u003e\u003c/div\u003e\n```\n\n## Usage with Glint\n\n`ember-click-outside-modifier` is a glint enabled addon. Add this to your\n`types/global.d.ts` file:\n\n```ts\nimport '@glint/environment-ember-loose';\n\nimport type EmberClickOutsideRegistry from 'ember-click-outside-modifier/template-registry';\n\ndeclare module '@glint/environment-ember-loose/registry' {\n  export default interface Registry extends EmberClickOutsideRegistry, /* other addon registries */ {\n    // local entries\n  }\n}\n```\n\nFor the entire guide, please refer to [Using\nAddons](https://typed-ember.gitbook.io/glint/environments/ember/using-addons#using-glint-enabled-addons)\nsection on the glint handbook.\n\nTypes are made available through package.json `exports` field.\n\n## Usage with `\u003ctemplate\u003e` tag\n\nFor usage in `gts` or `gjs` files, modifier are exported from the index:\n\n```hbs\nimport { clickOutside } from 'ember-click-outside-modifier';\n\n\u003ctemplate\u003e\n  \u003cdiv {{clickOutside this.handleClickOutside}}\u003e\n    Lorem ipsum.\n  \u003c/div\u003e\n\u003c/template\u003e\n```\n\n## Contributing\n\nSee the [Contributing](CONTRIBUTING.md) guide for details.\n\n## License\n\nThis project is licensed under the [MIT License](LICENSE.md).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flifeart%2Fember-click-outside-modifier","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flifeart%2Fember-click-outside-modifier","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flifeart%2Fember-click-outside-modifier/lists"}