Skip to content

ts plugin provide color #61773

Closed as not planned
Closed as not planned
@mantou132

Description

@mantou132

πŸ” Search Terms

ls, plugin, color

βœ… Viability Checklist

⭐ Suggestion

typescript LanguageService add provideDocumentColors:

interface LanguageService {
  ...
  provideDocumentColors: (fileName: string) => ColorInformation[]
}

interface ColorInformation {
    range: Range;
    color: Color;
}

πŸ“ƒ Motivating Example

Provide color for documents in ts plugin, not relying on LSP/Editor, e.g: Zed

πŸ’» Use Cases

  1. ts-gem-plugin css color
  2. typescript-lit-html-plugin css color

Metadata

Metadata

Assignees

No one assigned

    Labels

    Out of ScopeThis idea sits outside of the TypeScript language design constraintsSuggestionAn idea for TypeScript

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions