summaryrefslogtreecommitdiffstats
path: root/src/main.js
blob: 571646471b6483a909206e05b73cfe2b7b9d0053 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
import Vue from 'vue'
import VueRouter from 'vue-router'
import Vuex, { Store } from 'vuex'

import App from './App.vue'
import router from './routes'
import mainStore from './store'

import { Tooltip } from '@nextcloud/vue'

Vue.prototype.t = t
Vue.prototype.n = n
Vue.prototype.OC = OC
Vue.prototype.OCA = OCA

Vue.use(Vuex)
Vue.use(VueRouter)

Vue.directive('tooltip', Tooltip)

const store = new Store(mainStore)

export default new Vue({
	router,
	store,
	el: '#q-app',
	render: (h) => h(App),
})

/**
 * Closes warning messages generated by PHP code
 */
function closeCronWarning() {
	document.getElementById('cron-warning').style.display = 'none'
}
document.getElementById('close-cron-warning').onclick = closeCronWarning