-
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.
Merge branch 'next' into task/OV-5-JWT-token
- Loading branch information
Showing
10 changed files
with
202 additions
and
2 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
1 change: 1 addition & 0 deletions
1
frontend/src/bundles/common/components/loader/libs/constants/constants.ts
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 @@ | ||
export { SPIN_ANIMATION } from './spin-animation.constant.js'; |
8 changes: 8 additions & 0 deletions
8
frontend/src/bundles/common/components/loader/libs/constants/spin-animation.constant.ts
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,8 @@ | ||
import { keyframes } from '@chakra-ui/react'; | ||
|
||
const SPIN_ANIMATION = keyframes` | ||
0% { transform: rotate(0deg);} | ||
100% { transform: rotate(360deg)} | ||
`; | ||
|
||
export { SPIN_ANIMATION }; |
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,32 @@ | ||
import { Box, Circle, Flex, Text } from '@chakra-ui/react'; | ||
|
||
import { SPIN_ANIMATION } from './libs/constants/constants.js'; | ||
|
||
const Loader = (): JSX.Element => { | ||
return ( | ||
<Flex flexDirection="column" alignItems="center"> | ||
<Box position="relative" width="100px" height="100px"> | ||
<Circle | ||
size="full" | ||
backgroundColor="white" | ||
color="text.default" | ||
> | ||
LOGO | ||
</Circle> | ||
<Circle | ||
position="absolute" | ||
inset="0" | ||
borderWidth="5px" | ||
borderColor="shadow.200" | ||
borderTopColor="brand.secondary.300" | ||
animation={`${SPIN_ANIMATION} 1s linear infinite`} | ||
/> | ||
</Box> | ||
<Text fontSize="lg" marginTop="10px"> | ||
Loading... | ||
</Text> | ||
</Flex> | ||
); | ||
}; | ||
|
||
export { Loader }; |
26 changes: 26 additions & 0 deletions
26
frontend/src/bundles/common/components/overlay/overlay.tsx
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,26 @@ | ||
import { Fade, Flex } from '@chakra-ui/react'; | ||
|
||
type Properties = { | ||
isOpen: boolean; | ||
children: React.ReactNode; | ||
}; | ||
|
||
const Overlay = ({ isOpen, children }: Properties): JSX.Element => { | ||
return ( | ||
<Fade in={isOpen}> | ||
<Flex | ||
width="full" | ||
height="full" | ||
position="absolute" | ||
background="shadow.700" | ||
color="white" | ||
justifyContent="center" | ||
alignItems="center" | ||
> | ||
{children} | ||
</Flex> | ||
</Fade> | ||
); | ||
}; | ||
|
||
export { Overlay }; |
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 @@ | ||
export { UserCard } from './user-card/user-card.js'; |
32 changes: 32 additions & 0 deletions
32
frontend/src/bundles/users/components/user-card/user-card.tsx
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,32 @@ | ||
import { | ||
Button, | ||
Circle, | ||
Flex, | ||
Text, | ||
VStack, | ||
} from '~/bundles/common/components/components.js'; | ||
|
||
const UserCard: React.FC = () => ( | ||
<VStack rounded="lg" bg="background.600" spacing="10px" p="15px 5px 10px"> | ||
<Flex | ||
w="full" | ||
align="center" | ||
color="brand.secondary.900" | ||
gap="15px" | ||
pl="10px" | ||
> | ||
{/* TODO: replace Circle and Text content with dynamic values */} | ||
<Circle | ||
size="40px" | ||
border="2px solid" | ||
borderColor="brand.secondary.900" | ||
> | ||
FN | ||
</Circle> | ||
<Text>Firstname Lastname</Text> | ||
</Flex> | ||
<Button label="Create video" /> | ||
</VStack> | ||
); | ||
|
||
export { UserCard }; |
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