chained on click events to document; works