Skip to content

Commit b868f1a

Browse files
committed
Update advanced search language
Why these changes are being introduced: UXWS has requested that he simplify the language for the advanced search dropdown. Relevant ticket(s): * https://mitlibraries.atlassian.net/browse/GDT-126 How this addresses that need: This updates the language as requested: "Advanced search" when the dropdown is closed, and "Close advanced search" when it's open. Side effects of this change: Though it emerged from the GDT UI design work, this is a general enhancement that will apply to all TIMDEX UI apps.
1 parent 1c6dae7 commit b868f1a

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

app/javascript/search_form.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,15 @@ function disableAdvanced() {
66
);
77
keyword_field.setAttribute('placeholder', 'Enter your search');
88
advanced_label.classList = 'closed';
9-
advanced_label.innerText = 'Show advanced search fields';
9+
advanced_label.innerText = 'Advanced search';
1010
};
1111

1212
function enableAdvanced() {
1313
advanced_field.setAttribute('value', 'true');
1414
keyword_field.setAttribute('aria-required', false);
1515
keyword_field.setAttribute('placeholder', 'Keyword anywhere');
1616
advanced_label.classList = 'open';
17-
advanced_label.innerText = 'Clear advanced search fields';
17+
advanced_label.innerText = 'Close advanced search';
1818
};
1919

2020
var advanced_field = document.getElementById('advanced-search-field');

app/views/search/_form.html.erb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,11 @@ if params[:q]
66
end
77

88
# Initial form setup is determined by the advanced parameter. Thereafter it is altered by javascript.
9-
advanced_label = "Show advanced search fields"
9+
advanced_label = "Advanced search"
1010
advanced_label_class = "closed"
1111
search_required = true
1212
if params[:advanced] == "true"
13-
advanced_label = "Clear advanced search fields"
13+
advanced_label = "Close advanced search"
1414
advanced_label_class = "open"
1515
search_required = false
1616
end

0 commit comments

Comments
 (0)