{"_id":"@deeds_sa/edrs-notifications-package","_rev":"2-468aeb961cb5b63e9b19335ed0e81d9e","name":"@deeds_sa/edrs-notifications-package","dist-tags":{"latest":"0.0.2"},"versions":{"1.0.0":{"name":"@deeds_sa/edrs-notifications-package","version":"1.0.0","author":{"name":"Tsosane Mafisa"},"license":"MIT","_id":"@deeds_sa/edrs-notifications-package@1.0.0","maintainers":[{"name":"_taurux","email":"mafisa.developer@gmail.com"}],"dist":{"shasum":"343c3536144086bf4d2541a6fdcc0eee16d1ea6e","tarball":"https://registry.npmjs.org/@deeds_sa/edrs-notifications-package/-/edrs-notifications-package-1.0.0.tgz","fileCount":10,"integrity":"sha512-C4pu7RNGJmY9zYTLV1zWWwjfMRoT6Zblc80unQF9WDLNY4IfEgXZBw1Ikaa+Si2AKJL/a7Skm9TCflaBwSpBDw==","signatures":[{"sig":"MEYCIQCzr7PoF9iX0LBlC3V4RHo4z89GbezuwxOP9tvY2M2MWAIhAIlcjm5A4KzT+nZEHzrutCxWEABKTM22L3apGC5C/LOk","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":24537},"main":"bundles/notification-lib.umd.js","es2015":"fesm2015/notification-lib.js","module":"fesm2022/deeds_sa-edrs-notifications-package.mjs","exports":{".":{"types":"./index.d.ts","default":"./fesm2022/deeds_sa-edrs-notifications-package.mjs"},"./package.json":{"default":"./package.json"}},"gitHead":"74004deb50b139304d450ea2c83b730d033ee83c","typings":"index.d.ts","_npmUser":{"name":"_taurux","actor":{"name":"_taurux","type":"user","email":"mafisa.developer@gmail.com"},"email":"mafisa.developer@gmail.com"},"_npmVersion":"10.9.2","description":"Angular notification library with icon, dialog, and service","directories":{},"sideEffects":false,"_nodeVersion":"22.13.1","dependencies":{"tslib":"^2.3.0"},"_hasShrinkwrap":false,"peerDependencies":{"rxjs":"^7.0.0","@angular/core":"^14.0.0","@angular/common":"^14.0.0","@angular/material":"^14.0.0"},"_npmOperationalInternal":{"tmp":"tmp/edrs-notifications-package_1.0.0_1750187131151_0.4101814954456038","host":"s3://npm-registry-packages-npm-production"}},"0.0.2":{"name":"@deeds_sa/edrs-notifications-package","version":"0.0.2","description":"Angular notification library with icon, dialog, and service","author":{"name":"Tsosane Mafisa"},"license":"MIT","repository":{"type":"git","url":"git+ssh://git@bitbucket.org/your-bitbucket-username/notification-lib.git"},"peerDependencies":{"@angular/common":"^14.0.0","@angular/core":"^14.0.0","@angular/material":"^14.0.0","rxjs":"^7.0.0"},"devDependencies":{"@angular/cli":"^14.0.0","@angular/compiler":"^14.0.0","@angular/compiler-cli":"^14.0.0","ng-packagr":"^14.0.0"},"main":"bundles/notification-lib.umd.js","module":"fesm2015/notification-lib.js","es2015":"fesm2015/notification-lib.js","typings":"notification-lib.d.ts","sideEffects":false,"ngPackage":{"lib":{"entryFile":"src/public-api.ts"}},"_id":"@deeds_sa/edrs-notifications-package@0.0.2","gitHead":"00ac2324ead4467f7c5eea45ce090fcbb24c9809","bugs":{"url":"https://bitbucket.org/your-bitbucket-username/notification-lib/issues"},"homepage":"https://bitbucket.org/your-bitbucket-username/notification-lib#readme","_nodeVersion":"22.13.1","_npmVersion":"10.9.2","dist":{"integrity":"sha512-fp0Vcac5b7rckaXY08IGAAx/fN0HGsA1a17VaX7xxg+tL6S7cNKfIGk1AHi/9kwMEWiKvy52JzB/7/7c3KCpkw==","shasum":"7755fe713d2a955f7c5ce3662c32eb0ce9c4959e","tarball":"https://registry.npmjs.org/@deeds_sa/edrs-notifications-package/-/edrs-notifications-package-0.0.2.tgz","fileCount":17,"unpackedSize":12354,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEYCIQClukrPFNHRV46fEaW09APfOecfvsCKGSiQYbXJZkpCUAIhAJA2PTdlQiboNPmjxkKzkg0XpLnvGFhiJ+gY30NCZXss"}]},"_npmUser":{"name":"_taurux","email":"mafisa.developer@gmail.com","actor":{"name":"_taurux","email":"mafisa.developer@gmail.com","type":"user"}},"directories":{},"maintainers":[{"name":"_taurux","email":"mafisa.developer@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/edrs-notifications-package_0.0.2_1750878476153_0.3399505557177529"},"_hasShrinkwrap":false}},"time":{"created":"2025-06-17T19:05:31.046Z","modified":"2025-06-25T19:07:56.561Z","1.0.0":"2025-06-17T19:05:31.343Z","0.0.2":"2025-06-25T19:07:56.360Z"},"author":{"name":"Tsosane Mafisa"},"license":"MIT","description":"Angular notification library with icon, dialog, and service","maintainers":[{"name":"_taurux","email":"mafisa.developer@gmail.com"}],"readme":"# EDRS Notifications Package\n\nThis Angular library provides a reusable notification component and service that supports receiving notifications from multiple sources, including the User Authentication Manager (UAM) and the eDRS application.\n\n## Features\n\n- Notification icon with unread count badge.\n- Notification dialog displaying a list of notifications.\n- Supports multiple notification sources via polling.\n- Composite service to merge notifications from different sources.\n- Configurable polling intervals and sources.\n\n## Installation\n\nInstall the package from npm:\n\n```bash\nnpm install @deeds_sa/edrs-notifications-package\n```\n\n## Usage\n\nImport the `NotificationLibModule` in your Angular application's root module:\n\n```typescript\nimport { HttpClientModule, HttpClient } from '@angular/common/http';\nimport { NgModule } from '@angular/core';\nimport { NotificationLibModule, NotificationUamService, NotificationEdrsService } from '@deeds_sa/edrs-notifications-package';\n\n@NgModule({\n  imports: [\n    HttpClientModule,\n    NotificationLibModule.forRoot([\n      new NotificationUamService(httpClient),\n      new NotificationEdrsService(httpClient)\n    ]),\n    // other imports\n  ],\n  bootstrap: [AppComponent]\n})\nexport class AppModule {\n  constructor(private httpClient: HttpClient) {}\n}\n```\n\n## Components\n\n- `NotificationIconComponent`: Displays the notification bell icon with unread count.\n- `NotificationsComponent`: Dialog component showing the list of notifications.\n\n## Notification Services\n\n- `NotificationUamService`: Fetches notifications from the User Authentication Manager (UAM) backend using polling.\n- `NotificationEdrsService`: Fetches notifications from the eDRS backend using polling.\n- `NotificationCompositeService`: Internally used to merge notifications from multiple sources.\n\n## Configuration Options\n\n- Polling interval is set to 15 seconds by default in each service; you can modify this in the service code if needed.\n- To add more notification sources, implement the `NotificationService` abstract class and provide your implementation in the `forRoot` method.\n\n## Extending the Library\n\nYou can extend the library by creating new notification services for other sources and adding them to the providers array in `forRoot`.\n\n## Notes\n\n- The library uses polling instead of WebSockets for notification fetching.\n- Ensure your backend APIs conform to the expected notification data structure.\n\nThis documentation should enable host applications to integrate and configure the notifications package effectively.\n","readmeFilename":"README.md","homepage":"https://bitbucket.org/your-bitbucket-username/notification-lib#readme","repository":{"type":"git","url":"git+ssh://git@bitbucket.org/your-bitbucket-username/notification-lib.git"},"bugs":{"url":"https://bitbucket.org/your-bitbucket-username/notification-lib/issues"}}