Skip to content

Commit

Permalink
Move user-action dropdown on the left
Browse files Browse the repository at this point in the history
  • Loading branch information
kimsible committed Jul 29, 2020
1 parent 93cb466 commit bbfd2a4
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 10 deletions.
16 changes: 7 additions & 9 deletions client/src/app/+admin/users/user-list/user-list.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ <h6 class="dropdown-header" i18n>Advanced user filters</h6>
<th style="width: 60px;">
<div class="c-hand" ngbDropdown placement="bottom-right auto" container="body" autoClose="outside">
<my-global-icon iconName="columns" ngbDropdownToggle></my-global-icon>

<div role="menu" class="dropdown-menu" ngbDropdownMenu>
<div class="dropdown-header" i18n>Table parameters</div>
<div ngbDropdownItem class="dropdown-item">
Expand Down Expand Up @@ -95,6 +95,12 @@ <h6 class="dropdown-header" i18n>Advanced user filters</h6>
</span>
</td>

<td class="action-cell">
<my-user-moderation-dropdown *ngIf="!isInSelectionMode()" [user]="user" container="body"
(userChanged)="onUserChanged()" (userDeleted)="onUserChanged()">
</my-user-moderation-dropdown>
</td>

<td *ngIf="getColumn('username')">
<a i18n-title title="Open account in a new tab" target="_blank" rel="noopener noreferrer" [routerLink]="[ '/accounts/' + user.username ]">
<div class="chip two-lines">
Expand Down Expand Up @@ -161,14 +167,6 @@ <h6 class="dropdown-header" i18n>Advanced user filters</h6>
<td *ngIf="getColumn('createdAt')" [title]="user.createdAt">{{ user.createdAt | date: 'short' }}</td>

<td *ngIf="getColumn('lastLoginDate')" [title]="user.lastLoginDate">{{ user.lastLoginDate | date: 'short' }}</td>

<td class="action-cell">
<my-user-moderation-dropdown
*ngIf="!isInSelectionMode()"
[user]="user" container="body" (userChanged)="onUserChanged()" (userDeleted)="onUserChanged()"
>
</my-user-moderation-dropdown>
</td>
</tr>
</ng-template>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ export class UserModerationDropdownComponent implements OnInit, OnChanges {
@Input() prependActions: DropdownAction<{ user: User, account: Account }>[]

@Input() buttonSize: 'normal' | 'small' = 'normal'
@Input() placement = 'left-top left-bottom auto'
@Input() placement = 'right-top right-bottom auto'
@Input() label: string
@Input() container: 'body' | undefined = undefined

Expand Down

0 comments on commit bbfd2a4

Please sign in to comment.