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

Aria-label missing for Cypress tests #34

Open
Zanda94 opened this issue May 18, 2023 · 2 comments
Open

Aria-label missing for Cypress tests #34

Zanda94 opened this issue May 18, 2023 · 2 comments

Comments

@Zanda94
Copy link

Zanda94 commented May 18, 2023

Good day @arnog - I hope you are well. I have been using this library for a while now and have no complaints, it has really been outstanding, thank you. I want to find out if the aria-label ([aria-label="math input field"]) has been removed from the math-field, as I use this for Cypress tests, and it can no longer find it anymore. Is there an alternative solution I can try if it has been removed? I am currently using the aria label to find the 'input' field and 'paste' latex mathematics in it to test some of my personal work.

@arnog
Copy link
Member

arnog commented May 18, 2023

Glad to hear you're enjoying the proeect.

The aria-label has been transitioned to an "element internals" attribute, so, it's visible by screen readers, but may not appear in the regular DOM.

Any reason why you couldn't use the tagName property, which should be "MATH-FIELD"? In Cypress, I believe you could use cy.get('math-field').

@Zanda94
Copy link
Author

Zanda94 commented May 20, 2023

Hi @arnog - Thanx for the fast reply - I can get it like that, but when I use the type API from Cypress, some of the LaTeX commands do not work properly- it keeps replacing the curly left brace with the command for it instead of it being part of the latex command being executed - for example, if I type \text{ - it converts this to \text\left\lbrace\right} as input? Is there perhaps a workaround or something I need to do to stop that from happening? I am also trying to type in formulas that make use of \frac and when a power has more than one therm to include the ^{term goes here} the same thing happens and the math looks horrible :-(
image
Then when you press enter you get this:
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants