twobells 0.2.2__tar.gz → 0.2.3__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {twobells-0.2.2/src/twobells.egg-info → twobells-0.2.3}/PKG-INFO +1 -1
- {twobells-0.2.2 → twobells-0.2.3}/pyproject.toml +1 -1
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/board.js +37 -10
- {twobells-0.2.2 → twobells-0.2.3/src/twobells.egg-info}/PKG-INFO +1 -1
- {twobells-0.2.2 → twobells-0.2.3}/LICENSE +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/README.md +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/setup.cfg +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/__init__.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/__main__.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/board/__init__.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/board/app.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/board/displays/__init__.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/board/displays/display.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/board/displays/screen.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/board/displays/waveshare.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/board/dotfont.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/board/flaps.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/board/fonts/Inter-ExtraBold.ttf +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/board/fonts/Inter-Regular.ttf +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/board/fonts/LICENSE +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/board/fonts/SHA256SUMS +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/board/panel.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/board/platformclock.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/board/positions.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/board/render.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/board/route.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/board/scroll.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/board/sign.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/board/speaker.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/board/splitflap.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/board/state.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/board/tft.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/board/themes.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/board/view.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/cli/__init__.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/cli/common.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/cli/dev.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/cli/main.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/cli/run.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/cli/serve.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/cli/setup.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/cli/timetable.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/core/__init__.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/core/announce.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/core/budget.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/core/calling.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/core/errors.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/core/files.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/core/model.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/core/net.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/core/osgb.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/core/polling.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/core/safexml.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/core/walk.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/core/words.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard/__init__.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard/area.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard/collector.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard/config.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard/enrich.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard/history.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard/performance.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard/repay.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard/snapshot.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/alerts.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/api.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/app.css +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/area.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/disruptions.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/dom.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/extras.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/flap.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/fonts/DepartureboardDots.woff2 +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/fonts/LICENSE +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/fonts/SHA256SUMS +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/header.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/hero.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/history.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/icons/apple-touch-icon.png +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/icons/icon-192.png +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/icons/icon-512.png +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/icons/icon.svg +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/icons.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/index.html +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/kiosk.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/live.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/look.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/main.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/manifest.webmanifest +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/map.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/measures.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/pa.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/performance.html +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/performance.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/platformclock.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/sheet.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/show.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/strip.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/theme.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/time.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/train.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/vendor/inter-4.1/InterVariable.woff2 +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/vendor/inter-4.1/LICENSE +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/vendor/inter-4.1/SHA256SUMS +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/vendor/leaflet-1.9.4/LICENSE +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/vendor/leaflet-1.9.4/SHA256SUMS +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/vendor/leaflet-1.9.4/leaflet-src.esm.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/vendor/leaflet-1.9.4/leaflet.css +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/weather.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/data/gb_stations.csv +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/data/naptan_area_grid.csv +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/emulator/__init__.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/emulator/emulation.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/emulator/emulator.html +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/emulator/fake.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/emulator/server.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/fetch/__init__.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/fetch/handoff.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/fetch/service.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/settings/__init__.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/settings/config.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/settings/installs.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/settings/keyresults.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/settings/overlay.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/settings/schema.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/settings/show.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/settings/store.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/setup/__init__.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/setup/api.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/setup/discover.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/setup/keytest.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/setup/lookups.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/setup/spool/__init__.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/setup/spool/checks.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/setup/spool/folder.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/setup/spool/runner.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/setup/spool/worker.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/sources/__init__.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/sources/bods.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/sources/bodsbus.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/sources/darwin.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/sources/disruptions.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/sources/holidays.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/sources/lastbus.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/sources/livebus.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/sources/transportapi.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/sources/weather.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/timetable/__init__.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/timetable/build.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/timetable/model.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/timetable/roads.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/timetable/routesetup.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/version.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/web/__init__.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/web/auth.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/web/formpages.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/web/groupform.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/web/icons.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/web/keyspage.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/web/keystate.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/web/netguard.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/web/overview.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/web/places.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/web/server.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/web/settings.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/web/settingsite.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/web/status.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/web/web.css +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/web/windowrows.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/wizard_static/api.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/wizard_static/finish.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/wizard_static/home.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/wizard_static/index.html +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/wizard_static/keys.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/wizard_static/maps.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/wizard_static/presets.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/wizard_static/roads.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/wizard_static/say.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/wizard_static/state.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/wizard_static/station.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/wizard_static/steps.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/wizard_static/stops.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/wizard_static/views.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/wizard_static/walk.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/wizard_static/wizard.css +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells/wizard_static/wizard.js +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells.egg-info/SOURCES.txt +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells.egg-info/dependency_links.txt +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells.egg-info/entry_points.txt +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells.egg-info/requires.txt +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/src/twobells.egg-info/top_level.txt +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/tests/test_deploy.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/tests/test_docs.py +0 -0
- {twobells-0.2.2 → twobells-0.2.3}/tests/test_version.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: twobells
|
|
3
|
-
Version: 0.2.
|
|
3
|
+
Version: 0.2.3
|
|
4
4
|
Summary: Two Bells: know when to leave. Train and bus departures for Great Britain, on an e-paper or HDMI board on a Raspberry Pi and on a web dashboard, installed on a Pi, in Docker or on a desktop
|
|
5
5
|
Author: Albert Cornelissen
|
|
6
6
|
License-Expression: MIT
|
|
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "twobells"
|
|
7
|
-
version = "0.2.
|
|
7
|
+
version = "0.2.3"
|
|
8
8
|
description = "Two Bells: know when to leave. Train and bus departures for Great Britain, on an e-paper or HDMI board on a Raspberry Pi and on a web dashboard, installed on a Pi, in Docker or on a desktop"
|
|
9
9
|
readme = "README.md"
|
|
10
10
|
requires-python = ">=3.11"
|
|
@@ -12,6 +12,8 @@
|
|
|
12
12
|
// tablet (kiosk.js) there are no controls: 4 rows, the destination as text.
|
|
13
13
|
// Rows draw their position strips unless the settings turned them off
|
|
14
14
|
// (applyRowStrips marks <html data-row-strips="off">) or the page is on a wall tablet.
|
|
15
|
+
// A bus known only from the timetable has no strip, and no words until it is
|
|
16
|
+
// near (notTrackedYet).
|
|
15
17
|
// What the settings leave out (show.js) isn't drawn: where each train and bus
|
|
16
18
|
// is, the calling-at line, the punctuality note, a reminder's bell, the last buses.
|
|
17
19
|
// A row's time, destination and status carry a data-flap key, its board,
|
|
@@ -30,6 +32,9 @@ export const SHOWN = 5; // rows before "Show later departures"
|
|
|
30
32
|
export const KIOSK_ROWS = 4; // rows on a wall tablet, which has no "Show later departures"
|
|
31
33
|
const MAX_ROWS = 20; // the most the settings allow
|
|
32
34
|
export const GO_MS = 2 * 60_000; // "Go now" lasts this long past the leaving time (the hero's too)
|
|
35
|
+
// A bus known only from the timetable says "Not tracked yet" from this long
|
|
36
|
+
// before you need to leave for it (notTrackedYet).
|
|
37
|
+
export const NOT_TRACKED_WITHIN_MS = 10 * 60_000;
|
|
33
38
|
|
|
34
39
|
// On time is plain words; only the exceptions get an icon.
|
|
35
40
|
const ICON = { late: "triangle-alert", cancelled: "x", unknown: "clock" };
|
|
@@ -91,10 +96,12 @@ export function arrange(rows, t) {
|
|
|
91
96
|
}
|
|
92
97
|
|
|
93
98
|
// What a board looks like at `t`, as a string: when it changes, the board is
|
|
94
|
-
// drawn again.
|
|
95
|
-
|
|
99
|
+
// drawn again. A bus row that has come near enough to say "Not tracked yet"
|
|
100
|
+
// changes it too.
|
|
101
|
+
function arrangement(mode, rows, t) {
|
|
96
102
|
const { shown, missed } = arrange(rows, t);
|
|
97
|
-
|
|
103
|
+
const key = (row) => `${str(row.id)}${mode === "bus" && notTrackedYet(row, t) ? "?" : ""}`;
|
|
104
|
+
return `${shown.map(key).join(" ")}|${missed ? str(missed.id) : ""}`;
|
|
98
105
|
}
|
|
99
106
|
|
|
100
107
|
// Per board: the rows last drawn, how they were arranged, and whether the
|
|
@@ -173,7 +180,7 @@ function rowAttrs(row, id, later) {
|
|
|
173
180
|
// Notes the rows a board is drawn with, so tickBoards() knows when they change.
|
|
174
181
|
function remember(mode, rows, t) {
|
|
175
182
|
boards[mode].rows = rows;
|
|
176
|
-
boards[mode].drawn = arrangement(rows, t);
|
|
183
|
+
boards[mode].drawn = arrangement(mode, rows, t);
|
|
177
184
|
}
|
|
178
185
|
|
|
179
186
|
// The board itself: the "Just missed" line, the table, and the button for the
|
|
@@ -476,15 +483,35 @@ function dueCell(row, flap) {
|
|
|
476
483
|
h("span", { class: "sched", "aria-hidden": "true" }, "sched."), vh(", timetable only"));
|
|
477
484
|
}
|
|
478
485
|
|
|
486
|
+
// Whether a bus known only from the timetable says "Not tracked yet" at `t`
|
|
487
|
+
// (ms): from NOT_TRACKED_WITHIN_MS before you need to leave for it, or before
|
|
488
|
+
// its time when no walk is set, so the line is there while you decide whether
|
|
489
|
+
// to go. Not once it may not be running: that warning says more. Further off
|
|
490
|
+
// it says nothing, as its time and "sched." already say it is the timetable's.
|
|
491
|
+
export function notTrackedYet(row, t) {
|
|
492
|
+
if (row.live === true || row.ghost === true || row.status === "cancelled") return false;
|
|
493
|
+
const at = parseAt(row.leave_at) ?? parseAt(row.scheduled_at);
|
|
494
|
+
return at !== null && at - t <= NOT_TRACKED_WITHIN_MS;
|
|
495
|
+
}
|
|
496
|
+
|
|
497
|
+
// Where the bus is: a live one, or one whose bus is coming in to work it,
|
|
498
|
+
// shows its stops and says where it is; a timetable-only one has no strip
|
|
499
|
+
// and says "Not tracked yet" only when it is near (notTrackedYet).
|
|
500
|
+
function busWhere(row) {
|
|
501
|
+
if (!shows("where")) return null;
|
|
502
|
+
if (row.live !== true) {
|
|
503
|
+
return notTrackedYet(row, now()) ? h("span", { class: ["sub", "where", "untracked"] }, "Not tracked yet") : null;
|
|
504
|
+
}
|
|
505
|
+
const strip = obj(row.strip);
|
|
506
|
+
const where = str(strip?.where);
|
|
507
|
+
return where ? whereLine(where, "bus", strip, num(strip?.bus_at)) : null;
|
|
508
|
+
}
|
|
509
|
+
|
|
479
510
|
function busRow(row, later, names, alerts, flap) {
|
|
480
511
|
const id = validId(row.id) ? row.id : null;
|
|
481
512
|
const scheduled = str(row.scheduled);
|
|
482
513
|
const line = str(row.line);
|
|
483
514
|
const destination = str(row.destination);
|
|
484
|
-
const strip = obj(row.strip);
|
|
485
|
-
// Every bus with stops to draw shows them, live or not: a timetable-only
|
|
486
|
-
// one has no bus on its strip and says "No live position".
|
|
487
|
-
const where = str(strip?.where);
|
|
488
515
|
const walk = num(row.walk_min);
|
|
489
516
|
// The row header is said with every cell, so it is the line and where it
|
|
490
517
|
// goes, nothing more: "237 to Ashton-under-Lyne Interchange". The rest is
|
|
@@ -494,7 +521,7 @@ function busRow(row, later, names, alerts, flap) {
|
|
|
494
521
|
h("span", { class: "line", dataset: { flap: flap("line") } }, line), vh(` to ${destination}`)),
|
|
495
522
|
td("c-dest", null,
|
|
496
523
|
openButton(id, `the ${scheduled} ${line} to `, destination, flap("destination")),
|
|
497
|
-
|
|
524
|
+
busWhere(row),
|
|
498
525
|
busStatusExtras(row),
|
|
499
526
|
recordChip(row)),
|
|
500
527
|
stopCell(stopText(row, names), walk),
|
|
@@ -592,5 +619,5 @@ export function tickBoards() {
|
|
|
592
619
|
const at = parseAt(el.dataset.dueAt);
|
|
593
620
|
if (at !== null) flapText(el, dueText(at - t));
|
|
594
621
|
}
|
|
595
|
-
return Object.
|
|
622
|
+
return Object.entries(boards).some(([mode, board]) => board.drawn !== arrangement(mode, board.rows, t));
|
|
596
623
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: twobells
|
|
3
|
-
Version: 0.2.
|
|
3
|
+
Version: 0.2.3
|
|
4
4
|
Summary: Two Bells: know when to leave. Train and bus departures for Great Britain, on an e-paper or HDMI board on a Raspberry Pi and on a web dashboard, installed on a Pi, in Docker or on a desktop
|
|
5
5
|
Author: Albert Cornelissen
|
|
6
6
|
License-Expression: MIT
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/fonts/DepartureboardDots.woff2
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/vendor/inter-4.1/InterVariable.woff2
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/vendor/leaflet-1.9.4/LICENSE
RENAMED
|
File without changes
|
{twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/vendor/leaflet-1.9.4/SHA256SUMS
RENAMED
|
File without changes
|
|
File without changes
|
{twobells-0.2.2 → twobells-0.2.3}/src/twobells/dashboard_static/vendor/leaflet-1.9.4/leaflet.css
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|