forked from AkkomaGang/akkoma-fe
Clean up
This commit is contained in:
parent
3366c915e9
commit
4c2a7aabe5
|
@ -133,11 +133,6 @@
|
||||||
animation: 0.1s cubic-bezier(0.7, 0, 1, 0.6) media-fadein;
|
animation: 0.1s cubic-bezier(0.7, 0, 1, 0.6) media-fadein;
|
||||||
}
|
}
|
||||||
|
|
||||||
//.modal-image {
|
|
||||||
// height: 90vh;
|
|
||||||
// width: 100%;
|
|
||||||
//}
|
|
||||||
|
|
||||||
.modal-view-button-arrow {
|
.modal-view-button-arrow {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
display: block;
|
display: block;
|
||||||
|
|
|
@ -19,18 +19,18 @@ const mediaViewer = {
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
actions: {
|
actions: {
|
||||||
setMedia ({ commit, dispatch }, attachments) {
|
setMedia ({ commit }, attachments) {
|
||||||
const media = attachments.filter(attachment => {
|
const media = attachments.filter(attachment => {
|
||||||
const type = fileTypeService.fileType(attachment.mimetype)
|
const type = fileTypeService.fileType(attachment.mimetype)
|
||||||
return type === 'image' || type === 'video' || type === 'audio'
|
return type === 'image' || type === 'video' || type === 'audio'
|
||||||
})
|
})
|
||||||
commit('setMedia', media)
|
commit('setMedia', media)
|
||||||
},
|
},
|
||||||
setCurrent ({ commit, state, dispatch }, current) {
|
setCurrent ({ commit, state }, current) {
|
||||||
const index = state.media.indexOf(current)
|
const index = state.media.indexOf(current)
|
||||||
commit('setCurrent', index || 0)
|
commit('setCurrent', index || 0)
|
||||||
},
|
},
|
||||||
closeMediaViewer ({ commit, dispatch }) {
|
closeMediaViewer ({ commit }) {
|
||||||
commit('close')
|
commit('close')
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue