/labels.patch Secret
Created
May 21, 2019 14:40
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/playbooks/PlaybookSummary.js b/src/playbooks/PlaybookSummary.js | |
index 33a69a9..b750550 100644 | |
--- a/src/playbooks/PlaybookSummary.js | |
+++ b/src/playbooks/PlaybookSummary.js | |
@@ -12,6 +12,8 @@ import { | |
global_warning_color_100, | |
global_Color_light_100 | |
} from "@patternfly/react-tokens"; | |
+import { Button } from '@patternfly/react-core'; | |
+ | |
const StatusIcon = ({ status }) => { | |
switch (status) { | |
@@ -148,6 +150,11 @@ export default class Playbook extends Component { | |
</h1> | |
</StatusAndName> | |
<PlaybookInfos> | |
+ {playbook.labels.map(label => | |
+ <Button component="a" href="/playbooks/?label={label.name}" target="_blank" variant="secondary"> | |
+ {label.name} | |
+ </Button> | |
+ )} | |
<PlaybookInfo> | |
<b>{playbook.items.plays}</b> Plays | |
</PlaybookInfo> | |
@@ -175,6 +182,7 @@ export default class Playbook extends Component { | |
</Duration> | |
</PlaybookContent> | |
</div> | |
+ | |
</div> | |
</PlaybookWrapper> | |
); | |
-- | |
2.21.0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment