This is simple elevator simulator built using React + Semantic UI. Click here for live version
-
Most of it is boilerplate code taken from here
-
Code I wrote from scratch
src/api
- Business logic codesrc/components
- UI codesrc/api/test
- Unit test code
-
It is advisable to use the project with
yarn
yarn
- To initialize projectyarn test
- To run unit testsyarn start
- To start the application
Hopefully the application is self explanatory.
-
Up/Down button
white
- Can request for elevator for given floor at given directionred
- Waiting for elevatorgreen
- Elevator is in your floor
-
Elevator icon
- Has tiny pointer denoting the direction it is moving
- If in red color, it is busy moving to requested floor, cannot accept other requests
- If in green color, it is opening/closing doors in a given floor