diff --git a/components/ActionSheetComponents/EachTrainInfo/ScrollStickyContent.js b/components/ActionSheetComponents/EachTrainInfo/ScrollStickyContent.js index 23cf4e5..545428d 100644 --- a/components/ActionSheetComponents/EachTrainInfo/ScrollStickyContent.js +++ b/components/ActionSheetComponents/EachTrainInfo/ScrollStickyContent.js @@ -1,5 +1,5 @@ import React from "react"; -import { View, Text, LayoutAnimation } from "react-native"; +import { View, Text, LayoutAnimation, TouchableOpacity } from "react-native"; export const ScrollStickyContent = (props) => { const { currentTrainData, showThrew, setShowThrew, haveThrough } = props; @@ -50,7 +50,16 @@ export const ScrollStickyContent = (props) => { > 見込 - + { + if (!haveThrough) return; + LayoutAnimation.configureNext({ + duration: 200, + update: { type: "easeInEaseOut", springDamping: 0.6 }, + }); + setShowThrew(!showThrew); + }} + > { textAlignVertical: "center", opacity: haveThrough ? 1 : 0, }} - onPress={() => { - if (!haveThrough) return; - LayoutAnimation.configureNext({ - duration: 200, - update: { type: "easeInEaseOut", springDamping: 0.6 }, - }); - setShowThrew(!showThrew); - }} > (通過{showThrew ? "▼" : "▶"}) - +