Skip to content
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.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,6 @@ export class ScalarCardComponent<Downloader> {
@ViewChild(LineChartComponent)
lineChart?: LineChartComponent;
sortingInfo: SortingInfo = {
header: ColumnHeaderType.RUN, //This is no longer used but the type needs it or it will break sync. TODO(jameshollyer): remove this once internal code all uses name.
name: 'run',
order: SortingOrder.ASCENDING,
};
Expand Down
2 changes: 0 additions & 2 deletions tensorboard/webapp/widgets/data_table/data_table_component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -118,14 +118,12 @@ export class DataTableComponent implements OnDestroy {
this.sortingInfo.order === SortingOrder.ASCENDING
) {
this.sortDataBy.emit({
header: ColumnHeaderType.RUN, //This is no longer used but the sortingInfo interface needs it or it will break sync. TODO(jameshollyer): remove this once internal code all uses name.
name,
order: SortingOrder.DESCENDING,
});
return;
}
this.sortDataBy.emit({
header: ColumnHeaderType.RUN, //This is no longer used but the sortingInfo interface needs it or it will break sync. TODO(jameshollyer): remove this once internal code all uses name.
name,
order: SortingOrder.ASCENDING,
});
Expand Down
8 changes: 0 additions & 8 deletions tensorboard/webapp/widgets/data_table/data_table_test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,6 @@ describe('data table', () => {
fixture.componentInstance.headers = input.headers || [];
fixture.componentInstance.data = input.data || [];
fixture.componentInstance.sortingInfo = input.sortingInfo || {
header: ColumnHeaderType.RUN,
name: 'run',
order: SortingOrder.ASCENDING,
};
Expand Down Expand Up @@ -416,7 +415,6 @@ describe('data table', () => {

headerElements[3].triggerEventHandler('click', {});
expect(sortDataBySpy).toHaveBeenCalledOnceWith({
header: jasmine.any(String), // This attribute is no longer used but temporarily left here to no break internal syncs
name: 'step',
order: SortingOrder.ASCENDING,
});
Expand Down Expand Up @@ -451,7 +449,6 @@ describe('data table', () => {
},
],
sortingInfo: {
header: ColumnHeaderType.STEP,
name: 'step',
order: SortingOrder.ASCENDING,
},
Expand All @@ -463,7 +460,6 @@ describe('data table', () => {

headerElements[3].triggerEventHandler('click', {});
expect(sortDataBySpy).toHaveBeenCalledOnceWith({
header: jasmine.any(String), // This attribute is no longer used but temporarily left here to no break internal syncs
name: 'step',
order: SortingOrder.DESCENDING,
});
Expand Down Expand Up @@ -492,7 +488,6 @@ describe('data table', () => {
},
],
sortingInfo: {
header: ColumnHeaderType.VALUE,
name: 'value',
order: SortingOrder.ASCENDING,
},
Expand Down Expand Up @@ -557,7 +552,6 @@ describe('data table', () => {
},
],
sortingInfo: {
header: ColumnHeaderType.STEP,
name: 'step',
order: SortingOrder.DESCENDING,
},
Expand Down Expand Up @@ -622,7 +616,6 @@ describe('data table', () => {
},
],
sortingInfo: {
header: ColumnHeaderType.STEP,
name: 'step',
order: SortingOrder.DESCENDING,
},
Expand Down Expand Up @@ -692,7 +685,6 @@ describe('data table', () => {
},
],
sortingInfo: {
header: ColumnHeaderType.STEP,
name: 'step',
order: SortingOrder.DESCENDING,
},
Expand Down
6 changes: 3 additions & 3 deletions tensorboard/webapp/widgets/data_table/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,9 +56,9 @@ export interface SortingInfo {
// Currently in the process of moving from header to name.
// Header is no longer used but is required as to not break sync
// TODO(jameshollyer): Remove header once all internal code is switched
// to using name and make name required.
header: ColumnHeaderType;
name?: string;
// to using name.
header?: ColumnHeaderType;
name: string;
order: SortingOrder;
}

Expand Down