Rewrite i18n support to use new json format

Co-author: Bryan Davis <bd808@wikimedia.org>
Change-Id: Ie1b01b42e0746139ee32cfd66e6231ad4ed2cf4d