techsbcn-storybook 0.9.0 → 0.9.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -10,6 +10,7 @@ interface SelectAsyncFieldProps {
10
10
  disabled?: boolean;
11
11
  onChange?: (value: number, name: string) => void;
12
12
  onChangeValue?: (value: number) => void;
13
+ onChangeOption?: (value: number, label: string) => void;
13
14
  searchPromise: (filters: SearchFilters) => Promise<any>;
14
15
  invalid?: boolean;
15
16
  isClearable?: boolean;
@@ -1924,6 +1924,11 @@ var SelectAsyncField = function SelectAsyncField(props) {
1924
1924
  props.onChangeValue && props.onChangeValue(option && option.length > 0 ? option.map(function (o) {
1925
1925
  return o.value;
1926
1926
  }) : option ? option.value : option);
1927
+ props.onChangeOption && props.onChangeOption(option && option.length > 0 ? option.map(function (o) {
1928
+ return o.value;
1929
+ }) : option ? option.value : option, option && option.length > 0 ? option.map(function (o) {
1930
+ return o.label;
1931
+ }) : option ? option.label : option);
1927
1932
  },
1928
1933
  selectRef: props.inputRef,
1929
1934
  isDisabled: props.disabled,