Ppt on peptic ulcer drugs kdt based
ls /home/daytona/workspace/ 2>/dev/null || echo "workspace empty"
mkdir -p /home/daytona/workspace/peptic-ulcer-ppt && ls /home/daytona/workspace/peptic-ulcer-ppt
~/peptic-ulcer-ppt/build.js
const pptxgen = require("pptxgenjs");
const pres = new pptxgen();
pres.layout = "LAYOUT_16x9";
pres.title = "Drugs for Peptic Ulcer Disease";
// βββ THEME βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
const C = {
deepBlue: "0D1B2A", // dominant background
midBlue: "1A3A5C", // card / panel
accent: "00B4D8", // teal accent
gold: "F4A261", // highlight / subheadings
white: "FFFFFF",
lightGray: "D0E4F0",
softGreen: "52B788",
red: "E63946",
yellow: "FFD166",
pill: "1B4F72", // pill badge bg
};
const FONT = "Calibri";
// βββ HELPER: Slide header band ββββββββββββββββββββββββββββββββββββββββββββββββ
function addHeader(slide, title, subtitle) {
slide.addShape(pres.ShapeType.rect, {
x: 0, y: 0, w: 10, h: 1.05,
fill: { color: C.midBlue }
});
slide.addText(title, {
x: 0.25, y: 0.08, w: 9.5, h: 0.6,
fontFace: FONT, fontSize: 24, bold: true, color: C.accent,
});
if (subtitle) {
slide.addText(subtitle, {
x: 0.25, y: 0.62, w: 9.5, h: 0.36,
fontFace: FONT, fontSize: 13, color: C.lightGray, italic: true,
});
}
}
// βββ HELPER: Colored pill badge βββββββββββββββββββββββββββββββββββββββββββββββ
function pill(slide, text, x, y, color) {
slide.addShape(pres.ShapeType.roundRect, {
x, y, w: 1.6, h: 0.32,
fill: { color: color || C.pill },
line: { color: C.accent, width: 1 },
rectRadius: 0.1,
});
slide.addText(text, {
x, y, w: 1.6, h: 0.32,
fontFace: FONT, fontSize: 10, bold: true, color: C.white, align: "center",
});
}
// βββ HELPER: bullet list box βββββββββββββββββββββββββββββββββββββββββββββββββ
function bulletBox(slide, items, x, y, w, h, opts = {}) {
const textArr = items.map((item, i) => ({
text: item,
options: { bullet: true, breakLine: i < items.length - 1, indentLevel: opts.indent || 0 }
}));
slide.addText(textArr, {
x, y, w, h,
fontFace: FONT,
fontSize: opts.fontSize || 13,
color: opts.color || C.lightGray,
valign: "top",
margin: 4,
});
}
// βββ HELPER: Colored card βββββββββββββββββββββββββββββββββββββββββββββββββββββ
function card(slide, x, y, w, h, title, items, titleColor, bgColor) {
slide.addShape(pres.ShapeType.roundRect, {
x, y, w, h,
fill: { color: bgColor || C.midBlue },
line: { color: C.accent, width: 1 },
rectRadius: 0.12,
});
slide.addText(title, {
x: x + 0.12, y: y + 0.08, w: w - 0.24, h: 0.38,
fontFace: FONT, fontSize: 14, bold: true, color: titleColor || C.gold,
});
const txtItems = items.map((t, i) => ({
text: t, options: { bullet: { type: "bullet" }, breakLine: i < items.length - 1 }
}));
slide.addText(txtItems, {
x: x + 0.12, y: y + 0.5, w: w - 0.24, h: h - 0.58,
fontFace: FONT, fontSize: 11, color: C.lightGray, valign: "top",
});
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 1 β TITLE
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.deepBlue };
// Full-width accent band at top
s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 0.18, fill: { color: C.accent } });
// Rx icon area (decorative circle)
s.addShape(pres.ShapeType.ellipse, {
x: 3.8, y: 1.0, w: 2.4, h: 2.4,
fill: { color: C.midBlue },
line: { color: C.accent, width: 3 },
});
s.addText("Rx", {
x: 3.8, y: 1.4, w: 2.4, h: 1.4,
fontFace: FONT, fontSize: 60, bold: true, color: C.accent, align: "center",
});
s.addText("DRUGS FOR PEPTIC ULCER DISEASE", {
x: 0.5, y: 3.55, w: 9, h: 0.75,
fontFace: FONT, fontSize: 30, bold: true, color: C.white, align: "center",
});
s.addText("KD Tripathi Classification | Pharmacology", {
x: 0.5, y: 4.28, w: 9, h: 0.4,
fontFace: FONT, fontSize: 16, color: C.gold, align: "center", italic: true,
});
s.addText("Based on Essentials of Medical Pharmacology", {
x: 0.5, y: 4.72, w: 9, h: 0.35,
fontFace: FONT, fontSize: 13, color: C.lightGray, align: "center",
});
// Bottom accent band
s.addShape(pres.ShapeType.rect, { x: 0, y: 5.33, w: 10, h: 0.3, fill: { color: C.midBlue } });
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 2 β PATHOPHYSIOLOGY OVERVIEW
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.deepBlue };
addHeader(s, "Peptic Ulcer Disease β Pathophysiology", "Imbalance between aggressive & defensive mucosal factors");
// Two columns: Aggressive vs Defensive
// Left: Aggressive
s.addShape(pres.ShapeType.roundRect, { x: 0.3, y: 1.2, w: 4.2, h: 3.8, fill: { color: "3B0A0A" }, line: { color: C.red, width: 1.5 }, rectRadius: 0.12 });
s.addText("π΄ AGGRESSIVE FACTORS", { x: 0.3, y: 1.2, w: 4.2, h: 0.45, fontFace: FONT, fontSize: 14, bold: true, color: C.red, align: "center" });
bulletBox(s, [
"HCl hypersecretion",
"Pepsin activity",
"H. pylori infection (gram-negative)",
"NSAIDs / aspirin (βPG synthesis)",
"Bile reflux",
"Smoking & alcohol",
], 0.42, 1.65, 4.0, 3.2, { fontSize: 12, color: C.lightGray });
// Arrow in middle
s.addText("β‘ vs", { x: 4.5, y: 2.6, w: 1, h: 0.5, fontFace: FONT, fontSize: 22, bold: true, color: C.yellow, align: "center" });
// Right: Defensive
s.addShape(pres.ShapeType.roundRect, { x: 5.5, y: 1.2, w: 4.2, h: 3.8, fill: { color: "0A2B1A" }, line: { color: C.softGreen, width: 1.5 }, rectRadius: 0.12 });
s.addText("π’ DEFENSIVE FACTORS", { x: 5.5, y: 1.2, w: 4.2, h: 0.45, fontFace: FONT, fontSize: 14, bold: true, color: C.softGreen, align: "center" });
bulletBox(s, [
"Mucus & bicarbonate layer",
"Prostaglandins (PGE2, PGI2)",
"Mucosal blood flow",
"Epithelial restitution",
"Surface-active phospholipids",
], 5.62, 1.65, 4.0, 3.2, { fontSize: 12, color: C.lightGray });
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 3 β KDT CLASSIFICATION
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.deepBlue };
addHeader(s, "KDT Classification of Antiulcer Drugs", "KD Tripathi β Essentials of Medical Pharmacology");
const groups = [
{ label: "1. Antacids", color: "2E6B8A", items: ["Systemic: Na bicarbonate, NaHCOβ", "Non-systemic: Mg(OH)β, Al(OH)β, Mg trisilicate, CaCOβ"] },
{ label: "2. Hβ Blockers", color: "1B5E4F", items: ["Cimetidine, Ranitidine*", "Famotidine, Nizatidine"] },
{ label: "3. Proton Pump Inhibitors",color: "4A2060", items: ["Omeprazole, Lansoprazole", "Pantoprazole, Rabeprazole", "Esomeprazole, Dexlansoprazole"] },
{ label: "4. Anti-H. pylori", color: "5A3010", items: ["Triple / Quadruple therapy", "Clarithromycin, Amoxicillin", "Metronidazole, Tetracycline, Bismuth + PPI"] },
{ label: "5. Mucosal Protectives", color: "1B5220", items: ["Sucralfate, Bismuth subsalicylate", "Misoprostol (PGEβ analogue)", "Carbenoxolone"] },
{ label: "6. Anticholinergics", color: "3D1A00", items: ["Pirenzepine (Mβ selective)", "Propantheline (not preferred)"] },
];
const cols = 3;
const cw = 3.1, ch = 2.0;
const startX = 0.2, startY = 1.12;
const gapX = 0.18, gapY = 0.15;
groups.forEach((g, i) => {
const col = i % cols;
const row = Math.floor(i / cols);
const x = startX + col * (cw + gapX);
const y = startY + row * (ch + gapY);
s.addShape(pres.ShapeType.roundRect, { x, y, w: cw, h: ch, fill: { color: g.color }, line: { color: C.accent, width: 1 }, rectRadius: 0.1 });
s.addText(g.label, { x: x + 0.1, y: y + 0.06, w: cw - 0.2, h: 0.38, fontFace: FONT, fontSize: 12, bold: true, color: C.gold });
bulletBox(s, g.items, x + 0.1, y + 0.42, cw - 0.2, ch - 0.5, { fontSize: 11, color: C.lightGray });
});
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 4 β ANTACIDS
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.deepBlue };
addHeader(s, "1. Antacids", "Weak bases that neutralise gastric HCl β’ First-line symptomatic relief");
// Mechanism box
s.addShape(pres.ShapeType.roundRect, { x: 0.25, y: 1.18, w: 9.5, h: 0.58, fill: { color: C.midBlue }, line: { color: C.accent, width: 1 }, rectRadius: 0.1 });
s.addText("Mechanism: Neutralise HCl β β gastric pH β’ Pepsin inactivated above pH 4 β’ Stimulate PG synthesis (Mg, Al salts)", {
x: 0.35, y: 1.22, w: 9.2, h: 0.5, fontFace: FONT, fontSize: 12, color: C.white,
});
const antacids = [
{ name: "Sodium\nBicarbonate", props: ["Rapidly acting", "Systemic β COβ gas formed", "Risk: Milk-alkali syndrome", "Not recommended long-term"], color: "2E3A6B" },
{ name: "Magnesium\nHydroxide", props: ["Rapid onset", "Laxative effect", "β Mg absorption in renal failure", "Used in combination"], color: "1B5E4F" },
{ name: "Aluminium\nHydroxide", props: ["Slower acting", "Constipation (most common SE)", "Binds phosphate β β phosphate", "Preferred in renal failure (caution)"], color: "4A2060" },
{ name: "Calcium\nCarbonate", props: ["Rapid potent action", "Acid rebound (β gastrin)", "Constipation", "Hypercalcaemia risk"], color: "5A3010" },
];
antacids.forEach((a, i) => {
const x = 0.25 + i * 2.4;
s.addShape(pres.ShapeType.roundRect, { x, y: 1.9, w: 2.28, h: 3.5, fill: { color: a.color }, line: { color: C.accent, width: 1 }, rectRadius: 0.1 });
s.addText(a.name, { x: x + 0.08, y: 1.92, w: 2.12, h: 0.6, fontFace: FONT, fontSize: 13, bold: true, color: C.gold, align: "center" });
bulletBox(s, a.props, x + 0.1, y = 2.52, 2.1, 2.8, { fontSize: 11, color: C.lightGray });
});
s.addText("Combined antacids (e.g. Digene = Al(OH)β + Mg(OH)β + Simethicone) minimise individual adverse effects", {
x: 0.25, y: 5.28, w: 9.5, h: 0.3, fontFace: FONT, fontSize: 11, color: C.yellow, italic: true,
});
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 5 β H2 RECEPTOR ANTAGONISTS
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.deepBlue };
addHeader(s, "2. Hβ Receptor Antagonists (Hβ Blockers)", "Competitive antagonists at gastric parietal cell Hβ receptors");
// Mechanism diagram (text-based)
s.addShape(pres.ShapeType.roundRect, { x: 0.25, y: 1.1, w: 9.5, h: 1.25, fill: { color: C.midBlue }, line: { color: C.accent, width: 1.2 }, rectRadius: 0.1 });
s.addText("MECHANISM", { x: 0.35, y: 1.12, w: 2, h: 0.35, fontFace: FONT, fontSize: 12, bold: true, color: C.accent });
s.addText("Histamine (via ECL cells) β Hβ receptor on parietal cell β β cAMP β β PKA β HβΊ/KβΊ-ATPase activation β HCl secretion\nHβ blockers competitively block Hβ receptors β β basal, nocturnal, food-stimulated acid secretion by ~70%", {
x: 0.35, y: 1.44, w: 9.3, h: 0.85, fontFace: FONT, fontSize: 12, color: C.lightGray,
});
const drugs = [
{ name: "Cimetidine", dose: "400 mg BD / 800 mg HS", features: ["1st Hβ blocker (prototype)", "Inhibits CYP450 (major DDI)", "Anti-androgenic (gynaecomastia)", "Crosses BBB β confusion", "Short tΒ½ (2 h)"], color: "2E3A6B" },
{ name: "Ranitidine*", dose: "150 mg BD / 300 mg HS", features: ["5β10Γ more potent", "Less CYP inhibition", "No anti-androgenic effect", "*Withdrawn β NDMA contamination"], color: "5A3010" },
{ name: "Famotidine", dose: "20 mg BD / 40 mg HS", features: ["Most potent Hβ blocker", "No CYP inhibition", "No anti-androgenic effect", "Preferred in pregnancy (Cat B)", "Safe in renal failure (adjust dose)"], color: "1B5E4F" },
{ name: "Nizatidine", dose: "150 mg BD / 300 mg HS", features: ["Similar to ranitidine", "No CYP inhibition", "100% oral bioavailability", "Excreted unchanged in urine"], color: "4A2060" },
];
drugs.forEach((d, i) => {
const x = 0.25 + i * 2.4;
s.addShape(pres.ShapeType.roundRect, { x, y: 2.45, w: 2.28, h: 3.0, fill: { color: d.color }, line: { color: C.accent, width: 1 }, rectRadius: 0.1 });
s.addText(d.name, { x: x + 0.08, y: 2.48, w: 2.12, h: 0.38, fontFace: FONT, fontSize: 13, bold: true, color: C.gold, align: "center" });
s.addText(d.dose, { x: x + 0.08, y: 2.84, w: 2.12, h: 0.28, fontFace: FONT, fontSize: 10, color: C.yellow, align: "center", italic: true });
bulletBox(s, d.features, x + 0.1, 3.14, 2.1, 2.25, { fontSize: 10, color: C.lightGray });
});
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 6 β PROTON PUMP INHIBITORS
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.deepBlue };
addHeader(s, "3. Proton Pump Inhibitors (PPIs)", "Irreversible inhibitors of HβΊ/KβΊ-ATPase β most potent antisecretory agents");
// Mechanism
s.addShape(pres.ShapeType.roundRect, { x: 0.25, y: 1.1, w: 9.5, h: 1.15, fill: { color: C.midBlue }, line: { color: C.accent, width: 1.2 }, rectRadius: 0.1 });
s.addText("MECHANISM: Prodrugs β activated in acidic canaliculi of parietal cell β sulfenamide derivative β irreversible covalent bond with cysteine residues of HβΊ/KβΊ-ATPase β blocks the \"final step\" of HCl secretion\nβ β acid by 80β95% β’ Require 2β5 days for full effect β’ Must be taken 30β60 min BEFORE meals β’ Effective against all stimuli", {
x: 0.35, y: 1.13, w: 9.3, h: 1.05, fontFace: FONT, fontSize: 11.5, color: C.lightGray,
});
const ppis = [
{ name: "Omeprazole", dose: "20β40 mg OD", note: "Prototype; CYP2C19 interaction (clopidogrel warning)" },
{ name: "Pantoprazole", dose: "40 mg OD", note: "Least CYP interaction; preferred IV formulation" },
{ name: "Lansoprazole", dose: "15β30 mg OD", note: "Available as ODT; faster absorption" },
{ name: "Rabeprazole", dose: "20 mg OD", note: "Least dependent on CYP2C19; rapid action" },
{ name: "Esomeprazole", dose: "20β40 mg OD", note: "S-isomer of omeprazole; greater bioavailability" },
{ name: "Dexlansoprazole", dose: "30β60 mg OD", note: "Dual delayed-release; prolonged action" },
];
ppis.forEach((p, i) => {
const col = i % 3;
const row = Math.floor(i / 3);
const x = 0.25 + col * 3.2;
const y = 2.35 + row * 1.52;
s.addShape(pres.ShapeType.roundRect, { x, y, w: 3.1, h: 1.4, fill: { color: "1A1A3A" }, line: { color: C.accent, width: 1 }, rectRadius: 0.1 });
s.addText(p.name, { x: x + 0.1, y: y + 0.06, w: 2.0, h: 0.36, fontFace: FONT, fontSize: 13, bold: true, color: C.gold });
s.addText(p.dose, { x: x + 2.1, y: y + 0.06, w: 0.9, h: 0.36, fontFace: FONT, fontSize: 11, color: C.yellow, align: "right" });
s.addText(p.note, { x: x + 0.1, y: y + 0.48, w: 2.9, h: 0.84, fontFace: FONT, fontSize: 10.5, color: C.lightGray });
});
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 7 β PPI ADVERSE EFFECTS & CLINICAL USES
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.deepBlue };
addHeader(s, "PPIs β Adverse Effects & Clinical Uses", "Long-term use risks must be weighed against benefits");
card(s, 0.25, 1.12, 4.5, 4.35,
"β οΈ Adverse Effects",
[
"Headache, diarrhoea, nausea (common)",
"Hypomagnesaemia (long-term)",
"Vitamin B12 deficiency (long-term)",
"Clostridium difficile infection risk β",
"Fracture risk (β Ca absorption)",
"Fundic gland polyps",
"Community-acquired pneumonia β",
"Hypergastrinaemia β ECL hyperplasia",
"Drug interaction: β clopidogrel effect (CYP2C19)",
], C.red, "2A1010"
);
card(s, 5.05, 1.12, 4.7, 4.35,
"β
Clinical Uses",
[
"Peptic ulcer disease (gastric & duodenal)",
"H. pylori eradication (with antibiotics)",
"GERD / Reflux oesophagitis",
"Zollinger-Ellison syndrome",
"NSAID-induced ulcer prophylaxis",
"Stress ulcer prophylaxis (ICU)",
"Barrett's oesophagus",
"Upper GI bleeding (IV pantoprazole)",
"Dyspepsia",
], C.softGreen, "0A2B1A"
);
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 8 β ANTI-H. PYLORI REGIMENS
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.deepBlue };
addHeader(s, "4. Anti-H. pylori Regimens", "Eradication reduces recurrence from 60β100% to <15% per year");
// Diagnosis box
s.addShape(pres.ShapeType.roundRect, { x: 0.25, y: 1.1, w: 9.5, h: 0.55, fill: { color: C.midBlue }, line: { color: C.accent, width: 1 }, rectRadius: 0.1 });
s.addText("Diagnosis: Endoscopic biopsy (CLO test) | Urea Breath Test (UBT) | Stool Antigen Test | Serology (IgG)", {
x: 0.35, y: 1.14, w: 9.2, h: 0.45, fontFace: FONT, fontSize: 12, color: C.white,
});
const regimens = [
{
title: "Triple Therapy (14 days)",
color: "1B3A5C",
borderColor: C.accent,
items: [
"PPI (standard dose BD)",
"+ Clarithromycin 500 mg BD",
"+ Amoxicillin 1 g BD",
" (or Metronidazole 400 mg BD if penicillin allergy)",
"Eradication: ~80%",
"Use when clarithromycin resistance <15%",
],
},
{
title: "Bismuth Quadruple Therapy (14 days) β
1st Line",
color: "1B3A1B",
borderColor: C.softGreen,
items: [
"PPI (standard dose BD)",
"+ Bismuth subsalicylate 525 mg QID",
"+ Metronidazole 500 mg TID",
"+ Tetracycline 500 mg QID",
"Eradication: >90%",
"Preferred where clarithromycin resistance is high",
],
},
{
title: "Concomitant / Sequential (alternative)",
color: "3D1A00",
borderColor: C.gold,
items: [
"PPI + Clarithromycin",
"+ Amoxicillin + Metronidazole",
"All drugs given together Γ 10β14 days",
"Overcomes metronidazole resistance",
"Levofloxacin-based: salvage therapy",
],
},
];
regimens.forEach((r, i) => {
const x = 0.25 + i * 3.25;
s.addShape(pres.ShapeType.roundRect, { x, y: 1.75, w: 3.15, h: 3.75, fill: { color: r.color }, line: { color: r.borderColor, width: 1.5 }, rectRadius: 0.12 });
s.addText(r.title, { x: x + 0.1, y: 1.78, w: 2.95, h: 0.52, fontFace: FONT, fontSize: 12, bold: true, color: C.gold });
bulletBox(s, r.items, x + 0.1, 2.32, 2.95, 3.1, { fontSize: 11, color: C.lightGray });
});
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 9 β MUCOSAL PROTECTIVE AGENTS
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.deepBlue };
addHeader(s, "5. Mucosal Protective Agents", "Enhance defensive factors without significantly reducing acid secretion");
const agents = [
{
name: "Sucralfate", color: "1B5E4F",
moa: "Polymerises in acid pH β viscous paste β coats ulcer base β barrier against acid/pepsin/bile; also stimulates PG, binds EGF",
dose: "1 g QID (1 h before meals & HS)",
use: "Duodenal ulcer, stress ulcer prophylaxis",
se: "Constipation, β absorption of other drugs (give 2h apart)",
note: "Requires acid for activation β avoid PPIs simultaneously",
},
{
name: "Misoprostol", color: "4A2060",
moa: "PGEβ analogue β β mucus & bicarbonate secretion, β mucosal blood flow, β acid secretion (via IPβ/cAMP in parietal cell)",
dose: "200 ΞΌg QID with food",
use: "NSAID-induced ulcer prophylaxis, gastric ulcer",
se: "Diarrhoea (most common), abdominal cramps, uterine contractions",
note: "Contraindicated in pregnancy (abortifacient β PGEβ)",
},
{
name: "Bismuth Compounds", color: "5A3010",
moa: "Coat ulcer, inhibit H. pylori (disrupts cell wall), β PG, stimulate mucus & HCOβ, bind to pepsin",
dose: "Bismuth subsalicylate 525 mg QID",
use: "H. pylori eradication (quadruple therapy); traveller's diarrhoea",
se: "Black stools & tongue (bismuth sulfide), nausea",
note: "Not to be confused with bismuth toxicity at high doses",
},
{
name: "Carbenoxolone", color: "2E3A6B",
moa: "Synthetic derivative of glycyrrhetinic acid β β mucus synthesis & secretion, β mucosal PGs, β epithelial life span",
dose: "100 mg TID (before meals)",
use: "Gastric ulcer (less used now)",
se: "Sodium & water retention (aldosterone-like), hypertension, hypokalaemia",
note: "Largely replaced by PPIs",
},
];
agents.forEach((a, i) => {
const col = i % 2;
const row = Math.floor(i / 2);
const x = 0.25 + col * 4.9;
const y = 1.12 + row * 2.35;
s.addShape(pres.ShapeType.roundRect, { x, y, w: 4.72, h: 2.25, fill: { color: a.color }, line: { color: C.accent, width: 1 }, rectRadius: 0.12 });
s.addText(a.name, { x: x + 0.12, y: y + 0.06, w: 3.5, h: 0.38, fontFace: FONT, fontSize: 14, bold: true, color: C.gold });
s.addText(a.dose, { x: x + 3.5, y: y + 0.06, w: 1.1, h: 0.38, fontFace: FONT, fontSize: 10, color: C.yellow, align: "right", italic: true });
const details = [
{ text: "MOA: ", options: { bold: true, color: C.accent, breakLine: false } },
{ text: a.moa, options: { color: C.lightGray, breakLine: true } },
{ text: "Use: ", options: { bold: true, color: C.accent, breakLine: false } },
{ text: a.use, options: { color: C.lightGray, breakLine: true } },
{ text: "SE: ", options: { bold: true, color: C.red, breakLine: false } },
{ text: a.se, options: { color: C.lightGray, breakLine: true } },
{ text: "β ", options: { bold: true, color: C.yellow, breakLine: false } },
{ text: a.note, options: { color: C.yellow, italic: true } },
];
s.addText(details, { x: x + 0.12, y: y + 0.48, w: 4.5, h: 1.7, fontFace: FONT, fontSize: 10, valign: "top" });
});
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 10 β ANTICHOLINERGICS / OTHER DRUGS
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.deepBlue };
addHeader(s, "6. Other Drugs β Anticholinergics & Miscellaneous", "Adjuncts in peptic ulcer management");
card(s, 0.25, 1.12, 4.6, 4.3,
"Anticholinergics",
[
"Pirenzepine (Mβ selective) β preferred",
" Dose: 50 mg BD, before meals",
" β Acid secretion by blocking Mβ on ECL/ganglion cells",
" SE: Dry mouth, blurred vision (mild β Mβ/Mβ spared)",
"",
"Non-selective (Propantheline, Atropine)",
" Block all muscarinic receptors",
" High SE: dry mouth, constipation, urinary retention, tachycardia",
" Now rarely used for ulcers",
], C.gold, "2E1A00"
);
card(s, 5.1, 1.12, 4.6, 4.3,
"Miscellaneous Agents",
[
"Vonoprazan (Potassium-Competitive Acid Blocker)",
" KβΊ-competitive, reversible; faster onset than PPIs",
" Not pH-dependent activation; effective even at night",
"",
"Rebamipide",
" β Prostaglandins, scavenges free radicals",
" Used in Asia for mucosal healing",
"",
"Prokinetics (Domperidone, Metoclopramide)",
" Adjuncts in GERD to β gastric emptying & LES tone",
], C.accent, "0A1A2A"
);
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 11 β DRUG COMPARISON TABLE
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.deepBlue };
addHeader(s, "Comparative Overview", "Hβ Blockers vs PPIs vs Antacids");
const rows = [
["Parameter", "Antacids", "Hβ Blockers", "PPIs"],
["Mechanism", "Neutralise HCl", "Block Hβ receptor", "Block HβΊ/KβΊ-ATPase"],
["Acid reduction", "Transient", "~70%", "80β95%"],
["Onset", "Immediate", "30β60 min", "1β4 days (full effect)"],
["Duration", "1β2 h", "6β12 h", "24 h (irreversible)"],
["H. pylori use", "No", "No", "Yes (cornerstone)"],
["Pregnancy", "Safe (Ca, Mg)", "Famotidine (Cat B)", "Omeprazole (Cat C)"],
["Key ADR", "Acid rebound", "Cimetidine β DDI", "βB12, hypoMg"],
];
const colColors = [C.midBlue, "2E3A6B", "1B5E4F", "4A2060"];
const colW = [2.5, 2.4, 2.4, 2.4];
const rowH = 0.48;
const startX = 0.25, startY = 1.1;
rows.forEach((row, ri) => {
row.forEach((cell, ci) => {
const x = startX + colW.slice(0, ci).reduce((a, b) => a + b, 0);
const y = startY + ri * rowH;
const isHeader = ri === 0;
const isRowLabel = ci === 0;
s.addShape(pres.ShapeType.rect, {
x, y, w: colW[ci], h: rowH,
fill: { color: isHeader ? C.accent : (isRowLabel ? "1A2A3A" : colColors[ci]) },
line: { color: C.deepBlue, width: 1 },
});
s.addText(cell, {
x: x + 0.08, y, w: colW[ci] - 0.16, h: rowH,
fontFace: FONT,
fontSize: isHeader ? 13 : 11,
bold: isHeader || isRowLabel,
color: isHeader ? C.deepBlue : C.lightGray,
valign: "middle",
});
});
});
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 12 β NSAID-INDUCED ULCER & SPECIAL SITUATIONS
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.deepBlue };
addHeader(s, "NSAID-Induced Ulcer & Special Situations", "Prevention and management strategies");
card(s, 0.25, 1.12, 4.6, 4.3,
"NSAID-Induced Ulcer",
[
"NSAIDs inhibit COX-1 β β PGEβ / PGIβ",
" β β Mucus & bicarbonate",
" β β Mucosal blood flow",
" β Direct mucosal damage",
"",
"Prevention options:",
" β’ Misoprostol 200 ΞΌg QID (PGEβ analogue)",
" β’ PPI (omeprazole/pantoprazole) β preferred",
" β’ Switch to COX-2 selective NSAID",
"",
"If H. pylori present: eradicate first",
], C.gold, "2A1A00"
);
card(s, 5.1, 1.12, 4.6, 4.3,
"Special Clinical Scenarios",
[
"Zollinger-Ellison Syndrome:",
" High-dose PPI (omeprazole 60β360 mg/day)",
"",
"Stress Ulcer Prophylaxis (ICU):",
" IV pantoprazole or sucralfate",
"",
"Upper GI Bleeding:",
" IV PPI bolus then infusion (pantoprazole 80 mg + 8 mg/h)",
"",
"Pregnancy:",
" Antacids (1st line), Sucralfate (safe), Famotidine (if needed)",
" Avoid misoprostol (abortifacient)",
"",
"Paediatrics:",
" Omeprazole / Lansoprazole (age-appropriate dosing)",
], C.accent, "0A1A2A"
);
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 13 β DRUG INTERACTIONS & KEY POINTS
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.deepBlue };
addHeader(s, "Key Drug Interactions & High-Yield Points", "Important for exams and clinical practice");
card(s, 0.25, 1.12, 4.6, 4.3,
"β οΈ Drug Interactions",
[
"Cimetidine (major CYP inhibitor):",
" β Warfarin, phenytoin, theophylline, lidocaine levels",
"",
"PPIs + Clopidogrel:",
" Omeprazole inhibits CYP2C19 β β clopidogrel activation",
" Use pantoprazole/rabeprazole instead",
"",
"Antacids:",
" Chelate fluoroquinolones, tetracyclines, iron",
" Give 2 h apart from other drugs",
"",
"Sucralfate:",
" Adsorbs many drugs β give 2 h before other drugs",
], C.red, "2A0808"
);
card(s, 5.1, 1.12, 4.6, 4.3,
"π High-Yield Memory Points",
[
"PPIs = most potent & first-line antisecretory drugs",
"Cimetidine = 1st Hβ blocker, most DDIs",
"Famotidine = most potent Hβ blocker",
"Misoprostol = only drug contraindicated in pregnancy",
"Sucralfate needs acid for action β avoid with PPIs",
"Carbenoxolone β aldosterone-like SE",
"Pirenzepine = selective Mβ blocker",
"Ranitidine withdrawn (NDMA)",
"Quadruple therapy = >90% H. pylori eradication",
"PPI + Clarithromycin + Amoxicillin = triple therapy",
], C.softGreen, "0A2010"
);
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 14 β SUMMARY FLOWCHART
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.deepBlue };
addHeader(s, "Treatment Algorithm β Peptic Ulcer Disease", "Stepwise approach based on etiology");
// Flowchart using boxes + arrows (text-based)
const boxData = [
{ x: 3.5, y: 1.1, w: 3.0, h: 0.55, text: "Confirmed Peptic Ulcer", color: C.accent, textColor: C.deepBlue },
{ x: 0.25, y: 2.15, w: 2.5, h: 0.55, text: "H. pylori +ve", color: "1B5E4F", textColor: C.white },
{ x: 7.25, y: 2.15, w: 2.5, h: 0.55, text: "H. pylori -ve", color: "2E3A6B", textColor: C.white },
{ x: 0.1, y: 3.1, w: 2.8, h: 0.9, text: "Triple/Quadruple\nTherapy Γ 14 d\n+ PPI", color: "0A2B1A", textColor: C.lightGray },
{ x: 7.1, y: 3.1, w: 2.8, h: 0.9, text: "PPI Γ 4β8 wks\n(Omeprazole/Pantoprazole)\n+ Hβ blocker if needed", color: "0A1A2B", textColor: C.lightGray },
{ x: 3.5, y: 4.15, w: 3.0, h: 0.6, text: "Confirm Eradication (UBT)\nβ PPI Γ 4 more weeks", color: "2A1A00", textColor: C.yellow },
{ x: 3.5, y: 5.0, w: 3.0, h: 0.5, text: "Maintenance: Lifestyle + review NSAIDs", color: C.midBlue, textColor: C.lightGray },
];
boxData.forEach(b => {
s.addShape(pres.ShapeType.roundRect, { x: b.x, y: b.y, w: b.w, h: b.h, fill: { color: b.color }, line: { color: C.accent, width: 1 }, rectRadius: 0.1 });
s.addText(b.text, { x: b.x + 0.08, y: b.y, w: b.w - 0.16, h: b.h, fontFace: FONT, fontSize: 11.5, bold: true, color: b.textColor, valign: "middle", align: "center" });
});
// Connecting lines / arrows (text arrows)
s.addText("β", { x: 4.7, y: 1.65, w: 0.6, h: 0.5, fontFace: FONT, fontSize: 22, color: C.accent, align: "center" });
s.addText("β", { x: 3.5, y: 1.65, w: 1.5, h: 0.5, fontFace: FONT, fontSize: 22, color: C.softGreen, align: "center" });
s.addText("β", { x: 5.0, y: 1.65, w: 1.5, h: 0.5, fontFace: FONT, fontSize: 22, color: C.accent, align: "center" });
s.addText("β", { x: 1.2, y: 4.0, w: 0.6, h: 0.35, fontFace: FONT, fontSize: 18, color: C.softGreen, align: "center" });
s.addText("β", { x: 8.2, y: 4.0, w: 0.6, h: 0.35, fontFace: FONT, fontSize: 18, color: C.accent, align: "center" });
s.addText("β β", { x: 4.5, y: 4.76, w: 1.0, h: 0.3, fontFace: FONT, fontSize: 16, color: C.yellow, align: "center" });
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 15 β THANK YOU
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.deepBlue };
s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 0.18, fill: { color: C.accent } });
s.addShape(pres.ShapeType.rect, { x: 0, y: 5.45, w: 10, h: 0.18, fill: { color: C.accent } });
s.addShape(pres.ShapeType.ellipse, { x: 3.8, y: 0.8, w: 2.4, h: 2.4, fill: { color: C.midBlue }, line: { color: C.gold, width: 2 } });
s.addText("β", { x: 3.8, y: 0.9, w: 2.4, h: 2.2, fontFace: FONT, fontSize: 70, color: C.softGreen, align: "center" });
s.addText("Thank You", { x: 0.5, y: 3.3, w: 9, h: 0.7, fontFace: FONT, fontSize: 40, bold: true, color: C.white, align: "center" });
s.addText("KD Tripathi β Essentials of Medical Pharmacology", {
x: 0.5, y: 4.05, w: 9, h: 0.4, fontFace: FONT, fontSize: 15, color: C.gold, align: "center", italic: true,
});
s.addText("Lippincott Illustrated Reviews: Pharmacology | Katzung's Basic and Clinical Pharmacology", {
x: 0.5, y: 4.45, w: 9, h: 0.35, fontFace: FONT, fontSize: 12, color: C.lightGray, align: "center",
});
}
// Write file
pres.writeFile({ fileName: "/home/daytona/workspace/peptic-ulcer-ppt/Peptic_Ulcer_Drugs_KDT.pptx" })
.then(() => console.log("DONE"))
.catch(e => { console.error(e); process.exit(1); });
cd /home/daytona/workspace/peptic-ulcer-ppt && node build.js 2>&1
ls -lh /home/daytona/workspace/peptic-ulcer-ppt/Peptic_Ulcer_Drugs_KDT.pptx
Peptic Ulcer Drugs KDT
Presentation Β· PPTX
| Slide | Content |
|---|---|
| 1 | Title Slide β Drugs for Peptic Ulcer Disease (KDT-based) |
| 2 | Pathophysiology β Aggressive vs Defensive factors |
| 3 | KDT Classification β All 6 groups in color-coded cards |
| 4 | Antacids β Systemic vs Non-systemic, 4 drugs compared |
| 5 | Hβ Blockers β Mechanism + all 4 drugs (dose, features, SE) |
| 6 | Proton Pump Inhibitors β MOA + all 6 PPIs with doses |
| 7 | PPI Adverse Effects & Clinical Uses β Long-term risks |
| 8 | Anti-H. pylori Regimens β Triple, Quadruple, Concomitant |
| 9 | Mucosal Protective Agents β Sucralfate, Misoprostol, Bismuth, Carbenoxolone |
| 10 | Anticholinergics & Miscellaneous β Pirenzepine, Vonoprazan, Rebamipide |
| 11 | Comparison Table β Antacids vs Hβ Blockers vs PPIs |
| 12 | NSAID-Induced Ulcer & Special Situations β Pregnancy, ZES, ICU |
| 13 | Drug Interactions & High-Yield Points β Exam essentials |
| 14 | Treatment Algorithm Flowchart β H. pylori +ve vs -ve |
| 15 | Thank You / References |
Try again
~/peptic-ulcer-ppt/build2.js
const pptxgen = require("pptxgenjs");
const pres = new pptxgen();
pres.layout = "LAYOUT_16x9";
pres.title = "Drugs for Peptic Ulcer Disease β KDT";
// βββ WARM ORANGE/RED ACADEMIC PALETTE ββββββββββββββββββββββββββββββββββββββββ
const C = {
cream: "FFF8F0", // dominant slide background
warmWhite: "FFFFFF",
darkBrown: "2C1503", // text / dominant dark
rust: "C0392B", // primary accent (red)
orange: "E67E22", // secondary accent
amber: "F39C12", // highlight / subheadings
burntSiena: "A04000", // card tops / headers
teal: "1A7A7A", // contrast accent
softGreen: "27AE60",
charcoal: "3D3D3D",
lightRust: "F5D5CC", // card background
lightAmber: "FEF0D9", // alt card bg
midBrown: "7B3A10",
darkRed: "7B0A0A",
parchment: "FAF0E0", // slide bg variant
};
const FONT = "Georgia";
const FONT2 = "Calibri";
// βββ HELPERS ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
function addHeader(slide, title, sub) {
// Red diagonal band at top
slide.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 1.1, fill: { color: C.rust } });
// Orange accent strip
slide.addShape(pres.ShapeType.rect, { x: 0, y: 1.0, w: 10, h: 0.12, fill: { color: C.amber } });
slide.addText(title, {
x: 0.3, y: 0.08, w: 9.4, h: 0.58,
fontFace: FONT, fontSize: 23, bold: true, color: C.warmWhite,
});
if (sub) {
slide.addText(sub, {
x: 0.3, y: 0.66, w: 9.4, h: 0.3,
fontFace: FONT2, fontSize: 12, color: C.lightAmber, italic: true,
});
}
}
function roundCard(slide, x, y, w, h, title, titleColor, bgColor, borderColor) {
slide.addShape(pres.ShapeType.roundRect, {
x, y, w, h,
fill: { color: bgColor || C.lightAmber },
line: { color: borderColor || C.orange, width: 1.5 },
rectRadius: 0.14,
});
slide.addShape(pres.ShapeType.roundRect, {
x, y, w, h: 0.44,
fill: { color: borderColor || C.orange },
line: { color: borderColor || C.orange, width: 0 },
rectRadius: 0.14,
});
slide.addText(title, {
x: x + 0.12, y: y + 0.04, w: w - 0.24, h: 0.36,
fontFace: FONT, fontSize: 13, bold: true, color: titleColor || C.warmWhite,
});
}
function bulletBox(slide, items, x, y, w, h, opts = {}) {
const arr = items.map((t, i) => ({
text: t,
options: { bullet: true, breakLine: i < items.length - 1 },
}));
slide.addText(arr, {
x, y, w, h,
fontFace: FONT2, fontSize: opts.fontSize || 12,
color: opts.color || C.charcoal,
valign: "top", margin: 4,
});
}
function labelValue(slide, label, value, x, y, w) {
slide.addText([
{ text: label + " ", options: { bold: true, color: C.rust } },
{ text: value, options: { color: C.charcoal } },
], { x, y, w, h: 0.35, fontFace: FONT2, fontSize: 11.5 });
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 1 β TITLE
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.darkBrown };
// Top decorative bars
s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 0.22, fill: { color: C.rust } });
s.addShape(pres.ShapeType.rect, { x: 0, y: 0.22, w: 10, h: 0.1, fill: { color: C.amber } });
// Bottom bars
s.addShape(pres.ShapeType.rect, { x: 0, y: 5.3, w: 10, h: 0.1, fill: { color: C.amber } });
s.addShape(pres.ShapeType.rect, { x: 0, y: 5.4, w: 10, h: 0.22, fill: { color: C.rust } });
// Central circle
s.addShape(pres.ShapeType.ellipse, { x: 3.5, y: 0.7, w: 3.0, h: 3.0, fill: { color: C.rust }, line: { color: C.amber, width: 3 } });
s.addText("π", { x: 3.5, y: 0.8, w: 3.0, h: 2.8, fontSize: 64, align: "center", valign: "middle" });
// Title block
s.addShape(pres.ShapeType.roundRect, { x: 0.3, y: 3.8, w: 9.4, h: 1.4, fill: { color: C.burntSiena }, line: { color: C.amber, width: 2 }, rectRadius: 0.12 });
s.addText("DRUGS FOR PEPTIC ULCER DISEASE", {
x: 0.3, y: 3.86, w: 9.4, h: 0.65,
fontFace: FONT, fontSize: 28, bold: true, color: C.warmWhite, align: "center",
});
s.addText("KD Tripathi Classification Β· Essentials of Medical Pharmacology", {
x: 0.3, y: 4.5, w: 9.4, h: 0.38,
fontFace: FONT2, fontSize: 14, color: C.amber, align: "center", italic: true,
});
s.addText("Pharmacology | Academic Presentation", {
x: 0.3, y: 4.9, w: 9.4, h: 0.28,
fontFace: FONT2, fontSize: 11, color: C.lightRust, align: "center",
});
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 2 β PATHOPHYSIOLOGY
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.parchment };
addHeader(s, "Peptic Ulcer Disease β Pathophysiology", "Imbalance of aggressive vs. defensive mucosal factors");
// Left: Aggressive
s.addShape(pres.ShapeType.roundRect, { x: 0.2, y: 1.25, w: 4.3, h: 4.1, fill: { color: C.lightRust }, line: { color: C.rust, width: 2 }, rectRadius: 0.14 });
s.addShape(pres.ShapeType.roundRect, { x: 0.2, y: 1.25, w: 4.3, h: 0.52, fill: { color: C.rust }, line: { color: C.rust, width: 0 }, rectRadius: 0.14 });
s.addText("AGGRESSIVE FACTORS", { x: 0.3, y: 1.28, w: 4.1, h: 0.42, fontFace: FONT, fontSize: 14, bold: true, color: C.warmWhite });
bulletBox(s, [
"HCl hypersecretion (parietal cells)",
"Pepsin (proteolytic enzyme)",
"H. pylori infection (gram-negative rod)",
"NSAIDs & Aspirin β β PG synthesis",
"Bile salts reflux",
"Smoking, alcohol",
"Stress & corticosteroids",
], 0.3, 1.82, 4.1, 3.45, { fontSize: 12, color: C.darkRed });
// VS
s.addShape(pres.ShapeType.ellipse, { x: 4.4, y: 2.85, w: 1.2, h: 0.75, fill: { color: C.amber }, line: { color: C.rust, width: 1.5 } });
s.addText("VS", { x: 4.4, y: 2.85, w: 1.2, h: 0.75, fontFace: FONT, fontSize: 18, bold: true, color: C.warmWhite, align: "center", valign: "middle" });
// Right: Defensive
s.addShape(pres.ShapeType.roundRect, { x: 5.5, y: 1.25, w: 4.3, h: 4.1, fill: { color: "DFF2E9" }, line: { color: C.softGreen, width: 2 }, rectRadius: 0.14 });
s.addShape(pres.ShapeType.roundRect, { x: 5.5, y: 1.25, w: 4.3, h: 0.52, fill: { color: C.softGreen }, line: { color: C.softGreen, width: 0 }, rectRadius: 0.14 });
s.addText("DEFENSIVE FACTORS", { x: 5.6, y: 1.28, w: 4.1, h: 0.42, fontFace: FONT, fontSize: 14, bold: true, color: C.warmWhite });
bulletBox(s, [
"Mucus layer (viscous bicarbonate gel)",
"Bicarbonate secretion (surface cells)",
"Mucosal blood flow (Oβ & nutrients)",
"Prostaglandins β PGEβ & PGIβ",
"Tight epithelial junctions",
"Epithelial restitution (rapid repair)",
"Surface-active phospholipids",
], 5.6, 1.82, 4.1, 3.45, { fontSize: 12, color: "1A5C35" });
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 3 β KDT CLASSIFICATION
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.cream };
addHeader(s, "KDT Classification of Antiulcer Drugs", "6 major groups β KD Tripathi's Essentials of Medical Pharmacology");
const groups = [
{ num: "1", title: "Antacids", drugs: "Systemic: NaHCOβ\nNon-systemic: Mg(OH)β, Al(OH)β\nMg trisilicate, CaCOβ", bg: "FDE8D8", border: C.rust },
{ num: "2", title: "Hβ Blockers", drugs: "Cimetidine (prototype)\nRanitidine* (withdrawn)\nFamotidine Β· Nizatidine", bg: "FEF0CC", border: C.amber },
{ num: "3", title: "Proton Pump Inhibitors", drugs: "Omeprazole, Lansoprazole\nPantoprazole, Rabeprazole\nEsomeprazole, Dexlansoprazole", bg: "F9E4D4", border: C.orange },
{ num: "4", title: "Anti-H. pylori Drugs", drugs: "Amoxicillin, Clarithromycin\nMetronidazole, Tetracycline\nBismuth compounds + PPI", bg: "D9EFE4", border: C.softGreen },
{ num: "5", title: "Mucosal Protectives", drugs: "Sucralfate\nMisoprostol (PGEβ analogue)\nBismuth subsalicylate\nCarbenoxolone", bg: "DDEEF9", border: C.teal },
{ num: "6", title: "Anticholinergics", drugs: "Pirenzepine (Mβ selective)\nPropantheline (non-selective)\n[adjuncts β rarely used]", bg: "EDE0F5", border: "7B4BA0" },
];
const cw = 3.0, ch = 2.0;
groups.forEach((g, i) => {
const col = i % 3;
const row = Math.floor(i / 3);
const x = 0.25 + col * (cw + 0.28);
const y = 1.2 + row * (ch + 0.18);
s.addShape(pres.ShapeType.roundRect, { x, y, w: cw, h: ch, fill: { color: g.bg }, line: { color: g.border, width: 2 }, rectRadius: 0.14 });
// Number badge
s.addShape(pres.ShapeType.ellipse, { x: x + 0.1, y: y + 0.08, w: 0.42, h: 0.42, fill: { color: g.border }, line: { color: g.border, width: 0 } });
s.addText(g.num, { x: x + 0.1, y: y + 0.08, w: 0.42, h: 0.42, fontFace: FONT, fontSize: 14, bold: true, color: C.warmWhite, align: "center", valign: "middle" });
s.addText(g.title, { x: x + 0.6, y: y + 0.1, w: cw - 0.72, h: 0.38, fontFace: FONT, fontSize: 13, bold: true, color: C.darkBrown });
s.addShape(pres.ShapeType.line, { x: x + 0.1, y: y + 0.56, w: cw - 0.2, h: 0, line: { color: g.border, width: 1, dashType: "dash" } });
s.addText(g.drugs, { x: x + 0.1, y: y + 0.62, w: cw - 0.2, h: ch - 0.74, fontFace: FONT2, fontSize: 11, color: C.charcoal, valign: "top" });
});
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 4 β ANTACIDS
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.cream };
addHeader(s, "1. Antacids", "Weak bases that neutralise HCl Β· pH rises above 3.5 β pepsin inactivated");
// Mechanism banner
s.addShape(pres.ShapeType.roundRect, { x: 0.2, y: 1.22, w: 9.6, h: 0.55, fill: { color: C.lightAmber }, line: { color: C.amber, width: 1.5 }, rectRadius: 0.1 });
s.addText("Mechanism: Neutralise HCl β β gastric pH | Pepsin activity β at pH >4 | Mg & Al salts also stimulate PG synthesis", {
x: 0.3, y: 1.26, w: 9.4, h: 0.45, fontFace: FONT2, fontSize: 12, color: C.darkBrown,
});
const cols = [
{ name: "Sodium\nBicarbonate", dose: "0.6β2 g PRN", props: ["Rapidly acting systemic antacid", "Gas (COβ) formation β belching", "Milk-alkali syndrome (chronic)", "Systemic alkalosis risk", "Not for long-term use"], bg: "FDE8D8", border: C.rust },
{ name: "Magnesium\nHydroxide", dose: "0.3β1 g PRN", props: ["Rapid potent action", "Non-systemic (poorly absorbed)", "Osmotic laxative effect", "β Mg absorbed β toxicity in CRF", "Used in combination antacids"], bg: "FEF0CC", border: C.amber },
{ name: "Aluminium\nHydroxide", dose: "0.6β1 g PRN", props: ["Slower, sustained action", "Non-systemic antacid", "Constipation (most common SE)", "Binds phosphate (used in CRF)", "Adsorbs pepsin & bile salts"], bg: "F9E4D4", border: C.orange },
{ name: "Calcium\nCarbonate", dose: "0.5β2 g PRN", props: ["Most potent & rapid antacid", "Acid rebound (β gastrin)", "Constipation", "Hypercalcaemia, nephrolithiasis", "Milk-alkali syndrome"], bg: "DDEEF9", border: C.teal },
];
cols.forEach((c, i) => {
const x = 0.2 + i * 2.42;
s.addShape(pres.ShapeType.roundRect, { x, y: 1.85, w: 2.32, h: 3.6, fill: { color: c.bg }, line: { color: c.border, width: 1.5 }, rectRadius: 0.12 });
s.addShape(pres.ShapeType.roundRect, { x, y: 1.85, w: 2.32, h: 0.7, fill: { color: c.border }, line: { color: c.border, width: 0 }, rectRadius: 0.12 });
s.addText(c.name, { x: x + 0.08, y: 1.88, w: 2.16, h: 0.62, fontFace: FONT, fontSize: 12.5, bold: true, color: C.warmWhite, align: "center", valign: "middle" });
s.addText(c.dose, { x: x + 0.08, y: 2.6, w: 2.16, h: 0.28, fontFace: FONT2, fontSize: 10.5, color: C.burntSiena, align: "center", italic: true });
bulletBox(s, c.props, x + 0.1, 2.92, 2.12, 2.45, { fontSize: 10.5, color: C.charcoal });
});
s.addText("Tip: Combination antacids (e.g. Digene = Al(OH)β + Mg(OH)β + Simethicone) balance constipation vs laxative effects", {
x: 0.2, y: 5.5, w: 9.6, h: 0.26, fontFace: FONT2, fontSize: 10.5, color: C.burntSiena, italic: true,
});
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 5 β H2 BLOCKERS
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.cream };
addHeader(s, "2. Hβ Receptor Antagonists", "Competitive antagonists at Hβ receptors of parietal cells");
// MOA box
s.addShape(pres.ShapeType.roundRect, { x: 0.2, y: 1.22, w: 9.6, h: 1.0, fill: { color: C.lightAmber }, line: { color: C.amber, width: 1.5 }, rectRadius: 0.1 });
s.addText("MECHANISM", { x: 0.35, y: 1.25, w: 1.8, h: 0.3, fontFace: FONT, fontSize: 12, bold: true, color: C.rust });
s.addText("Histamine (from ECL cells) β Hβ receptor on parietal cell β β cAMP β β PKA β activates HβΊ/KβΊ-ATPase β HCl secretion\nHβ blockers: Competitively block Hβ receptors β β acid by ~70% (basal, nocturnal & food-stimulated acid)", {
x: 0.35, y: 1.52, w: 9.4, h: 0.64, fontFace: FONT2, fontSize: 11.5, color: C.darkBrown,
});
const drugs = [
{ name: "Cimetidine", dose: "400 mg BD\nor 800 mg HS", features: ["1st Hβ blocker (prototype)", "Inhibits CYP1A2, 2C9, 2D6, 3A4", "β Warfarin, phenytoin, theophylline", "Anti-androgenic: gynaecomastia", "Crosses BBB β confusion (elderly)", "Inhibits tubular creatinine secretion"], bg: C.lightRust, border: C.rust },
{ name: "Ranitidine*", dose: "150 mg BD\nor 300 mg HS", features: ["5β10Γ more potent than cimetidine", "Minimal CYP inhibition", "No anti-androgenic effects", "β Withdrawn (NDMA contamination)", "Famotidine now preferred"], bg: "F5E6C8", border: C.amber },
{ name: "Famotidine", dose: "20 mg BD\nor 40 mg HS", features: ["Most potent Hβ blocker", "No CYP inhibition", "No anti-androgenic effects", "Safe: Pregnancy Cat B", "Dose adjust in renal failure"], bg: "D9F0EC", border: C.teal },
{ name: "Nizatidine", dose: "150 mg BD\nor 300 mg HS", features: ["Similar to ranitidine in potency", "No CYP inhibition", "Highest oral bioavailability (~100%)", "Excreted unchanged in urine", "Least studied of the group"], bg: "E4EEF9", border: "4A7AB0" },
];
drugs.forEach((d, i) => {
const x = 0.2 + i * 2.42;
s.addShape(pres.ShapeType.roundRect, { x, y: 2.28, w: 2.32, h: 3.25, fill: { color: d.bg }, line: { color: d.border, width: 1.5 }, rectRadius: 0.12 });
s.addShape(pres.ShapeType.roundRect, { x, y: 2.28, w: 2.32, h: 0.62, fill: { color: d.border }, line: { color: d.border, width: 0 }, rectRadius: 0.12 });
s.addText(d.name, { x: x + 0.08, y: 2.3, w: 2.16, h: 0.38, fontFace: FONT, fontSize: 13, bold: true, color: C.warmWhite, align: "center" });
s.addText(d.dose, { x: x + 0.08, y: 2.66, w: 2.16, h: 0.36, fontFace: FONT2, fontSize: 9.5, color: C.burntSiena, align: "center", italic: true });
bulletBox(s, d.features, x + 0.1, 3.05, 2.12, 2.42, { fontSize: 10, color: C.charcoal });
});
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 6 β PPIs MECHANISM & DRUGS
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.cream };
addHeader(s, "3. Proton Pump Inhibitors (PPIs)", "Most potent antisecretory drugs Β· Irreversible HβΊ/KβΊ-ATPase inhibitors");
// Mechanism
s.addShape(pres.ShapeType.roundRect, { x: 0.2, y: 1.22, w: 9.6, h: 1.12, fill: { color: C.lightAmber }, line: { color: C.orange, width: 1.5 }, rectRadius: 0.1 });
s.addText("MECHANISM", { x: 0.35, y: 1.25, w: 1.8, h: 0.3, fontFace: FONT, fontSize: 12, bold: true, color: C.rust });
s.addText(
"Prodrugs β absorbed in small intestine β reach parietal cell canaliculi β activated (sulfenamide) at acidic pH β " +
"irreversible covalent bond with cysteine residues of HβΊ/KβΊ-ATPase\n" +
"β Blocks FINAL COMMON PATHWAY Β· β HCl by 80β95% Β· Must be taken 30β60 min BEFORE meals Β· 2β5 days for full effect",
{ x: 0.35, y: 1.52, w: 9.4, h: 0.76, fontFace: FONT2, fontSize: 11.5, color: C.darkBrown }
);
const ppis = [
{ name: "Omeprazole", dose: "20β40 mg OD", note: "Prototype PPI; inhibits CYP2C19 β clopidogrel interaction (avoid co-use)", bg: "FDE8D8", border: C.rust },
{ name: "Pantoprazole", dose: "40 mg OD", note: "Least CYP interaction; IV form available β preferred in GI bleeds", bg: "FEF0CC", border: C.amber },
{ name: "Lansoprazole", dose: "15β30 mg OD", note: "ODT (orally disintegrating tablet); faster absorption; also available for paediatrics", bg: "F9E4D4", border: C.orange },
{ name: "Rabeprazole", dose: "20 mg OD", note: "Least dependent on CYP2C19 polymorphism; faster onset of action", bg: "D9F0E4", border: C.softGreen },
{ name: "Esomeprazole", dose: "20β40 mg OD", note: "S-isomer of omeprazole; greater bioavailability; once-daily dosing", bg: "DDEEF9", border: C.teal },
{ name: "Dexlansoprazole", dose: "30β60 mg OD", note: "Dual delayed-release; two peak plasma concentrations; prolonged acid control", bg: "EDE0F5", border: "7B4BA0" },
];
ppis.forEach((p, i) => {
const col = i % 3;
const row = Math.floor(i / 3);
const x = 0.2 + col * 3.25;
const y = 2.42 + row * 1.6;
s.addShape(pres.ShapeType.roundRect, { x, y, w: 3.12, h: 1.52, fill: { color: p.bg }, line: { color: p.border, width: 1.5 }, rectRadius: 0.12 });
s.addShape(pres.ShapeType.roundRect, { x, y, w: 3.12, h: 0.44, fill: { color: p.border }, line: { color: p.border, width: 0 }, rectRadius: 0.12 });
s.addText(p.name, { x: x + 0.1, y: y + 0.04, w: 2.0, h: 0.36, fontFace: FONT, fontSize: 13, bold: true, color: C.warmWhite });
s.addText(p.dose, { x: x + 2.0, y: y + 0.04, w: 1.0, h: 0.36, fontFace: FONT2, fontSize: 10, color: C.warmWhite, align: "right", italic: true });
s.addText(p.note, { x: x + 0.1, y: y + 0.5, w: 2.9, h: 0.95, fontFace: FONT2, fontSize: 10.5, color: C.charcoal, valign: "top" });
});
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 7 β PPIs: ADRs & USES
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.cream };
addHeader(s, "PPIs β Adverse Effects & Clinical Uses", "Weigh long-term risks against therapeutic benefits");
// Adverse effects card
s.addShape(pres.ShapeType.roundRect, { x: 0.2, y: 1.22, w: 4.6, h: 4.25, fill: { color: "FDE8D8" }, line: { color: C.rust, width: 2 }, rectRadius: 0.14 });
s.addShape(pres.ShapeType.roundRect, { x: 0.2, y: 1.22, w: 4.6, h: 0.52, fill: { color: C.rust }, line: { color: C.rust, width: 0 }, rectRadius: 0.14 });
s.addText("β ADVERSE EFFECTS", { x: 0.32, y: 1.25, w: 4.36, h: 0.44, fontFace: FONT, fontSize: 13.5, bold: true, color: C.warmWhite });
bulletBox(s, [
"Headache, diarrhoea, nausea (common)",
"Hypomagnesaemia β tetany, arrhythmia",
"Vitamin B12 deficiency (long-term)",
"C. difficile infection risk β",
"Osteoporosis / fracture risk",
"Fundic gland polyps",
"Hypergastrinaemia β ECL cell hyperplasia",
"Community-acquired pneumonia β",
"CKD risk (long-term use data)",
"DDI: Omeprazole β clopidogrel (CYP2C19)",
], 0.32, 1.78, 4.38, 3.62, { fontSize: 11.5, color: C.darkRed });
// Clinical uses card
s.addShape(pres.ShapeType.roundRect, { x: 5.2, y: 1.22, w: 4.6, h: 4.25, fill: { color: "D9F2E4" }, line: { color: C.softGreen, width: 2 }, rectRadius: 0.14 });
s.addShape(pres.ShapeType.roundRect, { x: 5.2, y: 1.22, w: 4.6, h: 0.52, fill: { color: C.softGreen }, line: { color: C.softGreen, width: 0 }, rectRadius: 0.14 });
s.addText("β CLINICAL USES", { x: 5.32, y: 1.25, w: 4.36, h: 0.44, fontFace: FONT, fontSize: 13.5, bold: true, color: C.warmWhite });
bulletBox(s, [
"Peptic ulcer disease (duodenal & gastric)",
"H. pylori eradication (cornerstone drug)",
"GERD / Reflux oesophagitis",
"Zollinger-Ellison syndrome (high-dose)",
"NSAID-induced ulcer prophylaxis",
"Stress ulcer prophylaxis (ICU)",
"Barrett's oesophagus",
"Upper GI bleeding (IV pantoprazole)",
"Non-ulcer dyspepsia",
"Laryngopharyngeal reflux",
], 5.32, 1.78, 4.38, 3.62, { fontSize: 11.5, color: "1A5C35" });
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 8 β ANTI-H. PYLORI
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.cream };
addHeader(s, "4. Anti-H. pylori Regimens", "Eradication β recurrence β from 60β100% to <15%/year");
s.addShape(pres.ShapeType.roundRect, { x: 0.2, y: 1.22, w: 9.6, h: 0.48, fill: { color: C.lightAmber }, line: { color: C.amber, width: 1 }, rectRadius: 0.1 });
s.addText("Diagnosis: Endoscopic CLO test | Urea Breath Test (UBT) | Stool Antigen Test | Serology (IgG β low specificity)", {
x: 0.3, y: 1.26, w: 9.4, h: 0.38, fontFace: FONT2, fontSize: 12, color: C.darkBrown,
});
const regs = [
{
title: "Triple Therapy (Γ14 days)",
border: C.teal, bg: "DDEEF9",
lines: [
"PPI (standard dose) BD",
"+ Clarithromycin 500 mg BD",
"+ Amoxicillin 1 g BD",
" (or Metronidazole 400 mg BD if PCN allergy)",
"Eradication rate: ~80%",
"Use where clarithromycin resistance <15%",
"Prior macrolide exposure β avoid",
],
},
{
title: "Bismuth Quadruple (Γ14 days) β
1st Line",
border: C.softGreen, bg: "D9F2E4",
lines: [
"PPI (standard dose) BD",
"+ Bismuth subsalicylate 525 mg QID",
"+ Metronidazole 500 mg TID",
"+ Tetracycline 500 mg QID",
"Eradication rate: >90%",
"Preferred where clarithromycin resistance is high",
"First-line per ACG/AGA guidelines",
],
},
{
title: "Salvage / Levofloxacin Therapy",
border: C.orange, bg: "F9EED8",
lines: [
"PPI + Levofloxacin 500 mg OD",
"+ Amoxicillin 1 g BD Γ 14 days",
"After failed first-line treatment",
"Concomitant therapy: PPI + Clarithromycin",
" + Amoxicillin + Metronidazole Γ 10β14 d",
"Rifabutin-based: last resort",
],
},
];
regs.forEach((r, i) => {
const x = 0.2 + i * 3.25;
s.addShape(pres.ShapeType.roundRect, { x, y: 1.78, w: 3.12, h: 3.75, fill: { color: r.bg }, line: { color: r.border, width: 2 }, rectRadius: 0.14 });
s.addShape(pres.ShapeType.roundRect, { x, y: 1.78, w: 3.12, h: 0.56, fill: { color: r.border }, line: { color: r.border, width: 0 }, rectRadius: 0.14 });
s.addText(r.title, { x: x + 0.1, y: 1.81, w: 2.92, h: 0.48, fontFace: FONT, fontSize: 12, bold: true, color: C.warmWhite });
bulletBox(s, r.lines, x + 0.12, 2.38, 2.9, 3.08, { fontSize: 11, color: C.charcoal });
});
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 9 β MUCOSAL PROTECTIVE AGENTS
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.cream };
addHeader(s, "5. Mucosal Protective Agents", "Enhance defensive factors β no significant acid reduction");
const agents = [
{
name: "Sucralfate", dose: "1 g QID (1 h before meals & HS)", bg: "FDE8D8", border: C.rust,
moa: "In acid pH β polymerises β viscous paste β coats ulcer crater β barrier vs acid/pepsin/bile; stimulates PG, binds EGF",
use: "Duodenal ulcer, stress ulcer prophylaxis",
se: "Constipation; adsorbs other drugs (give 2 h apart)",
note: "Needs acid for activation β avoid simultaneous PPIs",
},
{
name: "Misoprostol", dose: "200 ΞΌg QID with meals", bg: "FEF0CC", border: C.amber,
moa: "PGEβ analogue β Gs-coupled β β mucus & HCOβ secretion, β mucosal blood flow, β acid secretion (inhibits HβΊ/KβΊ-ATPase via β cAMP)",
use: "NSAID-induced ulcer prophylaxis; gastric ulcer",
se: "Diarrhoea (most common), abdominal cramps, uterine contractions",
note: "β Contraindicated in pregnancy β potent abortifacient",
},
{
name: "Bismuth Subsalicylate", dose: "525 mg QID", bg: "D9F2E4", border: C.softGreen,
moa: "Coats ulcer surface; kills H. pylori (disrupts cell wall & inhibits urease); β mucus & PG; binds pepsin",
use: "H. pylori eradication (quadruple); traveller's diarrhoea",
se: "Black stools & tongue (bismuth sulphide β harmless), nausea",
note: "Salicylate component β avoid in aspirin allergy / children (Reye's)",
},
{
name: "Carbenoxolone", dose: "100 mg TID before meals", bg: "DDEEF9", border: C.teal,
moa: "Liquorice derivative β β mucus quality & quantity, β mucosal PGs, prolongs surface cell lifespan",
use: "Gastric ulcer (now largely obsolete)",
se: "Na & water retention (aldosterone-like), hypertension, hypokalaemia, oedema",
note: "Replaced by PPIs; use with aldosterone antagonist (spironolactone)",
},
];
agents.forEach((a, i) => {
const col = i % 2;
const row = Math.floor(i / 2);
const x = 0.2 + col * 4.95;
const y = 1.2 + row * 2.35;
s.addShape(pres.ShapeType.roundRect, { x, y, w: 4.75, h: 2.25, fill: { color: a.bg }, line: { color: a.border, width: 1.5 }, rectRadius: 0.14 });
s.addShape(pres.ShapeType.roundRect, { x, y, w: 4.75, h: 0.48, fill: { color: a.border }, line: { color: a.border, width: 0 }, rectRadius: 0.14 });
s.addText(a.name, { x: x + 0.12, y: y + 0.05, w: 2.8, h: 0.38, fontFace: FONT, fontSize: 13, bold: true, color: C.warmWhite });
s.addText(a.dose, { x: x + 2.88, y: y + 0.05, w: 1.78, h: 0.38, fontFace: FONT2, fontSize: 9.5, color: C.warmWhite, align: "right", italic: true });
const detail = [
{ text: "MOA: ", options: { bold: true, color: C.rust, breakLine: false } },
{ text: a.moa, options: { color: C.charcoal, breakLine: true } },
{ text: "Use: ", options: { bold: true, color: C.burntSiena, breakLine: false } },
{ text: a.use, options: { color: C.charcoal, breakLine: true } },
{ text: "SE: ", options: { bold: true, color: C.rust, breakLine: false } },
{ text: a.se, options: { color: C.charcoal, breakLine: true } },
{ text: "β ", options: { bold: true, color: C.amber, breakLine: false } },
{ text: a.note, options: { color: C.midBrown, italic: true } },
];
s.addText(detail, { x: x + 0.12, y: y + 0.52, w: 4.52, h: 1.65, fontFace: FONT2, fontSize: 10, valign: "top" });
});
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 10 β ANTICHOLINERGICS & MISC
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.cream };
addHeader(s, "6. Anticholinergics & Miscellaneous Drugs", "Adjuncts β largely replaced by PPIs");
// Left: Anticholinergics
s.addShape(pres.ShapeType.roundRect, { x: 0.2, y: 1.22, w: 4.6, h: 4.25, fill: { color: C.lightRust }, line: { color: C.rust, width: 2 }, rectRadius: 0.14 });
s.addShape(pres.ShapeType.roundRect, { x: 0.2, y: 1.22, w: 4.6, h: 0.52, fill: { color: C.rust }, line: { color: C.rust, width: 0 }, rectRadius: 0.14 });
s.addText("Anticholinergics", { x: 0.32, y: 1.25, w: 4.36, h: 0.44, fontFace: FONT, fontSize: 13.5, bold: true, color: C.warmWhite });
bulletBox(s, [
"Pirenzepine (Mβ SELECTIVE β preferred)",
" Dose: 50 mg BD before meals",
" Blocks Mβ on ECL cells & ganglion cells",
" β Acid secretion; spares Mβ (heart) & Mβ (glands)",
" SE: dry mouth, blurred vision (mild)",
"",
"Propantheline (Non-selective)",
" Blocks all muscarinic receptors",
" SE: dry mouth, urinary retention,",
" constipation, tachycardia (severe)",
" β Largely abandoned for ulcer therapy",
], 0.32, 1.78, 4.38, 3.65, { fontSize: 11, color: C.darkRed });
// Right: Miscellaneous
s.addShape(pres.ShapeType.roundRect, { x: 5.2, y: 1.22, w: 4.6, h: 4.25, fill: { color: "EAF4FB" }, line: { color: C.teal, width: 2 }, rectRadius: 0.14 });
s.addShape(pres.ShapeType.roundRect, { x: 5.2, y: 1.22, w: 4.6, h: 0.52, fill: { color: C.teal }, line: { color: C.teal, width: 0 }, rectRadius: 0.14 });
s.addText("Miscellaneous / Newer Agents", { x: 5.32, y: 1.25, w: 4.36, h: 0.44, fontFace: FONT, fontSize: 13.5, bold: true, color: C.warmWhite });
bulletBox(s, [
"Vonoprazan (P-CAB)",
" Potassium-competitive acid blocker",
" Reversible KβΊ-competitive inhibition of HβΊ/KβΊ-ATPase",
" Not pH-dependent for activation (unlike PPIs)",
" Faster onset; effective day-1; controls nocturnal acid",
"",
"Rebamipide",
" β PG synthesis, scavenges ROS, enhances mucin",
" Used adjunctively in Asia",
"",
"Prokinetics (Domperidone, Metoclopramide)",
" Adjuncts in GERD: β LES tone, β gastric emptying",
], 5.32, 1.78, 4.38, 3.65, { fontSize: 11, color: "0A3040" });
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 11 β COMPARISON TABLE
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.cream };
addHeader(s, "Comparative Overview", "Antacids Β· Hβ Blockers Β· PPIs β at a glance");
const rows = [
["Parameter", "Antacids", "Hβ Blockers", "PPIs"],
["Mechanism", "Neutralise HCl", "Block Hβ receptor", "Irreversible HβΊ/KβΊ-ATPase block"],
["Acid reduction", "Transient β", "~70%", "80β95%"],
["Onset", "Immediate", "30β60 min", "1β4 days (full effect)"],
["Duration", "1β2 hours", "6β12 hours", "24 h (irreversible enzyme)"],
["H. pylori use", "No", "No", "Yes (cornerstone)"],
["GERD first-line", "Symptomatic only", "Mild GERD", "ModerateβSevere GERD"],
["Pregnancy", "Mg, Ca, Al (safe)", "Famotidine (Cat B)", "Omeprazole (Cat C)"],
["Key ADR", "Acid rebound (CaCOβ)", "Cimetidine DDIs", "βB12, hypoMg, C. diff"],
];
const colW = [2.6, 2.3, 2.3, 2.5];
const rowH = 0.46;
const hdrColors = [C.rust, C.burntSiena, C.amber, C.orange];
const rowBgOdd = "FFF5EC";
const rowBgEven = "FDE8D8";
rows.forEach((row, ri) => {
row.forEach((cell, ci) => {
const x = 0.2 + colW.slice(0, ci).reduce((a, b) => a + b, 0);
const y = 1.2 + ri * rowH;
const isHdr = ri === 0;
const isLabel = ci === 0;
s.addShape(pres.ShapeType.rect, {
x, y, w: colW[ci], h: rowH,
fill: { color: isHdr ? hdrColors[ci] : (isLabel ? C.lightAmber : (ri % 2 === 0 ? rowBgOdd : rowBgEven)) },
line: { color: "CCBBAA", width: 0.8 },
});
s.addText(cell, {
x: x + 0.08, y, w: colW[ci] - 0.16, h: rowH,
fontFace: isHdr ? FONT : FONT2,
fontSize: isHdr ? 13 : 11,
bold: isHdr || isLabel,
color: isHdr ? C.warmWhite : C.charcoal,
valign: "middle",
wrap: true,
});
});
});
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 12 β NSAID ULCER & SPECIAL SITUATIONS
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.cream };
addHeader(s, "NSAID-Induced Ulcer & Special Situations", "Prevention strategies and high-risk scenarios");
// NSAID
s.addShape(pres.ShapeType.roundRect, { x: 0.2, y: 1.22, w: 4.6, h: 4.22, fill: { color: "FDE8D8" }, line: { color: C.rust, width: 2 }, rectRadius: 0.14 });
s.addShape(pres.ShapeType.roundRect, { x: 0.2, y: 1.22, w: 4.6, h: 0.52, fill: { color: C.rust }, line: { color: C.rust, width: 0 }, rectRadius: 0.14 });
s.addText("NSAID-Induced Ulcer", { x: 0.32, y: 1.25, w: 4.36, h: 0.44, fontFace: FONT, fontSize: 13.5, bold: true, color: C.warmWhite });
bulletBox(s, [
"NSAIDs inhibit COX-1 β β PGEβ / PGIβ",
"β β Mucus & bicarbonate secretion",
"β β Mucosal blood flow",
"β Direct mucosal damage (acidic NSAIDs)",
"",
"Prevention / Management:",
"β’ PPI (omeprazole / pantoprazole) β PREFERRED",
"β’ Misoprostol 200 ΞΌg QID (FDA approved)",
"β’ Switch to COX-2 selective NSAID (celecoxib)",
"β’ Hβ blocker (less effective than PPI)",
"β’ If H. pylori +ve: eradicate first",
"β’ Lowest effective NSAID dose for shortest duration",
], 0.32, 1.78, 4.38, 3.58, { fontSize: 11, color: C.darkRed });
// Special situations
s.addShape(pres.ShapeType.roundRect, { x: 5.2, y: 1.22, w: 4.6, h: 4.22, fill: { color: "EAF4FB" }, line: { color: C.teal, width: 2 }, rectRadius: 0.14 });
s.addShape(pres.ShapeType.roundRect, { x: 5.2, y: 1.22, w: 4.6, h: 0.52, fill: { color: C.teal }, line: { color: C.teal, width: 0 }, rectRadius: 0.14 });
s.addText("Special Clinical Scenarios", { x: 5.32, y: 1.25, w: 4.36, h: 0.44, fontFace: FONT, fontSize: 13.5, bold: true, color: C.warmWhite });
bulletBox(s, [
"Zollinger-Ellison Syndrome:",
" High-dose PPI (60β360 mg omeprazole/day)",
"",
"Stress Ulcer (ICU): IV pantoprazole / sucralfate",
"",
"Upper GI Bleeding:",
" IV PPI bolus 80 mg then 8 mg/h infusion Γ 72 h",
"",
"Pregnancy:",
" Antacids (1st line) β Sucralfate β Famotidine",
" Avoid misoprostol (abortifacient)",
"",
"Paediatrics: Omeprazole / Lansoprazole ODT",
"",
"Renal failure: Famotidine (dose-adjust); avoid Mg antacid",
], 5.32, 1.78, 4.38, 3.58, { fontSize: 11, color: "0A3040" });
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 13 β DRUG INTERACTIONS & HIGH-YIELD
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.cream };
addHeader(s, "Drug Interactions & High-Yield Exam Points", "Clinically significant interactions to remember");
s.addShape(pres.ShapeType.roundRect, { x: 0.2, y: 1.22, w: 4.6, h: 4.22, fill: { color: C.lightRust }, line: { color: C.rust, width: 2 }, rectRadius: 0.14 });
s.addShape(pres.ShapeType.roundRect, { x: 0.2, y: 1.22, w: 4.6, h: 0.52, fill: { color: C.rust }, line: { color: C.rust, width: 0 }, rectRadius: 0.14 });
s.addText("β Drug Interactions", { x: 0.32, y: 1.25, w: 4.36, h: 0.44, fontFace: FONT, fontSize: 13.5, bold: true, color: C.warmWhite });
bulletBox(s, [
"Cimetidine (CYP inhibitor):",
" β Warfarin, phenytoin, theophylline,",
" lidocaine, diazepam, propranolol",
"",
"PPI + Clopidogrel:",
" Omeprazole inhibits CYP2C19 β β clopidogrel",
" Use pantoprazole / rabeprazole instead",
"",
"Antacids + Other Drugs:",
" Chelate fluoroquinolones, tetracyclines, iron",
" Separate by at least 2 hours",
"",
"Sucralfate: adsorbs drugs β give 2 h before",
"Misoprostol: potentiates oxytocics",
], 0.32, 1.78, 4.38, 3.58, { fontSize: 11, color: C.darkRed });
s.addShape(pres.ShapeType.roundRect, { x: 5.2, y: 1.22, w: 4.6, h: 4.22, fill: { color: C.lightAmber }, line: { color: C.amber, width: 2 }, rectRadius: 0.14 });
s.addShape(pres.ShapeType.roundRect, { x: 5.2, y: 1.22, w: 4.6, h: 0.52, fill: { color: C.amber }, line: { color: C.amber, width: 0 }, rectRadius: 0.14 });
s.addText("π High-Yield Memory Points", { x: 5.32, y: 1.25, w: 4.36, h: 0.44, fontFace: FONT, fontSize: 13.5, bold: true, color: C.darkBrown });
bulletBox(s, [
"PPIs = most potent antisecretory drugs (1st line)",
"Cimetidine = 1st Hβ blocker; most drug interactions",
"Famotidine = most potent Hβ blocker",
"Omeprazole = prototype PPI (CYP2C19 DDI)",
"Pantoprazole = safest PPI (fewest DDIs); IV available",
"Misoprostol = contraindicated in pregnancy",
"Sucralfate = needs acid; give apart from other drugs",
"Carbenoxolone β aldosterone-like effects",
"Pirenzepine = selective Mβ blocker",
"Ranitidine = withdrawn (NDMA contamination)",
"Quadruple therapy β >90% H. pylori eradication",
], 5.32, 1.78, 4.38, 3.58, { fontSize: 11, color: C.darkBrown });
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 14 β TREATMENT ALGORITHM
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.cream };
addHeader(s, "Treatment Algorithm β Peptic Ulcer Disease", "Tailored approach based on etiology");
// Central diagnosis box
s.addShape(pres.ShapeType.roundRect, { x: 3.3, y: 1.18, w: 3.4, h: 0.58, fill: { color: C.rust }, line: { color: C.amber, width: 2 }, rectRadius: 0.1 });
s.addText("Confirmed Peptic Ulcer", { x: 3.3, y: 1.18, w: 3.4, h: 0.58, fontFace: FONT, fontSize: 13, bold: true, color: C.warmWhite, align: "center", valign: "middle" });
// Arrow down
s.addText("βΌ", { x: 4.7, y: 1.76, w: 0.6, h: 0.3, fontSize: 16, color: C.rust, align: "center" });
// Test box
s.addShape(pres.ShapeType.roundRect, { x: 2.8, y: 2.06, w: 4.4, h: 0.52, fill: { color: C.lightAmber }, line: { color: C.amber, width: 1.5 }, rectRadius: 0.1 });
s.addText("Test for H. pylori (UBT / Stool Ag / Biopsy)", { x: 2.8, y: 2.06, w: 4.4, h: 0.52, fontFace: FONT2, fontSize: 12, bold: true, color: C.darkBrown, align: "center", valign: "middle" });
// Branches
s.addText("POSITIVE β", { x: 0.4, y: 2.62, w: 2.3, h: 0.36, fontFace: FONT2, fontSize: 12, bold: true, color: C.softGreen });
s.addText("βΆ NEGATIVE", { x: 7.3, y: 2.62, w: 2.3, h: 0.36, fontFace: FONT2, fontSize: 12, bold: true, color: C.teal });
// H. pylori +ve branch
s.addShape(pres.ShapeType.roundRect, { x: 0.2, y: 3.0, w: 4.1, h: 1.62, fill: { color: "DFF2E9" }, line: { color: C.softGreen, width: 1.5 }, rectRadius: 0.1 });
s.addText("Quadruple / Triple Therapy Γ 14 days\n+ PPI (standard dose)\nβ Confirm eradication (UBT at 4 wks)\nβ PPI Γ 4 more weeks post-eradication", { x: 0.32, y: 3.04, w: 3.86, h: 1.52, fontFace: FONT2, fontSize: 11.5, color: "1A5C35" });
// H. pylori -ve branch
s.addShape(pres.ShapeType.roundRect, { x: 5.7, y: 3.0, w: 4.1, h: 1.62, fill: { color: "DDEEF9" }, line: { color: C.teal, width: 1.5 }, rectRadius: 0.1 });
s.addText("PPI Γ 4β8 weeks (omeprazole/pantoprazole)\n+ Hβ blocker (if PPI not tolerated)\nIf NSAID-induced: add misoprostol or stop NSAID\nReview contributing factors (NSAIDs, smoking)", { x: 5.82, y: 3.04, w: 3.86, h: 1.52, fontFace: FONT2, fontSize: 11.5, color: "0A2B4A" });
// Bottom
s.addShape(pres.ShapeType.roundRect, { x: 2.4, y: 4.72, w: 5.2, h: 0.72, fill: { color: C.lightAmber }, line: { color: C.orange, width: 1.5 }, rectRadius: 0.1 });
s.addText("Maintenance: Lifestyle modification Β· Avoid NSAIDs Β· Stop smoking Β· Reduce alcohol", { x: 2.52, y: 4.76, w: 4.96, h: 0.62, fontFace: FONT2, fontSize: 11.5, color: C.darkBrown, align: "center", valign: "middle" });
s.addText("β² β²", { x: 3.0, y: 4.56, w: 4.0, h: 0.22, fontSize: 14, color: C.orange, align: "center" });
}
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
// SLIDE 15 β SUMMARY & THANK YOU
// βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
{
const s = pres.addSlide();
s.background = { color: C.darkBrown };
s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 0.2, fill: { color: C.rust } });
s.addShape(pres.ShapeType.rect, { x: 0, y: 0.2, w: 10, h: 0.1, fill: { color: C.amber } });
s.addShape(pres.ShapeType.rect, { x: 0, y: 5.3, w: 10, h: 0.1, fill: { color: C.amber } });
s.addShape(pres.ShapeType.rect, { x: 0, y: 5.4, w: 10, h: 0.22, fill: { color: C.rust } });
// Quick summary box
s.addShape(pres.ShapeType.roundRect, { x: 0.3, y: 0.42, w: 9.4, h: 3.35, fill: { color: C.burntSiena }, line: { color: C.amber, width: 2 }, rectRadius: 0.14 });
s.addText("Summary", { x: 0.5, y: 0.48, w: 3, h: 0.42, fontFace: FONT, fontSize: 18, bold: true, color: C.amber });
const sumData = [
["1. Antacids", "Neutralise HCl; symptomatic relief; NaHCOβ (systemic), Al/Mg/Ca salts (non-systemic)"],
["2. Hβ Blockers", "~70% acid β; Cimetidine (DDI risk); Famotidine (most potent, safest)"],
["3. PPIs", "80β95% acid β; irreversible; most potent; cornerstone of PUD & GERD therapy"],
["4. Anti-H. pylori", "Quadruple (>90% eradication) or Triple therapy with PPI backbone"],
["5. Mucosal Protectives", "Sucralfate (coat), Misoprostol (PGEβ), Bismuth, Carbenoxolone (βmucus)"],
["6. Anticholinergics", "Pirenzepine (Mβ selective); mostly obsolete; replaced by PPIs"],
];
sumData.forEach((row, i) => {
s.addText([
{ text: row[0] + ": ", options: { bold: true, color: C.amber } },
{ text: row[1], options: { color: C.lightAmber } },
], { x: 0.5, y: 0.94 + i * 0.45, w: 9.1, h: 0.42, fontFace: FONT2, fontSize: 11.5 });
});
s.addText("Thank You", { x: 0.5, y: 3.88, w: 9, h: 0.65, fontFace: FONT, fontSize: 34, bold: true, color: C.warmWhite, align: "center" });
s.addText("Reference: KD Tripathi β Essentials of Medical Pharmacology (8th Ed.)", {
x: 0.5, y: 4.52, w: 9, h: 0.32, fontFace: FONT2, fontSize: 12, color: C.amber, align: "center", italic: true,
});
s.addText("Supplemented with Lippincott Illustrated Reviews: Pharmacology & Katzung's Basic and Clinical Pharmacology", {
x: 0.5, y: 4.84, w: 9, h: 0.28, fontFace: FONT2, fontSize: 10.5, color: C.lightRust, align: "center",
});
}
// βββ WRITE FILE βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
pres.writeFile({ fileName: "/home/daytona/workspace/peptic-ulcer-ppt/Peptic_Ulcer_Drugs_KDT_v2.pptx" })
.then(() => console.log("DONE"))
.catch(e => { console.error(e); process.exit(1); });