Set the background color of a Power BI Embedded IFrame
Published date: 01 June, 2018
When the IFrame size that's allocated for an embedded object and the embedded object itself don't share the same aspect ratio, the result is gray margins on the sides (marked in red in the following figure).
You can use the Custom Layout API to define how to fill the IFrame or set a fixed size for the object at any time. But that sometimes doesn't entirely fix the appearance of the gray margins.
You can now set the background color of the IFrame by making it transparent. By doing so, you'll give the IFrame the defined color of the DIV element that contains the IFrame. You have full control of what color/background layout will be seen in the margins, making the embedded object wrapped entirely by the application design.