sapo-components-ui-rn 1.0.18 → 1.0.19

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.
@@ -12,6 +12,7 @@ interface SearchInputProps {
12
12
  onFocus?: () => void;
13
13
  onBlur?: () => void;
14
14
  onChangeText?: (text: string) => void;
15
+ height?: number;
15
16
  }
16
- declare const SearchInput: ({ value, disabled, rightIcon, clearButton, placeholder, onFocus, onBlur, onChangeText, style, }: SearchInputProps) => React.JSX.Element;
17
+ declare const SearchInput: ({ value, disabled, rightIcon, clearButton, placeholder, onFocus, onBlur, onChangeText, style, height, }: SearchInputProps) => React.JSX.Element;
17
18
  export default SearchInput;
package/dist/index.esm.js CHANGED
@@ -5618,7 +5618,11 @@ var TextInputDefault = function (_a) {
5618
5618
  ? textAlign
5619
5619
  : I18nManager.getConstants().isRTL
5620
5620
  ? "right"
5621
- : "left", height: height ? height : 48 }),
5621
+ : "left", height: height ? height : 48, paddingTop: Platform.OS === "android"
5622
+ ? multiline
5623
+ ? CONSTANTS.SPACE_2
5624
+ : CONSTANTS.SPACE_8
5625
+ : CONSTANTS.SPACE_4 }),
5622
5626
  contentStyle,
5623
5627
  ] }))),
5624
5628
  !disabled && clearButton && inputValue ? (React$3.createElement(TouchableOpacity, { onPress: handleClear, style: multiline ? styles$a.clearButtonMultiline : styles$a.clearButton },
@@ -6815,15 +6819,16 @@ var styles = StyleSheet.create(__assign(__assign({}, containerStyles), { disable
6815
6819
  var index = React__default.memo(SelectionField);
6816
6820
 
6817
6821
  var SearchInput = function (_a) {
6818
- var _b = _a.value, value = _b === void 0 ? "" : _b, _c = _a.disabled, disabled = _c === void 0 ? false : _c, rightIcon = _a.rightIcon, _d = _a.clearButton, clearButton = _d === void 0 ? false : _d, _e = _a.placeholder, placeholder = _e === void 0 ? "Tìm kiếm" : _e, onFocus = _a.onFocus, onBlur = _a.onBlur, onChangeText = _a.onChangeText, style = _a.style;
6822
+ var _b = _a.value, value = _b === void 0 ? "" : _b, _c = _a.disabled, disabled = _c === void 0 ? false : _c, rightIcon = _a.rightIcon, _d = _a.clearButton, clearButton = _d === void 0 ? false : _d, _e = _a.placeholder, placeholder = _e === void 0 ? "Tìm kiếm" : _e, onFocus = _a.onFocus, onBlur = _a.onBlur, onChangeText = _a.onChangeText, style = _a.style, height = _a.height;
6819
6823
  return (React__default.createElement(TextInput, { left: React__default.createElement(View, { paddingRight: SPACE_8 },
6820
- React__default.createElement(Icon$1, { name: "IconSearch", type: "Svg", size: 24 })), disabled: disabled, value: value, clearButton: clearButton, mode: "default", placeholder: placeholder, right: rightIcon, onFocus: onFocus, onBlur: onBlur, allowFontScaling: false, onChangeText: onChangeText, contentStyle: [
6824
+ React__default.createElement(Icon$1, { name: "IconSearch", type: "Svg", size: 24 })), disabled: disabled, value: value, clearButton: clearButton, mode: "default", placeholder: placeholder, right: rightIcon, onFocus: onFocus, onBlur: onBlur, allowFontScaling: false, onChangeText: onChangeText, style: [
6821
6825
  {
6822
- height: 40,
6826
+ height: height || 40,
6823
6827
  },
6824
6828
  style,
6825
6829
  ] }));
6826
6830
  };
6831
+ StyleSheet.create(__assign({}, containerStyles));
6827
6832
 
6828
6833
  var toastRef = React__default.createRef();
6829
6834
  var showToast = function (_a) {