merge main

This commit is contained in:
Scott Wilson
2025-09-15 15:06:42 -07:00
605 changed files with 11025 additions and 4114 deletions
@@ -16,7 +16,7 @@ import { Link, Outlet, useLocation } from "@tanstack/react-router";
import { motion } from "framer-motion";
import { Badge, Lottie, Menu, MenuGroup, MenuItem } from "@app/components/v2";
import { useProjectPermission, useWorkspace } from "@app/context";
import { useProject, useProjectPermission } from "@app/context";
import {
useGetAccessRequestsCount,
useGetSecretApprovalRequestCount,
@@ -26,16 +26,15 @@ import {
import { AssumePrivilegeModeBanner } from "../ProjectLayout/components/AssumePrivilegeModeBanner";
export const SecretManagerLayout = () => {
const { currentWorkspace } = useWorkspace();
const { currentProject, projectId } = useProject();
const { assumedPrivilegeDetails } = useProjectPermission();
const { t } = useTranslation();
const workspaceId = currentWorkspace?.id || "";
const projectSlug = currentWorkspace?.slug || "";
const projectSlug = currentProject?.slug || "";
const location = useLocation();
const { data: secretApprovalReqCount } = useGetSecretApprovalRequestCount({
workspaceId
projectId
});
const { data: accessApprovalRequestCount } = useGetAccessRequestsCount({
projectSlug
@@ -43,7 +42,7 @@ export const SecretManagerLayout = () => {
// we only show the secret rotations v1 tab if they have existing rotations
const { data: secretRotations } = useGetSecretRotations({
workspaceId,
workspaceId: projectId,
options: {
refetchOnMount: false
}
@@ -75,9 +74,9 @@ export const SecretManagerLayout = () => {
<Link
to="/projects/secret-management/$projectId/overview"
params={{
projectId: currentWorkspace.id,
...(currentWorkspace.environments.length
? { envSlug: currentWorkspace.environments[0]?.slug }
projectId: currentProject.id,
...(currentProject.environments.length
? { envSlug: currentProject.environments[0]?.slug }
: {})
}}
>
@@ -86,7 +85,7 @@ export const SecretManagerLayout = () => {
isSelected={
isActive ||
location.pathname.startsWith(
`/projects/secret-management/${currentWorkspace.id}/overview`
`/projects/secret-management/${currentProject.id}/overview`
)
}
>
@@ -102,7 +101,7 @@ export const SecretManagerLayout = () => {
<Link
to="/projects/secret-management/$projectId/integrations"
params={{
projectId: currentWorkspace.id
projectId: currentProject.id
}}
>
{({ isActive }) => (
@@ -120,7 +119,7 @@ export const SecretManagerLayout = () => {
<Link
to="/projects/secret-management/$projectId/secret-rotation"
params={{
projectId: currentWorkspace.id
projectId: currentProject.id
}}
>
{({ isActive }) => (
@@ -138,7 +137,7 @@ export const SecretManagerLayout = () => {
<Link
to="/projects/secret-management/$projectId/approval"
params={{
projectId: currentWorkspace.id
projectId: currentProject.id
}}
>
{({ isActive }) => (
@@ -163,7 +162,7 @@ export const SecretManagerLayout = () => {
<Link
to="/projects/secret-management/$projectId/app-connections"
params={{
projectId: currentWorkspace.id
projectId: currentProject.id
}}
>
{({ isActive }) => (
@@ -182,7 +181,7 @@ export const SecretManagerLayout = () => {
<Link
to="/projects/secret-management/$projectId/access-management"
params={{
projectId: currentWorkspace.id
projectId: currentProject.id
}}
>
{({ isActive }) => (
@@ -199,7 +198,7 @@ export const SecretManagerLayout = () => {
<Link
to="/projects/secret-management/$projectId/audit-logs"
params={{
projectId: currentWorkspace.id
projectId: currentProject.id
}}
>
{({ isActive }) => (
@@ -216,7 +215,7 @@ export const SecretManagerLayout = () => {
<Link
to="/projects/secret-management/$projectId/settings"
params={{
projectId: currentWorkspace.id
projectId: currentProject.id
}}
>
{({ isActive }) => (