More layout work and made ported datecalc over to javascript for use