Fix: add data boundaries to spectrum pan + bump cache versions

The spectrum chart was missing xMin/xMax persistence and data boundary
clamping in enablePan(). Align with the background/cps chart patterns.
Bump cache versions to force browser refresh.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
Jacquin Antoine
2026-05-20 00:50:56 +02:00
parent c764a5c264
commit 6c78c13622
7 changed files with 225 additions and 23 deletions

View File

@ -0,0 +1,75 @@
{
"default": "radiacode103",
"detectors": {
"radiacode103": {
"name": "Radiacode 103",
"scintillator": "CsI(Tl)",
"energy_kev": { "min": 30, "max": 3000 },
"channels": 1024,
"calibration": { "offset": 0.33, "slope": 2.97 },
"fwhm_at_662": 8.4,
"sensitivity": "30 cps / 1 uSv/h (Cs-137)",
"display": {
"zoom_limits_x": { "min": 30, "max": 3000 },
"default_log_scale": true,
"default_smooth": true
}
},
"csi50": {
"name": "CsI 50x50mm",
"scintillator": "CsI(Tl)",
"energy_kev": { "min": 20, "max": 3000 },
"channels": 1024,
"calibration": { "offset": 0, "slope": 3.0 },
"fwhm_at_662": 7.0,
"sensitivity": "—",
"display": {
"zoom_limits_x": { "min": 20, "max": 3000 },
"default_log_scale": true,
"default_smooth": true
}
},
"naicl": {
"name": "NaI(Tl)",
"scintillator": "NaI(Tl)",
"energy_kev": { "min": 20, "max": 3000 },
"channels": 1024,
"calibration": { "offset": 0, "slope": 3.0 },
"fwhm_at_662": 7.0,
"sensitivity": "—",
"display": {
"zoom_limits_x": { "min": 20, "max": 3000 },
"default_log_scale": true,
"default_smooth": true
}
},
"hpge": {
"name": "HPGe",
"scintillator": "Ge (semiconductor)",
"energy_kev": { "min": 5, "max": 6000 },
"channels": 4096,
"calibration": { "offset": 0, "slope": 1.5 },
"fwhm_at_662": 1.8,
"sensitivity": "—",
"display": {
"zoom_limits_x": { "min": 5, "max": 6000 },
"default_log_scale": true,
"default_smooth": false
}
},
"lacl": {
"name": "LaBr3(Ce)",
"scintillator": "LaBr₃:Ce",
"energy_kev": { "min": 20, "max": 3500 },
"channels": 2048,
"calibration": { "offset": 0, "slope": 1.7 },
"fwhm_at_662": 3.5,
"sensitivity": "—",
"display": {
"zoom_limits_x": { "min": 20, "max": 3500 },
"default_log_scale": true,
"default_smooth": false
}
}
}
}