We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 35e2fc9 + db0c767 commit 1f5a81cCopy full SHA for 1f5a81c
1 file changed
src/components/NcAvatar/NcAvatar.vue
@@ -617,7 +617,7 @@ export default {
617
* @return {string}
618
*/
619
avatarUrlGenerator(user, size) {
620
- const darkTheme = window.getComputedStyle(this.$el)
+ const darkTheme = window.getComputedStyle(document.body)
621
.getPropertyValue('--background-invert-if-dark') === 'invert(100%)'
622
let url = '/avatar/{user}/{size}' + (darkTheme ? '/dark' : '')
623
if (this.isGuest) {
0 commit comments