reza fixed compo colors before AR

master
Reza_ashrafi 2 years ago
parent a8f4d7fe52
commit b424046245
  1. 20
      src/components/Select.js

@ -1,5 +1,5 @@
import React from "react";
import { Appearance } from "react-native";
import { connect } from "react-redux";
import Svg, { Path } from "react-native-svg";
import SelectDropdown from "react-native-select-dropdown";
@ -11,22 +11,20 @@ function Select({
options,
onChange,
name,
value,
width,
defaultValue,
theme,
}) {
const colorScheme = Appearance.getColorScheme();
return (
<SelectDropdown
data={options}
buttonStyle={{
width: width,
borderWidth: 1,
borderColor: Colors.theme1[colorScheme].gray2077 + "66",
borderColor: Colors.theme1[theme].gray2077 + "66",
borderRadius: 2,
height: 48,
backgroundColor: 'white',
backgroundColor: "white",
fontFamily: "regular",
}}
rowTextStyle={{
@ -40,7 +38,7 @@ function Select({
justifyContent: "flex-end",
flex: 0,
fontSize: fontSize.tiny,
color: Colors.theme1[colorScheme].gray2077,
color: Colors.theme1[theme].gray2077,
fontFamily: "regular",
// display: 'inline'
}}
@ -58,7 +56,7 @@ function Select({
<Path
d="m13.347 5.997-4.368 4.369a1.331 1.331 0 0 1-1.876 0L2.734 5.997"
fill="none"
stroke={Colors.theme1[colorScheme].gray2077 + "66"}
stroke={Colors.theme1[theme].gray2077 + "66"}
strokeLinecap="round"
strokeLinejoin="round"
strokeWidth={1.5}
@ -69,7 +67,11 @@ function Select({
);
}
export default Select;
const mapStateToProps = (state) => ({
theme: state.publicApi.theme,
});
export default connect(mapStateToProps)(Select);
Select.defaultProps = {
options: ["1", "2", "3"],

Loading…
Cancel
Save