|
1 | 1 | import classNames from 'classnames';
|
2 | 2 | import React, { PureComponent, CSSProperties } from 'react';
|
3 |
| -import { connect } from 'react-redux'; |
4 | 3 | import { Subscription } from 'rxjs';
|
5 | 4 |
|
6 | 5 | import {
|
@@ -41,7 +40,6 @@ import { getDatasourceSrv } from 'app/features/plugins/datasource_srv';
|
41 | 40 | import { applyFilterFromTable } from 'app/features/variables/adhoc/actions';
|
42 | 41 | import { onUpdatePanelSnapshotData } from 'app/plugins/datasource/grafana/utils';
|
43 | 42 | import { changeSeriesColorConfigFactory } from 'app/plugins/panel/timeseries/overrides/colorSeriesConfigFactory';
|
44 |
| -import { StoreState } from 'app/types'; |
45 | 43 | import { RenderEvent } from 'app/types/events';
|
46 | 44 |
|
47 | 45 | import { deleteAnnotation, saveAnnotation, updateAnnotation } from '../../annotations/api';
|
@@ -73,6 +71,7 @@ export interface Props {
|
73 | 71 | timezone?: string;
|
74 | 72 | hideMenu?: boolean;
|
75 | 73 | FNDashboard?: boolean;
|
| 74 | + mode?: "light" | "dark"; |
76 | 75 | }
|
77 | 76 |
|
78 | 77 | export interface State {
|
@@ -296,6 +295,7 @@ export class PanelStateWrapper extends PureComponent<Props, State> {
|
296 | 295 | if (width !== prevProps.width) {
|
297 | 296 | liveTimer.updateInterval(this);
|
298 | 297 | }
|
| 298 | + |
299 | 299 | }
|
300 | 300 |
|
301 | 301 | // Updates the response with information from the stream
|
@@ -613,8 +613,7 @@ export class PanelStateWrapper extends PureComponent<Props, State> {
|
613 | 613 | aria-label={selectors.components.Panels.Panel.containerByTitle(panel.title)}
|
614 | 614 | >
|
615 | 615 | {FNDashboard ? (
|
616 |
| - // TODO: Avoid divology. Use HTML5, i.e. wrap texts with p or h element instead of div. |
617 |
| - <div style={FN_TITLE_STYLE}>{panel.title}</div> |
| 616 | + <p style={FN_TITLE_STYLE}>{panel.title}</p> |
618 | 617 | ) : (
|
619 | 618 | <PanelHeader
|
620 | 619 | panel={panel}
|
@@ -646,9 +645,3 @@ export class PanelStateWrapper extends PureComponent<Props, State> {
|
646 | 645 | }
|
647 | 646 | }
|
648 | 647 | }
|
649 |
| - |
650 |
| -const mapStateToProps = (state: StoreState) => { |
651 |
| - return { ...state.fnGlobalState }; |
652 |
| -}; |
653 |
| -const connector = connect(mapStateToProps); |
654 |
| -export const PanelChrome = connector(PanelStateWrapper); |
0 commit comments