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
f749ced3
Commit
f749ced3
authored
Jan 04, 2019
by
Torkel Ödegaard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
AlertTab style fixes
parent
2eeba9da
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
33 additions
and
34 deletions
+33
-34
public/app/features/dashboard/dashgrid/EditorTabBody.tsx
+1
-1
public/app/features/dashboard/dashgrid/StateHistory.tsx
+31
-33
public/sass/pages/_alerting.scss
+1
-0
No files found.
public/app/features/dashboard/dashgrid/EditorTabBody.tsx
View file @
f749ced3
...
...
@@ -25,7 +25,7 @@ export interface EditorToolbarView {
icon
?:
string
;
disabled
?:
boolean
;
onClick
?:
()
=>
void
;
render
?:
(
closeFunction
?:
any
)
=>
JSX
.
Element
|
JSX
.
Element
[]
;
render
?:
(
)
=>
JSX
.
Element
;
action
?:
()
=>
void
;
buttonType
:
ToolbarButtonType
;
}
...
...
public/app/features/dashboard/dashgrid/StateHistory.tsx
View file @
f749ced3
...
...
@@ -69,41 +69,39 @@ class StateHistory extends PureComponent<Props, State> {
return
(
<
div
>
<
div
style=
{
{
margin
:
'0 auto'
,
maxWidth
:
'720px'
}
}
>
{
stateHistoryItems
.
length
>
0
&&
(
<
div
style=
{
{
marginBottom
:
'15px'
}
}
>
<
span
className=
"muted"
>
Last 50 state changes
</
span
>
<
button
className=
"btn btn-mini btn-danger pull-right"
onClick=
{
this
.
clearHistory
}
>
<
i
className=
"fa fa-trash"
/>
{
` Clear history`
}
</
button
>
</
div
>
)
}
<
ol
className=
"alert-rule-list"
>
{
stateHistoryItems
.
length
>
0
?
(
stateHistoryItems
.
map
((
item
,
index
)
=>
{
return
(
<
li
className=
"alert-rule-item"
key=
{
`${item.time}-${index}`
}
>
<
div
className=
{
`alert-rule-item__icon ${item.stateModel.stateClass}`
}
>
<
i
className=
{
item
.
stateModel
.
iconClass
}
/>
</
div
>
<
div
className=
"alert-rule-item__body"
>
<
div
className=
"alert-rule-item__header"
>
<
p
className=
"alert-rule-item__name"
>
{
item
.
alertName
}
</
p
>
<
div
className=
"alert-rule-item__text"
>
<
span
className=
{
`${item.stateModel.stateClass}`
}
>
{
item
.
stateModel
.
text
}
</
span
>
</
div
>
{
stateHistoryItems
.
length
>
0
&&
(
<
div
className=
"p-b-1"
>
<
span
className=
"muted"
>
Last 50 state changes
</
span
>
<
button
className=
"btn btn-mini btn-danger pull-right"
onClick=
{
this
.
clearHistory
}
>
<
i
className=
"fa fa-trash"
/>
{
` Clear history`
}
</
button
>
</
div
>
)
}
<
ol
className=
"alert-rule-list"
>
{
stateHistoryItems
.
length
>
0
?
(
stateHistoryItems
.
map
((
item
,
index
)
=>
{
return
(
<
li
className=
"alert-rule-item"
key=
{
`${item.time}-${index}`
}
>
<
div
className=
{
`alert-rule-item__icon ${item.stateModel.stateClass}`
}
>
<
i
className=
{
item
.
stateModel
.
iconClass
}
/>
</
div
>
<
div
className=
"alert-rule-item__body"
>
<
div
className=
"alert-rule-item__header"
>
<
p
className=
"alert-rule-item__name"
>
{
item
.
alertName
}
</
p
>
<
div
className=
"alert-rule-item__text"
>
<
span
className=
{
`${item.stateModel.stateClass}`
}
>
{
item
.
stateModel
.
text
}
</
span
>
</
div
>
{
item
.
info
}
</
div
>
<
div
className=
"alert-rule-item__time"
>
{
item
.
time
}
</
div
>
</
li
>
);
})
)
:
(
<
i
>
No state changes recorded
</
i
>
)
}
</
ol
>
</
div
>
{
item
.
info
}
</
div
>
<
div
className=
"alert-rule-item__time"
>
{
item
.
time
}
</
div
>
</
li
>
);
})
)
:
(
<
i
>
No state changes recorded
</
i
>
)
}
</
ol
>
</
div
>
);
}
...
...
public/sass/pages/_alerting.scss
View file @
f749ced3
...
...
@@ -107,6 +107,7 @@
display
:
flex
;
flex-direction
:
column
;
flex-grow
:
1
;
justify-content
:
center
;
overflow
:
hidden
;
}
...
...
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