Skip to content

Commit

Permalink
1.2.1
Browse files Browse the repository at this point in the history
- added: NotifyManager.isLoaded() : boolean
- added: NotifyManager.getWindow() : BrowserWindow
  • Loading branch information
fydne committed Jul 3, 2023
1 parent 33c1cad commit b7452d3
Show file tree
Hide file tree
Showing 5 changed files with 24 additions and 4 deletions.
8 changes: 8 additions & 0 deletions NotifyManager.js
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,14 @@ module.exports = class NotifyManager {
})();
}

isLoaded() {
return this.loaded;
}

getWindow() {
return this.win;
}

/**
* @param {Notify} notify Notification to show
*/
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ You can test the library with `npm run test` or `npm run test.reply`. And also s

#### Approximate result:
<a href="javascript:void(0)">
<img src="https://cdn.scpsl.store/another/kvrfintgaflc/image.png">
<img src="https://cdn.fydne.dev/another/kvrfintgaflc/image.png">
</a>

> You can change the appearance of the notification by adding your style when creating the NotifyManager
Expand Down
12 changes: 12 additions & 0 deletions files/index.d.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import { BrowserWindow } from "electron";

export class Notify {
/**
* @param title Title of notify
Expand Down Expand Up @@ -112,4 +114,14 @@ export class NotifyManager {
* @param notify Notification to destroy
*/
destroy(notify: Notify) : void;

/**
* Displays whether initialization has ended or not.
*/
isLoaded() : boolean;

/**
* Gets the BrowserWindow of notification manager.
*/
getWindow() : BrowserWindow;
};
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "notify-manager-electron",
"version": "1.2.0",
"version": "1.2.1",
"description": "Create beautiful and functional notifications on electron",
"main": "files/index.js",
"types": "files/index.d.ts",
Expand Down

0 comments on commit b7452d3

Please sign in to comment.