diff --git a/.vscode/tasks.json b/.vscode/tasks.json index 67e6a3b4b..e7c9534aa 100644 --- a/.vscode/tasks.json +++ b/.vscode/tasks.json @@ -131,4 +131,4 @@ "password": true } ] -} +} \ No newline at end of file diff --git a/README.md b/README.md index 6efe8d594..dc524bb35 100644 --- a/README.md +++ b/README.md @@ -282,6 +282,28 @@ By default, Chat Copilot runs locally without authentication, using a guest user ./start.sh ``` +## Optional Configuration: [Ms Graph API Plugin with On-Behalf-Of Flow](./plugins/OBO/README.md) + +This native plugin enables the execution of Microsoft Graph APIs using the On-Behalf-Of (OBO) flow with delegated permissions. + +The OBO flows is used to ensure that the backend APIs are consumed with the identity of the user, not the managed identity or service principal of the middle-tier application (in this case the WebApi). + +Also, this ensures that consent is given, so that the client app (WebApp) can call the middle-tier app (WebApi), and the middle-tier app has permission to call the back-end resource (MSGraph). + +This sample does not implement incremental consent in the UI so all the Graph scopes to be used need to have "Administrator Consent" given in the middle-tier app registration. + +More information in the [OBO readme.md](./plugins/OBO/README.md). + +### Requirements + +Backend authentication via Azure AD must be enabled. Detailed instructions for enabling backend authentication are provided below. + +### Limitations + +- Currently, the plugin only supports GET operations. Future updates may add support for other types of operations. +- Graph queries that return large results, may reach the token limit for the AI model, producing an error. +- Incremental consent is not implemented in this sample. + # Troubleshooting 1. **_Issue:_** Unable to load chats. diff --git a/plugins/OBO/README.md b/plugins/OBO/README.md new file mode 100644 index 000000000..c550ca118 --- /dev/null +++ b/plugins/OBO/README.md @@ -0,0 +1,103 @@ +# Ms Graph plugin using On-Behalf-Of Flow for Ms Graph APIs + +This repository contains a sample Plugin that uses the On-Behalf-Of (OBO) flow to call Microsoft Graph APIs. + +In this document we will refer to the client app as the WebApp (src/webapp), the middle-tier app as the WebApi (src/webapi) and the backend resource as the Ms Graph Api. + +> **IMPORTANT:** This sample is for educational purposes only and is not recommended for production deployments. + +> **NOTE:** This plugin was implemented as a native Kernel function, in the WebAPI code. This is not an implementation of the OpenAI plugin spec. + +> **NOTE:** This plugin works better GTP-4 or GTP-4-Turbo as these models works better with the function model. + +## Prerequisites + +- Enable backend authentication via Azure AD as described in the main [`README.md`](../../README.md) file. + +## Setup Instructions + +1. **Add the WebApp to the "known client application list" in the WebApi app registration.** + + - Go to the WebApp app registration in your tenant and copy the Application Id (Client ID). + - Go to the WebAPI app registration in your tenant. + - Click on "Manifest" option and add an entry for the `knownClientApplications` attribute using the Application Id (Client ID) of the WebApp registration as described in this [document](https://learn.microsoft.com/en-us/entra/identity-platform/reference-app-manifest#knownclientapplications-attribute) + + - Save the manifest. + +2. **Give the WebApi the delegated permissions.** + + - Go to the WebApi API app registration. + - Select the "API permissions" option. + - Click on "+ Add Permission" option and choose the "Microsoft Graph" option. + - Select "Delegated permission" and choose all the delegated permissions needed. + - Click on "Add Permissions". + - As the UI does not implement incremental consent, you need to grant "Admin Consent" to the new permissions added. + +3. **Create a Client Secret for the WebAPI app registration OBO Configuration.** + + - In the WebAPI app registration click on "Certificates & Secrets". + - Create a new secret by clicking in the "+ New client secret", enter a description and the expiration days. + - Copy the Client Secret and the Application Id (Client ID) to use in the WebAPI appsetting configuration. + +4. **Change the WebAPI `appsettings.json` file.** + - Add your OBO configuration values in the OnBehalfOfAuth section as shown below. The ClientId must be the WebAPI Application Id (Client ID). + +```json + // OBO Configuration for Plugins + "OnBehalfOfAuth": { + "Authority": "https://login.microsoftonline.com", + "TenantId": "[ENTER YOUR TENANT ID]", + "ClientId": "[ENTER YOUR CLIENT ID]", + "ClientSecret": "[ENTER YOUR CLIENT SECRET]" + } +``` + +5. Change the scope for the Ms Graph Obo plugin in the WebApp code + + - As the UI does not implement incremental consent, you need to configure the WebApp to use the [.default scope](https://learn.microsoft.com/en-us/entra/identity-platform/v2-oauth2-on-behalf-of-flow#default-and-combined-consent). The scope name is formed by the Application ID of the WebAPI app registration so you need to update it with the WebApi Application ID (Client ID). + + - Change the Constants.ts file located in the webapp/src folder, add the msGraphOboScopes entry with the WebApi Application Id, as shown below: + + ```typescript + plugins: { + msGraphOboScopes: ['api://[ENTER THE WE API APPLICATION ID]/.default'], + } + ``` + +## Test Instructions + +1. Login to the app + +![Login Step](./test-step-1.png) + +2. Enable Ms Graph OBO Plugin + +![Plugin Step](./test-step-2.png) + +![Plugin Step 2](./test-step-3.png) + +![Plugin Step 3](./test-step-4.png) + +3. Update the Persona Meta Prompt with the following text: + + ```text + This is a chat between an intelligent AI bot named Copilot and one or more participants. SK stands for Semantic Kernel, the AI platform used to build the bot. The AI was trained on data through 2021 and is not aware of events that have occurred since then. The bot has the ability to call Graph APIs using the MS Graph OBO tool to fetch real-time data. The user must first enable the plugin. To call a Graph API, the bot would call the \\"CallGraphApiTasksAsync\\" function, and provide the Graph API URL with the ODATA query and its required scopes as a list as arguments. The plugin will automatically handle authentication. Otherwise, the bot has no ability to access data on the Internet, so it should not claim that it can or say that it will go and look things up. Try to be concise with your answers, though it is not required. Knowledge cutoff: {{$knowledgeCutoff}} / Current date: {{TimePlugin.Now}}. + ``` + +![Persona Step 1](./test-step-5.png) + +4. Run a prompt to check if the bot understands that can can a graph API and then ask to run a query by providing a sample + +- Hi! Can you call a graph API for me? + +- Please get the list of applications in my tenant. + You can call the Graph API: `https://graph.microsoft.com/v1.0/applications$select=appId,identifierUris,displayName,publisherDomain,signInAudience` + Required scope: Application.Read.All + +![Check Step 1](./test-step-6.png) + +5. After the sample prompt the bot will execute any graph api query without the need of indicating the graph api, odata query or scopes + +- Please get the ObjectID of my user + +![Check Step 2](./test-step-7.png) diff --git a/plugins/OBO/test-step-1.png b/plugins/OBO/test-step-1.png new file mode 100644 index 000000000..6218369f8 Binary files /dev/null and b/plugins/OBO/test-step-1.png differ diff --git a/plugins/OBO/test-step-2.png b/plugins/OBO/test-step-2.png new file mode 100644 index 000000000..dd4e6f1d5 Binary files /dev/null and b/plugins/OBO/test-step-2.png differ diff --git a/plugins/OBO/test-step-3.png b/plugins/OBO/test-step-3.png new file mode 100644 index 000000000..46628d5b8 Binary files /dev/null and b/plugins/OBO/test-step-3.png differ diff --git a/plugins/OBO/test-step-4.png b/plugins/OBO/test-step-4.png new file mode 100644 index 000000000..ebe0ada50 Binary files /dev/null and b/plugins/OBO/test-step-4.png differ diff --git a/plugins/OBO/test-step-5.png b/plugins/OBO/test-step-5.png new file mode 100644 index 000000000..426e9b62f Binary files /dev/null and b/plugins/OBO/test-step-5.png differ diff --git a/plugins/OBO/test-step-6.png b/plugins/OBO/test-step-6.png new file mode 100644 index 000000000..690d39146 Binary files /dev/null and b/plugins/OBO/test-step-6.png differ diff --git a/plugins/OBO/test-step-7.png b/plugins/OBO/test-step-7.png new file mode 100644 index 000000000..e2ca9f3aa Binary files /dev/null and b/plugins/OBO/test-step-7.png differ diff --git a/scripts/Start.ps1 b/scripts/Start.ps1 index 66cb99ecd..d04fee035 100644 --- a/scripts/Start.ps1 +++ b/scripts/Start.ps1 @@ -9,8 +9,8 @@ $cmd = get-command 'pwsh' $ErrorActionPreference = 'Continue' if (!$cmd) { - Write-Warning "Please update your powershell installation: https://aka.ms/powershell" - return; + Write-Warning "Please update your powershell installation: https://aka.ms/powershell" + return; } $BackendScript = Join-Path "$PSScriptRoot" 'Start-Backend.ps1' @@ -41,7 +41,8 @@ while ($backendRunning -eq $false -and $retryCount -lt $maxRetries) { if ($backendRunning -eq $true) { # Start frontend (in current PS process) & $FrontendScript -} else { +} +else { # otherwise, write to the console that the backend is not running and we have exceeded the number of retries and we are exiting Write-Host "*************************************************" Write-Host "Backend is not running and we have exceeded " @@ -49,4 +50,4 @@ if ($backendRunning -eq $true) { Write-Host "" Write-Host "Therefore, we are exiting." Write-Host "*************************************************" -} +} \ No newline at end of file diff --git a/webapi/Controllers/ChatController.cs b/webapi/Controllers/ChatController.cs index 56fb28216..74d7e4297 100644 --- a/webapi/Controllers/ChatController.cs +++ b/webapi/Controllers/ChatController.cs @@ -47,6 +47,8 @@ public class ChatController : ControllerBase, IDisposable private readonly List _disposables; private readonly ITelemetryService _telemetryService; private readonly ServiceOptions _serviceOptions; + private readonly MsGraphOboPluginOptions _msGraphOboPluginOptions; + private readonly PromptsOptions _promptsOptions; private readonly IDictionary _plugins; private const string ChatPluginName = nameof(ChatPlugin); @@ -58,6 +60,8 @@ public ChatController( IHttpClientFactory httpClientFactory, ITelemetryService telemetryService, IOptions serviceOptions, + IOptions msGraphOboPluginOptions, + IOptions promptsOptions, IDictionary plugins) { this._logger = logger; @@ -65,6 +69,8 @@ public ChatController( this._telemetryService = telemetryService; this._disposables = new List(); this._serviceOptions = serviceOptions.Value; + this._msGraphOboPluginOptions = msGraphOboPluginOptions.Value; + this._promptsOptions = promptsOptions.Value; this._plugins = plugins; } @@ -214,6 +220,12 @@ private async Task RegisterFunctionsAsync(Kernel kernel, Dictionary RegisterCustomPlugins(Kernel kernel, object? customPluginsString, Dictionary authHeaders) { CustomPlugin[]? customPlugins = JsonSerializer.Deserialize(customPluginsString!.ToString()!); diff --git a/webapi/Extensions/ServiceExtensions.cs b/webapi/Extensions/ServiceExtensions.cs index 182a7706b..f5837a4f8 100644 --- a/webapi/Extensions/ServiceExtensions.cs +++ b/webapi/Extensions/ServiceExtensions.cs @@ -59,6 +59,8 @@ public static IServiceCollection AddOptions(this IServiceCollection services, Co AddOptions(FrontendOptions.PropertyName); + AddOptions(MsGraphOboPluginOptions.PropertyName); + return services; void AddOptions(string propertyName) diff --git a/webapi/Options/MsGraphOboPluginOptions.cs b/webapi/Options/MsGraphOboPluginOptions.cs new file mode 100644 index 000000000..c55fa6aaf --- /dev/null +++ b/webapi/Options/MsGraphOboPluginOptions.cs @@ -0,0 +1,24 @@ +// Copyright (c) Microsoft. All rights reserved. + +namespace CopilotChat.WebApi.Options; + +public class MsGraphOboPluginOptions +{ + public const string PropertyName = "OnBehalfOf"; + /// + /// The authority to use for OBO Auth. + /// + public string? Authority { get; set; } + /// + /// The Tenant Id to use for OBO Auth. + /// + public string? TenantId { get; set; } + /// + /// The Client Id to use for OBO Auth. + /// + public string? ClientId { get; set; } + /// + /// The Client Secret to use for OBO Auth. + /// + public string? ClientSecret { get; set; } +} diff --git a/webapi/Options/PromptsOptions.cs b/webapi/Options/PromptsOptions.cs index 5dd1edc6a..8439921c9 100644 --- a/webapi/Options/PromptsOptions.cs +++ b/webapi/Options/PromptsOptions.cs @@ -25,6 +25,11 @@ public class PromptsOptions /// [Required, Range(0, int.MaxValue)] public int ResponseTokenLimit { get; set; } + /// + /// The token count allowed for function calling responses. + /// + [Required, Range(0, int.MaxValue)] public int FunctionCallingTokenLimit { get; set; } + /// /// Weight of memories in the contextual part of the final prompt. /// Contextual prompt excludes all the system commands and user intent. diff --git a/webapi/Plugins/Chat/ChatPlugin.cs b/webapi/Plugins/Chat/ChatPlugin.cs index 010072caa..e5db7be92 100644 --- a/webapi/Plugins/Chat/ChatPlugin.cs +++ b/webapi/Plugins/Chat/ChatPlugin.cs @@ -582,10 +582,12 @@ private int GetMaxRequestTokenBudget() // "content": "Assistant is a large language model.","role": "system" // This burns just under 20 tokens which need to be accounted for. const int ExtraOpenAiMessageTokens = 20; - return this._promptOptions.CompletionTokenLimit // Total token limit - ExtraOpenAiMessageTokens - - this._promptOptions.ResponseTokenLimit; // Token count reserved for model to generate a response + // Token count reserved for model to generate a response + - this._promptOptions.ResponseTokenLimit + // Buffer for Tool Calls + - this._promptOptions.FunctionCallingTokenLimit; } /// diff --git a/webapi/Plugins/Chat/CopilotChatPlanner.cs b/webapi/Plugins/Chat/CopilotChatPlanner.cs new file mode 100644 index 000000000..5f282702b --- /dev/null +++ b/webapi/Plugins/Chat/CopilotChatPlanner.cs @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/webapi/Plugins/Chat/MsGraphOboPlugin.cs b/webapi/Plugins/Chat/MsGraphOboPlugin.cs new file mode 100644 index 000000000..65fcf4911 --- /dev/null +++ b/webapi/Plugins/Chat/MsGraphOboPlugin.cs @@ -0,0 +1,179 @@ +// Copyright (c) Microsoft. All rights reserved. + +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Net.Http; +using System.Text.Json; +using System.Threading; +using System.Threading.Tasks; +using CopilotChat.WebApi.Options; +using Microsoft.Extensions.Logging; +using Microsoft.SemanticKernel; + +namespace CopilotChat.WebApi.Plugins.Chat; + +/// +/// This class is a plugin that calls Graph API using the On-behalf-of flow. +/// +public sealed class MsGraphOboPlugin +{ + private readonly string _bearerToken; + private readonly ILogger _logger; + private readonly IHttpClientFactory _clientFactory; + private readonly string _clientId; + private readonly string _clientSecret; + private readonly string _tenantId; + private readonly string _authority; + private readonly int _responseTokenLimit = 128000; + + // + // Summary: + // Initializes a new instance of the MsGraphOboPlugin to execute the API calls using the OBO Flow. + // class. + // + // Parameters: + // bearerToken: + // The bearer token to received by the WebAPI and used to obtain a new access token using the OBO Flow. + // + // clientFactory: + // The factory to use to create HttpClient instances. + // + // PlannerOptions.OboOptions: + // Configuration for the plugin defined in appsettings.json. + public MsGraphOboPlugin(string bearerToken, IHttpClientFactory clientFactory, MsGraphOboPluginOptions? onBehalfOfAuth, int responseTokenLimit, ILogger logger) + { + this._bearerToken = bearerToken ?? throw new ArgumentNullException(bearerToken); + this._clientFactory = clientFactory; + this._logger = logger; + + this._clientId = onBehalfOfAuth?.ClientId ?? throw new ArgumentNullException(onBehalfOfAuth?.ClientId); + this._clientSecret = onBehalfOfAuth?.ClientSecret ?? throw new ArgumentNullException(onBehalfOfAuth?.ClientSecret); + this._tenantId = onBehalfOfAuth?.TenantId ?? throw new ArgumentNullException(onBehalfOfAuth?.TenantId); + this._authority = onBehalfOfAuth?.Authority ?? throw new ArgumentNullException(onBehalfOfAuth?.Authority); + this._responseTokenLimit = responseTokenLimit; + } + + // + // Summary: + // Call a Graph API with the OData query and the Graph API Scopes based on user input. + // + // Parameters: + // apiURL: + // The URL of the GRAPH API with the OData query to call. + // + // graphScopes: + // The comma separated value string with the Graph API Scopes needed to execute the + // call. + // + // cancellationToken: + // The cancellation token. + // + // Returns: + // The response from the GRAPH API. + // + // Exceptions: + // T:System.ArgumentNullException: + // apiURL is null or empty. + // + // T:System.ArgumentNullException: + // graphScopes is null or empty. + // + // T:System.Net.Http.HttpRequestException: + // Failed to get token: {response.StatusCode}. + // + // T:System.Net.Http.HttpRequestException: + // Failed to get access token. + // + // T:System.Net.Http.HttpRequestException: + // Failed to get graph data: {graphResponse.StatusCode}. + + [KernelFunction, Description("Call a Graph API using the provided OData query and the Graph API Scopes based on user input")] + public async Task CallGraphApiTasksAsync([Description("The URI of the Graph API with the OData query to call")] string apiToCall, [Description("A Comma separated value string with the Graph API Scopes needed to execute the Graph API call")] string graphScopes, CancellationToken cancellationToken = default) + { + if (string.IsNullOrEmpty(apiToCall)) + { + throw new ArgumentNullException(apiToCall); + } + + if (string.IsNullOrEmpty(graphScopes)) + { + throw new ArgumentNullException(graphScopes); + } + + var graphResponseContent = string.Empty; + var oboAccessToken = await this.GetOboAccessTokenAsync(graphScopes, cancellationToken); + using (HttpClient client = this._clientFactory.CreateClient()) + { + using (var graphRequest = new HttpRequestMessage(HttpMethod.Get, apiToCall)) + { + graphRequest.Headers.Authorization = new System.Net.Http.Headers.AuthenticationHeaderValue("Bearer", oboAccessToken); + var graphResponse = await client.SendAsync(graphRequest, cancellationToken); + + if (graphResponse.IsSuccessStatusCode) + { + graphResponseContent = await graphResponse.Content.ReadAsStringAsync(cancellationToken); + } + else + { + throw new HttpRequestException($"Failed to get graph data: {graphResponse.StatusCode}"); + } + } + } + return graphResponseContent; + } + + private async Task GetOboAccessTokenAsync(string graphScopes, CancellationToken cancellationToken) + { + var oboToken = string.Empty; + + using (HttpClient client = this._clientFactory.CreateClient()) + { + using (var request = new HttpRequestMessage(HttpMethod.Post, this._authority + "/" + this._tenantId + "/oauth2/v2.0/token")) + { + var keyValues = new List> + { + new("grant_type", "urn:ietf:params:oauth:grant-type:jwt-bearer"), + new("client_id", this._clientId), + new("client_secret", this._clientSecret), + new("assertion", this._bearerToken), + new("scope", graphScopes), + new("requested_token_use", "on_behalf_of") + }; + + request.Content = new FormUrlEncodedContent(keyValues); + var response = await client.SendAsync(request, cancellationToken); + var responseContent = string.Empty; + + if (response.IsSuccessStatusCode) + { + responseContent = await response.Content.ReadAsStringAsync(cancellationToken); + } + else + { + throw new HttpRequestException($"Failed to get token: {response.StatusCode}"); + } + + using (JsonDocument doc = JsonDocument.Parse(responseContent)) + { + JsonElement root = doc.RootElement; + if (root.TryGetProperty("access_token", out JsonElement accessTokenElement)) + { + oboToken = accessTokenElement.GetString(); + } + else + { + throw new HttpRequestException("Failed to get access token"); + } + } + } + } + + if (string.IsNullOrEmpty(oboToken)) + { + throw new HttpRequestException("Failed to get access token"); + } + + return oboToken; + } +} diff --git a/webapi/Plugins/Utils/JsonUtils.cs b/webapi/Plugins/Utils/JsonUtils.cs new file mode 100644 index 000000000..5f7f668aa --- /dev/null +++ b/webapi/Plugins/Utils/JsonUtils.cs @@ -0,0 +1,109 @@ +// Copyright (c) Microsoft. All rights reserved. + +using System; +using System.Collections.Generic; +using System.Globalization; +using System.Text.Json; +using System.Text.RegularExpressions; + +namespace CopilotChat.WebApi.Plugins.Utils; + +/// +/// Utility methods for working with asynchronous operations and callbacks. +/// +public static class JsonUtils +{ + /// + /// Try to optimize json from the planner response + /// based on token limit + /// + internal static string OptimizeOdataResponseJson(string jsonString, int tokenLimit) + { + // Remove all new line characters + leading and trailing white space + jsonString = Regex.Replace(jsonString.Trim(), @"[\n\r]", string.Empty); + var document = JsonDocument.Parse(jsonString); + + // The json will be deserialized based on the response type of the particular operation that was last invoked by the planner + // The response type can be a custom trimmed down json structure, which is useful in staying within the token limit + Type responseType = typeof(object); + + // Deserializing limits the json content to only the fields defined in the respective OpenApi's Model classes + var functionResponse = JsonSerializer.Deserialize(jsonString, responseType); + jsonString = functionResponse != null ? JsonSerializer.Serialize(functionResponse) : string.Empty; + document = JsonDocument.Parse(jsonString); + + int jsonStringTokenCount = TokenUtils.TokenCount(jsonString); + + // Return the JSON content if it does not exceed the token limit + if (jsonStringTokenCount < tokenLimit) + { + return jsonString; + } + + List itemList = new(); + + // Some APIs will return a JSON response with one property key representing an embedded answer. + // Extract this value for further processing + string resultsDescriptor = string.Empty; + + if (document.RootElement.ValueKind == JsonValueKind.Object) + { + if (document.RootElement.TryGetProperty("value", out JsonElement valueElement)) + { + if (document.RootElement.TryGetProperty("@odata.context", out JsonElement odataContext)) + { + // Save property name for result interpolation + var odataContextVal = odataContext.GetRawText(); + tokenLimit -= TokenUtils.TokenCount(odataContextVal); + resultsDescriptor = string.Format(CultureInfo.InvariantCulture, "{0}: ", odataContextVal); + } + + // Extract object to be truncated + var valueDocument = JsonDocument.Parse(valueElement.GetRawText()); + document = valueDocument; + } + } + + // Detail Object + // To stay within token limits, attempt to truncate the list of properties + if (document.RootElement.ValueKind == JsonValueKind.Object) + { + foreach (JsonProperty property in document.RootElement.EnumerateObject()) + { + int propertyTokenCount = TokenUtils.TokenCount(property.ToString()); + + if (tokenLimit - propertyTokenCount > 0) + { + itemList.Add(property); + tokenLimit -= propertyTokenCount; + } + else + { + break; + } + } + } + + // Summary (List) Object + // To stay within token limits, attempt to truncate the list of results + if (document.RootElement.ValueKind == JsonValueKind.Array) + { + foreach (JsonElement item in document.RootElement.EnumerateArray()) + { + int itemTokenCount = TokenUtils.TokenCount(item.ToString()); + + if (tokenLimit - itemTokenCount > 0) + { + itemList.Add(item); + tokenLimit -= itemTokenCount; + } + else + { + break; + } + } + } + + return string.Format(CultureInfo.InvariantCulture, "{0}{1}", resultsDescriptor, JsonSerializer.Serialize(itemList)); + } +} diff --git a/webapp/src/Constants.ts b/webapp/src/Constants.ts index df3577237..6d72bc5b2 100644 --- a/webapp/src/Constants.ts +++ b/webapp/src/Constants.ts @@ -45,6 +45,7 @@ export const Constants = { // For a list of Microsoft Graph permissions, see https://learn.microsoft.com/en-us/graph/permissions-reference. // Your application registration will need to be granted these permissions in Azure Active Directory. msGraphScopes: ['Calendars.Read', 'Mail.Read', 'Mail.Send', 'Tasks.ReadWrite', 'User.Read'], + msGraphOboScopes: ['[INCLUDE THE SCOPE FOR THE WEBAPI APP REGISTRATION HERE]'], }, KEYSTROKE_DEBOUNCE_TIME_MS: 250, }; diff --git a/webapp/src/components/chat/plan-viewer/PlanStepInput.tsx b/webapp/src/components/chat/plan-viewer/PlanStepInput.tsx index 320458c72..98c9a296e 100644 --- a/webapp/src/components/chat/plan-viewer/PlanStepInput.tsx +++ b/webapp/src/components/chat/plan-viewer/PlanStepInput.tsx @@ -32,7 +32,9 @@ const useClasses = makeStyles({ // (?:.+\s*) is a noncapturing group that matches the start of static string (matches any character followed by whitespace) // Matches: "Interpolated $variable_name", "$variable_name Interpolated", "Interpolated $variable_name Interpolated" // Doesn't match: standalone variables (e.g. "$variable_name") or dollar amounts (e.g. "$1.00", "$100") -const INTERPOLATED_VARIABLE_REGEX = /((\$[A-Za-z]+[_-]*[\w]+)(?=([^-_\d\w])+))|((?:.+\s*)(\$[A-Za-z]+[_-]*[\w]+))/g; +// const INTERPOLATED_VARIABLE_REGEX = /((\$[A-Za-z]+[_-]*[\w]+)(?=([^-_\d\w])+))|((?:.+\s*)(\$[A-Za-z]+[_-]*[\w]+))/g; +const INTERPOLATED_VARIABLE_REGEX = + /\$(?!top|filter|select|expand|orderby|skip|count|search)([A-Za-z0-9_]+|[A-Za-z0-9_]+\([^\)]*\))/g; interface PlanStepInputProps { input: IPlanInput; diff --git a/webapp/src/index.tsx b/webapp/src/index.tsx index d5f2aaace..6133e87b9 100644 --- a/webapp/src/index.tsx +++ b/webapp/src/index.tsx @@ -18,7 +18,7 @@ if (!localStorage.getItem('debug')) { let container: HTMLElement | null = null; let root: ReactDOM.Root | undefined = undefined; -let msalInstance: PublicClientApplication | undefined; +let msalInstance: PublicClientApplication; document.addEventListener('DOMContentLoaded', () => { if (!container) { @@ -35,47 +35,31 @@ document.addEventListener('DOMContentLoaded', () => { export function renderApp() { fetch(new URL('authConfig', BackendServiceUrl)) .then((response) => (response.ok ? (response.json() as Promise) : Promise.reject())) - .then((authConfig) => { + .then(async (authConfig: AuthConfig) => { store.dispatch(setAuthConfig(authConfig)); if (AuthHelper.isAuthAAD()) { - if (!msalInstance) { - msalInstance = new PublicClientApplication(AuthHelper.getMsalConfig(authConfig)); - msalInstance - .initialize() - .then(() => { - if (!msalInstance) { - store.dispatch(setAuthConfig(undefined)); - return; - } - msalInstance - .handleRedirectPromise() - .then((response) => { - if (response) { - msalInstance?.setActiveAccount(response.account); - } - }) - .catch(() => { - store.dispatch(setAuthConfig(undefined)); - }); - }) - .catch(() => { - store.dispatch(setAuthConfig(undefined)); - }); - } + msalInstance = new PublicClientApplication(AuthHelper.getMsalConfig(authConfig)); + await msalInstance.initialize(); - // render with the MsalProvider if AAD is enabled - // eslint-disable-next-line @typescript-eslint/no-non-null-assertion - root!.render( - - - - - - - , - ); + void msalInstance.handleRedirectPromise().then((response) => { + if (response) { + msalInstance.setActiveAccount(response.account); + } + }); } + + // render with the MsalProvider if AAD is enabled + // eslint-disable-next-line @typescript-eslint/no-non-null-assertion + root!.render( + + + + + + + , + ); }) .catch(() => { store.dispatch(setAuthConfig(undefined)); diff --git a/webapp/src/redux/features/plugins/PluginsState.ts b/webapp/src/redux/features/plugins/PluginsState.ts index 50d104436..aabac6979 100644 --- a/webapp/src/redux/features/plugins/PluginsState.ts +++ b/webapp/src/redux/features/plugins/PluginsState.ts @@ -13,12 +13,14 @@ export const enum BuiltInPlugins { MsGraph = 'Microsoft Graph', Jira = 'Jira', GitHub = 'GitHub', + MsGraphObo = 'Microsoft Graph OBO', } export const enum AuthHeaderTags { MsGraph = 'graph', Jira = 'jira', GitHub = 'github', + MsGraphObo = 'msgraphobo', } export interface PluginAuthRequirements { @@ -79,6 +81,18 @@ export const initialState: PluginsState = { headerTag: AuthHeaderTags.MsGraph, icon: GraphIcon, }, + [BuiltInPlugins.MsGraphObo]: { + name: BuiltInPlugins.MsGraphObo, + publisher: 'Microsoft', + description: 'Use your Microsoft Account to access Graph API using OBO flow.', + enabled: false, + authRequirements: { + Msal: true, + scopes: Constants.plugins.msGraphOboScopes, + }, + headerTag: AuthHeaderTags.MsGraphObo, + icon: GraphIcon, + }, [BuiltInPlugins.Jira]: { name: BuiltInPlugins.Jira, publisher: 'Atlassian', diff --git a/webapp/tsconfig.json b/webapp/tsconfig.json index c320a2400..fe4b51b07 100644 --- a/webapp/tsconfig.json +++ b/webapp/tsconfig.json @@ -33,4 +33,4 @@ "composite": true }, "include": ["src", "src/assets/custom.d.ts"] -} +} \ No newline at end of file diff --git a/webapp/yarn.lock b/webapp/yarn.lock index 1617ba687..dde5c24b2 100644 --- a/webapp/yarn.lock +++ b/webapp/yarn.lock @@ -54,11 +54,16 @@ "@babel/highlight" "^7.24.2" picocolors "^1.0.0" -"@babel/compat-data@^7.22.6", "@babel/compat-data@^7.23.5", "@babel/compat-data@^7.24.1": +"@babel/compat-data@^7.22.6", "@babel/compat-data@^7.23.5": version "7.24.1" resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.24.1.tgz#31c1f66435f2a9c329bb5716a6d6186c516c3742" integrity sha512-Pc65opHDliVpRHuKfzI+gSA4zcgr65O4cl64fFJIWEEh8JoHIHh0Oez1Eo8Arz8zq/JhgKodQaxEwUPRtZylVA== +"@babel/compat-data@^7.24.4": + version "7.24.4" + resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.24.4.tgz#6f102372e9094f25d908ca0d34fc74c74606059a" + integrity sha512-vg8Gih2MLK+kOkHJp4gBEIkyaIi00jgWot2D9QOmmfLC8jINSOzmCLta6Bvz/JSBCqnegV0L80jhxkol5GWNfQ== + "@babel/core@^7.1.0", "@babel/core@^7.11.1", "@babel/core@^7.12.3", "@babel/core@^7.16.0", "@babel/core@^7.7.2", "@babel/core@^7.8.0": version "7.24.3" resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.24.3.tgz#568864247ea10fbd4eff04dda1e05f9e2ea985c3" @@ -139,6 +144,21 @@ "@babel/helper-split-export-declaration" "^7.22.6" semver "^6.3.1" +"@babel/helper-create-class-features-plugin@^7.24.4": + version "7.24.4" + resolved "https://registry.yarnpkg.com/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.24.4.tgz#c806f73788a6800a5cfbbc04d2df7ee4d927cce3" + integrity sha512-lG75yeuUSVu0pIcbhiYMXBXANHrpUPaOfu7ryAzskCgKUHuAxRQI5ssrtmF0X9UXldPlvT0XM/A4F44OXRt6iQ== + dependencies: + "@babel/helper-annotate-as-pure" "^7.22.5" + "@babel/helper-environment-visitor" "^7.22.20" + "@babel/helper-function-name" "^7.23.0" + "@babel/helper-member-expression-to-functions" "^7.23.0" + "@babel/helper-optimise-call-expression" "^7.22.5" + "@babel/helper-replace-supers" "^7.24.1" + "@babel/helper-skip-transparent-expression-wrappers" "^7.22.5" + "@babel/helper-split-export-declaration" "^7.22.6" + semver "^6.3.1" + "@babel/helper-create-regexp-features-plugin@^7.18.6", "@babel/helper-create-regexp-features-plugin@^7.22.15", "@babel/helper-create-regexp-features-plugin@^7.22.5": version "7.22.15" resolved "https://registry.yarnpkg.com/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.22.15.tgz#5ee90093914ea09639b01c711db0d6775e558be1" @@ -280,9 +300,9 @@ "@babel/types" "^7.22.19" "@babel/helpers@^7.24.1": - version "7.24.1" - resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.24.1.tgz#183e44714b9eba36c3038e442516587b1e0a1a94" - integrity sha512-BpU09QqEe6ZCHuIHFphEFgvNSrubve1FtyMton26ekZ85gRGi6LrTF7zArARp2YvyFxloeiRmtSCq5sjh1WqIg== + version "7.24.4" + resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.24.4.tgz#dc00907fd0d95da74563c142ef4cd21f2cb856b6" + integrity sha512-FewdlZbSiwaVGlgT1DPANDuCHaDMiOo+D/IDYRFYjHOuv66xMSJ7fQwwODwRNAPkADIO/z1EoF/l2BCWlWABDw== dependencies: "@babel/template" "^7.24.0" "@babel/traverse" "^7.24.1" @@ -299,9 +319,17 @@ picocolors "^1.0.0" "@babel/parser@^7.1.0", "@babel/parser@^7.14.7", "@babel/parser@^7.20.7", "@babel/parser@^7.24.0", "@babel/parser@^7.24.1": - version "7.24.1" - resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.24.1.tgz#1e416d3627393fab1cb5b0f2f1796a100ae9133a" - integrity sha512-Zo9c7N3xdOIQrNip7Lc9wvRPzlRtovHVE4lkz8WEDr7uYh/GMQhSiIgFxGIArRHYdJE5kxtZjAf8rT0xhdLCzg== + version "7.24.4" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.24.4.tgz#234487a110d89ad5a3ed4a8a566c36b9453e8c88" + integrity sha512-zTvEBcghmeBma9QIGunWevvBAp4/Qu9Bdq+2k0Ot4fVMD6v3dsC9WOcRSKk7tRRyBM/53yKMJko9xOatGQAwSg== + +"@babel/plugin-bugfix-firefox-class-in-computed-class-key@^7.24.4": + version "7.24.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-bugfix-firefox-class-in-computed-class-key/-/plugin-bugfix-firefox-class-in-computed-class-key-7.24.4.tgz#6125f0158543fb4edf1c22f322f3db67f21cb3e1" + integrity sha512-qpl6vOOEEzTLLcsuqYYo8yDtrTocmu2xkGvgNebvPjT9DTtfFYGmgDqY+rBYXNlqL4s9qLDn6xkrJv4RxAPiTA== + dependencies: + "@babel/helper-environment-visitor" "^7.22.20" + "@babel/helper-plugin-utils" "^7.24.0" "@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@^7.24.1": version "7.24.1" @@ -587,10 +615,10 @@ dependencies: "@babel/helper-plugin-utils" "^7.24.0" -"@babel/plugin-transform-block-scoping@^7.24.1": - version "7.24.1" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.24.1.tgz#27af183d7f6dad890531256c7a45019df768ac1f" - integrity sha512-h71T2QQvDgM2SmT29UYU6ozjMlAt7s7CSs5Hvy8f8cf/GM/Z4a2zMfN+fjVGaieeCrXR3EdQl6C4gQG+OgmbKw== +"@babel/plugin-transform-block-scoping@^7.24.4": + version "7.24.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.24.4.tgz#28f5c010b66fbb8ccdeef853bef1935c434d7012" + integrity sha512-nIFUZIpGKDf9O9ttyRXpHFpKC+X3Y5mtshZONuEUYBomAKoM4y029Jr+uB1bHGPhNmK8YXHevDtKDOLmtRrp6g== dependencies: "@babel/helper-plugin-utils" "^7.24.0" @@ -602,12 +630,12 @@ "@babel/helper-create-class-features-plugin" "^7.24.1" "@babel/helper-plugin-utils" "^7.24.0" -"@babel/plugin-transform-class-static-block@^7.24.1": - version "7.24.1" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-class-static-block/-/plugin-transform-class-static-block-7.24.1.tgz#4e37efcca1d9f2fcb908d1bae8b56b4b6e9e1cb6" - integrity sha512-FUHlKCn6J3ERiu8Dv+4eoz7w8+kFLSyeVG4vDAikwADGjUCoHw/JHokyGtr8OR4UjpwPVivyF+h8Q5iv/JmrtA== +"@babel/plugin-transform-class-static-block@^7.24.4": + version "7.24.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-class-static-block/-/plugin-transform-class-static-block-7.24.4.tgz#1a4653c0cf8ac46441ec406dece6e9bc590356a4" + integrity sha512-B8q7Pz870Hz/q9UgP8InNpY01CSLDSCyqX7zcRuv3FcPl87A2G17lASroHWaCtbdIcbYzOZ7kWmXFKbijMSmFg== dependencies: - "@babel/helper-create-class-features-plugin" "^7.24.1" + "@babel/helper-create-class-features-plugin" "^7.24.4" "@babel/helper-plugin-utils" "^7.24.0" "@babel/plugin-syntax-class-static-block" "^7.14.5" @@ -971,12 +999,12 @@ "@babel/helper-plugin-utils" "^7.24.0" "@babel/plugin-transform-typescript@^7.24.1": - version "7.24.1" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-typescript/-/plugin-transform-typescript-7.24.1.tgz#5c05e28bb76c7dfe7d6c5bed9951324fd2d3ab07" - integrity sha512-liYSESjX2fZ7JyBFkYG78nfvHlMKE6IpNdTVnxmlYUR+j5ZLsitFbaAE+eJSK2zPPkNWNw4mXL51rQ8WrvdK0w== + version "7.24.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-typescript/-/plugin-transform-typescript-7.24.4.tgz#03e0492537a4b953e491f53f2bc88245574ebd15" + integrity sha512-79t3CQ8+oBGk/80SQ8MN3Bs3obf83zJ0YZjDmDaEZN8MqhMI760apl5z6a20kFeMXBwJX99VpKT8CKxEBp5H1g== dependencies: "@babel/helper-annotate-as-pure" "^7.22.5" - "@babel/helper-create-class-features-plugin" "^7.24.1" + "@babel/helper-create-class-features-plugin" "^7.24.4" "@babel/helper-plugin-utils" "^7.24.0" "@babel/plugin-syntax-typescript" "^7.24.1" @@ -1012,14 +1040,15 @@ "@babel/helper-plugin-utils" "^7.24.0" "@babel/preset-env@^7.11.0", "@babel/preset-env@^7.12.1", "@babel/preset-env@^7.16.4": - version "7.24.3" - resolved "https://registry.yarnpkg.com/@babel/preset-env/-/preset-env-7.24.3.tgz#f3f138c844ffeeac372597b29c51b5259e8323a3" - integrity sha512-fSk430k5c2ff8536JcPvPWK4tZDwehWLGlBp0wrsBUjZVdeQV6lePbwKWZaZfK2vnh/1kQX1PzAJWsnBmVgGJA== + version "7.24.4" + resolved "https://registry.yarnpkg.com/@babel/preset-env/-/preset-env-7.24.4.tgz#46dbbcd608771373b88f956ffb67d471dce0d23b" + integrity sha512-7Kl6cSmYkak0FK/FXjSEnLJ1N9T/WA2RkMhu17gZ/dsxKJUuTYNIylahPTzqpLyJN4WhDif8X0XK1R8Wsguo/A== dependencies: - "@babel/compat-data" "^7.24.1" + "@babel/compat-data" "^7.24.4" "@babel/helper-compilation-targets" "^7.23.6" "@babel/helper-plugin-utils" "^7.24.0" "@babel/helper-validator-option" "^7.23.5" + "@babel/plugin-bugfix-firefox-class-in-computed-class-key" "^7.24.4" "@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression" "^7.24.1" "@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining" "^7.24.1" "@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly" "^7.24.1" @@ -1046,9 +1075,9 @@ "@babel/plugin-transform-async-generator-functions" "^7.24.3" "@babel/plugin-transform-async-to-generator" "^7.24.1" "@babel/plugin-transform-block-scoped-functions" "^7.24.1" - "@babel/plugin-transform-block-scoping" "^7.24.1" + "@babel/plugin-transform-block-scoping" "^7.24.4" "@babel/plugin-transform-class-properties" "^7.24.1" - "@babel/plugin-transform-class-static-block" "^7.24.1" + "@babel/plugin-transform-class-static-block" "^7.24.4" "@babel/plugin-transform-classes" "^7.24.1" "@babel/plugin-transform-computed-properties" "^7.24.1" "@babel/plugin-transform-destructuring" "^7.24.1" @@ -1135,9 +1164,9 @@ integrity sha512-x/rqGMdzj+fWZvCOYForTghzbtqPDZ5gPwaoNGHdgDfF2QA/XZbCBp4Moo5scrkAMPhB7z26XM/AaHuIJdgauA== "@babel/runtime@^7.1.2", "@babel/runtime@^7.10.4", "@babel/runtime@^7.11.2", "@babel/runtime@^7.12.5", "@babel/runtime@^7.16.3", "@babel/runtime@^7.23.2", "@babel/runtime@^7.4.5", "@babel/runtime@^7.5.5", "@babel/runtime@^7.8.4", "@babel/runtime@^7.8.7": - version "7.24.1" - resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.24.1.tgz#431f9a794d173b53720e69a6464abc6f0e2a5c57" - integrity sha512-+BIznRzyqBf+2wCTxcKE3wDjfGeCoVE61KSHGpkzqrLi8qxqFwBeUFyId2cxkTmm55fzDGnm0+yCxaxygrLUnQ== + version "7.24.4" + resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.24.4.tgz#de795accd698007a66ba44add6cc86542aff1edd" + integrity sha512-dkxf7+hn8mFBwKjs9bvBlArzLVxVbS8usaPUDd5p2a9JCL9tB8OaOVN1isD4+Xyk4ns89/xeOmbQvgdK7IIVdA== dependencies: regenerator-runtime "^0.14.0" @@ -1383,10 +1412,10 @@ dependencies: "@swc/helpers" "^0.5.1" -"@fluentui/react-accordion@^9.3.47": - version "9.3.47" - resolved "https://registry.yarnpkg.com/@fluentui/react-accordion/-/react-accordion-9.3.47.tgz#4b940b3e5c75c5f07ec00392b965006c38121298" - integrity sha512-hb/CYIRgtudSwXPObnIlE0TOATq4wmUb1vTgp1DorXE5A/PipVeGNBmru7JPhKNhJCT7Wud7i2FLMs5htc0bmA== +"@fluentui/react-accordion@^9.3.48": + version "9.3.48" + resolved "https://registry.yarnpkg.com/@fluentui/react-accordion/-/react-accordion-9.3.48.tgz#a7dd9bf8360c55a7fb613a565b3c6a139348380d" + integrity sha512-GWtdMygMv0UCJE0rAGKjUV/y56phL1HycsoIKUAxUVIhxPhhrgm6WcvUGT/mRNxXM5eE53Swpv1ojl4GAN6uvQ== dependencies: "@fluentui/react-aria" "^9.10.3" "@fluentui/react-context-selector" "^9.1.57" @@ -1538,10 +1567,10 @@ "@griffel/react" "^1.5.14" "@swc/helpers" "^0.5.1" -"@fluentui/react-combobox@^9.9.5": - version "9.9.5" - resolved "https://registry.yarnpkg.com/@fluentui/react-combobox/-/react-combobox-9.9.5.tgz#88b4b1b842b02e42975337dc6c61ec532dcdbbf5" - integrity sha512-YbGbZWwBiogqUeVsvEmCoiV0lIew+V+gt/MjII6w7ZLMpa1EyY7N+SBjaf0NfYwLl/EVVa8C/2sp4b4Crpy1jA== +"@fluentui/react-combobox@^9.9.6": + version "9.9.6" + resolved "https://registry.yarnpkg.com/@fluentui/react-combobox/-/react-combobox-9.9.6.tgz#d65672ef678f3c040807465f318eed12c1459d69" + integrity sha512-6p0MuUVClWnjRUkE7Zwdg2cLV0rS3PuKbD2aj/WbrJerUDKjhEqQIZEQ2sJ150YN8cPUtvdM6PIdvEuiF7oChw== dependencies: "@fluentui/keyboard-keys" "^9.0.7" "@fluentui/react-aria" "^9.10.3" @@ -1582,11 +1611,11 @@ react-is "^17.0.2" "@fluentui/react-components@^9.47.3": - version "9.47.3" - resolved "https://registry.yarnpkg.com/@fluentui/react-components/-/react-components-9.47.3.tgz#346577571d5daf9512c11e3a4a6fe0aac18ac043" - integrity sha512-bWHA9JCoxd83T0FCgVL6R+4FYa/fLQyrBimKgRsYSFii8B4HrTam6ogeyolLPiA4y2Cizx35osTDMFIPeOjtWg== + version "9.47.5" + resolved "https://registry.yarnpkg.com/@fluentui/react-components/-/react-components-9.47.5.tgz#a6b50da69fd31ecd253d10176d4f57ab10f56779" + integrity sha512-kQ6AJbTHjo/JeoPJlPAF0HBBmLFl0AT2MnNNFuJp2DrNeaWsrcv9MmXrCAtnTfrcNcNt7P4QZ4KqRdG60je4AA== dependencies: - "@fluentui/react-accordion" "^9.3.47" + "@fluentui/react-accordion" "^9.3.48" "@fluentui/react-alert" "9.0.0-beta.115" "@fluentui/react-aria" "^9.10.3" "@fluentui/react-avatar" "^9.6.20" @@ -1595,7 +1624,7 @@ "@fluentui/react-button" "^9.3.74" "@fluentui/react-card" "^9.0.73" "@fluentui/react-checkbox" "^9.2.19" - "@fluentui/react-combobox" "^9.9.5" + "@fluentui/react-combobox" "^9.9.6" "@fluentui/react-dialog" "^9.9.16" "@fluentui/react-divider" "^9.2.66" "@fluentui/react-drawer" "^9.1.10" @@ -1614,7 +1643,7 @@ "@fluentui/react-portal" "^9.4.19" "@fluentui/react-positioning" "^9.14.3" "@fluentui/react-progress" "^9.1.70" - "@fluentui/react-provider" "^9.13.17" + "@fluentui/react-provider" "^9.13.18" "@fluentui/react-radio" "^9.2.14" "@fluentui/react-rating" "^9.0.2" "@fluentui/react-select" "^9.1.70" @@ -1624,7 +1653,7 @@ "@fluentui/react-spinbutton" "^9.2.70" "@fluentui/react-spinner" "^9.4.3" "@fluentui/react-switch" "^9.1.76" - "@fluentui/react-table" "^9.12.1" + "@fluentui/react-table" "^9.13.0" "@fluentui/react-tabs" "^9.4.15" "@fluentui/react-tabster" "^9.19.6" "@fluentui/react-tags" "^9.2.1" @@ -2018,10 +2047,10 @@ lodash "^4.17.15" prop-types "^15.7.2" -"@fluentui/react-provider@^9.13.17": - version "9.13.17" - resolved "https://registry.yarnpkg.com/@fluentui/react-provider/-/react-provider-9.13.17.tgz#6480cd0c732a6d57e3e0be7ab50940ae6a1b82f2" - integrity sha512-txhCPs9Q0ngM1LpDvpzB/0XHXrgWf/rVjDudepUBaIjE0T1nQaPQRsQgJG7TFLVt+kD8KqG3+lS/W+W88FYl7Q== +"@fluentui/react-provider@^9.13.18": + version "9.13.18" + resolved "https://registry.yarnpkg.com/@fluentui/react-provider/-/react-provider-9.13.18.tgz#89ac7f9dc7f7ae97b1aa0529ae5d340a09910ad1" + integrity sha512-FhPpEs7NUtPQXbQ+IX3QQS8TbTBBqY2bGiUX6Vs9CHAmEDh62tCyMtaTCxm2aSg8mULnyWJx7vLVxN7M8s8Zeg== dependencies: "@fluentui/react-icons" "^2.0.224" "@fluentui/react-jsx-runtime" "^9.0.35" @@ -2154,10 +2183,10 @@ "@griffel/react" "^1.5.14" "@swc/helpers" "^0.5.1" -"@fluentui/react-table@^9.12.1": - version "9.12.1" - resolved "https://registry.yarnpkg.com/@fluentui/react-table/-/react-table-9.12.1.tgz#47b216433eb3b245db577322ba17519f5de1683c" - integrity sha512-lMF7NWxdzKnepl+OSiUNMaL9BsP7mtS4xk6bi4yUStSFoU95Ej+7dwvJoKHfoF3qRCwNZHOcGjzkttZhvUA33A== +"@fluentui/react-table@^9.13.0": + version "9.13.0" + resolved "https://registry.yarnpkg.com/@fluentui/react-table/-/react-table-9.13.0.tgz#bb3efc49aed014dce0e4e15a823c011873c95e3e" + integrity sha512-7kIgdBLXEMGDav2KHZUyv7bkot4x/wnlpgCRglyIwEXj7cWuVQ23+prIQjtLS1V5tDnkHT+1iPFki9SXK8+kfQ== dependencies: "@fluentui/keyboard-keys" "^9.0.7" "@fluentui/react-aria" "^9.10.3" @@ -3071,9 +3100,9 @@ integrity sha512-EYNwp3bU+98cpU4lAWYYL7Zz+2gryWH1qbdDTidVd6hkiR6weksdbMadyXKXNPEkQFhXM+hVO9ZygomHXp+AIw== "@types/express-serve-static-core@*", "@types/express-serve-static-core@^4.17.33": - version "4.17.43" - resolved "https://registry.yarnpkg.com/@types/express-serve-static-core/-/express-serve-static-core-4.17.43.tgz#10d8444be560cb789c4735aea5eac6e5af45df54" - integrity sha512-oaYtiBirUOPQGSWNGPWnzyAFJ0BP3cwvN4oWZQY+zUBwpVIGsKUkpBpSztp74drYcjavs7SKFZ4DX1V2QeN8rg== + version "4.19.0" + resolved "https://registry.yarnpkg.com/@types/express-serve-static-core/-/express-serve-static-core-4.19.0.tgz#3ae8ab3767d98d0b682cda063c3339e1e86ccfaa" + integrity sha512-bGyep3JqPCRry1wq+O5n7oiBgGWmeIJXPjXXCo8EK0u8duZGSYar7cGqd3ML2JUsLGeB7fmc06KYo9fLGWqPvQ== dependencies: "@types/node" "*" "@types/qs" "*" @@ -3259,9 +3288,9 @@ "@types/express" "*" "@types/serve-static@*", "@types/serve-static@^1.13.10": - version "1.15.6" - resolved "https://registry.yarnpkg.com/@types/serve-static/-/serve-static-1.15.6.tgz#9cacd9b0b0fc5183ff0d5b27c1b1cad398113673" - integrity sha512-xkChxykiNb1X2YBevPIhQhNU9m9M7h9e2gDsmePAP2kNqhOvpKOrZWOCzq2ERQqfNFzlzHG2bdM0u3z5x+gQgg== + version "1.15.7" + resolved "https://registry.yarnpkg.com/@types/serve-static/-/serve-static-1.15.7.tgz#22174bbd74fb97fe303109738e9b5c2f3064f714" + integrity sha512-W8Ym+h8nhuRwaKPaDw34QUkwsGi6Rc4yYqvKFo5rm2FUEhCFbzVWrxXUxuKK8TASjWsysJY0nsmNCGhCOIsrOw== dependencies: "@types/http-errors" "*" "@types/node" "*" @@ -4440,9 +4469,9 @@ caniuse-api@^3.0.0: lodash.uniq "^4.5.0" caniuse-lite@^1.0.0, caniuse-lite@^1.0.30001587, caniuse-lite@^1.0.30001599: - version "1.0.30001605" - resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001605.tgz#ca12d7330dd8bcb784557eb9aa64f0037870d9d6" - integrity sha512-nXwGlFWo34uliI9z3n6Qc0wZaf7zaZWA1CPZ169La5mV3I/gem7bst0vr5XQH5TJXZIMfDeZyOrZnSlVzKxxHQ== + version "1.0.30001607" + resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001607.tgz#b91e8e033f6bca4e13d3d45388d87fa88931d9a5" + integrity sha512-WcvhVRjXLKFB/kmOFVwELtMxyhq3iM/MvmXcyCe2PNf166c39mptscOc/45TTS96n2gpNV2z7+NakArTWZCQ3w== case-sensitive-paths-webpack-plugin@^2.4.0: version "2.4.0" @@ -4860,15 +4889,15 @@ css-in-js-utils@^3.0.0: hyphenate-style-name "^1.0.3" css-loader@^6.5.1: - version "6.10.0" - resolved "https://registry.yarnpkg.com/css-loader/-/css-loader-6.10.0.tgz#7c172b270ec7b833951b52c348861206b184a4b7" - integrity sha512-LTSA/jWbwdMlk+rhmElbDR2vbtQoTBPr7fkJE+mxrHj+7ru0hUmHafDRzWIjIHTwpitWVaqY2/UWGRca3yUgRw== + version "6.11.0" + resolved "https://registry.yarnpkg.com/css-loader/-/css-loader-6.11.0.tgz#33bae3bf6363d0a7c2cf9031c96c744ff54d85ba" + integrity sha512-CTJ+AEQJjq5NzLga5pE39qdiSV56F8ywCIsqNIRF0r7BDgWsN25aazToqAFg7ZrtA/U016xudB3ffgweORxX7g== dependencies: icss-utils "^5.1.0" postcss "^8.4.33" - postcss-modules-extract-imports "^3.0.0" - postcss-modules-local-by-default "^4.0.4" - postcss-modules-scope "^3.1.1" + postcss-modules-extract-imports "^3.1.0" + postcss-modules-local-by-default "^4.0.5" + postcss-modules-scope "^3.2.0" postcss-modules-values "^4.0.0" postcss-value-parser "^4.2.0" semver "^7.5.4" @@ -5376,9 +5405,9 @@ ejs@^3.1.6: jake "^10.8.5" electron-to-chromium@^1.4.668: - version "1.4.724" - resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.4.724.tgz#e0a86fe4d3d0e05a4d7b032549d79608078f830d" - integrity sha512-RTRvkmRkGhNBPPpdrgtDKvmOEYTrPlXDfc0J/Nfq5s29tEahAwhiX4mmhNzj6febWMleulxVYPh7QwCSL/EldA== + version "1.4.729" + resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.4.729.tgz#8477d21e2a50993781950885b2731d92ad532c00" + integrity sha512-bx7+5Saea/qu14kmPTDHQxkp2UnziG3iajUQu3BxFvCOnpAJdDbMV4rSl+EqFDkkpNNVUFlR1kDfpL59xfy1HA== emittery@^0.10.2: version "0.10.2" @@ -9474,24 +9503,24 @@ postcss-minify-selectors@^5.2.1: dependencies: postcss-selector-parser "^6.0.5" -postcss-modules-extract-imports@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/postcss-modules-extract-imports/-/postcss-modules-extract-imports-3.0.0.tgz#cda1f047c0ae80c97dbe28c3e76a43b88025741d" - integrity sha512-bdHleFnP3kZ4NYDhuGlVK+CMrQ/pqUm8bx/oGL93K6gVwiclvX5x0n76fYMKuIGKzlABOy13zsvqjb0f92TEXw== +postcss-modules-extract-imports@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/postcss-modules-extract-imports/-/postcss-modules-extract-imports-3.1.0.tgz#b4497cb85a9c0c4b5aabeb759bb25e8d89f15002" + integrity sha512-k3kNe0aNFQDAZGbin48pL2VNidTF0w4/eASDsxlyspobzU3wZQLOGj7L9gfRe0Jo9/4uud09DsjFNH7winGv8Q== -postcss-modules-local-by-default@^4.0.4: - version "4.0.4" - resolved "https://registry.yarnpkg.com/postcss-modules-local-by-default/-/postcss-modules-local-by-default-4.0.4.tgz#7cbed92abd312b94aaea85b68226d3dec39a14e6" - integrity sha512-L4QzMnOdVwRm1Qb8m4x8jsZzKAaPAgrUF1r/hjDR2Xj7R+8Zsf97jAlSQzWtKx5YNiNGN8QxmPFIc/sh+RQl+Q== +postcss-modules-local-by-default@^4.0.5: + version "4.0.5" + resolved "https://registry.yarnpkg.com/postcss-modules-local-by-default/-/postcss-modules-local-by-default-4.0.5.tgz#f1b9bd757a8edf4d8556e8d0f4f894260e3df78f" + integrity sha512-6MieY7sIfTK0hYfafw1OMEG+2bg8Q1ocHCpoWLqOKj3JXlKu4G7btkmM/B7lFubYkYWmRSPLZi5chid63ZaZYw== dependencies: icss-utils "^5.0.0" postcss-selector-parser "^6.0.2" postcss-value-parser "^4.1.0" -postcss-modules-scope@^3.1.1: - version "3.1.1" - resolved "https://registry.yarnpkg.com/postcss-modules-scope/-/postcss-modules-scope-3.1.1.tgz#32cfab55e84887c079a19bbb215e721d683ef134" - integrity sha512-uZgqzdTleelWjzJY+Fhti6F3C9iF1JR/dODLs/JDefozYcKTBCdD8BIl6nNPbTbcLnGrk56hzwZC2DaGNvYjzA== +postcss-modules-scope@^3.2.0: + version "3.2.0" + resolved "https://registry.yarnpkg.com/postcss-modules-scope/-/postcss-modules-scope-3.2.0.tgz#a43d28289a169ce2c15c00c4e64c0858e43457d5" + integrity sha512-oq+g1ssrsZOsx9M96c5w8laRmvEu9C3adDSjI8oTcbfkrTE8hx/zfyobUoWIxaKPO8bt6S62kxpw5GqypEw1QQ== dependencies: postcss-selector-parser "^6.0.4" @@ -9832,9 +9861,9 @@ prop-types@^15.6.2, prop-types@^15.7.2, prop-types@^15.8.1: react-is "^16.13.1" property-information@^6.0.0: - version "6.4.1" - resolved "https://registry.yarnpkg.com/property-information/-/property-information-6.4.1.tgz#de8b79a7415fd2107dfbe65758bb2cc9dfcf60ac" - integrity sha512-OHYtXfu5aI2sS2LWFSN5rgJjrQ4pCy8i1jubJLe2QvMF8JJ++HXTUIVWFLfXJoaOfvYYjk2SN8J2wFUWIGXT4w== + version "6.5.0" + resolved "https://registry.yarnpkg.com/property-information/-/property-information-6.5.0.tgz#6212fbb52ba757e92ef4fb9d657563b933b7ffec" + integrity sha512-PgTgs/BlvHxOu8QuEN7wi5A0OmXaBcHpmCSTehcs6Uuu9IkDIEo13Hy7n898RHfrQ49vKCoGeWZSaAK01nwVig== proxy-addr@~2.0.7: version "2.0.7" @@ -10960,9 +10989,9 @@ string_decoder@~1.1.1: safe-buffer "~5.1.0" stringify-entities@^4.0.0: - version "4.0.3" - resolved "https://registry.yarnpkg.com/stringify-entities/-/stringify-entities-4.0.3.tgz#cfabd7039d22ad30f3cc435b0ca2c1574fc88ef8" - integrity sha512-BP9nNHMhhfcMbiuQKCqMjhDP5yBCAxsPu4pHFFzJ6Alo9dZgY4VLDPutXqIjpRiMoKdp7Av85Gr73Q5uH9k7+g== + version "4.0.4" + resolved "https://registry.yarnpkg.com/stringify-entities/-/stringify-entities-4.0.4.tgz#b3b79ef5f277cc4ac73caeb0236c5ba939b3a4f3" + integrity sha512-IwfBptatlO+QCJUo19AqvrPNqlVMpW9YEL2LIVY+Rpv2qsjCGxaDLNRgeGsQWJhfItebuJhsGSLjaBbNSQ+ieg== dependencies: character-entities-html4 "^2.0.0" character-entities-legacy "^3.0.0" @@ -11227,9 +11256,9 @@ terser-webpack-plugin@^5.2.5, terser-webpack-plugin@^5.3.10: terser "^5.26.0" terser@^5.0.0, terser@^5.10.0, terser@^5.26.0: - version "5.30.2" - resolved "https://registry.yarnpkg.com/terser/-/terser-5.30.2.tgz#79fc2222c241647cea54ab928ac987ffbe8ce9e2" - integrity sha512-vTDjRKYKip4dOFL5VizdoxHTYDfEXPdz5t+FbxCC5Rp2s+KbEO8w5wqMDPgj7CtFKZuzq7PXv28fZoXfqqBVuw== + version "5.30.3" + resolved "https://registry.yarnpkg.com/terser/-/terser-5.30.3.tgz#f1bb68ded42408c316b548e3ec2526d7dd03f4d2" + integrity sha512-STdUgOUx8rLbMGO9IOwHLpCqolkDITFFQSMYYwKE1N2lY6MVSaeoi10z/EhWxRc6ybqoVmKSkhKYH/XUpl7vSA== dependencies: "@jridgewell/source-map" "^0.3.3" acorn "^8.8.2"