2019-05-23 18:03:04 +03:00
|
|
|
/**
|
2018-12-11 22:56:46 +03:00
|
|
|
* @copyright 2018 Christoph Wurst <christoph@winzerhof-wurst.at>
|
|
|
|
*
|
|
|
|
* @author 2018 Christoph Wurst <christoph@winzerhof-wurst.at>
|
|
|
|
*
|
|
|
|
* @license GNU AGPL version 3 or any later version
|
|
|
|
*
|
|
|
|
* This program is free software: you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU Affero General Public License as
|
|
|
|
* published by the Free Software Foundation, either version 3 of the
|
|
|
|
* License, or (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU Affero General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU Affero General Public License
|
|
|
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
*/
|
|
|
|
|
2019-05-10 14:38:11 +03:00
|
|
|
import $ from 'jquery'
|
2019-01-31 21:07:39 +03:00
|
|
|
import './Polyfill/index'
|
2019-05-23 18:03:04 +03:00
|
|
|
import '@babel/polyfill'
|
2018-12-11 22:56:46 +03:00
|
|
|
|
2019-05-10 14:38:11 +03:00
|
|
|
// If you remove the line below, tests won't pass
|
2019-09-25 19:19:42 +03:00
|
|
|
// eslint-disable-next-line no-unused-vars
|
2019-05-10 14:38:11 +03:00
|
|
|
import OC from './OC/index'
|
|
|
|
|
2018-12-11 22:56:46 +03:00
|
|
|
import './globals'
|
2019-01-29 12:15:46 +03:00
|
|
|
import './jquery/index'
|
2019-09-25 19:19:42 +03:00
|
|
|
import { initCore } from './init'
|
|
|
|
import { registerAppsSlideToggle } from './OC/apps'
|
2019-01-04 13:24:50 +03:00
|
|
|
|
2019-09-25 19:19:42 +03:00
|
|
|
$(document).ready(function() {
|
|
|
|
initCore()
|
|
|
|
registerAppsSlideToggle()
|
2019-10-21 22:36:17 +03:00
|
|
|
|
|
|
|
// fallback to hashchange when no history support
|
|
|
|
if (window.history.pushState) {
|
|
|
|
window.onpopstate = _.bind(OC.Util.History._onPopState, OC.Util.History)
|
|
|
|
} else {
|
|
|
|
$(window).on('hashchange', _.bind(OC.Util.History._onPopState, OC.Util.History))
|
|
|
|
}
|
2019-09-25 19:19:42 +03:00
|
|
|
})
|