open-vault/ui/app/components/upgrade-link.js
Matthew Irish b383874a76
UI - Active Directory secrets (#4647)
* add AD secrets in the ui and move deprecated engines to the bottom of the list

* fix tools tests

* prettier
2018-05-29 09:14:31 -05:00

40 lines
826 B
JavaScript

import Ember from 'ember';
const { computed } = Ember;
export default Ember.Component.extend({
isAnimated: false,
isActive: false,
tagName: 'span',
trackingSource: computed('pageName', function() {
let trackingSource = 'vaultui';
let pageName = this.get('pageName');
if (pageName) {
trackingSource = trackingSource + '_' + encodeURIComponent(pageName);
}
return trackingSource;
}),
actions: {
openOverlay() {
this.set('isActive', true);
Ember.run.later(
this,
function() {
this.set('isAnimated', true);
},
10
);
},
closeOverlay() {
this.set('isAnimated', false);
Ember.run.later(
this,
function() {
this.set('isActive', false);
},
300
);
},
},
});