mirror of
https://github.com/NapNeko/NapCatQQ.git
synced 2025-07-19 12:03:37 +00:00
build: 1.3.5-beta15
This commit is contained in:
@@ -209,7 +209,7 @@ async function onSettingWindowCreated(view: Element) {
|
||||
dom.input.type = "url";
|
||||
dom.input.value = host;
|
||||
dom.input.addEventListener("input", () => {
|
||||
ob11Config[type.split(".")[0]][type.split(".")[-1]][index] =
|
||||
ob11Config[type.split(".")[0]][type.split(".")[1]][index] =
|
||||
dom.input.value;
|
||||
});
|
||||
|
||||
@@ -219,7 +219,7 @@ async function onSettingWindowCreated(view: Element) {
|
||||
dom.deleteBtn.innerHTML = "删除";
|
||||
dom.deleteBtn.dataset.type = "secondary";
|
||||
dom.deleteBtn.addEventListener("click", () => {
|
||||
ob11Config[type.split(".")[0]][type.split(".")[-1]].splice(index, 1);
|
||||
ob11Config[type.split(".")[0]][type.split(".")[1]].splice(index, 1);
|
||||
initReverseHost(type);
|
||||
});
|
||||
|
||||
@@ -253,11 +253,11 @@ async function onSettingWindowCreated(view: Element) {
|
||||
buildHostListItem(
|
||||
type,
|
||||
"",
|
||||
ob11Config[type.split(".")[0]][type.split(".")[-1]].length,
|
||||
ob11Config[type.split(".")[0]][type.split(".")[1]].length,
|
||||
inputAttr
|
||||
)
|
||||
);
|
||||
ob11Config[type.split(".")[0]][type.split(".")[-1]].push("");
|
||||
ob11Config[type.split(".")[0]][type.split(".")[1]].push("");
|
||||
};
|
||||
const initReverseHost = (type: string, doc: Document = document) => {
|
||||
const hostContainerDom = doc.body?.querySelector(
|
||||
@@ -266,7 +266,7 @@ async function onSettingWindowCreated(view: Element) {
|
||||
if (hostContainerDom) {
|
||||
[...hostContainerDom.childNodes].forEach((dom) => dom.remove());
|
||||
buildHostList(
|
||||
ob11Config[type.split(".")[0]][type.split(".")[-1]],
|
||||
ob11Config[type.split(".")[0]][type.split(".")[1]],
|
||||
type
|
||||
).forEach((dom) => {
|
||||
hostContainerDom?.appendChild(dom);
|
||||
|
Reference in New Issue
Block a user