diff options
author | Marius Balteanu <marius.balteanu@zitec.com> | 2024-12-09 21:35:20 +0000 |
---|---|---|
committer | Marius Balteanu <marius.balteanu@zitec.com> | 2024-12-09 21:35:20 +0000 |
commit | 1ad5daa3606494d849dc2b68a0a55dc74e2f9dfa (patch) | |
tree | 273e569e6d2e7740586eaf79334aa9376331a49a | |
parent | a563083434dc5d5e1ff793afac4b3b9551413bb6 (diff) | |
download | redmine-1ad5daa3606494d849dc2b68a0a55dc74e2f9dfa.tar.gz redmine-1ad5daa3606494d849dc2b68a0a55dc74e2f9dfa.zip |
Merge r23368 and r23369 from trunk to 6.0-stable (#41714).
git-svn-id: https://svn.redmine.org/redmine/branches/6.0-stable@23375 e93f8b46-1217-0410-a6f0-8f06a7374b81
-rw-r--r-- | app/assets/images/icons.svg | 4 | ||||
-rw-r--r-- | app/assets/images/search.svg | 1 | ||||
-rw-r--r-- | app/assets/stylesheets/application.css | 6 | ||||
-rw-r--r-- | app/assets/stylesheets/responsive.css | 19 | ||||
-rw-r--r-- | app/helpers/application_helper.rb | 2 | ||||
-rw-r--r-- | app/views/layouts/base.html.erb | 2 | ||||
-rw-r--r-- | config/icon_source.yml | 2 |
7 files changed, 18 insertions, 18 deletions
diff --git a/app/assets/images/icons.svg b/app/assets/images/icons.svg index 84d68904a..3bd8ae53b 100644 --- a/app/assets/images/icons.svg +++ b/app/assets/images/icons.svg @@ -331,6 +331,10 @@ <path d="M12 14m-2 0a2 2 0 1 0 4 0a2 2 0 1 0 -4 0"/> <path d="M14 4l0 4l-6 0l0 -4"/> </symbol> + <symbol viewBox="0 0 24 24" stroke-linecap="round" stroke-linejoin="round" id="icon--search"> + <path d="M10 10m-7 0a7 7 0 1 0 14 0a7 7 0 1 0 -14 0"/> + <path d="M21 21l-6 -6"/> + </symbol> <symbol viewBox="0 0 24 24" stroke-linecap="round" stroke-linejoin="round" id="icon--server-authentication"> <path d="M3 4m0 3a3 3 0 0 1 3 -3h12a3 3 0 0 1 3 3v2a3 3 0 0 1 -3 3h-12a3 3 0 0 1 -3 -3z"/> <path d="M3 12m0 3a3 3 0 0 1 3 -3h12a3 3 0 0 1 3 3v2a3 3 0 0 1 -3 3h-12a3 3 0 0 1 -3 -3z"/> diff --git a/app/assets/images/search.svg b/app/assets/images/search.svg new file mode 100644 index 000000000..c8142072b --- /dev/null +++ b/app/assets/images/search.svg @@ -0,0 +1 @@ +<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M10 10m-7 0a7 7 0 1 0 14 0a7 7 0 1 0 -14 0" /><path d="M21 21l-6 -6" /></svg>
\ No newline at end of file diff --git a/app/assets/stylesheets/application.css b/app/assets/stylesheets/application.css index 89d385ca0..a45f821b6 100644 --- a/app/assets/stylesheets/application.css +++ b/app/assets/stylesheets/application.css @@ -268,7 +268,9 @@ a#toggle-completed-versions {color:#999;} } .drdn.expanded .drdn-content {display:block;} -.drdn-content .quick-search {margin:8px;} +.drdn-content .quick-search {margin:8px; display: flex; align-items: center;} +.drdn-content .quick-search svg {margin-left: 5px; position: absolute;} +.drdn-content .quick-search input.autocomplete {background: none; padding-left: 24px !important;} .drdn-content .autocomplete {box-sizing: border-box; width:100% !important; height:28px;} .drdn-content .autocomplete:focus {border-color:#5ad;} .drdn-items {max-height:400px; overflow:auto;} @@ -1140,7 +1142,7 @@ input#principal_search, input#user_search {width:90%} .roles-selection label {display:inline-block; width:210px;} input.autocomplete { - background: #fff url(/magnifier.png) no-repeat 2px 50%; padding-left:20px !important; + background: #fff url(/search.svg) no-repeat 2px 50%; padding-left:20px !important; } input.autocomplete.ajax-loading { background-image: url(/loading.gif); diff --git a/app/assets/stylesheets/responsive.css b/app/assets/stylesheets/responsive.css index ea30ab86c..4eff84187 100644 --- a/app/assets/stylesheets/responsive.css +++ b/app/assets/stylesheets/responsive.css @@ -184,9 +184,14 @@ font-size:0.9375rem; font-weight:normal; } + #project-jump .drdn-content svg { + width: 1.25rem; + height: 1.25rem; + } #project-jump .drdn-content .autocomplete { height:40px; font-size:1.25rem; + padding-left: 28px !important; } #project-jump .drdn-content a { padding:8px; @@ -259,21 +264,7 @@ content: '\2261'; } - /* search magnifier icon */ - .search-magnifier { - font-family: var(--fonts-main); - color: #bbb; - - cursor: pointer; - -webkit-transform: rotate(-45deg); - -moz-transform: rotate(45deg); - -o-transform: rotate(45deg); - } - .search-magnifier--flyout { - font-size: 1.5625rem; - line-height: 54px; - position: absolute; z-index: 1; left: 12px; diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index bac8da266..d708019c9 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -610,7 +610,7 @@ module ApplicationHelper :class => (@project.nil? && controller.class.main_menu ? 'selected' : nil)) content = content_tag('div', - content_tag('div', q, :class => 'quick-search') + + content_tag('div', sprite_icon('search', icon_only: true, size: 18) + q, :class => 'quick-search') + content_tag('div', render_projects_for_jump_box(projects, selected: @project), :class => 'drdn-items projects selection') + content_tag('div', all, :class => 'drdn-items all-projects selection'), diff --git a/app/views/layouts/base.html.erb b/app/views/layouts/base.html.erb index 031c847f3..fdd560481 100644 --- a/app/views/layouts/base.html.erb +++ b/app/views/layouts/base.html.erb @@ -27,7 +27,7 @@ <div class="flyout-menu__search"> <%= form_tag(search_path(id: @project), :method => :get ) do %> <%= hidden_field_tag(controller.default_search_scope, 1, :id => nil) if controller.default_search_scope %> - <%= label_tag 'flyout-search', '⚲'.html_safe, :class => 'search-magnifier search-magnifier--flyout' %> + <%= label_tag 'flyout-search', sprite_icon('search', l(:label_search), icon_only: true), :class => 'search-magnifier search-magnifier--flyout' %> <%= text_field_tag 'q', @question, :id => 'flyout-search', :class => 'small js-search-input', :placeholder => l(:label_search) %> <% end %> </div> diff --git a/config/icon_source.yml b/config/icon_source.yml index a97b4bcb9..92ea716b1 100644 --- a/config/icon_source.yml +++ b/config/icon_source.yml @@ -197,3 +197,5 @@ svg: chevrons-left - name: key svg: key +- name: search + svg: search |