summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMayra Cabrera <mcabrera@gitlab.com>2018-05-17 20:54:08 +0000
committerMayra Cabrera <mcabrera@gitlab.com>2018-05-17 20:54:08 +0000
commit3706cdc01efc4b0bb86dedd3848c86d6a46b957f (patch)
tree850a3ab362db6cf76db6b6574488dd1f0eb3a961
parent82fbbe45011c8feaf24828575f66be81c3db7c85 (diff)
parentcc4f7ef41c65d4a3ac84b91c652fe4b49bfff493 (diff)
downloadgitlab-ce-3706cdc01efc4b0bb86dedd3848c86d6a46b957f.tar.gz
Merge branch '10-8-stable-prepare-rc12' into '10-8-stable'
Prepare 10.8 RC12 release See merge request gitlab-org/gitlab-ce!19005
-rw-r--r--app/assets/stylesheets/framework/snippets.scss3
-rw-r--r--app/models/list.rb3
-rw-r--r--app/views/shared/boards/components/_board.html.haml2
-rw-r--r--app/views/shared/snippets/_header.html.haml2
-rw-r--r--changelogs/unreleased/46303_copy_button_fix_embedded_snippets.yml5
-rw-r--r--config/initializers/deprecations.rb8
-rw-r--r--spec/fixtures/api/schemas/list.json2
7 files changed, 19 insertions, 6 deletions
diff --git a/app/assets/stylesheets/framework/snippets.scss b/app/assets/stylesheets/framework/snippets.scss
index 606d4675f19..430633bb01b 100644
--- a/app/assets/stylesheets/framework/snippets.scss
+++ b/app/assets/stylesheets/framework/snippets.scss
@@ -67,7 +67,8 @@
padding: 8px 40px;
}
- .embed-toggle {
+ .embed-toggle,
+ .snippet-clipboard-btn {
height: 35px;
}
}
diff --git a/app/models/list.rb b/app/models/list.rb
index 918275be142..5daf35ef845 100644
--- a/app/models/list.rb
+++ b/app/models/list.rb
@@ -31,7 +31,8 @@ class List < ActiveRecord::Base
if options.key?(:label)
json[:label] = label.as_json(
project: board.project,
- only: [:id, :title, :description, :color]
+ only: [:id, :title, :description, :color],
+ methods: [:text_color]
)
end
end
diff --git a/app/views/shared/boards/components/_board.html.haml b/app/views/shared/boards/components/_board.html.haml
index 4bff6468bb0..aea40df41b0 100644
--- a/app/views/shared/boards/components/_board.html.haml
+++ b/app/views/shared/boards/components/_board.html.haml
@@ -15,7 +15,7 @@
":title" => '(list.label ? list.label.description : "")',
data: { container: "body", placement: "bottom" },
class: "label color-label title board-title-text",
- ":style" => "{ backgroundColor: (list.label && list.label.color ? list.label.color : null), color: (list.label && list.label.text_color ? list.label.text_color : \"#2e2e2e\") }" }
+ ":style" => "{ backgroundColor: (list.label && list.label.color ? list.label.color : null), color: (list.label && list.label.textColor ? list.label.textColor : \"#2e2e2e\") }" }
{{ list.title }}
- if can?(current_user, :admin_list, current_board_parent)
diff --git a/app/views/shared/snippets/_header.html.haml b/app/views/shared/snippets/_header.html.haml
index 836230ae8ee..9f55c10d19b 100644
--- a/app/views/shared/snippets/_header.html.haml
+++ b/app/views/shared/snippets/_header.html.haml
@@ -45,6 +45,6 @@
%strong.embed-toggle-list-item= _("Share")
%input.js-snippet-url-area.snippet-embed-input.form-control{ type: "text", autocomplete: 'off', value: snippet_embed }
.input-group-btn
- %button.js-clipboard-btn.btn.btn-default.has-tooltip{ title: "Copy to clipboard", 'data-clipboard-target': '#snippet-url-area' }
+ %button.js-clipboard-btn.snippet-clipboard-btn.btn.btn-default.has-tooltip{ title: "Copy to clipboard", 'data-clipboard-target': '.js-snippet-url-area' }
= sprite_icon('duplicate', size: 16)
.clearfix
diff --git a/changelogs/unreleased/46303_copy_button_fix_embedded_snippets.yml b/changelogs/unreleased/46303_copy_button_fix_embedded_snippets.yml
new file mode 100644
index 00000000000..c8cdf3672b3
--- /dev/null
+++ b/changelogs/unreleased/46303_copy_button_fix_embedded_snippets.yml
@@ -0,0 +1,5 @@
+---
+title: fixed copy to blipboard button in embed bar of snippets
+merge_request: 18923
+author: haseebeqx
+type: fixed
diff --git a/config/initializers/deprecations.rb b/config/initializers/deprecations.rb
index 2476ea9e38a..14616e726d9 100644
--- a/config/initializers/deprecations.rb
+++ b/config/initializers/deprecations.rb
@@ -1,5 +1,9 @@
-deprecator = ActiveSupport::Deprecation.new('11.0', 'GitLab')
+if Rails.env.development? || ENV['GITLAB_LEGACY_PATH_LOG_MESSAGE']
+ deprecator = ActiveSupport::Deprecation.new('11.0', 'GitLab')
+
+ deprecator.behavior = -> (message, callstack) {
+ Rails.logger.warn("#{message}: #{callstack[1..20].join}")
+ }
-if Gitlab.dev_env_or_com?
ActiveSupport::Deprecation.deprecate_methods(Gitlab::GitalyClient::StorageSettings, :legacy_disk_path, deprecator: deprecator)
end
diff --git a/spec/fixtures/api/schemas/list.json b/spec/fixtures/api/schemas/list.json
index 622a1e40d07..05922df6b81 100644
--- a/spec/fixtures/api/schemas/list.json
+++ b/spec/fixtures/api/schemas/list.json
@@ -17,6 +17,7 @@
"required": [
"id",
"color",
+ "text_color",
"description",
"title",
"priority"
@@ -29,6 +30,7 @@
},
"description": { "type": ["string", "null"] },
"title": { "type": "string" },
+ "title": { "text_color": "string" },
"priority": { "type": ["integer", "null"] }
}
},