oobabooga 2 年之前
父節點
當前提交
87b84d2275
共有 1 個文件被更改,包括 6 次插入2 次删除
  1. 6 2
      css/chat.js

+ 6 - 2
css/chat.js

@@ -1,2 +1,6 @@
-document.getElementById("main").childNodes[0].style = "max-width: 800px; margin-left: auto; margin-right: auto";
-document.getElementById("extensions").style = "max-width: 800px; margin-left: auto; margin-right: auto";
+document.getElementById("main").style.setProperty("max-width", "800px");
+document.getElementById("main").style.setProperty("margin-left", "auto");
+document.getElementById("main").style.setProperty("margin-right", "auto");
+document.getElementById("extensions").style.setProperty("max-width", "800px");
+document.getElementById("extensions").style.setProperty("margin-left", "auto");
+document.getElementById("extensions").style.setProperty("margin-right", "auto");