Skip to content

Fix #7455: Decimal prevention in IntegerOnly and WithoutGrouping using numeric as reference in InputNumber#7868

Merged
melloware merged 2 commits intoprimefaces:masterfrom
Sumeet-2023:fix/decimal-value-prevention
Apr 7, 2025
Merged

Fix #7455: Decimal prevention in IntegerOnly and WithoutGrouping using numeric as reference in InputNumber#7868
melloware merged 2 commits intoprimefaces:masterfrom
Sumeet-2023:fix/decimal-value-prevention

Conversation

@Sumeet-2023
Copy link
Copy Markdown
Contributor

Defect Fixes

Fixes #7455

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Apr 7, 2025

Thanks a lot for your contribution! But, PR does not seem to be linked to any issues. Please manually link to an issue or mention it in the description using #<issue_id>.

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Apr 7, 2025

Thanks a lot for your contribution! But, PR does not seem to be linked to any issues. Please manually link to an issue or mention it in the description using #<issue_id>.

@Sumeet-2023 Sumeet-2023 changed the title fix(InputNumber): Decimal prevention in IntegerOnly and WithoutGrouping using numeric as reference Fix #7455: Decimal prevention in IntegerOnly and WithoutGrouping using numeric as reference in InputNumber Apr 7, 2025
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Apr 7, 2025

Thanks a lot for your contribution! But, PR does not seem to be linked to any issues. Please manually link to an issue or mention it in the description using #<issue_id>.

Comment thread components/lib/inputnumber/InputNumber.js
@vercel
Copy link
Copy Markdown

vercel Bot commented Apr 7, 2025

Deployment failed with the following error:

Creating the Deployment Timed Out.

@melloware
Copy link
Copy Markdown
Member

OK tested your change looks good

@melloware melloware merged commit 65e8792 into primefaces:master Apr 7, 2025
1 of 4 checks passed
@Sumeet-2023 Sumeet-2023 deleted the fix/decimal-value-prevention branch April 7, 2025 12:46
@codalf
Copy link
Copy Markdown

codalf commented May 8, 2025

Unfortunately, this fix breaks existing code and adds a new property inputMode which is not documented. Please revert.
With this change, decimal number are only posssble if the (undocumented) property 'inputMode' is set to something else than "numeric"

@Sumeet-2023
Copy link
Copy Markdown
Contributor Author

@codalf Hey!
Could you please elaborate more on what existing code got broken so that i can make necessary changes if necessary :)
This pull request that I created was made keeping in features that were requested in pull request #7233 and in issue #7455

@codalf
Copy link
Copy Markdown

codalf commented May 8, 2025

Hi @Sumeet-2023,
Please have a look at the issue #7977
There, I have added a reproducer. Basically, the default behavior has changed from allowing decimal numbers to not allowing them.
As an example you can take e.g. https://primereact.org/inputnumber/#prefixsuffix and compare the behavior with 10.9.5 and before.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

InputNumber: No possibility to prevent decimal values

3 participants