feat(ui): resolved dynamic secret merge conflict

This commit is contained in:
Akhil Mohan
2024-03-26 19:45:52 +05:30
parent 282434de8e
commit b912cd585c
8 changed files with 17 additions and 13 deletions

View File

@@ -23,7 +23,7 @@ export const createNotification = (
position: "bottom-right",
...toastProps,
theme: "dark",
type: myProps?.type || "info"
type: myProps?.type || "info",
});
export const NotificationContainer = () => <ToastContainer hideProgressBar />;

View File

@@ -9,6 +9,10 @@ html {
--toastify-color-dark: theme(colors.mineshaft.700);
}
.Toastify__toast {
@apply rounded-md;
}
.rdp-day,
.rdp-nav_button {
@apply rounded-md hover:text-mineshaft-500;

View File

@@ -3,8 +3,8 @@ import { zodResolver } from "@hookform/resolvers/zod";
import ms from "ms";
import { z } from "zod";
import { useNotificationContext } from "@app/components/context/Notifications/NotificationProvider";
import { TtlFormLabel } from "@app/components/features";
import { createNotification } from "@app/components/notifications";
import {
Accordion,
AccordionContent,
@@ -91,7 +91,7 @@ export const SqlDatabaseInputForm = ({
}
}
});
const { createNotification } = useNotificationContext();
const createDynamicSecret = useCreateDynamicSecret();
const handleCreateDynamicSecret = async ({ name, maxTTL, provider, defaultTTL }: TForm) => {

View File

@@ -6,8 +6,8 @@ import { AnimatePresence, motion } from "framer-motion";
import ms from "ms";
import { z } from "zod";
import { useNotificationContext } from "@app/components/context/Notifications/NotificationProvider";
import { TtlFormLabel } from "@app/components/features";
import { createNotification } from "@app/components/notifications";
import { Button, FormControl, IconButton, Input, SecretInput, Tooltip } from "@app/components/v2";
import { useTimedReset } from "@app/hooks";
import { useCreateDynamicSecretLease } from "@app/hooks/api";
@@ -102,7 +102,7 @@ export const CreateDynamicSecretLease = ({
ttl: "1h"
}
});
const { createNotification } = useNotificationContext();
const createDynamicSecretLease = useCreateDynamicSecretLease();

View File

@@ -9,7 +9,7 @@ import {
import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";
import { format, formatDistance } from "date-fns";
import { useNotificationContext } from "@app/components/context/Notifications/NotificationProvider";
import { createNotification } from "@app/components/notifications";
import { ProjectPermissionCan } from "@app/components/permissions";
import {
Button,
@@ -60,7 +60,7 @@ export const DynamicSecretLease = ({
path: secretPath,
dynamicSecretName
});
const { createNotification } = useNotificationContext();
const deleteDynamicSecretLease = useRevokeDynamicSecretLease();

View File

@@ -7,7 +7,7 @@ import {
} from "@fortawesome/free-solid-svg-icons";
import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";
import { useNotificationContext } from "@app/components/context/Notifications/NotificationProvider";
import { createNotification } from "@app/components/notifications";
import { ProjectPermissionCan } from "@app/components/permissions";
import {
Button,
@@ -59,7 +59,7 @@ export const DynamicSecretListView = ({
"deleteDynamicSecret"
] as const);
const { createNotification } = useNotificationContext();
const deleteDynamicSecret = useDeleteDynamicSecret();
const handleDynamicSecretDelete = async () => {

View File

@@ -3,8 +3,8 @@ import { zodResolver } from "@hookform/resolvers/zod";
import ms from "ms";
import { z } from "zod";
import { useNotificationContext } from "@app/components/context/Notifications/NotificationProvider";
import { TtlFormLabel } from "@app/components/features";
import { createNotification } from "@app/components/notifications";
import {
Accordion,
AccordionContent,
@@ -94,7 +94,7 @@ export const EditDynamicSecretSqlProviderForm = ({
}
}
});
const { createNotification } = useNotificationContext();
const updateDynamicSecret = useUpdateDynamicSecret();
const handleUpdateDynamicSecret = async ({ inputs, maxTTL, defaultTTL, newName }: TForm) => {

View File

@@ -3,8 +3,8 @@ import { zodResolver } from "@hookform/resolvers/zod";
import ms from "ms";
import { z } from "zod";
import { useNotificationContext } from "@app/components/context/Notifications/NotificationProvider";
import { TtlFormLabel } from "@app/components/features";
import { createNotification } from "@app/components/notifications";
import { Button, FormControl, Input } from "@app/components/v2";
import { useRenewDynamicSecretLease } from "@app/hooks/api";
@@ -48,7 +48,7 @@ export const RenewDynamicSecretLease = ({
ttl: "1h"
}
});
const { createNotification } = useNotificationContext();
const renewDynamicSecretLease = useRenewDynamicSecretLease();