mirror of
https://github.com/prowler-cloud/prowler.git
synced 2026-04-15 00:57:55 +00:00
feat(ui): add S3 bucket link with folder for each integration (#8554)
Co-authored-by: alejandrobailo <alejandrobailo94@gmail.com>
This commit is contained in:
@@ -322,8 +322,10 @@ export const S3IntegrationsManager = ({
|
||||
connectionStatus={{
|
||||
connected: integration.attributes.connected,
|
||||
}}
|
||||
navigationUrl={`https://console.aws.amazon.com/s3/buckets/${integration.attributes.configuration.bucket_name}`}
|
||||
/>
|
||||
</CardHeader>
|
||||
|
||||
<CardBody className="pt-0">
|
||||
<div className="flex flex-col gap-3 sm:flex-row sm:items-center sm:justify-between">
|
||||
<div className="text-xs text-gray-500 dark:text-gray-300">
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
"use client";
|
||||
|
||||
import { Chip } from "@nextui-org/react";
|
||||
import { ExternalLink } from "lucide-react";
|
||||
import { ReactNode } from "react";
|
||||
|
||||
interface IntegrationCardHeaderProps {
|
||||
@@ -22,6 +23,7 @@ interface IntegrationCardHeaderProps {
|
||||
connected: boolean;
|
||||
label?: string;
|
||||
};
|
||||
navigationUrl?: string;
|
||||
}
|
||||
|
||||
export const IntegrationCardHeader = ({
|
||||
@@ -30,13 +32,27 @@ export const IntegrationCardHeader = ({
|
||||
subtitle,
|
||||
chips = [],
|
||||
connectionStatus,
|
||||
navigationUrl,
|
||||
}: IntegrationCardHeaderProps) => {
|
||||
return (
|
||||
<div className="flex w-full flex-col gap-3 sm:flex-row sm:items-center sm:justify-between">
|
||||
<div className="flex items-center gap-3">
|
||||
{icon}
|
||||
<div>
|
||||
<h4 className="text-md font-semibold">{title}</h4>
|
||||
<div className="flex items-center gap-2">
|
||||
<h4 className="text-md font-semibold">{title}</h4>
|
||||
{navigationUrl && (
|
||||
<a
|
||||
target="_blank"
|
||||
rel="noopener noreferrer"
|
||||
className="text-black dark:text-white"
|
||||
href={navigationUrl}
|
||||
aria-label="open bucket in new tab"
|
||||
>
|
||||
<ExternalLink size={16} />
|
||||
</a>
|
||||
)}
|
||||
</div>
|
||||
{subtitle && (
|
||||
<p className="text-xs text-gray-500 dark:text-gray-300">
|
||||
{subtitle}
|
||||
|
||||
Reference in New Issue
Block a user