diff --git a/docs/api-reference/endpoints/project-identities/get-by-id.mdx b/docs/api-reference/endpoints/project-identities/get-by-id.mdx index a1f877314..bd9d0dd6f 100644 --- a/docs/api-reference/endpoints/project-identities/get-by-id.mdx +++ b/docs/api-reference/endpoints/project-identities/get-by-id.mdx @@ -1,4 +1,4 @@ --- -title: "Get Identity By Id" +title: "Get Identity by ID" openapi: "GET /api/v1/projects/{projectId}/identities/{identityId}" --- diff --git a/docs/api-reference/endpoints/project-identities/list-identity.mdx b/docs/api-reference/endpoints/project-identities/list-identity.mdx index c6b1bc1e4..3070b39e7 100644 --- a/docs/api-reference/endpoints/project-identities/list-identity.mdx +++ b/docs/api-reference/endpoints/project-identities/list-identity.mdx @@ -1,4 +1,4 @@ --- -title: "List Identity" -openapi: "POST /api/v1/projects/{projectId}/identities" +title: "List Identities" +openapi: "GET /api/v1/projects/{projectId}/identities" --- diff --git a/frontend/src/components/v2/Alert/Alert.tsx b/frontend/src/components/v2/Alert/Alert.tsx index f4910e495..70d0d5fc8 100644 --- a/frontend/src/components/v2/Alert/Alert.tsx +++ b/frontend/src/components/v2/Alert/Alert.tsx @@ -9,7 +9,7 @@ import { cva, type VariantProps } from "cva"; import { twMerge } from "tailwind-merge"; const alertVariants = cva( - "w-full bg-mineshaft-800 rounded-lg border border-bunker-400 px-4 py-3 text-sm flex items-center gap-x-4", + "w-full bg-mineshaft-800 rounded-lg border border-bunker-400 px-4 py-3 text-sm flex items-center gap-x-3", { variants: { variant: { @@ -28,6 +28,7 @@ type AlertProps = { title?: string; hideTitle?: boolean; icon?: React.ReactNode; + iconClassName?: string; }; const variantTitleMap = { @@ -45,36 +46,41 @@ const variantIconMap = { const Alert = forwardRef< HTMLDivElement, React.HTMLAttributes & VariantProps & AlertProps ->(({ className, variant, title, icon, hideTitle = false, children, ...props }, ref) => { - const defaultTitle = title ?? variantTitleMap[variant ?? "default"]; - return ( -
-
- {typeof icon !== "undefined" ? ( - <>{icon} - ) : ( - - )} +>( + ( + { className, variant, title, icon, hideTitle = false, children, iconClassName, ...props }, + ref + ) => { + const defaultTitle = title ?? variantTitleMap[variant ?? "default"]; + return ( +
+
+ {typeof icon !== "undefined" ? ( + <>{icon} + ) : ( + + )} +
+
+ {hideTitle ? null : ( +
+ {defaultTitle} +
+ )} + {children} +
-
- {hideTitle ? null : ( -
- {defaultTitle} -
- )} - {children} -
-
- ); -}); + ); + } +); Alert.displayName = "Alert"; const AlertDescription = forwardRef< diff --git a/frontend/src/pages/project/IdentityDetailsByIDPage/IdentityDetailsByIDPage.tsx b/frontend/src/pages/project/IdentityDetailsByIDPage/IdentityDetailsByIDPage.tsx index 1690e3637..e8a7d39e0 100644 --- a/frontend/src/pages/project/IdentityDetailsByIDPage/IdentityDetailsByIDPage.tsx +++ b/frontend/src/pages/project/IdentityDetailsByIDPage/IdentityDetailsByIDPage.tsx @@ -8,7 +8,7 @@ import { Link, useNavigate, useParams } from "@tanstack/react-router"; import { formatRelative } from "date-fns"; import { createNotification } from "@app/components/notifications"; -import { ProjectPermissionCan } from "@app/components/permissions"; +import { OrgPermissionCan, ProjectPermissionCan } from "@app/components/permissions"; import { Alert, AlertDescription, @@ -20,6 +20,8 @@ import { Spinner } from "@app/components/v2"; import { + OrgPermissionIdentityActions, + OrgPermissionSubjects, ProjectPermissionActions, ProjectPermissionIdentityActions, ProjectPermissionSub, @@ -211,19 +213,28 @@ const Page = () => {
{!isProjectIdentity && ( - + This identity is managed by your organization.{" "} - - - Click here to retrieve credentials. - - + {(isAllowed) => + isAllowed ? ( + + + Click here to manage identity. + + + ) : null + } + )}