Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: Columns are misaligned on Payments->Deposits #1838

Merged
merged 4 commits into from
May 19, 2021
Merged
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
1 change: 1 addition & 0 deletions changelog.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
* Fix - Fix hover dialog for close button on modals, unify styling and layout of modal buttons.
* Update - Use Site Language when rendering Stripe elements.
* Update - Use blog ID for authenticating most of the requests.
* Fix: Misaligned columns on Deposits page.

= 2.4.0 - 2021-05-12 =
* Update - Improve the Connect Account page.
Expand Down
4 changes: 3 additions & 1 deletion client/deposits/list/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ import ClickableCell from 'components/clickable-cell';
import Page from '../../components/page';
import DepositsFilters from '../filters';

import './style.scss';

const getColumns = ( sortByDate ) => [
{
key: 'details',
Expand Down Expand Up @@ -159,7 +161,7 @@ export const DepositsList = () => {
<Page>
<DepositsFilters storeCurrencies={ storeCurrencies } />
<TableCard
className="deposits-list woocommerce-report-table"
className="wcpay-deposits-list woocommerce-report-table"
title={ __( 'Deposit history', 'woocommerce-payments' ) }
isLoading={ isLoading }
rowsPerPage={ getQuery().per_page || 25 }
Expand Down
14 changes: 14 additions & 0 deletions client/deposits/list/style.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
$space-header-item: 25px;

.wcpay-deposits-list {
// alignment override for header items
.woocommerce-table__header:not( .is-left-aligned ),
.woocommerce-table__item:not( .is-left-aligned ) {
text-align: center;
}

// slight adjustment to align header items with sorting button to account for icon width
.woocommerce-table__header.is-numeric .components-button {
margin-right: $space-header-item;
}
}
4 changes: 2 additions & 2 deletions client/deposits/list/test/__snapshots__/index.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ exports[`Deposits list renders correctly with multiple currencies 1`] = `
</div>
</div>
<div
class="woocommerce-card woocommerce-table woocommerce-analytics__card deposits-list woocommerce-report-table has-menu"
class="woocommerce-card woocommerce-table woocommerce-analytics__card wcpay-deposits-list woocommerce-report-table has-menu"
>
<div
class="woocommerce-card__header"
Expand Down Expand Up @@ -478,7 +478,7 @@ exports[`Deposits list renders correctly with single currency 1`] = `
/>
</div>
<div
class="woocommerce-card woocommerce-table woocommerce-analytics__card deposits-list woocommerce-report-table has-menu"
class="woocommerce-card woocommerce-table woocommerce-analytics__card wcpay-deposits-list woocommerce-report-table has-menu"
>
<div
class="woocommerce-card__header"
Expand Down
4 changes: 2 additions & 2 deletions client/transactions/list/style.scss
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
@import 'node_modules/@wordpress/components/src/tooltip/style.scss';

$space-header-item: 15px;
$space-header-item: 25px;

.transactions-list {
.date-time {
Expand All @@ -9,7 +9,7 @@ $space-header-item: 15px;

.converted-amount {
display: flex; // Necessary for conversion tooltip to show.
justify-content: flex-end;
justify-content: center;

.conversion-indicator {
margin-right: 6px;
Expand Down
1 change: 1 addition & 0 deletions readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,7 @@ Please note that our support for the checkout block is still experimental and th
* Fix - Fix hover dialog for close button on modals, unify styling and layout of modal buttons.
* Update - Use Site Language when rendering Stripe elements.
* Update - Use blog ID for authenticating most of the requests.
* Fix: Misaligned columns on Deposits page.

= 2.4.0 - 2021-05-12 =
* Update - Improve the Connect Account page.
Expand Down