Skip to content

Commit

Permalink
Stack items vertically instead
Browse files Browse the repository at this point in the history
  • Loading branch information
mehmetseckin committed Feb 21, 2020
1 parent 9b3710c commit db2631f
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions TimeZoneDisplay/components/Display/Display.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,15 @@ const iconStyles: IIconStyles = {
float: 'left'
}
};
const iconCardSectionStyles: ICardSectionStyles = {
const dropdownCardSectionStyles: ICardSectionStyles = {
root: {
alignSelf: 'stretch',
borderRight: '1px solid #F3F2F1'
borderBottom: '1px solid #F3F2F1'
}
};

const cardTokens: ICardTokens = { childrenMargin: 12, minWidth: 600 };
const iconCardSectionTokens: ICardSectionTokens = { padding: '0px 12px 0px 0px' };
const cardTokens: ICardTokens = { childrenMargin: 12 };
const dropdownCardSectionTokens: ICardSectionTokens = { padding: '0px 0px 12px 0px' };

export const Display = (props: IDisplayProps) => {
let { date, timeZone, format, options } = props;
Expand All @@ -45,8 +45,8 @@ export const Display = (props: IDisplayProps) => {
? TimeZoneConverter.convert(date, selectedTimeZone).toDotNetFormat(format, options)
: "N/A";

return <Card horizontal tokens={cardTokens}>
<Card.Section styles={iconCardSectionStyles} tokens={iconCardSectionTokens} horizontal>
return <Card tokens={cardTokens}>
<Card.Section styles={dropdownCardSectionStyles} tokens={dropdownCardSectionTokens}>
<Card.Item>
<Dropdown
onRenderPlaceHolder={_onRenderPlaceHolder}
Expand All @@ -58,7 +58,6 @@ export const Display = (props: IDisplayProps) => {
setSelectedTimeZone(option.key.toString())
}
}}
styles={{dropdown: {minWidth: 200}}}
/>
</Card.Item>
</Card.Section>
Expand Down

0 comments on commit db2631f

Please sign in to comment.