sr-npm 1.7.156 → 1.7.158
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/pages/careersPage.js +12 -2
- package/pages/homePage.js +7 -1
package/package.json
CHANGED
package/pages/careersPage.js
CHANGED
|
@@ -271,9 +271,19 @@ async function handleDepartmentParam(_$w,department) {
|
|
|
271
271
|
fixDropdownOptions(optionsFromCMS, _$w);
|
|
272
272
|
}
|
|
273
273
|
|
|
274
|
-
_$w('#dropdownDepartment').value
|
|
274
|
+
if (_$w('#dropdownDepartment').options.find(option => option.value === departmentValue))
|
|
275
|
+
{
|
|
276
|
+
_$w('#dropdownDepartment').value = departmentValue;
|
|
277
|
+
await applyFilters(_$w, true); // Skip URL update since we're handling initial URL params
|
|
278
|
+
}
|
|
279
|
+
else{
|
|
280
|
+
console.warn("department value not found in dropdown options");
|
|
281
|
+
queryParams.remove(["department" ]);
|
|
282
|
+
|
|
283
|
+
}
|
|
284
|
+
|
|
275
285
|
|
|
276
|
-
|
|
286
|
+
|
|
277
287
|
}
|
|
278
288
|
|
|
279
289
|
function fixDropdownOptions(optionsFromCMS, _$w){
|
package/pages/homePage.js
CHANGED
|
@@ -48,7 +48,13 @@ function init(_$w) {
|
|
|
48
48
|
|
|
49
49
|
_$w('#searchInput').onInput(debouncedInput);
|
|
50
50
|
_$w('#searchInput').maxLength = 40;
|
|
51
|
-
|
|
51
|
+
_$w('#searchButton').onClick(()=>{
|
|
52
|
+
const trimmedInput = _$w('#searchInput').value.trim();
|
|
53
|
+
if (trimmedInput) {
|
|
54
|
+
location.to(`/positions?keyWord=${trimmedInput}`);
|
|
55
|
+
}
|
|
56
|
+
});
|
|
57
|
+
|
|
52
58
|
_$w('#searchInput').onKeyPress((event) => {
|
|
53
59
|
if (event.key === 'Enter') {
|
|
54
60
|
handleEnterPress(_$w('#searchInput').value);
|