detail
Real gap found (not the previous _recipeData bug -- this was a genuinely missing feature): the recipes.html edit form only ever had fields for title/notes/user_notes/status -- there was NO field to edit a recipe's directions (steps) at all, confirmed via full-file review of the edit-form HTML. USR369 hit this directly: 'no place to click edit to change the directions.' FIX: added a Directions textarea (data-field='steps') to the edit form, between Title and Notes. toggleEdit() now populates it from parseSteps(r.steps) joined as plain text (one step per line, reusing the existing parseSteps() display helper). saveEdit() now special-cases the steps field: splits the textarea back into lines, strips any leading '1.' numbering, and rebuilds the {text:...} JSON array format before sending to update_recipe -- other fields (title/notes/user_notes/status) still send as plain values same as before. ALSO clarified via conversation: USR369's 'notes disappear' complaint traces back to the DoughCalc 'Save to bake log' button (still unchanged, separate feature) writing a standalone bake-note item, never touching the recipe's own notes field -- this was found and reported several turns ago but a fix for THAT specific disconnect was not yet built/requested; the new DoughCalc 'Save as Recipe' feature (D960) is the intended path for pushing directions/ingredients into a recipe, Bake Notes remains a separate quick-journal feature per USR369's own 'build separately for now' direction. Backed up recipes.html first (BACKUP.php all_pass true). Probe-tested the exact new steps-save code path directly against the live API (update_recipe with a test steps value) before deploying the UI, then again after deploy to confirm end-to-end, restored recipe #26's real content both times. Real node --check syntax validation passed on the extracted script block.