From 07a0d909f70ee92030985200f94c45056dab0340 Mon Sep 17 00:00:00 2001 From: corlard3y Date: Sun, 26 Jan 2025 20:35:18 +0100 Subject: [PATCH] chore: fix issues on firefox --- src/blocks/box/Box.tsx | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/blocks/box/Box.tsx b/src/blocks/box/Box.tsx index f06a46097d..acae94ec85 100644 --- a/src/blocks/box/Box.tsx +++ b/src/blocks/box/Box.tsx @@ -27,6 +27,17 @@ const StyledBox = styled.div.withConfig({ border: ${(props) => getBlocksBorder(props.border)}; position: ${(props) => props.position}; + ${(props) => { + if (props.width === '-webkit-fill-available') { + return ` + width: 100%; /* Fallback for all browsers */ + width: -moz-available; /* Firefox */ + width: -webkit-fill-available; /* Chrome, Safari */ + `; + } + return `width: ${props.width};`; + }} + // push custom scroll ${(props) => props.customScrollbar &&