@sutech_jp/raas-react-client 0.1.37 → 0.1.38
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -5,9 +5,15 @@ declare type Props = {
|
|
|
5
5
|
session: Session | undefined;
|
|
6
6
|
width?: string | number;
|
|
7
7
|
height?: string | number;
|
|
8
|
+
customStyles?: ThemeOptions;
|
|
9
|
+
/**
|
|
10
|
+
* @deprecated This option has been removed. Specifying it will be ignored.
|
|
11
|
+
*/
|
|
8
12
|
hideTenantInfoConfig?: boolean;
|
|
13
|
+
/**
|
|
14
|
+
* @deprecated This option has been removed. Specifying it will be ignored.
|
|
15
|
+
*/
|
|
9
16
|
toolbarPosition?: 'top' | 'bottom';
|
|
10
|
-
customStyles?: ThemeOptions;
|
|
11
17
|
};
|
|
12
18
|
export declare const ReportConfig: VFC<Props>;
|
|
13
19
|
export {};
|
|
@@ -5,7 +5,7 @@ var jsx_runtime_1 = require("react/jsx-runtime");
|
|
|
5
5
|
var react_1 = require("react");
|
|
6
6
|
var targetOrigin_1 = require("../util/targetOrigin");
|
|
7
7
|
var ReportConfig = function (_a) {
|
|
8
|
-
var session = _a.session, _b = _a.width, width = _b === void 0 ? '100%' : _b, _c = _a.height, height = _c === void 0 ? '100%' : _c,
|
|
8
|
+
var session = _a.session, _b = _a.width, width = _b === void 0 ? '100%' : _b, _c = _a.height, height = _c === void 0 ? '100%' : _c, customStyles = _a.customStyles;
|
|
9
9
|
var iframe = (0, react_1.useRef)(null);
|
|
10
10
|
var handleMessage = (0, react_1.useCallback)(function (e) {
|
|
11
11
|
var _a;
|
|
@@ -26,13 +26,11 @@ var ReportConfig = function (_a) {
|
|
|
26
26
|
from: 'configClient',
|
|
27
27
|
action: 'onShow',
|
|
28
28
|
props: {
|
|
29
|
-
hideTenantInfoConfig: hideTenantInfoConfig,
|
|
30
|
-
toolbarPosition: toolbarPosition,
|
|
31
29
|
customStyles: customStyles,
|
|
32
30
|
},
|
|
33
31
|
}, (0, targetOrigin_1.getTargetOrigin)(session === null || session === void 0 ? void 0 : session.newUrl));
|
|
34
32
|
}
|
|
35
|
-
}, [customStyles,
|
|
33
|
+
}, [customStyles, session]);
|
|
36
34
|
(0, react_1.useEffect)(function () {
|
|
37
35
|
window.addEventListener('message', handleMessage);
|
|
38
36
|
return function () { return window.removeEventListener('message', handleMessage); };
|