first revision of sundial

Works with current uploader code, not yet modified to include needed tideline functions.

@jh-bate or @cheddar please review. @cheddar would like me to merge and tag this and have the uploader depend on it before merging the uploader branch where I've removed the moment dependency and replaced it with sundial methods.
Nothing's using this yet; I could do more exploration on this topic.

I basically copied this from what tideline uses in client-side validation, just for starters.