Calendar in pure-JS