diff --git a/awx/ui/client/features/output/index.controller.js b/awx/ui/client/features/output/index.controller.js index 17dfb63c4c..488d994dc2 100644 --- a/awx/ui/client/features/output/index.controller.js +++ b/awx/ui/client/features/output/index.controller.js @@ -55,6 +55,10 @@ function JobsIndexController ( up: scrollPageUp }; + vm.fullscreen = { + isFullscreen: false + }; + render.requestAnimationFrame(() => init()); } diff --git a/awx/ui/client/features/output/index.view.html b/awx/ui/client/features/output/index.view.html index 0c4a92de07..52d34ccb66 100644 --- a/awx/ui/client/features/output/index.view.html +++ b/awx/ui/client/features/output/index.view.html @@ -1,14 +1,17 @@
-
+
-
+
{{ vm.title }}
- + +
diff --git a/awx/ui/client/features/output/jobs.strings.js b/awx/ui/client/features/output/jobs.strings.js index e17722da3f..f1f3ace11d 100644 --- a/awx/ui/client/features/output/jobs.strings.js +++ b/awx/ui/client/features/output/jobs.strings.js @@ -31,6 +31,11 @@ function JobsStrings (BaseString) { PROJECT: t.s('View the Project'), PROJECT_UPDATE: t.s('View Project checkout results') }; + + ns.expandCollapse = { + EXPAND: t.s('Expand Output'), + COLLAPSE: t.s('Collapse Output') + }; } JobsStrings.$inject = ['BaseStringService']; diff --git a/awx/ui/client/features/output/stats.directive.js b/awx/ui/client/features/output/stats.directive.js index 51fbd89afb..789fc29de6 100644 --- a/awx/ui/client/features/output/stats.directive.js +++ b/awx/ui/client/features/output/stats.directive.js @@ -30,8 +30,12 @@ function AtJobStatsController (_strings_, _status_) { vm.init = scope => { const { resource } = scope; + vm.fullscreen = scope.fullscreen; + vm.download = resource.model.get('related.stdout'); + vm.toggleStdoutFullscreenTooltip = strings.get('expandCollapse.EXPAND'); + vm.setHostStatusCounts(status.getHostStatusCounts()); scope.$watch(status.getPlayCount, value => { vm.plays = value; }); @@ -55,6 +59,13 @@ function AtJobStatsController (_strings_, _status_) { vm.statsAreAvailable = Boolean(status.getStatsEvent()); }; + + vm.toggleFullscreen = () => { + vm.fullscreen.isFullscreen = !vm.fullscreen.isFullscreen; + vm.toggleStdoutFullscreenTooltip = vm.fullscreen.isFullscreen ? + strings.get('expandCollapse.COLLAPSE') : + strings.get('expandCollapse.EXPAND'); + }; } function atJobStats () { @@ -67,9 +78,13 @@ function atJobStats () { controller: [ 'JobStrings', 'JobStatusService', + '$scope', AtJobStatsController ], - scope: { resource: '=', }, + scope: { + resource: '=', + fullscreen: '=' + } }; } diff --git a/awx/ui/client/features/output/stats.partial.html b/awx/ui/client/features/output/stats.partial.html index 95668d4e2b..70d980ed33 100644 --- a/awx/ui/client/features/output/stats.partial.html +++ b/awx/ui/client/features/output/stats.partial.html @@ -19,20 +19,20 @@ - +
diff --git a/awx/ui/client/lib/components/input/_index.less b/awx/ui/client/lib/components/input/_index.less index 1f8962bccd..adcc2f2505 100644 --- a/awx/ui/client/lib/components/input/_index.less +++ b/awx/ui/client/lib/components/input/_index.less @@ -70,6 +70,10 @@ height: @at-height-textarea; } +.at-Input-button--active { + .at-mixin-ButtonColor(at-color-info, at-color-default); +} + .at-Input--focus { border-color: @at-color-input-focus; } @@ -269,4 +273,4 @@ cursor: not-allowed; } } -} \ No newline at end of file +}