X-Git-Url: https://git.localhorst.tv/?a=blobdiff_plain;f=resources%2Fjs%2Fcomponents%2Fusers%2FParticipation.js;h=d0d5d689658dc9f69608d1cf7ab41cae79d1f94a;hb=d611bc90eab94fbce54e9e5485f15c20abf1ad31;hp=e45fcf668e2fcc26c1bb0121ea6a77bc36a54e68;hpb=80befc9403845a0f41f5f7e766938b0bbf607d7e;p=alttp.git diff --git a/resources/js/components/users/Participation.js b/resources/js/components/users/Participation.js index e45fcf6..d0d5d68 100644 --- a/resources/js/components/users/Participation.js +++ b/resources/js/components/users/Participation.js @@ -1,6 +1,6 @@ import PropTypes from 'prop-types'; import React from 'react'; -import { Alert, Button } from 'react-bootstrap'; +import { Alert, Button, Table } from 'react-bootstrap'; import { withTranslation } from 'react-i18next'; import { useNavigate } from 'react-router-dom'; @@ -14,16 +14,34 @@ const Participation = ({ user }) => { {i18n.t('users.participationEmpty')} ; } - return
- {user.participation.map(p =>
- -
)} -
; + return + + + + + + + + {user.participation.map(p => + + + )} + +
{i18n.t('participants.tournament')}{i18n.t('participants.roles')}
+ + + {p.roles ? p.roles.map((role, index) => + + {index === 0 ? '' : ', '} + {i18n.t(`participants.roleNames.${role}`)} + + ) : null} +
; }; Participation.propTypes = {