You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2022/03/10 10:40:16 UTC

[GitHub] [superset] michael-s-molina commented on pull request #19076: fix: allow to select in a native filter single mode

michael-s-molina commented on pull request #19076:
URL: https://github.com/apache/superset/pull/19076#issuecomment-1063910197


   > @michael-s-molina @geido could one of you approve this as codeowners?
   
   @rusackas Before approving this PR we need to discuss how are we going to deal with `null` values in the Select component. Right now, Select values don't accept a `null` value as you can see by checking Typescript constraints.
   
   ```
   export function getValue(option: string | number | { value: string | number }) {
     - return typeof option === 'object' ? option.value : option;
     + return option && typeof option === 'object' ? option.value : option;
   }
   ```
   
   This change, for instance, shouldn't be valid because `option` can only be a `string`, `number` or `object`. The problem is that in `FilterSelectPlugin` we have:
   
   ```
   <Select
      // @ts-ignore
      options={options}
   >
   ```
   
   I already talked to @geido about this we will schedule a meeting to discuss the best approach.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org