Skip to content

feat(settings): Schema foundation + Editor/General settings #63

@tomymaritano

Description

@tomymaritano

Summary

Implement the settings infrastructure and core settings (Editor + General).

Reference: Inkdrop settings UI

Tasks

Phase 0: Schema Foundation

  • Create stores/settings/schema.ts (types + defaults + version)
  • Create stores/settings/settingsStore.ts (persist + migrate)
  • Export selectors for each section

Phase 1: MVP

  • Build reusable components: SettingRow, Toggle, Select, NumberInput
  • Implement EditorSection.tsx
  • Wire editor settings to CodeMirror
  • Implement GeneralSection.tsx (default notebook, open folder)
  • Update sidebar with new sections

Architecture

3-layer separation:

  1. Schema - Data model with versioning (SETTINGS_VERSION = 1)
  2. Store - Zustand persist with migrate function
  3. UI - Reusable components consuming store

Editor Settings

Setting Type Default
Line Numbers checkbox false
Highlight Active Line checkbox false
Line Wrapping checkbox true
Inline Image Widgets checkbox true
Scroll Past End checkbox true
Font Size number 14
Font Family text system-ui, monospace
Line Height number 1.6
Tab Size number 2
Indent with Tabs checkbox false

General Settings

Setting Type Default
Default Notebook dropdown Inbox
Open Data Folder button -

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions