[IMP] Improved javascript for selecting size of FA