Skip to content

Commit

Permalink
feat: support readonly property ThemeColor id
Browse files Browse the repository at this point in the history
fix #14404

contributed on behalf of STMicroelectronics

Signed-off-by: Remi Schnekenburger <[email protected]>
  • Loading branch information
rschnekenbu committed Nov 12, 2024
1 parent 1900a80 commit 74c1d61
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/core/src/common/theme.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ export interface ThemeChangeEvent {
}

export interface ThemeColor {
id: string;
readonly id: string;
}

export interface ThemeIcon {
Expand Down
2 changes: 1 addition & 1 deletion packages/plugin-ext/src/plugin/types-impl.ts
Original file line number Diff line number Diff line change
Expand Up @@ -725,7 +725,7 @@ export class SnippetString {

@es5ClassCompat
export class ThemeColor {
constructor(public id: string) { }
constructor(public readonly id: string) { }
}

@es5ClassCompat
Expand Down
5 changes: 5 additions & 0 deletions packages/plugin/src/theia.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2696,6 +2696,11 @@ export module '@theia/plugin' {
* Using a theme color is preferred over a custom color as it gives theme authors and users the possibility to change the color.
*/
export class ThemeColor {
/**
* The id of this color.
*/
readonly id: string;

/**
* Creates a reference to a theme color.
*/
Expand Down

0 comments on commit 74c1d61

Please sign in to comment.