fix: also include values in onchange
This commit is contained in:
1 parent
a6cbe233b7
commit
ba17b57cdd
1 file changed
+12
-8
@@ -2,7 +2,7 @@ export function main() {
|
|||||||
let root = window.document.getElementById("main");
|
let root = window.document.getElementById("main");
|
||||||
if (root != null) {
|
if (root != null) {
|
||||||
window.interpreter = new Interpreter(root);
|
window.interpreter = new Interpreter(root);
|
||||||
window.ipc.postMessage(serializeIpcMessage("initialize"))
|
window.ipc.postMessage(serializeIpcMessage("initialize"));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
export class Interpreter {
|
export class Interpreter {
|
||||||
@@ -207,7 +207,9 @@ export class Interpreter {
|
|||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
const href = target.getAttribute("href");
|
const href = target.getAttribute("href");
|
||||||
if (href !== "" && href !== null && href !== undefined) {
|
if (href !== "" && href !== null && href !== undefined) {
|
||||||
window.ipc.postMessage(serializeIpcMessage("browser_open", { href }))
|
window.ipc.postMessage(
|
||||||
|
serializeIpcMessage("browser_open", { href })
|
||||||
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -261,12 +263,13 @@ export class Interpreter {
|
|||||||
if (realId == null) {
|
if (realId == null) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
window.ipc.postMessage(serializeIpcMessage(
|
window.ipc.postMessage(
|
||||||
"user_event", {
|
serializeIpcMessage("user_event", {
|
||||||
event: edit.event_name,
|
event: edit.event_name,
|
||||||
mounted_dom_id: parseInt(realId),
|
mounted_dom_id: parseInt(realId),
|
||||||
contents: contents,
|
contents: contents,
|
||||||
}));
|
})
|
||||||
|
);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
this.NewEventListener(edit.event_name, edit.root, handler);
|
this.NewEventListener(edit.event_name, edit.root, handler);
|
||||||
@@ -342,6 +345,7 @@ export function serialize_event(event) {
|
|||||||
}
|
}
|
||||||
return {
|
return {
|
||||||
value: value,
|
value: value,
|
||||||
|
values: {},
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
case "input":
|
case "input":
|
||||||
|
|||||||
Reference in new issue
Block a user