diff --git a/ui/src/App.js b/ui/src/App.js index 2d1be1474..677c2ae2d 100644 --- a/ui/src/App.js +++ b/ui/src/App.js @@ -52,7 +52,10 @@ class App extends Component { settingsStore={this.settingsStore} /> - + initialAlertsToRender) by dividing it into 5 clicks. -// Don't use step lower than 5, too much clicking if we have a group of 9: -// * we'll show initially 5 -// * step would be 1 -// * 4 extra clicks to see the entire group -// but ensure that step wouldn't push us above totalSize -// With 9 alerts and rendering 5 initially we want to show extra 9 after one -// click, and when user clicks showLess we want to go back to 5. -function getStepSize(totalSize) { - return Math.min( - Math.max(Math.round((totalSize - initialAlertsToRender) / 5), 5), - totalSize - initialAlertsToRender - ); -} - const LoadButton = ({ icon, action }) => { return (