From 5a062b19dc455bb98c08d2909c0bf8bc565e3763 Mon Sep 17 00:00:00 2001 From: Pepe Fagoaga Date: Mon, 9 Mar 2026 12:14:19 +0000 Subject: [PATCH 001/108] chore: remove SaaS reference in dashboard (#10288) --- dashboard/__main__.py | 2 +- docs/user-guide/cli/tutorials/dashboard.mdx | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dashboard/__main__.py b/dashboard/__main__.py index 304e4afdf2..664ce3bfa5 100644 --- a/dashboard/__main__.py +++ b/dashboard/__main__.py @@ -21,7 +21,7 @@ print( f"{Fore.GREEN}Loading all CSV files from the folder {folder_path_overview} ...\n{Style.RESET_ALL}" ) cli.show_server_banner = lambda *x: click.echo( - f"{Fore.YELLOW}NOTE:{Style.RESET_ALL} If you are using {Fore.GREEN}{Style.BRIGHT}Prowler SaaS{Style.RESET_ALL} with the S3 integration or that integration \nfrom {Fore.CYAN}{Style.BRIGHT}Prowler Open Source{Style.RESET_ALL} and you want to use your data from your S3 bucket,\nrun: `{orange_color}aws s3 cp s3:///output/csv ./output --recursive{Style.RESET_ALL}`\nand then run `prowler dashboard` again to load the new files." + f"{Fore.YELLOW}NOTE:{Style.RESET_ALL} If you are using {Fore.GREEN}{Style.BRIGHT}Prowler Cloud{Style.RESET_ALL} with the S3 integration or that integration \nfrom {Fore.CYAN}{Style.BRIGHT}Prowler CLI{Style.RESET_ALL} and you want to use your data from your S3 bucket,\nrun: `{orange_color}aws s3 cp s3:///output/csv ./output --recursive{Style.RESET_ALL}`\nand then run `prowler dashboard` again to load the new files." ) # Initialize the app - incorporate css diff --git a/docs/user-guide/cli/tutorials/dashboard.mdx b/docs/user-guide/cli/tutorials/dashboard.mdx index 8c819743fe..0fe3c69fed 100644 --- a/docs/user-guide/cli/tutorials/dashboard.mdx +++ b/docs/user-guide/cli/tutorials/dashboard.mdx @@ -99,7 +99,7 @@ def get_table(data): ## S3 Integration -If you are using Prowler SaaS with the S3 integration or that integration from Prowler Open Source and you want to use your data from your S3 bucket, you can run the following command in order to load the dashboard with the new files: +If you are using Prowler Cloud with the S3 integration or that integration from Prowler CLI and you want to use your data from your S3 bucket, you can run the following command in order to load the dashboard with the new files: ```sh aws s3 cp s3:///output/csv ./output --recursive From 1e95b48c86f9aae5a220ad269f8003651546351c Mon Sep 17 00:00:00 2001 From: Alejandro Bailo <59607668+alejandrobailo@users.noreply.github.com> Date: Mon, 9 Mar 2026 13:36:31 +0100 Subject: [PATCH 002/108] fix(ui): rename error text token to text-text-error-primary (#10285) --- .../providers/radio-group-provider.tsx | 2 +- .../forms/fields/wizard-input-field.tsx | 2 +- .../forms/fields/wizard-textarea-field.tsx | 2 +- ...alibabacloud-via-credentials-type-form.tsx | 2 +- ...io-group-aws-via-credentials-type-form.tsx | 2 +- ...p-cloudflare-via-credentials-type-form.tsx | 2 +- ...io-group-gcp-via-credentials-type-form.tsx | 2 +- ...group-github-via-credentials-type-form.tsx | 2 +- ...o-group-m365-via-credentials-type-form.tsx | 2 +- ui/components/ui/form/Form.test.tsx | 65 +++++++++++++++++++ ui/components/ui/form/Form.tsx | 7 +- 11 files changed, 79 insertions(+), 11 deletions(-) create mode 100644 ui/components/ui/form/Form.test.tsx diff --git a/ui/components/providers/radio-group-provider.tsx b/ui/components/providers/radio-group-provider.tsx index b4bf22af4b..b071062e94 100644 --- a/ui/components/providers/radio-group-provider.tsx +++ b/ui/components/providers/radio-group-provider.tsx @@ -176,7 +176,7 @@ export const RadioGroupProvider: FC = ({ {errorMessage && ( - + {errorMessage} )} diff --git a/ui/components/providers/workflow/forms/fields/wizard-input-field.tsx b/ui/components/providers/workflow/forms/fields/wizard-input-field.tsx index 88188b5487..b769bd1461 100644 --- a/ui/components/providers/workflow/forms/fields/wizard-input-field.tsx +++ b/ui/components/providers/workflow/forms/fields/wizard-input-field.tsx @@ -163,7 +163,7 @@ export const WizardInputField = ({ )} - + ); }} diff --git a/ui/components/providers/workflow/forms/fields/wizard-textarea-field.tsx b/ui/components/providers/workflow/forms/fields/wizard-textarea-field.tsx index 05768b0e04..473de8d48d 100644 --- a/ui/components/providers/workflow/forms/fields/wizard-textarea-field.tsx +++ b/ui/components/providers/workflow/forms/fields/wizard-textarea-field.tsx @@ -87,7 +87,7 @@ export const WizardTextareaField = ({ {description}

)} - + ); }} diff --git a/ui/components/providers/workflow/forms/select-credentials-type/alibabacloud/radio-group-alibabacloud-via-credentials-type-form.tsx b/ui/components/providers/workflow/forms/select-credentials-type/alibabacloud/radio-group-alibabacloud-via-credentials-type-form.tsx index 0359f07c86..1315a6b559 100644 --- a/ui/components/providers/workflow/forms/select-credentials-type/alibabacloud/radio-group-alibabacloud-via-credentials-type-form.tsx +++ b/ui/components/providers/workflow/forms/select-credentials-type/alibabacloud/radio-group-alibabacloud-via-credentials-type-form.tsx @@ -50,7 +50,7 @@ export const RadioGroupAlibabaCloudViaCredentialsTypeForm = < {errorMessage && ( - + {errorMessage} )} diff --git a/ui/components/providers/workflow/forms/select-credentials-type/aws/radio-group-aws-via-credentials-type-form.tsx b/ui/components/providers/workflow/forms/select-credentials-type/aws/radio-group-aws-via-credentials-type-form.tsx index b88208347a..294d68515b 100644 --- a/ui/components/providers/workflow/forms/select-credentials-type/aws/radio-group-aws-via-credentials-type-form.tsx +++ b/ui/components/providers/workflow/forms/select-credentials-type/aws/radio-group-aws-via-credentials-type-form.tsx @@ -43,7 +43,7 @@ export const RadioGroupAWSViaCredentialsTypeForm = ({ {errorMessage && ( - + {errorMessage} )} diff --git a/ui/components/providers/workflow/forms/select-credentials-type/cloudflare/radio-group-cloudflare-via-credentials-type-form.tsx b/ui/components/providers/workflow/forms/select-credentials-type/cloudflare/radio-group-cloudflare-via-credentials-type-form.tsx index ba60dd6c25..67ea17267e 100644 --- a/ui/components/providers/workflow/forms/select-credentials-type/cloudflare/radio-group-cloudflare-via-credentials-type-form.tsx +++ b/ui/components/providers/workflow/forms/select-credentials-type/cloudflare/radio-group-cloudflare-via-credentials-type-form.tsx @@ -44,7 +44,7 @@ export const RadioGroupCloudflareViaCredentialsTypeForm = ({ {errorMessage && ( - + {errorMessage} )} diff --git a/ui/components/providers/workflow/forms/select-credentials-type/gcp/radio-group-gcp-via-credentials-type-form.tsx b/ui/components/providers/workflow/forms/select-credentials-type/gcp/radio-group-gcp-via-credentials-type-form.tsx index 279d17a790..1f32d154a7 100644 --- a/ui/components/providers/workflow/forms/select-credentials-type/gcp/radio-group-gcp-via-credentials-type-form.tsx +++ b/ui/components/providers/workflow/forms/select-credentials-type/gcp/radio-group-gcp-via-credentials-type-form.tsx @@ -47,7 +47,7 @@ export const RadioGroupGCPViaCredentialsTypeForm = ({ {errorMessage && ( - + {errorMessage} )} diff --git a/ui/components/providers/workflow/forms/select-credentials-type/github/radio-group-github-via-credentials-type-form.tsx b/ui/components/providers/workflow/forms/select-credentials-type/github/radio-group-github-via-credentials-type-form.tsx index f6964d98d0..fa2d5ab98f 100644 --- a/ui/components/providers/workflow/forms/select-credentials-type/github/radio-group-github-via-credentials-type-form.tsx +++ b/ui/components/providers/workflow/forms/select-credentials-type/github/radio-group-github-via-credentials-type-form.tsx @@ -54,7 +54,7 @@ export const RadioGroupGitHubViaCredentialsTypeForm = ({ {errorMessage && ( - + {errorMessage} )} diff --git a/ui/components/providers/workflow/forms/select-credentials-type/m365/radio-group-m365-via-credentials-type-form.tsx b/ui/components/providers/workflow/forms/select-credentials-type/m365/radio-group-m365-via-credentials-type-form.tsx index dcbba07d2b..ed871352a7 100644 --- a/ui/components/providers/workflow/forms/select-credentials-type/m365/radio-group-m365-via-credentials-type-form.tsx +++ b/ui/components/providers/workflow/forms/select-credentials-type/m365/radio-group-m365-via-credentials-type-form.tsx @@ -44,7 +44,7 @@ export const RadioGroupM365ViaCredentialsTypeForm = ({ {errorMessage && ( - + {errorMessage} )} diff --git a/ui/components/ui/form/Form.test.tsx b/ui/components/ui/form/Form.test.tsx new file mode 100644 index 0000000000..41f01750e5 --- /dev/null +++ b/ui/components/ui/form/Form.test.tsx @@ -0,0 +1,65 @@ +import { render, screen } from "@testing-library/react"; +import { useEffect } from "react"; +import { useForm } from "react-hook-form"; +import { describe, expect, it } from "vitest"; + +import { + Form, + FormControl, + FormField, + FormItem, + FormLabel, + FormMessage, +} from "./Form"; + +interface TestValues { + providerUid: string; +} + +function TestFormWithError() { + const form = useForm({ + defaultValues: { + providerUid: "", + }, + }); + + useEffect(() => { + form.setError("providerUid", { + type: "manual", + message: "Provider ID is required", + }); + }, [form]); + + return ( +
+ ( + + Provider UID + + + + + + )} + /> + + ); +} + +describe("Form", () => { + it("should use the existing error text token for labels and messages", async () => { + // Given + render(); + + // When + const label = await screen.findByText("Provider UID"); + const message = await screen.findByText("Provider ID is required"); + + // Then + expect(label).toHaveClass("text-text-error-primary"); + expect(message).toHaveClass("text-text-error-primary"); + }); +}); diff --git a/ui/components/ui/form/Form.tsx b/ui/components/ui/form/Form.tsx index f4cc7d5403..011b0e0492 100644 --- a/ui/components/ui/form/Form.tsx +++ b/ui/components/ui/form/Form.tsx @@ -100,7 +100,10 @@ const FormLabel = React.forwardRef< return (