Commit 6a7b6730 authored by Luke Bennett's avatar Luke Bennett Committed by Annabel Dunstone Gray

JS review changes - Removed window from window.gl in dispatcher

Added page:load event as ready isnt fired by turbolinks

Fix dropdown menu link click registration
parent 113050c5
...@@ -127,7 +127,7 @@ ...@@ -127,7 +127,7 @@
} }
break; break;
case 'projects:pipelines:show': case 'projects:pipelines:show':
new window.gl.Pipelines(); new gl.Pipelines();
break; break;
case 'groups:activity': case 'groups:activity':
new Activities(); new Activities();
......
...@@ -4,6 +4,7 @@ ...@@ -4,6 +4,7 @@
constructor() { constructor() {
$(document).off('click', '.toggle-pipeline-btn').on('click', '.toggle-pipeline-btn', this.toggleGraph); $(document).off('click', '.toggle-pipeline-btn').on('click', '.toggle-pipeline-btn', this.toggleGraph);
$(document).off('ready.addMarginToBuildColumns').on('ready.addMarginToBuildColumns', this.addMarginToBuildColumns); $(document).off('ready.addMarginToBuildColumns').on('ready.addMarginToBuildColumns', this.addMarginToBuildColumns);
$(document).off('page:load.addMarginToBuildColumns').on('page:load.addMarginToBuildColumns', this.addMarginToBuildColumns);
} }
toggleGraph() { toggleGraph() {
......
...@@ -373,6 +373,9 @@ ...@@ -373,6 +373,9 @@
} }
.build-content { .build-content {
display: -ms-flexbox;
display: -webkit-flex;
display: flex;
width: 164px; width: 164px;
.ci-status-icon { .ci-status-icon {
...@@ -403,6 +406,7 @@ ...@@ -403,6 +406,7 @@
width: auto; width: auto;
padding: 0; padding: 0;
color: $gl-text-color-light; color: $gl-text-color-light;
flex-grow: 1;
.ci-status-text { .ci-status-text {
max-width: 112px; max-width: 112px;
......
...@@ -10,5 +10,5 @@ ...@@ -10,5 +10,5 @@
- else - else
%li.build %li.build
.curve .curve
.dropdown.inline.build-content{ type: 'button', data: { toggle: 'dropdown' } } .dropdown.inline.build-content
= render "projects/commit/pipeline_status_group", name: group_name, subject: grouped_statuses = render "projects/commit/pipeline_status_group", name: group_name, subject: grouped_statuses
- group_status = CommitStatus.where(id: subject).status - group_status = CommitStatus.where(id: subject).status
%span.ci-status-icon %span.ci-status-icon
= render_status_with_link('build', group_status) = render_status_with_link('build', group_status)
%button.dropdown-menu-toggle %button.dropdown-menu-toggle{ type: 'button', data: { toggle: 'dropdown' } }
%span.ci-status-text %span.ci-status-text
= name = name
%span.badge= subject.size %span.badge= subject.size
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment