mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-01-04 08:54:36 +03:00
9adbcd1fd0
no issue Automated tools, code generators, and editor integrations are increasingly standardising on the import style used in `ember-modules-codemod`. Our import style differed a little with regards to service/controller injection imports which meant we were starting to see inconsistent naming.
20 lines
526 B
JavaScript
20 lines
526 B
JavaScript
import BasicDropdown from 'ember-basic-dropdown/components/basic-dropdown';
|
|
import layout from 'ember-basic-dropdown/templates/components/basic-dropdown';
|
|
import {inject as service} from '@ember/service';
|
|
|
|
export default BasicDropdown.extend({
|
|
dropdown: service(),
|
|
|
|
layout,
|
|
|
|
didInsertElement() {
|
|
this._super(...arguments);
|
|
this.get('dropdown').on('close', this, this.close);
|
|
},
|
|
|
|
willDestroyElement() {
|
|
this._super(...arguments);
|
|
this.get('dropdown').off('close');
|
|
}
|
|
});
|