-
Notifications
You must be signed in to change notification settings - Fork 719
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: Release v0.2.3-beta.0 (#1689)
- Loading branch information
Showing
85 changed files
with
2,318 additions
and
595 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,21 @@ | ||
import path from "node:path" | ||
import { fileURLToPath } from "node:url" | ||
|
||
import { isMacOS } from "./env" | ||
import { isMacOS, isWindows } from "./env" | ||
|
||
const __dirname = fileURLToPath(new URL(".", import.meta.url)) | ||
const iconMap = { | ||
prod: path.join(__dirname, "../../resources/icon.png"), | ||
dev: path.join(__dirname, "../../static/icon-dev.png"), | ||
} | ||
export const getIconPath = () => iconMap[process.env.NODE_ENV === "development" ? "dev" : "prod"] | ||
export const getTrayIconPath = () => | ||
isMacOS ? path.join(__dirname, "../../resources/tray-icon.png") : getIconPath() | ||
export const getTrayIconPath = () => { | ||
if (isMacOS) { | ||
return path.join(__dirname, "../../resources/tray-icon.png") | ||
} | ||
if (isWindows) { | ||
// https://www.electronjs.org/docs/latest/api/tray#:~:text=Windows,best%20visual%20effects. | ||
return path.join(__dirname, "../../resources/icon.ico") | ||
} | ||
return getIconPath() | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.