Skip to content

Commit

Permalink
Merge pull request #40314 from nextcloud/enh/a11y/search-labels
Browse files Browse the repository at this point in the history
enh(a11y): Add search contacts label
  • Loading branch information
Pytal authored Sep 8, 2023
2 parents 149e2a0 + 3695545 commit ce59e55
Show file tree
Hide file tree
Showing 7 changed files with 16 additions and 10 deletions.
2 changes: 1 addition & 1 deletion core/src/OC/contactsmenu.js
Original file line number Diff line number Diff line change
Expand Up @@ -294,7 +294,7 @@ const ContactsMenuView = View.extend({
contentTemplate: function(data) {
return this.templates.menu(
_.extend({
searchContactsText: t('core', 'Search contacts …')
searchContactsLabel: t('core', 'Search contacts'),
}, data)
)
},
Expand Down
4 changes: 2 additions & 2 deletions core/src/OC/contactsmenu/menu.handlebars
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<label class="hidden-visually" for="contactsmenu-search">{{searchContactsText}}</label>
<input id="contactsmenu-search" type="search" placeholder="{{searchContactsText}}" value="{{searchTerm}}">
<label for="contactsmenu-search">{{searchContactsLabel}}</label>
<input id="contactsmenu-search" type="search" value="{{searchTerm}}">
<div class="content">
</div>
8 changes: 7 additions & 1 deletion core/src/views/ContactsMenu.vue
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ export default {
#contactsmenu-menu {
/* show 2.5 to 4.5 entries depending on the screen height */
height: calc(100vh - 50px * 3);
max-height: calc(50px * 6 + 2px);
max-height: calc(50px * 6 + 2px + 26px);
min-height: calc(50px * 3.5);
width: 350px;
Expand All @@ -85,6 +85,12 @@ export default {
}
}
label[for="contactsmenu-search"] {
font-weight: bold;
font-size: 19px;
margin-left: 22px;
}
#contactsmenu-search {
width: calc(100% - 16px);
margin: 8px;
Expand Down
4 changes: 2 additions & 2 deletions dist/core-login.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/core-login.js.map

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions dist/core-main.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/core-main.js.map

Large diffs are not rendered by default.

0 comments on commit ce59e55

Please sign in to comment.