Don't prompt to comment on FR bets, arrow spacing

This commit is contained in:
Ian Philips 2022-06-23 16:09:26 -05:00
parent b5810481d0
commit 17ac6c58b2
2 changed files with 2 additions and 18 deletions

View File

@ -88,26 +88,11 @@ export function FeedAnswerCommentGroup(props: {
}
)
useEffect(() => {
if (
mostRecentCommentableBet &&
usersMostRecentBetTimeAtLoad !== undefined &&
mostRecentCommentableBet.createdTime > usersMostRecentBetTimeAtLoad &&
!showReply
)
scrollAndOpenReplyInput(undefined, answer)
}, [
answer,
usersMostRecentBetTimeAtLoad,
mostRecentCommentableBet,
scrollAndOpenReplyInput,
showReply,
])
useEffect(() => {
// Only show one comment input for a bet at a time
if (
betsByCurrentUser.length > 1 &&
inputRef?.textContent?.length === 0 &&
betsByCurrentUser.sort((a, b) => b.createdTime - a.createdTime)[0]
?.outcome !== answer.number.toString()
)

View File

@ -530,8 +530,7 @@ export function CommentInputTextArea(props: {
{user && !isSubmitting && (
<button
className={clsx(
'btn btn-ghost btn-sm absolute right-2 flex-row pl-2 capitalize',
isReply ? ' bottom-4' : ' bottom-2',
'btn btn-ghost btn-sm absolute right-2 bottom-2 flex-row pl-2 capitalize',
!commentText && 'pointer-events-none text-gray-500'
)}
onClick={() => {