);
}
function GoogleG(){
return ();
}
function AppleLogo(){
return ();
}
function ProviderButton({provider,children,onClick}){
return (
);
}
function AuthDivider({children}){
return (
{children}
);
}
function PasswordField({id,label,value,onChange,onBlur,error}){
const [show,setShow]=React.useState(false);
return (
);
}
function AuthProviderStub(provider,setNotice,onSuccess){
const cfg=BB_OAUTH_CONFIG[provider.toLowerCase()];
if(!cfg||!cfg.configured){
setNotice(`${provider} Sign-In will be available once ${provider} credentials are configured.`);
return;
}
if(provider.toLowerCase()==='google'&&window.google&&window.google.accounts){
try{
window.google.accounts.id.initialize({
client_id:cfg.clientId,
callback:(resp)=>{
try{
const payload=JSON.parse(atob(resp.credential.split('.')[1]));
const res=BB_AUTH.loginWithProvider('google',{email:payload.email,name:payload.name});
if(res.ok&&onSuccess)onSuccess();else setNotice('Google sign-in failed — please try again.');
}catch(e){setNotice('Could not verify Google response — please try again.');}
}
});
window.google.accounts.id.prompt(notification=>{
if(notification.isNotDisplayed()||notification.isSkippedMoment()){setNotice('Google sign-in was cancelled or blocked by the browser.');}
});
}catch(e){setNotice('Google sign-in is temporarily unavailable — please try again.');}
return;
}
setNotice(`${provider} Sign-In is configured but the provider script did not load — check your connection and try again.`);
}
Object.assign(window,{AuthShell,ProviderButton,AuthDivider,PasswordField,AuthProviderStub});