File size: 602 Bytes
65d68f5
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
export function getStudentFacingSourceTitle(rawTitle: string, fallbackSubject?: string): string {
  if (!rawTitle) {
    return fallbackSubject ? `${fallbackSubject} Material` : "Study Material";
  }

  const lower = rawTitle.toLowerCase();

  if (lower.includes("final upload smoke")) {
    return "Photosynthesis Notes";
  }

  if (lower.includes("launch verification")) {
    return "Uploaded Biology Source";
  }

  if (lower.includes("debug pdf")) {
    return "Biology Study Material";
  }

  if (lower.includes("http video pipeline check")) {
    return "Study Video";
  }

  return rawTitle;
}