Toggle navigation
Toggle navigation
This project
Loading...
Sign in
강동현
/
nodejs-game
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
Overnap
2021-05-31 04:54:59 +0900
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
8be6e0afb0253db7a68cc2182502499720e33b49
8be6e0af
1 parent
6037546b
방 정보 컴포넌트 추가
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
23 additions
and
0 deletions
web/src/components/rooms/RoomInfo.tsx
web/src/components/rooms/types.ts
web/src/components/rooms/RoomInfo.tsx
0 → 100644
View file @
8be6e0a
import React from 'react';
import { Room } from './types';
export const RoomInfo: React.FC<Room> = (props: Room) => {
return (
<div className={`flex items-center place-content-between m-2 w-5/6
${props.currentUsers < props.maxUsers ?
'bg-white active:bg-green-100' :
'bg-gray-200 active:bg-gray-200'}
rounded shadow hover:shadow-md`}>
<span className='mt-2 mb-2 ml-3 text-gray-600 text-lg'>{props.name}</span>
<span className='mt-2 mb-2 mr-3 text-gray-500 text-right'>
{props.currentUsers}/{props.maxUsers}
</span>
</div>
);
}
web/src/components/rooms/types.ts
0 → 100644
View file @
8be6e0a
export
interface
Room
{
uuid
:
string
;
name
:
string
;
currentUsers
:
number
;
maxUsers
:
number
;
}
Please
register
or
login
to post a comment