@@ -26,7 +26,7 @@ import { reportAppInteraction, USER_EVENTS_ACTIONS, USER_EVENTS_PAGES } from '..
2626import { areArraysEqual } from '../../services/comparison' ;
2727import { getAllLabelsFromDataFrame } from '../../services/labels' ;
2828import { setControlsExpandedStateFromLocalStorage } from '../../services/scenes' ;
29- import { getLogOption , setDisplayedFieldsInStorage } from '../../services/store' ;
29+ import { getBooleanLogOption , getLogOption , setDisplayedFieldsInStorage , setLogOption } from '../../services/store' ;
3030import { clearVariables } from '../../services/variableHelpers' ;
3131import { PanelMenu } from '../Panels/PanelMenu' ;
3232import { DEFAULT_URL_COLUMNS , DETECTED_LEVEL , LEVEL } from '../Table/constants' ;
@@ -102,7 +102,10 @@ export class LogsTablePanelScene extends SceneObjectBase<LogsTableSceneState> {
102102 }
103103
104104 protected onOptionsChange ( options : DeepPartial < Options > , prevOptions : DeepPartial < Options > ) {
105- console . log ( 'options change' , options ) ;
105+ // todo: Update after Grafana >= 13.1
106+ if ( 'wrapText' in options && 'wrapText' in prevOptions && options . wrapText !== prevOptions . wrapText ) {
107+ setLogOption ( 'wrapText' , Boolean ( options . wrapText ) ) ;
108+ }
106109 }
107110
108111 public onActivate ( ) {
@@ -112,6 +115,7 @@ export class LogsTablePanelScene extends SceneObjectBase<LogsTableSceneState> {
112115 ...defaultOptions ,
113116 // Could do url columns
114117 displayedFields : parentScene . state . displayedFields ,
118+ wrapText : getBooleanLogOption ( 'wrapText' , true ) ,
115119 } ) ) ;
116120
117121 // @todo set field defaults
0 commit comments