mirror of https://github.com/portainer/portainer
feat(sidebar): update endpoint selection UX (#1902)
* style(sidebar): update selected endpoint name color * feat(sidebar): sort groups/endpoints alphabeticallypull/1907/head
parent
5df09923b6
commit
32800a843a
|
@ -14,7 +14,7 @@
|
||||||
groups="groups"
|
groups="groups"
|
||||||
select-endpoint="switchEndpoint"
|
select-endpoint="switchEndpoint"
|
||||||
></endpoint-selector>
|
></endpoint-selector>
|
||||||
<li class="sidebar-title"><span>{{ activeEndpoint.Name }}</span></li>
|
<li class="sidebar-title"><span class="endpoint-name">{{ activeEndpoint.Name }}</span></li>
|
||||||
<docker-sidebar-content
|
<docker-sidebar-content
|
||||||
endpoint-api-version="applicationState.endpoint.apiVersion"
|
endpoint-api-version="applicationState.endpoint.apiVersion"
|
||||||
swarm-management="applicationState.endpoint.mode.provider === 'DOCKER_SWARM_MODE' && applicationState.endpoint.mode.role === 'MANAGER'"
|
swarm-management="applicationState.endpoint.mode.provider === 'DOCKER_SWARM_MODE' && applicationState.endpoint.mode.role === 'MANAGER'"
|
||||||
|
|
|
@ -58,8 +58,8 @@ function ($q, $scope, $state, EndpointService, GroupService, StateManager, Endpo
|
||||||
})
|
})
|
||||||
.then(function success(data) {
|
.then(function success(data) {
|
||||||
var endpoints = data.endpoints;
|
var endpoints = data.endpoints;
|
||||||
$scope.groups = data.groups;
|
$scope.groups = _.sortBy(data.groups, ['Name']);
|
||||||
$scope.endpoints = endpoints;
|
$scope.endpoints = _.sortBy(endpoints, ['Name']);
|
||||||
|
|
||||||
setActiveEndpoint(endpoints);
|
setActiveEndpoint(endpoints);
|
||||||
|
|
||||||
|
|
|
@ -304,6 +304,10 @@ ul.sidebar .sidebar-title {
|
||||||
height: auto;
|
height: auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ul.sidebar .sidebar-title .endpoint-name {
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
ul.sidebar .sidebar-list a {
|
ul.sidebar .sidebar-list a {
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue