File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -107,15 +107,14 @@ listings_UI <- function(module_id) { # nolint
107107 const table_container_id = '%s';
108108 const table = document.querySelector('#' + table_container_id + ' table.dataTable');
109109 if (!table) return;
110- console.log('table found');
111-
112110
113111 const headers = table.querySelectorAll('thead tr')[0]?.querySelectorAll('th.dtfc-fixed-left');
114112 const filters = table.querySelectorAll('thead tr')[1]?.querySelectorAll('td');
113+
115114 if (!headers || !filters) return;
116- console.log(' headers found');
117- headers.forEach((th, i) => {
118- const td = filters[i ];
115+ for(let idx = 0; idx < headers.length; ++idx){
116+ const th = headers[idx];
117+ const td = filters[idx ];
119118 if (!td) return;
120119
121120 const computed_style = window.getComputedStyle(th);
@@ -126,8 +125,8 @@ listings_UI <- function(module_id) { # nolint
126125 td.style.position = 'sticky';
127126 td.style.left = left;
128127 td.style.zIndex = zIndex;
129- });
130- });" , ns(TBL $ TABLE_ID ), ns(TBL $ TABLE_ID ), ns( TBL $ TABLE_ID ) )))
128+ }
129+ });" , ns(TBL $ TABLE_ID ), ns(TBL $ TABLE_ID ))))
131130
132131 )
133132}
You can’t perform that action at this time.
0 commit comments