Uh oh!
There was an error while loading. Please reload this page.
Refine poll headers, Markdown takeaways and demographic chart data - #78
Merged
Conversation
Greptile SummaryPoll publication pages now use a compact author-free header, support optional subtitles and Markdown takeaways, and expose crosstab data beneath inline charts.
Confidence Score: 5/5The PR appears safe to merge. No blocking failure remains.
|
| Filename | Overview |
|---|---|
| src/components/content/PollChartData.tsx | Adds lazy crosstab loading and a generic breakdown selector, resolving the previous inaccurate demographic label. |
| src/lib/polls/crosstabs.ts | Validates crosstab exports, matches exact question IDs, filters unknown categories, and suppresses columns with insufficient bases. |
| src/components/content/InlineChart.tsx | Integrates the shared tooltip and switches View data to crosstabs when an authenticated download URL is available. |
| src/components/content/ArticlePage.tsx | Applies poll-specific headers and layout, renders key messages as Markdown, and passes crosstab URLs into article charts. |
| src/app/memos/[slug]/MemoHero.tsx | Adds optional subtitles and a compact poll variant that omits author and supporter presentation. |
| src/lib/api/articles.ts | Normalizes the optional poll subtitle at the API boundary. |
Flowchart
%%{init: {'theme': 'neutral'}}%%
flowchart LR
A[Poll article chart] --> B[View data]
B --> C[Authenticated crosstabs download]
C --> D[Parse and suppress bases below 50]
D --> E[Match table by question ID]
E --> F[Choose breakdown]
F --> G[Render overall and selected columns]
Reviews (2): Last reviewed commit: "Label all crosstab comparisons as breakd..." | Re-trigger Greptile
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
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 freeto 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.
Poll pages now show a tighter publication header and let readers explore demographic results directly beneath each chart.
Validation: TypeScript, ESLint for affected components and libraries, all 14 poll tests, and git diff checks pass. Based on latest main.
The optional subtitle requires the companion York Factory subtitle migration/API changes, which remain local; it stays hidden until the API provides a value. Customer download suppression is handled by York Factory PR #125, with defensive suppression in these frontend tables.