Repository navigation
v0.1.1
π v0.1.1 β First public release
This is the first public version of React Railway β a step-by-step UI guide component built with React and MUI.
β¨ Highlights
β’ β¨ Core <Railway> component with spotlight backdrop and MUI Popper tooltip.
β’ π§ New context + hook: RailwayProvider and useRailway().
β’ startEngine, stopEngine, isRunning, runningId
β’ isViewed, isCompleted, setViewed, setCompleted (persisted via localStorage)
β’ railwayOrder, setRailwayOrder (single tour runs at a time; ordered autostart)
β’ π¦ Autostart per tour via config.autoStart (respects railwayOrder and viewed/completed).
β’ π― Station targeting:
β’ With id: highlights element (data-railway-station="..."), smart scroll-into-view, auto top/bottom placement.
β’ Without id: popper centers on the viewport (no backdrop hole).
β’ π§° Utility: clickElement(selector, options) to open drawers/menus, scroll, and wait for UI.
β’ π¦ Build & types: ESM + CJS outputs, bundled TypeScript declarations, React/MUI as peer deps.
π¦ Install via NPM
npm install react-railwayπ§ͺ Tested with
- React 19+
- MUI v7+
- Typescript