Skip to content

Commit

Permalink
Merge pull request #21 from maryia-matskevich-deriv/maryia/bot_builde…
Browse files Browse the repository at this point in the history
…r_toolbar

[BOT]Maryia/feat: make work run panel with summary, transactions tabs
  • Loading branch information
sandeep-deriv authored Jul 11, 2024
2 parents 6450a8e + e101810 commit 05303ff
Show file tree
Hide file tree
Showing 9 changed files with 31 additions and 12 deletions.
1 change: 1 addition & 0 deletions public/assets/icons/IcBox.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions public/assets/icons/IcCross.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions public/assets/icons/IcDbotDownload.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions public/assets/icons/IcDbotViewDetail.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 5 additions & 0 deletions src/components/download/download.scss
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,10 @@
padding: 12px;
padding-left: 16px;
border: solid 1px var(--general-section-1);

.download__button,
&__view-detail-button {
height: 3.2rem;
}
}
}
12 changes: 8 additions & 4 deletions src/components/download/download.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -97,15 +97,19 @@ const Download = observer(({ tab }: TDownloadProps) => {
>
<Button
id='download-button'
is_disabled={disabled}
disabled={disabled}
className='download__button'
icon={
<Icon icon='IcDbotDownload' color={disabled ? 'disabled' : undefined} className='download__icon' />
}
text={localize('Download')}
onClick={clickFunction}
secondary
/>
variant='outlined'
color='black'
size='sm'
textSize='sm'
>
{localize('Download')}
</Button>
</Popover>
);
});
Expand Down
7 changes: 5 additions & 2 deletions src/components/run-panel/run-panel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,13 @@ import React from 'react';
import classNames from 'classnames';
import { observer } from 'mobx-react-lite';

import { Button, Modal, Tabs, Text } from '@deriv-com/ui';
import { Button, Modal, Text } from '@deriv-com/ui';

import Journal from '@/components/journal';
import SelfExclusion from '@/components/self-exclusion';
import Drawer from '@/components/shared_ui/drawer';
import Money from '@/components/shared_ui/money';
import Tabs from '@/components/shared_ui/tabs';
import Summary from '@/components/summary';
import TradeAnimation from '@/components/trade-animation';
import Transactions from '@/components/transactions';
Expand Down Expand Up @@ -154,8 +155,10 @@ const DrawerFooter = ({ is_clear_stat_disabled, onClearStatClick }: TDrawerFoote
className='run-panel__footer-button'
disabled={is_clear_stat_disabled}
onClick={onClearStatClick}
has_effect
variant='outlined'
color='black'
size='sm'
textSize='sm'
>
<span>{localize('Reset')}</span>
</Button>
Expand Down
12 changes: 8 additions & 4 deletions src/components/transactions/transactions.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -114,14 +114,18 @@ const Transactions = observer(({ is_drawer_open }: TTransactions) => {
<Button
id='download__container__view-detail-button'
className='download__container__view-detail-button'
is_disabled={!transaction_list?.length}
text={localize('View Detail')}
disabled={!transaction_list?.length}
onClick={() => {
toggleTransactionDetailsModal(true);
}}
secondary
icon={<Icon icon='IcDbotViewDetail' size={18} />}
/>
variant='outlined'
color='black'
size='sm'
textSize='sm'
>
{localize('View Detail')}
</Button>
</div>
<div className='transactions__header'>
<span className='transactions__header-column transactions__header-type'>{localize('Type')}</span>
Expand Down
3 changes: 1 addition & 2 deletions src/pages/bot-builder/toolbox/search-box/search-box.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import { Field as FormField, FieldProps, Form, Formik } from 'formik';

import { Input } from '@deriv-com/ui';

import Input from '@/components/shared_ui/input';
import { localize } from '@/utils/tmp/dummy';

import SearchIcon from './search-icon';
Expand Down

0 comments on commit 05303ff

Please sign in to comment.