mirror of
https://github.com/simonw/datasette.git
synced 2026-09-12 03:24:18 +02:00
Use .textContent for column names in column chooser
Refs GHSA-hp2x-vx2r-6vxg Co-authored-by: Alex Garcia <15178711+asg017@users.noreply.github.com>
This commit is contained in:
parent
435e55ff0a
commit
4904249025
1 changed files with 3 additions and 1 deletions
|
|
@ -472,11 +472,13 @@ class ColumnChooser extends HTMLElement {
|
|||
<span class="drag-item-check">
|
||||
<input type="checkbox" ${this._checked.has(col) ? "checked" : ""}>
|
||||
</span>
|
||||
<span class="drag-item-label">${col}</span>
|
||||
<span class="drag-item-label"></span>
|
||||
</label>
|
||||
<div class="drop-indicator"></div>
|
||||
`;
|
||||
|
||||
li.querySelector(".drag-item-label").textContent = col;
|
||||
|
||||
li.querySelector("input").addEventListener("change", (e) => {
|
||||
e.target.checked ? this._checked.add(col) : this._checked.delete(col);
|
||||
this._updateCounts();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue