MCPcopy Create free account
hub / github.com/breck7/scroll / processTableHeaders

Method processTableHeaders

external/.tableSearch.js:99–116  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

97 }
98
99 processTableHeaders() {
100 // Store date column information
101 this.dateColumns = new Map()
102
103 // Process table headers
104 const table = document.querySelector("table.scrollTable")
105 const headers = table.querySelectorAll("th")
106
107 headers.forEach((header, index) => {
108 const originalText = header.textContent
109 if (originalText.startsWith("last")) {
110 // Store the column index and the new name (without 'last')
111 const newName = originalText.slice(4) // Remove 'last' prefix
112 this.dateColumns.set(index, newName)
113 header.textContent = newName
114 }
115 })
116 }
117
118 createColumnDefs() {
119 const columnDefs = []

Callers 1

constructorMethod · 0.95

Calls 3

forEachMethod · 0.80
sliceMethod · 0.80
setMethod · 0.45

Tested by

no test coverage detected