Better looking user list
This commit is contained in:
parent
83a966f1af
commit
27c780602c
2 changed files with 55 additions and 41 deletions
|
@ -1,27 +1,3 @@
|
||||||
.user img {
|
|
||||||
width: 100px;
|
|
||||||
height: 100px;
|
|
||||||
float: left;
|
|
||||||
margin-right: 0.5em;
|
|
||||||
}
|
|
||||||
.user h1 {
|
|
||||||
margin-top: 0;
|
|
||||||
margin-bottom: 0.25em;
|
|
||||||
}
|
|
||||||
|
|
||||||
.user {
|
|
||||||
line-height: 1.5em;
|
|
||||||
margin-bottom: 1em;
|
|
||||||
margin-right: 1em;
|
|
||||||
display: inline-block;
|
|
||||||
}
|
|
||||||
|
|
||||||
.user .details {
|
|
||||||
display: inline-block;
|
|
||||||
max-width: 25em;
|
|
||||||
white-space: pre;
|
|
||||||
}
|
|
||||||
|
|
||||||
nav.sort-styles ul {
|
nav.sort-styles ul {
|
||||||
list-style-type: none;
|
list-style-type: none;
|
||||||
margin: 0 0 2.5em 0;
|
margin: 0 0 2.5em 0;
|
||||||
|
@ -37,3 +13,39 @@ nav.sort-styles li {
|
||||||
nav.sort-styles li.active {
|
nav.sort-styles li.active {
|
||||||
border-bottom: 3px solid firebrick;
|
border-bottom: 3px solid firebrick;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.users-wrapper {
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
.users {
|
||||||
|
column-width: 20em;
|
||||||
|
-moz-column-width: 20em;
|
||||||
|
-webkit-column-width: 20em;
|
||||||
|
}
|
||||||
|
|
||||||
|
.user {
|
||||||
|
text-align: initial;
|
||||||
|
line-height: 1.5em;
|
||||||
|
margin-bottom: 1em;
|
||||||
|
margin-right: 1em;
|
||||||
|
white-space: pre;
|
||||||
|
}
|
||||||
|
|
||||||
|
.user a.avatar {
|
||||||
|
display: block;
|
||||||
|
float: left;
|
||||||
|
}
|
||||||
|
.user img {
|
||||||
|
width: 100px;
|
||||||
|
height: 100px;
|
||||||
|
margin-right: 1em;
|
||||||
|
}
|
||||||
|
.user .details {
|
||||||
|
display: inline-block;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
}
|
||||||
|
|
||||||
|
.user h1 {
|
||||||
|
margin-top: 0;
|
||||||
|
margin-bottom: 0.25em;
|
||||||
|
}
|
||||||
|
|
|
@ -36,25 +36,27 @@ if ($this->context->user->hasEnabledEndlessScrolling())
|
||||||
<?php if (empty($this->context->transport->users)): ?>
|
<?php if (empty($this->context->transport->users)): ?>
|
||||||
<p class="alert alert-warning">No users to show.</p>
|
<p class="alert alert-warning">No users to show.</p>
|
||||||
<?php else: ?>
|
<?php else: ?>
|
||||||
<div class="users paginator-content">
|
<div class="users-wrapper">
|
||||||
<?php foreach ($this->context->transport->users as $user): ?>
|
<div class="users paginator-content">
|
||||||
<div class="user">
|
<?php foreach ($this->context->transport->users as $user): ?>
|
||||||
<a href="<?php echo \Chibi\UrlHelper::route('user', 'view', ['name' => $user->name]) ?>">
|
<div class="user">
|
||||||
<img src="<?php echo htmlspecialchars($user->getAvatarUrl(100)) ?>" alt="<?php echo $user->name ?>"/>
|
<a class="avatar" href="<?php echo \Chibi\UrlHelper::route('user', 'view', ['name' => $user->name]) ?>">
|
||||||
</a>
|
<img src="<?php echo htmlspecialchars($user->getAvatarUrl(100)) ?>" alt="<?php echo $user->name ?>"/>
|
||||||
<div class="details">
|
</a>
|
||||||
<h1>
|
<div class="details">
|
||||||
<a href="<?php echo \Chibi\UrlHelper::route('user', 'view', ['name' => $user->name]) ?>">
|
<h1>
|
||||||
<?php echo $user->name ?>
|
<a href="<?php echo \Chibi\UrlHelper::route('user', 'view', ['name' => $user->name]) ?>">
|
||||||
</a>
|
<?php echo $user->name ?>
|
||||||
</h1>
|
</a>
|
||||||
|
</h1>
|
||||||
|
|
||||||
<div class="date-registered">Date registered: <?php echo date('Y-m-d H:i', $user->joinDate) ?></div>
|
<div class="date-registered">Registered: <?php echo date('Y-m-d H:i', $user->joinDate) ?></div>
|
||||||
<div class="fav-count">Favorite count: <?php echo $user->getFavoriteCount() ?></div>
|
<div class="fav-count">Favorite count: <?php echo $user->getFavoriteCount() ?></div>
|
||||||
<div class="post-count">Post count: <?php echo $user->getPostCount() ?></div>
|
<div class="post-count">Post count: <?php echo $user->getPostCount() ?></div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
<?php endforeach ?>
|
||||||
<?php endforeach ?>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<?php $this->renderFile('paginator') ?>
|
<?php $this->renderFile('paginator') ?>
|
||||||
|
|
Loading…
Reference in a new issue