Point the HTML example at a real published sheet - #14
Merged
Merged
Conversation
The example demonstrated the library with inline CSV, which proved the rendering but not the thing the project is actually for. It now loads a real Google Sheet published with File > Share > Publish to web, through a plain src attribute and no JavaScript at all -- which is the headline use case and should be the first thing anyone sees. Verified end to end against Google's live endpoint: toCsvUrl rewrote /pubhtml -> /pub?output=csv 200 text/csv, 5,043 bytes, fetched in 588ms 22 events parsed, 0 unparseable 3 spans (2 exact from End, 1 inferred from prose), 6 media links Rendered: 22 markers over 8 lanes, 0 overlapping labels, 20 ticks, 3 span bars of which 1 hollow, Wikipedia lead image fetched Also documents a real trap found while testing: the element follows the reader's prefers-color-scheme by default, so it turns dark on a light-only page for anyone with dark mode on. theme="light" pins it, and the README now says so where someone will actually read it. The roadmap example keeps its inline data, so the page still demonstrates a timeline that works with no network.
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.
What this changes
The HTML example loaded inline CSV. That proved the rendering worked but not the thing the project exists for. It now loads a real published Google Sheet through a plain
srcattribute, with no JavaScript on the page at all.End-to-end verification against Google's live endpoint
This was the last untested part of the project — everything before it used hand-written fixtures.
/pubhtml→/pub?output=csv200 text/csv, 5,043 bytes, 588 msEnd, one inferred from proseThe live sheet and the same data as a local CSV parse identically.
A trap worth documenting
The element follows the reader's
prefers-color-scheme, not the host page's. On a light-only page a visitor with dark mode gets a dark timeline against a white background — which is exactly what happened while testing.theme="light"pins it, and the README now says so in the theming section, since this will bite anyone embedding on a fixed-palette site.Notes
The roadmap example keeps its inline data on purpose, so the page still demonstrates a timeline that works with no network.
npm testpassesnpm run buildpassespackages/corehave a test — n/a, examples and docs only