mirror of
https://github.com/Azure/cosmos-explorer.git
synced 2025-02-18 02:07:04 +00:00
Fix format
This commit is contained in:
parent
4e71e340e3
commit
7a179ff34a
@ -23,7 +23,7 @@ import {
|
|||||||
useTableColumnSizing_unstable,
|
useTableColumnSizing_unstable,
|
||||||
useTableFeatures,
|
useTableFeatures,
|
||||||
useTableSelection,
|
useTableSelection,
|
||||||
useTableSort
|
useTableSort,
|
||||||
} from "@fluentui/react-components";
|
} from "@fluentui/react-components";
|
||||||
import {
|
import {
|
||||||
ArrowClockwise16Regular,
|
ArrowClockwise16Regular,
|
||||||
@ -164,9 +164,21 @@ export const DocumentsTableComponent: React.FC<IDocumentsTableComponentProps> =
|
|||||||
<MenuItem key="refresh" icon={<ArrowClockwise16Regular />} onClick={onRefreshTable}>
|
<MenuItem key="refresh" icon={<ArrowClockwise16Regular />} onClick={onRefreshTable}>
|
||||||
Refresh
|
Refresh
|
||||||
</MenuItem>
|
</MenuItem>
|
||||||
<MenuItem icon={<TextSortAscendingRegular />} onClick={(e) => setColumnSort(e, column.id, "ascending")}>Sort ascending</MenuItem>
|
<MenuItem
|
||||||
<MenuItem icon={<TextSortDescendingRegular />} onClick={(e) => setColumnSort(e, column.id, "descending")}>Sort descending</MenuItem>
|
icon={<TextSortAscendingRegular />}
|
||||||
<MenuItem icon={<ArrowResetRegular />} onClick={(e) => setColumnSort(e, undefined, undefined)}>Reset sorting</MenuItem>
|
onClick={(e) => setColumnSort(e, column.id, "ascending")}
|
||||||
|
>
|
||||||
|
Sort ascending
|
||||||
|
</MenuItem>
|
||||||
|
<MenuItem
|
||||||
|
icon={<TextSortDescendingRegular />}
|
||||||
|
onClick={(e) => setColumnSort(e, column.id, "descending")}
|
||||||
|
>
|
||||||
|
Sort descending
|
||||||
|
</MenuItem>
|
||||||
|
<MenuItem icon={<ArrowResetRegular />} onClick={(e) => setColumnSort(e, undefined, undefined)}>
|
||||||
|
Reset sorting
|
||||||
|
</MenuItem>
|
||||||
<MenuItem key="editcolumns" icon={<EditRegular />} onClick={openColumnSelectionPane}>
|
<MenuItem key="editcolumns" icon={<EditRegular />} onClick={openColumnSelectionPane}>
|
||||||
Edit columns
|
Edit columns
|
||||||
</MenuItem>
|
</MenuItem>
|
||||||
@ -316,7 +328,8 @@ export const DocumentsTableComponent: React.FC<IDocumentsTableComponentProps> =
|
|||||||
sortDirection: getSortDirection(columnId),
|
sortDirection: getSortDirection(columnId),
|
||||||
});
|
});
|
||||||
|
|
||||||
const rows: TableRowData[] = sort(getRows((row) => {
|
const rows: TableRowData[] = sort(
|
||||||
|
getRows((row) => {
|
||||||
const selected = isRowSelected(row.rowId);
|
const selected = isRowSelected(row.rowId);
|
||||||
return {
|
return {
|
||||||
...row,
|
...row,
|
||||||
@ -330,7 +343,8 @@ export const DocumentsTableComponent: React.FC<IDocumentsTableComponentProps> =
|
|||||||
selected,
|
selected,
|
||||||
appearance: selected ? ("brand" as const) : ("none" as const),
|
appearance: selected ? ("brand" as const) : ("none" as const),
|
||||||
};
|
};
|
||||||
}));
|
}),
|
||||||
|
);
|
||||||
|
|
||||||
const toggleAllKeydown = React.useCallback(
|
const toggleAllKeydown = React.useCallback(
|
||||||
(e: React.KeyboardEvent<HTMLDivElement>) => {
|
(e: React.KeyboardEvent<HTMLDivElement>) => {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user