Łukasz Mierzwa
baf0890392
feat(ui): hide filter counter value when not needed
...
Right now counter badge is rendered on every filter instance, but if there's only one filter that counter has the same value as the total alert counter on left side. With this change counter badge will only be rendered if there's a filter with hits != total alert count
2019-03-22 17:02:40 +00:00
Łukasz Mierzwa
f79b655893
chore(ui): use rocket icon on the upgrade screen
2019-03-20 21:54:05 +00:00
Łukasz Mierzwa
3974315ccc
feat(ui): add UI toggle for changing autohide settings
...
This adds a checkbox in the settings form to control if navbar autohide is on or off
Fixes #530
2019-03-15 14:57:27 +00:00
Łukasz Mierzwa
fc334ab4ac
feat(ui): add settings for controlling navbar autohide
...
This allows to control if the navbar should hide on idle or not
2019-03-15 14:57:27 +00:00
Łukasz Mierzwa
4a751843fb
fix(ui): shared silences is now a list
...
API changed, so UI needs to follow
2019-03-15 11:26:46 +00:00
Łukasz Mierzwa
a642dd7aff
fix(ui): add margin around silence fallback
2019-03-15 11:25:30 +00:00
Łukasz Mierzwa
4d138ddca7
fix(ui): tweak animations
...
Cleanup props by removing 'in' which is passed in from parent.
Set dropdown max-height to be biggish, so that the dropdown doesn't need to expand more after animation is complete.
Drop margin, padding and border overrides so transitions can't alter the size of the dropdown.
2019-03-14 18:04:21 +00:00
Łukasz Mierzwa
bd0a32ec8a
chore(ui): hide annotation details only when clicking on the - icon
...
This changes handling of annotation hide/show clicks. Right now annotation details are toggled when anything inside the annotation div is clicked. With this change showing annotation details stays the same (click anywhere), but hiding those details only works when clicking the minus icon. A tooltip was added and cursor changes to pointer only when hoovering over clickable elements.
Fixes #518
2019-03-13 18:06:15 +00:00
Łukasz Mierzwa
6f24026ae0
fix(ui): update grid after long silence is truncated
...
Ensures that grid is always packed correctly, since truncating silence comment can alter the size of alert group card
2019-03-08 20:10:57 +00:00
Łukasz Mierzwa
41cca9e501
feat(ui): deduplicate silences
...
If all alerts in a group are silenced and the same silence ID is used for all of them then there's no point in rendering silence object for each of the alerts, since they are all identical. Move the silence rendering to the footer if that happens so we save screen space
2019-03-08 17:41:22 +00:00
Łukasz Mierzwa
e3596dfbf4
feat(ui): truncate silences with long comments
...
Only show first 2 lines of a silence comment by default, the rest should be visible only when silence details are visible
2019-03-07 23:01:11 +00:00
Łukasz Mierzwa
f099ccc0ea
feat(ui): render an indicator icon when alert is inhibited
...
Right now we don't mark inhibted alerts in any way, so they look like silenced alerts with no silence details. Add an icon with tooltip so inhibited alerts can be easily distinguished from silenced onces
2019-03-05 11:02:08 +00:00
Łukasz Mierzwa
a41c07bcee
fix(ui): pass credentials when sending silences to alertmanager
...
Fixes #484
2019-03-01 20:47:36 +00:00
Łukasz Mierzwa
1093b38164
feat(ui): use not-equal operator when user alt+clicks on a label
...
When user clicks on a label we apply a foo=bar filter, this change allows to add a foo!=bar filter by holding Alt key when clicking.
Fixes #485
2019-03-01 19:44:08 +00:00
Łukasz Mierzwa
6ac1d17c18
refactor(ui): use bootstrap utilities for word breaks
...
Using bootstrap means that we don't need to worry about browser compatibility, which in this case means Edge where this wasn't enough
2019-02-24 22:35:39 +00:00
Łukasz Mierzwa
e20f75e09c
fix(ui): use current number of alerts in the count label
...
alertsToRender can be higher than the number of alerts in a group if the number keeps changing. This means we might end up with 'Showing 30/10', so ensuring that we don't show a number higher than the actual group size will make it more accurate
2019-02-23 11:18:44 +00:00
Łukasz Mierzwa
3bd6ebbf3a
feat(ui): use grid sorting settings from the API as defaults
2019-02-20 22:24:54 +00:00
Łukasz Mierzwa
397bbe5783
feat(config): allow configuring label value mapping for sorting
...
This feature solves the problem of sorting by label when values have special meaning and alphabetic sort doesn't make sense for it.
2019-02-18 23:17:47 +00:00
Łukasz Mierzwa
15f8af9a4a
fix(tests): update snapshot after upgrading enzyme
...
Those extra lines are 2 buttons that should be present: Back and Submit. Not sure why those were missing before, but looks like new enzyme fixes this snapshot test as those are expected.
2019-02-17 09:50:40 +00:00
Łukasz Mierzwa
da6368288a
feat(ui): allow sorting alert grid
...
This adds the ability for user to sort the grid of alerts via selected attribute.
UI configuration is provided to setup if timestamps or labels should be used to sort alerts.
2019-02-15 17:23:37 +00:00
Łukasz Mierzwa
4100486127
fix(tests): add css classes to react-select components
...
react-select 2.4 drops role['option'] from Option components, which makes it harder to find those in the DOM while testing. Set classNamePrefix so that all components get extra react-select-* css classes, which allows to easily reference them in tests via enzyme selectors.
2019-02-15 09:51:19 +00:00
Łukasz Mierzwa
17628fec8e
feat(ui): set font-display swap policy
...
This tells the browser to use a fallback font until Leto is loaded, which speeds up initial rendering, especially on slow clients
2019-02-11 19:23:09 +00:00
Łukasz Mierzwa
10897b2f93
chore(ui): use thinner fonts
2019-02-10 16:02:14 +00:00
Łukasz Mierzwa
9ee15fa9cc
feat(ui): bundle Lato fonts
...
With this change the browser won't need to make any external requests to render the page.
Fixes #425
2019-02-08 20:33:36 +00:00
Łukasz Mierzwa
f013ec321a
fix(tests): trigger click on the right element
2019-02-06 08:07:10 +00:00
Łukasz Mierzwa
675ec52cac
fix(tests): remove async from tests that don't need it
2019-02-06 07:51:04 +00:00
Łukasz Mierzwa
b8f15819b8
chore(tests): update snapshots after fontawesome upgrade
2019-01-29 09:03:51 +00:00
Łukasz Mierzwa
e0ddf15d0e
fix(ui): align autocomplete dropdown with the input
2019-01-18 20:08:51 +00:00
Łukasz Mierzwa
168638ae72
chore(tests): update snapshots after upgrading react-select
2019-01-18 08:55:23 +00:00
Łukasz Mierzwa
a3ef1dd40e
chore(api): drop counters from API response
...
Not used by any UI code, remove it.
2019-01-05 11:52:45 +00:00
Łukasz Mierzwa
bab4c20a27
chore(tests): update snapshots for react-json-pretty 2.0
2019-01-03 18:44:25 +00:00
Łukasz Mierzwa
fd7ece5364
fix(ui): use new import path for react-json-pretty theme
...
react-json-pretty 2.0 requires a different import path for themes
2019-01-03 18:41:51 +00:00
Łukasz Mierzwa
abd14bb079
fix(test): use correct alertmanager option format in tests
2019-01-01 23:02:29 +00:00
Łukasz Mierzwa
8c80f74487
fix(ui): prevent duplicated Alertmanager input options
...
Select value is an array, turn it into a string before checking if it's already selected
2019-01-01 23:02:29 +00:00
Łukasz Mierzwa
62db6859ea
fix(ui): use new style alertmanager input values
2019-01-01 23:02:29 +00:00
Łukasz Mierzwa
09d1196df0
fix(ui): user alertmanager label as argument for @alertmanager filter
2019-01-01 23:02:29 +00:00
Łukasz Mierzwa
05cefe8177
feat(ui): use bootstrap custom control for checkboxes
...
This will use bootstrap styled controls instead of native.
https://getbootstrap.com/docs/4.2/components/forms/#switches
2018-12-31 09:06:13 +00:00
Łukasz Mierzwa
82108866b2
chore(tests): update failing snapshots after react-select upgrade to 2.2
2018-12-29 21:26:59 +00:00
Łukasz Mierzwa
6aed0de5df
fix(tests): force using UTC so tests don't fail on a non-UTC timezone
2018-12-27 20:24:44 +01:00
Łukasz Mierzwa
7d52626489
fix(ui): send silences only to a single cluster node
...
Silences are shared by HA cluster members, when submitting a silence to a cluster try each each member but stop after first successful fetch
2018-12-01 17:58:40 +00:00
Łukasz Mierzwa
9f4ee09a56
fix(ui): only show one silence per Alertmanager cluster
...
HA clusters share silences which means that they are currently duplicated for each alertmanager instance in that cluster
2018-12-01 10:47:24 +00:00
Łukasz Mierzwa
3a905b748e
feat(api): consume Alertmanager cluster id in the UI
2018-12-01 09:57:59 +00:00
Łukasz Mierzwa
ffa446e8f6
chore(ui): update UI to consume cluster list as a dict
2018-11-30 23:59:58 +00:00
Łukasz Mierzwa
4babccbf0e
fix(tests): add clusters to tests
2018-11-30 19:41:13 +00:00
Łukasz Mierzwa
0ec81e8427
fix(ui): don't show @alertmanager labels on HA setup
...
Only show @alertmanager labels when we have more than one cluster present
2018-11-30 19:27:12 +00:00
Łukasz Mierzwa
fd2e852050
feat(ui): consumer Alertmanager version and cluster members
2018-11-30 18:35:34 +00:00
Łukasz Mierzwa
bfb509c0e7
chore(ui): use modal reference instead of class query
2018-11-21 21:54:49 +00:00
Łukasz Mierzwa
44e4d90651
chore(ui): react-datepicker 2.0 uses Date instead of moment
...
Latest react-datepicker no longer accepts moment instances, it uses plain js Date objects instead.
Migrate code to pass props as Date.
2018-11-19 21:40:05 +00:00
Łukasz Mierzwa
406c2c19bf
fix(ui): only break long words in annotations
2018-10-27 10:38:33 +01:00
Łukasz Mierzwa
87540017a4
chore(ui): drop margin between annotations and labels
2018-10-26 22:56:40 +01:00