refactor: more TS code

This commit is contained in:
Tristan Yang
2022-07-29 08:49:34 +08:00
parent 43a13f8d08
commit 96017c8fc6
21 changed files with 150 additions and 90 deletions
@@ -1,3 +1,4 @@
import { FC } from "react";
import styled from "styled-components";
import { useReactMessageMutation } from "../../../app/services/message";
import { Emojis } from "../../../app/config";
@@ -34,8 +35,11 @@ const StyledPicker = styled.div`
}
}
`;
export default function ReactionPicker({ mid, hidePicker }) {
type Props = {
mid: number;
hidePicker: () => void;
};
const ReactionPicker: FC<Props> = ({ mid, hidePicker }) => {
const [reactMessage, { isLoading }] = useReactMessageMutation();
const { reactionData, currUid } = useAppSelector((store) => {
return {
@@ -68,4 +72,5 @@ export default function ReactionPicker({ mid, hidePicker }) {
</ul>
</StyledPicker>
);
}
};
export default ReactionPicker;