fix: omitting "po" stops in timetable progress bar

This commit is contained in:
2024-08-19 23:56:15 +02:00
parent 80a5b56785
commit 551b60c733
4 changed files with 5 additions and 5 deletions
+2 -2
View File
@@ -80,13 +80,13 @@ export default defineComponent({
return stops
.reduce((acc: string[], stop: TrainStop, i: number) => {
if (stop.stopType.includes('ph') && !stop.stopNameRAW.includes('po.'))
if (stop.stopType.includes('ph') && !stop.stopNameRAW.includes(', po'))
acc.push(
`<strong style='color:${stop.confirmed ? 'springgreen' : 'white'}'>${
stop.stopName
}</strong>`
);
else if (i > 0 && i < stops.length - 1 && !/po\.|sbl/gi.test(stop.stopNameRAW))
else if (i > 0 && i < stops.length - 1 && !/(, po|sbl)/gi.test(stop.stopNameRAW))
acc.push(
`<span style='color:${stop.confirmed ? 'springgreen' : 'lightgray'}'>${
stop.stopName