Problem/Motivation

My logs show plenty of these messages:

/themes/contrib/bootstrap5/images/icons/required.svg

As the referrer

/themes/contrib/bootstrap5/css/components/form.css

is listed.

There the file is referenced by

background-image: url(../../images/icons/required.svg);

But there is no images folder in bootstrap5.

Steps to reproduce

Install/upgrade bootstrap 5. I'm not sure whether I've seen this 404 before, but as I see it in my browser when inspecting sites quite often now, it might have been induced by upgrading to 3.0.3.

Proposed resolution

Change the CSS or make the requested svg available in images

CommentFileSizeAuthor
#4 images.zip1.14 KBnofue

Issue fork bootstrap5-3342492

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

nofue created an issue. See original summary.

nofue’s picture

Issue summary: View changes
superlolo95’s picture

Same for me with Bootstrap5 3.0.3.
The star indicating a mandatory field display after the label is invisible.

nofue’s picture

StatusFileSize
new1.14 KB

@superlolo95 -- thanks for your observation. I couldn't figure what the loss of "required.svg" may cause. About time to dig them up from an older installation. I attached that required.svg from a Bootstrap 3 installation, found in /themes/contrib/bootstrap/starterkits/THEMENAME/images/required.svg

As Drupal.org doesn't allow the upload of SVG, I made it a zip within it's image/folder.

To make use of it, download the image.zip file, put it in bootstrap5's directory (/themes/custom/bootstrap5) and unzip it there. If you don't have shell access, you may want do download to your local machine. Then use FTP or what you've got to create
/themes/custom/bootstrap5/images
and upload required.svg into this directory.

natts’s picture

The required.svg is not the only missing image icon that's referred to in the CSS of this bootstrap5 theme. There are 25 matches across 6 CSS files. All of those icon images being referred to are in fact available within the Drupal core starterkit_theme (core/themes/starterkit_theme/image/icons) since Drupal 9.3.

So while a quick fix is to add required.svg into the place where the CSS says that it is (bootstrap5/images/icons), I believe the correct fix is either for all of the CSS to be updated to use the 24 image icon files made available in the core starterkit_theme, or possibly, to have its own copies of all 24 of them.

  • VladimirAus committed 061f35d4 on 3.0.x
    Issue #3342492 by nofue, superlolo95, natts, VladimirAus: Required.svg...
vladimiraus’s picture

Version: 3.0.3 » 3.0.x-dev
Component: Miscellaneous » User interface
Status: Active » Fixed

Thanks for your comments.
Committed! 🍻

nofue’s picture

Fast delivery, awesome 🍻

natts’s picture

I'm grateful for the quick turnaround today, but the issue was first reported 15 days ago and apparently ignored until I followed up on it yesterday.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.

barbarae made their first commit to this issue’s fork.

barbarae’s picture

I have the problem from this stream even though it is marked as fixed. My site runs ok on drupal 9.5.10 with civicrm 5.62.0 until I try to upgrade civicrm to either 5.62.1 or civicrm 5.62.2. Then I get the error mentioned below:

https://www.jandbwebsite.com/themes/contrib/bootstrap_barrio/images/requ...

/CimarronRES/sites/default/files/css/css_J-2CXAdyTZY8175zy0hWbrQ9H-g_PZRZY9cQ86ikAsI.css:1 GET https://www.jandbwebsite.com/themes/contrib/bootstrap_barrio/images/requ... 404

This is the expanded code from the GET:
https://www.jandbwebsite.com/CimarronRES/sites/default/files/css/css_J-2...

The initial https://www.jandbwebsite.com/themes/contrib/bootstrap_barrio/images/requ... would not find any correct files because it is missing my sub domain. But the second expanded code GET has the correct sub domain (CimarronRES).

I cannot logon to my site at all because of the missing sub domain (CimarronRES) in the initial reference https://www.jandbwebsite.com/themes/contrib/bootstrap_barrio/images/requ...

I am not a "coder" so even though I can debug a bit, I do not know how/where to fix this ?

Thank you for any help - barbarae (PS I have been using drupal with civicrm since 2008 and gone through the drupal 7 to drupal 9 upgrades).

nofue’s picture

@barbarae -- I think you should direct your request to "Bootstrap Barrio" which is a different theme, this is "Bootstrap5"