[PR #1868] [MERGED] Fix: Prevent 'NumpadDecimal' Key When isInteger is True #2940

Closed
opened 2026-01-29 18:21:12 +00:00 by claunia · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/radzenhq/radzen-blazor/pull/1868
Author: @aibutler
Created: 12/19/2024
Status: Merged
Merged: 12/19/2024
Merged by: @enchev

Base: masterHead: fix-numpaddecimal-isinteger-bug


📝 Commits (1)

  • d738900 Prevent decimal insertion in integer-only fields

📊 Changes

1 file changed (+1 additions, -1 deletions)

View changed files

📝 Radzen.Blazor/wwwroot/Radzen.Blazor.js (+1 -1)

📄 Description

This pull request addresses a bug where the numericKeyPress function did not correctly handle the 'NumpadDecimal' key when isInteger is true. The updated function now includes a condition to prevent the 'NumpadDecimal' key from being allowed if isInteger is true.

Changes Made

  • Added a condition to check if isInteger is true before handling the 'NumpadDecimal' key.
  • If isInteger is true, the function will not allow the 'NumpadDecimal' key.

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/radzenhq/radzen-blazor/pull/1868 **Author:** [@aibutler](https://github.com/aibutler) **Created:** 12/19/2024 **Status:** ✅ Merged **Merged:** 12/19/2024 **Merged by:** [@enchev](https://github.com/enchev) **Base:** `master` ← **Head:** `fix-numpaddecimal-isinteger-bug` --- ### 📝 Commits (1) - [`d738900`](https://github.com/radzenhq/radzen-blazor/commit/d7389001c6155c47bf91c2fcc6cdba9052706da9) Prevent decimal insertion in integer-only fields ### 📊 Changes **1 file changed** (+1 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `Radzen.Blazor/wwwroot/Radzen.Blazor.js` (+1 -1) </details> ### 📄 Description This pull request addresses a bug where the `numericKeyPress` function did not correctly handle the `'NumpadDecimal'` key when `isInteger` is `true`. The updated function now includes a condition to prevent the `'NumpadDecimal'` key from being allowed if `isInteger` is `true`. **Changes Made** - Added a condition to check if `isInteger` is `true` before handling the `'NumpadDecimal'` key. - If `isInteger` is `true`, the function will not allow the `'NumpadDecimal'` key. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
claunia added the pull-request label 2026-01-29 18:21:12 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/radzen-blazor#2940