metabase / metabase/metabase

FormCategoryInput does not allow you to remove values

Open
#27,377 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Clojure
Stars
49.3k
Forks
6.8k
Avg merge
1d 13h
Merged PRs (30d)
653

Description

I think there is some incompatibility with the text input version of this component in formik, if you remove a value form the input, formik completely deletes the data field instead of setting it empty(see `item_class` in the screenshot). 😱

![Screen Shot 2022-12-21 at 4 49 35 PM](https://user-images.githubusercontent.com/30528226/209024752-0505f227-fd65-4d90-8b10-6640479eab13.png)

Update: needs to support the `nullable` prop

Contributor guide

Open the contributing guide

Research direction

Start by locating the FormCategoryInput component and its Formik integration, then reproduce removing a value from the input. Check how the field value changes, including when the nullable prop is used; done means removing a value preserves the data field with the expected empty or null value.

Written by the indexing model from the issue text.

Assessment

Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
28/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.