Skip to content

Commit

Permalink
refactor: remove default export vehicleLabel
Browse files Browse the repository at this point in the history
Part of:
- #2603
  • Loading branch information
firestack committed Oct 11, 2024
1 parent 21fa866 commit c695752
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 7 deletions.
2 changes: 1 addition & 1 deletion assets/src/components/incomingBox.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import React, { useContext } from "react"
import { StateDispatchContext } from "../contexts/stateDispatchContext"
import vehicleLabel from "../helpers/vehicleLabel"
import { vehicleLabel } from "../helpers/vehicleLabel"
import { blockWaiverAlertStyle } from "../models/blockWaiver"
import { crowdingLabel, OccupancyStatus } from "../models/crowding"
import {
Expand Down
2 changes: 1 addition & 1 deletion assets/src/components/ladder.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import "tippy.js/dist/tippy.css"
import { StateDispatchContext } from "../contexts/stateDispatchContext"
import { flatten, partition } from "../helpers/array"
import { joinClasses } from "../helpers/dom"
import vehicleLabel from "../helpers/vehicleLabel"
import { vehicleLabel } from "../helpers/vehicleLabel"
import { blockWaiverAlertStyle } from "../models/blockWaiver"
import { crowdingLabel, OccupancyStatus } from "../models/crowding"
import {
Expand Down
2 changes: 1 addition & 1 deletion assets/src/components/propertiesPanel/header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import React, { useContext } from "react"
import { useRoute } from "../../contexts/routesContext"
import { StateDispatchContext } from "../../contexts/stateDispatchContext"
import { joinClasses } from "../../helpers/dom"
import vehicleLabel from "../../helpers/vehicleLabel"
import { vehicleLabel } from "../../helpers/vehicleLabel"
import { secondsAgoLabel, secondsToMinutes } from "../../util/dateTime"
import { useCurrentTimeSeconds } from "../../hooks/useCurrentTime"
import { emptyLadderDirectionsByRouteId } from "../../models/ladderDirection"
Expand Down
2 changes: 1 addition & 1 deletion assets/src/components/vehicleRouteSummary.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import React, {
import { useRoute } from "../contexts/routesContext"
import { StateDispatchContext } from "../contexts/stateDispatchContext"
import { joinClasses } from "../helpers/dom"
import vehicleLabel from "../helpers/vehicleLabel"
import { vehicleLabel } from "../helpers/vehicleLabel"
import { emptyLadderDirectionsByRouteId } from "../models/ladderDirection"
import { currentRouteTab } from "../models/routeTab"
import {
Expand Down
2 changes: 0 additions & 2 deletions assets/src/helpers/vehicleLabel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,5 +58,3 @@ export const runIdToLabel = (runId: RunId | null): string => {

const stripLeadingZero = (num: string): string =>
num.startsWith("0") ? num.slice(1) : num

export default vehicleLabel
3 changes: 2 additions & 1 deletion assets/tests/helpers/vehicleLabel.test.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import { describe, test, expect } from "@jest/globals"
import vehicleLabel, {
import {
vehicleLabel,
runOrBusNumberLabel,
runIdToLabel,
} from "../../src/helpers/vehicleLabel"
Expand Down

0 comments on commit c695752

Please sign in to comment.