-
Notifications
You must be signed in to change notification settings - Fork 2.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement missing API for vscode.typescript-language-features@1.62.3 #11083
Implement missing API for vscode.typescript-language-features@1.62.3 #11083
Conversation
@colin-grant-work I saw that there's a playwright test that consistently fails with this PR.
Looks like the selector for the notification indicator doesn't work anymore. |
I'll look into this once I'm back from vacation in mid May. |
@jfaltermeier, thanks for checking. I implemented a service that renders tooltips on status bar items as HTML elements rather than using the |
@colin-grant-work Thanks for the feedback! I think we currently use either icons or titles as selectors for notifications or status bar items in general. Originally, because there wasn't other metadata and it's the closest to what the user would use to identify a status bar item. But Thanks! |
The CQ opened for this pull-request has been approved 👍 |
9b7ae66
to
69f0381
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great! Works as expected and the vscode API is correctly supported as far as I can tell.
I have a few minor issues and a suggestion regarding the hover API that you introduced.
packages/core/src/browser/status-bar/status-bar-hover-manager.ts
Outdated
Show resolved
Hide resolved
packages/editor/src/browser/language-status/editor-language-status-service.ts
Outdated
Show resolved
Hide resolved
69f0381
to
3c6680c
Compare
3c6680c
to
fed00c9
Compare
@planger, I have added an |
Very nice! Thank you! You are certainly right, working with IDs makes the code much leaner. I think the use case for selecting by icons is rather uncommon for such rather static core elements, like status bar items. So I think only using the ID is completely fine for now. Thanks again! |
3d72edf
to
003b217
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll continue with a functional review, I only have some minor comments.
packages/editor/src/browser/language-status/editor-language-status-service.ts
Outdated
Show resolved
Hide resolved
} | ||
|
||
.hover-language-status>.element>.left>.detail:not(:empty)::before { | ||
/* endash */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I might be wrong but isn't it spelled like so: ;)
/* endash */ | |
/* en dash */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Compromise on en-dash
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, the changes look good to me!
- The updated versions of the typescript extensions start as expected
- Markdown rendered hovers behave as in vscode
- Status bar elements continue to work as expected
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The changes work well for me 👍
I confirmed that:
- existing statusbar items contributed by the framework look and work as expected
- the typescript-language-server builtin works without errors
- the
{ }
statusbar item looks good and works - the
{ }
pin/unpin functionality works - the
{ }
config file works
- the
- the contributed statusbar item works in markdown, icons are properly displayed
…feature/api-for-ts Conflicts: packages/plugin-ext/src/common/plugin-api-rpc.ts packages/plugin-ext/src/main/browser/languages-main.ts packages/plugin-ext/src/plugin/languages.ts packages/plugin-ext/src/plugin/plugin-context.ts packages/plugin/src/theia.d.ts
What it does
Fixes #11129 by updating the
MarkdownString
implementation available to plugins.Fixes #10819, fixes #10979, fixes #11036
This PR implements missing API required by recent versions of the TypeScript plugin. In particular:
LanguageStatusItem
and related API (vscode: supportcreateLanguageStatusItem
API #10979 & Supportvscode.LanguageStatusItem
#11036)TextDocumentChangeReason
How to test
TS Plugin Activation, Language Server
theia/plugins
folder.override
modifier andctrl+click
to go to the super method. Observe thatoverride
is not treated as a syntax error.Language Status Item (and HTML-element tooltips in StatusBar)
{}
) next to the language indicator.Markdown Rendering (MarkdownString in tooltips in StatusBar)
VSCode API: Show status item with Markdown tooltip
The gear should spin, and if you have an editor open as the current widget, clicking the link should trigger the 'save-as' action for that editor.
Review checklist
Reminder for reviewers