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

Fix styling for frozen columns in data table #4770

Merged
merged 3 commits into from
Jan 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 3 additions & 1 deletion jsapp/js/components/submissions/table.es6
Original file line number Diff line number Diff line change
Expand Up @@ -990,7 +990,9 @@ export class DataTable extends React.Component {
col.className = col.className
? `is-frozen is-last-frozen ${col.className}`
: 'is-frozen is-last-frozen';
col.headerClassName = 'is-frozen is-last-frozen';
col.headerClassName = col.headerClassName
? `is-frozen is-last-frozen ${col.headerClassName}`
: 'is-frozen is-last-frozen';
}
});

Expand Down
5 changes: 3 additions & 2 deletions jsapp/js/components/submissions/table.scss
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
@use '~kobo-common/src/styles/colors';
@use 'scss/z-indexes';
@use 'js/components/common/checkbox';
@use 'sass:color';

// These are custom styles for Table View table.

Expand Down Expand Up @@ -471,11 +472,11 @@ $s-data-table-font: 13px;
}

.rt-th.is-sorted {
background-color: rgba(colors.$kobo-light-teal, 0.5);
background-color: color.adjust(colors.$kobo-light-teal, $lightness: 4%);
}

.rt-td.is-sorted {
background-color: rgba(colors.$kobo-light-teal, 0.2);
background-color: color.adjust(colors.$kobo-light-teal, $lightness: 8%);
}

// NOTE: submissions actions column is always frozen as first column
Expand Down