apply fix on chart component fullscreen issues and it's now works well ...

This commit is contained in:
2026-08-31 00:52:12 +03:30
parent 174300d9f1
commit 864fa79454
@@ -113,8 +113,7 @@ export class XChartComponent extends XChartContainerComponent {
//#endregion //#endregion
// //
private ORIGINAL_HEIGHT: string = '300px'; private ORIGINAL_HEIGHT: string = undefined;
private RESIZE_SUBJECT = new Subject<Event>();
// //
private CHART_OPTIONS: XChartOptions = null; private CHART_OPTIONS: XChartOptions = null;
@@ -371,10 +370,6 @@ export class XChartComponent extends XChartContainerComponent {
onDestroy() { onDestroy() {
super.onDestroy(); super.onDestroy();
//
this.RESIZE_SUBJECT.next();
this.RESIZE_SUBJECT.complete();
// //
this.destroyComponent(); this.destroyComponent();
this.unregisterActionProvider(); this.unregisterActionProvider();
@@ -1393,7 +1388,9 @@ export class XChartComponent extends XChartContainerComponent {
// //
// Storing Original Height ... // Storing Original Height ...
this.ORIGINAL_HEIGHT = this.CHART_OPTIONS.chart?.height?.toString(); if (isNullOrEmptyString(this.ORIGINAL_HEIGHT)) {
this.ORIGINAL_HEIGHT = this.CHART_OPTIONS.chart?.height?.toString();
}
// //
await this.prepareActionBar(); await this.prepareActionBar();
@@ -2123,7 +2120,13 @@ export class XChartComponent extends XChartContainerComponent {
}; };
// //
this.chartInstance.updateOptions(this.CHART_OPTIONS, false, true, false, false); this.chartInstance.updateOptions(
this.CHART_OPTIONS,
false,
true,
false,
false,
);
this.managerService.dispatchResizeEvent(); this.managerService.dispatchResizeEvent();
} }
@@ -2217,7 +2220,9 @@ export class XChartComponent extends XChartContainerComponent {
// Handle Full Screen Toggled ... // Handle Full Screen Toggled ...
if (model.action == XCardAction.FullScreenToggled) { if (model.action == XCardAction.FullScreenToggled) {
// //
const isFullscreen = isNullOrUndefined(model.payload) ? false : true; const isFullscreen = isNullOrUndefined(model.payload)
? false
: (model.payload as boolean) || false;
await this.handleFullscreenMode(isFullscreen); await this.handleFullscreenMode(isFullscreen);
} }
}); });