2018-04-03 14:16:57 +00:00
|
|
|
import Ember from 'ember';
|
|
|
|
|
|
|
|
import { messageTypes } from 'vault/helpers/message-types';
|
|
|
|
const { computed } = Ember;
|
|
|
|
|
|
|
|
export default Ember.Component.extend({
|
|
|
|
type: null,
|
|
|
|
|
2018-05-24 03:10:21 +00:00
|
|
|
yieldWithoutColumn: false,
|
|
|
|
|
2018-04-03 14:16:57 +00:00
|
|
|
classNameBindings: ['containerClass'],
|
|
|
|
|
|
|
|
containerClass: computed('type', function() {
|
|
|
|
return 'message ' + messageTypes([this.get('type')]).class;
|
|
|
|
}),
|
|
|
|
|
|
|
|
alertType: computed('type', function() {
|
|
|
|
return messageTypes([this.get('type')]);
|
|
|
|
}),
|
|
|
|
|
|
|
|
messageClass: 'message-body',
|
|
|
|
});
|