diff --git a/src/components/containers/Sticky/index.tsx b/src/components/containers/Sticky/index.tsx index 232db8ff..15de9b7e 100644 --- a/src/components/containers/Sticky/index.tsx +++ b/src/components/containers/Sticky/index.tsx @@ -1,16 +1,14 @@ import React, { DetailsHTMLAttributes, FC } from 'react'; -import StickyBox from 'react-stickynode'; +import StickyBox from 'react-sticky-box'; interface IProps extends DetailsHTMLAttributes { offsetTop?: number; } -const Sticky: FC = ({ children, offsetTop = 65 }) => { - return ( - - {children} - - ); -}; +const Sticky: FC = ({ children, offsetTop = 65 }) => ( + + {children} + +); export { Sticky }; diff --git a/src/components/tags/TagAutocomplete/index.tsx b/src/components/tags/TagAutocomplete/index.tsx index 3949c267..b16ac0c5 100644 --- a/src/components/tags/TagAutocomplete/index.tsx +++ b/src/components/tags/TagAutocomplete/index.tsx @@ -35,6 +35,7 @@ const TagAutocomplete: VFC = ({ const pop = usePopper(wrapper?.current?.parentElement, wrapper.current, { placement: 'bottom-end', + strategy: 'fixed', modifiers: [ { name: 'offset', diff --git a/src/containers/tags/TagInput/index.tsx b/src/containers/tags/TagInput/index.tsx index e8da7c0c..03dfd502 100644 --- a/src/containers/tags/TagInput/index.tsx +++ b/src/containers/tags/TagInput/index.tsx @@ -101,8 +101,8 @@ const TagInput: FC = ({ exclude, onAppend, onClearTag, onSubmit }) => { const onAutocompleteSelect = useCallback( (val: string) => { - onAppend([val]); setInput(''); + onAppend([val]); }, [onAppend, setInput] );