-
Notifications
You must be signed in to change notification settings - Fork 3.8k
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
[Bug]: Method .fill does not accept type number. #33623
Comments
The bug reports you were referring to were about accepting numbers typing-wise while the issue in your scenario is different. The custom element doesn't listen on the It only listens on it('should work', async ({ page, server }) => {
await page.goto('https://primevue.org/inputnumber/');
await page.getByLabel('Integer Only').focus();
await page.keyboard.press('Meta+A');
await page.keyboard.press('Backspace');
await page.getByLabel('Integer Only').pressSequentially('987654321');
}); Note: We recommend listening on I also found an issue that Inspector controls only showed up sometimes when opening Codegen, this will be fixed with #33627. When interacting with the page Codegen didn't work for me because they call |
Closing as per above. If you still encounter problems, please file a new issue by filling in the "Bug Report" template and link to this one. |
@mxschmitt I was on the wrong track. Many thanks for pointing this out. I did not realize that the custom element does not listen on the input event. |
Version
1.48.2
Steps to reproduce
This problem has already been addressed elsewhere but not resolved. It is only unclear to me why the .fill() method does not accept the type number.
As you can see here: Input Number -> such an element should only accept numeric values.
Now to my specific problem:
We are using Vue with PrimeVue and PrimeVue provides the following component for InputFields with only numeric values: InputNumber PrimeVue
The following leads to a problem:
Assuming foo is the locator for the input field, then
foo.fill('123')
-> primeVue turns this into a0
, as strings is not allowed here.foo.fill(123) will throw an error since it can only accept strings
Here are some issues that describe exactly the same thing:
#16660
#33200
#28671
Expected behavior
I expect that fill should also allow numeric values
Actual behavior
fill() does not allow numeric values
Additional context
No response
Environment
The text was updated successfully, but these errors were encountered: