added requirejs.text to load templates; added pagination UI part