You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
On the deposit form, community theme CSS is loaded in a tag like <link rel="stylesheet" type="text/css" href="/communities//community-theme-.css"> whosehref URL 404s since it's missing components. This is apparent on the demo site if you login, go to upload, and view your browser's console.
Steps to Reproduce
Login
Create a new upload outside of any existing community /uploads/new
Expected behavior
No community theme CSS should be loaded since the record is not part of a community.
Screenshots (if applicable)
Excerpt of the <head> of /uploads/new:
<title>New upload</title><linkrel="shortcut icon" type="image/x-icon" href="/static/favicon.ico"/><linkrel="apple-touch-icon" sizes="120x120" href="/static/apple-touch-icon-120.png"/><linkrel="apple-touch-icon" sizes="152x152" href="/static/apple-touch-icon-152.png"/><linkrel="apple-touch-icon" sizes="167x167" href="/static/apple-touch-icon-167.png"/><linkrel="apple-touch-icon" sizes="180x180" href="/static/apple-touch-icon-180.png"/><linkrel="stylesheet" href="/static/dist/css/3526.b4b7482b3f9ce31d1a70.css" /><!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries --><!--[if lt IE 9]> <script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script> <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script> <![endif]--><linkrel="stylesheet" type="text/css" href="/communities//community-theme-.css">
Additional context
I was unable to fix this by editing my local app-rdm and communities packages' templates. I suspect the issue is either in app-rdm's records/deposit.html or communities' base.html. The URL in the templates is like <link rel="stylesheet" type="text/css" href="/communities/{{community.slug}}/community-theme-{{ community.revision_id }}.css"> so it's clear that the slug and revision_id are missing. What's odd is both templates wrap the <link> in a condition, so it seems like it should not appear on a record with no communities. My only thought is maybe draft records are considered part of some pseudo-community which has an enabled theme (making the condition in deposit.html true) but no slug nor revision_id.
The text was updated successfully, but these errors were encountered:
Package version (if known): v12.0.5
Describe the bug
On the deposit form, community theme CSS is loaded in a tag like
<link rel="stylesheet" type="text/css" href="/communities//community-theme-.css">
whosehref
URL 404s since it's missing components. This is apparent on the demo site if you login, go to upload, and view your browser's console.Steps to Reproduce
Expected behavior
No community theme CSS should be loaded since the record is not part of a community.
Screenshots (if applicable)
Excerpt of the
<head>
of /uploads/new:Additional context
I was unable to fix this by editing my local app-rdm and communities packages' templates. I suspect the issue is either in app-rdm's records/deposit.html or communities' base.html. The URL in the templates is like
<link rel="stylesheet" type="text/css" href="/communities/{{community.slug}}/community-theme-{{ community.revision_id }}.css">
so it's clear that the slug and revision_id are missing. What's odd is both templates wrap the<link>
in a condition, so it seems like it should not appear on a record with no communities. My only thought is maybe draft records are considered part of some pseudo-community which has an enabled theme (making the condition in deposit.html true) but noslug
norrevision_id
.The text was updated successfully, but these errors were encountered: