説明
Kibana version: 7.7.0
Elasticsearch version: 7.7.0
Server OS version: Ubuntu 18.04
Browser version: Chrome 81
Browser OS version: Windows 10
Original install method (e.g. download page, yum, from source, etc.): default tar.gz files
Describe the bug: If you select one or more follower indices in Management >
Cross-Cluster Replication, and click the Manage follower index button you see the appropriate menu action (if it's running you see the pause option, if it's paused you see the resume action). But after you take that action the index is still checked and when you click the Manage follower index` button again it now shows the same action which is now invalid.
Note: I have 2 single-node clusters but I think you can fake it and set one cluster to be added as a remote one for purposes of this issue.
Steps to reproduce:
- create a cross cluster replication follower index
- with it active, check the checkbox next to it and use the button to pause it;

- confirm pause in the pop-up
- without unchecking and rechecking the checkbox, click the button again.
Pause replicationis still available in that list. If you click it, you get the confirmation dialog again, and if you confirm on that, you get an error which doesn't really tell you why it failed;
Expected behavior: Ideally in step 4 above, when I click the button again, the option to pause shouldn't be there and the option to resume should. Another possible fix would be to uncheck the checkboxes after the first pause action is taken. Another possible fix would be to check the state before showing the confirmation dialog and showing a message that tells you it's already paused (not as good as the first suggestion) And lastly, the error message should be fixed to say WHY there was an error (because it was already paused).
All of this is the same the other direction. Going from paused to resume.
Screenshots (if relevant):
Errors in browser console (if relevant):
Provide logs and/or server output (if relevant):
Any additional context: Somewhat similar to this issue where the pop-up menu also stays open after an action is taken, thus still showing an action that is now invalid https://github.com/elastic/kibana/issues/56910