fmt: apply prettier to frontend JS/TS/CSS/JSON files

Initial prettier pass with tabWidth=4.
This commit is contained in:
KS Jannette
2026-02-28 20:07:28 -05:00
parent a5d1bc171c
commit da8b45012a
23 changed files with 4590 additions and 4343 deletions

View File

@@ -1,30 +1,30 @@
/**
* Auth Headers Helper
*
*
* Provides authentication headers for API calls
* Includes Firebase ID token in Authorization header
*/
import { auth } from '../firebase/config';
import { auth } from "../firebase/config";
/**
* Get headers with authentication token
* @returns {Promise<Object>} Headers object with Authorization
*/
export async function getAuthHeaders() {
const currentUser = auth.currentUser;
if (!currentUser) {
throw new Error('No authenticated user');
}
const currentUser = auth.currentUser;
// Get Firebase ID token
const token = await currentUser.getIdToken();
if (!currentUser) {
throw new Error("No authenticated user");
}
return {
'Content-Type': 'application/json',
'Authorization': `Bearer ${token}`
};
// Get Firebase ID token
const token = await currentUser.getIdToken();
return {
"Content-Type": "application/json",
Authorization: `Bearer ${token}`,
};
}
/**
@@ -32,16 +32,15 @@ export async function getAuthHeaders() {
* @returns {Promise<Object>} Headers object with Authorization
*/
export async function getAuthHeadersSimple() {
const currentUser = auth.currentUser;
if (!currentUser) {
throw new Error('No authenticated user');
}
const currentUser = auth.currentUser;
const token = await currentUser.getIdToken();
if (!currentUser) {
throw new Error("No authenticated user");
}
return {
'Authorization': `Bearer ${token}`
};
const token = await currentUser.getIdToken();
return {
Authorization: `Bearer ${token}`,
};
}