Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
GrossoKubo
Frequent Visitor

PowerBI Custom theme fill card background (new Slicer)

Hello, I'm trying to modify the coloring of cards on hover and on select using the PowerBI theme. The desktop counterpart for this would be

GrossoKubo_1-1714480972806.png

 

, but I can't seem to find an equivalent with the theme. I've tried using the background attribute, but it doesn't change the background of the cards, only the background of the visualization and the voice customFill doesn't have an id option.

What should I add to the theme? 

GrossoKubo_2-1714480988188.png

 

 

 

3 REPLIES 3
MFelix
Super User
Super User

Hi @GrossoKubo 

 

This should be the code for all the status of the slicer:

 

 "value": [
          {
            "$id": "default",
            "fontColor": {
              "solid": {
                "color": "#FFFFFF"
              }
            },
            "fontSize": 8,
            "fontFamily": "Segoe UI",
            "bold": false,
            "italic": false,
            "underline": false,
            "horizontalAlignment": "left",
            "textWrap": true,
            "labelDisplayUnits": 0,
            "labelPrecision": 0,
            "customFormatString": "",
            "showBlankAs": "--",
            "transparency": 0
          },
          {
            "$id": "hover",
            "fontColor": {
              "solid": {
                "color": "#FFFFFF"
              }
            },
            "fontSize": 8,
            "fontFamily": "Segoe UI",
            "bold": false,
            "italic": false,
            "underline": false,
            "horizontalAlignment": "left",
            "textWrap": true,
            "labelDisplayUnits": 0,
            "labelPrecision": 0,
            "customFormatString": "",
            "showBlankAs": "--",
            "transparency": 0
          },
          {
            "$id": "selected",
            "fontColor": {
              "solid": {
                "color": "#FFFFFF"
              }
            },
            "fontSize": 8,
            "fontFamily": "Segoe UI",
            "bold": false,
            "italic": false,
            "underline": false,
            "horizontalAlignment": "left",
            "textWrap": true,
            "labelDisplayUnits": 0,
            "labelPrecision": 0,
            "customFormatString": "",
            "showBlankAs": "--",
            "transparency": 0
          },
          {
            "$id": "disabled",
            "fontColor": {
              "solid": {
                "color": "#FFFFFF"
              }
            },
            "fontSize": 8,
            "fontFamily": "Segoe UI",
            "bold": false,
            "italic": false,
            "underline": false,
            "horizontalAlignment": "left",
            "textWrap": true,
            "labelDisplayUnits": 0,
            "labelPrecision": 0,
            "customFormatString": "",
            "showBlankAs": "--",
            "transparency": 0
          },
          {
            "show": false
          }
        ]

 

don't mind the values is just a test


Regards

Miguel Félix


Did I answer your question? Mark my post as a solution!

Proud to be a Super User!

Check out my blog: Power BI em Português



Hi @MFelix, so there is no way to fill the cards background using the theme?

Hi @GrossoKubo ,

 

Sorry I misslead you with the previous code there is an additional property for the background of the cards:

 

"fillCustom": [
          {
            "$id": "default",
            "image": {
              "name": "",
              "url": "",
              "scaling": "Normal"
            },
            "fillColor": {
              "solid": {
                "color": "#FFFFFF"
              }
            },
            "transparency": 0,
            "imageTransparency": 0
          },
          {
            "$id": "hover",
            "image": {
              "name": "",
              "url": "",
              "scaling": "Normal"
            },
            "fillColor": {
              "solid": {
                "color": "#BBAEED"
              }
            },
            "transparency": 16,
            "imageTransparency": 0
          },
          {
            "$id": "selected",
            "image": {
              "name": "",
              "url": "",
              "scaling": "Normal"
            },
            "fillColor": {
              "solid": {
                "color": "#FFFFFF"
              }
            },
            "transparency": 0,
            "imageTransparency": 0
          },
          {
            "$id": "disabled",
            "image": {
              "name": "",
              "url": "",
              "scaling": "Normal"
            },
            "fillColor": {
              "solid": {
                "color": "#FFFFFF"
              }
            },
            "transparency": 0,
            "imageTransparency": 0
          },
          {
            "show": true
          }
        ]

Regards

Miguel Félix


Did I answer your question? Mark my post as a solution!

Proud to be a Super User!

Check out my blog: Power BI em Português



Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel1

Power BI Monthly Update - May 2024

Check out the May 2024 Power BI update to learn about new features.