-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
61 changed files
with
1,280 additions
and
743 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,19 @@ | ||
export function EllipsisIcon() { | ||
return <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20" fill="none"> | ||
<path | ||
fillRule="evenodd" | ||
clipRule="evenodd" | ||
d="M4.16667 11.6674C3.94774 11.6674 3.73097 11.6242 3.52873 11.5404C3.32649 11.4565 3.14275 11.3337 2.98798 11.1788C2.83322 11.024 2.71047 10.8402 2.62674 10.6379C2.54301 10.4356 2.49995 10.2188 2.5 9.99992C2.50005 9.78099 2.54323 9.56422 2.62706 9.36199C2.71089 9.15975 2.83373 8.976 2.98857 8.82124C3.14341 8.66647 3.32722 8.54372 3.5295 8.45999C3.73178 8.37626 3.94858 8.3332 4.1675 8.33325C4.60964 8.33336 5.03362 8.50911 5.34618 8.82182C5.65874 9.13454 5.83428 9.55861 5.83417 10.0008C5.83406 10.4429 5.65831 10.8669 5.34559 11.1794C5.03288 11.492 4.6088 11.6675 4.16667 11.6674ZM9.80917 11.6674C9.36714 11.6674 8.94322 11.4918 8.63066 11.1793C8.31809 10.8667 8.1425 10.4428 8.1425 10.0008C8.1425 9.55872 8.31809 9.1348 8.63066 8.82224C8.94322 8.50968 9.36714 8.33409 9.80917 8.33409C10.2512 8.33409 10.6751 8.50968 10.9877 8.82224C11.3002 9.1348 11.4758 9.55872 11.4758 10.0008C11.4758 10.4428 11.3002 10.8667 10.9877 11.1793C10.6751 11.4918 10.2512 11.6674 9.80917 11.6674ZM15.4508 11.6674C15.2319 11.6674 15.0151 11.6242 14.8129 11.5404C14.6107 11.4565 14.4269 11.3337 14.2721 11.1788C14.1174 11.024 13.9946 10.8402 13.9109 10.6379C13.8272 10.4356 13.7841 10.2188 13.7842 9.99992C13.7842 9.78099 13.8274 9.56422 13.9112 9.36199C13.9951 9.15975 14.1179 8.976 14.2727 8.82124C14.4276 8.66647 14.6114 8.54372 14.8137 8.45999C15.016 8.37626 15.2327 8.3332 15.4517 8.33325C15.8938 8.33336 16.3178 8.50911 16.6304 8.82182C16.9429 9.13454 17.1184 9.55861 17.1183 10.0008C17.1182 10.4429 16.9425 10.8669 16.6298 11.1794C16.317 11.492 15.893 11.6675 15.4508 11.6674Z" | ||
fill="#BDBDBD" | ||
/> | ||
</svg> | ||
export function EllipsisIcon({ size }: { size: "sm" | "md" }) { | ||
const width = size === "sm" ? 12 : 20; | ||
return ( | ||
<svg | ||
xmlns="http://www.w3.org/2000/svg" | ||
width={width} | ||
height={width} | ||
viewBox="0 0 20 20" | ||
fill="none" | ||
> | ||
<path | ||
fillRule="evenodd" | ||
clipRule="evenodd" | ||
d="M4.16667 11.6674C3.94774 11.6674 3.73097 11.6242 3.52873 11.5404C3.32649 11.4565 3.14275 11.3337 2.98798 11.1788C2.83322 11.024 2.71047 10.8402 2.62674 10.6379C2.54301 10.4356 2.49995 10.2188 2.5 9.99992C2.50005 9.78099 2.54323 9.56422 2.62706 9.36199C2.71089 9.15975 2.83373 8.976 2.98857 8.82124C3.14341 8.66647 3.32722 8.54372 3.5295 8.45999C3.73178 8.37626 3.94858 8.3332 4.1675 8.33325C4.60964 8.33336 5.03362 8.50911 5.34618 8.82182C5.65874 9.13454 5.83428 9.55861 5.83417 10.0008C5.83406 10.4429 5.65831 10.8669 5.34559 11.1794C5.03288 11.492 4.6088 11.6675 4.16667 11.6674ZM9.80917 11.6674C9.36714 11.6674 8.94322 11.4918 8.63066 11.1793C8.31809 10.8667 8.1425 10.4428 8.1425 10.0008C8.1425 9.55872 8.31809 9.1348 8.63066 8.82224C8.94322 8.50968 9.36714 8.33409 9.80917 8.33409C10.2512 8.33409 10.6751 8.50968 10.9877 8.82224C11.3002 9.1348 11.4758 9.55872 11.4758 10.0008C11.4758 10.4428 11.3002 10.8667 10.9877 11.1793C10.6751 11.4918 10.2512 11.6674 9.80917 11.6674ZM15.4508 11.6674C15.2319 11.6674 15.0151 11.6242 14.8129 11.5404C14.6107 11.4565 14.4269 11.3337 14.2721 11.1788C14.1174 11.024 13.9946 10.8402 13.9109 10.6379C13.8272 10.4356 13.7841 10.2188 13.7842 9.99992C13.7842 9.78099 13.8274 9.56422 13.9112 9.36199C13.9951 9.15975 14.1179 8.976 14.2727 8.82124C14.4276 8.66647 14.6114 8.54372 14.8137 8.45999C15.016 8.37626 15.2327 8.3332 15.4517 8.33325C15.8938 8.33336 16.3178 8.50911 16.6304 8.82182C16.9429 9.13454 17.1184 9.55861 17.1183 10.0008C17.1182 10.4429 16.9425 10.8669 16.6298 11.1794C16.317 11.492 15.893 11.6675 15.4508 11.6674Z" | ||
fill="#BDBDBD" | ||
/> | ||
</svg> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
import { Box } from "@chakra-ui/react"; | ||
|
||
import { SECRET_USER_SUMMARY } from "../../constants/serviceConstants/userConstants"; | ||
import { useKeypadHeight } from "../../hooks/custom/useKeypadHeight"; | ||
import { ReplyProps } from "../../pageTemplates/square/SecretSquare/SecretSquareComments"; | ||
import { DispatchType } from "../../types/hooks/reactTypes"; | ||
import { IUserSummary } from "../../types/models/userTypes/userInfoTypes"; | ||
import { iPhoneNotchSize } from "../../utils/validationUtils"; | ||
import UserCommentInput from "../molecules/UserCommentInput"; | ||
|
||
interface BottomCommentInputProps { | ||
isFixed?: boolean; | ||
onSubmit: (value: string) => void; | ||
type?: "comment" | "message"; | ||
replyName: string; | ||
user: IUserSummary; | ||
setReplyProps: DispatchType<ReplyProps>; | ||
} | ||
|
||
function BottomCommentInput({ | ||
isFixed = true, | ||
onSubmit, | ||
type = "comment", | ||
replyName, | ||
user, | ||
setReplyProps, | ||
}: BottomCommentInputProps) { | ||
const keypadHeight = useKeypadHeight(); | ||
|
||
return ( | ||
<Box | ||
position={isFixed ? "fixed" : "static"} | ||
borderTop="var(--border)" | ||
borderBottom={isFixed ? null : "var(--border)"} | ||
mt={isFixed ? null : 5} | ||
bottom="0" | ||
flex={1} | ||
w="100%" | ||
backgroundColor="white" | ||
maxW="var(--max-width)" | ||
pb={`${keypadHeight === 0 ? iPhoneNotchSize() : 0}px`} | ||
> | ||
<Box py={2} borderBottom="var(--border)" px={5}> | ||
<UserCommentInput | ||
user={user || SECRET_USER_SUMMARY} | ||
onSubmit={onSubmit} | ||
type={type} | ||
replyName={replyName} | ||
setReplyProps={setReplyProps} | ||
/> | ||
</Box> | ||
</Box> | ||
); | ||
} | ||
|
||
export default BottomCommentInput; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
import { Box, Button } from "@chakra-ui/react"; | ||
|
||
import { iPhoneNotchSize } from "../../utils/validationUtils"; | ||
|
||
interface BottomFixedButton { | ||
text: string; | ||
func: () => void; | ||
} | ||
|
||
function BottomFixedButton({ text, func }: BottomFixedButton) { | ||
return ( | ||
<Box w="full" position="fixed" py={2} px={5} bottom={`${iPhoneNotchSize()}px`}> | ||
<Button | ||
size="lg" | ||
w="100%" | ||
maxW="var(--view-max-width)" | ||
borderRadius="12px" | ||
onClick={func} | ||
colorScheme={func ? "mint" : "blackAlpha"} | ||
> | ||
{text} | ||
</Button> | ||
</Box> | ||
); | ||
} | ||
|
||
export default BottomFixedButton; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.