ordering-ui-react-native 0.20.5-release → 0.20.7-release

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ordering-ui-react-native",
3
- "version": "0.20.5-release",
3
+ "version": "0.20.7-release",
4
4
  "description": "Reusable components made in react native",
5
5
  "main": "src/index.tsx",
6
6
  "author": "ordering.inc",
@@ -40,7 +40,6 @@ export const ProductItemAccordion = (props: ProductItemAccordionParams) => {
40
40
 
41
41
  const theme = useTheme();
42
42
 
43
-
44
43
  const pickerStyle = StyleSheet.create({
45
44
  inputAndroid: {
46
45
  width: 34,
@@ -77,7 +76,7 @@ export const ProductItemAccordion = (props: ProductItemAccordionParams) => {
77
76
  const [isServiceOpen, setIsServiceOpen] = useState(false)
78
77
  // const [setHeight, setHeightState] = useState({ height: new Animated.Value(0) })
79
78
  // const [setRotate, setRotateState] = useState({ angle: new Animated.Value(0) })
80
- const [productQuantity, setProductQuantity] = useState(product.quantity.toString())
79
+ let productQuantity = product.quantity.toString()
81
80
 
82
81
  const productInfo = () => {
83
82
  if (isCartProduct) {
@@ -121,7 +120,7 @@ export const ProductItemAccordion = (props: ProductItemAccordionParams) => {
121
120
 
122
121
  const handleChangeQuantity = (value: string) => {
123
122
  if (!orderState.loading) {
124
- setProductQuantity(value)
123
+ productQuantity = value
125
124
  if (parseInt(value) === 0) {
126
125
  onDeleteProduct && onDeleteProduct(product)
127
126
  } else {
@@ -285,7 +285,7 @@ const SingleOrderCardUI = (props: SingleOrderCardParams) => {
285
285
  ) : (
286
286
  <Price>
287
287
  <OText size={12} lineHeight={18}>
288
- {parsePrice(order?.summary?.total || order?.total)}
288
+ {parsePrice(order?.total)}
289
289
  </OText>
290
290
  </Price>
291
291
  )}