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

Update some small style regressions in the template list #36822

Merged
merged 1 commit into from Nov 26, 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.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
24 changes: 16 additions & 8 deletions packages/edit-site/src/components/list/style.scss
Expand Up @@ -61,10 +61,12 @@

.edit-site-list-table {
width: 100%;
border: $border-width solid $gray-200;
border: $border-width solid $gray-300;
border-radius: 2px;
margin: 0;
overflow: hidden;
border-spacing: 0;
max-width: 960px;

tr {
display: flex;
Expand All @@ -74,17 +76,18 @@
border-top: $border-width solid $gray-100;
margin: 0;

&:first-child {
border-top: 0;
}

@include break-medium() {
padding: $grid-unit-30 $grid-unit-40;
}

// Template.
.edit-site-list-table-column:nth-child(1) {
width: calc(60% - 36px);
flex-grow: 1;
display: flex;
flex-direction: column;
align-items: flex-start;
width: calc(60% - 18px);
padding-right: $grid-unit-30;

a {
display: inline-block;
Expand All @@ -96,7 +99,7 @@

// Added by.
.edit-site-list-table-column:nth-child(2) {
width: calc(40% - 36px);
width: calc(40% - 18px);
}

// Actions.
Expand All @@ -110,7 +113,12 @@
font-size: 16px;
font-weight: 600;
text-align: left;
color: #050505;
color: $gray-900;
border-top: none;
border-bottom: $border-width solid $gray-300;

th {
font-weight: inherit;
}
}
}
19 changes: 11 additions & 8 deletions packages/edit-site/src/components/list/table.js
Expand Up @@ -9,6 +9,7 @@ import {
DropdownMenu,
MenuGroup,
MenuItem,
__experimentalHeading as Heading,
} from '@wordpress/components';
import { moreVertical } from '@wordpress/icons';
import { addQueryArgs } from '@wordpress/url';
Expand Down Expand Up @@ -146,14 +147,16 @@ export default function Table( { templateType } ) {
role="row"
>
<td className="edit-site-list-table-column" role="cell">
<a
href={ addQueryArgs( window.location.href, {
postId: template.id,
postType: template.type,
} ) }
>
{ template.title.rendered }
</a>
<Heading level={ 4 }>
<a
href={ addQueryArgs( window.location.href, {
postId: template.id,
postType: template.type,
} ) }
>
{ template.title.rendered }
</a>
</Heading>
{ template.description }
</td>

Expand Down