Anatomical planes, position and terms Bones and cartilage Joints Muscles basics

| Plane | Orientation | Divides Body Into |
|---|---|---|
| Sagittal | Vertical | Left and right sections; the mid-sagittal (midsagittal/median) plane creates equal halves |
| Coronal (Frontal) | Vertical, perpendicular to sagittal | Anterior (front) and posterior (back) portions |
| Transverse (Axial/Horizontal) | Horizontal | Superior (upper) and inferior (lower) sections |
| Term | Meaning |
|---|---|
| Anterior / Ventral | Toward the front / belly side |
| Posterior / Dorsal | Toward the back |
| Superior / Cranial | Toward the head / above |
| Inferior / Caudal | Away from the head / below |
| Medial | Toward the midline of the body |
| Lateral | Away from the midline |
| Proximal | Nearer to the trunk (used for limbs) |
| Distal | Farther from the trunk (used for limbs) |
| Superficial | Toward the body surface |
| Deep | Away from the body surface |
| Ipsilateral | On the same side |
| Contralateral | On the opposite side |
Example: The humerus is proximal to the radius and ulna. The tibia is distal to the femur.
| Term | Definition |
|---|---|
| Flexion | Decreasing the angle between body parts |
| Extension | Increasing the angle between body parts |
| Abduction | Moving away from the midline |
| Adduction | Moving toward the midline |
| Rotation | Turning around a long axis |
| Circumduction | Combining flexion, extension, abduction, and adduction in a circular motion |
| Pronation / Supination | Rotating forearm so palm faces down / up |
| Inversion / Eversion | Turning sole inward / outward |
| Dorsiflexion / Plantarflexion | Foot upward / foot downward |
| Type | Description | Examples |
|---|---|---|
| Long bones | Greater length than width; shaft (diaphysis) + two ends (epiphyses) | Femur, humerus, tibia |
| Short bones | Roughly equal dimensions | Carpals, tarsals |
| Flat bones | Thin, broad plates | Skull bones, scapula, sternum |
| Irregular bones | Complex shapes, don't fit other categories | Vertebrae, facial bones |
| Sesamoid bones | Embedded in tendons | Patella |
| Type | Composition | Key Features | Location |
|---|---|---|---|
| Hyaline cartilage | Type II collagen + ground substance; chondrocytes in lacunae | Smooth, glassy; most common; no blood/nerve supply | Articular surfaces, costal cartilages, tracheal rings, fetal skeleton, growth plates |
| Fibrocartilage | Dense type I collagen bundles | Strongest; highest tensile strength | Intervertebral discs, pubic symphysis, menisci, tendon insertions |
| Elastic cartilage | Elastin fibers + type II collagen | Flexible and resilient | Auricle (pinna), epiglottis, Eustachian tube |
Key fact: Cartilage is avascular - it receives nutrients by diffusion through the matrix. This is why cartilage heals slowly after injury.

| Joint Type | Tissue Bridge | Movement | Also Called | Examples |
|---|---|---|---|---|
| Fibrous | Dense connective tissue | Minimal to none | Synarthroses | Skull sutures, gomphoses (teeth), syndesmoses (tibia-fibula) |
| Cartilaginous | Hyaline cartilage or fibrocartilage | Slight | Amphiarthroses | Pubic symphysis, intervertebral discs, costal cartilage-rib1 junction, epiphyseal plates |
| Synovial | Synovial cavity + fluid | Freely moveable | Diarthroses | Hip, knee, shoulder, elbow, wrist, ankle |
| Shape | Axes | Motion | Example |
|---|---|---|---|
| Hinge | Uniaxial | Flexion/Extension | Elbow (humeroulnar) |
| Pivot | Uniaxial | Rotation | Atlantoaxial (C1-C2), proximal radio-ulnar |
| Condyloid (Ellipsoid) | Biaxial | Flex/Ext + Abd/Add | Wrist (radiocarpal) |
| Saddle | Biaxial | Flex/Ext + Abd/Add | First carpometacarpal |
| Ball and Socket | Multiaxial | All planes | Shoulder (glenohumeral), hip |
| Plane (Gliding) | Multiaxial (gliding) | Gliding | Patellofemoral, intercarpal |
| Type | Control | Striations | Location |
|---|---|---|---|
| Skeletal | Voluntary / reflex | Yes | Attached to bones; movement, posture |
| Cardiac | Involuntary | Yes | Heart wall |
| Smooth | Involuntary | No | Hollow organs (gut, blood vessels, bladder) |

