-
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 #39 from jeffnawroth/development
- Loading branch information
Showing
16 changed files
with
118 additions
and
84 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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
// sidepanelVisibilityListener.ts | ||
export function setupSidepanelVisibilityListener() { | ||
document.addEventListener('visibilitychange', () => { | ||
if (document.visibilityState === 'hidden') { | ||
// Send a message to the background process when the sidepanel is hidden or closed | ||
// @ts-expect-error missing types | ||
chrome.runtime.sendMessage({ type: 'SIDE_PANEL_CLOSED' }) | ||
} | ||
else if (document.visibilityState === 'visible') { | ||
// @ts-expect-error missing types | ||
chrome.runtime.sendMessage({ type: 'SIDE_PANEL_OPENED' }) | ||
} | ||
}) | ||
} |
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,12 +1,15 @@ | ||
import { createApp } from 'vue' | ||
|
||
import { setupApp } from '~/logic/common-setup' | ||
import { setupSidepanelVisibilityListener } from '~/logic/sidepanelVisibilityListener' | ||
import i18n from '~/plugins/i18n' | ||
import pinia from '~/plugins/pinia' | ||
import vuetify from '~/plugins/vuetify' | ||
|
||
import App from './Sidepanel.vue' | ||
|
||
setupSidepanelVisibilityListener() | ||
|
||
const app = createApp(App).use(vuetify).use(i18n).use(pinia) | ||
setupApp(app) | ||
app.mount('#app') |
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.