From ebf72e35bce74255fef607b9e5511b223ccff8b8 Mon Sep 17 00:00:00 2001 From: harukin-expo-dev-env Date: Sat, 23 Aug 2025 16:34:29 +0000 Subject: [PATCH] =?UTF-8?q?=E3=81=A8=E3=82=8A=E3=81=82=E3=81=88=E3=81=9A?= =?UTF-8?q?=E5=AE=9F=E8=A3=85=E3=80=81=E6=98=8E=E6=97=A5=E5=8B=95=E4=BD=9C?= =?UTF-8?q?=E3=83=81=E3=82=A7=E3=83=83=E3=82=AF=E3=81=97=E3=81=A6=E6=8C=99?= =?UTF-8?q?=E5=8B=95=E7=A2=BA=E8=AA=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../EachTrainInfo/EachStopList.js | 2 +- .../EachTrainInfo/ScrollStickyContent.js | 4 ++-- .../ActionSheetComponents/EachTrainInfoCore.js | 5 ++++- components/DynamicHeaderScrollView.js | 2 +- lib/getTrainType.ts | 13 +++++++++++-- 5 files changed, 19 insertions(+), 7 deletions(-) diff --git a/components/ActionSheetComponents/EachTrainInfo/EachStopList.js b/components/ActionSheetComponents/EachTrainInfo/EachStopList.js index 5ebbb70..fc01483 100644 --- a/components/ActionSheetComponents/EachTrainInfo/EachStopList.js +++ b/components/ActionSheetComponents/EachTrainInfo/EachStopList.js @@ -79,7 +79,7 @@ export const EachStopList = ({ { @@ -16,7 +16,7 @@ export const ScrollStickyContent = (props) => { padding: 8, flexDirection: "row", borderBottomWidth: 1, - borderBottomColor: "#f0f0f0", + borderBottomColor: "#ffffffc2", flex: 1, }} > diff --git a/components/ActionSheetComponents/EachTrainInfoCore.js b/components/ActionSheetComponents/EachTrainInfoCore.js index 60daa28..9806359 100644 --- a/components/ActionSheetComponents/EachTrainInfoCore.js +++ b/components/ActionSheetComponents/EachTrainInfoCore.js @@ -392,6 +392,7 @@ export const EachTrainInfoCore = ({ containerProps={{ style: { maxHeight: isLandscape ? height - 94 : (height / 100) * 70, + backgroundColor:getTrainType(customTrainDataDetector(data.trainNum, allCustomTrainData).type).data === "notService" ? "#868686ff" :"white" }, }} shortHeader={ @@ -422,6 +423,7 @@ export const EachTrainInfoCore = ({ /> } > + {getTrainType(customTrainDataDetector(data.trainNum, allCustomTrainData).type).data === "notService" &&この列車には乗車できません。} {headStation.length != 0 && headStation.map((i, index) => showHeadStation.findIndex((d) => d == index) == -1 ? ( @@ -494,7 +496,7 @@ export const EachTrainInfoCore = ({ /> ) )} - 背景が緑色、時刻が斜体になっている時刻はコミュニティで追加されている独自データです。 + 背景が緑色、時刻が斜体になっている時刻はコミュニティで追加されている独自データです。 {tailStation.length != 0 && tailStation.map(({ station, dia }, index) => showTailStation.findIndex((d) => d == index) == -1 ? ( @@ -535,6 +537,7 @@ export const EachTrainInfoCore = ({ flexDirection: "row", borderBottomWidth: 1, borderBottomColor: "#f0f0f0", + backgroundColor:"#ffffffc2", flex: 1, }} > diff --git a/components/DynamicHeaderScrollView.js b/components/DynamicHeaderScrollView.js index 0e31d16..8d163bf 100644 --- a/components/DynamicHeaderScrollView.js +++ b/components/DynamicHeaderScrollView.js @@ -159,7 +159,7 @@ export const DynamicHeaderScrollView = (props) => { ref={scrollHandlers.ref} onLayout={scrollHandlers.onLayout} scrollEventThrottle={scrollHandlers.scrollEventThrottle} - style={{ backgroundColor: "white", zIndex: 0 }} + style={{ zIndex: 0 }} stickyHeaderIndices={[1]} onScroll={onScroll} > diff --git a/lib/getTrainType.ts b/lib/getTrainType.ts index 6c2d3e6..7966b8a 100644 --- a/lib/getTrainType.ts +++ b/lib/getTrainType.ts @@ -5,7 +5,7 @@ type nameString = | "SPCL" | "Normal" | string; -type colorString = "aqua" | "red" | "#297bff" | "#ff7300ff" | "white" | "pink"; +type colorString = "aqua" | "red" | "#297bff" | "#ff7300ff" | "#00869ecc" | "#727272cc" | "white" | "pink"; type trainTypeString = | "快速" | "特急" @@ -16,8 +16,11 @@ type trainTypeString = | "臨時快速" | "臨時特急" | "団体臨時" + | "貨物" + | "回送" + | "単機回送" | "その他"; -type trainTypeDataString = "rapid" | "express" | "normal"; +type trainTypeDataString = "rapid" | "express" | "normal" | "notService"; type getTrainType = (d: nameString) => { color: colorString; name: trainTypeString; @@ -45,6 +48,12 @@ export const getTrainType: getTrainType = (nameString) => { return { color: "#297bff", name: "臨時特急", data: "normal" }; case "Party": return { color: "#ff7300ff", name: "団体臨時", data: "normal" }; + case "Freight": + return { color: "#00869ecc", name: "貨物", data: "notService" }; + case "Forwarding": + return { color: "#727272cc", name: "回送", data: "notService" }; + case "FreightForwarding": + return { color: "#727272cc", name: "単機回送", data: "notService" }; default: return { color: "white", name: "その他", data: "normal" }; }