Skip to content

Commit 0071be7

Browse files
author
Shahak Yosef
committed
Merged PR 132063: Hide phased loading for single visual embedded
Phased loading (load and render) doesn't work for single visual embed (report embed with custom layout). Hide it from the official documentation.
1 parent 5735670 commit 0071be7

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

src/visual.ts

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import { Report } from './report'
55
import { Page } from './page';
66
import { VisualDescriptor } from './visualDescriptor';
77
import { IHttpPostMessageResponse } from 'http-post-message';
8+
import { IReportLoadConfiguration } from 'powerbi-models';
89

910
/**
1011
* The Power BI Visual embed component
@@ -20,6 +21,8 @@ export class Visual extends Report {
2021
static GetPagesNotSupportedError = "Get pages is not supported while embedding a visual.";
2122
/** @hidden */
2223
static SetPageNotSupportedError = "Set page is not supported while embedding a visual.";
24+
/** @hidden */
25+
static RenderNotSupportedError = "render is not supported while embedding a visual.";
2326

2427
/**
2528
* Creates an instance of a Power BI Single Visual.
@@ -33,6 +36,9 @@ export class Visual extends Report {
3336
super(service, element, baseConfig, phasedRender, isBootstrap, iframe);
3437
}
3538

39+
/**
40+
* @hidden
41+
*/
3642
load(phasedRender?: boolean): Promise<void> {
3743
var config = <embed.IVisualEmbedConfiguration>this.config;
3844

@@ -113,6 +119,16 @@ export class Visual extends Report {
113119
throw Visual.SetPageNotSupportedError;
114120
}
115121

122+
/**
123+
* Render a preloaded report, using phased embedding API
124+
*
125+
* @hidden
126+
* @returns {Promise<void>}
127+
*/
128+
async render(config?: IReportLoadConfiguration | embed.IReportEmbedConfiguration): Promise<void> {
129+
throw Visual.RenderNotSupportedError
130+
}
131+
116132
/**
117133
* Gets the embedded visual descriptor object that contains the visual name, type, etc.
118134
*

0 commit comments

Comments
 (0)