Skip to content

feat: Add structured data audit features including JSON-LD and Schema…#213

Merged
dermatz merged 7 commits into
mainfrom
feat/structured-data-audit
Jun 29, 2026
Merged

feat: Add structured data audit features including JSON-LD and Schema…#213
dermatz merged 7 commits into
mainfrom
feat/structured-data-audit

Conversation

@dermatz

@dermatz dermatz commented Jun 29, 2026

Copy link
Copy Markdown
Member

This pull request introduces a comprehensive "Structured Data" audit group to the MageForge Toolbar, with new viewers for JSON-LD and Schema.org microdata/RDFa, along with supporting UI and style changes. These enhancements make it easier to inspect and debug structured data on web pages directly from the findings panel.

Structured Data Auditing:

  • Added a new "Structured Data" audit group, including:
    • A JSON-LD viewer that lists all <script type="application/ld+json"> blocks, parses and displays them, flags errors, and allows copying valid JSON. [1] [2]
    • A Schema.org microdata and RDFa viewer that scans the DOM for itemscope/itemtype and typeof/property attributes, presenting a structured, interactive tree view of found data. [1] [2]
  • The missing JSON-LD audit was moved from the "SEO" group to "Structured Data" for better organization. [1] [2]

UI and Styling:

  • Introduced new CSS styles for the JSON-LD viewer, Schema.org viewer, and structured data badges, ensuring consistent and clear presentation in the findings panel. [1] [2]
  • Added a new CSS variable for structured data group color, used in the toolbar.
  • Updated the toolbar tab label rendering to show the full label instead of just the first word, improving clarity for new audit groups.

Summary of most important changes:

Structured Data Auditing

  • Added seo-json-ld-viewer.js and schema-org-viewer.js audits for JSON-LD and microdata/RDFa, with interactive viewers in the findings panel. [1] [2]
  • Registered the new audits and the "Structured Data" audit group in the audit index, and moved the missing JSON-LD audit into this group. [1] [2] [3]

UI and Styling

  • Added new CSS module toolbar/_jsonld-viewer.css and imported it into the main toolbar stylesheet for viewer styling. [1] [2]
  • Introduced a CSS variable for structured data group color.
  • Updated tab label rendering to display the full label for better group identification.

Comment thread src/view/frontend/web/js/toolbar/audits/seo-json-ld-viewer.js Fixed

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

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 extends the MageForge Toolbar audits by adding a new Structured Data group with interactive page-level viewers for JSON-LD and Schema.org microdata/RDFa, plus supporting UI and styling updates to present findings cleanly in the panel.

Changes:

  • Added two new structured-data audits: JSON-LD Viewer and Schema.org Viewer (microdata + RDFa tree/blocks).
  • Introduced a new Structured Data audit group, moved the “Missing JSON-LD” audit into it, and registered the new audits.
  • Updated toolbar UI/styling: full tab labels, new group colour token, and viewer-specific CSS.

Reviewed changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
src/view/frontend/web/js/toolbar/ui/constants.js Adds an icon mapping for the new structured-data group.
src/view/frontend/web/js/toolbar/ui/build.js Updates tab rendering to show full group labels (not just the first word).
src/view/frontend/web/js/toolbar/audits/seo-json-ld-viewer.js Implements JSON-LD block parsing + expandable viewer + clipboard copy action.
src/view/frontend/web/js/toolbar/audits/schema-org-viewer.js Implements Schema.org microdata + RDFa DOM scanning and viewer rendering.
src/view/frontend/web/js/toolbar/audits/index.js Registers the new audit group and adds/moves audits into it.
src/view/frontend/web/css/toolbar/_variables.css Introduces a new CSS variable for structured-data group colour.
src/view/frontend/web/css/toolbar/_jsonld-viewer.css Adds viewer styles for JSON-LD and Schema.org presentation within findings.
src/view/frontend/web/css/toolbar.css Imports the new viewer stylesheet into the main toolbar CSS bundle.

Comment thread src/view/frontend/web/js/toolbar/audits/seo-json-ld-viewer.js Outdated
Comment thread src/view/frontend/web/js/toolbar/audits/seo-json-ld-viewer.js Outdated
Comment thread src/view/frontend/web/js/toolbar/audits/schema-org-viewer.js
Comment thread src/view/frontend/web/js/toolbar/audits/schema-org-viewer.js
Comment thread src/view/frontend/web/js/toolbar/audits/index.js
Comment thread src/view/frontend/web/css/toolbar/_jsonld-viewer.css
Comment thread src/view/frontend/web/js/toolbar/audits/seo-json-ld-viewer.js Fixed
Copilot AI review requested due to automatic review settings June 29, 2026 20:46

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 9 out of 9 changed files in this pull request and generated 6 comments.

Comment thread src/view/frontend/web/js/toolbar/audits/seo-json-ld-viewer.js
Comment thread src/view/frontend/web/js/toolbar/audits/seo-json-ld-viewer.js
Comment thread src/view/frontend/web/js/toolbar/audits/seo-json-ld-viewer.js Outdated
Comment thread src/view/frontend/web/js/toolbar/audits/seo-json-ld-viewer.js Outdated
Comment thread src/view/frontend/web/js/toolbar/audits/schema-org-viewer.js
Comment thread src/view/frontend/web/css/toolbar/_variables.css Outdated
Copilot AI review requested due to automatic review settings June 29, 2026 21:11

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 9 out of 9 changed files in this pull request and generated 4 comments.

Comment thread src/view/frontend/web/js/toolbar/audits/seo-json-ld-viewer.js
Comment thread src/view/frontend/web/js/toolbar/audits/seo-json-ld-viewer.js
Comment thread src/view/frontend/web/js/toolbar/audits/seo-json-ld-viewer.js Outdated
Comment thread src/view/frontend/web/js/toolbar/audits/seo-json-ld-viewer.js
@dermatz dermatz merged commit 7e17433 into main Jun 29, 2026
16 checks passed
@dermatz dermatz deleted the feat/structured-data-audit branch June 29, 2026 21:35
@github-actions github-actions Bot mentioned this pull request Jun 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants