react-number-format icon indicating copy to clipboard operation
react-number-format copied to clipboard

How to create a similar money input?

Open Nazar-D-Aleannlab opened this issue 1 year ago • 0 comments

Describe the issue and the actual behavior

This is my actual code that I'm using now and after I put the cursor at the end I can't enter anything, how can I get around it?

<NumericFormat
          prefix="$"
          value={formik.values.value || '00.00'}
          error={!!formik.errors.value}
          onValueChange={handleChange}
          valueIsNumericString={true}
          wrapperInput={styles.numberFormat}
          decimalScale={2}
          fixedDecimalScale={true}
          disabled={!isCustomAmount}
          allowLeadingZeros={true}
          isAllowed={({ floatValue }) => {
            return (
              floatValue === undefined || +floatValue < MAX_LIMIT_PAYMENT_PLAN
            );
          }}
          classes={{
            root: clsx(styles.inputPaymentPlan, {
              [styles.statementAmount]: !isCustomAmount,
            }),
            input: styles.inputSum,
            underline: styles.underlineHide,
          }}
          variant="standard"
          customInput={CustomInput}
        />

Describe the expected behavior

I expect that after the course is set at the end it will be possible to enter the amount

Provide a CodeSandbox link illustrating the

https://github.com/s-yadav/react-number-format/assets/105917929/8f71d178-6d80-43dc-8541-90e91ff660f9

issue

Nazar-D-Aleannlab avatar Oct 20 '23 15:10 Nazar-D-Aleannlab