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

July 7 - July 17 | Round 2 of the Power BI Dataviz World Championships. Don't miss your chance! Learn more

Reply
Anonymous
Not applicable

Creating json theme template file

Hi,

 

I'm trying to create a json theme for my business, but running into trouble when trying to be specific about each visual. I'm able to get things to work for a general visual style, but I would like to specify each visual by itself. 
Below in my file, it seems that my clusteredbarchart is not applying what I want. I've tried removing the "visualstyles" right above clusteredbarchart, but that creates an error (the two lines I've commented out to show which lines I'm talking about). When adding those to lines back in it's runs, but nothing happens. Can anyone help me get this to work for just this visual? Then I hope i can add additional ones without issues.

 

{
	"name": "Testing",
    "dataColors": ["#F32345", "#6C0819", "#FDD3DA", "#008FFB", "#00365F", "#00A25E", "#003B23", "#F44900", "#5E1C00"],
    "firstLevelElements": "#292A2C",
    "secondLevelElements": "#292A2C",
    "thirdLevelElements": "#F7F7F8",
    "fourthLevelElements": "#F7F7F8",
    "background": "#F7F7F8",
    "secondaryBackground": "#292A2C",
    "tableAccent": "#292A2C",
    "good": "#6BF198",
    "neutral": "#FFD046",
    "bad": "#FF9A24",
    "maximum": "#F32345",
    "center": "#6C0819",
    "minimum": "#FDD3DA",
    "null": "#FFFFFF",
    "textClasses": {
        "callout": {
            "fontSize": 32,
            "fontFace": "Segoe UI",
            "color": "#0D0D0E"
        },
        "title": {
            "fontSize": 14,
            "fontFace": "Segoe UI",
            "color": "#0D0D0E"
        },
        "header": {
            "fontSize": 12,
            "fontFace": "Segoe UI Semibold",
            "color": "#0D0D0E"
        },
        "label": {
            "fontSize": 12,
            "fontFace": "Segoe UI",
            "color": "#0D0D0E"
        }
    },
	"visualStyles": {
        "page": {
            "*": {
                "background": [{
                    "color": { "solid": { "color": "#F7F7F8" } },	
                    "transparency": 0
                }],
                "outspace": [{
                    "color": { "solid": { "color": "#F7F7F8" } },
                    "transparency": 0
                }],
                "outspacePane": [{
                    "backgroundColor": { "solid": { "color": "#FFFFFF" } },
                    "foregroundColor": { "solid": { "color": "#292A2C" } },
                    "borderColor": { "solid": { "color": "#292A2C" } },
                    "transparency": 0,
                    "titleSize": 12,
                    "headerSize": 9,
                    "fontFamily": "Segoe UI",
                    "border": true
                }],
                "filterCard": [
		    {
                        "$id": "Applied",
                        "backgroundColor": { "solid": { "color": "#FFFFFF" } },
                        "foregroundColor": { "solid": { "color": "#292A2C" } },
                        "borderColor": { "solid": { "color": "#292A2C" } },
                        "inputBoxColor": { "solid": { "color": "#FFFFFF" } },
                        "transparency": 0,
                        "textSize": 10,
                        "fontFamily": "Segoe UI",
                        "border": true
                    },
                    {
                        "$id": "Available",
                        "backgroundColor": { "solid": { "color": "#FFFFFF" } },
                        "foregroundColor": { "solid": { "color": "#292A2C" } },
                        "borderColor": { "solid": { "color": "#292A2C" } },
                        "inputBoxColor": { "solid": { "color": "#FFFFFF" } },
                        "transparency": 0,
                        "textSize": 10,
                        "fontFamily": "Segoe UI",
                        "border": true
                    }
		]
            }
        },
 //       "visualStyles": {
                "clusteredBarChart": {
                    "*": {
                        "general": [{
                            "responsive": true,
                            "keepLayerOrder": true
                        }],
                        "legend": [{
                            "show": true,
                            "position": "Bottom",
                            "showTitle": true,
                            "titleText": "",
                            "labelColor": { "solid": { "color": "#01B8AA"}},
                            "fontFamily": "Courier New",
                            "fontSize": 18
                        }],
                        "categoryAxis": [{
                            "show": true,
                            "position": "Right",
                            "labelColor": { "solid": { "color": "#01B8AA"}},
                            "fontSize": 14,
                            "fontFamily": "Courier New",
                            "preferredCategoryWidth": 30,
                            "maxMarginFactor": 28,
                            "innerPadding": 22,
                            "concatenateLabels": true,
                            "showAxisTitle": true,
                            "axisStyle": "showTitleOnly",
                            "titleColor": { "solid": { "color": "#01B8AA"}},
                            "titleText": "asdf",
                            "titleFontSize": 12,
                            "titleFontFamily": "Segoe UI"
                        }],
                        "valueAxis": [{
                            "show": true,
                            "position": "Right",
                            "axisScale": "Linear",
                            "start": 0,
                            "end": 10,
                            "labelColor": { "solid": { "color": "#01B8AA"}},
                            "fontSize": 14,
                            "fontFamily": "Courier New",
                            "labelDisplayUnits": "0",
                            "labelPrecision": "Auto",
                            "showAxisTitle": true,
                            "axisStyle": "showTitleOnly",
                            "color": { "solid": { "color": "01B8AA"}},
                            "titleText": "asdf",
                            "titleFontSize": 12,
                            "titleFontFamily": "Courier New",
                            "gridlineShow": true,
                            "gridlineColor": { "solid": { "color": "#01B8AA"}},
                            "gridlineThickness": 2,
                            "gridlineStyle": "dashed"
                        }],
                        "dataPoint": [{
                            "defaultColor": { "solid": { "color": "#448822"}}
                        }],
                        "labels": [{
                            "show": true,
                            "color": { "solid": { "color": "#EEEEEE"}},
                            "labelDisplayUnits": "0",
                            "labelPrecision": 1,
                            "labelPosition": "OutsideEnd",
                            "fontSize": 11,
                            "fontFamily": "Courier New",
                            "enableBackground": true,
                            "backgroundColor": { "solid": { "color": "#0928DD"}},
                            "backgroundTransparency": 30
                        }],		
                        "plotArea": [{
                            "transparency": 20
                        }]
                    }
                }
//        }
        }
}

 

Thanks!


 

 

1 ACCEPTED SOLUTION
Anonymous
Not applicable
1 REPLY 1
Anonymous
Not applicable

Helpful resources

Announcements
FabCon and SQLCon Barcelona 2026

FabCon & SQLCon – Barcelona 2026

Join us in Barcelona for FabCon and SQLCon, the Fabric, Power BI, SQL, and AI community event. Save €200 with code FABCMTY200.

60 days of Data Days Carousel

Data Days 2026

Join Data Days 2026: 60 days of free live/on-demand sessions, challenges, study groups, and certification opportunities.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Top Solution Authors