| Level | Structure | Covering Sheath |
|---|---|---|
| Whole muscle | Made of fascicle bundles | Epimysium |
| Fascicle | Bundle of muscle fibers | Perimysium |
| Muscle fiber (cell/myofiber) | Multinucleated elongated cell | Endomysium |
| Myofibril | Cylindrical element inside fiber | Sarcolemma (cell membrane) |
| Sarcomere | Functional/contractile unit | - |
| Myofilaments | Actin (thin) + Myosin (thick) | - |
| Structure | Description |
|---|---|
| Tendon | Collagen-rich cord connecting muscle to bone |
| Aponeurosis | Flat, sheet-like tendon |
| Ligament | Connects bone to bone (stabilizes joints) |
| Fascia | Connective tissue sheath surrounding muscles and compartments |
| Role | Description | Example |
|---|---|---|
| Agonist (prime mover) | Main muscle producing a movement | Biceps brachii in elbow flexion |
| Antagonist | Opposes the agonist; relaxes to allow movement | Triceps brachii during elbow flexion |
| Synergist | Assists the agonist; stabilizes intermediate joints | Brachialis assisting biceps |
| Fixator | Stabilizes the origin of the agonist | Rotator cuff during deltoid action |
Create a presentation summarizing these anatomy basics
mkdir -p /home/daytona/workspace/anatomy-basics-pptx && ls /home/daytona/workspace/anatomy-basics-pptx
node /home/daytona/skills/shared/scripts/fetch_images.js \ "https://cdn.orris.care/cdss_images/892441b3b16b50336b6a3fa2859b2567057007f18b9ebd4aee82365b104b69be.png" \ "https://cdn.orris.care/cdss_images/d1e862db9b089b138234c853dc1c4c5fbc695755445b78d469a000d755c99a7f.png" \ "https://cdn.orris.care/cdss_images/4957a1e14023483530f3cba257927c5a6786df2827faea23230a4de825e46077.png" \ 2>/dev/null | node -e "const d=require('fs').readFileSync('/dev/stdin','utf8'); const arr=JSON.parse(d); arr.forEach((x,i)=>{ console.log(i, x.error ? 'ERROR:'+x.error : 'OK len='+x.base64.length); });"
~/anatomy-basics-pptx/build.js
const pptxgen = require("pptxgenjs");
const { execSync } = require("child_process");
// ── Fetch images ──────────────────────────────────────────────────────────────
const imageUrls = [
"https://cdn.orris.care/cdss_images/892441b3b16b50336b6a3fa2859b2567057007f18b9ebd4aee82365b104b69be.png", // planes
"https://cdn.orris.care/cdss_images/d1e862db9b089b138234c853dc1c4c5fbc695755445b78d469a000d755c99a7f.png", // joints histology
"https://cdn.orris.care/cdss_images/4957a1e14023483530f3cba257927c5a6786df2827faea23230a4de825e46077.png", // muscle structure
];
const imgData = JSON.parse(
execSync(
`node /home/daytona/skills/shared/scripts/fetch_images.js ${imageUrls.map((u) => `"${u}"`).join(" ")}`
).toString()
);
const [imgPlanes, imgJoint, imgMuscle] = imgData.map((d) => d.base64);
// ── Color palette ─────────────────────────────────────────────────────────────
// Deep navy dominant, teal accent, light slate content bg, warm white text
const C = {
navy: "0D1B2A", // dominant dark
teal: "1A8F7A", // accent / headings
tealLight: "2EC4A9", // highlight
slate: "1E2D3D", // content slide bg
cardBg: "162534", // card background
white: "F4F8FB", // text on dark
offWhite: "C8DCE8", // secondary text
gold: "E8B84B", // key term accent
divider: "1A8F7A", // line color
};
// ── Presentation setup ────────────────────────────────────────────────────────
const pres = new pptxgen();
pres.layout = "LAYOUT_16x9";
pres.title = "Anatomy Basics";
pres.author = "Orris Medical";
// ── Helper: dark gradient-style background via two rects ──────────────────────
function darkBg(slide, accent) {
slide.addShape(pres.shapes.RECTANGLE, {
x: 0, y: 0, w: 10, h: 5.625,
fill: { color: C.navy }, line: { color: C.navy },
});
// left accent bar
slide.addShape(pres.shapes.RECTANGLE, {
x: 0, y: 0, w: 0.06, h: 5.625,
fill: { color: accent || C.teal }, line: { color: accent || C.teal },
});
}
function contentBg(slide) {
slide.addShape(pres.shapes.RECTANGLE, {
x: 0, y: 0, w: 10, h: 5.625,
fill: { color: C.slate }, line: { color: C.slate },
});
slide.addShape(pres.shapes.RECTANGLE, {
x: 0, y: 0, w: 0.06, h: 5.625,
fill: { color: C.teal }, line: { color: C.teal },
});
}
function sectionHeader(slide, title, subtitle, accent) {
darkBg(slide, accent);
// big section number circle (decorative)
slide.addShape(pres.shapes.OVAL, {
x: 7.8, y: 0.5, w: 1.8, h: 1.8,
fill: { color: accent || C.teal, transparency: 80 },
line: { color: accent || C.teal, width: 1.5 },
});
slide.addText(title, {
x: 0.4, y: 1.5, w: 7, h: 1.2,
fontSize: 40, bold: true, color: C.white, fontFace: "Calibri",
charSpacing: 1,
});
if (subtitle) {
slide.addShape(pres.shapes.RECTANGLE, {
x: 0.4, y: 2.75, w: 1.5, h: 0.06,
fill: { color: accent || C.teal }, line: { color: accent || C.teal },
});
slide.addText(subtitle, {
x: 0.4, y: 2.9, w: 7, h: 0.7,
fontSize: 16, color: C.offWhite, fontFace: "Calibri",
});
}
}
function slideTitle(slide, txt) {
slide.addShape(pres.shapes.RECTANGLE, {
x: 0.25, y: 0.18, w: 9.5, h: 0.6,
fill: { color: C.cardBg }, line: { color: C.teal, width: 1 },
});
slide.addText(txt, {
x: 0.4, y: 0.18, w: 9.2, h: 0.6,
fontSize: 18, bold: true, color: C.teal, fontFace: "Calibri",
valign: "middle", margin: 6,
});
}
function card(slide, x, y, w, h, header, items, accentColor) {
slide.addShape(pres.shapes.RECTANGLE, {
x, y, w, h,
fill: { color: C.cardBg },
line: { color: accentColor || C.teal, width: 1 },
shadow: { type: "outer", color: "000000", blur: 5, offset: 2, angle: 135, opacity: 0.25 },
});
slide.addShape(pres.shapes.RECTANGLE, {
x, y, w, h: 0.35,
fill: { color: accentColor || C.teal }, line: { color: accentColor || C.teal },
});
slide.addText(header, {
x: x + 0.12, y: y + 0.01, w: w - 0.2, h: 0.33,
fontSize: 11, bold: true, color: C.navy, fontFace: "Calibri",
valign: "middle", margin: 0,
});
const richItems = items.map((item, i) => [
{ text: "• " + item, options: { breakLine: i < items.length - 1 } },
]).flat();
slide.addText(richItems, {
x: x + 0.12, y: y + 0.4, w: w - 0.2, h: h - 0.48,
fontSize: 10, color: C.offWhite, fontFace: "Calibri",
valign: "top", lineSpacingMultiple: 1.2,
});
}
// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 1 — Title
// ═══════════════════════════════════════════════════════════════════════════════
{
const s = pres.addSlide();
darkBg(s, C.teal);
// decorative circles
s.addShape(pres.shapes.OVAL, { x: 7.5, y: -0.5, w: 3.5, h: 3.5, fill: { color: C.teal, transparency: 88 }, line: { color: C.teal, transparency: 70, width: 1 } });
s.addShape(pres.shapes.OVAL, { x: 8.2, y: 3.2, w: 2.2, h: 2.2, fill: { color: C.tealLight, transparency: 92 }, line: { color: C.tealLight, transparency: 80, width: 1 } });
s.addText("ANATOMY BASICS", {
x: 0.4, y: 1.0, w: 8.5, h: 1.1,
fontSize: 48, bold: true, color: C.white, fontFace: "Calibri",
charSpacing: 4,
});
// teal underline
s.addShape(pres.shapes.RECTANGLE, { x: 0.4, y: 2.18, w: 5.5, h: 0.07, fill: { color: C.teal }, line: { color: C.teal } });
s.addText("A concise visual guide to foundational human anatomy", {
x: 0.4, y: 2.35, w: 7.5, h: 0.55,
fontSize: 15, color: C.offWhite, fontFace: "Calibri", italic: true,
});
const topics = ["Anatomical Planes & Terms", "Bones & Cartilage", "Joints", "Muscles"];
topics.forEach((t, i) => {
s.addShape(pres.shapes.ROUNDED_RECTANGLE, {
x: 0.4 + i * 2.38, y: 3.2, w: 2.15, h: 0.6,
fill: { color: C.teal, transparency: 55 }, line: { color: C.tealLight, width: 1 },
rectRadius: 0.08,
});
s.addText(t, {
x: 0.4 + i * 2.38, y: 3.2, w: 2.15, h: 0.6,
fontSize: 9.5, bold: true, color: C.white, fontFace: "Calibri",
align: "center", valign: "middle",
});
});
s.addText("Sources: Gray's Anatomy | Medical Physiology | Firestein & Kelley's Rheumatology", {
x: 0.4, y: 5.15, w: 9.2, h: 0.35,
fontSize: 8, color: C.offWhite, fontFace: "Calibri", italic: true, transparency: 30,
});
}
// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 2 — Section divider: Anatomical Planes & Terms
// ═══════════════════════════════════════════════════════════════════════════════
{
const s = pres.addSlide();
sectionHeader(s, "01. Anatomical Planes\n& Position", "Standard references for describing the human body", C.teal);
s.addText("01", {
x: 7.9, y: 0.55, w: 1.6, h: 1.6,
fontSize: 36, bold: true, color: C.teal, fontFace: "Calibri",
align: "center", valign: "middle", transparency: 40,
});
}
// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 3 — Anatomical Position & Planes (image + text)
// ═══════════════════════════════════════════════════════════════════════════════
{
const s = pres.addSlide();
contentBg(s);
slideTitle(s, "Standard Anatomical Position & Reference Planes");
// image
s.addImage({ data: imgPlanes, x: 0.25, y: 0.9, w: 3.5, h: 4.55 });
// planes cards
const planes = [
{ name: "Sagittal Plane", desc: "Vertical plane dividing body into LEFT and RIGHT. The mid-sagittal (median) plane creates equal halves.", color: "3A7BD5" },
{ name: "Coronal Plane", desc: "Vertical plane dividing body into ANTERIOR (front) and POSTERIOR (back) portions.", color: C.teal },
{ name: "Transverse Plane", desc: "Horizontal plane dividing body into SUPERIOR (upper) and INFERIOR (lower) sections.", color: "9B59B6" },
];
planes.forEach((p, i) => {
card(s, 4.0, 0.9 + i * 1.55, 5.7, 1.42, p.name, [p.desc], p.color);
});
}
// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 4 — Directional Terms
// ═══════════════════════════════════════════════════════════════════════════════
{
const s = pres.addSlide();
contentBg(s);
slideTitle(s, "Directional Terminology");
const terms = [
["Anterior / Ventral", "Toward the front / belly side"],
["Posterior / Dorsal", "Toward the back"],
["Superior / Cranial", "Above / toward the head"],
["Inferior / Caudal", "Below / away from the head"],
["Medial", "Toward the midline"],
["Lateral", "Away from the midline"],
["Proximal", "Nearer to the trunk (limbs)"],
["Distal", "Farther from the trunk (limbs)"],
["Superficial", "Toward the body surface"],
["Deep", "Away from the body surface"],
["Ipsilateral", "On the same side"],
["Contralateral", "On the opposite side"],
];
// 2 columns of 6
const colW = 4.7;
const rowH = 0.62;
terms.forEach((t, i) => {
const col = Math.floor(i / 6);
const row = i % 6;
const x = 0.2 + col * 4.9;
const y = 0.9 + row * rowH;
s.addShape(pres.shapes.RECTANGLE, {
x, y, w: colW, h: rowH - 0.05,
fill: { color: i % 2 === 0 ? C.cardBg : C.navy },
line: { color: C.teal, width: 0.5 },
});
s.addText(t[0], {
x: x + 0.15, y, w: 1.8, h: rowH - 0.05,
fontSize: 10.5, bold: true, color: C.gold, fontFace: "Calibri",
valign: "middle", margin: 0,
});
s.addText(t[1], {
x: x + 2.0, y, w: colW - 2.1, h: rowH - 0.05,
fontSize: 10.5, color: C.offWhite, fontFace: "Calibri",
valign: "middle", margin: 0,
});
});
s.addText("Example: The humerus is proximal to the radius & ulna. The tibia is distal to the femur.", {
x: 0.2, y: 5.08, w: 9.6, h: 0.4,
fontSize: 9.5, color: C.tealLight, italic: true, fontFace: "Calibri",
});
}
// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 5 — Movement Terms
// ═══════════════════════════════════════════════════════════════════════════════
{
const s = pres.addSlide();
contentBg(s);
slideTitle(s, "Movement Terminology at Joints");
const mvts = [
{ term: "Flexion", def: "Decrease angle between segments" },
{ term: "Extension", def: "Increase angle between segments" },
{ term: "Abduction", def: "Move away from midline" },
{ term: "Adduction", def: "Move toward midline" },
{ term: "Rotation", def: "Turn around long axis" },
{ term: "Circumduction", def: "Combines flex/ext + abd/add in a circle" },
{ term: "Pronation", def: "Forearm rotates — palm faces down" },
{ term: "Supination", def: "Forearm rotates — palm faces up" },
{ term: "Dorsiflexion", def: "Foot pulled upward" },
{ term: "Plantarflexion", def: "Foot pushed downward" },
{ term: "Inversion", def: "Sole turns inward" },
{ term: "Eversion", def: "Sole turns outward" },
];
const cols = 3;
const rows = 4;
const cW = 3.1;
const rH = 1.1;
mvts.forEach((m, i) => {
const col = i % cols;
const row = Math.floor(i / cols);
const x = 0.2 + col * 3.25;
const y = 0.92 + row * rH;
s.addShape(pres.shapes.RECTANGLE, {
x, y, w: cW, h: rH - 0.08,
fill: { color: C.cardBg }, line: { color: C.teal, width: 0.8 },
});
s.addShape(pres.shapes.RECTANGLE, { x, y, w: 0.07, h: rH - 0.08, fill: { color: C.tealLight }, line: { color: C.tealLight } });
s.addText(m.term, {
x: x + 0.15, y: y + 0.05, w: cW - 0.2, h: 0.38,
fontSize: 12, bold: true, color: C.gold, fontFace: "Calibri", margin: 0,
});
s.addText(m.def, {
x: x + 0.15, y: y + 0.44, w: cW - 0.2, h: 0.48,
fontSize: 10, color: C.offWhite, fontFace: "Calibri", margin: 0,
});
});
}
// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 6 — Section divider: Bones & Cartilage
// ═══════════════════════════════════════════════════════════════════════════════
{
const s = pres.addSlide();
sectionHeader(s, "02. Bones & Cartilage", "The structural framework of the human body", C.gold);
s.addText("02", {
x: 7.9, y: 0.55, w: 1.6, h: 1.6,
fontSize: 36, bold: true, color: C.gold, fontFace: "Calibri",
align: "center", valign: "middle", transparency: 40,
});
}
// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 7 — Bone Types by Shape
// ═══════════════════════════════════════════════════════════════════════════════
{
const s = pres.addSlide();
contentBg(s);
slideTitle(s, "Classification of Bones by Shape");
const bones = [
{ type: "Long Bones", desc: "Greater length than width\nShaft (diaphysis) + two ends (epiphyses)", eg: "Femur, Humerus, Tibia", color: C.gold },
{ type: "Short Bones", desc: "Roughly equal in all dimensions\nResilient under compressive forces", eg: "Carpals, Tarsals", color: "3A7BD5" },
{ type: "Flat Bones", desc: "Thin, broad protective plates\nContain diploe (spongy bone) between two cortical layers", eg: "Skull, Scapula, Sternum", color: C.teal },
{ type: "Irregular Bones", desc: "Complex shapes; don't fit other categories\nOften have mixed trabecular and cortical structure", eg: "Vertebrae, Facial bones", color: "E67E22" },
{ type: "Sesamoid Bones", desc: "Embedded within tendons\nProtect tendons from compressive forces", eg: "Patella", color: "9B59B6" },
];
bones.forEach((b, i) => {
const x = 0.2 + (i % 3) * 3.25;
const y = i < 3 ? 0.92 : 2.6;
const w = 3.1;
const h = 1.55;
s.addShape(pres.shapes.RECTANGLE, {
x, y, w, h, fill: { color: C.cardBg }, line: { color: b.color, width: 1.2 },
shadow: { type: "outer", color: "000000", blur: 4, offset: 2, angle: 135, opacity: 0.2 },
});
s.addShape(pres.shapes.RECTANGLE, { x, y, w, h: 0.38, fill: { color: b.color }, line: { color: b.color } });
s.addText(b.type, {
x: x + 0.1, y: y + 0.02, w: w - 0.15, h: 0.35,
fontSize: 11, bold: true, color: C.navy, fontFace: "Calibri", valign: "middle", margin: 0,
});
s.addText(b.desc, {
x: x + 0.1, y: y + 0.42, w: w - 0.15, h: 0.72,
fontSize: 9.5, color: C.offWhite, fontFace: "Calibri", margin: 0,
});
s.addText("e.g. " + b.eg, {
x: x + 0.1, y: y + 1.15, w: w - 0.15, h: 0.3,
fontSize: 9, color: b.color, bold: true, italic: true, fontFace: "Calibri", margin: 0,
});
});
}
// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 8 — Bone Structure & Ossification
// ═══════════════════════════════════════════════════════════════════════════════
{
const s = pres.addSlide();
contentBg(s);
slideTitle(s, "Bone Structure & Ossification");
// Left: structure
card(s, 0.2, 0.9, 4.7, 2.3, "Macroscopic Bone Structure", [
"Periosteum — outer fibrous covering; osteoprogenitor cells",
"Compact (cortical) bone — dense outer layer, Haversian systems",
"Cancellous (spongy/trabecular) bone — inner meshwork + marrow spaces",
"Medullary cavity — yellow (fat) or red (hematopoietic) marrow",
"Endosteum — lines inner surfaces",
], C.gold);
card(s, 0.2, 3.3, 4.7, 2.15, "Ossification (Bone Formation)", [
"Intramembranous: bone forms from mesenchymal cells directly (skull, clavicle)",
"Endochondral: bone replaces hyaline cartilage model (most of skeleton)",
"Epiphyseal growth plate drives longitudinal bone growth until puberty",
], "E67E22");
// Right: Cartilage types
const carts = [
{ name: "Hyaline Cartilage", color: "3A7BD5", traits: ["Type II collagen + ground substance", "Most common; no blood/nerve supply", "Articular surfaces, costal cartilages, growth plates"] },
{ name: "Fibrocartilage", color: C.teal, traits: ["Dense type I collagen", "Strongest; highest tensile strength", "Intervertebral discs, pubic symphysis, menisci"] },
{ name: "Elastic Cartilage", color: "9B59B6", traits: ["Elastin + type II collagen", "Flexible and resilient", "Auricle (ear), epiglottis, Eustachian tube"] },
];
s.addText("CARTILAGE TYPES", {
x: 5.1, y: 0.9, w: 4.7, h: 0.4,
fontSize: 12, bold: true, color: C.tealLight, fontFace: "Calibri", charSpacing: 2,
});
carts.forEach((c, i) => {
card(s, 5.1, 1.35 + i * 1.41, 4.7, 1.3, c.name, c.traits, c.color);
});
s.addText("Key: Cartilage is AVASCULAR — heals slowly after injury (nutrients via diffusion)", {
x: 5.1, y: 5.1, w: 4.7, h: 0.35,
fontSize: 9, color: C.gold, italic: true, fontFace: "Calibri",
});
}
// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 9 — Section divider: Joints
// ═══════════════════════════════════════════════════════════════════════════════
{
const s = pres.addSlide();
sectionHeader(s, "03. Joints", "Where bones meet — classification, structure, and motion", "3A7BD5");
s.addText("03", {
x: 7.9, y: 0.55, w: 1.6, h: 1.6,
fontSize: 36, bold: true, color: "3A7BD5", fontFace: "Calibri",
align: "center", valign: "middle", transparency: 40,
});
}
// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 10 — Joint Classification
// ═══════════════════════════════════════════════════════════════════════════════
{
const s = pres.addSlide();
contentBg(s);
slideTitle(s, "Classification of Joints");
const joints = [
{
name: "Fibrous (Synarthroses)",
tissue: "Dense connective tissue",
mvt: "Minimal / none",
sub: ["Sutures (skull)", "Syndesmoses (tibia-fibula)", "Gomphoses (teeth in sockets)"],
color: "E74C3C",
},
{
name: "Cartilaginous (Amphiarthroses)",
tissue: "Hyaline cartilage or fibrocartilage",
mvt: "Slight",
sub: ["Synchondroses (rib 1-sternum, growth plates)", "Secondary cartilaginous (pubic symphysis, IVDs)"],
color: C.gold,
},
{
name: "Synovial (Diarthroses)",
tissue: "Synovial cavity + fluid + articular cartilage",
mvt: "Freely moveable",
sub: ["Hinge — elbow", "Pivot — atlantoaxial", "Ball & socket — hip, shoulder", "Condyloid — wrist", "Saddle — 1st CMC", "Plane — patellofemoral"],
color: "3A7BD5",
},
];
joints.forEach((j, i) => {
const x = 0.2 + i * 3.25;
const y = 0.9;
const w = 3.1;
const h = 4.55;
s.addShape(pres.shapes.RECTANGLE, {
x, y, w, h,
fill: { color: C.cardBg }, line: { color: j.color, width: 1.5 },
});
s.addShape(pres.shapes.RECTANGLE, { x, y, w, h: 0.42, fill: { color: j.color }, line: { color: j.color } });
s.addText(j.name, {
x: x + 0.1, y: y + 0.03, w: w - 0.15, h: 0.37,
fontSize: 11, bold: true, color: C.navy, fontFace: "Calibri", valign: "middle", margin: 0,
});
s.addText("Tissue: " + j.tissue, {
x: x + 0.1, y: y + 0.5, w: w - 0.15, h: 0.45,
fontSize: 9.5, bold: true, color: C.offWhite, fontFace: "Calibri", margin: 0,
});
s.addText("Movement: " + j.mvt, {
x: x + 0.1, y: y + 0.93, w: w - 0.15, h: 0.38,
fontSize: 9.5, color: j.color, bold: true, fontFace: "Calibri", margin: 0,
});
s.addShape(pres.shapes.RECTANGLE, {
x: x + 0.1, y: y + 1.35, w: w - 0.2, h: 0.04,
fill: { color: j.color, transparency: 50 }, line: { color: j.color, transparency: 50 },
});
const richItems = j.sub.map((t, si) => ({ text: "• " + t, options: { breakLine: si < j.sub.length - 1 } }));
s.addText(richItems, {
x: x + 0.1, y: y + 1.46, w: w - 0.15, h: h - 1.56,
fontSize: 9.5, color: C.offWhite, fontFace: "Calibri",
valign: "top", lineSpacingMultiple: 1.3, margin: 0,
});
});
}
// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 11 — Synovial Joint Histology
// ═══════════════════════════════════════════════════════════════════════════════
{
const s = pres.addSlide();
contentBg(s);
slideTitle(s, "Synovial Joint — Structure & Components");
s.addImage({ data: imgJoint, x: 0.25, y: 0.92, w: 4.4, h: 4.5 });
const components = [
{ name: "Articular Cartilage", desc: "Hyaline cartilage covering opposing bone ends; resilient, zonal, near-frictionless motion" },
{ name: "Synovial Cavity", desc: "Space filled with synovial fluid — contains hyaluronic acid, lubricin, and phospholipids" },
{ name: "Synovium", desc: "Inner lining that produces synovial fluid; type A (macrophage-like) and type B (fibroblast-like) cells" },
{ name: "Fibrous Capsule", desc: "Outer tough connective tissue enclosing and protecting the joint" },
{ name: "Growth Plate", desc: "Hyaline cartilage between epiphysis and diaphysis — active during skeletal growth" },
];
components.forEach((c, i) => {
s.addShape(pres.shapes.RECTANGLE, {
x: 4.8, y: 0.9 + i * 0.88, w: 5.0, h: 0.82,
fill: { color: i % 2 === 0 ? C.cardBg : C.navy }, line: { color: "3A7BD5", width: 0.6 },
});
s.addShape(pres.shapes.RECTANGLE, { x: 4.8, y: 0.9 + i * 0.88, w: 0.07, h: 0.82, fill: { color: "3A7BD5" }, line: { color: "3A7BD5" } });
s.addText(c.name, {
x: 4.95, y: 0.9 + i * 0.88 + 0.04, w: 4.78, h: 0.3,
fontSize: 10.5, bold: true, color: C.gold, fontFace: "Calibri", margin: 0,
});
s.addText(c.desc, {
x: 4.95, y: 0.9 + i * 0.88 + 0.35, w: 4.78, h: 0.4,
fontSize: 9, color: C.offWhite, fontFace: "Calibri", margin: 0,
});
});
s.addText("Image: Frontal section of juvenile mouse knee — safranin O & fast green stain\n(Firestein & Kelley's Textbook of Rheumatology)", {
x: 0.25, y: 5.08, w: 4.4, h: 0.4,
fontSize: 7.5, color: C.offWhite, italic: true, fontFace: "Calibri", transparency: 20,
});
}
// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 12 — Section divider: Muscles
// ═══════════════════════════════════════════════════════════════════════════════
{
const s = pres.addSlide();
sectionHeader(s, "04. Muscles", "Structure, hierarchy, and neuromuscular control", "9B59B6");
s.addText("04", {
x: 7.9, y: 0.55, w: 1.6, h: 1.6,
fontSize: 36, bold: true, color: "9B59B6", fontFace: "Calibri",
align: "center", valign: "middle", transparency: 40,
});
}
// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 13 — Muscle Types
// ═══════════════════════════════════════════════════════════════════════════════
{
const s = pres.addSlide();
contentBg(s);
slideTitle(s, "Three Types of Muscle Tissue");
const types = [
{ name: "Skeletal Muscle", control: "Voluntary / reflex", striated: "Yes", location: "Attached to bones", function: "Movement, posture, heat generation", color: "9B59B6" },
{ name: "Cardiac Muscle", control: "Involuntary (autorhythmic)", striated: "Yes", location: "Heart wall (myocardium)", function: "Pumps blood continuously", color: "E74C3C" },
{ name: "Smooth Muscle", control: "Involuntary", striated: "No", location: "Walls of hollow organs", function: "Peristalsis, vasoconstriction, sphincters", color: C.teal },
];
types.forEach((t, i) => {
const x = 0.2 + i * 3.25;
const y = 0.92;
const w = 3.1;
const h = 4.55;
s.addShape(pres.shapes.RECTANGLE, {
x, y, w, h, fill: { color: C.cardBg }, line: { color: t.color, width: 1.5 },
});
s.addShape(pres.shapes.RECTANGLE, { x, y, w, h: 0.42, fill: { color: t.color }, line: { color: t.color } });
s.addText(t.name, {
x: x + 0.1, y: y + 0.02, w: w - 0.15, h: 0.4,
fontSize: 12, bold: true, color: C.navy, fontFace: "Calibri", valign: "middle", margin: 0,
});
const rows = [
["Control", t.control],
["Striations", t.striated],
["Location", t.location],
["Function", t.function],
];
rows.forEach(([lbl, val], ri) => {
s.addText(lbl, {
x: x + 0.1, y: y + 0.6 + ri * 0.88, w: 1.0, h: 0.35,
fontSize: 9.5, bold: true, color: t.color, fontFace: "Calibri", margin: 0,
});
s.addText(val, {
x: x + 1.05, y: y + 0.6 + ri * 0.88, w: w - 1.15, h: 0.35,
fontSize: 9.5, color: C.offWhite, fontFace: "Calibri", margin: 0,
});
if (ri < 3) {
s.addShape(pres.shapes.RECTANGLE, {
x: x + 0.1, y: y + 0.6 + ri * 0.88 + 0.35, w: w - 0.2, h: 0.04,
fill: { color: t.color, transparency: 75 }, line: { color: t.color, transparency: 75 },
});
}
});
});
}
// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 14 — Skeletal Muscle Hierarchy
// ═══════════════════════════════════════════════════════════════════════════════
{
const s = pres.addSlide();
contentBg(s);
slideTitle(s, "Skeletal Muscle — Hierarchical Organization");
s.addImage({ data: imgMuscle, x: 6.2, y: 0.9, w: 3.6, h: 4.5 });
const levels = [
{ level: "Whole Muscle", sheath: "Epimysium", desc: "Bundle of fascicles enclosed in outer sheath" },
{ level: "Fascicle", sheath: "Perimysium", desc: "Bundle of muscle fibers" },
{ level: "Muscle Fiber (cell)", sheath: "Endomysium + Sarcolemma", desc: "Multinucleated elongated cell" },
{ level: "Myofibril", sheath: "–", desc: "Cylindrical elements inside the fiber" },
{ level: "Sarcomere", sheath: "Z-lines (boundaries)", desc: "The basic contractile unit — bounded by Z-lines" },
{ level: "Myofilaments", sheath: "–", desc: "Actin (thin) + Myosin (thick) — sliding produces contraction" },
];
levels.forEach((l, i) => {
const y = 0.9 + i * 0.77;
s.addShape(pres.shapes.RECTANGLE, {
x: 0.2, y, w: 5.85, h: 0.71,
fill: { color: i % 2 === 0 ? C.cardBg : C.navy },
line: { color: "9B59B6", width: 0.5 },
});
s.addShape(pres.shapes.RECTANGLE, { x: 0.2, y, w: 0.07, h: 0.71, fill: { color: "9B59B6" }, line: { color: "9B59B6" } });
s.addText(l.level, {
x: 0.35, y: y + 0.05, w: 1.9, h: 0.32,
fontSize: 10.5, bold: true, color: C.gold, fontFace: "Calibri", margin: 0,
});
s.addText("Sheath: " + l.sheath, {
x: 0.35, y: y + 0.37, w: 1.9, h: 0.28,
fontSize: 8.5, color: "9B59B6", italic: true, fontFace: "Calibri", margin: 0,
});
s.addText(l.desc, {
x: 2.3, y: y + 0.08, w: 3.65, h: 0.56,
fontSize: 9.5, color: C.offWhite, fontFace: "Calibri", valign: "middle", margin: 0,
});
});
s.addText("Source: Medical Physiology (Boron & Boulpaep)", {
x: 6.2, y: 5.1, w: 3.6, h: 0.3,
fontSize: 7.5, color: C.offWhite, italic: true, fontFace: "Calibri",
});
}
// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 15 — Neuromuscular Control & Muscle Roles
// ═══════════════════════════════════════════════════════════════════════════════
{
const s = pres.addSlide();
contentBg(s);
slideTitle(s, "Neuromuscular Control & Muscle Functional Roles");
// Left: NMJ & motor unit
card(s, 0.2, 0.9, 4.7, 2.5, "Neuromuscular Junction (NMJ)", [
"Motor neuron axon terminal releases Acetylcholine (ACh)",
"ACh binds nicotinic receptors on motor end plate",
"End-plate potential → action potential → muscle contraction",
"Motor unit = 1 motor neuron + ALL fibers it innervates",
"Small innervation ratio → fine movement (extraocular ~3 fibers/neuron)",
"Large innervation ratio → powerful movement (gastrocnemius ~100-1000)",
], "9B59B6");
card(s, 0.2, 3.5, 4.7, 1.95, "Connective Tissue", [
"Tendon — collagen cord connecting muscle to bone",
"Aponeurosis — flat, sheet-like tendon",
"Ligament — bone to bone (joint stabilization)",
"Fascia — sheath surrounding muscles and compartments",
], C.teal);
// Right: muscle functional roles
const roles = [
{ role: "Agonist (Prime mover)", def: "Main muscle producing the movement", eg: "Biceps brachii in elbow flexion" },
{ role: "Antagonist", def: "Opposes and controls the agonist; relaxes to allow movement", eg: "Triceps brachii during flexion" },
{ role: "Synergist", def: "Assists the agonist; stabilizes intermediate joints", eg: "Brachialis assisting biceps" },
{ role: "Fixator", def: "Stabilizes the origin of the agonist", eg: "Rotator cuff during deltoid action" },
];
s.addText("FUNCTIONAL ROLES", {
x: 5.1, y: 0.9, w: 4.7, h: 0.38,
fontSize: 11, bold: true, color: "9B59B6", fontFace: "Calibri", charSpacing: 2,
});
roles.forEach((r, i) => {
s.addShape(pres.shapes.RECTANGLE, {
x: 5.1, y: 1.32 + i * 1.08, w: 4.7, h: 1.02,
fill: { color: i % 2 === 0 ? C.cardBg : C.navy }, line: { color: "9B59B6", width: 0.8 },
});
s.addShape(pres.shapes.RECTANGLE, { x: 5.1, y: 1.32 + i * 1.08, w: 0.07, h: 1.02, fill: { color: "9B59B6" }, line: { color: "9B59B6" } });
s.addText(r.role, {
x: 5.22, y: 1.32 + i * 1.08 + 0.04, w: 4.5, h: 0.3,
fontSize: 10.5, bold: true, color: C.gold, fontFace: "Calibri", margin: 0,
});
s.addText(r.def, {
x: 5.22, y: 1.32 + i * 1.08 + 0.36, w: 4.5, h: 0.3,
fontSize: 9.5, color: C.offWhite, fontFace: "Calibri", margin: 0,
});
s.addText("e.g. " + r.eg, {
x: 5.22, y: 1.32 + i * 1.08 + 0.67, w: 4.5, h: 0.28,
fontSize: 8.5, color: "9B59B6", italic: true, fontFace: "Calibri", margin: 0,
});
});
}
// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 16 — Summary / Closing
// ═══════════════════════════════════════════════════════════════════════════════
{
const s = pres.addSlide();
darkBg(s, C.tealLight);
s.addShape(pres.shapes.OVAL, { x: 7.5, y: -0.6, w: 3.5, h: 3.5, fill: { color: C.teal, transparency: 88 }, line: { color: C.teal, transparency: 70, width: 1 } });
s.addShape(pres.shapes.OVAL, { x: -0.8, y: 3.8, w: 2.5, h: 2.5, fill: { color: C.tealLight, transparency: 90 }, line: { color: C.tealLight, transparency: 80, width: 1 } });
s.addText("Key Takeaways", {
x: 0.4, y: 0.3, w: 7, h: 0.7,
fontSize: 30, bold: true, color: C.white, fontFace: "Calibri",
});
s.addShape(pres.shapes.RECTANGLE, { x: 0.4, y: 1.05, w: 4.0, h: 0.06, fill: { color: C.tealLight }, line: { color: C.tealLight } });
const summaryPoints = [
["Anatomical Position", "Body erect, palms forward — all terms reference this standard"],
["3 Reference Planes", "Sagittal (L/R) · Coronal (front/back) · Transverse (up/down)"],
["Bone Types", "Long, short, flat, irregular, sesamoid — each suited to its role"],
["Cartilage Types", "Hyaline (articular), Fibrocartilage (discs), Elastic (ear) — all avascular"],
["Joint Classification", "Fibrous (none) · Cartilaginous (slight) · Synovial (freely mobile)"],
["Muscle Hierarchy", "Muscle → Fascicle → Fiber → Myofibril → Sarcomere → Myofilaments"],
["Motor Unit", "1 motor neuron + its muscle fibers — basis of graded force production"],
];
summaryPoints.forEach((pt, i) => {
s.addShape(pres.shapes.RECTANGLE, {
x: 0.4, y: 1.2 + i * 0.6, w: 9.3, h: 0.54,
fill: { color: i % 2 === 0 ? C.cardBg : C.navy }, line: { color: C.teal, width: 0.5 },
});
s.addText(pt[0] + " ", {
x: 0.55, y: 1.2 + i * 0.6 + 0.06, w: 2.1, h: 0.38,
fontSize: 10, bold: true, color: C.tealLight, fontFace: "Calibri", margin: 0,
});
s.addText(pt[1], {
x: 2.7, y: 1.2 + i * 0.6 + 0.06, w: 6.9, h: 0.38,
fontSize: 10, color: C.offWhite, fontFace: "Calibri", margin: 0,
});
});
}
// ── Write file ────────────────────────────────────────────────────────────────
pres.writeFile({ fileName: "/home/daytona/workspace/anatomy-basics-pptx/Anatomy_Basics.pptx" })
.then(() => console.log("SUCCESS: /home/daytona/workspace/anatomy-basics-pptx/Anatomy_Basics.pptx"))
.catch((e) => { console.error("ERROR:", e); process.exit(1); });
cd /home/daytona/workspace/anatomy-basics-pptx && node build.js 2>&1
execSync has a 1MB stdout limit. I need to pre-save the images to disk first, then reference them by path in the script.cd /home/daytona/workspace/anatomy-basics-pptx && node -e " const { execSync } = require('child_process'); const fs = require('fs'); const urls = [ 'https://cdn.orris.care/cdss_images/892441b3b16b50336b6a3fa2859b2567057007f18b9ebd4aee82365b104b69be.png', 'https://cdn.orris.care/cdss_images/d1e862db9b089b138234c853dc1c4c5fbc695755445b78d469a000d755c99a7f.png', 'https://cdn.orris.care/cdss_images/4957a1e14023483530f3cba257927c5a6786df2827faea23230a4de825e46077.png' ]; const names = ['img_planes.png','img_joint.png','img_muscle.png']; urls.forEach((url, i) => { execSync(\`curl -sL \"\${url}\" -o /home/daytona/workspace/anatomy-basics-pptx/\${names[i]}\`); console.log('Saved', names[i], fs.statSync('/home/daytona/workspace/anatomy-basics-pptx/'+names[i]).size); }); " 2>&1
~/anatomy-basics-pptx/build.js
Successfully replaced 1 instance(s) of the string in '/home/daytona/workspace/anatomy-basics-pptx/build.js'
execSync import since it's no longer needed:~/anatomy-basics-pptx/build.js
Successfully replaced 1 instance(s) of the string in '/home/daytona/workspace/anatomy-basics-pptx/build.js'
cd /home/daytona/workspace/anatomy-basics-pptx && node build.js 2>&1
path: not data: when using local file paths). Let me fix the addImage calls — switch from data: to path::grep -n "addImage" /home/daytona/workspace/anatomy-basics-pptx/build.js
~/anatomy-basics-pptx/build.js
Successfully replaced 1 instance(s) of the string in '/home/daytona/workspace/anatomy-basics-pptx/build.js'
~/anatomy-basics-pptx/build.js
Successfully replaced 1 instance(s) of the string in '/home/daytona/workspace/anatomy-basics-pptx/build.js'
~/anatomy-basics-pptx/build.js
Successfully replaced 1 instance(s) of the string in '/home/daytona/workspace/anatomy-basics-pptx/build.js'
cd /home/daytona/workspace/anatomy-basics-pptx && node build.js 2>&1