diff --git a/public/audio/respiratory/normal-vesicular.ogg b/public/audio/respiratory/normal-vesicular.ogg new file mode 100644 index 0000000..e8b044f Binary files /dev/null and b/public/audio/respiratory/normal-vesicular.ogg differ diff --git a/public/audio/respiratory/pleural-rub.ogg b/public/audio/respiratory/pleural-rub.ogg new file mode 100644 index 0000000..64ada22 Binary files /dev/null and b/public/audio/respiratory/pleural-rub.ogg differ diff --git a/public/audio/respiratory/rhonchi.ogg b/public/audio/respiratory/rhonchi.ogg new file mode 100644 index 0000000..8f4af59 Binary files /dev/null and b/public/audio/respiratory/rhonchi.ogg differ diff --git a/public/index.html b/public/index.html index d716dc7..fa46a96 100644 --- a/public/index.html +++ b/public/index.html @@ -447,7 +447,6 @@ - diff --git a/public/js/peGuide.js b/public/js/peGuide.js index 2155e9b..e3346a7 100644 --- a/public/js/peGuide.js +++ b/public/js/peGuide.js @@ -247,11 +247,10 @@ // ──────────────────────────────────────────────────────────── // RESPIRATORY SOUNDS LIBRARY // ──────────────────────────────────────────────────────────── - // Each entry maps to a key in window.RespSounds (respiratorySounds.js). // Displayed as a dedicated card at the top of the Respiratory system. - // src = real recording path; if absent, the player falls back to synthesis + // src = real recording path served from /public/audio/respiratory/. var RESP_SOUNDS = [ - { key: 'normal', src: null, title: 'Normal vesicular breath sounds', + { key: 'normal', src: '/audio/respiratory/normal-vesicular.ogg', title: 'Normal vesicular breath sounds', where: 'Peripheral lung fields', features: 'Soft, rustling. Inspiration louder and longer than expiration.', clinical: 'Baseline — deviation elsewhere is what you listen for.' }, @@ -271,18 +270,14 @@ where: 'Lower lobes; either side', features: 'Discontinuous, longer and louder than fine crackles. Lower-pitched. Can be early or late inspiratory; often clear partly with cough.', clinical: 'Secretions in larger airways — bronchitis, later pneumonia, bronchiectasis, aspiration.' }, - { key: 'rhonchi', src: null, title: 'Rhonchi', + { key: 'rhonchi', src: '/audio/respiratory/rhonchi.ogg', title: 'Rhonchi', where: 'Central or anywhere with airway secretions', features: 'Continuous, low-pitched, snore-like. Typically expiratory. Clear or change with cough.', clinical: 'Large-airway secretions — bronchitis, pneumonia with large-airway involvement, cystic fibrosis, bronchiectasis.' }, - { key: 'pleuralrub', src: null, title: 'Pleural friction rub', + { key: 'pleuralrub', src: '/audio/respiratory/pleural-rub.ogg', title: 'Pleural friction rub', where: 'Focal, often lateral or posterior lower chest', features: 'Grating, creaky — "leather on leather". Biphasic (heard in inspiration and expiration). Does NOT clear with cough.', - clinical: 'Pleural inflammation — pleuritis, pulmonary embolism, pneumonia with pleural involvement, viral pleurisy.' }, - { key: 'grunting', src: null, title: 'Expiratory grunting', - where: 'Audible without stethoscope in infants', - features: 'Short, low-pitched sound at the end of each expiration. Physiologic PEEP against a partially closed glottis.', - clinical: 'Sign of significant respiratory distress in an infant — RDS, pneumonia, sepsis, congenital heart disease with heart failure.' } + clinical: 'Pleural inflammation — pleuritis, pulmonary embolism, pneumonia with pleural involvement, viral pleurisy.' } ]; // ──────────────────────────────────────────────────────────── @@ -1252,7 +1247,7 @@ { label: 'Listen for rhonchi', method: 'Low-pitched, continuous, snore-like. Often change with cough. Use the "Rhonchi" sample.', normal: 'No rhonchi' }, { label: 'Listen for pleural rub', method: 'Grating, creaky, biphasic, does NOT clear with cough. Use the "Pleural rub" sample.', normal: 'No pleural rub' }, { label: 'Listen at the neck (for stridor)', method: 'Place stethoscope over the anterior neck. Stridor is loudest here and differentiates from wheeze (loudest over chest). Use the "Stridor" sample.', normal: 'No stridor' }, - { label: 'Listen for expiratory grunting (infants)', method: 'Often audible without a stethoscope at the bedside. Use the "Grunting" sample.', normal: 'No grunting' }, + { label: 'Listen for expiratory grunting (infants)', method: 'Often audible without a stethoscope at the bedside — short, low-pitched sound at the end of each expiration (glottal closure against exhaled air).', normal: 'No grunting' }, { label: 'Cough re-listen', method: 'Have patient cough forcefully; re-listen to any abnormal area. Note if the sound clears or changes.', normal: 'Any secretion-based sound should clear or change with cough' } ], abnormalHints: ['Wheeze — asthma, bronchiolitis, foreign body (localised), anaphylaxis', 'Fine crackles — pulmonary edema, interstitial lung disease, early pneumonia', 'Coarse crackles — bronchitis, pneumonia, bronchiectasis, aspiration', 'Rhonchi — large-airway secretions', 'Pleural rub — pleurisy, PE, pneumonia with pleural involvement', 'Stridor — upper airway obstruction (croup, epiglottitis, FB)'] }, @@ -1398,16 +1393,7 @@ // free on all platforms incl. mobile). Falls back to a synth play button // when the sound has no real recording. function renderSoundCard(s) { - var isReal = !!s.src; - var player = isReal - ? '' - : '
' + - '' + - '' + - '
' + - '
' + - '
' + - '
'; + var player = ''; var html = ''; html += '
'; html += '
' + esc(s.title) + '
'; @@ -1612,64 +1598,12 @@ if (state[key]) state[key].note = inp.value; }); }); - // ── Single-playback policy: only one sound at a time across the whole - // ── page. When any