Decodes a url-safe base64 encoded string.

@param {String} str The url-safe base64 encoded string
@return {String} The decoded string
function urlSafeBase64DecodeString( str ) {
	const decodeMap = {
		'-': '+',
		_: '/',
		'.': '=',
	};

	return atob( str.replace( /[-_.]/g, ch => decodeMap[ ch ] ) );
}