{"id":16595673,"url":"https://github.com/1000ch/x-notification","last_synced_at":"2025-06-25T13:07:00.614Z","repository":{"id":17773859,"uuid":"20640064","full_name":"1000ch/x-notification","owner":"1000ch","description":"Declarative Browser Notification as Web Components.","archived":false,"fork":false,"pushed_at":"2023-03-14T17:36:52.000Z","size":1916,"stargazers_count":37,"open_issues_count":4,"forks_count":4,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-06-18T04:06:22.296Z","etag":null,"topics":["notification","web-components"],"latest_commit_sha":null,"homepage":"https://1000ch.github.io/x-notification/","language":"HTML","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/1000ch.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":"license","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},"funding":{"github":"1000ch"}},"created_at":"2014-06-09T08:50:01.000Z","updated_at":"2021-12-20T14:34:27.000Z","dependencies_parsed_at":"2024-10-28T10:28:10.981Z","dependency_job_id":"58b276d8-ede4-43da-a90b-c8c93879fe59","html_url":"https://github.com/1000ch/x-notification","commit_stats":{"total_commits":135,"total_committers":3,"mean_commits":45.0,"dds":"0.12592592592592589","last_synced_commit":"26a695e5aa76a213d858c8ceeb51d0835a8230c8"},"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"purl":"pkg:github/1000ch/x-notification","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/1000ch%2Fx-notification","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/1000ch%2Fx-notification/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/1000ch%2Fx-notification/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/1000ch%2Fx-notification/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/1000ch","download_url":"https://codeload.github.com/1000ch/x-notification/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/1000ch%2Fx-notification/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":261879317,"owners_count":23223739,"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":["notification","web-components"],"created_at":"2024-10-11T23:51:14.540Z","updated_at":"2025-06-25T13:07:00.583Z","avatar_url":"https://github.com/1000ch.png","language":"HTML","funding_links":["https://github.com/sponsors/1000ch"],"categories":[],"sub_categories":[],"readme":"# x-notification ![GitHub Actions Status](https://github.com/1000ch/x-notification/workflows/test/badge.svg)\n\n\u003e Declarative Browser Notification as Web Components.\n\n## Install\n\nUsing [npm](https://www.npmjs.org/package/x-notification):\n\n```sh\n$ npm install x-notification\n```\n\n## Usage\n\nImport `XNotification` and register it.\n\n```html\n\u003cscript type=\"module\"\u003e\nimport XNotification from 'https://unpkg.com/x-notification';\n\ncustomElements.define('x-notification', XNotification);\n\u003c/script\u003e\n```\n\nPut `\u003cx-notification\u003e` tag.\n\n```html\n\u003cx-notification autoshow title=\"Notification Title\" delay=\"1000\" timeout=\"3000\" tag=\"tag\"\u003e\n  Notification body\n\u003c/x-notification\u003e\n```\n\nIf you set `autoshow` attribute, a notification will be shown automatically.\n\nTo show it manually, execute `show()` function.\n\n```js\ndocument.querySelector('x-notification').show();\n```\n\n## Attributes\n\n### `title=\u003cString\u003e`\n\n**This is a required option** . This will be set as notification title.\n\n### `dir=\u003cString\u003e`\n\nThe direction of the notification.\nIt can be **auto** , **ltr** , or **rtl** .\n\n### `lang=\u003cString\u003e`\n\nSpecify the language used within the notification.\n\n### `body=\u003cString\u003e`\n\nA string representing an extra content to display within the notification.\n\n### `tag=\u003cString\u003e`\n\nAn ID for a given notification that allows to retrieve, replace or remove it if necessary.\n\n### `icon=\u003cString\u003e`\n\nThe URL of an image to be used as an icon by the notification.\n\n### `delay=\u003cNumber\u003e`\n\nDelay for timing to show notification.\n\n### `timeout=\u003cNumber\u003e`\n\nTimeout for timing to close notification automatically.\n\n### `autoshow`\n\nIf you add this attribute, notification will be shown automatically.\n\n## License\n\n[MIT](https://1000ch.mit-license.org) © [Shogo Sensui](https://github.com/1000ch)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F1000ch%2Fx-notification","html_url":"https://awesome.ecosyste.ms/projects/github.com%2F1000ch%2Fx-notification","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F1000ch%2Fx-notification/lists"}