Skip to content

Commit

Permalink
#694 Fix ontology viewer not working on mobile
Browse files Browse the repository at this point in the history
  • Loading branch information
Polleps authored and joepio committed Nov 7, 2023
1 parent ffb7f83 commit 39a757c
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ export function AtomicSelectInput({
};

return (
<InputWrapper>
<StyledInputWrapper>
<SelectWrapper disabled={!!props.disabled}>
<Select {...props} onChange={handleChange} value={value as string}>
{options.map(option => (
Expand All @@ -40,10 +40,14 @@ export function AtomicSelectInput({
))}
</Select>
</SelectWrapper>
</InputWrapper>
</StyledInputWrapper>
);
}

const StyledInputWrapper = styled(InputWrapper)`
min-width: 15ch;
`;

const SelectWrapper = styled.span<{ disabled: boolean }>`
width: 100%;
padding-inline: 0.2rem;
Expand Down
6 changes: 6 additions & 0 deletions browser/data-browser/src/views/OntologyPage/OntologyPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,12 @@ const FullPageWrapper = styled.div<{ edit: boolean }>`
--ontology-graph-ratio: 16/9;
}
@container (max-width: 600px) {
grid-template-areas: ${p =>
p.edit ? `'title' 'list' 'list'` : `'title' 'graph' 'list'`};
grid-template-columns: 100%;
}
padding-bottom: 3rem;
`;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ export function PropertyLineWrite({

return (
<ListItem>
<Row center>
<Row center wrapItems>
<InputSwitcher
commit
required
Expand Down

0 comments on commit 39a757c

Please sign in to comment.