import { initializeApp } from "firebase/app";
import { getAuth, GoogleAuthProvider } from "firebase/auth";

// Firebase configuration
// Note: Replace these with your actual Firebase project configuration
const firebaseConfig = {
  apiKey: "AIzaSyCI9wFnK7iJuH7zEKrdajjRgxd1uVjCnFA",
  authDomain: "enclave-wallet.firebaseapp.com",
  projectId: "enclave-wallet",
  storageBucket: "enclave-wallet.appspot.com",
  messagingSenderId: "160004845895",
  appId: "1:160004845895:web:47298d420101e76829dc62",
  measurementId: "G-TFLS0L6WKJ",
};

// Initialize Firebase
const app = initializeApp(firebaseConfig);

// Initialize Firebase Authentication and get a reference to the service
export const auth = getAuth(app);

// Initialize Google Auth Provider
export const googleProvider = new GoogleAuthProvider();

// Configure Google provider to always prompt for account selection
googleProvider.setCustomParameters({
  prompt: "select_account",
});

export default app;
