Merge remote-tracking branch 'remotes/upstream/master'

This commit is contained in:
Toni Barth 2024-10-11 15:43:38 +02:00
commit f643d12cd6
2 changed files with 11 additions and 15 deletions

View file

@ -65,15 +65,10 @@ export default {
},
methods: {
imageLoaded() {
var aspectRatio = 1.25
if (this.$refs.wrapper) {
aspectRatio = this.$refs.wrapper.clientHeight / this.$refs.wrapper.clientWidth
}
if (this.$refs.img) {
var { naturalWidth, naturalHeight } = this.$refs.img
var imgAr = naturalHeight / naturalWidth
var arDiff = Math.abs(imgAr - aspectRatio)
if (arDiff > 0.15) {
if (imgAr < 0.5 || imgAr > 2) {
this.showCoverBg = true
} else {
this.showCoverBg = false

View file

@ -93,17 +93,18 @@ export default {
},
computed: {
contextMenuItems() {
if (!this.userIsAdminOrUp) return []
return [
{
const menuItems = []
if (this.userIsAdminOrUp) {
menuItems.push({
text: 'Quick match all episodes',
action: 'quick-match-episodes'
},
{
text: this.allEpisodesFinished ? this.$strings.MessageMarkAllEpisodesNotFinished : this.$strings.MessageMarkAllEpisodesFinished,
action: 'batch-mark-as-finished'
}
]
})
}
menuItems.push({
text: this.allEpisodesFinished ? this.$strings.MessageMarkAllEpisodesNotFinished : this.$strings.MessageMarkAllEpisodesFinished,
action: 'batch-mark-as-finished'
})
return menuItems
},
sortItems() {
return [