Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2019-12-05 21:07:51 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2019-12-05 21:07:51 +0300
commit6a7cc8c14727f6fac64a5be6838764d8d5d41468 (patch)
tree97c8a3c2f180d26f0f8f0baaa3230352b8ef1efb /app/views/shared
parent872319738757edc0483346c75a2407f7019b963f (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/views/shared')
-rw-r--r--app/views/shared/buttons/_project_feature_toggle.html.haml16
1 files changed, 16 insertions, 0 deletions
diff --git a/app/views/shared/buttons/_project_feature_toggle.html.haml b/app/views/shared/buttons/_project_feature_toggle.html.haml
new file mode 100644
index 00000000000..0f630786455
--- /dev/null
+++ b/app/views/shared/buttons/_project_feature_toggle.html.haml
@@ -0,0 +1,16 @@
+- class_list ||= "js-project-feature-toggle project-feature-toggle"
+- data ||= nil
+- disabled ||= false
+- is_checked ||= false
+- label ||= nil
+
+%button{ type: 'button',
+ class: "#{class_list} #{'is-disabled' if disabled} #{'is-checked' if is_checked}",
+ "aria-label": label,
+ disabled: disabled,
+ data: data }
+ - if yield.present?
+ = yield
+ %span.toggle-icon
+ = sprite_icon('status_success_borderless', size: 16, css_class: 'toggle-icon-svg toggle-status-checked')
+ = sprite_icon('status_failed_borderless', size: 16, css_class: 'toggle-icon-svg toggle-status-unchecked')