diff --git a/.github/workflows/ui-tests.yml b/.github/workflows/ui-tests.yml index 5ae1eb9..4c81bf1 100644 --- a/.github/workflows/ui-tests.yml +++ b/.github/workflows/ui-tests.yml @@ -44,6 +44,7 @@ jobs: OpenAi__DeploymentName: xxxxxxxxxample OpenAi__Hint: xxxxxxxxxample ConnectionStrings__openAi : Endpoint=https://myoaiservice.openai.azure.com/;Key=xxx; + ConnectionStrings__openAi_Image : Endpoint=https://myoaiservice.openai.azure.com/;Key=xxx; - name: Build Tests run: dotnet build ./Tests/UiTests/UiTests.csproj diff --git a/OpenAIChatGPTBlazor/Components/GenerateImageOptions.razor b/OpenAIChatGPTBlazor/Components/GenerateImageOptions.razor index 20e75b4..57d2d08 100644 --- a/OpenAIChatGPTBlazor/Components/GenerateImageOptions.razor +++ b/OpenAIChatGPTBlazor/Components/GenerateImageOptions.razor @@ -1,4 +1,4 @@ -@using Azure.AI.OpenAI +@using Azure.AI.OpenAI @using OpenAI.Images
@@ -8,18 +8,15 @@ - - + + - - - - - - - + + + +
@@ -29,17 +26,15 @@ [Parameter] public string Prompt { get; set; } = string.Empty; - private string _size = GeneratedImageSize.W1024xH1024.ToString(); - private string _quality = GeneratedImageQuality.Standard.ToString(); - private string _style = GeneratedImageStyle.Natural.ToString(); + private string _size = "1024x1024"; + private string _quality = "high"; public ImageGenerationOptions AsAzureOptions(string deploymentName) { return new() { Size = new GeneratedImageSize(int.Parse(_size.Split("x")[0]), int.Parse(_size.Split("x")[1])), - Quality = Enum.Parse(_quality), - Style = Enum.Parse(_style) + Quality = new GeneratedImageQuality(_quality) }; } } diff --git a/OpenAIChatGPTBlazor/Components/Layout/NavMenu.razor b/OpenAIChatGPTBlazor/Components/Layout/NavMenu.razor index a627f60..97ae135 100644 --- a/OpenAIChatGPTBlazor/Components/Layout/NavMenu.razor +++ b/OpenAIChatGPTBlazor/Components/Layout/NavMenu.razor @@ -1,4 +1,4 @@ -