fix formview style

This commit is contained in:
Jan Prochazka
2021-01-23 20:40:49 +01:00
parent e253cfb1b0
commit 213ee01fa6

View File

@@ -26,6 +26,14 @@ const Table = styled.table`
outline: none; outline: none;
`; `;
const OuterWrapper = styled.div`
position: absolute;
left: 0;
top: 0;
bottom: 0;
right: 0;
`;
const Wrapper = styled.div` const Wrapper = styled.div`
position: absolute; position: absolute;
left: 0; left: 0;
@@ -477,6 +485,7 @@ export default function FormView(props) {
if (!formDisplay || !formDisplay.isLoadedCorrectly) return toolbar; if (!formDisplay || !formDisplay.isLoadedCorrectly) return toolbar;
return ( return (
<OuterWrapper>
<Wrapper ref={wrapperRef} onContextMenu={handleContextMenu}> <Wrapper ref={wrapperRef} onContextMenu={handleContextMenu}>
{columnChunks.map((chunk, chunkIndex) => ( {columnChunks.map((chunk, chunkIndex) => (
<Table key={chunkIndex} onMouseDown={handleTableMouseDown}> <Table key={chunkIndex} onMouseDown={handleTableMouseDown}>
@@ -565,9 +574,10 @@ export default function FormView(props) {
))} ))}
<FocusField type="text" ref={focusFieldRef} onKeyDown={handleKeyDown} /> <FocusField type="text" ref={focusFieldRef} onKeyDown={handleKeyDown} />
{rowCountInfo && <RowCountLabel theme={theme}>{rowCountInfo}</RowCountLabel>}
{toolbar} {toolbar}
</Wrapper> </Wrapper>
{rowCountInfo && <RowCountLabel theme={theme}>{rowCountInfo}</RowCountLabel>}
</OuterWrapper>
); );
} }