File tree Expand file tree Collapse file tree 1 file changed +7
-5
lines changed Expand file tree Collapse file tree 1 file changed +7
-5
lines changed Original file line number Diff line number Diff line change @@ -98,10 +98,8 @@ const Input: React.FC = () => {
9898 }
9999 }
100100
101- if ( buttonRef ?. current ) {
102- if ( button ) {
103- button . addEventListener ( "click" , focusInput ) ;
104- }
101+ if ( button ) {
102+ button . addEventListener ( "click" , focusInput ) ;
105103 }
106104
107105 return ( ) => {
@@ -128,7 +126,11 @@ const Input: React.FC = () => {
128126 if ( arrow && div && div . classList . contains ( "hidden" ) ) {
129127 div . classList . remove ( "hidden" ) ;
130128 div . classList . add ( "block" ) ;
131- if ( window . screen . height - 100 < div . getBoundingClientRect ( ) . bottom ) {
129+ // window.innerWidth === 767
130+ if (
131+ window . innerWidth > 767 &&
132+ window . screen . height - 100 < div . getBoundingClientRect ( ) . bottom
133+ ) {
132134 div . classList . add ( "bottom-full" ) ;
133135 div . classList . add ( "mb-2.5" ) ;
134136 div . classList . remove ( "mt-2.5" ) ;
You can’t perform that action at this time.
0 commit comments