fix: focal point should be only visible for images (#1311)
This commit is contained in:
parent
c2bda9b8f3
commit
9fd5c8f6d2
|
@ -7,8 +7,8 @@
|
||||||
aria-hidden="true"
|
aria-hidden="true"
|
||||||
/>
|
/>
|
||||||
<div class="compose-media-buttons">
|
<div class="compose-media-buttons">
|
||||||
<button class="compose-media-button compose-media-focal-button {type === 'audio' ? 'compose-media-hidden' : ''}"
|
<button class="compose-media-button compose-media-focal-button {focalHidden ? 'compose-media-hidden' : ''}"
|
||||||
aria-hidden={type === 'audio'}
|
aria-hidden={focalHidden}
|
||||||
aria-label="Change preview"
|
aria-label="Change preview"
|
||||||
title="Change preview"
|
title="Change preview"
|
||||||
on:click="onSetFocalPoint()" >
|
on:click="onSetFocalPoint()" >
|
||||||
|
@ -163,7 +163,8 @@
|
||||||
return 'center center'
|
return 'center center'
|
||||||
}
|
}
|
||||||
return `${coordsToPercent(focusX)}% ${100 - coordsToPercent(focusY)}%`
|
return `${coordsToPercent(focusX)}% ${100 - coordsToPercent(focusY)}%`
|
||||||
}
|
},
|
||||||
|
focalHidden: ({ type }) => type !== 'image'
|
||||||
},
|
},
|
||||||
store: () => store,
|
store: () => store,
|
||||||
methods: {
|
methods: {
|
||||||
|
|
Loading…
Reference in a new issue