Skip to content

TP-06 — Map editor_colors to QueryaEditorTheme #101

Description

@ZhuchkaTriplesix

Epic: A
Depends on: TP-04

Source: docs/theme-parser-github-issues.md

Goal

Convert custom editor color tokens into QueryaEditorTheme.

Files

  • lib/core/theme/parser/querya_editor_theme_from_manifest.dart
  • test/core/theme/parser/querya_editor_theme_from_manifest_test.dart

Implementation

Add:

QueryaEditorTheme editorThemeFromQueryaColors({
  required Map<String, String> colors,
  required QueryaEditorTheme fallback,
});

Support keys matching current QueryaEditorTheme fields. At minimum:

  • background
  • foreground
  • selection
  • lineNumber
  • bracketMatch
  • widgetBorder

If QueryaEditorTheme has additional fields, include them explicitly.

Fallback:

  • missing/invalid key -> fallback field.

Acceptance Criteria

  • Full fixture changes editor background/foreground/selection.
  • Minimal fixture falls back for missing fields.
  • Invalid optional color does not crash.

Tests

  • full custom values;
  • fallback behavior;
  • invalid optional value.

Metadata

Metadata

Assignees

No one assigned

    Labels

    parserTheme parser epic label: parserthemeTheming, colors, VS Code themes

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions