Skip to content

Commit

Permalink
fixes deprecated Github favicons #1300
Browse files Browse the repository at this point in the history
  • Loading branch information
austintoddj committed Jun 22, 2023
1 parent d5a3614 commit 75edfa2
Showing 1 changed file with 18 additions and 19 deletions.
37 changes: 18 additions & 19 deletions resources/js/views/PostStats.vue
Original file line number Diff line number Diff line change
Expand Up @@ -225,19 +225,17 @@
<div class="mr-auto">
<div v-if="host === trans.other">
<p class="mb-0 py-1">
<img
:src="getDefaultFavicon(host)"
:style="
settings.user.dark_mode === true
? {
filter: 'invert(100%)',
}
: ''
<i
class="bi bi-globe mr-1"
:style="settings.user.dark_mode === true
? {
filter: 'invert(100%)',
}
: ''
"
:alt="host"
width="15"
height="15"
class="mr-1"
height="15"
/>
<a
v-tooltip="{
Expand Down Expand Up @@ -268,15 +266,20 @@
</div>
<div v-else>
<p class="mb-0 py-1">
<img
:src="getDefaultFavicon(host)"
<i
class="bi bi-globe mr-1"
:style="settings.user.dark_mode === true
? {
filter: 'invert(100%)',
}
: ''
"
:alt="host"
width="15"
height="15"
class="mr-1"
/>
<a
:href="'http://' + host"
:href="'https://' + host"
class="text-decoration-none text-primary"
target="_blank"
>
Expand Down Expand Up @@ -408,11 +411,7 @@ export default {
this.$router.push({ name: 'stats' });
NProgress.done();
});
},
getDefaultFavicon(host) {
return `https://favicons.githubusercontent.com/${host}`;
},
}
},
};
</script>

0 comments on commit 75edfa2

Please sign in to comment.