more improvements

This commit is contained in:
talksik
2022-01-19 04:04:47 -08:00
parent e408f7a221
commit cfab31dec2
3 changed files with 15 additions and 5 deletions
+8 -2
View File
@@ -2,7 +2,7 @@ import { Divider, Select, Switch, Tooltip } from "antd";
const { Option } = Select;
import Modal from "antd/lib/modal/Modal";
import { useState } from "react";
import { useEffect, useState } from "react";
import toast from "react-hot-toast";
import { useAuth } from "../../contexts/authContext";
import {
@@ -18,9 +18,15 @@ const sendService = new SendService();
export default function CreateOrUpdateLink() {
const { currUser } = useAuth();
const { handleModalType, showModalType } = useKeyboardContext();
const { pastedLink, handleModalType, showModalType } = useKeyboardContext();
const { teamUsers, team } = useTeamDashboardContext();
useEffect(() => {
if (pastedLink) {
setLink(pastedLink ?? "");
}
}, [pastedLink]);
function closeModal() {
handleModalType(ShowModalType.na);
}