Remove feature flag

This commit is contained in:
Victor Meng
2021-08-10 16:55:53 -07:00
parent b4d23ac913
commit b783ebc834
3 changed files with 28 additions and 4 deletions

View File

@@ -54,8 +54,6 @@ export const ResourceTreeContainer: FunctionComponent<ResourceTreeContainerProps
</div>
{userContext.authType === AuthType.ResourceToken ? (
<ResourceTokenTree />
) : userContext.features.enableKoResourceTree ? (
<div style={{ overflowY: "auto" }} data-bind="react:resourceTree" />
) : (
<ResourceTree container={container} />
)}

View File

@@ -0,0 +1,28 @@
import React from "react";
import { AccordionComponent, AccordionItemComponent } from "../Controls/Accordion/AccordionComponent";
import { TreeComponent, TreeNode } from "../Controls/TreeComponent/TreeComponent";
interface RootNodeProps {
rootNode: TreeNode;
title: string;
className: string;
isExpanded: boolean;
}
export interface GenericResourceTreeProps {
rootNodes: RootNodeProps[];
}
export const GenericResourceTree: React.FC<GenericResourceTreeProps> = ({
rootNodes,
}: GenericResourceTreeProps): JSX.Element => {
return (
<AccordionComponent>
{rootNodes.map((rootNodeProps: RootNodeProps) => {
<AccordionItemComponent title={rootNodeProps.title} isExpanded={rootNodeProps.isExpanded}>
<TreeComponent className={rootNodeProps.className} rootNode={rootNodeProps.rootNode} />
</AccordionItemComponent>;
})}
</AccordionComponent>
);
};

View File

@@ -16,7 +16,6 @@ export type Features = {
readonly enableTtl: boolean;
readonly executeSproc: boolean;
readonly enableAadDataPlane: boolean;
readonly enableKoResourceTree: boolean;
readonly hostedDataExplorer: boolean;
readonly junoEndpoint?: string;
readonly livyEndpoint?: string;
@@ -58,7 +57,6 @@ export function extractFeatures(given = new URLSearchParams(window.location.sear
enableSDKoperations: "true" === get("enablesdkoperations"),
enableSpark: "true" === get("enablespark"),
enableTtl: "true" === get("enablettl"),
enableKoResourceTree: "true" === get("enablekoresourcetree"),
executeSproc: "true" === get("dataexplorerexecutesproc"),
hostedDataExplorer: "true" === get("hosteddataexplorerenabled"),
junoEndpoint: get("junoendpoint"),