diff --git a/src/Explorer/Tabs/DocumentsTabV2/DocumentsTabV2.tsx b/src/Explorer/Tabs/DocumentsTabV2/DocumentsTabV2.tsx
index 35c3f8221..9cfc4301d 100644
--- a/src/Explorer/Tabs/DocumentsTabV2/DocumentsTabV2.tsx
+++ b/src/Explorer/Tabs/DocumentsTabV2/DocumentsTabV2.tsx
@@ -1779,6 +1779,9 @@ export const DocumentsTabComponent: React.FunctionComponent
{tableItems.length > 0 && (
{
idHeader: ID_HEADER,
partitionKeyHeaders: [PARTITION_KEY_HEADER],
},
+ isSelectionDisabled: false,
});
it("should render documents and partition keys in header", () => {
@@ -31,4 +32,11 @@ describe("DocumentsTableComponent", () => {
const wrapper = mount();
expect(wrapper).toMatchSnapshot();
});
+
+ it("should not render selection column when isSelectionDisabled is true", () => {
+ const props: IDocumentsTableComponentProps = createMockProps();
+ props.isSelectionDisabled = true;
+ const wrapper = mount();
+ expect(wrapper).toMatchSnapshot();
+ });
});
diff --git a/src/Explorer/Tabs/DocumentsTabV2/DocumentsTableComponent.tsx b/src/Explorer/Tabs/DocumentsTabV2/DocumentsTableComponent.tsx
index 4089b12bd..d66568875 100644
--- a/src/Explorer/Tabs/DocumentsTabV2/DocumentsTableComponent.tsx
+++ b/src/Explorer/Tabs/DocumentsTabV2/DocumentsTableComponent.tsx
@@ -41,6 +41,7 @@ export interface IDocumentsTableComponentProps {
size: { height: number; width: number };
columnHeaders: ColumnHeaders;
style?: React.CSSProperties;
+ isSelectionDisabled?: boolean;
}
interface TableRowData extends RowStateBase {
@@ -61,6 +62,7 @@ export const DocumentsTableComponent: React.FC =
style,
size,
columnHeaders,
+ isSelectionDisabled,
}: IDocumentsTableComponentProps) => {
const [activeItemIndex, setActiveItemIndex] = React.useState(undefined);
@@ -127,12 +129,14 @@ export const DocumentsTableComponent: React.FC =
const { item, selected, appearance, onClick, onKeyDown } = data[index];
return (
-
+ {!isSelectionDisabled && (
+
+ )}
{columns.map((column) => (
=
-
+ {!isSelectionDisabled && (
+
+ )}
{columns.map((column /* index */) => (