1
0
Fork 0
mirror of https://github.com/jugeeya/UltimateTrainingModpack.git synced 2025-03-14 02:16:10 +00:00

Menu export bugfix (#229)

* Use jQuery to handle class addition/removal

* Use .is-appear class instead of innerHTML for goBackHook

* Revert unrelated comment

Co-authored-by: asimon-1 <asimon1@protonmail.com>
This commit is contained in:
asimon-1 2021-08-16 14:48:00 -04:00 committed by GitHub
parent dcdb670a42
commit 49c30bb30d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -282,9 +282,9 @@
var children = this.children;
for (var i = 0; i < children.length; i++) {
var child = children[i];
if (child.innerHTML.includes("is-appear")) {
if ($(child).find(".is-appear").length) {
val += child.getAttribute("val") + ",";
}
};
}
settings.push({
@ -297,7 +297,7 @@
$("div.onoff").each(function () {
var section = this.id;
var val = "";
if (this.innerHTML.includes("is-appear")) {
if ($(this).find(".is-appear").length) {
val = "1"
} else {
val = "0"