open-vault/ui/app/components/status-menu.js
2018-04-03 09:16:57 -05:00

22 lines
566 B
JavaScript

import Ember from 'ember';
const { inject, computed } = Ember;
export default Ember.Component.extend({
currentCluster: inject.service('current-cluster'),
cluster: computed.alias('currentCluster.cluster'),
auth: inject.service(),
type: 'cluster',
partialName: computed('type', function() {
return `partials/status/${this.get('type')}`;
}),
glyphName: computed('type', function() {
const glyphs = {
cluster: 'unlocked',
user: 'android-person',
replication: 'replication',
};
return glyphs[this.get('type')];
}),
});