Skip to content

Commit 9d19361

Browse files
committed
Merged PR 131439: Make master up to date with beta
We want to deploy to NPM as beta version
1 parent c8eed4a commit 9d19361

File tree

11 files changed

+1732
-1686
lines changed

11 files changed

+1732
-1686
lines changed

dist/powerbi-client.d.ts

Lines changed: 25 additions & 89 deletions
Original file line numberDiff line numberDiff line change
@@ -127,82 +127,17 @@ declare module "embed" {
127127
msRequestFullscreen: Function;
128128
}
129129
}
130-
/**
131-
* Prepare configuration for Power BI embed components.
132-
*
133-
* @export
134-
* @interface IBootstrapEmbedConfiguration
135-
*/
136-
export interface IBootstrapEmbedConfiguration {
137-
hostname?: string;
138-
embedUrl?: string;
139-
settings?: ISettings;
140-
uniqueId?: string;
141-
type?: string;
142-
groupId?: string;
143-
bootstrapped?: boolean;
144-
}
145-
/**
146-
* Base Configuration settings for Power BI embed components
147-
*
148-
* @export
149-
* @interface IEmbedConfigurationBase
150-
* @extends IBootstrapEmbedConfiguration
151-
*/
152-
export interface IEmbedConfigurationBase extends IBootstrapEmbedConfiguration {
153-
accessToken?: string;
154-
tokenType?: models.TokenType;
155-
}
156-
/**
157-
* Configuration settings for Power BI embed components
158-
*
159-
* @export
160-
* @interface IEmbedConfiguration
161-
*/
162-
export interface IEmbedConfiguration extends IEmbedConfigurationBase {
163-
id?: string;
164-
settings?: IEmbedSettings;
165-
pageName?: string;
166-
filters?: models.IFilter[];
167-
pageView?: models.PageView;
168-
datasetId?: string;
169-
permissions?: models.Permissions;
170-
viewMode?: models.ViewMode;
171-
action?: string;
172-
dashboardId?: string;
173-
height?: number;
174-
width?: number;
175-
theme?: models.IReportTheme;
176-
slicers?: models.ISlicer[];
177-
bookmark?: models.IApplyBookmarkRequest;
178-
datasetBinding?: models.IDatasetBinding;
179-
contrastMode?: models.ContrastMode;
180-
}
181-
export interface IVisualEmbedConfiguration extends IEmbedConfiguration {
182-
visualName: string;
183-
}
184-
/**
185-
* Configuration settings for Power BI Q&A embed component
186-
*
187-
* @export
188-
* @interface IEmbedConfiguration
189-
*/
190-
export interface IQnaEmbedConfiguration extends IEmbedConfigurationBase {
191-
datasetIds: string[];
192-
question?: string;
193-
viewMode?: models.QnaMode;
194-
}
195-
export interface ILocaleSettings {
196-
language?: string;
197-
formatLocale?: string;
198-
}
199-
export interface ISettings {
200-
localeSettings?: ILocaleSettings;
201-
}
202-
export interface IEmbedSettings extends models.ISettings, ISettings {
203-
}
204-
export interface IQnaSettings extends models.IQnaSettings, ISettings {
205-
}
130+
export type IBootstrapEmbedConfiguration = models.IBootstrapEmbedConfiguration;
131+
export type IEmbedConfigurationBase = models.IEmbedConfigurationBase;
132+
export type IEmbedConfiguration = models.IEmbedConfiguration;
133+
export type IVisualEmbedConfiguration = models.IVisualEmbedConfiguration;
134+
export type IReportEmbedConfiguration = models.IReportEmbedConfiguration;
135+
export type IDashboardEmbedConfiguration = models.IDashboardEmbedConfiguration;
136+
export type ITileEmbedConfiguration = models.ITileEmbedConfiguration;
137+
export type IQnaEmbedConfiguration = models.IQnaEmbedConfiguration;
138+
export type ILocaleSettings = models.ILocaleSettings;
139+
export type IQnaSettings = models.IQnaSettings;
140+
export type IEmbedSettings = models.ISettings;
206141
/** @hidden */
207142
export interface IInternalEventHandler<T> {
208143
test(event: service.IEvent<T>): boolean;
@@ -467,7 +402,7 @@ declare module "embed" {
467402
* Adds locale parameters to embedUrl
468403
*
469404
* @private
470-
* @param {IEmbedConfiguration} config
405+
* @param {IEmbedConfiguration | models.ICommonEmbedConfiguration} config
471406
* @hidden
472407
*/
473408
private addLocaleToEmbedUrl(config);
@@ -929,7 +864,7 @@ declare module "report" {
929864
import * as models from 'powerbi-models';
930865
import { IFilterable } from "ifilterable";
931866
import { Page } from "page";
932-
import { IReportLoadConfiguration } from 'powerbi-models';
867+
import { IReportLoadConfiguration, IReportEmbedConfiguration } from 'powerbi-models';
933868
import { BookmarksManager } from "bookmarksManager";
934869
/**
935870
* A Report node within a report hierarchy
@@ -940,7 +875,7 @@ declare module "report" {
940875
export interface IReportNode {
941876
iframe: HTMLIFrameElement;
942877
service: service.IService;
943-
config: embed.IEmbedConfiguration;
878+
config: embed.IEmbedConfiguration | IReportEmbedConfiguration;
944879
}
945880
/**
946881
* The Power BI Report embed component
@@ -1000,7 +935,7 @@ declare module "report" {
1000935
*
1001936
* @returns {Promise<void>}
1002937
*/
1003-
render(config?: IReportLoadConfiguration): Promise<void>;
938+
render(config?: IReportLoadConfiguration | embed.IReportEmbedConfiguration): Promise<void>;
1004939
/**
1005940
* Add an empty page to the report
1006941
*
@@ -1254,7 +1189,7 @@ declare module "create" {
12541189
* @extends {embed.Embed}
12551190
*/
12561191
export class Create extends embed.Embed {
1257-
constructor(service: service.Service, element: HTMLElement, config: embed.IEmbedConfiguration, phasedRender?: boolean, isBootstrap?: boolean);
1192+
constructor(service: service.Service, element: HTMLElement, config: embed.IEmbedConfiguration | models.IReportCreateConfiguration, phasedRender?: boolean, isBootstrap?: boolean);
12581193
/**
12591194
* Gets the dataset ID from the first available location: createConfig or embed url.
12601195
*
@@ -1323,7 +1258,6 @@ declare module "dashboard" {
13231258
* @class Dashboard
13241259
* @extends {embed.Embed}
13251260
* @implements {IDashboardNode}
1326-
* @implements {IFilterable}
13271261
*/
13281262
export class Dashboard extends embed.Embed implements IDashboardNode {
13291263
/** @hidden */
@@ -1595,6 +1529,7 @@ declare module "service" {
15951529
import * as wpmp from 'window-post-message-proxy';
15961530
import * as hpm from 'http-post-message';
15971531
import * as router from 'powerbi-router';
1532+
import * as models from 'powerbi-models';
15981533
export interface IEvent<T> {
15991534
type: string;
16001535
id: string;
@@ -1647,6 +1582,7 @@ declare module "service" {
16471582
export interface IService {
16481583
hpm: hpm.HttpPostMessage;
16491584
}
1585+
export type IComponentEmbedConfiguration = embed.IReportEmbedConfiguration | embed.IDashboardEmbedConfiguration | embed.ITileEmbedConfiguration | embed.IVisualEmbedConfiguration | embed.IQnaEmbedConfiguration;
16501586
/**
16511587
* The Power BI Service embed component, which is the entry point to embed all other Power BI components into your application
16521588
*
@@ -1700,7 +1636,7 @@ declare module "service" {
17001636
* @param {embed.IEmbedConfiguration} [config={}]
17011637
* @returns {embed.Embed}
17021638
*/
1703-
createReport(element: HTMLElement, config: embed.IEmbedConfiguration): embed.Embed;
1639+
createReport(element: HTMLElement, config: embed.IEmbedConfiguration | models.IReportCreateConfiguration): embed.Embed;
17041640
/**
17051641
* TODO: Add a description here
17061642
*
@@ -1719,7 +1655,7 @@ declare module "service" {
17191655
* @param {embed.IEmbedConfigurationBase} [config={}]
17201656
* @returns {embed.Embed}
17211657
*/
1722-
embed(element: HTMLElement, config?: embed.IEmbedConfigurationBase): embed.Embed;
1658+
embed(element: HTMLElement, config?: IComponentEmbedConfiguration | embed.IEmbedConfigurationBase): embed.Embed;
17231659
/**
17241660
* Given a configuration based on an HTML element,
17251661
* if the component has already been created and attached to the element, reuses the component instance and existing iframe,
@@ -1730,16 +1666,16 @@ declare module "service" {
17301666
* @param {embed.IEmbedConfigurationBase} [config={}]
17311667
* @returns {embed.Embed}
17321668
*/
1733-
load(element: HTMLElement, config?: embed.IEmbedConfigurationBase): embed.Embed;
1669+
load(element: HTMLElement, config?: IComponentEmbedConfiguration | embed.IEmbedConfigurationBase): embed.Embed;
17341670
/**
17351671
* Given an HTML element and entityType, creates a new component instance, and bootstrap the iframe for embedding.
17361672
*
17371673
* @param {HTMLElement} element
17381674
* @param {embed.IBootstrapEmbedConfiguration} config: a bootstrap config which is an embed config without access token.
17391675
*/
1740-
bootstrap(element: HTMLElement, config: embed.IBootstrapEmbedConfiguration): embed.Embed;
1676+
bootstrap(element: HTMLElement, config: IComponentEmbedConfiguration | embed.IBootstrapEmbedConfiguration): embed.Embed;
17411677
/** @hidden */
1742-
embedInternal(element: HTMLElement, config?: embed.IEmbedConfigurationBase, phasedRender?: boolean, isBootstrap?: boolean): embed.Embed;
1678+
embedInternal(element: HTMLElement, config?: IComponentEmbedConfiguration | embed.IEmbedConfigurationBase, phasedRender?: boolean, isBootstrap?: boolean): embed.Embed;
17431679
/** @hidden */
17441680
getNumberOfComponents(): number;
17451681
/** @hidden */
@@ -1828,7 +1764,7 @@ declare module "service" {
18281764
* @param {embed.IEmbedConfigurationBase} [config={}]
18291765
* @param {HTMLElement} [element=undefined]
18301766
*/
1831-
preload(config: embed.IEmbedConfigurationBase, element?: HTMLElement): HTMLIFrameElement;
1767+
preload(config: IComponentEmbedConfiguration | embed.IEmbedConfigurationBase, element?: HTMLElement): HTMLIFrameElement;
18321768
}
18331769
}
18341770
declare module "bookmarksManager" {
@@ -1946,7 +1882,7 @@ declare module "powerbi-client" {
19461882
export { Report } from "report";
19471883
export { Dashboard } from "dashboard";
19481884
export { Tile } from "tile";
1949-
export { IEmbedConfiguration, IQnaEmbedConfiguration, IVisualEmbedConfiguration, Embed, ILocaleSettings, IEmbedSettings, IQnaSettings } from "embed";
1885+
export { IEmbedConfiguration, IQnaEmbedConfiguration, IVisualEmbedConfiguration, IReportEmbedConfiguration, IDashboardEmbedConfiguration, ITileEmbedConfiguration, Embed, ILocaleSettings, IEmbedSettings, IQnaSettings } from "embed";
19501886
export { Page } from "page";
19511887
export { Qna } from "qna";
19521888
export { Visual } from "visual";

0 commit comments

Comments
 (0)