fix: rename bundled rstudio.svg to rproject.svg, add real RStudio icon#26216
Conversation
The bundled /icon/rstudio.svg was actually the R language logo (gray oval, blue R), not the RStudio IDE logo. This was misleading when users configured the rstudio coder_app slug and relied on the bundled icon. - Rename site/static/icon/rstudio.svg to rproject.svg so the existing R language artwork stays available for templates that want it. - Add a new site/static/icon/rstudio.svg with the actual RStudio R-ball logo (blue circle, white R), extracted from the Wikimedia source and normalized to viewBox 0 0 256 256 to match the rest of the icon set. - Add rproject.svg to site/src/theme/icons.json so it shows up in the icon picker and gallery alongside rstudio.svg. - Switch the RStudio example in docs/admin/templates/extending-templates/ web-ides.md to use the bundled /icon/rstudio.svg URL, matching the convention used by every other coder_app on that page. Existing templates that referenced /icon/rstudio.svg expecting the R language oval will now render the RStudio R-ball. Templates that wanted the R language icon should switch to /icon/rproject.svg. Generated by Coder Agents on behalf of @nickvigilante. Fixes #26211 Fixes PRODUCT-383
Docs preview📖 View docs preview for |
|
/coder-agents-review |
|
Chat: Review in progress | View chat deep-review v0.7.1 | Round 1 | Last posted: Round 1, 3 findings (1 P3, 1 Nit, 1 Note), COMMENT. Review Finding inventoryFindings
Round logRound 1Panel. 1 P3, 1 Nit, 1 Note. Netero clean. Reviewed against f9dfa18..57d3bcc. About deep-reviewCRF = Coder Review Finding (P0-P4, Nit, Note)
|
There was a problem hiding this comment.
Clean, focused change. The rename is byte-identical, both SVGs conform to the icon set's viewBox convention, icons.json matches make gen output, and the docs example now uses the bundled path like every other IDE example on that page. Pariston stress-tested the problem framing across four alternative approaches and found this one is at the right causal level.
Severity count: 1 P3, 1 Nit, 1 Note.
The P3 is in the same code block the PR already touched, fixing the same class of RStudio branding error: display_name = "R Studio" has an errant space. The Note is about cache infrastructure, not a code defect.
Pariston: "I tried to build a case against this change across all four framings and couldn't. The problem is correctly understood: the file name and content were mismatched. The solution is proportional."
In reply to IC_kwDOGkVX1s8AAAABFmVHUw:
Nit [CRF-3] (site/static/icon/rproject.svg) Every other language icon in the set uses the language name: python.svg, ruby.svg, go.svg, java.svg, etc. rproject references the R Project foundation (r-project.org), not the language itself.
r.svg would be the most consistent name but is a single character, which is genuinely short for discoverability. r-lang.svg or r-language.svg would split the difference. Low severity because the name is accurate (it is the R Project logo) and the icon picker shows filenames, not slugs. (Gon)
🤖
🤖 This review was automatically generated with Coder Agents.
| @@ -1,14 +1,4 @@ | |||
| <svg width="256" height="256" viewBox="0 0 256 256" fill="none" xmlns="http://www.w3.org/2000/svg"> | |||
There was a problem hiding this comment.
Note [CRF-2] The URL /icon/rstudio.svg doesn't change but the content does, and the server marks it immortal.
site/site.go:191 serves everything under icon/ with Cache-Control: public, max-age=31536000, immutable. Browsers that loaded the old R language oval will keep showing it for up to a year after upgrade. The immutable directive suppresses conditional requests, so Last-Modified and ETag won't help.
This is pre-existing infrastructure, not a bug in this PR. Every icon in the set has the same deal. But this is the first content swap at a stable icon path, so it's the first time the coupling bites. The breaking-change note describes what the server serves; it doesn't describe what cached browsers display. Worth a sentence in the note for operators. (Hisoka)
🤖
There was a problem hiding this comment.
Good catch on the cache behavior, this is accurate. Confirmed: site/site.go serves everything under /icon/ with Cache-Control: public, max-age=31536000, immutable, so any browser that loaded the old R language oval at /icon/rstudio.svg can keep displaying it for up to a year, and immutable does suppress revalidation.
This is shared infrastructure behavior, not a defect introduced by this PR, but it's worth being explicit about for operators. I've extended the PR breaking-change note to call out the client cache, and updated the Linear ticket so we can track a follow-up on cache-busting or hashed icon URLs separately if we decide the year of staleness for content-swapped icons is worth fixing structurally.
For immediate mitigation, a hard refresh (Ctrl/Cmd+Shift+R) or an incognito session will pick up the new icon.
Not in scope for this PR; leaving the file content swap as-is per the task brief.
Reply generated by Coder Agents on behalf of @nickvigilante.

The bundled
/icon/rstudio.svgrendered the R language logo (gray oval, blue R), not the RStudio IDE logo, so templates using therstudiocoder_appand the bundled URL got the wrong artwork (#26211, PRODUCT-383).This PR:
rstudio.svg(R language logo) torproject.svgso the artwork stays available for templates that want it.rstudio.svgcontaining the actual RStudio R-ball logo, extracted from the Wikimedia source and normalized toviewBox="0 0 256 256"to match the rest of the icon set.rproject.svgtosite/src/theme/icons.jsonso it appears in the icon picker and gallery alongsiderstudio.svg.coder_app "rstudio"example indocs/admin/templates/extending-templates/web-ides.mdto reference/icon/rstudio.svg(and correctsdisplay_nameto"RStudio"), matching every other example on that page./icon/rstudio.svg/icon/rproject.svgrstudio.svg→ newrproject.svgrstudio.svgBreaking-change note. Templates that referenced
/icon/rstudio.svgexpecting the R language oval will now render the RStudio R-ball. Templates that want the R language logo should switch to/icon/rproject.svg. The Linear issue acknowledges this tradeoff.Client cache caveat.
site/site.goserves everything under/icon/withCache-Control: public, max-age=31536000, immutable, so any browser that already loaded the old artwork at/icon/rstudio.svgcan keep displaying it for up to a year before revalidating. A hard refresh (Ctrl/Cmd+Shift+R) clears it immediately. Cache-busting (hashed icon URLs) is out of scope for this fix and tracked as a possible follow-up against PRODUCT-383.Implementation notes
viewBox="0 0 256 256"because 139 of 142 SVGs insite/static/icon/already use that viewBox.rstudio.svgreferences: the only direct one issite/src/theme/icons.json. The docs file references therstudiocoder_appslug, not the icon path, so the rename does not break any callsite.viewBox 0 0 1784.1 625.9. Translating by (-8.9, -3.1) and scaling by 256/619.6 maps its bounding box onto0 0 256 256. Path coordinates are pre-computed so the file ships with no transform layer.lint/site-icons.Fixes #26211
Fixes PRODUCT-383
Generated by Coder Agents on behalf of @nickvigilante.