Skip to content

Commit

Permalink
Move alt view dropdown to a button
Browse files Browse the repository at this point in the history
Signed-off-by: Sergio-Mira <sergio.mira@zendesk.com>
  • Loading branch information
Sergio-Mira committed Feb 4, 2023
1 parent 15017d5 commit 5cc8a41
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
// limitations under the License.

import * as React from 'react';
import { Dropdown, Icon, Menu } from 'antd';
import { Dropdown, Icon, Menu, Button } from 'antd';
import { Link } from 'react-router-dom';
import './AltViewOptions.css';

Expand Down Expand Up @@ -109,10 +109,10 @@ export default function AltViewOptions(props: Props) {
const dropdownText = currentItem ? currentItem.label : 'Alternate Views';
return (
<Dropdown overlay={menu}>
<div className="AltViewOptions">
<Button className="AltViewOptions">
{`${dropdownText} `}
<Icon type="down" />
</div>
</Button>
</Dropdown>
);
}
Original file line number Diff line number Diff line change
Expand Up @@ -70,13 +70,17 @@ exports[`AltViewOptions renders correctly 1`] = `
placement="bottomLeft"
prefixCls="ant-dropdown"
>
<div
<Button
block={false}
className="AltViewOptions"
ghost={false}
loading={false}
prefixCls="ant-btn"
>
Trace Timeline
<Icon
type="down"
/>
</div>
</Button>
</Dropdown>
`;

0 comments on commit 5cc8a41

Please sign in to comment.