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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more

Shape fill colors for .json theme template don't work

Dear Microsoft,

 

I've developed a full .json theme template that I'd like to use for my various customers and to help reduce report development time. A lot of reports we create use shapes to create headers and footers. I've been testing in a seperate report and here's the .json code that I'm currently using for shapes:

 

 

{
	"name": "Shapetest template",
	"dataColors": [
		"#cc0000",
		"#1c2c44",
		"#c7d6c3",
		"#c0dce6",
		"#f9e984",
		"#264691",
		"#849c9c",
		"#50677a",
		"#334c61",
		"#6e7983",
		"#454b5a",
		"#f9f9f7",
		"#6a7883",
		"#88a0c2",
		"#dd0000",
		"#929292",
		"#ffffff",
		"#252423",
		"#FDAB89",
		"#B687AC",
		"#28738A",
		"#A78F8F",
		"#168980",
		"#293537",
		"#BB4A4A",
		"#B59525",
		"#475052",
		"#6A9FB0",
		"#BD7150",
		"#7B4F71",
		"#1B4D5C",
		"#706060",
		"#0F5C55"
	],
	"visualStyles": {
		"shape": {
			"*": {
				"visualHeader": [
					{
						"show": false
					}
				],
				"background": [
					{
						"color": {
							"solid": {
								"color": "#FFFFFF"
							}
						},
						"transparency": 100
					}
				],
				"fill": [
					{
						"show": true,
						"fillColor": { "solid": { "color": "#FFFFFF"}},
						"transparency": 100
					}
				]
			}
		}
	}
}

 

 

 

I've noticed that the background and visual header properties are setting properly but the fill properties don't seem to work. I got the properties by opening the .pbix file as a .zip and opening the layout file in a code editor:

 

 

"sections": [
		{
			"id": 0,
			"name": "ReportSection",
			"displayName": "Page 1",
			"filters": "[]",
			"ordinal": 0,
			"visualContainers": [
				{
					"x": 229.1707317073171,
					"y": 157.1707317073171,
					"z": 1,
					"width": 300.2926829268293,
					"height": 299.4146341463415,
					"config": "{\"name\":\"02976ed171563d9e2075\",\"layouts\":[{\"id\":0,\"position\":{\"x\":229.1707317073171,\"y\":157.1707317073171,\"z\":1,\"width\":300.2926829268293,\"height\":299.4146341463415}}],\"singleVisual\":{\"visualType\":\"shape\",\"drillFilterOtherVisuals\":true,\"objects\":{\"shape\":[{\"properties\":{\"tileShape\":{\"expr\":{\"Literal\":{\"Value\":\"'oval'\"}}}}}],\"rotation\":[{\"properties\":{\"shapeAngle\":{\"expr\":{\"Literal\":{\"Value\":\"0L\"}}}}}],\"fill\":[{\"properties\":{\"fillColor\":{\"solid\":{\"color\":{\"expr\":{\"ThemeDataColor\":{\"ColorId\":3,\"Percent\":0}}}}},\"transparency\":{\"expr\":{\"Literal\":{\"Value\":\"31D\"}}}},\"selector\":{\"id\":\"default\"}}],\"outline\":[{\"properties\":{\"lineColor\":{\"solid\":{\"color\":{\"expr\":{\"ThemeDataColor\":{\"ColorId\":5,\"Percent\":0}}}}},\"weight\":{\"expr\":{\"Literal\":{\"Value\":\"5D\"}}},\"transparency\":{\"expr\":{\"Literal\":{\"Value\":\"12D\"}}}},\"selector\":{\"id\":\"default\"}}]}}}",
					"filters": "[]"
				},

 

 


From what I can tell I'm using the right properties but the color isn't being picked up from the .json template file.

Status: Investigating
Comments
Anonymous
Not applicable

Hi @Anonymous 

If you want your customers to use the template with your populated properties, you can save the theme you set in json format inside the theme, and then let your customers apply it directly .

Ailsamsft_0-1670396374312.png

Best Regards,
Community Support Team _ Ailsa Tao