Merge branch '47752-buttons-on-new-file-page-wrap-outside-of-container-for-long-branch-names' into 'master'

Resolve "Buttons on new file page wrap outside of container for long branch names"

Closes #47752

See merge request gitlab-org/gitlab-ce!21015
This commit is contained in:
Annabel Gray 2018-08-10 16:47:06 +00:00
commit a3c2b39d10
3 changed files with 20 additions and 18 deletions

View File

@ -36,10 +36,7 @@
line-height: 35px;
padding-top: 7px;
padding-bottom: 7px;
.float-right {
height: 20px;
}
display: flex;
}
.editor-ref {
@ -60,20 +57,18 @@
.new-file-name {
display: inline-block;
max-width: 450px;
max-width: 420px;
float: left;
@media(max-width: map-get($grid-breakpoints, lg)-1) {
width: 280px;
}
@media(max-width: map-get($grid-breakpoints, md)-1) {
width: 180px;
}
}
.file-buttons {
font-size: 0;
display: flex;
flex: 1;
justify-content: flex-end;
}
.select2 {
@ -111,12 +106,10 @@
}
@include media-breakpoint-down(xs) {
@include media-breakpoint-down(sm) {
.file-editor {
.file-title {
.float-right {
height: auto;
}
display: block;
}
.new-file-name {
@ -144,6 +137,10 @@
}
}
}
.editor-ref {
max-width: 250px;
}
}
}

View File

@ -2,11 +2,11 @@
.file-holder-bottom-radius.file-holder.file.append-bottom-default
.js-file-title.file-title.clearfix{ data: { current_action: action } }
.editor-ref
.editor-ref.block-truncated
= sprite_icon('fork', size: 12)
= ref
%span.editor-file-name
- if current_action?(:edit) || current_action?(:update)
- if current_action?(:edit) || current_action?(:update)
%span.editor-file-name
= text_field_tag 'file_path', (params[:file_path] || @path),
class: 'form-control new-file-path js-file-path-name-input'
@ -16,7 +16,7 @@
= text_field_tag 'file_name', params[:file_name], placeholder: "File name",
required: true, class: 'form-control new-file-name js-file-path-name-input'
.float-right.file-buttons
.file-buttons
= button_tag class: 'soft-wrap-toggle btn', type: 'button', tabindex: '-1' do
%span.no-wrap
= custom_icon('icon_no_wrap')

View File

@ -0,0 +1,5 @@
---
title: Fix buttons on the new file page wrapping outside of the container
merge_request: 21015
author:
type: fixed