SparkDevNetwork / Rock

An open source CMS, Relationship Management System (RMS) and Church Management System (ChMS) all rolled into one.
http://www.rockrms.com
572 stars 347 forks source link

v13 Alpha theme change and save results in bootstrap and less error #4869

Closed smross closed 2 years ago

smross commented 2 years ago

Prerequisites

A Picture Is worth a Thousand Words

Theme Styler | Rock RMS 2022-01-03 14-18-25

Description

When changing the Rock _theme an error is thrown, but the process completes (and without an exception)

Steps to Reproduce

(this was discovered during Alpha testing. I attempted to make a Rock theme change after we upgraded our testing Rock instance to v13 Alpha

  1. Go to 'Admin Tools > CMS Configuration > Themes'
  2. Click on the 'Rock' theme
  3. Change the 'Primary Brand Color' to a different color (I used #ffeb3b )
  4. Select the Save button
  5. See error
  6. Examine the exception log... there is no exception

Expected behavior:

When you select save you don't get an error

Actual behavior:

The change takes effect, but the following error happens:

Theme Styler | Rock RMS 2022-01-03 14-18-25

Text form of the error:


variable @fa-var-abacus is undefined on line 5 in file '../../../Styles/FontAwesome/_icons.less':
  [4]: .@{fa-css-prefix}-500px:before { content: @fa-var-500px; }
  [5]: .@{fa-css-prefix}-abacus:before { content: @fa-var-abacus; }
       -------------------------------------------^
  [6]: .@{fa-css-prefix}-accessible-icon:before { content: @fa-var-accessible-icon; }
A compile error occurred on connection-request.less

variable @fa-var-abacus is undefined on line 5 in file '../../../Styles/FontAwesome/_icons.less':
  [4]: .@{fa-css-prefix}-500px:before { content: @fa-var-500px; }
  [5]: .@{fa-css-prefix}-abacus:before { content: @fa-var-abacus; }
       -------------------------------------------^
  [6]: .@{fa-css-prefix}-accessible-icon:before { content: @fa-var-accessible-icon; }
A compile error occurred on email-editor.less

variable @fa-var-abacus is undefined on line 5 in file '../../../Styles/FontAwesome/_icons.less':
  [4]: .@{fa-css-prefix}-500px:before { content: @fa-var-500px; }
  [5]: .@{fa-css-prefix}-abacus:before { content: @fa-var-abacus; }
       -------------------------------------------^
  [6]: .@{fa-css-prefix}-accessible-icon:before { content: @fa-var-accessible-icon; }
A compile error occurred on group-placement.less

variable @fa-var-abacus is undefined on line 5 in file '../../../Styles/FontAwesome/_icons.less':
  [4]: .@{fa-css-prefix}-500px:before { content: @fa-var-500px; }
  [5]: .@{fa-css-prefix}-abacus:before { content: @fa-var-abacus; }
       -------------------------------------------^
  [6]: .@{fa-css-prefix}-accessible-icon:before { content: @fa-var-accessible-icon; }
A compile error occurred on group-scheduler.less

variable @fa-var-abacus is undefined on line 5 in file '../../../Styles/FontAwesome/_icons.less':
  [4]: .@{fa-css-prefix}-500px:before { content: @fa-var-500px; }
  [5]: .@{fa-css-prefix}-abacus:before { content: @fa-var-abacus; }
       -------------------------------------------^
  [6]: .@{fa-css-prefix}-accessible-icon:before { content: @fa-var-accessible-icon; }

Versions

@nate-steil may want to chime in, as he understands CSS, less, etc. better than I

smross commented 2 years ago

cc @nate-steil here's the issue I opened. If you have any insight or suggestions on a fix, fire away!

nate-steil commented 2 years ago

It looks like the error is happening then the bootstrap.less file id working on imports. There were no differences in the _icons.less file between our production (12.2) and alpha (13) version.

The files that creates the variables used by the _icons file IS different. I'm not sure whether the abacus icon was deprecated and should be removed from the _icons or if it just needs the variable added back in, but the _variables.less file is different after upgrading to v13 (we went from 12.2 to v13 so it may have been earlier). From Production (v12.2)

Screen Shot 2022-01-05 at 10 16 18 AM

From Alpha (v13)

Screen Shot 2022-01-05 at 10 19 07 AM