sapo-components-ui-rn 1.0.62 → 1.0.63

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 @@ export type Props = React.ComponentPropsWithRef<typeof NativeTextInput> & {
12
12
  maxValue?: number;
13
13
  type?: "integer" | "float";
14
14
  formatDecimal?: 1 | 2 | 3;
15
+ required?: boolean;
15
16
  /**
16
17
  * If true, user won't be able to interact with the component.
17
18
  */
@@ -1,4 +1,4 @@
1
1
  import * as React from "react";
2
2
  import type { ChildTextInputProps } from "./types";
3
- declare const TextInputDefault: ({ disabled, editable, label, error, selectionColor: customSelectionColor, cursorColor, outlineColor: customOutlineColor, activeOutlineColor, outlineStyle, textColor, dense, style, theme, render, multiline, parentState, innerRef, onFocus, forceFocus, onBlur, onChangeText, onLayout, left, right, placeholderTextColor, clearButton, contentStyle, value, textError, ...rest }: ChildTextInputProps) => React.JSX.Element;
3
+ declare const TextInputDefault: ({ disabled, editable, label, error, selectionColor: customSelectionColor, cursorColor, outlineColor: customOutlineColor, activeOutlineColor, outlineStyle, textColor, dense, style, theme, render, multiline, parentState, innerRef, onFocus, forceFocus, onBlur, onChangeText, onLayout, left, right, placeholderTextColor, clearButton, contentStyle, value, textError, required, ...rest }: ChildTextInputProps) => React.JSX.Element;
4
4
  export default TextInputDefault;
@@ -1,4 +1,4 @@
1
1
  import * as React from "react";
2
2
  import type { ChildTextInputProps } from "./types";
3
- declare const TextInputFlat: ({ disabled, editable, label, error, selectionColor: customSelectionColor, cursorColor, underlineColor, underlineStyle, activeUnderlineColor, textColor, dense, style, theme, render, multiline, parentState, innerRef, onFocus, forceFocus, onBlur, onChangeText, onLayoutAnimatedText, onLabelTextLayout, onLeftAffixLayoutChange, onRightAffixLayoutChange, onInputLayout, left, right, prefix, placeholderTextColor, clearButton, contentStyle, scaledLabel, outlineStyle, outlineColor, value, textError, ...rest }: ChildTextInputProps) => React.JSX.Element;
3
+ declare const TextInputFlat: ({ disabled, editable, label, error, selectionColor: customSelectionColor, cursorColor, underlineColor, underlineStyle, activeUnderlineColor, textColor, dense, style, theme, render, multiline, parentState, innerRef, onFocus, forceFocus, onBlur, onChangeText, onLayoutAnimatedText, onLabelTextLayout, onLeftAffixLayoutChange, onRightAffixLayoutChange, onInputLayout, left, right, prefix, placeholderTextColor, clearButton, contentStyle, scaledLabel, outlineStyle, outlineColor, value, textError, required, ...rest }: ChildTextInputProps) => React.JSX.Element;
4
4
  export default TextInputFlat;
@@ -1,20 +1,13 @@
1
1
  import React from "react";
2
- import { StyleProp, ViewStyle, TouchableOpacityProps, TextStyle } from "react-native";
3
- import { IText } from "../Text";
2
+ import { StyleProp, ViewStyle, TouchableOpacityProps } from "react-native";
4
3
  import { ThemeProp } from "../../types";
5
4
  export interface TextInputNumberProps extends TouchableOpacityProps {
6
5
  style?: StyleProp<ViewStyle>;
7
- borderColor?: string;
8
6
  value?: string | number;
9
7
  label?: string;
10
8
  textError?: string;
11
9
  left?: React.ReactNode;
12
10
  right?: React.ReactNode;
13
- textProps?: IText;
14
- textColor?: string;
15
- labelColor?: string;
16
- textStyle?: TextStyle;
17
- labelStyle?: TextStyle;
18
11
  disabled?: boolean;
19
12
  prefix?: string;
20
13
  onChangeText?: (value: string) => void;
@@ -23,6 +16,7 @@ export interface TextInputNumberProps extends TouchableOpacityProps {
23
16
  maxValue?: number;
24
17
  type?: "integer" | "float";
25
18
  formatDecimal?: 1 | 2 | 3;
19
+ required?: boolean;
26
20
  }
27
- declare const _default: React.MemoExoticComponent<({ style, value, label, textError, borderColor, left, right, textStyle, labelStyle, textProps, onChangeText, disabled, textColor, labelColor, theme: themeOverrides, prefix, clearButton, maxValue, type, formatDecimal, ...props }: TextInputNumberProps) => React.JSX.Element>;
21
+ declare const _default: React.MemoExoticComponent<({ style, value, label, textError, left, right, onChangeText, disabled, theme: themeOverrides, prefix, clearButton, maxValue, type, formatDecimal, required, ...props }: TextInputNumberProps) => React.JSX.Element>;
28
22
  export default _default;
@@ -95,6 +95,7 @@ export type ChildTextInputProps = {
95
95
  clearButton?: boolean;
96
96
  prefix?: string;
97
97
  textError?: string;
98
+ required?: boolean;
98
99
  } & $Omit<TextInputTypesWithoutMode, "theme"> & {
99
100
  theme: InternalTheme;
100
101
  };
@@ -144,6 +145,7 @@ export type InputLabelProps = {
144
145
  labelBackground?: any;
145
146
  maxFontSizeMultiplier?: number | undefined | null;
146
147
  scaledLabel?: boolean;
148
+ required?: boolean;
147
149
  } & LabelProps;
148
150
  export type LabelBackgroundProps = {
149
151
  labelStyle: any;