Ticket T1287263
Visible to All Users
Duplicate

We have closed this ticket because another page addresses its subject:

SCSS Variables - Overriding the `$dx-fl-caption-color` variable does not change the resulting theme file

SCSS Variables ignored

created 8 days ago (modified 8 days ago)

Hi,

i have a custom.scss and i want to modify the color of the formlayout caption and the variable for that is $dx-fl-caption-color which doesn´t do anything when i set another color.

what can i do? i dont know if it is a bug or if i have to implement a different approach.

Thank you in advance.

Answers approved by DevExpress Support

created 7 days ago (modified 5 days ago)

Hi Jose,

Thank you for the code snippet. To achieve your goal, specify the custom rule for the caption color after you import the theme:

Code
//custom.scss ... @import "C:/Program Files/DevExpress 24.2/Components/Sources/DevExpress.Blazor.Themes/scss/blazing-berry/blazing-berry.bs5.scss"; .dxbl-fl .dxbl-fl-cpt{ color: red; }

Let me know if this solution meets your requirements.

Answer updated:

What i want to know is why the variable "$dx-fl-caption-color" doesn´t work when i assign another color like this:

This behavior is unexpected, and I've already passed this information to our developers. We are going to fix this in the near feature. I created a public report, so that you will be notified when we have news on this regard: T1287866: SCSS Variables - Overriding the $dx-fl-caption-color variable does not change the resulting theme file.

    Comments (2)
    J J
    Jose Ignacio Lopez Bueno 6 days ago

      Hi Alexander,

      This solves my problem, yes. I fact, i have that selector in my custom.scss. But thats not the point.
      The thing is when i inspect the css code in any formlayout the code would be like this:

      CSS
      .dxbl-fl .dxbl-fl-cpt{ color: var(--dxbl-fl-caption-color); }

      and the "–dxbl-fl-caption-color" variable in your theme its filled with "$dx-fl-caption-color".

      What i want to know is why the variable "$dx-fl-caption-color" doesn´t work when i assign another color like this:

      Code
      $dx-fl-caption-color : $primary;

      when, for example, the code below it does work (also provided in the file)

      Code
      $dx-fl-caption-font-weight : 700;

      Thank you

      Alexander (DevExpress Support) 5 days ago

        Thank you for the update.

        What i want to know is why the variable "$dx-fl-caption-color" doesn´t work when i assign another color like this:

        This behavior is unexpected, and I've already passed this information to our developers. We are going to fix this in the near feature. I created a public report, so that you will be notified when we have news on this regard: T1287866: SCSS Variables - Overriding the $dx-fl-caption-color variable does not change the resulting theme file.

        Disclaimer: The information provided on DevExpress.com and affiliated web properties (including the DevExpress Support Center) is provided "as is" without warranty of any kind. Developer Express Inc disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.

        Confidential Information: Developer Express Inc does not wish to receive, will not act to procure, nor will it solicit, confidential or proprietary materials and information from you through the DevExpress Support Center or its web properties. Any and all materials or information divulged during chats, email communications, online discussions, Support Center tickets, or made available to Developer Express Inc in any manner will be deemed NOT to be confidential by Developer Express Inc. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.