2016-04-10 08:37:05 +00:00
|
|
|
/**
|
|
|
|
* @license
|
|
|
|
* caspar-sup <https://filadelfia.is>
|
|
|
|
* Copyright 2015 Jonatan Nilsson <http://jonatan.nilsson.is/>
|
|
|
|
*
|
|
|
|
* Available under WTFPL License (http://www.wtfpl.net/txt/copying/)
|
|
|
|
*/
|
|
|
|
|
|
|
|
'use strict'
|
|
|
|
|
|
|
|
//Add debug components to window. Allows us to play with controls
|
|
|
|
//in the console.
|
|
|
|
window.components = {}
|
|
|
|
|
2020-04-06 22:47:58 +00:00
|
|
|
require('../shared/socket')
|
2017-12-03 11:34:43 +00:00
|
|
|
require('./store')
|
2016-04-10 08:37:05 +00:00
|
|
|
|
|
|
|
const m = require('mithril')
|
2017-12-03 11:34:43 +00:00
|
|
|
const Header = require('./header')
|
|
|
|
const Menu = require('./menu')
|
|
|
|
|
2018-06-26 18:35:12 +00:00
|
|
|
const Add = require('./add/module')
|
|
|
|
const Graphic = require('./graphic/module')
|
|
|
|
const Dagskra = require('./dagskra/module')
|
2016-04-10 08:37:05 +00:00
|
|
|
|
2016-04-14 04:01:51 +00:00
|
|
|
m.mount(document.getElementById('header'), Header)
|
2016-04-10 08:37:05 +00:00
|
|
|
m.mount(document.getElementById('menu'), Menu)
|
|
|
|
|
|
|
|
m.route(document.getElementById('content'), '/', {
|
2018-06-26 18:35:12 +00:00
|
|
|
'/': Dagskra,
|
2016-04-14 04:01:51 +00:00
|
|
|
'/add': Add,
|
|
|
|
'/graphic/:id': Graphic,
|
2018-06-26 18:35:12 +00:00
|
|
|
})
|