diskFile is the v4 envelope. v3 fields (TextMode, Notes, Strings, Zoom, HighlightColor) are kept here as optional fallbacks — when a v3 file is loaded, those fields are wrapped into a single board.
| 19 | // HighlightColor) are kept here as optional fallbacks — when a v3 file is |
| 20 | // loaded, those fields are wrapped into a single board. |
| 21 | type diskFile struct { |
| 22 | SchemaVersion int `json:"schemaVersion"` |
| 23 | ActiveIdx int `json:"activeIdx,omitempty"` |
| 24 | Background *Background `json:"background,omitempty"` |
| 25 | Boards []*Board `json:"boards,omitempty"` |
| 26 | |
| 27 | // Legacy v3 fields — read on load, never written. |
| 28 | LegacyTextMode TextStyleMode `json:"textMode,omitempty"` |
| 29 | LegacyZoom int `json:"zoom,omitempty"` |
| 30 | LegacyHighlightColor int `json:"highlightColor,omitempty"` |
| 31 | LegacyNotes []*Note `json:"notes,omitempty"` |
| 32 | LegacyStrings []*StringConn `json:"strings,omitempty"` |
| 33 | } |
| 34 | |
| 35 | func DataPath() (string, error) { |
| 36 | var dir, legacyDir string |
nothing calls this directly
no outgoing calls
no test coverage detected