|
|
|
@ -43,7 +43,7 @@ const status = { |
|
|
|
|
2: "ارسال شده", |
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
function OrderDetails({ order }) { |
|
|
|
|
function OrderDetails({ order, mobile }) { |
|
|
|
|
const colorScheme = Appearance.getColorScheme(); |
|
|
|
|
const [position, setPosition] = useState("100%"); |
|
|
|
|
|
|
|
|
@ -77,14 +77,14 @@ function OrderDetails({ order }) { |
|
|
|
|
> |
|
|
|
|
<View |
|
|
|
|
style={[ |
|
|
|
|
tw("flex flex-row-reverse w-full justify-between items-center p-3"), |
|
|
|
|
tw(`flex flex-row-reverse w-full justify-between items-center ${mobile ? "p-3" : "p-4"}`), |
|
|
|
|
{ backgroundColor: Colors.theme1[colorScheme].greenCF + "1a" }, |
|
|
|
|
]} |
|
|
|
|
> |
|
|
|
|
<Text |
|
|
|
|
style={[ |
|
|
|
|
{ |
|
|
|
|
fontSize: fontSize.sm, |
|
|
|
|
fontSize: mobile ? fontSize.base : fontSize.xl, |
|
|
|
|
color: Colors.theme1[colorScheme].green79, |
|
|
|
|
fontFamily: "bold", |
|
|
|
|
}, |
|
|
|
@ -97,7 +97,7 @@ function OrderDetails({ order }) { |
|
|
|
|
style={[ |
|
|
|
|
{ |
|
|
|
|
color: Colors.theme1[colorScheme].green79, |
|
|
|
|
fontSize: fontSize.sm, |
|
|
|
|
fontSize: mobile ? mobile ? fontSize.sm : fontSize.lg : fontSize.lg, |
|
|
|
|
fontFamily: "bold", |
|
|
|
|
}, |
|
|
|
|
]} |
|
|
|
@ -124,7 +124,7 @@ function OrderDetails({ order }) { |
|
|
|
|
<Text |
|
|
|
|
style={[ |
|
|
|
|
{ |
|
|
|
|
fontSize: fontSize.sm, |
|
|
|
|
fontSize: mobile ? fontSize.sm : fontSize.lg, |
|
|
|
|
color: Colors.theme1[colorScheme].green79, |
|
|
|
|
fontFamily: "bold", |
|
|
|
|
}, |
|
|
|
@ -136,8 +136,8 @@ function OrderDetails({ order }) { |
|
|
|
|
style={[ |
|
|
|
|
tw("flex-1 font-light text-right mr-2"), |
|
|
|
|
{ |
|
|
|
|
fontSize: fontSize.sm, |
|
|
|
|
lineHeight: 17, |
|
|
|
|
fontSize: mobile ? fontSize.sm : fontSize.lg, |
|
|
|
|
lineHeight: mobile ? 17 : 'auto', |
|
|
|
|
color: Colors.theme1[colorScheme].green79, |
|
|
|
|
fontFamily: "regular", |
|
|
|
|
}, |
|
|
|
@ -159,7 +159,7 @@ function OrderDetails({ order }) { |
|
|
|
|
<Text |
|
|
|
|
style={[ |
|
|
|
|
{ |
|
|
|
|
fontSize: fontSize.sm, |
|
|
|
|
fontSize: mobile ? fontSize.sm : fontSize.lg, |
|
|
|
|
color: Colors.theme1[colorScheme].green79, |
|
|
|
|
fontFamily: "bold", |
|
|
|
|
}, |
|
|
|
@ -171,8 +171,8 @@ function OrderDetails({ order }) { |
|
|
|
|
style={[ |
|
|
|
|
tw("font-light text-right mr-1"), |
|
|
|
|
{ |
|
|
|
|
fontSize: fontSize.sm, |
|
|
|
|
lineHeight: 17, |
|
|
|
|
fontSize: mobile ? fontSize.sm : fontSize.lg, |
|
|
|
|
lineHeight: mobile ? 17 : 'auto', |
|
|
|
|
color: Colors.theme1[colorScheme].green79, |
|
|
|
|
fontFamily: "regular", |
|
|
|
|
}, |
|
|
|
@ -185,7 +185,7 @@ function OrderDetails({ order }) { |
|
|
|
|
<Text |
|
|
|
|
style={[ |
|
|
|
|
{ |
|
|
|
|
fontSize: fontSize.sm, |
|
|
|
|
fontSize: mobile ? fontSize.sm : fontSize.lg, |
|
|
|
|
color: Colors.theme1[colorScheme].green79, |
|
|
|
|
fontFamily: "bold", |
|
|
|
|
}, |
|
|
|
@ -197,8 +197,8 @@ function OrderDetails({ order }) { |
|
|
|
|
style={[ |
|
|
|
|
tw("text-right mr-1"), |
|
|
|
|
{ |
|
|
|
|
fontSize: fontSize.sm, |
|
|
|
|
lineHeight: 17, |
|
|
|
|
fontSize: mobile ? fontSize.sm : fontSize.lg, |
|
|
|
|
lineHeight: mobile ? 17 : 'auto', |
|
|
|
|
color: Colors.theme1[colorScheme].green79, |
|
|
|
|
fontFamily: "regular", |
|
|
|
|
}, |
|
|
|
@ -217,7 +217,7 @@ function OrderDetails({ order }) { |
|
|
|
|
<Text |
|
|
|
|
style={[ |
|
|
|
|
{ |
|
|
|
|
fontSize: fontSize.sm, |
|
|
|
|
fontSize: mobile ? mobile ? fontSize.sm : fontSize.lg : fontSize.lg, |
|
|
|
|
color: Colors.theme1[colorScheme].green79, |
|
|
|
|
fontFamily: "bold", |
|
|
|
|
}, |
|
|
|
@ -229,7 +229,7 @@ function OrderDetails({ order }) { |
|
|
|
|
style={[ |
|
|
|
|
tw("font-light text-right mt-1"), |
|
|
|
|
{ |
|
|
|
|
fontSize: fontSize.sm, |
|
|
|
|
fontSize: mobile ? mobile ? fontSize.sm : fontSize.lg : fontSize.lg, |
|
|
|
|
color: Colors.theme1[colorScheme].green79, |
|
|
|
|
fontFamily: "regular", |
|
|
|
|
}, |
|
|
|
@ -248,7 +248,7 @@ function OrderDetails({ order }) { |
|
|
|
|
<Text |
|
|
|
|
style={[ |
|
|
|
|
{ |
|
|
|
|
fontSize: fontSize.sm, |
|
|
|
|
fontSize: mobile ? fontSize.sm : fontSize.lg, |
|
|
|
|
color: Colors.theme1[colorScheme].green79, |
|
|
|
|
fontFamily: "bold", |
|
|
|
|
}, |
|
|
|
@ -260,7 +260,7 @@ function OrderDetails({ order }) { |
|
|
|
|
style={[ |
|
|
|
|
tw("font-light text-right mr-1"), |
|
|
|
|
{ |
|
|
|
|
fontSize: fontSize.sm, |
|
|
|
|
fontSize: mobile ? fontSize.sm : fontSize.lg, |
|
|
|
|
color: Colors.theme1[colorScheme].green79, |
|
|
|
|
fontFamily: "regular", |
|
|
|
|
}, |
|
|
|
@ -273,7 +273,7 @@ function OrderDetails({ order }) { |
|
|
|
|
<Text |
|
|
|
|
style={[ |
|
|
|
|
{ |
|
|
|
|
fontSize: fontSize.sm, |
|
|
|
|
fontSize: mobile ? fontSize.sm : fontSize.lg, |
|
|
|
|
color: Colors.theme1[colorScheme].green79, |
|
|
|
|
fontFamily: "bold", |
|
|
|
|
}, |
|
|
|
@ -285,7 +285,7 @@ function OrderDetails({ order }) { |
|
|
|
|
style={[ |
|
|
|
|
tw("font-light text-right mr-1"), |
|
|
|
|
{ |
|
|
|
|
fontSize: fontSize.sm, |
|
|
|
|
fontSize: mobile ? fontSize.sm : fontSize.lg, |
|
|
|
|
color: Colors.theme1[colorScheme].green79, |
|
|
|
|
fontFamily: "regular", |
|
|
|
|
}, |
|
|
|
@ -308,7 +308,7 @@ function OrderDetails({ order }) { |
|
|
|
|
<Text |
|
|
|
|
style={[ |
|
|
|
|
{ |
|
|
|
|
fontSize: fontSize.sm, |
|
|
|
|
fontSize: mobile ? fontSize.sm : fontSize.lg, |
|
|
|
|
color: Colors.theme1[colorScheme].green79, |
|
|
|
|
fontFamily: "bold", |
|
|
|
|
}, |
|
|
|
@ -320,7 +320,7 @@ function OrderDetails({ order }) { |
|
|
|
|
style={[ |
|
|
|
|
tw("font-light text-right mr-1"), |
|
|
|
|
{ |
|
|
|
|
fontSize: fontSize.sm, |
|
|
|
|
fontSize: mobile ? fontSize.sm : fontSize.lg, |
|
|
|
|
color: Colors.theme1[colorScheme].green79, |
|
|
|
|
fontFamily: "regular", |
|
|
|
|
}, |
|
|
|
@ -333,7 +333,7 @@ function OrderDetails({ order }) { |
|
|
|
|
<Text |
|
|
|
|
style={[ |
|
|
|
|
{ |
|
|
|
|
fontSize: fontSize.sm, |
|
|
|
|
fontSize: mobile ? fontSize.sm : fontSize.lg, |
|
|
|
|
color: Colors.theme1[colorScheme].green79, |
|
|
|
|
fontFamily: "bold", |
|
|
|
|
}, |
|
|
|
@ -345,7 +345,7 @@ function OrderDetails({ order }) { |
|
|
|
|
style={[ |
|
|
|
|
tw("font-light text-right mr-1"), |
|
|
|
|
{ |
|
|
|
|
fontSize: fontSize.sm, |
|
|
|
|
fontSize: mobile ? fontSize.sm : fontSize.lg, |
|
|
|
|
color: Colors.theme1[colorScheme].green79, |
|
|
|
|
fontFamily: "regular", |
|
|
|
|
}, |
|
|
|
@ -368,7 +368,7 @@ function OrderDetails({ order }) { |
|
|
|
|
<Text |
|
|
|
|
style={[ |
|
|
|
|
{ |
|
|
|
|
fontSize: fontSize.sm, |
|
|
|
|
fontSize: mobile ? fontSize.sm : fontSize.lg, |
|
|
|
|
color: Colors.theme1[colorScheme].green79, |
|
|
|
|
fontFamily: "bold", |
|
|
|
|
}, |
|
|
|
@ -380,7 +380,7 @@ function OrderDetails({ order }) { |
|
|
|
|
style={[ |
|
|
|
|
tw("font-light text-right mr-1"), |
|
|
|
|
{ |
|
|
|
|
fontSize: fontSize.sm, |
|
|
|
|
fontSize: mobile ? fontSize.sm : fontSize.lg, |
|
|
|
|
color: Colors.theme1[colorScheme].green79, |
|
|
|
|
fontFamily: "regular", |
|
|
|
|
}, |
|
|
|
@ -393,7 +393,7 @@ function OrderDetails({ order }) { |
|
|
|
|
<Text |
|
|
|
|
style={[ |
|
|
|
|
{ |
|
|
|
|
fontSize: fontSize.sm, |
|
|
|
|
fontSize: mobile ? fontSize.sm : fontSize.lg, |
|
|
|
|
color: Colors.theme1[colorScheme].green79, |
|
|
|
|
fontFamily: "bold", |
|
|
|
|
}, |
|
|
|
@ -405,7 +405,7 @@ function OrderDetails({ order }) { |
|
|
|
|
style={[ |
|
|
|
|
tw("font-light text-right mr-1"), |
|
|
|
|
{ |
|
|
|
|
fontSize: fontSize.sm, |
|
|
|
|
fontSize: mobile ? fontSize.sm : fontSize.lg, |
|
|
|
|
color: Colors.theme1[colorScheme].green79, |
|
|
|
|
fontFamily: "regular", |
|
|
|
|
}, |
|
|
|
@ -420,7 +420,7 @@ function OrderDetails({ order }) { |
|
|
|
|
<Text |
|
|
|
|
style={[ |
|
|
|
|
{ |
|
|
|
|
fontSize: fontSize.sm, |
|
|
|
|
fontSize: mobile ? fontSize.sm : fontSize.lg, |
|
|
|
|
color: Colors.theme1[colorScheme].green79, |
|
|
|
|
fontFamily: "bold", |
|
|
|
|
}, |
|
|
|
@ -432,7 +432,7 @@ function OrderDetails({ order }) { |
|
|
|
|
style={[ |
|
|
|
|
tw("font-light text-right mr-1"), |
|
|
|
|
{ |
|
|
|
|
fontSize: fontSize.sm, |
|
|
|
|
fontSize: mobile ? fontSize.sm : fontSize.lg, |
|
|
|
|
color: Colors.theme1[colorScheme].green79, |
|
|
|
|
fontFamily: "regular", |
|
|
|
|
}, |
|
|
|
@ -460,7 +460,11 @@ const styles = StyleSheet.create({ |
|
|
|
|
}, |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
export default OrderDetails; |
|
|
|
|
const mapStateToProps = (state) => ({ |
|
|
|
|
mobile: state.publicApi.mobile |
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
export default connect(mapStateToProps)(OrderDetails); |
|
|
|
|
|
|
|
|
|
OrderDetails.defaultProps = { |
|
|
|
|
order: { |
|
|
|
|