opentripplanner / otp-ui

React component library, which can be used to build trip planner webapps.
http://www.opentripplanner.org/otp-ui/?path=/story/transitvehicleoverlay--real-time-rectangles
MIT License
54 stars 34 forks source link

Blank MOD UI screen shown for unknown company icons #196

Closed binh-dam-ibigroup closed 4 years ago

binh-dam-ibigroup commented 4 years ago

MOD UI becomes all blank after clicking Bikeshare under Travel Options. This is associated with warnings about undefined rental company icons.

To reproduce:

  1. In file packages/trip-form/src/__mocks__/companies.js, add the following entry to the commonCompanies array:
    {
    id: "UNKNOWN_BIKESHARE",
    label: "Unknown Bikeshare",
    modes: "BICYCLE_RENT"
    }
  2. Launch Storybook and go to the first story for SettingsSelectorPanel
  3. Click "Transit+Biketown"
  4. An error message should fill the canvas.

~1. in OTP-RR config, enter a rental company whose icon is not in OTP-UI/icons package, e.g.:~

companies:
  - id: CITIBIKE
    label: Citibike
    modes: BICYCLE_RENT

~2. Load MOD UI, click Travel Options, then click Bikeshare.~ ~3. The entire browser screen goes blank.~

binh-dam-ibigroup commented 4 years ago

Issue description has been updated to reproduce the issue in Storybook instead of OTP-RR.