Create a PowerPoint presentation to Explain the ways in which infectious diseases can be transmitted and discuss specific examples. Evaluate the factors which increase the risk of contracting infectious diseases, and how this risk can be reduced. Identify the advantages and dangers in the use of antibiotics. The presentation should include: Two examples of the way diseases can be transmitted. Brief evaluation of three factors that can increase the risk of contracting infectious diseases and how the risk can be reduced in care settings. The advantages and dangers in the use of antibiotics when treating infections
ls -la /home/daytona/workspace/
mkdir -p /home/daytona/workspace/infectious-diseases-ppt
~/infectious-diseases-ppt/build.js
const pptxgen = require("pptxgenjs");
const pres = new pptxgen();
pres.layout = "LAYOUT_16x9";
pres.title = "Infectious Diseases: Transmission, Risk & Antibiotics";
// ─────────────────────────────────────────────
// THEME
// ─────────────────────────────────────────────
const DARK_BG = "0D1B2A"; // deep navy
const MID_BG = "1B2A3B"; // navy mid
const ACCENT1 = "00B4D8"; // vivid cyan (headings / accents)
const ACCENT2 = "90E0EF"; // light cyan (sub-text)
const DANGER_RED = "E63946"; // danger / antibiotics slides
const GREEN_SAFE = "2EC4B6"; // prevention / advantages
const WHITE = "FFFFFF";
const LIGHT_GRAY = "C9D6DF";
const CARD_BG = "162233"; // card background
function addSlideBackground(slide, color) {
slide.addShape(pres.ShapeType.rect, {
x: 0, y: 0, w: "100%", h: "100%",
fill: { color: color || DARK_BG }, line: { color: color || DARK_BG }
});
}
function addHeader(slide, text, y, color) {
slide.addText(text, {
x: 0.5, y: y || 0.25, w: 9, h: 0.55,
fontSize: 26, bold: true, color: color || ACCENT1,
fontFace: "Calibri", align: "left", margin: 0
});
}
function addDividerLine(slide, y) {
slide.addShape(pres.ShapeType.rect, {
x: 0.5, y: y || 0.9, w: 9, h: 0.03,
fill: { color: ACCENT1 }, line: { color: ACCENT1 }
});
}
function addBodyText(slide, text, x, y, w, h, color, fontSize) {
slide.addText(text, {
x, y, w, h,
fontSize: fontSize || 14,
color: color || LIGHT_GRAY,
fontFace: "Calibri",
align: "left",
valign: "top",
wrap: true
});
}
// ══════════════════════════════════════════════
// SLIDE 1 – TITLE
// ══════════════════════════════════════════════
{
const sl = pres.addSlide();
addSlideBackground(sl);
// Full-width accent bar at top
sl.addShape(pres.ShapeType.rect, {
x: 0, y: 0, w: "100%", h: 1.1,
fill: { color: ACCENT1 }, line: { color: ACCENT1 }
});
sl.addText("INFECTIOUS DISEASES", {
x: 0.5, y: 0.2, w: 9, h: 0.7,
fontSize: 36, bold: true, color: DARK_BG,
fontFace: "Calibri", align: "left", margin: 0
});
sl.addText("Transmission · Risk Factors · Antibiotics", {
x: 0.5, y: 1.35, w: 9, h: 0.5,
fontSize: 20, color: ACCENT2, fontFace: "Calibri",
align: "left", italic: true, margin: 0
});
sl.addShape(pres.ShapeType.rect, {
x: 0, y: 5.1, w: "100%", h: 0.5,
fill: { color: MID_BG }, line: { color: MID_BG }
});
sl.addText("Health Sciences | 2026", {
x: 0.5, y: 5.1, w: 9, h: 0.5,
fontSize: 12, color: ACCENT2, fontFace: "Calibri", align: "left", valign: "middle"
});
// Key bullet summary on title slide
const bulletItems = [
{ text: "How infectious diseases spread — two key transmission routes", options: { bullet: { code: "2022" }, breakLine: true } },
{ text: "Three risk factors and how to reduce them in care settings", options: { bullet: { code: "2022" }, breakLine: true } },
{ text: "Advantages and dangers of antibiotic therapy", options: { bullet: { code: "2022" } } }
];
sl.addText(bulletItems, {
x: 0.7, y: 2.1, w: 8.5, h: 2.5,
fontSize: 16, color: WHITE, fontFace: "Calibri",
lineSpacingMultiple: 1.4
});
}
// ══════════════════════════════════════════════
// SLIDE 2 – WHAT ARE INFECTIOUS DISEASES?
// ══════════════════════════════════════════════
{
const sl = pres.addSlide();
addSlideBackground(sl);
addHeader(sl, "What Are Infectious Diseases?");
addDividerLine(sl);
addBodyText(sl,
"Infectious diseases are disorders caused by organisms such as bacteria, viruses, fungi, or parasites that invade the body, multiply, and disrupt normal function. They can be spread from person to person, via animals, insects, or contaminated environments.",
0.5, 1.0, 9, 1.1, LIGHT_GRAY, 15);
// 3 boxes: Bacteria, Viruses, Parasites
const categories = [
{ label: "BACTERIA", detail: "Single-celled organisms. Cause TB, cholera, MRSA. Treatable with antibiotics." },
{ label: "VIRUSES", detail: "Non-living particles. Cause influenza, HIV, COVID-19. Antibiotics ineffective." },
{ label: "PARASITES / FUNGI", detail: "Multi- or single-celled. Cause malaria, tinea. Require specific treatments." }
];
categories.forEach((cat, i) => {
const xPos = 0.4 + i * 3.1;
sl.addShape(pres.ShapeType.rect, {
x: xPos, y: 2.3, w: 2.8, h: 2.8,
fill: { color: CARD_BG }, line: { color: ACCENT1, pt: 1.5 }
});
sl.addText(cat.label, {
x: xPos + 0.1, y: 2.4, w: 2.6, h: 0.5,
fontSize: 13, bold: true, color: ACCENT1,
fontFace: "Calibri", align: "center"
});
sl.addText(cat.detail, {
x: xPos + 0.1, y: 2.95, w: 2.6, h: 1.9,
fontSize: 12, color: LIGHT_GRAY, fontFace: "Calibri",
align: "center", valign: "top", wrap: true
});
});
}
// ══════════════════════════════════════════════
// SLIDE 3 – SECTION DIVIDER: TRANSMISSION
// ══════════════════════════════════════════════
{
const sl = pres.addSlide();
addSlideBackground(sl, MID_BG);
sl.addShape(pres.ShapeType.rect, {
x: 0, y: 1.8, w: "100%", h: 2.1,
fill: { color: ACCENT1 }, line: { color: ACCENT1 }
});
sl.addText("SECTION 1", {
x: 0.5, y: 1.88, w: 9, h: 0.4,
fontSize: 13, bold: true, color: DARK_BG,
fontFace: "Calibri", align: "center", italic: true
});
sl.addText("How Infectious Diseases\nAre Transmitted", {
x: 0.5, y: 2.25, w: 9, h: 1.4,
fontSize: 34, bold: true, color: DARK_BG,
fontFace: "Calibri", align: "center"
});
sl.addText("Two key routes: Airborne & Direct Contact", {
x: 0.5, y: 4.2, w: 9, h: 0.5,
fontSize: 16, color: ACCENT2, fontFace: "Calibri", align: "center", italic: true
});
}
// ══════════════════════════════════════════════
// SLIDE 4 – TRANSMISSION ROUTE 1: AIRBORNE
// ══════════════════════════════════════════════
{
const sl = pres.addSlide();
addSlideBackground(sl);
// Coloured top badge
sl.addShape(pres.ShapeType.rect, {
x: 0, y: 0, w: "100%", h: 0.5,
fill: { color: ACCENT1 }, line: { color: ACCENT1 }
});
sl.addText("TRANSMISSION ROUTE 1", {
x: 0.5, y: 0.05, w: 9, h: 0.4,
fontSize: 12, bold: true, color: DARK_BG,
fontFace: "Calibri", align: "left"
});
addHeader(sl, "Airborne Transmission", 0.65, WHITE);
addDividerLine(sl, 1.3);
addBodyText(sl,
"Airborne transmission occurs when infectious agents are carried by tiny airborne droplets or droplet nuclei (particles <5 µm) and inhaled by a susceptible host. These particles can remain suspended in the air for extended periods and travel further than 1 metre from the source.",
0.5, 1.45, 9, 1.0, LIGHT_GRAY, 14);
// Example box – TB
sl.addShape(pres.ShapeType.rect, {
x: 0.4, y: 2.6, w: 4.3, h: 2.6,
fill: { color: CARD_BG }, line: { color: ACCENT1, pt: 1.5 }
});
sl.addText("🦠 Example: Tuberculosis (TB)", {
x: 0.5, y: 2.7, w: 4.1, h: 0.45,
fontSize: 13, bold: true, color: ACCENT1, fontFace: "Calibri"
});
sl.addText([
{ text: "Pathogen: ", options: { bold: true, breakLine: false } },
{ text: "Mycobacterium tuberculosis\n", options: { breakLine: true } },
{ text: "Transmission: ", options: { bold: true, breakLine: false } },
{ text: "Infectious aerosols released when an infected person coughs, sneezes or speaks. Inhaled by a susceptible host.\n", options: { breakLine: true } },
{ text: "Impact: ", options: { bold: true, breakLine: false } },
{ text: "Was the leading infectious disease cause of death worldwide before SARS-CoV-2.", options: {} }
], {
x: 0.5, y: 3.2, w: 4.1, h: 1.9,
fontSize: 12, color: LIGHT_GRAY, fontFace: "Calibri", valign: "top", wrap: true
});
// Example box – Influenza
sl.addShape(pres.ShapeType.rect, {
x: 5.1, y: 2.6, w: 4.3, h: 2.6,
fill: { color: CARD_BG }, line: { color: ACCENT2, pt: 1.5 }
});
sl.addText("🫁 Example: Influenza", {
x: 5.2, y: 2.7, w: 4.1, h: 0.45,
fontSize: 13, bold: true, color: ACCENT2, fontFace: "Calibri"
});
sl.addText([
{ text: "Pathogen: ", options: { bold: true, breakLine: false } },
{ text: "Influenza A/B virus\n", options: { breakLine: true } },
{ text: "Transmission: ", options: { bold: true, breakLine: false } },
{ text: "Droplets expelled by coughing/sneezing travel through the air and are inhaled, or land on mucous membranes.\n", options: { breakLine: true } },
{ text: "Note: ", options: { bold: true, breakLine: false } },
{ text: "Larger respiratory droplets (>5 µm) are sometimes called droplet rather than airborne; both are aerosol-based routes.", options: {} }
], {
x: 5.2, y: 3.2, w: 4.1, h: 1.9,
fontSize: 12, color: LIGHT_GRAY, fontFace: "Calibri", valign: "top", wrap: true
});
}
// ══════════════════════════════════════════════
// SLIDE 5 – TRANSMISSION ROUTE 2: DIRECT CONTACT
// ══════════════════════════════════════════════
{
const sl = pres.addSlide();
addSlideBackground(sl);
sl.addShape(pres.ShapeType.rect, {
x: 0, y: 0, w: "100%", h: 0.5,
fill: { color: GREEN_SAFE }, line: { color: GREEN_SAFE }
});
sl.addText("TRANSMISSION ROUTE 2", {
x: 0.5, y: 0.05, w: 9, h: 0.4,
fontSize: 12, bold: true, color: DARK_BG, fontFace: "Calibri", align: "left"
});
addHeader(sl, "Direct Contact Transmission", 0.65, WHITE);
addDividerLine(sl, 1.3);
addBodyText(sl,
"Direct contact transmission occurs when an infectious organism is transferred through physical contact between an infected source and a susceptible host — either person-to-person, or via contaminated surfaces (fomites) and body fluids.",
0.5, 1.45, 9, 0.95, LIGHT_GRAY, 14);
// Sub-types row
const types = [
{ label: "Skin-to-Skin", desc: "Direct touching of infected skin or lesions (e.g. MRSA, herpes simplex)." },
{ label: "Body Fluids", desc: "Blood, sexual fluids or breast milk carrying HIV, Hepatitis B/C." },
{ label: "Fomites", desc: "Contaminated surfaces (door handles, instruments) harbouring pathogens." }
];
types.forEach((t, i) => {
const x = 0.4 + i * 3.1;
sl.addShape(pres.ShapeType.rect, {
x, y: 2.55, w: 2.8, h: 1.2,
fill: { color: CARD_BG }, line: { color: GREEN_SAFE, pt: 1 }
});
sl.addText(t.label, {
x: x + 0.05, y: 2.6, w: 2.7, h: 0.35,
fontSize: 12, bold: true, color: GREEN_SAFE, fontFace: "Calibri", align: "center"
});
sl.addText(t.desc, {
x: x + 0.05, y: 2.98, w: 2.7, h: 0.7,
fontSize: 11, color: LIGHT_GRAY, fontFace: "Calibri", align: "center", wrap: true
});
});
// Large example – MRSA
sl.addShape(pres.ShapeType.rect, {
x: 0.4, y: 3.9, w: 9.1, h: 1.5,
fill: { color: CARD_BG }, line: { color: GREEN_SAFE, pt: 1.5 }
});
sl.addText("Clinical Example: MRSA (Methicillin-Resistant Staphylococcus aureus)", {
x: 0.55, y: 3.97, w: 8.8, h: 0.4,
fontSize: 13, bold: true, color: GREEN_SAFE, fontFace: "Calibri"
});
sl.addText(
"MRSA spreads primarily through direct skin-to-skin contact or via contaminated hands of healthcare workers. It colonises wounds, surgical sites and skin abrasions. Shared equipment and unwashed hands are the principal vehicles. MRSA is a leading cause of healthcare-associated infections (HAIs) worldwide.",
{ x: 0.55, y: 4.38, w: 8.8, h: 0.95, fontSize: 12, color: LIGHT_GRAY, fontFace: "Calibri", valign: "top", wrap: true }
);
}
// ══════════════════════════════════════════════
// SLIDE 6 – SECTION DIVIDER: RISK FACTORS
// ══════════════════════════════════════════════
{
const sl = pres.addSlide();
addSlideBackground(sl, MID_BG);
sl.addShape(pres.ShapeType.rect, {
x: 0, y: 1.8, w: "100%", h: 2.1,
fill: { color: GREEN_SAFE }, line: { color: GREEN_SAFE }
});
sl.addText("SECTION 2", {
x: 0.5, y: 1.88, w: 9, h: 0.4,
fontSize: 13, bold: true, color: DARK_BG, fontFace: "Calibri", align: "center", italic: true
});
sl.addText("Risk Factors & Prevention\nin Care Settings", {
x: 0.5, y: 2.25, w: 9, h: 1.4,
fontSize: 34, bold: true, color: DARK_BG, fontFace: "Calibri", align: "center"
});
sl.addText("Three key factors that increase — and how to reduce — infection risk", {
x: 0.5, y: 4.2, w: 9, h: 0.5,
fontSize: 15, color: ACCENT2, fontFace: "Calibri", align: "center", italic: true
});
}
// ══════════════════════════════════════════════
// SLIDE 7 – RISK FACTOR 1: POOR HAND HYGIENE
// ══════════════════════════════════════════════
{
const sl = pres.addSlide();
addSlideBackground(sl);
sl.addShape(pres.ShapeType.rect, {
x: 0, y: 0, w: 0.25, h: "100%",
fill: { color: GREEN_SAFE }, line: { color: GREEN_SAFE }
});
sl.addText("RISK FACTOR 1 | Hand Hygiene", {
x: 0.45, y: 0.25, w: 9, h: 0.55,
fontSize: 22, bold: true, color: GREEN_SAFE, fontFace: "Calibri", margin: 0
});
addDividerLine(sl, 0.92);
// Two-column layout
// LEFT – the risk
sl.addShape(pres.ShapeType.rect, {
x: 0.4, y: 1.1, w: 4.3, h: 4.1,
fill: { color: CARD_BG }, line: { color: DANGER_RED, pt: 1.5 }
});
sl.addText("⚠ The Risk", {
x: 0.55, y: 1.18, w: 4.0, h: 0.4,
fontSize: 14, bold: true, color: DANGER_RED, fontFace: "Calibri"
});
sl.addText([
{ text: "Poor hand hygiene is the single most important risk factor for healthcare-associated infections (HAIs).\n\n", options: { breakLine: true } },
{ text: "Pathogens are transferred from contaminated surfaces or patients to hands, then to other patients, wounds, catheters or IV lines.\n\n", options: { breakLine: true } },
{ text: "MRSA, Clostridioides difficile and gram-negative bacteria are commonly spread this way in clinical settings.", options: {} }
], {
x: 0.55, y: 1.62, w: 4.0, h: 3.4,
fontSize: 12.5, color: LIGHT_GRAY, fontFace: "Calibri", valign: "top", wrap: true
});
// RIGHT – reduction
sl.addShape(pres.ShapeType.rect, {
x: 5.1, y: 1.1, w: 4.3, h: 4.1,
fill: { color: CARD_BG }, line: { color: GREEN_SAFE, pt: 1.5 }
});
sl.addText("✔ How to Reduce the Risk", {
x: 5.25, y: 1.18, w: 4.0, h: 0.4,
fontSize: 14, bold: true, color: GREEN_SAFE, fontFace: "Calibri"
});
const preventItems = [
{ text: "Use the WHO 5 Moments for Hand Hygiene — before/after patient contact, before aseptic procedures, after body fluid exposure, after touching patient surroundings.", options: { bullet: { code: "2022" }, breakLine: true, paraSpaceAfter: 4 } },
{ text: "Apply alcohol-based hand rub (ABHR) or soap and water — ABHR is preferred for most clinical interactions.", options: { bullet: { code: "2022" }, breakLine: true, paraSpaceAfter: 4 } },
{ text: "Promote visible, audited hand hygiene compliance programmes. Compliance increases with audit feedback.", options: { bullet: { code: "2022" } } }
];
sl.addText(preventItems, {
x: 5.25, y: 1.62, w: 4.0, h: 3.4,
fontSize: 12, color: LIGHT_GRAY, fontFace: "Calibri", valign: "top", wrap: true,
lineSpacingMultiple: 1.3
});
}
// ══════════════════════════════════════════════
// SLIDE 8 – RISK FACTOR 2: COMPROMISED IMMUNITY
// ══════════════════════════════════════════════
{
const sl = pres.addSlide();
addSlideBackground(sl);
sl.addShape(pres.ShapeType.rect, {
x: 0, y: 0, w: 0.25, h: "100%",
fill: { color: ACCENT1 }, line: { color: ACCENT1 }
});
sl.addText("RISK FACTOR 2 | Compromised Immunity", {
x: 0.45, y: 0.25, w: 9, h: 0.55,
fontSize: 22, bold: true, color: ACCENT1, fontFace: "Calibri", margin: 0
});
addDividerLine(sl, 0.92);
sl.addShape(pres.ShapeType.rect, {
x: 0.4, y: 1.1, w: 4.3, h: 4.1,
fill: { color: CARD_BG }, line: { color: DANGER_RED, pt: 1.5 }
});
sl.addText("⚠ The Risk", {
x: 0.55, y: 1.18, w: 4.0, h: 0.4,
fontSize: 14, bold: true, color: DANGER_RED, fontFace: "Calibri"
});
sl.addText([
{ text: "Patients with weakened immune systems — due to HIV, diabetes, chemotherapy, organ transplant, or extremes of age — have reduced capacity to fight pathogens.\n\n", options: { breakLine: true } },
{ text: "Opportunistic infections (e.g. Pneumocystis pneumonia, CMV, fungal infections) occur at much higher rates.\n\n", options: { breakLine: true } },
{ text: "Neonates and elderly patients in care homes are at especially high risk from common organisms that healthy adults resist easily.", options: {} }
], {
x: 0.55, y: 1.62, w: 4.0, h: 3.4,
fontSize: 12.5, color: LIGHT_GRAY, fontFace: "Calibri", valign: "top", wrap: true
});
sl.addShape(pres.ShapeType.rect, {
x: 5.1, y: 1.1, w: 4.3, h: 4.1,
fill: { color: CARD_BG }, line: { color: ACCENT1, pt: 1.5 }
});
sl.addText("✔ How to Reduce the Risk", {
x: 5.25, y: 1.18, w: 4.0, h: 0.4,
fontSize: 14, bold: true, color: ACCENT1, fontFace: "Calibri"
});
const items2 = [
{ text: "Ensure up-to-date vaccination programmes — including seasonal flu and pneumococcal vaccines for immunocompromised groups.", options: { bullet: { code: "2022" }, breakLine: true, paraSpaceAfter: 4 } },
{ text: "Use protective (reverse) isolation for highly immunocompromised patients (e.g. post-bone-marrow transplant) — HEPA-filtered, positive pressure rooms.", options: { bullet: { code: "2022" }, breakLine: true, paraSpaceAfter: 4 } },
{ text: "Monitor and manage underlying conditions (e.g. glycaemic control in diabetes) to optimise immune function.", options: { bullet: { code: "2022" } } }
];
sl.addText(items2, {
x: 5.25, y: 1.62, w: 4.0, h: 3.4,
fontSize: 12, color: LIGHT_GRAY, fontFace: "Calibri", valign: "top", wrap: true,
lineSpacingMultiple: 1.3
});
}
// ══════════════════════════════════════════════
// SLIDE 9 – RISK FACTOR 3: CROWDED / POOR ENVIRONMENTS
// ══════════════════════════════════════════════
{
const sl = pres.addSlide();
addSlideBackground(sl);
sl.addShape(pres.ShapeType.rect, {
x: 0, y: 0, w: 0.25, h: "100%",
fill: { color: ACCENT2 }, line: { color: ACCENT2 }
});
sl.addText("RISK FACTOR 3 | Environment & Overcrowding", {
x: 0.45, y: 0.25, w: 9, h: 0.55,
fontSize: 22, bold: true, color: ACCENT2, fontFace: "Calibri", margin: 0
});
addDividerLine(sl, 0.92);
sl.addShape(pres.ShapeType.rect, {
x: 0.4, y: 1.1, w: 4.3, h: 4.1,
fill: { color: CARD_BG }, line: { color: DANGER_RED, pt: 1.5 }
});
sl.addText("⚠ The Risk", {
x: 0.55, y: 1.18, w: 4.0, h: 0.4,
fontSize: 14, bold: true, color: DANGER_RED, fontFace: "Calibri"
});
sl.addText([
{ text: "Overcrowded care settings and poor ventilation increase the concentration of airborne particles and the likelihood of contact with contaminated surfaces.\n\n", options: { breakLine: true } },
{ text: "Congregate settings — care homes, wards, ICUs — allow rapid transmission of respiratory pathogens (e.g. TB, COVID-19, influenza).\n\n", options: { breakLine: true } },
{ text: "Poor sanitation and inadequate cleaning of clinical surfaces also allows pathogens to persist and colonise new hosts.", options: {} }
], {
x: 0.55, y: 1.62, w: 4.0, h: 3.4,
fontSize: 12.5, color: LIGHT_GRAY, fontFace: "Calibri", valign: "top", wrap: true
});
sl.addShape(pres.ShapeType.rect, {
x: 5.1, y: 1.1, w: 4.3, h: 4.1,
fill: { color: CARD_BG }, line: { color: ACCENT2, pt: 1.5 }
});
sl.addText("✔ How to Reduce the Risk", {
x: 5.25, y: 1.18, w: 4.0, h: 0.4,
fontSize: 14, bold: true, color: ACCENT2, fontFace: "Calibri"
});
const items3 = [
{ text: "Optimise ventilation — negative pressure rooms for airborne precautions; HEPA filtration in high-risk areas.", options: { bullet: { code: "2022" }, breakLine: true, paraSpaceAfter: 4 } },
{ text: "Apply transmission-based precautions: contact, droplet, and airborne isolation as dictated by the specific pathogen (CDC/HICPAC tiered precautions).", options: { bullet: { code: "2022" }, breakLine: true, paraSpaceAfter: 4 } },
{ text: "Regular environmental decontamination with appropriate disinfectants; cohorting of infected patients to prevent cross-transmission.", options: { bullet: { code: "2022" } } }
];
sl.addText(items3, {
x: 5.25, y: 1.62, w: 4.0, h: 3.4,
fontSize: 12, color: LIGHT_GRAY, fontFace: "Calibri", valign: "top", wrap: true,
lineSpacingMultiple: 1.3
});
}
// ══════════════════════════════════════════════
// SLIDE 10 – SECTION DIVIDER: ANTIBIOTICS
// ══════════════════════════════════════════════
{
const sl = pres.addSlide();
addSlideBackground(sl, MID_BG);
sl.addShape(pres.ShapeType.rect, {
x: 0, y: 1.8, w: "100%", h: 2.1,
fill: { color: DANGER_RED }, line: { color: DANGER_RED }
});
sl.addText("SECTION 3", {
x: 0.5, y: 1.88, w: 9, h: 0.4,
fontSize: 13, bold: true, color: WHITE, fontFace: "Calibri", align: "center", italic: true
});
sl.addText("Antibiotics:\nAdvantages & Dangers", {
x: 0.5, y: 2.25, w: 9, h: 1.4,
fontSize: 34, bold: true, color: WHITE, fontFace: "Calibri", align: "center"
});
sl.addText("A double-edged sword in the treatment of infection", {
x: 0.5, y: 4.2, w: 9, h: 0.5,
fontSize: 16, color: ACCENT2, fontFace: "Calibri", align: "center", italic: true
});
}
// ══════════════════════════════════════════════
// SLIDE 11 – ANTIBIOTICS: ADVANTAGES
// ══════════════════════════════════════════════
{
const sl = pres.addSlide();
addSlideBackground(sl);
sl.addShape(pres.ShapeType.rect, {
x: 0, y: 0, w: "100%", h: 0.5,
fill: { color: GREEN_SAFE }, line: { color: GREEN_SAFE }
});
sl.addText("ANTIBIOTICS | Advantages", {
x: 0.5, y: 0.07, w: 9, h: 0.38,
fontSize: 13, bold: true, color: DARK_BG, fontFace: "Calibri"
});
addHeader(sl, "Advantages of Antibiotic Therapy", 0.65, GREEN_SAFE);
addDividerLine(sl, 1.3);
const advantages = [
{
title: "Cure Bacterial Infections",
body: "Antibiotics are highly effective at eliminating susceptible bacterial pathogens, converting life-threatening infections (sepsis, pneumonia, meningitis, TB) into manageable or curable conditions."
},
{
title: "Prophylaxis",
body: "Pre- and peri-operative antibiotic prophylaxis dramatically reduces the risk of post-surgical infections, protecting patients undergoing invasive procedures."
},
{
title: "Reduced Mortality & Morbidity",
body: "Since their introduction in the 1940s, antibiotics have reduced mortality from bacterial diseases worldwide and enabled modern medicine (surgery, transplants, cancer chemotherapy) which all rely on effective infection control."
},
{
title: "Targeted Spectrum",
body: "Narrow-spectrum agents (e.g. penicillin for streptococcal infection) allow treatment with minimal disruption to the normal microbiome; broad-spectrum agents cover polymicrobial infections when causative organisms are unknown."
}
];
advantages.forEach((a, i) => {
const row = Math.floor(i / 2);
const col = i % 2;
const x = 0.4 + col * 4.8;
const y = 1.5 + row * 1.85;
sl.addShape(pres.ShapeType.rect, {
x, y, w: 4.4, h: 1.7,
fill: { color: CARD_BG }, line: { color: GREEN_SAFE, pt: 1 }
});
sl.addText("✔ " + a.title, {
x: x + 0.1, y: y + 0.08, w: 4.2, h: 0.38,
fontSize: 12.5, bold: true, color: GREEN_SAFE, fontFace: "Calibri"
});
sl.addText(a.body, {
x: x + 0.1, y: y + 0.5, w: 4.2, h: 1.1,
fontSize: 11.5, color: LIGHT_GRAY, fontFace: "Calibri", valign: "top", wrap: true
});
});
}
// ══════════════════════════════════════════════
// SLIDE 12 – ANTIBIOTICS: DANGERS
// ══════════════════════════════════════════════
{
const sl = pres.addSlide();
addSlideBackground(sl);
sl.addShape(pres.ShapeType.rect, {
x: 0, y: 0, w: "100%", h: 0.5,
fill: { color: DANGER_RED }, line: { color: DANGER_RED }
});
sl.addText("ANTIBIOTICS | Dangers", {
x: 0.5, y: 0.07, w: 9, h: 0.38,
fontSize: 13, bold: true, color: WHITE, fontFace: "Calibri"
});
addHeader(sl, "Dangers of Antibiotic Use", 0.65, DANGER_RED);
addDividerLine(sl, 1.3);
const dangers = [
{
title: "Antimicrobial Resistance (AMR)",
body: "Overuse and misuse drives natural selection of resistant strains. MRSA, multi-drug-resistant TB, and carbapenem-resistant Enterobacteriaceae are major global health threats. AMR is projected to cause 10 million deaths/year by 2050 if unchecked."
},
{
title: "Disruption of Normal Microbiome",
body: "Broad-spectrum antibiotics destroy beneficial gut bacteria, allowing opportunistic pathogens such as Clostridioides difficile to overgrow, causing severe, potentially fatal colitis."
},
{
title: "Adverse Drug Reactions",
body: "Side effects include allergic reactions (anaphylaxis with penicillins), nephrotoxicity (aminoglycosides), hepatotoxicity, QT prolongation (fluoroquinolones), and photosensitivity (tetracyclines)."
},
{
title: "Ineffective Against Viruses",
body: "Antibiotics have no effect on viruses (e.g. influenza, COVID-19). Inappropriate prescription accelerates resistance without patient benefit — a key driver of the AMR crisis."
}
];
dangers.forEach((d, i) => {
const row = Math.floor(i / 2);
const col = i % 2;
const x = 0.4 + col * 4.8;
const y = 1.5 + row * 1.85;
sl.addShape(pres.ShapeType.rect, {
x, y, w: 4.4, h: 1.7,
fill: { color: CARD_BG }, line: { color: DANGER_RED, pt: 1 }
});
sl.addText("⚠ " + d.title, {
x: x + 0.1, y: y + 0.08, w: 4.2, h: 0.38,
fontSize: 12.5, bold: true, color: DANGER_RED, fontFace: "Calibri"
});
sl.addText(d.body, {
x: x + 0.1, y: y + 0.5, w: 4.2, h: 1.1,
fontSize: 11.5, color: LIGHT_GRAY, fontFace: "Calibri", valign: "top", wrap: true
});
});
}
// ══════════════════════════════════════════════
// SLIDE 13 – ANTIBIOTICS: BALANCED OVERVIEW TABLE
// ══════════════════════════════════════════════
{
const sl = pres.addSlide();
addSlideBackground(sl);
addHeader(sl, "Antibiotics at a Glance", 0.25, WHITE);
addDividerLine(sl, 0.92);
// Header row
const colDefs = [
{ text: "Aspect", w: 2.0 },
{ text: "Advantages", w: 3.7 },
{ text: "Dangers", w: 3.7 }
];
const rows = [
["Efficacy", "Curative for susceptible bacterial infections; life-saving in sepsis, meningitis, TB", "No effect on viruses; inappropriate use common — drives AMR"],
["Spectrum", "Narrow-spectrum agents preserve microbiome; broad-spectrum covers unknown pathogens", "Broad-spectrum agents deplete beneficial flora; risk of C. difficile"],
["Prophylaxis", "Peri-operative prophylaxis drastically lowers post-surgical infection rates", "Routine or prolonged prophylaxis accelerates resistance"],
["Side Effects", "Well-tolerated in most patients at standard doses", "Allergy (anaphylaxis), nephrotoxicity, QT prolongation, hepatotoxicity"],
["Resistance", "Stewardship programmes can slow resistance emergence", "AMR is a global emergency; threatens modern surgical/oncological care"]
];
// Draw header
const headerColors = [DARK_BG, GREEN_SAFE, DANGER_RED];
let xCur = 0.35;
colDefs.forEach((col, ci) => {
sl.addShape(pres.ShapeType.rect, {
x: xCur, y: 1.05, w: col.w, h: 0.42,
fill: { color: headerColors[ci] }, line: { color: DARK_BG }
});
sl.addText(col.text, {
x: xCur + 0.05, y: 1.07, w: col.w - 0.1, h: 0.38,
fontSize: 12.5, bold: true, color: WHITE, fontFace: "Calibri", align: "center", valign: "middle"
});
xCur += col.w + 0.05;
});
// Draw data rows
rows.forEach((row, ri) => {
const yRow = 1.52 + ri * 0.74;
const rowBg = ri % 2 === 0 ? CARD_BG : "132030";
let xr = 0.35;
colDefs.forEach((col, ci) => {
sl.addShape(pres.ShapeType.rect, {
x: xr, y: yRow, w: col.w, h: 0.7,
fill: { color: rowBg }, line: { color: "1E3A50" }
});
sl.addText(row[ci], {
x: xr + 0.05, y: yRow + 0.02, w: col.w - 0.1, h: 0.66,
fontSize: 10.5, color: ci === 0 ? ACCENT1 : LIGHT_GRAY,
fontFace: "Calibri", valign: "middle", wrap: true,
bold: ci === 0
});
xr += col.w + 0.05;
});
});
}
// ══════════════════════════════════════════════
// SLIDE 14 – ANTIBIOTIC STEWARDSHIP
// ══════════════════════════════════════════════
{
const sl = pres.addSlide();
addSlideBackground(sl);
sl.addShape(pres.ShapeType.rect, {
x: 0, y: 0, w: "100%", h: 0.5,
fill: { color: ACCENT1 }, line: { color: ACCENT1 }
});
sl.addText("ANTIBIOTICS | Stewardship", {
x: 0.5, y: 0.07, w: 9, h: 0.38,
fontSize: 13, bold: true, color: DARK_BG, fontFace: "Calibri"
});
addHeader(sl, "Antibiotic Stewardship: Balancing Benefits & Risks", 0.65, WHITE);
addDividerLine(sl, 1.3);
addBodyText(sl,
"Antibiotic stewardship programmes (ASPs) are coordinated interventions to optimise antibiotic prescribing — ensuring patients receive the right antibiotic, at the right dose, for the right duration. This preserves the effectiveness of existing antibiotics while protecting patients from adverse effects.",
0.5, 1.45, 9, 0.9, LIGHT_GRAY, 14);
const principles = [
{ icon: "📋", label: "Right Indication", detail: "Only prescribe when bacterial infection is confirmed or strongly suspected." },
{ icon: "🔬", label: "Right Drug", detail: "Use culture and sensitivity results; choose narrowest effective spectrum." },
{ icon: "📏", label: "Right Dose & Duration", detail: "Avoid under-dosing (drives resistance) and over-duration (harms microbiome)." },
{ icon: "🔄", label: "IV to Oral Switch", detail: "Switch to oral as soon as clinically appropriate to reduce complications." }
];
principles.forEach((p, i) => {
const x = 0.4 + i * 2.35;
sl.addShape(pres.ShapeType.rect, {
x, y: 2.55, w: 2.1, h: 2.7,
fill: { color: CARD_BG }, line: { color: ACCENT1, pt: 1 }
});
sl.addText(p.icon, {
x: x + 0.05, y: 2.65, w: 2.0, h: 0.5,
fontSize: 22, align: "center", fontFace: "Segoe UI Emoji"
});
sl.addText(p.label, {
x: x + 0.05, y: 3.15, w: 2.0, h: 0.38,
fontSize: 11.5, bold: true, color: ACCENT1, fontFace: "Calibri", align: "center"
});
sl.addText(p.detail, {
x: x + 0.05, y: 3.55, w: 2.0, h: 1.55,
fontSize: 11, color: LIGHT_GRAY, fontFace: "Calibri", align: "center", wrap: true
});
});
}
// ══════════════════════════════════════════════
// SLIDE 15 – SUMMARY
// ══════════════════════════════════════════════
{
const sl = pres.addSlide();
addSlideBackground(sl);
sl.addShape(pres.ShapeType.rect, {
x: 0, y: 0, w: "100%", h: 0.85,
fill: { color: ACCENT1 }, line: { color: ACCENT1 }
});
sl.addText("SUMMARY", {
x: 0.5, y: 0.15, w: 9, h: 0.55,
fontSize: 26, bold: true, color: DARK_BG, fontFace: "Calibri", align: "center"
});
const summaryBlocks = [
{
heading: "Transmission",
color: ACCENT1,
text: "Infectious diseases spread via airborne routes (e.g. TB — inhaled aerosols) and direct contact (e.g. MRSA — hand/skin transfer). Understanding the route is essential for selecting correct precautions."
},
{
heading: "Risk Factors & Prevention",
color: GREEN_SAFE,
text: "Poor hand hygiene, compromised immunity, and overcrowded environments are the three key risk factors. Mitigation includes WHO hand hygiene protocols, isolation precautions, vaccination, and environmental controls."
},
{
heading: "Antibiotics",
color: DANGER_RED,
text: "Antibiotics are life-saving against bacterial infections but carry real dangers: antimicrobial resistance, microbiome disruption, and adverse reactions. Responsible stewardship — right drug, right dose, right duration — is essential."
}
];
summaryBlocks.forEach((b, i) => {
const y = 1.05 + i * 1.45;
sl.addShape(pres.ShapeType.rect, {
x: 0.35, y, w: 9.3, h: 1.3,
fill: { color: CARD_BG }, line: { color: b.color, pt: 2 }
});
sl.addShape(pres.ShapeType.rect, {
x: 0.35, y, w: 0.18, h: 1.3,
fill: { color: b.color }, line: { color: b.color }
});
sl.addText(b.heading, {
x: 0.65, y: y + 0.08, w: 8.8, h: 0.38,
fontSize: 13.5, bold: true, color: b.color, fontFace: "Calibri"
});
sl.addText(b.text, {
x: 0.65, y: y + 0.5, w: 8.8, h: 0.72,
fontSize: 12, color: LIGHT_GRAY, fontFace: "Calibri", valign: "top", wrap: true
});
});
sl.addText("Sources: Tintinalli's Emergency Medicine | Red Book 2021 | Goldman-Cecil Medicine | Robbins Pathology | Harrison's IM 22E", {
x: 0.35, y: 5.22, w: 9.3, h: 0.3,
fontSize: 8.5, color: "5C7D96", fontFace: "Calibri", align: "left", italic: true
});
}
// ─────────────────────────────────────────────
// WRITE FILE
// ─────────────────────────────────────────────
const outputPath = "/home/daytona/workspace/infectious-diseases-ppt/Infectious_Diseases.pptx";
pres.writeFile({ fileName: outputPath })
.then(() => console.log("✅ Saved:", outputPath))
.catch(err => { console.error("❌ Error:", err); process.exit(1); });
cd /home/daytona/workspace/infectious-diseases-ppt && node build.js 2>&1
ls -lh /home/daytona/workspace/infectious-diseases-ppt/Infectious_Diseases.pptx
Infectious Diseases
Presentation · PPTX
| Slide | Content |
|---|---|
| 1 | Title slide — Infectious Diseases: Transmission · Risk · Antibiotics |
| 2 | What Are Infectious Diseases? — Bacteria, Viruses, Parasites/Fungi |
| 3 | Section divider — Transmission |
| 4 | Route 1: Airborne Transmission — TB (inhaled aerosols) + Influenza (droplets) |
| 5 | Route 2: Direct Contact Transmission — MRSA; skin-to-skin, body fluids, fomites |
| 6 | Section divider — Risk Factors & Prevention |
| 7 | Risk Factor 1: Poor Hand Hygiene — the risk + WHO 5 Moments reduction strategy |
| 8 | Risk Factor 2: Compromised Immunity — vulnerable groups + reverse isolation, vaccination |
| 9 | Risk Factor 3: Overcrowding & Environment — transmission precautions, ventilation, decontamination |
| 10 | Section divider — Antibiotics |
| 11 | Antibiotic Advantages — 4 cards: cure, prophylaxis, reduced mortality, targeted spectrum |
| 12 | Antibiotic Dangers — 4 cards: AMR, microbiome disruption, adverse reactions, ineffective vs. viruses |
| 13 | Balanced comparison table — Advantages vs. Dangers across 5 dimensions |
| 14 | Antibiotic Stewardship — right indication, drug, dose/duration, IV-to-oral switch |
| 15 | Summary — all three sections synthesised, with textbook sources cited |