-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
π Merge pull request #3 from HiBixby/develop
π V0.1.0
- Loading branch information
Showing
21 changed files
with
270 additions
and
94 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
console.log("background.js loaded!"); | ||
|
||
chrome.alarms.onAlarm.addListener((alarm) => { | ||
console.log("Alarm!!!"); | ||
const id = alarm.name; | ||
chrome.storage.local.get(["todos"]).then((result) => { | ||
for (index in result.todos) { | ||
if (id === result.todos[index].id.toString()) { | ||
const message = result.todos[index].title; | ||
chrome.notifications.create(id.toString(), { | ||
type: "basic", | ||
iconUrl: "logo.png", | ||
title: "μ¨, μΌν΄", | ||
message: message ? message : "π³μ λͺ© μμπ³", | ||
priority: 2, | ||
}); | ||
if (result.todos[index].link !== null) { | ||
chrome.tabs.create({ | ||
url: result.todos[index].link, | ||
}); | ||
} | ||
} | ||
} | ||
}); | ||
}); |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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 +1 @@ | ||
<!doctype html><html lang=""><head><meta charset="utf-8"/><meta http-equiv="X-UA-Compatible" content="IE=edge"/><meta name="viewport" content="width=device-width,initial-scale=1"/><link rel="icon" href="favicon.ico"/><link rel="stylesheet" as="style" crossorigin href="https://cdn.jsdelivr.net/gh/orioncactus/pretendard@v1.3.6/dist/web/variable/pretendardvariable-dynamic-subset.css"/><link rel="stylesheet" href="main.css"/><title>whale-hae</title><script defer="defer" src="js/chunk-vendors.90ac33e3.js"></script><script defer="defer" src="js/app.347522dc.js"></script><link href="css/app.56f205ac.css" rel="stylesheet"></head><body><noscript><strong>We're sorry but whale-hae doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id="app"><div class="logo-container"><img src="logo.svg" class="logo__img"/><div class="logo__text">μ¨, μΌν΄</div></div></div></body></html> | ||
<!doctype html><html lang=""><head><meta charset="utf-8"/><meta http-equiv="X-UA-Compatible" content="IE=edge"/><meta name="viewport" content="width=device-width,initial-scale=1"/><link rel="icon" href="logo.png"/><link rel="stylesheet" as="style" crossorigin href="https://cdn.jsdelivr.net/gh/orioncactus/pretendard@v1.3.6/dist/web/variable/pretendardvariable-dynamic-subset.css"/><link rel="stylesheet" href="main.css"/><title>μ¨, μΌν΄</title><script defer="defer" src="js/chunk-vendors.71e5b51b.js"></script><script defer="defer" src="js/app.d1f8ce35.js"></script><link href="css/app.14708914.css" rel="stylesheet"></head><body><noscript><strong>We're sorry but whale-hae doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id="app"><div class="logo-container"><img src="logo.svg" class="logo__img"/><div class="logo__text">μ¨, μΌν΄</div></div></div></body></html> |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
6 changes: 3 additions & 3 deletions
6
docs/js/chunk-vendors.90ac33e3.js β docs/js/chunk-vendors.71e5b51b.js
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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 |
---|---|---|
@@ -0,0 +1,25 @@ | ||
console.log("background.js loaded!"); | ||
|
||
chrome.alarms.onAlarm.addListener((alarm) => { | ||
console.log("Alarm!!!"); | ||
const id = alarm.name; | ||
chrome.storage.local.get(["todos"]).then((result) => { | ||
for (index in result.todos) { | ||
if (id === result.todos[index].id.toString()) { | ||
const message = result.todos[index].title; | ||
chrome.notifications.create(id.toString(), { | ||
type: "basic", | ||
iconUrl: "logo.png", | ||
title: "μ¨, μΌν΄", | ||
message: message ? message : "π³μ λͺ© μμπ³", | ||
priority: 2, | ||
}); | ||
if (result.todos[index].link !== null) { | ||
chrome.tabs.create({ | ||
url: result.todos[index].link, | ||
}); | ||
} | ||
} | ||
} | ||
}); | ||
}); |
Oops, something went wrong.