Bug reportSep 18, 2026· 0:31· 1 views
PrimeNG InputNumber: pressing Enter with selected text resets value to 0
0:31 total
Comments · 0
Be the first to comment.
Bug report— by SceneRecap AI
mediumcomponents/inputnumber
os: macOSbrowser: Chromium 151.0.7922.34viewport: 1280x720
Repro steps
- 1.Navigate to the PrimeNG InputNumber documentation page (/inputnumber).
- 2.Scroll down to the 'Currency' demo section.
- 3.Click the 'United States' currency input field and enter a value (e.g., $42.00).
- 4.Select all text within the input field using Ctrl+A.
- 5.Press Enter.
Expected
The InputNumber component should retain the current value ($42.00) or submit the selected value without clearing/resetting to zero.
Actual
The InputNumber component resets its formatted value to $0.00 upon pressing Enter when all text is selected.
Evidence
visualUnited States currency input unexpectedly shows $0.00 after pressing Enter on highlighted text.
visualControl case: entering $100.00 and pressing Enter without full text selection commits and preserves the value properly.
Issue markdown (copy-paste ready)
### Summary When editing a currency input in PrimeNG's `InputNumber` component, selecting all text (`Ctrl+A`) and pressing `Enter` causes the value to reset to `$0.00` instead of retaining or committing the highlighted value. ### Steps to Reproduce 1. Open the PrimeNG InputNumber component demo page (`/inputnumber`) [0.0s]. 2. Scroll to the **Currency** demo section [5.0s]. 3. Click the **United States** input field and type `$42.00` [6.6s - 9.0s]. 4. Highlight the input value using `Ctrl+A` [13.7s]. 5. Press `Enter` [15.1s]. ### Expected Result The input value should stay as `$42.00` or confirm the existing numeric value. ### Actual Result The input resets to `$0.00` [17.0s]. ### Control Observation Typing `$100.00` and pressing `Enter` normally without text selection properly preserves the value as `$100.00` [25.0s - 29.0s]. *Recorded with SceneRecap.*
Your recordings could explain themselves too.
Free plan · silent recordings welcome · bug reports included.
Try SceneRecap free →