chore: merge executor worktree (06-02 presets + i18n)
This commit is contained in:
@@ -0,0 +1,65 @@
|
||||
---
|
||||
phase: 06-preset-data-first-run-detection-and-db-safety
|
||||
plan: "02"
|
||||
subsystem: data
|
||||
tags: [presets, i18n, static-data]
|
||||
dependency_graph:
|
||||
requires: []
|
||||
provides: [PresetItem, PRESETS]
|
||||
affects: [src/data/presets.ts, src/i18n/en.json, src/i18n/de.json]
|
||||
tech_stack:
|
||||
added: []
|
||||
patterns: [static-data-module, i18n-dot-path]
|
||||
key_files:
|
||||
created:
|
||||
- src/data/presets.ts
|
||||
modified:
|
||||
- src/i18n/en.json
|
||||
- src/i18n/de.json
|
||||
decisions:
|
||||
- "item_tier restricted to fixed|variable only (no one_off) to match DB check constraint on template_items"
|
||||
- "presets.{type}.{slug} i18n key structure matches type+slug fields in PRESETS array"
|
||||
metrics:
|
||||
duration: "~5 minutes"
|
||||
completed: "2026-04-20"
|
||||
tasks_completed: 2
|
||||
files_changed: 3
|
||||
---
|
||||
|
||||
# Phase 06 Plan 02: Preset Data Library Summary
|
||||
|
||||
Static 19-item preset budget library with English and German translations, structured as `presets.{type}.{slug}` i18n keys matching the PRESETS array shape.
|
||||
|
||||
## Tasks Completed
|
||||
|
||||
| Task | Name | Commit | Files |
|
||||
|------|------|--------|-------|
|
||||
| 1 | Create src/data/presets.ts | 3bc7782 | src/data/presets.ts (created) |
|
||||
| 2 | Add preset translations to en.json and de.json | d235080 | src/i18n/en.json, src/i18n/de.json |
|
||||
|
||||
## What Was Built
|
||||
|
||||
`src/data/presets.ts` exports `PresetItem` interface and `PRESETS` array with exactly 19 items:
|
||||
- 4 income, 4 bill, 5 variable_expense, 2 debt, 2 saving, 2 investment
|
||||
- All `item_tier` values are `"fixed"` or `"variable"` (no `"one_off"`)
|
||||
- Pure static module — no Supabase or React imports
|
||||
|
||||
Both i18n files now have a top-level `"presets"` key with nested `{type}.{slug}` structure covering all 19 slugs in English and German.
|
||||
|
||||
## Deviations from Plan
|
||||
|
||||
None - plan executed exactly as written.
|
||||
|
||||
## Threat Surface Scan
|
||||
|
||||
No new network endpoints, auth paths, or trust boundaries introduced. T-06-05 (JSON malformed) mitigated — both files verified valid via `node -e "JSON.parse(...)"` before commit.
|
||||
|
||||
## Self-Check: PASSED
|
||||
|
||||
- src/data/presets.ts: FOUND
|
||||
- src/i18n/en.json "presets" key: FOUND
|
||||
- src/i18n/de.json "presets" key: FOUND
|
||||
- 19 PRESETS items confirmed (grep '{ slug:' returns 19)
|
||||
- no one_off in presets.ts confirmed
|
||||
- tsc --noEmit: PASSED
|
||||
- Commits 3bc7782 and d235080: confirmed in git log
|
||||
Reference in New Issue
Block a user