Skip to content
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

CodeLens page object only supports one CodeLense per row/group #68

Open
jeffb-sfdc opened this issue Mar 21, 2023 · 1 comment
Open
Labels
help wanted Extra attention is needed

Comments

@jeffb-sfdc
Copy link
Contributor

jeffb-sfdc commented Mar 21, 2023

Our extension implements a few code lenses, and most of our code lens providers emit two code lenses per provider.

(eg a single row with "Run code | Debug code")

(also, for clarity, I'm referring to each link ("Run code" or "Debug code") as a separate code lens, not "Run code | Debug code" as a single code lens)

The CodeLens class (in TextEditor.ts) only returns the first anchor tag when getText() is called. This is because elem.$('a') is called instead of elem.$$('a'), and the page object definition for a CodeLens assumes there is only one code lens in the code lens's container.

    async getText (): Promise<string> {
        const link = await this.elem.$('a')
        return link.getText()
    }
@jeffb-sfdc jeffb-sfdc changed the title CodeLens only support one CodeLense per line CodeLens page object only supports one CodeLense per line Mar 21, 2023
@jeffb-sfdc jeffb-sfdc changed the title CodeLens page object only supports one CodeLense per line CodeLens page object only supports one CodeLense per row/group Mar 21, 2023
@christian-bromann
Copy link
Contributor

Thanks for reporting!

Any contributions that resolves the bug are highly appreciated. Don't expect this to be picked up by active contributors as they have their own priorities. If you depend on this bug to be fixed, your contribution is required. Please take a look into our contribution guidelines or join our Discord development server and let us know if you have any questions. Cheers!

@christian-bromann christian-bromann added the help wanted Extra attention is needed label Apr 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants