mirror of
https://github.com/Azure/cosmos-explorer.git
synced 2025-12-21 01:41:31 +00:00
Adding chatbot behind feature flag
This commit is contained in:
@@ -196,7 +196,7 @@ export function createControlCommandBarButtons(container: Explorer): CommandButt
|
|||||||
const showOpenFullScreen =
|
const showOpenFullScreen =
|
||||||
configContext.platform === Platform.Portal && !isRunningOnNationalCloud() && userContext.apiType !== "Gremlin";
|
configContext.platform === Platform.Portal && !isRunningOnNationalCloud() && userContext.apiType !== "Gremlin";
|
||||||
|
|
||||||
if (userContext.authType === AuthType.AAD) {
|
if (userContext.authType === AuthType.AAD && userContext.features.enableChatbot) {
|
||||||
const label = "Chat Assistant";
|
const label = "Chat Assistant";
|
||||||
const supportPaneButton: CommandButtonComponentProps = {
|
const supportPaneButton: CommandButtonComponentProps = {
|
||||||
iconName: "ChatBot",
|
iconName: "ChatBot",
|
||||||
|
|||||||
@@ -30,6 +30,7 @@ export type Features = {
|
|||||||
readonly mongoProxyAPIs?: string;
|
readonly mongoProxyAPIs?: string;
|
||||||
readonly enableThroughputCap: boolean;
|
readonly enableThroughputCap: boolean;
|
||||||
readonly enableNewQuickstart: boolean;
|
readonly enableNewQuickstart: boolean;
|
||||||
|
readonly enableChatbot?: boolean;
|
||||||
|
|
||||||
// can be set via both flight and feature flag
|
// can be set via both flight and feature flag
|
||||||
autoscaleDefault: boolean;
|
autoscaleDefault: boolean;
|
||||||
@@ -92,6 +93,7 @@ export function extractFeatures(given = new URLSearchParams(window.location.sear
|
|||||||
notebooksDownBanner: "true" === get("notebooksDownBanner"),
|
notebooksDownBanner: "true" === get("notebooksDownBanner"),
|
||||||
enableThroughputCap: "true" === get("enablethroughputcap"),
|
enableThroughputCap: "true" === get("enablethroughputcap"),
|
||||||
enableNewQuickstart: "true" === get("enablenewquickstart"),
|
enableNewQuickstart: "true" === get("enablenewquickstart"),
|
||||||
|
enableChatbot: "true" === get("enablechatbot"),
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user