Skip to content

Adds links to screenshots when include_screenshots is true#137

Merged
lindseywild merged 32 commits intomainfrom
adds-screenshots
Feb 20, 2026
Merged

Adds links to screenshots when include_screenshots is true#137
lindseywild merged 32 commits intomainfrom
adds-screenshots

Conversation

@lindseywild
Copy link
Contributor

@lindseywild lindseywild commented Feb 19, 2026

Adds links to screenshots (off by default).

This can be configured and turned on if include_screenshots is set to true.

GH Staff only - testing results

Screen shot of an issue with a new 'View screenshot' link

`;
const body = `## What

const body = `## What
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Prettier / eslint cleanup -- I have it installed locally on VSCode so you may see some unrelated changes that are purely linting. Once we add eslint/Prettier in this repo it will be updated if it doesn't follow suit with the guidelines anyway.

@lindseywild lindseywild marked this pull request as ready for review February 19, 2026 20:55
@lindseywild lindseywild requested a review from a team as a code owner February 19, 2026 20:55
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds screenshot capture functionality to the accessibility scanner. When enabled (default), the scanner captures full-page screenshots during accessibility scans and stores them in a gh-cache branch, then includes links to these screenshots in the generated GitHub issues.

Changes:

  • Added include_screenshots input parameter (defaults to true) to control screenshot capture
  • Implemented screenshot capture in the find action using Playwright
  • Enhanced gh-cache save/delete actions to handle directories in addition to files
  • Updated issue body generation to include screenshot links when available
  • Added screenshot_repo parameter to support cross-repository screenshot references
  • Added comprehensive test coverage for screenshot-related functionality in the file action

Reviewed changes

Copilot reviewed 14 out of 16 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
action.yml Added include_screenshots input, passed to find action, and added step to save screenshots to gh-cache
.github/actions/gh-cache/save/action.yml Enhanced to handle both files and directories, with empty directory checking
.github/actions/gh-cache/delete/action.yml Updated git commands for better directory handling
.github/actions/find/src/types.d.ts Added optional screenshotId field to Finding type
.github/actions/find/src/index.ts Added logic to read and pass include_screenshots parameter
.github/actions/find/src/findForUrl.ts Implemented screenshot capture using Playwright with UUID-based filenames
.github/actions/find/action.yml Added include_screenshots input parameter
.github/actions/file/tests/reopenIssue.test.ts Added tests for screenshot repo parameter handling in reopenIssue
.github/actions/file/tests/openIssue.test.ts Added tests for screenshot repo parameter handling in openIssue
.github/actions/file/tests/generateIssueBody.test.ts Added tests for screenshot URL generation and omission
.github/actions/file/src/types.d.ts Added optional screenshotId field to Finding type
.github/actions/file/src/reopenIssue.ts Updated to generate and include issue body with screenshot links when reopening
.github/actions/file/src/openIssue.ts Added screenshotRepo parameter for proper screenshot URL generation
.github/actions/file/src/index.ts Added screenshot_repo input handling and passed to openIssue/reopenIssue
.github/actions/file/src/generateIssueBody.ts Added screenshot section to issue body when screenshotId is present
.github/actions/file/action.yml Added screenshot_repo input parameter

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link
Member

@helen helen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Requesting that corresponding readme changes also be included in this before merge :)

@smockle
Copy link
Collaborator

smockle commented Feb 20, 2026

I’m going to remove this from the FR queue. If FR support is required, please feel free to re-add it!

abdulahmad307
abdulahmad307 previously approved these changes Feb 20, 2026
Copy link

@abdulahmad307 abdulahmad307 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No blocking concerns. Just a few minor readability and organizational thoughts.

repository,
issue_number: issueNumber,
state: 'open',
...body,

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I swear I'm not trying to be annoying 🙏
one final nit: if we don't destructure this here, but assign it directly, the assignment on line 15 can become a 1-liner. body = generateIssueBody...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated, thank you for calling out this silly thing!!

abdulahmad307
abdulahmad307 previously approved these changes Feb 20, 2026
@lindseywild lindseywild merged commit cc07ea1 into main Feb 20, 2026
6 checks passed
@lindseywild lindseywild deleted the adds-screenshots branch February 20, 2026 21:38
@helen helen linked an issue Feb 20, 2026 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add a screenshot to the Issue to help identify the problem

6 participants