瀏覽代碼

Modal functions.

dev-tmpl
Bryan Miller 6 年之前
父節點
當前提交
6f1599e29f
共有 2 個檔案被更改,包括 2 行新增2 行删除
  1. +1
    -0
      app/js/main.js
  2. +1
    -2
      app/js/ui/Modal.js

+ 1
- 0
app/js/main.js 查看文件

@@ -1,4 +1,5 @@
import EventWindow from "/app/js/ui/EventWindow.js";
import Modal from "/app/js/ui/Modal.js";
import {NESPainter} from "/app/js/NESPainter.js";
import {NESPalette} from "/app/js/NESPalette.js";


+ 1
- 2
app/js/ui/Modal.js 查看文件

@@ -45,7 +45,7 @@ class Modal{
if (el.classList.contains("modal")){
if (this.__currentModalEl !== null && force)
this.close_modal();
if this.__currentModalEl === null){
if (this.__currentModalEl === null){
el.classList.add("modal-visible");
this.__currentModalEl = el;
}
@@ -64,5 +64,4 @@ class Modal{


const instance = new Modal();
Object.freeze(instance);
export default instance;

Loading…
取消
儲存