@particle-network/ui-native 0.4.2-beta.7 → 0.4.2-beta.8

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.
@@ -4,7 +4,7 @@ import { useColors, useComponentConfig, useMs, useRadius } from "../../hooks/ind
4
4
  import { disabledOpacity } from "../../theme/index.js";
5
5
  const useStyles = (props)=>{
6
6
  const { input: inputConfig } = useComponentConfig();
7
- const { isInvalid, isDisabled, fullWidth, isFocused, color = 'default', size = 'md', variant = 'flat', multiline, radius = multiline ? void 0 : inputConfig.defaultProps?.radius, width: widthProp, textAlign = 'left' } = props;
7
+ const { isInvalid, isDisabled, fullWidth, isFocused, color = 'default', isColorText = false, size = 'md', variant = 'flat', multiline, radius = multiline ? void 0 : inputConfig.defaultProps?.radius, width: widthProp, textAlign = 'left' } = props;
8
8
  const { getColor } = useColors();
9
9
  const { getRadius } = useRadius();
10
10
  const { ms } = useMs();
@@ -52,10 +52,13 @@ const useStyles = (props)=>{
52
52
  ]);
53
53
  const inputTextColor = useMemo(()=>{
54
54
  if (isInvalid) return getColor('danger');
55
+ if (isColorText) return getColor(color);
55
56
  return getColor('foreground');
56
57
  }, [
57
58
  isInvalid,
58
- getColor
59
+ getColor,
60
+ isColorText,
61
+ color
59
62
  ]);
60
63
  const backgroundColor = useMemo(()=>getColor('bg-200'), [
61
64
  getColor
@@ -36,6 +36,7 @@ export interface UXInputCommonProps extends Omit<TextInputProps, 'style' | 'valu
36
36
  isReadOnly?: boolean;
37
37
  isDisabled?: boolean;
38
38
  isInvalid?: boolean;
39
+ isColorText?: boolean;
39
40
  label?: string;
40
41
  textAlign?: 'left' | 'center' | 'right';
41
42
  autoErrorMessage?: boolean;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@particle-network/ui-native",
3
- "version": "0.4.2-beta.7",
3
+ "version": "0.4.2-beta.8",
4
4
  "main": "./entry.js",
5
5
  "react-native": "./dist/index.js",
6
6
  "module": "./dist/index.js",
@@ -44,8 +44,8 @@
44
44
  "react-native-paper": "^5.14.5",
45
45
  "react-native-size-matters": "^0.4.2",
46
46
  "react-native-toast-message": "^2.3.3",
47
- "@particle-network/ui-shared": "0.3.2-beta.2",
48
- "@particle-network/icons": "0.4.2-beta.5"
47
+ "@particle-network/icons": "0.4.2-beta.6",
48
+ "@particle-network/ui-shared": "0.3.2-beta.2"
49
49
  },
50
50
  "devDependencies": {
51
51
  "@babel/core": "^7.24.0",
@@ -88,8 +88,8 @@
88
88
  "unfetch": "^4.2.0",
89
89
  "vite": "^6.3.5",
90
90
  "zustand": "^5.0.8",
91
- "@particle-network/icons": "0.4.2-beta.5",
92
91
  "@particle-network/eslint-config": "0.3.0",
92
+ "@particle-network/icons": "0.4.2-beta.6",
93
93
  "@particle-network/lintstaged-config": "0.1.0"
94
94
  },
95
95
  "overrides": {