[Fix] Applying correct format of origin when inside iframe but tested locally

- Checking if hostname is "localhost" when document.referrer exists. Applying origin value in the way Google Picker API asks for (same format as when not within an iframe)
- This  fix appeases Google Picker API throwing an error which happens in the situation when this component is being used inside an iframe but the overall application is being tested locally.