Skip to content

Commit

Permalink
Merge branch 'main' into core_worlds_files_reorg
Browse files Browse the repository at this point in the history
  • Loading branch information
Berserker66 authored Dec 8, 2024
2 parents 9f48255 + e3b5451 commit 8b4762b
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/unittests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pytest pytest-subtests pytest-xdist
pip install pytest "pytest-subtests<0.14.0" pytest-xdist
python ModuleUpdate.py --yes --force --append "WebHostLib/requirements.txt"
python Launcher.py --update_settings # make sure host.yaml exists for tests
- name: Unittests
Expand Down
11 changes: 9 additions & 2 deletions WebHostLib/templates/hostRoom.html
Original file line number Diff line number Diff line change
Expand Up @@ -178,8 +178,15 @@
})
.then(text => new DOMParser().parseFromString(text, 'text/html'))
.then(newDocument => {
let el = newDocument.getElementById("host-room-info");
document.getElementById("host-room-info").innerHTML = el.innerHTML;
["host-room-info", "slots-table"].forEach(function(id) {
const newEl = newDocument.getElementById(id);
const oldEl = document.getElementById(id);
if (oldEl && newEl) {
oldEl.innerHTML = newEl.innerHTML;
} else if (newEl) {
console.warn(`Did not find element to replace for ${id}`)
}
});
});
}

Expand Down
2 changes: 1 addition & 1 deletion WebHostLib/templates/macros.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
{%- endmacro %}
{% macro list_patches_room(room) %}
{% if room.seed.slots %}
<table>
<table id="slots-table">
<thead>
<tr>
<th>Id</th>
Expand Down

0 comments on commit 8b4762b

Please sign in to comment.