Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ensure Tabulator row content expand button works with frozen columns #2837

Merged
merged 2 commits into from
Oct 19, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions panel/models/tabulator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -344,7 +344,8 @@ export class DataTabulatorView extends PanelHTMLBoxView {
return
const style = getComputedStyle(this.tabulator.element.children[1].children[0])
const bg = style.backgroundColor
const row_view = div({style: "height: 100%; width: 100%; background-color: " + bg})
const neg_margin = "-" + rowEl.style.paddingLeft
const row_view = div({style: "background-color: " + bg +"; margin-left:" + neg_margin})
view.renderTo(row_view)
row.getElement().appendChild(row_view)
}
Expand Down Expand Up @@ -389,10 +390,11 @@ export class DataTabulatorView extends PanelHTMLBoxView {
columns.push({...column, columns: group_columns})
} else if (column.formatter === "expand") {
const expand = {
align: "center",
hozAlign: "center",
cellClick: (_: any, cell: any) => { this._update_expand(cell) },
formatter: (cell: any) => { return this._expand_render(cell) },
width:40
width:40,
frozen: true
}
columns.push(expand)
} else {
Expand Down