native-pytech 1.0.144 → 1.0.146

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.
@@ -41,7 +41,7 @@ export default memo(({ itemKey, label, defaultValue, minDate = new Date(new Date
41
41
  });
42
42
  const styles = StyleSheet.create({
43
43
  container: {
44
- padding: 10,
44
+ padding: 7,
45
45
  paddingHorizontal: 30,
46
46
  borderRadius: 20
47
47
  },
@@ -2,5 +2,5 @@ import React from 'react';
2
2
  import Props from './types';
3
3
  export declare const left = 16;
4
4
  export declare const right = 16;
5
- declare const _default: React.MemoExoticComponent<({ children, childrenLeft, childrenRight, onPress, style, backgroundColorPressed, LinearGradientProps, colorScheme, hasTextView, }: Props) => React.JSX.Element>;
5
+ declare const _default: React.MemoExoticComponent<({ children, childrenLeft, childrenRight, onPress, style, backgroundColorPressed, LinearGradientProps, colorScheme, hasTextView, hasNavigationArrow, }: Props) => React.JSX.Element>;
6
6
  export default _default;
@@ -1,6 +1,7 @@
1
1
  import { LinearGradient } from 'expo-linear-gradient';
2
2
  import React, { memo, useCallback, useMemo } from 'react';
3
3
  import { Pressable, StyleSheet, View } from 'react-native';
4
+ import { Ionicons } from '@expo/vector-icons';
4
5
  import colors from '../../constants';
5
6
  import Table from '../Table';
6
7
  import { useTable } from '../../context/table';
@@ -24,11 +25,13 @@ const AddTextView = memo(({ children, hasTextView }) => {
24
25
  {children}
25
26
  </Table.Option.Components.TextView>));
26
27
  });
27
- export default memo(({ children, childrenLeft, childrenRight, onPress, style, backgroundColorPressed, LinearGradientProps, colorScheme, hasTextView, }) => {
28
- // Component
28
+ export default memo(({ children, childrenLeft, childrenRight, onPress, style, backgroundColorPressed, LinearGradientProps, colorScheme, hasTextView, hasNavigationArrow = false, }) => {
29
29
  const content = <>
30
30
  {childrenLeft && <AddTextView hasTextView={hasTextView}>{childrenLeft}</AddTextView>}
31
- {childrenRight && <View style={styles.der}>{childrenRight}</View>}
31
+ {childrenRight || hasNavigationArrow ? (<View style={styles.der}>
32
+ {childrenRight}
33
+ {hasNavigationArrow && <Ionicons name='chevron-forward' size={24} color={colors.theme[colorScheme].icon}/>}
34
+ </View>) : null}
32
35
  {children}
33
36
  </>;
34
37
  const styleView = useMemo(() => [styles.Item_View, style], [style]);
@@ -54,8 +54,13 @@ type Props = {
54
54
  */
55
55
  hasTextView?: boolean;
56
56
  /**
57
- * Color del tema de la opción.
57
+ Color del tema de la opción.
58
58
  */
59
59
  colorScheme: ColorSchemeType;
60
+ /**
61
+ Si es True se muestra una flecha de navegación en el children Right.
62
+ @default false
63
+ */
64
+ hasNavigationArrow?: boolean;
60
65
  };
61
66
  export default Props;
@@ -3,7 +3,7 @@ import { ViewProps } from "react-native";
3
3
  import { type ColorSchemeType } from "../../constants";
4
4
  import OptionProps from "../Option/types";
5
5
  import { DeleteIcon, DragIcon, Icon, Image, Text, TextInput, TextInputCurrency, TextView } from '../OptionComponents';
6
- export type Props = OptionProps & {
6
+ export type Props = Omit<OptionProps, 'colorScheme'> & {
7
7
  id: string;
8
8
  /**
9
9
  @default false
@@ -1,3 +1,6 @@
1
+ import { type ColorSchemeType } from '../constants';
1
2
  import Props from './OptionWrapper/types';
2
- declare const _default: import("react").MemoExoticComponent<({ children, childrenLeft, childrenRight, onPress, onDelete, onDeleteShown, removeWidth, id, style, isAnimated, borders, backgroundColorPressed, LinearGradientProps, layoutAnimation, colorScheme, hasTextView, ...props }: Props) => import("react").JSX.Element>;
3
+ declare const _default: import("react").MemoExoticComponent<({ children, childrenLeft, childrenRight, onPress, onDelete, onDeleteShown, removeWidth, id, style, isAnimated, borders, backgroundColorPressed, LinearGradientProps, layoutAnimation, colorScheme, hasTextView, ...props }: Props & {
4
+ colorScheme: ColorSchemeType;
5
+ }) => import("react").JSX.Element>;
3
6
  export default _default;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "native-pytech",
3
- "version": "1.0.144",
3
+ "version": "1.0.146",
4
4
  "description": "Libreria de React Native Pytech",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",