Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions src/components/Dialog/Dialog.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,11 @@ export interface DialogProps extends ThemeProps, StyleProps {
type Props = DialogProps;

const Container = styled('div', (props: ThemeProps) => ({
width: '640px',
maxHeight: '480px',
width: '90%',
maxWidth: '800px',
maxHeight: '90vh',
display: 'flex',
flexDirection: 'column',
color: props.theme.color,
}));

Expand Down
14 changes: 12 additions & 2 deletions src/components/interface/Widget.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,8 @@ const Container = styled('div', (props: ThemeProps & ModeProps) => ({
borderRadius: props.mode === Mode.Floating ? `${props.theme.borderRadius}px` : undefined,
border: `1px solid ${props.theme.borderColor}`,
overflow: 'hidden',
flexBasis: '0',
flex: 1,
minHeight: 0,
pointerEvents: 'auto',
backgroundColor: props.theme.backgroundColor,
borderTop: props.mode === Mode.Sidebar ? 'none' : undefined,
Expand Down Expand Up @@ -163,6 +164,13 @@ const Title = styled('span', (props: ThemeProps & { $hasComponents: boolean }) =
whiteSpace: 'nowrap',
}));

const Content = styled('div', {
flex: 1,
overflowY: 'auto',
overflowX: 'hidden',
minHeight: 0,
});

const sizeIcon = (size: Size): IconProp => {
switch (size.type) {
case Size.Type.Partial: {
Expand Down Expand Up @@ -244,7 +252,9 @@ class Widget extends React.PureComponent<Props, State> {
.filter((self, i) => !hideActiveSize || i !== size)
}
</Chrome>
{children}
<Content>
{children}
</Content>
</Container>
);
}
Expand Down