This commit is contained in:
Vincent Fiduccia 2017-05-26 17:48:43 -07:00
parent e0819b9193
commit 2a7548bc23
No known key found for this signature in database
GPG Key ID: 2B29AD6BB2BB2582
4 changed files with 18 additions and 4 deletions

View File

@ -20,7 +20,7 @@ const defaultStateMap = {
'initializing': {icon: 'icon icon-alert', color: 'text-warning'},
'migrating': {icon: 'icon icon-info', color: 'text-info' },
'provisioning': {icon: 'icon icon-circle', color: 'text-info' },
'garbage-collection': {icon: 'icon icon-trash', color: 'text-success'},
'pending-delete': {icon: 'icon icon-trash', color: 'text-muted' },
'purged': {icon: 'icon icon-purged', color: 'text-error' },
'purging': {icon: 'icon icon-purged', color: 'text-info' },
'reconnecting': {icon: 'icon icon-alert', color: 'text-error' },

View File

@ -16,6 +16,10 @@ export default Ember.Mixin.create({
this.get(inputKey).sortBy('stateSort').forEach((inst) => {
let color = inst.get('stateBackground');
if ( color === 'bg-muted' ) {
color = 'bg-success';
}
let state = inst.get('displayState');
let entry = byName.findBy('state', state);
if ( entry ) {
@ -42,7 +46,7 @@ export default Ember.Mixin.create({
this.set(sortProperty, Ember.computed(countsProperty, `${inputKey}.[]`, () => {
let colors = this.get(`${countsProperty}.byColor`);
let success = (colors.findBy('bg-success')||{}).count;
let success = (colors.findBy('bg-success')||{}).count + (colors.findBy('bg-muted')||{}).coun;
let error = (colors.findBy('bg-error')||{}).count;
let other = this.get(`${inputKey}.length`) - success - error;

View File

@ -143,8 +143,8 @@ var Container = Instance.extend({
var health = this.get('healthState');
var hasCheck = !!this.get('healthCheck');
if ( this.get('desired') === false ) {
return 'garbage-collection';
if ( resource === 'stopped' && this.get('desired') === false ) {
return 'pending-delete';
}
else if ( C.ACTIVEISH_STATES.indexOf(resource) >= 0 )
{

View File

@ -11,6 +11,16 @@
&.text-success:hover {
color: $success;
}
// Successful states are de-emphasized by using [text-]color instead of background-color
&.bg-muted {
background-color: transparent;
color: $text-muted;
}
&.text-success:hover {
color: $text-muted;
}
}
.grid TD.state {