Forum Discussion

sushma1412_Ind's avatar
sushma1412_Ind
Frequent Visitor
4 years ago
Solved

Problem with custom theme (JSON)

Hi    I am Using JSON file for custom theme .   i already created 120 pages and i want to use this Custom theme for those 120 Pages.   When i import Json file ,its importing but not reflecting ...
  • KNP's avatar
    KNP
    4 years ago

    What I mean is, sometimes when Power BI updates happen, the structure of the JSON for the theming can change. If your custom theme doesn't match the new structure, you can run into these issues.

     

    See gif below explaining what I mean about saving a built in theme.

     

    You can now visually compare your custom theme JSON with the one saved.

    See if there's anything obvious missing etc.

     

    Here's the JSON from the theme in the gif...

    {
        "name": "Innovate",
        "dataColors": [
            "#70B0E0",
            "#FCB714",
            "#2878BD",
            "#0EB194",
            "#108372",
            "#AF916D",
            "#C4B07B",
            "#F15628",
            "#6F9EDB",
            "#FEE266",
            "#5DA9FD",
            "#4AC5BB",
            "#35B895",
            "#B69087",
            "#B6A887",
            "#F48459",
            "#1D5C95",
            "#BDA750",
            "#4A82BB",
            "#168980",
            "#288A6F",
            "#A67668",
            "#7B6E4F",
            "#B54C25",
            "#164672",
            "#7E6F36",
            "#31567D",
            "#0F5C55",
            "#0D2E25",
            "#7B594F",
            "#524934",
            "#793418"
        ],
        "foreground": "#FFFFFF",
        "foregroundNeutralSecondary": "#D2D0CE",
        "foregroundNeutralTertiary": "#979593",
        "background": "#3a3a3a",
        "backgroundLight": "#3B3A39",
        "backgroundNeutral": "#605E5C",
        "tableAccent": "#2878BD",
        "maximum": "#2878BD",
        "center": "#FCB714",
        "minimum": "#D0E4F5",
        "hyperlink": "#2878BD",
        "visitedHyperlink": "#D0E4F5",
        "textClasses": {
            "callout": {
                "fontFace": "Arial",
                "color": "#FFFFFF"
            },
            "title": {
                "fontFace": "Arial",
                "color": "#FFFFFF"
            },
            "header": {
                "fontFace": "Arial",
                "color": "#FFFFFF"
            },
            "label": {
                "fontFace": "Arial",
                "color": "#FFFFFF"
            }
        },
        "visualStyles": {
            "*": {
                "*": {
                    "background": [
                        {
                            "color": {
                                "solid": {
                                    "color": "#3a3a3a"
                                }
                            }
                        }
                    ],
                    "visualHeader": [
                        {
                            "foreground": {
                                "solid": {
                                    "color": "#FFFFFF"
                                }
                            },
                            "border": {
                                "solid": {
                                    "color": "#3a3a3a"
                                }
                            },
                            "background": {
                                "solid": {
                                    "color": "#3a3a3a"
                                }
                            }
                        }
                    ],
                    "outspacePane": [
                        {
                            "backgroundColor": {
                                "solid": {
                                    "color": "#3a3a3a"
                                }
                            },
                            "foregroundColor": {
                                "solid": {
                                    "color": "#FFFFFF"
                                }
                            },
                            "transparency": 0,
                            "border": true,
                            "borderColor": {
                                "solid": {
                                    "color": "#979593"
                                }
                            }
                        }
                    ],
                    "filterCard": [
                        {
                            "$id": "Applied",
                            "transparency": 0,
                            "foregroundColor": {
                                "solid": {
                                    "color": "#FFFFFF"
                                }
                            },
                            "backgroundColor": {
                                "solid": {
                                    "color": "#605E5C"
                                }
                            },
                            "inputBoxColor": {
                                "solid": {
                                    "color": "#605E5C"
                                }
                            },
                            "borderColor": {
                                "solid": {
                                    "color": "#979593"
                                }
                            },
                            "border": true
                        },
                        {
                            "$id": "Available",
                            "transparency": 0,
                            "foregroundColor": {
                                "solid": {
                                    "color": "#FFFFFF"
                                }
                            },
                            "backgroundColor": {
                                "solid": {
                                    "color": "#3a3a3a"
                                }
                            },
                            "inputBoxColor": {
                                "solid": {
                                    "color": "#3a3a3a"
                                }
                            },
                            "borderColor": {
                                "solid": {
                                    "color": "#979593"
                                }
                            },
                            "border": true
                        }
                    ]
                }
            },
            "slicer": {
                "*": {
                    "items": [
                        {
                            "background": {
                                "solid": {
                                    "color": "#3a3a3a"
                                }
                            }
                        }
                    ],
                    "numericInputStyle": [
                        {
                            "background": {
                                "solid": {
                                    "color": "#3a3a3a"
                                }
                            }
                        }
                    ]
                }
            },
            "keyDriversVisual": {
                "*": {
                    "keyInfluencersVisual": [
                        {
                            "canvasColor": {
                                "solid": {
                                    "color": "#3B3A39"
                                }
                            }
                        }
                    ]
                }
            },
            "page": {
                "*": {
                    "outspace": [
                        {
                            "color": {
                                "solid": {
                                    "color": "#3a3a3a"
                                }
                            }
                        }
                    ],
                    "background": [
                        {
                            "transparency": 0
                        }
                    ]
                }
            }
        }
    }

     

    If this doesn't work, you may just have to load your theme and then go into the 'Customize current theme' and change things one by one but at least that will work across all visuals in the report.