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

Get inspired! Check out the entries from the Power BI DataViz World Championships preliminary rounds and give kudos to your favorites. View the vizzies.

Reply
Mlemmers
Helper I
Helper I

Shape theme json fill color not showing

Hey,

 

I'm working on a power bi theme json and have been perusing different githubs with source code for this, https://github.com/MattRudy/PowerBI-ThemeTemplates/blob/master/Shape.json for example. The new shapes don't use visual style basicShape anymore but shape. However, I'm unable to change the fill to white and not show the outline. The shapes are filled with the first color specified in the "dataColors" list. I don't know if it matter that fill and line are now in the dropdown menu under shape style in desktop. Can someone help me out on this or point me to updated documentation?

My code: 

	"visualStyles": {
	
	        "shape": {
            "*": {
              "general": [{
					"keepLayerOrder": true
				}],
				"line": [{
					"show": false
				}],
				"title": [{
					"show": false
				}],
				"background": [{
					"show": false
				}],
				"fill": [{
					"show": true,
					"fillColor": { "solid": { "color": "#FFFFFF"}},
					"transparency": 0
				}],
				"visualHeader": [{
					"show": false
				}]
            }
        }

 

1 ACCEPTED SOLUTION
v-yiruan-msft
Community Support
Community Support

Hi @Mlemmers ,

Thanks for reaching out to us with your problem. Base on your decription, it seems that the fill color not display for the shape even though set it in theme file. You can adjust the codes as below and check if it works:

{
    "name": "Custom Theme",
    "dataColors": ["#01B8AA", "#374649", "#FD625E", "#F2C80F", "#5F6B6D", "#8AD4EB"],
    "visualStyles": {
        "shapes": {
            "*": {
                "general": [{
                    "keepLayerOrder": true
                }],
                "fill": [{
                    "show": true,
                    "fillColor": {
                        "solid": {
                            "color": "#FFFFFF"
                        }
                    }
                }],
                "outline": [{
                    "show": false
                }],
                "visualHeader": [{
                    "show": false
                }]
            }
        }
    }
}

Best Regards

Community Support Team _ Rena
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
bergmaal
Regular Visitor

This answer does not solve the problem with fill color and outline color. The "show" property works on both, but not the color.

{
    "visualStyles": {
        "shape": {
            "*": {
                "outline": [
                    {
                        "show": true,
                        "lineColor": {
                            "solid": {
                                "color": "#ffffff"
                            }
                        }
                    }
                ],
                "fill": [
                    {
                        "show": true,
                        "fillColor": {
                            "solid": {
                                "color": "#ffffff"
                            }
                        }
                    }
                ]
            }
        }
    }
}

 

This visual style adheres to latest schema (reportThemeSchema-2.131.json), but fill color defaults to ThemeColor1, and outline color a shaded version of ThemeColor1. My guess it that this is a bug.

v-yiruan-msft
Community Support
Community Support

Hi @Mlemmers ,

Thanks for reaching out to us with your problem. Base on your decription, it seems that the fill color not display for the shape even though set it in theme file. You can adjust the codes as below and check if it works:

{
    "name": "Custom Theme",
    "dataColors": ["#01B8AA", "#374649", "#FD625E", "#F2C80F", "#5F6B6D", "#8AD4EB"],
    "visualStyles": {
        "shapes": {
            "*": {
                "general": [{
                    "keepLayerOrder": true
                }],
                "fill": [{
                    "show": true,
                    "fillColor": {
                        "solid": {
                            "color": "#FFFFFF"
                        }
                    }
                }],
                "outline": [{
                    "show": false
                }],
                "visualHeader": [{
                    "show": false
                }]
            }
        }
    }
}

Best Regards

Community Support Team _ Rena
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

We face the same issue. I tried to import this JSON, but it doesn't seem to work. The outline is still there and the fill color hasn't changed. The fill color still uses the main theme color 1. Any other options?

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

FebPBI_Carousel

Power BI Monthly Update - February 2025

Check out the February 2025 Power BI update to learn about new features.

March2025 Carousel

Fabric Community Update - March 2025

Find out what's new and trending in the Fabric community.