2016-05-24 15:06:59 +03:00
|
|
|
import 'ghost-admin/utils/link-component';
|
2017-05-29 21:50:03 +03:00
|
|
|
import 'ghost-admin/utils/route';
|
2016-05-24 15:06:59 +03:00
|
|
|
import 'ghost-admin/utils/text-field';
|
2017-08-22 10:53:26 +03:00
|
|
|
import Application from '@ember/application';
|
2017-05-29 21:50:03 +03:00
|
|
|
import Resolver from './resolver';
|
2015-02-13 07:22:32 +03:00
|
|
|
import config from './config/environment';
|
2017-05-29 21:50:03 +03:00
|
|
|
import loadInitializers from 'ember-load-initializers';
|
2018-05-03 19:52:39 +03:00
|
|
|
import {registerWarnHandler} from '@ember/debug';
|
2014-02-27 08:45:45 +04:00
|
|
|
|
2017-07-31 12:38:46 +03:00
|
|
|
const App = Application.extend({
|
2015-10-28 14:36:45 +03:00
|
|
|
Resolver,
|
2015-02-13 07:22:32 +03:00
|
|
|
modulePrefix: config.modulePrefix,
|
2017-02-03 16:25:26 +03:00
|
|
|
podModulePrefix: config.podModulePrefix,
|
|
|
|
|
2017-11-24 21:53:19 +03:00
|
|
|
// eslint-disable-next-line
|
2017-02-03 16:25:26 +03:00
|
|
|
customEvents: {
|
|
|
|
touchstart: null,
|
|
|
|
touchmove: null,
|
|
|
|
touchend: null,
|
|
|
|
touchcancel: null
|
|
|
|
}
|
2014-02-26 08:58:00 +04:00
|
|
|
});
|
2014-03-02 18:30:35 +04:00
|
|
|
|
2017-04-05 20:21:33 +03:00
|
|
|
// TODO: remove once the validations refactor is complete
|
|
|
|
// eslint-disable-next-line
|
2018-05-03 19:52:39 +03:00
|
|
|
registerWarnHandler((message, options, next) => {
|
2017-04-05 20:21:33 +03:00
|
|
|
let skip = [
|
|
|
|
'ds.errors.add',
|
|
|
|
'ds.errors.remove',
|
|
|
|
'ds.errors.clear'
|
|
|
|
];
|
|
|
|
|
|
|
|
if (skip.includes(options.id)) {
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
|
|
|
next(message, options);
|
|
|
|
});
|
|
|
|
|
2015-02-13 07:22:32 +03:00
|
|
|
loadInitializers(App, config.modulePrefix);
|
2014-03-11 20:23:32 +04:00
|
|
|
|
2014-04-02 06:09:28 +04:00
|
|
|
export default App;
|