mirror of
https://github.com/cheeaun/phanpy.git
synced 2024-11-28 20:28:52 +03:00
Fix media alt modal not esc-able
This commit is contained in:
parent
a1b81562db
commit
c03f39b10c
2 changed files with 3 additions and 5 deletions
|
@ -24,7 +24,7 @@ export default function MediaAltModal({ alt, lang, onClose }) {
|
|||
);
|
||||
|
||||
return (
|
||||
<div class="sheet">
|
||||
<div class="sheet" tabindex="-1">
|
||||
{!!onClose && (
|
||||
<button type="button" class="sheet-close outer" onClick={onClose}>
|
||||
<Icon icon="x" />
|
||||
|
|
|
@ -183,10 +183,8 @@ export default function Modals() {
|
|||
{!!snapStates.showMediaAlt && (
|
||||
<Modal
|
||||
class="light"
|
||||
onClick={(e) => {
|
||||
if (e.target === e.currentTarget) {
|
||||
states.showMediaAlt = false;
|
||||
}
|
||||
onClose={(e) => {
|
||||
states.showMediaAlt = false;
|
||||
}}
|
||||
>
|
||||
<MediaAltModal
|
||||
|
|
Loading…
Reference in a new issue