Running Challenges on iPhone!#423
Open
johnsyweb wants to merge 154 commits into
Open
Conversation
Regions no longer exist
This reverts commit bb80703.
- Add Playwright test that loads a network-mocked parkrunner profile and checks for canvas.leaflet-piechart-icon elements on the explorer map - Ensures the leaflet-piechart integration doesn’t silently regress
- Point country completion pie chart UI test at A482 (Danny Norman) on parkrun.org.uk - This profile has substantial UK tourism (e.g. 474/868 events), ensuring a visible pie segment
- Drop brittle [title*='/'] marker selector and wait directly for canvas.leaflet-piechart-icon inside #explorer_map - Keeps the test focused on the presence of piechart canvases without assuming how Leaflet renders marker titles/tooltips
Switch leaflet-piechart to the upstream commit that restores CanvasIcon styling, and update UI tests and test runner so Playwright always uses a freshly built Chrome extension.
- Force chrome.storage.local to localStorage shim in userscript build - Expose i18n, cache, challenges and challenges_ui functions on window for IIFE bundle - Normalise table caption whitespace when matching 'All Results' - Add d3-bootstrap so window.d3.voronoi exists for challenges_ui - In test: listen for events.json before goto, save console on any failure
…nd sprites - Inject Leaflet ExtraMarkers CSS in userscript build and rewrite sprite URLs to unpkg so challenge maps (e.g. Pirates) show event markers - Add Pirates challenge map test and fulfill ExtraMarkers image requests from node_modules in UI test
…ut fixes - extension: add build:userscript script and esbuild devDependency - script/update: run userscript bundle build - challenges_ui: map div width 100%, reflow and invalidateSize for explorer/challenge maps so tiles and markers render correctly in userscript (e.g. in table layouts) - website: add 'Install as a userscript' link on index
- mise.toml, .ruby-version: pin Ruby 3.2 - website/Gemfile: require ruby ">= 3.2.0" - website/Gemfile.lock: resolve deps under 3.2 - README: document Ruby 3.2 and verify-website command Verified: bundle install && bundle exec jekyll build and serve under 3.2. Staging CI uses mise.toml so will pick up 3.2; production workflow unchanged.
- mise.toml: pin Ruby 3.3 - website/Gemfile: require ruby ">= 3.3.0" - website/Gemfile.lock: resolved under Ruby 3.3.10 - README: document Ruby 3.3 Verified: bundle install && bundle exec jekyll build under 3.3.
mise.toml is the single source of truth for tool versions; .ruby-version was redundant.
- mise.toml: pin Ruby 3.4 - website/Gemfile: require ruby ">= 3.4.0"; add base64, bigdecimal, csv (Ruby 3.4 ships these as bundled gems, required by Jekyll) - website/Gemfile.lock: resolved under Ruby 3.4.7 - README: document Ruby 3.4 Verified: bundle install && bundle exec jekyll build under 3.4.
- website/Gemfile: remove Jekyll boilerplate and redundant comments - website/Gemfile.lock: BUNDLED WITH 2.6.1
…ension - Playwright script loads Chrome extension and captures regions from live parkrun pages - Group by URL to load each page once and take multiple clips (top/bottom selectors) - Full-page screenshot with page-coordinate clip to avoid viewport issues - Config in screenshots.yml; run via ./script/update-screenshots
- Add running_challenges_volunteer_challenges_heading id for volunteer section selector - Give challenge map divs zero height when map not displayed - add_table_break_row: optional id for section headings - Website: userscript instructions and built userscript; index copy update
…Tampermonkey - build/version.sh and build script fallbacks set to 2.0.1 - Userscript @Version uses EXTENSION_BUILD_VERSION only (no build ID) for x.y.z format - Rebuild userscript bundle
- _data/userscript_managers.yml: Tampermonkey, Violentmonkey, Userscripts, Stay install URLs - getstarted.md: userscript installation section with step-by-step and manager links - index.md: link userscript managers by name on home page
- jekyll serve --host 0.0.0.0 so server listens on all interfaces - script/server-website prints LAN URL when available (macOS ipconfig / Linux hostname -I)
…hout SSH CI fails with 'Permission denied (publickey)' when cloning github: specifier. Switch to git+https://github.com/... in package.json and lockfile resolution.
…flow copy-assets.sh reads from browser-extensions/extension/node_modules/; add pnpm install --frozen-lockfile step so node_modules exists.
Deploy steps (checkout staging repo, reconcile branches, gh-pages deploy) now run only when github.repository is fraz3alpha/running-challenges and actor is not dependabot. Forks still run the full build but skip deploy.
… job script/cibuild runs Playwright UI tests; Chromium was not installed in this job, causing all 35 Playwright tests to fail in CI. Add the same playwright install step used by the integration-test job.
- Set website/Gemfile.lock BUNDLED WITH to 2.6.9 for dev/CI consistency - Add mise run bundle-install and bundle-update-bundler for website gems
Running Challenges on iPhone!
- Add mise and pnpm install so copy-assets.sh has node_modules (fixes build) - Switch to limjh16/jekyll-action-ts, deploy with peaceiris/actions-gh-pages - Deploy step runs only when github.repository is fraz3alpha/running-challenges
Escape dynamic content used in progress messages, introduce a shared escape_html helper, and wire it into the extension and userscript so status/errors can't inject markup.
Security Fix.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Context
parkrun's official app is nice, and all, but there are some views on my data that I really quite like from this little extension. I'd actually quite like to have a Userscript version of this to reduce the cycle time between tweaks and running in the browser (Safari, mostly). So I dusted off the repository and tried to remember how everything fitted together. I realised that there were some things I could simplify to make the SDLC more responsive. Like having a src/ directory that represents the common case and allows running unit tests. And using mocks rather than firing up Nginx instances to test the UI.
After all that, bundling a Userscript was relatively straightforward.
Change
See individual commits for finer details.
Confirmation