Commit 494e8090 authored by Alfredo Sumaran's avatar Alfredo Sumaran

Add rows hover state and improve layout for mobile

parent e21d9e88
...@@ -102,70 +102,71 @@ export default { ...@@ -102,70 +102,71 @@ export default {
:id="groupDomId" :id="groupDomId"
:class="rowClass" :class="rowClass"
> >
<div class="controls"> <div class="group-row-contents">
<a <div class="controls">
v-if="group.canEdit" <a
class="edit-group btn" v-if="group.canEdit"
:href="group.editPath"> class="edit-group btn"
<i aria-hidden="true" class="fa fa-cogs"></i> :href="group.editPath">
</a> <i aria-hidden="true" class="fa fa-cogs"></i>
<a @click="onLeaveGroup" </a>
:href="group.leavePath" <a @click="onLeaveGroup"
class="leave-group btn" :href="group.leavePath"
title="Leave this group"> class="leave-group btn"
<i aria-hidden="true" class="fa fa-sign-out"></i> title="Leave this group">
</a> <i aria-hidden="true" class="fa fa-sign-out"></i>
</div> </a>
</div>
<div class="stats"> <div class="stats">
<span class="number-projects"> <span class="number-projects">
<i aria-hidden="true" class="fa fa-bookmark"></i> <i aria-hidden="true" class="fa fa-bookmark"></i>
{{group.numberProjects}} {{group.numberProjects}}
</span> </span>
<span class="number-users"> <span class="number-users">
<i aria-hidden="true" class="fa fa-users"></i> <i aria-hidden="true" class="fa fa-users"></i>
{{group.numberUsers}} {{group.numberUsers}}
</span> </span>
<span class="group-visibility"> <span class="group-visibility">
<i aria-hidden="true" :class="visibilityIcon"></i> <i aria-hidden="true" :class="visibilityIcon"></i>
</span> </span>
</div> </div>
<div class="folder-toggle-wrap"> <div class="folder-toggle-wrap">
<span class="folder-caret" v-if="group.hasSubgroups"> <span class="folder-caret" v-if="group.hasSubgroups">
<i <i
v-if="group.isOpen" v-if="group.isOpen"
class="fa fa-caret-down" /> class="fa fa-caret-down" />
<i <i
v-if="!group.isOpen" v-if="!group.isOpen"
class="fa fa-caret-right" /> class="fa fa-caret-right" />
</span> </span>
<span class="folder-icon"> <span class="folder-icon">
<i <i
v-if="group.isOpen" v-if="group.isOpen"
class="fa fa-folder-open" class="fa fa-folder-open"
aria-hidden="true"></i> aria-hidden="true"></i>
<i <i
v-if="!group.isOpen" v-if="!group.isOpen"
class="fa fa-folder"></i> class="fa fa-folder"></i>
</span> </span>
</div> </div>
<div class="avatar-container s40"> <div class="avatar-container s40 hidden-xs">
<a href="/h5bp"> <a :href="group.webUrl">
<img class="avatar s40 hidden-xs" src="http://localhost:3000/uploads/group/avatar/2/logo-extra-whitespace.png" alt="Logo extra whitespace"> <img class="avatar s40" :src="group.avatarUrl" />
</a> </a>
</div> </div>
<div class="title"> <div class="title">
<a :href="group.webUrl">{{fullPath}}</a> <a :href="group.webUrl">{{fullPath}}</a>
</div> </div>
<div class="description"> <div class="description">
{{group.description}} {{group.description}}
</div>
</div> </div>
<group-folder v-if="group.isOpen && hasGroups" :groups="group.subGroups" :baseGroup="group" /> <group-folder v-if="group.isOpen && hasGroups" :groups="group.subGroups" :baseGroup="group" />
</li> </li>
</template> </template>
...@@ -116,6 +116,7 @@ export default class GroupsStore { ...@@ -116,6 +116,7 @@ export default class GroupsStore {
id: rawGroup.id, id: rawGroup.id,
fullName: rawGroup.full_name, fullName: rawGroup.full_name,
fullPath: rawGroup.full_path, fullPath: rawGroup.full_path,
avatarUrl: rawGroup.avatar_url,
name: rawGroup.name, name: rawGroup.name,
hasSubgroups: rawGroup.has_subgroups, hasSubgroups: rawGroup.has_subgroups,
canEdit: rawGroup.can_edit, canEdit: rawGroup.can_edit,
......
...@@ -302,10 +302,9 @@ ul.indent-list { ...@@ -302,10 +302,9 @@ ul.indent-list {
} }
.group-list-tree { .group-list-tree {
margin-top: 10px;
margin-bottom: 0; margin-bottom: 0;
margin-left: 20px; margin-left: 20px;
border-top: solid 1px $border-white-light; // border-top: solid 1px $border-white-light;
position: relative; position: relative;
&::before { &::before {
...@@ -313,7 +312,7 @@ ul.indent-list { ...@@ -313,7 +312,7 @@ ul.indent-list {
display: block; display: block;
width: 0; width: 0;
position: absolute; position: absolute;
top: 0; top: 5px;
bottom: 0; bottom: 0;
left: -16px; left: -16px;
border-left: 2px solid $border-white-normal; border-left: 2px solid $border-white-normal;
...@@ -341,6 +340,23 @@ ul.indent-list { ...@@ -341,6 +340,23 @@ ul.indent-list {
} }
} }
} }
.group-row {
padding: 0;
border: none;
}
.group-row-contents {
padding: 10px 10px 8px 10px;
border-top: solid 1px transparent;
border-bottom: solid 1px $white-normal;
&:hover{
border-color: $row-hover-border;
background-color: $row-hover;
cursor: pointer;
}
}
} }
.js-groups-list-holder { .js-groups-list-holder {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment