Skip to content

Add content error for non-absolute width SVGs#753

Merged
axlewin merged 2 commits intomainfrom
improvement/svg-width-error
Feb 2, 2026
Merged

Add content error for non-absolute width SVGs#753
axlewin merged 2 commits intomainfrom
improvement/svg-width-error

Conversation

@sjd210
Copy link
Copy Markdown
Contributor

@sjd210 sjd210 commented Jan 29, 2026

Checks all Media for SVGs containing non-absolute width (%-based width, or no width at all) via a regex match and adds it as a non-critical content error if so.

Since we don't process SVGs as content, this is the best way of dealing with this that I can think of. This means there will be no warning for SVGs not yet used as a "src", and multiple warnings for a single SVG used multiple times - but both of these are rare cases so I think it's okay.

@codecov
Copy link
Copy Markdown

codecov Bot commented Jan 29, 2026

Codecov Report

❌ Patch coverage is 0% with 6 lines in your changes missing coverage. Please review.
✅ Project coverage is 38.24%. Comparing base (9585009) to head (13966b6).
⚠️ Report is 129 commits behind head on main.

Files with missing lines Patch % Lines
...ava/uk/ac/cam/cl/dtg/segue/etl/ContentIndexer.java 0.00% 6 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #753      +/-   ##
==========================================
- Coverage   38.25%   38.24%   -0.01%     
==========================================
  Files         541      541              
  Lines       23664    23670       +6     
  Branches     2822     2824       +2     
==========================================
  Hits         9053     9053              
- Misses      13735    13741       +6     
  Partials      876      876              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@axlewin axlewin merged commit 6ca4443 into main Feb 2, 2026
5 checks passed
@axlewin axlewin deleted the improvement/svg-width-error branch February 2, 2026 12:11
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.

2 participants