Skip to content

Commit 6a97ce7

Browse files
authored
fix: shift header to the right when sticky header and single select are enabled (#2867)
Signed-off-by: Akshat Patel <[email protected]>
1 parent 2baf7ca commit 6a97ce7

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

src/table/cell/table-radio.component.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@ import {
22
Component,
33
Input,
44
Output,
5-
EventEmitter
5+
EventEmitter,
6+
HostBinding
67
} from "@angular/core";
78
import { I18n } from "carbon-components-angular/i18n";
89
import { TableItem } from "../table-item.class";
@@ -41,6 +42,9 @@ export class TableRadio {
4142
return this.row ? !!(this.row as TableRow).disabled : false;
4243
}
4344

45+
@HostBinding("class.cds--table-column-radio") radioColumn = true;
46+
@HostBinding("class.cds--table-column-checkbox") selectableColumn = true;
47+
4448
/**
4549
* Used to populate the row selection checkbox label with a useful value if set.
4650
*

src/table/head/table-head.component.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,6 @@ import { TableRowSize } from "../table.types";
3737
<th
3838
*ngIf="!skeleton && showSelectionColumn && enableSingleSelect"
3939
scope="col"
40-
style="width: 0;"
4140
[id]="model.getId('select')">
4241
<!-- add width 0; since the carbon styles don't seem to constrain this headers width -->
4342
</th>

0 commit comments

Comments
 (0)