mirror of
https://github.com/maziggy/bambuddy.git
synced 2026-10-06 06:02:05 +02:00
fix(labels): replace incorrect ams_30x15 preset with correct AMS holder sizes (#1426)
Reporter — the same person who originally requested the labels feature in #809 — discovered that the ams_30x15 preset's 30x15 mm dimension didn't actually fit any variant of the MakerWorld AMS Filament Label Holder (model 752566) it advertised. Two new presets replace it: - ams_holder_74x33 (74 x 33 mm) matches the printable label STL bundled in the MakerWorld project - ams_holder_75x55 (75 x 55 mm) fits the cardstock-insert variant the reporter validated on bench Both cross the 20 mm height threshold so they land in the roomy layout branch — swatch on the left, QR on the right, multi-line text (brand, material, hex code, spool ID) in the middle. The old 30x15 mm preset couldn't fit a QR code; the new ones do. No DB migration: the preset name was never persisted. Callers scripting the old ams_30x15 value get a clean 422 at the route's Literal validator with the new valid values listed. i18n: replaced inventory.labels.templates.ams.{label,hint} with amsHolderSmall and amsHolderLarge across all 8 locales with real translations; parity guard cleaned of the stale English-fallback cognate entries. Parity holds at 4856 leaves per locale. Tests: backend label renderer + integration tests cover both new presets; LabelTemplatePickerModal test updated for the 6-button grid and the new template value in the API-call assertion.
This commit is contained in:
@@ -33,10 +33,16 @@ interface TemplateOption {
|
||||
|
||||
const TEMPLATE_OPTIONS: TemplateOption[] = [
|
||||
{
|
||||
value: 'ams_30x15',
|
||||
i18nKey: 'ams',
|
||||
fallbackLabel: 'AMS holder (30 × 15 mm)',
|
||||
fallbackHint: 'Single label per page; fits the popular AMS filament label holder.',
|
||||
value: 'ams_holder_74x33',
|
||||
i18nKey: 'amsHolderSmall',
|
||||
fallbackLabel: 'AMS holder — small (74 × 33 mm)',
|
||||
fallbackHint: 'Single label per page; matches the printable label from MakerWorld model 752566 (AMS Filament Label Holder).',
|
||||
},
|
||||
{
|
||||
value: 'ams_holder_75x55',
|
||||
i18nKey: 'amsHolderLarge',
|
||||
fallbackLabel: 'AMS holder — large (75 × 55 mm)',
|
||||
fallbackHint: 'Single label per page; fits the cardstock-insert variant of the AMS Filament Label Holder. Roomy enough for swatch, brand, material, ID, and QR code.',
|
||||
},
|
||||
{
|
||||
value: 'box_40x30',
|
||||
|
||||
Reference in New Issue
Block a user