Skip to content

Commit 6a49a55

Browse files
committed
Adjust selectors in RuleCollectionBuilder to use plain js
1 parent 8d48e71 commit 6a49a55

1 file changed

Lines changed: 8 additions & 8 deletions

File tree

client/src/components/RuleCollectionBuilder.vue

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1836,16 +1836,16 @@ export default {
18361836
return { data, sources };
18371837
},
18381838
highlightColumn(n) {
1839-
const headerSelection = $(`.htCore > thead > tr > th:nth-child(${n + 1})`);
1840-
headerSelection.addClass("ht__highlight");
1841-
const bodySelection = $(`.htCore > tbody > tr > td:nth-child(${n + 1})`);
1842-
bodySelection.addClass("rule-highlight");
1839+
const headerSelection = document.querySelectorAll(`.htCore > thead > tr > th:nth-child(${n + 1})`);
1840+
headerSelection.forEach(el => el.classList.add("ht__highlight"));
1841+
const bodySelection = document.querySelectorAll(`.htCore > tbody > tr > td:nth-child(${n + 1})`);
1842+
bodySelection.forEach(el => el.classList.add("rule-highlight"));
18431843
},
18441844
unhighlightColumn(n) {
1845-
const headerSelection = $(`.htCore > thead > tr > th:nth-child(${n + 1})`);
1846-
headerSelection.removeClass("ht__highlight");
1847-
const bodySelection = $(`.htCore > tbody > tr > td:nth-child(${n + 1})`);
1848-
bodySelection.removeClass("rule-highlight");
1845+
const headerSelection = document.querySelectorAll(`.htCore > thead > tr > th:nth-child(${n + 1})`);
1846+
headerSelection.forEach(el => el.classList.remove("ht__highlight"));
1847+
const bodySelection = document.querySelectorAll(`.htCore > tbody > tr > td:nth-child(${n + 1})`);
1848+
bodySelection.forEach(el => el.classList.remove("rule-highlight"));
18491849
},
18501850
_datasetFor(dataIndex, data, mappingAsDict) {
18511851
const res = {};

0 commit comments

Comments
 (0)