Acute compartment syndrome make a ppt presentation
mkdir -p /home/daytona/workspace/acs-ppt && ls /home/daytona/workspace/acs-ppt/
~/acs-ppt/create_acs_ppt.js
const pptxgen = require("pptxgenjs");
const pres = new pptxgen();
pres.layout = "LAYOUT_16x9";
pres.title = "Acute Compartment Syndrome";
pres.author = "Medical Education";
// ─── COLOUR PALETTE ───────────────────────────────────────────────
const C = {
darkBg: "0D1B2A", // deep navy – title / section slides
midBg: "1B2A3B", // darker navy
accent: "E63946", // vivid red (danger / urgency)
accentAmb: "F4A261", // amber – warning
accentGrn: "2A9D8F", // teal-green – treatment
white: "FFFFFF",
lightGray: "D1D5DB",
textDark: "1F2937",
cardBg: "F0F4F8",
divider: "E63946",
slideNum: "A8B2BE",
};
// ─── HELPER: slide number footer ──────────────────────────────────
function addFooter(slide, num, total) {
slide.addText(`${num} / ${total}`, {
x: 9.2, y: 5.3, w: 0.6, h: 0.25,
fontSize: 9, color: C.slideNum, align: "right",
});
}
// ─── HELPER: section-label pill ───────────────────────────────────
function addPill(slide, label, color) {
slide.addShape(pres.ShapeType.roundRect, {
x: 0.35, y: 0.22, w: 1.7, h: 0.28,
fill: { color: color || C.accent }, line: { color: color || C.accent },
rectRadius: 0.05,
});
slide.addText(label, {
x: 0.35, y: 0.22, w: 1.7, h: 0.28,
fontSize: 8.5, bold: true, color: C.white, align: "center", valign: "middle",
margin: 0,
});
}
// ─── HELPER: content slide skeleton ───────────────────────────────
function contentSlide(title, pillLabel, pillColor) {
const slide = pres.addSlide();
// left red accent bar
slide.addShape(pres.ShapeType.rect, {
x: 0, y: 0, w: 0.12, h: 5.625,
fill: { color: C.accent }, line: { color: C.accent },
});
// heading underline strip
slide.addShape(pres.ShapeType.rect, {
x: 0.25, y: 0.65, w: 9.5, h: 0.04,
fill: { color: C.accent }, line: { color: C.accent },
});
if (pillLabel) addPill(slide, pillLabel, pillColor);
slide.addText(title, {
x: 0.25, y: 0.1, w: 9.5, h: 0.55,
fontSize: 20, bold: true, color: C.textDark, valign: "middle",
fontFace: "Calibri",
});
return slide;
}
// ─── HELPER: card ─────────────────────────────────────────────────
function addCard(slide, x, y, w, h, headerText, headerColor, bodyLines) {
// header
slide.addShape(pres.ShapeType.rect, {
x, y, w, h: 0.35,
fill: { color: headerColor }, line: { color: headerColor },
});
slide.addText(headerText, {
x: x + 0.08, y, w: w - 0.1, h: 0.35,
fontSize: 11, bold: true, color: C.white, valign: "middle", margin: 0,
});
// body
slide.addShape(pres.ShapeType.rect, {
x, y: y + 0.35, w, h: h - 0.35,
fill: { color: C.cardBg }, line: { color: "CBD5E1", size: 1 },
});
const items = bodyLines.map((t, i) => ({
text: t,
options: { bullet: { type: "bullet" }, breakLine: i < bodyLines.length - 1, fontSize: 10.5, color: C.textDark },
}));
slide.addText(items, {
x: x + 0.12, y: y + 0.42, w: w - 0.2, h: h - 0.55,
valign: "top", fontFace: "Calibri",
});
}
const TOTAL = 14;
// ══════════════════════════════════════════════════════════════════
// SLIDE 1 – TITLE SLIDE
// ══════════════════════════════════════════════════════════════════
{
const s = pres.addSlide();
s.background = { color: C.darkBg };
// diagonal red accent shape
s.addShape(pres.ShapeType.rect, {
x: 0, y: 3.8, w: 10, h: 1.825,
fill: { color: C.accent }, line: { color: C.accent },
});
// thin amber stripe
s.addShape(pres.ShapeType.rect, {
x: 0, y: 3.72, w: 10, h: 0.08,
fill: { color: C.accentAmb }, line: { color: C.accentAmb },
});
s.addText("ACUTE COMPARTMENT SYNDROME", {
x: 0.5, y: 0.6, w: 9, h: 1.2,
fontSize: 38, bold: true, color: C.white, align: "center",
fontFace: "Calibri", charSpacing: 2,
});
s.addText("A Surgical Emergency", {
x: 0.5, y: 1.9, w: 9, h: 0.6,
fontSize: 22, color: C.accentAmb, align: "center", italic: true, fontFace: "Calibri",
});
s.addText("Diagnosis · Pathophysiology · Management", {
x: 0.5, y: 2.6, w: 9, h: 0.5,
fontSize: 14, color: C.lightGray, align: "center", fontFace: "Calibri",
});
s.addText("Sources: Bailey & Love's Surgery 28e | Current Surgical Therapy 14e | Rosen's Emergency Medicine", {
x: 0.5, y: 4.0, w: 9, h: 0.5,
fontSize: 9, color: C.white, align: "center", fontFace: "Calibri",
});
addFooter(s, 1, TOTAL);
}
// ══════════════════════════════════════════════════════════════════
// SLIDE 2 – DEFINITION & OVERVIEW
// ══════════════════════════════════════════════════════════════════
{
const s = contentSlide("Definition & Overview", "OVERVIEW", C.textDark);
s.addText([
{ text: "Compartment syndrome", options: { bold: true, color: C.accent } },
{ text: " is raised pressure within a ", options: {} },
{ text: "closed fascial compartment", options: { bold: true } },
{ text: " that compromises tissue perfusion, leading to ischaemia and irreversible muscle damage.", options: {} },
], {
x: 0.25, y: 0.8, w: 9.5, h: 0.8,
fontSize: 14, color: C.textDark, fontFace: "Calibri",
});
// 3 info boxes
const boxes = [
{ x: 0.25, col: C.accent, title: "Causes", lines: ["Fractures (70%)", "Soft-tissue contusion (23%)", "Tight casts / dressings", "Burns (circumferential)", "Reperfusion / post-ischaemic", "Bleeding disorders / anticoagulation", "IV extravasation under pressure"] },
{ x: 3.55, col: C.accentAmb, title: "Pathophysiology", lines: ["↑ Tissue pressure", "→ ↓ Microperfusion", "→ Tissue ischaemia", "→ Cellular anoxia", "→ Irreversible muscle necrosis", "Vicious cycle of oedema & pressure"] },
{ x: 6.85, col: C.accentGrn, title: "Key Concept", lines: ["A time-critical emergency", "Minutes to hours matter", "Can occur in OPEN fractures", "Equal incidence: high-energy vs low-energy injuries", "Requires urgent fasciotomy"] },
];
boxes.forEach(b => addCard(s, b.x, 1.75, 3.1, 3.5, b.title, b.col, b.lines));
addFooter(s, 2, TOTAL);
}
// ══════════════════════════════════════════════════════════════════
// SLIDE 3 – ANATOMY OF COMPARTMENTS
// ══════════════════════════════════════════════════════════════════
{
const s = contentSlide("Anatomy of Compartments", "ANATOMY", C.accentGrn);
// Leg compartments box
addCard(s, 0.25, 0.78, 4.5, 2.2, "Lower Leg (4 Compartments)", C.accentGrn, [
"Anterior – tibialis anterior, EHL, EDB, deep peroneal n.",
"Lateral – peroneus longus & brevis, superficial peroneal n.",
"Superficial posterior – gastrocnemius, soleus, sural n.",
"Deep posterior – FHL, FDL, tibialis posterior, posterior tibial n.",
]);
// Forearm compartments box
addCard(s, 0.25, 3.1, 4.5, 2.2, "Forearm (3 Compartments)", C.accent, [
"Volar superficial – wrist & finger flexors",
"Volar deep – FDP, FPL, pronator quadratus",
"Dorsal – wrist & finger extensors",
]);
// image from textbook
s.addImage({
path: "/home/daytona/workspace/acs-ppt/compartment_diagram.png",
x: 4.95, y: 0.78, w: 4.85, h: 4.6,
sizing: { type: "contain", w: 4.85, h: 4.6 },
});
addFooter(s, 3, TOTAL);
}
// ══════════════════════════════════════════════════════════════════
// SLIDE 4 – CLINICAL FEATURES
// ══════════════════════════════════════════════════════════════════
{
const s = contentSlide("Clinical Features — The 6 P's", "DIAGNOSIS", C.accent);
// 6-P grid
const Ps = [
{ label: "Pain", desc: "Out of proportion to injury\nEarliest & most reliable sign", col: C.accent },
{ label: "Pressure", desc: "Tensely swollen, woody-hard compartment", col: C.accent },
{ label: "Paraesthesia", desc: "Numbness / tingling in the distribution of nerves in that compartment", col: C.accentAmb },
{ label: "Pain on Passive\nStretch", desc: "Key clinical test — stretching the muscles ↑ pain dramatically", col: C.accentAmb },
{ label: "Paralysis", desc: "Motor weakness – LATE sign indicating nerve/muscle damage", col: "6B7280" },
{ label: "Pulselessness",desc: "EXTREMELY late sign – arterial occlusion not needed for ACS", col: "6B7280" },
];
const cols = [0.25, 3.4, 6.55];
const rows = [0.82, 2.8];
Ps.forEach((p, i) => {
const x = cols[i % 3];
const y = rows[Math.floor(i / 3)];
// card header
s.addShape(pres.ShapeType.roundRect, {
x, y, w: 2.9, h: 1.75,
fill: { color: i < 4 ? C.cardBg : "F9FAFB" },
line: { color: p.col, size: 2 }, rectRadius: 0.06,
});
s.addShape(pres.ShapeType.roundRect, {
x, y, w: 2.9, h: 0.4,
fill: { color: p.col }, line: { color: p.col }, rectRadius: 0.06,
});
s.addText(p.label, {
x: x + 0.08, y, w: 2.74, h: 0.4,
fontSize: 12, bold: true, color: C.white, valign: "middle", margin: 0,
});
s.addText(p.desc, {
x: x + 0.1, y: y + 0.45, w: 2.7, h: 1.25,
fontSize: 10.5, color: C.textDark, valign: "top", fontFace: "Calibri",
});
});
// early vs late callout
s.addText("Early signs: Pain, Pressure, Paraesthesia, Pain on stretch | Late signs: Paralysis, Pulselessness", {
x: 0.25, y: 5.1, w: 9.5, h: 0.32,
fontSize: 9.5, color: C.white, align: "center", bold: true,
fill: { color: C.accent },
});
addFooter(s, 4, TOTAL);
}
// ══════════════════════════════════════════════════════════════════
// SLIDE 5 – DIAGNOSIS
// ══════════════════════════════════════════════════════════════════
{
const s = contentSlide("Diagnosis", "DIAGNOSIS", C.accent);
// Clinical diagnosis box
s.addShape(pres.ShapeType.rect, {
x: 0.25, y: 0.78, w: 4.55, h: 2.0,
fill: { color: "FFF5F5" }, line: { color: C.accent, size: 2 },
});
s.addText("Clinical Diagnosis (Primary)", {
x: 0.35, y: 0.82, w: 4.3, h: 0.38,
fontSize: 12, bold: true, color: C.accent, fontFace: "Calibri",
});
s.addText([
{ text: "• Pain out of proportion to injury\n", options: { breakLine: false } },
{ text: "• Increasing pain over time\n", options: { breakLine: false } },
{ text: "• Pain on passive muscle stretch\n", options: { breakLine: false } },
{ text: "• Paraesthesia in the compartment\n", options: { breakLine: false } },
{ text: "• Tense, woody compartment on palpation", options: {} },
], {
x: 0.35, y: 1.28, w: 4.3, h: 1.4,
fontSize: 10.5, color: C.textDark, fontFace: "Calibri",
});
// Pressure measurement box
s.addShape(pres.ShapeType.rect, {
x: 0.25, y: 2.9, w: 4.55, h: 2.4,
fill: { color: "FFFBF0" }, line: { color: C.accentAmb, size: 2 },
});
s.addText("Compartment Pressure Monitoring", {
x: 0.35, y: 2.94, w: 4.3, h: 0.38,
fontSize: 12, bold: true, color: C.accentAmb, fontFace: "Calibri",
});
s.addText([
{ text: "Indicated when:\n", options: { bold: true } },
{ text: "• Diagnostic uncertainty\n• Altered consciousness (intubated, head injury)\n• Uncooperative / sedated patient\n\n", options: {} },
{ text: "Thresholds for fasciotomy:\n", options: { bold: true } },
{ text: "• Absolute pressure ≥ 30 mmHg\n• ΔP (diastolic − compartment) ≤ 30 mmHg\n• Some advocate ΔP < 10 mmHg", options: {} },
], {
x: 0.35, y: 3.38, w: 4.3, h: 1.85,
fontSize: 10.5, color: C.textDark, fontFace: "Calibri",
});
// Important notes
addCard(s, 5.05, 0.78, 4.7, 2.1, "Pitfalls to Avoid", C.accent, [
"ACS can occur in OPEN fractures",
"Pulselessness is NOT required for diagnosis",
"High- and low-energy injuries carry equal risk",
"Elevated CPK / myoglobinuria = LATE marker; do not wait",
"Maintain high index of suspicion in all limb injuries",
]);
// Differential
addCard(s, 5.05, 3.0, 4.7, 2.3, "Differential Diagnosis", C.textDark, [
"Deep vein thrombosis (DVT)",
"Cellulitis / necrotizing fasciitis",
"Peripheral arterial occlusion",
"Rhabdomyolysis without ACS",
"Severe muscle contusion / haematoma",
]);
addFooter(s, 5, TOTAL);
}
// ══════════════════════════════════════════════════════════════════
// SLIDE 6 – MANAGEMENT OVERVIEW
// ══════════════════════════════════════════════════════════════════
{
const s = contentSlide("Management — Overview", "MANAGEMENT", C.accentGrn);
// 3-step flow
const steps = [
{ num: "1", title: "Immediate First Aid", col: C.accentAmb, items: [
"Remove ALL constricting casts, bandages, dressings",
"Split cast to the skin (bivalve cast)",
"Elevate extremity to heart level (NOT above)",
"Give adequate analgesia",
"Correct hypotension / optimise MAP",
]},
{ num: "2", title: "Surgical Fasciotomy", col: C.accent, items: [
"Definitive treatment – do NOT delay",
"Lower leg: 4-compartment via medial + lateral incisions",
"Forearm: Volar + dorsal release",
"Hand: Carpal tunnel ± hand fasciotomies if needed",
"Leave wounds OPEN – do NOT close primarily",
]},
{ num: "3", title: "Post-Fasciotomy Care", col: C.accentGrn, items: [
"Vacuum-assisted closure (VAC) device",
"Serial wound inspections every 48–72 hrs",
"Delayed primary closure / split-thickness skin graft",
"Monitor for rhabdomyolysis (urine output, CPK, creatinine)",
"IV hydration: target UO > 100 mL/hr until CPK < 5000 U/L",
]},
];
steps.forEach((st, i) => {
const x = 0.25 + i * 3.2;
// circle number
s.addShape(pres.ShapeType.ellipse, {
x: x + 1.1, y: 0.78, w: 0.9, h: 0.9,
fill: { color: st.col }, line: { color: st.col },
});
s.addText(st.num, {
x: x + 1.1, y: 0.78, w: 0.9, h: 0.9,
fontSize: 24, bold: true, color: C.white, align: "center", valign: "middle", margin: 0,
});
addCard(s, x, 1.75, 3.0, 3.55, st.title, st.col, st.items);
});
// flow arrows between steps
[1, 2].forEach(i => {
s.addShape(pres.ShapeType.rightArrow, {
x: 0.25 + i * 3.2 - 0.32, y: 3.3, w: 0.32, h: 0.5,
fill: { color: C.lightGray }, line: { color: C.lightGray },
});
});
addFooter(s, 6, TOTAL);
}
// ══════════════════════════════════════════════════════════════════
// SLIDE 7 – FASCIOTOMY TECHNIQUES
// ══════════════════════════════════════════════════════════════════
{
const s = contentSlide("Fasciotomy Techniques", "SURGERY", C.accent);
addCard(s, 0.25, 0.78, 4.6, 2.3, "Lower Leg – 4 Compartment Release", C.accent, [
"TWO longitudinal incisions",
"LATERAL: release anterior + lateral compartments",
"MEDIAL: release superficial + deep posterior compartments",
"Incisions 15–20 cm in length",
"Ensure complete skin release – no partial decompression",
]);
addCard(s, 0.25, 3.2, 4.6, 2.1, "Forearm Release", C.accentAmb, [
"Volar incision: release superficial & deep volar compartments",
"Dorsal incision: release dorsal compartment",
"Extend to carpal tunnel if hand swelling present",
"Consult hand surgery for digital fasciotomies",
]);
addCard(s, 5.1, 0.78, 4.6, 2.3, "Wound Management", C.accentGrn, [
"Wounds left OPEN post-fasciotomy",
"VAC (vacuum-assisted closure) applied",
"Reduces muscle oedema and promotes granulation",
"Closure at 5–7 days if swelling resolves",
"Split-thickness skin graft (STSG) if unable to close primarily",
]);
addCard(s, 5.1, 3.2, 4.6, 2.1, "Key Warnings", C.accent, [
"Incomplete skin release = muscle necrosis risk",
"Early closure attempts must be AVOIDED",
"Fasciotomy can be required for open fractures too",
"Prophylactic fasciotomy for ischaemia > 6 hours",
]);
addFooter(s, 7, TOTAL);
}
// ══════════════════════════════════════════════════════════════════
// SLIDE 8 – RHABDOMYOLYSIS & SYSTEMIC COMPLICATIONS
// ══════════════════════════════════════════════════════════════════
{
const s = contentSlide("Systemic Complications — Rhabdomyolysis", "COMPLICATIONS", C.accentAmb);
s.addText("Muscle necrosis releases myoglobin into the circulation, leading to a cascade of systemic complications.", {
x: 0.25, y: 0.82, w: 9.5, h: 0.5,
fontSize: 12, color: C.textDark, italic: true, fontFace: "Calibri",
});
const comp = [
{ title: "Rhabdomyolysis", col: C.accentAmb, items: ["Muscle cell destruction → release of myoglobin, K⁺, H⁺", "Elevated creatine phosphokinase (CPK)", "Myoglobinuria – brown/dark urine", "Late marker: do NOT use to diagnose ACS"] },
{ title: "Acute Kidney Injury", col: C.accent, items: ["Myoglobin precipitates in tubules → ATN", "Acute tubular necrosis", "Oliguric renal failure", "May require dialysis in severe cases"] },
{ title: "Electrolyte Disturbances", col: C.textDark, items: ["Hyperkalaemia (K⁺ release from cells)", "Metabolic acidosis (H⁺ release)", "Hypocalcaemia (Ca²⁺ sequestration)", "Risk of fatal arrhythmias"] },
];
comp.forEach((c, i) => addCard(s, 0.25 + i * 3.25, 1.45, 3.1, 2.7, c.title, c.col, c.items));
// Treatment box
s.addShape(pres.ShapeType.rect, {
x: 0.25, y: 4.3, w: 9.5, h: 1.1,
fill: { color: "F0FDF4" }, line: { color: C.accentGrn, size: 2 },
});
s.addText("Treatment of Rhabdomyolysis:", {
x: 0.4, y: 4.35, w: 2.5, h: 0.4,
fontSize: 11, bold: true, color: C.accentGrn, margin: 0,
});
s.addText([
{ text: "• Aggressive IV fluid resuscitation ", options: {} },
{ text: "• Target urine output > 100 mL/hr until CPK < 5,000 U/L ", options: {} },
{ text: "• Urine alkalinization (NaHCO₃) in severe cases ", options: {} },
{ text: "• Correct electrolyte imbalances ", options: {} },
{ text: "• Consider early dialysis if renal failure progresses", options: {} },
], {
x: 0.4, y: 4.78, w: 9.2, h: 0.55,
fontSize: 10, color: C.textDark, fontFace: "Calibri",
});
addFooter(s, 8, TOTAL);
}
// ══════════════════════════════════════════════════════════════════
// SLIDE 9 – SPECIAL SCENARIOS
// ══════════════════════════════════════════════════════════════════
{
const s = contentSlide("Special Scenarios", "SPECIAL CASES", C.accentAmb);
const scenarios = [
{ title: "Open Fractures", col: C.accent, items: [
"ACS CAN and DOES occur in open fractures",
"Do not be falsely reassured by an open wound",
"Fasciotomy still indicated if compartment pressure elevated",
"Monitor ALL open fracture patients closely",
]},
{ title: "Altered Consciousness", col: C.accentAmb, items: [
"Cannot assess clinical symptoms reliably",
"Intubated, head-injured, sedated patients at risk",
"Direct compartment pressure monitoring MANDATORY",
"Measure all compartments; repeat serially",
]},
{ title: "Reperfusion after Ischaemia", col: C.accentGrn, items: [
"Post-revascularisation oedema → ACS",
"More severe ischaemia = higher ACS risk",
"Ischaemia > 6 hours → prophylactic fasciotomy",
"Post-op VAC and close monitoring",
]},
{ title: "Burns", col: "7C3AED", items: [
"Circumferential third-degree burns",
"Eschar forms non-compliant constricting casing",
"Escharotomy required (not fasciotomy alone)",
"Upper and lower limb compartments at risk",
]},
];
const xs = [0.25, 2.65, 5.05, 7.45];
scenarios.forEach((sc, i) => addCard(s, xs[i], 0.82, 2.25, 4.55, sc.title, sc.col, sc.items));
addFooter(s, 9, TOTAL);
}
// ══════════════════════════════════════════════════════════════════
// SLIDE 10 – PRESSURE MONITORING TECHNIQUE
// ══════════════════════════════════════════════════════════════════
{
const s = contentSlide("Compartment Pressure Monitoring", "TECHNIQUE", C.textDark);
addCard(s, 0.25, 0.78, 4.6, 2.4, "Indications", C.textDark, [
"Diagnostic uncertainty",
"Unconscious / sedated patients",
"Head-injured or intubated patients",
"Children who cannot cooperate with exam",
"Suspicion not confirmed clinically",
]);
addCard(s, 5.1, 0.78, 4.6, 2.4, "Technique", C.accentGrn, [
"Use dedicated compartment pressure monitor or arterial line setup",
"18-gauge needle with saline flush",
"Insert needle into compartment at 90° to skin",
"Measure MULTIPLE sites near (not in) fracture",
"Measure ALL compartments of affected limb",
"Document each compartment value",
]);
// threshold table
const tableData = [
[
{ text: "Threshold", options: { bold: true, color: C.white, fill: C.textDark } },
{ text: "Value", options: { bold: true, color: C.white, fill: C.textDark } },
{ text: "Action", options: { bold: true, color: C.white, fill: C.textDark } },
],
[
{ text: "Absolute pressure", options: {} },
{ text: "≥ 30 mmHg", options: { bold: true, color: C.accent } },
{ text: "Fasciotomy indicated", options: {} },
],
[
{ text: "ΔP (DBP − compartment)", options: {} },
{ text: "≤ 30 mmHg", options: { bold: true, color: C.accent } },
{ text: "Fasciotomy indicated", options: {} },
],
[
{ text: "ΔP (DBP − compartment)", options: {} },
{ text: "< 10 mmHg", options: { bold: true, color: C.accent } },
{ text: "Fasciotomy strongly indicated (some guidelines)", options: {} },
],
[
{ text: "High clinical suspicion", options: {} },
{ text: "Any pressure", options: { bold: true, color: C.accentAmb } },
{ text: "Consider fasciotomy regardless", options: {} },
],
];
s.addTable(tableData, {
x: 0.25, y: 3.4, w: 9.5, h: 2.0,
fontSize: 11, fontFace: "Calibri",
colW: [3.2, 2.1, 4.2],
border: { type: "solid", color: C.lightGray, size: 1 },
fill: C.white,
align: "left",
});
addFooter(s, 10, TOTAL);
}
// ══════════════════════════════════════════════════════════════════
// SLIDE 11 – OUTCOMES & PROGNOSIS
// ══════════════════════════════════════════════════════════════════
{
const s = contentSlide("Outcomes & Prognosis", "OUTCOMES", C.accentGrn);
// Timeline graphic (horizontal)
const times = [
{ label: "< 6 hrs", desc: "Fasciotomy → Good recovery, minimal functional loss", col: C.accentGrn },
{ label: "6–12 hrs", desc: "Partial muscle necrosis, some functional deficit likely", col: C.accentAmb },
{ label: "> 12 hrs", desc: "Severe necrosis, contracture, potential limb loss", col: C.accent },
{ label: "> 24 hrs", desc: "High risk: limb loss, renal failure, mortality", col: "991B1B" },
];
times.forEach((t, i) => {
const x = 0.3 + i * 2.4;
s.addShape(pres.ShapeType.ellipse, {
x: x + 0.55, y: 0.9, w: 1.3, h: 1.3,
fill: { color: t.col }, line: { color: t.col },
});
s.addText(t.label, {
x: x + 0.55, y: 0.9, w: 1.3, h: 1.3,
fontSize: 13, bold: true, color: C.white, align: "center", valign: "middle", margin: 0,
});
s.addText(t.desc, {
x: x + 0.1, y: 2.35, w: 2.2, h: 1.0,
fontSize: 9.5, color: C.textDark, align: "center", fontFace: "Calibri",
});
// connecting line
if (i < 3) {
s.addShape(pres.ShapeType.line, {
x: x + 1.85, y: 1.55, w: 0.55, h: 0,
line: { color: C.lightGray, size: 2 },
});
}
});
addCard(s, 0.25, 3.5, 4.55, 1.85, "Complications of Delayed Diagnosis", C.accent, [
"Volkmann's ischaemic contracture",
"Permanent nerve damage / foot drop",
"Muscle fibrosis and chronic pain",
"Limb amputation",
"Death (from AKI / multi-organ failure)",
]);
addCard(s, 5.1, 3.5, 4.6, 1.85, "Factors Affecting Prognosis", C.accentGrn, [
"Time from onset to fasciotomy (most critical)",
"Severity of initial ischaemia",
"Number of compartments involved",
"Patient age and comorbidities",
"Quality of post-operative care",
]);
addFooter(s, 11, TOTAL);
}
// ══════════════════════════════════════════════════════════════════
// SLIDE 12 – VOLKMANN'S ISCHAEMIC CONTRACTURE
// ══════════════════════════════════════════════════════════════════
{
const s = contentSlide("Volkmann's Ischaemic Contracture", "COMPLICATION", C.accent);
s.addText("The most feared late consequence of untreated or delayed ACS in the forearm / hand.", {
x: 0.25, y: 0.82, w: 9.5, h: 0.45,
fontSize: 12, italic: true, color: C.textDark, fontFace: "Calibri",
});
addCard(s, 0.25, 1.38, 3.0, 3.9, "Pathology", C.accent, [
"Ischaemic necrosis of forearm flexors",
"Fibrosis replaces dead muscle",
"Tendons shorten → fixed flexion deformity",
"Wrist: palmar flexion",
"Fingers: flexion at MCP & IP joints",
"Thumb: flexion & adduction",
"Classic 'prayer deformity' posture",
]);
addCard(s, 3.45, 1.38, 3.0, 3.9, "Classification", C.accentAmb, [
"MILD: limited to fingers, corrects with wrist extension",
"MODERATE: forearm muscles involved, partial correction",
"SEVERE: all forearm muscles fibrosed, complete contracture",
"May involve ulnar / median nerve palsy",
]);
addCard(s, 6.65, 1.38, 3.1, 3.9, "Treatment", C.accentGrn, [
"Prevention (fasciotomy) is key",
"Physiotherapy / splinting (mild)",
"Muscle slide procedure",
"Tendon lengthening",
"Free muscle transfer (severe)",
"Neurolysis if nerve involvement",
"Functional recovery often incomplete",
]);
addFooter(s, 12, TOTAL);
}
// ══════════════════════════════════════════════════════════════════
// SLIDE 13 – KEY PEARLS & PITFALLS
// ══════════════════════════════════════════════════════════════════
{
const s = contentSlide("Key Pearls & Pitfalls", "PEARLS", C.textDark);
const pearls = [
"Pain out of proportion to injury is the EARLIEST and most reliable sign — take it seriously",
"ACS is a CLINICAL diagnosis; do not wait for pressure measurements if clinically obvious",
"Pulselessness is an EXTREMELY late sign — arterial pulse may be present until very late",
"ACS occurs in OPEN fractures — an open wound does NOT protect against compartment syndrome",
"High- and low-energy injuries carry EQUAL incidence of compartment syndrome",
"Maintain HIGH INDEX OF SUSPICION in patients with altered consciousness",
"Do NOT elevate the limb above the heart — this reduces perfusion pressure",
"Prophylactic fasciotomy recommended for limb ischaemia > 6 hours before revascularization",
"Elevated CPK and myoglobinuria are LATE markers — do not use them to establish diagnosis",
];
const pitfalls = [
"Assuming open fractures cannot develop ACS",
"Waiting for 'all 6 P's' before acting — paralysis / pulselessness = already too late",
"Incomplete fasciotomy (partial release) → ongoing muscle necrosis",
"Attempting early wound closure after fasciotomy",
"Failing to measure all compartments in the affected limb",
"Not repeating pressure measurements when clinical picture worsens",
];
addCard(s, 0.25, 0.78, 5.4, 4.65, "Pearls", C.accentGrn, pearls);
addCard(s, 5.85, 0.78, 3.9, 4.65, "Pitfalls to Avoid", C.accent, pitfalls);
addFooter(s, 13, TOTAL);
}
// ══════════════════════════════════════════════════════════════════
// SLIDE 14 – SUMMARY
// ══════════════════════════════════════════════════════════════════
{
const s = pres.addSlide();
s.background = { color: C.darkBg };
s.addShape(pres.ShapeType.rect, {
x: 0, y: 4.5, w: 10, h: 1.125,
fill: { color: C.accent }, line: { color: C.accent },
});
s.addText("Summary", {
x: 0.5, y: 0.25, w: 9, h: 0.65,
fontSize: 26, bold: true, color: C.white, align: "center", fontFace: "Calibri",
});
const summaryItems = [
{ icon: "🔑", text: "ACS = raised fascial compartment pressure → ischaemia → necrosis" },
{ icon: "⚡", text: "Most common cause: Fracture (70%) — but occurs with any limb injury" },
{ icon: "🩺", text: "Diagnose clinically: pain out of proportion + pain on passive stretch" },
{ icon: "📊", text: "Pressure monitoring for uncertain cases: Absolute ≥30 mmHg or ΔP ≤30 mmHg" },
{ icon: "🔪", text: "Definitive treatment: URGENT fasciotomy — time from onset determines outcome" },
{ icon: "⚠️", text: "Complications of delay: Volkmann's contracture, renal failure, limb loss, death" },
];
const items = summaryItems.map((it, i) => ({
text: `${it.icon} ${it.text}`,
options: { bullet: false, breakLine: i < summaryItems.length - 1, fontSize: 12.5, color: i % 2 === 0 ? C.white : C.lightGray },
}));
s.addText(items, {
x: 0.5, y: 1.05, w: 9, h: 3.3,
valign: "top", fontFace: "Calibri",
lineSpacingMultiple: 1.5,
});
s.addText("Bailey & Love 28e · Current Surgical Therapy 14e · Rosen's Emergency Medicine · Miller's Anaesthesia 10e", {
x: 0.5, y: 4.58, w: 9, h: 0.45,
fontSize: 9, color: C.white, align: "center", fontFace: "Calibri",
});
addFooter(s, 14, TOTAL);
}
// ══════════════════════════════════════════════════════════════════
// WRITE FILE
// ══════════════════════════════════════════════════════════════════
pres.writeFile({ fileName: "/home/daytona/workspace/acs-ppt/Acute_Compartment_Syndrome.pptx" })
.then(() => console.log("DONE: /home/daytona/workspace/acs-ppt/Acute_Compartment_Syndrome.pptx"))
.catch(e => { console.error(e); process.exit(1); });
curl -s "https://cdn.orris.care/cdss_images/77fd2adde28c3157b1de8e7e4c3d257687bb…
cd /home/daytona/workspace/acs-ppt && node create_acs_ppt.js 2>&1
ls -lh /home/daytona/workspace/acs-ppt/Acute_Compartment_Syndrome.pptx
Acute Compartment Syndrome
Presentation · PPTX
| Slide | Content |
|---|---|
| 1 | Title slide — navy/red design |
| 2 | Definition, causes, pathophysiology |
| 3 | Anatomy of compartments (leg & forearm) with textbook diagram |
| 4 | Clinical features — The 6 P's (color-coded early vs. late) |
| 5 | Diagnosis — clinical criteria, pressure thresholds, pitfalls, differentials |
| 6 | Management overview — 3-step flow (first aid → fasciotomy → post-op) |
| 7 | Fasciotomy techniques — lower leg, forearm, wound management |
| 8 | Rhabdomyolysis & systemic complications (AKI, electrolytes, treatment) |
| 9 | Special scenarios — open fractures, altered consciousness, reperfusion, burns |
| 10 | Compartment pressure monitoring — technique + threshold table |
| 11 | Outcomes & prognosis — time-based visual timeline |
| 12 | Volkmann's ischaemic contracture — classification & treatment |
| 13 | Key pearls & pitfalls |
| 14 | Summary slide — dark background |