Skip to content
Snippets Groups Projects
Commit e9ee67e8 authored by Hangzhi Yu's avatar Hangzhi Yu
Browse files

Remove BroadcastChannel-related stuff

parent 2512fb7e
No related branches found
No related tags found
1 merge request!1161Resolve "[Service Worker] Safari does not support BroadcastChannel API"
Pipeline #109837 failed
......@@ -56,8 +56,6 @@
</v-app-bar>
<v-main>
<v-container>
<broadcast-channel-notification channel-name="cache-or-not" />
<message-box type="warning" v-if="$root.offline">
{{ $t("network_errors.offline_notification") }}
</message-box>
......@@ -198,7 +196,6 @@
</template>
<script>
import BroadcastChannelNotification from "./BroadcastChannelNotification.vue";
import AccountMenu from "./AccountMenu.vue";
import NotificationList from "../notifications/NotificationList.vue";
import CeleryProgressBottom from "../celery_progress/CeleryProgressBottom.vue";
......@@ -262,7 +259,6 @@ export default {
name: "App",
components: {
AccountMenu,
BroadcastChannelNotification,
NotificationList,
CeleryProgressBottom,
Splash,
......
<template>
<message-box :value="show" type="warning">
{{ $t("alerts.page_cached") }}
</message-box>
</template>
<script>
export default {
name: "BroadcastChannelNotification",
props: {
channelName: {
type: String,
required: true,
},
},
data() {
return {
show: false,
};
},
created() {
this.channel = new BroadcastChannel(this.channelName);
this.channel.onmessage = (event) => {
this.show = event.data === true;
};
},
destroyed() {
this.channel.close();
},
};
</script>
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment