diff options
author | Evan Read <eread@gitlab.com> | 2020-12-03 01:46:16 +0300 |
---|---|---|
committer | Susan Tacker <stacker@gitlab.com> | 2020-12-03 01:46:16 +0300 |
commit | 30442749685c5f2f819ddff22b341bcc8b74ad31 (patch) | |
tree | 8e8fde7a685ca376856a4b71c533941a7a6eeed1 /lib | |
parent | 93f0237d681ed27ddf6fcb6641db11f4a928a29f (diff) |
Convert product tier badges to GitLab SVGs
Also updates tests and CI configuration to support tests.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/gitlab/navigation.rb | 4 | ||||
-rw-r--r-- | lib/helpers/icons_helper.rb | 2 |
2 files changed, 4 insertions, 2 deletions
diff --git a/lib/gitlab/navigation.rb b/lib/gitlab/navigation.rb index ae5dbe9c..32071322 100644 --- a/lib/gitlab/navigation.rb +++ b/lib/gitlab/navigation.rb @@ -1,8 +1,10 @@ require_relative '../helpers/generic' +require_relative '../helpers/icons_helper' module Gitlab class Navigation include Nanoc::Helpers::Generic + include Nanoc::Helpers::IconsHelper def initialize(items, item) @items = items @@ -30,7 +32,7 @@ module Gitlab def optional_ee_badge(element) return unless element.ee_only? - %[<span class="badges-drop global-nav-badges" data-toggle="tooltip" data-placement="top" title="Available in #{element.ee_tier}"><i class="fa fa-info-circle" aria-hidden="true"></i></span>] + %(<span class="badges-drop global-nav-badges" data-toggle="tooltip" data-placement="top" title="Available in #{element.ee_tier}">#{icon('information-o', 14)}</span>) end def children diff --git a/lib/helpers/icons_helper.rb b/lib/helpers/icons_helper.rb index dbd3035c..0f1e1728 100644 --- a/lib/helpers/icons_helper.rb +++ b/lib/helpers/icons_helper.rb @@ -6,7 +6,7 @@ module Nanoc::Helpers module IconsHelper extend self - ICONS_SVG = '/assets/images/icons.svg' + ICONS_SVG = '/assets/images/icons.svg' unless const_defined?('ICONS_SVG') GITLAB_SVGS_MAPPING = { 'bulb' => 'tip', |