Skip to content

Commit 4b4fbac

Browse files
authored
allow customization of exiting class (#389)
1 parent e0b3f06 commit 4b4fbac

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

addon/components/flash-message.hbs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<div
2-
class="flash-message {{this.alertType}} {{if this.exiting "exiting"}} {{if this.active "active"}}"
2+
class="flash-message {{this.alertType}} {{if this.exiting this.exitingClass}} {{if this.active "active"}}"
33
role="alert"
44
...attributes
55
{{on "click" this.onClick}}

addon/components/flash-message.js

+4
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,10 @@ export default class FlashMessage extends Component {
4242
return this.args.flash.exiting;
4343
}
4444

45+
get exitingClass() {
46+
return this.args.exitingClass || 'exiting';
47+
}
48+
4549
get messageStylePrefix() {
4650
return this.args.messageStylePrefix ?? this._defaultMessageStylePrefix;
4751
}

0 commit comments

Comments
 (0)