Parses and validates a tenant URL into a postMessage-safe origin. Allows https always; http only for localhost / 127.0.0.1 / [::1].
Absolute URL from the tenantUrl search param.
tenantUrl
Origin string suitable for postMessage targetOrigin.
postMessage
When missing, unparsable, or disallowed scheme/host.
Parses and validates a tenant URL into a postMessage-safe origin. Allows https always; http only for localhost / 127.0.0.1 / [::1].