dbc.FormFeedback not working with type="number" dbc.Input

dbc.FormFeedback does not seem to work when used with number inputs. I am not getting any feedback message. I want dbc.FormFeedback to display a feedback message when the number entered in dbc.Input(type="number") is out of range.

  • dash version: 2.71
  • dash-bootstrap-components version: 1.2.1
  • components affected by bug: dbc.Input(type="number"), dbc.FormFeedback

Code

html.Div element with dbc.Input(type="number") and dbc.FormFeedback:

html.Div([
    dbc.Input(type="number", value=3, min=1, max=5, step=1, id='some-number'),
    dbc.FormFeedback(
        "Please enter a number between 1 and 5 (inclusive).",
        type="invalid",
        id='some-number-feedback'
    )
])

This is my dash callback function for the input:

@app.callback(
    Output('some-number', "valid"),
    Output('some-number', "invalid"),

    Input('some-number', "value"),
)
def check_validity(num):
    if val:
        in_range = num >= 1 and num <= 5
        return in_range, not in_range
    return False, False

Would appreciate any help!