Create a comprehensive 10 pages ppt on priapism with defition,etiology,pathogenesis,classification,clinical manifestation,diagnosis,differential diagnosis and treatment.Add important small diagrams wherever u think is important.add to the topics page itself
priapism definition etiology pathogenesis classification treatment guidelines 2024
mkdir -p /home/daytona/workspace/priapism-ppt && ls /home/daytona/workspace/pria…
~/priapism-ppt/priapism.js
const pptxgen = require("pptxgenjs");
const pres = new pptxgen();
pres.layout = "LAYOUT_16x9";
pres.title = "Priapism - A Comprehensive Overview";
// ─────────────────────────────────────────────
// THEME
// ─────────────────────────────────────────────
const C = {
navy: "0D2B55", // dominant dark blue
teal: "1A7FA0", // accent teal
red: "C0392B", // alert / emphasis
orange: "E67E22", // sub-accent
white: "FFFFFF",
light: "EBF4F8", // light blue-grey background
text: "1C2833", // dark body text
muted: "5D6D7E", // secondary text
yellow: "F1C40F",
green: "27AE60",
lightred:"F8D7DA",
};
function addSlideHeader(slide, title, subtitle) {
// Dark navy top bar
slide.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 0.85, fill: { color: C.navy } });
slide.addText(title, {
x: 0.35, y: 0, w: 9.3, h: 0.85,
fontSize: 22, bold: true, color: C.white, valign: "middle", margin: 0
});
if (subtitle) {
slide.addText(subtitle, {
x: 0.35, y: 0.85, w: 9.3, h: 0.38,
fontSize: 11, color: C.teal, italic: true, valign: "middle", margin: 0
});
}
// Thin accent line
slide.addShape(pres.ShapeType.rect, { x: 0, y: 0.85, w: 10, h: 0.045, fill: { color: C.teal } });
}
function addFooter(slide, pageNum) {
slide.addShape(pres.ShapeType.rect, { x: 0, y: 5.32, w: 10, h: 0.305, fill: { color: C.navy } });
slide.addText("Priapism — A Comprehensive Overview", {
x: 0.3, y: 5.32, w: 7, h: 0.305,
fontSize: 8, color: C.muted, valign: "middle", margin: 0
});
slide.addText(`${pageNum} / 10`, {
x: 8.8, y: 5.32, w: 0.9, h: 0.305,
fontSize: 8, color: C.white, bold: true, valign: "middle", align: "right", margin: 0
});
}
// ═══════════════════════════════════════════════
// SLIDE 1 — TITLE SLIDE
// ═══════════════════════════════════════════════
{
const s = pres.addSlide();
s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 5.625, fill: { color: C.navy } });
// diagonal accent stripe
s.addShape(pres.ShapeType.rect, { x: 0, y: 3.4, w: 10, h: 0.12, fill: { color: C.teal } });
s.addShape(pres.ShapeType.rect, { x: 0, y: 3.56, w: 10, h: 0.06, fill: { color: C.orange } });
// Stethoscope icon (Unicode medical symbol drawn with text)
s.addText("⚕", { x: 0.3, y: 0.3, w: 1.2, h: 1.2, fontSize: 60, color: C.teal });
s.addText("PRIAPISM", {
x: 1.3, y: 0.5, w: 8.4, h: 1.1,
fontSize: 52, bold: true, color: C.white, charSpacing: 8, margin: 0
});
s.addText("A Comprehensive Clinical Overview", {
x: 1.3, y: 1.55, w: 8.4, h: 0.5,
fontSize: 18, color: C.teal, italic: true, margin: 0
});
// Topics list
const topics = [
"Definition & Overview", "Etiology", "Pathogenesis",
"Classification", "Clinical Manifestations", "Diagnosis",
"Differential Diagnosis", "Treatment", "Complications & Prognosis", "Summary"
];
const leftTopics = topics.slice(0, 5);
const rightTopics = topics.slice(5);
s.addText(leftTopics.map((t, i) => ({ text: `${i+1}. ${t}`, options: { breakLine: i < leftTopics.length - 1 } })), {
x: 0.5, y: 3.8, w: 4.5, h: 1.5,
fontSize: 11, color: "AECFD8", lineSpacingMultiple: 1.3, margin: 0
});
s.addText(rightTopics.map((t, i) => ({ text: `${i+6}. ${t}`, options: { breakLine: i < rightTopics.length - 1 } })), {
x: 5.2, y: 3.8, w: 4.5, h: 1.5,
fontSize: 11, color: "AECFD8", lineSpacingMultiple: 1.3, margin: 0
});
}
// ═══════════════════════════════════════════════
// SLIDE 2 — DEFINITION & OVERVIEW
// ═══════════════════════════════════════════════
{
const s = pres.addSlide();
s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 5.625, fill: { color: C.light } });
addSlideHeader(s, "Definition & Overview", "Slide 1 of 9 — Foundation");
// Definition box
s.addShape(pres.ShapeType.rect, { x: 0.35, y: 1.15, w: 9.3, h: 1.05, fill: { color: C.navy }, line: { color: C.teal, width: 2 } });
s.addText([
{ text: "DEFINITION: ", options: { bold: true, color: C.yellow } },
{ text: "A prolonged, persistent penile erection unrelated to sexual interest or stimulation, lasting ", options: { color: C.white } },
{ text: "> 4 hours", options: { bold: true, color: C.orange } },
{ text: ", constituting a urologic emergency.", options: { color: C.white } }
], { x: 0.35, y: 1.15, w: 9.3, h: 1.05, fontSize: 13, valign: "middle", margin: [0, 10, 0, 10] });
// Two columns of key facts
const col1 = [
["One of the most common", "urologic emergencies"],
["Involves only the", "corpora cavernosa"],
["Corpus spongiosum &", "glans spared (in ischemic type)"],
];
const col2 = [
["Incidence:", "≈ 1.5–5.34 per 100,000 men/year"],
["Peak age:", "5–10 yrs (SCD) & 20–50 yrs (adult)"],
["Idiopathic:", "~60% of adult cases"],
];
col1.forEach(([label, value], i) => {
const y = 2.4 + i * 0.85;
s.addShape(pres.ShapeType.rect, { x: 0.35, y, w: 4.3, h: 0.7, fill: { color: C.teal }, rounding: "0.05" });
s.addText([
{ text: label + " ", options: { color: C.white, fontSize: 11 } },
{ text: value, options: { bold: true, color: C.yellow, fontSize: 11 } }
], { x: 0.5, y, w: 4.1, h: 0.7, valign: "middle", margin: 0 });
});
col2.forEach(([label, value], i) => {
const y = 2.4 + i * 0.85;
s.addShape(pres.ShapeType.rect, { x: 5.1, y, w: 4.55, h: 0.7, fill: { color: C.navy }, rounding: "0.05" });
s.addText([
{ text: label + " ", options: { color: C.teal, bold: true, fontSize: 11 } },
{ text: value, options: { color: C.white, fontSize: 11 } }
], { x: 5.2, y, w: 4.3, h: 0.7, valign: "middle", margin: 0 });
});
addFooter(s, 2);
}
// ═══════════════════════════════════════════════
// SLIDE 3 — ETIOLOGY
// ═══════════════════════════════════════════════
{
const s = pres.addSlide();
s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 5.625, fill: { color: C.light } });
addSlideHeader(s, "Etiology", "Slide 2 of 9 — Causes & Risk Factors");
// 3-column etiology layout
const cols = [
{
title: "Hematologic",
color: C.red,
items: ["Sickle cell disease (most common)", "Leukemia / lymphoma", "Thalassemia", "Polycythemia vera", "G6PD deficiency", "Hypercoagulable states"]
},
{
title: "Pharmacologic",
color: C.teal,
items: ["Intracavernous injections\n(PGE1, papaverine)", "Antipsychotics (chlorpromazine,\nclozapine, olanzapine)", "Antidepressants (trazodone)", "Antihypertensives (hydralazine,\nprazosin)", "Anticoagulants (heparin)", "PDE5 inhibitors (overdose)"]
},
{
title: "Other Causes",
color: C.orange,
items: ["Perineal / penile trauma\n(non-ischemic type)", "Spinal cord injury", "Pelvic tumors / metastases", "Local infections / abscess", "Fabry disease", "Idiopathic (~60% cases)"]
}
];
cols.forEach((col, ci) => {
const x = 0.3 + ci * 3.25;
s.addShape(pres.ShapeType.rect, { x, y: 1.05, w: 3.1, h: 0.45, fill: { color: col.color } });
s.addText(col.title, {
x: x + 0.05, y: 1.05, w: 3.0, h: 0.45,
fontSize: 13, bold: true, color: C.white, valign: "middle", align: "center", margin: 0
});
s.addShape(pres.ShapeType.rect, { x, y: 1.5, w: 3.1, h: 3.75, fill: { color: C.white }, line: { color: col.color, width: 1.5 } });
s.addText(col.items.map((item, i) => ({
text: "• " + item,
options: { breakLine: i < col.items.length - 1 }
})), {
x: x + 0.1, y: 1.55, w: 2.9, h: 3.65,
fontSize: 10.5, color: C.text, lineSpacingMultiple: 1.5, valign: "top", margin: [4, 0, 0, 0]
});
});
// Small note
s.addText("★ Intracavernous injections for erectile dysfunction are currently the most common iatrogenic cause", {
x: 0.3, y: 5.1, w: 9.4, h: 0.22,
fontSize: 8.5, color: C.red, italic: true, margin: 0
});
addFooter(s, 3);
}
// ═══════════════════════════════════════════════
// SLIDE 4 — PATHOGENESIS
// ═══════════════════════════════════════════════
{
const s = pres.addSlide();
s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 5.625, fill: { color: C.light } });
addSlideHeader(s, "Pathogenesis", "Slide 3 of 9 — Mechanism of Injury");
// Ischemic pathway diagram
s.addShape(pres.ShapeType.rect, { x: 0.3, y: 1.05, w: 9.4, h: 0.3, fill: { color: C.navy } });
s.addText("ISCHEMIC (Low-Flow) PATHWAY", {
x: 0.3, y: 1.05, w: 9.4, h: 0.3,
fontSize: 11, bold: true, color: C.yellow, align: "center", valign: "middle", margin: 0
});
// Flow diagram boxes
const steps = [
{ label: "Venous\nOutflow\nObstruction", color: C.red },
{ label: "↓ Arterial\nInflow\nContinues", color: C.orange },
{ label: "Blood\nStasis &\nSludging", color: C.teal },
{ label: "Hypoxia\nHypercapnia\nAcidosis", color: "8E44AD" },
{ label: "Smooth Muscle\nNecrosis &\nFibrosis", color: C.red }
];
steps.forEach((st, i) => {
const x = 0.4 + i * 1.85;
s.addShape(pres.ShapeType.rect, { x, y: 1.45, w: 1.65, h: 1.0, fill: { color: st.color }, rounding: "0.05" });
s.addText(st.label, { x, y: 1.45, w: 1.65, h: 1.0, fontSize: 9.5, bold: true, color: C.white, align: "center", valign: "middle", margin: 0 });
if (i < steps.length - 1) {
s.addText("→", { x: x + 1.65, y: 1.75, w: 0.2, h: 0.4, fontSize: 16, color: C.navy, align: "center", margin: 0 });
}
});
// Molecular mechanism
s.addShape(pres.ShapeType.rect, { x: 0.3, y: 2.6, w: 9.4, h: 0.3, fill: { color: C.teal } });
s.addText("MOLECULAR / cGMP-NO DYSREGULATION (Stuttering Priapism)", {
x: 0.3, y: 2.6, w: 9.4, h: 0.3,
fontSize: 10.5, bold: true, color: C.white, align: "center", valign: "middle", margin: 0
});
const molSteps = [
{ label: "↓ PDE5\nActivity", color: C.navy },
{ label: "↑ cGMP\nAccumulation", color: C.teal },
{ label: "↑ Nitric\nOxide (NO)", color: C.green },
{ label: "Persistent\nSmooth Muscle\nRelaxation", color: C.orange },
{ label: "Recurrent\nErection\nEpisodes", color: C.red }
];
molSteps.forEach((st, i) => {
const x = 0.4 + i * 1.85;
s.addShape(pres.ShapeType.rect, { x, y: 3.0, w: 1.65, h: 1.0, fill: { color: st.color }, rounding: "0.05" });
s.addText(st.label, { x, y: 3.0, w: 1.65, h: 1.0, fontSize: 9.5, bold: true, color: C.white, align: "center", valign: "middle", margin: 0 });
if (i < molSteps.length - 1) {
s.addText("→", { x: x + 1.65, y: 3.3, w: 0.2, h: 0.4, fontSize: 16, color: C.navy, align: "center", margin: 0 });
}
});
s.addText("Non-ischemic: Trauma → cavernosal artery fistula → unregulated arterial inflow → sustained painless tumescence (no ischemia as venous drainage preserved)", {
x: 0.3, y: 4.15, w: 9.4, h: 0.5,
fontSize: 10, color: C.text, italic: true,
fill: { color: C.white }, line: { color: C.teal, width: 1 },
valign: "middle", margin: [4, 8, 4, 8]
});
addFooter(s, 4);
}
// ═══════════════════════════════════════════════
// SLIDE 5 — CLASSIFICATION
// ═══════════════════════════════════════════════
{
const s = pres.addSlide();
s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 5.625, fill: { color: C.light } });
addSlideHeader(s, "Classification", "Slide 4 of 9 — Three Distinct Types");
const types = [
{
name: "ISCHEMIC\n(Low-Flow / Veno-Occlusive)",
color: C.red,
icon: "🔴",
features: ["Most common (>95%)", "Venous outflow obstruction", "No/minimal arterial inflow", "Painful, rigid erection", "Hypoxic, hypercapnic, acidotic blood", "Medical EMERGENCY ⚠️"]
},
{
name: "NON-ISCHEMIC\n(High-Flow / Arterial)",
color: C.teal,
icon: "🔵",
features: ["Less common (~5%)", "Post-traumatic cavernous artery fistula", "Unregulated arterial inflow", "Painless, partial tumescence", "Well-oxygenated blood gas", "NOT an emergency"]
},
{
name: "STUTTERING\n(Recurrent / Intermittent)",
color: C.orange,
icon: "🟠",
features: ["Recurrent ischemic episodes", "Often in SCD patients", "Short episodes with detumescence", "Progressive worsening over time", "PDE5/NO dysregulation", "Risk of permanent ED"]
}
];
types.forEach((t, i) => {
const x = 0.25 + i * 3.25;
s.addShape(pres.ShapeType.rect, { x, y: 1.05, w: 3.1, h: 4.2, fill: { color: C.white }, line: { color: t.color, width: 2 } });
s.addShape(pres.ShapeType.rect, { x, y: 1.05, w: 3.1, h: 0.9, fill: { color: t.color } });
s.addText(t.name, {
x: x + 0.05, y: 1.05, w: 3.0, h: 0.9,
fontSize: 10.5, bold: true, color: C.white, align: "center", valign: "middle", margin: 0
});
// Mini comparison bar
t.features.forEach((feat, fi) => {
const fy = 2.05 + fi * 0.52;
s.addShape(pres.ShapeType.rect, { x: x + 0.05, y: fy, w: 3.0, h: 0.44,
fill: { color: fi % 2 === 0 ? C.light : C.white } });
s.addText(feat, {
x: x + 0.12, y: fy, w: 2.86, h: 0.44,
fontSize: 10, color: C.text, valign: "middle", margin: 0
});
});
});
addFooter(s, 5);
}
// ═══════════════════════════════════════════════
// SLIDE 6 — CLINICAL MANIFESTATIONS
// ═══════════════════════════════════════════════
{
const s = pres.addSlide();
s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 5.625, fill: { color: C.light } });
addSlideHeader(s, "Clinical Manifestations", "Slide 5 of 9 — Signs & Symptoms");
// Split into two panels: Ischemic vs Non-ischemic
s.addShape(pres.ShapeType.rect, { x: 0.25, y: 1.1, w: 4.55, h: 4.2, fill: { color: C.white }, line: { color: C.red, width: 2 } });
s.addShape(pres.ShapeType.rect, { x: 0.25, y: 1.1, w: 4.55, h: 0.4, fill: { color: C.red } });
s.addText("🔴 ISCHEMIC PRIAPISM", {
x: 0.3, y: 1.1, w: 4.45, h: 0.4,
fontSize: 12, bold: true, color: C.white, valign: "middle", margin: 0
});
const ischemicManif = [
["Onset", "Sudden; may follow sexual activity, SCD crisis, or drug use"],
["Pain", "Progressively severe; dull ache → acute pain"],
["Erection", "Fully rigid corpora cavernosa; glans & spongiosum SOFT"],
["Duration", "> 4 hours (emergency threshold)"],
["Colour", "Dusky / cyanotic penis as ischemia progresses"],
["Systemic", "Fever, tachycardia if prolonged (ischemic necrosis)"],
];
ischemicManif.forEach(([key, val], i) => {
const y = 1.6 + i * 0.55;
s.addShape(pres.ShapeType.rect, { x: 0.3, y, w: 1.3, h: 0.48, fill: { color: C.red } });
s.addText(key, { x: 0.3, y, w: 1.3, h: 0.48, fontSize: 9, bold: true, color: C.white, align: "center", valign: "middle", margin: 0 });
s.addText(val, { x: 1.65, y, w: 3.0, h: 0.48, fontSize: 9.5, color: C.text, valign: "middle", margin: 0 });
});
// Non-ischemic panel
s.addShape(pres.ShapeType.rect, { x: 5.2, y: 1.1, w: 4.55, h: 4.2, fill: { color: C.white }, line: { color: C.teal, width: 2 } });
s.addShape(pres.ShapeType.rect, { x: 5.2, y: 1.1, w: 4.55, h: 0.4, fill: { color: C.teal } });
s.addText("🔵 NON-ISCHEMIC PRIAPISM", {
x: 5.25, y: 1.1, w: 4.45, h: 0.4,
fontSize: 12, bold: true, color: C.white, valign: "middle", margin: 0
});
const nonIschemicManif = [
["Onset", "Delayed (days-weeks) after perineal trauma"],
["Pain", "Absent or minimal — key distinguishing feature"],
["Erection", "Partial/incomplete; less rigid than ischemic"],
["History", "Straddle injury, blunt perineal trauma"],
["Glans", "May be involved (partial)"],
["Course", "Non-progressive; does not cause ischemia"],
];
nonIschemicManif.forEach(([key, val], i) => {
const y = 1.6 + i * 0.55;
s.addShape(pres.ShapeType.rect, { x: 5.25, y, w: 1.3, h: 0.48, fill: { color: C.teal } });
s.addText(key, { x: 5.25, y, w: 1.3, h: 0.48, fontSize: 9, bold: true, color: C.white, align: "center", valign: "middle", margin: 0 });
s.addText(val, { x: 6.6, y, w: 3.0, h: 0.48, fontSize: 9.5, color: C.text, valign: "middle", margin: 0 });
});
addFooter(s, 6);
}
// ═══════════════════════════════════════════════
// SLIDE 7 — DIAGNOSIS
// ═══════════════════════════════════════════════
{
const s = pres.addSlide();
s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 5.625, fill: { color: C.light } });
addSlideHeader(s, "Diagnosis", "Slide 6 of 9 — Evaluation Algorithm");
// Step-by-step diagnostic algorithm
const steps = [
{ n: "1", title: "History", detail: "Duration, pain, medications (PDE5i, antipsychotics, intracavernosal injection), trauma, SCD history, prior episodes", color: C.navy },
{ n: "2", title: "Physical Exam", detail: "Assess rigidity (full=ischemic, partial=non-ischemic), glans/spongiosum involvement, tenderness, perineal bruising", color: C.teal },
{ n: "3", title: "Cavernous Blood Gas", detail: "pH<7.25, pO₂<30mmHg, pCO₂>60mmHg → Ischemic\nNormal arterial blood gas (pO₂>90) → Non-ischemic", color: C.red },
{ n: "4", title: "Penile Doppler USG", detail: "Absent/minimal flow → Ischemic priapism\nHigh-velocity turbulent flow or fistula → Non-ischemic\nFirst-line imaging for type differentiation", color: C.orange },
{ n: "5", title: "Lab Investigations", detail: "CBC (sickle cell, leukemia), reticulocyte count, coagulation profile, urine toxicology, PSA if malignancy suspected", color: "8E44AD" },
];
steps.forEach((st, i) => {
const y = 1.1 + i * 0.85;
// Number bubble
s.addShape(pres.ShapeType.ellipse, { x: 0.25, y: y + 0.05, w: 0.6, h: 0.6, fill: { color: st.color } });
s.addText(st.n, { x: 0.25, y: y + 0.05, w: 0.6, h: 0.6, fontSize: 14, bold: true, color: C.white, align: "center", valign: "middle", margin: 0 });
// Title
s.addShape(pres.ShapeType.rect, { x: 0.95, y, w: 2.2, h: 0.7, fill: { color: st.color } });
s.addText(st.title, { x: 0.95, y, w: 2.2, h: 0.7, fontSize: 11.5, bold: true, color: C.white, align: "center", valign: "middle", margin: 0 });
// Detail
s.addShape(pres.ShapeType.rect, { x: 3.25, y, w: 6.5, h: 0.7, fill: { color: C.white }, line: { color: st.color, width: 1 } });
s.addText(st.detail, { x: 3.35, y: y + 0.02, w: 6.3, h: 0.66, fontSize: 10, color: C.text, valign: "middle", margin: 0 });
});
// Blood gas mini-table legend at bottom
s.addText("Blood Gas Interpretation: Ischemic → pH<7.25 | pO₂<30 mmHg | pCO₂>60 mmHg | Non-Ischemic → Normal arterial gas values", {
x: 0.25, y: 5.12, w: 9.5, h: 0.25,
fontSize: 8.5, color: C.navy, bold: true, italic: true, margin: 0
});
addFooter(s, 7);
}
// ═══════════════════════════════════════════════
// SLIDE 8 — DIFFERENTIAL DIAGNOSIS
// ═══════════════════════════════════════════════
{
const s = pres.addSlide();
s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 5.625, fill: { color: C.light } });
addSlideHeader(s, "Differential Diagnosis", "Slide 7 of 9 — Key Distinctions");
// Table header
const tableH = 1.15;
const colW = [2.8, 2.2, 2.2, 2.55];
const headers = ["Condition", "Similarity to Priapism", "Key Difference", "Differentiating Test"];
headers.forEach((h, ci) => {
const x = 0.25 + colW.slice(0, ci).reduce((a, b) => a + b, 0);
s.addShape(pres.ShapeType.rect, { x, y: tableH, w: colW[ci], h: 0.42, fill: { color: C.navy } });
s.addText(h, { x: x + 0.05, y: tableH, w: colW[ci] - 0.1, h: 0.42, fontSize: 10.5, bold: true, color: C.white, valign: "middle", align: "center", margin: 0 });
});
const rows = [
["Peyronie's Disease", "Penile deformity, erection issue", "Plaque; curved not prolonged erection; not emergency", "US/palpation for plaque"],
["Penile Fracture", "Penile trauma, sudden event", "Audible 'pop', rapid detumescence, haematoma", "Clinical exam, USS"],
["Phimosis / Paraphimosis", "Penile pain & swelling", "Involves foreskin/glans, not corporal rigidity", "Physical examination"],
["Penile Carcinoma", "Penile mass, possible erection", "Ulcerative/fungating lesion; systemic malignancy signs", "Biopsy, PET/CT"],
["Drug-Induced Normal Erection", "Prolonged erection after PDE5i", "Usually responds to stimulation; <4 hrs; not rigid/painful", "Duration, blood gas"],
["Megapenis (congenital)", "Large phallus", "Not prolonged; no ischemia; congenital anomaly", "Age, history, blood gas"],
];
rows.forEach((row, ri) => {
const y = 1.57 + ri * 0.62;
const bg = ri % 2 === 0 ? C.white : C.light;
row.forEach((cell, ci) => {
const x = 0.25 + colW.slice(0, ci).reduce((a, b) => a + b, 0);
s.addShape(pres.ShapeType.rect, { x, y, w: colW[ci], h: 0.58, fill: { color: bg }, line: { color: "CCCCCC", width: 0.5 } });
s.addText(cell, { x: x + 0.07, y, w: colW[ci] - 0.14, h: 0.58, fontSize: 9.5, color: C.text, valign: "middle", margin: 0 });
});
});
addFooter(s, 8);
}
// ═══════════════════════════════════════════════
// SLIDE 9 — TREATMENT
// ═══════════════════════════════════════════════
{
const s = pres.addSlide();
s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 5.625, fill: { color: C.light } });
addSlideHeader(s, "Treatment", "Slide 8 of 9 — Evidence-Based Management");
// Three treatment pathways
const panels = [
{
title: "ISCHEMIC PRIAPISM", color: C.red, x: 0.2,
steps: [
"1st Line: Corporal aspiration (21G butterfly needle) → 20-30 mL blood",
"2nd Line: Intracavernosal α-agonist\n• Phenylephrine 100-200 mcg q3-5 min (preferred)\n• Epinephrine / Norepinephrine",
"3rd Line: Surgical shunt\n• Distal: Winter (glans-cavernosum), Ebbehoj\n• Proximal: Quackels (cavernosum-spongiosum)\n• Saphenous vein-cavernosum (if distal fails)",
"SCD-specific: O₂, IV fluids, analgesia, exchange transfusion, hydroxyurea (prevention)"
]
},
{
title: "NON-ISCHEMIC", color: C.teal, x: 4.95,
steps: [
"Conservative (observation) — safe initially as no ischemia",
"Selective arterial embolization — gold standard\n• Autologous clot or absorbable gelatin sponge\n• High success, preserves erectile function",
"Surgical ligation of fistula if embolization fails",
"Anti-androgen therapy (limited evidence) as adjunct"
]
}
];
panels.forEach((p) => {
s.addShape(pres.ShapeType.rect, { x: p.x, y: 1.05, w: 4.6, h: 4.25, fill: { color: C.white }, line: { color: p.color, width: 2 } });
s.addShape(pres.ShapeType.rect, { x: p.x, y: 1.05, w: 4.6, h: 0.4, fill: { color: p.color } });
s.addText(p.title, {
x: p.x + 0.05, y: 1.05, w: 4.5, h: 0.4,
fontSize: 12, bold: true, color: C.white, align: "center", valign: "middle", margin: 0
});
p.steps.forEach((step, si) => {
const sy = 1.55 + si * 0.95;
s.addShape(pres.ShapeType.rect, { x: p.x + 0.08, y: sy, w: 4.44, h: 0.85,
fill: { color: si % 2 === 0 ? C.light : C.white }, line: { color: p.color, width: 0.5 } });
s.addText(step, {
x: p.x + 0.14, y: sy + 0.02, w: 4.32, h: 0.81,
fontSize: 9.5, color: C.text, valign: "middle", margin: 0
});
});
});
// Stuttering treatment mini-banner
s.addShape(pres.ShapeType.rect, { x: 0.2, y: 5.1, w: 9.6, h: 0.27, fill: { color: C.orange } });
s.addText("STUTTERING: Oral PDE5 inhibitors (daily low-dose sildenafil) • GnRH agonists • Hydroxyurea for SCD • Pseudoephedrine at bedtime • Ketoconazole", {
x: 0.3, y: 5.1, w: 9.4, h: 0.27,
fontSize: 8.5, bold: true, color: C.white, valign: "middle", margin: 0
});
addFooter(s, 9);
}
// ═══════════════════════════════════════════════
// SLIDE 10 — COMPLICATIONS, PROGNOSIS & SUMMARY
// ═══════════════════════════════════════════════
{
const s = pres.addSlide();
s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 5.625, fill: { color: C.light } });
addSlideHeader(s, "Complications, Prognosis & Summary", "Slide 9 of 9 — Outcomes & Key Takeaways");
// Complications
s.addShape(pres.ShapeType.rect, { x: 0.25, y: 1.1, w: 4.5, h: 0.35, fill: { color: C.red } });
s.addText("⚠ COMPLICATIONS", { x: 0.25, y: 1.1, w: 4.5, h: 0.35, fontSize: 12, bold: true, color: C.white, valign: "middle", align: "center", margin: 0 });
const comps = [
"Erectile Dysfunction (most feared — up to 90% if >72 hrs untreated)",
"Cavernosal fibrosis → penile shortening",
"Penile gangrene (rare, extreme delay)",
"Penile pain syndrome / psychological distress",
"Recurrent priapism (stuttering progression)",
];
comps.forEach((c, i) => {
const y = 1.5 + i * 0.5;
s.addShape(pres.ShapeType.rect, { x: 0.25, y, w: 4.5, h: 0.45, fill: { color: i % 2 === 0 ? C.white : C.light }, line: { color: C.red, width: 0.5 } });
s.addText("• " + c, { x: 0.35, y, w: 4.3, h: 0.45, fontSize: 9.5, color: C.text, valign: "middle", margin: 0 });
});
// Prognosis based on duration
s.addShape(pres.ShapeType.rect, { x: 5.0, y: 1.1, w: 4.75, h: 0.35, fill: { color: C.navy } });
s.addText("⏱ PROGNOSIS BY DURATION", { x: 5.0, y: 1.1, w: 4.75, h: 0.35, fontSize: 12, bold: true, color: C.white, valign: "middle", align: "center", margin: 0 });
const prog = [
{ time: "< 24 hrs", outcome: "~95% erectile function preserved", color: C.green },
{ time: "24–48 hrs", outcome: "~50% erectile function preserved", color: C.orange },
{ time: "48–72 hrs", outcome: "~10–15% erectile function preserved", color: C.red },
{ time: "> 72 hrs", outcome: "~0–10%; penile fibrosis likely", color: "8B0000" },
];
prog.forEach((p, i) => {
const y = 1.5 + i * 0.55;
s.addShape(pres.ShapeType.rect, { x: 5.0, y, w: 1.5, h: 0.48, fill: { color: p.color } });
s.addText(p.time, { x: 5.0, y, w: 1.5, h: 0.48, fontSize: 10, bold: true, color: C.white, align: "center", valign: "middle", margin: 0 });
s.addShape(pres.ShapeType.rect, { x: 6.55, y, w: 3.2, h: 0.48, fill: { color: C.white }, line: { color: p.color, width: 1 } });
s.addText(p.outcome, { x: 6.65, y, w: 3.0, h: 0.48, fontSize: 9.5, color: C.text, valign: "middle", margin: 0 });
});
// Summary take-aways
s.addShape(pres.ShapeType.rect, { x: 0.25, y: 4.05, w: 9.5, h: 0.25, fill: { color: C.teal } });
s.addText("KEY TAKEAWAYS", { x: 0.25, y: 4.05, w: 9.5, h: 0.25, fontSize: 10, bold: true, color: C.white, align: "center", valign: "middle", margin: 0 });
const takeaways = [
"Ischemic priapism > 4 hrs = urologic emergency; early aspiration + phenylephrine is life-saving for erectile function",
"Blood gas from cavernosum is the GOLD STANDARD to differentiate ischemic (hypoxic/acidotic) from non-ischemic (normal)",
"Non-ischemic = NOT an emergency; selective embolization is treatment of choice; conservative management acceptable initially",
"Stuttering priapism in SCD: daily PDE5i + hydroxyurea to prevent recurrence and long-term damage",
];
takeaways.forEach((t, i) => {
const y = 4.35 + i * 0.29;
s.addText([
{ text: `${i + 1}. `, options: { bold: true, color: C.orange } },
{ text: t, options: { color: C.text } }
], { x: 0.3, y, w: 9.4, h: 0.27, fontSize: 9.5, valign: "middle", margin: 0 });
});
addFooter(s, 10);
}
// ═══════════════════════════════════════════════
// Write file
// ═══════════════════════════════════════════════
pres.writeFile({ fileName: "/home/daytona/workspace/priapism-ppt/Priapism_Comprehensive.pptx" })
.then(() => console.log("SUCCESS: Priapism_Comprehensive.pptx created"))
.catch(err => { console.error("ERROR:", err); process.exit(1); });
cd /home/daytona/workspace/priapism-ppt && node priapism.js 2>&1
ls -lh /home/daytona/workspace/priapism-ppt/Priapism_Comprehensive.pptx
Priapism Comprehensive
Presentation · PPTX
| Slide | Content |
|---|---|
| 1 | Title Slide - with full topic list embedded |
| 2 | Definition & Overview - key stats, epidemiology, fact boxes |
| 3 | Etiology - 3-column layout: Hematologic / Pharmacologic / Other causes |
| 4 | Pathogenesis - Two flow diagrams: ischemic cascade + NO/cGMP molecular pathway |
| 5 | Classification - Side-by-side cards: Ischemic vs Non-ischemic vs Stuttering with features |
| 6 | Clinical Manifestations - Comparative panel (Ischemic vs Non-ischemic) with color-coded rows |
| 7 | Diagnosis - 5-step numbered algorithm (History → Exam → Blood Gas → Doppler → Labs) with blood gas values |
| 8 | Differential Diagnosis - Full comparison table (Peyronie's, fracture, paraphimosis, carcinoma, etc.) |
| 9 | Treatment - Dual-panel: Ischemic (aspiration → phenylephrine → shunting) + Non-ischemic (embolization), with stuttering banner |
| 10 | Complications, Prognosis & Summary - Duration-based prognosis chart + 4 key takeaways |