Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adds support for rules screen in react-ui #6503
Adds support for rules screen in react-ui #6503
Changes from all commits
98a95f4
332e32c
846bfe0
e04f866
e32ffca
bcb85b1
41a334a
fc9dbfd
40987c2
012ec3a
ff367c4
441c285
8ed6406
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please remove
rulse-head
- it's not used anywhereThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you align response handling with the pattern used in other pages i.e check how
withStatusIndicator
HOC is usedThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Better to merge this one first #6629
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This component should look like:
name
andexpr
may have different content, so we can't rely onexpr
to represent thename
Also, wrapping the
Link
andtitle
in div will remove the need of<br/>
. IMO it's better.Comparing with the old UI titles here are wrapped in
<strong>
, maybe you should remove the extra tagAnother, more important thing is to pas the
pathPrefix
prop down tocreateExpressionLink
. IMO the../
increateExpressionLink
should be passed from outside and the function just to return${prefix}graph?g0.expr=${encodeURIComponent(expr)}&g0.tab=1&g0.stacked=0&g0.range_input=1h
The usage should looks like
createExpressionLink(expr, pathPrefix + '/../')
Suggestion:
GraphExpressionLink
can be moved tocomponent
folder and can replace both expressions hereprometheus/web/ui/react-app/src/pages/alerts/CollapsibleAlertPanel.tsx
Lines 35 to 41 in d996ba2
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
<td>
content can be reduced toSome of the divs are redundant and.
Alse, note that first
GraphExpressionLink
has as an expressionALERTS{alertname="${r.name}"}
. Passing justr.name
as expr is not enough and its not workingThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please pass as second argument the
pathPrefix
prop and remove../
- this should be passed from outside as well