Skip to content

Commit 03f1bae

Browse files
authored
feat(Table): add col-line-no style on Line column (#5851)
* refactor: 增加行号样式 * refactor: 增加 col-line-no 样式 * refactor: 增加间隙
1 parent dccf10f commit 03f1bae

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

src/BootstrapBlazor/Components/Table/Table.razor.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,7 @@ public partial class Table<TItem> : ITable, IModelEqualityComparer<TItem> where
133133
.Build();
134134

135135
private string? LineCellClassString => CssBuilder.Default("table-cell")
136+
.AddClass("col-line-no")
136137
.AddClass(LineNoColumnAlignment.ToDescriptionString())
137138
.Build();
138139

src/BootstrapBlazor/Components/Table/Table.razor.scss

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
.table-container {
1+
.table-container {
22
--bb-table-td-padding-x: .5rem;
33
--bb-table-td-padding-y: .5rem;
44
--bb-table-cardview-label-width: 30%;
@@ -753,6 +753,10 @@ form .table .table-cell > textarea {
753753
padding: 6px 8px;
754754
}
755755

756+
.table-excel > tbody > tr > td > .col-line-no {
757+
padding: 7px 0;
758+
}
759+
756760
.table-excel .active > td > .table-cell .form-control,
757761
.table-excel .active > td > .table-cell .form-select {
758762
background-color: transparent;

0 commit comments

Comments
 (0)