Automattic / Automattic/crowdsignal-forms
Survey/Quiz block: "View Results" links to generic dashboard instead of the specific survey
- Dominant language
- PHP
- Stars
- 15
- Forks
- 10
- Avg merge
- 13m
- Merged PRs (30d)
- 1
Description
## Description
In the Survey block (and its Quiz variation, `crowdsignal-forms/cs-embed`), the **Results** panel in the block sidebar has a "View results on crowdsignal.com" link and a **View Results** button. Both point to the generic Crowdsignal dashboard homepage rather than the results/report page for the specific embedded survey.
A user who clicks "View Results" lands on `https://app.crowdsignal.com/` and has to manually find the right survey, instead of being taken straight to that survey's results.
## Steps to reproduce
1. Add a Survey or Quiz block to a post and embed a survey (e.g. a `survey.fm` link).
2. Select the block and open the **Block → Results** panel in the sidebar.
3. Click **View Results** (or the "crowdsignal.com" link).
4. Observe it opens `https://app.crowdsignal.com/?ref=quizmbedblock` — the generic dashboard — not the embedded survey's report.
## Expected
The link should open the results/report page for the specific survey that's embedded in the block.
## Actual
Both the "View results on crowdsignal.com" link and the "View Results" button open the generic dashboard homepage.
## Notes
- Source: `client/blocks/cs-embed/sidebar.js` — both the text link and the button use `href={ dashboardLink }`, and `dashboardLink` is a hardcoded generic URL (from `variations.js` / `attributes.js`). Nothing derives a per-survey URL from the block's `url` attribute.
- For contrast, the Feedback block builds a survey-specific results URL: `client/blocks/feedback/sidebar.js` -> `https://app.crowdsignal.com/surveys/${ surveyId }/report/overview`.
- One wrinkle for whoever fixes this: the embed URL and its oEmbed response only expose the survey **slug**, not the numeric survey ID needed for the report URL — so resolving the ID will take some extra work.
Contributor guide
No contributing guide indexed for this repository
Research direction
Start in client/blocks/cs-embed/sidebar.js and trace dashboardLink through variations.js and attributes.js. Compare the Feedback block URL construction in client/blocks/feedback/sidebar.js, then investigate how the embedded slug and oEmbed response could identify the numeric survey ID. Done means both Results links open the embedded survey’s report page rather than the generic dashboard.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 52/100