JS doesn't like `var`'ing the same variable twice. Maybe move this to a ternary if statement?

`var closeText = (typeof window.trans == "undefined") ? 'Close' : window.trans('global-close');`