Skip to content

Commit 24a8ab6

Browse files
Merge pull request #1125 from newrelic/develop
fix: unscrollable when focus is on search , t&c content
2 parents b56fc2a + f392758 commit 24a8ab6

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

packages/gatsby-theme-newrelic/src/components/GlobalFooter.js

+6-1
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@ const GlobalFooter = ({ className }) => {
6767
margin: 0 auto;
6868
6969
@media screen and (max-width: 760px) {
70+
font-size: 0.5rem;
7071
justify-content: center;
7172
text-align: center;
7273
grid-template-columns: auto;
@@ -102,7 +103,7 @@ const GlobalFooter = ({ className }) => {
102103
flex-wrap: wrap;
103104
justify-content: flex-end;
104105
grid-area: legal;
105-
max-width: ${osanoPresent ? '29rem' : '32rem'};
106+
max-width: ${osanoPresent ? 'fit-content' : '32rem'};
106107
107108
a {
108109
margin-left: 0.75rem;
@@ -141,6 +142,10 @@ const GlobalFooter = ({ className }) => {
141142
&:hover svg {
142143
filter: invert(100%);
143144
}
145+
146+
@media screen and (max-width: 760px) {
147+
font-size: 0.5rem;
148+
}
144149
`}
145150
onClick={handlePrivacyClick}
146151
>

packages/gatsby-theme-newrelic/src/components/GlobalSearch.js

+1-2
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,6 @@ const GlobalSearch = ({ onClose }) => {
3232
const [selected, setSelected] = useState(null);
3333
const possibleSelections = results.length + recentQueries.length;
3434

35-
useScrollFreeze(open);
36-
3735
const moveUp = () =>
3836
setSelected((s) => {
3937
if (s == null) return possibleSelections - 1;
@@ -69,6 +67,7 @@ const GlobalSearch = ({ onClose }) => {
6967
});
7068

7169
const showSearchDropdown = query.length > 1 && open;
70+
useScrollFreeze(showSearchDropdown);
7271

7372
return (
7473
<>

0 commit comments

Comments
 (0)