diff options
Diffstat (limited to 'gui/src/renderer/components/cell')
| -rw-r--r-- | gui/src/renderer/components/cell/Selector.tsx | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/gui/src/renderer/components/cell/Selector.tsx b/gui/src/renderer/components/cell/Selector.tsx index cd308fa3e4..68507b4591 100644 --- a/gui/src/renderer/components/cell/Selector.tsx +++ b/gui/src/renderer/components/cell/Selector.tsx @@ -17,11 +17,12 @@ interface ISelectorProps<T> { onSelect: (value: T) => void; selectedCellRef?: React.Ref<HTMLButtonElement>; className?: string; + hasFooter?: boolean; } -const Section = styled(Cell.Section)({ - marginBottom: 20, -}); +const Section = styled(Cell.Section)((props: { hasFooter: boolean }) => ({ + marginBottom: props.hasFooter ? 0 : '20px', +})); export default class Selector<T> extends React.Component<ISelectorProps<T>> { public render() { @@ -49,7 +50,10 @@ export default class Selector<T> extends React.Component<ISelectorProps<T>> { return ( <AriaInput> - <Section role="listbox" className={this.props.className}> + <Section + role="listbox" + className={this.props.className} + hasFooter={this.props.hasFooter ?? false}> {title} {items} </Section> |
