Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
nexpie-grafana-theme
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Registry
Registry
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kornkitt Poolsup
nexpie-grafana-theme
Commits
06e48cb8
Unverified
Commit
06e48cb8
authored
Nov 26, 2020
by
Peter Holmberg
Committed by
GitHub
Nov 26, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix: Migrate Panel edit uiState percentage strings to number (#29412)
parent
bec3fbea
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
2 deletions
+10
-2
public/app/core/components/SplitPaneWrapper/SplitPaneWrapper.tsx
+0
-0
public/app/features/dashboard/components/PanelEditor/PanelEditor.tsx
+1
-1
public/app/features/dashboard/components/PanelEditor/state/reducers.ts
+9
-1
No files found.
public/app/core/components/
ThreePaneSplit
/SplitPaneWrapper.tsx
→
public/app/core/components/
SplitPaneWrapper
/SplitPaneWrapper.tsx
View file @
06e48cb8
File moved
public/app/features/dashboard/components/PanelEditor/PanelEditor.tsx
View file @
06e48cb8
...
...
@@ -18,7 +18,7 @@ import { OptionsPaneContent } from './OptionsPaneContent';
import
{
DashNavButton
}
from
'app/features/dashboard/components/DashNav/DashNavButton'
;
import
{
SubMenuItems
}
from
'app/features/dashboard/components/SubMenu/SubMenuItems'
;
import
{
BackButton
}
from
'app/core/components/BackButton/BackButton'
;
import
{
SplitPaneWrapper
}
from
'app/core/components/
ThreePaneSplit
/SplitPaneWrapper'
;
import
{
SplitPaneWrapper
}
from
'app/core/components/
SplitPaneWrapper
/SplitPaneWrapper'
;
import
{
SaveDashboardModalProxy
}
from
'../SaveDashboard/SaveDashboardModalProxy'
;
import
{
DashboardPanel
}
from
'../../dashgrid/DashboardPanel'
;
...
...
public/app/features/dashboard/components/PanelEditor/state/reducers.ts
View file @
06e48cb8
...
...
@@ -37,6 +37,14 @@ export interface PanelEditorState {
}
export
const
initialState
=
():
PanelEditorState
=>
{
const
storedUiState
=
store
.
getObject
(
PANEL_EDITOR_UI_STATE_STORAGE_KEY
,
DEFAULT_PANEL_EDITOR_UI_STATE
);
let
migratedState
=
{
...
storedUiState
};
if
(
typeof
storedUiState
.
rightPaneSize
===
'string'
)
{
migratedState
=
{
...
storedUiState
,
rightPaneSize
:
parseFloat
(
storedUiState
.
rightPaneSize
)
/
100
};
}
return
{
getPanel
:
()
=>
new
PanelModel
({}),
getSourcePanel
:
()
=>
new
PanelModel
({}),
...
...
@@ -50,7 +58,7 @@ export const initialState = (): PanelEditorState => {
isOpen
:
false
,
ui
:
{
...
DEFAULT_PANEL_EDITOR_UI_STATE
,
...
store
.
getObject
(
PANEL_EDITOR_UI_STATE_STORAGE_KEY
,
DEFAULT_PANEL_EDITOR_UI_STATE
)
,
...
migratedState
,
},
};
};
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment