Skip to content

feat: adds config editor symbol support - #1701

Merged
pedrolamas merged 1 commit into
fluidd-core:developfrom
pedrolamas:pedrolamas/config-go-to-symbol-monaco
Aug 10, 2025
Merged

feat: adds config editor symbol support#1701
pedrolamas merged 1 commit into
fluidd-core:developfrom
pedrolamas:pedrolamas/config-go-to-symbol-monaco

Conversation

@pedrolamas

Copy link
Copy Markdown
Member

This pull request enhances the Monaco editor integration for klipper-config files by adding improved symbol navigation and document structure awareness. The main changes introduce a document symbol provider to support outline and symbol navigation features, and ensure the necessary Monaco quick access functionality is included.

Monaco Editor Feature Enhancements:

  • Added import for standaloneGotoSymbolQuickAccess.js to enable symbol navigation (e.g., "Go to Symbol") in the Monaco editor.

klipper-config Language Support:

  • Registered a document symbol provider for klipper-config files, allowing the editor to display sections and properties in the outline view and support symbol navigation. This groups lines into sections (as namespaces) and properties (as child symbols), improving code navigation and structure visibility.

Klipper config editor showing "Go to symbol" menu

image

Signed-off-by: Pedro Lamas <pedrolamas@gmail.com>
@pedrolamas pedrolamas added this to the 1.34.4 milestone Aug 10, 2025
@pedrolamas pedrolamas added the FR - Enhancement New feature or request label Aug 10, 2025
@pedrolamas
pedrolamas requested a review from Copilot August 10, 2025 20:02

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This pull request enhances the Monaco editor integration for Klipper configuration files by adding document symbol provider support and symbol navigation capabilities. The changes enable users to navigate through configuration sections and properties using Monaco's outline view and "Go to Symbol" functionality.

Key Changes:

  • Added Monaco quick access functionality for symbol navigation
  • Implemented a document symbol provider for klipper-config files that parses sections and properties
  • Enhanced code navigation by organizing configuration structure into hierarchical symbols

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
src/components/widgets/filesystem/setupMonaco.features.ts Imports standaloneGotoSymbolQuickAccess module to enable symbol navigation features
src/components/widgets/filesystem/setupMonaco.ts Registers document symbol provider for klipper-config language with section and property parsing logic

Comment thread src/components/widgets/filesystem/setupMonaco.ts
Comment thread src/components/widgets/filesystem/setupMonaco.ts
@pedrolamas
pedrolamas merged commit f731cf2 into fluidd-core:develop Aug 10, 2025
4 checks passed
@pedrolamas
pedrolamas deleted the pedrolamas/config-go-to-symbol-monaco branch August 10, 2025 22:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

FR - Enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants