edit layout for small resolution screens

This commit is contained in:
smanylov
2026-01-23 15:43:05 +07:00
parent 38ce69047d
commit f8ab107724
22 changed files with 367 additions and 140 deletions
+7 -3
View File
@@ -44,9 +44,13 @@ export default function LanguageSwitcher() {
}, 3000)
}
useClickOutside(dropdownRef, () => {
setIsOpen(false);
});
useClickOutside(
dropdownRef,
() => {
setIsOpen(false);
},
isOpen
);
useEffect(() => {
const handleEscape = (event: KeyboardEvent) => {
+6 -3
View File
@@ -18,9 +18,12 @@ interface ChildProps {
export default function DropDownList({ children, value, callBack, translatedValue }: DropDownListProps) {
const [isOpen, setIsOpen] = useState(false)
const dropdownRef = useRef<HTMLDivElement>(null)
useClickOutside(dropdownRef, () => {
setIsOpen(false);
});
useClickOutside(dropdownRef,
() => {
setIsOpen(false);
},
isOpen
);
const enhancedChildren = React.Children.map(children, (child, index) => {
if (React.isValidElement<ChildProps>(child)) {