<html>
<%- include("partials/header.ejs") %>
<body>
    <%- include("partials/navbar.ejs") %>
    <div class="container">
        <h1 class="text-center my-5"><%= user.username %> infos</h1>
        <div class="row justify-content-center">
            <div class="col-lg-6">
                <table class="table table-striped">
                    <tr>
                        <th>Nom d'utilisateur</th>
                        <td><%= user.username %></td>
                    </tr>
                    <tr>
                        <th>Discord</th>
                        <td><%= user.discord %></td>
                    </tr>
                    <tr>
                        <th>Faction</th>
                        <td><% if(faction){ %><a href="/factions/faction/<%= faction._id %>"><%= faction.name %></a><%} else{ %> Aucune faction <% }%></td>
                    </tr>
                    <tr>
                        <th>Grade</th>
                        <td><% if(user.isFactionLeader){%> Chef <%} else{%> Membre <% } %></td>
                    </tr>
                </table>
            </div>
        </div>
    </div>
    <%- include("partials/footer.ejs") %>
</body>
</html>